Repository navigation
Post-merge follow-ups from PR #74: gated exit-77 accounting + junk transition ref refusal - #75
Merged
Merged
Conversation
… failure drill-lib.sh adopted the producer side of the skip contract (exit 77 = prerequisite missing, with its rationale in-line) but the counter never learned it: run-skill-tests.sh tallied the seven gated integration suites as FAIL on any machine without ARKHO_DIR, and test-harness-smoke.sh still gated with exit 0 — a phantom green pass, the exact failure mode drill-lib's own comment warns against. Both sides now speak the contract: the runner counts 77 as [SKIP] in both verbose and captured modes (surfacing the gate's SKIP reason lines), and the smoke test propagates 77. The PASS-branch grep that compensated for exit-0 skips is retired with the convention. All branches exercised: 77/124/1 exits and a clean pass, in both output modes; lint-shell clean.
…ueError board-transition's --plan gate validated argv through A.ref while the plain path handed the raw string to A.transition, whose int() raised an uncaught ValueError traceback — the last argv ref in the API tier not validated at the edge (six sibling verbs already do). The drills' discrimination is mutation-proven: with the fix reverted, exactly the two new asserts fail (the nt on the Traceback the old path raised).
…a skip The 77-means-SKIP branch added in 5731274 keyed off the exit code alone, so any suite that exited 77 for its own reasons — a `set -e` file propagating some child's stray 77, say — was tallied as a skip instead of a failure. That left `failed=0` and the runner printing `STATUS: PASSED` over a suite that never passed. Only the board-api integration drills define 77 as "prerequisite missing" (the contract in integration/drill-lib.sh). Gate the skip on the test's path matching that tier and nothing else; a 77 from anywhere else falls through to the ordinary [FAIL] handling, output dump included. The predicate is computed once per test and applied identically in the verbose and non-verbose branches, and the path is the only signal — the output is not parsed for SKIP markers.
SSFSKIM
added a commit
that referenced
this pull request
Sep 24, 2026
…, R1-F3); pre-existing dead-session slot gap filed as #75
SSFSKIM
added a commit
that referenced
this pull request
Sep 24, 2026
Report the BOARD_GH_TIMEOUT decimal normalization, the 300s caps on the GitHub read bound and the renewal interval, and the budget-long drill's resizing, with the aggregate test evidence as it happened. State the tree-quiet gate as a best-effort proxy and the dead-seat cleanup as the pre-existing #75 gap, matching the re-pinned Decision Log.
SSFSKIM
added a commit
that referenced
this pull request
Sep 24, 2026
…viewed head (#182) * spec(#74): the API tick's finalize pass — a merged PR at the reviewed head closes its ticket * spec(#74): second revision after the adversarial review — order ahead of review-recover, re-read before the write, sync the seat, bump the version * sweep(api): a finalize pass closes a ticket whose PR merged at the reviewed head * tests: the api finalize pass, hermetic * qa-loop: the trail names the reviewed head; the API finalize pass beside gh's FINALIZE * spec(#74): record full-tier verification * spec(#74): record the PR and handback constraint * sweep(api): finalize treats a dead owner as not mid-turn A session that died mid-turn leaves status=working in its registry record; finalize read that field without _liveness's verdict and stalled the merged ticket behind an owner no agent will ever speak for. A dead seat now skips the mid-turn check and the close is written as its run, as the spec's step 3d intends. * sweep(api): finalize writes nothing when the registry scan fails _metas_for_ticket runs through a process substitution, which hides a dead scan; finalize read the empty result as no owner and fell to the automation write, whose override passes the local fence and whose principal skips the server's by-this-run trail gate. The pass now checks _scan_ok like every other scan consumer and skips the ticket, and reads the scan to its end so the status is written before it is checked. * sweep(api): finalize renews live leases on a clock across its scan The pass reads GitHub and the board serially for every in-review ticket, and that scan can fill the tick budget, which is the lease's own length, after the tick's one renewal. Every live run is now renewed again ahead of a candidate once the last renewal pass began BOARD_FINALIZE_RENEW_SEC (default 300) ago. On a clock rather than per item as relay and resume do, because a per-candidate renewal would cost runs x candidates calls every tick. * spec(#74): re-pin — finalize leaves a live owner whose QA child still reviews (R2-F1) * sweep(api): finalize leaves a live owner whose transcript tree is still active An idle live owner may still have its QA child reviewing under subagents/; any done ends the run out from under it. Apply review-recover's whole-tree quiet gate against REVIEW_STALL_MIN before writing; no transcript is no signal, and a dead owner bypasses the gate. Fixture ticket 91 is now the pinned live+idle owner with a fresh tree; the dead-owner coverage moves to ticket 92 (fresh file, still closes as run). * sweep(api): finalize holds a ticket whose owner carries an unresolved fork _liveness reads status=error + pending_short as forked: not dead, but its record is not working/blocked either, so finalize wrote done as the run while the fork may still be live on it (and the tree gate only sees the superseded turn's transcript). Hold and surface it on stderr, as relay and resume already do. Fixture ticket 93 (forked owner, stale old transcript, accepting by-id row and transition) proves no write. * sweep(api): finalize takes its list round-robin past the last ticket a tick took A budget spent mid-list re-read the list from its head every tick, so the same first candidates took the budget each time and a merged ticket behind them was never examined. The last ticket taken is kept in a per-binding store and the next tick starts past it, wrapping at the end. * qa-loop: the reviewed-head trail line is a PR review's; a scale trail names its ranges Every PR trail carries the head the latest engine round reviewed, the trail so far before a hand-up included. A scale run has no PR and no merge, and may have no aggregate head, so its trail names the ranges it reviewed instead. * sweep(api): finalize bounds its GitHub read under the tick lock A stalled gh pr view held the per-board lock with no renewal until GitHub answered: the budget is checked before the read and renewal runs between candidates, so neither can end a read in flight. _gh_read_bounded runs gh in its own process group under BOARD_GH_TIMEOUT (60s, clamped >=5) and kills the group on expiry; the existing could-not-read log and continue stand. Test: a PR read hanging 147s in a grandchild ends at the 5s bound, 80 is logged and skipped, 88 still closes, runs renew after it, the helper is dead and the lock released. Red on the unbounded call (took 72s at a 47s hang, 80 closed off the late answer) and on a child-only kill (helper left). * spec(#74): the retrospective reflects the review loop's changes and the open park Outcomes & Retrospective predated every QA wave. It now names the live-tree gate, dead owner, unresolved-fork hold, failed-scan hold, clocked renewal, round-robin fairness, the bounded GitHub read and the PR-only head line, and states the remote-owner automation fallback as the open human park with no merge. A living-plan retrospective only: no re-pin, no pinned-section edit. Checks: test-sweep-finalize.sh PASS (drills 91-93, scan, renew, rotate, hung read) and test-qa-loop-agent.sh all passed at this head. * spec(#74): re-pin — automation close only for a null owner_run; a non-null remote owner_run is left for its home host (R3-F2, human's second re-pin) * sweep(api): finalize closes as automation only for a null owner_run; a remote owner run is left for its home host A non-null owner_run with no seat in this registry is a lease-live owner elsewhere, whose QA child this host cannot see; a done from here would end that run under it. Skip it with the 'another registry' line; the automation override reason now names the only case that reaches it. Ticket 94 drills the skip. * sweep(api): under `all`, finalize takes a share of the tick, not all of it Slow GitHub reads across the in-review list could spend the whole tick budget on every `all` tick, starving review-recover, relay, resume and dispatch indefinitely. The `all` arm now gives finalize half of what the tick has left: a later candidate is taken only if a read run to its bound still ends inside the share, and the first candidate's read is cut at the share's end, so even a budget-long read cannot outlast it. The whole-tick _budget_left ceiling, the cursor rotation, and a standalone `finalize` (no share) are unchanged. Drills: two slow-read `all` ticks (20s budget, 3s reads) stop finalize at its share, keep the rotation, and reach dispatch's claims; two `all` ticks whose first read is as long as the budget (8s/8s) cut that read and still reach dispatch. * spec(#74): re-pin — a dead local owner is left for the reclaim, not closed as its run (R3-F1: dead-run close leaks the seat slot) * sweep(api): finalize leaves a dead local owner for the reclaim instead of closing as its run A done written as a dead run ends it server-side, but a dead session is never renewed, so no 409 strips the run from its meta and the seat keeps its run and dispatch slot. The dead owner is now skipped with the spec's dead-session line; its lease lapses, the reclaim clears owner_run, and a later tick closes as automation. Ticket 92's drill is inverted in place (R3-F1). * spec(#74): re-cut — finalize leaves any lingering-predecessor-seat ticket to the recovery lifecycle (R5-F1: automation close leaked the reclaimed dead seat) * fix(api): leave reclaimed tickets with lingering owner seats for recovery * spec(#74): re-pin — state finalize's liveness/cleanup honestly (R1-F2, R1-F3); pre-existing dead-session slot gap filed as #75 * fix(api): read BOARD_GH_TIMEOUT as decimal before finalize's share arithmetic (W1-1) * test(api): size the budget-long first-read ticks for the phases behind finalize (W2-1) An 8s budget handed review-recover, relay and resume roughly half of it after finalize's cut read; those phases take ~2s here on their own, so dispatch's budget gate raced them (observed: dispatch started at ~8.2s of an 8s tick). A 30s budget with a 30s read keeps the proof (an uncut read would spend the whole tick) and leaves the phases ~13s. * fix(api): cap finalize's GitHub read bound below the run lease (W2-2) BOARD_GH_TIMEOUT clamped only from below, so an override of 901 let a standalone finalize read wait past the 15-minute lease with no renewal while the tick held the lock. Capped at 300: a read on top of a renewal interval and a candidate's 30s board calls still ends inside the lease. * fix(api): cap finalize's renewal interval below the run lease (W2-3) BOARD_FINALIZE_RENEW_SEC accepted any integer, so an interval of 1000 let a standalone scan of slow PRs go past the 15-minute lease between renewals with the lock held. Capped at 300 alongside the read bound. The tests that held renewal off with an over-lease interval now let it run: the scan-fail stub dies only after GitHub is read, and u-90's native wake lands only after its PR is read, so finalize's own sync is still the one pinned. * spec(#74): refresh Outcomes after the QA fix waves (WC-1) Report the BOARD_GH_TIMEOUT decimal normalization, the 300s caps on the GitHub read bound and the renewal interval, and the budget-long drill's resizing, with the aggregate test evidence as it happened. State the tree-quiet gate as a best-effort proxy and the dead-seat cleanup as the pre-existing #75 gap, matching the re-pinned Decision Log.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What this is
The two follow-up ticket candidates recorded in PR #74's review trail, executed. Releases as v7.57.1.
The changes
tests/claude-code/run-skill-tests.sh+test-harness-smoke.sh).drill-lib.shadopted the producer side of the skip contract (77 = prerequisite missing) but the counter never learned it: seven integration suites tallied as FAIL on any machine withoutARKHO_DIR, and the smoke test still gated with exit 0 — a phantom green pass. Both sides now speak the contract; the 77→SKIP branch is scoped toboard-api/integration/*only, so a stray 77 from any other suite stays a failure; the gate's SKIP reason lines surface in captured mode. Spec Revision Note resolution appended.skills/issue-tracker/scripts/board-transition.sh). The--plangate validated argv throughA.refwhile the plain path handed the raw string toA.transition'sint()— the last argv ref in the API tier not validated at the edge (six sibling verbs already do). Drill pair added beside the register verb's.Review trail
nton the Traceback the old path raised).lint-shell.shclean on all four touched shell files.🤖 Generated with Claude Code
https://claude.ai/code/session_01R8uGu8nAKgDauJcD3CM6PK