jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘

看很多安装教程都说安装jupyter需要anaconda,其实安装jupyter不一定要anaconda,它只是需要python3的环境,我自身电脑就只装了pychram。

首先介绍我的安装过程,然后介绍安装过程中的错误解决

安装步骤:

打开cmd,然后pip3 install juputer

这里我选择的安装路径是 C:\Python37\Scripts下,路径可以自己定义

jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘_第1张图片

接下来就是测试jupyter是否安装成功

执行 jupyter notebook

报错cannot import name 'secure_write' from 'jupyter_core.paths',即无法从jupyter_core.paths导入secure_write文件

jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘_第2张图片 

解决方法 pip3更新jupyter_core模块,从而使jupyter_core的paths文件完成自我修改

执行 pip3 install --upgrade jupyter_core jupyter_client

jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘_第3张图片

 再次运行jupyter notabook

jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘_第4张图片

jupyter notebook的安装及出现的错误:ImportError: cannot import name ‘secure_write‘ from ‘jupyter_core.paths‘_第5张图片

可见运行成功

最后就是jupyter notebook的配置了,不再做过多描述,见https://www.cnblogs.com/zlslch/p/6984403.html

你可能感兴趣的:(python,python)