找不到Jupyter命令`jupyter-lab` [英] Jupyter command `jupyter-lab` not found

查看:1491
本文介绍了找不到Jupyter命令`jupyter-lab`的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试在我的Kubuntu机器上安装jupyter lab. 如果我使用"pip3 install jupyter jupyterlab"安装jupyter lab,则"jupyter notebook"命令完全可以正常工作.但是,如果我每次收到消息时都尝试运行"jupyter实验室":

I have tried to install jupyter lab on my Kubuntu machine. If I install jupyter lab with 'pip3 install jupyter jupyterlab' the command 'jupyter notebook' works completly fine. But if I try to run 'jupyter lab' every time I get the message:

Traceback (most recent call last):
  File "/usr/local/bin/jupyter", line 11, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.6/dist-packages/jupyter_core/command.py", line 230, in main
    command = _jupyter_abspath(subcommand)
  File "/usr/local/lib/python3.6/dist-packages/jupyter_core/command.py", line 133, in _jupyter_abspath
    'Jupyter command `{}` not found.'.format(jupyter_subcommand)
Exception: Jupyter command `jupyter-lab` not found.

怎么了?

我尝试多次重新安装jupyter和jupyterlab,并且存在相同的问题.

I tried to reinstall jupyter and jupyterlab multiple times with the same issue.

推荐答案

它是空格.它总是空间.绝对不要在软件包名称中使用空格.它始终是namepart1-namepart2或namepart1namepart2.这是因为参数由空格分隔.因此,如果在两者之间放置空格,则会使pip认为您要安装名为jupyterlab的两个不同的软件包.只需使用:

Its the space. Its always the space. Never ever use spaces within package name. Its always either namepart1-namepart2 or namepart1namepart2. This is because arguments are separated by space. So if you put space in between, it makes pip think that you want to install two different packages named jupyter and lab. Just use:

python -m pip install jupyterlab

或者简单地:

pip install jupyterlab

无需卸载或重新安装任何东西.但是,要运行jupyter实验室服务器,您可能需要添加空格,如下所示:

No need to uninstall or reinstall anything. However to run jupyter lab server you might want to add spaces as follows:

jupyter lab

这篇关于找不到Jupyter命令`jupyter-lab`的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆