当我打开笔记本时,Jupyter笔记本内核不断重启

问题描述 投票:2回答:1

服务器启动但是当我打开一个笔记本,即使是一个空白的笔记本,内核死了并不断重启。我在arch-linux中使用python3.7。错误“RuntimeError:此事件循环已在运行”继续在循环中发生。

Connecting to: tcp://127.0.0.1:36789
Traceback (most recent call last):
  File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/usr/lib/python3.7/site-packages/ipykernel_launcher.py", line 16, in <module>
    app.launch_new_instance()
  File "/usr/lib/python3.7/site-packages/traitlets/config/application.py", line 658, in launch_instance
    app.start()
  File "/usr/lib/python3.7/site-packages/ipykernel/kernelapp.py", line 477, in start
    ioloop.IOLoop.instance().start()
  File "/usr/lib/python3.7/site-packages/tornado/platform/asyncio.py", line 132, in start
    self.asyncio_loop.run_forever()
  File "/usr/lib/python3.7/asyncio/base_events.py", line 510, in run_forever
    raise RuntimeError('This event loop is already running')
RuntimeError: This event loop is already running
jupyter-notebook python-3.7
1个回答
0
投票

这可能是一个Arch Linux问题,已在他们的论坛上多次询问,例如herebug report已经创建。它应该在python-ipykernel升级后解决,但我不知道这需要多长时间。

更新:它已在repo中更新,因此升级系统将修复它。

对我有用的临时hacky解决方案是使用pip作为用户升级它(因此它安装在〜/ .local而不是/ usr /),即:

pip install --user --upgrade ipykernel

这样,您不必降级任何软件包(这可能是一个更好的解决方案,但更烦人)。当Arch团队升级了软件包时,删除pip-version(pip uninstall ipykernel)可能是个好主意。

© www.soinside.com 2019 - 2024. All rights reserved.