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

Debug & remove error logs on extension init #113

Open
dlqqq opened this issue Dec 9, 2024 · 2 comments
Open

Debug & remove error logs on extension init #113

dlqqq opened this issue Dec 9, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@dlqqq
Copy link
Member

dlqqq commented Dec 9, 2024

Description

When starting the v3-dev branch of jupyterlab/jupyter-ai, I see several error logs being printed in the terminal every time I start the JupyterLab:

[I 2024-12-04 10:56:20.168 ServerApp] Initializing room text:chat:41030a07-f29d-4ded-b13b-39dfda2b43bb
[E 2024-12-04 10:56:20.169 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/jupyter_collaboration/handlers.py", line 270, in send
        self.write_message(message, binary=True)
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
[I 2024-12-04 10:56:20.241 AiExtension] Registered chat handler `test` with command `/test`.
[E 2024-12-04 10:56:20.242 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/jupyter_collaboration/handlers.py", line 270, in send
        self.write_message(message, binary=True)
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
[E 2024-12-04 10:56:20.242 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/jupyter_collaboration/handlers.py", line 270, in send
        self.write_message(message, binary=True)
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
[E 2024-12-04 10:56:20.243 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/jupyter_collaboration/handlers.py", line 270, in send
        self.write_message(message, binary=True)
      File "/Users/dlq/micromamba/envs/jai3/lib/python3.11/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
@dlqqq dlqqq added the bug Something isn't working label Dec 9, 2024
@dlqqq dlqqq added this to the Jupyter AI v3.0.0a0 milestone Dec 9, 2024
@brichet
Copy link
Collaborator

brichet commented Dec 10, 2024

Thanks @dlqqq.

I think that these errors come from jupyter_collaboration.
Below is the console with a collaborative Notebook opened in the workspace, in an environment without jupyterlab-chat.

[I 2024-12-10 14:54:01.891 ServerApp] Initializing room json:notebook:70d90075-bd0b-45ec-ba9d-4435e8026f4a
[E 2024-12-10 14:54:01.892 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/jupyter_server_ydoc/handlers.py", line 268, in send
        self.write_message(message, binary=True)
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
[I 2024-12-10 14:54:01.990 ServerApp] Content in room json:notebook:70d90075-bd0b-45ec-ba9d-4435e8026f4a loaded from the ystore SQLiteYStore
[E 2024-12-10 14:54:02.053 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/jupyter_server_ydoc/handlers.py", line 268, in send
        self.write_message(message, binary=True)
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError
[E 2024-12-10 14:54:02.055 ServerApp] Failed to write message
    Traceback (most recent call last):
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/jupyter_server_ydoc/handlers.py", line 268, in send
        self.write_message(message, binary=True)
      File "/home/brichet/mambaforge/envs/jupyter-collab/lib/python3.12/site-packages/tornado/websocket.py", line 332, in write_message
        raise WebSocketClosedError()
    tornado.websocket.WebSocketClosedError

@dlqqq
Copy link
Member Author

dlqqq commented Dec 10, 2024

@brichet Thanks for the quick research. Let's keep this issue open to track the upstream work that needs to be done on jupyter_collaboration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants