updates-open: the Updates surface's empty sections arrive as JSON null, the screen reads .length off one, and the whole P4b surface falls to the display-fault boundary #1630
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#1630
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 failure
The
updates-openleg of the #1618 Updates-lane proof drive (run20260919T135211Z,artifacts/legs.json—founding-prefixgreen,operator-sessiongreen,updates-openred after 30.5 s) timed out on:at
app/tests/e2e/fixtures/updatesDrive.ts:44-45. This is a NEW fault behind the same signature (7e8181a118ff): the previous heal (6bfde109) and the human fix (0f141763) repaired the route owner, and the drive's trace confirms the drill-in assertion one line earlier now PASSES —[data-field="updates-surface-drill-in"]was visible at monotonic 721234.9.The evidence
artifacts/live-box.jsonwas absent — the droplet was already torn down, so I read the box's own words out of the harvested Playwright trace (artifacts/journey.updates-…/trace.zip), which carries the captured request/response bodies verbatim.The leg's accessibility snapshot (
error-context.md) shows what stood where the surface should be:The page console names the throw, 0.5 s after the surface's two reads resolved (721245.3, immediately after
GET /api/v1/updatesat 721230.9 andGET /api/v1/updates/rolloutat 721244.8):And the box's own
GET /api/v1/updates— 200,x-idss-composition: whole— says why, verbatim:(
GET /api/v1/updates/rolloutanswered404 {"code":"no_rollout","message":"no rollout has run"}— that one is handled correctly bynullOn404indashboard/src/lib/api/updatesClient.ts:44-47,110-116, and is not the fault.)The defect
internal/update/surface.go:94-95declared the four sections as nil slices:and appended per group over
s.active. A group with no members stays nil, andencoding/jsonwrites a nil slice asnull, never[].internal/controlapi/updates.go:64marshalssvc.State()straight out.The surface contract declares all four as arrays —
dashboard/src/lib/updates.ts:175-179(pending: ReleaseView[]…) — andHttpUpdatesClient.state()only camelizes the wire (updatesClient.ts:61-63), soUpdatesScreen.vuereadssurface.pending.lengthdirectly at line 44 (and:76,:100,:118for the other three). The firstnullthrows in render, Vue unmounts the subtree, andSurfaceErrorBoundaryswallows the whole P4b surface — pending releases, review, policy, the maintenance window, rollout. A community at rest, or one with only ONE kind of release outstanding, cannot open Updates at all.Nothing caught it because every unit test drives the fakes in
updates.ts(restingSurface/busySurface), which build[]by hand and never marshal.Suspected layer
The producer:
internal/update/Orchestrator.State(). Fixed there so every consumer (the panel, and the drive's own API probes) gets the shape the contract declares. GOTCHAS #269 records the hazard.Proposed ruling (Ruled by the healer under ADR 0174 — veto anytime)
Two-way door. The change is six lines in one function — the four sections are composed
[]ReleaseView{}/[]QuarantineView{}instead ofvar … []ReleaseView; reverting is a one-hunkgit revertwith no migration, no stored state and no other call site (grepped: nothing reads these fields for nil). It is a mechanical repair, not a design decision: every section already renders behindv-if="…length", so an empty list and a nil slice draw the IDENTICAL screen — no message, route, default, secret or posture changes, and nothing a community sees differs except that the surface now renders at all instead of falling to the error boundary. The code is made to do what it already declared it does (Pending []ReleaseView \json:"pending"`againstpending: ReleaseView[]). Proven here red-first byinternal/update/surface_test.go:TestState_EmptySectionsMarshalAsListsNotNullmarshalsState()and failed with"pending" must marshal as an empty list, got null— the box's exact shape — and passes after;TestState_PopulatedSectionLeavesTheOthersAsListsseeds one automatic release (the drive's own founding shape) and proves the other three stay lists.internal/controlapi's HTTP integration suite over the sameState()` stays green. Built on the workstation (never the drive host) and closed through the close-report gate — the same gate a swarm worker passes.drive
20260919T135211Zred atupdates-open(sig 7e8181a118ff) — self-fixed on the fast lane, commit1035817588cc14a53e9ad6245dc69fafb80ef5d4; checks: Targeted:go test ./internal/update -run 'TestState_EmptySectionsMarshalAsListsNotNull|TestState_PopulatedSectionLeavesTheOthersAsLists'— RED first (surface_test.go:34: "pending" must marshal as an empty list, got null), GREEN after (ok git.matou.nz/Matou/idss/internal/update 0.005s). Package:go test ./internal/update/...— ok. Consumer package:go test ./internal/controlapi/...— ok (1.039s).gofmt -l internal/update/clean,go vet ./internal/update/clean.. evidence:/home/swarm/swarm/Matou/idss/test-results/private-path/20260919T135211Zon matou-workstation.close-report for #1630 — status
success✅ close-report gates passed — every claim verified against main; issue closed.
envelope