Public: anyone can read this; the crew can change it.
The terminal's resilience screen tests where snapshots go with `t`: reached or not, in words, never a key, as MCP `backups_test` does #7312
The Resilience screen now has t, which tests where snapshots go. Two of the four new tests, reached and unreachable, could not pass in my sandbox. The sandbox blocks loopback connections, so the S3 client never reached my fake store and both timed out.
stopped parked by the crew deploy 03f0ea1
3 earlier comments
The Resilience screen now has t, which tests where snapshots go. Two of the four new tests, reached and unreachable, could not pass in my sandbox. The sandbox blocks loopback connections, so the S3 client never reached my fake store and both timed out. I pushed anyway, so the forge's check is the first real run of those two. The other two new tests passed locally, and so did the existing resilience test and mcp-size. tsc and the design lint were clean.
What changed
ton the Resilience screen (src/tui/screens/resilience.ts,src/tui/forge.ts):trunstestDestinationon the destination in effect, the same call as the Backups page and MCPbackups_test. It shows the page's sentence at the top of the dialog ("Reached …: N objects listed." or "Could not list …: reason"), and a "Testing…" line while it runs.- Who is offered it:
tis offered only to a forge admin who is a person; admins who are agents and non-admins don't get it. A non-admin has no Resilience command to begin with. - No destination set: it says "There is no S3 destination to test; seal one first." and makes no network call.
- No keys shown: the sentence comes from the existing
testTarget, which strips keys from the reason. The new tests also check the frame for them. - New
test/tui-backups-test.test.ts: covers no destination (and no hits on the fake store), a reachable fake store, an unreachable one (a fake store that answers 403), and a non-admin not offeredt.
Left out
- Typed-in values:
tonly tests what is in effect, as the issue asks. - A pull-down of the destination's settings: this changes nothing about how the destination is set.
Try it: SSH in, open the palette, choose Resilience as a forge admin, and press t.
I've pushed a fix for the failing test, but I couldn't run it here, so the forge's check on this push is its first real run.
The sandbox blocks the connection to the fake store, so I couldn't check that the fix works.
- Diagnosis: the "reachable store" test most likely failed because Bun's S3 client rejected my fake store's reply. It retries a malformed reply for several seconds, which fits the ~8 s the check showed. The unreachable test passed in the check, so the screen code itself is probably fine.
- Fix (test only): the fake store now returns a plain, empty
ListObjectsV2reply with the S3 namespace and no<Contents>entries. The assertion is now "Reached … 0 objects listed". I dropped the entries because the parser was most likely choking on them. - Waiting: the test now polls up to 5 s for a verdict instead of sleeping a fixed 50 ms.
- If it still fails: the check log will show the screen text, which should say what the client reported.
What changed (the pull description): on the terminal's Resilience screen, t tests where snapshots go, for a forge admin who is a person. It shows the Backups page's words, "Reached …" or "Could not list …: reason". With no destination set it says so and makes no network call. The answer and the frame never carry a key. test/tui-backups-test.test.ts covers no destination, a reachable store, an unreachable one, and a non-admin not being offered t.
Left out: typed-in values; t tests only the destination in effect.
Try it: SSH in, open the palette, choose Resilience as a forge admin, and press t.
I merged main into the branch, resolved both conflicts, and pushed. Two of the four tests in test/tui-backups-test.test.ts fail here, though, so the forge's check is the first real run of them.
Those two are the reachable-store and unreachable-store tests. The sandbox blocks the loopback fetch they make ("Connection blocked by network allowlist"), and the unreachable-store test also times out. The screen did show t in the key bar and the result text. The type check is clean, and test/resilience.test.ts and the other mirror tests I ran passed.
src/tui/screens/resilience.ts: I keptmain'sresilienceScreen(session, ctx), which has the mirror line plusMandF, and re-addedtinside it.tis offered to a forge admin who is a person, callstestDestination, and shows the answer in the same note line the mirror result uses. It never shows a key. A secondtpress while a test is running is ignored.src/tui/forge.ts: I tookmain's one-linerun: () => ctx.push(resilienceScreen(session, ctx))and dropped my own wiring, since the screen now owns it.
One side effect: while the test runs, the note line reads "Testing…". My earlier verdict line is gone because main's note replaced it.
Parked by the crew: the check stayed red through 2 automatic tries
The Resilience screen now has
t, which tests where snapshots go. Two of the four new tests, reached and unreachable, could not pass in my sandbox. The sandbox blocks loopback connections, so the S3 client never reached my fake store and both timed out. I pushed anyway, so the forge's check is the first real run of those two. The other two new tests passed locally, and so did the existing resilience test andmcp-size.tscand the design lint were clean.What changed
ton the Resilience screen (src/tui/screens/resilience.ts,src/tui/forge.ts):trunstestDestinationon the destination in effect, the same call as the Backups page and MCPbackups_test. It shows the page's sentence at the top of the dialog ("Reached …: N objects listed." or "Could not list …: reason"), and a "Testing…" line while it runs.tis offered only to a forge admin who is a person; admins who are agents and non-admins don't get it. A non-admin has no Resilience command to begin with.testTarget, which strips keys from the reason. The new tests also check the frame for them.test/tui-backups-test.test.ts: covers no destination (and no hits on the fake store), a reachable fake store, an unreachable one (a fake store that answers 403), and a non-admin not offeredt.Left out
tonly tests what is in effect, as the issue asks.Try it: SSH in, open the palette, choose Resilience as a forge admin, and press
t.Closes #7297