You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(packj) uzer@smarttop ~/packj $
python3 /home/uzer/packj.git/main.py pypi yt-dlp
Traceback (most recent call last):
File "/home/uzer/packj.git/main.py", line 23, in <module>
from static_util import get_static_proxy_for_language
File "/home/uzer/packj.git/static_util.py", line 4, in <module>
from static_proxy.py_analyzer import PyAnalyzer
File "/home/uzer/packj.git/static_proxy/py_analyzer.py", line 13, in <module>
import proto.python.ast_pb2 as ast_pb2
File "/home/uzer/packj.git/proto/python/ast_pb2.py", line 32, in <module>
_descriptor.EnumValueDescriptor(
File "/home/uzer/packj/lib/python3.8/site-packages/google/protobuf/descriptor.py", line 755, in __new__
_message.Message._CheckCalledFromGeneratedFile()
TypeError: Descriptors cannot not be created directly.
If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.
If you cannot immediately regenerate your protos, some other possible workarounds are:
1. Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
More information: https://developers.google.com/protocol-buffers/docs/news/2022-05-06#python-updates
The text was updated successfully, but these errors were encountered:
, the version is being stripped from the requirements. Because the protobuf version is not pinned the latest protobuf version is installed, which is incompatible with this package.
It took me a long time to find this out, I didn't notice the split() logic so I thought setup.py was installing the pinned version in the requirements file. I was baffled as to why the wrong version was being installed. I was in python dependency hell looking over various debug logs and metadata until I realized the answer was right in front of me... 😅
virtualenv packj
. packj/bin/activate
pip install -r requirements.txt
The text was updated successfully, but these errors were encountered: