我正在尝试根据其directions安装Jupyter Plotly扩展,请参阅标题为:JupyterLab支持(Python 3.5+)。但是,列出的任何软件包的安装都会失败,并显示 ValueError ...不是有效的npm软件包。全面披露,这是我的第一个stackoverflow帖子。如果缺少信息,请告诉我。我是使用Python的工程师,而不是精通基础工具集的人。
系统
- Windows 10
- Python 3.7.5
- 节点12.13.0
- npm 6.9.0
我不知道这是否相关,但是我正在尝试通过python环境进行此安装。在尝试安装扩展程序之前我做了什么(请注意:不知道什么是最佳实践)。
- 为python环境文件夹创建的文件夹(> c:\ projects \ python \ environments )
- 在新文件夹中,创建了jupyterLab环境(> python -m venv jupyterLab )
- 启动的shell(> jupyterLab \ Scripts \ activate.bat )
- 已安装Jupyter Lab(> * pip安装Jupyter Lab)
- 已验证的Jupyter实验室打开并运行
接下来,我尝试安装ploty扩展名,因为图形未呈现。
命令行输入
jupyter labextension install @ jupyter-widgets / jupyterlab-manager @ 1.0 --no-build
结果
ValueError:“ @ jupyter-widgets/jupyterlab-manager@1.0”不是有效的npm软件包
无论我尝试从Plotly的方向安装哪个软件包或版本,我都会收到此错误。
尝试过的事情
- Python 3.8.0
- 已卸载并重新安装的nodejs和npm
- 将Juptyer Labs回滚至v 1.0.0
- 将NPM从6.7降低到6.13的各种版本
- 检查路径中的nodejs(在论坛中建议使用 )
- 检查C:\ Users {myUserId} \ AppData \ Roaming \ npm是否在路径中(在论坛中建议)
- 好极了...正在重启计算机
日志输出
Node v12.13.0
C:\Program Files\nodejs\npm.CMD" pack @jupyter-widgets/jupyterlab-manager@1.0npm notice
npm notice package: @jupyter-widgets/jupyterlab-manager@1.0.3
npm notice === Tarball Contents ===
npm notice 2.3kB package.json
npm notice 1.5kB LICENSE
npm notice 1.9kB README.md
npm notice 277B lib/index.d.ts
npm notice 380B lib/index.js
npm notice 5.4kB lib/manager.d.ts
npm notice 14.0kB lib/manager.js
npm notice 1.9kB lib/output.d.ts
npm notice 5.2kB lib/output.js
npm notice 830B lib/plugin.d.ts
npm notice 6.7kB lib/plugin.js
npm notice 956B lib/renderer.d.ts
npm notice 3.3kB lib/renderer.js
npm notice 216B lib/semvercache.d.ts
npm notice 862B lib/semvercache.js
npm notice 375B schema/plugin.json
npm notice === Tarball Details ===
npm notice name: @jupyter-widgets/jupyterlab-manager
npm notice version: 1.0.3
npm notice filename: jupyter-widgets-jupyterlab-manager-1.0.3.tgz
npm notice package size: 11.8 kB
npm notice unpacked size: 46.2 kB
npm notice shasum: 48f60ba3224327a7af21aef0edf9400202c3f34f
npm notice integrity: sha512-/VNnECOfq731D[...]wRYjB2nuNGpeg==
npm notice total files: 16
npm notice
jupyter-widgets-jupyterlab-manager-1.0.3.tgz
Traceback (most recent call last):
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\debuglog.py",line 47,in debug_logging
yield
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\labextensions.py",line 82,in start
ans = self.run_task()
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\labextensions.py",line 103,in run_task
for arg in self.extra_args
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\labextensions.py",in <listcomp>
for arg in self.extra_args
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\commands.py",line 316,in install_extension
return handler.install_extension(extension)
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\commands.py",line 517,in install_extension
info = self._install_extension(extension,tempdir)
File "c:\projects\python\environments\jupyterlabs\lib\site-packages\jupyterlab\commands.py",line 1373,in _install_extension
info = self._extract_package(extension,line 1444,in _extract_package
raise ValueError(msg % source)
ValueError: "@jupyter-widgets/jupyterlab-manager@1.0" is not a valid npm package
Exiting application: jupyter
任何帮助将不胜感激。谢谢!