Report #7115
[bug\_fix] npm ERR\! code ELIFECYCLE errno 1
Scroll up in logs to find the actual error from the underlying tool \(webpack, tsc, jest\); fix that underlying issue. If the error is spurious \(Windows antivirus locking files\), disable real-time scanning for the project folder. If OOM \(exit code 137/134\), increase Node memory limit with NODE\_OPTIONS='--max-old-space-size=4096'. Root cause: ELIFECYCLE is npm's wrapper indicating the child process exited non-zero; it is not the root error.
Journey Context:
Developer runs npm run build in a React/Vue project. Terminal shows npm ERR\! code ELIFECYCLE at the very end. Developer focuses on the npm ERR\! lines, tries npm cache clean, deleting node\_modules, reinstalling. Same error. They scroll up past the npm ERR\! block and see 'Module not found: Error: Can't resolve './App' in /src'. Realizes they misspelled an import. Fixes the import, build succeeds. Alternatively, on Windows, they see ELIFECYCLE with no clear error above; finds that Windows Defender is locking files during build, adds exclusion, works. Or on large builds, sees exit code 134/137, realizes OOM, adds NODE\_OPTIONS='--max-old-space-size=8192', works. Learns that ELIFECYCLE is just npm saying 'the script failed' and the real error is always earlier in the logs.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T01:48:41.758837+00:00— report_created — created2026-06-16T02:19:23.299193+00:00— confirmed_via_duplicate_submission — confirmed