ci(coverage): scope Test Coverage concurrency by ref (stop cross-PR cancellations)#333
Open
breimanntools wants to merge 1 commit into
Open
ci(coverage): scope Test Coverage concurrency by ref (stop cross-PR cancellations)#333breimanntools wants to merge 1 commit into
breimanntools wants to merge 1 commit into
Conversation
…ancellations)
The concurrency group was keyed on the workflow name only, making it repo-global:
with several PRs open, a new run anywhere cancelled all others, so only one PR ever
got a coverage number and every other PR's run showed a spurious 'cancelled' (red).
Add ${{ github.ref }} to the group so each branch/PR only supersedes its own
in-progress run; different branches no longer cancel each other.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #333 +/- ##
=======================================
Coverage 94.93% 94.93%
=======================================
Files 185 185
Lines 17883 17883
Branches 3038 3038
=======================================
Hits 16978 16978
Misses 598 598
Partials 307 307
🚀 New features to boost your workflow:
|
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.
Problem
The Test Coverage workflow (
test_coverage.yml) sets its concurrency group to${{ github.workflow }}— the workflow name only, with no${{ github.ref }}. That makes the group repo-global: withcancel-in-progress: true, a new run on any branch/PR cancels the in-progress runs of all others.With several PRs open at once, only the newest run survives; every other PR's coverage run ends as a spurious
cancelled(red ✗) and never reports a coverage number. (Confirmed: the failing checks concludecancelled, killed during dependency install before any test ran — not a test or coverage failure.)Fix
Add
${{ github.ref }}to the group so it is scoped per branch/PR:Now a new push to a branch only supersedes that branch's own in-progress run (still no stacked redundant runs on rapid pushes), while different branches/PRs no longer cancel each other — so every PR gets its own coverage result. Standard GitHub Actions pattern. The explanatory comment is updated to match.
Trade-off: with many active branches this permits more than one coverage run at a time (the previous config deliberately serialized the heaviest workflow repo-wide). That serialization is what caused the missing coverage on all-but-one PR, so per-ref scoping is the correct behavior for a multi-PR repo.
🤖 Generated with Claude Code