GitHub Actions cancel-in-progress cancels a deploy mid-flight
concurrency with cancel-in-progress: true cancels the running job when a newer run joins the same group. For CI that is desirable, but for deploys it can interrupt a half-applied release, leaving infrastructure in an inconsistent state.
What this error means
A deploy job is cancelled mid-run when a subsequent push triggers another run in the same concurrency group.
github-actions
concurrency:
group: deploy-prod
cancel-in-progress: true # a new push cancels the in-flight prod deployCommon causes
cancel-in-progress applied to deploys
Deployments should usually finish, not be preempted by a newer run.
Shared group between CI and deploy
Reusing one group for fast CI and slow deploys lets CI churn cancel deploys.
How to fix it
Queue deploys instead of cancelling
- Set cancel-in-progress: false for deploy concurrency so runs queue and complete.
- Use a dedicated deploy group separate from CI.
.github/workflows/deploy.yml
concurrency:
group: deploy-prod
cancel-in-progress: falseSeparate CI and deploy groups
- Give CI its own cancel-in-progress group and deploys a serialized group.
- This prevents CI activity from preempting deploys.
How to prevent it
- Use cancel-in-progress: false for deployments.
- Keep deploy and CI concurrency groups distinct.
Related guides
GitHub Actions concurrency group expression evaluates to emptyFix a concurrency group built from a context value that resolves empty, collapsing all runs into one global g…
GitHub Actions Deploy Canceled Mid-Run by a Concurrency GroupStop GitHub Actions deploys being canceled mid-run - a shared concurrency group with cancel-in-progress abort…
GitHub Actions concurrency cancel-in-progress without a groupFix GitHub Actions concurrency that does nothing because cancel-in-progress was set without a concurrency gro…