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

A failed hosted-forge restore in the drill is one named failure and pages once #14197

Merged opened this

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

Merged

When the restore drill fails at step forge, the reason now always reads hosted forge : . Before, only failures that proveHosted threw itself named the forge. A missing chunk from the restore underneath, or running out of the drill's time, came back without the name.

Notes

shipped production is serving it deploy 4adf612

opened this

When the restore drill fails at step forge, the reason now always reads hosted forge <name>: <what did not hold>. Before, only failures that proveHosted threw itself named the forge. A missing chunk from the restore underneath, or running out of the drill's time, came back without the name.

What changed

  • src/snapshot/drill.ts: the drill remembers which hosted forge it is proving. A failure at forge goes through a new namedForge(name, what), which adds the prefix only if it isn't already there. Running out of time reads hosted forge alpha: timed out: no answer within its … budget. This uses the drill's existing timer, so there is no new timeout (#2667). The red verdict, failedStep: "forge" and stopping at that step were already right.
  • Paging: the pager the other drill failures use (drillLines in src/crew/notify.ts) already pages once per drill, so it didn't need changing.
  • test/drill-hosted-red.test.ts (new): it uses an in-memory store whose manifest names hosted forge alpha, and a fake host restore that writes a minimal database. A deps.prove that throws gives:
    • a red verdict at forge, with the reason said once and no leftover scratch directory;
    • the forge named when the error came from below the proof without its name;
    • a forge time-out that names the forge;
    • exactly one page through startNotifier, and no second page when the same drill is read again.
  • test/drill-hosted-proof.test.ts: this was already failing on main. #14190's test expected a proof with no ms, while #14189 added ms around the same time. The test was wrong, not the code: it now checks that ms is a whole number of zero or more.

Not done: no change to the pager, docs/RECOVERY.md (its forge entry already says the forge is named), or the verdict file's format.

How to try it: bun test test/drill-hosted-red.test.ts test/drill-hosted-proof.test.ts test/snapshot-hosted-chunks.test.ts. The gate and tsc pass. I ran 33 drill, snapshot, notify and lint-style test files (unused-exports, module-state, recovery-red-drill, gate-stray-test) and they pass. scripts/fast.ts named 263 files (about 21 minutes), so I left the full set to the forge's check.

🤖 Generated with Claude Code

Closes #14186

commented

When the restore drill fails at step forge, the reason now always reads hosted forge <name>: <what did not hold>. Before, only failures that proveHosted threw itself named the forge. A missing chunk from the restore underneath, or running out of the drill's time, came back without the name.

What changed

  • src/snapshot/drill.ts: the drill remembers which hosted forge it is proving. A failure at forge goes through a new namedForge(name, what), which adds the prefix only if it isn't already there. Running out of time reads hosted forge alpha: timed out: no answer within its … budget. This uses the drill's existing timer, so there is no new timeout (#2667). The red verdict, failedStep: "forge" and stopping at that step were already right.
  • Paging: the pager the other drill failures use (drillLines in src/crew/notify.ts) already pages once per drill, so it didn't need changing.
  • test/drill-hosted-red.test.ts (new): it uses an in-memory store whose manifest names hosted forge alpha, and a fake host restore that writes a minimal database. A deps.prove that throws gives:
    • a red verdict at forge, with the reason said once and no leftover scratch directory;
    • the forge named when the error came from below the proof without its name;
    • a forge time-out that names the forge;
    • exactly one page through startNotifier, and no second page when the same drill is read again.
  • test/drill-hosted-proof.test.ts: this was already failing on main. #14190's test expected a proof with no ms, while #14189 added ms around the same time. The test was wrong, not the code: it now checks that ms is a whole number of zero or more.

Not done: no change to the pager, docs/RECOVERY.md (its forge entry already says the forge is named), or the verdict file's format.

How to try it: bun test test/drill-hosted-red.test.ts test/drill-hosted-proof.test.ts test/snapshot-hosted-chunks.test.ts. The gate and tsc pass. I ran 33 drill, snapshot, notify and lint-style test files (unused-exports, module-state, recovery-red-drill, gate-stray-test) and they pass. scripts/fast.ts named 263 files (about 21 minutes), so I left the full set to the forge's check.

🤖 Generated with Claude Code

Approved

A failure at step forge now always reads hosted forge <name>: <what did not hold>: a small namedForge helper prefixes once, and the timeout case is named too. The tests cover the injected throwing prove, a nameless error from under the proof, the budget timeout, and one page with no second page on re-read. I read the diff and the tests; I did not run them or load the preview, since there is no UI surface here. Next two things I would do: (1) run the drill-hosted tests in the forge check and watch for flake on the 50 ms timeout test; (2) fold the ms fix in drill-hosted-proof into its own pull next time, as it is unrelated to this change.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs