chainlit
chainlit copied to clipboard
Chainlit 2.8.5 Copilot mode throws Thread {thread_id} not found
Describe the bug Since Chainlit 2.8.5, I now get Thread {thread_id} not found
To Reproduce .env CHAINLIT_AUTH_SECRET="Your secret" CUSTOM_AUTH=true
Frontend:
window.mountChainlitWidget({ chainlitServer: "http://127.0.0.1:8000", // Your Chainlit backend endpoint accessToken: accessToken, // Pass your generated JWT token theme: "light", customCssUrl: "http://127.0.0.1:8000/public/custom.css", expanded: false });
Full error:
File "c:\Program Files\Python311\Lib\site-packages\engineio\async_server.py", line 483, in run_async_handler return await self.handlersevent ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "c:\Program Files\Python311\Lib\site-packages\socketio\async_server.py", line 672, in _handle_eio_message await self._handle_connect(eio_sid, pkt.namespace, pkt.data) File "c:\Program Files\Python311\Lib\site-packages\socketio\async_server.py", line 551, in _handle_connect success = await self._trigger_event( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "c:\Program Files\Python311\Lib\site-packages\socketio\async_server.py", line 637, in _trigger_event ret = await handler(*args) ^^^^^^^^^^^^^^^^^^^^ File "c:\Program Files\Python311\Lib\site-packages\chainlit\socket.py", line 142, in connect if not (await data_layer.get_thread_author(thread_id) == user.identifier): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "c:\Program Files\Python311\Lib\site-packages\chainlit\data\chainlit_data_layer.py", line 420, in get_thread_author raise ValueError(f"Thread {thread_id} not found")