Public: anyone can read this; the crew can change it.
small: every container, project and machine shows one of five states, each a colour with a word #18633
Merged 48m ago, live in production
Every container, machine and project on Infrastructure now shows one of five states: Running, Starting, Needs attention, Stopped or Can't tell. Each state is a coloured badge with its word. I ran the container, cloud-tree, infra and new five-state tests, plus the rest of the files listed below.
-
Reviews
Changes requested — before the latest pushThe mapping module and its test are good: one function, tables per raw state, the word always present. Four things to fix in one round. First: a failing machine or container row now draws a primary (accent) button per row, so a page with several broken rows has several accents (principle 5); make the fix a ghost/sm button. Second: the container pane already has Restart/Start/Stop in
game?.power, andfiveBlockadds a second Restart/Start to the same head, so there are two ways to do one thing; drop one (reuse the power control or drop the fix from the pane). Third: box 3 is not met for a project: its reason says what fails, but no button is drawn (() => undefined), so a project that Needs attention has no fix. Draw the worst container's fix on the project block (posting to that container's route), or state why a project cannot. Fourth:restartingmaps to Starting, so a crash loop never shows Needs attention; map it to attention with Restart/Stop reason, or give a crash loop its own rule. Also: the docs section in infra.md has a doubled blank line before the heading, and the preview was not booted by the builder: check /infra at 360px, the machine row now stacks badge, reason, button, ends and agent text in one meta row.ApprovedAll earlier asks are met: fix buttons are ghost/sm (no accent per row), the pane that already draws the power control shows the reason only (one way to restart), a project offers its worst container's fix through the existing guarded POST /infra/container route, a crash loop is Needs attention with Restart, the docs name the terminal keys, and a wrap rule keeps the meta row on a phone. Preview answers 200. Next two things: (1) Non-blocking: move /games server rows onto fiveOf so no page keeps its own state wording. (2) Non-blocking: look at /infra at 360px by eye once, since the wrap rule was not checked in a browser.
-
Checks
waiting merged; waiting for the forge to restart on it deploy 4794e6b
-
History
- Five states: fixes are ghost buttons, one fix per container, a project offers its worst container's fix, a crash loop needs attention (#18617) b4c67ed
- Rewrap comments (#18617) 37331a0
- Every container, machine and project on Infrastructure shows one of five states, each a colour with a word (#18617) da129c9
- On a repository's crew page, adding a member to a slot redraws in place without losing the scroll, and a member is one line with its description on demand (#18542) 5a6b787
- Small work starts on the smallest model for one measured week, and the forge keeps it only if a landed change costs less (#18562) 1b59e04
- The in-place form list shrinks: the first twelve entries of test/in-place-offenders.json submit in place and leave the list (#18530) a7cf471
- Telling the crew about an issue titled as a pillar umbrella sends no builder to it (#18572) e9eb675
- A provider that answers out of credit or at its limit pauses the queue for that account instead of spending retries (#18560) 7c319cb
- A pull that changes an MCP tool's schema also runs the Talk list ceiling (mcp… (#18577) 6f75def
- On /infra a machine opens to its projects and containers, and a container opens to live logs, stats, restart and stop (#18537) 5b0814e
- Owner decision: where do a pull's checks run on a Mac, away from the machine that holds signing keys (#18543) 5061124
- The Minecraft kind's console adapter answers /forge in game in under 300 ms, in rich text, and keeps a conversation (#18533) b9e784c
- One People page at /settings/people: Invite on top, a person is one row of what they can do, each with Remove (#18514) d9f5ff1
- An account's link to an outside identity is one table keyed by kind, with a prover per kind (#18536) 718f6d1
- Opening an invite link signs the person in, proves the account and applies the bundle, in every sign-up mode including closed (#18520) f42bd09
- forge.json declares jobs: steps, needs (macos, xcode, docker), on (pull, land) and secrets, read and validated at the boundary (#18512) 85e7b4f
- Lending speaks the versioned agent protocol, and each machine's page shows when it last used the old sync route (#18521) 7db7ea2
- A pull that changes an MCP tool's schema runs mcp-size.test.ts in its fast check (#18529) 9b4b38b
- may() is the only permission check: every remaining helper beside it is deleted, and a test fails if one returns (#18498) ad5d09a
- A test fails a new terminal screen for a thing that already has a web page, and today's screens are the only ones allowed (#18527) a068c28
Every container, machine and project on Infrastructure now shows one of five states: Running, Starting, Needs attention, Stopped or Can't tell. Each state is a coloured badge with its word. I ran the container, cloud-tree, infra and new five-state tests, plus the rest of the files listed below. They pass, and tsc and bun scripts/gate.ts are clean. I did not run the page-budget tests, the full suite or a booted app.
What changed
src/machines/five_states.tsis the one mapping. It has one table per raw state: Docker's states, a container's health check, and a machine row's state. Any state not in a table is Can't tell and says it doesn't know the word. A box that hasn't synced in two minutes is Can't tell too.- Needs attention gives a plain reason and one fix:
- A failing health check offers Restart.
- A dead container offers Start.
- A failed machine with nothing at its provider offers Clear this row.
- A project (a machine and its containers) is its worst container. A machine with no containers on record is Can't tell.
- On the page,
src/web/five_badge.tsdraws the badge, reason and fix button. It is used in the Infrastructure machine rows, the cloud-tree rows and container table, and the container and machine pane. The old Clear button in the machine actions is replaced by this one, so there is a single button. - In the terminal,
src/tui/screens/infra.tsandsrc/tui/screens/cloudtree.tsshow the same words. In the cloud tree,frestarts or starts the selected container. In Infrastructure,cstill clears a dead row. test/five-states.test.tslists every raw state and its mapping. It also checks that the word is always present, that prototype names likeconstructorare not states, and how a project combines its containers.- I changed three existing assertions in
test/cloud-containers.test.tsandtest/infra-page.test.tsbecause their expected text was the old raw state. They now expect "Running" and "Stopped", and the machine-row markup. I added one assertion that a failed machine row has one fix button. - The how-to is a new section in
docs/features/infra.md.
What I left out
- /games server rows and the topology still use their own wording (
nowWords,netState). Those pages aren't tree rows or infra views, so I left them. - A project's reason names the failing container, but its button isn't drawn, because a project has no single fix target. The container's own row has the button.
- Runner heartbeats (idle, busy, paused) are not mapped. They describe work, not whether the machine is up.
- A
restartingcontainer maps to Starting, matching existing /games behaviour. A crash loop therefore doesn't show as Needs attention.
Commit lines
- The gate asks for a "No door" line because the two new modules are helpers that the existing terminal screens import.
- No page in
app.looksshows /infra, so the commit says "No look" instead of naming one.
Try
- Open
/infrato see machine rows with state, reason and button. - Open
/infra/-/<cloud>/<account>/<project>/machine:<id>/container:<name>for a container.
I found no similar function elsewhere in the repo to reuse beyond statusBadge, row and btn in the web UI. The existing progressOf and netState mappings are left as they are.
🤖 Generated with Claude Code
All four review points are fixed and pushed. I did not boot the app, so I haven't looked at /infra at 360px.
- Accent per row: the fix button in
src/web/five_badge.tsis nowghost/sm, so a list of failing rows draws no accent. A new test checks the button is ghost. - Two ways to restart:
fiveHeadinsrc/web/pages/cloud_tree.tsnow shows only the reason when the pane already draws the power control (game?.power). Containers without that control keep the one Restart/Start fix. - Project fix: a project that Needs attention now draws its worst container's fix, posting to that container's route.
- Crash loop:
restartingnow maps to Needs attention, with the reason "it keeps restarting, which is a crash loop" and a Restart fix. This also made the project's worst-of rule show it. I updated the mapping assertion intest/five-states.test.ts, which pinned the old value, and added a crash-loop test. - Docs: the doubled blank line is gone from
docs/features/infra.md. The terminal bullet now names its screens:fon the cloud tree for Restart/Start,con the Infra machine list for Clear. - 360px: I added a rule in
src/web/style/components.tsso a row's meta wraps and the block can't push the button off the edge. This is the part to check by eye. - Terminal door: the commit says
No door:.src/tui/already shows the same words, and itsfkey restarts a crash-looping container, so nothing new is needed there.
tsc is clean. The five-states, cloud-tree, infra-page, web-budget, design-audit and audit tests pass, and design-lint and the gate pass. I did not run the full suite; the forge's check does that on the push.
🤖 Generated with Claude Code
Every container, machine and project on Infrastructure now shows one of five states: Running, Starting, Needs attention, Stopped or Can't tell. Each state is a coloured badge with its word. I ran the container, cloud-tree, infra and new five-state tests, plus the rest of the files listed below. They pass, and
tscandbun scripts/gate.tsare clean. I did not run the page-budget tests, the full suite or a booted app.What changed
src/machines/five_states.tsis the one mapping. It has one table per raw state: Docker's states, a container's health check, and a machine row's state. Any state not in a table is Can't tell and says it doesn't know the word. A box that hasn't synced in two minutes is Can't tell too.src/web/five_badge.tsdraws the badge, reason and fix button. It is used in the Infrastructure machine rows, the cloud-tree rows and container table, and the container and machine pane. The old Clear button in the machine actions is replaced by this one, so there is a single button.src/tui/screens/infra.tsandsrc/tui/screens/cloudtree.tsshow the same words. In the cloud tree,frestarts or starts the selected container. In Infrastructure,cstill clears a dead row.test/five-states.test.tslists every raw state and its mapping. It also checks that the word is always present, that prototype names likeconstructorare not states, and how a project combines its containers.test/cloud-containers.test.tsandtest/infra-page.test.tsbecause their expected text was the old raw state. They now expect "Running" and "Stopped", and the machine-row markup. I added one assertion that a failed machine row has one fix button.docs/features/infra.md.What I left out
nowWords,netState). Those pages aren't tree rows or infra views, so I left them.restartingcontainer maps to Starting, matching existing /games behaviour. A crash loop therefore doesn't show as Needs attention.Commit lines
app.looksshows /infra, so the commit says "No look" instead of naming one.Try
/infrato see machine rows with state, reason and button./infra/-/<cloud>/<account>/<project>/machine:<id>/container:<name>for a container.I found no similar function elsewhere in the repo to reuse beyond
statusBadge,rowandbtnin the web UI. The existingprogressOfandnetStatemappings are left as they are.🤖 Generated with Claude Code
Closes #18617