Repository navigation
test(ci): fail when ci-workflows raises a wait report-ci-status keeps - #17410
Conversation
ci-status calls report-ci-status without a wait input, so check-contract's and aggregate-results' rate-limit-wait-seconds stay at ci-workflows' defaults. A raise there would land with the next pin bump and silently outgrow the 435 s GH_READ_MARGIN_SECONDS that holds the composite's waits. The test reads, at the SHA ci-status pins, report-ci-status's action.yml and every same-repository action it runs, then asserts each rate-limit-wait-seconds is at most WAIT_BUDGET_SECONDS.step (the value rate-guard.mjs documents for these defaults) and that those waits plus aggregate-results' rerun-wait-seconds fit GH_READ_MARGIN_SECONDS. At 9c5bedfb (v0.76.3): 60 + 60 + 90 = 210 <= 435. It lives in callers.test.mjs, which already reads ci-workflows at pin and has yaml; affected-tests.sh selects it when pr-require-checks.yml (and so the pin) changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Vcupoo79EqmECYFZ4MTv6C
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
claude-security-review reviewed Security review: PR #17410 (incremental, 724fb6d → 70bba39)I found no security issues. This was an incremental review of the one file changed since the last reviewed head, What changed: the test now also counts two more waits against
Checks I made:
Prior findings and settled threads. The only prior entry is the lane's last summary, which reported no findings, so nothing carries over. critical-findings: 0 |
|
claude-review reviewed Incremental review, 724fb6d → 70bba39: no blocking findingsScope: one file, What changed: the sum check now adds two figures before comparing against
This answers this lane's earlier finding (discussion_r4625580805). That thread is resolved with an owner reply and stays settled. Using the PR's figures, raising Fail-closed behavior I checked in the new code:
Other checks:
Loosened-check verdict: fail (default; no verdict line in the prompt); patterns: 0 Verifier dropped 0 of 0 candidates. |
The sum compared only the input waits (210 s) with the whole 435 s GH_READ_MARGIN_SECONDS, though the margin's comment in pr-require-checks.yml also budgets 120 s of own-gate retries and 7 s of status writes, so a rerun-wait default of 250 passed and overflowed. The own-gate retries are now read at the pin from aggregate-results/run.sh (OWN_GATE_RETRY_DELAYS, summing to 120). The 7 s of status writes exists in no ci-workflows file as a value, so STATUS_WRITE_RETRY_SECONDS carries the margin comment's figure. At 9c5bedfb: 60 + 60 + 90 + 120 + 7 = 337 <= 435; with a 250 rerun wait, 497 > 435 fails. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Vcupoo79EqmECYFZ4MTv6C
No related issue: a guard test for the ci-workflows wait defaults ci-status keeps since #17283.
Summary
Since #17283, ci-status calls ci-workflows'
report-ci-statuscomposite with no wait input, so check-contract's and aggregate-results'rate-limit-wait-secondsstay at ci-workflows' defaults. Nothing here failed if a pin bump brought a raised default that outgrows the 435 sGH_READ_MARGIN_SECONDSholding the composite's waits.Fix
.github/actions/resolve-config/callers.test.mjsreads, at the ci-workflows SHA ci-status pins (fetchAtPin),report-ci-status/action.ymland each same-repository action it runs.rate-limit-wait-seconds, each value (the step'swith, else the input default) is at mostWAIT_BUDGET_SECONDS.step(60,rate-guard.mjs), and those waits plus aggregate-results'rerun-wait-seconds, its own-gate retries (OWN_GATE_RETRY_DELAYSinaggregate-results/run.shat the pin) and the margin comment's 7 s of status writes (STATUS_WRITE_RETRY_SECONDS) fitGH_READ_MARGIN_SECONDS.9c5bedfb(v0.76.3): 60 + 60 + 90 + 120 + 7 = 337 s against 435 s.Verification
node --test --test-name-pattern="report-ci-status's waits" .github/actions/resolve-config/callers.test.mjs: pass.'600'through the same fetch-and-parse path fails:check-contract's rate-limit-wait-seconds at 9c5bedfb… is 600, over WAIT_BUDGET_SECONDS.step 60. Feeding aggregate-results'rerun-wait-secondsas'250'fails the sum:total 497 s, over GH_READ_MARGIN_SECONDS 435. Both restored.scripts/affected-tests.sh .github/workflows/pr-require-checks.ymlselectscallers.test.mjs(it references the workflow), so a pin bump runs the test.Related
🤖 Generated with Claude Code
https://claude.ai/code/session_01Vcupoo79EqmECYFZ4MTv6C