【问题标题】:Install Jupyter Notebook in Atom Error: Installing “jupyter-notebook@0.0.10” failed在 Atom 中安装 Jupyter Notebook 错误:安装“jupyter-notebook@0.0.10”失败
【发布时间】:2018-02-10 22:42:38
【问题描述】:

jupyter notebook 可作为 atom 内的一个包使用。 下面是包裹截图:

不幸的是,当我按下安装按钮时,我收到如下所示的错误消息:

安装“jupyter-notebook@0.0.10”失败

当我按下 Show output… 时,错误详情如下所示:

bufferutil@1.2.1 install /tmp/apm-install-dir-118110-11290-1g90s6g.50fjqq6w29/node_modules/jupyter-notebook/node_modules/bufferutil 节点gyp重建

runas@3.1.1 安装 /tmp/apm-install-dir-118110-11290-1g90s6g.50fjqq6w29/node_modules/jupyter-notebook/node_modules/runas node-gyp 重建 /tmp/apm-install-dir-118110-11290-1g90s6g.50fjqq6w29 └──(空)

请在下面查看此问题的详细信息:

Installing “jupyter-notebook@0.0.10” failed.Hide output…
> bufferutil@1.2.1 install /tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/node_modules/jupyter-notebook/node_modules/bufferutil
> node-gyp rebuild


> runas@3.1.1 install /tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/node_modules/jupyter-notebook/node_modules/runas
> node-gyp rebuild

/tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr
└── (empty)


npm WARN deprecated jupyter-js-services@0.21.1: This package has moved to @jupyterlab/services
npm WARN deprecated phosphor@0.5.0: use @phosphor/ packages
gyp ERR! configure error 
gyp ERR! stack Error: Python executable "/snap/atom/116/usr/share/atom/resources/app/apm/bin/python-interceptor.sh" is v3.6.3, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack     at failPythonVersion (/snap/atom/116/usr/share/atom/resources/app/apm/node_modules/node-gyp/lib/configure.js:454:14)
gyp ERR! stack     at /snap/atom/116/usr/share/atom/resources/app/apm/node_modules/node-gyp/lib/configure.js:443:9
gyp ERR! stack     at ChildProcess.exithandler (child_process.js:197:7)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at maybeClose (internal/child_process.js:877:16)
gyp ERR! stack     at Socket.<anonymous> (internal/child_process.js:334:11)
gyp ERR! stack     at emitOne (events.js:96:13)
gyp ERR! stack     at Socket.emit (events.js:188:7)
gyp ERR! stack     at Pipe._handle.close [as _onclose] (net.js:498:12)
gyp ERR! System Linux 4.13.0-32-generic
gyp ERR! command "/snap/atom/116/usr/share/atom/resources/app/apm/bin/node" "/snap/atom/116/usr/share/atom/resources/app/apm/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/node_modules/jupyter-notebook/node_modules/bufferutil
gyp ERR! node -v v6.9.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok 
gyp ERR! configure error 
gyp ERR! stack Error: Python executable "/snap/atom/116/usr/share/atom/resources/app/apm/bin/python-interceptor.sh" is v3.6.3, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack     at failPythonVersion (/snap/atom/116/usr/share/atom/resources/app/apm/node_modules/node-gyp/lib/configure.js:454:14)
gyp ERR! stack     at /snap/atom/116/usr/share/atom/resources/app/apm/node_modules/node-gyp/lib/configure.js:443:9
gyp ERR! stack     at ChildProcess.exithandler (child_process.js:197:7)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at maybeClose (internal/child_process.js:877:16)
gyp ERR! stack     at Socket.<anonymous> (internal/child_process.js:334:11)
gyp ERR! stack     at emitOne (events.js:96:13)
gyp ERR! stack     at Socket.emit (events.js:188:7)
gyp ERR! stack     at Pipe._handle.close [as _onclose] (net.js:498:12)
gyp ERR! System Linux 4.13.0-32-generic
gyp ERR! command "/snap/atom/116/usr/share/atom/resources/app/apm/bin/node" "/snap/atom/116/usr/share/atom/resources/app/apm/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/node_modules/jupyter-notebook/node_modules/runas
gyp ERR! node -v v6.9.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok 
npm WARN enoent ENOENT: no such file or directory, open '/tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/package.json'
npm WARN apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr No description
npm WARN apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr No repository field.
npm WARN apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr No README data
npm WARN apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: bufferutil@1.2.1 (node_modules/jupyter-notebook/node_modules/bufferutil):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: bufferutil@1.2.1 install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
npm ERR! Linux 4.13.0-32-generic
npm ERR! argv "/snap/atom/116/usr/share/atom/resources/app/apm/bin/node" "/snap/atom/116/usr/share/atom/resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/home/User_name/.atom/.apm/.apmrc" "--userconfig" "/home/User_name/.atom/.apmrc" "install" "/tmp/d-118110-11148-wokfwx.il28dxi529/package.tgz" "--runtime=electron" "--target=1.6.15" "--arch=x64" "--global-style"
npm ERR! node v6.9.5
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE

npm ERR! runas@3.1.1 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the runas@3.1.1 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the runas package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs runas
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls runas
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /tmp/apm-install-dir-118110-11148-k6dnh7.k94kzhyqfr/npm-debug.log
npm ERR! code 1

我的操作系统: Ubuntu 16.04 LTS

Atom 版本:1.23.3

请问这个问题怎么解决?

【问题讨论】:

  • 您需要提问...请使用问题下方的edit 链接添加更多信息。
  • 完成!太感谢了!如果有人能解决这个问题,我将不胜感激。

标签: python jupyter-notebook jupyter atom-editor


【解决方案1】:

我刚刚在atom中安装“jupyter-notebook”时遇到了同样的问题,错误信息很清楚:

Error: Python executable "/snap/atom/116/usr/share/atom/resources/app/apm/bin/python-interceptor.sh" is v3.6.3, which is not supported by gyp

这基本上意味着 jupyter-notebook 对 atom 的依赖项之一是期待另一个 python 版本,即 « Python &gt;= v2.5.0 &amp; &lt; 3.0.0 »。

但是,看着the package page,支持python3 似乎是可能的,所以我按照说明进行了尝试:

  1. 首先安装依赖项:pip3 install jupyter jupyter_kernel_gateway,然后尝试apm install -->同样的错误。

  2. 第二次从他们的 git repo 获取源代码,然后 apm install; apm link 没有返回错误。但是,该软件包似乎未安装在 atom 中。

所以,因为我想使用python3(即使我以后会尝试支持python2.7),基本上我无法安装这个原子包:-/

【讨论】:

    猜你喜欢
    • 2023-03-11
    • 1970-01-01
    • 2020-07-17
    • 2020-01-24
    • 2018-05-16
    • 1970-01-01
    • 1970-01-01
    • 2018-07-20
    • 2021-04-20
    相关资源
    最近更新 更多