【发布时间】:2017-12-28 18:50:21
【问题描述】:
我使用的是 MacOS,我只是按照此处列出的安装说明进行操作: http://jupyter.org/install.html
这条命令满足:
$ python3 -m pip install --upgrade pip
Requirement already up-to-date: pip in /opt/local/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages
并且jupyter 已安装:
$ python3 -m pip install jupyter
Requirement already satisfied: jupyter in /opt/local/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-packages
但是,jupyter 命令似乎都不起作用:
$ jupyter
-bash: jupyter: command not found
$ jupyter notebook
-bash: jupyter: command not found
鉴于上述路径,有没有办法运行jupyter notebook?必须安装它。
【问题讨论】:
-
你总是可以运行
python3 -m jupyter或python3 -m jupyter notebook。 -
@Evert 对于后一个命令,我得到
Error executing Jupyter command 'notebook': [Errno 2] No such file or directory -
我无法重现该错误。
python3 -m jupyter --help有效吗?另请参阅 this question 并出现相同的错误,这可能表明您的安装不正确(这也可以解释为什么jupyter尚未安装或符号链接到/opt/local/bin)。 -
@Evert 我们可能正在取得进展。我从您上面粘贴的链接中尝试了这个命令:
python3 -m pip install --upgrade --force-reinstall --no-cache-dir jupyter。命令python3 -m jupyter --help现在可以工作了,但是python3 -m jupyter notebook仍然给出了上面相同的错误,即Error executing Jupyter command 'notebook': [Errno 2] No such file or directory -
1) 是完整的错误,还是有更多的回溯? 2) 帮助选项是否表明
notebook是有效的(子)命令?您是否也尝试过console子命令,只是想看看是否会导致同样的错误?
标签: python python-3.x jupyter-notebook jupyter