简体   繁体   English

无法打开 jupyter 笔记本

[英]Cannot open jupyter notebook

Jupyter notebooks will not open for me. Jupyter notebooks 不会为我打开。 I've installed a fresh version of Anaconda and I'm still encountering the same issue.我已经安装了 Anaconda 的新版本,但我仍然遇到同样的问题。 This is using Chrome on a Windows 11 machine but I've also had the same issue with Edge.这是在 Windows 11 机器上使用 Chrome,但我也遇到了与 Edge 相同的问题。 This issue is encountered whenever I try to open a notebook using a Python kernel.每当我尝试使用 Python kernel 打开笔记本时都会遇到此问题。

Things I've tried: uninstalling and reinstalling Anaconda, updating jupyter, testing with a new notebook, and using a fresh conda environment.我尝试过的事情:卸载并重新安装 Anaconda,更新 jupyter,使用新笔记本进行测试,以及使用全新的 conda 环境。

Does anyone have an idea what might be the problem?有谁知道可能是什么问题?

Below are the logs for reference.以下是日志供参考。

(base) C:\Users\info>jupyter notebook
[I 2022-08-28 20:34:08.379 LabApp] JupyterLab extension loaded from C:\Users\info\anaconda3\lib\site-packages\jupyterlab
[I 2022-08-28 20:34:08.379 LabApp] JupyterLab application directory is C:\Users\info\anaconda3\share\jupyter\lab
[I 20:34:08.384 NotebookApp] Serving notebooks from local directory: C:\Users\info
[I 20:34:08.384 NotebookApp] Jupyter Notebook 6.4.8 is running at:
[I 20:34:08.384 NotebookApp] http://localhost:8888/?token=c807506f35308673e826bffac9193f7fe551a92a0e1c67de
[I 20:34:08.385 NotebookApp]  or http://127.0.0.1:8888/?token=c807506f35308673e826bffac9193f7fe551a92a0e1c67de
[I 20:34:08.385 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 20:34:08.425 NotebookApp]

    To access the notebook, open this file in a browser:
        file:///C:/Users/info/AppData/Roaming/jupyter/runtime/nbserver-4468-open.html
    Or copy and paste one of these URLs:
        http://localhost:8888/?token=c807506f35308673e826bffac9193f7fe551a92a0e1c67de
     or http://127.0.0.1:8888/?token=c807506f35308673e826bffac9193f7fe551a92a0e1c67de
[W 20:34:08.549 NotebookApp] 404 GET /api/kernels/ce107385-7d51-45a6-8222-88f5d792c01b/channels?session_id=02de077cc1b6404d8537c297bbbccf4d (127.0.0.1): Kernel does not exist: ce107385-7d51-45a6-8222-88f5d792c01b
[W 20:34:08.563 NotebookApp] 404 GET /api/kernels/ce107385-7d51-45a6-8222-88f5d792c01b/channels?session_id=02de077cc1b6404d8537c297bbbccf4d (127.0.0.1) 14.950000ms referer=None
[W 20:34:14.725 NotebookApp] Notebook Untitled1.ipynb is not trusted
[I 20:34:14.793 NotebookApp] Kernel started: 152ee412-debd-4785-a2be-3b6f5831d7e2, name: python3
Traceback (most recent call last):
  File "C:\Users\info\anaconda3\lib\runpy.py", line 197, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\info\anaconda3\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Users\info\AppData\Roaming\Python\Python39\site-packages\ipykernel_launcher.py", line 16, in <module>
    app.launch_new_instance()
  File "C:\Users\info\anaconda3\lib\site-packages\traitlets\config\application.py", line 846, in launch_instance
    app.start()
  File "C:\Users\info\AppData\Roaming\Python\Python39\site-packages\ipykernel\kernelapp.py", line 477, in start
    ioloop.IOLoop.instance().start()
  File "C:\Users\info\AppData\Roaming\Python\Python39\site-packages\tornado\platform\asyncio.py", line 199, in start
    self.asyncio_loop.run_forever()
  File "C:\Users\info\anaconda3\lib\asyncio\windows_events.py", line 319, in run_forever
    assert self._self_reading_future is None
AssertionError

I am not sure how to solve the problem but why don't you use vscode with jupyter extension it works with me like charm我不知道如何解决这个问题,但你为什么不使用带有jupyter 扩展的 vscode 它像魅力一样对我有用

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM