A developer pushes a change, sees a mistake, and pushes a correction while the first CI run is still working. The team now has two revisions it could test. The first result may help explain a regression or document an intermediate step. The second result matters to someone deciding whether to merge what is currently on the branch. A workflow can make a choice about which work to continue. We looked at a rule that makes runs on ordinary feature branches eligible for interruption, and checked what an observed pair of runs could tell us about that decision.
Define which runs belong together
The rule groups runs using both the event that started the workflow and the full reference it ran against. In a fictional example, two pushes to a branch called Feature A share a group because their event and reference match. A push to Feature B creates a different group. This difference matters when two developers are working independently. If all feature branches shared one group, the arrival of a change on one branch could affect a run that is testing unrelated work. A per-reference group makes the branch the unit for deciding which revisions can supersede each other under this rule.
Grouping and interruption are separate decisions. The workflow enables in-progress cancellation for pushes to ordinary branches, with explicit exclusions for the default branch and release branches. A tag push and a non-push event also fall outside that predicate. These examples follow from reading the configuration. They describe whether the rule allows interrupting a run that is already executing. The concurrency group still applies when the interruption flag is off. We did not examine how queued runs are retained or replaced in those cases, so the default and release exclusions do not establish that every revision on those branches completes a full run.
Put the two results on a timeline
On the branch that introduced the rule, we inspected two hosted runs triggered by pushes. They tested different revisions. We verified the same concurrency block at both revisions and at the merge, while the rest of the workflow was outside that comparison. The older run's backend job started, and a newer run was created while that job was still in progress. The older backend job ended as cancelled shortly after the newer run was created. The newer run later completed successfully, including its backend check. Those records give us distinct outcomes for the two revisions.
The ordering is consistent with an older run being superseded, but it does not establish the reason the earlier job was cancelled. We did not rule out a manual cancellation, a timeout, or a runner interruption. The gap between creation of the older run and the start of its backend job is also unexplained by this comparison. We did not reproduce the two pushes in a local experiment. This is a chronology from hosted run records, and the cancellation flag is a separate observation from the workflow source. Keeping the two apart lets us describe the decision the workflow expresses without attributing an observed outcome to that rule alone.
Keep the result attached to its revision
When reading the CI record, I would keep both outcomes. A cancellation tells the reader that the earlier job stopped. A successful check on the later revision gives evidence for that revision. It cannot supply the result that the earlier job would have produced. If someone is tracing the first revision that introduced a regression, the cancelled run may be a gap in that investigation. If they are reviewing the tip of the branch, the successful run on the revised head may answer the immediate question. The value of continuing a run depends on which question the team needs its result to answer.
A fuller evaluation would send a controlled pair of pushes, capture the reason for cancellation, and observe how long the older job takes to stop. It would also check whether work started by that job leaves state behind and when an eligible worker becomes available again. Those observations would help separate a change in the workflow's verdicts from a change in how quickly contributors get feedback. We did not measure those effects here. The example gives us a concrete rule for interruption and a clear reason to record queue state, job outcome, and revision separately when evaluating it.
← All engineering articles