$apm --version gives following output
apm 1.12.9
npm 3.10.5
node 4.4.5
python 2.7.9
git 2.6.2
$node -v gives
v6.6.0
I have seen similar open issues in apm repo atom/apm#328 and atom/apm#531, but creating new issue because error diff
and the error message spit out by Atom with $sudo apm install Hydrogen (I'm aware that sudo isn't necessary, just precautionary) can be seen below:
> [email protected] install /private/tmp/apm-install-dir-1161030-31251-118tbxi/node_modules/Hydrogen/node_modules/zeromq
> prebuild --install --preinstall "npm run build:libzmq"
/private/tmp/apm-install-dir-1161030-31251-118tbxi
└── (empty)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
(node) warning: possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
at TLSSocket.addListener (events.js:239:17)
at TLSSocket.Readable.on (_stream_readable.js:673:33)
at Request.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm-registry-client/lib/request.js:153:7)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at ClientRequest.<anonymous> (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/request/request.js:823:10)
at emitOne (events.js:82:20)
at ClientRequest.emit (events.js:169:7)
at tickOnSocket (_http_client.js:502:7)
at onSocketNT (_http_client.js:514:5)
shell-init: error retrieving current directory: getcwd: cannot access parent directories: Permission denied
sh: prebuild: command not found
npm WARN enoent ENOENT: no such file or directory, open '/private/tmp/apm-install-dir-1161030-31251-118tbxi/package.json'
npm WARN apm-install-dir-1161030-31251-118tbxi No description
npm WARN apm-install-dir-1161030-31251-118tbxi No repository field.
npm WARN apm-install-dir-1161030-31251-118tbxi No README data
npm WARN apm-install-dir-1161030-31251-118tbxi No license field.
npm ERR! Darwin 15.6.0
npm ERR! argv "/Applications/Atom.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/Users/mupadhye/.atom/.apm/.apmrc" "--userconfig" "/Users/mupadhye/.atom/.apmrc" "install" "/private/tmp/d-1161030-31251-17wkst4/package.tgz" "--runtime=electron" "--target=1.3.6" "--arch=x64" "--global-style"
npm ERR! node v4.4.5
npm ERR! npm v3.10.5
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] install: `prebuild --install --preinstall "npm run build:libzmq"`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] install script 'prebuild --install --preinstall "npm run build:libzmq"'.
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 zeromq package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! prebuild --install --preinstall "npm run build:libzmq"
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs zeromq
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls zeromq
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /private/tmp/apm-install-dir-1161030-31251-118tbxi/npm-debug.log
npm ERR! code 1
|$sudo apm install Hydrogen| (I'm aware that sudo isn't necessary, just precautionary)
The use of sudo has been reported to break the installation (this is the result I'd expect of installing Atom packages in the user's folder with root's ownership).
That was it, it installed successfully when ran without sudo!
unfortunately, I guess which would be a separate concern, executing Hydrogen Run from within atom hangs and crashes editor.
I was having a similar issue. When i try to run the installation without sudo i get this:
/usr/share/atom/resources/app/apm/node_modules/fs-plus/node_modules/mkdirp/index.js:74
throw err0;
^
Error: EACCES, permission denied '/opt/virtual_env'
at Object.fs.mkdirSync (fs.js:654:18)
at sync (/usr/share/atom/resources/app/apm/node_modules/fs-plus/node_modules/mkdirp/index.js:55:12)
at Function.sync (/usr/share/atom/resources/app/apm/node_modules/fs-plus/node_modules/mkdirp/index.js:61:24)
at Object.fsPlus.makeTreeSync (/usr/share/atom/resources/app/apm/node_modules/fs-plus/lib/fs-plus.js:343:23)
at Install.module.exports.Install.createAtomDirectories (/usr/share/atom/resources/app/apm/lib/install.js:544:10)
at Install.module.exports.Install.run (/usr/share/atom/resources/app/apm/lib/install.js:829:12)
at Object.module.exports.run (/usr/share/atom/resources/app/apm/lib/apm-cli.js:226:32)
at Object.<anonymous> (/usr/share/atom/resources/app/apm/lib/cli.js:8:7)
at Object.<anonymous> (/usr/share/atom/resources/app/apm/lib/cli.js:19:4)
at Module._compile (module.js:456:26)
@pedrecal This looks more like a issue from apm and not from Hydrogen.
Does the error also appear while installing other packages?
Yeah! I just noticed that now! Sorry for taking your time. I'll try to find out what's happening.
When i try to install directly from atom, i get this:
> [email protected] install /tmp/apm-install-dir-11719-3659-ipbek9/node_modules/Hydrogen/node_modules/jmp/node_modules/zeromq
> prebuild-install || (npm run build:libzmq && node-gyp rebuild)
npm WARN engine [email protected]: wanted: {"node":">= 0.12.0"} (current: {"node":"0.10.40","npm":"2.13.3"})
npm WARN engine [email protected]: wanted: {"node":">=0.12.0","iojs":">=1.0.0"} (current: {"node":"0.10.40","npm":"2.13.3"})
prebuild-install info begin Prebuild-install version 2.1.0
prebuild-install info looking for local prebuild @ prebuilds/zeromq-v4.1.1-node-v1-linux-x64.tar.gz
prebuild-install info looking for cached prebuild @ /home/pedrecal/.atom/.node-gyp/.npm/_prebuilds/https-github.com-zeromq-zeromq.js-releases-download-v4.1.1-zeromq-v4.1.1-node-v1-linux-x64.tar.gz
prebuild-install http request GET https://github.com/zeromq/zeromq.js/releases/download/v4.1.1/zeromq-v4.1.1-node-v1-linux-x64.tar.gz
prebuild-install http 404 https://github.com/zeromq/zeromq.js/releases/download/v4.1.1/zeromq-v4.1.1-node-v1-linux-x64.tar.gz
prebuild-install WARN install No prebuilt binaries found (target=0.36.8 runtime=node arch=x64 platform=linux)
sh: 1: npm: not found
npm ERR! Linux 3.16.0-4-amd64
npm ERR! argv "/usr/share/atom/resources/app/apm/bin/node" "/usr/share/atom/resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/home/pedrecal/.atom/.apm/.apmrc" "--userconfig" "/home/pedrecal/.atom/.apmrc" "install" "/tmp/d-11719-3659-1v7dh1z/package.tgz" "--target=0.36.8" "--arch=x64"
npm ERR! node v0.10.40
npm ERR! npm v2.13.3
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] install: `prebuild-install || (npm run build:libzmq && node-gyp rebuild)`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] install script 'prebuild-install || (npm run build:libzmq && node-gyp rebuild)'.
npm ERR! This is most likely a problem with the zeromq package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! prebuild-install || (npm run build:libzmq && node-gyp rebuild)
npm ERR! You can get their info via:
npm ERR! npm owner ls zeromq
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-11719-3659-ipbek9/npm-debug.log
This only happens with hydrogen.
@pedrecal It looks like you're using a very old version of Atom. Could you try upgrading it?
It worked! Thank you so much!
Most helpful comment
The use of
sudohas been reported to break the installation (this is the result I'd expect of installing Atom packages in the user's folder withroot's ownership).