lundi 5 novembre 2018

When I try to run $ npm install to install all modules on project, or when trying to install ember v 2.18 with $ npm install ember@2.18 it gives me the error:

npm http GET https://www.npmjs.com/ember
npm http 200 https://www.npmjs.com/ember
npm ERR! registry error parsing json
npm ERR! SyntaxError: Unexpected token <
npm ERR!
npm ERR! <!doctype html>
npm ERR! <html>
. . .
. . .
npm ERR! </html>
npm ERR! 
npm ERR!     at Object.parse (native)
npm ERR!     at RegClient.<anonymous> (/home/felipe/.nvm/v0.8.16/lib/node_modules/npm/node_modules/npm-registry-client/lib/request.js:226:23)
npm ERR!     at Request.init.self.callback (/home/felipe/.nvm/v0.8.16/lib/node_modules/npm/node_modules/request/main.js:120:22)
npm ERR!     at Request.EventEmitter.emit (events.js:99:17)
npm ERR!     at Request.<anonymous> (/home/felipe/.nvm/v0.8.16/lib/node_modules/npm/node_modules/request/main.js:648:16)
npm ERR!     at Request.EventEmitter.emit (events.js:126:20)
npm ERR!     at IncomingMessage.Request.start.self.req.self.httpModule.request.buffer (/home/felipe/.nvm/v0.8.16/lib/node_modules/npm/node_modules/request/main.js:610:14)
npm ERR!     at IncomingMessage.EventEmitter.emit (events.js:126:20)
npm ERR!     at IncomingMessage._emitEnd (http.js:366:10)
npm ERR!     at HTTPParser.parserOnMessageComplete [as onMessageComplete] (http.js:149:23)
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.9.0-8-amd64
npm ERR! command "/home/felipe/.nvm/v0.8.16/bin/node" "/home/felipe/.nvm/v0.8.16/bin/npm" "install" "ember@2.18"
npm ERR! cwd /workspace/acras/projects/api_dashboard
npm ERR! node -v v0.8.16
npm ERR! npm -v 1.1.69
npm ERR! type unexpected_token
npm ERR! Error: EACCES, open 'npm-debug.log'
npm ERR!  { [Error: EACCES, open 'npm-debug.log'] errno: 3, code: 'EACCES', path: 'npm-debug.log' }
npm ERR! 
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Linux 4.9.0-8-amd64
npm ERR! command "/home/felipe/.nvm/v0.8.16/bin/node" "/home/felipe/.nvm/v0.8.16/bin/npm" "install" "ember@2.18"
npm ERR! cwd /workspace/acras/projects/api_dashboard
npm ERR! node -v v0.8.16
npm ERR! npm -v 1.1.69
npm ERR! path npm-debug.log
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, open 'npm-debug.log'
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /workspace/acras/projects/api_dashboard/npm-debug.log
npm ERR! not ok code 0

I tried with sudo, no luck.
I also tried to uninstall NPM and NodeJS, but no luck also.

How do I fix that? Is this a problem with my NPM or NodeJS installation?

Thanks!




Aucun commentaire:

Enregistrer un commentaire