【Bug】jupyter notebook运行一直显示:kernel starting,please wait(Ubuntu)

即使重装后kernel也一直卡在starting,弄了好长时间
参考的了这个博客https://blog.csdn.net/weixin_46088071/article/details/103803928

python -m ipykernel install --user

到这步时依旧报错ImportError: cannot import name 'create_prompt_application'
应该有很多朋友在安装jupyter时出现过这个错误提示,代码无法运行,服务器无法连接。
原因:prompt-toolkit版本不对。jupyter包依赖的时prompt-toolkit2.0.0以上的版本,而ipython包依赖的是1.0.15的版本,估计是装Jupyter时,将版本更新了,所以运行的时候报错,把版本切成1.0.15即可。
解决方法:安装符合要求的版本。
我用的anaconda,输入命令pip3 install --upgrade prompt-toolkit==1.0.5
重启jupyter notebook就可以运行了,不会提示kernel starting,please wait了。

你可能感兴趣的:(Bug,ubuntu,anaconda,linux,python)