2016-12-16 4 views
0

Ich erstelle eine neue Python 3 virtuelle Umgebung mit einem Jupyter Notebook-Server mit den folgenden Befehlen:Warum kann das Jupyter-Notebook die WebSocket-Verbindung nicht authentifizieren?

virtualenv env -p python3 
. env/bin/activate 
pip install jupyter 
jupyter notebook 

alle diese erfolgreich läuft. Aber wenn ich versuche, ein neues Notebook zu erstellen, erhalte ich einen WebSocket-Authentifizierungsfehler und kann das Notebook nicht erstellen. Der Client sagt

Eine Verbindung zum Notebook-Server konnte nicht hergestellt werden. Das Notebook versucht weiterhin, die Verbindung wiederherzustellen. Überprüfen Sie Ihre Netzwerkverbindung oder Notebook-Server-Konfiguration. Hier

ist das Protokoll vom Jupyter Notebook Server:

[I 22:50:23.085 NotebookApp] The port 8888 is already in use, trying another port. 
[I 22:50:23.110 NotebookApp] Serving notebooks from local directory: /tmp 
[I 22:50:23.110 NotebookApp] 0 active kernels 
[I 22:50:23.110 NotebookApp] The Jupyter Notebook is running at: http://localhost:8889/?token=b4d69926e308334a4ca121d3ceaa0dfa9f1ba93312770f88 
[I 22:50:23.110 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation). 
[I 22:50:36.778 NotebookApp] Accepting one-time-token-authenticated connection from 127.0.0.1 
[I 22:52:01.083 NotebookApp] Creating new notebook in 
[W 22:52:06.372 NotebookApp] 404 GET /nbextensions/widgets/notebook/js/extension.js?v=20161215225022 (127.0.0.1) 38.39ms referer=http://localhost:8889/notebooks/Untitled.ipynb?kernel_name=python3 
[I 22:52:06.855 NotebookApp] Kernel started: 7b5db30f-e2b2-48dc-9ec8-2aa9bd63b604 
[W 22:52:07.130 NotebookApp] Couldn't authenticate WebSocket connection 
[W 22:52:07.140 NotebookApp] 403 GET /api/kernels/7b5db30f-e2b2-48dc-9ec8-2aa9bd63b604/channels?session_id=277CA36E71FA431C922EE9F8AEFF6261 (127.0.0.1) 14.42ms referer=None 
[W 22:52:08.435 NotebookApp] Couldn't authenticate WebSocket connection 
[W 22:52:08.446 NotebookApp] 403 GET /api/kernels/7b5db30f-e2b2-48dc-9ec8-2aa9bd63b604/channels?session_id=277CA36E71FA431C922EE9F8AEFF6261 (127.0.0.1) 16.36ms referer=None 
WARNING: Attempting to work in a virtualenv. If you encounter problems, please install IPython inside the virtualenv. 
[W 22:52:10.619 NotebookApp] Couldn't authenticate WebSocket connection 
[W 22:52:10.622 NotebookApp] 403 GET /api/kernels/7b5db30f-e2b2-48dc-9ec8-2aa9bd63b604/channels?session_id=277CA36E71FA431C922EE9F8AEFF6261 (127.0.0.1) 10.53ms referer=None 
[W 22:52:14.657 NotebookApp] Couldn't authenticate WebSocket connection 
[W 22:52:14.666 NotebookApp] 403 GET /api/kernels/7b5db30f-e2b2-48dc-9ec8-2aa9bd63b604/channels?session_id=277CA36E71FA431C922EE9F8AEFF6261 (127.0.0.1) 15.54ms referer=None 

Was bedeuten diese Fehler bedeuten und wie kann ich es beheben?

Ich benutze Ubuntu 16.10, Python 3.5.2 und Jupyter 4.2.1.

Antwort

1

Ich habe gestern genau diesen gleichen Fehler bekommen und es stellte sich heraus, dass es vom lastpass chrome plugin verursacht wurde. Siehe hierzu other post für weitere Informationen.

+0

Danke. Ich benutzte den [Brave Browser] (https://brave.com/), aber jetzt bin ich zu Firefox gewechselt und es funktioniert. – argentpepper

Verwandte Themen