无法安装ipywidgets jupyter实验室扩展

时间:2020-07-24 13:14:11

标签: ipywidgets

我在安装ipywidgets jupyter实验室扩展程序时遇到了麻烦。我尝试通过遵循this direction来做到这一点,并收到如下消息Building jupyterlab assets (build:prod:minimize)

$  conda install -c conda-forge nodejs

Collecting package metadata (current_repodata.json): done

Solving environment: done

# All requested packages already installed.
$ jupyter labextension install @jupyter-widgets/jupyterlab-manager
Building jupyterlab assets (build:prod:minimize)
$ 

此过程完成后,我收到一条错误消息ModuleNotFoundError: No module named 'ipywidgets',如下所示。

screen shot of a jupyter lab's window

我尝试用2种方法解决此问题。

  1. 我引用了this page作为参考,并键入了jupyter lab build --minimize=False。但是,我得到了与以前相同的错误消息:

    $ jupyter labextension安装@ jupyter-widgets / jupyterlab-manager 建立Jupyterlab资产(build:prod:minimize)

  2. 我引用了this page作为参考。但是,当我尝试$which nodejs时,终端显示上没有任何响应。

如何解决此问题并安装ipywidgets?

以下是关于我的机器的信息。

$ which node
/Users/myname/opt/miniconda3/envs/ptfl/bin/node
$ node -v 
v14.5.0
$ which nodejs
$ ls /usr/local/bin/node 
/usr/local/bin/node
$ which npm
/Users/myname/opt/miniconda3/envs/ptfl/bin/npm
$ npm -v 
6.14.5

关于操作系统:MacOS Catalina 10.15.4版

关于miniconda:miniconda3

=============================

更新信息

7/25:

  1. 我将操作系统从v10.15.14更新到了v10.15.5。

  2. 更新操作系统后,我尝试将ipywidgets作为以下对象安装。

=

$ conda install -c conda-forge nodejs
 Collecting package metadata (current_repodata.json): done
 Solving environment: done

## Package Plan ##

  environment location: /Users/myname/opt/miniconda3/envs/ptfl

  added / updated specs:
    - nodejs


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    nodejs-14.6.0              |       hdde0ff8_0        12.7 MB  conda-forge
    ------------------------------------------------------------
                                           Total:        12.7 MB

The following packages will be UPDATED:

  nodejs                                  14.5.0-h2c41780_0 --> 14.6.0-hdde0ff8_0


Proceed ([y]/n)? y


Downloading and Extracting Packages
nodejs-14.6.0        | 12.7 MB   | ##################################### | 100% 
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
$ jupyter labextension install @jupyter-widgets/jupyterlab-manager
Building jupyterlab assets (build:prod:minimize)

0 个答案:

没有答案