founding seam + Go: the device plan becomes SEAM TRUTH — the bench saves nothing and invents the machines it shows #1391

Closed
opened 2026-09-11 18:11:44 +00:00 by ben · 3 comments
Owner

Founding's Infrastructure layer now carries the bench — the screen where the
operator drags each chosen service onto the machine that will run it, until the
machine is full (commits 54194917, 37236c88; Ben's rulings 2026-09-11).

The renderer half is built. Nothing behind it is real. The placement lives in
a ref in the component; there is no seam op to save it, no field on the draft to
hold it, and the machines after the gateway are stand-ins the screen mints
itself
(devicePlacement.ts's ADDED table — "Office mini PC", "Whaea's
desktop"). The gateway's own memory is read from the broker's offer preset, not
from the machine.

This ticket makes the plan seam truth.

What exists today (renderer only)

  • app/src/components/founding/FoundingDevicePlacement.vue — the bench, the
    device cards, the 80% fill meter, the minus that returns a pill, the
    "Not enough room" refusal.
  • app/src/components/founding/devicePlacement.ts — usePlacement():
    PlacementDevice{id,name,kind,memMb,gateway,location},
    PlacementService{slug,name,glyph,memMb,pinned}, where (slug → device id),
    the fit gate, and the ADDED stand-in machines this ticket deletes.
  • STEADY_CEILING = 0.8 — DDR 0146's fit gate, hand-copied into founding.

What does not exist

  • No save-placement (or equivalent) in internal/founding/stdio.go.
  • No Draft.Placement in internal/founding/draft.go.
  • No read of the gateway's REAL memory: the screen uses
    GatewayOffer.presetMemMb, which is what was ordered, not what the machine
    reports. On the self-hosted and own-VPS paths there is no offer at all, so the
    ceiling is drawn from nothing.

What this builds

  1. Draft.Placement — the device plan on the draft, persisted and resumed
    with the rest of the founding state document (ADR 0050). At minimum: the
    machines the plan knows about (id, name, kind, the specs they reported) and
    service slug → device id.
  2. save-placement — records the plan, and re-checks the fit gate
    server-side
    : a plan that puts more than 80% of a machine's memory on it is
    refused with the machine and the overage named. The screen prevents it; the
    seam must not trust the screen.
  3. The fit gate stops being hand-copied. STEADY_CEILING and the per-service
    steady footprint must come from the one place the control panel's P4 already
    reads them (internal/provision over internal/catalogue, DDR 0146 /
    ADR 0064). Two copies of "80%" is the bug this bullet prevents.
  4. The gateway's real specs replace the offer preset. Once the gateway has
    paired, the spec gate already knows its CPU/RAM/disk
    (internal/founding/standup.go, the S9 spec-gate pass). The placement screen
    must read THAT. Before pairing — which is where the Infrastructure layer sits
    in the walk today — say so plainly: the rented path may use the offer preset
    labelled as the machine ordered, and the self-hosted/own-VPS paths have no
    number to draw yet. Decide and record which rather than drawing a
    confident ceiling over a guess.
  5. Delete the ADDED stand-ins. Until founding can really add a device, the
    screen shows the gateway alone and says the rest come later; it must not mint
    machines that do not exist. (Really adding one during founding is the
    follow-on named in Out of scope.)

Acceptance

  1. A founding walk that places services, closes the app and reopens it lands back
    on the bench with every service on the machine it was left on — against the
    bridge, not the fake.
  2. save-placement refuses a plan that breaks the 80% ceiling, naming the
    machine and by how much; the draft is unchanged.
  3. save-placement refuses a plan that places a service not in Draft.Services,
    or that leaves a chosen service unplaced (Continue already gates on this in
    the UI — the seam must too).
  4. The front door is on the gateway in every accepted plan and cannot be moved.
  5. A Go test proves founding and internal/provision compute the same ceiling
    and the same per-service footprint for the same catalogue — one source.
  6. No ADDED-style fabricated machine appears anywhere in the shipped screen.

Out of scope

  • Adding a real device during founding (mint an enrollment code, wait for the
    device to join the mesh, read its reported specs, then let the operator place
    onto it). That is Ben's second Infrastructure brief (add-device in
    app/src/lib/foundingStack.ts) and its own ticket.
  • Deploying the plan — its own ticket.
Founding's Infrastructure layer now carries **the bench** — the screen where the operator drags each chosen service onto the machine that will run it, until the machine is full (commits `54194917`, `37236c88`; Ben's rulings 2026-09-11). **The renderer half is built. Nothing behind it is real.** The placement lives in a `ref` in the component; there is no seam op to save it, no field on the draft to hold it, and the machines after the gateway are **stand-ins the screen mints itself** (`devicePlacement.ts`'s `ADDED` table — "Office mini PC", "Whaea's desktop"). The gateway's own memory is read from the broker's *offer preset*, not from the machine. This ticket makes the plan seam truth. ## What exists today (renderer only) - `app/src/components/founding/FoundingDevicePlacement.vue` — the bench, the device cards, the 80% fill meter, the minus that returns a pill, the "Not enough room" refusal. - `app/src/components/founding/devicePlacement.ts` — `usePlacement()`: `PlacementDevice{id,name,kind,memMb,gateway,location}`, `PlacementService{slug,name,glyph,memMb,pinned}`, `where` (slug → device id), the fit gate, and the `ADDED` **stand-in machines this ticket deletes**. - `STEADY_CEILING = 0.8` — DDR 0146's fit gate, hand-copied into founding. ## What does not exist - No `save-placement` (or equivalent) in `internal/founding/stdio.go`. - No `Draft.Placement` in `internal/founding/draft.go`. - No read of the gateway's REAL memory: the screen uses `GatewayOffer.presetMemMb`, which is what was *ordered*, not what the machine reports. On the self-hosted and own-VPS paths there is no offer at all, so the ceiling is drawn from nothing. ## What this builds 1. **`Draft.Placement`** — the device plan on the draft, persisted and resumed with the rest of the founding state document (ADR 0050). At minimum: the machines the plan knows about (id, name, kind, the specs they reported) and `service slug → device id`. 2. **`save-placement`** — records the plan, and **re-checks the fit gate server-side**: a plan that puts more than 80% of a machine's memory on it is refused with the machine and the overage named. The screen prevents it; the seam must not trust the screen. 3. **The fit gate stops being hand-copied.** `STEADY_CEILING` and the per-service steady footprint must come from the one place the control panel's P4 already reads them (`internal/provision` over `internal/catalogue`, DDR 0146 / ADR 0064). Two copies of "80%" is the bug this bullet prevents. 4. **The gateway's real specs replace the offer preset.** Once the gateway has paired, the spec gate already knows its CPU/RAM/disk (`internal/founding/standup.go`, the S9 spec-gate pass). The placement screen must read THAT. Before pairing — which is where the Infrastructure layer sits in the walk today — say so plainly: the rented path may use the offer preset *labelled as the machine ordered*, and the self-hosted/own-VPS paths have no number to draw yet. **Decide and record which** rather than drawing a confident ceiling over a guess. 5. **Delete the `ADDED` stand-ins.** Until founding can really add a device, the screen shows the gateway alone and says the rest come later; it must not mint machines that do not exist. (Really adding one during founding is the follow-on named in Out of scope.) ## Acceptance 1. A founding walk that places services, closes the app and reopens it lands back on the bench with every service on the machine it was left on — against the **bridge**, not the fake. 2. `save-placement` refuses a plan that breaks the 80% ceiling, naming the machine and by how much; the draft is unchanged. 3. `save-placement` refuses a plan that places a service not in `Draft.Services`, or that leaves a chosen service unplaced (Continue already gates on this in the UI — the seam must too). 4. The front door is on the gateway in every accepted plan and cannot be moved. 5. A Go test proves founding and `internal/provision` compute the same ceiling and the same per-service footprint for the same catalogue — one source. 6. No `ADDED`-style fabricated machine appears anywhere in the shipped screen. ## Out of scope - **Adding a real device during founding** (mint an enrollment code, wait for the device to join the mesh, read its reported specs, then let the operator place onto it). That is Ben's second Infrastructure brief (`add-device` in `app/src/lib/foundingStack.ts`) and its own ticket. - Deploying the plan — its own ticket.
Author
Owner

RULED by Ben 2026-09-11 — the ceiling reads what was ORDERED, and says nothing where nothing was bought

Bullet 4 ("the gateway'''s real specs replace the offer preset") is decided:

  • Rented path, before pairing: the bench sizes against the preset the operator
    BOUGHT — AccessChoice.gatewayMemMb (#1393, landed) — and the card must be
    labelled as the machine ordered, never as the machine measured.
  • Self-hosted and own-VPS paths, before pairing: there is no number yet, and
    the screen must say so rather than draw a confident ceiling over a guess. No
    fill meter, no "not enough room" refusal, until a real spec arrives.
  • After pairing the S9 spec gate'''s measured CPU/RAM/disk
    (internal/founding/standup.go) is the truth, and it supersedes the ordered
    number wherever both exist.

Record this on the ticket'''s implementation, not just here — a reader of the
screen must be able to tell an ordered number from a measured one.

## RULED by Ben 2026-09-11 — the ceiling reads what was ORDERED, and says nothing where nothing was bought Bullet 4 ("the gateway'''s real specs replace the offer preset") is decided: - **Rented path, before pairing:** the bench sizes against the preset the operator BOUGHT — `AccessChoice.gatewayMemMb` (#1393, landed) — and the card must be **labelled as the machine ordered**, never as the machine measured. - **Self-hosted and own-VPS paths, before pairing:** there is no number yet, and the screen must say so rather than draw a confident ceiling over a guess. No fill meter, no "not enough room" refusal, until a real spec arrives. - **After pairing** the S9 spec gate'''s measured CPU/RAM/disk (`internal/founding/standup.go`) is the truth, and it supersedes the ordered number wherever both exist. Record this on the ticket'''s implementation, not just here — a reader of the screen must be able to tell an ordered number from a measured one.

swarm-claim host=matou-dev-server-01 run=22172
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=22172 (automated multi-host claim — lowest live claim id works this ticket)

close-report for #1391 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 1391,
  "status": "success",
  "commits": [
    "17e08c846de5a77b201053c4147244e357ed6e32"
  ],
  "changed_files": [
    "STATUS.md",
    "app/src/components/founding/FoundingDevicePlacement.vue",
    "app/src/components/founding/devicePlacement.ts",
    "app/src/components/founding/v2/FoundingV2Journey.vue",
    "app/src/i18n/founding/g10.uipass.en.ts",
    "app/src/i18n/founding/g10.uipass.es.ts",
    "app/src/i18n/founding/g10.uipass.fr.ts",
    "app/src/i18n/founding/g10.uipass.nl.ts",
    "app/src/lib/founding.ts",
    "app/tests/unit/foundingDevicePlacement.test.ts",
    "internal/founding/draft.go",
    "internal/founding/placement.go",
    "internal/founding/placement_test.go",
    "internal/founding/stdio.go",
    "internal/provision/assess.go"
  ],
  "tests": [
    {
      "command": "nix develop .#go-ci --command go test ./...",
      "exit_code": 0
    },
    {
      "command": "CI=true pnpm exec vitest run tests/unit/foundingDevicePlacement.test.ts",
      "exit_code": 0
    },
    {
      "command": "CI=true pnpm exec vue-tsc --noEmit -p tsconfig.json",
      "exit_code": 0
    },
    {
      "command": "CI=true pnpm exec eslint (changed founding files + i18n)",
      "exit_code": 0
    }
  ],
  "criteria": {
    "1: places services, close+reopen lands back on the bench against the bridge": "internal/founding/placement_test.go TestHandle_SavePlacementPersistsAndResumes (save-placement then OpResume off the same MemoryStore restores every device+placement); app foundingDevicePlacement.test.ts remounts with the saved draft.placement and lands empty-bench with all services on the gateway",
    "2: save-placement refuses a >80% plan naming the machine and overage, draft unchanged": "internal/founding/placement.go validatePlacement fit-gate loop + TestHandle_SavePlacementRefusesOverCeiling (a 4GB gateway over 80% is refused, error names machine+overage via mbLabel, baseline draft unchanged on resume)",
    "3: refuses an unchosen service or a chosen service left unplaced": "validatePlacement chosen/placed checks + TestHandle_SavePlacementRefusesUnchosenAndUnplaced",
    "4: front door on the gateway in every accepted plan and cannot be moved": "validatePlacement pins frontDoorSlug to the gateway id + TestHandle_SavePlacementPinsFrontDoorToGateway (front door moved off / no gateway both refused)",
    "5: a Go test proves founding and internal/provision compute the same ceiling and per-service footprint": "internal/provision/assess.go SteadyCeilingBytes is the one source (newGatewayHeadroom reads it); founding PlacementCeilingBytes/PlacementSteadyBytes defer to provision+catalogue; TestPlacement_FitGateIsOneSourceWithProvision asserts equality",
    "6: no ADDED-style fabricated machine appears anywhere in the shipped screen": "devicePlacement.ts ADDED table + addDevice deleted; FoundingDevicePlacement.vue add-a-device button removed, gateway shown alone with a more-later note; foundingDevicePlacement.test.ts asserts one device card (gateway), no add-a-device action, text lacks 'Office mini PC'"
  },
  "summary": "The founding Infrastructure device plan is now seam truth: Draft.Placement + save-placement persist/resume it and re-check the 80% fit gate (one shared source with provision) server-side, and the screen stops minting stand-in machines.",
  "reason": "",
  "blockers": [],
  "no_code_change": ""
}
**close-report** for #1391 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 1391, "status": "success", "commits": [ "17e08c846de5a77b201053c4147244e357ed6e32" ], "changed_files": [ "STATUS.md", "app/src/components/founding/FoundingDevicePlacement.vue", "app/src/components/founding/devicePlacement.ts", "app/src/components/founding/v2/FoundingV2Journey.vue", "app/src/i18n/founding/g10.uipass.en.ts", "app/src/i18n/founding/g10.uipass.es.ts", "app/src/i18n/founding/g10.uipass.fr.ts", "app/src/i18n/founding/g10.uipass.nl.ts", "app/src/lib/founding.ts", "app/tests/unit/foundingDevicePlacement.test.ts", "internal/founding/draft.go", "internal/founding/placement.go", "internal/founding/placement_test.go", "internal/founding/stdio.go", "internal/provision/assess.go" ], "tests": [ { "command": "nix develop .#go-ci --command go test ./...", "exit_code": 0 }, { "command": "CI=true pnpm exec vitest run tests/unit/foundingDevicePlacement.test.ts", "exit_code": 0 }, { "command": "CI=true pnpm exec vue-tsc --noEmit -p tsconfig.json", "exit_code": 0 }, { "command": "CI=true pnpm exec eslint (changed founding files + i18n)", "exit_code": 0 } ], "criteria": { "1: places services, close+reopen lands back on the bench against the bridge": "internal/founding/placement_test.go TestHandle_SavePlacementPersistsAndResumes (save-placement then OpResume off the same MemoryStore restores every device+placement); app foundingDevicePlacement.test.ts remounts with the saved draft.placement and lands empty-bench with all services on the gateway", "2: save-placement refuses a >80% plan naming the machine and overage, draft unchanged": "internal/founding/placement.go validatePlacement fit-gate loop + TestHandle_SavePlacementRefusesOverCeiling (a 4GB gateway over 80% is refused, error names machine+overage via mbLabel, baseline draft unchanged on resume)", "3: refuses an unchosen service or a chosen service left unplaced": "validatePlacement chosen/placed checks + TestHandle_SavePlacementRefusesUnchosenAndUnplaced", "4: front door on the gateway in every accepted plan and cannot be moved": "validatePlacement pins frontDoorSlug to the gateway id + TestHandle_SavePlacementPinsFrontDoorToGateway (front door moved off / no gateway both refused)", "5: a Go test proves founding and internal/provision compute the same ceiling and per-service footprint": "internal/provision/assess.go SteadyCeilingBytes is the one source (newGatewayHeadroom reads it); founding PlacementCeilingBytes/PlacementSteadyBytes defer to provision+catalogue; TestPlacement_FitGateIsOneSourceWithProvision asserts equality", "6: no ADDED-style fabricated machine appears anywhere in the shipped screen": "devicePlacement.ts ADDED table + addDevice deleted; FoundingDevicePlacement.vue add-a-device button removed, gateway shown alone with a more-later note; foundingDevicePlacement.test.ts asserts one device card (gateway), no add-a-device action, text lacks 'Office mini PC'" }, "summary": "The founding Infrastructure device plan is now seam truth: Draft.Placement + save-placement persist/resume it and re-check the 80% fit gate (one shared source with provision) server-side, and the screen stops minting stand-in machines.", "reason": "", "blockers": [], "no_code_change": "" } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#1391
No description provided.