harness: a transient Forgejo 5xx on the factory fetch reds the seam at stage one — check-harness-drift.sh has no TRANSPORT outcome and no retry (#1359 class, second surface) #1394
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#1394
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?
Symptom
ci run 21982 (seam on
d65ff9f6, started 2026-09-11T19:58:53Z — 5 s after the push) went red at the FIRST stage:Nothing had drifted.
d65ff9f6is an ADR-only commit (CONTEXT.md,STATUS.md, fourdocs/adr/*, one flow) — it touches no.sandcastle/file, so the vendored tree it gated was byte-identical toe9916f61's, whose own seam had just passed. Re-runningbash .sandcastle/check-harness-drift.shon the same tree now:OK — every vendored factory file matches …@6ea8ba0400e2.The healer's own probe in the same minute recorded
api_seconds=timeout(35 s ceiling onactions/tasks?limit=1&page=1) and an emptyworkflow_runs. That endpoint answers in ~1.1 s now, andtriage/publishon the same SHA went green at 20:04–20:05. A short, server-side Forgejo wobble;git.matou.nzresolves to 143.198.134.168 — off this host, so no runner-side cause.The durable gap
.sandcastle/check-harness-drift.shhas exactly two outcomes: drift or OK. It has none for "I could not reach the factory." Its fetch is a bare shallow-by-SHA attempt with stderr silenced, falling back to an un-retriedgit clone:One 5xx therefore reds the whole seam at stage one with exit 128, blocks
publish, and burns a healer investigation on a fault that was never in this repo.This is the same class as #1359 / GOTCHAS #217 — "a probe that cannot reach the server has not obtained a verdict" — at a second surface. #1359 gave
forgejo_issue_write_probeexponential backoff (FORGEJO_PROBE_RETRIES=3,FORGEJO_PROBE_BACKOFF=2) and taught a sustained outage to sayTRANSPORT, not a permission verdict. The git-transport half of the same rule was never applied.What to do
check-harness-drift.shis vendored (FACTORY_MANIFESTline 9) and owned byMatou/dev-factory— it must NOT be edited here. Land it there, bumpFACTORY_REF, re-vendor (the #891/#931 pattern):exit 128that reads as a harness fault. Decide whether that stays fatal to the seam or degrades to a loud warning — the gate's job is to catch a hand-edited vendored file, and it cannot do that job blind either way.tests/check-harness-drift-test.sh: rides out a transient 5xx; a sustained outage is named TRANSPORT and never claims drift.Note while you are there:
FACTORY_REFis 1 commit behinddev-factorymain.Evidence
run-verdict.txt,api-timing.txt(api_seconds=timeout),runs.json({"workflow_runs":[]}) in/tmp/matou-heal-Matou-idss.d9VTRD411fb54f2ace, heal runheal-Matou-idss-1789156807-1764127This ticket is a protected-path machinery change and cannot be completed by a Sandcastle worker — handing off to
ready-for-session(ADR 0174 / #445).Why a swarm worker cannot land this
Every substantive step of the "What to do" list writes to a path this repo fingerprints as protected (
protected-paths-lib.sh:PP_PROTECTED_DIRS_DEFAULT=".sandcastle .forgejo"):check-harness-drift.shis vendored under.sandcastle/(FACTORY_MANIFESTline 9) — protected. The issue itself says it "must NOT be edited here."Matou/dev-factory— a different repo the swarm worktree does not own..sandcastle/FACTORY_REFand re-vendoring.sandcastle/check-harness-drift.shboth mutate.sandcastle/— protected.dev-factory’s owntests/check-harness-drift-test.shalongside the fix.The #445 before/after tree-fingerprint attributes any
.sandcastle/change to the worker, rolls it back, and reds the run — so none of this is landable here. Per Rule 9 andPP_ESCAPE_PATH, a protected.sandcastle/path per #445 "needs an interactive session's standing, not Ben."Nothing in this ticket lands in a non-protected path of
Matou/idss, so there is no partial slice a worker can ship. Re-labelling this issue itself (rather than filing a duplicate)ready-for-session: it already describes the machinery change comprehensively.What a session must do (from the issue, unchanged)
Matou/dev-factory, wrap thecheck-harness-drift.shfetch/clone in the #52/#1359 retry posture (3 attempts, bounded exponential backoff) and add a third TRANSPORT outcome distinct from drift/OK.dev-factorytests/check-harness-drift-test.sh(rides out a transient 5xx; a sustained outage is named TRANSPORT and never claims drift).Matou/idssvia the #891/#931 pattern and bump.sandcastle/FACTORY_REF(currently6ea8ba04, 1 commit behind dev-factory main).Why human/session
Editing
.sandcastle/(protected machinery, #445) and pushing toMatou/dev-factoryboth require standing a swarm worker does not have.Close-report — landed, proven (ADR 0174, two-way doors only)
Ruled by agent under ADR 0174 — veto anytime. The durable gap is closed at the source and re-vendored here.
What landed
The gap was the git-transport half of #1359's rule (a probe that cannot reach the server has not obtained a verdict, GOTCHAS #217), never applied to
check-harness-drift.sh's bare, un-retried fetch/clone. Fixed inMatou/dev-factory(the file is vendored,FACTORY_MANIFESTline 9 — must not be edited here) and re-vendored, the #891/#931 pattern:FACTORY_FETCH_RETRIES=3,FACTORY_FETCH_BACKOFF=2(exponential), each attempt bounded by git's own transport. A transient blip is ridden out.could not reach … the factory was unreachable, so drift was NOT read here), never a bareexit 128and never a falseDRIFT. Ruling on fatal-vs-warn: it stays fatal. Greening on an unreachable factory would be exactly the GOTCHAS #30 hazard — a guard that could not reach the code it guards must never be mistaken for a clean result. The retry rides out the transient case that actually happened (ci run 21982 self-healed within a minute); the sustained case reds honestly but legibly, soseam-smoke.sh's verdict + the healer signature read factory unreachable, not drift, and no healer investigation is burned on an external fault.tests/check-harness-drift-test.sh+2 (14 total), a fake flakygit503-ing the first N network ops against the same local factory remote: T9 proves attempt 1's fetch+clone blip is ridden out to a greenOK; T10 proves a sustained outage exits 3, names TRANSPORT, never greens, and never claims DRIFT.FACTORY_REF6ea8ba0→dcda962(dev-factory main tip), which also lands the intervening #135 healer-evidence host-stamping (heal.sh/run-swarm.sh+ their tests) — expected pin-bump behaviour.Commits
Matou/dev-factory@dcda962— the harness fix + its test (pushed to dev-factorymain).Matou/idss@9d5bd2b0— re-vendor atdcda962+ STATUS.md.Proof
bash .sandcastle/check-harness-drift.sh— GREEN against the new pin (OK — every vendored factory file matches …@dcda962).tests/check-harness-drift-test.sh— 14/14 (12 prior + T9/T10), both in the dev-factory tree and re-run in idss.tests/run-swarm-stages-test.sh— GREEN (pulled-forward #135).prepush-drift-gate-test.sh/gate-lib-test.sh— GREEN.dcda962.Note (pre-existing, out of scope — not a regression)
tests/heal-test.sh's #123 scenario fails when run from a consumer.sandcastle/tests/checkout: it hard-codesHEAL_PROMPT_FILE="$here/../.sandcastle/heal-prompt.md", which resolves only in dev-factory's own self-vendored layout (in a consumer it points at the nonexistent.sandcastle/.sandcastle/heal-prompt.md). This fails identically on idss HEAD before the re-vendor, is not referenced by any idss workflow (idss's seam runs onlycheck-harness-drift.sh), and is proven green in dev-factory's own CI. Filing a follow-up against dev-factory for the vendored-test path portability rather than touching it here.Doors
All two-way (ADR 0174): a revertible dev-factory commit proven offline, a revertible
FACTORY_REFbump proven by the drift check. No personal credentials, no security widening, no data destruction, no non-routine spend.Follow-up for the pre-existing heal-test path portability noted above filed as Matou/dev-factory#139 (not a #1394 regression).