main is red on gofmt: compose.go carries formatting debt (f291b547) and the host push path has no Go gate to catch it #1458
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#1458
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?
Filed by the swarm healer (heal run
heal-Matou-idss-1789242959-2112217, signaturedb456344a32d, run https://git.matou.nz/Matou/idss/actions/runs/22767).The red
scripts/seam-smoke.shstage "Go: gofmt (tabs) — no formatting debt (#344)" fails onmain:Reproduced by the healer against
origin/main(tip713f5ccb) in a fresh clone:The debt is one struct-field alignment block in
type composed struct(~line 793):Fix:
gofmt -w control-plane/cmd/control-plane/compose.go. Whitespace only, no semantics.Where it came from
git bisectover the file across recentmaincommits (healer rangofmt -lon each blob):8b5051c5…c3181f6df291b547sandcastle: #1429 — the two Take-a-copy exports get a packer713f5ccb(tip)f291b547is a single-parent commit (not a merge). It added thestackExports controlapi.StackExportServicefield and hand-realignedpvto the new column width but notup/mem—gofmtwas never run.Why the gate did not stop it
.sandcastle/git-hooks/pre-pushruns three gates. Gate 3 — the Go language gate (gate.sh --prepush, which is the only path that runsgofmt -l) — is sandbox-only:f291b547was authored byMatou Swarm (session-runner@elitebook-distributed-server-03)— a session-runner host push, which takes the--prepush-tsbranch. TypeScript is gated on host pushes; Go is not.That is exactly the hole the hook's own comment declares closed:
This incident falsifies that premise. It is the Go twin of #1252 (the TS hole closed by Gate 2 for the same reason: the break reached
mainthrough the host reconcile push, not the sandbox).The #198 rationale for keeping Go off the host push still holds for the heavy stages —
nix develop .#go-ci+ build/vet/test/golangci-lint would stall every reconcile push. Butgofmt -lis none of that: it is a pure parse+print, no nix shell, no compile, sub-second on this tree. A gofmt-only host-side sub-gate (fires only when the pushed range touches*.go, matching Gate 2's shape) closes this class at negligible cost..sandcastle/git-hooks/pre-pushand.sandcastle/gate-lib.share both inFACTORY_MANIFEST(ADR 0180) — editing them here is blocked by Gate 1 and reds the seam drift stage. The gate change must land inMatou/dev-factory, thenFACTORY_REFbumped and re-vendored (onboarding/onboard.sh vendor). The healer did not attempt it.Asks
gofmt -w control-plane/cmd/control-plane/compose.goand push — unblocks the seam/ci Go stage onmain(blocking; every commit stays red until this lands).pre-push(Gate 3b), via the factory →FACTORY_REFbump → re-vendor route. Sibling of #1252 for Go; references #198, #344.Healer scope note
The healer classified this product-class for the file itself (
control-plane/source) and so did not edit it — charter forbids product code changes. The gate gap is harness-class but lives in factory-vendored files, which the charter's fresh-clone repair path cannot touch without tripping the drift gate.Sandcastle iteration (run 22605) — handing to a session.
Ask 1 is already resolved on
mainThe gofmt debt in
control-plane/cmd/control-plane/compose.gowas cleared byf2f71a52(sandcastle: #1416 — clear pre-existing #1429 Go-gate debt blocking the shared pre-push gate), which rangofmt -won the file (theup/memstruct-field alignment) plus a revive doc-comment onstackexport. Verified just now against the currentmaintip (061a3d4b) innix develop .#go-ci:So the blocking Go seam/ci stage on
mainis green — no product-code change is left for this ticket.Ask 2 (close the class) is protected-path + factory work — not a Sandcastle slice
Adding the Gate 3b gofmt-only host-side sub-gate means editing
.sandcastle/git-hooks/pre-pushand.sandcastle/gate-lib.sh. Both are FACTORY_MANIFEST-vendored (ADR 0180) and protected paths (#445). A Sandcastle agent cannot touch them: the change must land inMatou/dev-factory, thenFACTORY_REFis bumped and re-vendored (onboarding/onboard.sh vendor), exactly as the healer noted. Editing them in-repo would trip the drift gate + protected-paths guard.Per rule 9 / ADR 0174 / #445, a protected-
.sandcastle/machinery change needs an interactive session's standing, not a swarm worker. This ticket already fully specifies that change (sibling of #1252 for Go; references #198, #344), so rather than file a duplicate I'm relabelling #1458 itselfready-for-session.Residue for the session: implement the gofmt-only Gate 3b on the host push path of
pre-pushinMatou/dev-factory(fires only when the pushed range touches*.go, mirroring Gate 2's shape — puregofmt -l, no nix shell, no build), then bumpFACTORY_REFhere and re-vendor.Removing
ready-for-agent, addingready-for-session; releasing the run-22605 claim.Close-report — landed & proven (agent under ADR 0174)
Both asks are done.
Ask 1 (the red — gofmt debt on
compose.go): already cleared before this session, by #1416 (f2f71a52) — "clear pre-existing #1429 Go-gate debt blocking the shared pre-push gate". Verified on currentmain(tip70b3d228):gofmt -l . | grep -v '^node_modules/'is empty; theseam-smoke.sh#344 gofmt stage is green. No further file fix was needed.Ask 2 (close the class — a host-side gofmt sub-gate): landed. This is the Go twin of #1252's TS hole (Gate 2). Gate 3 (the full Go seam) stays sandbox-only (#198), but
gofmt -lis a pure parse+print — no nix, no compile, sub-second — so it costs nothing to run on every host push.Because
gate-lib.sh/gate.sh/git-hooks/pre-pushare FACTORY_MANIFEST-vendored (ADR 0180), the change landed upstream inMatou/dev-factory(9aaac50169d0cd2f0c0e83b7e14e6b119da74fd9) and was re-vendored here via the canonical tool (onboarding/onboard.sh vendor), bumpingFACTORY_REF72496a4→9aaac50:gate_gofmt_stage/gate_gofmt_default_cmd— run baregofmt -l(no nix); fail closed when neitherGATE_GOFMT_CMDnor agofmton PATH resolves, exactly as the TS gate fails closed (#1252 — a blocked push beats a red main).GATE_GOFMT_CMDis the env override + offline test seam;gate_rungains ago_tierarg (full= the Go seam,gofmt= the cheap host tier); theonlyfilter is unchanged;gate.sh --prepush-hostruns the TS lint gate plus the gofmt-only Go gate; the pre-push hook now runs--prepush-hoston every host push (--prepush-tskept as a back-compat alias). Fires only when the pushed range touches Go, matching Gate 2's shape.Proof:
.sandcastle/tests/gate-lib-test.sh— 34/34 (7 new Gate 3b checks, including the real bare-gofmtpath: a well-formatted tree passes,gofmtdebt fails, andgo_tier=gofmtruns the gofmt stage — never the full seam);.sandcastle/tests/prepush-drift-gate-test.sh— PASS;bash -nclean on all touched scripts;check-harness-drift.sh— OK (every vendored file matches9aaac50);gate: no gated language touched — nothing to check) and the #932 drift gate (manifest paths touched → drift confirmed clean).Commits: dev-factory
9aaac50; idss70b3d228(onmain). STATUS.md updated in the idss commit.Ruled by agent under ADR 0174 — veto anytime. Two-way door throughout: every change is revertible (a
FACTORY_REFrevert + re-vendor) and provable (gate-lib-test). No one-way door was touched — no credentials, no security-posture widening, no data destruction, no non-routine spend.%%in a .mermaid source only reds in CI (GOTCHAS #143, 2nd time) #2068defer res.Body.Close()in internal/controlapi/updates_i18n_seam_test.go:47 (from #2129/6caf5c25) #2153