Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

protobuf: "A file with this name is already in the pool." #3149

Open
heeplr opened this issue Jun 8, 2022 · 2 comments
Open

protobuf: "A file with this name is already in the pool." #3149

heeplr opened this issue Jun 8, 2022 · 2 comments
Assignees

Comments

@heeplr
Copy link

heeplr commented Jun 8, 2022

Describe the bug

I'm using yowsup with transwhat and this looks like a yowsup issue (please correct me if I'm wrong):

/usr/bin/transwhat --debug --host 127.0.0.1 --port 33760 --service.backend_id=1 "-j" "whatsapp.example.com" "/etc/spectrum2/transports/transwhat-whatsapp.cfg"
Traceback (most recent call last):
  File "/usr/lib/python-exec/python3.9/transwhat", line 33, in <module>
    sys.exit(load_entry_point('transwhat==0.2.2', 'console_scripts', 'transwhat')())
  File "/usr/lib/python-exec/python3.9/transwhat", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/usr/lib/python3.9/importlib/metadata.py", line 86, in load
    module = import_module(match.group('module'))
  File "/usr/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/usr/lib/python3.9/site-packages/transWhat/transwhat.py", line 12, in <module>
    from yowsup.stacks import YowStack
  File "/usr/lib/python3.9/site-packages/yowsup/stacks/__init__.py", line 1, in <module>
    from .yowstack import YowStack, YowStackBuilder
  File "/usr/lib/python3.9/site-packages/yowsup/stacks/yowstack.py", line 10, in <module>
    from yowsup.layers.protocol_messages           import YowMessagesProtocolLayer
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/__init__.py", line 1, in <module>
    from .layer import YowMessagesProtocolLayer
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/layer.py", line 2, in <module>
    from .protocolentities import TextMessageProtocolEntity
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/protocolentities/__init__.py", line 1, in <module>
    from .message_text import TextMessageProtocolEntity
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/protocolentities/message_text.py", line 1, in <module>
    from .protomessage import ProtomessageProtocolEntity
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/protocolentities/protomessage.py", line 3, in <module>
    from yowsup.layers.protocol_messages.protocolentities.attributes.converter import AttributesConverter
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/protocolentities/attributes/converter.py", line 1, in <module>
    from yowsup.layers.protocol_messages.proto.e2e_pb2 import Message
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/proto/e2e_pb2.py", line 15, in <module>
    from . import protocol_pb2 as protocol__pb2
  File "/usr/lib/python3.9/site-packages/yowsup/layers/protocol_messages/proto/protocol_pb2.py", line 17, in <module>
    DESCRIPTOR = _descriptor.FileDescriptor(
  File "/usr/lib/python3.9/site-packages/google/protobuf/descriptor.py", line 982, in __new__
    return _message.default_pool.AddSerializedFile(serialized_pb)
TypeError: Couldn't build proto file into descriptor pool!
Invalid proto descriptor for file "protocol.proto":
  protocol.proto: A file with this name is already in the pool.

Config file

Not sure where to get the config from. (Kindly advice so I can provide all necessary info)

Versions

python: 3.9

yowsup-cli v3.2.1
using:
  yowsup v3.3.0
  consonance v0.1.5
  dissononce v0.34.3
  python-axolotl v0.2.3
  cryptography v37.0.2
  protobuf v3.19.3

To Reproduce

/usr/bin/transwhat --debug --host 127.0.0.1 --port 33760 --service.backend_id=1 "-j" "whatsapp.example.com" "/etc/spectrum2/transports/transwhat-whatsapp.cfg"

Expected behavior
Startup of transwhat

OS (please complete the following information):
Gentoo Linux

@heeplr
Copy link
Author

heeplr commented Jun 10, 2022

Found protobuf issue #3002 that's most probably related.

@heeplr
Copy link
Author

heeplr commented Feb 9, 2023

Bumping this as I still got that error with:

yowsup-cli v3.2.1
using:
  yowsup v3.3.0
  consonance v0.1.5-r1
  dissononce v0.34.3-r3
  python-axolotl v0.2.3-r3
  cryptography v39.0.1
  protobuf v21.9

Any hint appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants