KeyError: 'OMEMO' on sending a file with HTTP upload and OMEMO if protobuf issue is not workaround
Versions:
- OS: Linux 6.0.8-1-default
- GTK Version: 3.24.34
- PyGObject Version: 3.42.2
- GLib Version : 2.74.0
- python-nbxmpp Version: 3.2.5
- Gajim Version: 1.5.3+36c2158d
Traceback
Traceback (most recent call last):
File "/home/<snip>/Development/gajim/gajim/gtk/chat_function_page.py", line 284, in _on_confirm_clicked
self._send_files(self._widget.get_catalog())
File "/home/<snip>/Development/gajim/gajim/gtk/chat_function_page.py", line 375, in _send_files
client.get_module('HTTPUpload').send_file(
File "/home/<snip>/Development/gajim/gajim/common/modules/httpupload.py", line 136, in send_file
self._start_transfer(transfer)
File "/home/<snip>/Development/gajim/gajim/common/modules/httpupload.py", line 227, in _start_transfer
plugin = app.plugin_manager.encryption_plugins[transfer.encryption]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^
KeyError: 'OMEMO'
Steps to reproduce the problem
11/27/2022 14:31:48 (E) gajim.p.omemo 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).
In this case
- Start Gajim without
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
- Send a file via HTTP upload and with OMEMO enabled
I assume the error should be catched.