GitHub Actions "Process completed with exit code 1" - Locate the Real Failure
A run step exited non-zero, so the runner reports "Process completed with exit code 1". This is a catch-all: the real cause is in the command output above it, not in the runner.
What this error means
A step ends with "Process completed with exit code 1" and the job fails, but the message itself says nothing about why - the actual error is earlier in the step log.
npm error code ELIFECYCLE
npm error Lifecycle script `test` failed with error
Error: Process completed with exit code 1.Common causes
A command in the step returned non-zero
Any failing command (a test run, a linter, a build) propagates its exit code. The runner reports exit code 1 as the step result.
set -e fails on the first error
Bash run steps use set -e by default, so the step stops and fails at the first command that returns non-zero, surfacing the generic message.
How to fix it
Read the output above the exit line
- Scroll up from the exit-code line to the first real error message.
- Reproduce the failing command locally to confirm the cause.
- Fix the underlying failure (failing test, lint error, missing file), not the exit code.
Make the failure easier to find
Split a long combined step into smaller named steps, or add echo markers, so the failing command is obvious.
- name: Lint
run: npm run lint
- name: Test
run: npm test # a failure here is clearly the test stepHow to prevent it
- Split combined run steps so failures pinpoint a single command.
- Surface tool output clearly rather than swallowing it.
- Treat exit code 1 as "look at the log above", not a runner bug.