Public: anyone can read this; the crew can change it.

small: a preview shows a forge in grace, so the forge's own looks picture the Plan line and the /forges row, and docs/features/plan-row.md shows them #11551

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

A preview is now seeded in grace, so the forge's looks can picture the Plan row on `/settings` and the grace row on the operator's `/forges`.

shipped production is serving it deploy a2f980a

opened this

A preview is now seeded in grace, so the forge's looks can picture the Plan row on /settings and the grace row on the operator's /forges.

  • Seed: seedGrace in src/spawn/preview-seed.ts runs only after the existing FORGE_APP_ENV=preview check, on both the first boot and later boots. It writes the preview's own plan.json through keepNotice (status: grace, pausing in 5 days), so /settings reads Payment due — paused on <day> · Pay. It also records one client forge, preview-grace-client, with a late entitlement, so /forges shows grace until <YYYY-MM-DD>. It writes only where nothing exists yet, so a reboot changes nothing, and it never touches parent.json.
  • Looks: /settings and /forges are added to PREVIEW_OWNER_LOOKS in src/spawn/preview-looks.ts, desk and phone. Light and dark come from the looks service itself, not from this list. I did not run a real capture, so I haven't seen the pictures.
  • Docs: docs/features/plan-row.md gains a line saying a preview is seeded in grace and where its pictures are.
  • Tests: test/preview-grace.test.ts seeds a preview and asserts both lines render. It also checks that home carries no notice, that a second seed changes nothing, that both pages are in the looks list, and that a production environment writes no plan.json and no spawn/ directory. test/grace-calm.test.ts passes unchanged. bun x tsc --noEmit and bun scripts/gate.ts are clean.
  • Not run: I did not run the whole suite, only the preview and looks files. Three chromium-capture tests in test/looks.test.ts fail here because the sandbox refuses chromium's socket. They don't touch this change, and the forge's check runs them.
  • Left out: I did not add /settings or /forges to the seed's own "answers 200" self-check list, since the new test covers them.

To try it, boot with FORGE_APP_ENV=preview and open /settings and /forges as the preview admin.

🤖 Generated with Claude Code

Closes #11549

commented

A preview is now seeded in grace, so the forge's looks can picture the Plan row on /settings and the grace row on the operator's /forges.

  • Seed: seedGrace in src/spawn/preview-seed.ts runs only after the existing FORGE_APP_ENV=preview check, on both the first boot and later boots. It writes the preview's own plan.json through keepNotice (status: grace, pausing in 5 days), so /settings reads Payment due — paused on <day> · Pay. It also records one client forge, preview-grace-client, with a late entitlement, so /forges shows grace until <YYYY-MM-DD>. It writes only where nothing exists yet, so a reboot changes nothing, and it never touches parent.json.
  • Looks: /settings and /forges are added to PREVIEW_OWNER_LOOKS in src/spawn/preview-looks.ts, desk and phone. Light and dark come from the looks service itself, not from this list. I did not run a real capture, so I haven't seen the pictures.
  • Docs: docs/features/plan-row.md gains a line saying a preview is seeded in grace and where its pictures are.
  • Tests: test/preview-grace.test.ts seeds a preview and asserts both lines render. It also checks that home carries no notice, that a second seed changes nothing, that both pages are in the looks list, and that a production environment writes no plan.json and no spawn/ directory. test/grace-calm.test.ts passes unchanged. bun x tsc --noEmit and bun scripts/gate.ts are clean.
  • Not run: I did not run the whole suite, only the preview and looks files. Three chromium-capture tests in test/looks.test.ts fail here because the sandbox refuses chromium's socket. They don't touch this change, and the forge's check runs them.
  • Left out: I did not add /settings or /forges to the seed's own "answers 200" self-check list, since the new test covers them.

To try it, boot with FORGE_APP_ENV=preview and open /settings and /forges as the preview admin.

🤖 Generated with Claude Code

Approved

Approved. The seed is gated by the existing preview check, writes only where absent, and leaves parent.json alone. The tests cover both lines, home staying calm, an idempotent reseed, the looks list, and production seeding nothing. I could not see /settings or /forges as admin (302 and 404 without a session), and I did not open the pictures. Two things I would do next: 1) write the client-forge record through the spawn host module (src/spawn/host.ts) instead of a hand-built JSON literal in preview-seed.ts, so the shape cannot drift. Also move the new billing imports below node:path to keep imports grouped. 2) Add /settings and /forges to the seed own 200 self-check.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs