由jupter notebook:Error executing Jupyter command ‘notebook‘: [Errno ‘jupyter-notebook‘ not found]的思考

昨晚还用得好好的,今天早上一打开,提示有错误


D:\AI>jupyter notebook
Error executing Jupyter command 'notebook': [Errno 'jupyter-notebook' not found] 2

上网查找解决方法

更新

D:\AI>pip3 install --upgrade jupyter

无错,更新后输入jupyter notebook,还是出现同样的问题

换一更新方式

D:\AI>pip3 install --upgrade --force-reinstall --no-cache-dir jupyter

如果是python2版本,将pip3换成pip

问题解决

参考:https://stackoverflow.com/questions/49925555/jupyter-notebook-command-returns-error-executing-jupyter-command-notebook-er

出现了新问题:

打开jupyterNotebook时500 : Internal Server Error

参考: https://stackoverflow.com/questions/55185563/jupyter-notebook-500-internal-server-error

和 https://github.com/conda-forge/nbconvert-feedstock/issues/27

安装nbconvert5.4.1及以后的版本即可。本文选择更新nbconvert到指定版本5.6.0后,问题解决了

D:\AI>pip3 install --upgrade --user nbconvert==5.6.0

再次出现问题

打开jupyterNotebook时,内核连接不成功

原因:

ModuleNotFoundError: No module named 'contextvars'

During handling of the above exception, another exception occurred:
...
...
...
ImportError: cannot import name 'AsyncGenerator'

原因是prompt_toolkit这依赖的版本不匹配(我这使用的python 3.6)

解决办法是,安装contextvars后,再降低版本prompt_toolkit的版本
pip3 install --upgrade prompt-toolkit==2.0.10

终于全部解决

思考:

1.一定要看引起错误的原因,再针对下药

2.多看模板的文档说明

3.多学习

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值