Repository navigation
ci: cost hygiene (concurrency, filters, retention) - #15
Conversation
Cancel superseded CI runs on the same ref so PR/push jobs do not pile up. Co-authored-by: Jonathan Borgwing <DevVig@users.noreply.github.com>
There was a problem hiding this comment.
🟢 Approval recommended
The reviewer identified no objective defects in the single well-formed concurrency block, leaving nothing outstanding to resolve.
No open issues 🎉
What changed in this PR
This PR applies a cost-hygiene improvement to GitHub Actions by adding a concurrency block to the repository's only CI workflow (.github/workflows/ci.yml). This ensures that redundant in-progress runs for the same workflow and ref are automatically cancelled when new commits arrive, reducing wasted runner minutes. The author intentionally limited the scope to this clearly-safe change, deferring docs-only paths-ignore and other optimizations due to uncertainty around required status checks.
Changes:
- Add a top-level
concurrencygroup keyed by${{ github.workflow }}-${{ github.ref }}. - Enable
cancel-in-progress: trueto stop superseded runs.
| File | Description |
|---|---|
.github/workflows/ci.yml |
Adds a concurrency block to cancel superseded in-progress CI runs per workflow/ref, reducing redundant runner usage. |
Note: cancel-in-progress: true also applies to push events on main (post-merge runs), so a rapid sequence of merges to main will cancel the earlier commit's run. This is the author's intended cost-hygiene tradeoff and is standard practice, but worth confirming it's acceptable if per-commit main run history is important for your workflow.
Review effort: Balanced
Summary
Cost-hygiene for GitHub Actions, applied only where clearly safe.
Applied
.github/workflows/ci.yml(PR/push CI, no existing concurrency):group: ${{ github.workflow }}-${{ github.ref }}cancel-in-progress: trueSkipped (per rules)
paths-ignoreonCI(.github/workflows/ci.yml): skipped. This is the repo’s only test workflow; CONTRIBUTING.md and README say it runs typecheck/tests on every PR/push, so it is likely a required status check. Addingpaths-ignorecould skip the check on docs-only PRs and leave them blocked.coderabbit-fallback-review(or other CodeRabbit) workflow in.github/workflows/.actions/upload-artifactretention: none. CI does not upload artifacts.Judgment calls
CIis inferred from repo docs, not from protection settings. IfCIis confirmed not required, docs-onlypaths-ignore(**/*.md,docs/**) could be added later.paths-ignorefor other non-code paths (e.g.LICENSE, issue templates) — out of scope.workflow_dispatchin place; concurrency still applies to the same ref.Type of change
Checklist
bun run typecheckpassesbun run testpassestests/unit-context-window.mjsNotes
Independent of the Namespace runners PR. Based on
mainonly.Summary by CodeRabbit