Hi,
We are trying to connect the Onyx 3.0.5 to our Zulip installation 9.4.
1. Bug in Zulip Connector — tempfile.tempdir vs tempfile.gettempdir():
Claude identified an issue in "/app/onyx/connectors/zulip/connector.py"
tempdir = tempfile.tempdir # This is None unless explicitly set
if tempdir is None:
raise Exception("Could not determine tempfile directory")
The code is reading tempfile.tempdir — which is a user-settable variable that defaults to None — instead of calling tempfile.gettempdir(), which is the correct function that actually returns the system temp directory (and is what proved writable as /tmp in your test).
This is a bug in the Onyx Zulip connector code. It should be:
tempdir = tempfile.gettempdir()
The temporary fix we applied to the running container:
docker exec -it onyx-background-1 sed -i \
's/tempdir = tempfile.tempdir/tempdir = tempfile.gettempdir()/' \
/app/onyx/connectors/zulip/connector.py
Also remove the now-unnecessary None check (optional but clean)
Verify the change looks right first:
docker exec -it onyx-background-1 grep -n "tempdir\|gettempdir" /app/onyx/connectors/zulip/connector.py
docker restart onyx-background-1
This resolved the issue when the connector was showing errors during indexing.
2. No Documents Being Indexed
Despite the connector now showing as healthy, no documents are being indexed from Zulip.
We have verified:
- The Realm is set to the name of the Zulip organisation
- The bot account is a member of all test channels
Can you advise:
- Is the
tempfile.tempdir bug a known issue, or is it specific to a particular version?
- Which versions of Zulip does the Onyx connector officially support?
Many thanks
Hi,
We are trying to connect the Onyx 3.0.5 to our Zulip installation 9.4.
1. Bug in Zulip Connector — tempfile.tempdir vs tempfile.gettempdir():
Claude identified an issue in "/app/onyx/connectors/zulip/connector.py"
The code is reading tempfile.tempdir — which is a user-settable variable that defaults to None — instead of calling tempfile.gettempdir(), which is the correct function that actually returns the system temp directory (and is what proved writable as /tmp in your test).
This is a bug in the Onyx Zulip connector code. It should be:
tempdir = tempfile.gettempdir()
The temporary fix we applied to the running container:
Also remove the now-unnecessary None check (optional but clean)
Verify the change looks right first:
docker exec -it onyx-background-1 grep -n "tempdir\|gettempdir" /app/onyx/connectors/zulip/connector.pydocker restart onyx-background-1This resolved the issue when the connector was showing errors during indexing.
2. No Documents Being Indexed
Despite the connector now showing as healthy, no documents are being indexed from Zulip.
We have verified:
Can you advise:
tempfile.tempdirbug a known issue, or is it specific to a particular version?Many thanks