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

A game box that cannot lend says why, and new boxes can lend #17941

opened this in answer to

Merged 24h 2m ago, live in production

A game box with lending on now says why it cannot lend, on its page, on the runners page and in the terminal. The related tests, tsc and the migration pin check pass; I did not run the dead-code test by name or the full suite.

Notes

opened this

A game box with lending on now says why it cannot lend, on its page, on the runners page and in the terminal. The related tests, tsc and the migration pin check pass; I did not run the dead-code test by name or the full suite.

  • Agent: while the box holds a runner token and bwrap or git is missing, it sends lendWhy with each check-in: "bubblewrap is not installed", "git is not installed", or "bubblewrap and git are not installed". lend_tick uses the same check, so it still refuses to claim. Previously it just returned.
  • Forge: the forge stores lend_why on the game box (migration 20261203070000-game-box-lend-why, pinned) and keeps only those three phrases. Anything else the box sends is dropped, so nothing unescaped reaches a page.
  • Doors: "cannot lend: bubblewrap is not installed" appears under the switch on /games/<box> and in the terminal's box screen. It also appears on that runner's row in Settings → Runners (a "Lending" fact) and in the terminal's runners screen. It shows only while the switch is on and clears at the next check-in once the tool is installed.
  • New boxes: the boot already installed bubblewrap and git in src/games/boot.ts, so I changed nothing there. Boxes older than that fix are the ones that need the message. docs/features/game-box.md now says so.
  • Tests: the agent runs for real without bubblewrap and sends the reason, and a capable box sends "". The page and runners page show the reason and drop a hostile phrase. The terminal box screen shows it too. GameBox in test/game-spare.test.ts now carries lendWhy, so it type-checks without as never.
  • Module state: cannotByRunner is a query, not module state.

Left out: no JSON or API field for the reason, and no alert or notification. The gate's "both doors" rule flagged the pull because it adds no new screen or how-to file. The terminal screens and the how-to are edited, so a commit line says No door: and explains that.

Try it on the preview: switch lending on for a box with no bubblewrap, and open /games/<box> or Settings → Runners after its next check-in.

I used bun scripts/gate.ts --explain rather than similar.ts. Its one duplicate note was cannotByRunner against readLevels, which does something different, so I kept it.

Closes #17934

commented

A game box with lending on now says why it cannot lend, on its page, on the runners page and in the terminal. The related tests, tsc and the migration pin check pass; I did not run the dead-code test by name or the full suite.

  • Agent: while the box holds a runner token and bwrap or git is missing, it sends lendWhy with each check-in: "bubblewrap is not installed", "git is not installed", or "bubblewrap and git are not installed". lend_tick uses the same check, so it still refuses to claim. Previously it just returned.
  • Forge: the forge stores lend_why on the game box (migration 20261203070000-game-box-lend-why, pinned) and keeps only those three phrases. Anything else the box sends is dropped, so nothing unescaped reaches a page.
  • Doors: "cannot lend: bubblewrap is not installed" appears under the switch on /games/<box> and in the terminal's box screen. It also appears on that runner's row in Settings → Runners (a "Lending" fact) and in the terminal's runners screen. It shows only while the switch is on and clears at the next check-in once the tool is installed.
  • New boxes: the boot already installed bubblewrap and git in src/games/boot.ts, so I changed nothing there. Boxes older than that fix are the ones that need the message. docs/features/game-box.md now says so.
  • Tests: the agent runs for real without bubblewrap and sends the reason, and a capable box sends "". The page and runners page show the reason and drop a hostile phrase. The terminal box screen shows it too. GameBox in test/game-spare.test.ts now carries lendWhy, so it type-checks without as never.
  • Module state: cannotByRunner is a query, not module state.

Left out: no JSON or API field for the reason, and no alert or notification. The gate's "both doors" rule flagged the pull because it adds no new screen or how-to file. The terminal screens and the how-to are edited, so a commit line says No door: and explains that.

Try it on the preview: switch lending on for a box with no bubblewrap, and open /games/<box> or Settings → Runners after its next check-in.

I used bun scripts/gate.ts --explain rather than similar.ts. Its one duplicate note was cannotByRunner against readLevels, which does something different, so I kept it.

Sign in to join this conversation.

Search
↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs