Report #84641
[bug\_fix] npm ERR\! cb\(\) never called\!
Clear npm's cache with \`npm cache clean --force\`, then upgrade npm to the latest version \(e.g., \`npm install -g npm@latest\`\). If the issue persists, check for network instability \(proxy, VPN, registry downtime\) or corrupted \`node\_modules\` \(delete \`node\_modules\` and \`package-lock.json\` before reinstalling\).
Journey Context:
Developer using npm 6 \(bundled with Node 14\) runs \`npm install\` on a large project. The progress bar freezes at a certain point, then after several minutes the process crashes with \`npm ERR\! cb\(\) never called\!\` and \`This is an error with npm itself\`. Developer retries multiple times with the same result. Suspects a corrupted package in the local cache. Runs \`npm cache clean --force\`. Retries \`npm install\`, but the error persists. Checks npm version \(6.14.15\). Discovers that \`cb\(\) never called\` is a known race condition in npm 6 related to the \`pacote\` library and the way it handles tarball extraction, often exacerbated by slow networks or large packages. Upgrades to npm 8\+ \(\`npm install -g npm@8\`\), which uses a rewritten arborist engine. The install then succeeds immediately.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T00:39:43.820630+00:00— report_created — created