Public: anyone can read this; the crew can change it.
Games survival step 4: admin mods (luckperms fabric, ledger with fabric-language-kotlin) #18148
Merged 4h 46m ago, live in production
This adds an admin set, set:admin (LuckPerms and Ledger), that a Fabric server's Mods block previews and installs in one commit, through the same planner as the survival set (#18090). The set is only names.
-
Reviews
Changes requested — before the latest pushSecurity review: no findings. No new route or input path. The set name is looked up in a frozen list, the project goes through the existing planner and sha-pinned commit, and the unknown-set error echoes only a slice that is already validated by the existing path. One change needed: with two sets offered, the web Mods block shows two identical 'Preview the set' buttons under bare rows with no set title, so a person cannot tell which set a button installs (the aria label differs, the visible text does not). Name the set in the visible button text or give each set a heading row (the terminal already prints '<title> set: ...'), e.g. 'Preview the admin set'. Optional: the tightened survival assertion in test/game-mods.test.ts now checks 'Lithium: game logic' which is weaker than the old one; also assert the page no longer offers 'Preview installing the survival performance set'.
ApprovedApproved. Since my last review (3098d8332226) the changes are the admin set definition, its docs and MCP doc line, and tests. Earlier asks: the set's button now names it ("Preview the Admin set"), the set is offered on the page, in the terminal (
r) and over MCP, and the how-to is in docs/features/game-mods.md, not README. All met. The set is only names run through the existing planner, so the input validation, same-origin checks and sha512 locking are unchanged and no route or dependency was added. The tests cover the plan (three projects, Kotlin as a non-top dependency, nothing written), the Paper refusal, the page offer, the one-commit lock and the removal that takes Kotlin back. Non-blocking: the one comment line in src/http/mcp/tools/games.ts that is over 100 columns can wait for the nightly rewrap. -
Checks
shipped production is serving it deploy a338207
-
History
- Restore comments this pull did not write (the diff is the change) (#18090) db6e500
- Merge main into the admin set branch (#18090) bc20bb6
- Games survival step 3b: a sleep (night-skip) mod in the quality set (#18172) 56e2b82
- Automate a review finding as a lint or test: One high finding, then smaller ones, all for one round. (#18167) f6eb779
- A spark profile decodes to a summary: call tree, slowest ticks, per-mod time, GC and memory (#18144) e30e2b6
- 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
- Traces 4: a Claude Code session file imports as a trace and is listed beside the others (#18129) 68f0754
- A game box stores spark profiles in the forge: POST /post gives a Location, reads need the box's game grants (#18146) b992c0d
- Merge main into the admin set branch: three sets, each with its key and sentence (#18090) a9e05fd
- Games survival step 4: each set's preview button names the set (#18090) 88f3d12
- 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
- Games survival step 4: say which page looks, and the direction (#18090) 3098d83
- 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
6 earlier comments
This adds an admin set, set:admin (LuckPerms and Ledger), that a Fabric server's Mods block previews and installs in one commit, through the same planner as the survival set (#18090).
The set is only names. The planner picks each project's newest release for the server's Minecraft version and loader, and pulls Fabric Language Kotlin in as Ledger's required dependency. All three land in the lockfile with their sha512, the compose env is rebuilt from the lock, and the commit is on the sha you previewed.
I did not touch the live survival box. Installing it, the quiet-hours restart and watching the numbers for a day remain operator steps. The first earlier parked try was declined for that reason.
The planner takes the newest release, not a fixed version. The 5.5.10 and 1.3.13 in the issue are not fixed in code. If Modrinth has no Ledger build for 1.21.6, the plan is refused with that reason and nothing is written. It would be worth running a dry run first.
What moved
src/games/mod_sets.ts: addsADMINand aSETSlist.setNamednow looks the name up in that list, and each set has a terminalkey(sfor survival,rfor admin).src/games/mods.ts: an unknown set name now lists every set.- Web, terminal and MCP: the web Mods block and the terminal mods screen loop over
SETSinstead of naming one set. The MCPmods_installdoc line mentionsset:admin.docs/features/game-mods.mddocuments the set; removing Ledger takes Fabric Language Kotlin with it, which is the way back.
I reused the existing planner and planSet, and added no dependency or new route.
Tests
test/game-mods.test.tshas a new "admin set" block with a stand-in Modrinth: the plan holds all three and writes nothing, a Paper server is refused, the page offers it, one commit locks all three, and removing Ledger drops its Kotlin dependency.- I tightened one old assertion that assumed no set was offered once survival was installed.
test/game-mods.test.ts(29) andtest/tui-games.test.ts(15) pass, andtscand design-lint are clean.- I did not run the broad suite.
scripts/fast.tsnamed 452 files, about 31 minutes, so the forge's check runs it on the push.
Try it
On a Fabric server's page /games/<box>/<service>, open Mods and press Preview the set under the admin lines. In the terminal, press r on the mods screen. Over MCP, call games with mods_install and project: "set:admin".
[{"go":"/games/net/smp","look":"Mods block on a Fabric server: an Admin set with LuckPerms and Ledger lines and a Preview the set button","expect":"the preview lists Adds LuckPerms, Adds Ledger and Adds Fabric Language Kotlin (required by Ledger), with Install and restart"}]
🤖 Generated with Claude Code
<!-- look-pages a6601e91c7f3 --> Look pages for a6601e9, from the gate:
look pages (none): "Looks: /games/net/smp" is not a page of app.looks in forge.json; this pull changes src/web/pages/games.ts but the forge could not trace the route of /, /admin/telemetry, /explore and 29 more (an inline or wrapped handler), so it could not infer a page; the reviewer decides. A "Looks: <path>" line naming the nearest page, or a "No look: <why>" line (10+ characters), says it
This pull adds an admin mod set for Fabric servers. It holds LuckPerms and Ledger, and the planner pulls Fabric Language Kotlin as Ledger's dependency. All three go into one locked install, each pinned by sha512.
The only new commit is an empty one, 3098d8332, that fixes the look-pages and issue-number feedback with commit lines. A pushed commit can't be amended without a force push, so it carries the lines the gate wanted instead. I didn't run the tests or tsc again. bun scripts/gate.ts runs clean on the updated branch and the push went through.
- Look pages:
/games/net/smpisn't a page inapp.looks, so the new commit saysNo look:. The page is behind login on a per-box route, and the change is one more button in an existing list. - Name the issue: the new commit has a
Direction:line citing #18090 and #18059. - Both doors: the page, terminal and MCP all take
set:admin. The terminal key isron the mods screen, anddocs/features/game-mods.mdsays so. The new commit repeats this as aNo door:line. - Dead code, module-level state: nothing needed changing.
SETSis used bysetNamedandplanInstall, and it is a frozen constant, not state that requests write to. - Comment width: the gate flags three comment lines over 100 columns in files this pull touches (
src/games/mods.ts,src/http/mcp/tools/games.ts,src/web/pages/games.ts). I left them, since the nightly rewrap handles them on main.
Try it: on a Fabric server's page /games/<box>/<service>, open Mods and press Preview the set under Admin. In the terminal, press r on the mods screen. Over MCP, call games mods_install with project set:admin.
🤖 Generated with Claude Code
Each set's preview button now names the set in its visible text: "Preview the admin set" and "Preview the survival performance set". A person can tell which one a button installs. I changed the label in src/web/pages/games.ts and fixed the one line in docs/features/game-mods.md that quoted the old "Preview the set" text.
The tightened survival assertion in test/game-mods.test.ts now also checks that the page no longer offers "Preview installing the survival performance set". The same test also checks that the page offers "Preview the admin set". I updated the two other assertions that used the old label.
test/game-mods.test.ts passes after the rename, and tsc and design-lint are clean. The gate's only note was three files with comment lines over 100 columns, which it says the nightly rewrap handles, so I left them. I did not run bun test beyond that one file.
Not changed: I added no new route, so there is no new terminal or MCP side. The terminal already prints "<title> set: …", so the page now matches it.
I merged main into the branch and pushed; the merge conflicts are resolved.
test/game-mods.test.ts passes (36 tests), and tsc is clean. The gate's only note is the long comment lines it leaves to the nightly rewrap. I ran no other test files, because the tool that names tests for a change reported all of them (3,988 files, over the 5-minute budget).
Conflict resolution:
- Three sets:
mainadded the quality-of-life set, so the page and the terminal now offer survival, quality and admin. Each set usesmain's fields, a terminal key and a one-sentenceabout. The admin set keepsrand gets its ownaboutline. - Button labels: I took
main's capitalised wording, so the buttons read "Preview the Survival performance set", "Preview the Quality of life set" and "Preview the Admin set". Each button still names its set, which is what @sentinel asked for. - Docs:
docs/features/game-mods.mdand the MCP doc string insrc/http/mcp/tools/games.tsnow describe the admin set alongside the quality set. - Tests: I updated the label assertions to match
main, including the check that the page no longer offers "Preview installing the survival performance set". The unknown-set error now lists the sets asset:survival, set:quality, set:admin, and I changed the test to expect that order.
I merged main into this branch and pushed it. It had conflicts in two files, which I resolved by keeping both sides' changes.
docs/features/game-mods.md: I tookmain's Quality of life line, which now lists Sleep Warp. I kept this branch'sset:adminparagraph (LuckPerms and Ledger).src/http/mcp/tools/games.ts: I kept this branch'smods_installdoc text, which includesset:admin, and addedsleep-warpto theset:qualitylist frommain.
The type check (bun x tsc --noEmit) printed nothing. The run covered 1364 tests across 219 files, all passing, though that is more than the test files I named. I didn't run scripts/gate.ts or scripts/design-lint.ts, so the forge's check will be the first to run them.
This push fixes the one gate failure behind the three red checks: comment rewraps in files this pull didn't write. I didn't change any behaviour, and the admin mods work from earlier commits is unchanged.
What changed
- I restored
src/games/when_quiet.ts,src/core/migrations/20261204100000-game-quiet-reports.tsandtest/game-when-quiet-door.test.tsto theirmainversions. An earlier--fixhad rewrapped their comments, and the "the diff is the change" rule (rewrapNoiseRefusal) refused those lines.
Checks I ran locally
bun scripts/gate.ts --explainnow reports 0 failures out of 37 rules. That covers the rules that came up repeatedly: both doors, dead exports, naming the issue, and no module-level state.bun x tsc --noEmitprinted nothing but an unrelatedlarge-blobENOENT warning from the test harness, which I took to mean no type errors.- The four test files I ran all pass (50 tests):
game-mods,game-when-quiet-door,unused-exportsandmodule-state. - The sandbox denied outbound requests to
api.modrinth.com. I don't know whether any of those tests depend on that host.
What I left alone
src/http/mcp/tools/games.tshas one comment line over 100 columns. The gate only notes it, and running--fixon it would rewrap lines this pull didn't write, so I left it for the nightly rewrap.
This adds an admin set,
set:admin(LuckPerms and Ledger), that a Fabric server's Mods block previews and installs in one commit, through the same planner as the survival set (#18090).The set is only names. The planner picks each project's newest release for the server's Minecraft version and loader, and pulls Fabric Language Kotlin in as Ledger's required dependency. All three land in the lockfile with their sha512, the compose env is rebuilt from the lock, and the commit is on the sha you previewed.
I did not touch the live survival box. Installing it, the quiet-hours restart and watching the numbers for a day remain operator steps. The first earlier parked try was declined for that reason.
The planner takes the newest release, not a fixed version. The 5.5.10 and 1.3.13 in the issue are not fixed in code. If Modrinth has no Ledger build for 1.21.6, the plan is refused with that reason and nothing is written. It would be worth running a dry run first.
What moved
src/games/mod_sets.ts: addsADMINand aSETSlist.setNamednow looks the name up in that list, and each set has a terminalkey(sfor survival,rfor admin).src/games/mods.ts: an unknown set name now lists every set.SETSinstead of naming one set. The MCPmods_installdoc line mentionsset:admin.docs/features/game-mods.mddocuments the set; removing Ledger takes Fabric Language Kotlin with it, which is the way back.I reused the existing planner and
planSet, and added no dependency or new route.Tests
test/game-mods.test.tshas a new "admin set" block with a stand-in Modrinth: the plan holds all three and writes nothing, a Paper server is refused, the page offers it, one commit locks all three, and removing Ledger drops its Kotlin dependency.test/game-mods.test.ts(29) andtest/tui-games.test.ts(15) pass, andtscand design-lint are clean.scripts/fast.tsnamed 452 files, about 31 minutes, so the forge's check runs it on the push.Try it
On a Fabric server's page
/games/<box>/<service>, open Mods and press Preview the set under the admin lines. In the terminal, pressron the mods screen. Over MCP, callgameswithmods_installandproject: "set:admin".🤖 Generated with Claude Code
Closes #18090