fix(ci): require fail-closed aggregate-check evidence - #1259
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
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. Comment |
|
4699b7a to
b15f7a7
Compare
|
Updated on exact head
The PR remains Draft. Exact-head upstream Actions and maintainer security review are still required; the Windows full suite is not claimed green. |
b15f7a7 to
01c21f5
Compare
|
Reviewed this one closely because it changes when CI runs at all, which One blocker before it can land, and it is in the fail-closed property the PR is named after.
The Suggested fix inside - name: Assert the scope output is usable
shell: bash
run: |
set -euo pipefail
case "${{ steps.filter.outputs.ci }}" in
true|false) ;;
*) echo "::error::changes.outputs.ci was '${{ steps.filter.outputs.ci }}', expected true or false"; exit 1 ;;
esacThat turns the silent-skip case into a failing Two smaller notes:
Holding rather than approving. CI here is |
|
Two corrections to my comment above, one of which is a defect in the snippet I suggested. The validation step I wrote interpolates the expression directly into shell. - name: Assert the scope output is usable
shell: bash
env:
CI_SCOPE: ${{ steps.filter.outputs.ci }}
run: |
set -euo pipefail
case "$CI_SCOPE" in
true|false) ;;
*) echo "::error::changes.outputs.ci was '$CI_SCOPE', expected true or false"; exit 1 ;;
esacWorth being explicit about what this does and does not buy: it closes the malformed output hole — empty string, renamed output, unexpected value — and nothing more. It cannot tell you a syntactically valid I also overstated the #1265 overlap. I said whichever of #1259 and #1265 lands second inherits a conflict. I checked the branch relationship, not the hunks — both touch The main blocker stands unchanged: |
Summary
changesfilter;changes.outputs.cias exactlytrueorfalse, re-emit only that validated value, and fail the producer job on missing or malformed output;ciresult, including documentation-only pull requests whose expensive jobs are intentionally skipped;cievidence and fail closed when the filtered response is missing, unreadable, foreign, pending, unsuccessful, conflicting, or truncated;checks: readpermission required by its live check lookup;Why
The readiness gate previously treated missing aggregate evidence as green. Requiring a check without changing the trigger would deadlock documentation-only pull requests, because the workflow-level path filter created no
ciresult for them.This change always creates the pull-request workflow, scopes costly work inside the read-only
changesjob, validates the filter output before downstream jobs consume it, and requires complete positive evidence before accepting the contributor CI claim.Verification
tests/ci-workflows.test.ts— 130/130 passed.b22e0e6d0): the same file — 130/130 passed.bun x tsc --noEmit: passed.bun scripts/privacy-scan.ts: passed.git diff --check: passed.Security boundary
The readiness writer remains a
pull_request_targetworkflow executing trusted default-branch code. Untrusted values are transported through step environment variables instead of shell-source interpolation. The Cross-platform CI workflow retains read-only repository permissions for pull requests, uses hosted runners for PR jobs, exposes no secrets, and keeps the persistent self-hosted Windows lane dispatch-only.This GitHub Actions policy change remains Draft pending exact-head upstream CI and the repository-required maintainer security review.
Readiness checklist