Anaconda jupyter 笔记本“连接失败”错误

时间:2021-05-25 07:25:53

标签: python jupyter-notebook anaconda kernel jupyter

我最近安装了 anaconda 并尝试运行 Jupyter Notebook。我使用的是 Windows 10。我打开了一个文件夹并运行了笔记本。每当我单击打开文件时,在将文件加载到新选项卡几秒钟后,我都会看到以下错误消息: Error message

当我点击“确定”时,我也看到了: enter image description here

enter image description here

我已经重新安装了 anaconda 三次以上,但这个问题仍然存在。我的互联网连接在这里不是问题,因为我可以在其他选项卡上运行 google。 以下是anaconda提示上的错误信息:\


(base) C:\Users\aayus>cd c:\MLcourse

(base) c:\MLCourse>jupyter-notebook
[W 2021-05-25 12:49:15.300 LabApp] 'ip' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[W 2021-05-25 12:49:15.301 LabApp] 'ip' has moved from NotebookApp to ServerApp. This config will be passed to ServerApp. Be sure to update your config before our next release.
[I 2021-05-25 12:49:15.317 LabApp] JupyterLab extension loaded from C:\Users\aayus\anaconda3\lib\site-packages\jupyterlab
[I 2021-05-25 12:49:15.317 LabApp] JupyterLab application directory is C:\Users\aayus\anaconda3\share\jupyter\lab
[I 12:49:15.322 NotebookApp] Serving notebooks from local directory: c:\MLCourse
[I 12:49:15.323 NotebookApp] Jupyter Notebook 6.3.0 is running at:
[I 12:49:15.324 NotebookApp] http://localhost:8888/?token=a24e8ab3aa1629c4892dded671be9d26b149e7492d74a1e9
[I 12:49:15.324 NotebookApp]  or http://127.0.0.1:8888/?token=a24e8ab3aa1629c4892dded671be9d26b149e7492d74a1e9
[I 12:49:15.324 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 12:49:15.366 NotebookApp]

    To access the notebook, open this file in a browser:
        file:///C:/Users/aayus/AppData/Roaming/jupyter/runtime/nbserver-21792-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/?token=a24e8ab3aa1629c4892dded671be9d26b149e7492d74a1e9
     or http://127.0.0.1:8888/?token=a24e8ab3aa1629c4892dded671be9d26b149e7492d74a1e9
[W 12:49:27.828 NotebookApp] Notebook ConditionalProbabilityExercise.ipynb is not trusted
Bad address (C:\ci\zeromq_1602704446950\work\src\epoll.cpp:100)
[I 12:49:28.339 NotebookApp] Kernel started: 4ed3dc80-f87f-41f4-9981-320da9710f87, name: python3
Bad address (C:\ci\zeromq_1602704446950\work\src\epoll.cpp:100)
Bad address (C:\ci\zeromq_1602704446950\work\src\epoll.cpp:100)

(base) c:\MLCourse>[IPKernelApp] WARNING | Parent appears to have exited, shutting down.

有人可以帮忙吗?我是一个公平的初学者,找不到答案。 提前致谢

1 个答案:

答案 0 :(得分:0)

在重新安装 Anaconda 并在此处找到解决方案后,我遇到了同样的错误:https://github.com/jupyter/notebook/issues/4909

我激活了我有问题的环境并安装了以下内容:

  • conda install -c conda-forge pywin32
  • conda install -c anaconda jupyter_client
  • conda install -c conda-forge jupyter_core

像魅力一样工作!