# Remote desktop update retry proof

Runtime evidence, not unit tests. Linux x64 packaged Electron, built separately from base and head. The initiating client is a raw WebSocket RPC driver. Its 1280×900 dark console records live RPC messages and selected target desktop log messages; it is explicitly not product UI. Profiles and updater caches are fresh and synthetic for each run. No project or thread is required.

Base: 73fb6cd009260087dca8b82e53e9415321f32961
Head: 5c65dbca8e0668d77f63bba20279bfa6a3a5cabe

Build each source checkout as 0.1.9:

```
T3CODE_DEV_SEED=0 vp run dist:desktop:artifact --platform linux --target AppImage --arch x64 --build-version 0.1.9 --mock-updates --mock-update-server-port 17991 --output-dir <artifact-directory>
```

Build a real 0.1.10 target from head with the same command and `--build-version 0.1.10 --output-dir <feed-directory>`. The repository's mock-update option redirects the real electron-updater to a loopback HTTP feed; it does not mock the downloader, desktop IPC, preparation, commit, or file replacement.

Place driver.mjs in a scratch directory. It imports Playwright from the provided checkout. Its Chromium executable path points to the VM's preinstalled headless browser; adjust that path on another host.

```
headless-desktop node driver.mjs <head-checkout> <base-AppImage> <feed-directory> before 73fb6cd009260087dca8b82e53e9415321f32961
headless-desktop node driver.mjs <head-checkout> <head-AppImage> <feed-directory> after 5c65dbca8e0668d77f63bba20279bfa6a3a5cabe
```

The driver starts the actual desktop with `--no-sandbox --disable-gpu`, waits for its server, obtains an isolated administrative session, calls `server.updateServerWithProgress({targetVersion:"0.1.10"})`, closes the WebSocket on its first downloading progress event, waits for the desktop to log preparation, then retries from a new connection after eight seconds. It counts subsequent AppImage HTTP requests and compares the returned token with the original preparation requestId. If a token is returned, it commits that token. The head process exits 0; SHA-256 comparison confirms the installed AppImage equals the real 0.1.10 feed artifact. The install record also says 0.1.9 → 0.1.10. Post-install relaunch is not part of this proof.

Run the five-minute check in an interactive terminal session; the noninteractive shell terminated one run with exit 143 before its late retries.

For the supplemental reservation check, retain a separate copy of the original head 0.1.9 AppImage before the commit run overwrites it, then append `expiry` to the driver invocation. It retries at eight seconds, 4m30s, and 5m05s after observing preparation. The late pre-expiry retry must retain the original token; the post-expiry retry must return a different token despite that recent retry.

Only console captures and sanitized runtime logs are public. Product-window screenshots are deliberately excluded: the initiating client was the RPC driver, and the local renderer's onboarding session was displaced by its separate bootstrap exchange. The desktop server and updater continued running and handled all measured RPCs.
