Labels
No labels
agent-blocked
agent-working
autopilot
bug
deferred
deploy-pending
enhancement
landing-pr
model-haiku
model-opus
model-sonnet
needs-design
needs-info
needs-triage
no-triage
out-of-scope
priority
ready-for-agent
ready-for-human
ready-for-session
rehearsal-183
snapshot-pending
standing-drive
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Matou/idss#2145
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The swarm has claimed nothing for over two hours while 8 tickets are ready — including #2141, the fix for red
main. Every worker iteration opens with an empty ready-tasks block, signalsCOMPLETE(or ends unclaimed), and the lane quietly stops. Found by the healer on heal runheal-Matou-idss-1793759807-2474692(ci run 59281, signature372652b2f4ef), while diagnosing why the #2141 vet break keeps re-REDingcion every push.Symptom
.sandcastle/claim-next-task.shemits[]and exits 0, while.sandcastle/list-ready-tasks.shrun by hand a second later returns 8 tasks. The workers notice and narrate it, verbatim fromworker-logs.txtin the heal bundle:Four consecutive worker runs (
20261104-013734,-014515,-020918,-021937) burned their single iteration this way. Last swarm-landed commit:d6578ff7, 00:29 UTC. Now: 02:43 UTC.Root cause — the lister leg can no longer fit its 12s bound
claim-next-task.shbounds the lister from outside atCLAIM_LISTER_MAX_TIME=12(idss#1195), andtimeout's rc 124 takes the graceful[]arm:Measured on
matou-dev-server-01at 02:38–02:43 UTC, 4 consecutive runs of the lister:So the lister exceeds 12s on 3 of 4 runs, and sits on the knife edge on the fourth. Per-endpoint probes name the dominant legs — this forge's own listing latency, not the script's logic:
issues?state=open&type=issues&limit=50&page=1pulls?state=open&limit=50issues?state=open&labels=standing-drive&limit=50issues/2141/dependencies?limit=50#128already moved/pullsand the standing-drive listing to the background so they overlap, so the lister ≈max(issues-page, /pulls)+ the dependency fan-out. With the issues page alone at 8–22s there is no room under a 12s bound.Note the healer's own latency probe does not see this:
api-timing.txtreadsapi_seconds=1.03against a cheap endpoint, so the bundle looks healthy while the swarm starves.Why it matters — this is the #1425 shape, on the leg #1425 did not close
#1425 fixed exactly this hazard for the alive-runs leg: a laundered
[]"is inserted by the prompt shell-expansion as an EMPTY ready-tasks queue, which a worker's 'Done' check treats as a completion candidate — fail-closed at the script, fail-OPEN at the surface that matters". That leg now exits loud. The lister-124 leg still emits[], and it is now firing every tick — so the swarm reads "nothing to do" while redmainsits unfixed, and nothing in the fleet reports a fault.Raising the bound does not fix it:
CLAIM_NEXT_DEADLINEis 26s, so a 20s lister leaves 6s for the claim walk,cap = 6/CLAIM_CANDIDATE_CALLS(5) = 1 < CLAIM_CALL_FLOOR(2), and the walk emits[]from the other graceful arm instead. There is no env-level escape.Why the healer did not repair it
Both files are factory-vendored —
claim-next-task.sh(FACTORY_MANIFEST:14) andlist-ready-tasks.sh(FACTORY_MANIFEST:40), atFACTORY_REF=4dc855df. An in-repo edit is drift andcheck-harness-drift.shblocks it. The #891/#931/#1394/#1411/#1425 pattern applies: land upstream inMatou/dev-factory, bumpFACTORY_REF, re-vendor — henceready-for-session, notready-for-agent.Shape of the fix (upstream; pick, don't do all three)
labels=ready-for-agentfiltered listing would return a handful instead of every open issue. (Careful: #120 records that this forge ignores an unknownlabels=filter and dumps every open issue, so the filter must be proven against a known-good label, with a read-back assertion.)[]— finish #1425 on this leg: rc 124 exits non-zero like the alive-runs arm, sorun-swarmre-keys it to the "list ready tasks" stage and the fault becomes visible to the healer instead of reading as an idle lane. (This alone makes the stall loud, not fixed.)Acceptance criteria
claim-next-task.shclaims the head of a non-empty ready queue rather than emitting[]..sandcastle/tests/claim-next-task-test.shcovers the slow-lister case with the queue non-empty.Matou/dev-factory,FACTORY_REFbumped, re-vendored,check-harness-drift.shgreen.Evidence
Heal bundle
/tmp/matou-heal-Matou-idss.dRFBi5(heal runheal-Matou-idss-1793759807-2474692, signature372652b2f4ef):worker-logs.txt(all four starved worker runs),api-timing.txt(the probe that misses this),runs.json,run-verdict.txt. Latency figures measured live onmatou-dev-server-01, 02:38–02:43 UTC 2026-11-04.Filed by the swarm healer. The triggering
cired itself is product-class and already tracked as #2141 — this ticket is why #2141 has not been claimed.recordingConfigmissing clan.Config.WriteCommunityLanguage (regression of #2122) — go vet fails, ci blocked #2141Close-report — landed (push)
Root cause (confirmed live, not just from the bundle): the host runs
list-ready-tasks.shOUTSIDE the sandbox's 30s prompt-expansion budget and, under the #301 fleet queue, had already chosen this run's ONE ticket (mirrored as/run/host-signals/fleet-pick) — yet the in-sandbox lister (insideclaim-next-task.sh, under the hard-coded 30sPROMPT_EXPANSION_TIMEOUT_MS) re-fetched the WHOLEready-for-agentpage and narrowed to the pick only at the foot. Measured on this forge today: theready-for-agentpage returns 19 full-body issues (~86KB) in 8-22s (variable, query-shape-independent — every variant cost the same). Page + claim walk cannot both fit 30s, so a slow-forge tick blewCLAIM_LISTER_MAX_TIME(12s) and rc 124 was laundered into a graceful[]the prompt renders as an empty ready queue a worker reads as "nothing to do" — the #1425 shape, on the leg #1425 left open. (Note: shape-1 "filter toready-for-agent" in the ticket was already in place — the filter matches nearly the whole DAG, so it does not reduce the cost.)Fix (two shapes, both landed):
list-ready-tasks.sh— when thefleet-picksignal names this run's one ticket,GET /issues/<n>(~2s) instead of the page. The dependency check, the agent-working/standing-drive/rehearsal-marker filters, the open-PR drop, run-landing parity and the fleet-pick narrowing all run UNCHANGED on the 1-element batch, so the OUTPUT is identical to the full-page path (which already narrowed to exactly this pick) — only the fetch cost changes; the standing-drive listing is skipped (ordering a 1-element queue is meaningless). No pick (a host with no fleet view) → the full page, byte-identical to before.claim-next-task.sh— finish #1425 on the lister leg: rc 124 now exits non-zero (no[]), exactly like the alive-runs arm, so a lister that genuinely cannot complete surfaces as a NAMED fault the healer sees, never a silent idle lane.The production scheduler (
swarm.ymlfleet-queue dispatch →SWARM_TICKET, or a fresh fleet-cache head) always sets the pick, so shape 1 covers the live path; shape 2 is the genuine-fault backstop for the rare no-pick/degraded case.Acceptance criteria:
claim-next-task.shclaims the head rather than[].claim-next-task-test.shcovers the slow-lister case with the queue non-empty (now asserts LOUD, not[]).Matou/dev-factory,FACTORY_REFbumped, re-vendored,check-harness-drift.shgreen.Proof:
list-ready-tasks-test.sh(37 cases PASS): fast path GETs/issues/<n>, touches neither the ready-for-agent page nor the standing-drive listing; a gone pick still answers[]and names it.claim-next-task-test.sh(45/0): a non-empty-queue slow lister fails LOUD (non-zero, no[]).gate-lib-test.shPASS; adjacentrun-swarm-ready-list/preflight-swarm/run-swarm-stages/ticket-landingsuites PASS.check-harness-drift.sh: OK — every vendored factory file matches dev-factory@4e8316c2.[#2129]and the single-issue endpoint is hit (not the page); a gone pick returns[]with the named stderr.Commits:
main:389dfd1b(FACTORY_REF4dc855df→4e8316c2;claim-next-task.sh,list-ready-tasks.sh, 2 tests, +gate-lib.sh& its test re-vendored; STATUS.md).backport/idss-2145:4e8316c2(built linearly on6da7606/#2134).Supersedes PR #2144: this bump was built on
6da7606(the #2134 gofmt-scan prune) to keep thebackport/idss-*chain linear, soFACTORY_REFnow includes #2134's fix — i.e. #2144's target6da7606is an ancestor of the new pin. PR #2144 can be closed as included (do not merge it — it would conflict/downgrade).OWED (filed as follow-up): the forward-port of this fix onto dev-factory
main(a reviewed PR — dev-factory isLANDING=pr; the #2053 debt).Ruled by agent under ADR 0174 — veto anytime (revertible:
git revertthe idss commit + reset the backport branch; provable: the vendored red-before-green suites).Close-report (2nd session) — verified landed, finishing the close
A sibling session (
elitebook-distributed-server-03run 3885404) landed this fix and posted the full close-report above at 03:32Z, but its run ended before it could PATCH the ticket closed — so it sat open with a now-staleagent-workingclaim (no swarm runs are running) and the runner relaunched me onto it. The fix is genuinely onmain; I am finishing the close, not re-doing the work.Independently verified on
origin/main(HEAD389dfd1b,FACTORY_REF4e8316c2):claim-next-task.shrc 124 now exits non-zero (no laundered[]) — the #1425 shape closed on the lister-124 leg.list-ready-tasks.shfast path: when/run/host-signals/fleet-picknames this runs ticket,GET /issues/<n>(~2s) replaces the 8-22sready-for-agentpage; all filters/narrowing run unchanged on the 1-element batch; no pick → full page, byte-identical.claim-next-task-test.sh45/0,list-ready-tasks-test.sh37 cases PASS,check-harness-drift.shOK (every vendored file matches dev-factory@4e8316c2).mainis filed as #2147.Note: I had independently prepared a parallel fix (a host→sandbox ready-queue cache read on timeout) on a local dev-factory backport branch before discovering this one had already landed; my push was correctly rejected (non-fast-forward) and I abandoned it unpushed — no double-fix, no force over the landed
backport/idss-2145.Removing the stale
agent-workinglabel (dead claim run 3885404) and closing. Ruled by agent under ADR 0174 — veto anytime (revertible:git revert 389dfd1b+ reset the backport branch; provable: the vendored red-before-green suites).