cli icon indicating copy to clipboard operation
cli copied to clipboard

[BUG] <npm crashes when trying to install/uninstall pacakges>

Open Raid5594 opened this issue 6 years ago • 6 comments

npm crashes when trying to install/uninstall pacakges

I get the following error, when installing the package Tried to remove npm folder and cache, didn't help

npm install eciesjs npm ERR! code EINVALIDTYPE npm ERR! typeerror Error: Argument #2: Expected object but got null npm ERR! typeerror at prepareAction (/usr/local/lib/node_modules/npm/lib/install/actions.js:183:3) npm ERR! typeerror at actionsToRun.reduce (/usr/local/lib/node_modules/npm/lib/install/actions.js:152:16) npm ERR! typeerror at Array.reduce () npm ERR! typeerror at runSerial (/usr/local/lib/node_modules/npm/lib/install/actions.js:150:29) npm ERR! typeerror at doReverseSerial (/usr/local/lib/node_modules/npm/lib/install/actions.js:146:3) npm ERR! typeerror at Array. (/usr/local/lib/node_modules/npm/node_modules/slide/lib/bind-actor.js:15:8) npm ERR! typeerror at LOOP (/usr/local/lib/node_modules/npm/node_modules/slide/lib/chain.js:15:14) npm ERR! typeerror at /usr/local/lib/node_modules/npm/node_modules/slide/lib/chain.js:18:7 npm ERR! typeerror at withInit.nodeify (/usr/local/lib/node_modules/npm/lib/install/actions.js:131:5) npm ERR! typeerror at tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23) npm ERR! typeerror at Promise.successAdapter [as _fulfillmentHandler0] (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/nodeify.js:23:30) npm ERR! typeerror at Promise._settlePromise (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:571:21) npm ERR! typeerror at Promise._settlePromise0 (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:619:10) npm ERR! typeerror at Promise._settlePromises (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:699:18) npm ERR! typeerror at _drainQueueStep (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:138:12) npm ERR! typeerror at _drainQueue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:131:9) npm ERR! typeerror This is an error with npm itself. Please report this error at: npm ERR! typeerror https://npm.community

npm ERR! A complete log of this run can be found in: npm ERR! /Users/Raid/.npm/_logs/2020-01-08T15_25_45_613Z-debug.log

Raid5594 avatar Jan 08 '20 15:01 Raid5594

Hi @Raid5594,

Please provide your npm and node versions so we can reproduce it.

node -v npm -v

DanielRuf avatar Jan 14 '20 06:01 DanielRuf

I am getting the same error when I install a new package.

node -v - v12.16.0
npm -v 6.13.4

ronhupa avatar Mar 20 '20 03:03 ronhupa

Can not repdoruce on Ubuntu:

npm-issue-993 npm install eciesjs

> [email protected] install /home/druf/Schreibtisch/npm-issue-993/node_modules/secp256k1
> node-gyp-build || exit 0

npm WARN saveError ENOENT: no such file or directory, open '/home/druf/Schreibtisch/npm-issue-993/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/home/druf/Schreibtisch/npm-issue-993/package.json'
npm WARN @angular/[email protected] requires a peer of @angular/[email protected] but none is installed. You must install peer dependencies yourself.
npm WARN npm-issue-993 No description
npm WARN npm-issue-993 No repository field.
npm WARN npm-issue-993 No README data
npm WARN npm-issue-993 No license field.

+ [email protected]
added 15 packages from 105 contributors and audited 24 packages in 4.495s
found 0 vulnerabilities

DanielRuf avatar Mar 20 '20 09:03 DanielRuf

I encountered this issue when I pulled my code from SVN. There were missing components and inconsistencies in the package.json reason I cannot install a new npm.

I resolved this by excluding nodes/components and the package.json in SVN.

ronhupa avatar Mar 31 '20 01:03 ronhupa

npm v6 is no longer in active development; We will continue to push security releases to v6 at our team's discretion as-per our Support Policy.

If your bug is preproducible on v7, please re-file this issue using our new issue template.

If your issue was a feature request, please consider opening a new RRFC or RFC. If your issue was a question or other idea that was not CLI-specific, consider opening a discussion on our feedback repo

Closing: This is an automated message.

darcyclarke avatar Jun 02 '21 21:06 darcyclarke

npm v6 is no longer in active development; We will continue to push security releases to v6 at our team's discretion as-per our Support Policy.

If your bug is preproducible on v7, please re-file this issue using our new issue template.

If your issue was a feature request, please consider opening a new RRFC or RFC. If your issue was a question or other idea that was not CLI-specific, consider opening a discussion on our feedback repo

Closing: This is an automated message.

darcyclarke avatar Jun 02 '21 22:06 darcyclarke