npm was told to use npm-shrinkwrap.json but the file is missing or not in the current directory. Commit or generate it, or switch to package-lock.json before rerunning.
npm prefers npm-shrinkwrap.json over package-lock.json when present. Some CI setups or older npm versions expect that file; if it is missing, renamed, or not checked in, fs.open fails with ENOENT and npm stops. This often happens after deleting the shrinkwrap file, migrating to package-lock without updating scripts, or in monorepos where the current directory differs from where the shrinkwrap lives.
pwd
ls npm-shrinkwrap.jsonIf missing, ensure you are in the package root that owns the shrinkwrap.
git checkout -- npm-shrinkwrap.json || true
npm shrinkwrapCommit the file if your pipeline expects it.
If your project uses package-lock.json, update CI scripts to stop requiring shrinkwrap and ensure package-lock is committed.
rm -rf node_modules package-lock.json npm-shrinkwrap.json
npm install --package-lock-only
npm cinpm resolves to npm-shrinkwrap.json before package-lock.json; keeping both can confuse CIβpick one. If you migrate off shrinkwrap, update npm to v7+ and remove scripts that expect it. In workspaces, each package may manage its own lock; ensure the shrinkwrap is committed for each published package to preserve exact versions.
npm ERR! code ENOAUDIT npm ERR! Audit endpoint not supported
How to fix "npm ERR! code ENOAUDIT - Audit endpoint not supported"
npm ERR! code EBADDEVENGINES npm ERR! devEngines.runtime incompatible with current node version
How to fix "npm ERR! code EBADDEVENGINES - devEngines.runtime incompatible with current node version"
npm ERR! code ETOOMANYARGS npm ERR! Too many arguments
How to fix "npm ERR! code ETOOMANYARGS - Too many arguments"
Run npm from the package directory that owns the shrinkwrap. Each package can have its own lock; ensure the correct one exists.