cli icon indicating copy to clipboard operation
cli copied to clipboard

[BUG] npm is failing to execute after nodejs update.

Open fr13nd230 opened this issue 1 month ago • 1 comments

Is there an existing issue for this?

  • [x] I have searched the existing issues

This issue exists in the latest npm version

  • [x] I am using the latest npm

Current Behavior

npm --help
/usr/share/nodejs/npm/lib/cli.js:48
    throw err
    ^

TypeError: Class extends value #<Object> is not a constructor or null
    at Object.<anonymous> (/usr/share/nodejs/npm/node_modules/fs-minipass/index.js:141:4)
    at Module._compile (node:internal/modules/cjs/loader:1706:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1839:10)
    at Module.load (node:internal/modules/cjs/loader:1441:32)
    at Module._load (node:internal/modules/cjs/loader:1263:12)
    at TracingChannel.traceSync (node:diagnostics_channel:328:14)
    at wrapModuleLoad (node:internal/modules/cjs/loader:237:24)
    at Module.require (node:internal/modules/cjs/loader:1463:12)
    at require (node:internal/modules/helpers:147:16)
    at Object.<anonymous> (/usr/share/nodejs/pacote/lib/fetcher.js:14:13)

Node.js v22.21.1

The problem even occur with other commands for an instance npm run command

Expected Behavior

npm to be working normally!

Steps To Reproduce

Node.js has been updated to v22.21.1 and system started failing I even couldn't execute npm -v

Environment

  • npm: 9.2.0~ds1-3
  • Node.js: v22.21.1
  • OS Name: Debian forky/sid x86_64
  • System Model Name: ThinkPad X1 Carbon Gen 11
  • npm config:
npm config ls

This won't work for me at all, npm is broken I've removed it and reinstalled it but nothing.

fr13nd230 avatar Nov 20 '25 13:11 fr13nd230

Looks like a Debian bug, rather than an upstream bug. The problem is also mentioned in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1117466#77

mmusenbr avatar Nov 21 '25 17:11 mmusenbr