Skip to content
Latchkey

GitHub Actions "The operation was canceled"

The job did not fail on its own; the orchestrator told it to stop, so its steps were interrupted and the conclusion is "cancelled" rather than a real error from your code.

What this error means

A step ends mid-execution with "The operation was canceled." The job conclusion is cancelled, not failed, and there is no error from the command itself.

github-actions
Error: The operation was canceled.

Common causes

Concurrency cancel-in-progress

A concurrency group with cancel-in-progress: true canceled the older run when a newer commit started.

Manual cancel, fail-fast, or timeout

Someone canceled the run, a matrix sibling failed under fail-fast, or a job/step timeout fired, each of which cancels remaining work.

How to fix it

Identify what issued the cancel

  1. Check whether a newer run on the same ref started (concurrency).
  2. Look for a failed matrix sibling with strategy.fail-fast not disabled.
  3. Confirm no one canceled the run manually.
  4. Inspect timeout-minutes on the job and steps.
.github/workflows/ci.yml
concurrency:
  group: ${{ github.workflow }}-${{ github.ref }}
  cancel-in-progress: true

Tune the policy if cancels are unwanted

Set cancel-in-progress: false to let runs finish, or strategy.fail-fast: false to keep matrix legs running after one fails.

How to prevent it

  • Make concurrency cancel behavior explicit per workflow.
  • Disable fail-fast where partial matrix results are useful.
  • Set realistic timeout-minutes so legitimate work is not cut off.

Frequently asked questions

What causes ""The operation was canceled""?
A concurrency group with cancel-in-progress: true canceled the older run when a newer commit started.
How do I fix "The operation was canceled"?
Identify what issued the cancel

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card