You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Trim PR Actions usage and defer macOS packaging to merge/release - #183
Cancel superseded PR runs in CI, Desktop and Self-Host Image without cancelling unrelated workflows or release candidates. Docs-only PRs skip heavy jobs, while required lint/test names fail closed on selector or lint errors. Keep Linux/Windows packaging/smoke tests on PRs and all four desktop targets on main, merge queue and immutable releases. The existing Publish test job keeps the full post-merge workspace suite; CI covers merge queues without a redundant new CI push run.
Apply the ci-cost-trim skill: add the 30-day report, per-run ledger and a bounded test-suite audit. Pass dynamic matrix fields via quoted environment variables to remove the shell-interpolation findings exposed by the security scan. Signing, provenance, release/smoke gates, secrets and main rules remain unchanged.
Audit: 76 run records and 547.50 observed runner minutes, including controlled verification runs. Excluding those verification branches, macOS PR jobs consumed 65.38 min. That is a gross saving opportunity, not net savings: new full main/merge verification offsets it. No test deletion, quarantine or scanner consolidation is performed; no billed-dollar or post-merge saving claim is made.
Validation:
actionlint, changed-file oxlint/oxfmt and commit hooks pass; 23 release/workflow tests and 9 selector tests pass. Zizmor remains non-clean on documented pre-existing findings; the newly introduced matrix injection findings are fixed.
Pre-audit full CI/Desktop/Image runs 41443911708, 41443911448 and 41443911471 passed. Final audited runs 41453728992, 41453728746 and 41453728751 execute the same heavy gates, with Linux/Windows PR targets only.
Deliberate selector-failure PR DO NOT MERGE: verify CI failure propagation #185, CI run 41453874222: both required lint and test report failure. Unexpected selection failures cannot become successful skips. Both test PRs are closed without merging.
Replacing a commit automatically cancelled CI/Desktop/Image runs 41443628010/016/019. No cancellation API was used for those runs. An older always()-based probe needed cleanup; it is not counted as automatic cancellation proof.
Local merge-group/matrix coverage passes. Live merge-queue verification is pending because no queue is configured/exercised. Main rule contexts remain lint/test.
Reports: CI cost report, test-suite discovery. No implementation merge, secret changes or test removal. Two-week remeasurement plan included, not scheduled.
Documentation-only pull requests skip resource-intensive build and verification jobs while retaining required check names.
Superseded pull-request runs are canceled automatically; other workflow runs are not canceled by this policy.
Desktop checks cover macOS packages on merge and release, while pull-request checks focus on Linux and Windows.
Merge-queue verification is supported across CI workflows.
Documentation
Added guidance on CI triggers, required checks, platform coverage, and pre-merge verification.
Added reports on CI usage and test-suite efficiency.
A shared CI policy classifies pull-request changes and selects job execution and desktop targets. CI, desktop, and self-host workflows use the policy outputs and update their triggers and concurrency behavior.
Changes: CI Policy and Workflow Selection
Layer / File(s)
Summary
Policy selection and validation .github/scripts/ci-policy.mjs, .github/scripts/ci-policy.test.mjs
The selector classifies documentation-only paths, obtains pull-request changed paths, and selects heavy-job execution and desktop targets by event. Tests cover path handling and event policies.
Required CI gates and merge-queue validation .github/workflows/ci.yml, tests/scripts/release-workflows.test.ts
The CI workflow adds merge-group runs and selector-driven gates for lint, tests, and the dashboard build. Workflow tests check selector-failure handling, triggers, and cancellation behavior.
Desktop and self-host workflow selection .github/workflows/desktop.yml, .github/workflows/selfhost-image.yml, tests/scripts/release-workflows.test.ts
Desktop and self-host workflows add selector jobs and use their outputs to control work. The desktop build uses the selected matrix and passes packaging values through environment variables.
CI documentation and reports .changeset/trim-actions-usage.md, docs/ci.md, docs/reports/*
The changeset and CI guide describe CI behavior. The reports document observed CI costs, workflow inventory, test-step timing, and measurement limits.
sequenceDiagram
participant GitHubEvent
participant Policy as ci-policy.mjs
participant ChangesJob as changes
participant CIJobs as CI workflow jobs
participant DesktopBuild as desktop build
GitHubEvent->>Policy: event name and changed paths
Policy-->>ChangesJob: run_heavy and desktop_matrix
ChangesJob->>CIJobs: run_heavy controls job execution
ChangesJob->>DesktopBuild: desktop_matrix selects build targets
Loading
Merge Risk: Minimal · up to 4af0e
This PR changes CI triggers, cancellation and path-based job selection. The reviewed evidence shows no regression in main-push coverage, and the only remaining comment is a cosmetic documentation nit. It is ready to merge once the hosted heavy-job results pass.
Pre-merge checks: 3 · 2
Failed checks: 2 warnings
Check name
Status
Explanation
Resolution
Title check
The title accurately describes the CI workflow changes, but it does not use the required Conventional Commits prefix.
Prefix the title with an allowed type, such as "ci: Trim PR Actions usage and defer macOS packaging to merge/release".
Docstring Coverage
Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed checks: 3 passed
Check name
Status
Explanation
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Description check
The pull request description directly matches the changeset. It describes CI cancellation, documentation-only job selection, desktop matrix changes, workflow validation, security fixes, and audit repo…
Full details: Description check
Explanation
The pull request description directly matches the changeset. It describes CI cancellation, documentation-only job selection, desktop matrix changes, workflow validation, security fixes, and audit reports.
Full details: Docstring Coverage
Explanation
Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 3 functions across 3 files. (5 skipped: 5 unsupported.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
Finishing Touches
Generate docstrings
Commit to this branch
Create a new PR
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Reviewing files that changed from the base of the PR and between 965b9c7 and 4af0e7f.
Files ignored due to path filters: 1
docs/reports/ci-cost-runs.csv is excluded by !**/*.csv
Files selected for processing: 6
.github/workflows/ci.yml
.github/workflows/desktop.yml
docs/ci.md
docs/reports/ci-cost-report.md
docs/reports/test-suite-efficiency-report.md
tests/scripts/release-workflows.test.ts
Files with no reviewable changes: 1
.github/workflows/ci.yml
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.
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
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.
Cancel superseded PR runs in CI, Desktop and Self-Host Image without cancelling unrelated workflows or release candidates. Docs-only PRs skip heavy jobs, while required lint/test names fail closed on selector or lint errors. Keep Linux/Windows packaging/smoke tests on PRs and all four desktop targets on main, merge queue and immutable releases. The existing Publish test job keeps the full post-merge workspace suite; CI covers merge queues without a redundant new CI push run.
Apply the ci-cost-trim skill: add the 30-day report, per-run ledger and a bounded test-suite audit. Pass dynamic matrix fields via quoted environment variables to remove the shell-interpolation findings exposed by the security scan. Signing, provenance, release/smoke gates, secrets and main rules remain unchanged.
Audit: 76 run records and 547.50 observed runner minutes, including controlled verification runs. Excluding those verification branches, macOS PR jobs consumed 65.38 min. That is a gross saving opportunity, not net savings: new full main/merge verification offsets it. No test deletion, quarantine or scanner consolidation is performed; no billed-dollar or post-merge saving claim is made.
Validation:
Reports: CI cost report, test-suite discovery. No implementation merge, secret changes or test removal. Two-week remeasurement plan included, not scheduled.