这就是我在终端机上输入的内容
(python_streamlit) kaipo@Kaipos-MacBook-Pro python_streamlit % streamlit hello这是我得到的回报
Traceback (most recent call last):
File "/Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/bin/streamlit", line 5, in <module>
from streamlit.web.cli import main
File "/Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/streamlit/__init__.py", line 48, in <module>
from streamlit.proto.RootContainer_pb2 import RootContainer
File "/Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/streamlit/proto/RootContainer_pb2.py", line 6, in <module>
from google.protobuf import descriptor as _descriptor
File "/Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/google/protobuf/descriptor.py", line 47, in <module>
from google.protobuf.pyext import _message
ImportError: dlopen(/Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/google/protobuf/pyext/_message.cpython-310-darwin.so, 2): Symbol not found: __ZN6google8protobuf15FieldDescriptor12TypeOnceInitEPKS1_
Referenced from: /Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/google/protobuf/pyext/_message.cpython-310-darwin.so
Expected in: flat namespace
in /Users/kaipo/.local/share/virtualenvs/python_streamlit-XyirRlP5/lib/python3.10/site-packages/google/protobuf/pyext/_message.cpython-310-darwin.so我已经做了
pipenv shell使用新的流光环境
它也在最新的更新中,Pipfile和Pipfile.lock在我的文件夹中。我也在macOS上。
感谢各位对此有什么想法:)
发布于 2022-09-21 07:20:45
您的protobuf版本似乎不兼容。尝试安装此版本:
protobuf = ">=3.6.0, !=3.11"https://stackoverflow.com/questions/73796603
复制相似问题