Public: anyone can read this; the crew can change it.
Access 4b-1: a person sees who can reach what on their own account, at /settings/who-can, linked from settings #18166
Closed 5h 31m ago
The /settings/who-can page was already on main from #18062 (5ba07c89c), along with its rules, its terminal screen ("Who may do what" in forge tui), its MCP tool and the one shared grant reader. What it lacked was a way in for anyone who isn't an admin. Its only link was on /settings/access, which only admins can see.
-
Reviews
No review yet.
-
Checks
stopped closed without shipping deploy 13384b1
-
History
- Merge main: #18131 already links Who may do what from every account's settings and names admin-only pages instead of linking them; keep main's side 13384b1
- Access 4b: the 'Who may do what' page, linked from settings, by person and by resource (#18131) 3ecccb5
- "asks ledger failed: database is locked" two minutes after a release (v0.7.733) (#18169) 009df15
- Who can reach me: name admin-only pages without linking them, and hold /settings at 153 words (#18158) 159805e
- Traces 4: a Claude Code session file imports as a trace and is listed beside the others (#18129) 68f0754
- Who can reach me: link /settings/who-can from every account's settings sidebar (#18158) c478255
- A game box stores spark profiles in the forge: POST /post gives a Location, reads need the box's game grants (#18146) b992c0d
- Games survival step 3: quality-of-life mods tried on a copy first (graves, essential-commands, sleep, harvest, vein miner, styled-chat) (#18145) f058287
- Spend 1: a monthly budget per cloud account, one notice at 80% and one at 100% (#18121) 3382c40
- Games: a proxy plugin update can wait until nobody has been on for 30 minutes (#18039) 9a5eb31
- Traces 5: compare two traces, and share one with secrets redacted (#18017) 7a17314
- AWS writes for mail setup are a named allowlist beside the read rule, and nothing else (#18142) 93c7c3d
- Traces 1c: GET /api/v1/traces/:id returns the thread, turns and steps as one tree (#18128) 077bab0
- A box's TPS and tick time show live on its games pane, from spark's health report or `/spark tps` at check-in (#18143) f7e559b
- Access 4c: the grants view as an MCP tool and a terminal screen (#18130) 89afadf
- small: the Absorb findings say they are ready for the owner to send to Ben (#18132) d41ec43
- Games survival step 2a: BlueMap behind login at /games/<box>/<server>/map, no published box port (#18100) 1132c91
- A Mac can take a repository's checks and report them on the pull (#17915) 4c72a1d
- Access 4: one view of every grant, and a page that says who may do what (#18062) 5ba07c8
- Access 2: one `may(principal, action, resource)`, with the repository checks behind it first (#18065) 7d48ce1
5 earlier comments
The /settings/who-can page was already on main from #18062 (5ba07c89c), along with its rules, its terminal screen ("Who may do what" in forge tui), its MCP tool and the one shared grant reader. What it lacked was a way in for anyone who isn't an admin. Its only link was on /settings/access, which only admins can see. The feature doc already said "Settings → Who may do what", but that row did not exist in the sidebar.
What changed
src/web/pages/origins.ts: a new Who can reach me row →/settings/who-canin the Account group of the settings sidebar. It shows for every account, admin or not, and adds a"who-can"section so the sidebar highlights it on that page.src/web/pages/who-can.ts: the page now marks its own sidebar row as current, not the admin-only "Access" row.docs/features/who-can.md: names the new sidebar row.test/who-can.test.ts: one new test (#18158). For both bob (a person with no grants) and dave (a person holding one grant of each kind):/settingslinks to/settings/who-can.- Dave's own page lists his grants and the pages where each is changed, with no admin look-up form.
- Bob's page shows only what his role gives him.
This test fails without the change. The existing tests already cover one grant of each kind and refuse another person's grants to a non-admin.
Left as it was: the route mark (/settings/who-can is already marked open), the grant reader, and the terminal screen, which already lists the same rows. The commit says No door for that reason. I added no grant table and no admin shortcut.
Checks: bun x tsc --noEmit, the gate, design-lint, and 14 test files passed (172 tests: who-can, grants-view, settings-groups, settings-routes, route-marks-roster, unused-exports, feature-doors, doorless, hollow, unreached, docs-link, origins, design-lint, module-state). I did not run the whole suite; the forge's check runs it on this push.
Try it: sign in as someone who isn't an admin, open /settings, and follow Who can reach me in the sidebar.
[{"go":"/settings","look":"the settings sidebar, Account group","expect":"a 'Who can reach me' row, also for an account that is not an admin"},
{"go":"/settings/who-can","look":"the page and the sidebar","expect":"'Who can reach me' highlighted; one sentence on what your role gives; your own grants, one row each linking to where it is changed, or 'No grants match.'"}]
🤖 Generated with Claude Code
Every account's settings sidebar now has a "Who can reach me" link to /settings/who-can. Before, the only link sat in the Access section, which only admins can see, so other people had no way to reach the page. The sidebar row marks the page as current.
The first check run failed for two reasons, both fixed here:
- Link that ends in a 403: a non-admin's own "member · this forge" grant linked to
/settings/people, which only admins can open, and the dead-end test caught it.src/web/pages/who-can.tsnow shows a grant as plain text when its link goes to an admin-only settings page and the viewer is not an admin. Admins still get the link. That check uses the admin flag already on the sidebar rows, through the newadminOnlySectioninsrc/web/pages/origins.ts.test/who-can.test.tschecks both the plain text for a member and the link for an admin. - Word limit on
/settings: the new row's four words put the page over its word limit.docs/design/attention-budget.jsonraises it from 149 to 153 words, with a note in the same style as the earlier nav-row increases. That is a deliberate budget raise, not a fix to the page; renaming the label shorter would avoid it.
The who-can, attention and dead-end tests now pass, along with the gate, the type check and the design lint.
The terminal side is unchanged because its screen draws no links (stated in the commit's "No door:" line).
To try it: sign in as a non-admin, open /settings and follow "Who can reach me". Your forge-role row shows as text, not a link.
[{"go":"/settings","look":"the Account group in the sidebar","expect":"a 'Who can reach me' row for a non-admin"},{"go":"/settings/who-can","look":"the grant list as a non-admin member","expect":"the 'this forge (forge)' member row is plain text, not a link to /settings/people; the sidebar marks 'Who can reach me' current"},{"go":"/settings/who-can?person=dave","look":"the same row as an admin","expect":"it links to /settings/people"}]
🤖 Generated with Claude Code
This pull now changes nothing: #18131, merged to main in 3ecccb598, already does everything it did, so it can be closed without merging. Merging main in and resolving the conflicts left the branch's files identical to main.
main already has, from #18131:
- Sidebar link: every account's settings sidebar has a link to
/settings/who-can, labelled "Who may do what", marked as the current page when you are on it. - Word limit: the
/settingsword limit is already raised to 153 for that row. - Admin-only pages: in a non-admin's view, a grant that only an admin can change is shown as text, "an admin changes it (People)", instead of a link that would return a 403. This covers People, Crew, Cloud, Subscriptions, Secrets, Telemetry and Devices, and both the web page and the terminal.
Every conflict was resolved by taking main's side, which also dropped my adminOnlySection helper because nothing used it any more. bun test test/who-can.test.ts (14 tests), bun x tsc --noEmit and bun scripts/gate.ts pass on the merged branch.
[{"go":"/settings","look":"the Account group in the sidebar as a non-admin","expect":"a 'Who may do what' row linking to /settings/who-can"},{"go":"/settings/who-can","look":"the grant list as a non-admin member","expect":"the forge member row reads 'an admin changes it (People)' with no link to /settings/people"}]
🤖 Generated with Claude Code
Left #18158 open: 3 unticked items remain (GET /settings/who-can lists the person's own grants, one row per grant with its kind and where it is changed; an account with no grants shows only what its role gives.; Link from /settings. Route marked in src/http/marks/; server-rendered; output escaped.; Reads grants through the existing may()/grant readers; adds no grant table and no admin-only shortcut.).
The
/settings/who-canpage was already on main from #18062 (5ba07c89c), along with its rules, its terminal screen ("Who may do what" inforge tui), its MCP tool and the one shared grant reader. What it lacked was a way in for anyone who isn't an admin. Its only link was on/settings/access, which only admins can see. The feature doc already said "Settings → Who may do what", but that row did not exist in the sidebar.What changed
src/web/pages/origins.ts: a new Who can reach me row →/settings/who-canin the Account group of the settings sidebar. It shows for every account, admin or not, and adds a"who-can"section so the sidebar highlights it on that page.src/web/pages/who-can.ts: the page now marks its own sidebar row as current, not the admin-only "Access" row.docs/features/who-can.md: names the new sidebar row.test/who-can.test.ts: one new test (#18158). For both bob (a person with no grants) and dave (a person holding one grant of each kind):/settingslinks to/settings/who-can.This test fails without the change. The existing tests already cover one grant of each kind and refuse another person's grants to a non-admin.
Left as it was: the route mark (
/settings/who-canis already markedopen), the grant reader, and the terminal screen, which already lists the same rows. The commit saysNo doorfor that reason. I added no grant table and no admin shortcut.Checks:
bun x tsc --noEmit, the gate, design-lint, and 14 test files passed (172 tests:who-can,grants-view,settings-groups,settings-routes,route-marks-roster,unused-exports,feature-doors,doorless,hollow,unreached,docs-link,origins,design-lint,module-state). I did not run the whole suite; the forge's check runs it on this push.Try it: sign in as someone who isn't an admin, open
/settings, and follow Who can reach me in the sidebar.🤖 Generated with Claude Code
Closes #18158