GitHub Actions / Events, execution, and data boundaries / Lesson 7
Step outcomes and release gates
Interpret step outcome and conclusion when a workflow handles an optional failure.
On this page
Lesson goals
- Distinguish a step outcome from its conclusion.
- Verify that required failures still block an intended release gate.
Follow the step result
A workflow run contains jobs and steps whose states need to be interpreted in context. GitHub exposes the outcome of a completed identified step before continue-on-error is applied and its conclusion afterward. An optional diagnostic can fail while the job continues, but that choice should be deliberate. Name which checks are required for the release before writing conditions or reviewing a green job.
Inspect an optional failure
The first synthetic record illustrates a step that failed but has a successful conclusion after continue-on-error. It is an explanatory JSON record, not a workflow file or a live run result. Preserve the failure evidence and decide how it is reported; a successful conclusion does not mean the underlying command succeeded. The exact conditions and permissions remain part of the actual workflow.
{"step_id":"optional_check","outcome":"failure","conclusion":"success","continue_on_error":true}
The original outcome is failure while the conclusion reflects the configured continuation behavior.
Compare a required test
The second fixture represents a required test that fails without continuation. Its failure should prevent the release path according to the reviewed workflow and repository protection. A later reporting step can still run under an appropriate condition, but publishing a report is not the same as passing the test. Inspect the actual job and protected revision rather than assuming the fixture describes every workflow.
{"step_id":"required_test","outcome":"failure","conclusion":"failure","continue_on_error":false}
The fixture retains a failure conclusion; no workflow is executed.
Review conditions and evidence
Conditions can skip steps or allow cleanup and reporting after failure. Record which step ran, its outcome and conclusion, the job result and the source revision evaluated. Check the actual status required by branch protection or deployment policy. A successful optional diagnostic, a skipped required test and a successful release gate are different outcomes and should not be collapsed into one color.
Test both paths safely
In a disposable repository, create a synthetic optional failure and a required test failure, then inspect the step contexts and downstream gate. Confirm that reporting runs as intended while the required failure prevents promotion. Repeat with a passing test and a skipped condition. Preserve sanitized logs and do not trigger a real deployment merely to demonstrate workflow behavior.
Common errors and fixes
A successful conclusion is reported as proof the command passed.
- Why it happens
- The effect of continue-on-error was overlooked.
- How to fix it
- Inspect the original outcome and diagnostic output.
- Prevent it next time
- Label optional checks and their reporting policy.
A failed required test does not block release.
- Why it happens
- Continuation or a downstream condition bypassed the gate.
- How to fix it
- Correct the workflow and verify the protected status.
- Prevent it next time
- Test a controlled failure in CI.
A skipped test is treated as a passing test.
- Why it happens
- Skipped and successful states were conflated.
- How to fix it
- Inspect the condition and required test result.
- Prevent it next time
- Report selected, executed and skipped checks separately.
2 practice exercises
1. In the first fixture, did optional_check actually pass?
Show worked solution
No. Its outcome is failure. Its conclusion is success after the configured continuation behavior, so the original diagnostic failure still needs to be interpreted.
2. Why run a reporting step after a required test fails?
Show worked solution
A report can preserve evidence for diagnosis, but the required test must still block the release gate. Test the workflow condition and job result rather than treating report publication as a pass.
Key takeaways
- A step outcome and conclusion can differ after continuation.
- Test that required checks block release even when reporting continues.