# Branch-menu VCS cache evidence

Beyond the PR badge named by the title, this fix changes upstream/divergence/default-ahead recovery, initial subscription timing, and local-only refresh overlap behavior. These are intended consequences of the same cache change. No unrelated behavioral difference was observed.

PR [#33263](https://git.cafe/pingdotgg/t3code/pull/33263) (GitHub [#33263](https://github.com/pingdotgg/t3code/pull/33263)). Before [4c361199f4](https://git.cafe/pingdotgg/t3code/commit/4c361199f47f6ea32a2c14835df392640d0f7c63); after [456327574c](https://git.cafe/pingdotgg/t3code/commit/456327574c52ad1c7624083bb97eaf382edd1732).

Captured here: **9/10 matrix rows**, all as paired real-server recordings. **10/10 server rows covered including retained R1**. All six required missing rows R2/R4/R5/R6/R7/R8 are captured; R3/R9 controls and P1 positive hosted payload are also captured. R1 was not recaptured; its existing PR-body recordings retain their actual before [c6ca605630](https://git.cafe/pingdotgg/t3code/commit/c6ca6056309904f89b90b6055d797973be0a0939) and after [33cb900503](https://git.cafe/pingdotgg/t3code/commit/33cb9005036fc80b97bb50dbf51132d09e8ec91b) revision labels.

[Fixture matrix](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/cf5d942bc376f552/matrix.md).

Environment: Linux 6.8.0-117-generic x64; Node v26.12.1. Each side ran its own `T3CODE_DEV_SEED=0 node apps/server/src/bin.ts serve --host 127.0.0.1 --port <ephemeral> --base-dir <fresh run>/t3 --no-browser --log-level warn --dev-url http://127.0.0.1:<same port>`. The dev URL provisions free Replay; no Vite server or browser was needed. The forwarding git wrapper is first on the server PATH. `automaticGitFetchInterval` is explicitly 0 seconds for R2/R5/R8 and explicitly 30 seconds for the other rows; other server settings begin with fresh defaults. Every log has its full exact command/environment line.

Same seeding and driver on both sides, checked by driver SHA256 and identical seeded git refs. Each row uses a separate fresh server/database on each side. No live userdata read, copy, migration, repair, service action, push, comment, paid provider, or repository source edit was used. P1 reads an existing public PR through the actual GitHub provider; its shallow checkout has identical branch/main refs on both sides.

| Row | Capture/result | Before | After |
|---|---|---|---|
| R1 | [#33263](https://git.cafe/pingdotgg/t3code/pull/33263) retained PR-body recording | Null within recorded 8s window | A ahead 1 arrives within recorded window |
| R2 | [cold-turn-end-zero](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/0630e2c10790e3e9/R2-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/03443fb6300dcf03/R2-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/99cda15183fadc40/R2-after.log) |
| R3 | [warm-same-branch](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/43b70c2ea74741bb/R3-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/f61fe492119c6ccc/R3-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/49e226436ed958c7/R3-after.log) |
| R4 | [branch-switch-subscribe](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/873146d922362560/R4-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/e70ce7e5f5d3ba0b/R4-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/712f5f82112746e2/R4-after.log) |
| R5 | [branch-switch-turn-end-zero](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/449c72e63631eead/R5-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/caf0d6885552cef4/R5-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/62b0622e99b29392/R5-after.log) |
| R6 | [first-read-overlap](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/d3cb39ac567a4781/R6-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/1bcdfec5d8073078/R6-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/c322b5f54ab5979b/R6-after.log) |
| R7 | [switched-in-flight-read](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/0e1a4405007c6852/R7-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/b0a8387221be1d30/R7-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/44492bfcc56013e7/R7-after.log) |
| R8 | [cold-subscribe-zero](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/2947ac08f8f2890e/R8-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/166634f25ccf9435/R8-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/38ecc864d0c774e5/R8-after.log) |
| R9 | [genuine-null-non-repository](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/4b566902cc7aa58b/R9-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/2bf477d4e68a7253/R9-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/68896deb2b3256ee/R9-after.log) |
| P1 | [positive-PR-overlap](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/f118b63c76abdb1a/P1-sheet.md) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/631337208fcd6041/P1-before.log) | [Recording](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/0514b36b8f8e5059/P1-after.log) |

What else changed in these recordings:

- R2/R5: completed Replay turns now recover remote status with automatic fetch disabled; the before captures remain null through the recorded post-turn window. Both sides complete and checkpoint the turn.
- R4/R8: cold/new-branch subscriptions now read immediately; the before captures remain null through the bounded observation window. R8 executes no fetch on either side.
- R4/R5: branch switches publish one necessary clear after the fix, versus two clears before it. The new branch receives its own distinct counts after the fix.
- R6/P1: before publishes populated remote state and then erases it; after retains it. P1 proves this with the actual open PR and default-ahead 1. The local-only server effect no longer waits for the remote writer.
- R7: both discard the obsolete A read. Only after does the next fresh B subscription read B immediately; before installs a null result and delays that read beyond the capture window.
- R3/R9 controls show no behavioral change: cached same-branch data and genuine non-repository null results remain stable.
- Immediate local-only RPC return values can still have default remote fields while a remote read is in flight. Timestamp/UUID/port/PID differences are run artifacts. No claim is made about the exact duration of a complete poll interval.

Unverified: **no server matrix row remains unverified**. P1 captures the live hosted PR over RPC; the optional web toolbar/menu/badge and git-control rendering were not exercised, because these are server recordings with no browser attached. Detached/no-upstream/alternate PR-state variants are represented by the shared cache branch and are not separately captured.

All 24 spawned server PIDs (pilots included) were verified stopped. The temporary before worktree was removed before handback; the after worktree remains unchanged. Scratch/raw recordings remain under the authorized scratch directory. Startup credentials and QR blocks were excluded from uploads. Uploaded attribution contains no private runtime model identifiers.

Scripts and capture validation:

- [capture.ts](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/14045d066cbabc5b/capture.ts)
- [capture-hosted.ts](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/385ab4eafb90c6a5/capture-hosted.ts)
- [seed.mjs](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/5901fe67aaf0db7a/seed.mjs)
- [seed-hosted.mjs](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/effa7efd37aac58e/seed-hosted.mjs)
- [git-wrapper.py](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/21bdbc442512d0a9/git-wrapper.py)
- [run-matrix.py](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/2161905a8589398a/run-matrix.py)
- [validate.py](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/9c4b2ad64d43c5b8/validate.py)
- [build-upload.py](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/d5f92216876e28e2/build-upload.py)
- [original-driver.ts](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/55bd6dadc418dff8/original-driver.ts)
- [verification.json](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/e9d6219f087029fa/verification.json)

The original-driver.ts link is an extracted reference from the pre-existing PR body; it was not executed. The matrix runner drove R2–R9; capture-hosted.ts drove P1. Verification validates capture completeness and final recorded states; it is not substituted for any recording.

AI-assisted; verified with the tests and tools listed above.

FRICTION:
runbook | The first scratch launch used the repository-root node_modules, which lacks the server RPC dependencies. Recorder now resolves through the server package node_modules. | Document the server-package dependency root for standalone drivers.
runbook | An open TCP port preceded HTTP/RPC readiness and returned 503 in a pilot. Recorder now retries only boot-time ticket issuance before any fixture action. | Wait for authenticated HTTP readiness rather than just the listening port.
tool | The typed settings RPC expects Effect Duration; the numeric pilot failed schema encoding. Both final sides use Duration.seconds and log the successful result. | Show the typed-client Duration form alongside wire-format examples.

PR [#33263](https://git.cafe/pingdotgg/t3code/pull/33263), head [456327574c](https://git.cafe/pingdotgg/t3code/commit/456327574c52ad1c7624083bb97eaf382edd1732), checks and reviews not re-audited; evidence capture only.
