I tried to install some packages for my BrowserQuest Server.
I used: npm install -d
Node Version v0.10.21
NPM Version v 1.3.11
OS Debian 7.0 Wheezy
Errors:
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:719:10)
npm ERR! at next (/usr/local/lib/node_modules/npm/lib/cache.js:698:17)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:675:5
npm ERR! at saved (/usr/local/lib/node_modules/npm/node_modules/npm-registry-
client/lib/get.js:142:7)
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.2.41-042stab081.5
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-d"
npm ERR! cwd /root/BrowserQuest
npm ERR! node -v v0.10.21
npm ERR! npm -v 1.3.11
npm http 304 https://registry.npmjs.org/redis
npm http 304 registry.npmjs org/connect
npm http 304 registry.npmjs org/underscore
npm http 304 registry.npmjs org/bison
npm http 304 registry.npmjs org/websocket-server
npm http 304 registry.npmjs org/sanitizer
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /root/BrowserQuest/npm-debug.log
npm ERR! not ok code 0>
Please help me!
I had a similar problem on ubuntu 12.10, and it was SSL related. Until i had figured it out, disabling https could solve things for a moment:
npm set registry http://registry.npmjs.org/
Related
While installing the module webdriverio using npm, I am getting the following error:
sudo npm install webdriverio
[sudo] password for username:
npm WARN package.json indexof#0.0.1 No repository field.
npm http GET https://registry.npmjs.org/webdriverio
npm http 304 https://registry.npmjs.org/webdriverio
npm WARN engine webdriverio#5.4.9: wanted: {"node":">= 4.8.5"} (current: {"node":"v0.10.15","npm":"1.3.5"})
npm http GET https://registry.npmjs.org/grapheme-splitter
npm http GET https://registry.npmjs.org/css-value
npm http GET https://registry.npmjs.org/lodash.merge
npm http GET https://registry.npmjs.org/lodash.zip
npm http GET https://registry.npmjs.org/rgb2hex
npm http GET https://registry.npmjs.org/serialize-error
npm http GET https://registry.npmjs.org/webdriver
npm http GET https://registry.npmjs.org/wdio/logger
npm http GET https://registry.npmjs.org/wdio/config
npm http GET https://registry.npmjs.org/wdio/repl
npm http 304 https://registry.npmjs.org/css-value
npm ERR! Error: No compatible version found: css-value#'^0.0.1'
npm ERR! Valid install targets:
npm ERR! ["0.0.1"]
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:719:10)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:638:10
npm ERR! at saved (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/get.js:142:7)
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 4.15.0-43-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "webdriverio"
npm ERR! cwd /home/username/research
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.3.5
npm http 304 https://registry.npmjs.org/lodash.merge
npm http 304 https://registry.npmjs.org/serialize-error
npm http 304 https://registry.npmjs.org/lodash.zip
npm http 304 https://registry.npmjs.org/grapheme-splitter
npm http 304 https://registry.npmjs.org/webdriver
npm http 304 https://registry.npmjs.org/rgb2hex
npm http 405 https://registry.npmjs.org/wdio/repl
npm ERR! TypeError: Object.keys called on non-object
npm ERR! at Function.keys (native)
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:708:24)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:638:10
npm ERR! at saved (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/get.js:142:7)
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 4.15.0-43-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "webdriverio"
npm ERR! cwd /home/username/research
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.3.5
npm ERR! type called_on_non_object
npm http 405 https://registry.npmjs.org/wdio/logger
npm ERR! TypeError: Object.keys called on non-object
npm ERR! at Function.keys (native)
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:708:24)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:638:10
npm ERR! at saved (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/get.js:142:7)
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 4.15.0-43-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "webdriverio"
npm ERR! cwd /home/username/research
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.3.5
npm ERR! type called_on_non_object
npm http 405 https://registry.npmjs.org/wdio/config
npm ERR! TypeError: Object.keys called on non-object
npm ERR! at Function.keys (native)
npm ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:708:24)
npm ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:638:10
npm ERR! at saved (/usr/local/lib/node_modules/npm/node_modules/npm-registry-client/lib/get.js:142:7)
npm ERR! at /usr/local/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 4.15.0-43-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "webdriverio"
npm ERR! cwd /home/username/research
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.3.5
npm ERR! type called_on_non_object
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/username/research/npm-debug.log
npm ERR! not ok code 0
Could someone please help with this? I do not understand why this is happening since when I do npm info loadash.merge, the module version is clearly present. I have also tried to see what my $NODE_PATH contains (as some answers on stackoverflow suggest), and it seems to be pointing towards the correct path of node, or at least the path where nvm installed node:
/home/username/.nvm/versions/node/v10.15.1/bin/node
Additionally, I am not sure about this particular warning:
npm WARN engine webdriverio#5.4.9: wanted: {"node":">= 4.8.5"} (current: {"node":"v0.10.15","npm":"1.3.5"}) My node version is 10.15.1 and not 0.10.15
I think you're missing the css-value library based on this part of the stack trace:
npm ERR! Error: No compatible version found: css-value#'^0.0.1'
Try to resolve this by doing: npm i css-value
Additionally, your stack trace is complaining about using an outdated version of Node. I would consider updating node since your version is very old:
npm WARN engine webdriverio#5.4.9: wanted: {"node":">= 4.8.5"} (current: {"node":"v0.10.15","npm":"1.3.5"})
Your issue is probably with using sudo in the npm install. You can check this out by using sudo node -v and it will probably give you a different node version than your nvm installed one, this would indicate that node in your server is broken in some places due some previous installation. To circumvent it I suggest the following that has worked for me for similar issues.
sudo su
nvm alias default 10.15.1
npm cache clean --force
npm install webdriverio
If it still gives syntax errors due to dependencies, use
npm install webdriverio --unsafe-perm
I've tried to install this wordpress template, which relies on some node modules for a gulp file, on a Windows PC.
The output of npm install is the following:
$ npm install
npm WARN package.json gulp-wordpress-template#0.0.1 No repository field.
npm http GET https://registry.npmjs.org/gulp-load-plugins
npm http GET https://registry.npmjs.org/gulp-autoprefixer
npm http GET https://registry.npmjs.org/gulp
npm http GET https://registry.npmjs.org/browser-sync
npm http 304 https://registry.npmjs.org/gulp-autoprefixer
npm ERR! Error: No compatible version found: gulp-autoprefixer#'^1.0.1'
npm ERR! Valid install targets:
npm ERR! ["0.0.1","0.0.2","0.0.3","0.0.4","0.0.5","0.0.6","0.0.7","0.0.8","0.0.9
","0.0.10","1.0.0","1.0.1","2.0.0","2.1.0"]
npm ERR! at installTargetsError (c:\Program Files\nodejs\node_modules\npm\li
b\cache.js:719:10)
npm ERR! at c:\Program Files\nodejs\node_modules\npm\lib\cache.js:638:10
npm ERR! at saved (c:\Program Files\nodejs\node_modules\npm\node_modules\npm
-registry-client\lib\get.js:142:7)
npm ERR! at c:\Program Files\nodejs\node_modules\npm\node_modules\graceful-f
s\polyfills.js:133:7
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files\\nodej
s\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! cwd c:\Users\USER\Desktop\wordpress-test
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.3.5
npm http 304 https://registry.npmjs.org/gulp-load-plugins
npm http 304 https://registry.npmjs.org/gulp
npm http GET https://registry.npmjs.org/gulp-connect-php
npm http GET https://registry.npmjs.org/gulp-shell
npm http GET https://registry.npmjs.org/gulp-sass
npm http 304 https://registry.npmjs.org/browser-sync
npm http 304 https://registry.npmjs.org/gulp-sass
npm http 304 https://registry.npmjs.org/gulp-connect-php
npm http 304 https://registry.npmjs.org/gulp-shell
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! c:\Users\USER\Desktop\wordpress-test\npm-debug.log
npm ERR! not ok code 0
According to the error, gulp-autoprefixer isn't available in version ^1.0.1. What is strange, is that below it suggests that 1.0.1 is a valid version.
What's even more strange, is that I can flawlessly install the package on an OSX machine.
I thought node is cross platform – is there something I am missing?
You need a newer version of npm that supports the ^ character in the version fields. The easiest way is to this is to just upgrade node (the latest stable being v0.10.35 as of this writing).
I am trying to install ari-client,using this command:
sudo npm install ari-client
Here is the error I get:
npm http GET http://registry.npmjs.org/ari-client
npm http 304 http://registry.npmjs.org/ari-client
npm http GET http://registry.npmjs.org/swagger-client/2.0.26
npm http GET http://registry.npmjs.org/ws/0.4.31
npm http GET http://registry.npmjs.org/underscore/1.6.0
npm http GET https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.1.tgz
npm http 400 https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.1.tgz
npm ERR! fetch failed https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.1.tgz
npm ERR! Error: 400 Bad Request
npm ERR! at WriteStream.<anonymous> (/usr/share/npm/lib/utils/fetch.js:57:12)
npm ERR! at WriteStream.EventEmitter.emit (events.js:117:20)
npm ERR! at fs.js:1601:14
npm ERR! at /usr/lib/nodejs/graceful-fs/graceful-fs.js:103:5
npm ERR! at Object.oncomplete (fs.js:107:15)
npm ERR! If you need help, you may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/bzegeju/npm-debug.log npm
npm ERR! System Linux 3.11.0-26-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "ari-client"
npm ERR! cwd /home/bzegeju
npm ERR! node -v v0.10.15
npm ERR! npm -v 1.2.18
npm http 304 http://registry.npmjs.org/ws/0.4.31
npm http 304 http://registry.npmjs.org/underscore/1.6.0
npm http 304 http://registry.npmjs.org/swagger-client/2.0.26
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/bzegeju/npm-debug.log
npm ERR! not ok code 0
Any help on the error or how I can manually install the library?
For Manual installation:
1.Go to npm site search for "ari-client".
2.Click the given "github" link , from there you can download as ZIP file.
3.Extract it and use in your project
I am following the testatcular vide tutorial http://vojtajina.github.com/testacular/.
I installed nodejs and when I tried to install testacular with
sudo npm install -g testacular
I get this error :
npm http GET https://registry.npmjs.org/testacular
npm http 304 https://registry.npmjs.org/testacular
npm http GET https://registry.npmjs.org/chokidar
npm http GET https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/socket.io
npm http GET https://registry.npmjs.org/glob
npm http GET https://registry.npmjs.org/optimist
npm http 304 https://registry.npmjs.org/glob
npm http 304 https://registry.npmjs.org/socket.io
npm http 304 https://registry.npmjs.org/optimist
npm http 304 https://registry.npmjs.org/chokidar
npm http 304 https://registry.npmjs.org/minimatch
> chokidar#0.4.0 postinstall /usr/local/lib/node_modules/testacular/node_modules/chokidar
> node setup.js postinstall
npm ERR! error installing chokidar#0.4.0
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
npm WARN /usr/share/doc/nodejs/README.Debian
npm WARN
npm ERR! error installing testacular#0.0.17
npm ERR! Error: ENOENT, lstat '/usr/local/lib/node_modules/testacular/node_modules/___minimatch.npm/package/minimatch.js'
npm ERR! You may report this log at:
npm ERR! <http://bugs.debian.org/npm>
npm ERR! or use
npm ERR! reportbug --attach /home/adio/workspace/java/tutorial/angularJS/npm-debug.log npm
npm ERR!
npm ERR! System Linux 3.5.0-17-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "testacular"
npm ERR! cwd /home/adio/workspace/java/tutorial/angularJS
npm ERR! node -v v0.6.19
npm ERR! npm -v 1.1.4
npm ERR! path /usr/local/lib/node_modules/testacular/node_modules/___minimatch.npm/package/minimatch.js
npm ERR! fstream_path /usr/local/lib/node_modules/testacular/node_modules/___minimatch.npm/package/minimatch.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! message ENOENT, lstat '/usr/local/lib/node_modules/testacular/node_modules/___minimatch.npm/package/minimatch.js'
npm ERR! errno {}
npm ERR! fstream_stack Object.oncomplete (/usr/lib/nodejs/fstream/lib/writer.js:204:26)
npm ERR! error rolling back testacular#0.0.17 Error: ENOTEMPTY, rmdir '/usr/local/lib/node_modules/testacular/node_modules/___glob.npm/package/test'
npm ERR! chokidar#0.4.0 postinstall: `node setup.js postinstall`
npm ERR! `sh "-c" "node setup.js postinstall"` failed with 1
npm ERR!
npm ERR! Failed at the chokidar#0.4.0 postinstall script.
npm ERR! This is most likely a problem with the chokidar package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node setup.js postinstall
npm ERR! You can get their info via:
npm ERR! npm owner ls chokidar
npm ERR! There is likely additional logging output above.
npm ERR!
npm ERR! System Linux 3.5.0-17-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "testacular"
npm ERR! cwd /home/adio/workspace/java/tutorial/angularJS
npm ERR! node -v v0.6.19
npm ERR! npm -v 1.1.4
npm ERR! code ELIFECYCLE
npm ERR! message chokidar#0.4.0 postinstall: `node setup.js postinstall`
npm ERR! message `sh "-c" "node setup.js postinstall"` failed with 1
npm ERR! errno {}
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/adio/workspace/java/tutorial/angularJS/npm-debug.log
npm not ok
anybody ran into this problem ?
thanks in advance for help.
Let me guess, is it happening on a Win7 machine 64 bits?
I got the same error and it was already reported on testacular github
The only workaround I found was installing node.js 32 bits instead of 64 bits version.
I encourage you to post another comment on their github so maybe it will be reconsidered
The problem was in the versions as the error log suggests. On Ubuntu 12.10 install NodeJS with sudo apt-get install nodejs will result in installing nodejs 0.6, but you need nodejs version 0.8 to install testacular so I followed this tutorial to install nodejs 0.8
http://davidtsadler.com/archives/2012/05/06/installing-node-js-on-ubuntu/
I searched for a long time, but haven't found the right answer yet.
I'm not the only one who has/had problems installing Socket.IO >0.7.7 but other solutions didn't work for me.
A possible problem could be an old version of GNU tar (version is 1.19) but I don´t know how to upgrade it or if it is possible at all.
An Update to a newer version of Ubuntu is not possible for me at this time.
If there is no way to update tar or something similar: Can I install Socket.IO without npm?
Here is the Output of "npm install socket.io":
npm http GET https://registry.npmjs.org/socket.io
npm http 304 https://registry.npmjs.org/socket.io
npm http GET https://registry.npmjs.org/socket.io-client/0.8.7
npm http GET https://registry.npmjs.org/policyfile/0.0.4
npm http GET https://registry.npmjs.org/redis/0.6.7
npm http 304 https://registry.npmjs.org/policyfile/0.0.4
npm http 304 https://registry.npmjs.org/socket.io-client/0.8.7
npm http 304 https://registry.npmjs.org/redis/0.6.7
npm http GET https://registry.npmjs.org/uglify-js/1.0.6
npm http GET https://registry.npmjs.org/websocket-client/1.0.0
npm http GET https://registry.npmjs.org/xmlhttprequest/1.2.2
npm http 304 https://registry.npmjs.org/uglify-js/1.0.6
npm http 304 https://registry.npmjs.org/xmlhttprequest/1.2.2
npm http 304 https://registry.npmjs.org/websocket-client/1.0.0
npm ERR! error installing websocket-client#1.0.0
npm ERR! error installing socket.io-client#0.8.7
npm ERR! Error: ENOENT, no such file or directory '/home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/___xmlhttprequest.npm/package/package.json'
npm ERR! You may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR!
npm ERR! System Linux 2.6.32.2-xxxx-grs-ipv6-32
npm ERR! command "node" "/home/admin/local/bin/npm" "install" "socket.io"
npm ERR! cwd /home/admin
npm ERR! node -v v0.6.10
npm ERR! npm -v 1.1.1
npm ERR! path /home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/___xmlhttprequest.npm/package/package.json
npm ERR! fstream_path /home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/___xmlhttprequest.npm/package/package.json
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! message ENOENT, no such file or directory '/home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/___xmlhttprequest.npm/package/package.json'
npm ERR! errno {}
npm ERR! fstream_stack Object.oncomplete (/home/admin/local/lib/node_modules/npm/node_modules/fstream/lib/writer.js:204:26)
npm ERR! error rolling back socket.io-client#0.8.7 Error: UNKNOWN, unknown error '/home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/___uglify-js.npm/package'
npm ERR! error installing socket.io#0.8.7
npm ERR! Error: ENOENT, no such file or directory '/home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/websocket-client/package.json'
npm ERR! You may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR!
npm ERR! System Linux 2.6.32.2-xxxx-grs-ipv6-32
npm ERR! command "node" "/home/admin/local/bin/npm" "install" "socket.io"
npm ERR! cwd /home/admin
npm ERR! node -v v0.6.10
npm ERR! npm -v 1.1.1
npm ERR! path /home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/websocket-client/package.json
npm ERR! code ENOENT
npm ERR! message ENOENT, no such file or directory '/home/admin/node_modules/socket.io/node_modules/socket.io-client/node_modules/websocket-client/package.json'
npm ERR! errno {}
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/admin/npm-debug.log
npm not ok