Skip to content
Latchkey

GitHub Actions continue-on-error on a matrix hides a real failing leg

continue-on-error lets a step or job fail without failing the run. Applied to a whole matrix it masks every failing leg, so a broken combination passes CI silently and required checks go green.

What this error means

A matrix leg clearly failed in its logs, yet the job and the overall run are reported as successful.

github-actions
strategy:
  matrix:
    target: [a, b, c]
continue-on-error: true   # every leg can fail without failing the run
# target=b failed but the run is green

Common causes

continue-on-error applied at job level over the matrix

It suppresses the failing status of every matrix leg, not just a known-flaky one.

Intent was to tolerate one leg, not all

Tolerating a single experimental combination requires scoping continue-on-error to that include entry.

How to fix it

Scope continue-on-error to a single include leg

  1. Move continue-on-error into the specific matrix combination you want to tolerate via include.
  2. Leave the rest of the matrix strict so real failures fail the run.
.github/workflows/ci.yml
strategy:
  matrix:
    target: [a, b]
    include:
      - target: experimental
        experimental: true
steps:
  - run: ./build.sh ${{ matrix.target }}
    continue-on-error: ${{ matrix.experimental == true }}

Remove blanket continue-on-error

  1. Delete job-level continue-on-error unless every leg is genuinely allowed to fail.
  2. Use fail-fast: false to keep legs independent without hiding failures.

How to prevent it

  • Keep continue-on-error as narrow as possible.
  • Audit required checks to ensure they actually go red on real failures.

Frequently asked questions

What causes "continue-on-error masks failure"?
It suppresses the failing status of every matrix leg, not just a known-flaky one.
How do I fix continue-on-error masks failure?
Scope continue-on-error to a single include leg

Related guides

References

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