A cancelled check shouldn’t tell you your code failed
Six of nine open pull requests for our cloud infrastructure showed a red and a green result for the same check. The red one said “cancelled.” A review had arrived while the check from a push was still running, and our workflow was set to stop the earlier run.
We changed the workflow to let the running check finish. The next run looks up the current reviews and changed files when it starts, so it can see if an approval was withdrawn while it waited.
Other workflows can still cancel a check. In one case, the replacement took 56 seconds just to appear. During that gap, our merge gate used to call the cancellation a failure. Now it keeps the merge blocked and waits up to 20 minutes for a replacement. A replacement still has to pass. If none shows up, the check fails when the window closes.
There’s a tradeoff: a job that hit its own time limit can also show up as cancelled, so the same wait can delay a failure you actually want to see. If you run required checks, can your merge gate tell a run that was replaced from one that timed out? What signal do you trust?







Comments
0 comments