Repository navigation
Cancel main's older CI run when a newer merge lands - #52
Merged
Merged
Conversation
Merging eleven PRs at 18:39 on Nov 6 started eleven full runs on main. Each needed about 5 minutes, but they queued behind the macOS runner limit for up to 62 minutes and held the doorbell PR's checks for 11. Every merge was already tested on its PR and the newest main run covers all of them, so main pushes now share one concurrency group and a newer one cancels the older.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What and why
On Nov 6 at 18:39, merging eleven PRs started eleven full CI runs on
main. Each needed about 5 minutes of work, but they queued behind the macOS runner limit for up to 62 minutes (run 42272702412). The doorbell PR (#40) waited 11 minutes for a runner in the same queue. Each merge was already tested on its own PR, and the newestmainrun tests everything merged before it, so the in-between runs added nothing.Now
mainpushes share one concurrency group (github.ref) and cancel in progress: a batch of merges costs one run. PR behaviour is unchanged (grouped by PR number, newer commit cancels). Manualworkflow_dispatchruns get their own group (run_id) and never cancel each other.How tested
python3 -c "import yaml; yaml.safe_load(...)": parses.mainrun cancelled (grey) and the newer one green.Risks
mainand merge B lands before A's run finishes, A's run is cancelled and B's run reports the break against B's commit, not A's. The PR runs still point at the culprit.maincommits. Theprotect-mainruleset checks PRs, notmainpushes, so nothing is blocked.What's left
Nothing.