Founding gateway size: stop silently defaulting a missing preset to the cheapest box, and keep the order+result past hand-off (follow-up from #1777) #1783
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#1783
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?
Follow-up from #1777 (which fixed the core bug: the "Upgrade to 8 GB" bench button now records the order through the
resize-gatewayseam, a placement plan that disagrees with the order can't commit, and a rented box that doesn't match the order fails loud). Two of #1777's five asks were deferred there as larger-than-the-bug changes and are tracked here.Ask 4 (second half) — stop silently defaulting a missing preset to the cheapest box
#1777 closed the new surface:
ResizeGatewayrefuses an empty pick outright. But the two documented empty→default fallbacks the ticket named still stand:resolvePreset(internal/founding/access.go) — an empty pick takesoff.Presets[0](the cheapest).Rentals.resolvePreset(broker/internal/broker/rentals.go) — an empty preset takescfg.Size(the default).These are load-bearing:
RentServerdocuments "empty = the offer's default", the fake broker mirrors it, and many seam tests driveRentRequest{}expecting the default. Making "empty where a pick was expected" a fault means reworking that contract acrossRentServer, the fake, the broker, and the tests — a design change, not a one-liner. The S4a rent card already seeds the first preset, so an empty-with-presets pick does not occur from the UI today; this is defence-in-depth against a future caller.Ask 5 — keep the order AND the result on the community after hand-off
"I picked 8 GB and got 4 GB" is exactly the question an operator asks once founding is over — which is precisely when founding throws the evidence away (
founding-state.jsonis deleted at hand-off). The order (recorded byresize-gateway) and the provisioned result should survive onto the community's durable config so the answer is recoverable post-founding. This touches the hand-off/scrub subsystem, not the founding seam.Found while working #1777.
Triage:
enhancement+ready-for-agentCategory —
enhancement. Neither ask is a live defect. #1777 already closed the reported bug (the "Upgrade to 8 GB" bench records the order throughresize-gateway, a disagreeing plan can't commit, a mismatched box fails loud). Ask 4's remaining fallbacks are unreachable from the UI today ("the S4a rent card already seeds the first preset"), so this is defence-in-depth; Ask 5 is a durability improvement. Verified both are real and unimplemented:resolvePreset(internal/founding/access.go:549) still returnsoff.Presets[0]— the cheapest — on an empty pick.Rentals.resolvePreset(broker/internal/broker/rentals.go:362,523) still takescfg.Size; the "empty pick takes the broker's default" contract is documented atrentals.go:619,644and driven byRentRequest{}in the seam tests.internal/founding/handoff.go.Ruled by agent under ADR 0174 — veto anytime
The ruling (Ask 4's direction): make "empty where a pick was expected" a fault at both
resolvePresetsites, mirroring #1777'sResizeGateway(which already refuses an empty pick). Rework the "empty = the offer's default" contract acrossRentServer, the fake broker, and the seam tests so the default is expressed by an explicit default-preset request, not by an absent one.Why it is a two-way door: the change is revertible by a later commit/label change, and it is proven by the existing broker/founding seam tests (the tests that today drive
RentRequest{}expecting the default become the tests that prove the new fault contract). It touches no personal credential, no security-posture widening, no member-facing trust accept, no data destruction, and no non-routine spend — so it is off the one-way-door list.What proves it: red-first seam tests at both sites (empty-with-presets → fault; an explicit default-preset request → the default box), the reworked fake broker, and the full
internal/founding+brokerGo suites green.Agent brief
Goal. Close the two deferred halves of #1777: (4) stop silently defaulting a missing preset to the cheapest box, and (5) keep the order + the provisioned result on the community past hand-off.
Ask 4 — empty pick is a fault.
internal/founding/access.goresolvePreset(line 549): an empty pick with priced presets present must return an error, notoff.Presets[0]. Preserve the genuine no-priced-presets read-only path.broker/internal/broker/rentals.goresolvePreset(lines 362/523): rework the "empty =cfg.Size" fallback (documented 619/644) so the offer default is requested explicitly. UpdateRentServer's contract doc, the fake broker (cmd/rehearsal-broker/ the founding test fakes), and every seam test that drivesRentRequest{}expecting a silent default.ResizeGatewayempty-refusal as the reference shape for the fault.Ask 5 — order + result survive hand-off.
resize-gatewayontoAccess; the provisioned result is whatprovisionverified. Persist both onto the community's durable config so "I picked 8 GB and got 4 GB" is answerable afterfounding-state.jsonis scrubbed (internal/founding/handoff.go).Acceptance.
resolvePresetsites; an explicit default-preset request still yields the default box.RentRequest{}-driven seam tests express the default explicitly and pass.internal/founding+brokerGo suites green; gofmt/vet/golangci-lint clean.Note: broker changes land in a deployed-service tree (
broker/**); the deploy rail (deploy-pending) handles installation post-merge — no live-infra work in this ticket.Relates to #1777, #1393, #1375; ADR 0047/0100/0189, DDR 0237/0240/0241, ADR 0174.
swarm-claim host=bens-mac-04 run=30980
(automated multi-host claim — lowest live claim id works this ticket)
close-report for #1783 — status
success⛔ close-report gates REFUSED this close — the following claims did not verify:
envelope
close-report for #1783 — status
success✅ close-report gates passed — every claim verified against main; issue closed.
envelope