Skip to content

KeyError when bridging Zulip to Element #754

@vigoux

Description

@vigoux

Hi, using the zulip api, I can't connect my zulip server to Matrix (element.org) because this raises an error.

I followed the steps described in the docs, and here is the error:

Starting matrix mirroring bot (this may take a minute)
Traceback (most recent call last):
  File "/<redacted>/python-zulip-api/zulip/integrations/bridge_with_matrix/matrix_bridge.py", line 333, in main
    matrix_login(matrix_client, matrix_config)
  File "/<redacted>/python-zulip-api/zulip/integrations/bridge_with_matrix/matrix_bridge.py", line 42, in matrix_login
    matrix_client.login_with_password(matrix_config["mxid"], matrix_config["password"])
  File "/<redacted>/python-zulip-api/zulip-api-py3-venv/lib/python3.10/site-packages/matrix_client/client.py", line 249, in login_with_password
    self._sync()
  File "/<redacted>/python-zulip-api/zulip-api-py3-venv/lib/python3.10/site-packages/matrix_client/client.py", line 551, in _sync
    for presence_update in response['presence']['events']:
KeyError: 'presence'
WARNING:zulip:Sleeping for 2s [max 2] before retrying.

Here is my matrix bridge config:

[matrix]
host = https://matrix.org
mxid = @nvimts-bot:matrix.org
password = <redacted>
room_id = #nvim-treesitter:matrix.org

[zulip]
email = nvim-treesitter-bridge-bot@zulipchat.com
api_key = <redacted>
site = https://nvim-treesitter.zulipchat.com
stream = general
topic = Gitter

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions