# Proof audit pass 2

Findings first: no blocking proof contradiction or sensitive-surface change found. The supplied R1–R5 actual isolated-server records satisfy the scoped server evidence requirement. Independent R1 replay reproduces the relevant live states and committed event milestones. Fresh affected-file tests pass 99/99 at the final SHA. No real Claude quota, rendered UI, pixel/theme comparison, or live R4 active-wake rejection is proved or claimed.

Scope: [#22775](https://git.cafe/pingdotgg/t3code/pulls/22775), [GitHub mirror #22775](https://github.com/pingdotgg/t3code/pull/22775). Exact requested BEFORE [21da3061aa](https://git.cafe/pingdotgg/t3code/commit/21da3061aa006fc852ea4bd84c31ec084a3afa26), original production/test AFTER [80d27e96db](https://git.cafe/pingdotgg/t3code/commit/80d27e96db888d3ab0dbf12314f136f4e8b3e9b4), final runner/capture AFTER [9fd419a6e9](https://git.cafe/pingdotgg/t3code/commit/9fd419a6e9b455f17958325ad3ed696f08f00722). The local final commit is not evidence of a pushed PR head.

Read matrix.md, proof-audit-1.md, capture-index.md, both combined transcripts and per-row records, capture-validation.log, capture-manifest.json, capture-cleanup.json, regression provenance/logs, complete added fixture scripts/data, changed production code and relevant committed tests. Independently parsed raw records rather than accepting capture-summary.json assertions. Recomputed combined transcript and fixture hashes, verified all ten raw files occur byte-for-byte in the corresponding combined transcript, checked revision headers, persisted event sequence ordering, source identity, live state/receipts and PID exits. Results: [audit2-validation.log](/tmp/issue-16815-evidence/audit2-validation.log).

## Row assessment

| Row | Status | Evidence and limits |
| --- | --- | --- |
| R1 prearm | SUFFICIENT | BEFORE live shell completed/no error, no blocked source or arm, two runs. AFTER offline SQL candidate and live blocked source identify L; live shell failed/usage_limit; completed worker sweep arms L; identical due command twice returns sequence 32 twice and adds one continuation. Independently replayed. |
| R2 already armed | SUFFICIENT | BEFORE stored arm persists but completed shell prevents due selection; AFTER preserves the same request identity, failed/usage_limit shell and L source; duplicate live dispatch adds one continuation. Pre-reset offline SQL candidate is null on both because an armed window is not due; this is not positive proof of the due SQL query. Runtime regression tests cover that query. |
| R3 Stop before arm | SUFFICIENT | AFTER live Stop records L's run_interrupt_request and disarmed recovery with requestId proof:stop:R3. A completed automatic sweep preserves it; explicit live rearm changes identity to proof:rearm:R3; duplicate due delivery adds one continuation. BEFORE lacks L's Stop metadata/marker and rejects rearm. |
| R4 manual + held queue | SUFFICIENT, mixed live/harness | Active-wake rejection is explicitly offline harness only, on both revisions. After completed pre-reset wake and elapsed reset, live BEFORE selected/forced Resume fails; AFTER selects L, accepts once, releases Q's hold while Q stays queued, rejects new-identity duplicate, and queue.resume leaves Q behind the active continuation. Selector expression is not rendered-button proof. |
| R5 post-reset success | SUFFICIENT | Both live revisions show completed/no error/no blocked source after post-reset wake with assistant output. Saved stale automatic request is a no-op; manual L request fails; two runs remain. Persisted arm metadata is inert. |
| R6 active supersession | SUFFICIENT, test-only | Committed running-wake presentation and manual active-wake rejection cases pass. R4 offline rejection supplements these; no additional live active-wake claim. |
| R7 normal/user-first work | SUFFICIENT, test-only | Committed client assertions cover user-first ordinal ordering despite shuffled array, missing input and child-only notification. No broad suppression of normal user work. |
| R8 reset/date boundaries | SUFFICIENT, test/diagnostic | Committed inclusive reset and post-reset cases plus runtime post-reset guards pass. Null/invalid dates and adjacent boundary variants rely additionally on the supplied 28-case SQL/shared diagnostic, whose generating script was removed; that log is supplemental, not a committed replayable fixture. |
| R9 failure/root identity | SUFFICIENT, test/diagnostic | Committed non-limit/root-child/input assertions and inspected latest-failure guard support the rule. Newer non-limit/missing-error/root-null variants additionally have the supplied 28-case parity result, not a newly rerun parity test. |
| R10 ordering/guards | SUFFICIENT, test/diagnostic | Fresh runtime/client suites cover queue/cancelled-before-start, interrupted/manual, Stop/rearm/archive/pending and duplicate/stale delivery guards. Supplemental parity diagnostic enumerates remaining status variants. Live duplicate receipt and stale request checks agree. |

## Revisions, conditions and hashes

All ten supplied headers match the exact requested code revisions and identical runner hashes; final checkout is clean. BEFORE's only reported untracked files are the three byte-identical fixture additions. Workspace-source dependency realpaths point into each revision's checkout; the external dependency store is shared. Same versioned recipe, synthetic provider/mock peer, isolated settings, loopback bootstrap/transport and 60-second reset rule apply. Absolute times, generated event UUIDs, home paths, PID/port and scheduling latency appropriately differ. All R1–R4 wakes finish before their recorded reset; R5 wakes finish strictly after it.

SHA-256 independently matched:

- Runner: `dd69af5dffc13ded23c47c8accea177c83c515aa59be81e375925c9e11baa102`
- Fixture TypeScript: `a3e1f4997a9ac04fa9d87efc508b4743aaa0c2dac12a781ed7d081bbb2860011`
- Fixture JSON: `b70816010d1982b4dd8248997b02003aaf9b970a4c8893f7751fd13039045b24`
- BEFORE transcript: `2a231e73e908e604a7c69de668040683dd8eb9d834b0ac82d37ae6739014713d`
- AFTER transcript: `fe9da2184d330b055cd3c110eb96c7f75d74a6257a543b177fbefe1aa47c3d2b`

At audit time local main predates the supplied baseline: `git merge-base HEAD main` does not equal the requested BEFORE revision. The requested BEFORE is an ancestor of HEAD and is the direct parent of this branch's first fix/test commit. This does not invalidate the explicit two-SHA experiment, but “merge-base” here must mean the supplied baseline, not today's local main calculation. No fetch or branch mutation was performed.

## Independent reproduction

Ran the committed runner from the clean final checkout on the same machine (`freestyle`, Linux x86_64, Node v24.21.0), using its own fresh `/tmp/t3-limit-evidence-audit2-R1` home and automatically reserved loopback port:

```sh
node apps/server/scripts/usage-limit-evidence.ts \
  --home /tmp/t3-limit-evidence-audit2-R1 --row R1 \
  --runner-commit 9fd419a6e9b455f17958325ad3ed696f08f00722
```

Actual server PID 66042, port 35083. Replay reset 2026-10-21T10:27:40.757Z. Server readiness, live worker sweep, HTTP shell, WebSocket dispatch, persisted events and shutdown are recorded. Replay exited 0. Normalization compared shell status/error, blocked source, arm/source identity relationship, run ordinals/status/holds, ordered core event type/status/run identity and duplicate receipts. All four live state milestones and persisted events 1–32 match supplied AFTER R1; duplicate receipts are exactly sequence 32/32 in both captures.

Raw event totals differ: supplied 37, replay 43. After receipt sequence 32 the replay progressed further through the mock provider before shutdown: ready-session update, native provider-thread binding, run/attempt/node running updates, and an additional shutdown provider-thread update. These six extra events do not change the compared live states, three-run count, continuation identity or idempotence result. UUIDs, timestamps/reset-derived IDs, home/PID/port differ as expected. This is semantic reproducibility, not byte-identical transcript reproduction.

Evidence: [replay transcript](/tmp/issue-16815-evidence/audit2-R1.log), [server log](/tmp/issue-16815-evidence/audit2-server.log), [fixture identities](/tmp/issue-16815-evidence/audit2-fixture.json), [normalized comparison and cleanup](/tmp/issue-16815-evidence/audit2-reproducibility.json).

Independently reran both affected test files at the final SHA with the already installed checkout-local executable:

```sh
node_modules/.bin/vp test run apps/server/src/orchestration-v2/runtimeLayer.test.ts packages/client-runtime/src/state/threadExecution.test.ts
```

99/99 passed, two files, 14.56 seconds. [Fresh output](/tmp/issue-16815-evidence/audit2-tests.log). Plain vp and the global-path fallback were unavailable; the existing local executable succeeded without installation. No repo-wide checks ran.

## Runner safety and what else changed

No NEEDS_JULIUS finding. Inspected all three scripts/data files added after review, including subprocess, environment, bootstrap, settings and cleanup behavior. Fresh top-level mode rejects existing/symlink homes and confines its explicitly named directory to the temporary root. Child processes use an environment allowlist with disposable HOME/CODEX_HOME, explicit T3 home, synthetic settings and the existing mock peer. It uses the existing desktop bootstrap/token exchange and transport; it does not change production auth, credentials, grants, approvals, runtime-mode interpretation, sandbox/trust or MCP semantics. The full-access value is ordinary fixture thread configuration confined to the sandbox database. Only captured child PIDs are signaled; there is no process-pattern killing. Offline service staging is labeled and the server is stopped before database inspection. The project fixture uses ProjectStore.apply; thread history uses Orchestrator/EventSink, without direct projection SQL.

Diff from original reviewed AFTER to final is exactly three added development fixture files (952 lines), with no production/test changes. From requested BEFORE, the existing fix additionally changes shared blocked-source selection, both SQL mirrors, Orchestrator read filters/manual/Stop handling, ChatView's Resume selector and the two regression files. The capture index's “what else changed” account matches this diff. No new production endpoint, contract, provider adapter or permission surface was introduced.

## Gaps and cleanup

Real Claude quota exhaustion/classification remains UNVERIFIED. Synthetic provider failures/wakes establish shared server state-machine behavior only. R4 active-wake rejection remains harness-only; completed-wake manual transitions are live. UI rendering and pixel/theme evidence are outside this server proof. Durable null/invalid-date and full SQL parity table coverage remains an optional improvement; the removed 28-case diagnostic cannot be replayed from its log alone.

Public delivery is unavailable due to the previously recorded ghdrop DNS failures; local raw evidence is sufficient for this audit. No upload retry was needed. matrix.md and proof-audit-1.md describe the earlier incomplete stage and are superseded for capture completion by this audit and capture-index.md.

First and final root checks show 12 GB free. All ten supplied captured PIDs are absent; independent PID 66042 exited normally through runner cleanup. Removed only the independent disposable home after retaining its log/fixture identity. No production edits, installs, worktrees, browser, credential access, push, comment or forge write. Worktree stays clean at requested final SHA. T3 app PR registration was verified; no monitoring was started.

VERDICT: SUFFICIENT
