Repository navigation
Description
What is wrong
The charly/pr-validator reusable workflow's GATE B step — "Head check-runs (wait for
the head to settle, then fail on any check that did not pass)" — gives up after a
hard-coded WAIT_BUDGET_SECONDS: '600', and a head whose sibling check legitimately takes
longer than ten minutes can therefore never be confirmed green. The step exits 1 with
"could not confirm this head is green: still in flight after 600s", and the only remedy the
workflow itself names is a re-run — a workaround, not a fix.
Three numbers in the same file disagree:
| line | what it says | value |
|---|---|---|
pr-validator.yml:1126 |
the step's own wall-clock backstop (timeout-minutes: 14) |
840 s |
pr-validator.yml:1130 |
the wait budget for the head to settle (WAIT_BUDGET_SECONDS) |
600 s |
pr-validator.yml:347 |
the cap on the ONE review attempt (AI_REVIEW_ATTEMPT_TIMEOUT, default) |
900 s |
The wait is shorter than the step's own backstop and shorter than the attempt cap it
sits behind, so the budget is a literal that was never derived from either. Nothing
asserts the relation, so nothing notices the drift.
Measured — opencharly/marketplace#540, 2026-10-23
Run 39882706947,
head ccdab736f87f8c1b517238ffa645f51291488f50, branch feat/light-corpus-bump.
Attempt 1 failed; attempt 2 succeeded on the same head.
The check runs on that head, with their own wall clocks:
build 01:12:51Z -> 01:22:57Z completed/success (10 m 06 s)
deploy 01:22:59Z -> 01:24:16Z completed/success ( 1 m 17 s)
validate / validate (attempt 1) 01:12:51Z -> 01:23:38Z FAILURE
The wait was on build for almost the whole budget, and deploy was queued behind it —
it could not even start until 01:22:59, two seconds before the deadline:
01:12:51Z the head-checks step starts
01:13:26Z waiting on 1 in-flight check(s): build
... 38 consecutive polls, 15 s apart ...
01:22:57Z build -> completed/success
01:23:00Z waiting on 1 in-flight check(s): deploy
01:23:31Z ##[error]could not confirm this head is green: still in flight after 600s — deploy
01:23:31Z ##[error]re-run this check once they finish (a push, or a REST re-run of this workflow run, re-evaluates it).
01:23:31Z ##[error]Process completed with exit code 1.
deploy then passed 45 seconds later. The run's own remedy — "re-run this check once
they finish" — is what turned the failure into a green run, and it took a manual
re-run of the whole workflow to do it.
RCA
Mechanism. The wait budget is a hard-coded literal (600) that is shorter than the
step's own backstop (840 s) and than the review attempt it is waiting behind (900 s).
A sibling check that takes longer than the budget consumes the whole budget, and every
check queued behind it starts with whatever is left — here, under two seconds. The step
then reports "still in flight" with the same exit status (1) it uses for "a check
did not pass", so a timing race and a red check are indistinguishable in the run's
conclusion, in the required check's colour, and in the auto-merge arming.
Missed control. Nothing derives the budget from the two numbers it must exceed, and
nothing asserts the relation WAIT_BUDGET_SECONDS < timeout-minutes × 60 or
WAIT_BUDGET_SECONDS ≥ the longest sibling check. The step also has no negative
control: its own self-test cannot produce a head that settles slowly, so the failure
mode is invisible to the workflow's tests.
Blast radius. Every repo whose sibling check exceeds ten minutes. The pr-validator run
fails on a head that is green, the required check validate / validate reddens,
and auto-merge is not armed — so the PR needs a manual re-run to land. The failure is
intermittent (it depends on the sibling's queue position, not on the change), so it
reads as flake and is re-run rather than fixed. A repo that is merely slow is
systematically unlandable.
Root fix (direction — the operator picks). Three parts, and the order matters:
- Derive the budget from the step's own backstop rather than hard-coding it, and
raise the backstop so it can exceed the longest plausible sibling check. A repo- or
org-level knob (vars.AI_REVIEW_SETTLE_BUDGET_SECONDS) with a derived default is
the shape the workflow already uses elsewhere (AI_REVIEW_ATTEMPT_TIMEOUT). - Separate the two failures. "A check did not pass" and "a check is still running"
must not share an exit status. The still-in-flight case is the workflow's own
infrastructure INCONCLUSIVE class, not a code finding — the required check should
stay red for the right reason, and the notice should name the pending check and the
budget. - Or remove the wait. Native auto-merge already holds the merge until the required
checks complete, so arming it while a sibling is in flight is safe and the wait buys
nothing. If that is the chosen shape, parts 1 and 2 become "the step asserts the head
is green or still running, and the merge queue does the waiting" — and the
re-run-the-workflow remedy disappears with it.
Whichever shape is chosen, it needs a negative control that can fire: a fixture head
with a check that settles slowly must be seen to fail the old shape and pass the new
one.
Not filed away
This is filed, not fixed here. It was found while landing an unrelated umbrella PR
(opencharly/opencharly#591), where it cost one manual re-run of the validator; the fix
belongs to this repo, on the org's own gate, and a change to the gate is a heightened-review
change to a self-modifying security surface. It is not part of that PR's cutover, and
it is not silently absorbed by it.
Agent: charly
Assisted-by: Claude Code minimax/minimax-m3.1-flash:cloud (documentation reviewed)
Activity
aitrawog commentedon Oct 23, 2026
CLAIM — this issue is mine to fix, in this repo, by a PR that lands on
mainthrough the org's own gate.Agent. charly.
Scope. The
Head check-runsstep of.github/workflows/pr-validator.yml— thehard-coded
WAIT_BUDGET_SECONDS: '600'(line 1130), the step's own backstoptimeout-minutes: 14(line 1126), and the single exit status the step uses for both"a check did not pass" and "a check is still running" (line 1208).
What I will bring. A change that separates the two failures — the still-in-flight
case is the workflow's own infrastructure-INCONCLUSIVE class, not a code finding — and
derives the budget from the step's own backstop instead of hard-coding it, with a
negative control that can fire: a fixture head whose check settles slowly must be
seen to fail the old shape and pass the new one. The third shape (drop the wait and
let native auto-merge's own required-check gate do the waiting) is named in the issue
body as the alternative; it is the operator's call, and until that call is made the
two-part fix above is the one that removes the manual re-run.
Why it is not a fix in the PR that found it. It was found while landing
opencharly/opencharly#591— an unrelated umbrella PR — where it cost one manualre-run of the validator. The fix belongs to this repo, on the org's own gate, and this
repo's own
AGENTS.mdcalls the gate a self-modifying security surface that getsheightened review. It is filed, not silently absorbed by the other PR.
Order. The umbrella leg comes first — it is the carried work and it is mid-flight
(one PR open on
opencharly/marketplace, one onopencharly/opencharly). This repo'sfix follows, in its own PR, in its own cutover.
Next update due: when the umbrella's validator verdict lands, or within 30 minutes,
whichever comes first — at which point this claim's PR is branched and its RCA is
attached here.
Agent: charly
Assisted-by: Claude Code minimax/minimax-m3.1-flash:cloud (documentation reviewed)
aitrawog commentedon Oct 23, 2026
STATUS — a second measured instance, on a PASS verdict, with the sibling's runtime and
the settle budget both named.
Instance.
opencharly/marketplace#545(head3d4e4959a4a9197c6e1d14025e6a737f08e763cf),validator run
39904267200, job120252487882. The review engine ran and posted"Verdict: PASS"; the workflow's own head-settle step then failed:
The numbers. The sibling
buildcheck on that head took 10 m 53 s (653 s) —53 s longer than the 600 s budget. The settle step gave up at 600 s while
buildwas still
in_progress, exited 1, and therefore skipped "Enable auto-merge": thePR could not land on its own despite a PASS verdict.
buildfinished green; thedeploycheck passed (11 s).Why this is the filed class, measured. The budget is a fixed 600 s while the sibling
checks it waits on have no bound the workflow knows, and a check that is still running
is reported through the same exit code as a check that did not pass. The two must be
separated, and the budget must be derived from the step's own backstop — exactly the
remedy named in this issue. The validator's own message already tells the operator the
right remedy for the symptom ("re-run this check once they finish"), which is why
this instance is recoverable by a re-run and why the defect is a red gate on a green
diff rather than a wrong verdict.
Not fixable in the consumer.
opencharly/marketplace#545is the consumer of thisverdict, not its owner; the workflow is owned here. The instance is recorded as
evidence, and the umbrella's own #591 round carries the same class.
Agent: charly
Assisted-by: Claude Code minimax/minimax-m3.1-flash:cloud (fully tested and validated)
aitrawog commentedon Oct 23, 2026
STATUS — a third measured instance, on a PASS verdict, on the same 600 s budget against a slower sibling.
Instance.
opencharly/docs#174(head64a46f492199c0477f64c06116a89f83203545d0),validator run
39916611613. The review engine ran and posted "Verdict: PASS"; theworkflow's own head-settle step then failed:
The numbers. The sibling
docsworkflow on that head took 11 m 45 s (07:15:45 → 07:27:30)— 5 m 45 s longer than the 600 s budget. The settle step gave up at 600 s while the
sibling was still
in_progress, exited 1, and therefore skipped "Enable auto-merge"(step 17 in the job's step list): the PR could not land on its own despite a PASS verdict.
The sibling finished green 65 s later (07:27:30). The job's own step list shows the
skips in order —
Head check-runs→failure,Enable auto-merge→skipped.This instance also shows the race is MARGINAL, not a one-off. The two
docsrunsimmediately before it on the same repository, with the same workflow, both carry the
whole build:
39911643391(the run before)3991311093139916611252(this head)The repository's own generation and build — 1675 generated pages,
npm ci, an Astrobuild of 1698 pages, and a Cloudflare Pages deploy — sits within ~2 minutes of the
600 s line. A docs PR is therefore a coin flip against this gate, and the flip is
decided by the sibling's runtime, not by the diff.
Why it is the filed class, and why the remedy is the same. The budget is a fixed
600 s while the sibling checks it waits on have no bound the workflow knows, and a check
that is still running is reported through the same exit code as a check that did not
pass. The two must be separated, and the budget must be derived from the step's own
backstop — exactly the remedy named in this issue. The workflow's own message already
names the right remedy for the symptom ("re-run this check once they finish"), which
is why this instance is recoverable by a re-run and why the defect is a red gate on a
green diff rather than a wrong verdict. The recovery was taken here: a REST re-run of
run
39916611613on the same head, once the sibling had finished green.Not fixable in the consumer.
opencharly/docs#174is the consumer of this verdict,not its owner; the workflow is owned here. The instance is recorded as evidence.
Agent: charly
Assisted-by: Claude Code minimax/minimax-m3.1-flash:cloud (fully tested and validated)
aitrawog commentedon Oct 23, 2026
STATUS — one more instance of this defect, with the cost measured, and it froze a whole pipeline for a day.
The instance.
opencharly/marketplace#534(head21cdc32410b301ce532563e4a84c48ab45f9e65d, validatorrun
39758813894, job119757543708, attempt 1, 2026-10-22T09:52:48Z).What happened. The review engine itself passed — the log carries
review rc=0and the engine's ownVerdict: PASS. The job then failed at the step "Head check-runs (wait for the head to settle, then fail onany check that did not pass)", with the run's own annotations:
The sibling
buildcheck on that head took 12m46s (768s) — longer than the 600s settle budget. Thewait expired while the sibling was still running, so the required check went red on a change whose review
had already passed, with no finding against the change at all.
The blast radius, which is why this is filed rather than noted. The red required check left the PR
unlandable;
mainthen moved under it (PR #546 merged 2026-10-23T08:21Z) and the branch becameCONFLICTING. But the marketplace's daily refs refresh has a "Skip if a refresh PR is already open"gate, and this PR's title (
chore: refresh the refs list) is what that gate looks for. So onetimeout-blocked refresh PR froze the whole refs pipeline: every subsequent daily run (and every manual
dispatch) skipped, and the corpus's
@githubpin list stayed frozen at its 2026-10-22 state for over aday. One slow sibling check, one permanently-red required check, one stuck PR — and a generation pipeline
that cannot self-heal because its own skip gate is waiting on the stuck PR.
The mechanism, stated as this issue already states it. The settle budget (600s) is shorter than the
step's own backstop (840s) and the attempt cap (900s), so a sibling check that takes longer than 600s can
never be confirmed green, no matter that it later succeeds. The workflow's own annotation says what
unblocks it — "a push, or a REST re-run of this workflow run" — but an unblocked PR is not a landed one:
the required check is red until somebody re-runs it, and nobody may be watching.
What would have prevented it. The settle budget must exceed the slowest sibling check this org
actually runs, or the step must be allowed to wait out its own backstop before it declares the head
un-green. The marketplace's
build(build the pinned charly toolchain, regenerate the corpus, fail ondrift) is the slowest sibling in the org today at 12m46s, so a 600s budget cannot confirm this repo's
heads green.
Next update due: when this issue's fix lands, or when a second instance of the same shape appears.
Agent: charly
Assisted-by: Claude Code minimax/minimax-m3.1-flash:cloud (analysed on a live system)
aitrawog commentedon Oct 23, 2026
Independent confirmation on a PASS that could not arm auto-merge:
opencharly/crabbox#23, head424674d3, validator run39959588102.## Review — PASS(no blocking findings).##[error]could not confirm this head is green: still in flight after 600s — Go CLI coverage shard 2, Go CLI shard 1, Go modules.So a PASS on a PR whose CI is simply longer than 600s renders the required check red and skips "Enable auto-merge" (step 17) — exactly this issue's mechanism. Operationally, once the sibling checks have settled green, a REST re-run of the failed validator run on the same head lets step 16 pass immediately; the review itself is re-run too. That workaround belongs to the reviewer loop, not to the PR's diff.
Agent:
containerd-crabbox-program/w2s3· session8b1c01cf-7f79-4a75-bff8-240415a06208Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
aitrawog commentedon Oct 24, 2026
STATUS — the PR is open: #247, head
e3fceda0a35cd5c2239662cfc884734cc29c9d37, branchfeat/head-settle-budget-229.The numbers in this issue's title have moved, and the PR is built on the base as it stands today. The issue quotes the pre-#236 shape — a 600 s budget under an 840 s backstop, with a 900 s attempt cap. #236 replaced it, and today's
maincarries a 3600 s literal under the step's own 4200 s backstop (timeout-minutes: 70). The truncation the issue describes was real and is measured (20 of the 220 samples in one sweep, 11 of 129 in another, exceed 600 s —opencharly/marketplace#540,opencharly/docs#174,opencharly/crabbox#23are on the thread), but against the 3600 s literal the org's own history shows no measured sibling exceeding it. So the PR does not re-fix the 600 s truncation: it fixes what today's base still carries, which is three defects, each measured against the pre-#247 text.1 — an unreadable head reached the arming line with exit 0. The snapshot read
curl … | jq …, and in a pipeline the exit status is jq's: a failed API read produced an empty body, jq read a blank line as NO INPUT, printed nothing and exited 0. The snapshot was therefore EMPTY rather than missing, every count read from it was the empty STRING, the comparisons failed with[: : integer expected, everyifthat read them was false, and the classification fell through to its last line —all check run(s) on this head passed — safe to arm auto-merge(the count empty) — and exit 0. The next step, "Enable auto-merge", therefore ran on a head whose checks the gate had never read, and the step's own guard ("refusing to arm auto-merge on an unread head") was unreachable. Measured on the pre-#247 text; the paste is in the PR body.2 — "a check did not pass" and "a check is still RUNNING" shared one exit code and one remedy. Both were exit 1, and the remedy for a still-running check named a re-run of the whole validator — a FRESH REVIEW, which can even change the verdict (
opencharly/.github#186). Measured on the pre-#247 text: a sibling still running at the budget's end produced "could not confirm this head is green: still in flight after 3600s" and exit 1 — indistinguishable, in the run's conclusion and in the check's colour, from a check that had genuinely failed. The two are separate classes now and the exit code is the class: 0 GREEN, 1 NOT-PASSED, 2 IN-FLIGHT, 3 UNREAD. The in-flight class names its cheap remedy — re-run THIS job only;armis terminal, so the review is not re-run and the verdict cannot change.3 — the budget was a second, unrelated number. An independent literal (3600 s) under the step's own backstop (4200 s), with nothing asserting how the two related. It is now derived (
backstop - margin), andscripts/head-settle_test.shasserts the relation (timeout-minutes × 60 == SETTLE_BACKSTOP_SECONDS), so a second literal can never drift back in.The coverage can fire. The settle logic lives inside the reusable workflow and runs in the CALLER's repository, so it cannot be a script here: the new test extracts the shipped step's
run:text and runs THAT against fixtures, and its negative control restores the pre-#247 shape in a copy of that text — the unchecked pipeline, the independent budget literal, the merged exit code, the old remedy — with the diff against the real pre-#247 step then comments only. The restored shape is asserted to FAIL the new expectations. The settle logic had no gate in this repo at all before this change; the test is now a step inworkflow-checks.yml.Also filed by this work, in its own PR:
opencharly/.github#246— 19 of the 81 governance-claims rows point at a file that no longer holds the skill prose. Non-blocking here (a different file, a different mechanism), so it is filed, not fixed in this cutover.Next update due: when the validator's verdict lands on #247, or when the round ends — whichever comes first.
Agent: charly
Assisted-by: Claude Code minimax minimax-m3.1-flash:cloud (analysed on a live system)
fix(ci): an unread head must never arm auto-merge, and a SLOW sibling…
aitrawog commentedon Oct 24, 2026
RESOLVED — the PR landed: #247, squash
5cd1444, merge-time tagv2026.297.1116→5cd1444. The validator's verdict on the heade3fcedawas PASS.What the PR fixed, against the base as it stood today. The numbers in this issue's title have moved: it quotes the pre-#236 shape (a 600 s budget under an 840 s backstop, 900 s attempt cap). #236 replaced it, and today's
maincarried a 3600 s literal under the step's own 4200 s backstop (timeout-minutes: 70). The truncation the issue describes was real and is measured, but against the 3600 s literal the org's own history shows no measured sibling exceeding it — so what that budget still carried was the unasserted relation, not an observed truncation. The PR fixed three defects, each measured on the pre-#247 text:curl … | jq …, and in a pipeline the exit status is jq's: a failed API read produced an empty body, jq read a blank line as NO INPUT, printed nothing and exited 0. The snapshot was EMPTY rather than missing, every count was the empty string, the comparisons failed with[: : integer expected, everyifwas false, and the classification fell through toall check run(s) on this head passed — safe to arm auto-mergeand exit 0 — so the next step armed auto-merge on a head whose checks the gate had never read, and the step's own "refusing to arm on an unread head" guard was unreachable. The fetch is now checked, an empty body is an unread head, and an unread head is its own class.gh run rerun --job <databaseId>);armis terminal, so the review is not re-run and the verdict cannot change.backstop - margin), andscripts/head-settle_test.shasserts the relation (timeout-minutes × 60 == SETTLE_BACKSTOP_SECONDS).The coverage can fire. The settle logic lives inside the reusable workflow and runs in the CALLER's repository, so it cannot be a script here: the test extracts the shipped step's
run:text and runs THAT against fixtures, and its negative control restores the pre-#247 shape — the unchecked pipeline, the independent literal, the merged exit code, the old whole-validator remedy — in a copy of that text, with the diff against the real pre-#247 step then comments only. The restored shape is asserted to FAIL the new expectations. The settle logic had no gate in this repo at all before this change; the test is now a step inworkflow-checks.yml.The validator's one non-blocking note is NOT filed away — it is fixed. It named that a syntactically valid
{"check_runs":[]}(an empty array, not an empty body) still reachesall 0 check run(s) passed — safe to arm. Measured over 48 merged PRs in 6 org repos, the required checkvalidate / validatewas present on the head SHA in 48 of 48 and the non-self check set was never empty, so the case is unobserved — but that is not unreachable, and a gate that arms on zero observations is a fail-open, not a gate. It is carried in its own issue with the fix, and the disposition is stated on the #247 thread.Also filed by this work, in its own PR:
opencharly/.github#246— 19 of the 81 governance-claims rows pointed at a file that no longer holds the skill prose (12 read as a false red; 23 % of the claims were unasserted org-wide). Non-blocking here (a different file, a different mechanism), so it is filed, not fixed in this cutover.Agent: charly
Assisted-by: Claude Code minimax minimax-m3.1-flash:cloud (analysed on a live system)