From ef2daeee80375231f4dcafcf453276bb55c098c8 Mon Sep 17 00:00:00 2001 From: Neil <4138956+nwparker@users.noreply.github.com> Date: Tue, 17 Nov 2026 05:12:29 -0800 Subject: [PATCH] refactor(tests): colocate runtime and compatibility contracts with owners (#43589) --- config/flaky-test-pattern-baseline.txt | 21 +- config/legacy-relay-compat-tags-baseline.txt | 6 +- config/legacy-relay-importers-baseline.txt | 2 +- config/path-literal-baseline.txt | 6 +- config/reliability-gates.jsonc | 160 ++------ .../native-chat/native-chat-4a-arm.ts | 2 +- .../vitest-node-runtime-files.mjs | 1 - .../reclaim-release-test-caches.mjs | 4 +- .../reclaim-release-test-caches.test.ts | 4 +- config/tsconfig.node.json | 2 +- config/tsconfig.test.pane-launch.json | 2 +- docs/readme/release-source-sharing.md | 2 +- ...time-terminal-close-continuity-fixtures.ts | 2 +- ...time-native-chat-draft-resolutions.spec.ts | 138 +++++++ ...gent-session-tab-authority.test-support.ts | 2 +- .../scripted-codex-transport.test-fixture.ts | 4 +- .../browser-capabilities.spec.ts | 58 +-- .../browser-page-inventory.test.ts | 48 +-- .../renderer-browser-lifecycle.test.ts | 9 +- .../renderer-browser-ownership.test.ts | 9 +- .../commands/browser-page-targeting.spec.ts | 127 ++++++ ...orca-runtime-serve-browser-restore.test.ts | 6 +- .../client/peer-desktops.integration.test.ts | 2 +- .../runtime/construction/orca-runtime.test.ts | 147 +++---- .../orca-runtime-test-fixtures.spec.ts | 52 +-- .../orca-runtime-test-lifecycle.spec.ts | 58 +-- ...rca-runtime-test-scenario-builders.spec.ts | 26 +- .../runtime-durable-store-fixture.ts | 14 +- .../runtime-store-partial-fixture.ts | 14 +- .../runtime-test-module-registration.spec.ts | 73 ++++ ...ile-relay-host-catalog.integration.test.ts | 2 +- .../multi-client-terminal.integration.test.ts | 4 +- .../headless-snapshots.spec.ts | 212 ---------- .../mobile-summaries-part-04.spec.ts | 133 ------- ...oject-setup-folder-remote-identity.spec.ts | 365 ------------------ .../runtime-test-module-registration.spec.ts | 73 ---- .../targeting-and-resilience.spec.ts | 310 --------------- ...nal-creation-and-readiness-part-06.spec.ts | 172 --------- ...l-handles-and-agent-status-part-04.spec.ts | 234 ----------- ...l-handles-and-agent-status-part-05.spec.ts | 81 ---- .../terminal-listing.spec.ts | 149 ------- ...terminal-side-effect-facts-part-02.spec.ts | 260 ------------- .../worktree-ps-structured-host.spec.ts | 87 ----- ...removal-and-reconciliation-part-02.spec.ts | 108 ------ .../worktree-scan-cache-ttl.spec.ts | 98 ----- .../worktree-selector-resolution.spec.ts | 106 ----- ...worktree-setup-and-startup-part-04.spec.ts | 87 ----- .../wsl-stopped-distro-worktree-scan.spec.ts | 89 ----- .../runtime-orchestration-db.test-fixture.ts | 10 +- ...ation-mailbox-notification-test-harness.ts | 2 +- .../lineage-and-scan-cache-part-05.spec.ts | 172 +-------- ...pencode-finished-session-authority.test.ts | 2 +- ...rker-terminal-recovery-persistence.test.ts | 2 +- ...-chat-coordinator-mail-rig.test-fixture.ts | 2 +- .../terminal-creation-and-readiness.spec.ts | 141 +------ ...ker-recovery-releases-conversation.test.ts | 14 +- .../codex-reconnect-failed-dispatch.test.ts | 2 +- ...ime-mobile-notification-controller.spec.ts | 38 ++ ...oject-setup-folder-remote-identity.spec.ts | 156 ++++++++ .../repo-icon-fork-backfill.test.ts | 2 +- ...ository-project-operations-part-02.spec.ts | 31 +- .../runtime-remove-project-host-scope.test.ts | 2 +- ...repository-registration-controller.test.ts | 2 +- .../managed-cwd-launch.test-fixture.ts | 6 +- ...status-machine-name-publish-budget.test.ts | 2 +- .../federation-liveness-verdict.test.ts | 2 +- .../structured-worker-tab-retirement.test.ts | 2 +- ...worker-release-runtime-incarnation.spec.ts | 2 +- ...ructured-codex-session-rpc-test-harness.ts | 2 +- .../worktree-rm-cli.integration.test.ts | 2 +- ...elegated-mobile-device.integration.test.ts | 2 +- ...time-rpc-mobile-terminal-streaming.test.ts | 2 +- .../window-authority.spec.ts | 6 +- ...gent-resume-spawn-commands.test-fixture.ts | 0 ...session-tabs-targeted-agent-resume.spec.ts | 26 +- ...runtime-mobile-markdown-tab-routes.test.ts | 6 +- ...ssion-tabs-empty-headless-snapshot.spec.ts | 8 +- .../mobile-creation-and-orchestration.spec.ts | 17 +- .../mobile-session-tabs-part-03.spec.ts | 22 +- .../mobile-session-tabs-part-12.spec.ts | 178 +-------- .../mobile-session-tabs-part-13.spec.ts | 17 +- .../mobile-terminal-create-resilience.spec.ts | 145 +++++++ .../split-placement-session.test-fixture.ts | 4 +- .../mobile-session-tab-event-wait.ts | 2 +- .../mobile-session-tabs-part-09.spec.ts | 15 +- .../publication}/mobile-session-tabs.spec.ts | 21 +- .../mobile-session-tabs-part-02.spec.ts | 12 +- .../mobile-session-tabs-part-07.spec.ts | 20 +- .../mobile-session-tabs-part-08.spec.ts | 18 +- ...ssion-tabs-windowless-sleep-resume.spec.ts | 55 +-- .../exit-retirement-activation.spec.ts | 8 +- .../mobile-session-tabs-part-04.spec.ts | 18 +- .../mobile-session-tabs-part-05.spec.ts | 21 +- .../mobile-session-tabs-part-10.spec.ts | 12 +- .../mobile-session-tabs-part-11.spec.ts | 25 +- .../orca-runtime-workspace-unread.test.ts | 2 +- .../mobile-summaries-part-02.spec.ts | 18 +- .../mobile-summaries-part-03.spec.ts | 18 +- .../mobile-summaries-part-04.spec.ts | 59 +++ .../workspace-facts}/mobile-summaries.spec.ts | 8 +- ...l-handles-and-agent-status-part-04.spec.ts | 116 ++++++ ...output-and-worker-recovery-part-02.spec.ts | 18 +- ...output-and-worker-recovery-part-06.spec.ts | 18 +- ...output-and-worker-recovery-part-07.spec.ts | 10 +- ...nal-creation-and-readiness-part-08.spec.ts | 21 +- .../identity/exported-pane-key-follow.test.ts | 6 +- .../identity/main-pane-record-arrival.test.ts | 8 +- ...untime-terminal-handle-incarnation.test.ts | 4 +- .../terminal-handles-and-agent-status.spec.ts | 14 +- .../terminal-handles-part-02.spec.ts | 56 +-- .../identity}/terminal-handles.spec.ts | 145 +------ .../terminal-identity-schedules.test.ts | 2 +- .../qoder-independent-spawn-review.test.ts | 14 +- .../qoder-mobile-resume-adoption.test.ts | 21 +- ...nal-creation-and-readiness-part-04.spec.ts | 21 +- .../launch/terminal-pty-exit-waiter.spec.ts | 2 +- .../layout}/bind-first-pane.test-fixture.ts | 21 +- .../main-owned-workspace-runtime-fixture.ts | 2 +- ...orca-runtime-layout-owner-start-fixture.ts | 21 +- .../remote-desktop-headless-park.test.ts | 2 +- .../session-layout-apply.test-fixture.ts | 8 +- ...ca-runtime-exited-split-pane-close.test.ts | 2 +- .../pty-inventory-lifecycle-fixture.ts | 2 +- ...inal-list-pending-pty-registration.test.ts | 2 +- .../output/headless-snapshots.spec.ts | 75 ++++ .../stale-title-display-surfaces.test.ts | 8 +- ...nal-creation-and-readiness-part-11.spec.ts | 19 +- .../terminal-restore-record-seed.test.ts | 2 +- ...terminal-side-effect-facts-part-02.spec.ts | 83 ++++ .../trust-dialog-status-observer.test.ts | 2 +- .../agent-status-and-waits-part-02.spec.ts | 13 +- .../query}/conpty-stream-read.spec.ts | 13 +- ...nal-creation-and-readiness-part-09.spec.ts | 11 +- ...nal-creation-and-readiness-part-10.spec.ts | 79 +--- .../query/terminal-identity.test-fixture.ts | 7 +- .../terminal-listing-fresh-liveness.spec.ts | 25 ++ .../restored-pane-hook-store-resume.test.ts | 10 +- .../restored-pane-start-layout-owner.test.ts | 8 +- ...rminal-pane-recovery-liveness-gate.test.ts | 6 +- .../project-removal-terminal-stop.test.ts | 4 +- ...erminal-sleep-and-teardown-part-02.spec.ts | 277 +------------ ...erminal-sleep-and-teardown-part-03.spec.ts | 30 +- .../stop}/terminal-sleep-and-teardown.spec.ts | 53 +-- ...-sleep-idempotency-and-convergence.spec.ts | 194 ++++++++++ ...adless-create-terminal-handle-main.test.ts | 6 +- ...ime-terminal-close-spill-partition.spec.ts | 2 +- ...terminal-retirement-host-partition.spec.ts | 2 +- .../orca-runtime-terminal-retirement.test.ts | 2 +- ...retirement-proof-publication-order.spec.ts | 2 +- ...owned-terminal-publication-lineage.test.ts | 8 +- .../terminal-list-surface-lost-orphan.spec.ts | 4 +- .../terminal-surface-replies-main.test.ts | 2 +- .../terminal-surface-replies.test-fixture.ts | 6 +- ...space-layout-stream-events.test-fixture.ts | 6 +- .../surface/workspace-layout-stream.test.ts | 2 +- ...-runtime-terminal-rename-retention.test.ts | 8 +- .../active-worktree-context-parity.test.ts | 2 +- .../agent-startup-blocked-message.test.ts | 5 +- .../agent-transcript-pane-test-harness.ts | 14 +- .../claude-dialog-interactive-wait.test.ts | 5 +- .../hermes-slash-readiness-transcript.test.ts | 2 +- ...ed-agent-composer-readiness-claude.test.ts | 5 +- .../wait/launched-agent-exit-watch.test.ts | 5 +- ...creation-and-orchestration-part-04.spec.ts | 54 +-- .../wait/omp-readiness-transcripts.test.ts | 5 +- ...nal-creation-and-readiness-part-06.spec.ts | 67 ++++ ...rminal-interactive-wait-visibility.test.ts | 2 +- .../terminal-start-failure-readiness.test.ts | 5 +- .../wait/terminal-wait-name-only-idle.test.ts | 2 +- .../wait/tui-idle-claude-cold-start.test.ts | 5 +- .../wait/tui-idle-codex-plan-menu.test.ts | 5 +- .../wait/tui-idle-command-paint.test.ts | 5 +- .../wait/tui-idle-hook-lane-runtime.test.ts | 2 +- ...-zsh-preexec-hook-order.live-shell.test.ts | 5 +- ...workspace-selector-folder-matching.test.ts | 2 +- .../worktree-scan-repeated-path.test.ts | 2 +- .../worktree-selector-resolution.spec.ts | 46 +++ .../creation}/local-worktree-creation.spec.ts | 25 +- .../managed-worktree-create-telemetry.test.ts | 2 +- ...worktree-provisioning-availability.test.ts | 8 +- ...-folder-workspace-wsl-launch-scope.test.ts | 6 +- .../lineage-and-scan-cache-part-02.spec.ts | 43 +-- .../lineage}/lineage-and-scan-cache.spec.ts | 17 +- .../worktree-ps-agent-wait.spec.ts | 16 +- .../worktree-ps-degraded-repo-scan.test.ts | 2 +- .../worktree-ps-structured-host.spec.ts | 57 +++ ...worktree-ps-unverifiable-terminals.test.ts | 2 +- .../gitlab-and-pr-bases-part-02.spec.ts | 18 +- .../hooks-and-hosted-review-part-02.spec.ts | 16 +- .../owned-session-teardown-policy.test.ts | 6 +- .../runtime-worktree-removal-pty-stop.spec.ts | 74 ++++ ...removal-and-reconciliation-part-02.spec.ts | 60 +++ ...removal-and-reconciliation-part-03.spec.ts | 115 +----- ...removal-and-reconciliation-part-04.spec.ts | 24 +- .../worktree-removal-failed-retry.spec.ts | 21 +- ...older-workspace-mixed-host-routing.test.ts | 4 +- .../folder-workspace-pty-identity.test.ts | 2 +- .../automatic-activation-host-sleep.test.ts | 6 +- ...worktree-setup-and-startup-part-03.spec.ts | 27 +- ...nt-launch-reserved-session-id.unit.test.ts | 88 ----- ...-session-clear-old-tab-mirror.unit.test.ts | 72 ---- ...session-cli-missing-downgrade.unit.test.ts | 39 -- ...-handle-replacement-downgrade.unit.test.ts | 231 ----------- ...on-interrupted-tool-downgrade.unit.test.ts | 116 ------ ...sion-kill-delivered-downgrade.unit.test.ts | 206 ---------- ...ssion-resume-marker-downgrade.unit.test.ts | 76 ---- ...nt-session-newer-chat-refusal.unit.test.ts | 79 +--- ...-session-stop-event-downgrade.unit.test.ts | 73 +--- ...ersion-host-observed-turn-end.unit.test.ts | 86 +---- .../structured-agent-session-host-fixture.ts | 20 +- .../structured-agent-session-surface-calls.ts | 2 +- ...uctured-agent-session-surface-execution.ts | 19 +- ...ructured-agent-session-surface-manifest.ts | 20 +- .../versioned-agent-session-wire.ts | 28 +- .../released-chat-continuation.ts | 12 +- .../released-chat-journal.ts | 6 +- .../released-chat-queue.ts | 6 +- .../released-chat-writers.ts | 18 +- ...leased-journal-sql-workers.test-fixture.ts | 0 .../cross-version-stopping.unit.test.ts | 163 -------- .../cross-version-terminal-wire.unit.test.ts | 185 --------- ...s-version-worktree-ps-verdict.unit.test.ts | 218 ----------- ...hestration-delivery-downgrade.unit.test.ts | 75 ---- ...s-version-device-key-registry.unit.test.ts | 8 +- ...version-mobile-direct-e2ee-v2.unit.test.ts | 8 +- ...on-paired-e2ee-handshake-core.unit.test.ts | 10 +- .../cross-version-pairing-ticket.unit.test.ts | 12 +- ...s-version-web-session-pairing.unit.test.ts | 11 +- ...oder-history-search-downgrade.unit.test.ts | 222 ----------- .../legacy-relay-bridge.unit.test.ts | 117 ++---- .../{ => relay}/released-relay-daemon.ts | 10 +- .../{ => relay}/released-relay-transport.ts | 6 +- .../release-checkout-prefetch.ts | 0 .../release-checkout-process.ts | 0 .../release-checkout-publication.ts | 0 .../release-checkout-tree.ts | 2 +- .../release-checkout-tree.unit.test.ts | 27 -- .../release-checkout.ts | 12 +- .../release-checkout.unit.test.ts | 140 +------ .../release-fixture-setup.ts | 0 .../release-missing-packages.ts | 0 .../release-missing-packages.unit.test.ts | 0 .../release-module-locations.ts | 0 .../release-source-cache.ts | 2 +- .../release-source-retention.ts | 0 .../release-source-retention.unit.test.ts | 29 ++ .../release-source-retention.unit.test.ts | 79 ---- .../released-chat-upgrade.unit.test.ts | 255 ------------ ...ported-lossy-initial-snapshot.unit.test.ts | 160 -------- ...ubmission-positions-downgrade.unit.test.ts | 200 ---------- .../host-terminal-runtime-stub.ts | 0 .../published-field-shape.ts | 0 .../terminal-skew-journey.ts | 0 .../terminal-wire-link.ts | 0 .../versioned-terminal-wire.ts | 10 +- ...n-worktree-identity-downgrade.unit.test.ts | 7 +- ...untime-source-fence-downgrade.unit.test.ts | 28 +- .../helpers/build-released-relay-bundle.mts | 4 +- tests/e2e/helpers/legacy-relay-docker-host.ts | 2 +- tests/e2e/remote-terminal-input-model-link.ts | 2 +- .../active-tab-publication.test-fixture.ts | 4 +- ...ile-session-legacy-navigation.unit.test.ts | 4 +- 262 files changed, 2632 insertions(+), 7810 deletions(-) create mode 100644 src/main/runtime/agent-session/launch/runtime-native-chat-draft-resolutions.spec.ts rename src/main/runtime/{orca-runtime-tests => agent-session/testing}/scripted-codex-transport.test-fixture.ts (73%) rename src/main/runtime/{orca-runtime-tests => browser/client-pages}/browser-capabilities.spec.ts (54%) rename src/main/runtime/{orca-runtime-tests => browser/client-pages}/browser-page-inventory.test.ts (88%) create mode 100644 src/main/runtime/browser/commands/browser-page-targeting.spec.ts rename src/main/runtime/{orca-runtime-tests => construction/test-context}/orca-runtime-test-fixtures.spec.ts (89%) rename src/main/runtime/{orca-runtime-tests => construction/test-context}/orca-runtime-test-lifecycle.spec.ts (86%) rename src/main/runtime/{orca-runtime-tests => construction/test-context}/orca-runtime-test-scenario-builders.spec.ts (92%) rename src/main/runtime/{orca-runtime-tests => construction/test-context}/runtime-durable-store-fixture.ts (85%) rename src/main/runtime/{orca-runtime-tests => construction/test-context}/runtime-store-partial-fixture.ts (85%) create mode 100644 src/main/runtime/construction/test-context/runtime-test-module-registration.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/headless-snapshots.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/mobile-summaries-part-04.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/project-setup-folder-remote-identity.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/targeting-and-resilience.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-06.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-04.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-05.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/terminal-listing.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-02.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-02.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/worktree-scan-cache-ttl.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/worktree-selector-resolution.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-04.spec.ts delete mode 100644 src/main/runtime/orca-runtime-tests/wsl-stopped-distro-worktree-scan.spec.ts rename src/main/runtime/{orca-runtime-tests => orchestration/db}/runtime-orchestration-db.test-fixture.ts (91%) rename src/main/runtime/{orca-runtime-tests => orchestration/terminal-authority}/lineage-and-scan-cache-part-05.spec.ts (53%) rename src/main/runtime/{orca-runtime-tests => orchestration/terminal-authority}/terminal-creation-and-readiness.spec.ts (55%) rename src/main/runtime/{orca-runtime-tests => orchestration/terminal-authority}/worker-recovery-releases-conversation.test.ts (86%) create mode 100644 src/main/runtime/push/notifications/runtime-mobile-notification-controller.spec.ts create mode 100644 src/main/runtime/repositories/project-setup-folder-remote-identity.spec.ts rename src/main/runtime/{orca-runtime-tests => repositories}/repository-project-operations-part-02.spec.ts (84%) rename src/main/runtime/{orca-runtime-tests => session-graph}/window-authority.spec.ts (96%) rename src/main/runtime/{orca-runtime-tests => session-lifecycle/projection}/agent-resume-spawn-commands.test-fixture.ts (100%) rename src/main/runtime/{orca-runtime-tests => session-lifecycle/projection}/mobile-session-tabs-targeted-agent-resume.spec.ts (91%) rename src/main/runtime/{orca-runtime-tests => session-tabs/inventory}/mobile-session-tabs-empty-headless-snapshot.spec.ts (91%) rename src/main/runtime/{orca-runtime-tests => session-tabs/layout}/mobile-creation-and-orchestration.spec.ts (92%) rename src/main/runtime/{orca-runtime-tests => session-tabs/layout}/mobile-session-tabs-part-03.spec.ts (87%) rename src/main/runtime/{orca-runtime-tests => session-tabs/layout}/mobile-session-tabs-part-12.spec.ts (50%) rename src/main/runtime/{orca-runtime-tests => session-tabs/layout}/mobile-session-tabs-part-13.spec.ts (96%) create mode 100644 src/main/runtime/session-tabs/layout/mobile-terminal-create-resilience.spec.ts rename src/main/runtime/{orca-runtime-tests => session-tabs/layout}/split-placement-session.test-fixture.ts (89%) rename src/main/runtime/{orca-runtime-tests => session-tabs/publication}/mobile-session-tab-event-wait.ts (64%) rename src/main/runtime/{orca-runtime-tests => session-tabs/publication}/mobile-session-tabs-part-09.spec.ts (81%) rename src/main/runtime/{orca-runtime-tests => session-tabs/publication}/mobile-session-tabs.spec.ts (82%) rename src/main/runtime/{orca-runtime-tests => session-tabs/restoration}/mobile-session-tabs-part-02.spec.ts (87%) rename src/main/runtime/{orca-runtime-tests => session-tabs/restoration}/mobile-session-tabs-part-07.spec.ts (79%) rename src/main/runtime/{orca-runtime-tests => session-tabs/restoration}/mobile-session-tabs-part-08.spec.ts (94%) rename src/main/runtime/{orca-runtime-tests => session-tabs/restoration}/mobile-session-tabs-windowless-sleep-resume.spec.ts (64%) rename src/main/runtime/{orca-runtime-tests => session-tabs/terminal-retirement}/exit-retirement-activation.spec.ts (93%) rename src/main/runtime/{orca-runtime-tests => session-tabs/terminal-retirement}/mobile-session-tabs-part-04.spec.ts (86%) rename src/main/runtime/{orca-runtime-tests => session-tabs/terminal-retirement}/mobile-session-tabs-part-05.spec.ts (93%) rename src/main/runtime/{orca-runtime-tests => session-tabs/terminal-retirement}/mobile-session-tabs-part-10.spec.ts (95%) rename src/main/runtime/{orca-runtime-tests => session-tabs/terminal-retirement}/mobile-session-tabs-part-11.spec.ts (95%) rename src/main/runtime/{orca-runtime-tests => sidebar-inputs/workspace-facts}/mobile-summaries-part-02.spec.ts (92%) rename src/main/runtime/{orca-runtime-tests => sidebar-inputs/workspace-facts}/mobile-summaries-part-03.spec.ts (89%) create mode 100644 src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-04.spec.ts rename src/main/runtime/{orca-runtime-tests => sidebar-inputs/workspace-facts}/mobile-summaries.spec.ts (94%) create mode 100644 src/main/runtime/terminal/adoption/terminal-handles-and-agent-status-part-04.spec.ts rename src/main/runtime/{orca-runtime-tests => terminal/adoption}/terminal-output-and-worker-recovery-part-02.spec.ts (79%) rename src/main/runtime/{orca-runtime-tests => terminal/adoption}/terminal-output-and-worker-recovery-part-06.spec.ts (90%) rename src/main/runtime/{orca-runtime-tests => terminal/adoption}/terminal-output-and-worker-recovery-part-07.spec.ts (96%) rename src/main/runtime/{orca-runtime-tests => terminal/focus}/terminal-creation-and-readiness-part-08.spec.ts (83%) rename src/main/runtime/{orca-runtime-tests => terminal/identity}/terminal-handles-and-agent-status.spec.ts (94%) rename src/main/runtime/{orca-runtime-tests => terminal/identity}/terminal-handles-part-02.spec.ts (51%) rename src/main/runtime/{orca-runtime-tests => terminal/identity}/terminal-handles.spec.ts (52%) rename src/main/runtime/{orca-runtime-tests => terminal/launch}/terminal-creation-and-readiness-part-04.spec.ts (80%) rename src/main/runtime/{orca-runtime-tests => terminal/layout}/bind-first-pane.test-fixture.ts (91%) rename src/main/runtime/{orca-runtime-tests => terminal/layout}/orca-runtime-layout-owner-start-fixture.ts (75%) rename src/main/runtime/{orca-runtime-tests => terminal/layout}/session-layout-apply.test-fixture.ts (65%) create mode 100644 src/main/runtime/terminal/output/headless-snapshots.spec.ts rename src/main/runtime/{orca-runtime-tests => terminal/output}/terminal-creation-and-readiness-part-11.spec.ts (86%) create mode 100644 src/main/runtime/terminal/output/terminal-side-effect-facts-part-02.spec.ts rename src/main/runtime/{orca-runtime-tests => terminal/query}/agent-status-and-waits-part-02.spec.ts (81%) rename src/main/runtime/{orca-runtime-tests => terminal/query}/conpty-stream-read.spec.ts (81%) rename src/main/runtime/{orca-runtime-tests => terminal/query}/terminal-creation-and-readiness-part-09.spec.ts (94%) rename src/main/runtime/{orca-runtime-tests => terminal/query}/terminal-creation-and-readiness-part-10.spec.ts (71%) create mode 100644 src/main/runtime/terminal/query/terminal-listing-fresh-liveness.spec.ts rename src/main/runtime/{orca-runtime-tests => terminal/stop}/terminal-sleep-and-teardown-part-02.spec.ts (58%) rename src/main/runtime/{orca-runtime-tests => terminal/stop}/terminal-sleep-and-teardown-part-03.spec.ts (90%) rename src/main/runtime/{orca-runtime-tests => terminal/stop}/terminal-sleep-and-teardown.spec.ts (64%) create mode 100644 src/main/runtime/terminal/stop/terminal-sleep-idempotency-and-convergence.spec.ts rename src/main/runtime/{orca-runtime-tests => terminal/surface}/workspace-layout-stream-events.test-fixture.ts (83%) rename src/main/runtime/{orca-runtime-tests => terminal/wait}/agent-transcript-pane-test-harness.ts (91%) rename src/main/runtime/{orca-runtime-tests => terminal/wait}/mobile-creation-and-orchestration-part-04.spec.ts (51%) create mode 100644 src/main/runtime/terminal/wait/terminal-creation-and-readiness-part-06.spec.ts create mode 100644 src/main/runtime/workspaces/catalog/worktree-selector-resolution.spec.ts rename src/main/runtime/{orca-runtime-tests => workspaces/creation}/local-worktree-creation.spec.ts (87%) rename src/main/runtime/{orca-runtime-tests => workspaces/lineage}/lineage-and-scan-cache-part-02.spec.ts (79%) rename src/main/runtime/{orca-runtime-tests => workspaces/lineage}/lineage-and-scan-cache.spec.ts (82%) rename src/main/runtime/{orca-runtime-tests => workspaces/process-listing}/worktree-ps-agent-wait.spec.ts (82%) create mode 100644 src/main/runtime/workspaces/process-listing/worktree-ps-structured-host.spec.ts rename src/main/runtime/{orca-runtime-tests => workspaces/references}/gitlab-and-pr-bases-part-02.spec.ts (86%) rename src/main/runtime/{orca-runtime-tests => workspaces/references}/hooks-and-hosted-review-part-02.spec.ts (82%) create mode 100644 src/main/runtime/workspaces/removal/runtime-worktree-removal-pty-stop.spec.ts create mode 100644 src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-02.spec.ts rename src/main/runtime/{orca-runtime-tests => workspaces/removal}/worktree-removal-and-reconciliation-part-03.spec.ts (66%) rename src/main/runtime/{orca-runtime-tests => workspaces/removal}/worktree-removal-and-reconciliation-part-04.spec.ts (86%) rename src/main/runtime/{orca-runtime-tests => workspaces/removal}/worktree-removal-failed-retry.spec.ts (84%) rename src/main/runtime/{orca-runtime-tests => workspaces/startup}/worktree-setup-and-startup-part-03.spec.ts (57%) delete mode 100644 tests/e2e/cross-version-wire/agent-launch-reserved-session-id.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-clear-old-tab-mirror.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-cli-missing-downgrade.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-handle-replacement-downgrade.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-interrupted-tool-downgrade.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-kill-delivered-downgrade.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/agent-session-resume-marker-downgrade.unit.test.ts rename tests/e2e/cross-version-wire/{ => agent-sessions}/agent-session-newer-chat-refusal.unit.test.ts (63%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/agent-session-stop-event-downgrade.unit.test.ts (57%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/cross-version-host-observed-turn-end.unit.test.ts (50%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/structured-agent-session-host-fixture.ts (89%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/structured-agent-session-surface-calls.ts (99%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/structured-agent-session-surface-execution.ts (90%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/structured-agent-session-surface-manifest.ts (93%) rename tests/e2e/cross-version-wire/{ => agent-sessions}/versioned-agent-session-wire.ts (86%) rename tests/e2e/cross-version-wire/{ => chat-journals}/released-chat-continuation.ts (79%) rename tests/e2e/cross-version-wire/{ => chat-journals}/released-chat-journal.ts (77%) rename tests/e2e/cross-version-wire/{ => chat-journals}/released-chat-queue.ts (84%) rename tests/e2e/cross-version-wire/{ => chat-journals}/released-chat-writers.ts (91%) rename tests/e2e/cross-version-wire/{ => chat-journals}/released-journal-sql-workers.test-fixture.ts (100%) delete mode 100644 tests/e2e/cross-version-wire/cross-version-stopping.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/cross-version-worktree-ps-verdict.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/orchestration-delivery-downgrade.unit.test.ts rename tests/e2e/cross-version-wire/{ => pairing}/cross-version-device-key-registry.unit.test.ts (91%) rename tests/e2e/cross-version-wire/{ => pairing}/cross-version-mobile-direct-e2ee-v2.unit.test.ts (93%) rename tests/e2e/cross-version-wire/{ => pairing}/cross-version-paired-e2ee-handshake-core.unit.test.ts (92%) rename tests/e2e/cross-version-wire/{ => pairing}/cross-version-pairing-ticket.unit.test.ts (88%) rename tests/e2e/cross-version-wire/{ => pairing}/cross-version-web-session-pairing.unit.test.ts (85%) delete mode 100644 tests/e2e/cross-version-wire/qoder-history-search-downgrade.unit.test.ts rename tests/e2e/cross-version-wire/{ => relay}/legacy-relay-bridge.unit.test.ts (72%) rename tests/e2e/cross-version-wire/{ => relay}/released-relay-daemon.ts (95%) rename tests/e2e/cross-version-wire/{ => relay}/released-relay-transport.ts (93%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout-prefetch.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout-process.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout-publication.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout-tree.ts (98%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout-tree.unit.test.ts (92%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout.ts (95%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-checkout.unit.test.ts (68%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-fixture-setup.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-missing-packages.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-missing-packages.unit.test.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-module-locations.ts (100%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-source-cache.ts (98%) rename tests/e2e/cross-version-wire/{ => release-checkouts}/release-source-retention.ts (100%) create mode 100644 tests/e2e/cross-version-wire/release-checkouts/release-source-retention.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/release-source-retention.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/released-chat-upgrade.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts delete mode 100644 tests/e2e/cross-version-wire/submission-positions-downgrade.unit.test.ts rename tests/e2e/cross-version-wire/{ => terminal-streams}/host-terminal-runtime-stub.ts (100%) rename tests/e2e/cross-version-wire/{ => terminal-streams}/published-field-shape.ts (100%) rename tests/e2e/cross-version-wire/{ => terminal-streams}/terminal-skew-journey.ts (100%) rename tests/e2e/cross-version-wire/{ => terminal-streams}/terminal-wire-link.ts (100%) rename tests/e2e/cross-version-wire/{ => terminal-streams}/versioned-terminal-wire.ts (93%) rename tests/e2e/cross-version-wire/{ => workspace-identity}/cross-version-worktree-identity-downgrade.unit.test.ts (96%) rename tests/e2e/cross-version-wire/{ => workspace-identity}/runtime-source-fence-downgrade.unit.test.ts (81%) diff --git a/config/flaky-test-pattern-baseline.txt b/config/flaky-test-pattern-baseline.txt index a42e829f38d..f0c1cdb9e10 100644 --- a/config/flaky-test-pattern-baseline.txt +++ b/config/flaky-test-pattern-baseline.txt @@ -49,8 +49,8 @@ 1 test-no-polling-loop:tests/e2e/browser-guest-crash-recovery.spec.ts 1 test-no-polling-loop:tests/e2e/browser-tab.spec.ts 1 test-no-polling-loop:tests/e2e/chinese-ime-chat-input-repro.spec.ts -1 test-no-polling-loop:tests/e2e/cross-version-wire/released-relay-daemon.ts -1 test-no-polling-loop:tests/e2e/cross-version-wire/released-relay-transport.ts +1 test-no-polling-loop:tests/e2e/cross-version-wire/relay/released-relay-daemon.ts +1 test-no-polling-loop:tests/e2e/cross-version-wire/relay/released-relay-transport.ts 1 test-no-polling-loop:tests/e2e/daemon-lifecycle-retirement.spec.ts 1 test-no-polling-loop:tests/e2e/fixtures/daemon-generation-legacy-close-client.ts 1 test-no-polling-loop:tests/e2e/fixtures/daemon-generation-reconnect-client.ts @@ -181,9 +181,9 @@ 9 test-no-real-time-wait:tests/e2e/chinese-ime-chat-input-repro.spec.ts 2 test-no-real-time-wait:tests/e2e/cli-floating-file-open-position.spec.ts 1 test-no-real-time-wait:tests/e2e/codex-ctrl-c-status.spec.ts -1 test-no-real-time-wait:tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts -1 test-no-real-time-wait:tests/e2e/cross-version-wire/released-relay-daemon.ts -2 test-no-real-time-wait:tests/e2e/cross-version-wire/released-relay-transport.ts +1 test-no-real-time-wait:tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts +1 test-no-real-time-wait:tests/e2e/cross-version-wire/relay/released-relay-daemon.ts +2 test-no-real-time-wait:tests/e2e/cross-version-wire/relay/released-relay-transport.ts 1 test-no-real-time-wait:tests/e2e/daemon-lifecycle-retirement.spec.ts 2 test-no-real-time-wait:tests/e2e/default-tabs-mark-crash-relaunch.spec.ts 1 test-no-real-time-wait:tests/e2e/diff-note-draft.spec.ts @@ -429,8 +429,8 @@ 10 test-no-wall-clock:src/wsl-guest/agent-hooks/publication/agent-hook-integration.test.ts 1 test-no-wall-clock:src/wsl-guest/agent-hooks/server/agent-hook-server.test.ts 1 test-no-wall-clock:src/wsl-guest/agent-hooks/presence/relay-idle-process-owner.test.ts -2 test-no-wall-clock:tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts -4 test-no-wall-clock:tests/e2e/cross-version-wire/release-checkout.unit.test.ts +2 test-no-wall-clock:tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts +2 test-no-wall-clock:tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts 1 test-no-wall-clock:tests/e2e/host-cold-park-remote-subscriber.unit.test.ts 1 test-timeout-needs-reason:src/cli/agents/agent-launch-process.test.ts 1 test-timeout-needs-reason:src/cli/runtime/serve/startup/serve-pid1-init-reaper.test.ts @@ -507,11 +507,8 @@ 1 test-timeout-needs-reason:tests/e2e/cli-agent-unopened-workspace-resume.spec.ts 1 test-timeout-needs-reason:tests/e2e/combined-diff-invalidation-freeze-repro.spec.ts 1 test-timeout-needs-reason:tests/e2e/completed-worker-retirement-resume.spec.ts -2 test-timeout-needs-reason:tests/e2e/cross-version-wire/agent-session-newer-chat-refusal.unit.test.ts -3 test-timeout-needs-reason:tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts -4 test-timeout-needs-reason:tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts -3 test-timeout-needs-reason:tests/e2e/cross-version-wire/release-checkout.unit.test.ts -2 test-timeout-needs-reason:tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts +3 test-timeout-needs-reason:tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts +2 test-timeout-needs-reason:tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts 1 test-timeout-needs-reason:tests/e2e/csv-paged-preview.spec.ts 1 test-timeout-needs-reason:tests/e2e/csv-url-links.spec.ts 1 test-timeout-needs-reason:tests/e2e/cursor-quota-transport.unit.test.ts diff --git a/config/legacy-relay-compat-tags-baseline.txt b/config/legacy-relay-compat-tags-baseline.txt index 35b7d966e3f..8b6b8998024 100644 --- a/config/legacy-relay-compat-tags-baseline.txt +++ b/config/legacy-relay-compat-tags-baseline.txt @@ -25,9 +25,9 @@ src/renderer/src/store/terminals/retirement/legacy-relay-bridged-tab-close.ts src/shared/remote-runtime/relay/legacy-relay-bridge-contract.ts src/shared/remote-runtime/ssh/ssh-types.ts src/shared/telemetry/schemas/telemetry-ssh-host-server-event-schemas.ts -tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts -tests/e2e/cross-version-wire/released-relay-daemon.ts -tests/e2e/cross-version-wire/released-relay-transport.ts +tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts +tests/e2e/cross-version-wire/relay/released-relay-daemon.ts +tests/e2e/cross-version-wire/relay/released-relay-transport.ts tests/e2e/helpers/build-released-relay-bundle.mts tests/e2e/helpers/legacy-relay-docker-host.ts tests/e2e/helpers/orcad-upgrade-profile.ts diff --git a/config/legacy-relay-importers-baseline.txt b/config/legacy-relay-importers-baseline.txt index 44d3041afea..66b9faada11 100644 --- a/config/legacy-relay-importers-baseline.txt +++ b/config/legacy-relay-importers-baseline.txt @@ -9,7 +9,7 @@ src/main/ipc/ssh/ssh-host-server-on-connect-wiring.ts src/main/ipc/ssh/ssh-session-teardown.ts src/main/ipc/ssh/ssh.ts src/main/managed-server/lifecycle/orcad-runtime-conversion-wiring.ts -tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts +tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts tests/e2e/helpers/legacy-relay-docker-host.ts src/main/managed-server/install/remote-install-model.ts src/main/ssh/system-transport/ssh-system-transport.integration.test.ts diff --git a/config/path-literal-baseline.txt b/config/path-literal-baseline.txt index 7fa833955d9..5cbdc849824 100644 --- a/config/path-literal-baseline.txt +++ b/config/path-literal-baseline.txt @@ -19,9 +19,9 @@ config/tsconfig.node.json src/renderer/src/components/native-chat/native-chat-co config/tsconfig.node.json src/renderer/src/components/native-chat/native-chat-resolution-receipt.ts config/tsconfig.node.json src/renderer/src/components/native-chat/structured-agent-question-projection.ts tests/e2e/capture-opencode-tui-repro.mjs src/cli/cmd/tui/ui/spinner -tests/e2e/cross-version-wire/released-chat-writers.ts src/main/native-chat/agent-session-wire/structured-agent-session-event-sink.ts +tests/e2e/cross-version-wire/chat-journals/released-chat-writers.ts src/main/native-chat/agent-session-wire/structured-agent-session-event-sink.ts # Released source trees retain this actual registry; the current registry is checked first. -tests/e2e/cross-version-wire/release-module-locations.ts src/main/runtime/rpc/methods/index.ts -tests/e2e/cross-version-wire/release-module-locations.ts src/renderer/src/runtime/remote-runtime-terminal-multiplexer.ts +tests/e2e/cross-version-wire/release-checkouts/release-module-locations.ts src/main/runtime/rpc/methods/index.ts +tests/e2e/cross-version-wire/release-checkouts/release-module-locations.ts src/renderer/src/runtime/remote-runtime-terminal-multiplexer.ts # The rollback negative control restores this source from its fixed affected archive. config/scripts/runtime-verification/ephemeral-store/run-ephemeral-vm-runtime-store-rollback-repro.mjs src/shared/ephemeral-vm-runtime-store.ts diff --git a/config/reliability-gates.jsonc b/config/reliability-gates.jsonc index 5b48b4a6193..7ebb3ec378e 100644 --- a/config/reliability-gates.jsonc +++ b/config/reliability-gates.jsonc @@ -442,7 +442,7 @@ "id": "terminal-input.prompt-reply-occurrence-acknowledgment", "title": "Terminal chat replies hide only the acknowledged prompt occurrence", "maturity": "experimental", - "protection": "partial", + "protection": "none", "owner": "terminal-runtime", "layer": "renderer-mobile-provider-contract", "surfaces": [ @@ -452,68 +452,16 @@ ], "platforms": ["macos", "linux", "windows"], "providers": ["local", "daemon", "ssh", "wsl", "remote-runtime", "mobile-relay"], - "coveredPlatforms": ["macos"], + "coveredPlatforms": [], "coveredProviders": [], - "coverageNotes": "Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose PTY writer driving-input recording before provider write and launch/query-reply/focus classification alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit3984 retires all four remaining viewport-fixture suites (14 authored/15 finite cases) and the fixture after composing the sender-host deletion. Accepted source-alarm losses include live-region/disclosure continuity, task/question/approval history and revision handling, stale turn status, prompt-dismissal remount/rebind, and pending-send cancellation when approval arrives between body and Enter. No equivalent replacement or fresh runtime validation is claimed. Audits3764/3766 retire16 authored/27 expanded mobile cases, including entire HTML-image syntax, Mermaid routing, table styles, file-query encoding, workspace naming and fresh-Git-status adapter suites. Accepted losses include image width/icon filtering, partial-heading streaming, mocked Mermaid key/identity checks, generated table widths/counts, selected-text caret placement, tiny Base64 chunk encoding, twelve query-path roundtrips, locale-import fallback, apostrophe slugging, fresh-status fallback and an intermediate reviewed marker. These are deliberate removals for marginal value; remaining tests are not equivalent replacements. Earlier receipts are historical and do not validate these deleted/reduced drivers. Audit3748 intentionally removes ten authored/ten finite registrations from the surviving media-handle-registry.test.ts driver selected by this full-mobile command. Retired real alarms: nominal minted handle uniqueness/metadata and dimensions; ordinary range/EOF/overread/empty-file/direct chunk-clamp samples; nominal successful release, expired-release false, exact millisecond TTL boundary and ordinary releaseAll replay. Deterministic registry code runs; these examples are removed on marginal value without replacement or fresh execution claims. Seven owner cases retain cap refusal/disposal and sweep-before-admission, nonempty EOF and unknown/released/expired refusal, read TTL refresh, idempotent explicit release and continuation after discard failure. Existing commands, assertions, unrelated wire receipt and timing remain; the driver survives. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered mobile Vitest command. Its mobile/src include patterns admit the partial live-input-commit and native-media drivers:5 authored/5 finite removals. Accepted losses: two Android-labeled replay samples after mocked composition conversion, an immediate Backspace absence check that does not wait for pending commit or prove local edit, and released-handle/double-release adapter examples. Real hook, registry and adapter logic run; no equivalent replacement or native Android/iOS exercise is claimed. Both drivers and selector stay. The unchanged wire-specific dated receipt does not validate these reduced mobile sources. Audit3666 removes30 authored/36 finite mobile cases, including7 whole drivers. It retires direct consent/channel/token/header-payload/fingerprint/route-object inventories, background legacy-dismissal filtering, the two-row520-entry watermark retention workload, reentrant write-batch example, font-before-ready projection, and legacy-segmenter/scrollback/wrap selection examples. Actual policy, parsing, hashing, tray matching, serialization and xterm buffers execute in these tests; their stated alarms are deliberately lost without replacement. Twelve unchanged authored/19 finite cases retain compact browser geometry regressions, an independent fingerprint-to-host protocol vector, serialized watermark/reload isolation, OSC52 live/replay gating, queue boundaries/reset/generation, disposed font completion and Unicode cell mapping. Pairing classification2/2 was already approved by3657 and receives no3666 delta or credit. Static review only; no runtime, native, provider, browser rendering, OS, remote, mobile/folder parity or new historical fault evidence. Previous account (preserved verbatim): Audit3663 removes the complete mobile scan-error message suite (two authored/two finite callbacks). Its4URL assertion loop is one registration. Accept loss of Orca new/legacy Android-download URL classification and other-page invalid-code translated-key mapping. Real URL parsing/classification runs, but the only output observed is an identity-translator key. No camera scan, pairing offer admission, connection or device/UI action is exercised. No equivalent replacement or physical/mobile/mixed-version result claimed. Preserve all historical evidence and metadata bytes. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The broad mobile runner loses retired-name sequencing and PR action samples while retaining the editor-lifetime and original PR action keeper; commit-message generation is unchanged. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. The broad mobile command loses the entire three-case mocked diff-review controller suite and the stale layout-sequence comparator sample. Keep only the direct layout-versus-scrollback counter distinction; the unchanged dictation retry hook retains complete recording replay. No rendered app, native capture, actual process death or remote execution is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad mobile discovery loses whole prompt-presentation, Jira-URL and folder-source-repository suites. The prompt suite exercised presentation projections; it did not provide native mobile prompt acknowledgment acceptance. Existing direct prompt-controller selectors are unchanged. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The stale-leaf-liveness suite and its exact command/testFiles selector are removed; its fake terminal refusal/liveness alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The entire mocked mobile failure-banner suite and its sole send/previous-banner/new-notice ordering alarm are retired. Its filenames are removed from active selectors. Desktop prompt roots and the independent unchanged terminal wire-codec receipt remain at their stated scopes; no mobile send/recovery proof is claimed. Audit2251 narrows agent-paste-draft.test.ts from 25 authored cases (26 literal cases) to four. Retained cases cover buffered readiness on PTY binding, separate spawn/composer lifetimes, real per-PTY paste/Enter serialization against a competing paste, and frame closure/no Enter after a rejected content chunk. Intentionally lost alarms include agent marker and fallback examples, direct-write failure/rejection, missing-PTY and Codex process-only timeout paths, exact nonprimary-PTY routing, full large-body chunk reconstruction, escaping/CRLF samples, internal laziness/yield work assertions, oversized preflight refusal, and exact configured delay/budget counts. No equivalent replacement, new execution, real PTY/provider delivery, rendered/native UI, deployment, measured performance or cross-platform result is claimed. Historical prior account (preserved verbatim): Mobile owner-layout policy retires whole tests and mixed registrations without equivalent replacement coverage. Retained callbacks and reduced selectors need fresh execution at their stated scope; prior measurements do not validate them. Affected sources: mobile/src/session/mobile-prompt-controller.test.ts, tests/e2e/native-chat-ssh-delivery.unit.test.ts, mobile/src/session/native-chat/use-mobile-native-chat-controller.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-cancel-ask.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-answer-send.test.ts, mobile/src/session/native-chat/transcript/use-mobile-native-chat-message-send.test.ts. Historical scope: Audit2003: Remove agent-prompt absence routing, throwing/live/missing-probe and cached-probe-count examples from the stale-leaf source. Controller-proven absence, unknown-liveness admission, obsolete-absence clearing and same-ID respawn fences remain at a supplied provider/row seam. Preserve the independent wire-codec receipt only in its original scope. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove partial-runtime terminal-send guard/status/floor/query projection and argument-inventory samples. Retained RPC viewport admission, authenticated-client spoof refusal, text admission and stale-binding fences remain bounded mock-boundary behavior. The unchanged wire-codec receipt remains valid only for its original command; it does not validate this reduced RPC selector. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1908 removes the complete prompt-presentation hook and literal interactive-protocol mapping suites and narrows the interactive card and prompt-card input suites. Lost alarms include replacement approval A settling after answered B; collapse/expand composer ownership and partial-answer presentation; identical new waits after an unmounted view; collapsed transcript re-reads; answered/dismissed status-backed persistence and retirement; and literal answer-to-PTY byte arrays. The retained stale-PTY acknowledgment, cancellation/answer retry, and answered-approval remount/rebind assertions remain meaningful but are not equivalent replacement coverage. No fresh reduced-selector result, physical provider, rendered/native-focus, mixed-version deployment, soak, or measured-budget validation is claimed. The unchanged wire-codec receipt remains valid only for its exact command. Historical prior account (preserved verbatim): Audit1640 removes low-value IPC, SSH, workspace and transcript-watcher tests without equivalent replacement coverage. Per-source reviews record retained public refusal, cancellation, execution-host and real-filesystem outcomes with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1471 removes the entire interactive-send hook suite. Its mock-writer routing, cancellation-handle, option-digit, interrupt, supplied settlement and inference-argument alarms are retired. No actual PTY bytes, replacement question lifetime or agent delivery were exercised. No equivalent replacement or fresh execution of the reduced reliability selector is claimed; historical receipts retain their original scope. Audit1468 removes the entire runtime-send suite. Its mock PTY clear/body/Enter byte-order, nominal timing, queue cancellation/serialization, attachment escaping, key-group pacing and deferred acceptance callback alarms are intentionally retired. No actual receiving agent or physical terminal delivery was exercised. No equivalent replacement or fresh execution of the reduced reliability selector is claimed; historical receipts retain their original scope. Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Audit1417 intentionally reduces src/renderer/src/lib/agent-paste-draft-submit-retry.test.ts: Loses configured retry gap and single-Enter agent selection alarms alongside forbidden timer-count checks. No equivalent replacement coverage or fresh result is claimed. Historical coverage account: Audit1383 changes referenced sources; no new execution result validates reduced selectors. Retained unchanged receipts apply only to unchanged commands. Historical coverage: Audits1340 and1348 changes referenced sources. Retained unchanged-source receipts apply only to their unchanged commands; the reduced selectors have no new execution result. Historical coverage account (not a current claim for changed sources): Audit1316 changes referenced sources. Retained unchanged-source receipts apply only to their unchanged commands; the reduced selectors have no new execution result. Historical coverage account (not a current claim for changed sources): Production mobile controller, parser, presentation, overlay, view, question, permission and composer run with native surfaces mocked on macOS. Desktop selector groups traverse the real observed-write queue, verified helper, IPC chunker, SSH provider and transport callbacks; paired sends traverse the real dispatcher and runtime writer into that provider. Local/daemon contracts and released-version terminal codecs are covered. Provider labels describe contracts, not physical deployments; physical WSL/Linux/Windows remain gaps. Audit885 removes the isolated observed-send mock-call suite; no replacement-equivalence claim is made. Audit1107 removes the small healthy ordinary SSH-send byte/callback sample. Its exact clear/body/Enter sample alarm is lost; retained slow-answer, cancellation and simulated older-host sequence checks are not claimed as equivalent replacement coverage. The SSH delivery fixture uses controlled fake provider settlement, and its paired path uses the real runtime/dispatcher without a physical SSH or paired wire transport. Audit1278 removes the mobile Stop display/disabled/placeholder suite; its local Stop presentation, repeat-stop and dispatch-visibility alarms are intentionally lost. No equivalent replacement or runtime stopping proof is claimed. Audit1292: The blind OpenCode readiness warning and late launch success/failure content-plus-submit write samples are removed. Their mocked readiness/inspection/delivery alarms are lost; no real PTY delivery or equivalent replacement coverage is claimed. Audit1294 removes mobile/src/session/native-chat/input/mobile-native-chat-permission-send.test.ts. Its mock-only request/capability/private-state/copy alarms are intentionally lost. Remaining tests are not equivalent replacement coverage. Narrowed commands require fresh parent-owned validation; no new runtime, platform or physical mobile evidence is claimed. Audit1302: src/main/ipc/pty/ipc/write-input-acceptance.test.ts: Provider registry and write acceptance/refusal/unverifiable receipts are supplied by fixture; local/daemon/WSL/SSH labels use the same fake provider. Chunking/settlement/remount cases inspect delegated calls or canned receipts without actual provider acceptance/acknowledgement. Lose chunk/refusal/pending/remount and raw-pane routing alarms; no equivalent replacement. Reduced selectors require fresh validation; prior full-suite receipts do not validate removed or changed coverage. No equivalent replacement or physical-provider claim. Audit1303 intentionally removes supplied-state/mock-callback component and hook examples in mobile/src/session/native-chat/input/use-mobile-native-chat-ask-dismiss.test.ts, mobile/src/session/native-chat/input/MobileNativeChatPromptCard.test.tsx. Their exact retired alarms are not equivalent to retained coverage; no new runtime, physical phone or deployed mixed-version evidence is claimed. Audit1310 removes the supplied-geometry/direct-callback chat history-paging suite. Its prepend/scroll-position examples are intentionally lost; no real rendered anchoring, equivalent replacement or physical phone proof is claimed. Narrowed commands need fresh validation. Audit1315 removes/narrows mobile/src/session/native-chat/MobileNativeChatView.composer-lock.test.ts, mobile/src/session/native-chat/MobileNativeChatView.prompt-presentation.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1316: src/renderer/src/lib/agent-followup-delivery.test.ts removed. Interpreter wrapper/live child/shell readiness and final readiness recheck delivery mock samples lose alarms. No equivalent replacement coverage is claimed. Audit1322 removes/narrows mobile/src/session/native-chat/MobileNativeChatView.tail-follow.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1341 scope1334 removes/narrows mobile/src/session/native-chat/mobile-native-chat-send.test.ts, mobile/src/session/native-chat/transcript/use-mobile-native-chat-message-send.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1341 scope1335 removes/narrows mobile/src/session/native-chat/use-mobile-native-chat-controller.test.ts, mobile/src/session/mobile-prompt-controller.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-answer-send.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1340: src/main/daemon/daemon-pty-write-settlement-recovery.test.ts removed. Ambiguous handoff settlement remains unverifiable when listener throws. No equivalent replacement coverage is claimed. Audit1348: src/main/ipc/pty/ipc/write-input-chunk-yield.test.ts removed. Check-phase yielding and no-yield single-chunk scheduling work. No equivalent replacement coverage is claimed. Audit1352: focused Linux unit selections validated on source head b638e07d395b76af3ba6b03761a1a0fe7e5e026e. Historical statements above retain their original scope. Intentional test losses are recorded in knownGaps; these runs claim no physical-provider, p95, rendered E2E or cross-platform validation. Audit1360: focused Linux unit selections validated on source head 415c9cffc2d10024131ec4b6721767a22195de6d. Historical statements above retain their original scope. Intentional test losses are recorded in knownGaps; these runs claim no physical-provider, p95, rendered E2E or cross-platform validation. Audit1383: src/main/ipc/pty/ipc/write-input-user-input.test.ts reduced. Lose admission provenance spy, direct local Escape write outcome matrix and separate client-side SSH no-evidence control. Provider writes mocked; retained tests protect observation order/facts only. No equivalent replacement coverage is claimed. Audit1401: src/main/ipc/pty/ipc/write-input-user-input.test.ts reduced. Loses local-only post-accept observation and refused/unverifiable settlement delivery alarms. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1402: src/renderer/src/components/native-chat/native-chat-runtime-send-launch-draft.test.ts removed. Intentionally loses clear-confirmation/body/submit and maximal-clear ordering, queued text/image send ordering, ordinary cursor-spanning draft replacement and oversized refusal/queue settlement alarms. No equivalent replacement or real terminal delivery claim. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1426 removes NativeChatComposer.test.tsx. Local pane-remount, draft/cancel/confirmation sequencing and manual IME callback alarms are lost. No equivalent replacement coverage or provider delivery is claimed; historical receipts retain their original scope and the reduced selector has no new execution result. Audit2450 removes the MobileNativeChatView failure-banner callback-only example whose old banner is supplied unchanged by its props. Retain fatal-read gating and the ordering test that preserves a new delivery notice. The removed false-send/old-banner combination has no equivalent replacement; prior raw receipts and budgets retain their original source scope. No new soak, platform, performance or red/green claim.", + "coverageNotes": "The sole recorded execution selected a now-retired cross-version terminal-wire suite. Demote protection to none, clear covered platforms/providers, and archive all prior active selectors/assertion references and the exact dated receipt. The surviving test files elsewhere are unchanged and receive no replacement-coverage or fresh execution claim. Prior account preserved verbatim: Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose PTY writer driving-input recording before provider write and launch/query-reply/focus classification alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit3984 retires all four remaining viewport-fixture suites (14 authored/15 finite cases) and the fixture after composing the sender-host deletion. Accepted source-alarm losses include live-region/disclosure continuity, task/question/approval history and revision handling, stale turn status, prompt-dismissal remount/rebind, and pending-send cancellation when approval arrives between body and Enter. No equivalent replacement or fresh runtime validation is claimed. Audits3764/3766 retire16 authored/27 expanded mobile cases, including entire HTML-image syntax, Mermaid routing, table styles, file-query encoding, workspace naming and fresh-Git-status adapter suites. Accepted losses include image width/icon filtering, partial-heading streaming, mocked Mermaid key/identity checks, generated table widths/counts, selected-text caret placement, tiny Base64 chunk encoding, twelve query-path roundtrips, locale-import fallback, apostrophe slugging, fresh-status fallback and an intermediate reviewed marker. These are deliberate removals for marginal value; remaining tests are not equivalent replacements. Earlier receipts are historical and do not validate these deleted/reduced drivers. Audit3748 intentionally removes ten authored/ten finite registrations from the surviving media-handle-registry.test.ts driver selected by this full-mobile command. Retired real alarms: nominal minted handle uniqueness/metadata and dimensions; ordinary range/EOF/overread/empty-file/direct chunk-clamp samples; nominal successful release, expired-release false, exact millisecond TTL boundary and ordinary releaseAll replay. Deterministic registry code runs; these examples are removed on marginal value without replacement or fresh execution claims. Seven owner cases retain cap refusal/disposal and sweep-before-admission, nonempty EOF and unknown/released/expired refusal, read TTL refresh, idempotent explicit release and continuation after discard failure. Existing commands, assertions, unrelated wire receipt and timing remain; the driver survives. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered mobile Vitest command. Its mobile/src include patterns admit the partial live-input-commit and native-media drivers:5 authored/5 finite removals. Accepted losses: two Android-labeled replay samples after mocked composition conversion, an immediate Backspace absence check that does not wait for pending commit or prove local edit, and released-handle/double-release adapter examples. Real hook, registry and adapter logic run; no equivalent replacement or native Android/iOS exercise is claimed. Both drivers and selector stay. The unchanged wire-specific dated receipt does not validate these reduced mobile sources. Audit3666 removes30 authored/36 finite mobile cases, including7 whole drivers. It retires direct consent/channel/token/header-payload/fingerprint/route-object inventories, background legacy-dismissal filtering, the two-row520-entry watermark retention workload, reentrant write-batch example, font-before-ready projection, and legacy-segmenter/scrollback/wrap selection examples. Actual policy, parsing, hashing, tray matching, serialization and xterm buffers execute in these tests; their stated alarms are deliberately lost without replacement. Twelve unchanged authored/19 finite cases retain compact browser geometry regressions, an independent fingerprint-to-host protocol vector, serialized watermark/reload isolation, OSC52 live/replay gating, queue boundaries/reset/generation, disposed font completion and Unicode cell mapping. Pairing classification2/2 was already approved by3657 and receives no3666 delta or credit. Static review only; no runtime, native, provider, browser rendering, OS, remote, mobile/folder parity or new historical fault evidence. Previous account (preserved verbatim): Audit3663 removes the complete mobile scan-error message suite (two authored/two finite callbacks). Its4URL assertion loop is one registration. Accept loss of Orca new/legacy Android-download URL classification and other-page invalid-code translated-key mapping. Real URL parsing/classification runs, but the only output observed is an identity-translator key. No camera scan, pairing offer admission, connection or device/UI action is exercised. No equivalent replacement or physical/mobile/mixed-version result claimed. Preserve all historical evidence and metadata bytes. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The broad mobile runner loses retired-name sequencing and PR action samples while retaining the editor-lifetime and original PR action keeper; commit-message generation is unchanged. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. The broad mobile command loses the entire three-case mocked diff-review controller suite and the stale layout-sequence comparator sample. Keep only the direct layout-versus-scrollback counter distinction; the unchanged dictation retry hook retains complete recording replay. No rendered app, native capture, actual process death or remote execution is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad mobile discovery loses whole prompt-presentation, Jira-URL and folder-source-repository suites. The prompt suite exercised presentation projections; it did not provide native mobile prompt acknowledgment acceptance. Existing direct prompt-controller selectors are unchanged. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The stale-leaf-liveness suite and its exact command/testFiles selector are removed; its fake terminal refusal/liveness alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The entire mocked mobile failure-banner suite and its sole send/previous-banner/new-notice ordering alarm are retired. Its filenames are removed from active selectors. Desktop prompt roots and the independent unchanged terminal wire-codec receipt remain at their stated scopes; no mobile send/recovery proof is claimed. Audit2251 narrows agent-paste-draft.test.ts from 25 authored cases (26 literal cases) to four. Retained cases cover buffered readiness on PTY binding, separate spawn/composer lifetimes, real per-PTY paste/Enter serialization against a competing paste, and frame closure/no Enter after a rejected content chunk. Intentionally lost alarms include agent marker and fallback examples, direct-write failure/rejection, missing-PTY and Codex process-only timeout paths, exact nonprimary-PTY routing, full large-body chunk reconstruction, escaping/CRLF samples, internal laziness/yield work assertions, oversized preflight refusal, and exact configured delay/budget counts. No equivalent replacement, new execution, real PTY/provider delivery, rendered/native UI, deployment, measured performance or cross-platform result is claimed. Historical prior account (preserved verbatim): Mobile owner-layout policy retires whole tests and mixed registrations without equivalent replacement coverage. Retained callbacks and reduced selectors need fresh execution at their stated scope; prior measurements do not validate them. Affected sources: mobile/src/session/mobile-prompt-controller.test.ts, tests/e2e/native-chat-ssh-delivery.unit.test.ts, mobile/src/session/native-chat/use-mobile-native-chat-controller.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-cancel-ask.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-answer-send.test.ts, mobile/src/session/native-chat/transcript/use-mobile-native-chat-message-send.test.ts. Historical scope: Audit2003: Remove agent-prompt absence routing, throwing/live/missing-probe and cached-probe-count examples from the stale-leaf source. Controller-proven absence, unknown-liveness admission, obsolete-absence clearing and same-ID respawn fences remain at a supplied provider/row seam. Preserve the independent wire-codec receipt only in its original scope. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove partial-runtime terminal-send guard/status/floor/query projection and argument-inventory samples. Retained RPC viewport admission, authenticated-client spoof refusal, text admission and stale-binding fences remain bounded mock-boundary behavior. The unchanged wire-codec receipt remains valid only for its original command; it does not validate this reduced RPC selector. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1908 removes the complete prompt-presentation hook and literal interactive-protocol mapping suites and narrows the interactive card and prompt-card input suites. Lost alarms include replacement approval A settling after answered B; collapse/expand composer ownership and partial-answer presentation; identical new waits after an unmounted view; collapsed transcript re-reads; answered/dismissed status-backed persistence and retirement; and literal answer-to-PTY byte arrays. The retained stale-PTY acknowledgment, cancellation/answer retry, and answered-approval remount/rebind assertions remain meaningful but are not equivalent replacement coverage. No fresh reduced-selector result, physical provider, rendered/native-focus, mixed-version deployment, soak, or measured-budget validation is claimed. The unchanged wire-codec receipt remains valid only for its exact command. Historical prior account (preserved verbatim): Audit1640 removes low-value IPC, SSH, workspace and transcript-watcher tests without equivalent replacement coverage. Per-source reviews record retained public refusal, cancellation, execution-host and real-filesystem outcomes with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1471 removes the entire interactive-send hook suite. Its mock-writer routing, cancellation-handle, option-digit, interrupt, supplied settlement and inference-argument alarms are retired. No actual PTY bytes, replacement question lifetime or agent delivery were exercised. No equivalent replacement or fresh execution of the reduced reliability selector is claimed; historical receipts retain their original scope. Audit1468 removes the entire runtime-send suite. Its mock PTY clear/body/Enter byte-order, nominal timing, queue cancellation/serialization, attachment escaping, key-group pacing and deferred acceptance callback alarms are intentionally retired. No actual receiving agent or physical terminal delivery was exercised. No equivalent replacement or fresh execution of the reduced reliability selector is claimed; historical receipts retain their original scope. Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Audit1417 intentionally reduces src/renderer/src/lib/agent-paste-draft-submit-retry.test.ts: Loses configured retry gap and single-Enter agent selection alarms alongside forbidden timer-count checks. No equivalent replacement coverage or fresh result is claimed. Historical coverage account: Audit1383 changes referenced sources; no new execution result validates reduced selectors. Retained unchanged receipts apply only to unchanged commands. Historical coverage: Audits1340 and1348 changes referenced sources. Retained unchanged-source receipts apply only to their unchanged commands; the reduced selectors have no new execution result. Historical coverage account (not a current claim for changed sources): Audit1316 changes referenced sources. Retained unchanged-source receipts apply only to their unchanged commands; the reduced selectors have no new execution result. Historical coverage account (not a current claim for changed sources): Production mobile controller, parser, presentation, overlay, view, question, permission and composer run with native surfaces mocked on macOS. Desktop selector groups traverse the real observed-write queue, verified helper, IPC chunker, SSH provider and transport callbacks; paired sends traverse the real dispatcher and runtime writer into that provider. Local/daemon contracts and released-version terminal codecs are covered. Provider labels describe contracts, not physical deployments; physical WSL/Linux/Windows remain gaps. Audit885 removes the isolated observed-send mock-call suite; no replacement-equivalence claim is made. Audit1107 removes the small healthy ordinary SSH-send byte/callback sample. Its exact clear/body/Enter sample alarm is lost; retained slow-answer, cancellation and simulated older-host sequence checks are not claimed as equivalent replacement coverage. The SSH delivery fixture uses controlled fake provider settlement, and its paired path uses the real runtime/dispatcher without a physical SSH or paired wire transport. Audit1278 removes the mobile Stop display/disabled/placeholder suite; its local Stop presentation, repeat-stop and dispatch-visibility alarms are intentionally lost. No equivalent replacement or runtime stopping proof is claimed. Audit1292: The blind OpenCode readiness warning and late launch success/failure content-plus-submit write samples are removed. Their mocked readiness/inspection/delivery alarms are lost; no real PTY delivery or equivalent replacement coverage is claimed. Audit1294 removes mobile/src/session/native-chat/input/mobile-native-chat-permission-send.test.ts. Its mock-only request/capability/private-state/copy alarms are intentionally lost. Remaining tests are not equivalent replacement coverage. Narrowed commands require fresh parent-owned validation; no new runtime, platform or physical mobile evidence is claimed. Audit1302: src/main/ipc/pty/ipc/write-input-acceptance.test.ts: Provider registry and write acceptance/refusal/unverifiable receipts are supplied by fixture; local/daemon/WSL/SSH labels use the same fake provider. Chunking/settlement/remount cases inspect delegated calls or canned receipts without actual provider acceptance/acknowledgement. Lose chunk/refusal/pending/remount and raw-pane routing alarms; no equivalent replacement. Reduced selectors require fresh validation; prior full-suite receipts do not validate removed or changed coverage. No equivalent replacement or physical-provider claim. Audit1303 intentionally removes supplied-state/mock-callback component and hook examples in mobile/src/session/native-chat/input/use-mobile-native-chat-ask-dismiss.test.ts, mobile/src/session/native-chat/input/MobileNativeChatPromptCard.test.tsx. Their exact retired alarms are not equivalent to retained coverage; no new runtime, physical phone or deployed mixed-version evidence is claimed. Audit1310 removes the supplied-geometry/direct-callback chat history-paging suite. Its prepend/scroll-position examples are intentionally lost; no real rendered anchoring, equivalent replacement or physical phone proof is claimed. Narrowed commands need fresh validation. Audit1315 removes/narrows mobile/src/session/native-chat/MobileNativeChatView.composer-lock.test.ts, mobile/src/session/native-chat/MobileNativeChatView.prompt-presentation.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1316: src/renderer/src/lib/agent-followup-delivery.test.ts removed. Interpreter wrapper/live child/shell readiness and final readiness recheck delivery mock samples lose alarms. No equivalent replacement coverage is claimed. Audit1322 removes/narrows mobile/src/session/native-chat/MobileNativeChatView.tail-follow.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1341 scope1334 removes/narrows mobile/src/session/native-chat/mobile-native-chat-send.test.ts, mobile/src/session/native-chat/transcript/use-mobile-native-chat-message-send.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1341 scope1335 removes/narrows mobile/src/session/native-chat/use-mobile-native-chat-controller.test.ts, mobile/src/session/mobile-prompt-controller.test.ts, mobile/src/session/native-chat/input/use-mobile-native-chat-answer-send.test.ts. Exact retired scenarios are intentionally lost; surviving assertions are limited to unchanged retained authored cases. No equivalent replacement, physical phone or deployed mixed-host claim. Fresh validation is required for narrowed commands. Audit1340: src/main/daemon/daemon-pty-write-settlement-recovery.test.ts removed. Ambiguous handoff settlement remains unverifiable when listener throws. No equivalent replacement coverage is claimed. Audit1348: src/main/ipc/pty/ipc/write-input-chunk-yield.test.ts removed. Check-phase yielding and no-yield single-chunk scheduling work. No equivalent replacement coverage is claimed. Audit1352: focused Linux unit selections validated on source head b638e07d395b76af3ba6b03761a1a0fe7e5e026e. Historical statements above retain their original scope. Intentional test losses are recorded in knownGaps; these runs claim no physical-provider, p95, rendered E2E or cross-platform validation. Audit1360: focused Linux unit selections validated on source head 415c9cffc2d10024131ec4b6721767a22195de6d. Historical statements above retain their original scope. Intentional test losses are recorded in knownGaps; these runs claim no physical-provider, p95, rendered E2E or cross-platform validation. Audit1383: src/main/ipc/pty/ipc/write-input-user-input.test.ts reduced. Lose admission provenance spy, direct local Escape write outcome matrix and separate client-side SSH no-evidence control. Provider writes mocked; retained tests protect observation order/facts only. No equivalent replacement coverage is claimed. Audit1401: src/main/ipc/pty/ipc/write-input-user-input.test.ts reduced. Loses local-only post-accept observation and refused/unverifiable settlement delivery alarms. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1402: src/renderer/src/components/native-chat/native-chat-runtime-send-launch-draft.test.ts removed. Intentionally loses clear-confirmation/body/submit and maximal-clear ordering, queued text/image send ordering, ordinary cursor-spanning draft replacement and oversized refusal/queue settlement alarms. No equivalent replacement or real terminal delivery claim. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1426 removes NativeChatComposer.test.tsx. Local pane-remount, draft/cancel/confirmation sequencing and manual IME callback alarms are lost. No equivalent replacement coverage or provider delivery is claimed; historical receipts retain their original scope and the reduced selector has no new execution result. Audit2450 removes the MobileNativeChatView failure-banner callback-only example whose old banner is supplied unchanged by its props. Retain fatal-read gating and the ordering test that preserves a new delivery notice. The removed false-send/old-banner combination has no equivalent replacement; prior raw receipts and budgets retain their original source scope. No new soak, platform, performance or red/green claim.", "motivatingLinks": ["https://github.com/stablyai/orca/pull/25761"], "invariant": "A prompt occurrence leaves the input region only when an accepted reply answers it (a current host's provider acknowledgment, or an older host's whole-write acceptance as before) or the user collapses it to a strip above the composer, which writes nothing and keeps the card mounted with its partial answer; status-backed occurrences are told apart by the host wait's start, so view toggles and remounts preserve them while real clear/replacement supersedes them, and a transcript-only one is dropped when the view stops observing it; obsolete results cannot change replacements; selector groups wait for complete writes before pacing; refusal or unknown handoff never causes replay; a card retires an unsubmitted composer send without writing under it or losing its text, and the hidden composer cannot send or interrupt; Collapse or Escape folds a card without writing, never during an in-flight answer, and a new occurrence shows expanded again; the phone blocks only Send while a card is expanded and shows one card per occurrence; cancellation stops unsent groups and active dictation can stop.", - "oracle": "Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose PTY writer driving-input recording before provider write and launch/query-reply/focus classification alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audits3764/3766 retire16 authored/27 expanded mobile cases, including entire HTML-image syntax, Mermaid routing, table styles, file-query encoding, workspace naming and fresh-Git-status adapter suites. Accepted losses include image width/icon filtering, partial-heading streaming, mocked Mermaid key/identity checks, generated table widths/counts, selected-text caret placement, tiny Base64 chunk encoding, twelve query-path roundtrips, locale-import fallback, apostrophe slugging, fresh-status fallback and an intermediate reviewed marker. These are deliberate removals for marginal value; remaining tests are not equivalent replacements. Earlier receipts are historical and do not validate these deleted/reduced drivers. Audit3748 intentionally removes ten authored/ten finite registrations from the surviving media-handle-registry.test.ts driver selected by this full-mobile command. Retired real alarms: nominal minted handle uniqueness/metadata and dimensions; ordinary range/EOF/overread/empty-file/direct chunk-clamp samples; nominal successful release, expired-release false, exact millisecond TTL boundary and ordinary releaseAll replay. Deterministic registry code runs; these examples are removed on marginal value without replacement or fresh execution claims. Seven owner cases retain cap refusal/disposal and sweep-before-admission, nonempty EOF and unknown/released/expired refusal, read TTL refresh, idempotent explicit release and continuation after discard failure. Existing commands, assertions, unrelated wire receipt and timing remain; the driver survives. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered mobile Vitest command. Its mobile/src include patterns admit the partial live-input-commit and native-media drivers:5 authored/5 finite removals. Accepted losses: two Android-labeled replay samples after mocked composition conversion, an immediate Backspace absence check that does not wait for pending commit or prove local edit, and released-handle/double-release adapter examples. Real hook, registry and adapter logic run; no equivalent replacement or native Android/iOS exercise is claimed. Both drivers and selector stay. The unchanged wire-specific dated receipt does not validate these reduced mobile sources. Audit3666 removes30 authored/36 finite mobile cases, including7 whole drivers. It retires direct consent/channel/token/header-payload/fingerprint/route-object inventories, background legacy-dismissal filtering, the two-row520-entry watermark retention workload, reentrant write-batch example, font-before-ready projection, and legacy-segmenter/scrollback/wrap selection examples. Actual policy, parsing, hashing, tray matching, serialization and xterm buffers execute in these tests; their stated alarms are deliberately lost without replacement. Twelve unchanged authored/19 finite cases retain compact browser geometry regressions, an independent fingerprint-to-host protocol vector, serialized watermark/reload isolation, OSC52 live/replay gating, queue boundaries/reset/generation, disposed font completion and Unicode cell mapping. Pairing classification2/2 was already approved by3657 and receives no3666 delta or credit. Static review only; no runtime, native, provider, browser rendering, OS, remote, mobile/folder parity or new historical fault evidence. Previous oracle (preserved verbatim): Audit3663 removes the complete mobile scan-error message suite (two authored/two finite callbacks). Its4URL assertion loop is one registration. Accept loss of Orca new/legacy Android-download URL classification and other-page invalid-code translated-key mapping. Real URL parsing/classification runs, but the only output observed is an identity-translator key. No camera scan, pairing offer admission, connection or device/UI action is exercised. No equivalent replacement or physical/mobile/mixed-version result claimed. Preserve all historical evidence and metadata bytes. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The broad mobile runner loses retired-name sequencing and PR action samples while retaining the editor-lifetime and original PR action keeper; commit-message generation is unchanged. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. The broad mobile command loses the entire three-case mocked diff-review controller suite and the stale layout-sequence comparator sample. Keep only the direct layout-versus-scrollback counter distinction; the unchanged dictation retry hook retains complete recording replay. No rendered app, native capture, actual process death or remote execution is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad mobile discovery loses whole prompt-presentation, Jira-URL and folder-source-repository suites. The prompt suite exercised presentation projections; it did not provide native mobile prompt acknowledgment acceptance. Existing direct prompt-controller selectors are unchanged. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The stale-leaf-liveness suite and its exact command/testFiles selector are removed; its fake terminal refusal/liveness alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The entire mocked mobile failure-banner suite and its sole send/previous-banner/new-notice ordering alarm are retired. Its filenames are removed from active selectors. Desktop prompt roots and the independent unchanged terminal wire-codec receipt remain at their stated scopes; no mobile send/recovery proof is claimed. Audit2251 narrows agent-paste-draft.test.ts from 25 authored cases (26 literal cases) to four. Retained cases cover buffered readiness on PTY binding, separate spawn/composer lifetimes, real per-PTY paste/Enter serialization against a competing paste, and frame closure/no Enter after a rejected content chunk. Intentionally lost alarms include agent marker and fallback examples, direct-write failure/rejection, missing-PTY and Codex process-only timeout paths, exact nonprimary-PTY routing, full large-body chunk reconstruction, escaping/CRLF samples, internal laziness/yield work assertions, oversized preflight refusal, and exact configured delay/budget counts. No equivalent replacement, new execution, real PTY/provider delivery, rendered/native UI, deployment, measured performance or cross-platform result is claimed. Historical prior account (preserved verbatim): Mobile owner-layout policy retires whole tests and mixed registrations without equivalent replacement coverage. Retained callbacks and reduced selectors need fresh execution at their stated scope; prior measurements do not validate them. Historical oracle: Audit2003: Remove agent-prompt absence routing, throwing/live/missing-probe and cached-probe-count examples from the stale-leaf source. Controller-proven absence, unknown-liveness admission, obsolete-absence clearing and same-ID respawn fences remain at a supplied provider/row seam. Preserve the independent wire-codec receipt only in its original scope. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove partial-runtime terminal-send guard/status/floor/query projection and argument-inventory samples. Retained RPC viewport admission, authenticated-client spoof refusal, text admission and stale-binding fences remain bounded mock-boundary behavior. The unchanged wire-codec receipt remains valid only for its original command; it does not validate this reduced RPC selector. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1908 removes the complete prompt-presentation hook and literal interactive-protocol mapping suites and narrows the interactive card and prompt-card input suites. Lost alarms include replacement approval A settling after answered B; collapse/expand composer ownership and partial-answer presentation; identical new waits after an unmounted view; collapsed transcript re-reads; answered/dismissed status-backed persistence and retirement; and literal answer-to-PTY byte arrays. The retained stale-PTY acknowledgment, cancellation/answer retry, and answered-approval remount/rebind assertions remain meaningful but are not equivalent replacement coverage. No fresh reduced-selector result, physical provider, rendered/native-focus, mixed-version deployment, soak, or measured-budget validation is claimed. The unchanged wire-codec receipt remains valid only for its exact command. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Retained unchanged-selector receipts are the only current execution evidence. Reduced-source assertions await validation. Historical prior oracle: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): After acknowledged phone replies with stale host status, the exact card disappears and Send is enabled; unknown, refused or unverifiable-settlement replies retain enabled choices, while an older host's accepted reply dismisses like an acknowledged one; a same-occurrence view toggle retains pending acknowledgment and real replacements discard it. A slow 32 KiB SSH answer completes all chunks before Enter; cancellation preserves issued bytes but omits remaining groups. Paired settlement invokes the actual provider and lost callbacks remain unknown; older hosts deliver ordinary messages, launch and selector groups once and their accepted answers dismiss as before. An answered card stays hidden across a view remount; a collapsed card is a strip that frees the composer and expands back; an identical question in a new wait shows again; a composer send caught by a new card keeps its bubble without submitting or clearing the line under it. Audit2450 removes the MobileNativeChatView failure-banner callback-only example whose old banner is supplied unchanged by its props. Retain fatal-read gating and the ordering test that preserves a new delivery notice. The removed false-send/old-banner combination has no equivalent replacement; prior raw receipts and budgets retain their original source scope. No new soak, platform, performance or red/green claim.", - "commands": [ - "ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/runtime/terminal/input/runtime-terminal-writer.test.ts --maxWorkers=2", - "ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts --maxWorkers=2", - "ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1", - "ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts --maxWorkers=2", - "ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts --maxWorkers=2" - ], - "testFiles": [ - "src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx", - "src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts", - "src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts", - "src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts", - "src/main/runtime/terminal/input/runtime-terminal-writer.test.ts", - "mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts", - "tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts" - ], - "assertionRefs": [ - { - "file": "src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx", - "assertions": [ - "ignores a raw acknowledgment from a rebound PTY", - "sends only one cancellation, can cancel an answer, and permits retry after unknown" - ] - }, - - { - "file": "mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts", - "assertions": [ - "retains permission choices on %s", - - "keeps an acknowledged Deny hidden after the chat screen remounts on a lingering status", - "settles the terminal answer for Q1 after Q2 arrives without hiding Q2", - "keeps structured answer controls after a thrown send" - ] - }, - { - "file": "src/main/runtime/terminal/input/runtime-terminal-writer.test.ts", - "assertions": [ - "waits for complete body settlement before Enter", - "does not send the suffix after refusal or unknown settlement", - "returns unknown after an acknowledged prefix followed by refusal or bookkeeping failure", - "preserves legacy raw body and Enter writes" - ] - } - ], - "evidenceRuns": [ - { - "date": "2026-10-06", - "runner": "local", - "platform": "macos", - "command": "ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1", - "result": "passed", - "durationSeconds": 25.68, - "summary": "10 terminal wire codec compatibility cases passed against current and two supported released source versions; this is a codec/RPC-reader contract, not a physical mixed-version paired deployment." - } - ], + "oracle": "The sole recorded execution selected a now-retired cross-version terminal-wire suite. Demote protection to none, clear covered platforms/providers, and archive all prior active selectors/assertion references and the exact dated receipt. The surviving test files elsewhere are unchanged and receive no replacement-coverage or fresh execution claim. Prior account preserved verbatim: Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose PTY writer driving-input recording before provider write and launch/query-reply/focus classification alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audits3764/3766 retire16 authored/27 expanded mobile cases, including entire HTML-image syntax, Mermaid routing, table styles, file-query encoding, workspace naming and fresh-Git-status adapter suites. Accepted losses include image width/icon filtering, partial-heading streaming, mocked Mermaid key/identity checks, generated table widths/counts, selected-text caret placement, tiny Base64 chunk encoding, twelve query-path roundtrips, locale-import fallback, apostrophe slugging, fresh-status fallback and an intermediate reviewed marker. These are deliberate removals for marginal value; remaining tests are not equivalent replacements. Earlier receipts are historical and do not validate these deleted/reduced drivers. Audit3748 intentionally removes ten authored/ten finite registrations from the surviving media-handle-registry.test.ts driver selected by this full-mobile command. Retired real alarms: nominal minted handle uniqueness/metadata and dimensions; ordinary range/EOF/overread/empty-file/direct chunk-clamp samples; nominal successful release, expired-release false, exact millisecond TTL boundary and ordinary releaseAll replay. Deterministic registry code runs; these examples are removed on marginal value without replacement or fresh execution claims. Seven owner cases retain cap refusal/disposal and sweep-before-admission, nonempty EOF and unknown/released/expired refusal, read TTL refresh, idempotent explicit release and continuation after discard failure. Existing commands, assertions, unrelated wire receipt and timing remain; the driver survives. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered mobile Vitest command. Its mobile/src include patterns admit the partial live-input-commit and native-media drivers:5 authored/5 finite removals. Accepted losses: two Android-labeled replay samples after mocked composition conversion, an immediate Backspace absence check that does not wait for pending commit or prove local edit, and released-handle/double-release adapter examples. Real hook, registry and adapter logic run; no equivalent replacement or native Android/iOS exercise is claimed. Both drivers and selector stay. The unchanged wire-specific dated receipt does not validate these reduced mobile sources. Audit3666 removes30 authored/36 finite mobile cases, including7 whole drivers. It retires direct consent/channel/token/header-payload/fingerprint/route-object inventories, background legacy-dismissal filtering, the two-row520-entry watermark retention workload, reentrant write-batch example, font-before-ready projection, and legacy-segmenter/scrollback/wrap selection examples. Actual policy, parsing, hashing, tray matching, serialization and xterm buffers execute in these tests; their stated alarms are deliberately lost without replacement. Twelve unchanged authored/19 finite cases retain compact browser geometry regressions, an independent fingerprint-to-host protocol vector, serialized watermark/reload isolation, OSC52 live/replay gating, queue boundaries/reset/generation, disposed font completion and Unicode cell mapping. Pairing classification2/2 was already approved by3657 and receives no3666 delta or credit. Static review only; no runtime, native, provider, browser rendering, OS, remote, mobile/folder parity or new historical fault evidence. Previous oracle (preserved verbatim): Audit3663 removes the complete mobile scan-error message suite (two authored/two finite callbacks). Its4URL assertion loop is one registration. Accept loss of Orca new/legacy Android-download URL classification and other-page invalid-code translated-key mapping. Real URL parsing/classification runs, but the only output observed is an identity-translator key. No camera scan, pairing offer admission, connection or device/UI action is exercised. No equivalent replacement or physical/mobile/mixed-version result claimed. Preserve all historical evidence and metadata bytes. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The broad mobile runner loses retired-name sequencing and PR action samples while retaining the editor-lifetime and original PR action keeper; commit-message generation is unchanged. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. The broad mobile command loses the entire three-case mocked diff-review controller suite and the stale layout-sequence comparator sample. Keep only the direct layout-versus-scrollback counter distinction; the unchanged dictation retry hook retains complete recording replay. No rendered app, native capture, actual process death or remote execution is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad mobile discovery loses whole prompt-presentation, Jira-URL and folder-source-repository suites. The prompt suite exercised presentation projections; it did not provide native mobile prompt acknowledgment acceptance. Existing direct prompt-controller selectors are unchanged. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The stale-leaf-liveness suite and its exact command/testFiles selector are removed; its fake terminal refusal/liveness alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The entire mocked mobile failure-banner suite and its sole send/previous-banner/new-notice ordering alarm are retired. Its filenames are removed from active selectors. Desktop prompt roots and the independent unchanged terminal wire-codec receipt remain at their stated scopes; no mobile send/recovery proof is claimed. Audit2251 narrows agent-paste-draft.test.ts from 25 authored cases (26 literal cases) to four. Retained cases cover buffered readiness on PTY binding, separate spawn/composer lifetimes, real per-PTY paste/Enter serialization against a competing paste, and frame closure/no Enter after a rejected content chunk. Intentionally lost alarms include agent marker and fallback examples, direct-write failure/rejection, missing-PTY and Codex process-only timeout paths, exact nonprimary-PTY routing, full large-body chunk reconstruction, escaping/CRLF samples, internal laziness/yield work assertions, oversized preflight refusal, and exact configured delay/budget counts. No equivalent replacement, new execution, real PTY/provider delivery, rendered/native UI, deployment, measured performance or cross-platform result is claimed. Historical prior account (preserved verbatim): Mobile owner-layout policy retires whole tests and mixed registrations without equivalent replacement coverage. Retained callbacks and reduced selectors need fresh execution at their stated scope; prior measurements do not validate them. Historical oracle: Audit2003: Remove agent-prompt absence routing, throwing/live/missing-probe and cached-probe-count examples from the stale-leaf source. Controller-proven absence, unknown-liveness admission, obsolete-absence clearing and same-ID respawn fences remain at a supplied provider/row seam. Preserve the independent wire-codec receipt only in its original scope. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove partial-runtime terminal-send guard/status/floor/query projection and argument-inventory samples. Retained RPC viewport admission, authenticated-client spoof refusal, text admission and stale-binding fences remain bounded mock-boundary behavior. The unchanged wire-codec receipt remains valid only for its original command; it does not validate this reduced RPC selector. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1908 removes the complete prompt-presentation hook and literal interactive-protocol mapping suites and narrows the interactive card and prompt-card input suites. Lost alarms include replacement approval A settling after answered B; collapse/expand composer ownership and partial-answer presentation; identical new waits after an unmounted view; collapsed transcript re-reads; answered/dismissed status-backed persistence and retirement; and literal answer-to-PTY byte arrays. The retained stale-PTY acknowledgment, cancellation/answer retry, and answered-approval remount/rebind assertions remain meaningful but are not equivalent replacement coverage. No fresh reduced-selector result, physical provider, rendered/native-focus, mixed-version deployment, soak, or measured-budget validation is claimed. The unchanged wire-codec receipt remains valid only for its exact command. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Retained unchanged-selector receipts are the only current execution evidence. Reduced-source assertions await validation. Historical prior oracle: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): After acknowledged phone replies with stale host status, the exact card disappears and Send is enabled; unknown, refused or unverifiable-settlement replies retain enabled choices, while an older host's accepted reply dismisses like an acknowledged one; a same-occurrence view toggle retains pending acknowledgment and real replacements discard it. A slow 32 KiB SSH answer completes all chunks before Enter; cancellation preserves issued bytes but omits remaining groups. Paired settlement invokes the actual provider and lost callbacks remain unknown; older hosts deliver ordinary messages, launch and selector groups once and their accepted answers dismiss as before. An answered card stays hidden across a view remount; a collapsed card is a strip that frees the composer and expands back; an identical question in a new wait shows again; a composer send caught by a new card keeps its bubble without submitting or clearing the line under it. Audit2450 removes the MobileNativeChatView failure-banner callback-only example whose old banner is supplied unchanged by its props. Retain fatal-read gating and the ordering test that preserves a new delivery notice. The removed false-send/old-banner combination has no equivalent replacement; prior raw receipts and budgets retain their original source scope. No new soak, platform, performance or red/green claim.", + "commands": [], + "testFiles": [], + "assertionRefs": [], + "evidenceRuns": [], "runtimeBudget": { "p95Seconds": 300, "scope": "Historical measurement only for changed selectors; no new reduced-source runtime budget is measured. Prior scope: Historical prior-selector budget; changed selectors have no new runtime measurement. Unchanged receipts apply only to their own commands." @@ -599,7 +547,8 @@ "Audit5648 exact complete original commands before retired-suite selector pruning: [\"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/ipc/write-input-user-input.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts src/main/runtime/terminal/input/runtime-terminal-writer.test.ts --maxWorkers=2\",\"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts --maxWorkers=2\",\"ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1\",\"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/ipc/write-input-user-input.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts --maxWorkers=2\",\"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts --maxWorkers=2\"]", "Audit5648 exact complete original testFiles before retired-suite selector pruning: [\"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\"src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts\",\"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts\",\"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts\",\"src/main/ipc/pty/ipc/write-input-user-input.test.ts\",\"src/main/ipc/pty/pty-write-ipc-validation.test.ts\",\"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\"]", "Audit5648 exact complete original assertionRefs before retired-suite selector pruning: [{\"file\":\"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\"assertions\":[\"ignores a raw acknowledgment from a rebound PTY\",\"sends only one cancellation, can cancel an answer, and permits retry after unknown\"]},{\"file\":\"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\"assertions\":[\"retains permission choices on %s\",\"keeps an acknowledged Deny hidden after the chat screen remounts on a lingering status\",\"settles the terminal answer for Q1 after Q2 arrives without hiding Q2\",\"keeps structured answer controls after a thrown send\"]},{\"file\":\"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\"assertions\":[\"waits for complete body settlement before Enter\",\"does not send the suffix after refusal or unknown settlement\",\"returns unknown after an acknowledged prefix followed by refusal or bookkeeping failure\",\"preserves legacy raw body and Enter writes\"]}]", - "IPC/PTY folder cleanup at predecessor d23e47411ae7cfcd2ce51187d3ae07ff0a95e586 retires whole TEST Programs from current selectors: src/main/ipc/pty/pty-write-ipc-validation.test.ts. Their complete authored alarms are intentionally lost. No equivalent replacement, fresh execution, new runtime/performance result, cross-platform, remote, mobile or folder-workspace proof is claimed. Unrelated retained dated receipts remain scoped only to exact unchanged commands. Complete original current selector/assertion fields verbatim:\ncommands: [\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts src/main/runtime/terminal/input/runtime-terminal-writer.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts --maxWorkers=2\"\n ]\ntestFiles: [\n \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts\",\n \"src/main/ipc/pty/pty-write-ipc-validation.test.ts\",\n \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\"\n ]\nassertionRefs: [\n {\n \"file\": \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"assertions\": [\n \"ignores a raw acknowledgment from a rebound PTY\",\n \"sends only one cancellation, can cancel an answer, and permits retry after unknown\"\n ]\n },\n\n {\n \"file\": \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"assertions\": [\n \"retains permission choices on %s\",\n\n \"keeps an acknowledged Deny hidden after the chat screen remounts on a lingering status\",\n \"settles the terminal answer for Q1 after Q2 arrives without hiding Q2\",\n \"keeps structured answer controls after a thrown send\"\n ]\n },\n {\n \"file\": \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"assertions\": [\n \"waits for complete body settlement before Enter\",\n \"does not send the suffix after refusal or unknown settlement\",\n \"returns unknown after an acknowledged prefix followed by refusal or bookkeeping failure\",\n \"preserves legacy raw body and Enter writes\"\n ]\n }\n ]" + "IPC/PTY folder cleanup at predecessor d23e47411ae7cfcd2ce51187d3ae07ff0a95e586 retires whole TEST Programs from current selectors: src/main/ipc/pty/pty-write-ipc-validation.test.ts. Their complete authored alarms are intentionally lost. No equivalent replacement, fresh execution, new runtime/performance result, cross-platform, remote, mobile or folder-workspace proof is claimed. Unrelated retained dated receipts remain scoped only to exact unchanged commands. Complete original current selector/assertion fields verbatim:\ncommands: [\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts src/main/runtime/terminal/input/runtime-terminal-writer.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/ipc/pty/pty-write-ipc-validation.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts --maxWorkers=2\"\n ]\ntestFiles: [\n \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts\",\n \"src/main/ipc/pty/pty-write-ipc-validation.test.ts\",\n \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\"\n ]\nassertionRefs: [\n {\n \"file\": \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"assertions\": [\n \"ignores a raw acknowledgment from a rebound PTY\",\n \"sends only one cancellation, can cancel an answer, and permits retry after unknown\"\n ]\n },\n\n {\n \"file\": \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"assertions\": [\n \"retains permission choices on %s\",\n\n \"keeps an acknowledged Deny hidden after the chat screen remounts on a lingering status\",\n \"settles the terminal answer for Q1 after Q2 arrives without hiding Q2\",\n \"keeps structured answer controls after a thrown send\"\n ]\n },\n {\n \"file\": \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"assertions\": [\n \"waits for complete body settlement before Enter\",\n \"does not send the suffix after refusal or unknown settlement\",\n \"returns unknown after an acknowledged prefix followed by refusal or bookkeeping failure\",\n \"preserves legacy raw body and Enter writes\"\n ]\n }\n ]", + "Runtime layout retirement; exact prior fields are historical only and provide no current execution or replacement-coverage claim:\ncommands: [\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts src/main/runtime/terminal/input/runtime-terminal-writer.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1\",\n \"ORCA_BACKGROUND_LAUNCH=1 pnpm test src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts --maxWorkers=2\",\n \"ORCA_BACKGROUND_LAUNCH=1 mobile/node_modules/.bin/vitest run --config mobile/vitest.config.ts --maxWorkers=2\"\n ]\ntestFiles: [\n \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"src/renderer/src/runtime/hosted-terminals/inspection/runtime-terminal-inspection.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft.test.ts\",\n \"src/renderer/src/lib/agent-session/messaging/paste/agent-paste-draft-submit-retry.test.ts\",\n \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\"\n ]\nassertionRefs: [\n {\n \"file\": \"src/renderer/src/components/native-chat/prompts/NativeChatInteractiveCard.test.tsx\",\n \"assertions\": [\n \"ignores a raw acknowledgment from a rebound PTY\",\n \"sends only one cancellation, can cancel an answer, and permits retry after unknown\"\n ]\n },\n\n {\n \"file\": \"mobile/src/session/native-chat/input/prompts/mobile-prompt-controller.test.ts\",\n \"assertions\": [\n \"retains permission choices on %s\",\n\n \"keeps an acknowledged Deny hidden after the chat screen remounts on a lingering status\",\n \"settles the terminal answer for Q1 after Q2 arrives without hiding Q2\",\n \"keeps structured answer controls after a thrown send\"\n ]\n },\n {\n \"file\": \"src/main/runtime/terminal/input/runtime-terminal-writer.test.ts\",\n \"assertions\": [\n \"waits for complete body settlement before Enter\",\n \"does not send the suffix after refusal or unknown settlement\",\n \"returns unknown after an acknowledged prefix followed by refusal or bookkeeping failure\",\n \"preserves legacy raw body and Enter writes\"\n ]\n }\n ]\nevidenceRuns: [\n {\n \"date\": \"2026-10-06\",\n \"runner\": \"local\",\n \"platform\": \"macos\",\n \"command\": \"ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --maxWorkers=1\",\n \"result\": \"passed\",\n \"durationSeconds\": 25.68,\n \"summary\": \"10 terminal wire codec compatibility cases passed against current and two supported released source versions; this is a codec/RPC-reader contract, not a physical mixed-version paired deployment.\"\n }\n ]\nprotection: \"partial\"\ncoveredPlatforms: [\"macos\"]\ncoveredProviders: []" ], "promotionCriteria": [ "Record change-reverted red/green evidence and repeatable remote rendered approval/question/dictation journeys.", @@ -3555,7 +3504,7 @@ "https://github.com/stablyai/orca/pull/14070" ], "invariant": "Every genuine renderer graph reload revision settles exactly once, while a blocked external navigation that preserves the current document never starts a revision. A cancelled renderer-document navigation restores authority only when that same renderer survived; cancellation after an earlier document committed remains fenced until publication or timeout. Replacing a reload cancels only the prior revision; its timer and callbacks cannot settle a newer revision. A desktop reload succeeds only from a publication carrying a new renderer-document generation, while a failed headless promotion may recover only from its originating window. Timeout, renderer loss, and close reach a terminal graph state, and successful desktop publication permanently retires headless sentinel fallback until a new headless runtime is established.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5644 integrates source audit5640: retire the whole renderer sync-runtime-graph-payload-partition suite and its active command/testFiles selectors. Intentionally lose failed graph publication acknowledgement/memo retry of changed worktree payloads and unchanged worktree resync self-republication alarms. Remaining main/E2E selectors retain only their own scope; no equivalent replacement, fresh execution, platform or remote evidence is claimed. Complete original selectors are preserved in knownGaps. Historical prior account (preserved verbatim): Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. The whole main-window attach-services suite is removed: runtime/window attach, notifier wiring, reload/teardown and permission-handler mock orchestration alarms are intentionally lost. Prune its exact deleted command selectors, testFiles entries and notifier assertionRef where present; complete prior selectors/ref are archived. Unrelated dated receipts remain exact and retain their original scope; no fresh reduced-selector, native-window or remote execution is claimed. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Start a blocked external main-frame navigation and require the current renderer graph and notification path to remain authoritative. Start a same-renderer navigation, cancel it before commit, and require the renderer canary and ready authority to survive; coalesce overlapping provisional starts into one fence, and keep an earlier committed reload fenced if a later navigation is cancelled. Drive two genuine reloads half a timeout apart and require the first deadline to leave the second revision reloading while the second deadline alone makes it unavailable. During the second revision publish from the prior renderer document through the still-current main frame and require rejection without graph mutation or timeout cancellation. Restore headless authority after failed promotion, publish from a competing window, and require rejection while the sentinel remains authoritative. Then force a real renderer crash and separately promote an isolated headless serve owner; require runtime graph readiness, stable runtime/main/daemon/PTY identities, recovered visible terminal output, and post-recovery input/output.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5644 integrates source audit5640: retire the whole renderer sync-runtime-graph-payload-partition suite and its active command/testFiles selectors. Intentionally lose failed graph publication acknowledgement/memo retry of changed worktree payloads and unchanged worktree resync self-republication alarms. Remaining main/E2E selectors retain only their own scope; no equivalent replacement, fresh execution, platform or remote evidence is claimed. Complete original selectors are preserved in knownGaps. Historical prior account (preserved verbatim): Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. The whole main-window attach-services suite is removed: runtime/window attach, notifier wiring, reload/teardown and permission-handler mock orchestration alarms are intentionally lost. Prune its exact deleted command selectors, testFiles entries and notifier assertionRef where present; complete prior selectors/ref are archived. Unrelated dated receipts remain exact and retain their original scope; no fresh reduced-selector, native-window or remote execution is claimed. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Start a blocked external main-frame navigation and require the current renderer graph and notification path to remain authoritative. Start a same-renderer navigation, cancel it before commit, and require the renderer canary and ready authority to survive; coalesce overlapping provisional starts into one fence, and keep an earlier committed reload fenced if a later navigation is cancelled. Drive two genuine reloads half a timeout apart and require the first deadline to leave the second revision reloading while the second deadline alone makes it unavailable. During the second revision publish from the prior renderer document through the still-current main frame and require rejection without graph mutation or timeout cancellation. Restore headless authority after failed promotion, publish from a competing window, and require rejection while the sentinel remains authoritative. Then force a real renderer crash and separately promote an isolated headless serve owner; require runtime graph readiness, stable runtime/main/daemon/PTY identities, recovered visible terminal output, and post-recovery input/output.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/session-graph/runtime-graph-reload-lifecycle.test.ts src/main/runtime/construction/orca-runtime.test.ts", "pnpm exec electron-vite build --mode e2e", @@ -4098,7 +4047,7 @@ "https://github.com/stablyai/orca/pull/13876" ], "invariant": "Opening one HTML preview from a paired client renders the workspace document in exactly one client-local browser tab, located by that document and served over the orca-preview scheme. The client gains exactly that one browser workspace and it is the document one — blank where a URL page carries a URL, named by the document, with the chip naming the file — while the host gains no browser page at all, neither in its own page registry nor in the tab snapshot its clients publish into. The preview occupies its own split without taking focus from the source editor; an explicit click activates it, and closing it removes only the preview. Following a document from a file link is the other half of that switch and does move the reader to it, tab group included, whether the preview is new or already open, because opening a file is a request to look at it. A document tab quit with the client comes back as the same row on a grant the relaunched client mints afresh. A preview is named by the browser page it is open in, not by a namespace of its own, and the page registry has two halves: a workspace-document guest is registered in its own map and is absent from the browsing one entirely. That absence is the fence. Page, session and profile management, agent tab enumeration and command targeting, download routing and certificate attribution all read the browsing map directly, in more places than a per-channel guard could be remembered in, so none of them can name a document page and none of them carries a guard. Browser tools the reader drives (element grab, hover describe, selection capture, the annotation viewport bridge) are the one operation that legitimately spans the halves, and they go through the single authority that reads both, keyed by the page and its hosting renderer. The halves are disjoint in both directions: browsing registration refuses a page the document half already holds, and minting a grant refuses a page the browsing half already holds, so one id can never name a surface in both. The headless backend acts on that refusal by destroying the window it had already opened rather than leaving a policy-less page behind an id nothing can drive, keeping nothing under that id for its own shutdown to hand back. Registration refuses on the same terms when the guest it was asked about is already gone. The exit door is guarded in both its halves: a preview withdraws by revoking its grant and never through the unregister channel, so a page the document half holds arriving there is refused before either the registration teardown or the grab-state disposal beside it, which would otherwise drop the intent an in-flight preview grab compares by identity and leave that grab answering ok without ever arming its guest. A bridge request whose guest does not resolve is refused without tearing down the page it named, so a misaddressed request cannot cancel a healthy page's in-flight downloads and grabs. The annotation viewport bridge resolves its guest when its serialized op actually runs rather than when the request arrived, so a cross-process navigation while it waited cannot leave the bridge installed in a retired guest while the reader looks at a new one. State main keys by a preview's page is disposed when that page's grant is revoked, which is the only signal a preview's surface is gone. A tool asking for a page whose guest has not attached yet waits for that registration and arms when it arrives, rather than answering not-ready at the reader; that wait resolves only the request already naming this page, never the worktree-wide or any-tab waits the CLI and agents use to ask for a browser tab to drive. Handing the previewed document to the reader's own machine routes on the owners its grant was minted against — the file's own connection owner and the worktree's own runtime owner, neither read from the tab's stored fields. Only a document proven to live on this machine reaches the client OS; one with a resolved remote owner is downloaded first; and one whose owner cannot be resolved at all, workspace root included, is refused with a message naming that, because the download route would otherwise read the same absolute path on the client and hand back a same-named local file under the remote document's name. A runtime-owned path that falls outside its worktree root is refused by that route itself and surfaces as a failure toast rather than a download. Nothing the document does writes a file to this machine either: the preview partition denies downloads outright instead of routing them through the browser download flow, which has no page to attribute a preview's bytes to and would otherwise reserve a name in this desktop's Downloads folder and write them there unprompted. That refusal is visible to the reader and invisible to the document: the preview's shell carries a fixed sentence saying downloads are off, published at most once per preview per interval so a document asking in a loop cannot fill Orca's chrome, while the page itself gets back exactly what it got before, which is nothing. The sentence names no file, because the document chooses the name it offers; and a refusal never takes the document away the way an entry document's own failure does, whatever it names. A preview is a browser tab, not an editor tab in a preview mode: it is named the way a browser tab is named — by the document it shows when that document declares a title, and by the file it shows when it does not — while the chip goes on naming the file and the host whatever the document calls itself. A title is refused on the same terms the url is: a document that declares none has Chromium report the grant URL as its title, and that title is stored, mirrored onto the tab and written to disk, so anything carrying the scheme falls back to the file instead. It is created by the preview action as a page located by its document, it carries the workspace-relative path copy the editor's path header owned, and closing it revokes the grant that made the document readable while a URL tab closing beside it revokes nothing. Chrome persisted by builds that made previews editor tabs is dropped on restore rather than coming back naming a surface no restore can produce, and the ordinary editor tab for the same document is left alone. A document tab is held back at the mobile publish boundary — no client holds its grant, and the wire has no tab kind for it — while an ordinary browser tab beside it still publishes. It is held back from the group projection that publishes tab order, recency and group activity as well as from the tab list itself, so no published group names a tab the phone is never sent. A browser page can be located by a workspace document instead of a URL, and the document is the whole of its stored identity. The grant and the orca-preview URL that document is served over are minted when the page mounts and replaced by a hard reload, so neither is ever written to the page's url, mirrored onto its tab, persisted or published: such a page's url is the blank URL from creation through restore, including when a session written elsewhere carries a grant URL in, and what the session carries is the worktree and path a restored page mints afresh against today's owners. Every door onto a page's url holds that line — creation, the title update, and the navigation commit alike — so a report about a document page cannot give it a URL it never had, and the title fallback and the loading affordance follow the url each door actually wrote. The mirror carries the document too, so a tab entry cannot go on naming a document its active page has left. Every guest in the app is policy-attached through one door: a workspace document takes a restricted profile there rather than a separate installer beside it, so the attachment bookkeeping that door owns — what registration refuses, and what teardown frees — covers a preview on the same terms as a browsing page, and a preview takes none of the browsing machinery that door installs. That authority answers from the moment the embedder hands the guest over rather than only after a later navigation: the guest binds to the grant it is already showing, so the tools reach the document the reader opened and not just one they navigated to. A read the host reports as truncated or over-cap is refused rather than served partially, and a document outside the paired worktree is refused with a message naming that boundary instead of a bare read failure. The rendered document reaches nothing off-machine on its own: every served response carries a self-only content security policy, the preview session cancels any request that is not in-document, subframes cannot navigate outside the grant, a guest no document has yet bound to a grant may not navigate at all, the guest gathers no ICE candidates, and an SSH path that canonicalizes outside the grant root is refused before it is read. The one route out is a link the reader presses: a trusted click on an anchor, reported by the preview's own preload from a guest still bound to a live grant, leaves through the configured browser destination and captured source route — and only after the reader confirms the exact destination URL, so a document cannot spend a single stray press exfiltrating what it can read into a link it authored. The preview hands its guest that focus itself whenever it is the surface the reader is in — a browsing page gets it from the chrome around it, and a preview has no chrome to get it from — and it does so only then, so a preview mounted behind a terminal or an editor never takes the keyboard from what the reader is actually in. It offers again when the window itself takes focus back and nothing in the embedder has claimed that focus, because another app coming to the front lands focus on the embedder rather than the guest and the route out would otherwise stay shut until something remounted the pane — while the same window focus also arrives when the reader presses a tab, that being the guest's own blur returning, and taking focus back from there would fight the reader for their own click. Nothing else does. A navigation or popup the document starts by itself is swallowed whatever else is happening, including immediately after a genuine press elsewhere in the document, so a page that can read its grant cannot hand it to a browser tab; a middle click opens nothing; and a fragment link is answered inside the document. A preview attach carries the preview preload and no renderer-supplied one, and no other attach path can acquire it. A subresource the workspace will not send degrades the document to a notice naming that file, never to a failure panel over a page that rendered. A grant outlives neither the tab that owns it nor the renderer document that minted it, and only the trusted renderer can mint or revoke one. For the browser creations this gate still owns, owner-pinned creation returns the canonical host page identity before navigation readiness; delayed navigation cannot turn a created page into an unidentifiable failure or a duplicate retry. Capability rejection before host mutation must preserve the original error, issue no RPC, surface a failure toast, and remove only a caller-declared newly-created empty split. Post-create reconciliation failure requires exact rollback; ambiguous rollback rejects without local fallback.", - "oracle": "Audit6018 removes the whole HtmlDocPreview.toolbar.test.tsx suite. Its last current case exercises real DOM/registry hide, explicit close, recreation and unmount lifetime against supplied native guest boundaries; those alarms are intentionally lost without equivalent replacement. Remove its six compound-selector tokens, testFiles entry and obsolete focus assertionRef (the latter assertions were already absent from the current single case). No complete active dated receipt selects this source; all remain unchanged and do not validate narrowed commands. No fresh runtime/native/import-closure claim. Complete prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5910 retires the complete use-doc-preview-guest-tools suite: token-scoped pending-card position after inner scroll, load reset and detached guest listener cleanup alarms are intentionally lost without equivalent replacement. Narrow three compound selectors and remove its testFiles entry. All remaining assertions/selectors and complete dated evidenceRuns retain only their original scope; no fresh validation or replacement claim. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The complete mocked session-close routing suite is removed, including the explicit cross-worktree cleanup alarm. Remove its active file, command token and assertion reference; historical selectors and receipts retain their original scope. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3342 retires the complete mobile editor/diff tab-publication projection suite: editor/diff serialization, workspace-document privacy withholding, pending/focus and capability/options projections are intentionally lost without equivalent replacement. The surviving focused selectors are unexecuted in this source composition. Six complete compound macOS receipts whose command fields select the changed source are retired verbatim as history; their other selected tests receive no promoted evidence. Other dated receipts keep their original scope; no fresh runtime/UI/mobile/mixed-version or cross-platform validation is claimed. Audit3335 retires the complete three-case browser-tabs snapshot assembly suite: canonical snapshot replay/placement/focus, local host-page adoption and unstamped host echo leaving a local page untouched alarms are intentionally lost without equivalent replacement. The surviving focused selector is unexecuted in this source composition. Unrelated dated receipts keep their original scope; no fresh runtime/network, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Audit 3301 removes the caller-chat-target precedence over host selection example from web-session-tabs-sync-focus-intent.test.ts. The snapshot-before-RPC replay and split-sibling-first exact-leaf focus cases remain unchanged and match the existing assertion reference. Preserve current selectors, assertion references, unrelated active receipts and complete archived history. These mocked state-composition survivors provide no equivalent replacement, rendered, native, network or fresh execution proof. Audit3108: doc-preview-grants.test.ts now retains only the stale grant-rejection race: a late rejected grant request must not evict a newer grant registry entry, witnessed by later revocation of grant-2. Retire stable minted-location and outside-workspace POSIX/Windows request-projection alarms without replacement. The direct nonempty grant selector remains unchanged; no real grant-server/file authorization, SSH/HTML delivery or native-focus result is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2043: Remove the registration-wait, webview-security, preview-authorization, guest-lifecycle and grant-IPC unit suites and the sibling-directory assertion reference. Runtime and browser capability consumers also lose removed imported examples. Remaining document-policy, file-reader and grant-registry assertions do not replace those alarms. Preserve the 27 independent dated receipts at their original unchanged selectors; reduced prospective unit selectors have no fresh result or equivalent replacement claim. Historical prior account (preserved verbatim): Audit1973: Delete the browser RPC forwarding/schema/scalar suite and its prospective selector. Preserve all27 unrelated dated receipts; no actual browser operation alarm is replaced. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): The complete terminal-file-link-actions suite is removed. Lose supplied local/remote menu-row inventories, browser label/order/download/reveal callback forwarding, platform-copy and source-group pinning examples. No OS reveal/download, real remote preview or browser navigation was exercised; the other real document-preview sources are not equivalent replacements. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1709 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1687 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1421 narrows renderer unit coverage as recorded in coverageNotes. Prior oracle descriptions are historical for the changed suite. The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Retained unchanged-selector receipts are the only current execution evidence. Reduced-source assertions await validation. Historical prior oracle: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): In paired Electron, write an HTML fixture that declares its own title on the host, invoke the Explorer preview action on the client, and require the document text to be readable out of the orca-preview guest before judging any absence. With that presence established, require the client to hold exactly one browser workspace more than its baseline and that workspace to be the document one: page and tab url blank, the document path mirrored onto both, the tab named by the document's title, the chip naming the file, no editor row of the retired preview species anywhere, and the guest URL carrying the orca-preview scheme. Ask the host through its own page registry as well as through the tab snapshot, and in the same run open an ordinary URL browser tab from the same client and require that one to arrive in both — the presence precondition without which “the host gained nothing” is satisfied just as well by an oracle that cannot see browser pages at all. Require the preview to sit in a group other than the source editor's while the active group and tab remain the source editor's. Then click away to the terminal, click the preview tab, require it to reactivate and still render, close it with its own X, and require the document tab to be gone while the host still holds only the URL tab and the source group, source editor and terminal survive. Quit the client with a document tab open and relaunch it on the same profile: require the same workspace row to come back, blank and named by the document, rendering the document again over a grant URL that differs from the one that was quit, with no preview-scheme or document-named page anywhere in what the host holds. Prove the halves are live by flipping one product property at a time and requiring the run to fail: publish document workspaces to the host like ordinary ones, and stop mirroring the document onto the workspace row. Have the fixture document attempt its own egress on every load — an unattended window.open and location.href to an off-machine URL, plus an inline ICE gathering probe — and require the same baseline counts and a candidate count of zero, so the document's own attempts are measured rather than assumed. Then, as a separate phase after the close oracle has already run, bring the client window to the front, press the document's heading with a real mouse event, and require the document to report that the same press drove it to attempt a second window.open and location.href while both browser counts stay at that phase's baseline and nothing routes — the case a recent-input gate cannot distinguish from the press's own effect. Only then press the target=_blank link with a real mouse event and require both a recorded routing call that returned success and a browser count above that baseline, with the preview tab still open. Drive the preload's click policy as a unit oracle over a real document: a dispatched click, a trusted press on an external anchor, an anchor reached through what it wraps, an SVG animated href, a sibling preview link, fragment and percent-encoded fragment targets, a bare hash, and a middle click. Create a browser page located by a workspace document, handing creation a live grant URL, and require its stored url, its mirrored tab url and the written session payload all to be blank with no orca-preview string anywhere in what was written, while an ordinary page created the same way keeps the URL it was given and asks for the address bar the document page never does. Parse the written page and tab through the session schema and require the document to survive both halves. Hydrate them back and require the document page to return blank and still named — including when its page row was salvaged away and only the tab's own copy remains, and when a foreign session carried a grant URL into both rows. Drive the mirror across a page switch out of the document and back, and across a repair in which the document is the only mirrored field that differs. Name a document page from its document and require the tab to take that name, name it with an empty title and require the file, name it with a live grant URL and require the file again with no preview scheme anywhere in the written session, and require an ordinary blank browser tab beside it to still be called New Tab. Dispatch a title update out of a rendered preview's own guest and require it to reach the page state while the identity chip still reads the document's workspace-relative path. Attach a browsing guest and a workspace-document guest through the same method in one run and require the browsing one to take clicked-link routing, popup handling and auth-identity detach tracking while the document guest takes none of them, stays inside the grant it is showing, denies every window it asks for, and is dropped from the page-keyed document registry by the same teardown that frees its id for a later attach. Register a browsing guest and attach a workspace-document guest in one run against the real manager, require the one door to answer each page with the guest of its own half, and require the document page to be absent from the browsing map and from its enumeration. Drive both browsing registration entry points with a page the document half already holds and require them to register nothing, and drive the mint channel with a page the browsing half already holds and require it to refuse; and drive the offscreen one with a guest that is missing and with one already destroyed, requiring the same refusal. Arm a grab on a live preview target, drive the unregister channel at that same target in the window before the queued operation runs, and require the grab to reach the guest anyway — then drive the same sequence for an ordinary browser page and require its grab state to be disposed after all. Hold one viewport-bridge op open, queue a second behind it, swap the page's guest while that second op waits, and require the injection to land in the guest the page has then. Revoke a grant after a tool has run against its page and require that page's grab state to be cancelled and disposed. Ask a tool for a document page whose guest has not attached, require the request to park in the registration wait, attach the guest, and require the same request to arm on it; require a page nothing ever renders to answer not-ready once that wait elapses. With a document open, ask a tool for a browsing page id and require it to be answered by the browsing half or not at all, with the same channel reaching the document guest under the page it really renders. Drive open-externally for a document whose per-file owner is remote while the workspace-scoped owner is unresolved, for a runtime-owned worktree whose preview tab carries no runtime id of its own, and for a worktree that resolves no runtime owner while the tab still carries one, requiring the download route in each; and for an owner that cannot be resolved at all, and for an unknown workspace root while nothing names another host, requiring a refusal that neither opens nor downloads. Drive the headless backend with a page the document half already holds and require it to reject, destroy the window, and unregister nothing — then shut the backend down and require it still to have unregistered nothing. Navigate a bound preview guest at a second grant through both latch events and require it to stay on the grant it bound to. Mount a preview while a renderer drag is already in flight and require its guest to be click-through at the moment it is appended, not a turn later. Render the editor panel shell in each remaining tab mode and require the path header exactly where the surface does not already name itself. Drive the preview action and require a browser tab located by the document rather than an editor tab, require a second open of the same document to activate the tab it is already in, and require closing that tab to revoke its grant while a URL tab closed beside it revokes none. Publish a worktree holding a document tab and a URL tab and require only the URL tab to reach the mobile snapshot. Install the shared partition policies for a preview partition and for an ordinary browsing partition in the same run, fire each one's own will-download listener, and require the preview's to cancel while the browsing one still reaches the download router — then require the preview protocol installer to be what asks for that deny. In the same run, require the cancelled download to raise a reader-facing notice and the routed one to raise none. require the guest registry to name the bound grant for a live preview guest and nothing for a contents that is not one, has committed no document, or is gone. Drive the shell with a refusal and require one fixed sentence, still one row after three more refusals, standing beside an asset failure rather than being counted with it, gone behind the failure panel, and ignored when it names another preview's grant. Drive the main-side report gate directly for a sender that is no preview guest, a guest with no bound or a revoked grant, a genuine press Electron's webview focus flag misreports as unfocused, and non-web URLs; drive the reader-facing confirmation for accept, cancel, and a confirmed tab the browser refuses; and drive will-attach-webview in both preload directions. Run the per-owner reader, grant-containment, scheme-admission, guest-policy, and plan-routing contracts as unit oracles, including a host-reported truncation, an over-cap binary, and an out-of-worktree paired path. Drive the reader-facing component with the payloads the reader can actually produce — the entry document fails only as truncated or unreadable, a subresource additionally as a refused format — and require the asset case to leave the guest mounted. Drive the closed-tab cleanup hook, the window installer, and the grant IPC handlers directly, requiring the grant to be released when the preview tab closes, cleared at window creation and on a cross-document main-frame navigation, and refused to any sender that is not the trusted renderer. For the browser creations this gate still owns, run the unchanged contract oracle for direct create and side-preview callers with absent status, unknown capabilities, and a mixed-version host, requiring the original unsupported error or visible toast, zero RPCs, and no retained new split; hold a real navigation response beyond the 15-second client deadline after host creation and require the first RPC to return the exact host inventory page ID, one host page, and no retry; repeat reconciliation faults against headless serve and retain the separate exact-page reconciliation rollback oracle. Audit2452 removes the whole fake-effect browser-close routing suite. Active selectors and assertion references no longer select it. Its requested-worktree default close, sibling-page close and explicit missing-page typed reply alarms are intentionally retired without equivalent replacement. Prior dated receipts remain unchanged and scoped to their original sources; no fresh execution of the reduced gate, rendered browser, live remote, mobile or cross-platform validation is claimed.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit6018 removes the whole HtmlDocPreview.toolbar.test.tsx suite. Its last current case exercises real DOM/registry hide, explicit close, recreation and unmount lifetime against supplied native guest boundaries; those alarms are intentionally lost without equivalent replacement. Remove its six compound-selector tokens, testFiles entry and obsolete focus assertionRef (the latter assertions were already absent from the current single case). No complete active dated receipt selects this source; all remain unchanged and do not validate narrowed commands. No fresh runtime/native/import-closure claim. Complete prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5910 retires the complete use-doc-preview-guest-tools suite: token-scoped pending-card position after inner scroll, load reset and detached guest listener cleanup alarms are intentionally lost without equivalent replacement. Narrow three compound selectors and remove its testFiles entry. All remaining assertions/selectors and complete dated evidenceRuns retain only their original scope; no fresh validation or replacement claim. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. The complete mocked session-close routing suite is removed, including the explicit cross-worktree cleanup alarm. Remove its active file, command token and assertion reference; historical selectors and receipts retain their original scope. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3342 retires the complete mobile editor/diff tab-publication projection suite: editor/diff serialization, workspace-document privacy withholding, pending/focus and capability/options projections are intentionally lost without equivalent replacement. The surviving focused selectors are unexecuted in this source composition. Six complete compound macOS receipts whose command fields select the changed source are retired verbatim as history; their other selected tests receive no promoted evidence. Other dated receipts keep their original scope; no fresh runtime/UI/mobile/mixed-version or cross-platform validation is claimed. Audit3335 retires the complete three-case browser-tabs snapshot assembly suite: canonical snapshot replay/placement/focus, local host-page adoption and unstamped host echo leaving a local page untouched alarms are intentionally lost without equivalent replacement. The surviving focused selector is unexecuted in this source composition. Unrelated dated receipts keep their original scope; no fresh runtime/network, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Audit 3301 removes the caller-chat-target precedence over host selection example from web-session-tabs-sync-focus-intent.test.ts. The snapshot-before-RPC replay and split-sibling-first exact-leaf focus cases remain unchanged and match the existing assertion reference. Preserve current selectors, assertion references, unrelated active receipts and complete archived history. These mocked state-composition survivors provide no equivalent replacement, rendered, native, network or fresh execution proof. Audit3108: doc-preview-grants.test.ts now retains only the stale grant-rejection race: a late rejected grant request must not evict a newer grant registry entry, witnessed by later revocation of grant-2. Retire stable minted-location and outside-workspace POSIX/Windows request-projection alarms without replacement. The direct nonempty grant selector remains unchanged; no real grant-server/file authorization, SSH/HTML delivery or native-focus result is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2043: Remove the registration-wait, webview-security, preview-authorization, guest-lifecycle and grant-IPC unit suites and the sibling-directory assertion reference. Runtime and browser capability consumers also lose removed imported examples. Remaining document-policy, file-reader and grant-registry assertions do not replace those alarms. Preserve the 27 independent dated receipts at their original unchanged selectors; reduced prospective unit selectors have no fresh result or equivalent replacement claim. Historical prior account (preserved verbatim): Audit1973: Delete the browser RPC forwarding/schema/scalar suite and its prospective selector. Preserve all27 unrelated dated receipts; no actual browser operation alarm is replaced. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): The complete terminal-file-link-actions suite is removed. Lose supplied local/remote menu-row inventories, browser label/order/download/reveal callback forwarding, platform-copy and source-group pinning examples. No OS reveal/download, real remote preview or browser navigation was exercised; the other real document-preview sources are not equivalent replacements. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1709 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1687 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1421 narrows renderer unit coverage as recorded in coverageNotes. Prior oracle descriptions are historical for the changed suite. The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Retained unchanged-selector receipts are the only current execution evidence. Reduced-source assertions await validation. Historical prior oracle: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): In paired Electron, write an HTML fixture that declares its own title on the host, invoke the Explorer preview action on the client, and require the document text to be readable out of the orca-preview guest before judging any absence. With that presence established, require the client to hold exactly one browser workspace more than its baseline and that workspace to be the document one: page and tab url blank, the document path mirrored onto both, the tab named by the document's title, the chip naming the file, no editor row of the retired preview species anywhere, and the guest URL carrying the orca-preview scheme. Ask the host through its own page registry as well as through the tab snapshot, and in the same run open an ordinary URL browser tab from the same client and require that one to arrive in both — the presence precondition without which “the host gained nothing” is satisfied just as well by an oracle that cannot see browser pages at all. Require the preview to sit in a group other than the source editor's while the active group and tab remain the source editor's. Then click away to the terminal, click the preview tab, require it to reactivate and still render, close it with its own X, and require the document tab to be gone while the host still holds only the URL tab and the source group, source editor and terminal survive. Quit the client with a document tab open and relaunch it on the same profile: require the same workspace row to come back, blank and named by the document, rendering the document again over a grant URL that differs from the one that was quit, with no preview-scheme or document-named page anywhere in what the host holds. Prove the halves are live by flipping one product property at a time and requiring the run to fail: publish document workspaces to the host like ordinary ones, and stop mirroring the document onto the workspace row. Have the fixture document attempt its own egress on every load — an unattended window.open and location.href to an off-machine URL, plus an inline ICE gathering probe — and require the same baseline counts and a candidate count of zero, so the document's own attempts are measured rather than assumed. Then, as a separate phase after the close oracle has already run, bring the client window to the front, press the document's heading with a real mouse event, and require the document to report that the same press drove it to attempt a second window.open and location.href while both browser counts stay at that phase's baseline and nothing routes — the case a recent-input gate cannot distinguish from the press's own effect. Only then press the target=_blank link with a real mouse event and require both a recorded routing call that returned success and a browser count above that baseline, with the preview tab still open. Drive the preload's click policy as a unit oracle over a real document: a dispatched click, a trusted press on an external anchor, an anchor reached through what it wraps, an SVG animated href, a sibling preview link, fragment and percent-encoded fragment targets, a bare hash, and a middle click. Create a browser page located by a workspace document, handing creation a live grant URL, and require its stored url, its mirrored tab url and the written session payload all to be blank with no orca-preview string anywhere in what was written, while an ordinary page created the same way keeps the URL it was given and asks for the address bar the document page never does. Parse the written page and tab through the session schema and require the document to survive both halves. Hydrate them back and require the document page to return blank and still named — including when its page row was salvaged away and only the tab's own copy remains, and when a foreign session carried a grant URL into both rows. Drive the mirror across a page switch out of the document and back, and across a repair in which the document is the only mirrored field that differs. Name a document page from its document and require the tab to take that name, name it with an empty title and require the file, name it with a live grant URL and require the file again with no preview scheme anywhere in the written session, and require an ordinary blank browser tab beside it to still be called New Tab. Dispatch a title update out of a rendered preview's own guest and require it to reach the page state while the identity chip still reads the document's workspace-relative path. Attach a browsing guest and a workspace-document guest through the same method in one run and require the browsing one to take clicked-link routing, popup handling and auth-identity detach tracking while the document guest takes none of them, stays inside the grant it is showing, denies every window it asks for, and is dropped from the page-keyed document registry by the same teardown that frees its id for a later attach. Register a browsing guest and attach a workspace-document guest in one run against the real manager, require the one door to answer each page with the guest of its own half, and require the document page to be absent from the browsing map and from its enumeration. Drive both browsing registration entry points with a page the document half already holds and require them to register nothing, and drive the mint channel with a page the browsing half already holds and require it to refuse; and drive the offscreen one with a guest that is missing and with one already destroyed, requiring the same refusal. Arm a grab on a live preview target, drive the unregister channel at that same target in the window before the queued operation runs, and require the grab to reach the guest anyway — then drive the same sequence for an ordinary browser page and require its grab state to be disposed after all. Hold one viewport-bridge op open, queue a second behind it, swap the page's guest while that second op waits, and require the injection to land in the guest the page has then. Revoke a grant after a tool has run against its page and require that page's grab state to be cancelled and disposed. Ask a tool for a document page whose guest has not attached, require the request to park in the registration wait, attach the guest, and require the same request to arm on it; require a page nothing ever renders to answer not-ready once that wait elapses. With a document open, ask a tool for a browsing page id and require it to be answered by the browsing half or not at all, with the same channel reaching the document guest under the page it really renders. Drive open-externally for a document whose per-file owner is remote while the workspace-scoped owner is unresolved, for a runtime-owned worktree whose preview tab carries no runtime id of its own, and for a worktree that resolves no runtime owner while the tab still carries one, requiring the download route in each; and for an owner that cannot be resolved at all, and for an unknown workspace root while nothing names another host, requiring a refusal that neither opens nor downloads. Drive the headless backend with a page the document half already holds and require it to reject, destroy the window, and unregister nothing — then shut the backend down and require it still to have unregistered nothing. Navigate a bound preview guest at a second grant through both latch events and require it to stay on the grant it bound to. Mount a preview while a renderer drag is already in flight and require its guest to be click-through at the moment it is appended, not a turn later. Render the editor panel shell in each remaining tab mode and require the path header exactly where the surface does not already name itself. Drive the preview action and require a browser tab located by the document rather than an editor tab, require a second open of the same document to activate the tab it is already in, and require closing that tab to revoke its grant while a URL tab closed beside it revokes none. Publish a worktree holding a document tab and a URL tab and require only the URL tab to reach the mobile snapshot. Install the shared partition policies for a preview partition and for an ordinary browsing partition in the same run, fire each one's own will-download listener, and require the preview's to cancel while the browsing one still reaches the download router — then require the preview protocol installer to be what asks for that deny. In the same run, require the cancelled download to raise a reader-facing notice and the routed one to raise none. require the guest registry to name the bound grant for a live preview guest and nothing for a contents that is not one, has committed no document, or is gone. Drive the shell with a refusal and require one fixed sentence, still one row after three more refusals, standing beside an asset failure rather than being counted with it, gone behind the failure panel, and ignored when it names another preview's grant. Drive the main-side report gate directly for a sender that is no preview guest, a guest with no bound or a revoked grant, a genuine press Electron's webview focus flag misreports as unfocused, and non-web URLs; drive the reader-facing confirmation for accept, cancel, and a confirmed tab the browser refuses; and drive will-attach-webview in both preload directions. Run the per-owner reader, grant-containment, scheme-admission, guest-policy, and plan-routing contracts as unit oracles, including a host-reported truncation, an over-cap binary, and an out-of-worktree paired path. Drive the reader-facing component with the payloads the reader can actually produce — the entry document fails only as truncated or unreadable, a subresource additionally as a refused format — and require the asset case to leave the guest mounted. Drive the closed-tab cleanup hook, the window installer, and the grant IPC handlers directly, requiring the grant to be released when the preview tab closes, cleared at window creation and on a cross-document main-frame navigation, and refused to any sender that is not the trusted renderer. For the browser creations this gate still owns, run the unchanged contract oracle for direct create and side-preview callers with absent status, unknown capabilities, and a mixed-version host, requiring the original unsupported error or visible toast, zero RPCs, and no retained new split; hold a real navigation response beyond the 15-second client deadline after host creation and require the first RPC to return the exact host inventory page ID, one host page, and no retry; repeat reconciliation faults against headless serve and retain the separate exact-page reconciliation rollback oracle. Audit2452 removes the whole fake-effect browser-close routing suite. Active selectors and assertion references no longer select it. Its requested-worktree default close, sibling-page close and explicit missing-page typed reply alarms are intentionally retired without equivalent replacement. Prior dated receipts remain unchanged and scoped to their original sources; no fresh execution of the reduced gate, rendered browser, live remote, mobile or cross-platform validation is claimed.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/browser/client-pages/orca-runtime-browser.test.ts", "pnpm exec vitest run --config config/vitest.config.ts src/main/browser/document-preview/doc-preview-file-reader.test.ts src/main/browser/document-preview/doc-preview-guest-policy.test.ts src/shared/document-preview/doc-preview-scheme.test.ts src/renderer/src/components/browser-pane/workspace-doc/doc-preview-external-link-confirmation.test.ts", @@ -5496,10 +5445,10 @@ "coverageNotes": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5901 removes only the mobile-creation-and-orchestration-part-03.spec import from the retained runtime driver. The fragment's missing-handle wait abort and waiter retirement on reload-exit alarms are intentionally lost. This is a conservative import-closure notice: named command filters may exclude those cases. Driver selectors remain; unchanged historical receipts retain their original scope and establish no fresh whole-gate pass or equivalent replacement. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5708 retires the whole controlled-proof terminal-shell-recovery-barrier suite, accepting reset/release ordering, late/dead/refuted proof, throwing sink, nested episode and deadline alarms. Active command/testFiles selectors are reduced; no equivalent replacement or fresh execution is claimed. Historical dated scopes remain unchanged. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4345 deletes the foreground agent-process suite (8 authored cases): nested/stopped POSIX shells, recycled/query-denied Windows anchors and console-attachment filtering/refusal alarms are deliberately lost without equivalent replacement. Reduced selectors have no fresh gate execution; unrelated historical receipts retain their own commands. Audit3994 retires two authored callbacks imported by the shared construction test driver: split OSC 9999 carry and rendererless status ownership, plus OpenCode permission text taking priority in status and tui-idle refusal. Remaining imports and selectors keep their scope. No equivalent replacement or fresh gate execution is claimed. Audit3984 retires all nine mobile-presence and imported subscribe callbacks plus their orphan store fixture. Accepted losses include desktop/phone restore geometry, echo filtering, held reconnect/reclaim notifications, and the real headless snapshot sequence race. No equivalent replacement or fresh gate execution is claimed. Audit 3959 retires the whole session.test.ts driver (27 authored / 33 finite cases): startup/echo filtering, readiness input gates, ownership confirmation, detach authority, and termination retry/exit ordering alarms are intentionally lost. No equivalent replacement or fresh runtime validation is claimed. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial mobile-presence suite retains only five authored callbacks: admitted preview-paste completion across phone takeover, desktop take-back superseding mobile input, desktop viewport write/restore geometry, and held-fit reclaim convergence. Other supplied floor/rollback/selection/viewport/grace/disconnect/reconnect/orphan-state alarms are lost. No per-source assertion object exists to reassign. The one affected dated mobile-view-authority receipt is retired whole into historical notes with its full original/currentCommand/raw data preserved; it is not active corroboration for reduced candidate bytes. Imported mobile-subscribe registrations and retained callbacks remain bounded to their actual source obligations, without equivalent replacement or physical-phone/native-PTY claims. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1709 removes low-value test definitions and retires affected assertion or execution-receipt claims without equivalent replacement coverage. Per-source reviews bound retained behavior and injected/native/remote limits. Unchanged assertions and receipts keep their original scope; gates lacking current active evidence are downgraded. Historical scope before this audit: Audit1683 removes low-value test projections, mock wiring, private-state assertions, inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained public behavior and refusal boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1627 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1623 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Audit1417 intentionally deletes src/renderer/src/components/terminal-pane/pty-connection-hidden-tui-snapshot-replay.spec.ts: Loses rich hidden snapshot sequence replay/grid resize and forced repaint after hidden snapshot alarms, including live-trigger deduplication. No equivalent replacement coverage or fresh result is claimed. Historical coverage account: Audit1320 changes referenced sources. Retained unchanged-source receipts apply only to their unchanged commands; the reduced selectors have no new execution result. Historical coverage account (not a current claim for changed sources): Deterministic host/parser, process-classifier, snapshot-publication, mixed-version, renderer, and macOS Electron coverage proves the local and shared paired-runtime contracts. Direct SSH intentionally publishes no shell proof and immediately preserves incumbent behavior. WSL, Windows ConPTY, Linux desktop, and paired headed/headless journeys remain gaps. The audit removed the isolated terminal-multiplex pending-escape-tail forwarding test. Its direct RPC snapshot field-copy alarm is lost; retained parser, snapshot and lifecycle suites do not establish equivalent RPC field coverage. Audit1320: src/renderer/src/components/terminal-pane/remote-runtime-pty-snapshot-escape-tail.test.ts removed. Snapshot pending escape/alternate-screen/shell metadata forwarding and negative app-store-read alarm disappears. No equivalent replacement coverage is claimed. Audit1383: src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts reduced. Lose command-list/receipt/default/background activation matrices whose provider spawn returns canned IDs. Retained test proves actual tab allocation separation, not terminal startup. No equivalent replacement coverage is claimed. Existing exact unaffected receipts and their platform/provider/budget claims remain scoped to unchanged selectors. Changed optional selectors have no new execution result. Audit1391: src/renderer/src/components/terminal-pane/pty-connection-remote-pause-drop-notice.spec.ts reduced. Lose repeated quiet switches avoiding snapshots and legacy host without drop-report capability requesting a snapshot. Retained imported registrar uses fake transport/xterm writes, exercising real gap/restore lifecycle rather than actual terminal rendering. No equivalent replacement coverage is claimed. The existing primary-selector receipt and its claims remain scoped to their unchanged sources; the broad optional command has no new execution result. Audit1401: src/main/runtime/orca-runtime-tests/mobile-session-tabs-duplicate-pty-repair.spec.ts removed. Loses listing-on-already-repaired-data alarm; it never established runtime repair invocation. src/main/runtime/orca-runtime-tests/mobile-session-tabs-split-agent-tab.spec.ts removed. Loses actual mobile split sibling shell versus recorded-agent resume command alarms; no equivalent coverage asserted. src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts removed. Loses separate setup/startup tab result in that manually assembled path. src/main/runtime/orca-runtime.test.ts reduced. Driver registration/import of a whole-deleted selected spec is removed; directly authored cases remain unchanged. No extra authored removal credit. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1402: src/renderer/src/components/terminal-pane/pty-connection-park-reveal-model-snapshot.spec.ts reduced. Loses basic paired serialize/initial replay forwarding check; hidden alt-frame grid/precedence policy remains. No real terminal renderer claim. No equivalent replacement coverage is claimed. The existing primary-selector receipt and its claims remain scoped to their unchanged sources; the broad optional command has no new execution result. Audit1412: src/main/daemon/terminal-host-concurrent-create.test.ts reduced. Loses race deduplication, attach during unsettled ownership proof, retry after failed spawn, distinct-session parallelism, disposal waiting and shutdown retry-fencing alarms bundled with removed internal-call counts or real-time waits. No replacement-equivalence claim. src/main/daemon/terminal-checkpoint-serializer.test.ts reduced. Loses bounded native conversion/no-whole-candidate materialization and snapshot getter single-read alarms. Retained byte-size outcomes do not establish CPU/allocation bounds. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Prospective settings-host12 runtime-ipc110 reduction: The runtime compatibility driver is intentionally narrowed by runtime-ipc110 whole-registration policy: four imported TEST fragments are retired and reviewed partial fragments lose complete callbacks. Full path/title/hash and lost-alarm records are bound in the local runtime-ipc110 recipe. This is an import-closure disclosure; command filters may select only part of that driver. All remaining selectors keep only their own bounded scope. Preserve every earlier narrative, historical assertion receipt and dated evidenceRun exactly. Historical runs do not validate the reduced registration set; no fresh test, timing, runtime or whole-gate pass is claimed.", "motivatingLinks": ["https://github.com/stablyai/orca/pull/16379"], "invariant": "After a TUI exits or is killed, reveal, reattach, snapshot replay, or renderer remount must not deliver terminal-owned mouse or alternate-screen protocol bytes to the surviving shell. Recovery is an ordered output barrier in the daemon session data path: an OSC 133;D completing while the alternate screen is still active pauses the stream at that exact byte boundary, a fresh execution-host process inspection proves shell ownership, and on proof a mode reset is injected as in-stream output so every consumer converges by parsing the same bytes and the queued post-boundary shell output (the prompt) lands on the normal buffer. Snapshots are pure reads. Any failure — refuted proof, timeout, queue overflow, session death, disposal — flushes the queue unmodified, preserving incumbent behavior; later command or mode bytes revoke proof. Clean alternate-screen exits prove ownership asynchronously without pausing.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial mobile-presence suite retains only five authored callbacks: admitted preview-paste completion across phone takeover, desktop take-back superseding mobile input, desktop viewport write/restore geometry, and held-fit reclaim convergence. Other supplied floor/rollback/selection/viewport/grace/disconnect/reconnect/orphan-state alarms are lost. No per-source assertion object exists to reassign. The one affected dated mobile-view-authority receipt is retired whole into historical notes with its full original/currentCommand/raw data preserved; it is not active corroboration for reduced candidate bytes. Imported mobile-subscribe registrations and retained callbacks remain bounded to their actual source obligations, without equivalent replacement or physical-phone/native-PTY claims. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1709 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Run one fixed child-TUI journey for normal exit and cleanup-free SIGKILL. Assert renderer and host normal-buffer/non-mouse state, host snapshot terminalOwner metadata, exact PTY writes with no post-exit mouse report, unrelated-pane survival, post-boundary prompt output preserved (normal exit), ordered proof invalidation, bounded settlement and bail-out flush, one inspection per unclean episode with zero scans for ordinary output, split-escape safety at every chunk boundary, and old/new client-host fallback parity.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial mobile-presence suite retains only five authored callbacks: admitted preview-paste completion across phone takeover, desktop take-back superseding mobile input, desktop viewport write/restore geometry, and held-fit reclaim convergence. Other supplied floor/rollback/selection/viewport/grace/disconnect/reconnect/orphan-state alarms are lost. No per-source assertion object exists to reassign. The one affected dated mobile-view-authority receipt is retired whole into historical notes with its full original/currentCommand/raw data preserved; it is not active corroboration for reduced candidate bytes. Imported mobile-subscribe registrations and retained callbacks remain bounded to their actual source obligations, without equivalent replacement or physical-phone/native-PTY claims. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1709 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Run one fixed child-TUI journey for normal exit and cleanup-free SIGKILL. Assert renderer and host normal-buffer/non-mouse state, host snapshot terminalOwner metadata, exact PTY writes with no post-exit mouse report, unrelated-pane survival, post-boundary prompt output preserved (normal exit), ordered proof invalidation, bounded settlement and bail-out flush, one inspection per unclean episode with zero scans for ordinary output, split-escape safety at every chunk boundary, and old/new client-host fallback parity.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/daemon/sessions/testing/session-shell-recovery.test.ts src/main/daemon/terminal-host/testing/terminal-host-concurrent-create.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/history/restoration/testing/daemon-restore-scrollback-depth.test.ts src/main/daemon/history/restoration/testing/terminal-checkpoint-serializer.test.ts src/main/runtime/construction/orca-runtime.test.ts src/shared/terminal/protocol/escape/terminal-partial-escape-tail.test.ts src/shared/terminal/protocol/escape/terminal-partial-escape-tail.fuzz.test.ts --reporter=dot", - "pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts --reporter=dot", + "pnpm exec electron-vite build --mode e2e", "SKIP_BUILD=1 pnpm exec playwright test tests/e2e/terminal-hidden-child-tui-kill-mode-reset.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1" ], @@ -5512,7 +5461,7 @@ "src/main/runtime/construction/orca-runtime.test.ts", "src/shared/terminal/protocol/escape/terminal-partial-escape-tail.test.ts", "src/shared/terminal/protocol/escape/terminal-partial-escape-tail.fuzz.test.ts", - "tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts", + "tests/e2e/terminal-hidden-child-tui-kill-mode-reset.spec.ts" ], "assertionRefs": [ @@ -5886,7 +5835,7 @@ "https://github.com/stablyai/orca/issues/14524" ], "invariant": "Close permanently removes the owned provider session, agent descendants, persisted tab/layout authority, and resume authority even when no TerminalPane is mounted; final-pane CLI close commits durable tab retirement before PTY stop can publish graph loss, does not acknowledge before that retirement, and treats the later exit retirement as idempotent. Workspace-wide CLI close applies that same durable contract to every terminal in exactly one worktree, including pinned and persisted-only surfaces, without touching sibling-worktree PTYs or resume records. A persisted explicit-empty state prevents initial-tab fallback from repopulating the workspace after reload or restart. A handle remains valid while the same provider-attested PTY incarnation survives renderer reload or re-key, and becomes stale without adopting a replacement incarnation. A terminating id remains reserved through natural exit, duplicate callers await the same completion, and immediate teardown upgrades any graceful request without signalling a recycled PID or a descendant tree after root ownership is lost; process-table work is locale-stable, bounded, fresh for each post-start request, same-turn coalesced, and begins within the requesting caller's deadline, including bulk worktree cleanup; detach and park preserve ownership; aliases prevent a detached agent's immutable physical pane key from being retired with its former tab.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5631 accompanies Audit5617 whole-suite deletion of src/renderer/src/store/terminals/layout/terminal-pane-detach-agent-identity.test.ts. Accepted loss: Detached leaf foreground/status/launch/resume identity map transfer and sibling preservation. No equivalent replacement or fresh reduced-command validation is claimed. Retained partial protection applies only to independent historical receipt scopes and does not protect these retired alarms. Historical prior account follows: Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Lose the complete completed-worker-retirement-resume suite: exact terminal-close resume-record revocation, PTY-exit recovery retention and settled-worker release examples. Remove its exact command token or standalone command, testFiles entry and assertionRef, archiving complete prior fields. Independent receipts retain original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3323 (reconciled source audit3320) intentionally retires seven low-value renderer authority/retirement examples: retires one pane, clears resume authority, and rejects late status without harming siblings — Late status reviving a retired pane, sibling damage, or resume authority left behind.; can retire live pane authority while retaining its sleeping session — Retiring live authority accidentally dropping a retained sleeping session.; keeps a physical pane routed through chained detaches until its current owner closes — Chained detach alias routing broken after original owner closes, or alias survives final close.; forgets routing aliases for purged tabs — Purged-tab routing aliases lingering.; retires split, relay, deferred, and pending sessions for a parked tab — Split, relay, deferred or pending session omitted from teardown, sleeping-record sibling damaged, parked disposer skipped.; retires parked ownership before teardown and sweeps published state before unified close — Parked cleanup/provider teardown/state removal/sweep/unified-close ordering changes.; starts mixed provider teardown and classifies both rejection kinds after synchronous retirement — Mixed teardown failures blocking retirement, or local/runtime warning counts misclassified.. Remove the exact-pane-retirement and chained-detach assertion references because their source cases are gone. Other retained cases do not replace these alarms. Preserve all dated evidenceRuns and prior history with their original source scope; no fresh execution or historical import-closure equivalence is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1904 reduces persistence-pty-binding-reconciliation from six to four definitions, intentionally losing legacy remap-load and first-binding projection alarms. Current selector/testFile remains valid, with no selected-source assertionRef or active matching receipt. The six unchanged close/continuity receipts keep their exact original scope; no new broad gate or replacement evidence is claimed. Historical prior account (preserved verbatim): Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1674 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Capture exact tab, pane, PTY, handle, incarnation, and persisted layout identities. Final-pane terminal.close must invoke one durability-acknowledged tab retirement before exact PTY teardown; controlled PTY exit and graph removal afterward must remain idempotent, omit the target from persistence and provider inventory, and leave an unrelated canary handle live. terminal.closeAll must force-retire every pinned and unpinned target surface, clear its persisted agent-resume and incarnation records, await authoritative PTY exit, preserve a sibling worktree's tab, PTY, and resume authority, and return an unverifiable failure instead of claiming exit when the owning host does not confirm a stop. The ordinary path stays pending until the persisted row is removed and never falls back to the fire-and-forget pane event; reload/restart must keep the explicitly emptied worktree at zero terminal tabs and provider sessions. Reloading the renderer with the same tab/pane/PTY/incarnation must keep the handle readable; changing only the incarnation behind the same PTY id, losing the authoritative graph, or superseding the renderer handle with a preallocated handle must reject the old handle with terminal_handle_stale. Parked-close tests prove the exact PTY disappears; descendant/process tests keep natural exits reserved, upgrade teardown safely, bound/coalesce process-table work, and protect recycled identities.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5631 accompanies Audit5617 whole-suite deletion of src/renderer/src/store/terminals/layout/terminal-pane-detach-agent-identity.test.ts. Accepted loss: Detached leaf foreground/status/launch/resume identity map transfer and sibling preservation. No equivalent replacement or fresh reduced-command validation is claimed. Retained partial protection applies only to independent historical receipt scopes and does not protect these retired alarms. Historical prior account follows: Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Lose the complete completed-worker-retirement-resume suite: exact terminal-close resume-record revocation, PTY-exit recovery retention and settled-worker release examples. Remove its exact command token or standalone command, testFiles entry and assertionRef, archiving complete prior fields. Independent receipts retain original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3323 (reconciled source audit3320) intentionally retires seven low-value renderer authority/retirement examples: retires one pane, clears resume authority, and rejects late status without harming siblings — Late status reviving a retired pane, sibling damage, or resume authority left behind.; can retire live pane authority while retaining its sleeping session — Retiring live authority accidentally dropping a retained sleeping session.; keeps a physical pane routed through chained detaches until its current owner closes — Chained detach alias routing broken after original owner closes, or alias survives final close.; forgets routing aliases for purged tabs — Purged-tab routing aliases lingering.; retires split, relay, deferred, and pending sessions for a parked tab — Split, relay, deferred or pending session omitted from teardown, sleeping-record sibling damaged, parked disposer skipped.; retires parked ownership before teardown and sweeps published state before unified close — Parked cleanup/provider teardown/state removal/sweep/unified-close ordering changes.; starts mixed provider teardown and classifies both rejection kinds after synchronous retirement — Mixed teardown failures blocking retirement, or local/runtime warning counts misclassified.. Remove the exact-pane-retirement and chained-detach assertion references because their source cases are gone. Other retained cases do not replace these alarms. Preserve all dated evidenceRuns and prior history with their original source scope; no fresh execution or historical import-closure equivalence is claimed. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1904 reduces persistence-pty-binding-reconciliation from six to four definitions, intentionally losing legacy remap-load and first-binding projection alarms. Current selector/testFile remains valid, with no selected-source assertionRef or active matching receipt. The six unchanged close/continuity receipts keep their exact original scope; no new broad gate or replacement evidence is claimed. Historical prior account (preserved verbatim): Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Audit1674 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Capture exact tab, pane, PTY, handle, incarnation, and persisted layout identities. Final-pane terminal.close must invoke one durability-acknowledged tab retirement before exact PTY teardown; controlled PTY exit and graph removal afterward must remain idempotent, omit the target from persistence and provider inventory, and leave an unrelated canary handle live. terminal.closeAll must force-retire every pinned and unpinned target surface, clear its persisted agent-resume and incarnation records, await authoritative PTY exit, preserve a sibling worktree's tab, PTY, and resume authority, and return an unverifiable failure instead of claiming exit when the owning host does not confirm a stop. The ordinary path stays pending until the persisted row is removed and never falls back to the fire-and-forget pane event; reload/restart must keep the explicitly emptied worktree at zero terminal tabs and provider sessions. Reloading the renderer with the same tab/pane/PTY/incarnation must keep the handle readable; changing only the incarnation behind the same PTY id, losing the authoritative graph, or superseding the renderer handle with a preallocated handle must reject the old handle with terminal_handle_stale. Parked-close tests prove the exact PTY disappears; descendant/process tests keep natural exits reserved, upgrade teardown safely, bound/coalesce process-table work, and protect recycled identities.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/terminal/surface/orca-runtime-terminal-close-continuity.test.ts", "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/construction/orca-runtime.test.ts", @@ -6108,7 +6057,7 @@ "https://github.com/stablyai/orca/issues/9229" ], "invariant": "Reconnect, replay, or lifecycle observations from a viewer that negotiated explicit close intent must never kill a live PTY. A capable reasonless close must keep and republish; a legacy paired viewer must retain current-main behavior because its intentional close and cleanup echo are wire-identical. Lifecycle close requires the exact observed publication, terminal, environment, and authoritative liveness, never signals a process, and leaves renderer-owned or partial-split retirement to its owner. Legacy daemon hello and warm reattachment remain non-destructive.", - "oracle": "Audit5922 intentionally retires mixed split/agent parking eligibility classification; incorrect eligibility can unmount a still-needed terminal or hide resume, though the retired predicate suite never mounts or resumes the actual view. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3881 intentionally removes the entire legacy E2EE channel and mobile socket-wiring test suites and the v2 additive runtime-capability refusal callback, without equivalent replacement. Those deleted suites leave current selectors and that v2 assertion alias is retired. Retained v2 replay/queue-counter cases do not establish the removed capability refusal. Reduced test bytes/selectors have no fresh execution in this static packet; independent dated daemon E2E receipts retain their complete original scope. Historical prior account (preserved verbatim): Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3774 (independent peer expansion of3773): deliberately retire7authored/13potential expanded registrations across4whole suites: standalone truncated8-byte E2EE guard; open/empty readiness null fast-path; capability parser acceptance/atomic malformed-array bounds; phone/delegated-parent/desktop/in-process creator provenance projections. These are real guard/policy alarms accepted as low marginal value, not tautologies. No equivalent replacement, authenticated-refusal, observer delivery, persisted visibility, synchronous scheduling or fresh execution is claimed. Prior dated receipts retain their exact original scopes and do not validate the changed/reduced current selector. Independent daemon E2E receipts remain scoped to their own unchanged commands. Historical prior account (preserved verbatim): Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1983: Delete the reasonless-close scalar suite and optional-capability socket forwarding alias. Delete the mocked close-attribution topology field-inventory suite and its aliases/selectors; preserve independent dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1959 (sources 1957:11, 1957:35, 1957:36): The fixture-supplied repository roundtrip, isolated capability metadata readback, parser/default-timer/size-threshold/internal failure-counter examples and standalone handshake-only replay example are removed. Source11 retains real encrypted multi-client event ordering, reconnect snapshot and multiplex delivery under synthetic runtime state, and does not establish the broad handshake-to-reasonless-close refusal alias; retire that whole assertion object. Source36 capability metadata readback alias is retired. Source35 retains the actual v2 runtime-only metadata/downgrade refusal callback and captured mutating-trace fresh-nonce rejection; its mapped mobile-v2 refusal alias remains within modeled credential lookup scope. Both independent daemon E2E dated receipts remain byte-exact with their original commands and results. No historical passed receipt is narrowed or transferred to changed source bytes. No fresh execution, equivalent replacement, physical provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed by this metadata packet. Historical prior account (preserved verbatim): Audit1939 (sources1934/1935): Retain actual parked exit/disposal/cancel/leaf progression using injected exit and close adapters. The retained last-watcher case checks exact lifecyclePtyId, but no retained callback establishes the whole existing replacement-or-sibling-incarnation alias. Retire that broad assertion object rather than transfer partial support. Capability admission, static fields and duplicate routing examples are intentionally lost; unchanged daemon E2E receipts remain scoped to their own commands. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Start isolated v25 and v26 daemon generations with one capable-viewer PTY and one legacy-viewer PTY per generation in four target worktrees plus an unaddressed control PTY in a fifth worktree. Route them through the production desktop scanner, runtime, RPC dispatcher, renderer-close relay, and daemon router. First issue sequential reasonless closes from an authenticated capable connection and require refusal, snapshot republish, zero shutdown calls, exact process survival, and post-close I/O. Then issue the byte-identical requests without the negotiated capability and require current-main behavior: two ordered immediate shutdowns, session-killed events, and exact root/descendant death, while capable and control PTYs survive. An observer lists all targets before, between, and after while issuing zero closes. Unit contracts also require in-process reasonless refusal, legacy runtime/mobile compatibility, explicit user closes, encrypted client-auth advertisement, and old-server lifecycle calls never to fall back. Audit4587 retires the one-case CLI WebSocket protocol/preflight suite and its hand-built server; its cross-layer non-delivery witness is intentionally lost, with no replacement coverage claimed.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5922 intentionally retires mixed split/agent parking eligibility classification; incorrect eligibility can unmount a still-needed terminal or hide resume, though the retired predicate suite never mounts or resumes the actual view. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3881 intentionally removes the entire legacy E2EE channel and mobile socket-wiring test suites and the v2 additive runtime-capability refusal callback, without equivalent replacement. Those deleted suites leave current selectors and that v2 assertion alias is retired. Retained v2 replay/queue-counter cases do not establish the removed capability refusal. Reduced test bytes/selectors have no fresh execution in this static packet; independent dated daemon E2E receipts retain their complete original scope. Historical prior account (preserved verbatim): Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3774 (independent peer expansion of3773): deliberately retire7authored/13potential expanded registrations across4whole suites: standalone truncated8-byte E2EE guard; open/empty readiness null fast-path; capability parser acceptance/atomic malformed-array bounds; phone/delegated-parent/desktop/in-process creator provenance projections. These are real guard/policy alarms accepted as low marginal value, not tautologies. No equivalent replacement, authenticated-refusal, observer delivery, persisted visibility, synchronous scheduling or fresh execution is claimed. Prior dated receipts retain their exact original scopes and do not validate the changed/reduced current selector. Independent daemon E2E receipts remain scoped to their own unchanged commands. Historical prior account (preserved verbatim): Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit1983: Delete the reasonless-close scalar suite and optional-capability socket forwarding alias. Delete the mocked close-attribution topology field-inventory suite and its aliases/selectors; preserve independent dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1959 (sources 1957:11, 1957:35, 1957:36): The fixture-supplied repository roundtrip, isolated capability metadata readback, parser/default-timer/size-threshold/internal failure-counter examples and standalone handshake-only replay example are removed. Source11 retains real encrypted multi-client event ordering, reconnect snapshot and multiplex delivery under synthetic runtime state, and does not establish the broad handshake-to-reasonless-close refusal alias; retire that whole assertion object. Source36 capability metadata readback alias is retired. Source35 retains the actual v2 runtime-only metadata/downgrade refusal callback and captured mutating-trace fresh-nonce rejection; its mapped mobile-v2 refusal alias remains within modeled credential lookup scope. Both independent daemon E2E dated receipts remain byte-exact with their original commands and results. No historical passed receipt is narrowed or transferred to changed source bytes. No fresh execution, equivalent replacement, physical provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed by this metadata packet. Historical prior account (preserved verbatim): Audit1939 (sources1934/1935): Retain actual parked exit/disposal/cancel/leaf progression using injected exit and close adapters. The retained last-watcher case checks exact lifecyclePtyId, but no retained callback establishes the whole existing replacement-or-sibling-incarnation alias. Retire that broad assertion object rather than transfer partial support. Capability admission, static fields and duplicate routing examples are intentionally lost; unchanged daemon E2E receipts remain scoped to their own commands. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Start isolated v25 and v26 daemon generations with one capable-viewer PTY and one legacy-viewer PTY per generation in four target worktrees plus an unaddressed control PTY in a fifth worktree. Route them through the production desktop scanner, runtime, RPC dispatcher, renderer-close relay, and daemon router. First issue sequential reasonless closes from an authenticated capable connection and require refusal, snapshot republish, zero shutdown calls, exact process survival, and post-close I/O. Then issue the byte-identical requests without the negotiated capability and require current-main behavior: two ordered immediate shutdowns, session-killed events, and exact root/descendant death, while capable and control PTYs survive. An observer lists all targets before, between, and after while issuing zero closes. Unit contracts also require in-process reasonless refusal, legacy runtime/mobile compatibility, explicit user closes, encrypted client-auth advertisement, and old-server lifecycle calls never to fall back. Audit4587 retires the one-case CLI WebSocket protocol/preflight suite and its hand-built server; its cross-layer non-delivery witness is intentionally lost, with no replacement coverage claimed.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/mobile/e2ee/e2ee-channel-v2.test.ts src/shared/remote-runtime/remote-runtime-client.test.ts src/shared/remote-runtime/control/remote-runtime-shared-control-connection.test.ts src/renderer/src/components/terminal/tab-lifecycle/terminal-close-incarnation.test.ts", "pnpm exec playwright test tests/e2e/daemon-generation-reconnect-safety.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1", @@ -6755,7 +6704,7 @@ "https://github.com/stablyai/orca/pull/10193" ], "invariant": "For every claim-capable execution route, one provider-session identity has at most one live PTY owner and one canonical host surface across concurrent clients, retries, reconnects, and stale publications. For paired structured fresh and resume requests, the authenticated owning runtime creates in background without a renderer window; activate=true focuses the exact requested leaf only on the requesting viewer, while activate=false changes no viewer focus. A live orphan may be adopted only when the controller proves its exact handle and incarnation, its worktree and host owner match, no competing visual owner exists, and a host topology CAS wins. A viewer may classify completion only from successful host/provider inspection or explicit lifecycle evidence; transport, handle, or provider unavailability remains unknown and breaks any consecutive-idle proof. A physical exit retires that exact incarnation durably so stale client state and host restart cannot recreate it. Mixed-version routes select the unchanged legacy request before any authority side effect or execution-owner-local filesystem access.", - "oracle": "Shared agent/chat layout cleanup retires the remaining mocked agent-session operation-ledger registration: concurrent-retry joining, changed-fingerprint conflicts and exact createTerminal call count. Its active command token and test-file entry are removed. Prior evidence remains historical; no equivalent replacement or fresh gate coverage is claimed. Prior account: Audit5922 intentionally retires Gemini interrupt versus Codex navigation classification and command-finished cleanup arbitration under supplied status/transport; the retained completion wrapper loses exactly two finite arbitration cases while its other registration factories remain. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The Codex restart suite and exact command/testFiles/assertionRef are removed; its mock account-change/remote-pane restart alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3368 retires the whole host-session-launch unit source, including host-authority/create/ensure/legacy/Kimi/refusal/draft/options/prompt/cancel/kill/shared-disconnect and passive-sleep output callback alarms, without equivalent replacement. Its unit command token and test-file entry retire. Five unrelated macOS receipts remain verbatim and keep only their original scope; no fresh changed-selector/runtime/provider/process/UI/mobile/mixed-version/cross-platform evidence is claimed. Audit3359 retires the whole create-handoff suite. Supplied disposition, late completion, close-callback and metadata-bookkeeping alarms are intentionally lost without equivalent replacement; the compound unit selector and test-file entry narrow accordingly. Five unrelated macOS receipts retain their original scope. No fresh runtime, process-deduplication, physical provider/network, historical-import, mobile, mixed-version or cross-platform validation is claimed. Audit 3301 removes the caller-chat-target precedence over host selection example from web-session-tabs-sync-focus-intent.test.ts. The snapshot-before-RPC replay and split-sibling-first exact-leaf focus cases remain unchanged and match the existing assertion reference. Preserve current selectors, assertion references, unrelated active receipts and complete archived history. These mocked state-composition survivors provide no equivalent replacement, rendered, native, network or fresh execution proof. Audit2694 source-only review: Remove14 authored/14 expanded cases in the renderer completion wrapper family, including the complete bell/query-reply/stale-input factory, without replacement. Retain29 authored/34 expanded cases with unchanged callback bodies. Three removals are the existing pending2203 overlap and must be adopted/count-reconciled once; eleven are fresh removals. No current-source runtime or gate execution is supplied by this packet; dated evidence retains its original source scope and does not validate the reduced factory bytes. No equivalent replacement, physical provider, mixed-version, mobile, rendered UI, cross-platform, soak or measured-performance result is claimed. The existing command and testFiles selector retain tests/pty-connection-completion-and-notification.test.ts; no wrapper-specific assertionRef is removed. Historical selector results do not validate its changed reachable factories. Historical prior account (preserved verbatim): Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2003: Delete the complete pure orphan-topology suite and its file membership; preserve the other selectors from its combined command after archiving the original command string. Lost alarms are synthetic current-layout preservation, one-anchor grafting and ambiguous-anchor appending examples. Do not transfer their ownership/topology scope to sibling suites. Preserve all5 independent historical receipts exactly. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1983: Delete the mocked agent-session suite and its prospective selector and aliases. Retire all3 whole dated changed-selector receipts, preserving their original raw objects in historical gaps without transferring counts or durations. Preserve5 unrelated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial agent-operation service suite retains only concurrent retry joining with changed-fingerprint conflict. Retire its complete three-title assertion object: old-owner legacy fallback before side effects, nested SSH Pi transcript refusal and completed/ambiguous physical-commit replay fences are no longer backed. Other probe/launch option/ledger/failure/remote-inventory examples disappear as detailed below. No actual provider spawn, live SSH or physical commit proof is retained by this source. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1911: The complete provider PTY-inspection mock suite is removed: missing-provider rejection, stale-PTY renderer unverifiable mapping, preserved supplied renderer failures, and supplied transport-loss mapping alarms are intentionally lost. No actual terminal teardown, daemon error or remote transport was exercised. Only the deleted explicit source tokens, testFile and whole assertionRef are removed. Meaningful remaining source selectors/assertions and unaffected dated receipts retain their original scope. No equivalent replacement, fresh reduced-gate, native/platform/provider, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Race independent clients and repeated operation IDs, then assert one physical spawn and one canonical PTY/surface; inject exit-before-reply, provider disconnect, conflicting claim scope, old daemon/relay capabilities, reused handles, stale incarnations, owner mismatch, and topology revision conflict; assert safe adoption or explicit failure without a second spawn or wrong-process attachment. Run fresh/resume with activate true/false against an isolated headed desktop host and a separate paired client, then against isolated headless serve: assert host presentation stays background, only the requesting viewer focuses the exact leaf, inactive calls preserve client/DOM focus, a same-version publication replay cannot lose focus intent, and sibling-first split publication cannot consume exact-leaf intent. Restore legacy split panes and groups beside a newer host-owned tab, preserving exact predecessor/new/successor order, output, input, resize, titles, tab/leaf identity, active group, and multi-client convergence. For completion, drive a known running agent through outer transport loss, authoritative provider rejection, reconnect, explicit stop, real exit status, and successful hook completion; assert unavailable evidence never dispatches completion and two fresh authoritative idle samples are required after the gap. After exact exit, assert terminal and tab listings omit the surface, a stale publication cannot restore it, restart cannot resurrect it, exact tokened fixture PIDs are dead, and unrelated tabs/processes survive until scoped cleanup. Settings-host12 TEST policy additionally retires tests/e2e/remote-terminal-tab-retirement.unit.test.ts: loses permanent host exit retirement in simultaneous viewers and stale snapshot/replay resurrection protection. The callback composed runtime publication and synthetic viewer reducers with exact flush/publication work counts. No replacement or equivalent coverage is claimed; prior receipts remain historical and apply only to their original selectors.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Shared agent/chat layout cleanup retires the remaining mocked agent-session operation-ledger registration: concurrent-retry joining, changed-fingerprint conflicts and exact createTerminal call count. Its active command token and test-file entry are removed. Prior evidence remains historical; no equivalent replacement or fresh gate coverage is claimed. Prior account: Audit5922 intentionally retires Gemini interrupt versus Codex navigation classification and command-finished cleanup arbitration under supplied status/transport; the retained completion wrapper loses exactly two finite arbitration cases while its other registration factories remain. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. The Codex restart suite and exact command/testFiles/assertionRef are removed; its mock account-change/remote-pane restart alarms are intentionally lost. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3368 retires the whole host-session-launch unit source, including host-authority/create/ensure/legacy/Kimi/refusal/draft/options/prompt/cancel/kill/shared-disconnect and passive-sleep output callback alarms, without equivalent replacement. Its unit command token and test-file entry retire. Five unrelated macOS receipts remain verbatim and keep only their original scope; no fresh changed-selector/runtime/provider/process/UI/mobile/mixed-version/cross-platform evidence is claimed. Audit3359 retires the whole create-handoff suite. Supplied disposition, late completion, close-callback and metadata-bookkeeping alarms are intentionally lost without equivalent replacement; the compound unit selector and test-file entry narrow accordingly. Five unrelated macOS receipts retain their original scope. No fresh runtime, process-deduplication, physical provider/network, historical-import, mobile, mixed-version or cross-platform validation is claimed. Audit 3301 removes the caller-chat-target precedence over host selection example from web-session-tabs-sync-focus-intent.test.ts. The snapshot-before-RPC replay and split-sibling-first exact-leaf focus cases remain unchanged and match the existing assertion reference. Preserve current selectors, assertion references, unrelated active receipts and complete archived history. These mocked state-composition survivors provide no equivalent replacement, rendered, native, network or fresh execution proof. Audit2694 source-only review: Remove14 authored/14 expanded cases in the renderer completion wrapper family, including the complete bell/query-reply/stale-input factory, without replacement. Retain29 authored/34 expanded cases with unchanged callback bodies. Three removals are the existing pending2203 overlap and must be adopted/count-reconciled once; eleven are fresh removals. No current-source runtime or gate execution is supplied by this packet; dated evidence retains its original source scope and does not validate the reduced factory bytes. No equivalent replacement, physical provider, mixed-version, mobile, rendered UI, cross-platform, soak or measured-performance result is claimed. The existing command and testFiles selector retain tests/pty-connection-completion-and-notification.test.ts; no wrapper-specific assertionRef is removed. Historical selector results do not validate its changed reachable factories. Historical prior account (preserved verbatim): Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2003: Delete the complete pure orphan-topology suite and its file membership; preserve the other selectors from its combined command after archiving the original command string. Lost alarms are synthetic current-layout preservation, one-anchor grafting and ambiguous-anchor appending examples. Do not transfer their ownership/topology scope to sibling suites. Preserve all5 independent historical receipts exactly. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1983: Delete the mocked agent-session suite and its prospective selector and aliases. Retire all3 whole dated changed-selector receipts, preserving their original raw objects in historical gaps without transferring counts or durations. Preserve5 unrelated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial agent-operation service suite retains only concurrent retry joining with changed-fingerprint conflict. Retire its complete three-title assertion object: old-owner legacy fallback before side effects, nested SSH Pi transcript refusal and completed/ambiguous physical-commit replay fences are no longer backed. Other probe/launch option/ledger/failure/remote-inventory examples disappear as detailed below. No actual provider spawn, live SSH or physical commit proof is retained by this source. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1911: The complete provider PTY-inspection mock suite is removed: missing-provider rejection, stale-PTY renderer unverifiable mapping, preserved supplied renderer failures, and supplied transport-loss mapping alarms are intentionally lost. No actual terminal teardown, daemon error or remote transport was exercised. Only the deleted explicit source tokens, testFile and whole assertionRef are removed. Meaningful remaining source selectors/assertions and unaffected dated receipts retain their original scope. No equivalent replacement, fresh reduced-gate, native/platform/provider, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Race independent clients and repeated operation IDs, then assert one physical spawn and one canonical PTY/surface; inject exit-before-reply, provider disconnect, conflicting claim scope, old daemon/relay capabilities, reused handles, stale incarnations, owner mismatch, and topology revision conflict; assert safe adoption or explicit failure without a second spawn or wrong-process attachment. Run fresh/resume with activate true/false against an isolated headed desktop host and a separate paired client, then against isolated headless serve: assert host presentation stays background, only the requesting viewer focuses the exact leaf, inactive calls preserve client/DOM focus, a same-version publication replay cannot lose focus intent, and sibling-first split publication cannot consume exact-leaf intent. Restore legacy split panes and groups beside a newer host-owned tab, preserving exact predecessor/new/successor order, output, input, resize, titles, tab/leaf identity, active group, and multi-client convergence. For completion, drive a known running agent through outer transport loss, authoritative provider rejection, reconnect, explicit stop, real exit status, and successful hook completion; assert unavailable evidence never dispatches completion and two fresh authoritative idle samples are required after the gap. After exact exit, assert terminal and tab listings omit the surface, a stale publication cannot restore it, restart cannot resurrect it, exact tokened fixture PIDs are dead, and unrelated tabs/processes survive until scoped cleanup. Settings-host12 TEST policy additionally retires tests/e2e/remote-terminal-tab-retirement.unit.test.ts: loses permanent host exit retirement in simultaneous viewers and stale snapshot/replay resurrection protection. The callback composed runtime publication and synthetic viewer reducers with exact flush/publication work counts. No replacement or equivalent coverage is claimed; prior receipts remain historical and apply only to their original selectors.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/shared/agent-session/lifecycle/leases/claimed-agent-pty-owner.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/runtime/terminal/surface/orca-runtime-terminal-retirement.test.ts", @@ -7776,7 +7725,7 @@ "https://github.com/stablyai/orca/pull/10625" ], "invariant": "A host advertising terminal.paired-parking.v1 keeps the PTY and bounded authoritative history alive while an ordinary hidden-view park destroys the client xterm and releases its raw per-PTY stream. Reveal must restore up to the requested 5,000 rows, parked-time side effects/output, the same PTY identity, and continued input/output. Parked watcher synchronization compares parking semantics rather than fresh object identity, owns setup and cleanup across StrictMode replay, reconciles real PTY/layout changes, and performs no terminal-state scan when nothing is parked. After a host main-process relaunch, unknown local delivery-sync state must not be treated as proof that a surviving daemon PTY is already foregrounded. An empty headed session-tab inventory is authoritative only after the current renderer graph generation publishes a complete inventory and every execution host answers the PTY census; unpublished, resync-pending, transport-failed, and partially scoped inventories remain unverifiable, while genuinely authoritative empty and non-empty inventories settle and a scope-less legacy empty keeps its pre-authority best-effort settle so outdated hosts retain agent auto-resume. The unpublished-empty regression must keep the resume dispatch parked with exactly one daemon process/writer; restoring unconditional empty hydration must release one dispatch and create two live writers. If subscription precedes provider readiness, authoritative inventory must reconsider that existing subscriber without spawning, resizing, or changing reconnect state. A snapshot without an output high-water must keep it unknown rather than borrowing a layout version that can suppress newer live output. Hosts without the capability must gate hidden raw output before xterm scheduling and repaint from the authoritative snapshot on reveal while retaining the existing limit/TTL force-parking fallback. After the first semantic title state, decorative spinner frequency must add zero paired client-event frames and zero full session-tabs work between status-freshness leases regardless of hidden worktree count. Continuous working or permission evidence may refresh each affected worktree once per 15 minutes through one globally spaced FIFO so current and legacy viewers do not decay before 30 minutes; sibling PTYs share that worktree refresh, while local title animation, raw output, and semantic title, status, bell, completion, and query facts remain intact. A paired terminal stream whose delivery credits stop progressing must replace only that stream; command silence first probes authoritative state and replaces the stream if the probe times out or proves the PTY advanced beyond the client's delivered output sequence. When no comparable delivery high-water exists, the first sequenced probe establishes a baseline and only later advancement proves staleness. A same-sequence snapshot remains valid proof of a responsive silent command. A successful status probe may replace a pre-ready shared-control socket without rejecting or duplicating calls already waiting for that transport. Manual disconnect must retain pairing while preventing queued or passive calls and subscriptions from recreating transport until explicit Connect. A paired pane reconnecting to a relaunched host that has not yet published its window graph (an unpublished frame, bare or client-projected) must stay in recovery rather than retire, and the host's first published snapshot carrying the surface must reattach it; a published frame lacking the surface still retires it. The placeholder is only ever sent before the host's graph first publishes; afterwards a worktree with no tabs gets a real empty answer, pushed once to any client that asked during startup, so a paired client opening a never-opened host worktree still gets its first terminal.", - "oracle": "Audit5922 intentionally retires mixed split/agent parking eligibility classification; incorrect eligibility can unmount a still-needed terminal or hide resume, though the retired predicate suite never mounts or resumes the actual view. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5879 retires the entire cold-parking hook suite and its stale exemption/park-set and unnecessary recomputation alarms. Remaining selectors are not equivalent replacement coverage; unchanged independent dated receipts retain their original scope and do not validate reduced commands. Historical prior account preserved verbatim: Audit5772 companion to audit5768: Retire the whole hidden-view parking policy suite. Direct oldest/cap/TTL/last-active worktree ranking and equal-hidden-time tab activation-order alarms are intentionally lost without equivalent replacement. Narrow one compound unit command and remove the parking testFiles entry. Physical parking/restoration/stream-budget selectors and assertions remain unchanged at their own exact scope; they are not certified as replacements. Complete dated evidenceRuns and unrelated selectors/assertions are unchanged; none selects these retired suites and none validates the narrowed command. No fresh execution, current import reachability, replacement coverage or native/platform/remote result is claimed. Complete prior account preserved verbatim below as historical, including any older then-retained coverage claim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. The decorative fanout suite retains only real OSC9999 ingestion through runtime/title heartbeat/viewer past the stale boundary, preserving stateStartedAt and clearing expired prompt metadata. Spinner volume/zero-work inventories, Pi/Grok frame tables, rich-status and foreground-reset examples are retired. Existing receipts for separate paired-terminal sources retain their original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3342 removes three supplied activation/inventory fallback and same-handle retry examples; their fallback/retry alarms are intentionally lost without equivalent replacement. The exact mounted-HUB pending old-stream-end versus replacement-snapshot registration and its assertion remain. Unrelated dated macOS receipts retain only their original scope; no fresh runtime, provider, performance, mobile, mixed-version or cross-platform validation is claimed. Audit3326 adopts reconciled source audit3324 and intentionally retires these low-value examples and their regression alarms: restarts only the stream whose renderer delivery credit never settles — An unreturned renderer delivery credit stalls only its stream, leaving healthy sibling/shared transport alive. Fake-clock deadline plus real multiplexer unsubscribe isolates recovery ownership.; probes then restarts a stream when an entered command receives no frames — Entered command produces no output; actual multiplexer must probe then close only its stalled stream after probe timeout. Distinct response liveness from parser credit.; establishes a probe baseline before recovering an unsequenced stream — 142-line manual five-probe baseline/regression sequence derives request IDs from encoded mock traffic and checks repeated no-close/close choreography. Oversized algorithm/state-machine example; no actual renderer/host command or recovery delivery. Retires unsequenced/unchanged/regressed baseline classification alarms.. Retained tests do not replace these alarms. Dated unrelated evidence remains scoped to its original execution; no historical source/import-closure equivalence, fresh execution, real network/provider/SSH, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Audit 3318 reduces remote-runtime-pty-transport-unpublished-host-graph.test.ts, retiring its direct published-empty-graph omission-to-pane-exit alarm. The unchanged bounded unpublished-frame/pushed-recovery and stale-handle park/manual-retry cases are narrower, not equivalent replacements. Both complete three-case Linux receipts dated 2026-11-04 are archived as historical, including source heads; they do not validate this reduced selector. Remaining fourteen active receipts are macOS only. No fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. The direct side-effect-facts selector retains six cases: replay exclusion, live sequence handling, stale disposer ownership, one handoff drain, drain-before-snapshot, and stale replacement-snapshot refusal. Successful current-entry snapshot application is not witnessed by the retained snapshot case. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2003: Remove SSH/absent-inventory attach refusal, later-subscriber retry, no-view adoption/takeback, provider-tail/unknown-read projections, failed-keystroke retry and simpler loss reattach examples. Keep the existing-subscriber inventory-ready retry alias only at its retained callback, plus retained held-input cancellation/replacement and overlapping attach/loss fences. The inventory driver also loses the whole empty-worktree-publication registration and folder-host/unverifiable scalar examples. Retire the entire dated10-case attach receipt; retain16 independent receipts only in their original scopes. No retained-memory or real-daemon measurement follows from supplied provider inventories. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove initial-snapshot sequence-domain, limited-tail/truncation and unknown-output-sequence aliases whose callbacks are removed. The source retains partial-chunk replay and requested-snapshot retry/admission at supplied snapshot/data seams, not equivalent replacement or measured retained-memory proof. Preserve the existing stream/pending-wait capacity aliases only to their retained owning multiplex callbacks with supplied PTY resolutions. Removing the sibling-PTY heartbeat dedup work-count sample does not establish a new decorative fanout budget; the unrelated-PTY cancellation fence survives. Preserve17 unrelated dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1983: Remove the reasonless-close selector and narrow census aliases to actual retained runtime and injected-inventory callbacks. The removed synthetic census-dedup and isolated pre-boundary timing cases receive no replacement credit; preserve17 unrelated dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1939 (sources1934/1935): Delete the synthetic watcher-synchronization and partial-reconciliation suites. Retire all affected host-fact, capability-owner, activation-residue and retention-cap aliases because the remaining callbacks do not establish those full claims. Keep exact local hook/timer, byte-stream side effects, exit/disposal, scroll-intent cleanup and deterministic local rank/TTL progression callbacks within their mocked-host scope. No physical paired-host retention, resource budget or equivalent replacement evidence is assigned. The generic broad test command remains a runnable discovery command, never a dated execution receipt. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Delete the complete hook-agent-status projection suite and its two behavioral assertion aliases. Supplied stored hook/title/resume/staleness/rename/question/generation/PTY-retirement/snapshot-version projections are intentionally lost. The separate osc-status-scan gate mentions this source only in existing historical notes and receives no mutation. No measured hidden-output retention, CPU/RSS or resource budget result is claimed by the deleted source or this audit. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Run one byte-identical six-terminal oracle against an isolated headed desktop host and an isolated headless `orca serve` host. Stage at least 1,000,000 xterm cells, hide all six warm managers, emit an initial working title followed by 30 timed real-PTY spinner frames and a final idle title per worktree, and observe a second real session-tabs subscription plus the production renderer store. Require exactly two transport envelopes and two title mutations per worktree, no decorative title crossing either boundary, and positive decoded-envelope bytes. Enable ordinary parking with the lossy retention budget disabled, require exactly one mounted manager and five parked tabs, at most 45% retained cells, no more than 16 MiB heap growth, and under 500 ms timer drift. In headed mode, require the host renderer to remain on its original workspace with zero target terminal managers mounted throughout client park, reveal, and live I/O. While a tab is parked, require authoritative terminal.read to observe new PTY output; reveal it and require the original PTY, a marker within the requested 5,000-row history, the parked marker, and post-reveal input/output. Drive 24 real PTY title trackers in distinct worktrees through 40 decorative spinner frames each, then 40 spinner frames alternating with Cursor's bare native identity redraw, using fake clocks. Require all 2,880 raw chunks exactly and zero host session-tabs publications, serialized bytes, renderer apply calls, and renderer store mutations. Continue decorative evidence beyond 30 minutes, require exactly one refresh per worktree per 15-minute lease through a FIFO spaced by at least 50 ms, and require all 24 viewer statuses to remain working and fresh; then require one exact semantic idle transition and one visible-output chunk per PTY. Require ordinary and interior-Braille title changes to publish. Drive 64 host PTYs through ten 80 ms synthetic title frames, require zero paired client events after the first frame per PTY while all 640 local frames remain observable, attach a late client and require one current frame per PTY, then require semantic bell and idle transitions on both clients. Reconstruct a legacy subscribed stream with no outputPause capability, hide a chatty pane, require no hidden xterm writes, reveal it, and require one authoritative snapshot plus continued live output. Drop and acknowledge output only for one original paired-client stream, prove the fixture process consumed input while the host model advanced and the client stayed stale, then require the command snapshot probe to replace that stream, repaint exact fixture output, preserve authoritative PTY identity and target-tab cardinality, and resume live I/O. For a client without a delivered sequence, require the first numeric probe to establish a baseline without replacement, a same-sequence probe to remain attached, and a later advanced probe to replace only that stream. Withhold the first encrypted shared-control ready frame, start one RPC, trigger a status-probe refresh, and require two connections, one host delivery, successful response, and zero retained request bytes. Admit 128 active streams, reject the 129th as retryable, release one stream, then require the retry to attach and publish a snapshot without multiplying retained subscribers. Disable terminal.paired-parking.v1 and require the same oracle to fail before parking, while the legacy limit-one fallback separately passes. Also preserve truncated first paint, ACK-starved same-PTY recovery, responsive silent-command snapshot probes, dead-stream probe timeout recovery, and queued manual-disconnect fencing.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5922 intentionally retires mixed split/agent parking eligibility classification; incorrect eligibility can unmount a still-needed terminal or hide resume, though the retired predicate suite never mounts or resumes the actual view. These narrow alarms are lost without equivalent replacement. Remaining selectors/assertions and dated evidenceRuns retain their original scope; no fresh validation or whole-gate replacement claim. Preserve complete historical narratives and earlier knownGaps verbatim. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5879 retires the entire cold-parking hook suite and its stale exemption/park-set and unnecessary recomputation alarms. Remaining selectors are not equivalent replacement coverage; unchanged independent dated receipts retain their original scope and do not validate reduced commands. Historical prior account preserved verbatim: Audit5772 companion to audit5768: Retire the whole hidden-view parking policy suite. Direct oldest/cap/TTL/last-active worktree ranking and equal-hidden-time tab activation-order alarms are intentionally lost without equivalent replacement. Narrow one compound unit command and remove the parking testFiles entry. Physical parking/restoration/stream-budget selectors and assertions remain unchanged at their own exact scope; they are not certified as replacements. Complete dated evidenceRuns and unrelated selectors/assertions are unchanged; none selects these retired suites and none validates the narrowed command. No fresh execution, current import reachability, replacement coverage or native/platform/remote result is claimed. Complete prior account preserved verbatim below as historical, including any older then-retained coverage claim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. The decorative fanout suite retains only real OSC9999 ingestion through runtime/title heartbeat/viewer past the stale boundary, preserving stateStartedAt and clearing expired prompt metadata. Spinner volume/zero-work inventories, Pi/Grok frame tables, rich-status and foreground-reset examples are retired. Existing receipts for separate paired-terminal sources retain their original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3342 removes three supplied activation/inventory fallback and same-handle retry examples; their fallback/retry alarms are intentionally lost without equivalent replacement. The exact mounted-HUB pending old-stream-end versus replacement-snapshot registration and its assertion remain. Unrelated dated macOS receipts retain only their original scope; no fresh runtime, provider, performance, mobile, mixed-version or cross-platform validation is claimed. Audit3326 adopts reconciled source audit3324 and intentionally retires these low-value examples and their regression alarms: restarts only the stream whose renderer delivery credit never settles — An unreturned renderer delivery credit stalls only its stream, leaving healthy sibling/shared transport alive. Fake-clock deadline plus real multiplexer unsubscribe isolates recovery ownership.; probes then restarts a stream when an entered command receives no frames — Entered command produces no output; actual multiplexer must probe then close only its stalled stream after probe timeout. Distinct response liveness from parser credit.; establishes a probe baseline before recovering an unsequenced stream — 142-line manual five-probe baseline/regression sequence derives request IDs from encoded mock traffic and checks repeated no-close/close choreography. Oversized algorithm/state-machine example; no actual renderer/host command or recovery delivery. Retires unsequenced/unchanged/regressed baseline classification alarms.. Retained tests do not replace these alarms. Dated unrelated evidence remains scoped to its original execution; no historical source/import-closure equivalence, fresh execution, real network/provider/SSH, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Audit 3318 reduces remote-runtime-pty-transport-unpublished-host-graph.test.ts, retiring its direct published-empty-graph omission-to-pane-exit alarm. The unchanged bounded unpublished-frame/pushed-recovery and stale-handle park/manual-retry cases are narrower, not equivalent replacements. Both complete three-case Linux receipts dated 2026-11-04 are archived as historical, including source heads; they do not validate this reduced selector. Remaining fourteen active receipts are macOS only. No fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. The direct side-effect-facts selector retains six cases: replay exclusion, live sequence handling, stale disposer ownership, one handoff drain, drain-before-snapshot, and stale replacement-snapshot refusal. Successful current-entry snapshot application is not witnessed by the retained snapshot case. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2003: Remove SSH/absent-inventory attach refusal, later-subscriber retry, no-view adoption/takeback, provider-tail/unknown-read projections, failed-keystroke retry and simpler loss reattach examples. Keep the existing-subscriber inventory-ready retry alias only at its retained callback, plus retained held-input cancellation/replacement and overlapping attach/loss fences. The inventory driver also loses the whole empty-worktree-publication registration and folder-host/unverifiable scalar examples. Retire the entire dated10-case attach receipt; retain16 independent receipts only in their original scopes. No retained-memory or real-daemon measurement follows from supplied provider inventories. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1991: Remove initial-snapshot sequence-domain, limited-tail/truncation and unknown-output-sequence aliases whose callbacks are removed. The source retains partial-chunk replay and requested-snapshot retry/admission at supplied snapshot/data seams, not equivalent replacement or measured retained-memory proof. Preserve the existing stream/pending-wait capacity aliases only to their retained owning multiplex callbacks with supplied PTY resolutions. Removing the sibling-PTY heartbeat dedup work-count sample does not establish a new decorative fanout budget; the unrelated-PTY cancellation fence survives. Preserve17 unrelated dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, physical provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1983: Remove the reasonless-close selector and narrow census aliases to actual retained runtime and injected-inventory callbacks. The removed synthetic census-dedup and isolated pre-boundary timing cases receive no replacement credit; preserve17 unrelated dated receipts. Changed-source prior results do not validate reduced-source bytes. No fresh execution, equivalent replacement, red/green, measured budget, soak, provider/PTY, rendered, live remote/mobile or cross-platform result is claimed. Historical prior account (preserved verbatim): Audit1939 (sources1934/1935): Delete the synthetic watcher-synchronization and partial-reconciliation suites. Retire all affected host-fact, capability-owner, activation-residue and retention-cap aliases because the remaining callbacks do not establish those full claims. Keep exact local hook/timer, byte-stream side effects, exit/disposal, scroll-intent cleanup and deterministic local rank/TTL progression callbacks within their mocked-host scope. No physical paired-host retention, resource budget or equivalent replacement evidence is assigned. The generic broad test command remains a runnable discovery command, never a dated execution receipt. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Delete the complete hook-agent-status projection suite and its two behavioral assertion aliases. Supplied stored hook/title/resume/staleness/rename/question/generation/PTY-retirement/snapshot-version projections are intentionally lost. The separate osc-status-scan gate mentions this source only in existing historical notes and receives no mutation. No measured hidden-output retention, CPU/RSS or resource budget result is claimed by the deleted source or this audit. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Retained exact unchanged-source receipts remain the only current execution evidence. Reduced selectors have no fresh execution result. Historical pre-audit oracle account for changed sources: The retained unchanged-source receipts are the only current execution evidence; reduced-source assertions await validation. Historical oracle account (not a current claim for changed sources): Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Run one byte-identical six-terminal oracle against an isolated headed desktop host and an isolated headless `orca serve` host. Stage at least 1,000,000 xterm cells, hide all six warm managers, emit an initial working title followed by 30 timed real-PTY spinner frames and a final idle title per worktree, and observe a second real session-tabs subscription plus the production renderer store. Require exactly two transport envelopes and two title mutations per worktree, no decorative title crossing either boundary, and positive decoded-envelope bytes. Enable ordinary parking with the lossy retention budget disabled, require exactly one mounted manager and five parked tabs, at most 45% retained cells, no more than 16 MiB heap growth, and under 500 ms timer drift. In headed mode, require the host renderer to remain on its original workspace with zero target terminal managers mounted throughout client park, reveal, and live I/O. While a tab is parked, require authoritative terminal.read to observe new PTY output; reveal it and require the original PTY, a marker within the requested 5,000-row history, the parked marker, and post-reveal input/output. Drive 24 real PTY title trackers in distinct worktrees through 40 decorative spinner frames each, then 40 spinner frames alternating with Cursor's bare native identity redraw, using fake clocks. Require all 2,880 raw chunks exactly and zero host session-tabs publications, serialized bytes, renderer apply calls, and renderer store mutations. Continue decorative evidence beyond 30 minutes, require exactly one refresh per worktree per 15-minute lease through a FIFO spaced by at least 50 ms, and require all 24 viewer statuses to remain working and fresh; then require one exact semantic idle transition and one visible-output chunk per PTY. Require ordinary and interior-Braille title changes to publish. Drive 64 host PTYs through ten 80 ms synthetic title frames, require zero paired client events after the first frame per PTY while all 640 local frames remain observable, attach a late client and require one current frame per PTY, then require semantic bell and idle transitions on both clients. Reconstruct a legacy subscribed stream with no outputPause capability, hide a chatty pane, require no hidden xterm writes, reveal it, and require one authoritative snapshot plus continued live output. Drop and acknowledge output only for one original paired-client stream, prove the fixture process consumed input while the host model advanced and the client stayed stale, then require the command snapshot probe to replace that stream, repaint exact fixture output, preserve authoritative PTY identity and target-tab cardinality, and resume live I/O. For a client without a delivered sequence, require the first numeric probe to establish a baseline without replacement, a same-sequence probe to remain attached, and a later advanced probe to replace only that stream. Withhold the first encrypted shared-control ready frame, start one RPC, trigger a status-probe refresh, and require two connections, one host delivery, successful response, and zero retained request bytes. Admit 128 active streams, reject the 129th as retryable, release one stream, then require the retry to attach and publish a snapshot without multiplying retained subscribers. Disable terminal.paired-parking.v1 and require the same oracle to fail before parking, while the legacy limit-one fallback separately passes. Also preserve truncated first paint, ACK-starved same-PTY recovery, responsive silent-command snapshot probes, dead-stream probe timeout recovery, and queued manual-disconnect fencing.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/terminal-pane/pty-transport/remote-runtime/remote-runtime-pty-transport-unpublished-host-graph.test.ts", "ORCA_BACKGROUND_LAUNCH=1 pnpm exec playwright test tests/e2e/paired-remote-terminal-host-quit-reconnect-input.spec.ts --config tests/playwright.config.ts --project electron-headless --workers=1", @@ -8389,7 +8338,7 @@ "https://github.com/stablyai/orca/pull/7054" ], "invariant": "High-volume terminal output must stay bounded across daemon socket writes, SSH relay writer/decoder/source retention/reconnect, main model and projection admission, runtime metadata, detectors, and tail checks, main-to-renderer in-flight bytes, renderer scheduler queues, and hidden-output restore without starving focused input. Every new SSH session offers V1 and every same-build relay supports it; legacy delivery is reachable only when capability negotiation proves the peer cannot use V1. Negotiated SSH spans remain exact and contiguous through activation, exit, cancellation, recovery, desktop projection, and required remote replacement; provisional activation data cannot project, reconnect may release it only into the exact attempt's private recovery quarantine after contract validation, and exit seals that quarantine against later same-token frames until ordered admission or exact cancellation proof. Reconnect checkpoint capture freezes exact provider-generation/PTy admission, cancels queued old work, and waits for the running raw completion before exposing its accepted checkpoint; timeout or failure detaches only that PTy's old model, makes the checkpoint unavailable, and releases the bounded fence without closing the shared provider, while the same failure outside an active exact migration remains generation-fatal and overlapping reconnects preserve any earlier outstanding fence. Pending renderer projection IDs are capped and compacted across split remainders, exit preparation owns its renderer fence through finalization, exit-time cancellation transfers published projections before proof commit, generation close fences late proof while draining exact projection waiters, closed-generation identity compacts without weakening stale rejection, canceled source-delivery retirement retains at most one ordered token per PTY, and pause/resume targets only the exact provider generation. Additional subscribers cannot stall the owner, while the required legacy primary retains backpressure.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Previous oracle (preserved verbatim): Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous oracle (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous oracle (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous oracle (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous oracle (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous oracle (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous oracle (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous oracle (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous oracle (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous oracle (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous oracle (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous oracle (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous oracle (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous oracle (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous oracle (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Previous oracle (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Module layout SSH policy: Retire the multiplexer private-clock saturation registration, the writer saturation transition-count registration and the changed-source dated writer/backpressure receipt. Retained byte delivery, lane order, fairness, settlement and cancellation cases are unvalidated by that historical receipt. No equivalent replacement, new execution, measured performance, live SSH/WSL or cross-platform proof is claimed. The unchanged WSL protocol receipt retains only its original command scope. Historical prior account (preserved verbatim): Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2070 (sources2068/2069): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/hooks-and-hosted-review.spec'). src/main/ssh/ssh-multiplexer-transport-writer.test.ts: reports saturated epochs and their drain boundary exactly once. src/main/runtime/orca-runtime-tests/worktree-removal-archive-hook-gate.spec.ts: removes and records the waiver when the failure is explicitly overridden; removes without an override record when the hook succeeds; removes when the hook is configured but not requested; removes when no archive hook is configured; holds a desktop removal in the same repo until this one is accepted; joins a desktop removal of the same worktree accepted while this one waited. src/main/runtime/orca-runtime-tests/worktree-ps-agent-row-dismissal.spec.ts: drops the row as soon as the user dismisses it, without waiting for the PTY to exit; tells paired clients to republish on the transition and on the dismissal; rejoins a row through its %s handle after pane ownership clears. src/main/runtime/orca-runtime-tests/hooks-and-hosted-review.spec.ts: reports an error when the SSH filesystem provider is unavailable; reports an SSH orca.yaml as an error without reading any filesystem; reports ok for a local repo hook check; reads SSH issue commands as absent and drops writes without touching any filesystem; allows host integration slug helpers for SSH repos through provider-aware GitHub clients; routes runtime GitHub repo identity helpers through the selected WSL project runtime; routes runtime GitHub issue and work-item actions through the selected WSL project runtime; pins explicit origin preference on runtime open-by-number work item lookups; forwards check-details cancellation without local Git overrides. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. The historical receipt/currentCommand selecting src/main/ssh/ssh-multiplexer-transport-writer.test.ts remains historical and is not a passing result for the reduced current command. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Delete the complete tail-wait memo suite: its sole current authored callback checks supplied fromTail/blocked field values. Retire all three broader memoization/equivalence/eviction assertion aliases; they are not backed by retained source callbacks. No scan-work budget, sustained output, physical terminal or resource measurement is assigned to this removed test. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1674 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The current executable slice injects main-process renderer backlog pressure, then asserts ordinary terminal-wait detection without a joined-tail allocation and with full prompt-family continuity, per-PTY and total pending-output caps, a 1,024-ID projection cap with split-remainder compaction, preserved sequenced-tail metadata, active-pending protection ahead of background trimming, exact provider-generation pause ownership, renderer exit/data ordering, and ACK-gated in-flight bounds. The negotiation seam proves every initial connection and reconnect offers V1, the same-build relay advertises V1 without launch flags, old clients remain token-free, and method-not-found peers fall back without installing source ACK publication. The joined source-intake/multiplex oracle blocks renderer or headless serialization, admits one snapshot-covered span and one trailing span, requires replacement reservation only after the authoritative sequence is known, advances upstream ACK eligibility exactly to the covered boundary after SnapshotEnd, and delivers then ACKs the trailing span through the ordinary live path without cancellation. Source-range ledger and multiplex seams additionally require cumulative byte ACK 40 then 100 for one 100-byte frame to release exact byte credit without early source settlement, admit a contiguous higher-generation recovered token while the prior token remains unsettled, and reject stale stream or source generations without releasing in-flight byte credit. Replacement reservation rolls back every earlier span on a later failure, commit requires the exact frozen transfer states, and an authoritatively reclaimed covered span rejects commit without local trim authority while rollback removes the reservation idempotently. The exit-deadline oracle publishes a source-backed desktop projection, advances a fake clock to cancellation, and requires one projection transfer, proof commit, preparation, and final exit with no provider close, retained obligation, duplicate finalization, or process-lifetime cancellation tombstone; a second controlled proof remains pending across generation close and must never publish final exit, while both paths release the renderer preparation lease exactly once. The model-migration oracle accepts span A, blocks span B's raw emulator completion, begins disconnect migration, and proves no checkpoint or reconnect attach can remain at A; releasing B advances the exact checkpoint to B and projects B once. Its fake-clock arm reaches the 10-second deadline, requires checkpoint-unavailable, one exact model reset, zero retained admission charge and timers, and no effect from late raw settlement. Its two-PTY failure arm rejects one running raw callback under an active exact migration and requires one checkpoint-unavailable result, one model reset, zero provider closes, retained sibling checkpoint and transport liveness, zero charges and timers, and an unaffected other generation; a non-migrating sibling oracle still requires generation close. The intake additionally closes 2,048 sequential provider generations into one exact range, rejects stale events across that range, and preserves an out-of-order live gap until its own close. Direct-SSH contracts additionally prove activation-response settlement before the first source frame, claim-gated projection under same-decoder-turn response/data delivery, exact early-ACK reservation through send settlement or same-token retry, recovery completion visible before lease-held frames transfers those frames only into the private quarantine and admits no output until exact checkpoint-to-recoveryEnd coverage, invalid-checkpoint restore retention through response settlement followed by fresh-token retry and one live source frame, isolated saturated-subscriber eviction with healthy owner liveness, preserved legacy-primary backpressure, one-write ownership across write(false)/drain, control selection ahead of queued ordinary PTY input with FIFO lanes and bounded fairness, liveness rebasing, failed-exit retention through late ACK or exact recovery, response-settlement cancellation authority, token-scoped exit cancellation, exact checkpoint-to-recoveryEnd continuity, stale-owner one-shot retry, no physical PTY teardown on recovery failure, exact provider-generation closure and once-only cleanup when recovery cancellation publication or proof rejects, 16 MiB-plus-1 MiB decoder caps, charged per-PTY/session retention budgets, and eight-wide isolated reattach. The live Electron perf oracle adds hidden-output floods, renderer scheduler queue depth, dropped-output-zero normal scenarios, and active key latency budgets before promotion.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Previous oracle (preserved verbatim): Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous oracle (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous oracle (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous oracle (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous oracle (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous oracle (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous oracle (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous oracle (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous oracle (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous oracle (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous oracle (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous oracle (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous oracle (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous oracle (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous oracle (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Previous oracle (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Module layout SSH policy: Retire the multiplexer private-clock saturation registration, the writer saturation transition-count registration and the changed-source dated writer/backpressure receipt. Retained byte delivery, lane order, fairness, settlement and cancellation cases are unvalidated by that historical receipt. No equivalent replacement, new execution, measured performance, live SSH/WSL or cross-platform proof is claimed. The unchanged WSL protocol receipt retains only its original command scope. Historical prior account (preserved verbatim): Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2070 (sources2068/2069): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/hooks-and-hosted-review.spec'). src/main/ssh/ssh-multiplexer-transport-writer.test.ts: reports saturated epochs and their drain boundary exactly once. src/main/runtime/orca-runtime-tests/worktree-removal-archive-hook-gate.spec.ts: removes and records the waiver when the failure is explicitly overridden; removes without an override record when the hook succeeds; removes when the hook is configured but not requested; removes when no archive hook is configured; holds a desktop removal in the same repo until this one is accepted; joins a desktop removal of the same worktree accepted while this one waited. src/main/runtime/orca-runtime-tests/worktree-ps-agent-row-dismissal.spec.ts: drops the row as soon as the user dismisses it, without waiting for the PTY to exit; tells paired clients to republish on the transition and on the dismissal; rejoins a row through its %s handle after pane ownership clears. src/main/runtime/orca-runtime-tests/hooks-and-hosted-review.spec.ts: reports an error when the SSH filesystem provider is unavailable; reports an SSH orca.yaml as an error without reading any filesystem; reports ok for a local repo hook check; reads SSH issue commands as absent and drops writes without touching any filesystem; allows host integration slug helpers for SSH repos through provider-aware GitHub clients; routes runtime GitHub repo identity helpers through the selected WSL project runtime; routes runtime GitHub issue and work-item actions through the selected WSL project runtime; pins explicit origin preference on runtime open-by-number work item lookups; forwards check-details cancellation without local Git overrides. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. The historical receipt/currentCommand selecting src/main/ssh/ssh-multiplexer-transport-writer.test.ts remains historical and is not a passing result for the reduced current command. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Delete the complete tail-wait memo suite: its sole current authored callback checks supplied fromTail/blocked field values. Retire all three broader memoization/equivalence/eviction assertion aliases; they are not backed by retained source callbacks. No scan-work budget, sustained output, physical terminal or resource measurement is assigned to this removed test. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1674 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: The current executable slice injects main-process renderer backlog pressure, then asserts ordinary terminal-wait detection without a joined-tail allocation and with full prompt-family continuity, per-PTY and total pending-output caps, a 1,024-ID projection cap with split-remainder compaction, preserved sequenced-tail metadata, active-pending protection ahead of background trimming, exact provider-generation pause ownership, renderer exit/data ordering, and ACK-gated in-flight bounds. The negotiation seam proves every initial connection and reconnect offers V1, the same-build relay advertises V1 without launch flags, old clients remain token-free, and method-not-found peers fall back without installing source ACK publication. The joined source-intake/multiplex oracle blocks renderer or headless serialization, admits one snapshot-covered span and one trailing span, requires replacement reservation only after the authoritative sequence is known, advances upstream ACK eligibility exactly to the covered boundary after SnapshotEnd, and delivers then ACKs the trailing span through the ordinary live path without cancellation. Source-range ledger and multiplex seams additionally require cumulative byte ACK 40 then 100 for one 100-byte frame to release exact byte credit without early source settlement, admit a contiguous higher-generation recovered token while the prior token remains unsettled, and reject stale stream or source generations without releasing in-flight byte credit. Replacement reservation rolls back every earlier span on a later failure, commit requires the exact frozen transfer states, and an authoritatively reclaimed covered span rejects commit without local trim authority while rollback removes the reservation idempotently. The exit-deadline oracle publishes a source-backed desktop projection, advances a fake clock to cancellation, and requires one projection transfer, proof commit, preparation, and final exit with no provider close, retained obligation, duplicate finalization, or process-lifetime cancellation tombstone; a second controlled proof remains pending across generation close and must never publish final exit, while both paths release the renderer preparation lease exactly once. The model-migration oracle accepts span A, blocks span B's raw emulator completion, begins disconnect migration, and proves no checkpoint or reconnect attach can remain at A; releasing B advances the exact checkpoint to B and projects B once. Its fake-clock arm reaches the 10-second deadline, requires checkpoint-unavailable, one exact model reset, zero retained admission charge and timers, and no effect from late raw settlement. Its two-PTY failure arm rejects one running raw callback under an active exact migration and requires one checkpoint-unavailable result, one model reset, zero provider closes, retained sibling checkpoint and transport liveness, zero charges and timers, and an unaffected other generation; a non-migrating sibling oracle still requires generation close. The intake additionally closes 2,048 sequential provider generations into one exact range, rejects stale events across that range, and preserves an out-of-order live gap until its own close. Direct-SSH contracts additionally prove activation-response settlement before the first source frame, claim-gated projection under same-decoder-turn response/data delivery, exact early-ACK reservation through send settlement or same-token retry, recovery completion visible before lease-held frames transfers those frames only into the private quarantine and admits no output until exact checkpoint-to-recoveryEnd coverage, invalid-checkpoint restore retention through response settlement followed by fresh-token retry and one live source frame, isolated saturated-subscriber eviction with healthy owner liveness, preserved legacy-primary backpressure, one-write ownership across write(false)/drain, control selection ahead of queued ordinary PTY input with FIFO lanes and bounded fairness, liveness rebasing, failed-exit retention through late ACK or exact recovery, response-settlement cancellation authority, token-scoped exit cancellation, exact checkpoint-to-recoveryEnd continuity, stale-owner one-shot retry, no physical PTY teardown on recovery failure, exact provider-generation closure and once-only cleanup when recovery cancellation publication or proof rejects, 16 MiB-plus-1 MiB decoder caps, charged per-PTY/session retention budgets, and eight-wide isolated reattach. The live Electron perf oracle adds hidden-output floods, renderer scheduler queue depth, dropped-output-zero normal scenarios, and active key latency budgets before promotion.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts", "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/construction/orca-runtime.test.ts", @@ -9778,7 +9727,7 @@ "https://github.com/stablyai/orca/issues/14347" ], "invariant": "Injected orchestration task prompts for recognized agent CLIs must send the prompt body inside one bracketed-paste frame, sanitize embedded ESC bytes, preserve chunk boundaries without losing the frame, and submit exactly once only after the agent can accept Enter. Local worker-start with supported observation must preserve an unobserved turn as start_unknown without revoking authority, closing questions, or triggering a rescue Enter; a worker report during observation must settle normally. Claude and Codex must emit a post-paste composer marker and then settle, or reach the bounded fallback first; every other agent retains the platform delay.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Retained assertion references and unchanged receipts keep their original scopes; retired callbacks and archived receipts provide no current coverage.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Retained assertion references and unchanged receipts keep their original scopes; retired callbacks and archived receipts provide no current coverage.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/shared/agent-launch/startup/agent-prompt-injection.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/orchestration/coordinator/coordinator.test.ts", "pnpm exec vitest run --config config/vitest.config.ts src/main/runtime/rpc/methods/orchestration/worker/start/readiness/worker-start-prompt-contract.test.ts --reporter=dot", @@ -10014,7 +9963,7 @@ "https://linear.app/stably/issue/STA-4022" ], "invariant": "Starting a worker in the coordinator's current workspace must materialize one inactive terminal tab before worker-start returns, preserve coordinator focus, and remain exactly once after workspace re-entry. After an app update or restart, an exact live legacy worker must fence automatic provider resume, adopt its original PTY into its original background pane, retain readable output, and clear the resume record without spawning, writing, signalling, interrupting, replacing, or focusing the worker. A current-contract worker whose renderer graph identity is temporarily absent must retain its Dispatch capability and settle exactly once from exact hook-attested handle, pane, and process evidence; otherwise only an exact attested coordinator may take over. A worker_done caller may report success only after the owning runtime returns an explicit lifecycle verdict or authoritative reads prove that the exact Task, Dispatch, and worker report receipt settled the expected outcome. Federated terminal settlement must remain replay-eligible until the worker durably acknowledges it, and identical same-outcome retries must converge idempotently. Independently updated clients and worker servers must preserve the negotiated protocol: current peers use Run-home lifecycle settlement, while protocol v1/v2 peers retain their legacy completion path without receiving newer-only fields. A federated worker may accept only the authority defined by its negotiated protocol. An exact existing target workspace must receive a discoverable tab without stealing coordinator focus; if renderer reveal fails, worker-start must expose that the live worker remains background-only. Run and Dispatch checks must resolve through the caller's stable pane identity when a terminal handle is reminted, while a live handle outranks mismatched pane metadata. A nested worker's creator edge requires the current creator pane, process incarnation, and owning Run generation; reminting and rebinding that pane to another Run must remove the stale edge. Explicit legacy terminal inspection remains handle-scoped, and remote or headless worker presentation remains background-only.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5912 deletes the complete federation acknowledgment migration suite. Its invented v26-schema default, migration-start and imported-cursor alarms are intentionally lost. The sole migration command, testFiles and assertionRef are retired. No equivalent replacement or fresh whole-gate pass is claimed. Complete prior oracle retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. The complete federation-lifecycle-settlement suite is removed, losing its fake remote settlement/protocol/acknowledgment examples. Its exact standalone command, testFiles entry and complete assertionRef are retired and prior fields archived. Existing receipts select unrelated migration and compiled CLI journeys and retain original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit2923 accepts loss of the first/replayed attested legacy worker_done CLI acceptance alarms, including exact send parameters, sender pane proof, lifecycle-wait flag and minted mutation identity. The removed fixture supplied settled runtime verdicts; it did not execute settlement authority, durable replay or outage recovery. Reduced selectors have no new execution, fault-control or equivalent replacement credit. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Retained assertion references and unchanged receipts keep their original scopes; retired callbacks and archived receipts provide no current coverage.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5912 deletes the complete federation acknowledgment migration suite. Its invented v26-schema default, migration-start and imported-cursor alarms are intentionally lost. The sole migration command, testFiles and assertionRef are retired. No equivalent replacement or fresh whole-gate pass is claimed. Complete prior oracle retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. The complete federation-lifecycle-settlement suite is removed, losing its fake remote settlement/protocol/acknowledgment examples. Its exact standalone command, testFiles entry and complete assertionRef are retired and prior fields archived. Existing receipts select unrelated migration and compiled CLI journeys and retain original scopes. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit2923 accepts loss of the first/replayed attested legacy worker_done CLI acceptance alarms, including exact send parameters, sender pane proof, lifecycle-wait flag and minted mutation identity. The removed fixture supplied settled runtime verdicts; it did not execute settlement authority, durable replay or outage recovery. Reduced selectors have no new execution, fault-control or equivalent replacement credit. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Retained assertion references and unchanged receipts keep their original scopes; retired callbacks and archived receipts provide no current coverage.", "commands": [ "ORCA_BACKGROUND_LAUNCH=1 npx vitest run --config config/vitest.config.ts src/main/runtime/rpc/methods/orchestration/messaging/check-worker-federated-attachment.test.ts", "pnpm exec vitest run --config config/vitest.config.ts src/cli/orchestration/orchestration.test.ts src/cli/orchestration/messages/orchestration-check-identity.test.ts src/main/runtime/rpc/methods/orchestration/worker/start/worker-start-composition.test.ts src/main/runtime/rpc/methods/orchestration/messaging/check.test.ts src/main/runtime/rpc/methods/orchestration/messaging/send.test.ts", @@ -11821,14 +11770,14 @@ "providers": ["local", "remote-runtime", "ssh"], "coveredPlatforms": ["macos", "linux"], "coveredProviders": ["local", "remote-runtime", "ssh"], - "coverageNotes": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5901 removes only the mobile-creation-and-orchestration-part-03.spec import from the retained runtime driver. The fragment's missing-handle wait abort and waiter retirement on reload-exit alarms are intentionally lost. This is a conservative import-closure notice: named command filters may exclude those cases. Driver selectors remain; unchanged historical receipts retain their original scope and establish no fresh whole-gate pass or equivalent replacement. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5896 retires the whole promise-settlement-waiters suite, intentionally losing its Promise ordering/abandon cleanup alarms. Remaining selectors are not equivalent replacement coverage; unrelated dated receipts retain original scope. No fresh whole-gate validation is claimed. Complete prior account retained verbatim: Shared primitives layout deliberately retires the promise waiter actual-timeout/supplied-result/internal waiter-count/timer-count callback. The already-aborted ownership-abandon callback survives at its moved concurrency test path. No equivalent timeout detachment/timer-cleanup alarm or fresh validation of the reduced/moved source is claimed. All13 dated build/resource/fault-harness receipts remain exact and retain only their original scopes. Previous account (verbatim; historical where it concerns changed source): Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose watcher registry release-before-listen wakeup, one-released-slot reservation ordering, event flush blocked-active/overflow delivery and close-settlement alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit5574 removes the entire physical-exit waiter bookkeeping suite and its active selectors/assertion reference. Timeout/retry, fanout/double-exit and immediate-later-wait alarms are intentionally retired without equivalent replacement or fresh process-exit evidence. Unrelated dated receipts retain their exact original scopes. Historical account follows: Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4358 intentionally removes six whole mocked daemon subprocess suites and two extra pre-listener replay variants (18 authored / 20 finite cases). Lost alarms include cancel-during-cwd-validation, root agent startup refusal, output/exit before ConPTY publication, fresh/delayed/unavailable foreground confirmation, cache/decision separation, detached/no-tty child evidence and synthetic agent authorization. The retained lifecycle case checks data and exit replay after handle creation, not startup-time publication or alternate listener order. The retained native Windows Git Bash workflow and host cold-restore seed check have separate scopes. No equivalent replacement or fresh gate execution is claimed. Earlier notes and dated receipts retain their original scope. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3994 retires two authored callbacks imported by the shared construction test driver: split OSC 9999 carry and rendererless status ownership, plus OpenCode permission text taking priority in status and tui-idle refusal. Remaining imports and selectors keep their scope. No equivalent replacement or fresh gate execution is claimed. Audit 3959 retires the whole session.test.ts driver (27 authored / 33 finite cases): startup/echo filtering, readiness input gates, ownership confirmation, detach authority, and termination retry/exit ordering alarms are intentionally lost. No equivalent replacement or fresh runtime validation is claimed. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous account (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous account (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous account (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous account (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous account (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous account (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous account (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous account (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous account (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous account (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous account (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous account (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous account (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous account (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous account (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous account (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous account (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous account (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Independently remove one authored/finite Playwright closed-gate app-boot inventory: accept loss of real renderer/preload/main refusal composition, saved-host row and Add/Move hiding/Remove visibility alarms. Keep the unchanged scripted-move rendered dialog lifecycle/reload case. It runs no real WSL migration, host connection, file copy or automation restoration. No selector or Playwright participation cleanup is required because the spec remains. Previous account (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3553/3559 current scope: delete worktrees-delete-pty-teardown.test.ts and worktrees-issue-command-overrides.test.ts entirely and remove three cases from worktrees-orphan-directory-cleanup.test.ts (6 authored/6 finite removals). Intentionally retire typed unserved-SSH create/delete admission, exact-name collision/error-token, proven-orphan no-force confirmation, standalone .git-directory refusal, and SSH-owned local-path preservation alarms. Retain only actual authorized orphan deletion and no-marker notes-file preservation; they are not equivalent replacements. The no-marker fixture resolves the default getRepos owner, so it does not prove temporary owner-repo binding. Git/Store/PTY/notifications are mocked; no physical process stop, durable metadata, real SSH delivery or native UI proof is claimed. Unchanged historical oracle, coverage, evidenceRuns and escaped receipts retain their original scopes only; no fresh execution or transferred pass validates the reduced sources. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2056 (sources2054/2055): Intentionally retire these low-value alarms without replacement: src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts: delivers remote file changes to listeners for the same worktree. src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/mobile-session-tabs-part-14.spec'). src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-03.spec.ts: arms the stale-title timer for a seeded working title; arms the Command Code scrape from the noted spawn command; prefers the tracked title over a stale renderer lastTitle in the hydration seed; writes recent output into the current runtime output map; uses a later title handler replacement with the runtime receiver; calls the current injected listener with the runtime receiver; keeps optional reconciliation lazy after its callback is removed. src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-14.spec.ts: lists them, so a paired client can mirror a migrated editor; closes one by retiring it from the host session; keeps an unsaved draft unless the close is forced; shares aggregate work but leaves a replacement pending promise alone; lets a targeted refresh finish while an aggregate refresh waits; refuses a close when the store lacks %s before the guard; keeps a later missing %s on the original caught failure path. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Exact retired assertionRefs, preserved as historical objects only: {\n \"file\": \"src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts\",\n \"assertions\": [\n \"terminal watcher error and setup failure evict the shared entry before retrying callbacks run\",\n \"an old stream end cannot evict the replacement stream, which still delivers to its listener\",\n \"two same-worktree listeners share a synthetic subscription until the final stop unsubscribes and sends unwatch\"\n ]\n } Historical prior account (preserved verbatim): Audit1973: Delete the standalone mocked watcher cleanup suite and its entire sole-file prospective command. Retire the removed file-command transport-abort alias; preserve the independent cancellation suite and final-overflow/error/end cleanup callback, and13 unrelated receipt objects. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial runtime files-watch suite retains controlled Windows close-event waiting, shared-client survival, late physical-exit ownership/deadline cleanup and shutdown joining. Its combined Windows close/deadline/late-exit alias remains backed by unchanged callbacks. Retire native-error-close, pre-publication setup ownership and failed-delete rearm aliases; associated delegation, failure forwarding, removal routing and recovery examples are lost. These tests inject watch/subscription seams and do not observe an actual native watcher or physical process. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): Partial runtime watcher-host suite loses mocked option/event/overflow/resubscription forwarding, supplied teardown-error propagation, aborted-signal/no-call and private ten-thousand-waiter-count inventories. Retire the 10,000-caller bound and failed-recovery-subscriber-ending assertion aliases. Keep same-root owner cancellation, pre-ready replacement, held root-close join, stale-generation recovery delivery and initial failed-root ownership mappings backed by retained real-host callbacks with injected subscription/error/physical-exit promises. No actual native watcher, process termination or resource bound was observed. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1683 removes low-value test projections, mock wiring, private-state assertions, inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained public behavior and refusal boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1645 removes low-value test projections, mock wiring, private-state assertions, inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained public behavior and refusal boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1640 removes low-value IPC, SSH, workspace and transcript-watcher tests without equivalent replacement coverage. Per-source reviews record retained public refusal, cancellation, execution-host and real-filesystem outcomes with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1634 removes low-value IPC, filesystem and runtime projections, argument inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained cancellation, ownership, authorization, filesystem and SQLite boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1627 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1623 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1516 removes package-electron-runtime-contract.test.mjs, a copied release-workflow platform and marker matrix. Its workflow wiring alarm is intentionally retired; no actual packaged watcher delivery was exercised and no equivalent replacement is claimed. Unaffected dated execution receipts retain their original scope; changed optional selectors have no fresh full-gate execution result. This audit removes the paired-web stopped-during-outage and late-ready direct-branch examples. The retained pre-ready cancellation, failed-unwatch retry and replay-continuity cases are not equivalent replacements for those ordering alarms. Current web-runtime-client.test.ts assertions below name only its retained pre-ready callback case; replay cases remain in their separate suite. Historical commands and results remain historical. Deterministic tests cover one shared healthy child per runtime process plus at most four bounded fault-quarantine children, native desktop, paired-runtime, and WSL snapshot processes sharing the same eight-physical-child reservation with typed serialized event-driven capacity recovery, including recursive re-wait when crash recovery reclaims an announced slot, one quarantine attempt per watch lifetime, generation-scoped cancellation, bounded termination with removable deadline waiters, replacement-crawl errors that cannot be blessed by a late readiness ack, pre-ready paired-web cancellation registered before an unbounded capacity wait, already-resolved and late physical-exit retry of a rejected paired-web teardown, physical desktop-install and local/SSH PTY teardown, stale-generation rejection, per-child stat bounds, final-overflow RPC delivery, and renderer eviction before terminal callbacks can retry. Destructive local and SSH removal fences both ID-derived and resolved-cwd terminal roots, including sibling-root/cwd combinations with reverse admission rollback, closes descendant relay watches before parent deletion, enumerates authoritative provider/cwd ownership, falls back to daemon spawn cwd before OSC 7, and keeps daemon/relay immediate shutdown pending until native exit or a bounded fail-closed error; a dead relay PID discovered during attach also settles concurrent shutdown before its stale entry is reaped, while Windows runtime watcher deadlines retain one removable physical-close waiter, treat Node's error-close path as positive physical-exit proof, and clear root ownership on late close. The relay policy test maps a standard repository's base, Git common directory, and worktree roots to one healthy supervisor, then proves a shared-child failure recovers those roots in separate quarantine supervisors with overflow and resumed events. Abortable capacity, quarantine, runtime-root, relay, SSH, and relay pre-install setup waits attach one reaction to each shared promise and explicitly remove 10,000 cancelled caller closures while one anchor remains. Built-entry macOS harnesses kill the desktop/runtime and SSH relay watcher children, then require automatic resubscription and later events while the host process and relay PTY survive. SSH bundles the child boundary beside relay.js, requires both artifacts for install completeness, and preserves registration-owned same-root cancellation. The test-value audit corrects the active renderer watch command/file reference to the existing runtime-file-client-watch.test.ts, whose three cases are retained unchanged. They observe synthetic subscription retry/fanout and unsubscribe/unwatch calls, not actual preload/main bookkeeping or physical watcher-process cleanup. The separate read/preview client suite loses forwarding, supplied-error and negative-only examples, retaining binary detection and Unicode SVG decoding. Historical evidence commands/results are unchanged. Test-value audit1293 removes src/main/providers/local-pty/local-pty-provider-session-inventory.test.ts (2 authored cases). Their isolated assertions no longer run; surviving tests are not claimed as equivalent coverage. Fresh execution against the candidate SHA is required. Audit1312 removes low-value imported specs from aggregate test drivers; old whole-driver execution receipts are archived. Retained registrations are unchanged. No equivalent replacement coverage is claimed. Audit1383: src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts reduced. Lose command-list/receipt/default/background activation matrices whose provider spawn returns canned IDs. Retained test proves actual tab allocation separation, not terminal startup. No equivalent replacement coverage is claimed. Existing exact unaffected receipts and their platform/provider/budget claims remain scoped to unchanged selectors. Changed optional selectors have no new execution result. Audit1401: src/main/runtime/orca-runtime-tests/mobile-session-tabs-duplicate-pty-repair.spec.ts removed. Loses listing-on-already-repaired-data alarm; it never established runtime repair invocation. src/main/runtime/orca-runtime-tests/mobile-session-tabs-split-agent-tab.spec.ts removed. Loses actual mobile split sibling shell versus recorded-agent resume command alarms; no equivalent coverage asserted. src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts removed. Loses separate setup/startup tab result in that manually assembled path. src/main/runtime/orca-runtime.test.ts reduced. Driver registration/import of a whole-deleted selected spec is removed; directly authored cases remain unchanged. No extra authored removal credit. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1412: src/main/workspaces/removal/watcher-removal-gate.test.ts reduced. Loses exact removal-error compatibility with renderer predicate under shared message constants. Kept public refusal outcomes do not establish that renderer classification. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Prospective settings-host12 runtime-ipc110 reduction: The runtime compatibility driver is intentionally narrowed by runtime-ipc110 whole-registration policy: four imported TEST fragments are retired and reviewed partial fragments lose complete callbacks. Full path/title/hash and lost-alarm records are bound in the local runtime-ipc110 recipe. This is an import-closure disclosure; command filters may select only part of that driver. All remaining selectors keep only their own bounded scope. Preserve every earlier narrative, historical assertion receipt and dated evidenceRun exactly. Historical runs do not validate the reduced registration set; no fresh test, timing, runtime or whole-gate pass is claimed. Module-layout cleanup: Removed paired-web client TEST alarms for connecting-search abort/pre-abort, close rejecting pending connect waiters, expired-handshake socket retirement and encrypted binary interoperability. The pre-ready paired-web watch assertion reference also retires with that TEST; its claimed callback was already absent from the current four registrations. No replacement coverage or new execution is claimed; dated receipts describe their original runs.", + "coverageNotes": "Runtime layout review retires the wedged watcher-install removal-fence callback because it asserts an internal production-derived timing boundary. Its acquisition-expiry, usable-release and subsequent-install alarms are intentionally lost without replacement coverage. The retained runtime collector has narrower scope; unrelated dated physical watcher resource/fault/build receipts retain their original scope and are not fresh validation of this reduction. Complete prior account retained verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5901 removes only the mobile-creation-and-orchestration-part-03.spec import from the retained runtime driver. The fragment's missing-handle wait abort and waiter retirement on reload-exit alarms are intentionally lost. This is a conservative import-closure notice: named command filters may exclude those cases. Driver selectors remain; unchanged historical receipts retain their original scope and establish no fresh whole-gate pass or equivalent replacement. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5896 retires the whole promise-settlement-waiters suite, intentionally losing its Promise ordering/abandon cleanup alarms. Remaining selectors are not equivalent replacement coverage; unrelated dated receipts retain original scope. No fresh whole-gate validation is claimed. Complete prior account retained verbatim: Shared primitives layout deliberately retires the promise waiter actual-timeout/supplied-result/internal waiter-count/timer-count callback. The already-aborted ownership-abandon callback survives at its moved concurrency test path. No equivalent timeout detachment/timer-cleanup alarm or fresh validation of the reduced/moved source is claimed. All13 dated build/resource/fault-harness receipts remain exact and retain only their original scopes. Previous account (verbatim; historical where it concerns changed source): Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose watcher registry release-before-listen wakeup, one-released-slot reservation ordering, event flush blocked-active/overflow delivery and close-settlement alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit5574 removes the entire physical-exit waiter bookkeeping suite and its active selectors/assertion reference. Timeout/retry, fanout/double-exit and immediate-later-wait alarms are intentionally retired without equivalent replacement or fresh process-exit evidence. Unrelated dated receipts retain their exact original scopes. Historical account follows: Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4358 intentionally removes six whole mocked daemon subprocess suites and two extra pre-listener replay variants (18 authored / 20 finite cases). Lost alarms include cancel-during-cwd-validation, root agent startup refusal, output/exit before ConPTY publication, fresh/delayed/unavailable foreground confirmation, cache/decision separation, detached/no-tty child evidence and synthetic agent authorization. The retained lifecycle case checks data and exit replay after handle creation, not startup-time publication or alternate listener order. The retained native Windows Git Bash workflow and host cold-restore seed check have separate scopes. No equivalent replacement or fresh gate execution is claimed. Earlier notes and dated receipts retain their original scope. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3994 retires two authored callbacks imported by the shared construction test driver: split OSC 9999 carry and rendererless status ownership, plus OpenCode permission text taking priority in status and tui-idle refusal. Remaining imports and selectors keep their scope. No equivalent replacement or fresh gate execution is claimed. Audit 3959 retires the whole session.test.ts driver (27 authored / 33 finite cases): startup/echo filtering, readiness input gates, ownership confirmation, detach authority, and termination retry/exit ordering alarms are intentionally lost. No equivalent replacement or fresh runtime validation is claimed. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous account (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous account (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous account (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous account (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous account (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous account (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous account (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous account (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous account (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous account (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous account (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous account (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous account (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous account (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous account (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous account (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous account (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous account (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Independently remove one authored/finite Playwright closed-gate app-boot inventory: accept loss of real renderer/preload/main refusal composition, saved-host row and Add/Move hiding/Remove visibility alarms. Keep the unchanged scripted-move rendered dialog lifecycle/reload case. It runs no real WSL migration, host connection, file copy or automation restoration. No selector or Playwright participation cleanup is required because the spec remains. Previous account (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3553/3559 current scope: delete worktrees-delete-pty-teardown.test.ts and worktrees-issue-command-overrides.test.ts entirely and remove three cases from worktrees-orphan-directory-cleanup.test.ts (6 authored/6 finite removals). Intentionally retire typed unserved-SSH create/delete admission, exact-name collision/error-token, proven-orphan no-force confirmation, standalone .git-directory refusal, and SSH-owned local-path preservation alarms. Retain only actual authorized orphan deletion and no-marker notes-file preservation; they are not equivalent replacements. The no-marker fixture resolves the default getRepos owner, so it does not prove temporary owner-repo binding. Git/Store/PTY/notifications are mocked; no physical process stop, durable metadata, real SSH delivery or native UI proof is claimed. Unchanged historical oracle, coverage, evidenceRuns and escaped receipts retain their original scopes only; no fresh execution or transferred pass validates the reduced sources. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2056 (sources2054/2055): Intentionally retire these low-value alarms without replacement: src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts: delivers remote file changes to listeners for the same worktree. src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/mobile-session-tabs-part-14.spec'). src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-03.spec.ts: arms the stale-title timer for a seeded working title; arms the Command Code scrape from the noted spawn command; prefers the tracked title over a stale renderer lastTitle in the hydration seed; writes recent output into the current runtime output map; uses a later title handler replacement with the runtime receiver; calls the current injected listener with the runtime receiver; keeps optional reconciliation lazy after its callback is removed. src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-14.spec.ts: lists them, so a paired client can mirror a migrated editor; closes one by retiring it from the host session; keeps an unsaved draft unless the close is forced; shares aggregate work but leaves a replacement pending promise alone; lets a targeted refresh finish while an aggregate refresh waits; refuses a close when the store lacks %s before the guard; keeps a later missing %s on the original caught failure path. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Exact retired assertionRefs, preserved as historical objects only: {\n \"file\": \"src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts\",\n \"assertions\": [\n \"terminal watcher error and setup failure evict the shared entry before retrying callbacks run\",\n \"an old stream end cannot evict the replacement stream, which still delivers to its listener\",\n \"two same-worktree listeners share a synthetic subscription until the final stop unsubscribes and sends unwatch\"\n ]\n } Historical prior account (preserved verbatim): Audit1973: Delete the standalone mocked watcher cleanup suite and its entire sole-file prospective command. Retire the removed file-command transport-abort alias; preserve the independent cancellation suite and final-overflow/error/end cleanup callback, and13 unrelated receipt objects. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial runtime files-watch suite retains controlled Windows close-event waiting, shared-client survival, late physical-exit ownership/deadline cleanup and shutdown joining. Its combined Windows close/deadline/late-exit alias remains backed by unchanged callbacks. Retire native-error-close, pre-publication setup ownership and failed-delete rearm aliases; associated delegation, failure forwarding, removal routing and recovery examples are lost. These tests inject watch/subscription seams and do not observe an actual native watcher or physical process. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): Partial runtime watcher-host suite loses mocked option/event/overflow/resubscription forwarding, supplied teardown-error propagation, aborted-signal/no-call and private ten-thousand-waiter-count inventories. Retire the 10,000-caller bound and failed-recovery-subscriber-ending assertion aliases. Keep same-root owner cancellation, pre-ready replacement, held root-close join, stale-generation recovery delivery and initial failed-root ownership mappings backed by retained real-host callbacks with injected subscription/error/physical-exit promises. No actual native watcher, process termination or resource bound was observed. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1683 removes low-value test projections, mock wiring, private-state assertions, inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained public behavior and refusal boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1645 removes low-value test projections, mock wiring, private-state assertions, inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained public behavior and refusal boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1640 removes low-value IPC, SSH, workspace and transcript-watcher tests without equivalent replacement coverage. Per-source reviews record retained public refusal, cancellation, execution-host and real-filesystem outcomes with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1634 removes low-value IPC, filesystem and runtime projections, argument inventories and duplicate examples without equivalent replacement coverage. Per-source reviews record retained cancellation, ownership, authorization, filesystem and SQLite boundaries with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1627 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1623 removes low-value mocked daemon projections, scalar tables and duplicate terminal examples without equivalent replacement coverage. Per-source reviews record retained terminal content preservation, process ownership refusal and recovery boundaries together with injected/native/remote limits. Affected historical receipts are retired; gates without active current evidence are downgraded. Historical scope before this audit: Audit1516 removes package-electron-runtime-contract.test.mjs, a copied release-workflow platform and marker matrix. Its workflow wiring alarm is intentionally retired; no actual packaged watcher delivery was exercised and no equivalent replacement is claimed. Unaffected dated execution receipts retain their original scope; changed optional selectors have no fresh full-gate execution result. This audit removes the paired-web stopped-during-outage and late-ready direct-branch examples. The retained pre-ready cancellation, failed-unwatch retry and replay-continuity cases are not equivalent replacements for those ordering alarms. Current web-runtime-client.test.ts assertions below name only its retained pre-ready callback case; replay cases remain in their separate suite. Historical commands and results remain historical. Deterministic tests cover one shared healthy child per runtime process plus at most four bounded fault-quarantine children, native desktop, paired-runtime, and WSL snapshot processes sharing the same eight-physical-child reservation with typed serialized event-driven capacity recovery, including recursive re-wait when crash recovery reclaims an announced slot, one quarantine attempt per watch lifetime, generation-scoped cancellation, bounded termination with removable deadline waiters, replacement-crawl errors that cannot be blessed by a late readiness ack, pre-ready paired-web cancellation registered before an unbounded capacity wait, already-resolved and late physical-exit retry of a rejected paired-web teardown, physical desktop-install and local/SSH PTY teardown, stale-generation rejection, per-child stat bounds, final-overflow RPC delivery, and renderer eviction before terminal callbacks can retry. Destructive local and SSH removal fences both ID-derived and resolved-cwd terminal roots, including sibling-root/cwd combinations with reverse admission rollback, closes descendant relay watches before parent deletion, enumerates authoritative provider/cwd ownership, falls back to daemon spawn cwd before OSC 7, and keeps daemon/relay immediate shutdown pending until native exit or a bounded fail-closed error; a dead relay PID discovered during attach also settles concurrent shutdown before its stale entry is reaped, while Windows runtime watcher deadlines retain one removable physical-close waiter, treat Node's error-close path as positive physical-exit proof, and clear root ownership on late close. The relay policy test maps a standard repository's base, Git common directory, and worktree roots to one healthy supervisor, then proves a shared-child failure recovers those roots in separate quarantine supervisors with overflow and resumed events. Abortable capacity, quarantine, runtime-root, relay, SSH, and relay pre-install setup waits attach one reaction to each shared promise and explicitly remove 10,000 cancelled caller closures while one anchor remains. Built-entry macOS harnesses kill the desktop/runtime and SSH relay watcher children, then require automatic resubscription and later events while the host process and relay PTY survive. SSH bundles the child boundary beside relay.js, requires both artifacts for install completeness, and preserves registration-owned same-root cancellation. The test-value audit corrects the active renderer watch command/file reference to the existing runtime-file-client-watch.test.ts, whose three cases are retained unchanged. They observe synthetic subscription retry/fanout and unsubscribe/unwatch calls, not actual preload/main bookkeeping or physical watcher-process cleanup. The separate read/preview client suite loses forwarding, supplied-error and negative-only examples, retaining binary detection and Unicode SVG decoding. Historical evidence commands/results are unchanged. Test-value audit1293 removes src/main/providers/local-pty/local-pty-provider-session-inventory.test.ts (2 authored cases). Their isolated assertions no longer run; surviving tests are not claimed as equivalent coverage. Fresh execution against the candidate SHA is required. Audit1312 removes low-value imported specs from aggregate test drivers; old whole-driver execution receipts are archived. Retained registrations are unchanged. No equivalent replacement coverage is claimed. Audit1383: src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts reduced. Lose command-list/receipt/default/background activation matrices whose provider spawn returns canned IDs. Retained test proves actual tab allocation separation, not terminal startup. No equivalent replacement coverage is claimed. Existing exact unaffected receipts and their platform/provider/budget claims remain scoped to unchanged selectors. Changed optional selectors have no new execution result. Audit1401: src/main/runtime/orca-runtime-tests/mobile-session-tabs-duplicate-pty-repair.spec.ts removed. Loses listing-on-already-repaired-data alarm; it never established runtime repair invocation. src/main/runtime/orca-runtime-tests/mobile-session-tabs-split-agent-tab.spec.ts removed. Loses actual mobile split sibling shell versus recorded-agent resume command alarms; no equivalent coverage asserted. src/main/runtime/orca-runtime-tests/worktree-native-chat-setup.spec.ts removed. Loses separate setup/startup tab result in that manually assembled path. src/main/runtime/orca-runtime.test.ts reduced. Driver registration/import of a whole-deleted selected spec is removed; directly authored cases remain unchanged. No extra authored removal credit. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Audit1412: src/main/workspaces/removal/watcher-removal-gate.test.ts reduced. Loses exact removal-error compatibility with renderer predicate under shared message constants. Kept public refusal outcomes do not establish that renderer classification. No equivalent replacement coverage is claimed. Existing exact unaffected receipts remain unchanged and apply only to their unchanged selectors. Changed optional selectors have no new execution result. Prospective settings-host12 runtime-ipc110 reduction: The runtime compatibility driver is intentionally narrowed by runtime-ipc110 whole-registration policy: four imported TEST fragments are retired and reviewed partial fragments lose complete callbacks. Full path/title/hash and lost-alarm records are bound in the local runtime-ipc110 recipe. This is an import-closure disclosure; command filters may select only part of that driver. All remaining selectors keep only their own bounded scope. Preserve every earlier narrative, historical assertion receipt and dated evidenceRun exactly. Historical runs do not validate the reduced registration set; no fresh test, timing, runtime or whole-gate pass is claimed. Module-layout cleanup: Removed paired-web client TEST alarms for connecting-search abort/pre-abort, close rejecting pending connect waiters, expired-handshake socket retirement and encrypted binary interoperability. The pre-ready paired-web watch assertion reference also retires with that TEST; its claimed callback was already absent from the current four registrations. No replacement coverage or new execution is claimed; dated receipts describe their original runs.", "motivatingLinks": [ "https://github.com/stablyai/orca/issues/5308", "https://github.com/stablyai/orca/issues/7547", "https://github.com/stablyai/orca/issues/8212" ], "invariant": "Local runtime and SSH relay roots share one watcher child per host process while healthy and use at most four quarantine children after shard failure; native desktop, paired-runtime, and direct WSL snapshot children consume the same process-wide eight-child reservation and retry transient exhaustion without permanently disabling a root. Cancellation remains owned by its child generation and settles only after acknowledgement or bounded physical exit; paired-web retains cleanup ownership and can cancel before readiness even while capacity is exhausted, retries a failed unwatch after already-resolved or late physical exit without duplicating stream termination, replacements never overlap a still-retiring generation, and aborted or timed-out callers detach immediately even while queued behind same-root relay teardown. Destructive local and SSH cleanup holds one containment-aware watcher/terminal removal fence through descendant watcher and PTY physical exit plus parent Git/filesystem deletion; daemon and relay kill requests retain ownership until the actual subprocess exit callback or an equivalent positive dead-PID proof and propagate rejected signals or a bounded failure otherwise. A crash-fused shared shard moves affected roots into the bounded quarantine pool, a second fused quarantine ends those watch lifetimes, interrupted setup emits overflow after recovery, metadata work stays bounded, and the SSH relay, PTYs, Git, and other filesystem operations never load the watcher native addon or share its fault boundary.", - "oracle": "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5896 retires the whole promise-settlement-waiters suite, intentionally losing its Promise ordering/abandon cleanup alarms. Remaining selectors are not equivalent replacement coverage; unrelated dated receipts retain original scope. No fresh whole-gate validation is claimed. Complete prior account retained verbatim: Shared primitives layout deliberately retires the promise waiter actual-timeout/supplied-result/internal waiter-count/timer-count callback. The already-aborted ownership-abandon callback survives at its moved concurrency test path. No equivalent timeout detachment/timer-cleanup alarm or fresh validation of the reduced/moved source is claimed. All13 dated build/resource/fault-harness receipts remain exact and retain only their original scopes. Previous account (verbatim; historical where it concerns changed source): Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose watcher registry release-before-listen wakeup, one-released-slot reservation ordering, event flush blocked-active/overflow delivery and close-settlement alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4358 intentionally removes six whole mocked daemon subprocess suites and two extra pre-listener replay variants (18 authored / 20 finite cases). Lost alarms include cancel-during-cwd-validation, root agent startup refusal, output/exit before ConPTY publication, fresh/delayed/unavailable foreground confirmation, cache/decision separation, detached/no-tty child evidence and synthetic agent authorization. The retained lifecycle case checks data and exit replay after handle creation, not startup-time publication or alternate listener order. The retained native Windows Git Bash workflow and host cold-restore seed check have separate scopes. No equivalent replacement or fresh gate execution is claimed. Earlier notes and dated receipts retain their original scope. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Previous oracle (preserved verbatim): Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous oracle (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous oracle (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous oracle (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous oracle (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous oracle (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous oracle (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous oracle (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous oracle (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous oracle (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous oracle (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous oracle (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous oracle (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous oracle (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous oracle (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Previous oracle (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3553/3559 current scope: delete worktrees-delete-pty-teardown.test.ts and worktrees-issue-command-overrides.test.ts entirely and remove three cases from worktrees-orphan-directory-cleanup.test.ts (6 authored/6 finite removals). Intentionally retire typed unserved-SSH create/delete admission, exact-name collision/error-token, proven-orphan no-force confirmation, standalone .git-directory refusal, and SSH-owned local-path preservation alarms. Retain only actual authorized orphan deletion and no-marker notes-file preservation; they are not equivalent replacements. The no-marker fixture resolves the default getRepos owner, so it does not prove temporary owner-repo binding. Git/Store/PTY/notifications are mocked; no physical process stop, durable metadata, real SSH delivery or native UI proof is claimed. Unchanged historical oracle, coverage, evidenceRuns and escaped receipts retain their original scopes only; no fresh execution or transferred pass validates the reduced sources. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2056 (sources2054/2055): Intentionally retire these low-value alarms without replacement: src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts: delivers remote file changes to listeners for the same worktree. src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/mobile-session-tabs-part-14.spec'). src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-03.spec.ts: arms the stale-title timer for a seeded working title; arms the Command Code scrape from the noted spawn command; prefers the tracked title over a stale renderer lastTitle in the hydration seed; writes recent output into the current runtime output map; uses a later title handler replacement with the runtime receiver; calls the current injected listener with the runtime receiver; keeps optional reconciliation lazy after its callback is removed. src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-14.spec.ts: lists them, so a paired client can mirror a migrated editor; closes one by retiring it from the host session; keeps an unsaved draft unless the close is forced; shares aggregate work but leaves a replacement pending promise alone; lets a targeted refresh finish while an aggregate refresh waits; refuses a close when the store lacks %s before the guard; keeps a later missing %s on the original caught failure path. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Exact retired assertionRefs, preserved as historical objects only: {\n \"file\": \"src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts\",\n \"assertions\": [\n \"terminal watcher error and setup failure evict the shared entry before retrying callbacks run\",\n \"an old stream end cannot evict the replacement stream, which still delivers to its listener\",\n \"two same-worktree listeners share a synthetic subscription until the final stop unsubscribes and sends unwatch\"\n ]\n } Historical prior account (preserved verbatim): Audit1973: Delete the standalone mocked watcher cleanup suite and its entire sole-file prospective command. Retire the removed file-command transport-abort alias; preserve the independent cancellation suite and final-overflow/error/end cleanup callback, and13 unrelated receipt objects. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial runtime files-watch suite retains controlled Windows close-event waiting, shared-client survival, late physical-exit ownership/deadline cleanup and shutdown joining. Its combined Windows close/deadline/late-exit alias remains backed by unchanged callbacks. Retire native-error-close, pre-publication setup ownership and failed-delete rearm aliases; associated delegation, failure forwarding, removal routing and recovery examples are lost. These tests inject watch/subscription seams and do not observe an actual native watcher or physical process. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): Partial runtime watcher-host suite loses mocked option/event/overflow/resubscription forwarding, supplied teardown-error propagation, aborted-signal/no-call and private ten-thousand-waiter-count inventories. Retire the 10,000-caller bound and failed-recovery-subscriber-ending assertion aliases. Keep same-root owner cancellation, pre-ready replacement, held root-close join, stale-generation recovery delivery and initial failed-root ownership mappings backed by retained real-host callbacks with injected subscription/error/physical-exit promises. No actual native watcher, process termination or resource bound was observed. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Fill the global watcher-child reservation, require native desktop, paired-runtime, and WSL setup to retain typed transient capacity and retry after one serialized release, then cancel pending desktop and paired-client watches and require no retry. Hold one live anchor while aborting 10,000 callers at the capacity, quarantine-assignment, runtime-root, relay-setup, and SSH-registration layers; require exactly one explicit waiter and one base-promise reaction to remain, then zero after settlement. Hold an old relay unsubscribe, queue one same-root setup leader and one anchor, then abort 10,000 joiners; require every cancellation to settle before teardown releases, exactly one anchor waiter, and only one later physical install. Advance the former paired-web callback deadline while capacity remains full, require cancellation ownership to stay live, publish the server token before ready, and require files.unwatch to abort setup before a later slot release can install a native root. Reject the first ready-watch unwatch with a physical-exit promise, resolve that exit later, and require a fresh physical unwatch attempt, registry release, and exactly one stream end. Fill one healthy shared child with multiple roots, map a standard SSH repository's base, Git common directory, and worktree roots to one relay supervisor, then inject IPC disconnect-before-exit, queued and active cancellation, operations during termination, kill-without-exit, repeated unkillable generations, initial and recovery timeouts, and shard failure. During local and SSH deletion, attempt a late terminal spawn whose worktree identity and cwd name different roots, enumerate a non-prefix remote PTY by authoritative worktree ownership, withhold daemon/relay exit callbacks, make attach positively prove a concurrent-shutdown PID dead, and make the provider unavailable; require every acquired admission to roll back on rejection, dead-PID proof to settle physical exit before reaping, timeout to retain ownership, and Git/filesystem deletion never to start. Require bounded watcher process count, physical-exit settlement, healthy-root recovery, stale-generation rejection, overflow plus later events, and fail-closed destructive cleanup. Verify relay build hashes and remote install probes require both relay.js and relay-watcher.js. Launch the built relay with a real PTY and Parcel watch, kill only the watcher child, and require the same relay PID and PTY to answer before a replacement child delivers overflow and a post-crash event.", + "oracle": "Runtime layout cleanup intentionally retires the removed compatibility callbacks and wholly removed fragments without replacement coverage. The compatibility entrypoint retains only its surviving registration scope. Existing independent dated receipts remain at their original commands and scopes; no fresh runtime, native, remote or platform execution is claimed. Prior account preserved verbatim: Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. Complete prior account retained verbatim: Audit5896 removes only the paired-settings.spec and dispatch-mailbox-delivery.spec import lines from their retained runtime/mailbox drivers. Those imported suites and alarms are intentionally retired, without equivalent replacement. Driver selectors remain; unchanged dated receipts retain original scope and do not establish a new whole-gate import-closure pass. Complete prior account retained verbatim: Audit5896 retires the whole promise-settlement-waiters suite, intentionally losing its Promise ordering/abandon cleanup alarms. Remaining selectors are not equivalent replacement coverage; unrelated dated receipts retain original scope. No fresh whole-gate validation is claimed. Complete prior account retained verbatim: Shared primitives layout deliberately retires the promise waiter actual-timeout/supplied-result/internal waiter-count/timer-count callback. The already-aborted ownership-abandon callback survives at its moved concurrency test path. No equivalent timeout detachment/timer-cleanup alarm or fresh validation of the reduced/moved source is claimed. All13 dated build/resource/fault-harness receipts remain exact and retain only their original scopes. Previous account (verbatim; historical where it concerns changed source): Audit5648/source5643 retires complete suites and their exact active selectors/assertion references. Intentionally lose watcher registry release-before-listen wakeup, one-released-slot reservation ordering, event flush blocked-active/overflow delivery and close-settlement alarms. No equivalent replacement, fresh execution or native/remote/platform evidence is claimed. Complete original selector/assertion fields and historical scopes remain in knownGaps. Prior account (verbatim): Audit4368 intentionally drops seven mocked teardown cases: duplicate single-chat rollback, forced stuck-close warning/retirement, post-close-throw exit acceptance, mixed live/unconfirmed wording, exact serial-close budget work, missing runtime selector success and runtime-sweep rejection. Four structured-session and three PTY teardown cases remain; no replacement or fresh native/process/remote proof is claimed. Historical assertion anchors and receipts are not refreshed by this source-only reduction. Audit4362 intentionally deletes the imported stale-waiter retry and manually assembled OSC9999 mobile-republish cases, plus the mocked missing-worktree cleanup suite (4 authored / 5 finite cases in three suites). Lost alarms include repeated unread worker_done pointers, working-to-waiting mobile status publication, missing-worktree filtering, and scoped daemon shutdown with unrelated duplicate identities. No replacement coverage or new platform proof is claimed. Audit4358 intentionally removes six whole mocked daemon subprocess suites and two extra pre-listener replay variants (18 authored / 20 finite cases). Lost alarms include cancel-during-cwd-validation, root agent startup refusal, output/exit before ConPTY publication, fresh/delayed/unavailable foreground confirmation, cache/decision separation, detached/no-tty child evidence and synthetic agent authorization. The retained lifecycle case checks data and exit replay after handle creation, not startup-time publication or alternate listener order. The retained native Windows Git Bash workflow and host cold-restore seed check have separate scopes. No equivalent replacement or fresh gate execution is claimed. Earlier notes and dated receipts retain their original scope. Audit4351 removes the physical-exit timeout/retry and kill-failure/retry local-PTY shutdown cases. The retained shutdown case proves pending ownership until the injected node-pty exit callback only. These two narrow error-path alarms are intentionally lost; retained commands still select the reduced suite. No equivalent replacement or fresh runtime execution is claimed. Earlier notes and dated receipts retain their original scopes. Audit3832 deliberately retires76 authored/79 finite cases:75 runtime compatibility cases/78 finite cases across14 fragments, plus one localization extractor default-flag case. Three whole runtime fragments are deleted;27 authored/30 finite cases remain across the reviewed sources. This gate retains only its own selected scope; no equivalent replacement or fresh runtime/native/remote evidence is claimed. Runtime component A: Audit3828 composes3822 with independent3824: deliberately retires49 authored/52 finite cases from seven compatibility fragments, leaving15 authored/18 finite cases and deleting two entire fragments. Accepted losses: positive folder-worker recovery/materialization and reveal deadline; persisted-key normalization and legacy split/group/focus projection; fixed stale CAS refusal; occupied/alias/restored/preallocated terminal-handle variants; fixed OpenCode/Cursor/Claude/Codex/Antigravity classification, readiness, title and management examples; direct private-map browser authority projections; browser-focus and OMP title projection; already-aborted claim cleanup. Additional3824 loss: src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-02.spec.ts :: does not poll a wrapper foreground for a speculative CLI prompt send :: Speculative retryForegroundWrappers:false check must return false on a wrapper after one foreground read, without polling the supplied later codex response. These real bounded alarms are deliberately retired for low marginal value. Retained callbacks are unchanged and provide only their own bounded scope, not equivalent replacement. Historical receipts do not validate reduced callbacks. No fresh runtime/native/SSH/WSL/phone/browser evidence or full transitive closure is claimed. Runtime component B: Audit3834 deliberately retires26 authored/26 finite cases from seven fresh compatibility fragments, leaving10/10 and deleting the one-case saved-binding reattachment fragment. Original position58 is excluded: its existing substantive3578 KEEP7 review remains historical, with no fresh credit. Accepted losses: fixed hook/provider-session identities and stale metadata refusal; decorative/pre-title foreground ordering variants; saved-binding surface reattachment; saved-row exit ghost removal and silent activation selection; unsupported headless wake; positive pending materialization/group projections; per-caller navigation selection; positive SSH hydration/read partition; laptop mobile publication/buffer and background/pending/status projections; abnormal/unregistered SSH grace, normal-exit refusal, persisted SSH hydration, positive serve reattachment, pending-agent launch arguments and direct seeded running-launch admission guard. These are real bounded alarms deliberately retired for low marginal value. Retained cases preserve their own distinct deferred foreground coalescing, usable handle continuity, stale inventory refresh, concurrent browser snapshot preservation, renderer graph fencing, caller dedup isolation, SSH partition writes, runtime split lifetime, independent relay-ready publication, lease admission/state/expiry. The direct running-launch no-spawn guard alarm is deliberately retired; no remaining owning-launch refusal coverage is claimed. Historical runs do not validate reduced callbacks. No equivalent replacement, runtime/native/SSH/WSL/phone/browser result or full transitive closure is claimed. Additional extractor loss: config/scripts/localization/source-extraction/audit-localization-native-dialogs.test.mjs :: does not change the existing renderer scan by default :: Default options must omit the five native-only fields in this supplied snippet. No equivalent replacement is claimed. Historical prior account (preserved verbatim): Audit3814 deliberately retires60 authored/60 finite cases:53runtime compatibility cases,4native XCTest methods and3Python clipboard methods, including the entire StableElementIndexes suite. Clipboard cuts retire the one-over-cap sample, incoming-offer destruction trace and sequential20-copy replay; actual wire, FD/pipe, startup and Xvfb/GTK boundaries remain without equivalent replacement claims. Accepted losses include narrow terminal-send payload/provider projections, legacy and direct no-op/error permutations, timing/work-count examples, private state/title/activity projections and fixture-driven readiness examples, individually enumerated below. These include real bounded production alarms consciously retired for marginal value; retained failed writes, duplicate submission, stale capture, transcript/ring and allocation fences are not equivalent replacements. No fresh native/remote/browser execution or complete transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3806 deliberately retires40 authored/40 finite runtime compatibility cases, including the terminal-side-effect-facts-part03 headless-snapshots-part02 and agent-status-and-waits-part03 fragments, plus20 scalar Swift precondition sites. Lost runtime alarms include status/title/attention projection examples, simple renderer/headless frame restoration and status waiting outcomes detailed in the accepted-loss ledger. Swift cuts retire duplicate generation-map/schema/navigation/bridge and notification-wrapper assertions; no standalone native program is deleted. These include real bounded production alarms consciously retired for marginal value. Retained races, pending writes/reflow, namespace and waiter ownership are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3798 deliberately retires21 authored/24 finite compatibility cases, including the entire SSH-worktree-lifecycle and repository-project-operations fragments. Accepted losses include navigation-only settings acknowledgement, browser session cleanup and host preservation projections, window positive/policy-state examples, terminal recovery/reload and no-incarnation remint examples, terminal listing compatibility/malformed IDs, directory browse/sort/Windows path smoke, SSH create refusal/manual lineage, recursive parent-folder creation and fork/origin/avatar/icon projections. Real bounded production alarms are consciously retired for marginal value; retained authority races, cleanup/clone ownership, pending waiters, nested-folder and scan invalidation cases are not equivalent replacements. No fresh native/remote/browser execution or full transitive closure is claimed. Earlier dated receipts and raw selectors remain historical accounts of prior callback sets. Audit3788 retires10 authored/11 expanded cases across six changed drivers, including the entire screencast pending-frame-retry and usage-source-cache-streaming suites. Deliberate losses are false-refused last-frame retry/once-only delivery, ordinary stable-pane reattachment, cleared-chat Dispatch completion, terminal-declared chat-caller refusal, at-rest worker liveness projection, nested depth/cap policy, small unsigned6/sealed7 plain-format and verified-bit examples, generic malformed-ISIZE footer refusal examples, and synthetic10k/100k chunk-size/work-count budgets in gzip and general cache I/O. These include real state/disk/RPC outcomes consciously retired for marginal value; retained E2EE-backlog, receipt/custody/uncertain-ack, integrity/migration and staging-cleanup cases are not equivalent replacements. The footer test did not prove early rejection or bounded allocation; staging cleanup did not seed unrelated files. No replacement or fresh native/remote/performance execution is claimed. Earlier raw selectors and dated receipts remain historical. Audit3779 retires17 authored/17 expanded registrations across six changed drivers, including the entire shared-Codex-home and prompt-telemetry suites. Accepted losses are shared-home wrapper noninterference/opt-out preservation, mocked metric count/provenance filters, SSH activity labeling/clearing and handover idle timing, VM ownership/capability/status projections and asleep-worktree refusal, a link-only external conversation replay sample, and two narrow input-credit noninterference/expiry examples. Retain the direct exact-tab/single-use input-credit case. These bounded real disk/state/routing alarms are intentionally retired for marginal value without equivalent replacement or fresh execution claims; earlier receipts remain historical. Audit3772 retires18 authored/27 expanded cases, including whole Codex service opt-out, RPC capability-parser, creator-provenance, short-ciphertext and readiness-null suites. Accepted losses include service ledger/symlink/mode cleanup, user TOML substring preservation, old-hash cleanup, description pass-through, malformed-file/pending-hash examples, coordinator write/probe counts, capability array bounds, positive creator projections, early short-payload refusal and readiness helper null shape. Two redundant Codex exit-cause rows are also retired; Pi shares their direct-idle path only in this empty-output immediate-exit fixture, and future agent-config drift coverage is lost. Real bounded filesystem/parser/runtime alarms are deliberately retired for marginal value; no equivalent replacements or fresh execution are claimed. Earlier receipts retain their historical scope. Audits3754/3755 intentionally remove9 authored/9 finite registrations: the entire one-case usage-source-cache-streaming.test.ts driver and8 cases from the surviving computer-action-validation.test.ts driver. This gate retains an unfiltered root Vitest command; UNIT_INCLUDE admits both source paths. Accepted losses are the real encoder output chunk-size/work-count alarm on repetitive10k/100k ownership payloads through a mocked durable sink, plus CLI diagnostic precedence, fractional window-id rejection, action-call-site window-target exclusivity, plain-text click-count recovery copy, incomplete click/drag targeting, mouse/modifier/direction allowlist samples and inline/stdin text exclusivity. These CLI cases exercise real argument/handler validation before mocked runtime calls; they are deliberately retired for marginal value, not declared tautologies. Retained cache I/O and CLI cases are not equivalent replacements for these alarms. Existing historical raw receipts remain unchanged and do not validate the deleted or reduced drivers. No fresh execution claim is made. Audits3758/3763 intentionally remove9 authored/11 finite registrations from6 changed drivers, including the entire pane-title-notification, window-linear-notices and worktree-card-lifecycle-effects suites. This gate retains an unfiltered root Vitest command admitting these paths. Accepted losses are same-account linked-row success-notice fanout, sidebar-switch channel forwarding, Linear-only notification forwarding/non-terminal-consumer selection/closed-window detach, destroyed-window refusal and first-send-failure suspension through the pane-title adapter, the100-card synthetic focus/poll absence sample, stored-source local folder badge refresh, unobserved-row badge refusal, and immediate reposChanged lineage invalidation. These exercise real owners with controlled ports; they are retired for marginal value, without equivalent replacement claims. The no-badge-work fixture does not seed its title-promised collection-only cache. Preserved historical receipts do not validate deleted or reduced drivers; no fresh execution is claimed. Audit3759 retires the entire one-case Tailwind compiler/scanner smoke. Accept loss of the direct CSS production/test/spec source-exclusion and rescan alarm; no replacement or current execution is claimed. Audit3752 independently approves audit3749: retire five authored/five finite watcher-process registrations, retaining18 raw-exact registrations. Accept loss of healthy shared-pool joint recovery, last-pending-failure idle retirement/respawn, late VITEST fallback release, missing-entry fail-closed selection and independent-supervisor fuse locality alarms. These are real bounded host-policy alarms intentionally retired for low marginal value; no equivalent replacement is asserted. Remaining driver selections exercise controlled FakeChild supervisor lifecycle, cancellation, physical-exit fencing, recovery and fuse behavior. This source review supplies no fresh native/process/platform/remote/SSH execution; historical receipts retain original source and selector scopes. Previous oracle (preserved verbatim): Audits3738/3742/3743/3744 intentionally remove15 authored/21 finite registrations from six surviving drivers, with no equivalent replacement or fresh execution claim. This gate retains an unfiltered root Vitest command. Current UNIT_INCLUDE admits the partial push-service, metadata-dialog and two config/scripts browser drivers:10 authored/16 finite removals. Accepted losses: actual retry30s/60s progression and register bucket/refill wiring, explicit seven-day lease arithmetic (its notification lacked seq/epoch and never reached send), equal-name edit latch/save payload, real image/font/meta-refresh/form/popup browser refusal controls, and broad rich-markdown bridge/command/edit-select smoke. Actual production state, callback routing and browser enforcement run in these cases; these alarms are deliberately retired on marginal value. All drivers and selectors survive. Existing unrelated receipts remain historical evidence for their unchanged selectors, not proof of the reduced cases. Audit3732 removes 2 authored/3 finite registrations from two partial suites: nominal custom/Kimi local naming success and deferred context usage row presentation. Real losses: custom/Kimi successful extraction through conversation-name sanitization and agentLabel composition; separate ordered counted/deferred lists and exact percentage/token formatting. No replacement or equivalent coverage claimed. Retain 11 authored/13 finite raw-exact registrations for bounded naming instruction/refusal/cancellation, menu dismissal focus ownership and hover/composer Escape/timer cleanup. Source-only bounded value review, no runtime/CI/native/remote/mobile/folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3733 removes2authored/2finite terminal input checks: fixed custom-cap error/secret fixture and three-emoji cap5refusal whose6UTF16units already trip length fast guard (no UTF8-dependent boundary). Accept exact non-disclosure/oversized-refusal alarm losses; no replacement/equivalence claim. Retain13/13scalar/pending input, OSC state and cron DST/cadence outcomes after bounded material reads. Source-only zero runtime/novelty credit; original historical reasons preserved. Previous oracle (preserved verbatim): Audit3729 removes1authored/3finite by deleting whole CLI runtime pairing advisory-close suite. Accept losing post-real-close injected EIO preservation of native/script/unreadable pairing, env identity/preservation and exact close/release assertions; no actual failed-close leak or replacement coverage claimed. Two retained URL grammar/identity suites11authored16finite raw unchanged. Bounded source/owner/caller value review, zero novelty/runtime credit; other seven3724deferred closures remain. Historical receipts preserve original limits. Previous oracle (preserved verbatim): Audit3724 removes3authored/3finite checks by deleting two whole suites: TUI clear burst-size singleton and terminal-file-URL target two-case wrapper suite. Deliberate losses: derived widest burst<64byte alarm, UNC authority+line-column anchor composition, and malformed-percent null refusal. Real production algorithms execute in those tests; no mocked-output tautology, equivalent replacement, actual Claude/file-navigation delivery or universal safety-irrelevance claim. TUI58byte bound and URI examples have low marginal value as standalone suites. Actual1262/1264/1742KEEP superseded explicitly. Remaining14drivers83authored136finite raw unchanged. Bounded source-only review; ten closures deferred, four bounded keep judgments repeated with zero new semantic-frontier credit. No runtime/CI/native/remote/mobile/folder/global completion claim; historical receipts retain original scope. Previous oracle (preserved verbatim): Audit3723 removes 4 authored/4 finite registrations in two whole suites: keybinding cache freeze/token spellings and host-dependent Orca command name examples. Real losses include returned-object freeze, repeated Mod+P key, Space/PageDown/NumpadSubtract mapping, unknown/empty/prototype-token rejection, and headless Linux versus Windows-server/WSL command choice. No equivalent or replacement coverage claimed. Retain 12 authored/21 finite raw-exact registrations exercising generated scaffold validation, artifact failures, shipped editor/hook/worker/panel tests, actual generated typing compilation, independent CLI root routing and intent-name precedence. Source-only bounded audit; no runtime, CI, native, remote, mobile, folder workspace or global completion credit. Previous oracle (preserved verbatim): Audit3720 removes17authored/23finite checks: whole main catalog-date adapter2 and shared date-helper7, seven renderer nominal ranking/cap/no-date/composition cases, and one browser registration expanding to seven forced-container/DOM-child boundary cases. Deliberate real losses: community oldest-date UTC forwarding, official/undated omission, date sorting/window/invalid/future/skew/clamp and default/override cap; nominal ranking/cap and combined Featured/Newly-added outputs; real CSS459/460,719/720,1055/1056breakpoint, five-card partial-row and720px two-card first-row alarms. Browser cases really measure rendered geometry but force width/remove DOM children; no fake-pixel or tautology rationale. No replacement/equivalent coverage claimed. Retain14authored/19finite raw-exact registrations across4drivers: adversarial featured category/order/tie and installability, date order/window selection, actual PluginManager failure/escaping/duplicate-card suppression, real browser viewport/odd-count geometry/phone catalog visibility, syntax ingress/depth/include/printability and68dlong-bracket auto-close fill-in. No tests/browser/native/UI/provider/remote/mobile/folder/CI/global execution or completion credit. Previous oracle (preserved verbatim): Audit3717 removes6 authored/6finite checks in two whole thin-adapter/presentation suites. Deliberate real losses: ordinary recipe repository-URL withholding and provisioned-root credential scrubbing/forwarding; repository label lockstep suffix expansion, host-scoped map identity/collision grouping, Windows crosshost paths and WSL distro suffixes. Actual provision options, label/sort consumers and host/scrubber delegates inspected; no replacement/equivalence claim. Retain40 authored/84finite registrations raw exact in14 drivers with bounded owner/context review. Prior KEEP superseded for removed suites; no runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3714 removes8 authored/39finite checks: whole CLI selector-recovery, task display-text and ANSI grammar suites plus two name joiner/blank tables. Deliberate real losses: selector flag/value/identity and mutation recovery merge/serialization; exact task suffix, transcript fallback, input immutability, cache reuse and edited blocks; independent failed-escape/resumption and OSC/DCS/BEL/ST/C1/nested/unfinished stripping outputs; meaningful-language joiner preservation and invisible/blank-name rejection. These are real bounded alarms, removed as narrow supplied-error examples, helper/token inventories and repeated internal-work fixtures. Prior2936,1195/1196,1214/1215 and1082 KEEP superseded; no replacement or equivalent coverage claimed. Keep9authored/9finite raw-exact registrations in5surviving drivers: screenshot export/failure filesystem behavior, CLI local tree query, event-local reply provenance, vault role-sensitive content and four hostile/UTF16/dangling/tag-name regressions. No native/UI/provider/remote/mobile/folder/runtime/CI/global completion credit. Previous oracle (preserved verbatim): Audit3711 retires2authored/4finite cases by deleting whole clipboard-image-temp-file signature-to-name inventory (HEIC/TIFF/unrecognised bytes) and workspace-last-active switch-on supplied visit/reason singleton, plus its now-orphan test fixture. This intentionally loses real generated-filename suffix/extensionless alarms and real newer-visit archived7day versus inactive30day filtering/older-visit identity alarms. Filesystem writing and production reason pruning really execute; no equivalent replacement or universal absence of safety relevance is claimed. The clipboard test does not inspect written bytes, native delivery or decode; the visit test supplies candidate/timestamps and does not exercise persisted visit routing or actual removal.20authored/20finite cases remain unchanged across4bounded Git/sidecar/removal drivers. No new runner/test/module evaluation or runtime result; historical notes and receipts remain historical. Previous oracle (preserved verbatim): Audit3707 removes10 authored/11finite checks: three whole renderer adapter/assembled-stage suites and two native projection cases. Deliberate losses: plugin URL/ref/default-version/local-path and unsafe credential refusal forwarding; real Task hook/store A→B→A late-save/list/count fences, owner disappearance, legacy-host convergence, query/history/eviction and same-ID host history; native child append ordered-ID/replacement and compound fallback/order/optimistic-admission/child-turn/duplicate/shrink/revision alarms. These are real bounded alarms; removal follows thin adapter, manually assembled Task pipeline and repetitive fixture value judgment, with no replacement or equivalent coverage claim. Prior1179/1182,1220/1221 and1885 KEEP superseded as applicable. Keep36 authored/38finite registrations raw exact across13 surviving drivers. No runtime/CI/provider/browser/native/mobile/remote/folder/global completion credit. Previous oracle (preserved verbatim): Audit3706 removes7authored/7potential cases from3renderer sources: whole usage-label3case and130000-distinct-day usage-overview singleton suites, plus3SSH grouping/ordinary-range examples. Retain11authored/11potential cases across6drivers in this bounded selection; no equivalent replacement or fresh runtime result. Existing bare root-unit commands admit this selection statically; prior command/receipt strings remain historical. Audit3706 intentionally retires first/second-order usage-group label collision alarms; equal50%-weekly bucket versus derived-weekly selection identity and Gemini wk label alarm;130000distinct-day aggregation no-spread-crash/max/intensity alarm; legacy absent-source SSH grouping and ordinary reverse-select/selected-target deselect range alarms. Actual label ambiguity and pathological-input crash are accepted losses. Distinct-day fixture spans~356years; no hard producer/date bound is claimed. Retained filtered-anchor/grouped-order guards do not replace removed deselection/reverse-range/legacy-group coverage. No native SSH, mounted renderer, live provider, remote/folder/mobile end-to-end or current runtime pass was obtained. Previous oracle (preserved verbatim): Audit3699 removes4 authored/4finite checks, including one whole xterm copy-policy suite and one root/group CLI help case. Deliberate losses: direct copy-chord admission for platform, selection, Kitty mode, defaultPrevented, logical/physical key and key phase; command-group disclosure and group help routing including claude-teams early return without RuntimeClient construction. These are real bounded policy/wiring alarms; no replacement or equivalent coverage claimed. Retain14 authored/19finite raw-exact registrations across6 drivers: unsafe CLI refusal, Claude model event carry and disk reconstruction/OSC-first case, attachment ownership/upload lifetime and mixed BMP file-reference/PNG-chip delivery, actual SQLite authority/admission/mutation, and Electron geometry/hit-testing. No runtime, CI, native-key delivery, external provider, mobile, remote, folder or global completion credit. Previous oracle (preserved verbatim): Audit3692 removes5 authored/5finite marginal Codex checks: unrelated login URL without notice; ordinary per-account launch resource/config materialization; no-retained-pane skip; preservation of a previously owed full scan through actual preparation and pending-marker update (no actual history scan/settlement); ordinary later-config refresh. Accept these exact branch/wiring alarms as deliberate losses without replacement. Retain32 authored/34finite raw callbacks/registrations/table bytes exact across14suites, including credential/admission refusal, grace/reset readiness, filesystem ownership, commit-dependent queue state, streaming/host trust, path canonicalization and private-state preservation. All14whole suites challenged without keeper quota; no whole deletion warranted on current concrete signals. No runtime/CI/native WSL/remote/mobile/folder/global completion credit Previous oracle (preserved verbatim): Audit3691 removes two complete runtime-home routing singleton suites (2 authored/2 finite): catalog wrapper mirror login-copy and passive transcript-lookup filesystem noncreation. Exact accepted losses are recorded in knownGaps; no replacement or equivalent coverage claimed. Audit3691: no dedicated alarm remains in the deleted sources for post-launch system login import through prepareHostCodexHomeForReadOnlyAppServer, or for repeated missing-transcript lookups leaving removed Codex account/runtime directories absent and userData entries unchanged. Ownership-marker read avoidance was never independently measured. No real catalog probe, provider, native Windows or crash was validated by those fixtures. Previous oracle (preserved verbatim): Audit3686 current Claude profile/account review removes5 authored/5 finite cases: whole structured-auth diagnostic-label suite3 and Windows-only command suite1 whose advertised cache alarm is ineffective because cache lifetime is per invocation; remove duplicate setup namespace-link refusal1 at wrapper layer. All5 exact historical KEEP are consciously superseded. Retain49 authored/50 finite unchanged, including filesystem privacy/recovery, route identity and concurrency, built worker/helper, legacy WSL alias compatibility and sign-in handoff. These are deliberate coverage losses without replacement. No runtime/CI/native WSL/macOS Keychain, remote/mobile/folder or global completion credit. Explicit accepted real losses: unknown-account host fallback and mixed-version/WSL-only structured auth diagnostic labels; Windows-only sentinel ENOENT-to-friendly-error translation plus fresh-call successful dispatch smoke; setup catch-to-refused wrapper and no-write outcome for a namespace symlink. The command case does not discriminate removal of its per-invocation noncache guard; it still supplies the error-translation alarm, which is intentionally retired. No replacement/equivalence promise. Previous oracle (preserved verbatim): Audit3680 removes eleven authored/eleven finite unit cases across four files, including entire launch setup row projection, structured legacy-model metadata, and legacy classifier suites. Accept loss of exact row partition/start selection, Codex supersession/default/unknown and Claude alias/suffix folding examples, other-agent exemption, getter/cache read budgets, same-array per-agent cache isolation, replaced-catalog metadata, and tracked-only model exclusion from structured and PTY legacy inventories. These are real narrow policy/metadata alarms intentionally retired without equivalent replacements. Retain real menu collapse/reopen in dropdown/select, AI picker cancel/accept and stale-effort filing, IME carry/gesture/frame transitions, and typed-flip versus held-dispatch fencing. No production or shared fixtures change. No dead timing entry exists for the three deleted drivers; retained timing keys stay unchanged. Static source-value review only; no project import, test runner, native/app execution or runtime validation established. Earlier receipts retain historical scope. Previous oracle (preserved verbatim): Audit3678 current-source reassessment removes20 authored/24 finite root-unit cases across7 retained test sources; all10 selected current drivers80 authored/93 finite were read, leaving60 authored/69 finite unchanged. Removed alarms are the in-memory WAL PRAGMA constant, ordinary latest-dispatch/gate-creation inventories, self-reported-failure and explicit-terminal retry policy rows, SSH/unsupported-provider output fallback labels, legacy typing no-op/retain-before-report/manual scheduling rows, exited output status and copied resume-session metadata, incomplete inventory deferral/reset cascade inventory, and nominal release/active-state/corrupt external history/stopped-abandoned outcome/generic close-exception rows. These are intentional coverage losses, not replaced alarms. Retained source includes actual SQLite rollback/custody, mutable transcript/deletion and saved-copy compatibility, cursor mutation, clear lineage, auto-release timing/restart/admission and concurrent recovery seams. Historical KEEP decisions are consciously superseded where stated in decisions.json. Source-only evidence; no runtime, CI, native, provider, remote, mobile/folder or global completion credit. Previous oracle (preserved verbatim): Audit3672 renewed by3676 removes four authored/four finite cases from federation-output.test.ts: nominal show/read routing and terminal-fallback projection; initial archive-table SELECT failure returning retained/no-close; simulated old-peer read/fleet/refusal and method inventory; and absent archive-release capability refusing release. These actual compatibility/guard alarms are intentionally lost without equivalent replacement; the dropped-table case never reaches capture or commit. Current selected frontier9 becomes5: retain actual temporary transcript parsing/path omission, current no-transcript release/unavailable-output/restart/replay regression, and three home deadline/stop nonmutation cases. Prior held-capture case was already removed upstream and receives no new removal credit; prior redacted snapshot archive behavior was rewritten upstream and is not claimed retained here. The surviving driver timing entry stays. Static review/private composition only; no actual peer/network/native/platform or fresh runtime validation. Previous oracle (preserved verbatim): Audit3671 removes14 authored/32 finite root-unit cases, including the whole WSL move-handler refusal suite, WSL preload object-presence suite and internal gate spelling truth table. Also retire the weak withheld-command non-array shape assertion, static serve-only Add/capability/mock-remove example, grammar scope equality and basic configuration/payload schema roundtrips. Genuine wrong-window/malformed-request/gate-before-work, exact gate spellings/platform/argv precedence, static serve-only routing, declaration mismatch and empty grammar/pair admission alarms are consciously lost without replacement; prior KEEP decisions are reconsidered. Seven unchanged authored/finite root-unit cases retain real image/provider/line budgets, live policy transition/capability broadcast, grammar resource/reference traversal and strict-versus-tolerant literal salvage. Source-value evidence only; no runner/compiler/build/app/native/provider/remote/mobile/folder validation or historical fault claim. Previous oracle (preserved verbatim): Audit3663 renews approved3644/3645/3648/amended3651 at privatec1ef: remove10authored/26finite across7changedtestpaths,4whole drivers; retain23authored/24finite including actualcmdkStrictMode defaultcursor race. Retire version1.5.0/1.5.1→shrinksImages capability threshold and launch-to-prompt wiring alarm. Surviving prompt tests explicitly supply capability and do not replace wiring coverage. Retire resolved-before-personOnly precedence; hook-gone/live-dialog guidance; stale-incarnation versus live-looking dialog classification; delayed/clipped warning extraction and wait-for-paint wiring; 3row setting/personOnly approve/deny/disclaimer suggestion composition;13row setting/reason/person/coordinator admission, close/mail attribution, terminal delivery/refusal/preanswered/personOnly/dropped-allow handler propagation alarms. Real state/access/SQLite effects occur; these genuine losses are accepted, not mocked-away. Retire full command extraction from serialized JSON in worker receipt and nontruncation alarm; no rendering, actual worker approval or native shell proof. Retire2row extra-source first/last order and controlled default cursor projection, plus generic open-palette livefolder add/remove render alarm. Explicitly supersede rawexact297KEEP refresh. Keep actualcmdk/StrictMode default cursor race driver; no default-suite loss claim. No equivalent replacement asserted. Retained queue/commit/retryownership/filebudget, terminalfreshness/provenance/competing-answer, RPC DB-effect, qualifiedfolder/runtimehandoff and lingering-reopen cases have distinct scope. Audit3675 preserves the upstream revised unreported-approval close regression, its escalation helper and adapted survivors. Source-only static renewal; no runner/compiler/app/native/remote/CI claim. Upstream41390host-owned approvalwatch/report lifetime reviewed separately; no new lifetime test removed. Preserve all earlier metadata/evidence. Audit3634: Remove five authored/five finite cases, including the complete structured chat terminal-refusal, terminal-plus-agent worker-start validation, and canonical Git common-directory parser suites. Also remove the gh free-text -R argument projection case. Consciously supersede prior KEEP decisions and accept chat-versus-stale redirect classification, real RPC refusal-before-SQLite-Dispatch, old-Git echoed-option relative-path parsing, WSL execution-space resolution, and free-text preservation/bare-repo qualification alarms. These are genuine narrow alarms, intentionally retired without equivalent replacements. Retain real Git stdin/EOF delivery, bound-account host admission, naming environment/account precedence, upload iterator cancellation and remote path confinement. Shared fixtures and production code remain. Remove only the dead canonical-repo-key timing entry. Static source-value evidence only; all prior evidence retains historical scope. Audit3636: Remove the entire maintenance opportunity internal-count driver (one authored/two finite cases), the mocked remote worker start-card argument case (one/one), and the follow-up heading mapping table (one/two). Root-unit discovery loses three authored/five finite cases. Independently remove four Python native screenshot methods/five statically enumerated subTest scenarios: grim argv/stub payload, failure-code mapping, X11 mocked capture payload, and capability flags. The Python lane is verify:computer-native and is not root Vitest. Accept loss of exact native command/projection and exception/capability alarms, ready-only card publication arguments/agent forwarding, and serialized follow-up heading mapping; no equivalent replacement is claimed. Retain actual ownership/mail/queue/reopen transitions, remote lost-response fencing and first-result settlement, filesystem/maintenance admission and successor progress, wrong-region screenshot refusal and Sway geometry. The whole-deleted new driver has no timing key; this component requires no timing cleanup. No production changes. Static source-value review only; no project import, runner, app, native desktop or runtime validation established. All prior evidence retains historical scope. Audit3629 removes two singleton parser suites: WSL Claude plugin metadata out-of-range index rejection and Git checkout unlink-warning path extraction. Their real range-refusal and quoted-path extraction alarms are intentionally lost without replacement; no WSL execution, checkout recovery or equivalent remaining coverage is claimed. Audit3630 removes the sole orphan automation availability test (1 authored/1 finite). Its real policy kind, orphan precondition, delete/toggle enablement and run/edit refusal alarms are intentionally lost. The test did not dispatch an action, enforce a server generation fence or observe a remote mutation. No equivalent replacement, actual renderer/transport execution or new platform/provider evidence is claimed. Previous account (preserved verbatim): Audit3628: remove the entire one-authored/one-finite RepositoryRemoveProjectSection happy-dom suite. Accept losing the local zero-to-one-terminal stale-count revalidation alarm: first confirmation defers the removal callback and second confirmation invokes it after the count snapshot updates. The test never asserts updated warning text/count, actual terminal creation or removal/PTY teardown, host/scope routing, cancellation or folder/mobile behavior. No equivalent replacement or end-to-end warning-before-teardown proof asserted. Static evidence only; historical receipts retain original scope. Audit3624: Remove one authored/five finite positive Gemini identity table from the Claude/Gemini title collision driver. The real normalization, legacy label and explicit title evidence owners execute, so ordinary Gemini marker/name/wrapper recognition and normalized-label composition alarms are consciously retired without equivalent replacement; these five supplied title-to-literal identity examples have low marginal value. Preserve the six-row Claude task-text collision oracle, whose unrelated CLI mentions must not rebrand or destructively normalize titles. The other audited drivers preserve real permission-mode session transitions, prompt secret/fence/bounds defenses, JSON-to-Ask option/preview preservation, and optional GitLab failure summary/trace composition. Root-unit discovery loses one authored/five finite cases; no whole driver or timing key is removed. No actual terminal stream, UI routing, application/native or runtime execution established; all prior evidence retains historical scope. Audit3618: Remove three authored/three finite browser reload cases, including the complete renderer reload-actions suite. Agent bridge fake did-fail-load plus permanently supplied manager error projects description/code into a rejection. Renderer seeded empty metadata projects a saved URL into plain webview src; its earlier not-ready case projects a live-id/throwing fake reload into absence of a loading patch. Real queue/wait/error/cache/classifier/hook code executes, but these narrow supplied-state and exception-to-callback wirings have low marginal value; no rerender, lifecycle, actual cache generation/retirement or guest commit is asserted. Explicitly supersede audit1822 not-ready KEEP and preliminary3617 cross-module retain opinion, accepting offline-reload failure reporting, empty guest to saved URL routing, native-reload bypass and premature-loading/stranded-state alarms without replacement. Retain distinct main cancellation queue progression and absent queued side-effect dispatch. Root-unit discovery loses three/three. No Electron guest, network failure, restored navigation/commit, app/native focus or runtime execution established; earlier evidence retains its historical scope. Audit3614: Remove thirty-one authored/thirty-nine finite potential cases across CLI format and argument drivers, including three whole suites: search-result/status sanitation sites, Linear issue/list/warning sanitation sites, and quote-stripped JSON diagnostic secret non-echo. Those real formatter/guard transformations execute on supplied strings; intentionally retire their field-specific CSI/OSC/C1/newline/bell and diagnostic secrecy alarms as low-value caller/output inventories, without replacement. Also retire twenty-one search registrations/twenty-four finite cases covering minimal positional request/default omission, exhaustive all-flags request projection, nominal named query/index routes, repeated syntax/agent examples, enum/agent/path-count/timestamp/numeric/cursor admission examples, unknown/browser flag examples and postcommand last-wins projections; retire one parser sentinel-only case. Keep actual ambiguity, conflicting index request, precommand/crosscommand scoping, variadic reference parsing and missing-repeatable-value controls, without claiming equivalent coverage. Root-unit discovery loses all twenty-nine/thirty-seven. No CLI/RPC/terminal/PowerShell/host/schema/runtime execution is established by this source-only audit; earlier evidence retains its historical scope. Audit3613: remove six authored/six finite callbacks, including whole reviewer-display oversize-input and explorer-root record-filter suites, plus plugin family-emoji/invisible-only-name and pool legacy-name/urgent-countdown samples. Accept losing oversized-input empty-result/no-split, malformed-record/prototype-sensitive-key/nonstring filtering, exact ZWJ family preservation, invisible-only name refusal, no-group old-host full-name preservation, and80/79/null-reset countdown composition alarms. No equivalent replacement asserted. Retained strict/runtime sanitization, SVG parser, mobile focus recovery and collision/tie cases have different scopes. Static evidence only; historical receipts retain original scope. Audit3609: Remove the complete pnpm CLI invocation literal-selection suite (eleven authored/nineteen finite potential cases), with no replacement claimed. Root-unit discovery loses JavaScript-versus-native command selection, npm/npx executable rejection, Windows cmd/bat casing and shell selection, non-Windows cmd behavior, native PNPM_HOME flat/bin preference, explicit-path priority, relative-home rejection, missing-native fallback and non-Windows home-probe refusal alarms. The suite called the real resolver with independently expected objects, but exercised no pnpm/node/cmd process, installed native executable or real filesystem probe. Earlier KEEP decisions are consciously superseded by accepting these narrow branch and probe-inventory alarms as low value. Real symlink entry, Git signing isolation, Bun filesystem/Node child normalization and compiler scheduling/continuation tests remain distinct tests, not equivalent coverage. No runner, compiler, app, platform or remote execution was performed in this source-only audit. Earlier evidence retains its historical scope. Audit3608: remove five authored/five finite callbacks, including whole owner-slug and remote favicon URL suites and two repository-label projections. Lose five owner acceptance samples, eleven negative owner samples plus nonstring refusal, six host-local icon refusal samples, legacy-SSH same-path label-map cardinality, and explicit runtime ownership over stale legacy metadata at label level. These are accepted narrow grammar/presentation alarms with no equivalent replacement claimed. Retained binary parser, React recovery and label grouping/platform cases do not replace these losses. Static evidence only; historical receipts retain their original scope. Audit3606 adopts the enhanced3604/3605 icon cuts: nine authored/nine finite cases removed, including the whole tray-attention-icon suite. Retires the no-encoder oversized-upload null sample, missing-ID/request-order sample, encoder-null PNG-prefix fallback, SVG/404 rejection samples, transparent amber-dot placement and half-alpha white-tint sample, exact small fetched-byte passthrough, host-qualified image-key inventory and constant-encoder large-upload projection. These specific admission, formatting and bitmap alarms are intentionally lost without equivalent replacements. Retained queue/cache, bounded fetch and Dock lifecycle checks do not establish actual raster decoding, native image conversion or rendered appearance. Historical receipts below are preserved evidence for earlier test sets, not fresh validation of this reduced selection. Audit3601 scope: remove the whole custom-sound happy-path IPC suite and one custom-label/multiline notification formatting example (2 authored/2 finite). Intentionally lose configured .ogg selection, exact byte/MIME success wiring, successful dispatch for the formatting fixture, custom-label whitespace/title normalization and assistant-body whitespace/180-character-cap alarms. Retain prompt-exclusion, persisted qualified dismissal/restart, theme ownership/restore and Ghostty precedence/collision cases; none replaces the retired sound/formatting alarms. No actual playback, native delivery, phone/network, cross-platform or new runtime evidence is claimed; historical execution keeps its original scope. Audit3598: Remove seven authored/nine finite literal-table potential test registrations across workflow routing, Claude cold-start and real-zsh preexec drivers. Root-unit discovery loses six authored/six finite: three test-local workflow parser fixtures, the five-positive/three-negative explicit command-paint route inventory, a boot-banner-before-composer sample and an already-painted bare-title positive sample. The separately selected shell_contracts live-shell driver loses one authored/three finite raw-capture paint-only cases across three hook configurations; its real-wrapper launch-order, four rechunkings (twelve finite) and runtime-wait replay remain, without claiming equivalent replacement. Intentionally lose those parser, exact routing-list, banner, post-paint subscription and native-read-boundary paint alarms. Retained workflow/UNIT_EXCLUDE/classifier cross-source routing checks and readiness-race-to-writer timing are distinct bounded alarms. No runner, real shell, PTY, app, native focus, remote delivery, cross-platform execution or full-feature correctness is established by this source-only audit. Earlier evidence retains its historical scope. Audit3597 scope: remove two renderer-hang-capture examples (2 authored/2 finite): an invalid repeated-token oversized reducer fixture and a shorter unanswered-request fixture. Intentionally lose the direct truncated flag/sanitized frame fixture and request-pending status/zero-sample alarms. Retain window-death/stale-result exclusion, generation reconciliation, and baseline-publication cancellation lifecycles; they are not equivalent bound, redaction or pending-status replacements. Historical execution retains its original source scope; no new runtime evidence is claimed. Audit3591: Retire the whole one-case background journal-producer attribution suite and the fabricated malformed-details-block case (two authored/two finite cases). Intentionally lose the fixed own-task versus output/foreign-task attribution examples across flat/message row shapes, missing-root classification, and direct unbalanced/detailsish fabricated-block rejection alarms. Retained parser sibling/depth and editor navigation tests do not replace these alarms. No equivalent replacement or fresh runtime, transport, persistence, native focus or rendered UI validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3592: Retire the whole three-case shared agent smart-key resolver suite, explicitly superseding its Audit3238/3237 keep decisions. Intentionally lose literal permission-versus-question classification, longest-question digit selection, Codex async-question opener/digit/Enter/skip mapping, and unsupported-agent/state/prompt refusal examples. These were real parser/selection and literal-byte alarms; they did not exercise terminal delivery or timing. No equivalent replacement or fresh runtime, native TUI, mobile, remote or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3587/3588: Retire six authored/fourteen finite cases, including the whole WSL stopped-notice and connecting-status selector suites. Intentionally lose direct WSL retry connection field/target/ready-epoch/null-guard examples, connecting/reconnecting distro and absent-state selector samples, and stopped/connecting notice text/button/data-attribute examples. Retained host-ready retry and content-loader/reload lifecycles do not replace these alarms. No equivalent replacement or fresh runtime, native WSL, remote, rendered UI or performance validation is claimed. Earlier dated text and evidence retain their historical scopes. Audit3580: Retire the whole one-case runtime host environment prototype/subclass suite. Intentionally lose the exact configured lower-case Windows Claude home to account-identity normalization and host-account override precedence alarm previously retained by Audit3129. No equivalent replacement or fresh runtime validation is claimed. Earlier dated keep statements below describe their historical source scope; the current suite is removed. Audit3563 scope: retire the whole Kiro OSC/hook identity suite and the OpenCode2 identity-only case; reduce Codex cached startup child-retirement and missing-session-ID tables to one case each (2 authored/4 finite removals). Intentionally lose Kiro alias/session continuity, OpenCode2 completed OSC identity continuity, cached replacement without relay-generation restart, and missing-previous-ID context-preservation alarms. Remaining provider, remote compatibility, persistence and cross-session pollution cases are not equivalent replacements. Also remove the private Codex roster-size assertion while retaining public child-absence checks. Historical evidence retains its original source scope; no new execution or transferred pass validates these reductions. Audit3553/3559 current scope: delete worktrees-delete-pty-teardown.test.ts and worktrees-issue-command-overrides.test.ts entirely and remove three cases from worktrees-orphan-directory-cleanup.test.ts (6 authored/6 finite removals). Intentionally retire typed unserved-SSH create/delete admission, exact-name collision/error-token, proven-orphan no-force confirmation, standalone .git-directory refusal, and SSH-owned local-path preservation alarms. Retain only actual authorized orphan deletion and no-marker notes-file preservation; they are not equivalent replacements. The no-marker fixture resolves the default getRepos owner, so it does not prove temporary owner-repo binding. Git/Store/PTY/notifications are mocked; no physical process stop, durable metadata, real SSH delivery or native UI proof is claimed. Unchanged historical oracle, coverage, evidenceRuns and escaped receipts retain their original scopes only; no fresh execution or transferred pass validates the reduced sources. Audit3492 composes ROOT-approved75(AUTHOR3475/PEER3476 and AUTHOR3485/PEER3481, including five-field clarification and zero-credit selector3483) plus123(AUTHOR3486/PEER3487 reconciled FINAL3491, including peer case10:3 and9:0 wording clarifications). It intentionally removes198 authored registrations/232 finite literal-table potential registrations across70 changed JS/TS test sources, including45 whole suites;87 authored/90 finite potential registrations remain across95 reviewed JS/TS bodies. One mobile native-suspension manual recipe and the now-unreferenced GitLab mock fixture helper are separately removed with zero registration credit. Static literal table potential is not execution. No equivalent replacement, fresh runtime result or merge credit is claimed. Earlier135 complete dated receipts, all raw gaps and full prior98/161/history notes retain their exact scopes and bytes. The additional123 retirement accepts loss of mocked GitLab request/error/identity/classification inventories; basic Linear migration and metadata discovery; simulated OpenCode key failed-save retention/retry/log redaction; analytics identity-flush smoke that did not prove ordering; AppImage static entry guards and empty-staging cleanup; GPU/process/minidump breadcrumb/annotation shapes and weak redaction oracles; namespace/status/foreign-launcher ownership guards and persistence roundtrips; profile transfer field projections; worker hook/screen/incarnation/result admission/classification guards; and source-coupled CLI transaction fixtures. Privileged publication failure injection was a false-positive: its mkdir regex missed -m 700 and outer rejection accepted an inner assertion before any shell ran. The identity-flush case awaited identity after flush and could pass despite early flush. Retained actual negative-token cache recovery, SQL filter-before-LIMIT open approval, unreadable-root FTS preservation/degradation, latest-connect-wins persistence, worker stop-debt settlement, unmodified same-inode foreign-content transaction, explicit incomplete-pagination error, FTS own-message snippet association, filter-before-route result and bounded-search truncation honesty are distinct bounded outcomes, not replacements for retired alarms. Case9:0 checks both roots before chmod but only mounted-session/degraded-root after chmod. Entire extraction-root suite is removed; no retained extraction cleanup is claimed. Removing the manual iOS foreground-stall shell script loses its unique real native-suspension recipe; timer tests do not replace it. First-match PIDs, indefinite waiting, broad success matching and absent trap cleanup made that diagnostic brittle and able to leave a desktop stopped. The current Windows operational driver remains byte-exact, preserving already-merged removal of orcad-convert and orcad-cli-convert selectors and the retained cmd/powershell/managed CLI lanes. The package skill-sharing release selector loses only the exact already-retired skills-suite token; no extra test credit. Included approved75 retirement account follows (historical proposal labels identify provenance; final198 counts above control): Audit3488 composes ROOT-approved source49(AUTHOR3485/PEER3481, including its immutable five-field clarification) and source26(AUTHOR3475/PEER3476): intentionally removes75 authored registrations/87 finite potential registrations across35 changed sources, including25 whole suites;35 authored/36 finite potential registrations remain in the combined reviewed scopes. Literal table potential counts are not executions. This source-only reduction has no equivalent replacement, fresh runtime result or merge credit. Root unit discovery deliberately loses entire message-row filtering/chunk reconstruction, discussion-pagination rejection passthrough, Linear bearer/stack redaction, new-profile telemetry/default/existing-JSON no-op, WSL user-trigger routing, terminal-delivery refusal, native-chat worker-approval UI, followup-paste routing, live-surface tombstone refusal, activity-bar hydration, fabricated approval-caller policy, child-PATH transformation and branch-review URL/identity suites. It also loses cache roundtrip/mode/fingerprint/fallback/no-op samples; GPU field-shape privacy examples; older auth-probe failure retention; orphan SQLite-sidecar/future-schema admission; usage tie/duplicate/composite-key examples; allocation-name sanitizer/unknown-prefix examples; real worker-and-backup preflight wrapper smoke; and JSONL descriptor-loop truncation. The discussion page contained id-only discussions without notes, so its rejection did not prove a nonempty notes-prefix oracle. The preflight did launch actual worker/backup entrypoints with production internal self-validation; removing its revision/version wrapper deliberately retires that real-entry smoke alarm. The skipped-prefix JSONL keeper rewrites/grows after collecting the suffix and before final validation, not concurrently during parsing. Retained queue rejection/recovery and held/drain mechanisms, recorder nonsettling-provider deadline, corrupt authoritative-DB refusal, legacy cache split migration, merge-added-row indexing, external-frame redaction, and pinned JSONL read/verification/mutation checks are bounded concrete oracles, not equivalent replacements for retired alarms. The full cloud relay cohort/ceiling/control suite is separately removed from the relay package runner, outside root unit discovery; no cloud runtime result is claimed. The Python computer-use benchmark remains unchanged tooling with zero authored/removal credit; no native benchmark trial ran. The package skill-sharing release selector drops only the exact already-deleted skills-suite token, with zero additional removal credit. Prior dated receipts, raw gaps, and complete earlier161/98/history notes remain exactly at their original scopes; no changed-source historical receipt becomes fresh reduced-suite evidence. Included approved26 alarm account: Broad root-unit discovery loses entire ref-label string, hostile/malformed CSV-link rendering, Codex filename-discovery, mocked paged-preview postscan mutation, usage path-containment, real symlink-ancestor, Codex skip RPC, local/remote inference routing, width-preference, and synthetic workspace-document input suites. It also loses the hand-assembled sorted CSV edit example, connect-time JPEG seed and invalid AVCC guard samples, and eight-record/64KiB detector boundary cases. The symlink suite exercised actual kernel traversal; its lost ancestor alarm could omit supplemental local editor watches and leave content stale, not bypass authorization. Retained linked stream cancellation, preview-only save fence, failed-flush dirty-draft preservation, clipboard byte/edit preservation, fragmented AVCC parsing and independent quoted-CSV interpretation checks do not replace these deliberately retired alarms. The stream fixture uses an in-memory source and does not establish actual fd cleanup; editor save endpoints are synthetic, browser events are synthetic, and no native focus, actual remote delivery, real disk write, cross-platform execution or interoperability is claimed. Earlier complete dated receipts, raw known gaps and previous notes are historical evidence at their original source/selector scope, not fresh evidence for this reduced suite. Audit3438 composes ROOT-adopted3434/independent3436: intentionally removes60 authored/62 potential expanded cases across16 sources, deleting9 whole suites. Eight authored/eight potential cases remain; delete the102line unused ACP fixture and57line unused teardown helper with zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses ACP model-catalog fixtures, resume-record projections, dashboard mock payload/state cases, mobile folder/launch/session examples and dictionary pipeline rows. Selected E2E removals also retire auto-conversion and golden-core journeys and one Windows CLI conversion registration. Retain ACP reply text across a resumed subagent, both VAD checks, focused tab send ownership, async focus ownership in happy-dom, the question-skip journey, the original managed Windows CLI lifecycle journey and dictionary substitution. These checks do not replace the removed alarms. Audit3470 composes ROOT-approved AUTHOR3466/PEER3467 source proposal: intentionally removes38 authored registrations/59 finite potential expansions, including8 whole registering suites, retaining13 authored registrations/18 finite potential expansions. The sole dead shell-recipe caller cleanup has zero additional test credit. No equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses process-import boundary, Korean/Japanese locale policy, worker-reset, mobile agent-history/queued-message and median-summary suites, plus packaged mobile-manifest, worker-pool fixture, HTML preview, mobile shell and terminal samples. The environment-provider contract and its sole shell-recipe caller are deleted. Separate cross-version-wire discovery loses the large byte-budget fresh-snapshot/replay sample while retaining independent live same-revision note publication; the retained terminal stale-refresh and dirty HTML draft persistence checks do not replace removed alarms. The source4 unused start/stop fixture hooks are removed; its retained nested failed-import test remains byte-exact with its own lifecycle. Unchanged SVG preview and Git-resolution registrations stay intact. Root balanced CI excludes the cross-version directory, which has a separate job; unbalanced root discovery can include its parent. No native app/device, actual remote, released-pair interoperability or cross-platform execution result is claimed. Audit3468 accepted source proposal AUTHOR3462/PEER3463, composed privately by audit3469: removes62 authored registrations/95 finite potential expansions, including5 whole suites, retaining25 authored registrations/29 finite potential expansions. ROOT approved source value; no equivalent replacement, fresh runtime or merge credit is claimed. Broad root-unit discovery loses the profile-state worker smoke, worker-agent views and three search discovery suites, plus samples from node-server qualification, skill-bundle generation, CLI hooks/profile/recovery/offline admission, permission-hook holds and search indexing. The separate Cloud relay runner loses one relay blackbox sample; unchanged mobile native-chat and dependent-transcript drivers remain. Retained source callback/table/ancestor/fixture bytes bind to the sealed candidate. No physical-device, mixed-version, remote, cross-platform or app execution result is claimed. Audit3460 final-v2 composes accepted AUTHOR3454/PEER3455 on actual post263 main: intentionally removes99 authored/106 potential expanded cases across16 selected drivers, including7 whole suites, retaining24 authored/26 potential cases. No equivalent replacement or fresh runtime is claimed. Broad root-unit discovery loses whole cross-client workspace-sync, terminal-preview, picker-skill-hint and close-routing suites plus reduced worker-stop, remote-owned-record, scanner, mobile-bundle and daemon-health samples. Separate E2E discovery also loses the paired mobile/desktop mirror journey and two unit drivers. Retained callback/table/outer-loop/guard bytes are exact; retained checks do not replace the removed alarms. No app, native device, mixed-version, remote or cross-platform execution result is claimed. Audit3456 composes ROOT-adopted3449/independent3450: intentionally removes62 authored/82 potential expanded cases from16 selected drivers, including7 whole suites, while13 authored/13 potential cases remain. Delete the unused48line legacy workspace-session JSON fixture with zero test credit. These are source-only reductions without equivalent replacement or fresh runtime claims. Broad unit discovery intentionally loses whole trust-dialog observer, background-turn notifications, redirected session refusal, typed-agent identity, chat-tab lifetime-cost, model-manager and mobile diff-review controller suites, plus individual persistence, synthetic composition, pairing, manifest and subprocess samples. Retain deferred snapshot dirty-domain persistence, two direct editor ownership cases, stream counter-domain distinction, two persisted pairing identity cases, parser entrypoint asymmetry, dictation retry and process-group timeout; paired restart and packaged old-binary/corrupt-profile journeys remain in their E2E driver scope. Retained checks do not replace removed alarms. No fresh execution, native IME/microphone, real authentication, mixed-version/platform or performance result is claimed. Audit3451 composes ROOT-adopted3444/independent3445: intentionally removes101 authored registrations across16 reviewed sources, deleting7 whole suites and reducing8; one reviewed source is unchanged. Fresh main has123 authored registrations before and22 after because an upstream direct-child shell regression remains verbatim with zero removal credit. Registered removals are100+7*S and explicit-active removals99+7*S, where S is the unprobed count0..3 of admitted bash/zsh/fish shells. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses extra stream lifecycle/forwarding examples, unreadable-store/cache projections, orchestration presentation/benchmark cases, remote-owned routing matrices, mobile legacy navigation and model-catalog listing/cache examples. Whole suites retire renderer client-event projections, manually assembled structured-session reader ownership, mobile prompt presentation, renderer AI-vault resume commands, mobile Jira URL lookup, composer retention and mobile folder source-repository queries. Retained checks preserve original stream/store/orchestration/routing/navigation/catalog cases and shell behavior, including the upstream direct-child case. No real provider, native desktop or mobile acceptance is established by this reduction. Audit3446 composes ROOT-adopted3441/independent3442: intentionally removes100 authored registrations/119 potential expanded cases (118 conditional-active before platform gates) across16 sources, retaining11 authored/13 expanded cases and deleting6 whole suites. Two parent registrar import/call cleanups and the unused68line CLI recording fixture carry zero test credit. No equivalent replacement or fresh execution is claimed. Broad unit and mobile discovery loses interrupt/wake registrars, task storage/session-close/account snapshot hooks, permission tables, copy/preference/model-discovery/composer examples, launch placement examples, VM projections and extra mobile-history scenarios. Retained checks cover abandoned versus dispatched fork uncertainty; /fast dispatch supersession; discovery lock release after exit; stale-send draft preservation; OSC status lifetime; future-version file preservation; launch cancellation before/during dispatch on both layout owners; mobile resume addressability before hooks; and recipe snapshot cleanup after plugin removal. The paired browser-link Electron source is unchanged. Terminal launch seams, mobile roles-only history and injected provider results do not establish native terminal destruction, transcript text fidelity or real remote provider cleanup. Audit3437 composes ROOT-adopted3431/independent3432: intentionally removes127 authored/174 potential expanded cases across12 sources, deleting7 whole suites and one267line unused helper without test credit. Retain8 authored/13 potential cases. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses reduced or deleted relay, coordinator mail, recovery watchdog, automation observer, launch picker, folder PTY, profile restart, web migration, retirement, pointer delivery, agent-row and run-bound mailbox examples. Retained checks cover relay hello/payload and SIGTERM drain, coordinator pending-check and clear-to-Run continuity, profile persistence, the full six-row web merge table and real run-bound delivery waiter. These do not replace removed alarms. Audit3429 composes root-adopted3426/independent3427: intentionally removes168 authored/205 potential expanded cases across16 semantic sources, deleting11 whole suites and one304line unused assertion helper. Five authored/five potential cases remain; the duplicate500k graph row is dropped while its50k row and callback remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted migration/recovery/federation/rich-draft/paste/automation/mobile/catalog examples. Keep server-edit preservation during migration, native supervised cancellation holding the agent home until physical stop, pagehide lost-text preservation, graph old-result WRAPPER WeakRef collection with50k rows, and mobile React render isolation. The WeakRef does not prove all commit objects are collectible or a memory budget. Audit3425 composes root-adopted3420/independent3421: intentionally removes83 authored/112 potential expanded registrations across13 semantic sources, deleting7 whole conventional suites and1 registering helper;7 authored/10 potential expanded cases remain. No equivalent replacement or fresh execution is claimed. Broad unit discovery loses the adopted mock orchestration, refusal, restart and storage examples. Retain unchanged two-phase real-WSL deployment/survival, the reduced idle-release holder proof without restart/first-output measurement, real worker stop/release cleanup barrier rows, physical Git branch-preservation rows, and SSH disconnected-close proof. Other SSH and CLI variants and WSL telemetry/warmup churn are intentionally removed. Audit3417 composes root-adopted3415v2/independent3416v2: intentionally removes117authored/173potential expanded registrations from12semantic sources, deleting4whole conventional suites and3registration modules and retaining4authored/5expanded cases, without equivalent replacement or fresh execution. Broad root-unit discovery loses naming/title/queued-host fixtures, main-window focus-shortcut and attach-services mock orchestration, Git Bash console-capacity fake process inventories, most real-Git preparation/locking variants and Claude/Codex catch-up examples. Keep lifetime rejected-writer followed by late termination proof and autonomous real-checkout cleanup; two-row real-Git rollback after a real move preserving a replacement/admin marker or revoked permission; a live translator write during a held transcript read fencing stale Claude history append; and Codex expected-item revision rejection before a historical writer shim. Codex driver registers retained bounds exactly once with original inputs; bounds does not prove modern writer persistence. Accepted changed-lock preflight sentinel and omitted-parent routing losses are not replaced. Audit3413 composes root-adopted3405/independent3406 and3409/independent3410: intentionally removes337 authored registrations/363potential expanded cases from13sources, retaining31authored/32potential cases and deleting one whole clipboard suite, without equivalent replacement or fresh execution. Broad root-unit discovery loses35WSL examples,22STT examples,22shared-server-banner examples,18clipboard-handler examples (whole suite deleted),14VM lifecycle examples and16commit-message cancellation examples. Retain4WSL and7STT mocked connector/worker cases,1rendered stale-banner refusal,2VM guard/failed-compensation cases and1late-stream ownership cancellation case; real WSL/microphone/remote-provider proof is not established. Separately discovered e2e-unit drivers lose13cross-version-wire local cases and15mobile active-publication cases, keeping same-process disk-reopen/new-host cursor content/epoch/sequence outcomes and a host/renderer-snapshot selection and inventory revision race respectively. Imported released stop-note scenarios remain unchanged and receive no duplicate credit. Cloud suites are outside root UNIT_INCLUDE. Audit3403 composes root-adopted3393/3394,3400/3401 and3398/3399: intentionally retires167 authored registrations/196 potential expanded cases across93 whole suites without equivalent replacement or fresh execution. Retained65 registrations/79 potential cases include one conditional missing-input failure sentinel; potential counts are not executions. Historical notes and complete dated receipts retain their exact original scopes. The retained runtime registration driver loses three complete imported fragments: changed-working-label title facts and suppressed-frame tracked snapshots; refusing SSH GitLab MR-base lookup before local Git/glab calls; and missing folder-workspace path creation/update refusal before spawn/store mutation. These alarms are intentionally lost. Other imported fragments and separately rooted dated receipts are unchanged; they are not equivalent replacement coverage. The broad root-unit command loses the UNIT_INCLUDE src/ subset of retired examples; mobile is outside UNIT_INCLUDE. Other lost alarms are recorded by the adopted per-case source reviews. Audit3390 composes root-adopted3382/independent3383 and3386/independent3387 and3388/independent3389: intentionally retires216 authored registrations/230 expanded cases in42 whole authored suites plus5 zero-case registration drivers, without equivalent replacement. Lost local alarms include fake PTY identity/routing/startup/replay/mode/title/mouse/IME/scroll matrices, broad startup identity and file-open wiring, mock mailbox title recovery, mobile row parity and whole-v-selective save parity. Retained24 registrations/26 expanded cases in22 suites preserve actual xterm Windows buffer/wrap/scroll, typed TOML scalar, real Promise cancellation/settlement, HTTP Codex scanner/projector semantics, durable recovery admission/newer-schema bytes, federation completion/ACK/SQLite atomicity and failed stale-run-write versus imported durable history. Additional retained clock-domain scheduling, durable freeze/ACK/checkpoint ordering, ABA dirty intent, SQL atomicity, folder-domain retier/last-note deletion, scrollback durable no-sync staging, PanelBridge subscriber lifetime and reserved-send publication preserve narrower concrete behaviors. Current finite owner drift assessed in bounded defining bodies; retained callback bytes unchanged. Historical notes and complete dated receipts keep their original exact scopes. No new execution, equivalent replacement, native focus/device/pixel, live remote or global mixed-version guarantee is claimed. Audit3381 composes root-adopted3376/independent3377 and3379/independent3380: intentionally retires436 authored registrations/670 expanded cases, including79 whole suites and12877 test lines, without equivalent replacement. Lost alarms include scheduling, account/host/status/filter/format inventories, microphone/image cleanup, title/bell/capability lifecycle routing, access/impersonation/outcome matrices, paste/input resend/ledger/retention, stale completions/reload containment, trust-read failure and popup OAuth/security/geometry vectors. Retained30 registrations/34expanded cases in22 suites preserve narrower SQLite TEMP/TZ/WAL, HTTP transcript root resume, mobile original-index Choose/Submit, child environment/Git lock expiry, stale ACK/PTY lifetime/peer fairness/durable replay/output ordering, actual DOM paste/editor focus, DEC2026 conservation, filesystem rollback, owned buffer lifetime, actual OSC parser/tracker handback, POSIX Python UTF8/fallback, durable trust concurrency/version, OpenSSH verdicts and hidden Chromium POST/route lifecycle. Mocked boundaries limit claims. Current bounded defining-owner reads preserve the retained oracles; captured identities are not full transitive semantic review. Both component blind pins authenticated before exchange; final reconciliation and explicit postpin3380reason correction supplement control, without retroactive blind claims. Root unit command excludes mobile and separately admitted Electron probes; use existing respective runners. No fresh execution, native focus/device/pixel UI, live SSH/remote, equivalent replacement or broad mixed-version/cross-platform validation is claimed. Prior dated receipts retain exact original scopes. Audit3375 composes root-adopted3370/independent3371 and3373/independent3374: intentionally retires79 authored registrations/84 expanded cases, including39 whole suites, without equivalent replacement. Lost alarms include federation field/parser inventories; Claude rejected-key precedence, credential clone redaction, managed-versus-user hook preservation and CLI defaults; setting/status/activity projections, mocked SSH/notification/reveal/Linear refusal, fake-clock reconnect and noise; image-fold artifact visibility, paste eligibility, setup trust, scripted ACP error-to-journal publication and ligature cache tuple aliasing; plus supplied folder-runner uniqueness, mobile host-overlay/credential/update/preference races, status/markup/title/keyed-row projections, subscriber cleanup, cancellation/close/refusal/link-issue and mirror suppression alarms. Retained3373 merger contiguity, dual-clock overdue-resume exactly-once, rejected-paste IPC sink and annotation schema roundtrip remain bounded. Retained actual HTTP/OSC status composition, destructive sibling-filesystem isolation, external contrast invariant and fixture CSS pixel intervention remain narrower. Original reviewed87authored/92expanded become9/9; current OpenCode suite adds two preserved upstream cases and the synthetic-title suite gained one Cursor policy mock-call case, independently reviewed for removal in root3378; current90/95 become11/11. That Cursor suppression/ready-frame regression alarm is intentionally lost; it does not observe native title ownership or tab flicker. For3370 only the peer was independently blind, with author exposure explicit;3373/3374 both blind pins were verified. This broad root unit command selects the reduced root unit suite; UNIT_INCLUDE excludes mobile tests, which require the existing mobile runner; retained Playwright component-pixel spec uses its separate existing headless fixture runner and is not validated by the broad unit command. No fresh execution, actual agent/shell/provider, OS material/focus, historical import equivalence, mobile, mixed-version or cross-platform evidence is claimed. All dated receipts retain their original scope. Audit3368 composes root-adopted3363/3364 and3367/3369: intentionally retires181 authored registrations/196 expanded cases, including28 whole suites, without equivalent replacement. Lost alarms include hibernation attention/liveness/backoff/sequential teardown and inventory, host launch compatibility/legacy/Kimi/resource cleanup, terminal recovery parser/pause/quarantine/remount, window-visibility omission-fence lifetime, launch-option rendered Start, sleeping-resume saved recipe/WSL quoting/cancellation, plus removed project/window/input variants. Additional tiny-suite losses include sentence/label/field/default inventories, credential omission, Windows argument/environment mapping, URI decoding, diagnostics, provider classification and fake-clock callback/parser examples. Retained ten registrations/twelve expanded cases include two literal Unicode Mn/Cf zero-width range guards in the actual character-range algorithm and protect narrower delayed editor bytes/destructive ownership, mounted hidden collision repair, ten transport epochs, duplicate-command refusal, caller timeout typing, executor unknown-opener refusal and failed-chunk user bytes. This broad unit command selects the reduced suite; no fresh runtime, real provider/network/PTY, filesystem restart, native UI, historical import equivalence, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3362 composes root-adopted3358/independent3360: intentionally retires129 authored registrations/140 expanded cases, including four whole suites, without equivalent replacement. Lost alarms include supplied orphan-adoption retry/malformed inventory/cancellation; fake-terminal replay parser/wedge/disposal callbacks; all-host catalog metadata and Windows preferences; host keepalive/protocol/stale/settings failures; and removed exact-stop/suppression, source save lifetime, diff-note queue, rename/editor close, input flood/chunk refusal/limits, purge and creation examples. Retained18 registrations/21 expanded cases protect narrower ownership, generation, dirty-state, queue convergence, encoding and attachment-lease outcomes. No replacement or keeper quota claim. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY/xterm parser, disk restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3359 composes root-adopted source3355/independent3356: intentionally retires130 authored registrations/139 expanded cases, including eight whole suites, without equivalent replacement. Lost alarms include strict create naming/capability/legacy payloads; supplied transport host replacement, deadline reattach, create-handoff and split activation; agent-session fork/clipboard/platform flags; shutdown cleared-scrollback/unmounted bindings; simulator host-collision/selection/shutdown; and removed editor, catalog, mutation, launch and status examples. Retained12 adverse-ordering/state-consequence cases are narrower and do not replace all removed alarms. Two queue absences receive zero removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH/PTY, filesystem restart, native UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3349 composes adopted batches3343,3345 and refreshed3354: intentionally retires234 authored registrations/294 expanded cases, including13 whole suites, without equivalent replacement. Lost alarms include supplied terminal reconnect/replacement/typeahead/mirror/result and snapshot examples; synthetic render-desync persistence/recovery; worktree listing/owner/catalog/lineage/removal and activation/creation examples; host-scoped PR and task-record projections; editor diff/status/comment and UI send-target examples; automation observation/wake, supplied sleep/deadline clock and native-chat completion/notification/relaunch samples; held-tab layout and cleanup/progress guard examples. Retained adverse-ordering and wire-boundary cases are narrower and do not replace all removed alarms. The already-upstream visibility-resume deletion receives zero new removal credit. This broad unit command selects the reduced suite; no fresh execution, historical import equivalence, real provider/network/SSH, native process/power/GPU, rendered UI, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain their original scope. Audit3342 composes adopted source batches3333/3334,3336/3337 and3340/3341: intentionally retires180 authored registrations/263 expanded cases, including seven whole suites, without equivalent replacement. Lost alarms include corrupt editor hydration; mobile editor/diff publication and privacy projections; stale-resubscribe routing; model-picker projection/refetch/retry/fallback; editor check-details and frame property inventories; latched-pane cleanup/quiescence; client create replay identity/options/compatibility; and removed owner, async routing, terminal and layout examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts keep their original scope. Audit3335 composes adopted source unions3327/3328 and3330/3332: intentionally retires100 authored registrations/123 expanded cases, including ten whole suites, without equivalent replacement. Lost alarms include seeded host persistence/contention and stale-host cleanup; browser snapshot assembly; mocked wake/DPR callbacks and frame budgets; preflight projections; palette authority/cache suppression, URL intent and saved-title cross-repo collisions; metadata coverage/set patch and dropdown assembly; and removed terminal, worktree, review-refresh and owner-routing examples. Retained definitions do not replace these alarms. This broad root unit command selects the reduced suite; no fresh execution, historical source/import equivalence, real provider/network/SSH, rendered UI/GPU/focus, durability restart, mobile, mixed-version or cross-platform validation is claimed. Unrelated dated receipts retain only their original scope. Audit 3318 composes adopted sources 3310, 3313 and 3317: intentionally retires 71 authored declarations and 102 expanded cases, including whole terminal-detach agent-retention, seeded batch/single open-files equivalence, shallow context-menu shortcut-badge, mocked active-workspace delete-dispatch, workspace session hydration, SSH target cleanup, editor session hydration and worktree terminal purge suites. Lost alarms include chained transfer alias and immediate close/exit retention; batch/single divergence, survivor/selection/map preservation and input nonmutation across 400 imperative seeds (one registered case); disconnected pending-handle retry, authoritative absences/close-record shortcut/older-host absence and published-presence/unpublished-frame examples; published empty host-graph omission to pane exit; legacy search ranking/exclusion fallback; provider request upgrade/dedupe/finalizer ownership; asynchronous PR suppression/primary-change and same-number different-repository URL rejection. Deletion routing loses host/instance qualification, paired and legacy mapping, folder ownership, active-versus-hover/menu-row selection, ambiguity, modal/editable/creation/view/main/deleting/missing guards and shortcut advertisement. Unchanged real keyboard/hover/confirmation/catalog E2E remains narrower, not an equivalent replacement. Additional losses include scripted old-host disk/UTF-8/noop/baseline and landed/unlanded lost-reply/replacement-retry outcomes; ordinary/repeated healthy-link reattach; cross-owner terminal/chat binding; oversized replay permanent-unavailable classification; floating reveal keyboard ownership/close/disable/listener disposal; naming/retained-turn/Sleep/error/close/reject status tables; SSH membership prune/new-target-only reads and environment/local bucket isolation; same-frame receipt capacity and positive bare/headless publisher readmission. These actual regression alarms are deliberately lost; no fresh gate, provider, rendered, mobile, mixed-version, cross-platform, soak or measured-budget validation is claimed. Audit 3312 composes adopted sources 3302 and 3308: deliberately retires 33 authored declarations and 36 expanded cases, including the whole backend startup-focus, active-browser IPC-close-routing, remote-browser-creation and agent-terminal-presence suites. Intentionally lost alarms cover distinct six-pane reconnect handles; SSH host label/Connect callback, unhydrated visit cleanup, repo cache aliases and hidden worktree/tab/PTY cleanup; adopted-agent startup focus and viewer navigation/reuse; staged, pageless, source, stale and orphan browser-close routing; web local-materialization refusal, desktop incapable-host fallback, failed/thrown remote creation and paired-web sign-in refusal; BOM/NUL and remote/local custom-editor byte-read examples; immediate folder activation and unread clearing; and batching idle/coalescing, accumulated byte ceiling, leading-edge-disabled, standalone synchronous oversize rejection, validation yield, deferred pending-tail order and both viewport-clear examples. The newly reintroduced agent-terminal-presence suite also loses actual terminal-status membership positive and nonterminal-status callback suppression alarms, including the recent 40916 guard regression; the older different 2133 presence-suite history remains historical and receives zero duplicate removal credit. These real regression alarms are intentionally lost. The unchanged survivors provide narrower coverage, with no equivalent replacement or fresh gate, provider, rendered, remote/mobile, mixed-version, cross-platform, soak or measured-budget validation claimed. Audit 3301 combines adopted source batches 3296 and 3299: retire 27 authored declarations and 36 expanded scenarios, including six whole suites. Intentionally lost alarms cover failed-verification/recovery/restart counters and mocked hosting/toast; early overlapping pane-read scheduling/count; unreadable removal listing draft guard; bulk-purge remote-qualified and raw-local guard maps; initial-snapshot blank/mode/oversize/printable/fresh-spawn callback and replay examples; fallback mobile file close and ordinary MRU; default queue overload/drain; seeded browser-page reuse and supplied missing-page URL recreation; ambiguous sleep/hibernation owner refusal and untouched bindings/origins; ordinary selection/activity/fallback priority; skip-remote success and retained hints; supplied structured-chat unsent retention and scoped removal draft eviction; caller-chat focus precedence; open/draft PR cache eviction and merged-head fallback result inventories. Retained adverse-ordering and ownership cases are narrower and do not establish equivalent replacements. No fresh runtime, native, physical provider, cross-platform, mobile or mixed-version evidence is claimed. Audit 3292 combines adopted 3285/3287/3289/3293 removals: 40 authored declarations and 47 expanded scenarios, including whole frame-editor-view, ambiguous remote-delete-refusal, unverifiable-host subscription and editor-close cleanup suites. The previously reviewed dock-badge suite was already removed upstream in PR 40895 and receives zero new removal credit. Intentionally retired alarms include background browser selection and last-tab landing; main startup fallback, SSH project cleanup/survivor routing, exact-PR contradiction/saved-push positives, replay/sidecar rollback and wrapped remote error normalization; records/snapshot missing-diff hydration, ambiguous folder-owner delete refusal, focus no-op notifications, nested editor context-only cache check, pending broadcast-first status and ordinary four-confirmation aggregation; preview-source frontmatter pruning, approved local/runtime agent dispatch, non-GitHub legacy PR cache invalidation, stale merged-head transient-error fallback, empty-queue immediate query reply and unverified-to-concrete preflight risk. Additional intentionally retired alarms are injected host subscription/unsubscribe counts, synthetic editor reveal/draft/fallback/scoped close, ambiguous unread refusals and hidden mark/read roundtrip, immediate connect backoff/noError, positive mirrored evidence-clock renewal, supplied VM failure/success projections and git-local/folder-SSH wake permutations. Remaining temporal/ownership cases are narrower; no equivalent replacement or fresh execution is claimed. Audit 3283 removes 20 authored declarations and 31 expanded scenarios, including two whole suites. Retired alarms cover PR refresh-state pruning, shared runtime subscription cleanup and store isolation, language content-change routing and older completion ownership, ordinary panel retry-timer cleanup and pending loading, four hosted-review lifetime permutations, mocked terminal creation error/order wiring, five sleep-inventory variants with pending-frame-only assertions, palette fallback/composite highlights, Windows/UNC encoded-editor input rows, mixed-repository partial failure counts, title setters and generated-title bypass/replacement, five window-close coordinator delegation/guard/finally branches, and ambiguous-old-record frame reveal. These regression checks are intentionally lost under the test-value audit; retained cases are not equivalent replacements. Prior coverage notes and receipts remain historical. Audit 3273 removes 14 authored declarations and 19 expanded scenarios across four whole suites and eight partial suites. Retired alarms cover saved-local cancellation/layout ownership, ambiguous-owner warning reset, folder attachment routing, VM false-capability bypass, abandoned reveal warmup cleanup and viewport claim deduplication/rearming, quiet unrelated remote-removal refusal, startup-command one-shot consumption, repository/floating recovery-ledger rows, fake-React pinned-scroll intent, split-ratio state identity/subscriber suppression and fractional change, cross-host project-group join refusal, three PR request-lifetime permutations, upstream-status preservation on error, and unresolved Git-owner refusal. These regression checks are intentionally lost under the test-value audit; retained scenarios are not equivalent replacements. Historical coverage receipts remain historical, including gate35 subscriber claims. Audit 3256 removes these specific alarms from the broad root unit commands: skill dialog active-share selection, close and pending-share handoff; simple keyed-record deletion; marker live-region insertion, simple landing and nine baseline policy examples; General search/control navigation inventory; orphan-count cache bootstrap; seven Codex code classifications and HTTP 429 warning mapping; two skill unread-root verdict examples; peer-mail payload and conversation-ID rejection; and the GitHub organization TABLE text-field optimistic rollback/failed-envelope example. These include real behaviors; retained tests do not provide equivalent coverage for every removed scenario. Mobile losses are recorded separately and are not coverage of these root commands. Audit3246 retires NewRowsMarker reveal/no-repeat and pane-scoped beforeinput checks; skill-owner option availability/count/dedup/order; six styled Input/Textarea IME forwarding rows; the static Codex/OpenCode smart-key inventory; tab-map AST ratchet diagnostic fixtures; child-roster work-budget and retained-aggregate alarms; malformed persisted floating-cwd fallback/no-crash/empty exact-root checks; the unanswered-host empty-list discriminator; the direct invalidated-cache commit-false assertion; one redundant digit-keyup IME row; cached non-supported Claude title-generator rows; and the duplicate late naming-result singleton. These root broad commands lose those specific alarms without equivalent replacement. Distinct retained owner/state checks have their own bounded claims; the real scheduler still rejects stale response data, while the direct false-return alarm is retired. Audit3231 retires supported-host restore-pane key mapping, closed/open creation-sidebar toggle visibility, unrelated scope-error/null classification and quick-submit reveal/no-create checks. These broad commands lose those real narrow alarms; no replacement coverage is claimed. Audit3219 removes the synthetic Cmd+J extra-source suite; this broad command no longer checks its match/tie placement and selection, announced count, empty-query cap, or workspace hiding with retained recent tabs. No replacement coverage is claimed. Audit3209 composes approved sources3202/3206: deliberately retires seven authored/expanded cases in four whole suites without equivalent replacement. Work-item queries lose real GitHub/GitLab oversized ASCII secret-prefix empty-query and whitespace-before-trim refusal alarms; inputs share the imported size bound and exercise only its fast length branch, with no multibyte or actual provider/exposure guarantee. Skill sharing loses complete/partial managed-bundle and destination-ambiguity association checks plus three negative origin/path/scheme admission examples; these do not establish uploaded contents, arbitrary-URL fetching, authorization or execution. Retain exact originless-project direct-link fallback, cloud-delete confirmation, bundled-target repair/owner isolation and explicit Windows-host preference over stale WSL suites. Rejected3201 runtime-preference removal is excluded. No real cloud/network/host/disk, mobile or mixed-version execution validation is claimed. Audit3200 composes approved source3194: deliberately retires thirteen authored registrations/twenty-seven expanded cases in six whole automation host/list policy suites without equivalent replacement. Real RPC category/retryability and wrapped-timeout recognition, unscoped-failure/scoped-success health evidence precedence, exact-ID create selectors and per-run workspace omission, paired-web local/SSH/absent host catalog routing, incompatible/removed/unhydrated/offline execution health, runtime-before-nested-SSH recovery dispatch, and no-owned-focus/successor/foreign-list focus policy alarms are consciously lost. Retain exact20line orphan allow/refuse/precondition and exact90line cross-host same-ID search suites. No retry-timer/fence lifecycle, actual reconnect/network/write delivery, native focus, mobile/mixed-version runtime or disk persistence coverage is claimed. Audit3191 combines approved source3182/3187/3188: deliberately retires thirteen authored Vitest registrations and fifteen expanded cases, including five whole suites, without equivalent replacement. Attachment intake loses real portal/native-capture terminal interception and unowned-container refusal, immediate child-only committed availability/claim-ref negotiation and delivery, and direct-target over stable focused/background composer routing through disable/re-enable/remount and independent question focus. Exact destination/cache/draft and final-stat owner/workspace/File-release suites remain; they do not replace Surface recipient routing. Automation authoring loses destination runtime catalog membership, local/direct-SSH exclusion of paired-runtime repos, unknown-runtime empty catalog, logical project/host/setup/repo/path context payload, and missing/nonready setup refusal; these were genuine direct helper alarms, while exact schedule transformation, legacy schedule and setup-decision suites remain. Agent picker loses setup-chat/terminal/missing-installer/unsupported-or-unknown-host row projection samples and the ordinary unsearched menu variant; the entire original26-line resume recipe suite remains, including reported bypass versus default/absent permission modes, as does the exact search-result menu callback with its fixtures, model/effort commits and staged Arguments reopen outcome. Rejected predecessor3180 full recipe deletion is excluded. No actual native drag/cursor/focus/IME, upload bytes or disk/restart persistence, full automation save/scheduler/runtime transport, real resume-process flags/environment delivery, or native menu/rendered layout validation is claimed. Audit3178 combines source3169/3170/3175: deliberately retires eight authored units (six Vitest cases and two imperative custom relay scenarios), including two whole suites, without equivalent replacement. Voice Section loses per-model pending-delete isolation across interleaved A/B completion and the two-success refresh-call alarm; exact VoicePane delayed key-clear/newer enabled-toggle merge remains and does not replace row deletion coverage. Speech loses dedicated rating-scale/inclusive-ceiling, unsupported-versus-unmeasured, explicit/system-language precedence/locale alias, accuracy versus fast named/default/best-measured selection, and unmeasured/no-match examples; exact offered-user-pick versus retired-selection case and its fixture remain. Relay loses legacy ping-delivery count/liveness sampled before the silence deadline and grouped malformed Bearer/host-ID 401/429 routing checks; twelve real Worker/DurableObject/shipped-client scenarios remain, not equivalent replacement for those narrow alarms. Six prior speech cases are not all deleted: approved successor3175 keeps the original user-choice case. No actual credential/file persistence, native/GPU/engine/download delivery, production assignment policy or deployed-runtime validation is claimed by this reduction. Audit3165 combines source3160/3162: deliberately retires six authored/expanded cases across three whole suites without equivalent replacement. Launch/status losses: observed React-render pending/resuming coordination across settings and deferred offer read; stale-offer reread suppressing dialog reopen; held-local-chat recovery visibility with new-chat preferences off; disabled-local admission avoiding offer RPC despite an injected but unconsumed paired-tab fixture; and run-only lost-reply uncertainty reachability until direct viewed-run retirement. Launch probe does not prove arbitrary synchronous-store atomicity, the paired fixture is not remote runtime enrollment, and the status case directly marks viewed state rather than rendering the summary. Crew-hook losses: old-host method_not_found cache persists across party changes but is released by independently supplied connection generation/verified pairing status or pairing revision, with actual frame publication and teardown. These are real narrow coordination, admission, uncertainty and mixed-version cache alarms consciously lost. Exact web verified-runtime writer handoff guard remains; it does not replace those alarms or prove live host/native/mobile delivery. Audit3156 combines3147/3150/3152/3153/3154: deliberately retires39authored/40expanded native-chat recovery cases, eight whole suites and two orphan test-support files without equivalent replacement. Lost alarms: lost-reply unconfirmed reconciliation, skipped rows/counts and missed-frame repair, unknown/pending outcome and omitted-failure-list compatibility, uncertain history after dismissal, retry/refusal/dismiss lifecycle, hidden/consumed picker ownership, result-tree keyboard focus/disclosure and all-skipped retirement; unconfirmed-over-conflict guidance and failed-chat changes despite older host timestamps; nearest-listed ancestor/cyclic forest shape, descendant membership, host ordering/missing-host local fallback; skipped/readiness/admission counts, provisional skip/progress monotonicity, early per-chat verdicts with batch pending protection, older-host waiting, start-slot/delivery distinction, retry-over-failure and unknown-after-withdrawal attention; remote snooze/reconnect/reoffer, unseen mixed summary through open/close, watched completion retirement, new success beside old failure, failed-reread mixed-result preservation, filter/collapse completion resets, retry summary replacement and current-offer/history selection; cross-host workspace identity, rendered cyclic reachability, nested tri-state/toggle propagation, project eligibility isolation and collapse preserving selection. Exact fallback-list completion barrier, batched verdict/cleanup retention, stale-read versus dismissal publication race, and requested-but-never-rendered finished-run retirement remain; they do not replace retired alarms. Audit3146 combines source reviews3132/3133/3135/3138/3143: intentionally retire20authored/31expanded cases without equivalent replacement. Provider-session losses: structured-native terminal-resume exclusion, metadata-less completed identity, new-turn completion clearing, Pi provider-only/periodic/manual promotion, changed-transcript launch-config isolation, Pi/omp/prime-agent completed-session remote/manual-shutdown promotion, and quit/done precedence over heartbeat. Side-thread/question losses: finished-pane acquisition, hidden title/recap states, local/relay/relay-done conversation takeover with prompt/session/child resets, plain-message abandonment, compaction/session replacement and completion resets. Codex startup losses: incoming-owner cached child replacement, old-relay foreign live-session correction, completed foreign-root turn-fact permutations. Transcript losses: real temporary-JSONL partial sibling/final-child completion, unlabelled child attribution, compact cached replay preservation and100/1000completed-child roster retention/release. Compiler-ratchet losses: valid-line uncompiled-list parser grammar examples and injected-existence stale-path filtering; these did not exercise actual filesystem canonicalization or build exclusion. These are real lifecycle, ownership, replay, liveness and retention alarms, including recent#40246 regressions, deliberately lost. Retained conditional record replacement, clockless root/SSH owner isolation, persisted main-thread fork rejection, partial/final question-answer lifetime, cached-roster/missing-ID/live HTTP/durable startup boundaries and restarted-relay refusal/acceptance do not replace those losses. No native/SSH/WSL execution or equivalent coverage is claimed. Audit3128 scoped coverage reduction: Audit3121 removes VoiceDictationLanguageSetting.test.tsx (Spanish-to-es callback and unsupported-model Korean option presence) and voice-speech-model-rows.test.ts (provider/language-order/retired-on-disk list policy); these real narrow alarms are deliberately retired without replacement. VoiceSpeechModelSection per-model concurrent deletion remains unchanged. Audit3122 removes the direct absolute/parent-segment sparse-directory exception-type sample and the five-row IPC sparse-preset error-code/non-save table (two authored/six expanded cases). Those real typed-validation and IPC refusal/error-code alarms are deliberately retired. Keep both real symlink/junction floating-directory trust cases and the minimal RPC structured validation-reason serialization case. The RPC case does not replace IPC save/refusal behavior, typed normalization for both path inputs, actual Git sparse checkout or rendered localization. No equivalent replacement or fresh test/runtime/platform/remote/performance validation is claimed. Audit3124 removes ExperimentalPane.test.tsx (ordinary Pet switch callback), WorkspaceDirectorySetting.test.tsx (padded absolute saved-path normalization/no-write blur), and repository-search.perf.test.ts (navigation/selected-pane builder-call policy, fixture cardinality/nonempty entries and renamed project keyword inclusion). These real narrow alarms are retired without replacement; RepositoryPane.search.test.tsx search-to-sparse-editor request remains unchanged. Audit3129: resolver Windows case-insensitive and POSIX case-sensitive configured-env composition plus mocked-base launch-preflight Windows composition are intentionally no longer checked by the two deleted suites. No equivalent coverage claimed. Keep runtime-structured-agent-host-env.test.ts unchanged: configured Windows Claude-home account identity and host-account precedence remain checked. Audit3114 incorporates source3101: retire three structured Claude child-environment wrapper cases covering inherited stamp isolation/default and explicit entrypoint, Windows SDK-key canonicalization/default/duplicate-key order, and configured lookup/final environment/config-dir conjunction. Keep direct auth/session sanitation and Windows-versus-Linux overlay checks, actual executable lookup from supplied inherited PATH, native Windows child environment delivery, and stale option-mutation fencing. These are not equivalent replacements for the retired wrapper alarms. No fresh test/runtime, real login-shell probe, Claude SDK startup, remote/mixed-version, UI or performance result is claimed. Audit3114 incorporates source3105: retire 17 authored/20 expanded daemon launch-note cases, including the entire two-case SessionLaunchNote suite. Deliberately lose split-marker carry across same-token re-arm, stale-token retirement refusal, foreground tri-state and serial settlement, omitted-note/no-incarnation mixed-version policy, sticky retirement, first-incarnation/replacement launch preservation and held-launch precedence. Keep only the unchanged unresolved foreground-read race against a later finished attach. Supplied notes/foreground and runtime calls do not establish actual daemon/main restart, SSH, native Windows observation, mobile UI, equivalent replacement or fresh runtime/performance validation. Audit3114 incorporates source3109: retire six authored/35 expanded pricing cases: 21 accepted model-name examples, 10 unsupported/future-model fail-closed examples, malformed TTL clamp, unknown-model estimate refusal, flat-model long-context disregard and oversized long-context clamp. Keep mixed five-minute/one-hour write allocation and short/all-long/mixed long-context allocation with original fixed oracles. Real parser/refusal/bounds alarms are knowingly lost without equivalent replacement; retained tests do not validate provider rates, actual billing or request threshold classification. Preserve the archived usage-scan-append source-freeze receipt without transferring historical execution/performance credit. No fresh runtime result is claimed. Audit3108 source-only reduction (3094/3095/3100): retire 27 authored/30 expanded cases, including complete markdown view-state, file-preview link-open and CLI agent-server-route suites, without replacement. Deliberate losses include preview visibility/reference lifetime and same-path owners; SSH stat, directory/missing-target, explicit-null owner, nonmarkdown line/column, local URI routing, remote-to-client guard and same-file reuse; document-preview source-owner/folder/reuse routing, stable grant location and outside-workspace POSIX/Windows request projection; and verified remote CLI send/check refusal, suggested --on argv/copy, shell no-probe bypass, unverified-launch admission and older-peer refusal. Retain two markdown source-runtime/qualified-reveal alarms, one stale grant-rejection fence and two remote read/mutation evidence policies, with original callbacks. Final last-wins reveal did not prove transient cancellation; CLI prerequisite did not prove no real send, and envelope tests do not execute server refusal. No fresh runtime, rendered UI, actual file/SSH/paired transport, authorization, mixed-version or performance result is claimed. Audit3096 source-only reduction (3087/3088): retire 69 authored/76 expanded cases, including complete recovery-portals and reconnect-banner suites. Intentionally lose dead/default TUI replay, generated alternate-frame style composition, reset/mode/dimension and legacy missing-mode-boundary alarms, UI notice/action/reveal policies, and isolated recovery lifecycle variants, without equivalent replacement. Retained registrations and callbacks are unchanged; headless cells are not pixels, and no fresh runtime, host, SSH, WSL, rendered-app or performance result is claimed. Audit3086 source-only reduction (3079/3080/3081): intentionally retire 93 authored/100 expanded mock-boundary cases, including the complete spawn-errors and SSH reconnect overlay suites, without replacement. Retired alarms include spawn classification/ownership, reply ceilings and renderer-write failure recovery, disconnect/detach fencing branches, authority facts, and overlay retry/visibility wiring. Retained callbacks are unchanged; no fresh execution, real PTY/SSH, rendered UI, or performance result is claimed. Audit2432: The broad unit command loses the isolated BranchPicker open-change notification sample. Its unique true/false callback alarm is intentionally retired; reopening/status-refresh behavior was not exercised. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2425: The broad unit command loses the workspace-copy-status supplied readError forwarding sample. It did not exercise the branch-switch blocking promised by its title. This alarm is intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2417: The broad unit command loses two ordinary clean Git cherry-pick/revert success samples and two terminal startup foreground-read work-budget samples. These unique alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2412: The broad unit command loses the whole six-case fake-React-hook scroll-anchor suite, two generic draft-retention samples, a simple new-agent order sample, a real history-publication batching-count sample, an unmounted handoff abort/timer sample and three basic WSL preview/error samples. These alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2404: The broad unit command loses the standalone share-name lookup 503 propagation suite, initial deletion placement-kind sample, direct changed-mtime stale sample, first-pass rollback existence example and abandoned-preparation directory sample. These exact alarms are intentionally retired without equivalent replacement or fresh validation of the reduced selector. Audit2397 review amendment: The broad unit command loses three standalone suites, two partial-case definitions and two URL table rows across package/download/placement tests. Keep initial wrong-port authorization, modified independent-copy digest refusal and abort-after-begin cancellation dispatch. The remaining alarms are deliberately retired; no equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2393 current-parent refresh2401: Remove the basic skill-install service alias sample and original public managed-remove receiptless refusal case. Preserve the upstream request ownership suite and transaction interruption coverage. No equivalent complete replacement or fresh validation of the reduced selector is claimed. Audit2389: The broad unit command loses the missing-preview suite, plain-global destination sample and prepublished-receipt recovery example. No equivalent replacement or fresh validation of the reduced selector is claimed. Audit2385: The broad unit command loses four authored walker/staging/protocol examples (six expanded cases); no equivalent replacement or fresh validation is claimed for the reduced suite. Audit2383: The unscoped Vitest command no longer includes the removed Antigravity catalogue suite; its exact provider-root/owner example has no equivalent replacement or fresh validation claim. Audit2377/2381: The unscoped Vitest command includes the reduced bundled-skill and native-discovery suites; the eight removed backup/legacy/catalogue/symlink/SSH-builder examples have no replacement-equivalence or fresh validation claim here. Audit2133 current-parent preparation: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2095 current-parent preparation2126: Current reduced sources/selectors intentionally retire the alarms listed in knownGaps; prior dated runs and replacement claims do not validate the changed set. Historical prior account (preserved verbatim): Audit2090 (sources2088/2089): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2086 (sources2082/2083): Current reduced suites intentionally retire the alarms listed in knownGaps; prior dated execution and replacement claims do not validate changed source bytes or selectors. Historical prior account (preserved verbatim): Audit2076 (sources2073/2074): Intentionally retire these low-value alarms without replacement: src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts: recovers a moved SSH pane through the tab it now sits in, not the one its lease froze; reports a plain expired orphan; does not report a pane whose only recent lease was superseded; does not report a pane whose only recent lease had its relay id recycled; picks the eligible orphan over a superseded predecessor that matches first; collects the same tabs the per-tab reader reports, in one sweep of the leases; reports no candidate when no lease names any of the worktree tabs. src/main/runtime/orca-runtime-tests/runtime-availability.spec.ts: starts unavailable with no authoritative window; reports the configured Windows terminal shell on status; reports floating workspace availability from settings on status; polls floating tabs with targeted PTY liveness and no repo/provider inventory; hydrates persisted tabs when the store cannot report repos; advertises browser screencast only when a renderer window is available; routes mobile Codex reset consumption through the account mutation coordinator; maps a definite pre-provider rejection into an authoritative current snapshot. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Frozen current literal-import graph reaches these changed test bytes; unresolved local and computed edges remain debt, and current reachability is not historical execution or equivalent replacement evidence. Historical prior account (preserved verbatim): Audit2056 (sources2054/2055): Intentionally retire these low-value alarms without replacement: src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts: delivers remote file changes to listeners for the same worktree. src/main/runtime/orca-runtime.test.ts: ordinary registration cleanup removes only await import('./orca-runtime-tests/mobile-session-tabs-part-14.spec'). src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-03.spec.ts: arms the stale-title timer for a seeded working title; arms the Command Code scrape from the noted spawn command; prefers the tracked title over a stale renderer lastTitle in the hydration seed; writes recent output into the current runtime output map; uses a later title handler replacement with the runtime receiver; calls the current injected listener with the runtime receiver; keeps optional reconciliation lazy after its callback is removed. src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-14.spec.ts: lists them, so a paired client can mirror a migrated editor; closes one by retiring it from the host session; keeps an unsaved draft unless the close is forced; shares aggregate work but leaves a replacement pending promise alone; lets a targeted refresh finish while an aggregate refresh waits; refuses a close when the store lacks %s before the guard; keeps a later missing %s on the original caught failure path. Existing unrelated evidenceRuns retain their original scope; unchanged dated receipt objects do not validate changed source bytes or reduced selectors. No fresh gate execution or historical import-closure equivalence is claimed. Exact retired assertionRefs, preserved as historical objects only: {\n \"file\": \"src/renderer/src/runtime/files/watching/runtime-file-client-watch.test.ts\",\n \"assertions\": [\n \"terminal watcher error and setup failure evict the shared entry before retrying callbacks run\",\n \"an old stream end cannot evict the replacement stream, which still delivers to its listener\",\n \"two same-worktree listeners share a synthetic subscription until the final stop unsubscribes and sends unwatch\"\n ]\n } Historical prior account (preserved verbatim): Audit1973: Delete the standalone mocked watcher cleanup suite and its entire sole-file prospective command. Retire the removed file-command transport-abort alias; preserve the independent cancellation suite and final-overflow/error/end cleanup callback, and13 unrelated receipt objects. Whole original changed dated receipts are retired, never narrowed or transferred. This metadata review claims no fresh execution, equivalent replacement, provider/PTY, live remote/mobile, rendered, cross-platform, soak or measured-budget result. Historical prior account (preserved verbatim): Audit1931 (sources1928/1929): Partial runtime files-watch suite retains controlled Windows close-event waiting, shared-client survival, late physical-exit ownership/deadline cleanup and shutdown joining. Its combined Windows close/deadline/late-exit alias remains backed by unchanged callbacks. Retire native-error-close, pre-publication setup ownership and failed-delete rearm aliases; associated delegation, failure forwarding, removal routing and recovery examples are lost. These tests inject watch/subscription seams and do not observe an actual native watcher or physical process. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1925 (sources1922/1923): Partial runtime watcher-host suite loses mocked option/event/overflow/resubscription forwarding, supplied teardown-error propagation, aborted-signal/no-call and private ten-thousand-waiter-count inventories. Retire the 10,000-caller bound and failed-recovery-subscriber-ending assertion aliases. Keep same-root owner cancellation, pre-ready replacement, held root-close join, stale-generation recovery delivery and initial failed-root ownership mappings backed by retained real-host callbacks with injected subscription/error/physical-exit promises. No actual native watcher, process termination or resource bound was observed. Preserve meaningful remaining selectors/assertions and unchanged dated receipts within their original scope. Reduced selectors have no fresh gate execution evidence in this metadata packet. No equivalent replacement, physical watcher/PTY/provider, live SSH/remote/mobile, rendered, cross-platform, soak or measured-budget result is claimed. Historical prior account (preserved verbatim): Audit1683 retires changed-source assertion and execution scope without equivalent replacement coverage. Existing unchanged-selector receipts remain scoped to their original sources. Historical prior-source oracle: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Existing exact unchanged-selector receipts remain the only current execution evidence. Changed source selectors have no fresh execution result. Historical prior-source oracle account: Fill the global watcher-child reservation, require native desktop, paired-runtime, and WSL setup to retain typed transient capacity and retry after one serialized release, then cancel pending desktop and paired-client watches and require no retry. Hold one live anchor while aborting 10,000 callers at the capacity, quarantine-assignment, runtime-root, relay-setup, and SSH-registration layers; require exactly one explicit waiter and one base-promise reaction to remain, then zero after settlement. Hold an old relay unsubscribe, queue one same-root setup leader and one anchor, then abort 10,000 joiners; require every cancellation to settle before teardown releases, exactly one anchor waiter, and only one later physical install. Advance the former paired-web callback deadline while capacity remains full, require cancellation ownership to stay live, publish the server token before ready, and require files.unwatch to abort setup before a later slot release can install a native root. Reject the first ready-watch unwatch with a physical-exit promise, resolve that exit later, and require a fresh physical unwatch attempt, registry release, and exactly one stream end. Fill one healthy shared child with multiple roots, map a standard SSH repository's base, Git common directory, and worktree roots to one relay supervisor, then inject IPC disconnect-before-exit, queued and active cancellation, operations during termination, kill-without-exit, repeated unkillable generations, initial and recovery timeouts, and shard failure. During local and SSH deletion, attempt a late terminal spawn whose worktree identity and cwd name different roots, enumerate a non-prefix remote PTY by authoritative worktree ownership, withhold daemon/relay exit callbacks, make attach positively prove a concurrent-shutdown PID dead, and make the provider unavailable; require every acquired admission to roll back on rejection, dead-PID proof to settle physical exit before reaping, timeout to retain ownership, and Git/filesystem deletion never to start. Require bounded watcher process count, physical-exit settlement, healthy-root recovery, stale-generation rejection, overflow plus later events, and fail-closed destructive cleanup. Verify relay build hashes and remote install probes require both relay.js and relay-watcher.js. Launch the built relay with a real PTY and Parcel watch, kill only the watcher child, and require the same relay PID and PTY to answer before a replacement child delivers overflow and a post-crash event.", "commands": [ "pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot", "pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot", @@ -12297,7 +12246,8 @@ "Audit5901 removes only the mobile-creation-and-orchestration-part-03.spec import from the retained runtime driver. The fragment's missing-handle wait abort and waiter retirement on reload-exit alarms are intentionally lost. This is a conservative import-closure notice: named command filters may exclude those cases. Driver selectors remain; unchanged historical receipts retain their original scope and establish no fresh whole-gate pass or equivalent replacement. ", "Audit5916 removes the entire local-worktree-creation-part-02.spec import from the retained runtime driver, intentionally losing the mocked exact-name create refusal when a selected PR matches a remote branch. The sole zero-auth terminal-handle registrar for another deleted suite is also retired, with no authored credit. Driver selectors retain only their narrowed import scope. Unchanged dated independent receipts are not equivalent replacement or fresh whole-gate validation. ", "IPC/PTY folder cleanup at predecessor d23e47411ae7cfcd2ce51187d3ae07ff0a95e586 retires whole TEST Programs from current selectors: src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts, src/main/ipc/worktrees-orphan-directory-cleanup.test.ts, src/main/ipc/worktrees-remove-preflight.test.ts. Their complete authored alarms are intentionally lost. No equivalent replacement, fresh execution, new runtime/performance result, cross-platform, remote, mobile or folder-workspace proof is claimed. Unrelated retained dated receipts remain scoped only to exact unchanged commands. Complete original current selector/assertion fields verbatim:\ncommands: [\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\",\n \"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/ipc/worktrees-orphan-directory-cleanup.test.ts src/main/ipc/worktrees-remove-preflight.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts\",\n \"pnpm run build:electron-vite\",\n \"node config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-resource-probe.mjs\",\n \"node config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-fault-harness.mjs\",\n \"ELECTRON_RUN_AS_NODE=1 pnpm exec electron config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-fault-harness.mjs\",\n \"pnpm exec vitest run --config config/vitest.config.ts\"\n ]\ntestFiles: [\n \"src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts\",\n \"src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts\",\n \"src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts\",\n \"src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts\",\n \"src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts\",\n \"src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts\",\n \"src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts\",\n \"src/main/ipc/worktrees-orphan-directory-cleanup.test.ts\",\n \"src/main/ipc/worktrees-remove-preflight.test.ts\",\n \"src/main/workspaces/removal/watcher-removal-gate.test.ts\",\n \"src/main/ipc/pty/pty-spawn-cwd-fallback.test.ts\",\n \"src/main/providers/local-pty/local-pty-provider-shutdown.test.ts\",\n \"src/main/daemon/terminal-host/testing/terminal-host.test.ts\",\n \"src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\",\n \"src/main/runtime/files/watch/orca-runtime-files-watch.test.ts\",\n \"src/main/runtime/workspaces/removal/worktree-teardown.test.ts\",\n \"src/main/runtime/construction/orca-runtime.test.ts\",\n \"src/main/runtime/rpc/methods/files/files.test.ts\",\n \"src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts\",\n \"src/renderer/src/web/web-runtime-client.test.ts\",\n \"src/shared/file-access/cross-platform-path.test.ts\",\n \"config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-fault-harness.mjs\",\n \"config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-resource-probe.mjs\"\n ]\nassertionRefs: [\n {\n \"file\": \"src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts\",\n \"assertions\": [\n \"pins Parcel to the Windows backend for local Windows watches; rejects installs during destructive removal and allows a retry afterward; never watches an SSH path on the local disk\"\n ]\n },\n {\n \"file\": \"src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts\",\n \"assertions\": [\n \"initial-subscribe crashes complete with an interruption refresh\",\n \"watch errors before readiness reject setup and physically cancel the native crawl\",\n \"watch errors during replacement crawl terminate recovery and a late readiness ack cannot revive the failed root\",\n \"IPC disconnect recovery restores every existing root before accepting new setup\",\n \"queued abort removes one request without restarting healthy roots, while active abort or crawl-scoped timeout restores the shard\",\n \"queues subscribe and unsubscribe behind the retiring child; bounds a pending crawl and restores healthy roots after setup timeout\",\n \"production runtime-pool disposal rejects later subscriptions without forking an overlapping child\",\n \"Historical assertion retired by audit3749/3752; no current direct driver or replacement coverage is claimed. Original assertion (preserved verbatim): missing built entries fail closed\"\n ]\n },\n {\n \"file\": \"src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts\",\n \"assertions\": [\n \"a waiter recursively re-enters the event-driven barrier when crash recovery reclaims its announced slot\"\n ]\n },\n {\n \"file\": \"src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts\",\n \"assertions\": [\n \"pending-crawl cancellation after disconnect remains pending until the exact child exits\",\n \"ready and pending-crawl cancellation force disconnected-child exit even while a healthy sibling root remains\",\n \"a cancellation deadline joins active disconnect termination without duplicate sibling resubscription\",\n \"an exit-deadline failure replaces the early cancellation and remains visible to synchronous unsubscribe until physical exit\"\n ]\n },\n {\n \"file\": \"src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts\",\n \"assertions\": [\n \"worktree deletion physically aborts pending native setup and settles before its crawl resolves\",\n \"a cancelled pending install retains physical-exit failure across an immediate second destructive close\",\n \"desktop terminal failure remains root-owned even when the cleared subscription later unsubscribes cleanly\",\n \"Windows event payloads retain the physical root spelling instead of the comparison key\",\n \"failed local worktree removal restores every live renderer listener and emits overflow\"\n ]\n },\n {\n \"file\": \"src/main/runtime/files/watch/orca-runtime-files-watch.test.ts\",\n \"assertions\": [\n \"Windows runtime cleanup waits for the native close event, fails closed at a bounded deadline, and clears retained ownership on late close without retry listeners\"\n ]\n },\n {\n \"file\": \"src/main/runtime/workspaces/removal/worktree-teardown.test.ts\",\n \"assertions\": [\n \"overlapping runtime, provider, and registry sweeps stay behind one physical PTY-stop promise\",\n \"destructive teardown rejects instead of releasing deletion when physical stop misses its deadline\",\n \"cwd-owned and floating PTYs are swept while legacy rows without cwd retain prefix ownership\",\n \"remote provider enumeration matches authoritative worktree ownership without touching the local-only registry\"\n ]\n },\n {\n \"file\": \"src/main/runtime/rpc/methods/files/files.test.ts\",\n \"assertions\": [\n \"terminal watcher loss flushes a final overflow change before error/end and unregisters cleanup\"\n ]\n },\n {\n \"file\": \"src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts\",\n \"assertions\": [\n \"the server publishes a cleanup token before ready and files.unwatch aborts pending setup without delivering queued crawl events\"\n ]\n },\n {\n \"file\": \"src/shared/file-access/cross-platform-path.test.ts\",\n \"assertions\": [\n \"POSIX literal backslashes preserve containment and relative identity\",\n \"Windows drive and UNC roots enforce containment\",\n \"WSL Linux-tail comparisons remain case-sensitive and relative suffix bytes remain exact\"\n ]\n },\n {\n \"file\": \"src/renderer/src/web/web-runtime-client.test.ts\",\n \"assertions\": [\n \"a stopped pre-ready paired-web watch retains its callback beyond the former deadline and uses the early server token to unwatch\"\n ]\n },\n {\n \"file\": \"config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-resource-probe.mjs\",\n \"assertions\": [\n \"five healthy roots share one exact watcher PID within the per-child RSS budget\",\n \"four quarantine roots use exactly four child PIDs and remain within the global eight-child reservation cap\",\n \"CPU and RSS are sampled for every exact child PID and every PID exits during cleanup\",\n \"per-child and aggregate RSS and sampled CPU ceilings fail the probe before the physical child cap can hide excess resource use\"\n ]\n },\n {\n \"file\": \"config/scripts/diagnostics/runtime-watchers/runtime-file-watcher-fault-harness.mjs\",\n \"assertions\": [\n \"the built watcher entry delivers an event before fault injection\",\n \"the harness parent survives watcher-child SIGSEGV\",\n \"the real supervisor automatically replaces the child, resubscribes, and delivers a post-crash event\"\n ]\n }\n ]", - "Module-layout web/session cleanup: Removed paired-web client TEST alarms for connecting-search abort/pre-abort, close rejecting pending connect waiters, expired-handshake socket retirement and encrypted binary interoperability. The pre-ready paired-web watch assertion reference also retires with that TEST; its claimed callback was already absent from the current four registrations. No replacement coverage or new execution is claimed; dated receipts describe their original runs. Prior active fields (historical only): [{\"pointer\":\"/gates/127/commands/0\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/1\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/2\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/3\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/4\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/5\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/6\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts\\\"\"},{\"pointer\":\"/gates/127/testFiles/16\",\"raw\":\"\\\"src/renderer/src/web/web-runtime-client.test.ts\\\"\"},{\"pointer\":\"/gates/127/assertionRefs/10\",\"raw\":\"{\\n \\\"file\\\": \\\"src/renderer/src/web/web-runtime-client.test.ts\\\",\\n \\\"assertions\\\": [\\n \\\"a stopped pre-ready paired-web watch retains its callback beyond the former deadline and uses the early server token to unwatch\\\"\\n ]\\n }\"}]" + "Module-layout web/session cleanup: Removed paired-web client TEST alarms for connecting-search abort/pre-abort, close rejecting pending connect waiters, expired-handshake socket retirement and encrypted binary interoperability. The pre-ready paired-web watch assertion reference also retires with that TEST; its claimed callback was already absent from the current four registrations. No replacement coverage or new execution is claimed; dated receipts describe their original runs. Prior active fields (historical only): [{\"pointer\":\"/gates/127/commands/0\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/1\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-supervisor-capacity.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/main/runtime/rpc/methods/files/files-watch-cancellation.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/providers/adapter/testing/daemon-pty-adapter.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/2\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watchers/filesystem-watcher.test.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts --reporter=dot\\\"\"},{\"pointer\":\"/gates/127/commands/3\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/4\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/providers/local-pty/local-pty-provider-shutdown.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/5\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts src/main/daemon/terminal-host/testing/terminal-host.test.ts src/main/daemon/terminal-host/testing/terminal-host-session-reaping-leak.test.ts\\\"\"},{\"pointer\":\"/gates/127/commands/6\",\"raw\":\"\\\"pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/filesystem/watcher-process/parcel-watcher-process.test.ts src/main/ipc/filesystem/watcher-process/supervision/parcel-watcher-disconnect-termination.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-local-unsubscribe.test.ts src/main/ipc/filesystem/watchers/filesystem-watcher-wsl.test.ts src/main/workspaces/removal/watcher-removal-gate.test.ts src/main/runtime/files/watch/orca-runtime-files-watch.test.ts src/main/runtime/workspaces/removal/worktree-teardown.test.ts src/main/runtime/construction/orca-runtime.test.ts src/main/runtime/rpc/methods/files/files.test.ts src/renderer/src/web/web-runtime-client.test.ts src/shared/file-access/cross-platform-path.test.ts\\\"\"},{\"pointer\":\"/gates/127/testFiles/16\",\"raw\":\"\\\"src/renderer/src/web/web-runtime-client.test.ts\\\"\"},{\"pointer\":\"/gates/127/assertionRefs/10\",\"raw\":\"{\\n \\\"file\\\": \\\"src/renderer/src/web/web-runtime-client.test.ts\\\",\\n \\\"assertions\\\": [\\n \\\"a stopped pre-ready paired-web watch retains its callback beyond the former deadline and uses the early server token to unwatch\\\"\\n ]\\n }\"}]", + "Runtime layout review retires the wedged watcher-install removal-fence callback because it asserts an internal production-derived timing boundary. Its acquisition-expiry, usable-release and subsequent-install alarms are intentionally lost without replacement coverage. The retained runtime collector has narrower scope; unrelated dated physical watcher resource/fault/build receipts retain their original scope and are not fresh validation of this reduction." ], "demotionRule": "Demote or quarantine if the fault harness flakes without a product or harness bug, if healthy operation exceeds one runtime watcher child, if total physical operation exceeds eight children including retiring generations, if quarantine children outlive their roots or repeat after fusing, if event delivery becomes unbounded, or if metadata/stat work returns to the serve process." }, @@ -12423,7 +12373,7 @@ "id": "remote-wire.cross-version-terminal-journey", "title": "A released client and a current server still complete one terminal journey in both skew directions", "maturity": "experimental", - "protection": "partial", + "protection": "none", "owner": "remote-runtime", "layer": "cross-version-protocol-integration", "surfaces": [ @@ -12434,56 +12384,19 @@ ], "platforms": ["macos", "linux", "windows"], "providers": ["paired-runtime"], - "coveredPlatforms": ["macos"], - "coveredProviders": ["paired-runtime"], - "coverageNotes": "Loads the real host RPC methods, real RpcDispatcher, real renderer terminal multiplexer, and codecs from the current working tree, exact pre-fix main, newest release tag, and the pinned reported 1.4.192-client/1.4.191-host commits. In-process transport reproduces production frame routing, including decoder-rejected opcodes. Covers the terminal stream only; session tabs, agent publications, file/Git RPCs, mobile E2EE framing, and relay transport are uncovered.", + "coveredPlatforms": [], + "coveredProviders": [], + "coverageNotes": "Both current cross-version terminal journey suites and the sole recorded execution are intentionally retired. Demote protection to none, clear covered platforms/providers, and archive exact active selectors/assertion references and the dated receipt. No equivalent replacement or fresh execution is claimed. Prior account preserved verbatim: Loads the real host RPC methods, real RpcDispatcher, real renderer terminal multiplexer, and codecs from the current working tree, exact pre-fix main, newest release tag, and the pinned reported 1.4.192-client/1.4.191-host commits. In-process transport reproduces production frame routing, including decoder-rejected opcodes. Covers the terminal stream only; session tabs, agent publications, file/Git RPCs, mobile E2EE framing, and relay transport are uncovered.", "motivatingLinks": [ "https://github.com/stablyai/orca/pull/12641", "https://github.com/stablyai/orca/pull/12655" ], "invariant": "A client and a server built from different releases must complete subscribe, input delivery to the process, hide/reveal buffer snapshot, transport drop, and resubscribe with no frame refused by the receiving build's decoder, the same negotiated capabilities, and the same published snapshot content — so a new optional field stays safe, a new opcode is only sent after negotiation, and a change in what the host publishes is visible before release.", - "oracle": "Run one fixed journey per general pairing (old client/new server, new client/old server, and current/current) plus the pinned reported pair, exact pre-fix main control, and candidate controls. Assert exact frames, subscriptions, input, rendered snapshot/live content, and zero decoder rejects or missing host methods. The reported and pre-fix-main clients must render blank after discarding the nonempty lossy initial image; candidate pairings must paint it once, recover the first post-snapshot sequence gap, and resume contiguous live output once.", - "commands": [ - "pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts", - "pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts" - ], - "testFiles": [ - "tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts", - "tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts" - ], - "assertionRefs": [ - { - "file": "tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts", - "assertions": [ - "expect(record.completed).toEqual([...JOURNEY_STEPS])", - "expect(record.frameSequence).toEqual(EXPECTED_JOURNEY_FRAMES)", - "expect(record.rejected).toEqual([])", - "expect(record.inputAtProcess).toEqual([JOURNEY_INPUTS.first, JOURNEY_INPUTS.second])", - "expect(event.capabilities).toEqual({ outputPause: 1 })" - ] - }, - { - "file": "tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts", - "assertions": [ - "the reported 1.4.192 client discards the reported 1.4.191 host's nonempty lossy snapshot", - "the exact pre-fix main client reproduces the same blank rendered terminal", - "the candidate client paints that old-host image exactly once and resumes live output", - "the candidate client paints the candidate-host image exactly once and resumes live output", - "both candidate pairings report zero decoder rejects and missing runtime methods" - ] - } - ], - "evidenceRuns": [ - { - "date": "2026-08-05", - "runner": "local", - "platform": "macos", - "result": "passed", - "command": "pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts", - "durationSeconds": 6, - "summary": "v1.4.169 against working tree c4d5a535f2; all three pairings produced the identical 16-frame journey with zero rejected frames." - } - ], + "oracle": "Both current cross-version terminal journey suites and the sole recorded execution are intentionally retired. Demote protection to none, clear covered platforms/providers, and archive exact active selectors/assertion references and the dated receipt. No equivalent replacement or fresh execution is claimed. Prior account preserved verbatim: Run one fixed journey per general pairing (old client/new server, new client/old server, and current/current) plus the pinned reported pair, exact pre-fix main control, and candidate controls. Assert exact frames, subscriptions, input, rendered snapshot/live content, and zero decoder rejects or missing host methods. The reported and pre-fix-main clients must render blank after discarding the nonempty lossy initial image; candidate pairings must paint it once, recover the first post-snapshot sequence gap, and resume contiguous live output once.", + "commands": [], + "testFiles": [], + "assertionRefs": [], + "evidenceRuns": [], "runtimeBudget": { "p95Seconds": 180, "scope": "four historical checkout extractions plus seven in-process pairings" @@ -12511,7 +12424,8 @@ "The newest stable release and pinned reported pair do not expose every intermediate regression.", "The host runtime is a stub around a fake PTY, so real PTY, daemon, and SSH provider behavior is out of scope.", "The baseline is the newest release tag by default, so the compared pair changes when a new release is cut unless ORCA_CROSS_VERSION_BASELINE_REF pins it.", - "tests/ is outside every tsconfig include, so the harness is linted and executed but not typechecked." + "tests/ is outside every tsconfig include, so the harness is linted and executed but not typechecked.", + "Runtime layout retirement; exact prior fields are historical only and provide no current execution or replacement-coverage claim:\ncommands: [\n \"pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\",\n \"pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts\"\n ]\ntestFiles: [\n \"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\",\n \"tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts\"\n ]\nassertionRefs: [\n {\n \"file\": \"tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\",\n \"assertions\": [\n \"expect(record.completed).toEqual([...JOURNEY_STEPS])\",\n \"expect(record.frameSequence).toEqual(EXPECTED_JOURNEY_FRAMES)\",\n \"expect(record.rejected).toEqual([])\",\n \"expect(record.inputAtProcess).toEqual([JOURNEY_INPUTS.first, JOURNEY_INPUTS.second])\",\n \"expect(event.capabilities).toEqual({ outputPause: 1 })\"\n ]\n },\n {\n \"file\": \"tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts\",\n \"assertions\": [\n \"the reported 1.4.192 client discards the reported 1.4.191 host's nonempty lossy snapshot\",\n \"the exact pre-fix main client reproduces the same blank rendered terminal\",\n \"the candidate client paints that old-host image exactly once and resumes live output\",\n \"the candidate client paints the candidate-host image exactly once and resumes live output\",\n \"both candidate pairings report zero decoder rejects and missing runtime methods\"\n ]\n }\n ]\nevidenceRuns: [\n {\n \"date\": \"2026-08-05\",\n \"runner\": \"local\",\n \"platform\": \"macos\",\n \"result\": \"passed\",\n \"command\": \"pnpm exec vitest run --config config/vitest.config.ts tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts\",\n \"durationSeconds\": 6,\n \"summary\": \"v1.4.169 against working tree c4d5a535f2; all three pairings produced the identical 16-frame journey with zero rejected frames.\"\n }\n ]\nprotection: \"partial\"\ncoveredPlatforms: [\"macos\"]\ncoveredProviders: [\"paired-runtime\"]" ], "demotionRule": "Demote if the baseline checkout cannot be materialized in CI, if a pairing has to be skipped to keep the lane green, or if the journey stops asserting the full step list and frame sequence." }, diff --git a/config/scripts/performance/native-chat/native-chat-4a-arm.ts b/config/scripts/performance/native-chat/native-chat-4a-arm.ts index 6ab698cdad6..d841f8d8ed5 100644 --- a/config/scripts/performance/native-chat/native-chat-4a-arm.ts +++ b/config/scripts/performance/native-chat/native-chat-4a-arm.ts @@ -27,7 +27,7 @@ import { type ArmSpec } from './native-chat-4a-arm-provenance' import { installVisibilityProbe } from './native-chat-4a-probes' -import { releaseModuleLocation } from '../../../../tests/e2e/cross-version-wire/release-module-locations' +import { releaseModuleLocation } from '../../../../tests/e2e/cross-version-wire/release-checkouts/release-module-locations' const HARNESS_ROOT = path.resolve(import.meta.dirname, '../../../..') const SYSTEM_DIRS = ['/usr/bin', '/bin', '/usr/sbin', '/sbin'] diff --git a/config/scripts/test-runtime/sqlite-admission/vitest-node-runtime-files.mjs b/config/scripts/test-runtime/sqlite-admission/vitest-node-runtime-files.mjs index 39e1fe3e9eb..cd51ec72193 100644 --- a/config/scripts/test-runtime/sqlite-admission/vitest-node-runtime-files.mjs +++ b/config/scripts/test-runtime/sqlite-admission/vitest-node-runtime-files.mjs @@ -33,7 +33,6 @@ const NODE_RUNTIME_INCLUDE = [ 'src/main/runtime/orchestration/mailbox/terminal-pointer/orchestration-mailbox-delivery.test.ts', 'src/main/runtime/orchestration/mailbox/routing/orchestration-mailbox-routing.test.ts', - 'tests/e2e/cross-version-wire/agent-session-clear-old-tab-mirror.unit.test.ts', 'src/main/pi/rpc/rpc-session-startup.test.ts', 'src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-clear-queued-command.test.ts', 'src/main/acp/session/acp-structured-session-adapter.test.ts', diff --git a/config/scripts/worktree-storage/reclaim-release-test-caches.mjs b/config/scripts/worktree-storage/reclaim-release-test-caches.mjs index 457f435189e..f398cc0e124 100644 --- a/config/scripts/worktree-storage/reclaim-release-test-caches.mjs +++ b/config/scripts/worktree-storage/reclaim-release-test-caches.mjs @@ -5,8 +5,8 @@ import { lock } from 'proper-lockfile' import { localRepositoryWorktrees } from './local-repository-worktrees.mjs' import { getDevBundleProcessTable } from '../development/electron-bundle-cache/dev-electron-bundle-cache.mjs' import { worktreeActiveSince } from './worktree-recent-activity.mjs' -import { CHECKOUT_FORMAT } from '../../../tests/e2e/cross-version-wire/release-checkout-publication.ts' -import { withReleaseSourceFormatLease } from '../../../tests/e2e/cross-version-wire/release-source-retention.ts' +import { CHECKOUT_FORMAT } from '../../../tests/e2e/cross-version-wire/release-checkouts/release-checkout-publication.ts' +import { withReleaseSourceFormatLease } from '../../../tests/e2e/cross-version-wire/release-checkouts/release-source-retention.ts' const COMMIT = '(?:[\\da-f]{40}|[\\da-f]{64})' const LOCAL_ENTRY = new RegExp(`^(${COMMIT})-format-([1-9]\\d*)$`) diff --git a/config/scripts/worktree-storage/reclaim-release-test-caches.test.ts b/config/scripts/worktree-storage/reclaim-release-test-caches.test.ts index a4bfc7984d2..352c0dd2113 100644 --- a/config/scripts/worktree-storage/reclaim-release-test-caches.test.ts +++ b/config/scripts/worktree-storage/reclaim-release-test-caches.test.ts @@ -15,8 +15,8 @@ import { join } from 'node:path' import { afterEach, expect, it } from 'vitest' import { lock } from 'proper-lockfile' import { reclaimReleaseTestCaches } from './reclaim-release-test-caches.mjs' -import { withReleaseSourceLease } from '../../../tests/e2e/cross-version-wire/release-source-retention' -import { CHECKOUT_FORMAT } from '../../../tests/e2e/cross-version-wire/release-checkout-publication' +import { withReleaseSourceLease } from '../../../tests/e2e/cross-version-wire/release-checkouts/release-source-retention' +import { CHECKOUT_FORMAT } from '../../../tests/e2e/cross-version-wire/release-checkouts/release-checkout-publication' const roots: string[] = [] const commit = 'c'.repeat(40) diff --git a/config/tsconfig.node.json b/config/tsconfig.node.json index 3be6835a659..e55f0e99659 100644 --- a/config/tsconfig.node.json +++ b/config/tsconfig.node.json @@ -42,7 +42,7 @@ "../src/types/**/*" ], "exclude": [ - "../src/main/runtime/orca-runtime-tests/browser-page-inventory.test.ts", + "../src/main/runtime/browser/client-pages/browser-page-inventory.test.ts", "../src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail.test.ts", "../src/main/github/pull-requests/refresh/pr-refresh-coordinator-local-delivery.test.ts" ], diff --git a/config/tsconfig.test.pane-launch.json b/config/tsconfig.test.pane-launch.json index c7aa3eff816..ecb82d6044b 100644 --- a/config/tsconfig.test.pane-launch.json +++ b/config/tsconfig.test.pane-launch.json @@ -2,7 +2,7 @@ "extends": "./tsconfig.web.json", "include": [ "../src/renderer/src/components/browser-pane/host-guest/browser-profile-native.test-fixture.ts", - "../src/main/runtime/orca-runtime-tests/browser-page-inventory.test.ts", + "../src/main/runtime/browser/client-pages/browser-page-inventory.test.ts", "../src/renderer/src/components/sidebar/workspace-creation/folder/folder-workspace-composer-submit-host-platform.test.ts", "../src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail.test.ts", "../src/main/github/pull-requests/refresh/pr-refresh-coordinator-local-delivery.test.ts", diff --git a/docs/readme/release-source-sharing.md b/docs/readme/release-source-sharing.md index c9204c4beb5..aea4fdb533f 100644 --- a/docs/readme/release-source-sharing.md +++ b/docs/readme/release-source-sharing.md @@ -99,7 +99,7 @@ Tests cover concurrent publication, lock heartbeats and eviction, independent br corrupt seeds, fallback, the opt-out, and preserved read-only files. Run them with: ```sh -ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/release-source-cache.unit.test.ts tests/e2e/cross-version-wire/release-source-retention.unit.test.ts tests/e2e/cross-version-wire/release-checkout.unit.test.ts tests/e2e/cross-version-wire/release-checkout-tree.unit.test.ts tests/e2e/cross-version-wire/release-missing-packages.unit.test.ts config/scripts/artifact-storage/reflink-copy/space-sharing-copy.test.ts +ORCA_BACKGROUND_LAUNCH=1 pnpm test tests/e2e/cross-version-wire/release-source-cache.unit.test.ts tests/e2e/cross-version-wire/release-checkouts/release-source-retention.unit.test.ts tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.unit.test.ts tests/e2e/cross-version-wire/release-checkouts/release-missing-packages.unit.test.ts config/scripts/artifact-storage/reflink-copy/space-sharing-copy.test.ts ``` ## P3 remains an experiment diff --git a/src/main/runtime/__fixtures__/orca-runtime-terminal-close-continuity-fixtures.ts b/src/main/runtime/__fixtures__/orca-runtime-terminal-close-continuity-fixtures.ts index fe3fcd12798..fad05e1b469 100644 --- a/src/main/runtime/__fixtures__/orca-runtime-terminal-close-continuity-fixtures.ts +++ b/src/main/runtime/__fixtures__/orca-runtime-terminal-close-continuity-fixtures.ts @@ -1,4 +1,4 @@ -import { withDurableRuntimeStore } from '../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../construction/test-context/runtime-durable-store-fixture' import { vi, type Mock } from 'vitest' import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' diff --git a/src/main/runtime/agent-session/launch/runtime-native-chat-draft-resolutions.spec.ts b/src/main/runtime/agent-session/launch/runtime-native-chat-draft-resolutions.spec.ts new file mode 100644 index 00000000000..4e40cf4e943 --- /dev/null +++ b/src/main/runtime/agent-session/launch/runtime-native-chat-draft-resolutions.spec.ts @@ -0,0 +1,138 @@ +import { describe, expect, it, vi } from 'vitest' +import { registerLivePty } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../../shared/workspace-layout/stable-pane-id' +import type { RuntimeClientEvent } from '../../../../shared/remote-runtime/session-graph/runtime-client-events' +import type { RuntimeSyncWindowGraph } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import { store } from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('routes a launch-draft resolution to the handle-owning local and remote renderers', async () => { + const runtime = new OrcaRuntimeService(store) + const nativeChatLaunchDraftResolved = vi.fn() + const events: RuntimeClientEvent[] = [] + runtime.setNotifier({ nativeChatLaunchDraftResolved } as never) + runtime.onClientEvent((event) => events.push(event)) + runtime.attachWindow(1) + const graph: RuntimeSyncWindowGraph = { + tabs: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + title: 'Claude', + activeLeafId: 'pane:1', + layout: null + } + ], + leaves: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + leafId: 'pane:1', + paneRuntimeId: 1, + ptyId: 'pty-1' + } + ], + mobileSessionTabs: [ + { + worktree: 'repo-1::/tmp/worktree-a', + publicationEpoch: 'launch-draft-epoch', + snapshotVersion: 1, + activeGroupId: 'group-1', + activeTabId: 'tab-1::pane:1', + activeTabType: 'terminal', + tabs: [ + { + type: 'terminal', + id: 'tab-1::pane:1', + parentTabId: 'tab-1', + leafId: 'pane:1', + title: 'Claude', + launchDraft: 'seed', + launchDraftCreatedAt: 7, + isActive: true + } + ] + } + ] + } + registerLivePty(runtime, 'pty-1', 'repo-1::/tmp/worktree-a', null, { + tabId: 'tab-1', + leafId: 'pane:1' + }) + await runtime.syncWindowGraph(1, graph) + const listed = await runtime.listMobileSessionTabs('branch:feature/foo') + const mobileTab = listed.tabs.find((tab) => tab.type === 'terminal') + if (!mobileTab?.terminal) { + throw new Error('expected mobile terminal handle') + } + expect(mobileTab).toMatchObject({ launchDraft: 'seed', launchDraftCreatedAt: 7 }) + + runtime.notifyNativeChatLaunchDraftResolved(mobileTab.terminal, { + text: 'seed', + createdAt: 7 + }) + + expect(nativeChatLaunchDraftResolved).toHaveBeenCalledWith('tab-1', { + text: 'seed', + createdAt: 7 + }) + expect(events).toContainEqual({ + type: 'nativeChatLaunchDraftResolved', + tabId: 'tab-1', + text: 'seed', + createdAt: 7 + }) + expect(runtime.getNativeChatLaunchDraftResolutionClientEventSnapshot()).toContainEqual({ + type: 'nativeChatLaunchDraftResolved', + tabId: 'tab-1', + text: 'seed', + createdAt: 7 + }) + const retired = (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( + (tab) => tab.type === 'terminal' + ) + expect(retired).not.toHaveProperty('launchDraft') + expect(retired).not.toHaveProperty('launchDraftCreatedAt') + + runtime.markRendererReloading(1) + const replay = await runtime.syncWindowGraph(1, { + ...graph, + mobileSessionTabs: graph.mobileSessionTabs?.map((snapshot) => ({ + ...snapshot, + publicationEpoch: 'launch-draft-reload', + snapshotVersion: 2 + })) + }) + expect(replay.nativeChatLaunchDraftResolutions).toEqual([ + { tabId: 'tab-1', text: 'seed', createdAt: 7 } + ]) + expect( + (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( + (tab) => tab.type === 'terminal' + ) + ).not.toHaveProperty('launchDraft') + + const reconciled = await runtime.syncWindowGraph(1, { + ...graph, + mobileSessionTabs: graph.mobileSessionTabs?.map((snapshot) => ({ + ...snapshot, + publicationEpoch: 'launch-draft-reload', + snapshotVersion: 3, + tabs: snapshot.tabs.map((tab) => { + if (tab.type !== 'terminal') { + return tab + } + return { ...tab, launchDraftCreatedAt: 8 } + }) + })) + }) + expect(reconciled.nativeChatLaunchDraftResolutions).toBeUndefined() + expect( + (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( + (tab) => tab.type === 'terminal' + ) + ).toMatchObject({ launchDraft: 'seed', launchDraftCreatedAt: 8 }) + }) +}) diff --git a/src/main/runtime/agent-session/lifecycle/structured-agent-session-tab-authority.test-support.ts b/src/main/runtime/agent-session/lifecycle/structured-agent-session-tab-authority.test-support.ts index b8741baa8d6..5d1ff5e43c6 100644 --- a/src/main/runtime/agent-session/lifecycle/structured-agent-session-tab-authority.test-support.ts +++ b/src/main/runtime/agent-session/lifecycle/structured-agent-session-tab-authority.test-support.ts @@ -31,7 +31,7 @@ import { createStructuredAgentSessionLogger } from '../../../native-chat/agent-s import { OrcaRuntimeService } from '../../orca-runtime' import { withChatTabChanges } from '../../session-tabs/chat/agent-session-tab-layout' import { collectSavedStructuredAgentSessionIds } from './saved-structured-agent-session-restoration' -import { chatTabCommandsSettled } from '../../orca-runtime-tests/session-layout-apply.test-fixture' +import { chatTabCommandsSettled } from '../../terminal/layout/session-layout-apply.test-fixture' import { stopStructuredAgentSessionRuntime } from '../installation/structured-agent-session-runtime' export const B = 'chat-b-0002', diff --git a/src/main/runtime/orca-runtime-tests/scripted-codex-transport.test-fixture.ts b/src/main/runtime/agent-session/testing/scripted-codex-transport.test-fixture.ts similarity index 73% rename from src/main/runtime/orca-runtime-tests/scripted-codex-transport.test-fixture.ts rename to src/main/runtime/agent-session/testing/scripted-codex-transport.test-fixture.ts index 2324d654929..ea61e86c740 100644 --- a/src/main/runtime/orca-runtime-tests/scripted-codex-transport.test-fixture.ts +++ b/src/main/runtime/agent-session/testing/scripted-codex-transport.test-fixture.ts @@ -1,5 +1,5 @@ -import { CODEX_MINIMUM_SUPPORTED_VERSION } from '../../../shared/agent-launch/startup/codex-cli-installation' -import type { StructuredAgentSessionRuntimeDeps } from '../agent-session/installation/structured-agent-session-runtime-contract' +import { CODEX_MINIMUM_SUPPORTED_VERSION } from '../../../../shared/agent-launch/startup/codex-cli-installation' +import type { StructuredAgentSessionRuntimeDeps } from '../installation/structured-agent-session-runtime-contract' /** Runtime deps that put a scripted Codex child where the real app-server would spawn. It speaks * the supported protocol, so it reports that version; its fake pid has a fixed start time. */ diff --git a/src/main/runtime/orca-runtime-tests/browser-capabilities.spec.ts b/src/main/runtime/browser/client-pages/browser-capabilities.spec.ts similarity index 54% rename from src/main/runtime/orca-runtime-tests/browser-capabilities.spec.ts rename to src/main/runtime/browser/client-pages/browser-capabilities.spec.ts index 0e812a401c6..5ee6cec02d3 100644 --- a/src/main/runtime/orca-runtime-tests/browser-capabilities.spec.ts +++ b/src/main/runtime/browser/client-pages/browser-capabilities.spec.ts @@ -1,20 +1,15 @@ import { describe, expect, it } from 'vitest' -import './runtime-test-module-registration.spec' -import '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import { getBrowserHostLeaseRegistry } from '../browser-host/leases/browser-host-lease-registry-instance' -import { getRuntimeBrowserPageRegistry } from '../browser/client-pages/runtime-browser-page-registry' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../browser-host/leases/browser-host-lease-registry-instance' +import { getRuntimeBrowserPageRegistry } from './runtime-browser-page-registry' import { - TEST_REPO_ID, TEST_WORKTREE_ID, - createRuntime, - store -} from './orca-runtime-test-fixtures.spec' -import { - attachClientBrowserHost, - publishClientHostedPage -} from './orca-runtime-test-scenario-builders.spec' -import '../../../shared/worktree/host-qualified-identity' + createRuntime +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' +import '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('preserves a live client page across headed renderer graph updates and prunes it after retirement', async () => { @@ -84,39 +79,4 @@ describe('OrcaRuntimeService', () => { }) expect((await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`)).tabs).toEqual([]) }) - - it('closes a worktree’s client-hosted browser pages when its metadata is removed (leak fix)', async () => { - const runtime = createRuntime() - const host = attachClientBrowserHost(runtime) - const removed = await publishClientHostedPage(runtime, host, 'page-removed', TEST_WORKTREE_ID) - const survivor = await publishClientHostedPage( - runtime, - host, - 'page-other', - `${TEST_REPO_ID}::/tmp/other` - ) - - runtime['removeWorktreeMetadataAndHistory'](store as never, TEST_WORKTREE_ID) - - expect(host.takeCommands()).toEqual([ - expect.objectContaining({ - browserPageId: 'page-removed', - pageHostGeneration: removed.pageHostGeneration, - command: { - type: 'closePage', - targetAuthority: { - authorityRuntimeId: runtime.getRuntimeId(), - authorityEpoch: getBrowserHostLeaseRegistry(runtime).authorityEpoch, - browserHostClientId: removed.browserHostClientId, - browserHostGeneration: removed.browserHostGeneration, - pageHostGeneration: removed.pageHostGeneration - } - } - }) - ]) - expect(getRuntimeBrowserPageRegistry(runtime).getPage('page-removed')).toBeUndefined() - expect(getRuntimeBrowserPageRegistry(runtime).getPage('page-other')?.placement).toEqual( - survivor - ) - }) }) diff --git a/src/main/runtime/orca-runtime-tests/browser-page-inventory.test.ts b/src/main/runtime/browser/client-pages/browser-page-inventory.test.ts similarity index 88% rename from src/main/runtime/orca-runtime-tests/browser-page-inventory.test.ts rename to src/main/runtime/browser/client-pages/browser-page-inventory.test.ts index f939dd2997a..03499d7d016 100644 --- a/src/main/runtime/orca-runtime-tests/browser-page-inventory.test.ts +++ b/src/main/runtime/browser/client-pages/browser-page-inventory.test.ts @@ -1,7 +1,7 @@ import { EventEmitter } from 'node:events' -import type { AppState } from '../../../renderer/src/store/types' +import type { AppState } from '../../../../renderer/src/store/types' import { afterEach, describe, expect, it, vi } from 'vitest' -import './orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { createRuntime, TEST_WORKTREE_ID, @@ -11,22 +11,22 @@ import { makeWorkspaceSessionWithHeadlessTerminal, makeHeadlessTerminalLayout, HEADLESS_LEAF_ID -} from './orca-runtime-test-fixtures.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { browserManager } from '../../browser/guest-lifecycle/manager/browser-manager' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import { buildMobileSessionTabSnapshots } from '../../../renderer/src/runtime/sync-runtime-graph/mobile-session-snapshots' -import { makeState } from '../../../renderer/src/runtime/sync-runtime-graph/testing/sync-runtime-graph-test-harness' -import { watchBrowserMainWindowReadiness } from '../../browser/guest-lifecycle/browser-main-window-readiness' -import { resolveTabRegistrationWaiters } from '../../ipc/browser/browser-tab-registration-wait' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { browserManager } from '../../../browser/guest-lifecycle/manager/browser-manager' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import { buildMobileSessionTabSnapshots } from '../../../../renderer/src/runtime/sync-runtime-graph/mobile-session-snapshots' +import { makeState } from '../../../../renderer/src/runtime/sync-runtime-graph/testing/sync-runtime-graph-test-harness' +import { watchBrowserMainWindowReadiness } from '../../../browser/guest-lifecycle/browser-main-window-readiness' +import { resolveTabRegistrationWaiters } from '../../../ipc/browser/browser-tab-registration-wait' import type { BrowserPage, BrowserWorkspace -} from '../../../shared/browser/workspaces/browser-workspace-types' +} from '../../../../shared/browser/workspaces/browser-workspace-types' import type { RuntimeMobileSessionTabsResult, RuntimeSyncWindowGraph -} from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' +} from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' const workspace: BrowserWorkspace = { id: 'browser-w', @@ -317,30 +317,6 @@ describe('accepted saved browser page inventory', () => { unsubscribe() }) - it.each([10, 100])('keeps hidden sibling churn local with %i saved pages', async (count) => { - vi.useFakeTimers() - const { runtime, sync, list } = fixture() - const hidden = Array.from({ length: count }, (_, index) => page(`saved-${index}`)) - await sync(publication([...hidden, page('C')])) - await vi.advanceTimersByTimeAsync(100) - const initial = await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`) - expect(initial.tabs).toEqual( - expect.arrayContaining([expect.objectContaining({ browserPageId: 'C', title: 'C' })]) - ) - const events: RuntimeMobileSessionTabsResult[] = [] - const unsubscribe = runtime.onMobileSessionTabsChanged((snapshot) => events.push(snapshot)) - await sync( - publication([...hidden.map((entry) => ({ ...entry, title: 'Updated sibling' })), page('C')]) - ) - await vi.advanceTimersByTimeAsync(100) - expect((await list()).tabs.filter((entry) => entry.title === 'Updated sibling')).toHaveLength( - count - ) - expect(await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`)).toEqual(initial) - expect(events).toEqual([]) - unsubscribe() - }) - it('keeps a simultaneous graph-only visible change after an inventory-only acceptance', async () => { vi.useFakeTimers() const { runtime, sync, list } = fixture() diff --git a/src/main/runtime/browser/client-pages/renderer-browser-lifecycle.test.ts b/src/main/runtime/browser/client-pages/renderer-browser-lifecycle.test.ts index 7bff0f40654..e8bf150adb8 100644 --- a/src/main/runtime/browser/client-pages/renderer-browser-lifecycle.test.ts +++ b/src/main/runtime/browser/client-pages/renderer-browser-lifecycle.test.ts @@ -1,12 +1,15 @@ -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { expect, it, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' -import { TEST_WORKTREE_ID, store } from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import '../../../../shared/orca-profiles/constants' import type { BrowserTabInfo } from '../../../../shared/browser/runtime/runtime-browser-contracts' diff --git a/src/main/runtime/browser/client-pages/renderer-browser-ownership.test.ts b/src/main/runtime/browser/client-pages/renderer-browser-ownership.test.ts index e61e0e113ac..00f4e06f07f 100644 --- a/src/main/runtime/browser/client-pages/renderer-browser-ownership.test.ts +++ b/src/main/runtime/browser/client-pages/renderer-browser-ownership.test.ts @@ -1,12 +1,15 @@ -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { expect, it, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' -import { TEST_WORKTREE_ID, store } from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import type { RuntimeMobileSessionTabsSnapshot } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' diff --git a/src/main/runtime/browser/commands/browser-page-targeting.spec.ts b/src/main/runtime/browser/commands/browser-page-targeting.spec.ts new file mode 100644 index 00000000000..b93e81b1d67 --- /dev/null +++ b/src/main/runtime/browser/commands/browser-page-targeting.spec.ts @@ -0,0 +1,127 @@ +import { describe, expect, it, vi } from 'vitest' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../../../shared/workspace-layout/layout-owner-switch' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { MOCK_GIT_WORKTREES, electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import '../../orca-runtime' +import { AgentBrowserBridge } from '../../../browser/agent-browser/agent-browser-bridge' + +import '../../../git/worktrees/removal/worktree-removal-preflight' +import 'electron' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import '../../../git/worktrees/removal/worktree-removal' +import { + TEST_REPO_ID, + createRuntime +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' + +function createBrowserBridge(overrides: Partial): AgentBrowserBridge { + return Object.assign(vi.mockObject(AgentBrowserBridge.prototype), overrides) +} + +describe('OrcaRuntimeService', () => { + describe('browser page targeting', () => { + function mockLiveBrowserGuest(): void { + electronMocks.webContents.fromId.mockReturnValue({ + isDestroyed: () => false, + isLoading: () => false + }) + } + + it('does not silently drop invalid explicit worktree selectors for page-targeted commands', async () => { + vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) + mockLiveBrowserGuest() + const runtime = createRuntime() + const snapshotMock = vi.fn() + + runtime.setAgentBrowserBridge( + createBrowserBridge({ + snapshot: snapshotMock, + getRegisteredTabs: vi.fn(() => new Map([['page-1', 1]])), + getRegisteredPageWebContentsId: (page: string) => (page === 'page-1' ? 1 : undefined) + }) + ) + + await expect( + runtime.browserSnapshot({ + worktree: 'path:/tmp/missing-worktree', + page: 'page-1' + }) + ).rejects.toThrow('selector_not_found') + expect(snapshotMock).not.toHaveBeenCalled() + }) + + it('does not silently drop invalid explicit worktree selectors for non-page browser commands', async () => { + vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) + const runtime = createRuntime() + const tabListMock = vi.fn() + + runtime.setAgentBrowserBridge( + createBrowserBridge({ + tabList: tabListMock + }) + ) + + await expect( + runtime.browserTabList({ + worktree: 'path:/tmp/missing-worktree' + }) + ).rejects.toThrow('selector_not_found') + expect(tabListMock).not.toHaveBeenCalled() + }) + + it('rejects closing an unknown page id instead of treating it as success', async () => { + vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) + mockLiveBrowserGuest() + const runtime = createRuntime() + + runtime.setAgentBrowserBridge( + createBrowserBridge({ + getRegisteredTabs: vi.fn(() => new Map([['page-1', 1]])), + getRegisteredPageWebContentsId: (page: string) => (page === 'page-1' ? 1 : undefined) + }) + ) + + await expect( + runtime.browserTabClose({ + page: 'missing-page' + }) + ).rejects.toThrow('Browser page missing-page was not found') + }) + + it('rejects closing a page outside the explicitly scoped worktree', async () => { + mockLiveBrowserGuest() + vi.mocked(listWorktrees).mockResolvedValue([ + ...MOCK_GIT_WORKTREES, + { + path: '/tmp/worktree-b', + head: 'def', + branch: 'feature/bar', + isBare: false, + isMainWorktree: false + } + ]) + const runtime = createRuntime() + const getRegisteredTabsMock = vi.fn((worktreeId?: string) => + worktreeId === `${TEST_REPO_ID}::/tmp/worktree-b` ? new Map() : new Map([['page-1', 1]]) + ) + + runtime.setAgentBrowserBridge( + createBrowserBridge({ + getRegisteredTabs: getRegisteredTabsMock, + getRegisteredPageWebContentsId: (page: string, worktreeId?: string) => + getRegisteredTabsMock(worktreeId).get(page) + }) + ) + + await expect( + runtime.browserTabClose({ + page: 'page-1', + worktree: 'path:/tmp/worktree-b' + }) + ).rejects.toThrow('Browser page page-1 was not found in this worktree') + expect(getRegisteredTabsMock).toHaveBeenCalledWith(`${TEST_REPO_ID}::/tmp/worktree-b`) + }) + }) +}) diff --git a/src/main/runtime/browser/headless/orca-runtime-serve-browser-restore.test.ts b/src/main/runtime/browser/headless/orca-runtime-serve-browser-restore.test.ts index 502593fb92b..6d189e2109a 100644 --- a/src/main/runtime/browser/headless/orca-runtime-serve-browser-restore.test.ts +++ b/src/main/runtime/browser/headless/orca-runtime-serve-browser-restore.test.ts @@ -1,12 +1,12 @@ -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { describe, expect, it, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { withOpenedServeBrowserTab } from './serve-browser-tab-layout' import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' diff --git a/src/main/runtime/client/peer-desktops.integration.test.ts b/src/main/runtime/client/peer-desktops.integration.test.ts index 8abff0284f4..de6d425e518 100644 --- a/src/main/runtime/client/peer-desktops.integration.test.ts +++ b/src/main/runtime/client/peer-desktops.integration.test.ts @@ -29,7 +29,7 @@ import { } from '../rpc/server/runtime-rpc-mobile-ws-test-harness' import { makeStore } from '../rpc/server/runtime-rpc-worktree-store-fixtures' import { DECLARED_CLIENT_RECONNECT_GRACE_MS } from '../rpc/server/pairing/declared-desktop-clients' -import { partialRuntimeStore } from '../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../construction/test-context/runtime-store-partial-fixture' vi.mock('../../git/worktrees/catalog/worktree-scan-cache', async (importOriginal) => { const facade = getWorktreeListingMocks() diff --git a/src/main/runtime/construction/orca-runtime.test.ts b/src/main/runtime/construction/orca-runtime.test.ts index 761a0f74383..9b2ab9ae637 100644 --- a/src/main/runtime/construction/orca-runtime.test.ts +++ b/src/main/runtime/construction/orca-runtime.test.ts @@ -7,80 +7,83 @@ vi.mock('node:fs/promises', async (importOriginal) => { return { ...actual, mkdir: vi.fn(actual.mkdir) } }) -await import('../orca-runtime-tests/runtime-test-module-registration.spec') -await import('../orca-runtime-tests/orca-runtime-test-lifecycle.spec') -await import('../orca-runtime-tests/orca-runtime-test-fixtures.spec') -await import('../orca-runtime-tests/orca-runtime-test-scenario-builders.spec') +await import('./test-context/runtime-test-module-registration.spec') +await import('./test-context/orca-runtime-test-lifecycle.spec') +await import('./test-context/orca-runtime-test-fixtures.spec') +await import('./test-context/orca-runtime-test-scenario-builders.spec') -await import('../orca-runtime-tests/browser-capabilities.spec') -await import('../orca-runtime-tests/window-authority.spec') -await import('../orca-runtime-tests/terminal-handles.spec') -await import('../orca-runtime-tests/terminal-handles-part-02.spec') -await import('../orca-runtime-tests/terminal-listing.spec') -await import('../orca-runtime-tests/worktree-selector-resolution.spec') -await import('../orca-runtime-tests/local-worktree-creation.spec') -await import('../orca-runtime-tests/hooks-and-hosted-review-part-02.spec') -await import('../orca-runtime-tests/repository-project-operations-part-02.spec') -await import('../orca-runtime-tests/project-setup-folder-remote-identity.spec') -await import('../orca-runtime-tests/terminal-side-effect-facts-part-02.spec') -await import('../orca-runtime-tests/headless-snapshots.spec') -await import('../orca-runtime-tests/agent-status-and-waits-part-02.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness.spec') -await import('../orca-runtime-tests/runtime-orchestration-db.test-fixture') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-04.spec') +await import('../browser/client-pages/browser-capabilities.spec') +await import('../session-graph/window-authority.spec') +await import('../agent-session/launch/runtime-native-chat-draft-resolutions.spec') +await import('../terminal/identity/terminal-handles.spec') +await import('../terminal/identity/terminal-handles-part-02.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-06.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-08.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-09.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-10.spec') -await import('../orca-runtime-tests/terminal-creation-and-readiness-part-11.spec') -await import('../orca-runtime-tests/conpty-stream-read.spec') -await import('../orca-runtime-tests/terminal-output-and-worker-recovery-part-02.spec') +await import('../workspaces/catalog/worktree-selector-resolution.spec') +await import('../workspaces/creation/local-worktree-creation.spec') +await import('../workspaces/references/hooks-and-hosted-review-part-02.spec') +await import('../repositories/repository-project-operations-part-02.spec') +await import('../repositories/project-setup-folder-remote-identity.spec') +await import('../terminal/output/terminal-side-effect-facts-part-02.spec') +await import('../terminal/output/headless-snapshots.spec') +await import('../terminal/query/agent-status-and-waits-part-02.spec') +await import('../orchestration/terminal-authority/terminal-creation-and-readiness.spec') +await import('../orchestration/db/runtime-orchestration-db.test-fixture') +await import('../terminal/launch/terminal-creation-and-readiness-part-04.spec') -await import('../orca-runtime-tests/terminal-output-and-worker-recovery-part-06.spec') -await import('../orca-runtime-tests/terminal-output-and-worker-recovery-part-07.spec') -await import('../orca-runtime-tests/terminal-handles-and-agent-status.spec') -await import('../orca-runtime-tests/terminal-handles-and-agent-status-part-04.spec') -await import('../orca-runtime-tests/terminal-handles-and-agent-status-part-05.spec') -await import('../orca-runtime-tests/mobile-session-tabs.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-02.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-03.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-04.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-05.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-07.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-08.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-09.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-10.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-11.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-12.spec') -await import('../orca-runtime-tests/mobile-session-tabs-part-13.spec') -await import('../orca-runtime-tests/mobile-session-tabs-empty-headless-snapshot.spec') -await import('../orca-runtime-tests/mobile-session-tabs-windowless-sleep-resume.spec') -await import('../orca-runtime-tests/mobile-session-tabs-targeted-agent-resume.spec') -await import('../orca-runtime-tests/exit-retirement-activation.spec') -await import('../orca-runtime-tests/mobile-creation-and-orchestration.spec') -await import('../orca-runtime-tests/mobile-creation-and-orchestration-part-04.spec') -await import('../orca-runtime-tests/mobile-summaries.spec') -await import('../orca-runtime-tests/mobile-summaries-part-02.spec') -await import('../orca-runtime-tests/mobile-summaries-part-03.spec') -await import('../orca-runtime-tests/mobile-summaries-part-04.spec') -await import('../orca-runtime-tests/worktree-ps-structured-host.spec') -await import('../orca-runtime-tests/worktree-ps-agent-wait.spec') -await import('../orca-runtime-tests/terminal-sleep-and-teardown.spec') -await import('../orca-runtime-tests/terminal-sleep-and-teardown-part-02.spec') -await import('../orca-runtime-tests/terminal-sleep-and-teardown-part-03.spec') -await import('../orca-runtime-tests/lineage-and-scan-cache.spec') -await import('../orca-runtime-tests/lineage-and-scan-cache-part-02.spec') -await import('../orca-runtime-tests/lineage-and-scan-cache-part-05.spec') -await import('../orca-runtime-tests/wsl-stopped-distro-worktree-scan.spec') +await import('../terminal/wait/terminal-creation-and-readiness-part-06.spec') +await import('../terminal/focus/terminal-creation-and-readiness-part-08.spec') +await import('../terminal/query/terminal-creation-and-readiness-part-09.spec') +await import('../terminal/query/terminal-creation-and-readiness-part-10.spec') +await import('../terminal/output/terminal-creation-and-readiness-part-11.spec') +await import('../terminal/query/conpty-stream-read.spec') +await import('../terminal/adoption/terminal-output-and-worker-recovery-part-02.spec') -await import('../orca-runtime-tests/worktree-setup-and-startup-part-03.spec') -await import('../orca-runtime-tests/worktree-setup-and-startup-part-04.spec') +await import('../terminal/adoption/terminal-output-and-worker-recovery-part-06.spec') +await import('../terminal/adoption/terminal-output-and-worker-recovery-part-07.spec') +await import('../terminal/identity/terminal-handles-and-agent-status.spec') +await import('../terminal/adoption/terminal-handles-and-agent-status-part-04.spec') -await import('../orca-runtime-tests/gitlab-and-pr-bases-part-02.spec') -await import('../orca-runtime-tests/worktree-removal-and-reconciliation-part-02.spec') -await import('../orca-runtime-tests/worktree-removal-and-reconciliation-part-03.spec') -await import('../orca-runtime-tests/worktree-removal-and-reconciliation-part-04.spec') -await import('../orca-runtime-tests/worktree-removal-failed-retry.spec') -await import('../orca-runtime-tests/targeting-and-resilience.spec') -await import('../orca-runtime-tests/worktree-scan-cache-ttl.spec') +await import('../session-tabs/publication/mobile-session-tabs.spec') +await import('../session-tabs/restoration/mobile-session-tabs-part-02.spec') +await import('../session-tabs/layout/mobile-session-tabs-part-03.spec') +await import('../session-tabs/terminal-retirement/mobile-session-tabs-part-04.spec') +await import('../session-tabs/terminal-retirement/mobile-session-tabs-part-05.spec') +await import('../session-tabs/restoration/mobile-session-tabs-part-07.spec') +await import('../session-tabs/restoration/mobile-session-tabs-part-08.spec') +await import('../session-tabs/publication/mobile-session-tabs-part-09.spec') +await import('../session-tabs/terminal-retirement/mobile-session-tabs-part-10.spec') +await import('../session-tabs/terminal-retirement/mobile-session-tabs-part-11.spec') +await import('../session-tabs/layout/mobile-session-tabs-part-12.spec') +await import('../session-tabs/layout/mobile-session-tabs-part-13.spec') +await import('../session-tabs/inventory/mobile-session-tabs-empty-headless-snapshot.spec') +await import('../session-tabs/restoration/mobile-session-tabs-windowless-sleep-resume.spec') +await import('../session-lifecycle/projection/mobile-session-tabs-targeted-agent-resume.spec') +await import('../session-tabs/terminal-retirement/exit-retirement-activation.spec') +await import('../session-tabs/layout/mobile-creation-and-orchestration.spec') +await import('../terminal/wait/mobile-creation-and-orchestration-part-04.spec') +await import('../sidebar-inputs/workspace-facts/mobile-summaries.spec') +await import('../sidebar-inputs/workspace-facts/mobile-summaries-part-02.spec') +await import('../sidebar-inputs/workspace-facts/mobile-summaries-part-03.spec') +await import('../sidebar-inputs/workspace-facts/mobile-summaries-part-04.spec') +await import('../workspaces/process-listing/worktree-ps-structured-host.spec') +await import('../workspaces/process-listing/worktree-ps-agent-wait.spec') +await import('../terminal/stop/terminal-sleep-and-teardown.spec') +await import('../terminal/stop/terminal-sleep-and-teardown-part-02.spec') +await import('../push/notifications/runtime-mobile-notification-controller.spec') +await import('../terminal/stop/terminal-sleep-idempotency-and-convergence.spec') +await import('../terminal/stop/terminal-sleep-and-teardown-part-03.spec') +await import('../terminal/query/terminal-listing-fresh-liveness.spec') +await import('../workspaces/lineage/lineage-and-scan-cache.spec') +await import('../workspaces/lineage/lineage-and-scan-cache-part-02.spec') +await import('../orchestration/terminal-authority/lineage-and-scan-cache-part-05.spec') + +await import('../workspaces/startup/worktree-setup-and-startup-part-03.spec') + +await import('../workspaces/references/gitlab-and-pr-bases-part-02.spec') +await import('../workspaces/removal/worktree-removal-and-reconciliation-part-02.spec') +await import('../workspaces/removal/worktree-removal-and-reconciliation-part-03.spec') +await import('../workspaces/removal/worktree-removal-and-reconciliation-part-04.spec') +await import('../workspaces/removal/worktree-removal-failed-retry.spec') +await import('../browser/commands/browser-page-targeting.spec') +await import('../workspaces/removal/runtime-worktree-removal-pty-stop.spec') +await import('../session-tabs/layout/mobile-terminal-create-resilience.spec') diff --git a/src/main/runtime/orca-runtime-tests/orca-runtime-test-fixtures.spec.ts b/src/main/runtime/construction/test-context/orca-runtime-test-fixtures.spec.ts similarity index 89% rename from src/main/runtime/orca-runtime-tests/orca-runtime-test-fixtures.spec.ts rename to src/main/runtime/construction/test-context/orca-runtime-test-fixtures.spec.ts index 5cd57c64ab6..8ce5180cc28 100644 --- a/src/main/runtime/orca-runtime-tests/orca-runtime-test-fixtures.spec.ts +++ b/src/main/runtime/construction/test-context/orca-runtime-test-fixtures.spec.ts @@ -3,42 +3,42 @@ import { afterEach, beforeEach, expect, vi } from 'vitest' import { forgetInstalledPaneSession, announceSessionWrites -} from '../terminal/layout/profile-session-store.test-fixture' +} from '../../terminal/layout/profile-session-store.test-fixture' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' import { createHash } from 'node:crypto' -import { HeadlessEmulator } from '../../daemon/emulation/headless-emulator' -import { OrcaRuntimeService } from '../orca-runtime' +import { HeadlessEmulator } from '../../../daemon/emulation/headless-emulator' +import { OrcaRuntimeService } from '../../orca-runtime' import { buildAgentPromptPasteBytes, getTerminalPasteIngestMs -} from '../../../shared/agent-launch/startup/agent-prompt-injection' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import type { LayoutCommand } from '../../../shared/workspace-layout/workspace-layout-command-types' -import { applyCommandToSession } from '../../persistence/terminal-topology/pane-admission/terminal-pane-admission' -import { resolveHostId } from '../../persistence/loading-store/workspace-sessions/session-host-partitions' -import { toComparableRelaySshPtyId } from '../../../shared/remote-runtime/ssh/ssh-pty-id' -import '../terminal/launch/spawned-pty-env-fixtures' +} from '../../../../shared/agent-launch/startup/agent-prompt-injection' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' +import type { LayoutCommand } from '../../../../shared/workspace-layout/workspace-layout-command-types' +import { applyCommandToSession } from '../../../persistence/terminal-topology/pane-admission/terminal-pane-admission' +import { resolveHostId } from '../../../persistence/loading-store/workspace-sessions/session-host-partitions' +import { toComparableRelaySshPtyId } from '../../../../shared/remote-runtime/ssh/ssh-pty-id' +import '../../terminal/launch/spawned-pty-env-fixtures' import './runtime-test-module-registration.spec' import { computeWorktreePathMock, ensurePathWithinWorkspaceMock -} from '../orca-runtime-test-mocks/setup.spec' -import type { ProjectGroup } from '../../../shared/project/groups/project-group-types' -import type { RpcRequest } from '../rpc/core' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' -import type { TerminalLayoutSnapshot } from '../../../shared/workspace-layout/terminal-tab-types' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import type { AgentStatusIpcPayload } from '../../../shared/agent-status/contracts/agent-status-ipc-payload' +} from '../../orca-runtime-test-mocks/setup.spec' +import type { ProjectGroup } from '../../../../shared/project/groups/project-group-types' +import type { RpcRequest } from '../../rpc/core' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' +import type { TerminalLayoutSnapshot } from '../../../../shared/workspace-layout/terminal-tab-types' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' -import type { FolderWorkspace } from '../../../shared/folder-workspaces/folder-workspace-types' -import '../orchestration/mailbox/terminal-pointer/in-memory-orchestration-messages.spec' -import type { InMemoryOrchestrationMessages } from '../orchestration/mailbox/terminal-pointer/in-memory-orchestration-messages.spec' -import type { OrchestrationDb } from '../orchestration/db/orchestration-db' -import type { TerminalProcessInspection as PtyProcessInspection } from '../../../shared/terminal/pty/lifecycle/terminal-process-inspection' -import type { Store } from '../../persistence/loading-store/store' -import type { HostWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' +import type { FolderWorkspace } from '../../../../shared/folder-workspaces/folder-workspace-types' +import '../../orchestration/mailbox/terminal-pointer/in-memory-orchestration-messages.spec' +import type { InMemoryOrchestrationMessages } from '../../orchestration/mailbox/terminal-pointer/in-memory-orchestration-messages.spec' +import type { OrchestrationDb } from '../../orchestration/db/orchestration-db' +import type { TerminalProcessInspection as PtyProcessInspection } from '../../../../shared/terminal/pty/lifecycle/terminal-process-inspection' +import type { Store } from '../../../persistence/loading-store/store' +import type { HostWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' type RuntimeService = InstanceType type HeadlessTerminal = InstanceType diff --git a/src/main/runtime/orca-runtime-tests/orca-runtime-test-lifecycle.spec.ts b/src/main/runtime/construction/test-context/orca-runtime-test-lifecycle.spec.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/orca-runtime-test-lifecycle.spec.ts rename to src/main/runtime/construction/test-context/orca-runtime-test-lifecycle.spec.ts index cb666318f84..2225502d492 100644 --- a/src/main/runtime/orca-runtime-tests/orca-runtime-test-lifecycle.spec.ts +++ b/src/main/runtime/construction/test-context/orca-runtime-test-lifecycle.spec.ts @@ -82,56 +82,56 @@ import { updateGitLabIssueMock, updateGitLabMRMock, updateGitLabMRReviewersMock -} from '../orca-runtime-test-mocks/setup.spec' -import { RuntimeBrowserCommands } from '../browser/commands/browser-commands' -import { _resetTerminalViewAttributesForTest } from '../terminal/view/terminal-view-attribute-store' -import { addSparseWorktree } from '../../git/worktrees/creation/worktree-sparse-add' -import { addWorktree } from '../../git/worktrees/creation/worktree-add' -import { advertisedUrlWatcher } from '../../ports/advertised-url-watcher' +} from '../../orca-runtime-test-mocks/setup.spec' +import { RuntimeBrowserCommands } from '../../browser/commands/browser-commands' +import { _resetTerminalViewAttributesForTest } from '../../terminal/view/terminal-view-attribute-store' +import { addSparseWorktree } from '../../../git/worktrees/creation/worktree-sparse-add' +import { addWorktree } from '../../../git/worktrees/creation/worktree-add' +import { advertisedUrlWatcher } from '../../../ports/advertised-url-watcher' import { afterAll, afterEach, beforeAll, beforeEach, vi, type MockInstance } from 'vitest' -import { initOrcaProfilePaths } from '../../orca-profiles/profile-storage-paths' -import { stopStructuredAgentSessionRuntime } from '../agent-session/installation/structured-agent-session-runtime' -import { assertWorktreeCleanForRemoval } from '../../git/worktrees/removal/worktree-removal-preflight' -import { __cancelLegacyWorkerTerminalRecoveryRetriesForTests as cancelLegacyWorkerTerminalRecoveryRetriesForTests } from '../orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-controller' -import { clearConfiguredWorktreeSharedDirectoriesCacheForTests } from '../../git/worktrees/content-paths/worktree-shared-directories' +import { initOrcaProfilePaths } from '../../../orca-profiles/profile-storage-paths' +import { stopStructuredAgentSessionRuntime } from '../../agent-session/installation/structured-agent-session-runtime' +import { assertWorktreeCleanForRemoval } from '../../../git/worktrees/removal/worktree-removal-preflight' +import { __cancelLegacyWorkerTerminalRecoveryRetriesForTests as cancelLegacyWorkerTerminalRecoveryRetriesForTests } from '../../orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-controller' +import { clearConfiguredWorktreeSharedDirectoriesCacheForTests } from '../../../git/worktrees/content-paths/worktree-shared-directories' import { createSetupRunnerScript, resolveSetupRunnerShell -} from '../../workspace-hooks/worktree-runner-script' +} from '../../../workspace-hooks/worktree-runner-script' import { describeCreatedWorktree, listWorktreesStrict -} from '../../git/worktrees/catalog/worktree-listing' +} from '../../../git/worktrees/catalog/worktree-listing' import { getDefaultTabsLaunch, getEffectiveHooksFromConfig, shouldRunSetupForCreate -} from '../../workspace-hooks/effective-hook-config' -import { getEffectiveHooks, hasHooksFile, loadHooks, runHook } from '../../workspace-hooks/hooks' -import { installFakeAppEnvironment } from '../../../../config/scripts/test-runtime/environment/vitest-host-ports-setup' +} from '../../../workspace-hooks/effective-hook-config' +import { getEffectiveHooks, hasHooksFile, loadHooks, runHook } from '../../../workspace-hooks/hooks' +import { installFakeAppEnvironment } from '../../../../../config/scripts/test-runtime/environment/vitest-host-ports-setup' import { listWorktrees, listWorktreesSharedStrict -} from '../../git/worktrees/catalog/worktree-scan-cache' -import { parseOrcaYaml } from '../../../shared/workspace-setup/orca-yaml' -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' +} from '../../../git/worktrees/catalog/worktree-scan-cache' +import { parseOrcaYaml } from '../../../../shared/workspace-setup/orca-yaml' +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' import { setRuntimeBrowserCommandsFactory, setRuntimeBrowserUnavailableCause -} from '../browser/installation/runtime-browser-commands-factory' -import { setRuntimeDesktopSurface } from '../construction/runtime-desktop-surface' -import { setRuntimeTerminalUnavailableCause } from '../terminal/launch/native-terminal-availability' -import { OrcaRuntimeService as runtimeMockOrcaRuntimeService } from '../orca-runtime' +} from '../../browser/installation/runtime-browser-commands-factory' +import { setRuntimeDesktopSurface } from '../runtime-desktop-surface' +import { setRuntimeTerminalUnavailableCause } from '../../terminal/launch/native-terminal-availability' +import { OrcaRuntimeService as runtimeMockOrcaRuntimeService } from '../../orca-runtime' -import * as worktreeChangeInvalidators from '../../ipc/worktrees/listing/worktree-change-invalidators' -import { awaitBackgroundRemovalsInRuntimeTests } from '../workspaces/removal/orca-runtime-background-removal-test-support' -import { commitFakeSpawnsInRuntimeTests } from './bind-first-pane.test-fixture' +import * as worktreeChangeInvalidators from '../../../ipc/worktrees/listing/worktree-change-invalidators' +import { awaitBackgroundRemovalsInRuntimeTests } from '../../workspaces/removal/orca-runtime-background-removal-test-support' +import { commitFakeSpawnsInRuntimeTests } from '../../terminal/layout/bind-first-pane.test-fixture' import { _resetPendingWorktreeRemovalsForTests, _settlePendingWorktreeRemovalsForTests -} from '../../workspaces/removal/worktree-background-removal' -import { _resetCanonicalRepoKeyCacheForTests } from '../../git/repositories/canonical-repo-key' -import { setWorktreeRemovalRecordsDirectory } from '../../workspaces/removal/worktree-removal-table' +} from '../../../workspaces/removal/worktree-background-removal' +import { _resetCanonicalRepoKeyCacheForTests } from '../../../git/repositories/canonical-repo-key' +import { setWorktreeRemovalRecordsDirectory } from '../../../workspaces/removal/worktree-removal-table' awaitBackgroundRemovalsInRuntimeTests(runtimeMockOrcaRuntimeService.prototype) commitFakeSpawnsInRuntimeTests(runtimeMockOrcaRuntimeService.prototype) diff --git a/src/main/runtime/orca-runtime-tests/orca-runtime-test-scenario-builders.spec.ts b/src/main/runtime/construction/test-context/orca-runtime-test-scenario-builders.spec.ts similarity index 92% rename from src/main/runtime/orca-runtime-tests/orca-runtime-test-scenario-builders.spec.ts rename to src/main/runtime/construction/test-context/orca-runtime-test-scenario-builders.spec.ts index b8bace4369a..663370270c3 100644 --- a/src/main/runtime/orca-runtime-tests/orca-runtime-test-scenario-builders.spec.ts +++ b/src/main/runtime/construction/test-context/orca-runtime-test-scenario-builders.spec.ts @@ -1,13 +1,13 @@ -import * as gitExecFile from '../../git/command-runner/git-exec-file' -import { CrewChanges } from '../orchestration/crew/crew-changes' +import * as gitExecFile from '../../../git/command-runner/git-exec-file' +import { CrewChanges } from '../../orchestration/crew/crew-changes' import { withDurableRuntimeStore } from './runtime-durable-store-fixture' import './runtime-test-module-registration.spec' -import { HEADLESS_RUNTIME_WINDOW_ID } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import { getBrowserHostLeaseRegistry } from '../browser-host/leases/browser-host-lease-registry-instance' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import { getRuntimeBrowserPageRegistry } from '../browser/client-pages/runtime-browser-page-registry' +import { HEADLESS_RUNTIME_WINDOW_ID } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import { getBrowserHostLeaseRegistry } from '../../browser-host/leases/browser-host-lease-registry-instance' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import { getRuntimeBrowserPageRegistry } from '../../browser/client-pages/runtime-browser-page-registry' import { vi } from 'vitest' import type { Mock } from 'vitest' @@ -19,11 +19,11 @@ const { TEST_WORKTREE_PATH, makeHeadlessTerminalLayout, makeRuntimeStoreWithWork fixtures const { makeWorkspaceSessionWithHeadlessTerminal, store } = fixtures -import type { RuntimeBrowserClientPlacement } from '../../../shared/browser/client-hosting/runtime-browser-placement' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import type { BrowserClientHostCommandEvent } from '../../../shared/browser/client-hosting/browser-client-host-protocol' -import type { TerminalSideEffectBatch } from '../../../shared/terminal/output/terminal-side-effect-facts' -import type { OrchestrationDb } from '../orchestration/db/orchestration-db' +import type { RuntimeBrowserClientPlacement } from '../../../../shared/browser/client-hosting/runtime-browser-placement' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import type { BrowserClientHostCommandEvent } from '../../../../shared/browser/client-hosting/browser-client-host-protocol' +import type { TerminalSideEffectBatch } from '../../../../shared/terminal/output/terminal-side-effect-facts' +import type { OrchestrationDb } from '../../orchestration/db/orchestration-db' type RuntimeService = InstanceType type TestMock = Mock diff --git a/src/main/runtime/orca-runtime-tests/runtime-durable-store-fixture.ts b/src/main/runtime/construction/test-context/runtime-durable-store-fixture.ts similarity index 85% rename from src/main/runtime/orca-runtime-tests/runtime-durable-store-fixture.ts rename to src/main/runtime/construction/test-context/runtime-durable-store-fixture.ts index 82f00edb76e..d6d671a4f4d 100644 --- a/src/main/runtime/orca-runtime-tests/runtime-durable-store-fixture.ts +++ b/src/main/runtime/construction/test-context/runtime-durable-store-fixture.ts @@ -1,18 +1,18 @@ -import type { DurableProfileStateMutation } from '../../persistence/loading-store/store-runtime-state' -import { profileStateWriterFailureOutcome } from '../../persistence/profile-state/writer/profile-state-writer-errors' -import { resolveHostId } from '../../persistence/loading-store/workspace-sessions/session-host-partitions' +import type { DurableProfileStateMutation } from '../../../persistence/loading-store/store-runtime-state' +import { profileStateWriterFailureOutcome } from '../../../persistence/profile-state/writer/profile-state-writer-errors' +import { resolveHostId } from '../../../persistence/loading-store/workspace-sessions/session-host-partitions' import { admitPaneToSession, withdrawPaneFromSession, type PaneLayoutChange, type TerminalPaneAdmission -} from '../../persistence/terminal-topology/pane-admission/terminal-pane-admission' +} from '../../../persistence/terminal-topology/pane-admission/terminal-pane-admission' import type { CommandOf, LayoutRefusalCode -} from '../../../shared/workspace-layout/workspace-layout-command-types' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import { clearReplacedPaneBinding } from '../../persistence/loading-store/terminal-bindings/replaced-pane-binding' +} from '../../../../shared/workspace-layout/workspace-layout-command-types' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import { clearReplacedPaneBinding } from '../../../persistence/loading-store/terminal-bindings/replaced-pane-binding' /** Keep runtime fakes on the same reserved, durable-before-ack contract as Store. */ export function withDurableRuntimeStore< diff --git a/src/main/runtime/orca-runtime-tests/runtime-store-partial-fixture.ts b/src/main/runtime/construction/test-context/runtime-store-partial-fixture.ts similarity index 85% rename from src/main/runtime/orca-runtime-tests/runtime-store-partial-fixture.ts rename to src/main/runtime/construction/test-context/runtime-store-partial-fixture.ts index d468f1490d5..1cd4c9fb4c2 100644 --- a/src/main/runtime/orca-runtime-tests/runtime-store-partial-fixture.ts +++ b/src/main/runtime/construction/test-context/runtime-store-partial-fixture.ts @@ -1,10 +1,10 @@ -import type { RuntimeStore } from '../construction/runtime-store-contract' -import type { GlobalSettings } from '../../../shared/settings/global-settings-types' -import type { Repo } from '../../../shared/repository/repo-types' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' -import type { Project } from '../../../shared/project/project-types' -import type { ProjectGroup } from '../../../shared/project/groups/project-group-types' -import type { FolderWorkspace } from '../../../shared/folder-workspaces/folder-workspace-types' +import type { RuntimeStore } from '../runtime-store-contract' +import type { GlobalSettings } from '../../../../shared/settings/global-settings-types' +import type { Repo } from '../../../../shared/repository/repo-types' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' +import type { Project } from '../../../../shared/project/project-types' +import type { ProjectGroup } from '../../../../shared/project/groups/project-group-types' +import type { FolderWorkspace } from '../../../../shared/folder-workspaces/folder-workspace-types' type RuntimeSettings = ReturnType diff --git a/src/main/runtime/construction/test-context/runtime-test-module-registration.spec.ts b/src/main/runtime/construction/test-context/runtime-test-module-registration.spec.ts new file mode 100644 index 00000000000..a02e5e060d7 --- /dev/null +++ b/src/main/runtime/construction/test-context/runtime-test-module-registration.spec.ts @@ -0,0 +1,73 @@ +import '../../orca-runtime-test-mocks/setup.spec' +import 'vitest' +import '../../browser/commands/browser-commands' +import '../../browser/installation/runtime-browser-commands-factory' +import '../../orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-controller' +import '../../terminal/launch/native-terminal-availability' +import '../runtime-desktop-surface' +import '../../../../../config/scripts/test-runtime/environment/vitest-host-ports-setup' +import 'node:perf_hooks' +import 'node:events' +import 'node:crypto' +import 'node:child_process' +import 'node:fs' +import 'node:fs/promises' +import 'node:os' +import 'node:path' +import 'electron' +import '../../../../shared/agent-status/contracts/agent-status-freshness' +import '../../../../shared/worktree/hosted-review/review-head-tracking-ref' +import '../../../../shared/agent-status/title/agent-title-status' +import '../../../../shared/agent-status/title/osc-title-extraction' +import '../../../git/worktrees/creation/worktree-sparse-add' +import '../../../git/worktrees/creation/worktree-add' +import '../../../git/worktrees/removal/worktree-removal-preflight' +import '../../../git/worktrees/catalog/worktree-listing' +import '../../../git/worktrees/catalog/worktree-scan-cache' +import '../../../git/worktrees/removal/worktree-removal' +import '../../workspaces/removal/worktree-teardown' +import '../../workspaces/removal/worktree-teardown-deadline' +import '../../../git/source-control/submodules/submodule-paths' +import '../../../workspace-hooks/hooks' +import '../../../../shared/workspace-setup/orca-yaml' +import '../../../workspace-hooks/worktree-runner-script' +import '../../../workspace-hooks/effective-hook-config' +import '../../../git/repositories/repository-name' +import '../../../git/remotes/repo-remote-queries' +import '../../../git/repositories/discovery/repo-detection' +import '../../../git/refs/resolution/repo-base-ref-search' +import '../../../git/refs/resolution/repo-branch-conflict' +import '../../orchestration/db/orchestration-db' +import '../../orchestration/db/contract-constants' +import '../../orchestration/db/messages/mailbox-routing-page' +import '../../orchestration/db/dispatch-row-writer' +import '../../orchestration/db/attempt-outcome-projection' +import '../../orca-runtime' +import '../../session-graph/runtime-graph-reload-lifecycle' +import '../../browser/client-pages/runtime-browser-page-registry' +import '../../browser-host/leases/browser-host-lease-registry-instance' +import '../../terminal/output/recent-pty-output-buffer' +import '../../session-lifecycle/projection/mobile-session-browser-equality' +import '../../session-lifecycle/projection/mobile-session-browser-group-projection' +import '../../../daemon/emulation/headless-emulator' + +import '../../../../shared/terminal/input/terminal-input' +import '../../../../shared/agent-launch/startup/agent-prompt-injection' +import '../../../../shared/clipboard/clipboard-text' +import '../../../../shared/project/host-setup/project-host-setup-projection' +import '../../../memory/pty-registry' +import '../../../providers/pty/process-inspection' +import '../../../workspaces/catalog/worktree-path-comparison-key' +import '../../../workspaces/removal/local-worktree-filesystem' +import '../../../../shared/orca-profiles/constants' +import '../../../ports/advertised-url-watcher' +import '../../../../shared/workspace-layout/stable-pane-id' +import '../../../../shared/agent-launch/startup/setup-agent-sequencing' +import '../../../../shared/worktree/id' +import '../../../../shared/agent-launch/catalog/tui-agent-config' +import '../../../workspaces/removal/watcher-removal-gate' +import '../../../workspaces/removal/watcher-removal-drain' +import '../../terminal/view/terminal-view-attribute-store' +import '../../../git/worktrees/content-paths/worktree-shared-directories' +import '../../../workspaces/removal/worktree-watcher-removal' +import '../../orchestration/db/root-dispatch-test-fixture' diff --git a/src/main/runtime/mobile-desktop-relay/mobile-relay-host-catalog.integration.test.ts b/src/main/runtime/mobile-desktop-relay/mobile-relay-host-catalog.integration.test.ts index 806a152c239..2211d7e84a2 100644 --- a/src/main/runtime/mobile-desktop-relay/mobile-relay-host-catalog.integration.test.ts +++ b/src/main/runtime/mobile-desktop-relay/mobile-relay-host-catalog.integration.test.ts @@ -24,7 +24,7 @@ import { } from '../rpc/server/runtime-rpc-mobile-ws-test-harness' import { makeStore } from '../rpc/server/runtime-rpc-worktree-store-fixtures' import type { MobileDesktopRelayHosts } from './mobile-desktop-relay-hosts' -import { partialRuntimeStore } from '../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../construction/test-context/runtime-store-partial-fixture' vi.mock('../../git/worktrees/catalog/worktree-scan-cache', async (importOriginal) => { const listings = getWorktreeListingMocks() diff --git a/src/main/runtime/multi-client-terminal.integration.test.ts b/src/main/runtime/multi-client-terminal.integration.test.ts index 0e59b41df5c..6919d40c24b 100644 --- a/src/main/runtime/multi-client-terminal.integration.test.ts +++ b/src/main/runtime/multi-client-terminal.integration.test.ts @@ -23,10 +23,10 @@ import { OrcaRuntimeRpcServer } from './rpc/server/runtime-rpc' import { readRuntimeMetadata } from './rpc/server/runtime-metadata' import { sendRequest } from './rpc/server/runtime-rpc-test-harness' import { makeStore } from './rpc/server/runtime-rpc-worktree-store-fixtures' -import { partialRuntimeStore } from './orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from './construction/test-context/runtime-store-partial-fixture' import { settledWriteStub } from '../providers/testing/settled-pty-write-stub' import { publishHeadlessRuntimeGraph } from './session-graph/headless-runtime-graph' -import { committingSpawn } from './orca-runtime-tests/bind-first-pane.test-fixture' +import { committingSpawn } from './terminal/layout/bind-first-pane.test-fixture' vi.mock('../git/worktrees/catalog/worktree-scan-cache', async (importOriginal) => ({ ...(await importOriginal()), diff --git a/src/main/runtime/orca-runtime-tests/headless-snapshots.spec.ts b/src/main/runtime/orca-runtime-tests/headless-snapshots.spec.ts deleted file mode 100644 index 41af191ed9b..00000000000 --- a/src/main/runtime/orca-runtime-tests/headless-snapshots.spec.ts +++ /dev/null @@ -1,212 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { setPlatform } from '../orca-runtime-test-mocks/setup.spec' -import type { HeadlessEmulator } from '../../daemon/emulation/headless-emulator' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import { - declarePendingPaneSerializer, - settlePendingPaneSerializer -} from '../../ipc/pty/pane/serializer-state' -import { seedHeadlessTerminalFromSpawnResult } from '../../ipc/pty/pane/terminal-spawn-restore' - -import { - TEST_WORKTREE_ID, - createRuntime, - makeDeferred, - parseHeadlessSnapshotLines, - store, - syncSinglePty -} from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it('orders headless mirror resizes behind queued PTY writes', async () => { - const spawn = { cols: 80, rows: 10 } - const resized = { cols: 120, rows: 10 } - let currentSize = spawn - const runtime = createRuntime() - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - getSize: () => currentSize, - resize: () => { - currentSize = resized - return true - } - }) - await syncSinglePty(runtime, 'pty-1') - runtime.onPtyData('pty-1', 'prompt\r\n', 100) - await runtime.serializeMainTerminalBuffer('pty-1') - - type HeadlessStateForTest = { - emulator: HeadlessEmulator - writeChain: Promise - } - const headless = ( - runtime as unknown as { headlessTerminals: Map } - ).headlessTerminals.get('pty-1') - expect(headless).toBeDefined() - const originalWrite = headless!.emulator.write.bind(headless!.emulator) - const queuedWriteStarted = makeDeferred() - const releaseQueuedWrite = makeDeferred() - headless!.emulator.write = async (data: string): Promise => { - queuedWriteStarted.resolve() - await releaseQueuedWrite.promise - await originalWrite(data) - } - - try { - runtime.onPtyData('pty-1', '\x1b[90GOLD', 200) - await queuedWriteStarted.promise - await runtime.updateDesktopViewport('pty-1', resized) - runtime.onPtyData('pty-1', '\r\nNEXT', 300) - releaseQueuedWrite.resolve() - - const snapshot = await runtime.serializeMainTerminalBuffer('pty-1', { scrollbackRows: 100 }) - expect(snapshot).toMatchObject({ cols: resized.cols, rows: resized.rows }) - await expect(parseHeadlessSnapshotLines(snapshot!, resized)).resolves.toEqual([ - 'prompt', - ' O', - 'LD', - 'NEXT' - ]) - } finally { - headless!.emulator.write = originalWrite - releaseQueuedWrite.resolve() - } - }) - - it('keeps pre-TUI shell scrollback when hydrating from a renderer on the alternate screen (#6106)', async () => { - // Renderer serialization emits normal scrollback before alt-screen bytes; zeroing scrollback loses shell history. - const serializeBuffer = vi.fn(async (_ptyId: string, opts?: { scrollbackRows?: number }) => { - const suppressesScrollback = - (opts as Record | undefined)?.altScreenForcesZeroRows === true - const scrollback = suppressesScrollback ? '' : 'PRE_CODEX_START\r\nAGENTS.md\r\n' - return { - data: `${scrollback}\x1b[?1049h\x1b[HCodex TUI frame`, - cols: 80, - rows: 24 - } - }) - const runtime = createRuntime() - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeBuffer, - hasRendererSerializer: () => true, - getSize: () => ({ cols: 80, rows: 24 }) - }) - await syncSinglePty(runtime, 'pty-1') - - runtime.onPtyData('pty-1', 'live byte', 100) - - const snapshot = await runtime.serializeMainTerminalBuffer('pty-1', { scrollbackRows: 1000 }) - const restored = `${snapshot?.scrollbackAnsi ?? ''}${snapshot?.data ?? ''}` - expect(restored).toContain('PRE_CODEX_START') - expect(restored).toContain('AGENTS.md') - }) - - it('retains cold-restored history in hidden-output recovery while renderer serialization is pending', async () => { - const runtime = createRuntime() - await syncSinglePty(runtime, 'cold-pty') - const paneKey = makePaneKey('tab-1', '44444444-4444-4444-8444-444444444444') - const generation = declarePendingPaneSerializer(paneKey, undefined) - try { - seedHeadlessTerminalFromSpawnResult( - runtime, - { - id: 'cold-pty', - coldRestore: { scrollback: 'restored history\r\n', cwd: '/tmp', cols: 40, rows: 6 } - }, - paneKey - ) - runtime.onPtyData('cold-pty', 'fresh shell prompt $ ', 100) - - const snapshot = await runtime.serializeHiddenOutputRecoveryBuffer('cold-pty', { - scrollbackRows: 100 - }) - expect(snapshot?.data).toContain('restored history') - expect(snapshot?.data).toContain('fresh shell prompt $ ') - } finally { - settlePendingPaneSerializer(paneKey, generation) - } - }) - - it('binds shell ownership evidence to the headless snapshot sequence', async () => { - const runtime = createRuntime() - let resolveConfirmation: ((confirmed: boolean) => void) | undefined - const confirmShellForeground = vi.fn( - () => new Promise((resolve) => void (resolveConfirmation = resolve)) - ) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - confirmShellForeground - }) - await syncSinglePty(runtime, 'pty-1') - - runtime.onPtyData('pty-1', '\x1b[?1049hTUI\x1b]133;D;137\x07shell-marker', 100) - const shellSnapshotPromise = runtime.serializeHiddenOutputRecoveryBuffer('pty-1') - await vi.waitFor(() => expect(confirmShellForeground).toHaveBeenCalledTimes(1)) - let snapshotSettled = false - void shellSnapshotPromise.then(() => { - snapshotSettled = true - }) - await Promise.resolve() - expect(snapshotSettled).toBe(false) - - resolveConfirmation?.(true) - const shellSnapshot = await shellSnapshotPromise - // Direct providers cannot inject a daemon reset barrier; retain poisoned alt mode with proof for renderer grounding. - expect(shellSnapshot).toMatchObject({ - alternateScreen: true, - terminalOwner: 'shell', - seq: '\x1b[?1049hTUI\x1b]133;D;137\x07shell-marker'.length - }) - expect(confirmShellForeground).toHaveBeenCalledTimes(1) - - runtime.onPtyData('pty-1', '\x1b]133;C\x07\x1b[?1049hLIVE-TUI', 101) - const liveSnapshot = await runtime.serializeHiddenOutputRecoveryBuffer('pty-1') - - expect(liveSnapshot?.alternateScreen).toBe(true) - expect(liveSnapshot?.terminalOwner).toBeUndefined() - }) - - it('keeps SSH OSC7 cwd POSIX when the desktop runtime is on Windows', async () => { - setPlatform('win32') - const runtime = new OrcaRuntimeService(store) - runtime.preparePtyExecutionContext('pty-ssh', 'Ubuntu', { resetIncarnation: true }) - runtime.registerPty('pty-ssh', TEST_WORKTREE_ID, 'ssh-conn-1') - - runtime.onPtyData('pty-ssh', '\x1b]7;file://remote-host/home/me/repo/src\x07', 123) - - const internals = runtime as unknown as { - terminalCwdByPtyId: Map - terminalFileUriHostnameByPtyId: Map - wslDistroByPtyId: Map - } - expect(internals.terminalCwdByPtyId.get('pty-ssh')).toBe('/home/me/repo/src') - expect(internals.terminalFileUriHostnameByPtyId.get('pty-ssh')).toBe('remote-host') - expect(internals.wslDistroByPtyId.has('pty-ssh')).toBe(false) - }) - - it('uses per-incarnation WSL context before registration and across simultaneous distros', () => { - setPlatform('win32') - const runtime = new OrcaRuntimeService(store) - runtime.preparePtyExecutionContext('pty-ubuntu', 'Ubuntu', { resetIncarnation: true }) - runtime.preparePtyExecutionContext('pty-debian', 'Debian', { resetIncarnation: true }) - runtime.registerPty('pty-ubuntu', TEST_WORKTREE_ID) - runtime.registerPty('pty-debian', TEST_WORKTREE_ID) - - runtime.onPtyData('pty-ubuntu', '\x1b]7;file://DESKTOP/home/me/repo\x07', 1) - runtime.onPtyData('pty-debian', '\x1b]7;file://DESKTOP/home/me/repo\x07', 1) - - const cwds = (runtime as unknown as { terminalCwdByPtyId: Map }) - .terminalCwdByPtyId - expect(cwds.get('pty-ubuntu')).toBe('\\\\wsl.localhost\\Ubuntu\\home\\me\\repo') - expect(cwds.get('pty-debian')).toBe('\\\\wsl.localhost\\Debian\\home\\me\\repo') - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-04.spec.ts b/src/main/runtime/orca-runtime-tests/mobile-summaries-part-04.spec.ts deleted file mode 100644 index edf305e4c24..00000000000 --- a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-04.spec.ts +++ /dev/null @@ -1,133 +0,0 @@ -import { describe, expect, it } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { setPlatform } from '../orca-runtime-test-mocks/setup.spec' -import * as worktreePathComparison from '../../workspaces/catalog/worktree-path-comparison-key' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' -import { makeWorktreeMeta, store, syncSinglePty } from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it('keeps pinned and unread worktrees when active rows fill the mobile summary limit', async () => { - setPlatform('win32') - const remoteRepo = { - id: 'repo-pinned-limit', - path: '/remote', - displayName: 'pinned-limit-vm', - badgeColor: 'blue', - addedAt: 1, - connectionId: 'ssh-pinned-limit' - } - const activeWorktrees = Array.from({ length: 199 }, (_, index) => ({ - path: `relative/active-${String(index).padStart(3, '0')}`, - head: `head-${index}`, - branch: `refs/heads/active-${index}`, - isBare: false, - isMainWorktree: false - })) - const pinnedPath = 'relative/zzz-pinned' - const unreadPath = 'relative/zzz-unread' - const pinnedId = `${remoteRepo.id}::${pinnedPath}` - const unreadId = `${remoteRepo.id}::${unreadPath}` - // No SSH Git provider is installed, so these fixtures use stored rows. - const metaById: Record = { - ...Object.fromEntries( - activeWorktrees.map((worktree) => [ - `${remoteRepo.id}::${worktree.path}`, - makeWorktreeMeta() - ]) - ), - [pinnedId]: makeWorktreeMeta({ isPinned: true }), - [unreadId]: makeWorktreeMeta({ isUnread: true }) - } - const runtimeStore = { - ...store, - getRepos: () => [remoteRepo], - getRepo: (id: string) => (id === remoteRepo.id ? remoteRepo : undefined), - getAllWorktreeMeta: () => metaById, - getWorktreeMeta: (worktreeId: string) => metaById[worktreeId] - } - const now = Date.now() - const runtime = new OrcaRuntimeService(runtimeStore as never, undefined, { - getAgentStatusSnapshot: () => - activeWorktrees.map((worktree, index) => ({ - paneKey: `active-tab:${String(index).padStart(8, '0')}-8888-4888-8888-888888888888`, - worktreeId: `${remoteRepo.id}::${worktree.path.replace('relative/', 'relative/./')}`, - tabId: 'active-tab', - state: 'working' as const, - prompt: 'active row', - agentType: 'codex', - connectionId: 'ssh-pinned-limit', - receivedAt: now, - stateStartedAt: now - 100 - })) - }) - - const summaries = await runtime.getWorktreePs() - - expect(summaries).toMatchObject({ totalCount: 201, truncated: true }) - expect(summaries.worktrees).toHaveLength(200) - expect(summaries.worktrees.find((worktree) => worktree.worktreeId === pinnedId)).toMatchObject({ - isPinned: true, - hasHostSidebarActivity: false - }) - expect(summaries.worktrees.find((worktree) => worktree.worktreeId === unreadId)).toMatchObject({ - unread: true, - hasHostSidebarActivity: false - }) - expect( - worktreePathComparison.worktreePathComparisonKey(activeWorktrees[0]!.path, 'linux') - ).toBe( - worktreePathComparison.worktreePathComparisonKey( - activeWorktrees[0]!.path.replace('relative/', 'relative/./'), - 'linux' - ) - ) - }) - - it('clears stale working status after the agent exits and the shell takes over the title', async () => { - // Recompute from the live title so retained agent status cannot strand a working spinner (#1437). - const runtime = new OrcaRuntimeService(store) - - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { - tabs: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - title: 'Codex working', - activeLeafId: 'pane:1', - layout: null - } - ], - leaves: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-1' - } - ] - }) - - runtime.onPtyData('pty-1', '\x1b]0;Codex working\x07', 100) - const working = await runtime.getWorktreePs() - expect(working.worktrees[0].status).toBe('working') - - runtime.onPtyData('pty-1', '\x1b]0;bash\x07', 200) - const afterExit = await runtime.getWorktreePs() - expect(afterExit.worktrees[0].status).toBe('active') - }) - - it('shows worktree.ps active when the current pane is the Claude agents screen', async () => { - const runtime = new OrcaRuntimeService(store) - - await syncSinglePty(runtime, 'pty-1', { paneTitle: 'claude working' }) - runtime.onPtyData('pty-1', '\x1b]0;claude working\x07', 100) - await syncSinglePty(runtime, 'pty-1', { paneTitle: 'claude agents' }) - - const summary = await runtime.getWorktreePs() - - expect(summary.worktrees[0].status).toBe('active') - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/project-setup-folder-remote-identity.spec.ts b/src/main/runtime/orca-runtime-tests/project-setup-folder-remote-identity.spec.ts deleted file mode 100644 index 0b058d91439..00000000000 --- a/src/main/runtime/orca-runtime-tests/project-setup-folder-remote-identity.spec.ts +++ /dev/null @@ -1,365 +0,0 @@ -import { realpathSync } from 'node:fs' -import { beforeEach, describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { execFileSync } from 'node:child_process' -import * as forkMetadata from '../../github/client/fetch/repo-slug-upstream' -import { join } from 'node:path' -import { mkdtemp, rm } from 'node:fs/promises' -import { projectHostSetupProjectionFromRepos } from '../../../shared/project/host-setup/project-host-setup-projection' -import { tmpdir } from 'node:os' -import { store } from './orca-runtime-test-fixtures.spec' -import type { Repo } from '../../../shared/repository/repo-types' -import type { RuntimeStore } from '../construction/runtime-store-contract' - -const parentProbe = vi.spyOn(forkMetadata, 'probeRepoUpstream') -beforeEach(() => { - parentProbe.mockReset().mockResolvedValue({ upstream: undefined, origin: null }) -}) - -function createRuntime(repos: Repo[]): OrcaRuntimeService { - const runtimeStore: RuntimeStore = { - ...store, - getRepos: () => [...repos], - addRepo: (repo: Repo) => { - repos.push(repo) - }, - getRepo: (id: string) => repos.find((repo) => repo.id === id), - updateRepo: ({ id }, updates) => { - const repo = repos.find((entry) => entry.id === id) - if (!repo) { - return null - } - Object.assign(repo, updates) - return { ...repo } - }, - removeProjectForHost: ({ id }: { id: string }) => { - const index = repos.findIndex((repo) => repo.id === id) - if (index !== -1) { - repos.splice(index, 1) - } - }, - getProjects: () => [...projectHostSetupProjectionFromRepos(repos).projects], - getProjectHostSetups: () => [...projectHostSetupProjectionFromRepos(repos).setups] - } - return new OrcaRuntimeService(runtimeStore) -} - -async function withGitFolder( - remotes: Record, - run: (path: string) => Promise -): Promise { - const tempRoot = await mkdtemp(join(tmpdir(), 'orca-runtime-folder-remote-')) - try { - execFileSync('git', ['init'], { cwd: tempRoot, stdio: 'ignore' }) - for (const [name, url] of Object.entries(remotes)) { - execFileSync('git', ['remote', 'add', name, url], { cwd: tempRoot, stdio: 'ignore' }) - } - await run(tempRoot) - } finally { - await rm(tempRoot, { recursive: true, force: true }) - } -} - -const repoA = { provider: 'github' as const, owner: 'acme', repo: 'repo-a' } - -describe('OrcaRuntimeService project setup of an existing folder (#30663)', () => { - it('refuses to relabel a folder whose own GitHub remote names another repository', async () => { - const repos: Repo[] = [] - const runtime = createRuntime(repos) - - await withGitFolder({ origin: 'https://github.com/acme/repo-b.git' }, async (path) => { - await expect( - runtime.setupProjectExistingFolder({ - projectId: 'github:acme/repo-a', - projectProviderIdentity: repoA, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - ).rejects.toThrow(/points at acme\/repo-b, not acme\/repo-a/) - }) - - expect(repos).toHaveLength(0) - }) - - it('judges an already-registered folder by its current remotes, not the stored ones', async () => { - const repos: Repo[] = [] - const runtime = createRuntime(repos) - - await withGitFolder( - { - origin: 'https://github.com/me/repo-a-fork.git', - upstream: 'https://github.com/acme/repo-a.git' - }, - async (path) => { - // Registered before the user added the `upstream` remote the refusal recommends. - repos.push({ - id: 'repo-registered', - path: realpathSync(path), - displayName: 'repo-a-fork', - badgeColor: '#000000', - addedAt: 1, - kind: 'git', - executionHostId: 'runtime:env-1', - upstream: null, - gitRemoteIdentity: { - canonicalKey: 'github.com/me/repo-a-fork', - remoteName: 'origin', - remoteUrl: 'https://github.com/me/repo-a-fork.git' - } - }) - const result = await runtime.setupProjectExistingFolder({ - projectId: 'github:acme/repo-a', - projectProviderIdentity: repoA, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - expect(result.project.id).toBe('github:acme/repo-a') - expect(result.repo.id).toBe('repo-registered') - } - ) - }) -}) - -it('completes parent-selected setup while unrelated background metadata remains pending', async () => { - await withGitFolder({ origin: 'https://github.com/me/repo-a.git' }, async (path) => { - const repos: Repo[] = [ - { - id: 'blocker', - path: '/blocked', - displayName: 'blocker', - badgeColor: 'blue', - addedAt: 1, - kind: 'git' - } - ] - const runtime = createRuntime(repos) - const gate = Promise.withResolvers() - parentProbe - .mockImplementationOnce(() => gate.promise) - .mockResolvedValue({ - upstream: { owner: 'acme', repo: 'repo-a' }, - origin: { owner: 'me', repo: 'repo-a' } - }) - const background = runtime.repositoryForkBackfill.enqueue(repos) - try { - const result = await runtime.setupProjectExistingFolder({ - projectId: 'github:acme/repo-a', - projectProviderIdentity: repoA, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - expect(result.project.id).toBe('github:acme/repo-a') - expect(repos[0].upstream).toBeUndefined() - expect(parentProbe).toHaveBeenCalledTimes(2) - } finally { - gate.resolve({ upstream: null, origin: null }) - await background - } - }) -}) - -it.each([false, true])( - 'refuses changed current origin after an unavailable lookup (pre-existing=%s)', - async (existing) => { - await withGitFolder({ origin: 'https://github.com/me/repo-a.git' }, async (path) => { - const repos: Repo[] = [] - if (existing) { - repos.push({ - id: 'selected', - path: realpathSync(path), - displayName: 'repo-a', - badgeColor: 'blue', - addedAt: 1, - kind: 'git', - executionHostId: 'runtime:env-1', - gitRemoteIdentity: { - canonicalKey: 'github.com/me/repo-a', - remoteName: 'origin', - remoteUrl: 'https://github.com/me/repo-a.git' - } - }) - } - const runtime = createRuntime(repos) - const gate = Promise.withResolvers() - const started = Promise.withResolvers() - parentProbe.mockImplementationOnce(() => { - started.resolve() - return gate.promise - }) - const setup = runtime.setupProjectExistingFolder({ - projectId: 'github:me/repo-a', - projectProviderIdentity: { provider: 'github', owner: 'me', repo: 'repo-a' }, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - const rejection = expect(setup).rejects.toThrow(/points at other\/repo-a, not me\/repo-a/) - await started.promise - execFileSync('git', ['remote', 'set-url', 'origin', 'https://github.com/other/repo-a.git'], { - cwd: path, - stdio: 'ignore' - }) - gate.resolve({ upstream: undefined, origin: { owner: 'me', repo: 'repo-a' } }) - await rejection - expect(repos).toHaveLength(existing ? 1 : 0) - expect(parentProbe).toHaveBeenCalledTimes(1) - }) - } -) - -it('retains matching null authority when a nonfork result settles during setup', async () => { - await withGitFolder({ origin: 'https://github.com/me/repo-a.git' }, async (path) => { - const repos: Repo[] = [] - const runtime = createRuntime(repos) - const gate = Promise.withResolvers() - const started = Promise.withResolvers() - parentProbe.mockImplementationOnce(() => { - started.resolve() - return gate.promise - }) - const setup = runtime.setupProjectExistingFolder({ - projectId: 'github:me/repo-a', - projectProviderIdentity: { provider: 'github', owner: 'me', repo: 'repo-a' }, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - await started.promise - execFileSync('git', ['remote', 'set-url', 'origin', 'https://github.com/other/repo-a.git'], { - cwd: path, - stdio: 'ignore' - }) - gate.resolve({ upstream: null, origin: { owner: 'me', repo: 'repo-a' } }) - const result = await setup - expect(result.project.id).toBe('github:me/repo-a') - expect(result.repo.upstream).toBeNull() - expect( - projectHostSetupProjectionFromRepos(JSON.parse(JSON.stringify(repos))).setups[0].projectId - ).toBe('github:me/repo-a') - }) -}) - -it('publishes metadata retained on a pre-existing row after explicit setup fails', async () => { - await withGitFolder({ origin: 'https://github.com/me/repo-a.git' }, async (path) => { - const repos: Repo[] = [ - { - id: 'selected', - path: realpathSync(path), - displayName: 'repo-a', - badgeColor: 'blue', - addedAt: 1, - kind: 'git', - executionHostId: 'runtime:env-1' - } - ] - const runtime = createRuntime(repos) - parentProbe.mockResolvedValue({ - upstream: { owner: 'acme', repo: 'repo-a' }, - origin: { owner: 'me', repo: 'repo-a' } - }) - const notifications: string[] = [] - const unsubscribe = runtime.onClientEvent((event) => { - if (event.type === 'reposChanged') { - notifications.push(event.type) - } - }) - try { - await expect( - runtime.setupProjectExistingFolder({ - projectId: 'github:elsewhere/repo-a', - projectProviderIdentity: { provider: 'github', owner: 'elsewhere', repo: 'repo-a' }, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - ).rejects.toThrow(/points at me\/repo-a, not elsewhere\/repo-a/) - expect(repos).toHaveLength(1) - expect(repos[0].upstream).toEqual({ owner: 'acme', repo: 'repo-a' }) - expect(notifications).toEqual(['reposChanged']) - expect(parentProbe).toHaveBeenCalledTimes(1) - } finally { - unsubscribe() - } - }) -}) - -it.each(['recovered parent', 'unavailable'] as const)( - 'settles an explicit origin after ordinary alias enrichment: %s', - async (evidence) => { - await withGitFolder({ origin: 'git@gh-personal:me/repo-a.git' }, async (path) => { - const repos: Repo[] = [] - const runtime = createRuntime(repos) - const origin = { owner: 'me', repo: 'repo-a' } - const ordinary = Promise.withResolvers() - const ordinaryStarted = Promise.withResolvers() - const ordinaryFinished = Promise.withResolvers() - const required = Promise.withResolvers() - const requiredStarted = Promise.withResolvers() - parentProbe - .mockImplementationOnce(() => { - ordinaryStarted.resolve() - return ordinary.promise - }) - .mockImplementationOnce(() => { - requiredStarted.resolve() - return required.promise - }) - const unsubscribe = runtime.onClientEvent((event) => { - if (event.type === 'reposChanged' && repos[0]?.repoIcon?.type === 'image') { - ordinaryFinished.resolve() - } - }) - try { - const added = await runtime.addRepo(path, 'git', 'runtime:env-1') - await ordinaryStarted.promise - ordinary.resolve({ upstream: undefined, origin }) - await ordinaryFinished.promise - expect(added.id).toBe(repos[0].id) - expect(repos[0].gitRemoteIdentity).toEqual({ - canonicalKey: 'gh-personal/me/repo-a', - remoteName: 'origin', - remoteUrl: 'git@gh-personal:me/repo-a.git' - }) - expect(repos[0].repoIcon).toEqual({ - type: 'image', - source: 'github', - src: 'https://github.com/me.png?size=64', - label: 'me/repo-a' - }) - expect(repos[0].upstream).toBeUndefined() - - const setup = runtime.setupProjectExistingFolder({ - projectId: 'github:me/repo-a', - projectProviderIdentity: { provider: 'github', ...origin }, - hostId: 'runtime:env-1', - path, - kind: 'git' - }) - await requiredStarted.promise - const completion = runtime.repositoryForkBackfill.resolve(repos[0]) - required.resolve({ - upstream: evidence === 'recovered parent' ? { owner: 'acme', repo: 'repo-a' } : undefined, - origin - }) - const result = await setup - await completion - expect(result.project.id).toBe('github:me/repo-a') - expect(result.repo.upstream).toEqual(evidence === 'recovered parent' ? origin : null) - parentProbe.mockResolvedValue({ upstream: { owner: 'acme', repo: 'repo-a' }, origin }) - await runtime.repositoryForkBackfill.run() - expect(repos[0].upstream).toEqual(evidence === 'recovered parent' ? origin : null) - expect( - projectHostSetupProjectionFromRepos(JSON.parse(JSON.stringify(repos))).setups[0].projectId - ).toBe('github:me/repo-a') - } finally { - ordinary.resolve({ upstream: undefined, origin }) - required.resolve({ upstream: undefined, origin }) - unsubscribe() - } - }) - } -) diff --git a/src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec.ts b/src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec.ts deleted file mode 100644 index 25dc0eaa887..00000000000 --- a/src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec.ts +++ /dev/null @@ -1,73 +0,0 @@ -import '../orca-runtime-test-mocks/setup.spec' -import 'vitest' -import '../browser/commands/browser-commands' -import '../browser/installation/runtime-browser-commands-factory' -import '../orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-controller' -import '../terminal/launch/native-terminal-availability' -import '../construction/runtime-desktop-surface' -import '../../../../config/scripts/test-runtime/environment/vitest-host-ports-setup' -import 'node:perf_hooks' -import 'node:events' -import 'node:crypto' -import 'node:child_process' -import 'node:fs' -import 'node:fs/promises' -import 'node:os' -import 'node:path' -import 'electron' -import '../../../shared/agent-status/contracts/agent-status-freshness' -import '../../../shared/worktree/hosted-review/review-head-tracking-ref' -import '../../../shared/agent-status/title/agent-title-status' -import '../../../shared/agent-status/title/osc-title-extraction' -import '../../git/worktrees/creation/worktree-sparse-add' -import '../../git/worktrees/creation/worktree-add' -import '../../git/worktrees/removal/worktree-removal-preflight' -import '../../git/worktrees/catalog/worktree-listing' -import '../../git/worktrees/catalog/worktree-scan-cache' -import '../../git/worktrees/removal/worktree-removal' -import '../workspaces/removal/worktree-teardown' -import '../workspaces/removal/worktree-teardown-deadline' -import '../../git/source-control/submodules/submodule-paths' -import '../../workspace-hooks/hooks' -import '../../../shared/workspace-setup/orca-yaml' -import '../../workspace-hooks/worktree-runner-script' -import '../../workspace-hooks/effective-hook-config' -import '../../git/repositories/repository-name' -import '../../git/remotes/repo-remote-queries' -import '../../git/repositories/discovery/repo-detection' -import '../../git/refs/resolution/repo-base-ref-search' -import '../../git/refs/resolution/repo-branch-conflict' -import '../orchestration/db/orchestration-db' -import '../orchestration/db/contract-constants' -import '../orchestration/db/messages/mailbox-routing-page' -import '../orchestration/db/dispatch-row-writer' -import '../orchestration/db/attempt-outcome-projection' -import '../orca-runtime' -import '../session-graph/runtime-graph-reload-lifecycle' -import '../browser/client-pages/runtime-browser-page-registry' -import '../browser-host/leases/browser-host-lease-registry-instance' -import '../terminal/output/recent-pty-output-buffer' -import '../session-lifecycle/projection/mobile-session-browser-equality' -import '../session-lifecycle/projection/mobile-session-browser-group-projection' -import '../../daemon/emulation/headless-emulator' - -import '../../../shared/terminal/input/terminal-input' -import '../../../shared/agent-launch/startup/agent-prompt-injection' -import '../../../shared/clipboard/clipboard-text' -import '../../../shared/project/host-setup/project-host-setup-projection' -import '../../memory/pty-registry' -import '../../providers/pty/process-inspection' -import '../../workspaces/catalog/worktree-path-comparison-key' -import '../../workspaces/removal/local-worktree-filesystem' -import '../../../shared/orca-profiles/constants' -import '../../ports/advertised-url-watcher' -import '../../../shared/workspace-layout/stable-pane-id' -import '../../../shared/agent-launch/startup/setup-agent-sequencing' -import '../../../shared/worktree/id' -import '../../../shared/agent-launch/catalog/tui-agent-config' -import '../../workspaces/removal/watcher-removal-gate' -import '../../workspaces/removal/watcher-removal-drain' -import '../terminal/view/terminal-view-attribute-store' -import '../../git/worktrees/content-paths/worktree-shared-directories' -import '../../workspaces/removal/worktree-watcher-removal' -import '../orchestration/db/root-dispatch-test-fixture' diff --git a/src/main/runtime/orca-runtime-tests/targeting-and-resilience.spec.ts b/src/main/runtime/orca-runtime-tests/targeting-and-resilience.spec.ts deleted file mode 100644 index 08b74e0bf16..00000000000 --- a/src/main/runtime/orca-runtime-tests/targeting-and-resilience.spec.ts +++ /dev/null @@ -1,310 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import { bindPaneFirst, registerBoundPty } from './bind-first-pane.test-fixture' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES, electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { AgentBrowserBridge } from '../../browser/agent-browser/agent-browser-bridge' -import type { IPtyProvider } from '../../providers/pty/provider-contract' -import '../../git/worktrees/removal/worktree-removal-preflight' -import { ipcMain } from 'electron' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' -import { - TEST_REPO_ID, - TEST_WORKTREE_ID, - createRuntime, - store, - syncSinglePty -} from './orca-runtime-test-fixtures.spec' -import { createMobileCreateTestNotifier } from './orca-runtime-test-scenario-builders.spec' - -function createBrowserBridge(overrides: Partial): AgentBrowserBridge { - return Object.assign(vi.mockObject(AgentBrowserBridge.prototype), overrides) -} - -describe('OrcaRuntimeService', () => { - describe('browser page targeting', () => { - function mockLiveBrowserGuest(): void { - electronMocks.webContents.fromId.mockReturnValue({ - isDestroyed: () => false, - isLoading: () => false - }) - } - - it('does not silently drop invalid explicit worktree selectors for page-targeted commands', async () => { - vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) - mockLiveBrowserGuest() - const runtime = createRuntime() - const snapshotMock = vi.fn() - - runtime.setAgentBrowserBridge( - createBrowserBridge({ - snapshot: snapshotMock, - getRegisteredTabs: vi.fn(() => new Map([['page-1', 1]])), - getRegisteredPageWebContentsId: (page: string) => (page === 'page-1' ? 1 : undefined) - }) - ) - - await expect( - runtime.browserSnapshot({ - worktree: 'path:/tmp/missing-worktree', - page: 'page-1' - }) - ).rejects.toThrow('selector_not_found') - expect(snapshotMock).not.toHaveBeenCalled() - }) - - it('does not silently drop invalid explicit worktree selectors for non-page browser commands', async () => { - vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) - const runtime = createRuntime() - const tabListMock = vi.fn() - - runtime.setAgentBrowserBridge( - createBrowserBridge({ - tabList: tabListMock - }) - ) - - await expect( - runtime.browserTabList({ - worktree: 'path:/tmp/missing-worktree' - }) - ).rejects.toThrow('selector_not_found') - expect(tabListMock).not.toHaveBeenCalled() - }) - - it('rejects closing an unknown page id instead of treating it as success', async () => { - vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) - mockLiveBrowserGuest() - const runtime = createRuntime() - - runtime.setAgentBrowserBridge( - createBrowserBridge({ - getRegisteredTabs: vi.fn(() => new Map([['page-1', 1]])), - getRegisteredPageWebContentsId: (page: string) => (page === 'page-1' ? 1 : undefined) - }) - ) - - await expect( - runtime.browserTabClose({ - page: 'missing-page' - }) - ).rejects.toThrow('Browser page missing-page was not found') - }) - - it('rejects closing a page outside the explicitly scoped worktree', async () => { - mockLiveBrowserGuest() - vi.mocked(listWorktrees).mockResolvedValue([ - ...MOCK_GIT_WORKTREES, - { - path: '/tmp/worktree-b', - head: 'def', - branch: 'feature/bar', - isBare: false, - isMainWorktree: false - } - ]) - const runtime = createRuntime() - const getRegisteredTabsMock = vi.fn((worktreeId?: string) => - worktreeId === `${TEST_REPO_ID}::/tmp/worktree-b` ? new Map() : new Map([['page-1', 1]]) - ) - - runtime.setAgentBrowserBridge( - createBrowserBridge({ - getRegisteredTabs: getRegisteredTabsMock, - getRegisteredPageWebContentsId: (page: string, worktreeId?: string) => - getRegisteredTabsMock(worktreeId).get(page) - }) - ) - - await expect( - runtime.browserTabClose({ - page: 'page-1', - worktree: 'path:/tmp/worktree-b' - }) - ).rejects.toThrow('Browser page page-1 was not found in this worktree') - expect(getRegisteredTabsMock).toHaveBeenCalledWith(`${TEST_REPO_ID}::/tmp/worktree-b`) - }) - }) - - describe('removeManagedWorktree PTY teardown (design §4.3)', () => { - function createProviderStub( - listProcesses: () => Promise<{ id: string; cwd: string; title: string }[]> - ) { - return { - spawn: vi.fn(), - attach: vi.fn(), - write: vi.fn(), - writeWithSettlement: vi.fn(), - resize: vi.fn(), - shutdown: vi.fn().mockResolvedValue(undefined), - sendSignal: vi.fn(), - getCwd: vi.fn(), - getInitialCwd: vi.fn(), - clearBuffer: vi.fn(), - resetInputModes: vi.fn(), - acknowledgeDataEvent: vi.fn(), - hasChildProcesses: vi.fn(), - getForegroundProcess: vi.fn(), - serialize: vi.fn(), - revive: vi.fn(), - listProcesses: vi.fn(listProcesses), - getDefaultShell: vi.fn(), - getProfiles: vi.fn(), - onData: vi.fn().mockReturnValue(() => {}), - onReplay: vi.fn().mockReturnValue(() => {}), - onExit: vi.fn().mockReturnValue(() => {}) - } satisfies IPtyProvider - } - - it('does not start Git removal when physical PTY stop cannot be proven', async () => { - // Retain the live PTY in fresh inventory so failed stop cannot be mistaken for proven exit. - const localProvider = createProviderStub(async () => [ - { id: 'pty-1', cwd: '/tmp', title: 'shell' } - ]) - const runtime = new OrcaRuntimeService(store, undefined, { - getLocalProvider: () => localProvider - }) - runtime.setPtyController({ - write: () => true, - kill: vi.fn(() => true), - stopAndWait: vi.fn(async () => false), - getForegroundProcess: async () => null - }) - await syncSinglePty(runtime, 'pty-1') - - await expect(runtime.removeManagedWorktree(TEST_WORKTREE_ID)).rejects.toThrow( - 'Failed to physically stop every PTY' - ) - - expect(removeWorktree).not.toHaveBeenCalled() - }) - }) - - describe('mobile terminal create resilience (#7718)', () => { - it('cancels the surface wait without rolling back when the client connection dies', async () => { - vi.useFakeTimers() - try { - const closeTerminal = vi.fn() - const runtime = new OrcaRuntimeService(store) - runtime.setNotifier(createMobileCreateTestNotifier(closeTerminal)) - const abort = new AbortController() - const webContents = { send: vi.fn() } - const send = vi.fn((_channel: string, payload: { requestId: string }) => { - ipcMain.emit( - 'terminal:tabCreateReply', - { sender: webContents }, - { requestId: payload.requestId, tabId: 'tab-abort', title: 'Terminal' } - ) - }) - webContents.send = send - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - electronMocks.BrowserWindow.fromId.mockReturnValue({ - isDestroyed: () => false, - webContents - }) - - const create = runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false, - signal: abort.signal - }) - const settled = create.then( - () => ({ ok: true as const }), - (error: Error) => ({ ok: false as const, error }) - ) - await vi.waitFor(() => expect(send).toHaveBeenCalledTimes(1)) - - // Disconnect must settle promptly without closing the real terminal. - abort.abort() - await vi.advanceTimersByTimeAsync(0) - const outcome = await settled - - expect(outcome.ok).toBe(false) - if (outcome.ok === false) { - expect(outcome.error.message).toBe('client_disconnected') - } - expect(closeTerminal).not.toHaveBeenCalled() - } finally { - vi.useRealTimers() - } - }) - - it('keeps a mobile-created terminal alive when its live shell has no registered pane key', async () => { - vi.useFakeTimers() - try { - const closeTerminal = vi.fn() - const runtime = new OrcaRuntimeService(store) - runtime.setNotifier(createMobileCreateTestNotifier(closeTerminal)) - const webContents = { send: vi.fn() } - const send = vi.fn((_channel: string, payload: { requestId: string }) => { - ipcMain.emit( - 'terminal:tabCreateReply', - { sender: webContents }, - { requestId: payload.requestId, tabId: 'tab-stall', title: 'Terminal' } - ) - }) - webContents.send = send - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - electronMocks.BrowserWindow.fromId.mockReturnValue({ - isDestroyed: () => false, - webContents - }) - - const create = runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false - }) - const settled = create.then( - () => ({ ok: true as const }), - (error: Error) => ({ ok: false as const, error }) - ) - await vi.waitFor(() => expect(send).toHaveBeenCalledTimes(1)) - - // Main-owned layouts require the spawn's binding; a renderer leaf cannot vouch for a live PTY. - if (ORCA_LAYOUT_OWNER_IS_MAIN) { - registerBoundPty(runtime, 'pty-stall', TEST_WORKTREE_ID, null, { - tabId: 'tab-stall', - leafId: '88888888-8888-4888-8888-888888888888' - }) - await vi.advanceTimersByTimeAsync(50) - expect(await settled).toEqual({ ok: true }) - expect(closeTerminal).not.toHaveBeenCalled() - return - } - // A live shell exists, but stalled renderer publication never registered its pane key. - bindPaneFirst(runtime, { - worktreeId: TEST_WORKTREE_ID, - tabId: 'tab-stall', - leafId: 'pane:1', - ptyId: 'pty-stall' - }) - await runtime.syncWindowGraph(1, { - tabs: [], - leaves: [ - { - tabId: 'tab-stall', - worktreeId: TEST_WORKTREE_ID, - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-stall', - paneTitle: null - } - ] - }) - - await vi.advanceTimersByTimeAsync(11_000) - const outcome = await settled - - expect(outcome.ok).toBe(false) - if (outcome.ok === false) { - expect(outcome.error.message).toContain('Timed out') - } - expect(closeTerminal).not.toHaveBeenCalled() - } finally { - vi.useRealTimers() - } - }) - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-06.spec.ts b/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-06.spec.ts deleted file mode 100644 index 5baa9432b31..00000000000 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-06.spec.ts +++ /dev/null @@ -1,172 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { TEST_WORKTREE_ID, TEST_WORKTREE_PATH, store } from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it('replays fast setup completion emitted before its observer is registered', async () => { - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - spawn: vi.fn().mockResolvedValue({ id: 'pty-fast-setup' }), - write: () => true, - kill: () => true, - getForegroundProcess: async () => null - }) - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - const { handle } = await runtime.createTerminal(`path:${TEST_WORKTREE_PATH}`) - ;( - runtime as unknown as { setupCompletionTokenByPtyId: Map } - ).setupCompletionTokenByPtyId.set('pty-fast-setup', 'token-fast') - runtime.onPtyData( - 'pty-fast-setup', - '__ORCA_SETUP_COMPLETE__:wrong:9\r\n__ORCA_SETUP_COMPLETE__:token-fast:0\r\n$', - 100 - ) - - await expect(runtime.waitForSetupTerminalCompletion(handle)).resolves.toEqual({ exitCode: 0 }) - }) - - it('drops retained PTY transcript memory when a background terminal exits', async () => { - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - spawn: vi.fn().mockResolvedValue({ id: 'pty-bg' }), - write: () => true, - kill: () => true, - getForegroundProcess: async () => null - }) - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - const { handle } = await runtime.createTerminal(`path:${TEST_WORKTREE_PATH}`) - - runtime.onPtyData( - 'pty-bg', - `${Array.from({ length: 20 }, (_, i) => `line-${i}`).join('\n')}\nwrote /tmp/exited-result.json\n`, - 100 - ) - await expect(runtime.readTerminal(handle)).resolves.toMatchObject({ - status: 'running', - tail: expect.arrayContaining(['line-0']) - }) - - runtime.onPtyExit('pty-bg', 0) - - const pty = ( - runtime as unknown as { - ptysById: Map< - string, - { - tailBuffer: string[] - tailPartialLine: string - tailLinesTotal: number - tailTruncated: boolean - } - > - } - ).ptysById.get('pty-bg') - expect(pty).toMatchObject({ - tailBuffer: [], - tailPartialLine: '', - tailLinesTotal: 0, - tailTruncated: false - }) - await expect(runtime.readTerminal(handle)).resolves.toMatchObject({ - status: 'exited', - tail: [] - }) - }) - - it('bounds disconnected background PTY records and their synthetic handles', async () => { - let nextPtyIndex = 0 - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - spawn: vi.fn().mockImplementation(async () => ({ id: `pty-bg-${nextPtyIndex++}` })), - write: () => true, - kill: () => true, - getForegroundProcess: async () => null - }) - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - - const handles: string[] = [] - for (let index = 0; index < 140; index += 1) { - const { handle } = await runtime.createTerminal(`path:${TEST_WORKTREE_PATH}`) - handles.push(handle) - runtime.onPtyData(`pty-bg-${index}`, `wrote /tmp/result-${index}.json\n`, 100 + index) - runtime.onPtyExit(`pty-bg-${index}`, 0) - } - - const internals = runtime as unknown as { - ptysById: Map - handles: Map - handleByPtyId: Map - } - expect(internals.ptysById.size).toBeLessThanOrEqual(128) - expect(internals.ptysById.has('pty-bg-0')).toBe(false) - expect(internals.ptysById.has('pty-bg-139')).toBe(true) - expect(internals.handleByPtyId.has('pty-bg-0')).toBe(false) - expect(internals.handles.has(handles[0]!)).toBe(false) - - await expect(runtime.readTerminal(handles[0]!)).rejects.toThrow('terminal_handle_stale') - await expect(runtime.readTerminal(handles.at(-1)!)).resolves.toMatchObject({ - status: 'exited' - }) - }) - - it('does not treat a Codex launch title as tui-idle readiness', async () => { - vi.useFakeTimers() - try { - const runtime = new OrcaRuntimeService(store) - const serializeProviderBuffer = vi.fn().mockResolvedValue({ - data: 'OpenAI Codex\r\nmodel: gpt-5.5\r\ndirectory: /repo\r\n', - cols: 80, - rows: 24, - seq: 1 - }) - runtime.setPtyController({ - spawn: vi.fn().mockResolvedValue({ id: 'pty-bg' }), - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeProviderBuffer - }) - const { handle } = await runtime.createTerminal(`path:${TEST_WORKTREE_PATH}`) - - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { - tabs: [ - { - tabId: 'tab-bg', - worktreeId: TEST_WORKTREE_ID, - title: 'Codex YOLO', - activeLeafId: 'pane-bg', - layout: null - } - ], - leaves: [ - { - tabId: 'tab-bg', - worktreeId: TEST_WORKTREE_ID, - leafId: 'pane-bg', - paneRuntimeId: 1, - ptyId: 'pty-bg', - paneTitle: null - } - ] - }) - - const waitPromise = runtime.waitForTerminal(handle, { - condition: 'tui-idle', - timeoutMs: 1_000 - }) - const timeoutAssertion = expect(waitPromise).rejects.toThrow('timeout') - - await vi.advanceTimersByTimeAsync(2_000) - - await timeoutAssertion - expect(serializeProviderBuffer).not.toHaveBeenCalled() - } finally { - vi.useRealTimers() - } - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-04.spec.ts b/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-04.spec.ts deleted file mode 100644 index 69f6f8e660d..00000000000 --- a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-04.spec.ts +++ /dev/null @@ -1,234 +0,0 @@ -import type { AdoptStablePaneArgs, AdoptStablePaneResult } from '../../ipc/pty/ipc/spawn-types' -import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it.each([ - { - behavior: 'fills a missing renderer session', - hookAgentType: 'codex', - hookOffset: 0, - rendererSessionId: null, - expectedSessionId: 'hook-session' - }, - { - behavior: 'replaces a stale renderer session at the same event timestamp', - hookAgentType: 'codex', - hookOffset: 0, - rendererSessionId: 'stale-renderer-session', - expectedSessionId: 'hook-session' - }, - { - behavior: 'preserves a renderer session newer than the hook row', - hookAgentType: 'codex', - hookOffset: -1, - rendererSessionId: 'newer-renderer-session', - expectedSessionId: 'newer-renderer-session' - }, - { - behavior: 'rejects a hook session owned by another agent', - hookAgentType: 'claude', - hookOffset: 1, - rendererSessionId: null, - expectedSessionId: null - } - ] as const)( - '$behavior', - async ({ hookAgentType, hookOffset, rendererSessionId, expectedSessionId }) => { - const leafId = '11111111-1111-4111-8111-111111111111' - const paneKey = `codex-tab:${leafId}` - const providerSession = { - key: 'session_id' as const, - id: 'hook-session' - } - const now = Date.now() - const runtime = new OrcaRuntimeService(store, undefined, { - getAgentStatusSnapshot: () => [ - { - paneKey, - state: 'done', - prompt: '', - agentType: hookAgentType, - connectionId: null, - receivedAt: now + hookOffset, - stateStartedAt: now + hookOffset, - tabId: 'codex-tab', - worktreeId: TEST_WORKTREE_ID, - providerSession - } - ] - }) - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { - tabs: [], - leaves: [], - mobileSessionTabs: [ - { - worktree: TEST_WORKTREE_ID, - publicationEpoch: 'epoch-1', - snapshotVersion: 1, - activeGroupId: null, - activeTabId: `codex-tab::${leafId}`, - activeTabType: 'terminal', - tabs: [ - { - type: 'terminal', - id: `codex-tab::${leafId}`, - parentTabId: 'codex-tab', - leafId, - title: 'Codex', - launchAgent: 'codex', - agentStatus: { - state: 'working', - prompt: 'Reply with MOBILE QA OK and nothing else.', - updatedAt: now, - stateStartedAt: now, - agentType: 'codex', - paneKey, - stateHistory: [], - ...(rendererSessionId - ? { - providerSession: { - key: 'session_id' as const, - id: rendererSessionId - } - } - : {}) - }, - isActive: true - } - ] - } - ] - }) - - const result = await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`) - - expect(result.tabs[0]).toEqual( - expect.objectContaining({ - type: 'terminal', - agentStatus: expect.objectContaining({ - state: 'working', - prompt: 'Reply with MOBILE QA OK and nothing else.', - agentType: 'codex' - }) - }) - ) - if (expectedSessionId) { - expect(result.tabs[0]).toHaveProperty('agentStatus.providerSession', { - key: 'session_id', - id: expectedSessionId - }) - } else { - expect(result.tabs[0]).not.toHaveProperty('agentStatus.providerSession') - } - } - ) - - it('preserves host metadata when terminal.create adopts a stable pane owner', async () => { - const adoptStablePane = vi.fn( - async (args: AdoptStablePaneArgs): Promise => { - await args.spawnFresh?.({ mustExist: false }) - return null - } - ) - const spawn = vi.fn(async (opts: { adoptedStablePane?: { owner: { handle?: string } } }) => - opts.adoptedStablePane - ? { - id: 'pty-stable-owner', - isReattach: true, - stablePaneOwner: { - handle: opts.adoptedStablePane.owner.handle!, - tabId: 'stable-owner-tab', - leafId: HEADLESS_LEAF_ID - } - } - : { id: 'pty-stable-owner' } - ) - const runtimeStore = { - ...store, - getSettings: () => ({ - ...store.getSettings(), - claudeAgentTeamsMode: 'in-process' as const - }) - } - const runtime = new OrcaRuntimeService(runtimeStore) - runtime.setPtyController({ - adoptStablePane, - spawn, - write: () => true, - kill: () => true, - getForegroundProcess: async () => null - }) - const first = await runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { - tabId: 'stable-owner-tab', - leafId: HEADLESS_LEAF_ID, - title: 'Original owner', - launchAgent: 'claude' - }) - adoptStablePane.mockResolvedValueOnce({ - materialized: true, - result: { id: 'pty-stable-owner', isReattach: true }, - owner: { - handle: first.handle, - tabId: 'stable-owner-tab', - leafId: HEADLESS_LEAF_ID, - ptyId: 'pty-stable-owner' - } - }) - - const adopted = await runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { - tabId: 'stable-owner-tab', - leafId: HEADLESS_LEAF_ID, - title: 'Replacement intent', - command: "claude 'replacement'", - launchAgent: 'claude' - }) - const listed = await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`) - - expect(adopted).toMatchObject({ - handle: first.handle, - ptyId: 'pty-stable-owner', - title: 'Original owner', - isReattach: true - }) - expect(listed.tabs).toEqual([ - expect.objectContaining({ - parentTabId: 'stable-owner-tab', - title: 'Original owner', - launchAgent: 'claude' - }) - ]) - expect(spawn).toHaveBeenCalledOnce() - }) - - it('refuses before spawning when the client disconnects during pane adoption', async () => { - const abort = new AbortController() - const spawn = vi.fn() - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - adoptStablePane: vi.fn(async (args: AdoptStablePaneArgs) => { - abort.abort() - await args.spawnFresh?.({ mustExist: false }) - return null - }), - spawn, - write: () => true, - kill: () => true, - getForegroundProcess: async () => null - }) - - await expect( - runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { - tabId: 'disconnected-during-adopt', - leafId: HEADLESS_LEAF_ID, - signal: abort.signal - }) - ).rejects.toThrow('client_disconnected') - - expect(spawn).not.toHaveBeenCalled() - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-05.spec.ts b/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-05.spec.ts deleted file mode 100644 index e41260b332c..00000000000 --- a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status-part-05.spec.ts +++ /dev/null @@ -1,81 +0,0 @@ -import type { RuntimeMobileSessionTabsResult } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' -import { describe, expect, it, vi } from 'vitest' -import { committingSpawn } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import '../../../shared/agent-status/contracts/agent-status-freshness' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../../shared/workspace-layout/stable-pane-id' -import '../orca-runtime-test-mocks/setup.spec' -import { waitForMobileSessionTabsEvents } from './mobile-session-tab-event-wait' - -import { - HEADLESS_LEAF_ID, - TEST_WORKTREE_ID, - deferred, - store -} from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it('coalesces same-status title frames behind one post-title foreground probe', async () => { - const staleForegroundProcess = deferred() - const freshForegroundProcess = deferred() - const spawn = vi.fn().mockResolvedValue({ id: 'pty-typed-omp' }) - const getForegroundProcess = vi - .fn() - .mockReturnValueOnce(staleForegroundProcess.promise) - .mockReturnValueOnce(freshForegroundProcess.promise) - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - spawn: committingSpawn(runtime, spawn), - write: () => true, - kill: () => true, - getForegroundProcess - }) - const terminal = await runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { - tabId: 'typed-omp-tab', - leafId: HEADLESS_LEAF_ID, - title: 'Terminal' - }) - const events: RuntimeMobileSessionTabsResult[] = [] - const unsubscribe = runtime.onMobileSessionTabsChanged((snapshot) => events.push(snapshot)) - - runtime.onPtyData('pty-typed-omp', '\x1b]0;Pi ready\x07', 123) - await new Promise((resolve) => setImmediate(resolve)) - runtime.onPtyData('pty-typed-omp', '\x1b]0;Pi idle\x07', 124) - runtime.onPtyData('pty-typed-omp', '\x1b]0;Pi done\x07', 125) - await new Promise((resolve) => setImmediate(resolve)) - - expect(getForegroundProcess).toHaveBeenCalledTimes(1) - expect(events).toHaveLength(0) - - staleForegroundProcess.resolve(null) - await new Promise((resolve) => setImmediate(resolve)) - - expect(getForegroundProcess).toHaveBeenCalledTimes(2) - expect(events).toHaveLength(0) - - freshForegroundProcess.resolve('omp') - await new Promise((resolve) => setImmediate(resolve)) - await waitForMobileSessionTabsEvents(events, 1) - - expect(getForegroundProcess).toHaveBeenCalledTimes(2) - expect(events).toEqual([ - expect.objectContaining({ - tabs: [ - expect.objectContaining({ - type: 'terminal', - title: 'OMP ready', - agentStatus: expect.objectContaining({ - state: 'done', - agentType: 'omp', - terminalHandle: terminal.handle, - terminalTitle: 'OMP ready' - }) - }) - ] - }) - ]) - - unsubscribe() - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-listing.spec.ts b/src/main/runtime/orca-runtime-tests/terminal-listing.spec.ts deleted file mode 100644 index df6f6c7286d..00000000000 --- a/src/main/runtime/orca-runtime-tests/terminal-listing.spec.ts +++ /dev/null @@ -1,149 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { FOLDER_WORKSPACE_INSTANCE_SEPARATOR } from '../../../shared/worktree/id' -import { MOCK_GIT_WORKTREES } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { - TEST_FOLDER_WORKSPACE_PATH, - TEST_REPO_ID, - TEST_WORKTREE_ID, - TEST_WORKTREE_PATH, - createRuntime, - makeWorktreeMeta, - store -} from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it('keeps targeted terminal lists from adopting controller PTYs for other worktrees', async () => { - vi.mocked(listWorktrees).mockResolvedValue([ - ...MOCK_GIT_WORKTREES, - { - path: '/tmp/worktree-b', - head: 'def', - branch: 'feature/bar', - isBare: false, - isMainWorktree: false - }, - { - path: '/tmp/worktree-a/nested', - head: 'ghi', - branch: 'feature/nested', - isBare: false, - isMainWorktree: false - } - ]) - const runtime = createRuntime() - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - listProcesses: async () => [ - { id: 'target-controller-pty', cwd: '/tmp/worktree-a/src', title: 'target' }, - { id: 'other-controller-pty', cwd: '/tmp/worktree-b/src', title: 'other' }, - { - id: 'repo-1::/tmp/worktree-b@@other-controller-pty', - cwd: '/tmp/worktree-a/src', - title: 'prefixed other' - }, - { id: 'nested-controller-pty', cwd: '/tmp/worktree-a/nested/src', title: 'nested' } - ] - }) - runtime.attachWindow(1) - runtime.markGraphReady(1) - - const terminals = await runtime.listTerminals(`path:${TEST_WORKTREE_PATH}`) - - expect(terminals.terminals).toHaveLength(1) - expect(terminals.terminals[0]).toMatchObject({ - worktreeId: TEST_WORKTREE_ID, - worktreePath: TEST_WORKTREE_PATH - }) - const internals = runtime as unknown as { ptysById: Map } - expect(internals.ptysById.has('target-controller-pty')).toBe(true) - expect(internals.ptysById.has('other-controller-pty')).toBe(false) - expect(internals.ptysById.has('repo-1::/tmp/worktree-b@@other-controller-pty')).toBe(false) - expect(internals.ptysById.has('nested-controller-pty')).toBe(false) - }) - - it('keeps explicit-id cold-cache terminal lists from adopting nested worktree PTYs', async () => { - const nestedWorktreeId = `${TEST_REPO_ID}::${TEST_WORKTREE_PATH}/nested` - vi.mocked(listWorktrees).mockClear() - vi.mocked(listWorktrees).mockRejectedValue( - new Error('explicit-id fallback should not rescan worktrees') - ) - const runtime = new OrcaRuntimeService({ - ...store, - getAllWorktreeMeta: () => ({ - [TEST_WORKTREE_ID]: store.getAllWorktreeMeta()[TEST_WORKTREE_ID], - [nestedWorktreeId]: makeWorktreeMeta() - }), - getWorktreeMeta: (worktreeId: string) => - ({ - [TEST_WORKTREE_ID]: store.getAllWorktreeMeta()[TEST_WORKTREE_ID], - [nestedWorktreeId]: makeWorktreeMeta() - })[worktreeId] - }) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - listProcesses: async () => [ - { id: 'cwd-only-pty', cwd: `${TEST_WORKTREE_PATH}/src`, title: 'cwd shell' }, - { id: 'nested-controller-pty', cwd: `${TEST_WORKTREE_PATH}/nested/src`, title: 'nested' } - ] - }) - - const terminals = await runtime.listTerminals(`id:${TEST_WORKTREE_ID}`) - - expect(listWorktrees).not.toHaveBeenCalled() - expect(terminals.terminals.map((terminal) => terminal.worktreeId)).toEqual([TEST_WORKTREE_ID]) - const internals = runtime as unknown as { ptysById: Map } - expect(internals.ptysById.has('cwd-only-pty')).toBe(true) - expect(internals.ptysById.has('nested-controller-pty')).toBe(false) - }) - - it('keeps same-path folder workspace instance PTYs scoped to their exact ids', async () => { - const firstWorktreeId = `${TEST_REPO_ID}::${TEST_FOLDER_WORKSPACE_PATH}${FOLDER_WORKSPACE_INSTANCE_SEPARATOR}11111111-1111-4111-8111-111111111111` - const secondWorktreeId = `${TEST_REPO_ID}::${TEST_FOLDER_WORKSPACE_PATH}${FOLDER_WORKSPACE_INSTANCE_SEPARATOR}22222222-2222-4222-8222-222222222222` - vi.mocked(listWorktrees).mockClear() - vi.mocked(listWorktrees).mockRejectedValue( - new Error('folder explicit-id fallback should not rescan worktrees') - ) - const runtime = createRuntime() - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - listProcesses: async () => [ - { - id: 'first-folder-pty', - cwd: TEST_FOLDER_WORKSPACE_PATH, - title: 'first', - worktreeId: firstWorktreeId - }, - { - id: 'second-folder-pty', - cwd: TEST_FOLDER_WORKSPACE_PATH, - title: 'second', - worktreeId: secondWorktreeId - } - ] - }) - - const terminals = await runtime.listTerminals(`id:${secondWorktreeId}`) - - expect(listWorktrees).not.toHaveBeenCalled() - expect(terminals.terminals).toHaveLength(1) - expect(terminals.terminals[0]).toMatchObject({ - ptyId: 'second-folder-pty', - worktreeId: secondWorktreeId, - worktreePath: TEST_FOLDER_WORKSPACE_PATH - }) - const internals = runtime as unknown as { - ptysById: Map - } - expect(internals.ptysById.get('first-folder-pty')).toBeUndefined() - expect(internals.ptysById.get('second-folder-pty')?.worktreeId).toBe(secondWorktreeId) - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-02.spec.ts b/src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-02.spec.ts deleted file mode 100644 index 2f04219ebc8..00000000000 --- a/src/main/runtime/orca-runtime-tests/terminal-side-effect-facts-part-02.spec.ts +++ /dev/null @@ -1,260 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { AUTHORITATIVE_TERMINAL_SNAPSHOT_TIMEOUT_MS } from '../terminal/output/provider-snapshot-budget' -import { OrcaRuntimeService } from '../orca-runtime' -import type { AgentStatusIpcPayload } from '../../../shared/agent-status/contracts/agent-status-ipc-payload' -import { syncSinglePty, store } from './orca-runtime-test-fixtures.spec' -import { createSideEffectRuntime } from './orca-runtime-test-scenario-builders.spec' - -describe('terminal side-effect fact channel', () => { - it('bounds a hung authoritative provider acquisition and reuses its fallback', async () => { - vi.useFakeTimers() - try { - let releaseProvider: (value: null) => void = () => {} - const hungProvider = new Promise((resolve) => { - releaseProvider = resolve - }) - const serializeProviderBuffer = vi - .fn() - .mockReturnValueOnce(hungProvider) - .mockResolvedValueOnce({ - data: 'provider recovered\r\n', - cols: 100, - rows: 30, - seq: 200, - source: 'headless' - }) - const { runtime } = createSideEffectRuntime() - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeProviderBuffer, - hasRendererSerializer: () => false - }) - await syncSinglePty(runtime) - runtime.onPtyData('pty-1', 'available mirror\r\n', 100) - - const firstSnapshot = runtime.serializeAuthoritativeTerminalBuffer('pty-1', { - scrollbackRows: 5000 - }) - const concurrentSnapshot = runtime.serializeAuthoritativeTerminalBuffer('pty-1', { - scrollbackRows: 5000 - }) - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - await vi.advanceTimersByTimeAsync(AUTHORITATIVE_TERMINAL_SNAPSHOT_TIMEOUT_MS) - await expect(firstSnapshot).resolves.toMatchObject({ - data: expect.stringContaining('available mirror'), - source: 'headless' - }) - await expect(concurrentSnapshot).resolves.toMatchObject({ - data: expect.stringContaining('available mirror'), - source: 'headless' - }) - - await expect( - runtime.serializeAuthoritativeTerminalBuffer('pty-1', { scrollbackRows: 5000 }) - ).resolves.toMatchObject({ - data: expect.stringContaining('available mirror'), - source: 'headless' - }) - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - - releaseProvider(null) - await vi.advanceTimersByTimeAsync(0) - await expect( - runtime.serializeAuthoritativeTerminalBuffer('pty-1', { scrollbackRows: 5000 }) - ).resolves.toMatchObject({ - data: 'provider recovered\r\n', - source: 'headless' - }) - expect(serializeProviderBuffer).toHaveBeenCalledTimes(2) - } finally { - vi.useRealTimers() - } - }) - - it('falls back to provider history when a mounted renderer has not hydrated yet', async () => { - const { runtime } = createSideEffectRuntime() - const serializeBuffer = vi.fn().mockResolvedValue({ - data: '', - cols: 80, - rows: 24 - }) - const serializeProviderBuffer = vi.fn().mockResolvedValue({ - data: '', - scrollbackAnsi: 'restored history\r\n', - cols: 120, - rows: 40, - seq: 900, - source: 'headless' - }) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeBuffer, - serializeProviderBuffer, - hasRendererSerializer: () => true - }) - - const snapshot = await runtime.serializeTerminalBuffer('pty-restored', { - scrollbackRows: 5000 - }) - - expect(serializeBuffer).toHaveBeenCalledOnce() - expect(serializeProviderBuffer).toHaveBeenCalledWith('pty-restored', { - scrollbackRows: 5000 - }) - expect(snapshot).toMatchObject({ - data: '', - scrollbackAnsi: 'restored history\r\n', - source: 'headless' - }) - }) - - it('does not let pre-response bytes hide restored provider history', async () => { - const { runtime } = createSideEffectRuntime() - const serializeProviderBuffer = vi.fn().mockResolvedValue({ - data: 'restored history\r\nqueued', - cols: 80, - rows: 24, - seq: 906, - source: 'headless' - }) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeProviderBuffer, - hasRendererSerializer: () => false - }) - runtime.onPtyData('pty-restored', 'queued', 100) - runtime.synchronizePtyOutputSequenceFromProvider( - 'pty-restored', - { value: 900, generation: 'continued' }, - 0 - ) - - const snapshot = await runtime.serializeTerminalBuffer('pty-restored', { - scrollbackRows: 5000 - }) - - expect(snapshot?.data).toContain('restored history') - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - }) - - it('keeps mode transitions that race a provider snapshot response', async () => { - const { runtime } = createSideEffectRuntime() - let resolveProviderSnapshot: - | ((snapshot: { - data: string - cols: number - rows: number - seq: number - source: 'headless' - alternateScreen: boolean - }) => void) - | undefined - const serializeProviderBuffer = vi.fn( - () => - new Promise<{ - data: string - cols: number - rows: number - seq: number - source: 'headless' - alternateScreen: boolean - }>((resolve) => { - resolveProviderSnapshot = resolve - }) - ) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - serializeProviderBuffer, - hasRendererSerializer: () => false - }) - runtime.synchronizePtyOutputSequenceFromProvider( - 'pty-tui-race', - { value: 900, generation: 'continued' }, - 0 - ) - - const snapshotPromise = runtime.serializeTerminalBuffer('pty-tui-race') - await vi.waitFor(() => expect(resolveProviderSnapshot).toBeDefined()) - runtime.onPtyData('pty-tui-race', '\x1b[?1049l', 100) - resolveProviderSnapshot?.({ - data: 'captured alt screen', - cols: 80, - rows: 24, - seq: 900, - source: 'headless', - alternateScreen: true - }) - await snapshotPromise - - expect(runtime.isTerminalAlternateScreen('pty-tui-race')).toBe(false) - }) - - it('parses synthetic frames statelessly so ticks cannot corrupt the bell detector', async () => { - const { runtime, batches } = createSideEffectRuntime() - await syncSinglePty(runtime) - - runtime.onPtyData('pty-1', '\x1b]0;split ti', 100) - // An 80ms spinner tick lands between the two halves of the real OSC. - runtime.ingestSyntheticTitleFrame('pty-1', '\x1b]0;⠋ Cursor Agent\x07') - // This BEL terminates the real partial OSC; it is not a bell. - runtime.onPtyData('pty-1', 'tle\x07', 101) - // A later standalone BEL must still produce a bell fact. - runtime.onPtyData('pty-1', 'ready\x07', 102) - - expect(batches.flatMap((batch) => batch.facts)).toEqual([ - { kind: 'title', normalizedTitle: '⠋ Cursor Agent', rawTitle: '⠋ Cursor Agent' }, - { kind: 'agent-working' }, - { kind: 'title', normalizedTitle: 'split title', rawTitle: 'split title' }, - { kind: 'bell' } - ]) - }) -}) - -it.each([false, true])( - 'does not infer completion during stop; stopped=%s settles the pending producer', - async (stopped) => { - vi.useFakeTimers() - let row: AgentStatusIpcPayload | undefined - const runtime = new OrcaRuntimeService(store, undefined, { - getAgentStatusSnapshotForPane: () => (row ? [row] : []), - onTerminalAgentStatus: (event) => { - row = { - ...event.payload, - paneKey: event.paneKey, - connectionId: null, - stateStartedAt: Date.now(), - receivedAt: Date.now() - } - } - }) - try { - syncSinglePty(runtime) - runtime.onPtyData('pty-1', '# Command Code v0.27.3\r\n', 100) - runtime.onPtyData('pty-1', '❯ say hi\r\n✻ Thinking...', 101) - expect(row).toMatchObject({ state: 'working', agentType: 'command-code', prompt: 'say hi' }) - const settle = runtime.intentionalPtyStops.mark('pty-1', 'reversible', null) - runtime.onPtyData( - 'pty-1', - '\r\n✻ Thought for 1 second\r\n:: Hi!\r\n❯ Ask your question...', - 102 - ) - await vi.advanceTimersByTimeAsync(2000) - expect(row?.state).toBe('working') - settle(stopped) - await vi.advanceTimersByTimeAsync(2000) - expect(row?.state).toBe(stopped ? 'working' : 'done') - } finally { - await runtime.onPtyExit('pty-1', 0) - vi.useRealTimers() - } - } -) diff --git a/src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts b/src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts deleted file mode 100644 index b438293f2a8..00000000000 --- a/src/main/runtime/orca-runtime-tests/worktree-ps-structured-host.spec.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { makeStructuredAgentStatusSubject } from '../../../shared/agent-status/contracts/agent-status-subject' -import { beforeEach, describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' -import { AgentHookServer, _internals } from '../../agent-hooks/server/agent-hook-server' - -vi.mock('../../telemetry/client', () => ({ track: vi.fn() })) -vi.mock('../../telemetry/cohort-classifier', () => ({ - getCohortAtEmit: vi.fn(() => ({ nth_repo_added: 2 })) -})) - -/** Covers the production status-store read, which a hand-built projection snapshot can bypass. */ -const SESSION = 'a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d' -const SUBJECT = makeStructuredAgentStatusSubject( - { - executionHostId: 'local', - wslDistro: null, - workspaceId: TEST_WORKTREE_ID, - workspaceKind: 'git-worktree' - }, - SESSION -) - -beforeEach(() => { - _internals.resetCachesForTests() -}) - -describe('worktree ps reads structured sessions from the agent-status store', () => { - it('lists a host-held structured session with no terminal behind it', async () => { - const statusStore = new AgentHookServer() - statusStore.ingestStructuredStatus( - { - sessionId: SESSION, - workspaceId: TEST_WORKTREE_ID, - agent: 'claude', - status: 'working', - hostExecutionOwned: true, - latestPrompt: 'ship the thing', - updatedAt: 1_757_030_400_000 - }, - SUBJECT - ) - const getAgentStatusSnapshot = vi.fn(() => statusStore.getStatusSnapshot()) - - const { worktrees } = await new OrcaRuntimeService(store, undefined, { - getAgentStatusSnapshot - }).getWorktreePs() - - const worktree = worktrees.find((entry) => entry.worktreeId === TEST_WORKTREE_ID) - expect(worktree).toBeDefined() - expect(worktree?.agents).toHaveLength(1) - expect(worktree?.agents[0]).toMatchObject({ - state: 'working', - agentType: 'claude', - prompt: 'ship the thing', - structuredHostOwned: true - }) - expect(worktree?.status).toBe('working') - expect(getAgentStatusSnapshot).toHaveBeenCalledTimes(1) - }) - - it('lists nothing once the host has dropped the session', async () => { - const statusStore = new AgentHookServer() - statusStore.ingestStructuredStatus( - { - sessionId: SESSION, - workspaceId: TEST_WORKTREE_ID, - agent: 'claude', - status: 'attention', - latestPrompt: 'rm the branch', - updatedAt: 1_757_030_400_000 - }, - SUBJECT - ) - statusStore.dropStructuredStatus(SUBJECT) - - const { worktrees } = await new OrcaRuntimeService(store, undefined, { - getAgentStatusSnapshot: () => statusStore.getStatusSnapshot() - }).getWorktreePs() - - const worktree = worktrees.find((entry) => entry.worktreeId === TEST_WORKTREE_ID) - expect(worktree).toBeDefined() - expect(worktree?.agents).toEqual([]) - expect(worktree?.status).not.toBe('permission') - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-02.spec.ts b/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-02.spec.ts deleted file mode 100644 index 4d244b14c70..00000000000 --- a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-02.spec.ts +++ /dev/null @@ -1,108 +0,0 @@ -import * as gitExecFile from '../../git/command-runner/git-exec-file' -import { describe, expect, it, vi } from 'vitest' -import { readFile, mkdir, rm, writeFile } from 'node:fs/promises' - -import './runtime-test-module-registration.spec' -import { - MOCK_GIT_WORKTREES, - closeLocalWatcherForWorktreePathMock, - deleteWorktreeHistoryDirMock, - restoreLocalWatcherAfterFailedRemovalMock, - setPlatform -} from '../orca-runtime-test-mocks/setup.spec' -import { WATCHER_REMOVAL_DRAIN_BUDGET_MS } from '../../workspaces/removal/watcher-removal-drain' -import { beginWatcherInstall } from '../../workspaces/removal/watcher-removal-gate' -import { join } from 'node:path' -import { listWorktreesStrict } from '../../git/worktrees/catalog/worktree-listing' - -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' -import { - TEST_WORKTREE_ID, - TEST_WORKTREE_PATH, - createRuntime, - createStaleRuntimeWorktreeStore -} from './orca-runtime-test-fixtures.spec' -import { createWorktreeRemovalRuntime } from './orca-runtime-test-scenario-builders.spec' - -describe('OrcaRuntimeService', () => { - it('blocks new watcher installs while a pre-removal install drains', async () => { - const runtime = createRuntime() - const finishInstall = beginWatcherInstall(TEST_WORKTREE_PATH) - - const acquiring = runtime.acquireFileWatcherRemoval(TEST_WORKTREE_PATH) - await vi.waitFor(() => expect(closeLocalWatcherForWorktreePathMock).toHaveBeenCalled()) - expect(() => beginWatcherInstall(TEST_WORKTREE_PATH)).toThrow( - 'cannot start while the worktree is being removed' - ) - - finishInstall() - const gate = await acquiring - await gate.finish(false) - expect(restoreLocalWatcherAfterFailedRemovalMock).toHaveBeenCalledWith(TEST_WORKTREE_PATH) - - const finishRetry = beginWatcherInstall(TEST_WORKTREE_PATH) - finishRetry() - }) - - it('proceeds when a wedged install never releases the removal fence', async () => { - vi.useFakeTimers() - // Model an unabortable native subscribe; removal must abandon its fence slot instead of leaking it. - beginWatcherInstall(TEST_WORKTREE_PATH) - try { - const runtime = createRuntime() - - let acquired = false - const acquiring = runtime.acquireFileWatcherRemoval(TEST_WORKTREE_PATH).then((gate) => { - acquired = true - return gate - }) - await vi.advanceTimersByTimeAsync(WATCHER_REMOVAL_DRAIN_BUDGET_MS - 1) - expect(acquired).toBe(false) - - await vi.advanceTimersByTimeAsync(1) - const gate = await acquiring - expect(acquired).toBe(true) - - await gate.finish(true) - const finishRetry = beginWatcherInstall(TEST_WORKTREE_PATH) - finishRetry() - } finally { - vi.useRealTimers() - } - }) - - it('refuses a nonempty markerless Windows folder before teardown', async () => { - setPlatform('win32') - const { runtimeStore, removeWorktreeMeta } = createStaleRuntimeWorktreeStore(TEST_WORKTREE_ID) - const runtime = createWorktreeRemovalRuntime(runtimeStore) - deleteWorktreeHistoryDirMock.mockClear() - const teardown = vi.spyOn(runtime, 'acquireFileWatcherRemoval') - await mkdir(TEST_WORKTREE_PATH, { recursive: true }) - await writeFile(join(TEST_WORKTREE_PATH, 'scratch.txt'), 'delete me') - const gitSpy = vi.spyOn(gitExecFile, 'gitExecFileAsync').mockResolvedValue({ - stdout: '', - stderr: '' - }) - vi.mocked(listWorktreesStrict) - .mockResolvedValueOnce(MOCK_GIT_WORKTREES) - .mockResolvedValueOnce(MOCK_GIT_WORKTREES) - .mockResolvedValue([]) - - try { - await expect( - runtime.removeManagedWorktree(TEST_WORKTREE_ID, { force: true }) - ).rejects.toThrow('is no longer a Git worktree, so its folder was left on disk.') - expect(teardown).not.toHaveBeenCalled() - expect(removeWorktree).not.toHaveBeenCalled() - expect(removeWorktreeMeta).not.toHaveBeenCalled() - expect(deleteWorktreeHistoryDirMock).not.toHaveBeenCalled() - expect(closeLocalWatcherForWorktreePathMock).not.toHaveBeenCalled() - expect(await readFile(join(TEST_WORKTREE_PATH, 'scratch.txt'), 'utf8')).toBe('delete me') - expect(runtimeStore.getWorktreeMeta(TEST_WORKTREE_ID)).toBeDefined() - } finally { - teardown.mockRestore() - gitSpy.mockRestore() - await rm(TEST_WORKTREE_PATH, { recursive: true, force: true }) - } - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/worktree-scan-cache-ttl.spec.ts b/src/main/runtime/orca-runtime-tests/worktree-scan-cache-ttl.spec.ts deleted file mode 100644 index f8d7f555097..00000000000 --- a/src/main/runtime/orca-runtime-tests/worktree-scan-cache-ttl.spec.ts +++ /dev/null @@ -1,98 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { resolveWorktreeScanCacheTtlMs } from '../workspaces/catalog/runtime-worktree-scan-cache' -import { store } from './orca-runtime-test-fixtures.spec' -import { bumpLocalWorktreeScanGeneration } from '../../workspaces/catalog/local-worktree-scan-generation' - -describe('resolveWorktreeScanCacheTtlMs', () => { - const BASE_TTL_MS = 30_000 - const SCRATCH_TTL_MS = 5 * 60_000 - - it('never extends the TTL for SSH repos', () => { - // Remote paths that resemble local scratch paths must retain normal freshness. - expect( - resolveWorktreeScanCacheTtlMs({ - path: '/home/dev/.codex-tmp/capsule', - connectionId: 'ssh-1' - }) - ).toBe(BASE_TTL_MS) - }) - - it('keeps a scratch repo scan cached past the base TTL while normal repos rescan', async () => { - // Fake only Date: real admin-fingerprint probes must settle before refresh can invalidate the cache. - vi.useFakeTimers({ toFake: ['Date'] }) - let runtimeProbes: { size: number } = { size: 0 } - const settleFingerprintProbes = async (): Promise => { - for (let attempt = 0; attempt < 400 && runtimeProbes.size > 0; attempt += 1) { - await new Promise((resolve) => setTimeout(resolve, 5)) - } - } - vi.mocked(listWorktrees).mockClear() - try { - const scratchPath = '/tmp/.codex-tmp/capsule-a' - const runtime = new OrcaRuntimeService({ - ...store, - getRepos: () => [ - { id: 'repo-1', path: '/tmp/repo', displayName: 'repo', badgeColor: 'blue', addedAt: 1 }, - { - id: 'repo-scratch', - path: scratchPath, - displayName: 'capsule', - badgeColor: 'blue', - addedAt: 1 - } - ] - } as never) - const internals = runtime as unknown as { listResolvedWorktrees: () => Promise } - runtimeProbes = runtime['worktreeAdminFingerprintProbes'] - const scanCallsFor = (path: string): number => - vi.mocked(listWorktrees).mock.calls.filter((call) => call[0] === path).length - - await internals.listResolvedWorktrees() - await settleFingerprintProbes() - expect(scanCallsFor('/tmp/repo')).toBe(1) - expect(scanCallsFor(scratchPath)).toBe(1) - - vi.advanceTimersByTime(BASE_TTL_MS + 1_000) - await internals.listResolvedWorktrees() - expect(scanCallsFor('/tmp/repo')).toBe(2) - expect(scanCallsFor(scratchPath)).toBe(1) - - vi.advanceTimersByTime(SCRATCH_TTL_MS) - await internals.listResolvedWorktrees() - expect(scanCallsFor(scratchPath)).toBe(2) - } finally { - vi.useRealTimers() - } - }) - - it('scans a repo registered after the last snapshot instead of answering from it', async () => { - // A newly registered SSH repo must invalidate the fleet snapshot or workspace lookup falsely reports absence. - vi.mocked(listWorktrees).mockClear() - const addedPath = '/tmp/repo-registered-later' - const repos = [ - { id: 'repo-1', path: '/tmp/repo', displayName: 'repo', badgeColor: 'blue', addedAt: 1 } - ] - const runtime = new OrcaRuntimeService({ ...store, getRepos: () => repos } as never) - const internals = runtime as unknown as { listResolvedWorktrees: () => Promise } - const scanCallsFor = (path: string): number => - vi.mocked(listWorktrees).mock.calls.filter((call) => call[0] === path).length - - await internals.listResolvedWorktrees() - expect(scanCallsFor(addedPath)).toBe(0) - - repos.push({ - id: 'repo-added', - path: addedPath, - displayName: 'added', - badgeColor: 'blue', - addedAt: 2 - }) - bumpLocalWorktreeScanGeneration('repo-added') - - await internals.listResolvedWorktrees() - expect(scanCallsFor(addedPath)).toBe(1) - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/worktree-selector-resolution.spec.ts b/src/main/runtime/orca-runtime-tests/worktree-selector-resolution.spec.ts deleted file mode 100644 index fb0cb100b13..00000000000 --- a/src/main/runtime/orca-runtime-tests/worktree-selector-resolution.spec.ts +++ /dev/null @@ -1,106 +0,0 @@ -import '../../providers/ssh-host-not-served-error' -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import '../../../shared/orca-profiles/constants' -import { - MOCK_GIT_WORKTREES, - computeWorktreePathMock, - ensurePathWithinWorkspaceMock -} from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../git/worktrees/creation/worktree-sparse-add' -import '../../git/worktrees/creation/worktree-add' -import { join } from 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { mkdir, mkdtemp, writeFile } from 'node:fs/promises' -import { tmpdir } from 'node:os' -import '../rpc/dispatcher' -import '../rpc/methods/terminal/terminal' -import { - TEST_FOLDER_WORKSPACE_KEY, - TEST_REPO_ID, - TEST_WORKTREE_ID, - createFolderWorkspaceRuntimeStore, - deferred, - makeFolderProjectGroup, - makeFolderWorkspace, - store -} from './orca-runtime-test-fixtures.spec' - -describe('OrcaRuntimeService', () => { - it.each([ - { label: 'canonical folder workspace selector', selector: TEST_FOLDER_WORKSPACE_KEY }, - { label: 'id-prefixed folder workspace selector', selector: `id:${TEST_FOLDER_WORKSPACE_KEY}` } - ])('reads file explorer paths for a $label', async ({ selector }) => { - const folderPath = await mkdtemp(join(tmpdir(), 'orca-runtime-folder-files-')) - await mkdir(join(folderPath, 'src')) - await writeFile(join(folderPath, 'src', 'app.ts'), 'export {}\n') - const folderWorkspace = makeFolderWorkspace({ folderPath }) - const projectGroup = makeFolderProjectGroup({ parentPath: folderPath }) - const runtime = new OrcaRuntimeService( - createFolderWorkspaceRuntimeStore(folderWorkspace, projectGroup) as never - ) - - await expect(runtime.readFileExplorerDir(selector, 'src')).resolves.toContainEqual({ - name: 'app.ts', - isDirectory: false, - isSymlink: false - }) - await expect(runtime.readFileExplorerPreview(selector, 'src/app.ts')).resolves.toMatchObject({ - content: 'export {}\n', - isBinary: false - }) - }) - - it('does not reuse stale in-flight worktree scans after creating a worktree', async () => { - const addRetiredWorktreeName = vi.fn() - const runtime = new OrcaRuntimeService({ - ...store, - addRetiredWorktreeName, - getRetiredWorktreeNameRegistry: () => ({ - exhaustedTiers: 0, - names: Array.from({ length: 100 }, (_unused, index) => - index === 0 ? 'nautilus' : `nautilus-${index + 1}` - ) - }) - }) - const staleScan = deferred() - const createdWorktree = { - path: '/tmp/workspaces/repo-nautilus-101', - head: 'def', - branch: 'nautilus-101', - isBare: false, - isMainWorktree: false - } - computeWorktreePathMock.mockReturnValue(createdWorktree.path) - ensurePathWithinWorkspaceMock.mockReturnValue(createdWorktree.path) - vi.mocked(listWorktrees) - .mockImplementationOnce(() => staleScan.promise) - .mockResolvedValueOnce([createdWorktree]) - // listDetected prunes after the create, so it observes again with its own pre-scan claim. - .mockResolvedValueOnce([...MOCK_GIT_WORKTREES, createdWorktree]) - .mockResolvedValueOnce([...MOCK_GIT_WORKTREES, createdWorktree]) - - const staleLookup = runtime.showManagedWorktree(TEST_WORKTREE_ID) - const result = await runtime.createManagedWorktree({ - repoSelector: 'id:repo-1', - name: 'nautilus', - nameWasGenerated: true - }) - const freshLookup = runtime.showManagedWorktree(result.worktree.id) - - staleScan.resolve(MOCK_GIT_WORKTREES) - - await expect(staleLookup).resolves.toMatchObject({ id: TEST_WORKTREE_ID }) - await expect(freshLookup).resolves.toMatchObject({ - id: result.worktree.id, - path: createdWorktree.path - }) - await expect(runtime.listDetectedManagedWorktrees(`id:${TEST_REPO_ID}`)).resolves.toMatchObject( - { - worktrees: expect.arrayContaining([expect.objectContaining({ path: createdWorktree.path })]) - } - ) - expect(addRetiredWorktreeName).toHaveBeenCalledWith(TEST_REPO_ID, 'nautilus-101') - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-04.spec.ts b/src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-04.spec.ts deleted file mode 100644 index 65992d400e5..00000000000 --- a/src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-04.spec.ts +++ /dev/null @@ -1,87 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' - -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' - -import { - computeWorktreePathMock, - ensurePathWithinWorkspaceMock -} from '../orca-runtime-test-mocks/setup.spec' - -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' - -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' - -import { TEST_REPO_ID, makeWorktreeMeta, store } from './orca-runtime-test-fixtures.spec' - -import type { HostWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' - -describe('OrcaRuntimeService', () => { - it('does not send stdin-after-start prompts into a shell when the agent never starts', async () => { - vi.useFakeTimers() - try { - const metaById: Record = {} - const runtimeStore = { - ...store, - getSettings: () => ({ - ...store.getSettings(), - agentCmdOverrides: {} - }), - getAllWorktreeMeta: () => metaById, - getWorktreeMeta: (worktreeId: string) => metaById[worktreeId], - setWorktreeMeta: ({ id: worktreeId }: HostWorktreeTarget, meta: Partial) => { - metaById[worktreeId] = { ...(metaById[worktreeId] ?? makeWorktreeMeta()), ...meta } - return metaById[worktreeId] - } - } - const runtime = new OrcaRuntimeService(runtimeStore as never) - const write = vi.fn().mockReturnValue(true) - runtime.setPtyController({ - spawn: vi.fn().mockResolvedValue({ id: 'pty-cli-aider-shell' }), - write, - kill: () => true, - getForegroundProcess: async () => 'zsh', - hasChildProcesses: vi.fn().mockResolvedValue(false) - }) - runtime.setNotifier({ - worktreesChanged: vi.fn(), - reposChanged: vi.fn(), - activateWorktree: vi.fn(), - createTerminal: vi.fn(), - revealTerminalSession: vi.fn().mockResolvedValue({ tabId: 'tab-cli-aider-shell' }), - splitTerminal: vi.fn(), - renameTerminal: vi.fn(), - focusTerminal: vi.fn(), - closeTerminal: vi.fn(), - terminalFitOverrideChanged: vi.fn(), - terminalDriverChanged: vi.fn() - }) - runtime.attachWindow(1) - - computeWorktreePathMock.mockReturnValue('/tmp/workspaces/runtime-cli-aider-shell') - ensurePathWithinWorkspaceMock.mockReturnValue('/tmp/workspaces/runtime-cli-aider-shell') - vi.mocked(listWorktrees).mockResolvedValue([ - { - path: '/tmp/workspaces/runtime-cli-aider-shell', - head: 'def', - branch: 'runtime-cli-aider-shell', - isBare: false, - isMainWorktree: false - } - ]) - - await runtime.createManagedWorktree({ - repoSelector: TEST_REPO_ID, - name: 'runtime-cli-aider-shell', - startupAgent: 'aider', - startupPrompt: 'fix it' - }) - - await vi.advanceTimersByTimeAsync(6000) - - expect(write).not.toHaveBeenCalled() - } finally { - vi.useRealTimers() - } - }) -}) diff --git a/src/main/runtime/orca-runtime-tests/wsl-stopped-distro-worktree-scan.spec.ts b/src/main/runtime/orca-runtime-tests/wsl-stopped-distro-worktree-scan.spec.ts deleted file mode 100644 index c8e29246e50..00000000000 --- a/src/main/runtime/orca-runtime-tests/wsl-stopped-distro-worktree-scan.spec.ts +++ /dev/null @@ -1,89 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import * as repoWorktreeAdminFingerprint from '../workspaces/catalog/repo-worktree-admin-fingerprint' -import * as wslUncAccessGate from '../../wsl/filesystem/wsl-unc-access-gate' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { makeWorktreeInfo, makeWorktreeMeta, store } from './orca-runtime-test-fixtures.spec' - -const WSL_REPO_PATH = '\\\\wsl.localhost\\Ubuntu\\home\\me\\repo' - -function runtimeFor(path: string, storedWorktreePaths: string[] = []): OrcaRuntimeService { - const repos = [{ ...store.getRepos()[0], id: 'wsl-repo', path }] - const storedMeta = Object.fromEntries( - storedWorktreePaths.map((worktreePath) => [`wsl-repo::${worktreePath}`, makeWorktreeMeta()]) - ) - const runtimeStore = { - ...store, - getAllWorktreeMeta: () => storedMeta, - getRepos: () => repos, - getRepo: (id: string) => repos.find((repo) => repo.id === id) - } - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: the shared runtime fixture store, as sibling scan-cache specs build it. - return new OrcaRuntimeService(runtimeStore as never) -} - -describe('worktree scans of a stopped WSL distro (E9)', () => { - it('keeps the known rows and never reads the admin dir or runs Git while the distro is stopped', async () => { - vi.mocked(listWorktrees).mockReset() - vi.mocked(listWorktrees).mockImplementation(async (repoPath) => [makeWorktreeInfo(repoPath)]) - vi.useFakeTimers({ now: 0 }) - const fingerprint = vi - .spyOn(repoWorktreeAdminFingerprint, 'readRepoWorktreeAdminFingerprint') - .mockResolvedValue(null) - const blocked = vi.spyOn(wslUncAccessGate, 'blockedWslDistroForPath').mockResolvedValue(null) - // This test runs off Windows; the gate only asks about paths it maps to a distro. - const distroFor = vi.spyOn(wslUncAccessGate, 'wslDistroForPath').mockReturnValue('Ubuntu') - try { - const runtime = runtimeFor(WSL_REPO_PATH) - const running = await runtime.listDetectedManagedWorktrees('id:wsl-repo') - expect(listWorktrees).toHaveBeenCalledTimes(1) - - blocked.mockResolvedValue({ distro: 'Ubuntu', state: 'stopped' }) - fingerprint.mockClear() - vi.setSystemTime(10 * 60_000) - const stopped = await runtime.listDetectedManagedWorktrees('id:wsl-repo') - - expect(listWorktrees).toHaveBeenCalledTimes(1) - expect(fingerprint).not.toHaveBeenCalled() - expect(stopped.worktrees.map((worktree) => worktree.path)).toEqual( - running.worktrees.map((worktree) => worktree.path) - ) - expect(blocked).toHaveBeenCalledWith(WSL_REPO_PATH, undefined) - - // Once it runs again, the next scan goes to Git as before. - blocked.mockResolvedValue(null) - vi.setSystemTime(20 * 60_000) - await runtime.listDetectedManagedWorktrees('id:wsl-repo') - expect(listWorktrees).toHaveBeenCalledTimes(2) - } finally { - distroFor.mockRestore() - blocked.mockRestore() - fingerprint.mockRestore() - vi.useRealTimers() - } - }) - - it.each(['stopped', 'unverifiable'] as const)( - 'with no cached scan, a %s distro answers from stored rows without any read or Git', - async (state) => { - vi.mocked(listWorktrees).mockReset() - const fingerprint = vi.spyOn(repoWorktreeAdminFingerprint, 'readRepoWorktreeAdminFingerprint') - const blocked = vi - .spyOn(wslUncAccessGate, 'blockedWslDistroForPath') - .mockResolvedValue({ distro: 'Ubuntu', state }) - const distroFor = vi.spyOn(wslUncAccessGate, 'wslDistroForPath').mockReturnValue('Ubuntu') - try { - const runtime = runtimeFor(WSL_REPO_PATH, [WSL_REPO_PATH]) - const result = await runtime.listDetectedManagedWorktrees('id:wsl-repo') - expect(listWorktrees).not.toHaveBeenCalled() - expect(fingerprint).not.toHaveBeenCalled() - expect(result.worktrees.map((worktree) => worktree.path)).toEqual([WSL_REPO_PATH]) - } finally { - distroFor.mockRestore() - blocked.mockRestore() - fingerprint.mockRestore() - } - } - ) -}) diff --git a/src/main/runtime/orca-runtime-tests/runtime-orchestration-db.test-fixture.ts b/src/main/runtime/orchestration/db/runtime-orchestration-db.test-fixture.ts similarity index 91% rename from src/main/runtime/orca-runtime-tests/runtime-orchestration-db.test-fixture.ts rename to src/main/runtime/orchestration/db/runtime-orchestration-db.test-fixture.ts index 65657678524..e26927af14b 100644 --- a/src/main/runtime/orca-runtime-tests/runtime-orchestration-db.test-fixture.ts +++ b/src/main/runtime/orchestration/db/runtime-orchestration-db.test-fixture.ts @@ -1,11 +1,7 @@ import { afterEach, vi } from 'vitest' -import { OrchestrationDb } from '../orchestration/db/orchestration-db' -import type { TaskRuntimeLineageRow } from '../orchestration/db/run-list-page' -import type { - CoordinatorRun, - DispatchContextRow, - RunRow -} from '../orchestration/db/orchestration-records' +import { OrchestrationDb } from './orchestration-db' +import type { TaskRuntimeLineageRow } from './run-list-page' +import type { CoordinatorRun, DispatchContextRow, RunRow } from './orchestration-records' const databases = new Set() const createdAt = '2026-10-27T12:00:00Z' diff --git a/src/main/runtime/orchestration/mailbox/terminal-pointer/orchestration-mailbox-notification-test-harness.ts b/src/main/runtime/orchestration/mailbox/terminal-pointer/orchestration-mailbox-notification-test-harness.ts index 74bfe45638c..cdc9cd95bb3 100644 --- a/src/main/runtime/orchestration/mailbox/terminal-pointer/orchestration-mailbox-notification-test-harness.ts +++ b/src/main/runtime/orchestration/mailbox/terminal-pointer/orchestration-mailbox-notification-test-harness.ts @@ -13,7 +13,7 @@ import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../../shared/workspace-layou import { bindPaneFirst, registerBoundPty -} from '../../../orca-runtime-tests/bind-first-pane.test-fixture' +} from '../../../terminal/layout/bind-first-pane.test-fixture' import { publishHeadlessRuntimeGraph } from '../../../session-graph/headless-runtime-graph' export const TAB_ID = '11111111-1111-4111-8111-111111111111' diff --git a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-05.spec.ts b/src/main/runtime/orchestration/terminal-authority/lineage-and-scan-cache-part-05.spec.ts similarity index 53% rename from src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-05.spec.ts rename to src/main/runtime/orchestration/terminal-authority/lineage-and-scan-cache-part-05.spec.ts index fe5b1e79287..e4d9a4cc802 100644 --- a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-05.spec.ts +++ b/src/main/runtime/orchestration/terminal-authority/lineage-and-scan-cache-part-05.spec.ts @@ -1,164 +1,18 @@ -import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { FOLDER_WORKSPACE_INSTANCE_SEPARATOR } from '../../../shared/worktree/id' -import { OrcaRuntimeService } from '../orca-runtime' -import { OrchestrationDb } from '../orchestration/db/orchestration-db' -import { createRootDispatch } from '../orchestration/db/root-dispatch-test-fixture' -import { join } from 'node:path' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import { tmpdir } from 'node:os' -import { TEST_REPO_ID, TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' +import { describe, expect, it } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../../../shared/worktree/id' +import { OrcaRuntimeService } from '../../orca-runtime' +import { OrchestrationDb } from '../db/orchestration-db' +import { createRootDispatch } from '../db/root-dispatch-test-fixture' +import 'node:path' +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' +import 'node:os' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { - it('uses durable Run ownership before worktree-scoped legacy attribution', async () => { - const childWorktreeId = `${TEST_REPO_ID}::${join(tmpdir(), 'workspaces', 'run-a-worker')}` - const folderWorktreeId = `${TEST_REPO_ID}::${join(tmpdir(), 'folder')}${FOLDER_WORKSPACE_INSTANCE_SEPARATOR}11111111-1111-4111-8111-111111111111` - const meta = store.getAllWorktreeMeta()[TEST_WORKTREE_ID] - const metaById = { - ...store.getAllWorktreeMeta(), - [childWorktreeId]: meta, - [folderWorktreeId]: meta - } - const runtime = new OrcaRuntimeService({ - ...store, - getAllWorktreeMeta: () => metaById, - getWorktreeMeta: (worktreeId: string) => metaById[worktreeId] - } as never) - const terminals = [ - { - name: 'coordinator-a', - worktreeId: TEST_WORKTREE_ID, - leafId: '11111111-1111-4111-8111-111111111111' - }, - { - name: 'coordinator-b', - worktreeId: TEST_WORKTREE_ID, - leafId: '22222222-2222-4222-8222-222222222222' - }, - { - name: 'worker-cross-worktree', - worktreeId: childWorktreeId, - leafId: '33333333-3333-4333-8333-333333333333' - }, - { - name: 'worker-same-worktree', - worktreeId: TEST_WORKTREE_ID, - leafId: '44444444-4444-4444-8444-444444444444' - }, - { - name: 'worker-folder', - worktreeId: folderWorktreeId, - leafId: '55555555-5555-4555-8555-555555555555' - }, - { - name: 'legacy-worker', - worktreeId: childWorktreeId, - leafId: '66666666-6666-4666-8666-666666666666' - } - ].map((terminal, index) => ({ - ...terminal, - tabId: `tab-${terminal.name}`, - ptyId: `pty-${terminal.name}`, - paneRuntimeId: index + 1 - })) - const terminalByName = Object.fromEntries( - terminals.map((terminal) => [terminal.name, terminal]) - ) - const handles = Object.fromEntries( - terminals.map((terminal) => [terminal.name, runtime.preAllocateHandleForPty(terminal.ptyId)]) - ) - const paneKey = (name: string): string => { - const terminal = terminalByName[name] - return makePaneKey(terminal.tabId, terminal.leafId) - } - const db = new OrchestrationDb(':memory:') - try { - const runA = db.createRun({ - objective: 'coordinate run A', - coordinatorHandle: handles['coordinator-a'], - coordinatorPaneKey: paneKey('coordinator-a') - }) - const runB = db.createRun({ - objective: 'coordinate run B', - coordinatorHandle: handles['coordinator-b'], - coordinatorPaneKey: paneKey('coordinator-b') - }) - const dispatches = Object.fromEntries( - [ - ['worker-cross-worktree', runA.id], - ['worker-same-worktree', runA.id], - ['worker-folder', runB.id] - ].map(([name, runId]) => { - const task = db.createTask({ spec: name, runId }) - return [name, createRootDispatch(db, task.id, handles[name], paneKey(name))] - }) - ) - const legacyTask = db.createTask({ - runId: 'run_legacy_local', - spec: 'legacy worker' - }) - const legacyDispatch = createRootDispatch( - db, - legacyTask.id, - handles['legacy-worker'], - paneKey('legacy-worker') - ) - db.createCoordinatorRun({ - spec: 'unrelated legacy coordinator', - coordinatorHandle: handles['coordinator-b'] - }) - const getActiveCoordinatorRun = vi.spyOn(db, 'getActiveCoordinatorRun') - runtime.setOrchestrationDb(db) - runtime.attachWindow(1) - - const result = await runtime.syncWindowGraph(1, { - tabs: terminals.map((terminal) => ({ - tabId: terminal.tabId, - worktreeId: terminal.worktreeId, - title: terminal.name, - activeLeafId: terminal.leafId, - layout: null - })), - leaves: terminals.map((terminal) => ({ - tabId: terminal.tabId, - worktreeId: terminal.worktreeId, - leafId: terminal.leafId, - paneRuntimeId: terminal.paneRuntimeId, - ptyId: terminal.ptyId, - paneTitle: null - })) - }) - - for (const [name, run, coordinator] of [ - ['worker-cross-worktree', runA, 'coordinator-a'], - ['worker-same-worktree', runA, 'coordinator-a'], - ['worker-folder', runB, 'coordinator-b'] - ] as const) { - expect(result.agentOrchestrationByPaneKey?.[paneKey(name)]).toMatchObject({ - taskId: dispatches[name].task_id, - dispatchId: dispatches[name].id, - dispatchStatus: 'dispatched', - parentTerminalHandle: handles[coordinator], - parentPaneKey: paneKey(coordinator), - coordinatorHandle: handles[coordinator], - orchestrationRunId: run.id - }) - } - const legacyContext = result.agentOrchestrationByPaneKey?.[paneKey('legacy-worker')] - expect(legacyContext).toMatchObject({ - taskId: legacyTask.id, - dispatchId: legacyDispatch.id, - dispatchStatus: 'dispatched' - }) - expect(legacyContext).not.toHaveProperty('parentTerminalHandle') - expect(legacyContext).not.toHaveProperty('coordinatorHandle') - expect(legacyContext).not.toHaveProperty('orchestrationRunId') - expect(getActiveCoordinatorRun).toHaveBeenCalledOnce() - } finally { - db.close() - } - }) - it('uses the still-bound owning Run coordinator after a creator pane rebinds', async () => { const runtime = new OrcaRuntimeService(store) const terminals = [ diff --git a/src/main/runtime/orchestration/terminal-authority/opencode-finished-session-authority.test.ts b/src/main/runtime/orchestration/terminal-authority/opencode-finished-session-authority.test.ts index 55a63313e29..d6395b802cb 100644 --- a/src/main/runtime/orchestration/terminal-authority/opencode-finished-session-authority.test.ts +++ b/src/main/runtime/orchestration/terminal-authority/opencode-finished-session-authority.test.ts @@ -17,7 +17,7 @@ import { AgentHookServer } from '../../../agent-hooks/server/agent-hook-server' import { OrcaRuntimeService } from '../../orca-runtime' import { makeStore } from '../../rpc/server/runtime-rpc-worktree-store-fixtures' import { spawnedPtyEnv } from '../../terminal/launch/spawned-pty-env-fixtures' -import { committingSpawn } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { committingSpawn } from '../../terminal/layout/bind-first-pane.test-fixture' // STA-4557: deferred OpenCode foreground reads retained/revived finished authority (#14866, reverted in #14943). diff --git a/src/main/runtime/orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-persistence.test.ts b/src/main/runtime/orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-persistence.test.ts index ec46a30a74e..9f15053f0e1 100644 --- a/src/main/runtime/orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-persistence.test.ts +++ b/src/main/runtime/orchestration/terminal-authority/runtime-legacy-worker-terminal-recovery-persistence.test.ts @@ -6,7 +6,7 @@ import type { ExecutionHostId } from '../../../../shared/execution-host/executio import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' -import { withDurableRuntimeStore } from '../../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { RuntimeLegacyWorkerTerminalRecoveryPersistence } from './runtime-legacy-worker-terminal-recovery-persistence' diff --git a/src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail-rig.test-fixture.ts b/src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail-rig.test-fixture.ts index 18503816394..b0070f0f474 100644 --- a/src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail-rig.test-fixture.ts +++ b/src/main/runtime/orchestration/terminal-authority/structured-sessions/structured-chat-coordinator-mail-rig.test-fixture.ts @@ -34,7 +34,7 @@ import { type FakeConnection } from './structured-chat-coordinator-fake-codex-fixture' import { createStructuredAgentSessionLogger } from '../../../../native-chat/agent-session-wire/host/structured-agent-session-logger' -import { scriptedCodexTransport } from '../../../orca-runtime-tests/scripted-codex-transport.test-fixture' +import { scriptedCodexTransport } from '../../../agent-session/testing/scripted-codex-transport.test-fixture' export const COORDINATOR = '4a1f6c2e-8b3d-4e7a-9c15-0d2b6e8f1a37' export const PEER_CHAT = '7e3b9d15-2c4a-4f86-a0b1-5c9e2d7f3b64' diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness.spec.ts b/src/main/runtime/orchestration/terminal-authority/terminal-creation-and-readiness.spec.ts similarity index 55% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness.spec.ts rename to src/main/runtime/orchestration/terminal-authority/terminal-creation-and-readiness.spec.ts index bab05aeaa99..b674f9ff243 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness.spec.ts +++ b/src/main/runtime/orchestration/terminal-authority/terminal-creation-and-readiness.spec.ts @@ -1,9 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import { committingSpawn, registerLivePty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' +import { + committingSpawn, + registerLivePty +} from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' import { HEADLESS_LEAF_ID, RESTORED_AUTHORITY_TOKEN, @@ -11,14 +14,12 @@ import { TEST_WINDOW_ID, TEST_WORKTREE_ID, TEST_WORKTREE_PATH, - deferred, - makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal, store -} from './orca-runtime-test-fixtures.spec' -import { spawnedPtyEnv } from '../terminal/launch/spawned-pty-env-fixtures' -import '../../../shared/agent-launch/startup/jcode-runtime-dir' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { spawnedPtyEnv } from '../../terminal/launch/spawned-pty-env-fixtures' +import '../../../../shared/agent-launch/startup/jcode-runtime-dir' describe('OrcaRuntimeService', () => { it('retires inherited launch authority when the agent command exits', async () => { @@ -163,124 +164,4 @@ describe('OrcaRuntimeService', () => { processIncarnation: `persisted-pty:${incarnationId}` }) }) - - it('drops an out-of-order aggregate inventory after a newer SSH inventory', async () => { - const targetId = 'ssh-1' - const ptyId = `ssh:${targetId}@@persisted-pty` - const paneKey = makePaneKey('host-tab', HEADLESS_LEAF_ID) - const oldIncarnation = 'bbbbbbbb-bbbb-4bbb-8bbb-bbbbbbbbbbbb' - const newIncarnation = 'cccccccc-cccc-4ccc-8ccc-cccccccccccc' - const session = makeWorkspaceSessionWithHeadlessTerminal({ - tabsByWorktree: { - [TEST_WORKTREE_ID]: [ - { - id: 'host-tab', - ptyId, - worktreeId: TEST_WORKTREE_ID, - title: 'Persisted Terminal', - customTitle: null, - color: null, - sortOrder: 0, - createdAt: 1 - } - ] - }, - terminalLayoutsByTabId: { - 'host-tab': makeHeadlessTerminalLayout({ [HEADLESS_LEAF_ID]: ptyId }) - }, - terminalPtyIncarnationsByPaneKey: { [paneKey]: oldIncarnation } - }) - const { runtimeStore } = makeRuntimeStoreWithWorkspaceSession(session) - const runtime = new OrcaRuntimeService(runtimeStore as never, undefined, { - attestAgentHookCompatibilityAuthority: ({ paneKey: candidate, launchTokenHash }) => - candidate === paneKey && launchTokenHash === RESTORED_AUTHORITY_TOKEN_HASH - ? { paneKey: candidate, source: 'hydrated_commitment' } - : null - }) - const oldInventory = deferred< - { - id: string - incarnationId: string - terminalHandle: string - worktreeId: string - cwd: string - title: string - wslDistro: null - }[] - >() - const newInventory = - deferred ? T : never>() - const listProcesses = vi - .fn() - .mockImplementationOnce(() => oldInventory.promise) - .mockImplementationOnce(() => newInventory.promise) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - listProcesses - }) - const internals = runtime as unknown as { - refreshPtyWorktreeRecordsWithControllerInventory: ( - worktrees: [], - targetWorktreeId: string | null, - deadline: number | undefined, - connectionId: string | null | undefined - ) => Promise - ptysById: Map - restoredOrchestrationAuthorityByPtyId: Map - } - const host = runtime.registerOrchestrationCompatibilitySshAttachment( - targetId, - 'connection-incarnation' - ) - - const staleRefresh = internals.refreshPtyWorktreeRecordsWithControllerInventory( - [], - null, - undefined, - undefined - ) - const currentRefresh = internals.refreshPtyWorktreeRecordsWithControllerInventory( - [], - null, - undefined, - targetId - ) - newInventory.resolve([ - { - id: ptyId, - incarnationId: newIncarnation, - terminalHandle: 'term_new_process', - worktreeId: TEST_WORKTREE_ID, - cwd: TEST_WORKTREE_PATH, - title: 'Replacement', - wslDistro: null - } - ]) - await expect(currentRefresh).resolves.not.toBeNull() - oldInventory.resolve([ - { - id: ptyId, - incarnationId: oldIncarnation, - terminalHandle: 'term_old_process', - worktreeId: TEST_WORKTREE_ID, - cwd: TEST_WORKTREE_PATH, - title: 'Retained coordinator', - wslDistro: null - } - ]) - await expect(staleRefresh).resolves.toBeNull() - - expect(internals.ptysById.get(ptyId)?.incarnationId).toBe(newIncarnation) - expect(internals.restoredOrchestrationAuthorityByPtyId.has(ptyId)).toBe(false) - expect( - runtime.verifyOrchestrationCompatibilityCaller({ - terminalHandle: 'term_old_process', - paneKey, - launchToken: RESTORED_AUTHORITY_TOKEN, - host - }) - ).toBeNull() - }) }) diff --git a/src/main/runtime/orca-runtime-tests/worker-recovery-releases-conversation.test.ts b/src/main/runtime/orchestration/terminal-authority/worker-recovery-releases-conversation.test.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/worker-recovery-releases-conversation.test.ts rename to src/main/runtime/orchestration/terminal-authority/worker-recovery-releases-conversation.test.ts index eb2bdf71f46..ac4f265118a 100644 --- a/src/main/runtime/orca-runtime-tests/worker-recovery-releases-conversation.test.ts +++ b/src/main/runtime/orchestration/terminal-authority/worker-recovery-releases-conversation.test.ts @@ -1,15 +1,15 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import './orca-runtime-test-lifecycle.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { OrchestrationDb } from '../orchestration/db/orchestration-db' -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { OrchestrationDb } from '../db/orchestration-db' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import type { AgentStatusIpcPayload } from '../../../shared/agent-status/contracts/agent-status-ipc-payload' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' const SESSION = { key: 'session_id', id: 'grok-session-1' } as const const DEAD_PANE_KEY = 'crashed-reopen-tab:44444444-4444-4444-8444-444444444444' diff --git a/src/main/runtime/orchestration/workers/launch/codex-reconnect-failed-dispatch.test.ts b/src/main/runtime/orchestration/workers/launch/codex-reconnect-failed-dispatch.test.ts index 114be0917d8..8139bf6967b 100644 --- a/src/main/runtime/orchestration/workers/launch/codex-reconnect-failed-dispatch.test.ts +++ b/src/main/runtime/orchestration/workers/launch/codex-reconnect-failed-dispatch.test.ts @@ -4,7 +4,7 @@ import { makePaneKey } from '../../../../../shared/workspace-layout/stable-pane- import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID -} from '../../../orca-runtime-tests/agent-transcript-pane-test-harness' +} from '../../../terminal/wait/agent-transcript-pane-test-harness' import { OrchestrationDb } from '../../db/orchestration-db' import '../../db/contract-constants' import '../../db/messages/mailbox-routing-page' diff --git a/src/main/runtime/push/notifications/runtime-mobile-notification-controller.spec.ts b/src/main/runtime/push/notifications/runtime-mobile-notification-controller.spec.ts new file mode 100644 index 00000000000..e73876ce5e0 --- /dev/null +++ b/src/main/runtime/push/notifications/runtime-mobile-notification-controller.spec.ts @@ -0,0 +1,38 @@ +import { describe, expect, it } from 'vitest' +import '../../../../shared/worktree/host-qualified-identity' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../git/worktrees/catalog/worktree-scan-cache' + +import '../../session-lifecycle/close/mobile-session-tab-close-outcome' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('isolates a throwing subscriber across runtime listener fan-out', () => { + const runtime = new OrcaRuntimeService(store) + const delivered: number[] = [] + // Sibling notification fan-outs must also isolate throwing subscribers. + runtime.onNotificationDispatched(() => { + throw new Error('subscriber_send_failed') + }) + runtime.onNotificationDispatched((event) => { + delivered.push(event.notificationSeq ?? -1) + }) + + expect(() => + runtime.dispatchMobileNotification({ + type: 'notification', + source: 'test', + title: 'Test', + body: 'Body', + worktreeId: TEST_WORKTREE_ID + }) + ).not.toThrow() + + expect(delivered).toHaveLength(1) + }) +}) diff --git a/src/main/runtime/repositories/project-setup-folder-remote-identity.spec.ts b/src/main/runtime/repositories/project-setup-folder-remote-identity.spec.ts new file mode 100644 index 00000000000..162cafae650 --- /dev/null +++ b/src/main/runtime/repositories/project-setup-folder-remote-identity.spec.ts @@ -0,0 +1,156 @@ +import { realpathSync } from 'node:fs' +import { beforeEach, describe, expect, it, vi } from 'vitest' +import '../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../orca-runtime' +import { execFileSync } from 'node:child_process' +import * as forkMetadata from '../../github/client/fetch/repo-slug-upstream' +import { join } from 'node:path' +import { mkdtemp, rm } from 'node:fs/promises' +import { projectHostSetupProjectionFromRepos } from '../../../shared/project/host-setup/project-host-setup-projection' +import { tmpdir } from 'node:os' +import { store } from '../construction/test-context/orca-runtime-test-fixtures.spec' +import type { Repo } from '../../../shared/repository/repo-types' +import type { RuntimeStore } from '../construction/runtime-store-contract' + +const parentProbe = vi.spyOn(forkMetadata, 'probeRepoUpstream') +beforeEach(() => { + parentProbe.mockReset().mockResolvedValue({ upstream: undefined, origin: null }) +}) + +function createRuntime(repos: Repo[]): OrcaRuntimeService { + const runtimeStore: RuntimeStore = { + ...store, + getRepos: () => [...repos], + addRepo: (repo: Repo) => { + repos.push(repo) + }, + getRepo: (id: string) => repos.find((repo) => repo.id === id), + updateRepo: ({ id }, updates) => { + const repo = repos.find((entry) => entry.id === id) + if (!repo) { + return null + } + Object.assign(repo, updates) + return { ...repo } + }, + removeProjectForHost: ({ id }: { id: string }) => { + const index = repos.findIndex((repo) => repo.id === id) + if (index !== -1) { + repos.splice(index, 1) + } + }, + getProjects: () => [...projectHostSetupProjectionFromRepos(repos).projects], + getProjectHostSetups: () => [...projectHostSetupProjectionFromRepos(repos).setups] + } + return new OrcaRuntimeService(runtimeStore) +} + +async function withGitFolder( + remotes: Record, + run: (path: string) => Promise +): Promise { + const tempRoot = await mkdtemp(join(tmpdir(), 'orca-runtime-folder-remote-')) + try { + execFileSync('git', ['init'], { cwd: tempRoot, stdio: 'ignore' }) + for (const [name, url] of Object.entries(remotes)) { + execFileSync('git', ['remote', 'add', name, url], { cwd: tempRoot, stdio: 'ignore' }) + } + await run(tempRoot) + } finally { + await rm(tempRoot, { recursive: true, force: true }) + } +} + +const repoA = { provider: 'github' as const, owner: 'acme', repo: 'repo-a' } + +describe('OrcaRuntimeService project setup of an existing folder (#30663)', () => { + it('refuses to relabel a folder whose own GitHub remote names another repository', async () => { + const repos: Repo[] = [] + const runtime = createRuntime(repos) + + await withGitFolder({ origin: 'https://github.com/acme/repo-b.git' }, async (path) => { + await expect( + runtime.setupProjectExistingFolder({ + projectId: 'github:acme/repo-a', + projectProviderIdentity: repoA, + hostId: 'runtime:env-1', + path, + kind: 'git' + }) + ).rejects.toThrow(/points at acme\/repo-b, not acme\/repo-a/) + }) + + expect(repos).toHaveLength(0) + }) + + it('judges an already-registered folder by its current remotes, not the stored ones', async () => { + const repos: Repo[] = [] + const runtime = createRuntime(repos) + + await withGitFolder( + { + origin: 'https://github.com/me/repo-a-fork.git', + upstream: 'https://github.com/acme/repo-a.git' + }, + async (path) => { + // Registered before the user added the `upstream` remote the refusal recommends. + repos.push({ + id: 'repo-registered', + path: realpathSync(path), + displayName: 'repo-a-fork', + badgeColor: '#000000', + addedAt: 1, + kind: 'git', + executionHostId: 'runtime:env-1', + upstream: null, + gitRemoteIdentity: { + canonicalKey: 'github.com/me/repo-a-fork', + remoteName: 'origin', + remoteUrl: 'https://github.com/me/repo-a-fork.git' + } + }) + const result = await runtime.setupProjectExistingFolder({ + projectId: 'github:acme/repo-a', + projectProviderIdentity: repoA, + hostId: 'runtime:env-1', + path, + kind: 'git' + }) + expect(result.project.id).toBe('github:acme/repo-a') + expect(result.repo.id).toBe('repo-registered') + } + ) + }) +}) + +it('retains matching null authority when a nonfork result settles during setup', async () => { + await withGitFolder({ origin: 'https://github.com/me/repo-a.git' }, async (path) => { + const repos: Repo[] = [] + const runtime = createRuntime(repos) + const gate = Promise.withResolvers() + const started = Promise.withResolvers() + parentProbe.mockImplementationOnce(() => { + started.resolve() + return gate.promise + }) + const setup = runtime.setupProjectExistingFolder({ + projectId: 'github:me/repo-a', + projectProviderIdentity: { provider: 'github', owner: 'me', repo: 'repo-a' }, + hostId: 'runtime:env-1', + path, + kind: 'git' + }) + await started.promise + execFileSync('git', ['remote', 'set-url', 'origin', 'https://github.com/other/repo-a.git'], { + cwd: path, + stdio: 'ignore' + }) + gate.resolve({ upstream: null, origin: { owner: 'me', repo: 'repo-a' } }) + const result = await setup + expect(result.project.id).toBe('github:me/repo-a') + expect(result.repo.upstream).toBeNull() + expect( + projectHostSetupProjectionFromRepos(JSON.parse(JSON.stringify(repos))).setups[0].projectId + ).toBe('github:me/repo-a') + }) +}) diff --git a/src/main/runtime/repositories/repo-icon-fork-backfill.test.ts b/src/main/runtime/repositories/repo-icon-fork-backfill.test.ts index fc76801687b..7482b0f0578 100644 --- a/src/main/runtime/repositories/repo-icon-fork-backfill.test.ts +++ b/src/main/runtime/repositories/repo-icon-fork-backfill.test.ts @@ -1,6 +1,6 @@ import { afterEach, describe, expect, it, vi } from 'vitest' import type { Repo } from '../../../shared/repository/repo-types' -import { partialRuntimeStore } from '../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../construction/test-context/runtime-store-partial-fixture' import { probeRepoUpstream, type RepoUpstreamProbe diff --git a/src/main/runtime/orca-runtime-tests/repository-project-operations-part-02.spec.ts b/src/main/runtime/repositories/repository-project-operations-part-02.spec.ts similarity index 84% rename from src/main/runtime/orca-runtime-tests/repository-project-operations-part-02.spec.ts rename to src/main/runtime/repositories/repository-project-operations-part-02.spec.ts index 193c6f0914b..660ab236f49 100644 --- a/src/main/runtime/orca-runtime-tests/repository-project-operations-part-02.spec.ts +++ b/src/main/runtime/repositories/repository-project-operations-part-02.spec.ts @@ -1,7 +1,7 @@ import * as gitSpawn from '../../git/command-runner/git-spawn' import { realpath, lstat, mkdir, mkdtemp, rm, writeFile } from 'node:fs/promises' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../construction/test-context/runtime-test-module-registration.spec' import '../../../shared/repository/appearance/repo-badge-color' import { EventEmitter } from 'node:events' import { OrcaRuntimeService } from '../orca-runtime' @@ -15,7 +15,7 @@ import { join } from 'node:path' import 'node:fs' import '../../../shared/project/host-setup/project-host-setup-projection' import { tmpdir } from 'node:os' -import { createRuntime, store } from './orca-runtime-test-fixtures.spec' +import { createRuntime, store } from '../construction/test-context/orca-runtime-test-fixtures.spec' import '../../../shared/file-access/cross-platform-path' // Clone and create register resolved paths (macOS tmpdir is a /var symlink). @@ -61,33 +61,6 @@ describe('OrcaRuntimeService', () => { } }) - it('removes an owned runtime clone target when git exits unsuccessfully', async () => { - const spawnSpy = vi.spyOn(gitSpawn, 'gitSpawnAfterWindowsEnvironmentReady') - const proc = new EventEmitter() as EventEmitter & { stderr: EventEmitter } - proc.stderr = new EventEmitter() - spawnSpy.mockResolvedValue(proc as never) - const runtime = createRuntime() - const destination = await mkdtempReal(join(tmpdir(), 'orca-runtime-clone-')) - const clonePath = join(destination, 'repo-badge-color') - - try { - const clonePromise = runtime.cloneRepo( - 'https://example.com/repo-badge-color.git', - destination - ) - await vi.waitFor(() => expect(spawnSpy).toHaveBeenCalledTimes(1)) - await writeFile(join(clonePath, 'partial.txt'), 'git wrote this before failing') - proc.stderr.emit('data', Buffer.from('fatal: repository not found\n')) - proc.emit('close', 128, null) - - await expect(clonePromise).rejects.toThrow('Clone failed: fatal: repository not found') - await expect(lstat(clonePath)).rejects.toThrow() - } finally { - spawnSpy.mockRestore() - await rm(destination, { recursive: true, force: true }) - } - }) - it('preserves an existing runtime clone target when git exits unsuccessfully', async () => { const spawnSpy = vi.spyOn(gitSpawn, 'gitSpawnAfterWindowsEnvironmentReady') const proc = new EventEmitter() as EventEmitter & { stderr: EventEmitter } diff --git a/src/main/runtime/repositories/runtime-remove-project-host-scope.test.ts b/src/main/runtime/repositories/runtime-remove-project-host-scope.test.ts index 86bb264051e..313cac63c52 100644 --- a/src/main/runtime/repositories/runtime-remove-project-host-scope.test.ts +++ b/src/main/runtime/repositories/runtime-remove-project-host-scope.test.ts @@ -5,7 +5,7 @@ import { OrcaRuntimeService } from '../orca-runtime' import { findRepoRowForHostScopedWrite } from '../../persistence/tracking-repos/repo-update-operations' import { getRepoExecutionHostId } from '../../../shared/execution-host/execution-host' import type { RepoHostTarget } from '../../../shared/repository/repo-host-identity' -import { partialRuntimeStore } from '../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../construction/test-context/runtime-store-partial-fixture' import { withProjectWorktreeCreate } from '../../workspaces/creation/worktree-create-in-flight' function registerRuntimeRemoveProjectHostScopeTests(): void { diff --git a/src/main/runtime/repositories/runtime-repository-registration-controller.test.ts b/src/main/runtime/repositories/runtime-repository-registration-controller.test.ts index ef9413784b9..6f2546d1150 100644 --- a/src/main/runtime/repositories/runtime-repository-registration-controller.test.ts +++ b/src/main/runtime/repositories/runtime-repository-registration-controller.test.ts @@ -6,7 +6,7 @@ import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' import '../../../shared/file-access/cross-platform-path' import type { Repo } from '../../../shared/repository/repo-types' import { RuntimeRepositoryRegistrationController } from './runtime-repository-registration-controller' -import { partialRuntimeStore } from '../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../construction/test-context/runtime-store-partial-fixture' vi.mock('../../repository-icons/repo-icon-autodetect', () => ({ detectRepoLocalMetadata: vi.fn().mockResolvedValue({}) diff --git a/src/main/runtime/rpc/methods/agent-launch/managed-cwd-launch.test-fixture.ts b/src/main/runtime/rpc/methods/agent-launch/managed-cwd-launch.test-fixture.ts index 73b11cada34..854bef01ed8 100644 --- a/src/main/runtime/rpc/methods/agent-launch/managed-cwd-launch.test-fixture.ts +++ b/src/main/runtime/rpc/methods/agent-launch/managed-cwd-launch.test-fixture.ts @@ -7,7 +7,7 @@ import type { WorktreeLineage } from '../../../../../shared/worktree/lineage-typ import type { Repo } from '../../../../../shared/repository/repo-types' import type { WorktreeMeta } from '../../../../../shared/worktree/meta-types' import type { AgentSessionRecordStore } from '../../../agent-session/records/agent-session-record-store' -import '../../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../../orca-runtime' import { addWorktree } from '../../../../git/worktrees/creation/worktree-add' import { @@ -18,8 +18,8 @@ import { listWorktrees } from '../../../../git/worktrees/catalog/worktree-scan-c import { store, makeWorktreeMeta -} from '../../../orca-runtime-tests/orca-runtime-test-fixtures.spec' -import { registerLivePty } from '../../../orca-runtime-tests/bind-first-pane.test-fixture' +} from '../../../construction/test-context/orca-runtime-test-fixtures.spec' +import { registerLivePty } from '../../../terminal/layout/bind-first-pane.test-fixture' import type { HostWorktreeTarget } from '../../../../../shared/worktree/host-qualified-identity' import { mergeWorktreeMetaForWrite } from '../../../../persistence/loading-store/worktree-metadata/worktree-meta-write-normalization' diff --git a/src/main/runtime/rpc/methods/host-management/status-machine-name-publish-budget.test.ts b/src/main/runtime/rpc/methods/host-management/status-machine-name-publish-budget.test.ts index 97680a578fb..779539b44a7 100644 --- a/src/main/runtime/rpc/methods/host-management/status-machine-name-publish-budget.test.ts +++ b/src/main/runtime/rpc/methods/host-management/status-machine-name-publish-budget.test.ts @@ -3,7 +3,7 @@ import { afterEach, describe, expect, it, vi } from 'vitest' import { OrcaRuntimeService } from '../../../orca-runtime' import { MACHINE_NAME_PUBLISH_WAIT_MS } from '../../../hosts/platform-probe/runtime-machine-name' import { STATUS_METHODS } from './status' -import { partialRuntimeStore } from '../../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../../construction/test-context/runtime-store-partial-fixture' // Use a fresh process before its memoized scutil lookup completes; control completion to exercise the publish deadline. const runProcessMock = vi.hoisted(() => vi.fn()) diff --git a/src/main/runtime/rpc/methods/orchestration/federation/federation-liveness-verdict.test.ts b/src/main/runtime/rpc/methods/orchestration/federation/federation-liveness-verdict.test.ts index 763b43bfae5..f1a7c3c7df4 100644 --- a/src/main/runtime/rpc/methods/orchestration/federation/federation-liveness-verdict.test.ts +++ b/src/main/runtime/rpc/methods/orchestration/federation/federation-liveness-verdict.test.ts @@ -9,7 +9,7 @@ import '../../../../orchestration/db/dispatch-row-writer' import '../../../../orchestration/db/attempt-outcome-projection' import { ORCHESTRATION_METHODS } from '../orchestration' import { isStreamingMethod, eraseRpcMethods } from '../../../core' -import { registerBoundPty } from '../../../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../../../../terminal/layout/bind-first-pane.test-fixture' // Host contact loss never proves worker exit; relay only confirmed stops as settled. diff --git a/src/main/runtime/rpc/methods/orchestration/structured-workers/structured-worker-tab-retirement.test.ts b/src/main/runtime/rpc/methods/orchestration/structured-workers/structured-worker-tab-retirement.test.ts index c9132629c30..7248751afa8 100644 --- a/src/main/runtime/rpc/methods/orchestration/structured-workers/structured-worker-tab-retirement.test.ts +++ b/src/main/runtime/rpc/methods/orchestration/structured-workers/structured-worker-tab-retirement.test.ts @@ -9,7 +9,7 @@ import type { AgentSessionLease } from '../../../../../../shared/agent-session/l import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' import { setStructuredAgentSessionHost } from '../../../../../native-chat/agent-session-wire/host/structured-agent-session-registry' -import { partialRuntimeStore } from '../../../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../../../construction/test-context/runtime-store-partial-fixture' import { OrcaRuntimeService } from '../../../../orca-runtime' import { diff --git a/src/main/runtime/rpc/methods/orchestration/worker/release/worker-release-runtime-incarnation.spec.ts b/src/main/runtime/rpc/methods/orchestration/worker/release/worker-release-runtime-incarnation.spec.ts index 3aa29f97a24..d8eedff6b09 100644 --- a/src/main/runtime/rpc/methods/orchestration/worker/release/worker-release-runtime-incarnation.spec.ts +++ b/src/main/runtime/rpc/methods/orchestration/worker/release/worker-release-runtime-incarnation.spec.ts @@ -1,7 +1,7 @@ import { afterEach, describe, expect, it, vi } from 'vitest' import { createOrchestrationWorkerReleaseHarness } from '../testing/worker-release.test-support' import { makePaneKey } from '../../../../../../../shared/workspace-layout/stable-pane-id' -import { registerBoundPty } from '../../../../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../../../../../terminal/layout/bind-first-pane.test-fixture' export function registerWorkerReleaseRuntimeIncarnationTests(): void { const PTY_ID = 'runtime_test:term_worker' diff --git a/src/main/runtime/rpc/methods/structured-sessions/structured-codex-session-rpc-test-harness.ts b/src/main/runtime/rpc/methods/structured-sessions/structured-codex-session-rpc-test-harness.ts index 4e5b629da45..79618bee6fd 100644 --- a/src/main/runtime/rpc/methods/structured-sessions/structured-codex-session-rpc-test-harness.ts +++ b/src/main/runtime/rpc/methods/structured-sessions/structured-codex-session-rpc-test-harness.ts @@ -24,7 +24,7 @@ import { STRUCTURED_AGENT_SESSION_METHODS } from './structured-agent-session' import { stopStructuredAgentSessionRuntime } from '../../../agent-session/installation/structured-agent-session-runtime' import { ensureTestStructuredAgentSessionHost as ensureStructuredAgentSessionHost } from '../../../agent-session/records/agent-session-record-store-test-harness' import { createStructuredAgentSessionLogger } from '../../../../native-chat/agent-session-wire/host/structured-agent-session-logger' -import { scriptedCodexTransport } from '../../../orca-runtime-tests/scripted-codex-transport.test-fixture' +import { scriptedCodexTransport } from '../../../agent-session/testing/scripted-codex-transport.test-fixture' export const SESSION = 'session-integration-1' export const THREAD = 'thread-integration' diff --git a/src/main/runtime/rpc/methods/workspaces/worktree-rm-cli.integration.test.ts b/src/main/runtime/rpc/methods/workspaces/worktree-rm-cli.integration.test.ts index e733e7e9345..c93c566702d 100644 --- a/src/main/runtime/rpc/methods/workspaces/worktree-rm-cli.integration.test.ts +++ b/src/main/runtime/rpc/methods/workspaces/worktree-rm-cli.integration.test.ts @@ -10,7 +10,7 @@ import { partialRuntimeStore, storeRepo, storeWorktreeMeta -} from '../../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../../construction/test-context/runtime-store-partial-fixture' import type { WorktreeMeta } from '../../../../../shared/worktree/meta-types' import type { Repo } from '../../../../../shared/repository/repo-types' import type { HostWorktreeTarget } from '../../../../../shared/worktree/host-qualified-identity' diff --git a/src/main/runtime/rpc/server/pairing/delegated-mobile-device.integration.test.ts b/src/main/runtime/rpc/server/pairing/delegated-mobile-device.integration.test.ts index 7f649430754..92404ba3671 100644 --- a/src/main/runtime/rpc/server/pairing/delegated-mobile-device.integration.test.ts +++ b/src/main/runtime/rpc/server/pairing/delegated-mobile-device.integration.test.ts @@ -24,7 +24,7 @@ import { waitForWsClose } from '../runtime-rpc-mobile-ws-test-harness' import { makeStore } from '../runtime-rpc-worktree-store-fixtures' -import { partialRuntimeStore } from '../../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../../construction/test-context/runtime-store-partial-fixture' vi.mock('../../../../git/worktrees/catalog/worktree-scan-cache', async (importOriginal) => { const facade = getWorktreeListingMocks() diff --git a/src/main/runtime/rpc/server/runtime-rpc-mobile-terminal-streaming.test.ts b/src/main/runtime/rpc/server/runtime-rpc-mobile-terminal-streaming.test.ts index 0958acd0e59..0c0873ebe2c 100644 --- a/src/main/runtime/rpc/server/runtime-rpc-mobile-terminal-streaming.test.ts +++ b/src/main/runtime/rpc/server/runtime-rpc-mobile-terminal-streaming.test.ts @@ -28,7 +28,7 @@ import { createEncryptedWsResponseReader } from './runtime-rpc-mobile-ws-test-harness' import { makeStore } from './runtime-rpc-worktree-store-fixtures' -import { committingSpawn } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { committingSpawn } from '../../terminal/layout/bind-first-pane.test-fixture' vi.mock('../../../git/worktrees/catalog/worktree-scan-cache', async (importOriginal) => { const listings = getWorktreeListingMocks() diff --git a/src/main/runtime/orca-runtime-tests/window-authority.spec.ts b/src/main/runtime/session-graph/window-authority.spec.ts similarity index 96% rename from src/main/runtime/orca-runtime-tests/window-authority.spec.ts rename to src/main/runtime/session-graph/window-authority.spec.ts index 34f91b514f5..306a25b27d4 100644 --- a/src/main/runtime/orca-runtime-tests/window-authority.spec.ts +++ b/src/main/runtime/session-graph/window-authority.spec.ts @@ -1,16 +1,16 @@ import '../../../shared/workspace-layout/layout-owner-switch' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../construction/test-context/runtime-test-module-registration.spec' import { HEADLESS_RUNTIME_WINDOW_ID } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' import '../orca-runtime' -import { RUNTIME_GRAPH_RELOAD_TIMEOUT_MS } from '../session-graph/runtime-graph-reload-lifecycle' +import { RUNTIME_GRAPH_RELOAD_TIMEOUT_MS } from './runtime-graph-reload-lifecycle' import '../orca-runtime-test-mocks/setup.spec' import { HEADLESS_LEAF_ID, TEST_WINDOW_ID, TEST_WORKTREE_ID, createRuntime -} from './orca-runtime-test-fixtures.spec' +} from '../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('keeps an earlier committed reload fenced when a later reload is cancelled', async () => { diff --git a/src/main/runtime/orca-runtime-tests/agent-resume-spawn-commands.test-fixture.ts b/src/main/runtime/session-lifecycle/projection/agent-resume-spawn-commands.test-fixture.ts similarity index 100% rename from src/main/runtime/orca-runtime-tests/agent-resume-spawn-commands.test-fixture.ts rename to src/main/runtime/session-lifecycle/projection/agent-resume-spawn-commands.test-fixture.ts diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-targeted-agent-resume.spec.ts b/src/main/runtime/session-lifecycle/projection/mobile-session-tabs-targeted-agent-resume.spec.ts similarity index 91% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-targeted-agent-resume.spec.ts rename to src/main/runtime/session-lifecycle/projection/mobile-session-tabs-targeted-agent-resume.spec.ts index d9990eb8b53..80d6e3fa805 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-targeted-agent-resume.spec.ts +++ b/src/main/runtime/session-lifecycle/projection/mobile-session-tabs-targeted-agent-resume.spec.ts @@ -1,24 +1,24 @@ import { describe, expect, it, vi } from 'vitest' -import '../../../shared/workspace-layout/layout-owner-switch' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import type { SleepingAgentSessionRecord } from '../../../shared/agent-session/lifecycle/agent-session-resume' +import '../../../../shared/workspace-layout/layout-owner-switch' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import type { SleepingAgentSessionRecord } from '../../../../shared/agent-session/lifecycle/agent-session-resume' import { HEADLESS_LEAF_ID, TEST_WINDOW_ID, TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import type { AgentStatusIpcPayload } from '../../../shared/agent-status/contracts/agent-status-ipc-payload' -import type { PtyProcessInfo } from '../../providers/pty/process-info' -import { deterministicAgentSessionUuid } from '../terminal/launch/runtime-agent-launch-resolution' -import { deriveRemoteRuntimeTerminalCreateHandle } from '../terminal/identity/remote-runtime-terminal-create-identity' -import type { RuntimePtyController } from '../terminal/lifecycle/runtime-pty-controller-contract' -import '../../ipc/pty/host-env/saved-resume-admission' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' +import type { PtyProcessInfo } from '../../../providers/pty/process-info' +import { deterministicAgentSessionUuid } from '../../terminal/launch/runtime-agent-launch-resolution' +import { deriveRemoteRuntimeTerminalCreateHandle } from '../../terminal/identity/remote-runtime-terminal-create-identity' +import type { RuntimePtyController } from '../../terminal/lifecycle/runtime-pty-controller-contract' +import '../../../ipc/pty/host-env/saved-resume-admission' import { resumeSpawns } from './agent-resume-spawn-commands.test-fixture' -import { agentProviderSessionsEqual } from '../../../shared/agent-session/lifecycle/resume/agent-provider-session-equality' +import { agentProviderSessionsEqual } from '../../../../shared/agent-session/lifecycle/resume/agent-provider-session-equality' const PANE_KEY = `host-tab:${HEADLESS_LEAF_ID}` const SESSION = { key: 'session_id', id: 'provider-session-1' } as const diff --git a/src/main/runtime/session-lifecycle/projection/orca-runtime-mobile-markdown-tab-routes.test.ts b/src/main/runtime/session-lifecycle/projection/orca-runtime-mobile-markdown-tab-routes.test.ts index 0227a43d947..83c05386c6f 100644 --- a/src/main/runtime/session-lifecycle/projection/orca-runtime-mobile-markdown-tab-routes.test.ts +++ b/src/main/runtime/session-lifecycle/projection/orca-runtime-mobile-markdown-tab-routes.test.ts @@ -28,11 +28,11 @@ vi.mock('../../files/chat-scratch-file-root', async (importOriginal) => ({ resolveRuntimeAuthorizedPath: async (path: string) => path })) -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { TEST_REPO_ID, TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, store } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') type Runtime = InstanceType diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-empty-headless-snapshot.spec.ts b/src/main/runtime/session-tabs/inventory/mobile-session-tabs-empty-headless-snapshot.spec.ts similarity index 91% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-empty-headless-snapshot.spec.ts rename to src/main/runtime/session-tabs/inventory/mobile-session-tabs-empty-headless-snapshot.spec.ts index 2a73c82247e..c9d00edc279 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-empty-headless-snapshot.spec.ts +++ b/src/main/runtime/session-tabs/inventory/mobile-session-tabs-empty-headless-snapshot.spec.ts @@ -1,14 +1,14 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import { getRuntimeBrowserPageRegistry } from '../browser/client-pages/runtime-browser-page-registry' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { getRuntimeBrowserPageRegistry } from '../../browser/client-pages/runtime-browser-page-registry' // #25900: empty windowless snapshots hid persisted live agents and stranded clients on Reconnecting. diff --git a/src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration.spec.ts b/src/main/runtime/session-tabs/layout/mobile-creation-and-orchestration.spec.ts similarity index 92% rename from src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration.spec.ts rename to src/main/runtime/session-tabs/layout/mobile-creation-and-orchestration.spec.ts index 98b5e8739d9..903550d05a5 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration.spec.ts +++ b/src/main/runtime/session-tabs/layout/mobile-creation-and-orchestration.spec.ts @@ -1,12 +1,15 @@ -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' import { describe, expect, it, vi } from 'vitest' -import { bindPaneFirst, registerBoundPty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' +import { bindPaneFirst, registerBoundPty } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' import { ipcMain } from 'electron' -import { TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' -import { createMobileCreateTestNotifier } from './orca-runtime-test-scenario-builders.spec' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createMobileCreateTestNotifier } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('does not re-deliver the agent launch command when the adopted renderer PTY spawned with one', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-03.spec.ts b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-03.spec.ts similarity index 87% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-03.spec.ts rename to src/main/runtime/session-tabs/layout/mobile-session-tabs-part-03.spec.ts index 676672c2462..20ee6c26211 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-03.spec.ts +++ b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-03.spec.ts @@ -1,14 +1,18 @@ -import '../../../shared/workspace-layout/layout-owner-switch' +import '../../../../shared/workspace-layout/layout-owner-switch' import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES, electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../browser/client-pages/runtime-browser-page-registry' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { MOCK_GIT_WORKTREES, electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../browser/client-pages/runtime-browser-page-registry' import 'electron' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { TEST_WORKTREE_ID, deferred, store } from './orca-runtime-test-fixtures.spec' -import '../../../shared/orca-profiles/constants' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import { + TEST_WORKTREE_ID, + deferred, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../../../shared/orca-profiles/constants' import './split-placement-session.test-fixture' describe('OrcaRuntimeService', () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-12.spec.ts b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-12.spec.ts similarity index 50% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-12.spec.ts rename to src/main/runtime/session-tabs/layout/mobile-session-tabs-part-12.spec.ts index 382e8c6dc1e..b70bb52ff05 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-12.spec.ts +++ b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-12.spec.ts @@ -1,16 +1,16 @@ import { describe, expect, it, vi } from 'vitest' -import { bindPaneFirst, registerBoundPty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' +import { bindPaneFirst, registerBoundPty } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' import { ipcMain } from 'electron' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, TEST_WORKTREE_ID, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('forwards inactive mobile terminal creation to the renderer without focusing it', async () => { @@ -205,170 +205,4 @@ describe('OrcaRuntimeService', () => { : [] ) }) - - it('dedupes concurrent mobile terminal creates that share a clientMutationId', async () => { - const runtime = new OrcaRuntimeService(store) - runtime.setNotifier({ - focusTerminal: vi.fn(), - worktreesChanged: vi.fn(), - reposChanged: vi.fn(), - activateWorktree: vi.fn(), - createTerminal: vi.fn(), - revealTerminalSession: vi.fn(), - splitTerminal: vi.fn(), - renameTerminal: vi.fn(), - closeTerminal: vi.fn(), - closeSessionTab: vi.fn(), - terminalFitOverrideChanged: vi.fn(), - terminalDriverChanged: vi.fn() - }) - const webContents = { send: vi.fn() } - const send = vi.fn(async (_channel: string, payload: { requestId: string }) => { - await runtime.syncWindowGraph(1, { - tabs: [], - leaves: [ - { - tabId: 'tab-renderer', - worktreeId: TEST_WORKTREE_ID, - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-renderer', - paneTitle: null - } - ], - mobileSessionTabs: [ - { - worktree: TEST_WORKTREE_ID, - publicationEpoch: 'epoch-1', - snapshotVersion: 1, - activeGroupId: 'group-1', - activeTabId: null, - activeTabType: null, - tabs: [ - { - type: 'terminal', - id: 'tab-renderer::pane:1', - parentTabId: 'tab-renderer', - leafId: 'pane:1', - title: 'Terminal', - isActive: false - } - ] - } - ] - }) - ipcMain.emit( - 'terminal:tabCreateReply', - { sender: webContents }, - { requestId: payload.requestId, tabId: 'tab-renderer', title: 'Terminal' } - ) - }) - webContents.send = send - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - electronMocks.BrowserWindow.fromId.mockReturnValue({ - isDestroyed: () => false, - webContents - }) - - const [first, second] = await Promise.all([ - runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false, - clientMutationId: 'mutation-1' - }), - runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false, - clientMutationId: 'mutation-1' - }) - ]) - - const createRequests = send.mock.calls.filter( - ([channel]) => channel === 'terminal:requestTabCreate' - ) - expect(createRequests).toHaveLength(1) - expect(second).toBe(first) - expect(first.tab).toMatchObject({ parentTabId: 'tab-renderer' }) - }) - - it('returns the settled success for a retried clientMutationId whose response was lost', async () => { - const runtime = new OrcaRuntimeService(store) - runtime.setNotifier({ - focusTerminal: vi.fn(), - worktreesChanged: vi.fn(), - reposChanged: vi.fn(), - activateWorktree: vi.fn(), - createTerminal: vi.fn(), - revealTerminalSession: vi.fn(), - splitTerminal: vi.fn(), - renameTerminal: vi.fn(), - closeTerminal: vi.fn(), - closeSessionTab: vi.fn(), - terminalFitOverrideChanged: vi.fn(), - terminalDriverChanged: vi.fn() - }) - const webContents = { send: vi.fn() } - const send = vi.fn(async (_channel: string, payload: { requestId: string }) => { - await runtime.syncWindowGraph(1, { - tabs: [], - leaves: [ - { - tabId: 'tab-renderer', - worktreeId: TEST_WORKTREE_ID, - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-renderer', - paneTitle: null - } - ], - mobileSessionTabs: [ - { - worktree: TEST_WORKTREE_ID, - publicationEpoch: 'epoch-1', - snapshotVersion: 1, - activeGroupId: 'group-1', - activeTabId: null, - activeTabType: null, - tabs: [ - { - type: 'terminal', - id: 'tab-renderer::pane:1', - parentTabId: 'tab-renderer', - leafId: 'pane:1', - title: 'Terminal', - isActive: false - } - ] - } - ] - }) - ipcMain.emit( - 'terminal:tabCreateReply', - { sender: webContents }, - { requestId: payload.requestId, tabId: 'tab-renderer', title: 'Terminal' } - ) - }) - webContents.send = send - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) - electronMocks.BrowserWindow.fromId.mockReturnValue({ - isDestroyed: () => false, - webContents - }) - - const first = await runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false, - clientMutationId: 'mutation-lost-response' - }) - // A retry within the retention window must reuse the terminal when its create reply was lost. - const retried = await runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { - activate: false, - clientMutationId: 'mutation-lost-response' - }) - - const createRequests = send.mock.calls.filter( - ([channel]) => channel === 'terminal:requestTabCreate' - ) - expect(createRequests).toHaveLength(1) - expect(retried).toBe(first) - }) }) diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-13.spec.ts b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-13.spec.ts similarity index 96% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-13.spec.ts rename to src/main/runtime/session-tabs/layout/mobile-session-tabs-part-13.spec.ts index caa28500030..cdb57b4e6ce 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-13.spec.ts +++ b/src/main/runtime/session-tabs/layout/mobile-session-tabs-part-13.spec.ts @@ -1,18 +1,21 @@ import { describe, expect, it, vi } from 'vitest' -import { committingSpawn, registerBoundPty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES, electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import { + committingSpawn, + registerBoundPty +} from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { MOCK_GIT_WORKTREES, electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { ipcMain } from 'electron' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' import { TEST_REPO_ID, TEST_WORKTREE_ID, TEST_WORKTREE_PATH, makeWorktreeMeta, store -} from './orca-runtime-test-fixtures.spec' -import { createMobileCreateTestNotifier } from './orca-runtime-test-scenario-builders.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createMobileCreateTestNotifier } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('does not dedupe mobile terminal creates across worktrees with the same clientMutationId', async () => { diff --git a/src/main/runtime/session-tabs/layout/mobile-terminal-create-resilience.spec.ts b/src/main/runtime/session-tabs/layout/mobile-terminal-create-resilience.spec.ts new file mode 100644 index 00000000000..2fa2b84fefb --- /dev/null +++ b/src/main/runtime/session-tabs/layout/mobile-terminal-create-resilience.spec.ts @@ -0,0 +1,145 @@ +import { describe, expect, it, vi } from 'vitest' +import { bindPaneFirst, registerBoundPty } from '../../terminal/layout/bind-first-pane.test-fixture' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../browser/agent-browser/agent-browser-bridge' + +import '../../../git/worktrees/removal/worktree-removal-preflight' +import { ipcMain } from 'electron' +import '../../../git/worktrees/catalog/worktree-scan-cache' +import '../../../git/worktrees/removal/worktree-removal' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createMobileCreateTestNotifier } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' + +describe('OrcaRuntimeService', () => { + describe('mobile terminal create resilience (#7718)', () => { + it('cancels the surface wait without rolling back when the client connection dies', async () => { + vi.useFakeTimers() + try { + const closeTerminal = vi.fn() + const runtime = new OrcaRuntimeService(store) + runtime.setNotifier(createMobileCreateTestNotifier(closeTerminal)) + const abort = new AbortController() + const webContents = { send: vi.fn() } + const send = vi.fn((_channel: string, payload: { requestId: string }) => { + ipcMain.emit( + 'terminal:tabCreateReply', + { sender: webContents }, + { requestId: payload.requestId, tabId: 'tab-abort', title: 'Terminal' } + ) + }) + webContents.send = send + runtime.attachWindow(1) + await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) + electronMocks.BrowserWindow.fromId.mockReturnValue({ + isDestroyed: () => false, + webContents + }) + + const create = runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { + activate: false, + signal: abort.signal + }) + const settled = create.then( + () => ({ ok: true as const }), + (error: Error) => ({ ok: false as const, error }) + ) + await vi.waitFor(() => expect(send).toHaveBeenCalledTimes(1)) + + // Disconnect must settle promptly without closing the real terminal. + abort.abort() + await vi.advanceTimersByTimeAsync(0) + const outcome = await settled + + expect(outcome.ok).toBe(false) + if (outcome.ok === false) { + expect(outcome.error.message).toBe('client_disconnected') + } + expect(closeTerminal).not.toHaveBeenCalled() + } finally { + vi.useRealTimers() + } + }) + + it('keeps a mobile-created terminal alive when its live shell has no registered pane key', async () => { + vi.useFakeTimers() + try { + const closeTerminal = vi.fn() + const runtime = new OrcaRuntimeService(store) + runtime.setNotifier(createMobileCreateTestNotifier(closeTerminal)) + const webContents = { send: vi.fn() } + const send = vi.fn((_channel: string, payload: { requestId: string }) => { + ipcMain.emit( + 'terminal:tabCreateReply', + { sender: webContents }, + { requestId: payload.requestId, tabId: 'tab-stall', title: 'Terminal' } + ) + }) + webContents.send = send + runtime.attachWindow(1) + await runtime.syncWindowGraph(1, { tabs: [], leaves: [] }) + electronMocks.BrowserWindow.fromId.mockReturnValue({ + isDestroyed: () => false, + webContents + }) + + const create = runtime.createMobileSessionTerminal(`id:${TEST_WORKTREE_ID}`, { + activate: false + }) + const settled = create.then( + () => ({ ok: true as const }), + (error: Error) => ({ ok: false as const, error }) + ) + await vi.waitFor(() => expect(send).toHaveBeenCalledTimes(1)) + + // Main-owned layouts require the spawn's binding; a renderer leaf cannot vouch for a live PTY. + if (ORCA_LAYOUT_OWNER_IS_MAIN) { + registerBoundPty(runtime, 'pty-stall', TEST_WORKTREE_ID, null, { + tabId: 'tab-stall', + leafId: '88888888-8888-4888-8888-888888888888' + }) + await vi.advanceTimersByTimeAsync(50) + expect(await settled).toEqual({ ok: true }) + expect(closeTerminal).not.toHaveBeenCalled() + return + } + // A live shell exists, but stalled renderer publication never registered its pane key. + bindPaneFirst(runtime, { + worktreeId: TEST_WORKTREE_ID, + tabId: 'tab-stall', + leafId: 'pane:1', + ptyId: 'pty-stall' + }) + await runtime.syncWindowGraph(1, { + tabs: [], + leaves: [ + { + tabId: 'tab-stall', + worktreeId: TEST_WORKTREE_ID, + leafId: 'pane:1', + paneRuntimeId: 1, + ptyId: 'pty-stall', + paneTitle: null + } + ] + }) + + await vi.advanceTimersByTimeAsync(11_000) + const outcome = await settled + + expect(outcome.ok).toBe(false) + if (outcome.ok === false) { + expect(outcome.error.message).toContain('Timed out') + } + expect(closeTerminal).not.toHaveBeenCalled() + } finally { + vi.useRealTimers() + } + }) + }) +}) diff --git a/src/main/runtime/orca-runtime-tests/split-placement-session.test-fixture.ts b/src/main/runtime/session-tabs/layout/split-placement-session.test-fixture.ts similarity index 89% rename from src/main/runtime/orca-runtime-tests/split-placement-session.test-fixture.ts rename to src/main/runtime/session-tabs/layout/split-placement-session.test-fixture.ts index c466e429158..440be5f6481 100644 --- a/src/main/runtime/orca-runtime-tests/split-placement-session.test-fixture.ts +++ b/src/main/runtime/session-tabs/layout/split-placement-session.test-fixture.ts @@ -1,8 +1,8 @@ -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' export const LEFT_LEAF = '51515151-5151-4151-8151-515151515151' export const RIGHT_LEAF = '52525252-5252-4252-8252-525252525252' diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tab-event-wait.ts b/src/main/runtime/session-tabs/publication/mobile-session-tab-event-wait.ts similarity index 64% rename from src/main/runtime/orca-runtime-tests/mobile-session-tab-event-wait.ts rename to src/main/runtime/session-tabs/publication/mobile-session-tab-event-wait.ts index 8c131179749..ef220e60c12 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tab-event-wait.ts +++ b/src/main/runtime/session-tabs/publication/mobile-session-tab-event-wait.ts @@ -1,5 +1,5 @@ import { expect, vi } from 'vitest' -import type { RuntimeMobileSessionTabsResult } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import type { RuntimeMobileSessionTabsResult } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' export async function waitForMobileSessionTabsEvents( events: RuntimeMobileSessionTabsResult[], diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-09.spec.ts b/src/main/runtime/session-tabs/publication/mobile-session-tabs-part-09.spec.ts similarity index 81% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-09.spec.ts rename to src/main/runtime/session-tabs/publication/mobile-session-tabs-part-09.spec.ts index e04de4cb1ee..0341637431f 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-09.spec.ts +++ b/src/main/runtime/session-tabs/publication/mobile-session-tabs-part-09.spec.ts @@ -1,11 +1,14 @@ import { describe, expect, it, vi } from 'vitest' -import { committingSpawn } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' +import { committingSpawn } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' import { waitForMobileSessionTabsEvents } from './mobile-session-tab-event-wait' -import type { RuntimeMobileSessionTabsResult } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' -import { TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' +import type { RuntimeMobileSessionTabsResult } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('keeps the activated headless tab active across PTY republishes (serve focus-jump regression)', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs.spec.ts b/src/main/runtime/session-tabs/publication/mobile-session-tabs.spec.ts similarity index 82% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs.spec.ts rename to src/main/runtime/session-tabs/publication/mobile-session-tabs.spec.ts index 43f06741e51..3717db61ec0 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs.spec.ts +++ b/src/main/runtime/session-tabs/publication/mobile-session-tabs.spec.ts @@ -1,14 +1,17 @@ import { describe, expect, it } from 'vitest' -import './bind-first-pane.test-fixture' -import '../terminal/layout/profile-session-store.test-fixture' -import '../__fixtures__/main-layout-close-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import '../../../shared/orca-profiles/constants' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../terminal/layout/profile-session-store.test-fixture' +import '../../__fixtures__/main-layout-close-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../../../shared/orca-profiles/constants' -import { TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' -import '../../../shared/worktree/host-qualified-identity' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('keeps published mobile terminal handles usable across renderer graph epochs', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-02.spec.ts b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-02.spec.ts similarity index 87% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-02.spec.ts rename to src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-02.spec.ts index 90c6f6afe1f..316fcabc342 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-02.spec.ts +++ b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-02.spec.ts @@ -1,8 +1,8 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import '../../../shared/orca-profiles/constants' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../../../shared/orca-profiles/constants' import { HEADLESS_LEAF_ID, @@ -10,8 +10,8 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import '../../../shared/worktree/host-qualified-identity' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('refreshes stale daemon liveness before phone-local terminal materialization', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-07.spec.ts b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-07.spec.ts similarity index 79% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-07.spec.ts rename to src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-07.spec.ts index 88ead94cedf..8d63fa214e7 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-07.spec.ts +++ b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-07.spec.ts @@ -1,9 +1,9 @@ -import type { RuntimeMobileSessionTabsResult } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import type { RuntimeMobileSessionTabsResult } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { HEADLESS_LEAF_ID, @@ -13,11 +13,11 @@ import { makeHeadlessTerminalLayout, makeWorkspaceSessionWithHeadlessTerminal, store -} from './orca-runtime-test-fixtures.spec' -import './orca-runtime-test-scenario-builders.spec' -import '../../agent-launch/agent-launch-pane-attachment' -import '../../../shared/workspace-layout/stable-pane-id' -import '../../../shared/workspace-layout/layout-owner-switch' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' +import '../../../agent-launch/agent-launch-pane-attachment' +import '../../../../shared/workspace-layout/stable-pane-id' +import '../../../../shared/workspace-layout/layout-owner-switch' describe('OrcaRuntimeService', () => { it('publishes a recovered SSH pane when its relay becomes ready after an empty restart replay', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-08.spec.ts b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-08.spec.ts similarity index 94% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-08.spec.ts rename to src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-08.spec.ts index 1f126a7239e..4247d9e583b 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-08.spec.ts +++ b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-part-08.spec.ts @@ -1,12 +1,12 @@ -import './runtime-durable-store-fixture' +import '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import '../__fixtures__/main-layout-close-fixture' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import './bind-first-pane.test-fixture' +import '../../__fixtures__/main-layout-close-fixture' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import '../../terminal/layout/bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -15,8 +15,8 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import { makePendingAgentTabActivationRuntime } from './orca-runtime-test-scenario-builders.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { makePendingAgentTabActivationRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('falls back to a plain shell when the pending tab agent is disabled', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-windowless-sleep-resume.spec.ts b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-windowless-sleep-resume.spec.ts similarity index 64% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-windowless-sleep-resume.spec.ts rename to src/main/runtime/session-tabs/restoration/mobile-session-tabs-windowless-sleep-resume.spec.ts index 477c36de9c3..c59314f4212 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-windowless-sleep-resume.spec.ts +++ b/src/main/runtime/session-tabs/restoration/mobile-session-tabs-windowless-sleep-resume.spec.ts @@ -1,16 +1,16 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import type { SleepingAgentSessionRecord } from '../../../shared/agent-session/lifecycle/agent-session-resume' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import type { SleepingAgentSessionRecord } from '../../../../shared/agent-session/lifecycle/agent-session-resume' import { HEADLESS_LEAF_ID, TEST_WINDOW_ID, TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import type { RuntimeStore } from '../construction/runtime-store-contract' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import type { RuntimeStore } from '../../construction/runtime-store-contract' const PANE_KEY = `host-tab:${HEADLESS_LEAF_ID}` // Pane-owned captures must not be resumed twice (#11598). @@ -44,15 +44,6 @@ function makeWorkingSleepStore(overrides: Partial = return fixture } -function withClaudeLaunchedTab(fixture: ReturnType): void { - const session = structuredClone(fixture.getSession()) - const tab = session.tabsByWorktree[TEST_WORKTREE_ID]?.[0] - if (tab) { - tab.launchAgent = 'claude' - } - fixture.setSession(session) -} - async function openPane( runtimeStore: RuntimeStore, windowStatus: 'blocked' | 'openable', @@ -107,40 +98,6 @@ function spawnedCommand(spawn: ReturnType, call = 0): string { describe('opening a workspace-slept running agent on a host with no window', () => { // A restart that loses the PTY still needs the saved resume flags. - it('still resumes with the recorded flags after a host restart loses the PTY', async () => { - const fixture = makeWorkingSleepStore({ - launchConfig: { agentArgs: '--permission-mode plan', agentEnv: {} } - }) - withClaudeLaunchedTab(fixture) - await ( - await openPane(fixture.runtimeStore, 'openable') - ).opened - - const restarted = await openPane(fixture.runtimeStore, 'openable') - await restarted.opened - const command = spawnedCommand(restarted.spawn) - expect(command).toContain('provider-session-1') - expect(command).toMatch(/--permission-mode'? '?plan/) - expect(command).not.toContain('--dangerously-skip-permissions') - }) - - it('resumes from both of two overlapping opens of the pane, never a plain shell', async () => { - const fixture = makeWorkingSleepStore() - withClaudeLaunchedTab(fixture) - const { opened, spawn, runtime } = await openPane(fixture.runtimeStore, 'openable') - const second = runtime.activateMobileSessionTab( - `id:${TEST_WORKTREE_ID}`, - 'host-tab', - HEADLESS_LEAF_ID, - { notifyClients: false, navigation: 'caller', intent: 'user' } - ) - - await Promise.allSettled([opened, second]) - expect(spawn).toHaveBeenCalled() - for (let call = 0; call < spawn.mock.calls.length; call += 1) { - expect(spawnedCommand(spawn, call)).toContain('provider-session-1') - } - }) it('keeps the record for the next open when the pane resume fails to spawn', async () => { const fixture = makeWorkingSleepStore() diff --git a/src/main/runtime/orca-runtime-tests/exit-retirement-activation.spec.ts b/src/main/runtime/session-tabs/terminal-retirement/exit-retirement-activation.spec.ts similarity index 93% rename from src/main/runtime/orca-runtime-tests/exit-retirement-activation.spec.ts rename to src/main/runtime/session-tabs/terminal-retirement/exit-retirement-activation.spec.ts index 5084efafc20..37f9b16c0a8 100644 --- a/src/main/runtime/orca-runtime-tests/exit-retirement-activation.spec.ts +++ b/src/main/runtime/session-tabs/terminal-retirement/exit-retirement-activation.spec.ts @@ -1,7 +1,7 @@ -import type { AdoptStablePaneArgs } from '../../ipc/pty/ipc/spawn-types' +import type { AdoptStablePaneArgs } from '../../../ipc/pty/ipc/spawn-types' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -10,7 +10,7 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' async function startSplitHost() { const { runtimeStore, getSession } = makeRuntimeStoreWithWorkspaceSession( diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-04.spec.ts b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-04.spec.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-04.spec.ts rename to src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-04.spec.ts index 8e1b7791b7f..44d7db9d4ba 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-04.spec.ts +++ b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-04.spec.ts @@ -1,11 +1,11 @@ -import './runtime-durable-store-fixture' +import '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import './mobile-session-tab-event-wait' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import '../publication/mobile-session-tab-event-wait' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import 'node:path' import 'node:fs/promises' import 'node:os' @@ -17,8 +17,8 @@ import { TEST_WORKTREE_PATH, makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession -} from './orca-runtime-test-fixtures.spec' -import '../terminal/launch/spawned-pty-env-fixtures' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../terminal/launch/spawned-pty-env-fixtures' describe('OrcaRuntimeService', () => { it('keeps a live headed runtime-owned tab until its explicit close', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-05.spec.ts b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-05.spec.ts similarity index 93% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-05.spec.ts rename to src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-05.spec.ts index b85b78cc3e0..01c28e1388e 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-05.spec.ts +++ b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-05.spec.ts @@ -1,12 +1,15 @@ -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' -import '../__fixtures__/main-layout-close-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' +import '../../__fixtures__/main-layout-close-fixture' import { describe, expect, it, vi } from 'vitest' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import { committingSpawn, registerLivePty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import type { RuntimeMobileSessionTabsResult } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import { + committingSpawn, + registerLivePty +} from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import type { RuntimeMobileSessionTabsResult } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' import { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, @@ -14,7 +17,7 @@ import { makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('uses fresh PTY management titles over stale mobile snapshot and OSC titles', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-10.spec.ts b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-10.spec.ts similarity index 95% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-10.spec.ts rename to src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-10.spec.ts index 52866015aca..14ae5abd12b 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-10.spec.ts +++ b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-10.spec.ts @@ -1,12 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import { registerLivePty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' +import { registerLivePty } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' import { expectDesktopDropsPane, expectDesktopDropsTab -} from '../__fixtures__/main-layout-close-fixture' +} from '../../__fixtures__/main-layout-close-fixture' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -14,7 +14,7 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('rejects missing requested split leaves instead of activating a sibling', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-11.spec.ts b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-11.spec.ts similarity index 95% rename from src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-11.spec.ts rename to src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-11.spec.ts index 557640faf65..ca52000f825 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-session-tabs-part-11.spec.ts +++ b/src/main/runtime/session-tabs/terminal-retirement/mobile-session-tabs-part-11.spec.ts @@ -1,9 +1,9 @@ import { describe, expect, it, vi } from 'vitest' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import { registerLivePty } from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import { registerLivePty } from '../../terminal/layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -12,7 +12,7 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { describe('close intent adjudication', () => { @@ -377,19 +377,6 @@ describe('OrcaRuntimeService', () => { expect(getSession().terminalLayoutsByTabId['host-tab']).toBeDefined() }) - it('still kills a live split leaf for an explicit user close', async () => { - const { runtime, kill } = await makeSplitLeafRuntime() - - await runtime.closeMobileSessionTab( - `id:${TEST_WORKTREE_ID}`, - `host-tab::${HEADLESS_SECOND_LEAF_ID}`, - { reason: 'user' } - ) - - expect(kill).toHaveBeenCalledWith('serve-right') - expect(kill).not.toHaveBeenCalledWith('serve-left') - }) - it('refuses without republishing when the echoed leaf is dead but a sibling is live', async () => { // Refusing a dead split leaf must not republish it into a refuse/republish/echo loop. const { runtime, getSession, kill, closeTerminal, exitShell } = await makeSplitLeafRuntime() diff --git a/src/main/runtime/sidebar-inputs/temporal/orca-runtime-workspace-unread.test.ts b/src/main/runtime/sidebar-inputs/temporal/orca-runtime-workspace-unread.test.ts index 209ff2f54ad..c5d1ae05e9c 100644 --- a/src/main/runtime/sidebar-inputs/temporal/orca-runtime-workspace-unread.test.ts +++ b/src/main/runtime/sidebar-inputs/temporal/orca-runtime-workspace-unread.test.ts @@ -17,7 +17,7 @@ import { storeRepo, storeWorktreeMeta, type PartialRuntimeStore -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' import type { FolderWorkspace } from '../../../../shared/folder-workspaces/folder-workspace-types' diff --git a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-02.spec.ts b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-02.spec.ts similarity index 92% rename from src/main/runtime/orca-runtime-tests/mobile-summaries-part-02.spec.ts rename to src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-02.spec.ts index c7293380411..c29ba3bfc28 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-02.spec.ts +++ b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-02.spec.ts @@ -1,12 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import { makeAgentStatusStoreWiring } from '../terminal/identity/agent-status-store-wiring.test-fixture' -import './runtime-test-module-registration.spec' -import '../../../shared/agent-status/contracts/agent-status-freshness' -import { MOCK_GIT_WORKTREES } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import '../../terminal/layout/bind-first-pane.test-fixture' +import { makeAgentStatusStoreWiring } from '../../terminal/identity/agent-status-store-wiring.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../../../shared/agent-status/contracts/agent-status-freshness' +import { MOCK_GIT_WORKTREES } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' import { HEADLESS_LEAF_ID, TEST_REPO_ID, @@ -15,7 +15,7 @@ import { makeWorkspaceSessionWithHeadlessTerminal, makeWorktreeMeta, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('suppresses restored-unconfirmed hook rows from worktree.ps', async () => { diff --git a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-03.spec.ts b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-03.spec.ts similarity index 89% rename from src/main/runtime/orca-runtime-tests/mobile-summaries-part-03.spec.ts rename to src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-03.spec.ts index 2818ab9b71e..046d02e09c9 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-summaries-part-03.spec.ts +++ b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-03.spec.ts @@ -1,19 +1,19 @@ import { describe, expect, it } from 'vitest' -import './bind-first-pane.test-fixture' -import '../terminal/identity/agent-status-store-wiring.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import '../orca-runtime-test-mocks/setup.spec' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../terminal/identity/agent-status-store-wiring.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import '../../orca-runtime-test-mocks/setup.spec' import 'node:path' -import '../../workspaces/catalog/worktree-path-comparison-key' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' +import '../../../workspaces/catalog/worktree-path-comparison-key' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' import { TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorktreeMeta, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' // No SSH Git provider is installed, so these fixtures use stored rows. function storedWorktreeMeta( diff --git a/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-04.spec.ts b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-04.spec.ts new file mode 100644 index 00000000000..5237429ac65 --- /dev/null +++ b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries-part-04.spec.ts @@ -0,0 +1,59 @@ +import { describe, expect, it } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../../workspaces/catalog/worktree-path-comparison-key' + +import { + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('clears stale working status after the agent exits and the shell takes over the title', async () => { + // Recompute from the live title so retained agent status cannot strand a working spinner (#1437). + const runtime = new OrcaRuntimeService(store) + + runtime.attachWindow(1) + await runtime.syncWindowGraph(1, { + tabs: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + title: 'Codex working', + activeLeafId: 'pane:1', + layout: null + } + ], + leaves: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + leafId: 'pane:1', + paneRuntimeId: 1, + ptyId: 'pty-1' + } + ] + }) + + runtime.onPtyData('pty-1', '\x1b]0;Codex working\x07', 100) + const working = await runtime.getWorktreePs() + expect(working.worktrees[0].status).toBe('working') + + runtime.onPtyData('pty-1', '\x1b]0;bash\x07', 200) + const afterExit = await runtime.getWorktreePs() + expect(afterExit.worktrees[0].status).toBe('active') + }) + + it('shows worktree.ps active when the current pane is the Claude agents screen', async () => { + const runtime = new OrcaRuntimeService(store) + + await syncSinglePty(runtime, 'pty-1', { paneTitle: 'claude working' }) + runtime.onPtyData('pty-1', '\x1b]0;claude working\x07', 100) + await syncSinglePty(runtime, 'pty-1', { paneTitle: 'claude agents' }) + + const summary = await runtime.getWorktreePs() + + expect(summary.worktrees[0].status).toBe('active') + }) +}) diff --git a/src/main/runtime/orca-runtime-tests/mobile-summaries.spec.ts b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries.spec.ts similarity index 94% rename from src/main/runtime/orca-runtime-tests/mobile-summaries.spec.ts rename to src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries.spec.ts index fb7c66df399..c076353e34c 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-summaries.spec.ts +++ b/src/main/runtime/sidebar-inputs/workspace-facts/mobile-summaries.spec.ts @@ -1,7 +1,7 @@ import { describe, expect, it, vi } from 'vitest' -import { makeAgentStatusStoreWiring } from '../terminal/identity/agent-status-store-wiring.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import { makeAgentStatusStoreWiring } from '../../terminal/identity/agent-status-store-wiring.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { HEADLESS_LEAF_ID, TEST_REPO_ID, @@ -11,7 +11,7 @@ import { makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('prefers migrated layout ownership over a worktree id frozen in the PTY id', async () => { diff --git a/src/main/runtime/terminal/adoption/terminal-handles-and-agent-status-part-04.spec.ts b/src/main/runtime/terminal/adoption/terminal-handles-and-agent-status-part-04.spec.ts new file mode 100644 index 00000000000..04ca7603844 --- /dev/null +++ b/src/main/runtime/terminal/adoption/terminal-handles-and-agent-status-part-04.spec.ts @@ -0,0 +1,116 @@ +import type { AdoptStablePaneArgs, AdoptStablePaneResult } from '../../../ipc/pty/ipc/spawn-types' +import { describe, expect, it, vi } from 'vitest' +import '../layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { + HEADLESS_LEAF_ID, + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('preserves host metadata when terminal.create adopts a stable pane owner', async () => { + const adoptStablePane = vi.fn( + async (args: AdoptStablePaneArgs): Promise => { + await args.spawnFresh?.({ mustExist: false }) + return null + } + ) + const spawn = vi.fn(async (opts: { adoptedStablePane?: { owner: { handle?: string } } }) => + opts.adoptedStablePane + ? { + id: 'pty-stable-owner', + isReattach: true, + stablePaneOwner: { + handle: opts.adoptedStablePane.owner.handle!, + tabId: 'stable-owner-tab', + leafId: HEADLESS_LEAF_ID + } + } + : { id: 'pty-stable-owner' } + ) + const runtimeStore = { + ...store, + getSettings: () => ({ + ...store.getSettings(), + claudeAgentTeamsMode: 'in-process' as const + }) + } + const runtime = new OrcaRuntimeService(runtimeStore) + runtime.setPtyController({ + adoptStablePane, + spawn, + write: () => true, + kill: () => true, + getForegroundProcess: async () => null + }) + const first = await runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { + tabId: 'stable-owner-tab', + leafId: HEADLESS_LEAF_ID, + title: 'Original owner', + launchAgent: 'claude' + }) + adoptStablePane.mockResolvedValueOnce({ + materialized: true, + result: { id: 'pty-stable-owner', isReattach: true }, + owner: { + handle: first.handle, + tabId: 'stable-owner-tab', + leafId: HEADLESS_LEAF_ID, + ptyId: 'pty-stable-owner' + } + }) + + const adopted = await runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { + tabId: 'stable-owner-tab', + leafId: HEADLESS_LEAF_ID, + title: 'Replacement intent', + command: "claude 'replacement'", + launchAgent: 'claude' + }) + const listed = await runtime.listMobileSessionTabs(`id:${TEST_WORKTREE_ID}`) + + expect(adopted).toMatchObject({ + handle: first.handle, + ptyId: 'pty-stable-owner', + title: 'Original owner', + isReattach: true + }) + expect(listed.tabs).toEqual([ + expect.objectContaining({ + parentTabId: 'stable-owner-tab', + title: 'Original owner', + launchAgent: 'claude' + }) + ]) + expect(spawn).toHaveBeenCalledOnce() + }) + + it('refuses before spawning when the client disconnects during pane adoption', async () => { + const abort = new AbortController() + const spawn = vi.fn() + const runtime = new OrcaRuntimeService(store) + runtime.setPtyController({ + adoptStablePane: vi.fn(async (args: AdoptStablePaneArgs) => { + abort.abort() + await args.spawnFresh?.({ mustExist: false }) + return null + }), + spawn, + write: () => true, + kill: () => true, + getForegroundProcess: async () => null + }) + + await expect( + runtime.createTerminal(`id:${TEST_WORKTREE_ID}`, { + tabId: 'disconnected-during-adopt', + leafId: HEADLESS_LEAF_ID, + signal: abort.signal + }) + ).rejects.toThrow('client_disconnected') + + expect(spawn).not.toHaveBeenCalled() + }) +}) diff --git a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-02.spec.ts b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-02.spec.ts similarity index 79% rename from src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-02.spec.ts rename to src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-02.spec.ts index 904649a6eac..86bd8870f95 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-02.spec.ts +++ b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-02.spec.ts @@ -1,11 +1,11 @@ -import './runtime-orchestration-db.test-fixture' -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' +import '../../orchestration/db/runtime-orchestration-db.test-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import '../../../shared/workspace-layout/layout-owner-switch' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import '../../../shared/workspace-layout/stable-pane-id' +import '../../../../shared/workspace-layout/layout-owner-switch' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import '../../../../shared/workspace-layout/stable-pane-id' import { HEADLESS_LEAF_ID, @@ -14,8 +14,8 @@ import { TEST_WORKTREE_PATH, deferred, makeRuntimeStoreWithWorkspaceSession -} from './orca-runtime-test-fixtures.spec' -import './orca-runtime-test-scenario-builders.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('preserves concurrent workspace-session changes when async orphan persistence fails', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-06.spec.ts b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-06.spec.ts similarity index 90% rename from src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-06.spec.ts rename to src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-06.spec.ts index 12aa86fb27e..a828f0f61a4 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-06.spec.ts +++ b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-06.spec.ts @@ -1,11 +1,11 @@ -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import './runtime-orchestration-db.test-fixture' -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import '../../orchestration/db/runtime-orchestration-db.test-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../../shared/orca-profiles/constants' -import '../orca-runtime-test-mocks/setup.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../../shared/orca-profiles/constants' +import '../../orca-runtime-test-mocks/setup.spec' import { HEADLESS_LEAF_ID, @@ -16,8 +16,8 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from './orca-runtime-test-fixtures.spec' -import './orca-runtime-test-scenario-builders.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('restores orphan pane and group topology without replacing a newer host-owned tab', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-07.spec.ts b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-07.spec.ts similarity index 96% rename from src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-07.spec.ts rename to src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-07.spec.ts index dfc4b49afa6..deb95cd2d3f 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-output-and-worker-recovery-part-07.spec.ts +++ b/src/main/runtime/terminal/adoption/terminal-output-and-worker-recovery-part-07.spec.ts @@ -1,8 +1,8 @@ -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { HEADLESS_LEAF_ID, TEST_REPO_ID, @@ -12,7 +12,7 @@ import { makeWorkspaceSessionWithHeadlessTerminal, store, withPlatform -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('keeps current-generation tab and leaf identity across a host restart', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-08.spec.ts b/src/main/runtime/terminal/focus/terminal-creation-and-readiness-part-08.spec.ts similarity index 83% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-08.spec.ts rename to src/main/runtime/terminal/focus/terminal-creation-and-readiness-part-08.spec.ts index 3ceeb3a5ff4..f3a03d1c108 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-08.spec.ts +++ b/src/main/runtime/terminal/focus/terminal-creation-and-readiness-part-08.spec.ts @@ -1,13 +1,16 @@ import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import '../../../shared/orca-profiles/constants' -import './runtime-test-module-registration.spec' -import '../../../shared/agent-launch/startup/agent-prompt-injection' -import '../../../shared/clipboard/clipboard-text' -import { OrcaRuntimeService } from '../orca-runtime' -import '../orca-runtime-test-mocks/setup.spec' -import '../../../shared/terminal/input/terminal-input' -import { TEST_WORKTREE_PATH, store } from './orca-runtime-test-fixtures.spec' +import '../layout/bind-first-pane.test-fixture' +import '../../../../shared/orca-profiles/constants' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../../../shared/agent-launch/startup/agent-prompt-injection' +import '../../../../shared/clipboard/clipboard-text' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../../../shared/terminal/input/terminal-input' +import { + TEST_WORKTREE_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('coalesces concurrent focusTerminal navigations so only the latest full reveal runs', async () => { diff --git a/src/main/runtime/terminal/identity/exported-pane-key-follow.test.ts b/src/main/runtime/terminal/identity/exported-pane-key-follow.test.ts index 3f5ee52717e..2e85ac2f31f 100644 --- a/src/main/runtime/terminal/identity/exported-pane-key-follow.test.ts +++ b/src/main/runtime/terminal/identity/exported-pane-key-follow.test.ts @@ -5,11 +5,11 @@ import { afterEach, beforeEach, describe, expect, it } from 'vitest' import { agentHookServer } from '../../../agent-hooks/server/agent-hook-server' import type { PtyProcessInfo } from '../../../providers/pty/process-info' -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { TEST_WORKTREE_ID, TEST_WORKTREE_PATH, store } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') // Fresh per test: the hook server is a process singleton. let OLD_TAB = '' diff --git a/src/main/runtime/terminal/identity/main-pane-record-arrival.test.ts b/src/main/runtime/terminal/identity/main-pane-record-arrival.test.ts index 47ddb5284a0..00db8bb408c 100644 --- a/src/main/runtime/terminal/identity/main-pane-record-arrival.test.ts +++ b/src/main/runtime/terminal/identity/main-pane-record-arrival.test.ts @@ -5,9 +5,9 @@ vi.mock('../../../../shared/workspace-layout/layout-owner-switch', () => ({ ORCA_LAYOUT_OWNER_IS_MAIN: true })) -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') const { HEADLESS_LEAF_ID, @@ -15,7 +15,7 @@ const { TEST_WORKTREE_PATH, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') type Listed = { id: string; incarnationId: string; connected: boolean } diff --git a/src/main/runtime/terminal/identity/orca-runtime-terminal-handle-incarnation.test.ts b/src/main/runtime/terminal/identity/orca-runtime-terminal-handle-incarnation.test.ts index 7a5c4b3392d..ecef7d4d179 100644 --- a/src/main/runtime/terminal/identity/orca-runtime-terminal-handle-incarnation.test.ts +++ b/src/main/runtime/terminal/identity/orca-runtime-terminal-handle-incarnation.test.ts @@ -2,8 +2,8 @@ import { describe, expect, it, vi } from 'vitest' import { OrcaRuntimeService } from '../../orca-runtime' import '../../../../shared/workspace-layout/stable-pane-id' import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' -import '../../orca-runtime-tests/bind-first-pane.test-fixture' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import '../layout/bind-first-pane.test-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' const PTY_ID = 'ssh:target@@relay-pty' const WORKTREE_ID = 'repo::/worktree' diff --git a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status.spec.ts b/src/main/runtime/terminal/identity/terminal-handles-and-agent-status.spec.ts similarity index 94% rename from src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status.spec.ts rename to src/main/runtime/terminal/identity/terminal-handles-and-agent-status.spec.ts index d88cb9ccd30..086061df0eb 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-handles-and-agent-status.spec.ts +++ b/src/main/runtime/terminal/identity/terminal-handles-and-agent-status.spec.ts @@ -1,10 +1,10 @@ -import { withDurableRuntimeStore } from './runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' -import './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../ports/advertised-url-watcher' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' +import '../layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../ports/advertised-url-watcher' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -12,7 +12,7 @@ import { TEST_WORKTREE_PATH, makeRuntimeStoreWithWorkspaceSession, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('never lets an old handle adopt a replacement PTY incarnation', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts b/src/main/runtime/terminal/identity/terminal-handles-part-02.spec.ts similarity index 51% rename from src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts rename to src/main/runtime/terminal/identity/terminal-handles-part-02.spec.ts index 20653d381ce..e106706d52a 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-handles-part-02.spec.ts +++ b/src/main/runtime/terminal/identity/terminal-handles-part-02.spec.ts @@ -1,15 +1,13 @@ -import { describe, expect, it, vi } from 'vitest' -import { movePaneFirst, registerBoundPty } from './bind-first-pane.test-fixture' +import { describe, expect, it } from 'vitest' +import '../layout/bind-first-pane.test-fixture' import { - HEADLESS_LEAF_ID, TEST_WINDOW_ID, TEST_WORKTREE_ID, - createRuntime, - createRuntimeWithSshLease -} from './orca-runtime-test-fixtures.spec' -import './runtime-test-module-registration.spec' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import '../orca-runtime' + createRuntime +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../../../shared/workspace-layout/stable-pane-id' +import '../../orca-runtime' describe('OrcaRuntimeService', () => { it('keeps a live CLI waiter pending when a re-keyed shared handle transfers to the live leaf', async () => { @@ -90,44 +88,4 @@ describe('OrcaRuntimeService', () => { await waiting expect(settled).toBe('rejected') }) - - it('refuses a moved SSH pane addressed through the tab it left', async () => { - // Old-tab coordinates must refuse the moved leaf; otherwise one PTY binds into two tabs. - const leaseTabId = 'tab-stale-mirror' - const currentTabId = 'tab-moved-to' - const appPtyId = 'ssh:ssh-target@@pty-9' - const runtime = createRuntimeWithSshLease(appPtyId, leaseTabId) - const stalePaneKey = makePaneKey(leaseTabId, HEADLESS_LEAF_ID) - registerBoundPty(runtime, appPtyId, TEST_WORKTREE_ID, 'ssh-target', { - tabId: leaseTabId, - leafId: HEADLESS_LEAF_ID - }) - const staleHandle = runtime.resolveTerminalPane(stalePaneKey, TEST_WORKTREE_ID).handle - movePaneFirst(runtime, leaseTabId, { - worktreeId: TEST_WORKTREE_ID, - tabId: currentTabId, - leafId: HEADLESS_LEAF_ID, - ptyId: appPtyId - }) - runtime.registerPty(appPtyId, TEST_WORKTREE_ID, 'ssh-target', { - tabId: currentTabId, - leafId: HEADLESS_LEAF_ID - }) - runtime.onPtyExit(appPtyId, -1, undefined, { hostExitConfirmed: true }) - const createTerminal = vi.spyOn(runtime, 'createTerminal') - - await expect( - runtime.recoverTerminalPane(stalePaneKey, TEST_WORKTREE_ID, staleHandle) - ).rejects.toThrow(/terminal_not_recoverable|terminal_not_found/) - const leases = runtime as unknown as { - getRecentExpiredSshLease: (worktreeId: string, tabId: string, leafId?: string) => unknown - } - expect( - leases.getRecentExpiredSshLease(TEST_WORKTREE_ID, leaseTabId, HEADLESS_LEAF_ID) - ).toBeNull() - expect( - leases.getRecentExpiredSshLease(TEST_WORKTREE_ID, currentTabId, HEADLESS_LEAF_ID) - ).not.toBeNull() - expect(createTerminal).not.toHaveBeenCalled() - }) }) diff --git a/src/main/runtime/orca-runtime-tests/terminal-handles.spec.ts b/src/main/runtime/terminal/identity/terminal-handles.spec.ts similarity index 52% rename from src/main/runtime/orca-runtime-tests/terminal-handles.spec.ts rename to src/main/runtime/terminal/identity/terminal-handles.spec.ts index dac5373b119..4ac12c8662b 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-handles.spec.ts +++ b/src/main/runtime/terminal/identity/terminal-handles.spec.ts @@ -1,151 +1,18 @@ import { describe, expect, it, vi } from 'vitest' -import { - dropFromHostInventory, - registerBoundPty, - registerLivePty -} from './bind-first-pane.test-fixture' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import type { RuntimeClientEvent } from '../../../shared/remote-runtime/session-graph/runtime-client-events' -import type { RuntimeSyncWindowGraph } from '../../../shared/remote-runtime/session-graph/runtime-session-contracts' +import { dropFromHostInventory, registerBoundPty } from '../layout/bind-first-pane.test-fixture' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' + import { HEADLESS_LEAF_ID, TEST_WINDOW_ID, TEST_WORKTREE_ID, createRuntime, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { - it('routes a launch-draft resolution to the handle-owning local and remote renderers', async () => { - const runtime = new OrcaRuntimeService(store) - const nativeChatLaunchDraftResolved = vi.fn() - const events: RuntimeClientEvent[] = [] - runtime.setNotifier({ nativeChatLaunchDraftResolved } as never) - runtime.onClientEvent((event) => events.push(event)) - runtime.attachWindow(1) - const graph: RuntimeSyncWindowGraph = { - tabs: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - title: 'Claude', - activeLeafId: 'pane:1', - layout: null - } - ], - leaves: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-1' - } - ], - mobileSessionTabs: [ - { - worktree: 'repo-1::/tmp/worktree-a', - publicationEpoch: 'launch-draft-epoch', - snapshotVersion: 1, - activeGroupId: 'group-1', - activeTabId: 'tab-1::pane:1', - activeTabType: 'terminal', - tabs: [ - { - type: 'terminal', - id: 'tab-1::pane:1', - parentTabId: 'tab-1', - leafId: 'pane:1', - title: 'Claude', - launchDraft: 'seed', - launchDraftCreatedAt: 7, - isActive: true - } - ] - } - ] - } - registerLivePty(runtime, 'pty-1', 'repo-1::/tmp/worktree-a', null, { - tabId: 'tab-1', - leafId: 'pane:1' - }) - await runtime.syncWindowGraph(1, graph) - const listed = await runtime.listMobileSessionTabs('branch:feature/foo') - const mobileTab = listed.tabs.find((tab) => tab.type === 'terminal') - if (!mobileTab?.terminal) { - throw new Error('expected mobile terminal handle') - } - expect(mobileTab).toMatchObject({ launchDraft: 'seed', launchDraftCreatedAt: 7 }) - - runtime.notifyNativeChatLaunchDraftResolved(mobileTab.terminal, { - text: 'seed', - createdAt: 7 - }) - - expect(nativeChatLaunchDraftResolved).toHaveBeenCalledWith('tab-1', { - text: 'seed', - createdAt: 7 - }) - expect(events).toContainEqual({ - type: 'nativeChatLaunchDraftResolved', - tabId: 'tab-1', - text: 'seed', - createdAt: 7 - }) - expect(runtime.getNativeChatLaunchDraftResolutionClientEventSnapshot()).toContainEqual({ - type: 'nativeChatLaunchDraftResolved', - tabId: 'tab-1', - text: 'seed', - createdAt: 7 - }) - const retired = (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( - (tab) => tab.type === 'terminal' - ) - expect(retired).not.toHaveProperty('launchDraft') - expect(retired).not.toHaveProperty('launchDraftCreatedAt') - - runtime.markRendererReloading(1) - const replay = await runtime.syncWindowGraph(1, { - ...graph, - mobileSessionTabs: graph.mobileSessionTabs?.map((snapshot) => ({ - ...snapshot, - publicationEpoch: 'launch-draft-reload', - snapshotVersion: 2 - })) - }) - expect(replay.nativeChatLaunchDraftResolutions).toEqual([ - { tabId: 'tab-1', text: 'seed', createdAt: 7 } - ]) - expect( - (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( - (tab) => tab.type === 'terminal' - ) - ).not.toHaveProperty('launchDraft') - - const reconciled = await runtime.syncWindowGraph(1, { - ...graph, - mobileSessionTabs: graph.mobileSessionTabs?.map((snapshot) => ({ - ...snapshot, - publicationEpoch: 'launch-draft-reload', - snapshotVersion: 3, - tabs: snapshot.tabs.map((tab) => { - if (tab.type !== 'terminal') { - return tab - } - return { ...tab, launchDraftCreatedAt: 8 } - }) - })) - }) - expect(reconciled.nativeChatLaunchDraftResolutions).toBeUndefined() - expect( - (await runtime.listMobileSessionTabs('branch:feature/foo')).tabs.find( - (tab) => tab.type === 'terminal' - ) - ).toMatchObject({ launchDraft: 'seed', launchDraftCreatedAt: 8 }) - }) - it('surfaces stale terminal handles for stranded panes and recovers after same-pane wake', async () => { const runtime = new OrcaRuntimeService(store) const tabId = 'tab-1' diff --git a/src/main/runtime/terminal/identity/terminal-identity-schedules.test.ts b/src/main/runtime/terminal/identity/terminal-identity-schedules.test.ts index 27a6707829e..fe6502a8ff2 100644 --- a/src/main/runtime/terminal/identity/terminal-identity-schedules.test.ts +++ b/src/main/runtime/terminal/identity/terminal-identity-schedules.test.ts @@ -1,6 +1,6 @@ import { expect, it } from 'vitest' import { identityFixture, identityGraph, LEAF, PANE } from '../query/terminal-identity.test-fixture' -import { TEST_WORKTREE_ID } from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +import { TEST_WORKTREE_ID } from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { OrchestrationDb } from '../../orchestration/db/orchestration-db' it('retains pane-issued process identity across reload with exact first-match and SSH precedence in either context', async () => { diff --git a/src/main/runtime/terminal/launch/qoder-independent-spawn-review.test.ts b/src/main/runtime/terminal/launch/qoder-independent-spawn-review.test.ts index 620c03c4b0d..d623e66ad5c 100644 --- a/src/main/runtime/terminal/launch/qoder-independent-spawn-review.test.ts +++ b/src/main/runtime/terminal/launch/qoder-independent-spawn-review.test.ts @@ -6,9 +6,9 @@ import { tmpdir } from 'node:os' import { join } from 'node:path' -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') const { store, @@ -17,8 +17,8 @@ const { createFolderWorkspaceRuntimeStore, makeFolderWorkspace, makeFolderProjectGroup -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') -const { committingSpawn } = await import('../../orca-runtime-tests/bind-first-pane.test-fixture') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') +const { committingSpawn } = await import('../layout/bind-first-pane.test-fixture') const { detectAgentCommandsOnHost } = await import('../../../preflight/agent-command-detection') beforeEach(() => vi @@ -104,7 +104,7 @@ it.each(['offline', 'legacy-identity'])( 'refuses a Qoder command-bearing create with unverifiable inventory: %s', async (state) => { const { TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const runtime = new OrcaRuntimeService(store) await runtime.syncWindowGraph(0, { tabs: [], leaves: [] }) const spawn = vi.fn() @@ -145,7 +145,7 @@ it.each(['offline', 'legacy-identity'])( it('reconciles after the reply-cache expires and isolates deliberate forks and paired callers', async () => { const { TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') vi.useFakeTimers() try { // Copy the fixture store so main-owned bindings cannot leak into shared tests. diff --git a/src/main/runtime/terminal/launch/qoder-mobile-resume-adoption.test.ts b/src/main/runtime/terminal/launch/qoder-mobile-resume-adoption.test.ts index 66379c2a96e..7098ccb4aee 100644 --- a/src/main/runtime/terminal/launch/qoder-mobile-resume-adoption.test.ts +++ b/src/main/runtime/terminal/launch/qoder-mobile-resume-adoption.test.ts @@ -2,15 +2,15 @@ import { expect, it, vi } from 'vitest' import type { SleepingAgentLaunchConfig } from '../../../../shared/agent-session/lifecycle/agent-session-resume' import { buildAgentResumeStartupPlan } from '../../../../shared/agent-launch/startup/tui-agent-resume-startup' -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') const { store, TEST_WORKTREE_PATH } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const { detectAgentCommandsOnHost } = await import('../../../preflight/agent-command-detection') const { bindPaneFirst, committingSpawn, registerBoundPty } = - await import('../../orca-runtime-tests/bind-first-pane.test-fixture') + await import('../layout/bind-first-pane.test-fixture') type SpawnPane = { worktreeId?: string; tabId?: string; leafId?: string } @@ -30,14 +30,15 @@ it.each([ 'surviving-recipe' ])('reconciles a paired Qoder resume after ambiguous creation: %s', async (scenario) => { const failure = scenario === 'Terminal creation timed out' ? scenario : 'client_disconnected' - const { withPlatform } = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + const { withPlatform } = + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') await withPlatform(scenario === 'wsl-inventory' ? 'win32' : 'darwin', async () => { vi.useFakeTimers() try { - await import('../../orca-runtime-tests/runtime-test-module-registration.spec') + await import('../../construction/test-context/runtime-test-module-registration.spec') const { electronMocks } = await import('../../orca-runtime-test-mocks/setup.spec') const { TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') vi.mocked(detectAgentCommandsOnHost).mockResolvedValue(new Set(['qoder'])) // Copy the fixture store so main-owned bindings cannot leak into shared tests. const runtime = new QoderAdoptionRuntime({ ...store }) @@ -299,7 +300,7 @@ it.each(['missing-original', 'different-agent'])( 'refuses unproven adopted launch recipe: %s', async (state) => { const { TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const { deriveRemoteRuntimeTerminalCreateHandle } = await import('../identity/remote-runtime-terminal-create-identity') const handle = deriveRemoteRuntimeTerminalCreateHandle( @@ -373,7 +374,7 @@ it('releases abandoned dispatch capacity without guessing an expired live recipe vi.useFakeTimers() try { const { TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const { deriveRemoteRuntimeTerminalCreateHandle } = await import('../identity/remote-runtime-terminal-create-identity') vi.mocked(detectAgentCommandsOnHost) diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-04.spec.ts b/src/main/runtime/terminal/launch/terminal-creation-and-readiness-part-04.spec.ts similarity index 80% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-04.spec.ts rename to src/main/runtime/terminal/launch/terminal-creation-and-readiness-part-04.spec.ts index 36378232a78..1e5c2eb92db 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-04.spec.ts +++ b/src/main/runtime/terminal/launch/terminal-creation-and-readiness-part-04.spec.ts @@ -2,16 +2,19 @@ import 'node:fs/promises' import 'node:os' import 'node:path' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { electronMocks } from '../orca-runtime-test-mocks/setup.spec' -import '../../../shared/orca-profiles/constants' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { electronMocks } from '../../orca-runtime-test-mocks/setup.spec' +import '../../../../shared/orca-profiles/constants' import { ipcMain } from 'electron' -import '../rpc/dispatcher' -import '../rpc/methods/terminal/terminal' -import { TEST_WORKTREE_ID, store } from './orca-runtime-test-fixtures.spec' -import '../terminal/launch/spawned-pty-env-fixtures' -import './orca-runtime-test-scenario-builders.spec' +import '../../rpc/dispatcher' +import '../../rpc/methods/terminal/terminal' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import './spawned-pty-env-fixtures' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { // A timed-out renderer create could finish later and duplicate a retried terminal. diff --git a/src/main/runtime/terminal/launch/terminal-pty-exit-waiter.spec.ts b/src/main/runtime/terminal/launch/terminal-pty-exit-waiter.spec.ts index 3d397a1750f..e919f3920d9 100644 --- a/src/main/runtime/terminal/launch/terminal-pty-exit-waiter.spec.ts +++ b/src/main/runtime/terminal/launch/terminal-pty-exit-waiter.spec.ts @@ -3,7 +3,7 @@ import { describe, expect, it, vi } from 'vitest' import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +} from '../wait/agent-transcript-pane-test-harness' import { readRuntimeFixture } from '../wait/agent-transcript-replay-test-harness' import { deliverTerminalAgentLaunchPrompt } from '../../rpc/methods/agent-launch/agent-launch-terminal-prompt' import { waitForWorkerAgentReady } from '../wait/launched-agent-composer-readiness' diff --git a/src/main/runtime/orca-runtime-tests/bind-first-pane.test-fixture.ts b/src/main/runtime/terminal/layout/bind-first-pane.test-fixture.ts similarity index 91% rename from src/main/runtime/orca-runtime-tests/bind-first-pane.test-fixture.ts rename to src/main/runtime/terminal/layout/bind-first-pane.test-fixture.ts index d9d6f2d0ba5..0f2d80afff1 100644 --- a/src/main/runtime/orca-runtime-tests/bind-first-pane.test-fixture.ts +++ b/src/main/runtime/terminal/layout/bind-first-pane.test-fixture.ts @@ -1,16 +1,13 @@ // L80: emulate the PTY host's binding commit before registration in layout-owner builds; switch-off writes nothing. -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import type { RuntimePtyController } from '../terminal/lifecycle/runtime-pty-controller-contract' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import { getConnectionExecutionHostId } from '../../../shared/execution-host/execution-host' -import { getPtyExecutionHost } from '../../../shared/terminal/pty/lifecycle/terminal-execution-host' -import { - asProfileSessionStore, - storeOf -} from '../terminal/layout/profile-session-store.test-fixture' -import { reusedTerminalIdUnbinding } from '../../persistence/loading-store/terminal-bindings/reused-terminal-id-unbind' -import { layoutContainsLeafId } from '../../../shared/workspace-layout/terminal-topology/terminal-pane-tree' -import type { OrcaRuntimeService } from '../orca-runtime' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import type { RuntimePtyController } from '../lifecycle/runtime-pty-controller-contract' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import { getConnectionExecutionHostId } from '../../../../shared/execution-host/execution-host' +import { getPtyExecutionHost } from '../../../../shared/terminal/pty/lifecycle/terminal-execution-host' +import { asProfileSessionStore, storeOf } from './profile-session-store.test-fixture' +import { reusedTerminalIdUnbinding } from '../../../persistence/loading-store/terminal-bindings/reused-terminal-id-unbind' +import { layoutContainsLeafId } from '../../../../shared/workspace-layout/terminal-topology/terminal-pane-tree' +import type { OrcaRuntimeService } from '../../orca-runtime' export type BoundPane = { worktreeId: string diff --git a/src/main/runtime/terminal/layout/main-owned-workspace-runtime-fixture.ts b/src/main/runtime/terminal/layout/main-owned-workspace-runtime-fixture.ts index 3a9ece97b66..9f68a22e535 100644 --- a/src/main/runtime/terminal/layout/main-owned-workspace-runtime-fixture.ts +++ b/src/main/runtime/terminal/layout/main-owned-workspace-runtime-fixture.ts @@ -9,7 +9,7 @@ import { resolveHostId } from '../../../persistence/loading-store/workspace-sess import { withDurableRuntimeStore, withRuntimePaneAdmission -} from '../../orca-runtime-tests/runtime-durable-store-fixture' +} from '../../construction/test-context/runtime-durable-store-fixture' import { OrcaRuntimeService } from '../../orca-runtime' export const REPO = { diff --git a/src/main/runtime/orca-runtime-tests/orca-runtime-layout-owner-start-fixture.ts b/src/main/runtime/terminal/layout/orca-runtime-layout-owner-start-fixture.ts similarity index 75% rename from src/main/runtime/orca-runtime-tests/orca-runtime-layout-owner-start-fixture.ts rename to src/main/runtime/terminal/layout/orca-runtime-layout-owner-start-fixture.ts index d4b5b050ec0..eb0797e0b91 100644 --- a/src/main/runtime/orca-runtime-tests/orca-runtime-layout-owner-start-fixture.ts +++ b/src/main/runtime/terminal/layout/orca-runtime-layout-owner-start-fixture.ts @@ -1,15 +1,18 @@ // Windowless layout-owner fixture applies commands in memory and starts main-owned terminals immediately. import { vi } from 'vitest' -import { getDefaultWorkspaceSession } from '../../../shared/orca-profiles/constants' -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import type { LayoutCommand } from '../../../shared/workspace-layout/workspace-layout-command-types' -import { applyCommandToSession } from '../../persistence/terminal-topology/pane-admission/terminal-pane-admission' -import { resolveHostId } from '../../persistence/loading-store/workspace-sessions/session-host-partitions' -import { withDurableRuntimeStore, withRuntimePaneAdmission } from './runtime-durable-store-fixture' -import { OrcaRuntimeService } from '../orca-runtime' +import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import type { LayoutCommand } from '../../../../shared/workspace-layout/workspace-layout-command-types' +import { applyCommandToSession } from '../../../persistence/terminal-topology/pane-admission/terminal-pane-admission' +import { resolveHostId } from '../../../persistence/loading-store/workspace-sessions/session-host-partitions' +import { + withDurableRuntimeStore, + withRuntimePaneAdmission +} from '../../construction/test-context/runtime-durable-store-fixture' +import { OrcaRuntimeService } from '../../orca-runtime' import { committingSpawn } from './bind-first-pane.test-fixture' -import type { RuntimeNotifier } from '../client/events/runtime-notifier-contract' -import type { PaneResumeOutcome } from '../../../shared/workspace-layout/published-layout/workspace-layout-published' +import type { RuntimeNotifier } from '../../client/events/runtime-notifier-contract' +import type { PaneResumeOutcome } from '../../../../shared/workspace-layout/published-layout/workspace-layout-published' export const REPO = { id: 'repo-1', diff --git a/src/main/runtime/terminal/layout/remote-desktop-headless-park.test.ts b/src/main/runtime/terminal/layout/remote-desktop-headless-park.test.ts index 9919dad02b1..03e97b3d50e 100644 --- a/src/main/runtime/terminal/layout/remote-desktop-headless-park.test.ts +++ b/src/main/runtime/terminal/layout/remote-desktop-headless-park.test.ts @@ -4,7 +4,7 @@ import { OrcaRuntimeService } from '../../orca-runtime' import { publishHeadlessRuntimeGraph } from '../../session-graph/headless-runtime-graph' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' // Headless hosts keep a parked viewer's grid until another viewer or phone takes it (#15997). diff --git a/src/main/runtime/orca-runtime-tests/session-layout-apply.test-fixture.ts b/src/main/runtime/terminal/layout/session-layout-apply.test-fixture.ts similarity index 65% rename from src/main/runtime/orca-runtime-tests/session-layout-apply.test-fixture.ts rename to src/main/runtime/terminal/layout/session-layout-apply.test-fixture.ts index 35af315e20c..8fb3e1aab34 100644 --- a/src/main/runtime/orca-runtime-tests/session-layout-apply.test-fixture.ts +++ b/src/main/runtime/terminal/layout/session-layout-apply.test-fixture.ts @@ -1,8 +1,8 @@ // Apply layout record patches to plain session maps as Store does, including main-owned chat tabs. -import type { WorkspaceSessionState } from '../../../shared/workspace-session/workspace-session-state-types' -import type { LayoutCommand } from '../../../shared/workspace-layout/workspace-layout-command-types' -import { applyCommandToSession } from '../../persistence/terminal-topology/pane-admission/terminal-pane-admission' -import { resolveHostId } from '../../persistence/loading-store/workspace-sessions/session-host-partitions' +import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' +import type { LayoutCommand } from '../../../../shared/workspace-layout/workspace-layout-command-types' +import { applyCommandToSession } from '../../../persistence/terminal-topology/pane-admission/terminal-pane-admission' +import { resolveHostId } from '../../../persistence/loading-store/workspace-sessions/session-host-partitions' export function layoutApplyOn( get: (hostId: string) => WorkspaceSessionState | null, diff --git a/src/main/runtime/terminal/lifecycle/orca-runtime-exited-split-pane-close.test.ts b/src/main/runtime/terminal/lifecycle/orca-runtime-exited-split-pane-close.test.ts index 3d7323ab348..0c95ef0c485 100644 --- a/src/main/runtime/terminal/lifecycle/orca-runtime-exited-split-pane-close.test.ts +++ b/src/main/runtime/terminal/lifecycle/orca-runtime-exited-split-pane-close.test.ts @@ -4,7 +4,7 @@ import '../../../../shared/workspace-layout/terminal-topology/terminal-pane-layo import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' import type { RuntimeMobileSessionTabsSnapshot } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' import { OrcaRuntimeService } from '../../orca-runtime' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' vi.mock('../../../../shared/workspace-layout/layout-owner-switch', () => ({ ORCA_LAYOUT_OWNER_IS_MAIN: true diff --git a/src/main/runtime/terminal/lifecycle/pty-inventory-lifecycle-fixture.ts b/src/main/runtime/terminal/lifecycle/pty-inventory-lifecycle-fixture.ts index 6b3dfa87a10..65b9c602d94 100644 --- a/src/main/runtime/terminal/lifecycle/pty-inventory-lifecycle-fixture.ts +++ b/src/main/runtime/terminal/lifecycle/pty-inventory-lifecycle-fixture.ts @@ -6,7 +6,7 @@ import type { } from './runtime-pty-controller-contract' import type { PtyProcessInfo } from '../../../providers/pty/process-info' import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' -import { registerBoundPty } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../layout/bind-first-pane.test-fixture' export const WORKTREE = 'repo::/tmp/inventory-admission' export const PTY = `${WORKTREE}@@shell` diff --git a/src/main/runtime/terminal/lifecycle/terminal-list-pending-pty-registration.test.ts b/src/main/runtime/terminal/lifecycle/terminal-list-pending-pty-registration.test.ts index 6aef7efa654..95c4628a9d3 100644 --- a/src/main/runtime/terminal/lifecycle/terminal-list-pending-pty-registration.test.ts +++ b/src/main/runtime/terminal/lifecycle/terminal-list-pending-pty-registration.test.ts @@ -12,7 +12,7 @@ import { PTY, WORKTREE } from './pty-inventory-lifecycle-fixture' -import { registerBoundPty } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../layout/bind-first-pane.test-fixture' const TAB = '40000000-0000-4000-8000-000000000001' const LEAF = '40000000-0000-4000-8000-000000000002' diff --git a/src/main/runtime/terminal/output/headless-snapshots.spec.ts b/src/main/runtime/terminal/output/headless-snapshots.spec.ts new file mode 100644 index 00000000000..0ebeb2ecd7f --- /dev/null +++ b/src/main/runtime/terminal/output/headless-snapshots.spec.ts @@ -0,0 +1,75 @@ +import { describe, expect, it, vi } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime' +import '../../orca-runtime-test-mocks/setup.spec' + +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' +import { + declarePendingPaneSerializer, + settlePendingPaneSerializer +} from '../../../ipc/pty/pane/serializer-state' +import { seedHeadlessTerminalFromSpawnResult } from '../../../ipc/pty/pane/terminal-spawn-restore' + +import { + createRuntime, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('keeps pre-TUI shell scrollback when hydrating from a renderer on the alternate screen (#6106)', async () => { + // Renderer serialization emits normal scrollback before alt-screen bytes; zeroing scrollback loses shell history. + const serializeBuffer = vi.fn(async (_ptyId: string, opts?: { scrollbackRows?: number }) => { + const suppressesScrollback = + (opts as Record | undefined)?.altScreenForcesZeroRows === true + const scrollback = suppressesScrollback ? '' : 'PRE_CODEX_START\r\nAGENTS.md\r\n' + return { + data: `${scrollback}\x1b[?1049h\x1b[HCodex TUI frame`, + cols: 80, + rows: 24 + } + }) + const runtime = createRuntime() + runtime.setPtyController({ + write: () => true, + kill: () => true, + getForegroundProcess: async () => null, + serializeBuffer, + hasRendererSerializer: () => true, + getSize: () => ({ cols: 80, rows: 24 }) + }) + await syncSinglePty(runtime, 'pty-1') + + runtime.onPtyData('pty-1', 'live byte', 100) + + const snapshot = await runtime.serializeMainTerminalBuffer('pty-1', { scrollbackRows: 1000 }) + const restored = `${snapshot?.scrollbackAnsi ?? ''}${snapshot?.data ?? ''}` + expect(restored).toContain('PRE_CODEX_START') + expect(restored).toContain('AGENTS.md') + }) + + it('retains cold-restored history in hidden-output recovery while renderer serialization is pending', async () => { + const runtime = createRuntime() + await syncSinglePty(runtime, 'cold-pty') + const paneKey = makePaneKey('tab-1', '44444444-4444-4444-8444-444444444444') + const generation = declarePendingPaneSerializer(paneKey, undefined) + try { + seedHeadlessTerminalFromSpawnResult( + runtime, + { + id: 'cold-pty', + coldRestore: { scrollback: 'restored history\r\n', cwd: '/tmp', cols: 40, rows: 6 } + }, + paneKey + ) + runtime.onPtyData('cold-pty', 'fresh shell prompt $ ', 100) + + const snapshot = await runtime.serializeHiddenOutputRecoveryBuffer('cold-pty', { + scrollbackRows: 100 + }) + expect(snapshot?.data).toContain('restored history') + expect(snapshot?.data).toContain('fresh shell prompt $ ') + } finally { + settlePendingPaneSerializer(paneKey, generation) + } + }) +}) diff --git a/src/main/runtime/terminal/output/stale-title-display-surfaces.test.ts b/src/main/runtime/terminal/output/stale-title-display-surfaces.test.ts index 1fdaadc9bea..0d50c4aa00c 100644 --- a/src/main/runtime/terminal/output/stale-title-display-surfaces.test.ts +++ b/src/main/runtime/terminal/output/stale-title-display-surfaces.test.ts @@ -1,14 +1,14 @@ import { describe, expect, it, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, store, syncSinglePty -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' -import { registerBoundPty } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { registerBoundPty } from '../layout/bind-first-pane.test-fixture' async function psStatus(runtime: OrcaRuntimeService): Promise { return (await runtime.getWorktreePs()).worktrees.find((w) => w.worktreeId === TEST_WORKTREE_ID) diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-11.spec.ts b/src/main/runtime/terminal/output/terminal-creation-and-readiness-part-11.spec.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-11.spec.ts rename to src/main/runtime/terminal/output/terminal-creation-and-readiness-part-11.spec.ts index 540bc7cd315..bde12cc71b5 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-11.spec.ts +++ b/src/main/runtime/terminal/output/terminal-creation-and-readiness-part-11.spec.ts @@ -1,12 +1,15 @@ import { describe, expect, it } from 'vitest' -import './runtime-test-module-registration.spec' -import { HeadlessEmulator } from '../../daemon/emulation/headless-emulator' -import '../../../shared/agent-status/title/osc-title-extraction' -import { OrcaRuntimeService } from '../orca-runtime' -import '../terminal/output/recent-pty-output-buffer' -import '../terminal/output/tail/terminal-tail-buffer' -import '../terminal/output/tail/terminal-tail-state' -import { store, syncSinglePty } from './orca-runtime-test-fixtures.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { HeadlessEmulator } from '../../../daemon/emulation/headless-emulator' +import '../../../../shared/agent-status/title/osc-title-extraction' +import { OrcaRuntimeService } from '../../orca-runtime' +import './recent-pty-output-buffer' +import './tail/terminal-tail-buffer' +import './tail/terminal-tail-state' +import { + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('keeps cursor pagination stable across a CUU redraw of the live screen', async () => { diff --git a/src/main/runtime/terminal/output/terminal-restore-record-seed.test.ts b/src/main/runtime/terminal/output/terminal-restore-record-seed.test.ts index e923605d4bb..2c207fdfe58 100644 --- a/src/main/runtime/terminal/output/terminal-restore-record-seed.test.ts +++ b/src/main/runtime/terminal/output/terminal-restore-record-seed.test.ts @@ -4,7 +4,7 @@ import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/con import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' import '../../../../shared/workspace-layout/stable-pane-id' import '../../../../shared/workspace-layout/layout-owner-switch' -import '../../orca-runtime-tests/bind-first-pane.test-fixture' +import '../layout/bind-first-pane.test-fixture' // Reattach restore arrives as RPC data, not onPtyData; seed preview/tail/title without inventing recency or side-effect facts. diff --git a/src/main/runtime/terminal/output/terminal-side-effect-facts-part-02.spec.ts b/src/main/runtime/terminal/output/terminal-side-effect-facts-part-02.spec.ts new file mode 100644 index 00000000000..536436c6e6d --- /dev/null +++ b/src/main/runtime/terminal/output/terminal-side-effect-facts-part-02.spec.ts @@ -0,0 +1,83 @@ +import { describe, expect, it, vi } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import './provider-snapshot-budget' +import '../../orca-runtime' + +import { syncSinglePty } from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createSideEffectRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' + +describe('terminal side-effect fact channel', () => { + it('keeps mode transitions that race a provider snapshot response', async () => { + const { runtime } = createSideEffectRuntime() + let resolveProviderSnapshot: + | ((snapshot: { + data: string + cols: number + rows: number + seq: number + source: 'headless' + alternateScreen: boolean + }) => void) + | undefined + const serializeProviderBuffer = vi.fn( + () => + new Promise<{ + data: string + cols: number + rows: number + seq: number + source: 'headless' + alternateScreen: boolean + }>((resolve) => { + resolveProviderSnapshot = resolve + }) + ) + runtime.setPtyController({ + write: () => true, + kill: () => true, + getForegroundProcess: async () => null, + serializeProviderBuffer, + hasRendererSerializer: () => false + }) + runtime.synchronizePtyOutputSequenceFromProvider( + 'pty-tui-race', + { value: 900, generation: 'continued' }, + 0 + ) + + const snapshotPromise = runtime.serializeTerminalBuffer('pty-tui-race') + await vi.waitFor(() => expect(resolveProviderSnapshot).toBeDefined()) + runtime.onPtyData('pty-tui-race', '\x1b[?1049l', 100) + resolveProviderSnapshot?.({ + data: 'captured alt screen', + cols: 80, + rows: 24, + seq: 900, + source: 'headless', + alternateScreen: true + }) + await snapshotPromise + + expect(runtime.isTerminalAlternateScreen('pty-tui-race')).toBe(false) + }) + + it('parses synthetic frames statelessly so ticks cannot corrupt the bell detector', async () => { + const { runtime, batches } = createSideEffectRuntime() + await syncSinglePty(runtime) + + runtime.onPtyData('pty-1', '\x1b]0;split ti', 100) + // An 80ms spinner tick lands between the two halves of the real OSC. + runtime.ingestSyntheticTitleFrame('pty-1', '\x1b]0;⠋ Cursor Agent\x07') + // This BEL terminates the real partial OSC; it is not a bell. + runtime.onPtyData('pty-1', 'tle\x07', 101) + // A later standalone BEL must still produce a bell fact. + runtime.onPtyData('pty-1', 'ready\x07', 102) + + expect(batches.flatMap((batch) => batch.facts)).toEqual([ + { kind: 'title', normalizedTitle: '⠋ Cursor Agent', rawTitle: '⠋ Cursor Agent' }, + { kind: 'agent-working' }, + { kind: 'title', normalizedTitle: 'split title', rawTitle: 'split title' }, + { kind: 'bell' } + ]) + }) +}) diff --git a/src/main/runtime/terminal/output/trust-dialog-status-observer.test.ts b/src/main/runtime/terminal/output/trust-dialog-status-observer.test.ts index a087cb58889..30438cb8fd5 100644 --- a/src/main/runtime/terminal/output/trust-dialog-status-observer.test.ts +++ b/src/main/runtime/terminal/output/trust-dialog-status-observer.test.ts @@ -9,7 +9,7 @@ import { TERMINAL_METHODS } from '../../rpc/methods/terminal/terminal' import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +} from '../wait/agent-transcript-pane-test-harness' function fixture(name: string): { recording: string; cols: number; rows: number } { const url = (ext: string) => new URL(`../../__fixtures__/${name}.${ext}`, import.meta.url) diff --git a/src/main/runtime/orca-runtime-tests/agent-status-and-waits-part-02.spec.ts b/src/main/runtime/terminal/query/agent-status-and-waits-part-02.spec.ts similarity index 81% rename from src/main/runtime/orca-runtime-tests/agent-status-and-waits-part-02.spec.ts rename to src/main/runtime/terminal/query/agent-status-and-waits-part-02.spec.ts index 79cc2611a8d..f1a8e1a43b5 100644 --- a/src/main/runtime/orca-runtime-tests/agent-status-and-waits-part-02.spec.ts +++ b/src/main/runtime/terminal/query/agent-status-and-waits-part-02.spec.ts @@ -1,10 +1,13 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import '../orca-runtime' -import '../../providers/pty/process-inspection' -import '../../../shared/workspace-layout/stable-pane-id' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime' +import '../../../providers/pty/process-inspection' +import '../../../../shared/workspace-layout/stable-pane-id' -import { createExplicitAgentStatusHarness, deferred } from './orca-runtime-test-fixtures.spec' +import { + createExplicitAgentStatusHarness, + deferred +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('rejects foreground evidence when the handle rebinds during the ordinary read', async () => { diff --git a/src/main/runtime/orca-runtime-tests/conpty-stream-read.spec.ts b/src/main/runtime/terminal/query/conpty-stream-read.spec.ts similarity index 81% rename from src/main/runtime/orca-runtime-tests/conpty-stream-read.spec.ts rename to src/main/runtime/terminal/query/conpty-stream-read.spec.ts index 0d40798ae32..bb3055b0a17 100644 --- a/src/main/runtime/orca-runtime-tests/conpty-stream-read.spec.ts +++ b/src/main/runtime/terminal/query/conpty-stream-read.spec.ts @@ -1,17 +1,20 @@ import { readFileSync } from 'node:fs' import { describe, expect, it } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { join } from 'node:path' -import { store, syncSinglePty } from './orca-runtime-test-fixtures.spec' +import { + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { clearNativeWindowsConptyPty, markNativeWindowsConptyPty -} from '../terminal/output/terminal-model-query-authority' +} from '../output/terminal-model-query-authority' // Captured pwsh 7.6/ConPTY: grey PSReadLine predictions from history are overwritten by absolute cursor moves. const PSREADLINE_PREDICTION_TRANSCRIPT = readFileSync( - join(__dirname, '..', '__fixtures__', 'pwsh-7-6-psreadline-history-prediction-conpty.txt'), + join(__dirname, '..', '..', '__fixtures__', 'pwsh-7-6-psreadline-history-prediction-conpty.txt'), 'utf8' ) const PROMPT = 'PS C:\\Users\\user\\orca\\workspaces\\orca\\run-ownership-validation>' diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-09.spec.ts b/src/main/runtime/terminal/query/terminal-creation-and-readiness-part-09.spec.ts similarity index 94% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-09.spec.ts rename to src/main/runtime/terminal/query/terminal-creation-and-readiness-part-09.spec.ts index fdfdb9283d3..7303fa845ef 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-09.spec.ts +++ b/src/main/runtime/terminal/query/terminal-creation-and-readiness-part-09.spec.ts @@ -1,9 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' -import '../../../shared/terminal/protocol/input-modes/terminal-kitty-keyboard-mode-tracker' -import { store, syncSinglePty } from './orca-runtime-test-fixtures.spec' +import '../../../../shared/terminal/protocol/input-modes/terminal-kitty-keyboard-mode-tracker' +import { + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('clears terminal scrollback through the PTY controller and headless buffer', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-10.spec.ts b/src/main/runtime/terminal/query/terminal-creation-and-readiness-part-10.spec.ts similarity index 71% rename from src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-10.spec.ts rename to src/main/runtime/terminal/query/terminal-creation-and-readiness-part-10.spec.ts index af935750d8a..e81040fc7c7 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-creation-and-readiness-part-10.spec.ts +++ b/src/main/runtime/terminal/query/terminal-creation-and-readiness-part-10.spec.ts @@ -1,11 +1,14 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import type { PtyProviderBufferSnapshot } from '../../providers/pty/provider-contract' -import '../orca-runtime-test-mocks/setup.spec' -import '../rpc/dispatcher' -import '../rpc/methods/terminal/terminal' -import { store, syncSinglePty } from './orca-runtime-test-fixtures.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import type { PtyProviderBufferSnapshot } from '../../../providers/pty/provider-contract' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../rpc/dispatcher' +import '../../rpc/methods/terminal/terminal' +import { + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' async function createProviderSnapshotRuntime( serializeProviderBuffer: () => Promise @@ -57,68 +60,6 @@ describe('OrcaRuntimeService', () => { expect(read.tail.join('\n')).not.toContain('Stale Ready screen') }) - it('bounds a stuck provider snapshot and shares the timed-out request', async () => { - vi.useFakeTimers() - try { - const serializeProviderBuffer = vi.fn(() => new Promise(() => undefined)) - const { runtime, handle } = await createProviderSnapshotRuntime(serializeProviderBuffer) - - const reads = Promise.all([runtime.readTerminal(handle), runtime.showTerminal(handle)]) - await vi.advanceTimersByTimeAsync(750) - const [read, shown] = await reads - - expect(read.tail).toEqual(['shell history']) - expect(shown.preview).toBe('shell history') - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - - await vi.advanceTimersByTimeAsync(1_001) - let laterReadSettled = false - const laterRead = runtime.readTerminal(handle).finally(() => { - laterReadSettled = true - }) - await vi.advanceTimersByTimeAsync(100) - expect(laterReadSettled).toBe(true) - await expect(laterRead).resolves.toMatchObject({ tail: ['shell history'] }) - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - } finally { - vi.useRealTimers() - } - }) - - it('keeps a provider frame that lands after its visible read timed out', async () => { - vi.useFakeTimers() - try { - let resolveSnapshot!: (snapshot: PtyProviderBufferSnapshot) => void - const serializeProviderBuffer = vi.fn( - () => - new Promise((resolve) => { - resolveSnapshot = resolve - }) - ) - const { runtime, handle } = await createProviderSnapshotRuntime(serializeProviderBuffer) - - const firstRead = runtime.readTerminal(handle) - await vi.advanceTimersByTimeAsync(750) - await expect(firstRead).resolves.toMatchObject({ tail: ['shell history'] }) - resolveSnapshot({ - data: '\x1b[?1049h\x1b[2J\x1b[HSlow Ready screen\r\n', - cols: 80, - rows: 24, - seq: runtime.getPtyOutputSequence('pty-1'), - source: 'headless', - alternateScreen: true - }) - await vi.advanceTimersByTimeAsync(50) - - await expect(runtime.readTerminal(handle)).resolves.toMatchObject({ - tail: ['Slow Ready screen'] - }) - expect(serializeProviderBuffer).toHaveBeenCalledOnce() - } finally { - vi.useRealTimers() - } - }) - it('discards a provider frame when the PTY generation resets during capture', async () => { type Snapshot = { data: string diff --git a/src/main/runtime/terminal/query/terminal-identity.test-fixture.ts b/src/main/runtime/terminal/query/terminal-identity.test-fixture.ts index 886ef1d5a56..a6e825e1c4e 100644 --- a/src/main/runtime/terminal/query/terminal-identity.test-fixture.ts +++ b/src/main/runtime/terminal/query/terminal-identity.test-fixture.ts @@ -1,6 +1,9 @@ -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { vi, type Mock, type MockInstance } from 'vitest' -import { store, TEST_WORKTREE_ID } from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +import { + store, + TEST_WORKTREE_ID +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import type { RuntimeSyncWindowGraph } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' import type { TerminalIdentitySource } from '../identity/terminal-identity-source' diff --git a/src/main/runtime/terminal/query/terminal-listing-fresh-liveness.spec.ts b/src/main/runtime/terminal/query/terminal-listing-fresh-liveness.spec.ts new file mode 100644 index 00000000000..f0c81a1fe9c --- /dev/null +++ b/src/main/runtime/terminal/query/terminal-listing-fresh-liveness.spec.ts @@ -0,0 +1,25 @@ +import { describe, expect, it } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { store } from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../hosts/platform-probe/runtime-machine-name' + +describe('OrcaRuntimeService', () => { + it('fails terminal listing closed when fresh PTY liveness is required and unavailable', async () => { + const runtime = new OrcaRuntimeService(store) + runtime.setPtyController({ + write: () => true, + kill: () => true, + getForegroundProcess: async () => null, + listProcesses: async () => { + throw new Error('provider unavailable') + } + }) + + await expect( + runtime.listTerminals('id:repo-1::/tmp/worktree-a', undefined, { + requireFreshPtyLiveness: true + }) + ).rejects.toThrow('terminal_liveness_unavailable') + }) +}) diff --git a/src/main/runtime/terminal/recovery/restored-pane-hook-store-resume.test.ts b/src/main/runtime/terminal/recovery/restored-pane-hook-store-resume.test.ts index 4e05260e179..104367fd358 100644 --- a/src/main/runtime/terminal/recovery/restored-pane-hook-store-resume.test.ts +++ b/src/main/runtime/terminal/recovery/restored-pane-hook-store-resume.test.ts @@ -2,19 +2,19 @@ import { describe, expect, it, vi } from 'vitest' import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' // Preserve side-effect order: mocks, lifecycle, fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') -const { committingSpawn } = await import('../../orca-runtime-tests/bind-first-pane.test-fixture') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') +const { committingSpawn } = await import('../layout/bind-first-pane.test-fixture') const PANE_KEY = `host-tab:${HEADLESS_LEAF_ID}` const SESSION_ID = '0bc9e9f8-192c-4bd4-beb8-8b745c59c8b0' diff --git a/src/main/runtime/terminal/recovery/restored-pane-start-layout-owner.test.ts b/src/main/runtime/terminal/recovery/restored-pane-start-layout-owner.test.ts index 9c9cce9abd6..7296c185d3f 100644 --- a/src/main/runtime/terminal/recovery/restored-pane-start-layout-owner.test.ts +++ b/src/main/runtime/terminal/recovery/restored-pane-start-layout-owner.test.ts @@ -6,17 +6,17 @@ vi.mock('../../../../shared/workspace-layout/layout-owner-switch', () => ({ })) // Fragments stay side-effect ordered: mocks, then lifecycle, then fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { HEADLESS_LEAF_ID, TEST_WORKTREE_ID, deferred, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') -const { committingSpawn } = await import('../../orca-runtime-tests/bind-first-pane.test-fixture') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') +const { committingSpawn } = await import('../layout/bind-first-pane.test-fixture') async function windowlessRuntime() { const { runtimeStore, getSession, setSession } = makeRuntimeStoreWithWorkspaceSession( diff --git a/src/main/runtime/terminal/recovery/terminal-pane-recovery-liveness-gate.test.ts b/src/main/runtime/terminal/recovery/terminal-pane-recovery-liveness-gate.test.ts index 593d052d1b8..50dec167e02 100644 --- a/src/main/runtime/terminal/recovery/terminal-pane-recovery-liveness-gate.test.ts +++ b/src/main/runtime/terminal/recovery/terminal-pane-recovery-liveness-gate.test.ts @@ -5,11 +5,11 @@ import { createRuntimeWithSshLease, deferred, store -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' import { OrcaRuntimeService } from '../../orca-runtime' -import { registerBoundPty } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../layout/bind-first-pane.test-fixture' import type { RuntimeTerminalCreate } from '../../../../shared/terminal/runtime/runtime-terminal-create-contract' import type { RuntimeTerminalResolvePane } from '../../../../shared/terminal/runtime/runtime-terminal-contracts' diff --git a/src/main/runtime/terminal/stop/project-removal-terminal-stop.test.ts b/src/main/runtime/terminal/stop/project-removal-terminal-stop.test.ts index 20e1b935b6e..ef37339611c 100644 --- a/src/main/runtime/terminal/stop/project-removal-terminal-stop.test.ts +++ b/src/main/runtime/terminal/stop/project-removal-terminal-stop.test.ts @@ -5,14 +5,14 @@ import { spawnWorktreeTarget } from '../../../../shared/worktree/host-qualified- import type { Repo } from '../../../../shared/repository/repo-types' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { TEST_REPO_ID, TEST_WORKTREE_ID, store -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('project removal on the execution host', () => { it('refuses a spawn that reaches its lease after the project is gone', async () => { diff --git a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-02.spec.ts b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-02.spec.ts similarity index 58% rename from src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-02.spec.ts rename to src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-02.spec.ts index e2d75f216b4..7ac8d036695 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-02.spec.ts +++ b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-02.spec.ts @@ -1,12 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import { spawnWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import type { AgentStatusIpcPayload } from '../../../shared/agent-status/contracts/agent-status-ipc-payload' -import type { RuntimeClientEvent } from '../../../shared/remote-runtime/session-graph/runtime-client-events' -import '../session-lifecycle/close/mobile-session-tab-close-outcome' +import { spawnWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { MOCK_GIT_WORKTREES } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' +import type { RuntimeClientEvent } from '../../../../shared/remote-runtime/session-graph/runtime-client-events' +import '../../session-lifecycle/close/mobile-session-tab-close-outcome' import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, @@ -18,7 +18,7 @@ import { makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('does not stop a provider-owned foreign PTY referenced by stale target state', async () => { @@ -369,64 +369,6 @@ describe('OrcaRuntimeService', () => { ).toEqual(['started', 'committed', 'woken']) }) - it('waits for an in-flight spawn before inventorying worktree sleep', async () => { - const runtime = new OrcaRuntimeService(store) - const listProcesses = vi.fn().mockResolvedValue([]) - runtime.setPtyController({ - write: () => true, - kill: () => false, - stopAndWait: vi.fn(async () => true), - getForegroundProcess: async () => null, - listProcesses - }) - const releaseSpawn = await runtime.acquireWorktreeTerminalSpawn( - spawnWorktreeTarget(TEST_WORKTREE_ID, null) - ) - - const sleep = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - await Promise.resolve() - expect(listProcesses).not.toHaveBeenCalled() - releaseSpawn() - - await expect(sleep).resolves.toMatchObject({ stopped: 0, postStopVerified: true }) - expect(listProcesses).toHaveBeenCalledTimes(1) - }) - - it('expires while queued behind a spawn and never stops it later', async () => { - vi.useFakeTimers() - try { - const runtime = new OrcaRuntimeService(store) - const listProcesses = vi.fn().mockResolvedValue([]) - const stopAndWait = vi.fn(async () => true) - runtime.setPtyController({ - write: () => true, - kill: () => false, - stopAndWait, - getForegroundProcess: async () => null, - listProcesses - }) - const releaseSpawn = await runtime.acquireWorktreeTerminalSpawn( - spawnWorktreeTarget(TEST_WORKTREE_ID, null) - ) - - const sleep = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - const rejection = expect(sleep).rejects.toThrow('terminal_worktree_sleep_timeout') - await vi.advanceTimersByTimeAsync(12_001) - await rejection - releaseSpawn() - await Promise.resolve() - - expect(listProcesses).not.toHaveBeenCalled() - expect(stopAndWait).not.toHaveBeenCalled() - const releaseNextSpawn = await runtime.acquireWorktreeTerminalSpawn( - spawnWorktreeTarget(TEST_WORKTREE_ID, null) - ) - releaseNextSpawn() - } finally { - vi.useRealTimers() - } - }) - it('releases the worktree terminal mutation when a wake client-event listener throws', async () => { const runtime = new OrcaRuntimeService(store) const secondListenerEvents: RuntimeClientEvent[] = [] @@ -470,205 +412,4 @@ describe('OrcaRuntimeService', () => { runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) ).resolves.toMatchObject({ postStopVerified: true }) }) - - it('isolates a throwing subscriber across runtime listener fan-out', () => { - const runtime = new OrcaRuntimeService(store) - const delivered: number[] = [] - // Sibling notification fan-outs must also isolate throwing subscribers. - runtime.onNotificationDispatched(() => { - throw new Error('subscriber_send_failed') - }) - runtime.onNotificationDispatched((event) => { - delivered.push(event.notificationSeq ?? -1) - }) - - expect(() => - runtime.dispatchMobileNotification({ - type: 'notification', - source: 'test', - title: 'Test', - body: 'Body', - worktreeId: TEST_WORKTREE_ID - }) - ).not.toThrow() - - expect(delivered).toHaveLength(1) - }) - - it('keeps the original committed disposition across an idempotent retry', async () => { - const runtime = new OrcaRuntimeService(store) - const events: RuntimeClientEvent[] = [] - runtime.onClientEvent((event) => events.push(event)) - const processLists = [ - [ - { - id: 'pty-preserved-history', - cwd: TEST_WORKTREE_PATH, - worktreeId: TEST_WORKTREE_ID, - title: 'Shell' - } - ], - [], - [] - ] - runtime.setPtyController({ - write: () => true, - kill: () => false, - stopAndWait: async (ptyId) => { - runtime.onPtyExit(ptyId, -1) - return true - }, - getForegroundProcess: async () => null, - listProcesses: async () => processLists.shift() ?? [] - }) - - await runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - expect(runtime.getTerminalSleepClientEventSnapshot()).toEqual([ - expect.objectContaining({ phase: 'committed', ptyIds: ['pty-preserved-history'] }) - ]) - await runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - const releaseSpawn = await runtime.acquireWorktreeTerminalSpawn( - spawnWorktreeTarget(TEST_WORKTREE_ID, null) - ) - releaseSpawn() - - const sleepEvents = events.filter((event) => event.type === 'worktreeTerminalSleepState') - expect(sleepEvents.map((event) => event.phase)).toEqual(['started', 'committed', 'woken']) - expect(sleepEvents.at(-1)?.ptyIds).toEqual(['pty-preserved-history']) - }) - - it('keeps concurrent sleep coalesced until every launched stop settles', async () => { - const runtime = new OrcaRuntimeService(store) - const clientEvents: RuntimeClientEvent[][] = [[], []] - for (const events of clientEvents) { - runtime.onClientEvent((event) => events.push(event)) - } - const secondStop = deferred() - const failedPty = { - id: 'pty-fails', - cwd: TEST_WORKTREE_PATH, - worktreeId: TEST_WORKTREE_ID, - title: 'Claude' - } - const listProcesses = vi - .fn() - .mockResolvedValueOnce([ - failedPty, - { id: 'pty-slow', cwd: TEST_WORKTREE_PATH, worktreeId: TEST_WORKTREE_ID, title: 'Shell' } - ]) - .mockResolvedValueOnce([failedPty]) - .mockResolvedValueOnce([failedPty]) - .mockResolvedValueOnce([]) - let failedAttempts = 0 - const stopAndWait = vi.fn(async (ptyId: string) => { - if (ptyId === 'pty-fails') { - failedAttempts += 1 - if (failedAttempts === 1) { - throw new Error('stop failed') - } - runtime.onPtyExit(ptyId, -1) - return true - } - const stopped = await secondStop.promise - runtime.onPtyExit(ptyId, -1) - return stopped - }) - runtime.setPtyController({ - write: () => true, - kill: () => false, - stopAndWait, - getForegroundProcess: async () => null, - listProcesses - }) - - const first = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - await vi.waitFor(() => expect(stopAndWait).toHaveBeenCalledTimes(2)) - const concurrent = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - secondStop.resolve(true) - - await expect(first).rejects.toThrow('terminal_worktree_sleep_failed') - await expect(concurrent).rejects.toThrow('terminal_worktree_sleep_failed') - expect(runtime.getTerminalSleepClientEventSnapshot()).toEqual([ - expect.objectContaining({ phase: 'committed', ptyIds: ['pty-slow'] }) - ]) - await expect( - runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) - ).resolves.toMatchObject({ postStopVerified: true, stoppedPtyIds: ['pty-fails'] }) - expect(stopAndWait).toHaveBeenCalledTimes(3) - for (const events of clientEvents) { - const sleepEvents = events.filter( - (event): event is Extract => - event.type === 'worktreeTerminalSleepState' - ) - expect( - [ - ...new Set( - sleepEvents - .filter((event) => event.phase === 'committed') - .flatMap((event) => event.ptyIds) - ) - ].sort() - ).toEqual(['pty-fails', 'pty-slow']) - expect( - sleepEvents.filter((event) => event.phase === 'cancelled').flatMap((event) => event.ptyIds) - ).toEqual(['pty-fails']) - } - }) - - it('reports recoverable post-stop liveness failure after exact terminal stop', async () => { - const runtime = new OrcaRuntimeService(store) - const stopped: string[] = [] - const processLists = [[{ id: 'pty-1', cwd: '/tmp/worktree-a', title: 'Claude' }]] - runtime.setPtyController({ - write: () => true, - kill: () => false, - stopAndWait: async (ptyId) => { - stopped.push(ptyId) - runtime.onPtyExit(ptyId, -1) - return true - }, - getForegroundProcess: async () => null, - // Why: the daemon stays unavailable through every bounded post-stop retry. - listProcesses: async () => { - const next = processLists.shift() - if (!next) { - throw new Error('daemon unavailable') - } - return next - } - }) - - runtime.attachWindow(1) - await runtime.syncWindowGraph(1, { - tabs: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - title: 'Claude', - activeLeafId: 'pane:1', - layout: null - } - ], - leaves: [ - { - tabId: 'tab-1', - worktreeId: 'repo-1::/tmp/worktree-a', - leafId: 'pane:1', - paneRuntimeId: 1, - ptyId: 'pty-1' - } - ] - }) - - await expect( - runtime.stopExactTerminalsForWorktree('id:repo-1::/tmp/worktree-a', ['pty-1']) - ).resolves.toEqual({ - stopped: 1, - stoppedPtyIds: ['pty-1'], - livePtyIds: ['pty-1'], - postStopVerified: false, - postStopFailure: 'terminal_liveness_unavailable' - }) - expect(stopped).toEqual(['pty-1']) - }) }) diff --git a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-03.spec.ts b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-03.spec.ts similarity index 90% rename from src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-03.spec.ts rename to src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-03.spec.ts index 8881a0adedf..2446e43296e 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown-part-03.spec.ts +++ b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown-part-03.spec.ts @@ -1,8 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { TEST_WORKTREE_ID, TEST_WORKTREE_PATH, store } from './orca-runtime-test-fixtures.spec' -import '../hosts/platform-probe/runtime-machine-name' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { + TEST_WORKTREE_ID, + TEST_WORKTREE_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../hosts/platform-probe/runtime-machine-name' describe('OrcaRuntimeService', () => { it('stops nothing for a sole-terminal sleep while another terminal in the worktree is live', async () => { @@ -261,22 +265,4 @@ describe('OrcaRuntimeService', () => { }) expect(stopped).toEqual(['pty-1']) }) - - it('fails terminal listing closed when fresh PTY liveness is required and unavailable', async () => { - const runtime = new OrcaRuntimeService(store) - runtime.setPtyController({ - write: () => true, - kill: () => true, - getForegroundProcess: async () => null, - listProcesses: async () => { - throw new Error('provider unavailable') - } - }) - - await expect( - runtime.listTerminals('id:repo-1::/tmp/worktree-a', undefined, { - requireFreshPtyLiveness: true - }) - ).rejects.toThrow('terminal_liveness_unavailable') - }) }) diff --git a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown.spec.ts b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown.spec.ts similarity index 64% rename from src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown.spec.ts rename to src/main/runtime/terminal/stop/terminal-sleep-and-teardown.spec.ts index 72244d5d935..718457ea276 100644 --- a/src/main/runtime/orca-runtime-tests/terminal-sleep-and-teardown.spec.ts +++ b/src/main/runtime/terminal/stop/terminal-sleep-and-teardown.spec.ts @@ -1,52 +1,13 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../workspaces/removal/worktree-teardown' -import '../workspaces/removal/worktree-teardown-deadline' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { - TEST_WORKTREE_ID, - makeDeferred, - store, - syncSinglePty -} from './orca-runtime-test-fixtures.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { MOCK_GIT_WORKTREES } from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../workspaces/removal/worktree-teardown' +import '../../workspaces/removal/worktree-teardown-deadline' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import { store } from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { - it('awaits physical PTY stop when destructive teardown supplies shared dedupe', async () => { - const runtime = new OrcaRuntimeService(store) - const physicalStop = makeDeferred() - const kill = vi.fn(() => true) - const stopAndWait = vi.fn(async () => { - await physicalStop.promise - return true - }) - runtime.setPtyController({ - write: () => true, - kill, - stopAndWait, - getForegroundProcess: async () => null - }) - await syncSinglePty(runtime) - const stopPty = vi.fn(async (_ptyId: string, stop: () => Promise) => ({ - stopped: await stop(), - owner: true - })) - - const stopping = runtime.stopTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`, { stopPty }) - await vi.waitFor(() => expect(stopAndWait).toHaveBeenCalledWith('pty-1')) - expect(kill).not.toHaveBeenCalled() - let settled = false - void stopping.then(() => { - settled = true - }) - await Promise.resolve() - expect(settled).toBe(false) - - physicalStop.resolve() - await expect(stopping).resolves.toEqual({ stopped: 1 }) - }) - it('fails terminal stop closed if the graph reloads during selector resolution', async () => { const runtime = new OrcaRuntimeService(store) let killed = false diff --git a/src/main/runtime/terminal/stop/terminal-sleep-idempotency-and-convergence.spec.ts b/src/main/runtime/terminal/stop/terminal-sleep-idempotency-and-convergence.spec.ts new file mode 100644 index 00000000000..e18f76b703a --- /dev/null +++ b/src/main/runtime/terminal/stop/terminal-sleep-idempotency-and-convergence.spec.ts @@ -0,0 +1,194 @@ +import { describe, expect, it, vi } from 'vitest' +import { spawnWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../git/worktrees/catalog/worktree-scan-cache' + +import type { RuntimeClientEvent } from '../../../../shared/remote-runtime/session-graph/runtime-client-events' +import '../../session-lifecycle/close/mobile-session-tab-close-outcome' +import { + TEST_WORKTREE_ID, + TEST_WORKTREE_PATH, + deferred, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('keeps the original committed disposition across an idempotent retry', async () => { + const runtime = new OrcaRuntimeService(store) + const events: RuntimeClientEvent[] = [] + runtime.onClientEvent((event) => events.push(event)) + const processLists = [ + [ + { + id: 'pty-preserved-history', + cwd: TEST_WORKTREE_PATH, + worktreeId: TEST_WORKTREE_ID, + title: 'Shell' + } + ], + [], + [] + ] + runtime.setPtyController({ + write: () => true, + kill: () => false, + stopAndWait: async (ptyId) => { + runtime.onPtyExit(ptyId, -1) + return true + }, + getForegroundProcess: async () => null, + listProcesses: async () => processLists.shift() ?? [] + }) + + await runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) + expect(runtime.getTerminalSleepClientEventSnapshot()).toEqual([ + expect.objectContaining({ phase: 'committed', ptyIds: ['pty-preserved-history'] }) + ]) + await runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) + const releaseSpawn = await runtime.acquireWorktreeTerminalSpawn( + spawnWorktreeTarget(TEST_WORKTREE_ID, null) + ) + releaseSpawn() + + const sleepEvents = events.filter((event) => event.type === 'worktreeTerminalSleepState') + expect(sleepEvents.map((event) => event.phase)).toEqual(['started', 'committed', 'woken']) + expect(sleepEvents.at(-1)?.ptyIds).toEqual(['pty-preserved-history']) + }) + + it('keeps concurrent sleep coalesced until every launched stop settles', async () => { + const runtime = new OrcaRuntimeService(store) + const clientEvents: RuntimeClientEvent[][] = [[], []] + for (const events of clientEvents) { + runtime.onClientEvent((event) => events.push(event)) + } + const secondStop = deferred() + const failedPty = { + id: 'pty-fails', + cwd: TEST_WORKTREE_PATH, + worktreeId: TEST_WORKTREE_ID, + title: 'Claude' + } + const listProcesses = vi + .fn() + .mockResolvedValueOnce([ + failedPty, + { id: 'pty-slow', cwd: TEST_WORKTREE_PATH, worktreeId: TEST_WORKTREE_ID, title: 'Shell' } + ]) + .mockResolvedValueOnce([failedPty]) + .mockResolvedValueOnce([failedPty]) + .mockResolvedValueOnce([]) + let failedAttempts = 0 + const stopAndWait = vi.fn(async (ptyId: string) => { + if (ptyId === 'pty-fails') { + failedAttempts += 1 + if (failedAttempts === 1) { + throw new Error('stop failed') + } + runtime.onPtyExit(ptyId, -1) + return true + } + const stopped = await secondStop.promise + runtime.onPtyExit(ptyId, -1) + return stopped + }) + runtime.setPtyController({ + write: () => true, + kill: () => false, + stopAndWait, + getForegroundProcess: async () => null, + listProcesses + }) + + const first = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) + await vi.waitFor(() => expect(stopAndWait).toHaveBeenCalledTimes(2)) + const concurrent = runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) + secondStop.resolve(true) + + await expect(first).rejects.toThrow('terminal_worktree_sleep_failed') + await expect(concurrent).rejects.toThrow('terminal_worktree_sleep_failed') + expect(runtime.getTerminalSleepClientEventSnapshot()).toEqual([ + expect.objectContaining({ phase: 'committed', ptyIds: ['pty-slow'] }) + ]) + await expect( + runtime.sleepTerminalsForWorktree(`id:${TEST_WORKTREE_ID}`) + ).resolves.toMatchObject({ postStopVerified: true, stoppedPtyIds: ['pty-fails'] }) + expect(stopAndWait).toHaveBeenCalledTimes(3) + for (const events of clientEvents) { + const sleepEvents = events.filter( + (event): event is Extract => + event.type === 'worktreeTerminalSleepState' + ) + expect( + [ + ...new Set( + sleepEvents + .filter((event) => event.phase === 'committed') + .flatMap((event) => event.ptyIds) + ) + ].sort() + ).toEqual(['pty-fails', 'pty-slow']) + expect( + sleepEvents.filter((event) => event.phase === 'cancelled').flatMap((event) => event.ptyIds) + ).toEqual(['pty-fails']) + } + }) + + it('reports recoverable post-stop liveness failure after exact terminal stop', async () => { + const runtime = new OrcaRuntimeService(store) + const stopped: string[] = [] + const processLists = [[{ id: 'pty-1', cwd: '/tmp/worktree-a', title: 'Claude' }]] + runtime.setPtyController({ + write: () => true, + kill: () => false, + stopAndWait: async (ptyId) => { + stopped.push(ptyId) + runtime.onPtyExit(ptyId, -1) + return true + }, + getForegroundProcess: async () => null, + // Why: the daemon stays unavailable through every bounded post-stop retry. + listProcesses: async () => { + const next = processLists.shift() + if (!next) { + throw new Error('daemon unavailable') + } + return next + } + }) + + runtime.attachWindow(1) + await runtime.syncWindowGraph(1, { + tabs: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + title: 'Claude', + activeLeafId: 'pane:1', + layout: null + } + ], + leaves: [ + { + tabId: 'tab-1', + worktreeId: 'repo-1::/tmp/worktree-a', + leafId: 'pane:1', + paneRuntimeId: 1, + ptyId: 'pty-1' + } + ] + }) + + await expect( + runtime.stopExactTerminalsForWorktree('id:repo-1::/tmp/worktree-a', ['pty-1']) + ).resolves.toEqual({ + stopped: 1, + stoppedPtyIds: ['pty-1'], + livePtyIds: ['pty-1'], + postStopVerified: false, + postStopFailure: 'terminal_liveness_unavailable' + }) + expect(stopped).toEqual(['pty-1']) + }) +}) diff --git a/src/main/runtime/terminal/surface/headless-create-terminal-handle-main.test.ts b/src/main/runtime/terminal/surface/headless-create-terminal-handle-main.test.ts index f43f50aac15..17a0adc0f7e 100644 --- a/src/main/runtime/terminal/surface/headless-create-terminal-handle-main.test.ts +++ b/src/main/runtime/terminal/surface/headless-create-terminal-handle-main.test.ts @@ -7,10 +7,10 @@ vi.mock('../../../../shared/workspace-layout/layout-owner-switch', () => ({ })) // Preserve side-effect order: mocks, lifecycle, fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { TEST_WORKTREE_ID, TEST_WORKTREE_PATH } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const { surfaceRuntime } = await import('./terminal-surface-replies.test-fixture') type Runtime = ReturnType['runtime'] diff --git a/src/main/runtime/terminal/surface/orca-runtime-terminal-close-spill-partition.spec.ts b/src/main/runtime/terminal/surface/orca-runtime-terminal-close-spill-partition.spec.ts index e273d424a77..3497fdfdd8e 100644 --- a/src/main/runtime/terminal/surface/orca-runtime-terminal-close-spill-partition.spec.ts +++ b/src/main/runtime/terminal/surface/orca-runtime-terminal-close-spill-partition.spec.ts @@ -1,4 +1,4 @@ -import '../../orca-runtime-tests/runtime-durable-store-fixture' +import '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import '../../../../shared/execution-host/execution-host' diff --git a/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement-host-partition.spec.ts b/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement-host-partition.spec.ts index 5b90d7db9d1..bcd77bef6eb 100644 --- a/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement-host-partition.spec.ts +++ b/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement-host-partition.spec.ts @@ -1,4 +1,4 @@ -import { withDurableRuntimeStore } from '../../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { diff --git a/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement.test.ts b/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement.test.ts index ed8be3cebc2..70886e881eb 100644 --- a/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement.test.ts +++ b/src/main/runtime/terminal/surface/orca-runtime-terminal-retirement.test.ts @@ -1,4 +1,4 @@ -import '../../orca-runtime-tests/runtime-durable-store-fixture' +import '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' diff --git a/src/main/runtime/terminal/surface/paired-close-retirement-proof-publication-order.spec.ts b/src/main/runtime/terminal/surface/paired-close-retirement-proof-publication-order.spec.ts index f350351f2ec..2420ace9e95 100644 --- a/src/main/runtime/terminal/surface/paired-close-retirement-proof-publication-order.spec.ts +++ b/src/main/runtime/terminal/surface/paired-close-retirement-proof-publication-order.spec.ts @@ -1,4 +1,4 @@ -import { withDurableRuntimeStore } from '../../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it, vi } from 'vitest' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' diff --git a/src/main/runtime/terminal/surface/runtime-owned-terminal-publication-lineage.test.ts b/src/main/runtime/terminal/surface/runtime-owned-terminal-publication-lineage.test.ts index dcf3a931cbd..24ca569d1a6 100644 --- a/src/main/runtime/terminal/surface/runtime-owned-terminal-publication-lineage.test.ts +++ b/src/main/runtime/terminal/surface/runtime-owned-terminal-publication-lineage.test.ts @@ -2,12 +2,12 @@ import { expect, it, vi } from 'vitest' import type { RuntimeMobileSessionTabsResult } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' // Fragments stay side-effect ordered: mocks, then lifecycle, then fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { store, TEST_WORKTREE_ID } = - await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') -const { committingSpawn } = await import('../../orca-runtime-tests/bind-first-pane.test-fixture') + await import('../../construction/test-context/orca-runtime-test-fixtures.spec') +const { committingSpawn } = await import('../layout/bind-first-pane.test-fixture') it.each(['renderer:active-generation', 'headless:active-generation'])( 'keeps %s live when runtime-owned creation supplements its inventory', diff --git a/src/main/runtime/terminal/surface/terminal-list-surface-lost-orphan.spec.ts b/src/main/runtime/terminal/surface/terminal-list-surface-lost-orphan.spec.ts index 055cb76e786..d764d6afdab 100644 --- a/src/main/runtime/terminal/surface/terminal-list-surface-lost-orphan.spec.ts +++ b/src/main/runtime/terminal/surface/terminal-list-surface-lost-orphan.spec.ts @@ -9,8 +9,8 @@ import type { import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' import './pty-recorded-surface-topology' import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' -import { bindPaneFirst } from '../../orca-runtime-tests/bind-first-pane.test-fixture' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { bindPaneFirst } from '../layout/bind-first-pane.test-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' export function registerTerminalListSurfaceLostOrphanTests(): void { // Orphan status must compare PTY claims to current layout topology (#18191); main-layout builds retract panes through main, not window graphs. diff --git a/src/main/runtime/terminal/surface/terminal-surface-replies-main.test.ts b/src/main/runtime/terminal/surface/terminal-surface-replies-main.test.ts index 4143063442d..a7c5cdbab3a 100644 --- a/src/main/runtime/terminal/surface/terminal-surface-replies-main.test.ts +++ b/src/main/runtime/terminal/surface/terminal-surface-replies-main.test.ts @@ -5,7 +5,7 @@ import { HEADLESS_LEAF_ID, HEADLESS_SECOND_LEAF_ID, TEST_WORKTREE_ID -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { SURFACE_PTYS, SURFACE_TAB_ID, diff --git a/src/main/runtime/terminal/surface/terminal-surface-replies.test-fixture.ts b/src/main/runtime/terminal/surface/terminal-surface-replies.test-fixture.ts index d1f93d694c5..ad20f482636 100644 --- a/src/main/runtime/terminal/surface/terminal-surface-replies.test-fixture.ts +++ b/src/main/runtime/terminal/surface/terminal-surface-replies.test-fixture.ts @@ -1,7 +1,7 @@ // Normalize one desktop scenario's CLI, paired and orcad replies for byte-identical comparison across layout ownership modes. import { readFileSync } from 'node:fs' import { vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { HEADLESS_LEAF_ID, @@ -11,14 +11,14 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import type { RuntimeSyncWindowGraph } from '../../../../shared/remote-runtime/session-graph/runtime-session-contracts' import type { RuntimeTerminalShow } from '../../../../shared/terminal/runtime/runtime-terminal-contracts' import type { WorkspaceSessionState } from '../../../../shared/workspace-session/workspace-session-state-types' import type { ExecutionHostId } from '../../../../shared/execution-host/execution-host' import type { LayoutCommand } from '../../../../shared/workspace-layout/workspace-layout-command-types' import { applyCommandToSession } from '../../../persistence/terminal-topology/pane-admission/terminal-pane-admission' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' export const SURFACE_TAB_ID = '44444444-4444-4444-8444-444444444444' export const SURFACE_PTYS = { [HEADLESS_LEAF_ID]: 'pty-a', [HEADLESS_SECOND_LEAF_ID]: 'pty-b' } diff --git a/src/main/runtime/orca-runtime-tests/workspace-layout-stream-events.test-fixture.ts b/src/main/runtime/terminal/surface/workspace-layout-stream-events.test-fixture.ts similarity index 83% rename from src/main/runtime/orca-runtime-tests/workspace-layout-stream-events.test-fixture.ts rename to src/main/runtime/terminal/surface/workspace-layout-stream-events.test-fixture.ts index 7456b90e81f..def245ae407 100644 --- a/src/main/runtime/orca-runtime-tests/workspace-layout-stream-events.test-fixture.ts +++ b/src/main/runtime/terminal/surface/workspace-layout-stream-events.test-fixture.ts @@ -1,11 +1,11 @@ // Normalize records frames into per-workspace whole-layout events so both layout ownership modes share assertions. -import type { PublishedWorkspaceLayout } from '../../../shared/workspace-layout/published-layout/workspace-layout-published' -import { applyWorkspaceLayoutRecordChange } from '../../../shared/workspace-layout/published-layout/workspace-layout-records' +import type { PublishedWorkspaceLayout } from '../../../../shared/workspace-layout/published-layout/workspace-layout-published' +import { applyWorkspaceLayoutRecordChange } from '../../../../shared/workspace-layout/published-layout/workspace-layout-records' import type { WorkspaceLayoutEvent, WorkspaceLayoutStreamEvent -} from '../../../shared/workspace-layout/published-layout/workspace-layout-stream-frames' +} from '../../../../shared/workspace-layout/published-layout/workspace-layout-stream-frames' export type LayoutEventCollector = { /** One per workspace changed, in frame order. */ diff --git a/src/main/runtime/terminal/surface/workspace-layout-stream.test.ts b/src/main/runtime/terminal/surface/workspace-layout-stream.test.ts index 6a950161871..dd199451594 100644 --- a/src/main/runtime/terminal/surface/workspace-layout-stream.test.ts +++ b/src/main/runtime/terminal/surface/workspace-layout-stream.test.ts @@ -14,7 +14,7 @@ import { SSH_KEY } from '../../../../shared/workspace-layout/persistence/workspace-layout-session.test-fixture' import { WorkspaceLayoutStream } from './workspace-layout-stream' -import '../../orca-runtime-tests/workspace-layout-stream-events.test-fixture' +import './workspace-layout-stream-events.test-fixture' const SSH_HOST: ExecutionHostId = 'ssh:target-1' diff --git a/src/main/runtime/terminal/title/orca-runtime-terminal-rename-retention.test.ts b/src/main/runtime/terminal/title/orca-runtime-terminal-rename-retention.test.ts index f2446be4b08..5139c9b9763 100644 --- a/src/main/runtime/terminal/title/orca-runtime-terminal-rename-retention.test.ts +++ b/src/main/runtime/terminal/title/orca-runtime-terminal-rename-retention.test.ts @@ -1,8 +1,8 @@ -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { describe, expect, it, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { HEADLESS_LEAF_ID, @@ -10,10 +10,10 @@ import { TEST_WORKTREE_PATH, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' -import { committingSpawn } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { committingSpawn } from '../layout/bind-first-pane.test-fixture' import '../../session-lifecycle/projection/runtime-mobile-agent-status-builder' describe('terminal rename before renderer graph hydration', () => { diff --git a/src/main/runtime/terminal/wait/active-worktree-context-parity.test.ts b/src/main/runtime/terminal/wait/active-worktree-context-parity.test.ts index 47bcf4f7357..967e981f15a 100644 --- a/src/main/runtime/terminal/wait/active-worktree-context-parity.test.ts +++ b/src/main/runtime/terminal/wait/active-worktree-context-parity.test.ts @@ -32,7 +32,7 @@ import { partialRuntimeStore, storeRepo, storeWorktreeMeta -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' type Session = Partial< Pick< diff --git a/src/main/runtime/terminal/wait/agent-startup-blocked-message.test.ts b/src/main/runtime/terminal/wait/agent-startup-blocked-message.test.ts index bcbf07e79cd..36d3170e0eb 100644 --- a/src/main/runtime/terminal/wait/agent-startup-blocked-message.test.ts +++ b/src/main/runtime/terminal/wait/agent-startup-blocked-message.test.ts @@ -1,10 +1,7 @@ import { readFileSync } from 'node:fs' import { afterEach, describe, expect, it, vi } from 'vitest' import { agentStartupBlockedMessage } from './agent-startup-blocked-message' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' function fixture(name: string): { recording: string; cols: number; rows: number } { const url = (ext: string) => new URL(`../../__fixtures__/${name}.${ext}`, import.meta.url) diff --git a/src/main/runtime/orca-runtime-tests/agent-transcript-pane-test-harness.ts b/src/main/runtime/terminal/wait/agent-transcript-pane-test-harness.ts similarity index 91% rename from src/main/runtime/orca-runtime-tests/agent-transcript-pane-test-harness.ts rename to src/main/runtime/terminal/wait/agent-transcript-pane-test-harness.ts index ec7eb163ff0..7814136995f 100644 --- a/src/main/runtime/orca-runtime-tests/agent-transcript-pane-test-harness.ts +++ b/src/main/runtime/terminal/wait/agent-transcript-pane-test-harness.ts @@ -1,11 +1,11 @@ -import type { RuntimeTerminalCreate } from '../../../shared/terminal/runtime/runtime-terminal-create-contract' +import type { RuntimeTerminalCreate } from '../../../../shared/terminal/runtime/runtime-terminal-create-contract' import { vi } from 'vitest' -import { OrcaRuntimeService } from '../orca-runtime' -import type { TuiAgent } from '../../../shared/agent-launch/catalog/tui-agent' -import type { TerminalProcessInspection as PtyProcessInspection } from '../../../shared/terminal/pty/lifecycle/terminal-process-inspection' -import type { RuntimeStore } from '../construction/runtime-store-contract' -import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../shared/workspace-layout/layout-owner-switch' -import { committingSpawn, registerBoundPty } from './bind-first-pane.test-fixture' +import { OrcaRuntimeService } from '../../orca-runtime' +import type { TuiAgent } from '../../../../shared/agent-launch/catalog/tui-agent' +import type { TerminalProcessInspection as PtyProcessInspection } from '../../../../shared/terminal/pty/lifecycle/terminal-process-inspection' +import type { RuntimeStore } from '../../construction/runtime-store-contract' +import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/workspace-layout/layout-owner-switch' +import { committingSpawn, registerBoundPty } from '../layout/bind-first-pane.test-fixture' const TRANSCRIPT_PANE_LEAF_ID = '11111111-1111-4111-8111-111111111111' const TRANSCRIPT_PANE_TAB_ID = 'tab-1' diff --git a/src/main/runtime/terminal/wait/claude-dialog-interactive-wait.test.ts b/src/main/runtime/terminal/wait/claude-dialog-interactive-wait.test.ts index 9a95555a6c4..b087bd90dfe 100644 --- a/src/main/runtime/terminal/wait/claude-dialog-interactive-wait.test.ts +++ b/src/main/runtime/terminal/wait/claude-dialog-interactive-wait.test.ts @@ -1,10 +1,7 @@ import { readFileSync } from 'node:fs' import { join } from 'node:path' import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import type { RuntimeVisibleTerminalState } from '../records/runtime-terminal-state-records' vi.mock('electron', () => ({ diff --git a/src/main/runtime/terminal/wait/hermes-slash-readiness-transcript.test.ts b/src/main/runtime/terminal/wait/hermes-slash-readiness-transcript.test.ts index 93ca844d23a..31797d8a6c9 100644 --- a/src/main/runtime/terminal/wait/hermes-slash-readiness-transcript.test.ts +++ b/src/main/runtime/terminal/wait/hermes-slash-readiness-transcript.test.ts @@ -5,7 +5,7 @@ import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID, waitForTranscriptIdle -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +} from './agent-transcript-pane-test-harness' import metadata from '../../__fixtures__/hermes-slash-setup.meta.json' vi.mock('electron', () => ({ diff --git a/src/main/runtime/terminal/wait/launched-agent-composer-readiness-claude.test.ts b/src/main/runtime/terminal/wait/launched-agent-composer-readiness-claude.test.ts index 0deeddc0e07..4f84aed16a8 100644 --- a/src/main/runtime/terminal/wait/launched-agent-composer-readiness-claude.test.ts +++ b/src/main/runtime/terminal/wait/launched-agent-composer-readiness-claude.test.ts @@ -3,10 +3,7 @@ import { readFileSync } from 'node:fs' import { join } from 'node:path' import { afterEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { waitForLaunchedAgentComposer } from './launched-agent-composer-readiness' import type { ProcessTableRow } from '../../../../shared/process-observation/tables/process-table-snapshot' diff --git a/src/main/runtime/terminal/wait/launched-agent-exit-watch.test.ts b/src/main/runtime/terminal/wait/launched-agent-exit-watch.test.ts index 0eb51fcb5bf..1628a8b1d53 100644 --- a/src/main/runtime/terminal/wait/launched-agent-exit-watch.test.ts +++ b/src/main/runtime/terminal/wait/launched-agent-exit-watch.test.ts @@ -1,8 +1,5 @@ import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { waitForWorkerAgentReady } from './launched-agent-composer-readiness' import type { LaunchedAgentForeground } from './launched-agent-foreground' import { failOnLaunchedAgentExit, type LaunchedAgentExitRuntime } from './launched-agent-exit-watch' diff --git a/src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration-part-04.spec.ts b/src/main/runtime/terminal/wait/mobile-creation-and-orchestration-part-04.spec.ts similarity index 51% rename from src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration-part-04.spec.ts rename to src/main/runtime/terminal/wait/mobile-creation-and-orchestration-part-04.spec.ts index 15a22c43322..e65fb1e5629 100644 --- a/src/main/runtime/orca-runtime-tests/mobile-creation-and-orchestration-part-04.spec.ts +++ b/src/main/runtime/terminal/wait/mobile-creation-and-orchestration-part-04.spec.ts @@ -1,12 +1,12 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { MOCK_GIT_WORKTREES } from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import '../../../git/worktrees/catalog/worktree-scan-cache' import 'node:os' -import { TEST_REPO_ID, deferred, store, withPlatform } from './orca-runtime-test-fixtures.spec' +import { store } from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('tui-idle times out when PTY data has no agent OSC title transitions', async () => { @@ -91,48 +91,4 @@ describe('OrcaRuntimeService', () => { expect(result.condition).toBe('tui-idle') expect(result.satisfied).toBe(true) }) - - it('keeps each worktree poll paired with its platform generation', async () => { - await withPlatform('win32', async () => { - let runtimePreference: { kind: 'wsl'; distro: string } | { kind: 'windows-host' } = { - kind: 'wsl', - distro: 'Ubuntu' - } - const runtimeStore = { - ...store, - getProjects: () => [ - { - id: 'project-generation', - displayName: 'generation', - badgeColor: 'blue', - sourceRepoIds: [TEST_REPO_ID], - localWindowsRuntimePreference: runtimePreference, - createdAt: 0, - updatedAt: 0 - } - ], - getSettings: () => ({ - ...store.getSettings(), - localWindowsRuntimeDefault: { kind: 'windows-host' as const } - }) - } - const staleScan = deferred() - const scansBefore = vi.mocked(listWorktrees).mock.calls.length - vi.mocked(listWorktrees).mockImplementationOnce(() => staleScan.promise) - const runtime = new OrcaRuntimeService(runtimeStore as never) - - const stalePoll = runtime.getWorktreePs() - runtimePreference = { kind: 'windows-host' } - runtime.notifyBranchRenamed(TEST_REPO_ID) - const freshPolling = runtime.getWorktreePs() - staleScan.resolve(MOCK_GIT_WORKTREES) - const [staleResult, freshPoll] = await Promise.all([stalePoll, freshPolling]) - // Only the live route lists; the poll admitted for the replaced WSL route runs no Git. - expect(vi.mocked(listWorktrees).mock.calls.length - scansBefore).toBe(1) - - // Concurrent scans retain the platform map from their own generation even when they finish out of order. - expect(staleResult.worktrees[0]).toMatchObject({ terminalPlatform: 'linux' }) - expect(freshPoll.worktrees[0]).toMatchObject({ terminalPlatform: 'win32' }) - }) - }) }) diff --git a/src/main/runtime/terminal/wait/omp-readiness-transcripts.test.ts b/src/main/runtime/terminal/wait/omp-readiness-transcripts.test.ts index e1a6c202c5b..8aeade2b83d 100644 --- a/src/main/runtime/terminal/wait/omp-readiness-transcripts.test.ts +++ b/src/main/runtime/terminal/wait/omp-readiness-transcripts.test.ts @@ -1,10 +1,7 @@ import { readFileSync } from 'node:fs' import { join } from 'node:path' import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import type { TuiAgent } from '../../../../shared/agent-launch/catalog/tui-agent' import { createDraftPasteReadyScanner } from '../../../../shared/agent-launch/startup/readiness/draft-paste-ready-scanner' diff --git a/src/main/runtime/terminal/wait/terminal-creation-and-readiness-part-06.spec.ts b/src/main/runtime/terminal/wait/terminal-creation-and-readiness-part-06.spec.ts new file mode 100644 index 00000000000..84da347e120 --- /dev/null +++ b/src/main/runtime/terminal/wait/terminal-creation-and-readiness-part-06.spec.ts @@ -0,0 +1,67 @@ +import { describe, expect, it, vi } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { + TEST_WORKTREE_ID, + TEST_WORKTREE_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it('does not treat a Codex launch title as tui-idle readiness', async () => { + vi.useFakeTimers() + try { + const runtime = new OrcaRuntimeService(store) + const serializeProviderBuffer = vi.fn().mockResolvedValue({ + data: 'OpenAI Codex\r\nmodel: gpt-5.5\r\ndirectory: /repo\r\n', + cols: 80, + rows: 24, + seq: 1 + }) + runtime.setPtyController({ + spawn: vi.fn().mockResolvedValue({ id: 'pty-bg' }), + write: () => true, + kill: () => true, + getForegroundProcess: async () => null, + serializeProviderBuffer + }) + const { handle } = await runtime.createTerminal(`path:${TEST_WORKTREE_PATH}`) + + runtime.attachWindow(1) + await runtime.syncWindowGraph(1, { + tabs: [ + { + tabId: 'tab-bg', + worktreeId: TEST_WORKTREE_ID, + title: 'Codex YOLO', + activeLeafId: 'pane-bg', + layout: null + } + ], + leaves: [ + { + tabId: 'tab-bg', + worktreeId: TEST_WORKTREE_ID, + leafId: 'pane-bg', + paneRuntimeId: 1, + ptyId: 'pty-bg', + paneTitle: null + } + ] + }) + + const waitPromise = runtime.waitForTerminal(handle, { + condition: 'tui-idle', + timeoutMs: 1_000 + }) + const timeoutAssertion = expect(waitPromise).rejects.toThrow('timeout') + + await vi.advanceTimersByTimeAsync(2_000) + + await timeoutAssertion + expect(serializeProviderBuffer).not.toHaveBeenCalled() + } finally { + vi.useRealTimers() + } + }) +}) diff --git a/src/main/runtime/terminal/wait/terminal-interactive-wait-visibility.test.ts b/src/main/runtime/terminal/wait/terminal-interactive-wait-visibility.test.ts index 6759b60dcbb..9c7cd40b1b0 100644 --- a/src/main/runtime/terminal/wait/terminal-interactive-wait-visibility.test.ts +++ b/src/main/runtime/terminal/wait/terminal-interactive-wait-visibility.test.ts @@ -11,7 +11,7 @@ import { type TranscriptPaneOptions, TRANSCRIPT_PANE_PTY_ID as PTY_ID, waitForTranscriptIdle -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +} from './agent-transcript-pane-test-harness' import { assertTerminalAgentSendable } from '../../rpc/terminal/terminal-agent-send-guard' import { readRuntimeFixture } from './agent-transcript-replay-test-harness' diff --git a/src/main/runtime/terminal/wait/terminal-start-failure-readiness.test.ts b/src/main/runtime/terminal/wait/terminal-start-failure-readiness.test.ts index db4e25e5b6c..7546035ef75 100644 --- a/src/main/runtime/terminal/wait/terminal-start-failure-readiness.test.ts +++ b/src/main/runtime/terminal/wait/terminal-start-failure-readiness.test.ts @@ -1,8 +1,5 @@ import { afterEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { waitForWorkerAgentReady, waitForLaunchedAgentComposer diff --git a/src/main/runtime/terminal/wait/terminal-wait-name-only-idle.test.ts b/src/main/runtime/terminal/wait/terminal-wait-name-only-idle.test.ts index 7bdbda1c486..24d278bc799 100644 --- a/src/main/runtime/terminal/wait/terminal-wait-name-only-idle.test.ts +++ b/src/main/runtime/terminal/wait/terminal-wait-name-only-idle.test.ts @@ -5,7 +5,7 @@ import type { RuntimeSyncWindowGraph } from '../../../../shared/remote-runtime/s import type { TuiAgent } from '../../../../shared/agent-launch/catalog/tui-agent' -import { registerBoundPty } from '../../orca-runtime-tests/bind-first-pane.test-fixture' +import { registerBoundPty } from '../layout/bind-first-pane.test-fixture' // #6011: name-only Codex/Devin titles were stored as idle and prematurely satisfied tui-idle; distinguish settling, corroborating and veto evidence. diff --git a/src/main/runtime/terminal/wait/tui-idle-claude-cold-start.test.ts b/src/main/runtime/terminal/wait/tui-idle-claude-cold-start.test.ts index c5ce9724782..b42afd39a9a 100644 --- a/src/main/runtime/terminal/wait/tui-idle-claude-cold-start.test.ts +++ b/src/main/runtime/terminal/wait/tui-idle-claude-cold-start.test.ts @@ -1,10 +1,7 @@ /** STA-2380: a shell auto-title names Claude before it draws anything; quiet alone must not make it ready. */ import { afterEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { waitForWorkerStartComposer } from './launched-agent-composer-readiness' import { sendAgentTurn } from '../../orchestration/turn-delivery/send-agent-turn' import type { RuntimePtyController } from '../lifecycle/runtime-pty-controller-contract' diff --git a/src/main/runtime/terminal/wait/tui-idle-codex-plan-menu.test.ts b/src/main/runtime/terminal/wait/tui-idle-codex-plan-menu.test.ts index 2f366431158..a3d4cd35b18 100644 --- a/src/main/runtime/terminal/wait/tui-idle-codex-plan-menu.test.ts +++ b/src/main/runtime/terminal/wait/tui-idle-codex-plan-menu.test.ts @@ -1,10 +1,7 @@ import { afterEach, describe, expect, it, vi } from 'vitest' import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { readRuntimeFixture } from './agent-transcript-replay-test-harness' import type { OrcaRuntimeService } from '../../orca-runtime' diff --git a/src/main/runtime/terminal/wait/tui-idle-command-paint.test.ts b/src/main/runtime/terminal/wait/tui-idle-command-paint.test.ts index 47782045379..14c00a2a0a7 100644 --- a/src/main/runtime/terminal/wait/tui-idle-command-paint.test.ts +++ b/src/main/runtime/terminal/wait/tui-idle-command-paint.test.ts @@ -1,10 +1,7 @@ /** Quiet foreground is insufficient until the agent paints; use command-start markers to exclude shell prompts and launch echo. */ import { afterEach, describe, expect, it, vi } from 'vitest' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' const POLL_INTERVAL_MS = 2_000 diff --git a/src/main/runtime/terminal/wait/tui-idle-hook-lane-runtime.test.ts b/src/main/runtime/terminal/wait/tui-idle-hook-lane-runtime.test.ts index 1a30a96daaf..3ddf36dbbfe 100644 --- a/src/main/runtime/terminal/wait/tui-idle-hook-lane-runtime.test.ts +++ b/src/main/runtime/terminal/wait/tui-idle-hook-lane-runtime.test.ts @@ -1,5 +1,5 @@ import { describe, expect, it, vi, afterEach } from 'vitest' -import { createTranscriptPane } from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane } from './agent-transcript-pane-test-harness' import type { AgentStatusIpcPayload } from '../../../../shared/agent-status/contracts/agent-status-ipc-payload' import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' diff --git a/src/main/runtime/terminal/wait/tui-idle-zsh-preexec-hook-order.live-shell.test.ts b/src/main/runtime/terminal/wait/tui-idle-zsh-preexec-hook-order.live-shell.test.ts index b9d2e626c26..72a991a1e26 100644 --- a/src/main/runtime/terminal/wait/tui-idle-zsh-preexec-hook-order.live-shell.test.ts +++ b/src/main/runtime/terminal/wait/tui-idle-zsh-preexec-hook-order.live-shell.test.ts @@ -10,10 +10,7 @@ import { quotePosixShell } from '../../../../shared/shell/launch/shell-argument- import { getShellLaunchConfig } from '../../../providers/local-pty/local-pty-shell-ready' import { selectShellStartupFeatures } from '../../../pty/shell-startup/shell-startup-features' import { hasZsh, ZSH_PATH } from '../../../pty/shell-startup/zsh-startup-hook-pty-harness' -import { - createTranscriptPane, - TRANSCRIPT_PANE_PTY_ID -} from '../../orca-runtime-tests/agent-transcript-pane-test-harness' +import { createTranscriptPane, TRANSCRIPT_PANE_PTY_ID } from './agent-transcript-pane-test-harness' import { normalizeTerminalChunk } from '../output/terminal-ansi-normalization' import { hasTerminalAgentPainted, TerminalCommandPaint } from '../input/terminal-command-paint' diff --git a/src/main/runtime/workspaces/catalog/workspace-selector-folder-matching.test.ts b/src/main/runtime/workspaces/catalog/workspace-selector-folder-matching.test.ts index c684b195a2e..3e10f44ad4e 100644 --- a/src/main/runtime/workspaces/catalog/workspace-selector-folder-matching.test.ts +++ b/src/main/runtime/workspaces/catalog/workspace-selector-folder-matching.test.ts @@ -1,6 +1,6 @@ import { describe, expect, it } from 'vitest' -import { withDurableRuntimeStore } from '../../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { getDefaultWorkspaceSession } from '../../../../shared/orca-profiles/constants' import { OrcaRuntimeService } from '../../orca-runtime' import type { Repo } from '../../../../shared/repository/repo-types' diff --git a/src/main/runtime/workspaces/catalog/worktree-scan-repeated-path.test.ts b/src/main/runtime/workspaces/catalog/worktree-scan-repeated-path.test.ts index 889db5c99e2..3b69b755012 100644 --- a/src/main/runtime/workspaces/catalog/worktree-scan-repeated-path.test.ts +++ b/src/main/runtime/workspaces/catalog/worktree-scan-repeated-path.test.ts @@ -32,7 +32,7 @@ import { partialRuntimeStore, storeWorktreeMeta, type PartialRuntimeStore -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' const REPO_ID = 'repo-local' diff --git a/src/main/runtime/workspaces/catalog/worktree-selector-resolution.spec.ts b/src/main/runtime/workspaces/catalog/worktree-selector-resolution.spec.ts new file mode 100644 index 00000000000..a945a40be61 --- /dev/null +++ b/src/main/runtime/workspaces/catalog/worktree-selector-resolution.spec.ts @@ -0,0 +1,46 @@ +import '../../../providers/ssh-host-not-served-error' +import { describe, expect, it } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../../../shared/orca-profiles/constants' +import '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../git/worktrees/creation/worktree-sparse-add' +import '../../../git/worktrees/creation/worktree-add' +import { join } from 'node:path' +import '../../../git/worktrees/catalog/worktree-scan-cache' +import { mkdir, mkdtemp, writeFile } from 'node:fs/promises' +import { tmpdir } from 'node:os' +import '../../rpc/dispatcher' +import '../../rpc/methods/terminal/terminal' +import { + TEST_FOLDER_WORKSPACE_KEY, + createFolderWorkspaceRuntimeStore, + makeFolderProjectGroup, + makeFolderWorkspace +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' + +describe('OrcaRuntimeService', () => { + it.each([ + { label: 'canonical folder workspace selector', selector: TEST_FOLDER_WORKSPACE_KEY }, + { label: 'id-prefixed folder workspace selector', selector: `id:${TEST_FOLDER_WORKSPACE_KEY}` } + ])('reads file explorer paths for a $label', async ({ selector }) => { + const folderPath = await mkdtemp(join(tmpdir(), 'orca-runtime-folder-files-')) + await mkdir(join(folderPath, 'src')) + await writeFile(join(folderPath, 'src', 'app.ts'), 'export {}\n') + const folderWorkspace = makeFolderWorkspace({ folderPath }) + const projectGroup = makeFolderProjectGroup({ parentPath: folderPath }) + const runtime = new OrcaRuntimeService( + createFolderWorkspaceRuntimeStore(folderWorkspace, projectGroup) as never + ) + + await expect(runtime.readFileExplorerDir(selector, 'src')).resolves.toContainEqual({ + name: 'app.ts', + isDirectory: false, + isSymlink: false + }) + await expect(runtime.readFileExplorerPreview(selector, 'src/app.ts')).resolves.toMatchObject({ + content: 'export {}\n', + isBinary: false + }) + }) +}) diff --git a/src/main/runtime/orca-runtime-tests/local-worktree-creation.spec.ts b/src/main/runtime/workspaces/creation/local-worktree-creation.spec.ts similarity index 87% rename from src/main/runtime/orca-runtime-tests/local-worktree-creation.spec.ts rename to src/main/runtime/workspaces/creation/local-worktree-creation.spec.ts index 8ff5a82763c..a9731ae0286 100644 --- a/src/main/runtime/orca-runtime-tests/local-worktree-creation.spec.ts +++ b/src/main/runtime/workspaces/creation/local-worktree-creation.spec.ts @@ -1,18 +1,21 @@ -import '../../git/command-runner/git-exec-file' +import '../../../git/command-runner/git-exec-file' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../git/worktrees/creation/worktree-add' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../git/worktrees/creation/worktree-add' import { addWorktreeMock, deleteWorktreeHistoryDirMock -} from '../orca-runtime-test-mocks/setup.spec' -import '../../git/refs/resolution/repo-default-base-ref' -import '../../git/refs/resolution/repo-branch-conflict' -import '../../git/worktrees/catalog/worktree-scan-cache' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' -import { makeWorktreeMeta, store } from './orca-runtime-test-fixtures.spec' -import type { HostWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' +} from '../../orca-runtime-test-mocks/setup.spec' +import '../../../git/refs/resolution/repo-default-base-ref' +import '../../../git/refs/resolution/repo-branch-conflict' +import '../../../git/worktrees/catalog/worktree-scan-cache' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' +import { + makeWorktreeMeta, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import type { HostWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('creates additional workspace metadata for folder-mode repos through runtime create', async () => { diff --git a/src/main/runtime/workspaces/creation/managed-worktree-create-telemetry.test.ts b/src/main/runtime/workspaces/creation/managed-worktree-create-telemetry.test.ts index 4d12e81854a..eacb37bf0e9 100644 --- a/src/main/runtime/workspaces/creation/managed-worktree-create-telemetry.test.ts +++ b/src/main/runtime/workspaces/creation/managed-worktree-create-telemetry.test.ts @@ -48,7 +48,7 @@ import { OrcaRuntimeService } from '../../orca-runtime' import type { WorktreeCreateTimingRecorder } from '../../../workspaces/creation/worktree-create-timing' import type { PreparationRearmHolder } from '../../../workspaces/creation/preparation/worktree-create-preparation' import { _resetWorktreeCreateConcurrencyForTests } from '../../../workspaces/creation/worktree-create-concurrency' -import { partialRuntimeStore } from '../../orca-runtime-tests/runtime-store-partial-fixture' +import { partialRuntimeStore } from '../../construction/test-context/runtime-store-partial-fixture' const gitRepo = { id: 'repo-1', diff --git a/src/main/runtime/workspaces/creation/orca-runtime-worktree-provisioning-availability.test.ts b/src/main/runtime/workspaces/creation/orca-runtime-worktree-provisioning-availability.test.ts index 1011720746c..9ca2de52a00 100644 --- a/src/main/runtime/workspaces/creation/orca-runtime-worktree-provisioning-availability.test.ts +++ b/src/main/runtime/workspaces/creation/orca-runtime-worktree-provisioning-availability.test.ts @@ -1,6 +1,6 @@ -import '../../orca-runtime-tests/orca-runtime-test-lifecycle.spec' +import '../../construction/test-context/orca-runtime-test-lifecycle.spec' import { describe, expect, it, onTestFinished, vi } from 'vitest' -import '../../orca-runtime-tests/runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../orca-runtime' import { computeWorktreePathMock, @@ -11,8 +11,8 @@ import { createSetupRunnerScript } from '../../../workspace-hooks/worktree-runne import { getEffectiveHooks } from '../../../workspace-hooks/hooks' import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' import { shouldRunSetupForCreate } from '../../../workspace-hooks/effective-hook-config' -import { store } from '../../orca-runtime-tests/orca-runtime-test-fixtures.spec' -import { createMobileCreateTestNotifier } from '../../orca-runtime-tests/orca-runtime-test-scenario-builders.spec' +import { store } from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createMobileCreateTestNotifier } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' import 'node:os' describe('host worktree creation while its renderer is unavailable', () => { diff --git a/src/main/runtime/workspaces/creation/runtime-folder-workspace-wsl-launch-scope.test.ts b/src/main/runtime/workspaces/creation/runtime-folder-workspace-wsl-launch-scope.test.ts index 6d27a7ad4d1..b2b58309b85 100644 --- a/src/main/runtime/workspaces/creation/runtime-folder-workspace-wsl-launch-scope.test.ts +++ b/src/main/runtime/workspaces/creation/runtime-folder-workspace-wsl-launch-scope.test.ts @@ -8,15 +8,15 @@ vi.mock('node:fs/promises', async (importOriginal) => ({ })) // Fragments stay side-effect ordered: mocks, then lifecycle, then fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { createFolderWorkspaceRuntimeStore, makeFolderProjectGroup, makeFolderWorkspace, TEST_FOLDER_WORKSPACE_KEY -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') const { blockedWslDistroForPath } = await import('../../../wsl/filesystem/wsl-unc-access-gate') const { isWslUserActFor } = await import('../../../wsl/discovery/wsl-user-act-scope') const { wslDistroHoldMessage } = diff --git a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-02.spec.ts b/src/main/runtime/workspaces/lineage/lineage-and-scan-cache-part-02.spec.ts similarity index 79% rename from src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-02.spec.ts rename to src/main/runtime/workspaces/lineage/lineage-and-scan-cache-part-02.spec.ts index 6604faf4095..d6e33537f45 100644 --- a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache-part-02.spec.ts +++ b/src/main/runtime/workspaces/lineage/lineage-and-scan-cache-part-02.spec.ts @@ -1,21 +1,21 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' import 'node:os' -import type { WorktreeLineage } from '../../../shared/worktree/lineage-types' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' +import type { WorktreeLineage } from '../../../../shared/worktree/lineage-types' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' import { TEST_REPO_ID, makeWorktreeInfo, makeWorktreeMeta, store -} from './orca-runtime-test-fixtures.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' import { hostWorktreeTarget, type HostWorktreeTarget -} from '../../../shared/worktree/host-qualified-identity' +} from '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('refuses a reparent that closes a three-workspace loop through saved lineage', async () => { @@ -172,33 +172,4 @@ describe('OrcaRuntimeService', () => { }) // #10562: renderer purges even after failed sweep; stale 30s scan rows would strand PTYs with no later retry. - it('revalidates against a fresh scan instead of a warm worktree-scan cache', async () => { - const deletedId = `${TEST_REPO_ID}::/tmp/deleted` - const localProvider = { - listProcesses: vi.fn(async () => [ - { id: `${deletedId}@@deleted-session`, cwd: '/tmp/deleted', title: 'shell' } - ]), - shutdown: vi.fn(async () => {}) - } - const runtime = new OrcaRuntimeService(store, undefined, { - getLocalProvider: () => localProvider as never - }) - - vi.mocked(listWorktrees).mockResolvedValueOnce([ - { path: '/tmp/deleted', head: 'abc', branch: 'd', isBare: false, isMainWorktree: false } - ]) - await runtime.teardownMissingManagedWorktreeTerminals(`id:${TEST_REPO_ID}`, [deletedId]) - expect(localProvider.shutdown).not.toHaveBeenCalled() - - vi.mocked(listWorktrees).mockResolvedValue([]) - const result = await runtime.teardownMissingManagedWorktreeTerminals(`id:${TEST_REPO_ID}`, [ - deletedId - ]) - - expect(result).toEqual({ stoppedWorktreeIds: [deletedId] }) - expect(localProvider.shutdown).toHaveBeenCalledWith( - `${deletedId}@@deleted-session`, - expect.objectContaining({ immediate: true }) - ) - }) }) diff --git a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache.spec.ts b/src/main/runtime/workspaces/lineage/lineage-and-scan-cache.spec.ts similarity index 82% rename from src/main/runtime/orca-runtime-tests/lineage-and-scan-cache.spec.ts rename to src/main/runtime/workspaces/lineage/lineage-and-scan-cache.spec.ts index fad26563eeb..80e96cdfd56 100644 --- a/src/main/runtime/orca-runtime-tests/lineage-and-scan-cache.spec.ts +++ b/src/main/runtime/workspaces/lineage/lineage-and-scan-cache.spec.ts @@ -1,14 +1,17 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' import { join } from 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' import { lstat, mkdir, mkdtemp, rm } from 'node:fs/promises' import { tmpdir } from 'node:os' -import type { WorktreeLineage } from '../../../shared/worktree/lineage-types' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' -import { makeWorktreeMeta, store } from './orca-runtime-test-fixtures.spec' -import type { HostWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' +import type { WorktreeLineage } from '../../../../shared/worktree/lineage-types' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' +import { + makeWorktreeMeta, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import type { HostWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' describe('OrcaRuntimeService', () => { it('rejects local lineage updates when Orca worktree identity is missing', async () => { diff --git a/src/main/runtime/orca-runtime-tests/worktree-ps-agent-wait.spec.ts b/src/main/runtime/workspaces/process-listing/worktree-ps-agent-wait.spec.ts similarity index 82% rename from src/main/runtime/orca-runtime-tests/worktree-ps-agent-wait.spec.ts rename to src/main/runtime/workspaces/process-listing/worktree-ps-agent-wait.spec.ts index 73bd4955883..bf837087946 100644 --- a/src/main/runtime/orca-runtime-tests/worktree-ps-agent-wait.spec.ts +++ b/src/main/runtime/workspaces/process-listing/worktree-ps-agent-wait.spec.ts @@ -1,11 +1,15 @@ import { beforeEach, describe, expect, it, vi } from 'vitest' -import { makePaneKey } from '../../../shared/workspace-layout/stable-pane-id' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { TEST_WORKTREE_ID, TEST_WORKTREE_PATH, store } from './orca-runtime-test-fixtures.spec' -import { AgentHookServer, _internals } from '../../agent-hooks/server/agent-hook-server' +import { makePaneKey } from '../../../../shared/workspace-layout/stable-pane-id' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { + TEST_WORKTREE_ID, + TEST_WORKTREE_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { AgentHookServer, _internals } from '../../../agent-hooks/server/agent-hook-server' -vi.mock('../../telemetry/client', () => ({ track: vi.fn() })) +vi.mock('../../../telemetry/client', () => ({ track: vi.fn() })) async function makeRuntimeWithHookRow( state: 'waiting' | 'working', diff --git a/src/main/runtime/workspaces/process-listing/worktree-ps-degraded-repo-scan.test.ts b/src/main/runtime/workspaces/process-listing/worktree-ps-degraded-repo-scan.test.ts index 8373bab9664..12016631998 100644 --- a/src/main/runtime/workspaces/process-listing/worktree-ps-degraded-repo-scan.test.ts +++ b/src/main/runtime/workspaces/process-listing/worktree-ps-degraded-repo-scan.test.ts @@ -39,7 +39,7 @@ import { partialRuntimeStore, storeRepo, storeWorktreeMeta -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' const REPO_ID = 'repo-remote' const REPO_PATH = '/home/user/projects/app' diff --git a/src/main/runtime/workspaces/process-listing/worktree-ps-structured-host.spec.ts b/src/main/runtime/workspaces/process-listing/worktree-ps-structured-host.spec.ts new file mode 100644 index 00000000000..a1b97d2e803 --- /dev/null +++ b/src/main/runtime/workspaces/process-listing/worktree-ps-structured-host.spec.ts @@ -0,0 +1,57 @@ +import { makeStructuredAgentStatusSubject } from '../../../../shared/agent-status/contracts/agent-status-subject' +import { beforeEach, describe, expect, it, vi } from 'vitest' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { + TEST_WORKTREE_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { AgentHookServer, _internals } from '../../../agent-hooks/server/agent-hook-server' + +vi.mock('../../../telemetry/client', () => ({ track: vi.fn() })) +vi.mock('../../../telemetry/cohort-classifier', () => ({ + getCohortAtEmit: vi.fn(() => ({ nth_repo_added: 2 })) +})) + +/** Covers the production status-store read, which a hand-built projection snapshot can bypass. */ +const SESSION = 'a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d' +const SUBJECT = makeStructuredAgentStatusSubject( + { + executionHostId: 'local', + wslDistro: null, + workspaceId: TEST_WORKTREE_ID, + workspaceKind: 'git-worktree' + }, + SESSION +) + +beforeEach(() => { + _internals.resetCachesForTests() +}) + +describe('worktree ps reads structured sessions from the agent-status store', () => { + it('lists nothing once the host has dropped the session', async () => { + const statusStore = new AgentHookServer() + statusStore.ingestStructuredStatus( + { + sessionId: SESSION, + workspaceId: TEST_WORKTREE_ID, + agent: 'claude', + status: 'attention', + latestPrompt: 'rm the branch', + updatedAt: 1_757_030_400_000 + }, + SUBJECT + ) + statusStore.dropStructuredStatus(SUBJECT) + + const { worktrees } = await new OrcaRuntimeService(store, undefined, { + getAgentStatusSnapshot: () => statusStore.getStatusSnapshot() + }).getWorktreePs() + + const worktree = worktrees.find((entry) => entry.worktreeId === TEST_WORKTREE_ID) + expect(worktree).toBeDefined() + expect(worktree?.agents).toEqual([]) + expect(worktree?.status).not.toBe('permission') + }) +}) diff --git a/src/main/runtime/workspaces/process-listing/worktree-ps-unverifiable-terminals.test.ts b/src/main/runtime/workspaces/process-listing/worktree-ps-unverifiable-terminals.test.ts index f4dd5bcca32..bc6148672f7 100644 --- a/src/main/runtime/workspaces/process-listing/worktree-ps-unverifiable-terminals.test.ts +++ b/src/main/runtime/workspaces/process-listing/worktree-ps-unverifiable-terminals.test.ts @@ -12,7 +12,7 @@ import { OrcaRuntimeService } from '../../orca-runtime' import { partialRuntimeStore, storeWorktreeMeta -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' // BUG-9: lost relay contact must report unverifiable, never live:0/pty:no for a surviving terminal. diff --git a/src/main/runtime/orca-runtime-tests/gitlab-and-pr-bases-part-02.spec.ts b/src/main/runtime/workspaces/references/gitlab-and-pr-bases-part-02.spec.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/gitlab-and-pr-bases-part-02.spec.ts rename to src/main/runtime/workspaces/references/gitlab-and-pr-bases-part-02.spec.ts index 62304051419..b1967d5c14e 100644 --- a/src/main/runtime/orca-runtime-tests/gitlab-and-pr-bases-part-02.spec.ts +++ b/src/main/runtime/workspaces/references/gitlab-and-pr-bases-part-02.spec.ts @@ -1,16 +1,20 @@ -import * as gitExecFile from '../../git/command-runner/git-exec-file' -import { SshHostNotServedError } from '../../providers/ssh-host-not-served-error' +import * as gitExecFile from '../../../git/command-runner/git-exec-file' +import { SshHostNotServedError } from '../../../providers/ssh-host-not-served-error' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { ORIGIN_HEAD_COMPONENT, ORIGIN_REMOTE_URL, getGitLabProjectRefForRemoteMock, getPullRequestPushTargetMock -} from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../../shared/worktree/hosted-review/review-head-tracking-ref' -import { TEST_REPO_ID, TEST_REPO_PATH, store } from './orca-runtime-test-fixtures.spec' +} from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../../shared/worktree/hosted-review/review-head-tracking-ref' +import { + TEST_REPO_ID, + TEST_REPO_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('refuses SSH GitHub fork PR heads instead of resolving them on this machine', async () => { diff --git a/src/main/runtime/orca-runtime-tests/hooks-and-hosted-review-part-02.spec.ts b/src/main/runtime/workspaces/references/hooks-and-hosted-review-part-02.spec.ts similarity index 82% rename from src/main/runtime/orca-runtime-tests/hooks-and-hosted-review-part-02.spec.ts rename to src/main/runtime/workspaces/references/hooks-and-hosted-review-part-02.spec.ts index 5c7868cc8ad..9ddb5363f3b 100644 --- a/src/main/runtime/orca-runtime-tests/hooks-and-hosted-review-part-02.spec.ts +++ b/src/main/runtime/workspaces/references/hooks-and-hosted-review-part-02.spec.ts @@ -1,14 +1,18 @@ import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { MOCK_GIT_WORKTREES, createHostedReviewMock, getHostedReviewCreationEligibilityMock -} from '../orca-runtime-test-mocks/setup.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import '../../git/refs/resolution/repo-default-base-ref' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { TEST_REPO_ID, TEST_REPO_PATH, store } from './orca-runtime-test-fixtures.spec' +} from '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../git/refs/resolution/repo-default-base-ref' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import { + TEST_REPO_ID, + TEST_REPO_PATH, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' describe('OrcaRuntimeService', () => { it('rejects hosted review worktree selectors outside the selected repo', async () => { diff --git a/src/main/runtime/workspaces/removal/owned-session-teardown-policy.test.ts b/src/main/runtime/workspaces/removal/owned-session-teardown-policy.test.ts index 5c5171fe803..52e3f1af4de 100644 --- a/src/main/runtime/workspaces/removal/owned-session-teardown-policy.test.ts +++ b/src/main/runtime/workspaces/removal/owned-session-teardown-policy.test.ts @@ -5,14 +5,14 @@ import { spawnWorktreeTarget } from '../../../../shared/worktree/host-qualified- import type { RuntimeClientEvent } from '../../../../shared/remote-runtime/session-graph/runtime-client-events' // Fragments stay side-effect ordered: mocks, then lifecycle, then fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { TEST_WORKTREE_ID, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') async function makeRuntime() { const { runtimeStore } = makeRuntimeStoreWithWorkspaceSession( diff --git a/src/main/runtime/workspaces/removal/runtime-worktree-removal-pty-stop.spec.ts b/src/main/runtime/workspaces/removal/runtime-worktree-removal-pty-stop.spec.ts new file mode 100644 index 00000000000..fde54bd5f68 --- /dev/null +++ b/src/main/runtime/workspaces/removal/runtime-worktree-removal-pty-stop.spec.ts @@ -0,0 +1,74 @@ +import { describe, expect, it, vi } from 'vitest' +import '../../terminal/layout/bind-first-pane.test-fixture' +import '../../../../shared/workspace-layout/layout-owner-switch' +import '../../construction/test-context/runtime-test-module-registration.spec' +import '../../orca-runtime-test-mocks/setup.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import '../../../browser/agent-browser/agent-browser-bridge' +import type { IPtyProvider } from '../../../providers/pty/provider-contract' +import '../../../git/worktrees/removal/worktree-removal-preflight' +import 'electron' +import '../../../git/worktrees/catalog/worktree-scan-cache' +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' +import { + TEST_WORKTREE_ID, + store, + syncSinglePty +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../construction/test-context/orca-runtime-test-scenario-builders.spec' + +describe('OrcaRuntimeService', () => { + describe('removeManagedWorktree PTY teardown (design §4.3)', () => { + function createProviderStub( + listProcesses: () => Promise<{ id: string; cwd: string; title: string }[]> + ) { + return { + spawn: vi.fn(), + attach: vi.fn(), + write: vi.fn(), + writeWithSettlement: vi.fn(), + resize: vi.fn(), + shutdown: vi.fn().mockResolvedValue(undefined), + sendSignal: vi.fn(), + getCwd: vi.fn(), + getInitialCwd: vi.fn(), + clearBuffer: vi.fn(), + resetInputModes: vi.fn(), + acknowledgeDataEvent: vi.fn(), + hasChildProcesses: vi.fn(), + getForegroundProcess: vi.fn(), + serialize: vi.fn(), + revive: vi.fn(), + listProcesses: vi.fn(listProcesses), + getDefaultShell: vi.fn(), + getProfiles: vi.fn(), + onData: vi.fn().mockReturnValue(() => {}), + onReplay: vi.fn().mockReturnValue(() => {}), + onExit: vi.fn().mockReturnValue(() => {}) + } satisfies IPtyProvider + } + + it('does not start Git removal when physical PTY stop cannot be proven', async () => { + // Retain the live PTY in fresh inventory so failed stop cannot be mistaken for proven exit. + const localProvider = createProviderStub(async () => [ + { id: 'pty-1', cwd: '/tmp', title: 'shell' } + ]) + const runtime = new OrcaRuntimeService(store, undefined, { + getLocalProvider: () => localProvider + }) + runtime.setPtyController({ + write: () => true, + kill: vi.fn(() => true), + stopAndWait: vi.fn(async () => false), + getForegroundProcess: async () => null + }) + await syncSinglePty(runtime, 'pty-1') + + await expect(runtime.removeManagedWorktree(TEST_WORKTREE_ID)).rejects.toThrow( + 'Failed to physically stop every PTY' + ) + + expect(removeWorktree).not.toHaveBeenCalled() + }) + }) +}) diff --git a/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-02.spec.ts b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-02.spec.ts new file mode 100644 index 00000000000..594c9fa226a --- /dev/null +++ b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-02.spec.ts @@ -0,0 +1,60 @@ +import * as gitExecFile from '../../../git/command-runner/git-exec-file' +import { describe, expect, it, vi } from 'vitest' +import { readFile, mkdir, rm, writeFile } from 'node:fs/promises' + +import '../../construction/test-context/runtime-test-module-registration.spec' +import { + MOCK_GIT_WORKTREES, + closeLocalWatcherForWorktreePathMock, + deleteWorktreeHistoryDirMock, + setPlatform +} from '../../orca-runtime-test-mocks/setup.spec' +import '../../../workspaces/removal/watcher-removal-drain' +import '../../../workspaces/removal/watcher-removal-gate' +import { join } from 'node:path' +import { listWorktreesStrict } from '../../../git/worktrees/catalog/worktree-listing' + +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' +import { + TEST_WORKTREE_ID, + TEST_WORKTREE_PATH, + createStaleRuntimeWorktreeStore +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createWorktreeRemovalRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' + +describe('OrcaRuntimeService', () => { + it('refuses a nonempty markerless Windows folder before teardown', async () => { + setPlatform('win32') + const { runtimeStore, removeWorktreeMeta } = createStaleRuntimeWorktreeStore(TEST_WORKTREE_ID) + const runtime = createWorktreeRemovalRuntime(runtimeStore) + deleteWorktreeHistoryDirMock.mockClear() + const teardown = vi.spyOn(runtime, 'acquireFileWatcherRemoval') + await mkdir(TEST_WORKTREE_PATH, { recursive: true }) + await writeFile(join(TEST_WORKTREE_PATH, 'scratch.txt'), 'delete me') + const gitSpy = vi.spyOn(gitExecFile, 'gitExecFileAsync').mockResolvedValue({ + stdout: '', + stderr: '' + }) + vi.mocked(listWorktreesStrict) + .mockResolvedValueOnce(MOCK_GIT_WORKTREES) + .mockResolvedValueOnce(MOCK_GIT_WORKTREES) + .mockResolvedValue([]) + + try { + await expect( + runtime.removeManagedWorktree(TEST_WORKTREE_ID, { force: true }) + ).rejects.toThrow('is no longer a Git worktree, so its folder was left on disk.') + expect(teardown).not.toHaveBeenCalled() + expect(removeWorktree).not.toHaveBeenCalled() + expect(removeWorktreeMeta).not.toHaveBeenCalled() + expect(deleteWorktreeHistoryDirMock).not.toHaveBeenCalled() + expect(closeLocalWatcherForWorktreePathMock).not.toHaveBeenCalled() + expect(await readFile(join(TEST_WORKTREE_PATH, 'scratch.txt'), 'utf8')).toBe('delete me') + expect(runtimeStore.getWorktreeMeta(TEST_WORKTREE_ID)).toBeDefined() + } finally { + teardown.mockRestore() + gitSpy.mockRestore() + await rm(TEST_WORKTREE_PATH, { recursive: true, force: true }) + } + }) +}) diff --git a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-03.spec.ts b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-03.spec.ts similarity index 66% rename from src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-03.spec.ts rename to src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-03.spec.ts index ae6898acc6e..1fc3783f7f3 100644 --- a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-03.spec.ts +++ b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-03.spec.ts @@ -1,31 +1,30 @@ -import * as gitExecFile from '../../git/command-runner/git-exec-file' -import { describe, expect, it, vi, type MockInstance } from 'vitest' +import * as gitExecFile from '../../../git/command-runner/git-exec-file' +import { describe, expect, it, vi } from 'vitest' import { readFile, lstat, mkdir, mkdtemp, rm, writeFile } from 'node:fs/promises' -import { _settlePendingWorktreeRemovalsForTests } from '../../workspaces/removal/worktree-background-removal' +import { _settlePendingWorktreeRemovalsForTests } from '../../../workspaces/removal/worktree-background-removal' -import './runtime-test-module-registration.spec' -import { assertWorktreeCleanForRemoval } from '../../git/worktrees/removal/worktree-removal-preflight' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { assertWorktreeCleanForRemoval } from '../../../git/worktrees/removal/worktree-removal-preflight' import { closeLocalWatcherForWorktreePathMock, deleteWorktreeHistoryDirMock, forceDeleteLocalBranchMock, invalidateAuthorizedRootsCacheMock -} from '../orca-runtime-test-mocks/setup.spec' +} from '../../orca-runtime-test-mocks/setup.spec' import { join } from 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' -import { runHook } from '../../workspace-hooks/hooks' +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' +import { runHook } from '../../../workspace-hooks/hooks' import { tmpdir } from 'node:os' import { TEST_REPO_ID, TEST_WORKTREE_ID, createStaleRuntimeWorktreeStore, - deferred, - store -} from './orca-runtime-test-fixtures.spec' -import { createWorktreeRemovalRuntime } from './orca-runtime-test-scenario-builders.spec' -import { hostWorktreeTarget } from '../../../shared/worktree/host-qualified-identity' + deferred +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createWorktreeRemovalRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' +import { hostWorktreeTarget } from '../../../../shared/worktree/host-qualified-identity' // Connected SSH fixtures need the host HOME for removal guards. @@ -44,94 +43,6 @@ describe('OrcaRuntimeService', () => { expect(forceDeleteLocalBranchMock).not.toHaveBeenCalled() }) - it('coalesces concurrent runtime worktree removals for the same worktree id', async () => { - const runtime = createWorktreeRemovalRuntime() - const removeStarted = deferred() - const finishRemoval = deferred() - vi.mocked(removeWorktree).mockImplementation(async () => { - removeStarted.resolve() - await finishRemoval.promise - return {} - }) - - const first = runtime.removeManagedWorktree(TEST_WORKTREE_ID, { force: true }) - const second = runtime.removeManagedWorktree(TEST_WORKTREE_ID, { force: true }) - - await removeStarted.promise - await Promise.resolve() - expect(removeWorktree).toHaveBeenCalledTimes(1) - - finishRemoval.resolve() - await expect(Promise.all([first, second])).resolves.toEqual([{}, {}]) - }) - - it('does not coalesce concurrent same-id removals on different hosts', async () => { - const baseRepo = store.getRepos()[0]! - // Migrated executionHostId must keep remote removal separate from the same-path local owner. - const remoteRepo = { ...baseRepo, path: '/remote/repo', executionHostId: 'ssh:host-b' } - const runtimeStore = { - ...store, - getRepos: () => [{ ...baseRepo, executionHostId: 'local' }, remoteRepo] - } - const runtime = createWorktreeRemovalRuntime(runtimeStore) - vi.spyOn(runtime, 'acquireFileWatcherRemoval').mockResolvedValue({ finish: vi.fn() }) - const localStarted = deferred() - const finishRemovals = deferred() - const startRemoval = async (): Promise> => { - localStarted.resolve() - await finishRemovals.promise - return {} - } - vi.mocked(removeWorktree).mockImplementation(startRemoval) - const local = runtime.removeManagedWorktree(TEST_WORKTREE_ID, { - force: true, - runHooks: false, - allowUnverifiedPtyStop: false, - hostId: 'local' - }) - const remote = runtime.removeManagedWorktree(TEST_WORKTREE_ID, { - force: true, - runHooks: false, - allowUnverifiedPtyStop: false, - hostId: 'ssh:host-b' - }) - - const remoteRefusal = expect(remote).rejects.toThrow('selector_not_found') - await localStarted.promise - await remoteRefusal - - finishRemovals.resolve() - await expect(local).resolves.toEqual({}) - expect(removeWorktree).toHaveBeenCalledTimes(1) - }) - - it('joins a runtime removal Git is already deleting, even with different options', async () => { - const runtime = createWorktreeRemovalRuntime() - const removeStarted = deferred() - const finishRemoval = deferred() - vi.mocked(removeWorktree).mockImplementation(async () => { - removeStarted.resolve() - await finishRemoval.promise - return {} - }) - - const resolveTarget: MockInstance<(...args: unknown[]) => Promise> = vi.spyOn( - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: resolveWorktreeRemovalTarget is a protected runtime method the spy only observes. - runtime as never, - 'resolveWorktreeRemovalTarget' - ) - const first = runtime.removeManagedWorktree(TEST_WORKTREE_ID) - - await removeStarted.promise - // Acceptance follows every refusal; a force retry has nothing left to waive. - const second = runtime.removeManagedWorktree(TEST_WORKTREE_ID, { force: true }) - await vi.waitFor(() => expect(resolveTarget).toHaveBeenCalledTimes(2)) - await resolveTarget.mock.results[1]?.value - finishRemoval.resolve() - await expect(Promise.all([first, second])).resolves.toEqual([{}, {}]) - expect(removeWorktree).toHaveBeenCalledTimes(1) - }) - it('answers a client that cannot wait as soon as Git starts deleting', async () => { const runtime = createWorktreeRemovalRuntime() const removeStarted = deferred() diff --git a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-04.spec.ts b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-04.spec.ts similarity index 86% rename from src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-04.spec.ts rename to src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-04.spec.ts index f97cd1e8e21..e01a6519e70 100644 --- a/src/main/runtime/orca-runtime-tests/worktree-removal-and-reconciliation-part-04.spec.ts +++ b/src/main/runtime/workspaces/removal/worktree-removal-and-reconciliation-part-04.spec.ts @@ -1,24 +1,24 @@ -import * as gitExecFile from '../../git/command-runner/git-exec-file' +import * as gitExecFile from '../../../git/command-runner/git-exec-file' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { MOCK_GIT_WORKTREES, restoreLocalWatcherAfterFailedRemovalMock, removeWorktreeLinkedPathsMock -} from '../orca-runtime-test-mocks/setup.spec' -import { assertWorktreeCleanForRemoval } from '../../git/worktrees/removal/worktree-removal-preflight' -import { getEffectiveHooks, runHook } from '../../workspace-hooks/hooks' +} from '../../orca-runtime-test-mocks/setup.spec' +import { assertWorktreeCleanForRemoval } from '../../../git/worktrees/removal/worktree-removal-preflight' +import { getEffectiveHooks, runHook } from '../../../workspace-hooks/hooks' import { join } from 'node:path' -import { listWorktrees } from '../../git/worktrees/catalog/worktree-scan-cache' -import { listWorktreesStrict } from '../../git/worktrees/catalog/worktree-listing' +import { listWorktrees } from '../../../git/worktrees/catalog/worktree-scan-cache' +import { listWorktreesStrict } from '../../../git/worktrees/catalog/worktree-listing' import { lstat, mkdir, mkdtemp, rm } from 'node:fs/promises' -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' import { tmpdir } from 'node:os' -import type { WorktreeMeta } from '../../../shared/worktree/meta-types' +import type { WorktreeMeta } from '../../../../shared/worktree/meta-types' import { hostWorktreeTarget, type HostWorktreeTarget -} from '../../../shared/worktree/host-qualified-identity' +} from '../../../../shared/worktree/host-qualified-identity' import { TEST_REPO_ID, TEST_WORKTREE_ID, @@ -26,8 +26,8 @@ import { makeWorktreeMeta, store, syncSinglePty -} from './orca-runtime-test-fixtures.spec' -import { createWorktreeRemovalRuntime } from './orca-runtime-test-scenario-builders.spec' +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createWorktreeRemovalRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' describe('OrcaRuntimeService', () => { it('does not inspect or delete a local path for an SSH runtime orphan this process does not serve', async () => { diff --git a/src/main/runtime/orca-runtime-tests/worktree-removal-failed-retry.spec.ts b/src/main/runtime/workspaces/removal/worktree-removal-failed-retry.spec.ts similarity index 84% rename from src/main/runtime/orca-runtime-tests/worktree-removal-failed-retry.spec.ts rename to src/main/runtime/workspaces/removal/worktree-removal-failed-retry.spec.ts index cae57710711..2087d2088b0 100644 --- a/src/main/runtime/orca-runtime-tests/worktree-removal-failed-retry.spec.ts +++ b/src/main/runtime/workspaces/removal/worktree-removal-failed-retry.spec.ts @@ -2,25 +2,28 @@ import 'node:fs' import { readFile, realpath, writeFile, mkdir, mkdtemp, rm } from 'node:fs/promises' import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' +import '../../construction/test-context/runtime-test-module-registration.spec' import { join } from 'node:path' -import '../../git/worktrees/catalog/worktree-listing' -import '../../workspaces/removal/local-worktree-filesystem' +import '../../../git/worktrees/catalog/worktree-listing' +import '../../../workspaces/removal/local-worktree-filesystem' -import { removeWorktree } from '../../git/worktrees/removal/worktree-removal' -import '../orca-runtime-test-mocks/setup.spec' +import { removeWorktree } from '../../../git/worktrees/removal/worktree-removal' +import '../../orca-runtime-test-mocks/setup.spec' import { tmpdir } from 'node:os' -import { TEST_REPO_ID, TEST_REPO_PATH } from './orca-runtime-test-fixtures.spec' -import { createWorktreeRemovalRuntime } from './orca-runtime-test-scenario-builders.spec' +import { + TEST_REPO_ID, + TEST_REPO_PATH +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import { createWorktreeRemovalRuntime } from '../../construction/test-context/orca-runtime-test-scenario-builders.spec' import { _resetPendingWorktreeRemovalsForTests, _settlePendingWorktreeRemovalsForTests, loadWorktreeRemovalRecords -} from '../../workspaces/removal/worktree-background-removal' +} from '../../../workspaces/removal/worktree-background-removal' import { readWorktreeRemovalRecords, writeWorktreeRemovalRecords -} from '../../workspaces/removal/worktree-removal-records' +} from '../../../workspaces/removal/worktree-removal-records' const FAILURE = "error: failed to delete 'node_modules/a/LICENSE': Operation not permitted" diff --git a/src/main/runtime/workspaces/session-hosts/folder-workspace-mixed-host-routing.test.ts b/src/main/runtime/workspaces/session-hosts/folder-workspace-mixed-host-routing.test.ts index deda2fc2943..263ec2d922d 100644 --- a/src/main/runtime/workspaces/session-hosts/folder-workspace-mixed-host-routing.test.ts +++ b/src/main/runtime/workspaces/session-hosts/folder-workspace-mixed-host-routing.test.ts @@ -14,11 +14,11 @@ import { } from '../../../../shared/workspace-layout/persistence/workspace-layout-session.test-fixture' import { OrcaRuntimeService } from '../../orca-runtime' import { WorkspaceLayoutStream } from '../../terminal/surface/workspace-layout-stream' -import '../../orca-runtime-tests/workspace-layout-stream-events.test-fixture' +import '../../terminal/surface/workspace-layout-stream-events.test-fixture' import { partialRuntimeStore, storeRepo -} from '../../orca-runtime-tests/runtime-store-partial-fixture' +} from '../../construction/test-context/runtime-store-partial-fixture' const mocks = vi.hoisted(() => ({ layoutOwnerIsMain: true })) vi.mock('../../../../shared/workspace-layout/layout-owner-switch', () => ({ diff --git a/src/main/runtime/workspaces/session-hosts/folder-workspace-pty-identity.test.ts b/src/main/runtime/workspaces/session-hosts/folder-workspace-pty-identity.test.ts index eba88f97b74..b1f4861ffef 100644 --- a/src/main/runtime/workspaces/session-hosts/folder-workspace-pty-identity.test.ts +++ b/src/main/runtime/workspaces/session-hosts/folder-workspace-pty-identity.test.ts @@ -1,4 +1,4 @@ -import { withDurableRuntimeStore } from '../../orca-runtime-tests/runtime-durable-store-fixture' +import { withDurableRuntimeStore } from '../../construction/test-context/runtime-durable-store-fixture' import { describe, expect, it } from 'vitest' import { spawnWorktreeTarget, diff --git a/src/main/runtime/workspaces/sleep/automatic-activation-host-sleep.test.ts b/src/main/runtime/workspaces/sleep/automatic-activation-host-sleep.test.ts index 772c0ad674b..e9afbd72085 100644 --- a/src/main/runtime/workspaces/sleep/automatic-activation-host-sleep.test.ts +++ b/src/main/runtime/workspaces/sleep/automatic-activation-host-sleep.test.ts @@ -4,15 +4,15 @@ import { spawnWorktreeTarget } from '../../../../shared/worktree/host-qualified- import type { RuntimeClientEvent } from '../../../../shared/remote-runtime/session-graph/runtime-client-events' // Preserve side-effect order: mocks, lifecycle, fixtures. -await import('../../orca-runtime-tests/runtime-test-module-registration.spec') +await import('../../construction/test-context/runtime-test-module-registration.spec') const { OrcaRuntimeService } = await import('../../orca-runtime') -await import('../../orca-runtime-tests/orca-runtime-test-lifecycle.spec') +await import('../../construction/test-context/orca-runtime-test-lifecycle.spec') const { TEST_WORKTREE_ID, deferred, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} = await import('../../orca-runtime-tests/orca-runtime-test-fixtures.spec') +} = await import('../../construction/test-context/orca-runtime-test-fixtures.spec') async function makeRuntime(listProcesses: () => Promise = async () => []) { const { runtimeStore } = makeRuntimeStoreWithWorkspaceSession( diff --git a/src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-03.spec.ts b/src/main/runtime/workspaces/startup/worktree-setup-and-startup-part-03.spec.ts similarity index 57% rename from src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-03.spec.ts rename to src/main/runtime/workspaces/startup/worktree-setup-and-startup-part-03.spec.ts index af041250707..7287f98bcc5 100644 --- a/src/main/runtime/orca-runtime-tests/worktree-setup-and-startup-part-03.spec.ts +++ b/src/main/runtime/workspaces/startup/worktree-setup-and-startup-part-03.spec.ts @@ -1,18 +1,21 @@ -import '../../../shared/orca-profiles/constants' +import '../../../../shared/orca-profiles/constants' import { describe, expect, it, vi } from 'vitest' -import './runtime-test-module-registration.spec' -import { OrcaRuntimeService } from '../orca-runtime' -import { addWorktree } from '../../git/worktrees/creation/worktree-add' -import '../orca-runtime-test-mocks/setup.spec' -import '../../workspace-hooks/worktree-runner-script' -import '../../workspace-hooks/effective-hook-config' -import '../../workspace-hooks/hooks' -import '../../git/worktrees/catalog/worktree-scan-cache' +import '../../construction/test-context/runtime-test-module-registration.spec' +import { OrcaRuntimeService } from '../../orca-runtime' +import { addWorktree } from '../../../git/worktrees/creation/worktree-add' +import '../../orca-runtime-test-mocks/setup.spec' +import '../../../workspace-hooks/worktree-runner-script' +import '../../../workspace-hooks/effective-hook-config' +import '../../../workspace-hooks/hooks' +import '../../../git/worktrees/catalog/worktree-scan-cache' -import { TEST_REPO_ID, store } from './orca-runtime-test-fixtures.spec' -import '../terminal/launch/spawned-pty-env-fixtures' +import { + TEST_REPO_ID, + store +} from '../../construction/test-context/orca-runtime-test-fixtures.spec' +import '../../terminal/launch/spawned-pty-env-fixtures' -import '../../../shared/workspace-layout/layout-owner-switch' +import '../../../../shared/workspace-layout/layout-owner-switch' describe('OrcaRuntimeService', () => { it('rejects explicit startup commands for disabled selected agents', async () => { diff --git a/tests/e2e/cross-version-wire/agent-launch-reserved-session-id.unit.test.ts b/tests/e2e/cross-version-wire/agent-launch-reserved-session-id.unit.test.ts deleted file mode 100644 index 016752e61ba..00000000000 --- a/tests/e2e/cross-version-wire/agent-launch-reserved-session-id.unit.test.ts +++ /dev/null @@ -1,88 +0,0 @@ -import { describe, expect, it } from 'vitest' -import { AgentLaunchReplay } from '../../../src/shared/rpc-contract/agent-launch/agent-launch-params' -import { AGENT_LAUNCH_PLAIN_SESSION_ID_RUNTIME_CAPABILITY } from '../../../src/shared/agent-launch/contracts/agent-launch-runtime-capability' -import { agentLaunchExistingParams } from '../../../mobile/src/session/agent-launch/agent-launch-request' -import { - reserveMobileAgentLaunch, - reservedAgentLaunchFields -} from '../../../mobile/src/session/agent-launch/mobile-agent-launch-reservation' -import { - importReleaseCheckoutModule, - materializeReleaseCheckout, - releaseModuleExport -} from './release-checkout' - -// A phone reserves its new chat's id on agent.launchReplay; a shipped host must still admit it. -const SUITE_TIMEOUT_MS = 180_000 -// Move this baseline only when that host falls out of support. -const BEFORE_PLAIN_SESSION_ID_REF = 'v1.4.259' -const LAUNCH_PARAMS = 'src/shared/rpc-contract/agent-launch/agent-launch-params.ts' -// A shipped host's launch capabilities, without the plain-session-id one. -const SHIPPED_HOST_CAPABILITIES = ['agent.launch.v2', 'agent.launch.replay-required.v1'] -const OPERATION_ID = '1767225600000-00000000000040008000000000000002' - -type Schema = { safeParse: (value: unknown) => { success: boolean } } - -function fixedUuids(): () => string { - const uuids = [ - '11111111-1111-4111-8111-111111111111', - '22222222-2222-4222-8222-222222222222', - '33333333-3333-4333-8333-333333333333' - ] - return () => uuids.shift()! -} - -describe('a reserved chat id on agent.launchReplay, across versions', () => { - // Cold baseline release materialization and import can take minutes. - it( - 'new phone against the shipped host: the host admits the phone’s reservation', - async () => { - const checkout = await materializeReleaseCheckout(BEFORE_PLAIN_SESSION_ID_REF) - const shipped = releaseModuleExport( - await importReleaseCheckoutModule(checkout, LAUNCH_PARAMS), - 'AgentLaunchReplay' - ) - const reservation = reserveMobileAgentLaunch( - 'claude', - SHIPPED_HOST_CAPABILITIES, - fixedUuids() - ) - const params = agentLaunchExistingParams({ - agent: 'claude', - worktreeId: 'workspace-1', - operationId: OPERATION_ID, - ...reservedAgentLaunchFields(reservation) - }) - expect(params).toHaveProperty('sessionId') - expect(shipped.safeParse(params).success).toBe(true) - }, - SUITE_TIMEOUT_MS - ) - - it('the current host admits a plain reserved id', () => { - const params = { - agent: 'claude', - operationId: OPERATION_ID, - target: { kind: 'existing', worktree: 'id:workspace-1' }, - paneKey: '11111111-1111-4111-8111-111111111111:22222222-2222-4222-8222-222222222222', - sessionId: '3540ecf3-47c3-4876-b825-81bf5d6b3595' - } - expect(AgentLaunchReplay.safeParse(params).success).toBe(true) - }) - - it('the phone reserves a plain id when the host advertises support', () => { - const reservation = reserveMobileAgentLaunch( - 'claude', - [AGENT_LAUNCH_PLAIN_SESSION_ID_RUNTIME_CAPABILITY], - fixedUuids() - ) - const params = agentLaunchExistingParams({ - agent: 'claude', - worktreeId: 'workspace-1', - operationId: OPERATION_ID, - ...reservedAgentLaunchFields(reservation) - }) - expect(params.sessionId).toBe('33333333-3333-4333-8333-333333333333') - expect(AgentLaunchReplay.safeParse(params).success).toBe(true) - }) -}) diff --git a/tests/e2e/cross-version-wire/agent-session-clear-old-tab-mirror.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-clear-old-tab-mirror.unit.test.ts deleted file mode 100644 index f5453ff94bb..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-clear-old-tab-mirror.unit.test.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { describe, expect, it, vi } from 'vitest' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' -import { - HOST_TEST_SESSION, - HOST_TEST_NOW -} from '../../../src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-host-test-data.test-fixture' -import { - WORKTREE, - createChat, - clear, - snapshot -} from '../../../src/main/runtime/rpc/methods/session-tabs/structured-chat-tab-table.test-fixture' - -describe('historical clients after a clear', () => { - it.each(['v1.4.222', 'b6b4d68cd844c921c7c5191cef72d5adafc0dafa'])( - '%s mirrors the actual published tab without changing pane or conversation identity', - async (ref) => { - const checkout = await materializeReleaseCheckout(ref) - vi.doMock(`${checkout.root}/src/renderer/src/runtime/web-runtime-session.ts`, () => ({ - HOST_TERMINAL_SURFACE_SEPARATOR: '::', - WEB_TERMINAL_SURFACE_TAB_PREFIX: 'web-terminal:', - toWebTerminalSurfaceTabId: (id: string) => id - })) - vi.doMock(`${checkout.root}/src/renderer/src/runtime/runtime-terminal-stream.ts`, () => ({ - getRemoteRuntimePtyEnvironmentId: () => null - })) - const module = await importReleaseCheckoutModule( - checkout, - 'src/renderer/src/runtime/web-session-tabs-sync/terminal-surfaces.ts' - ) - const build = module.buildMirroredAgentTabs - if (typeof build !== 'function') { - throw new Error('historical agent tab mirror missing') - } - expect(await createChat(HOST_TEST_SESSION)).toMatchObject({ ok: true }) - const localTabs = [ - { - id: 'existing-local-pane', - entityId: HOST_TEST_SESSION, - contentType: 'agent-session', - agentSessionAgent: 'codex', - worktreeId: WORKTREE, - groupId: 'existing-local-group', - label: 'Codex Chat', - customLabel: 'My conversation', - color: null, - createdAt: HOST_TEST_NOW, - sortOrder: 0, - isPinned: true - } - ] - const mirror = async () => - build(await snapshot(), 'remote-host', new Map(), 'fallback', 0, localTabs, HOST_TEST_NOW) - const before = await mirror() - await clear(HOST_TEST_SESSION) - expect(await mirror()).toEqual(before) - expect(await mirror()).toMatchObject([ - { - hostTabId: `agent-session:${HOST_TEST_SESSION}`, - unifiedTab: { - id: 'existing-local-pane', - entityId: HOST_TEST_SESSION, - groupId: 'existing-local-group', - customLabel: 'My conversation', - isPinned: true - } - } - ]) - }, - 300_000 - ) -}) diff --git a/tests/e2e/cross-version-wire/agent-session-cli-missing-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-cli-missing-downgrade.unit.test.ts deleted file mode 100644 index 97481c8abd4..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-cli-missing-downgrade.unit.test.ts +++ /dev/null @@ -1,39 +0,0 @@ -import { expect, test } from 'vitest' -import { agentSessionFailureWords } from '../../../src/shared/agent-session/failures/agent-session-failure-words' -import { agentSessionFailureFact } from '../../../src/shared/agent-session/failures/agent-session-failure' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' - -// Pin a release predating cliMissing so unknown failure kinds must fall back to the host’s own sentence. -const BASELINE_REF = 'v1.4.218' - -type OldStatusBlock = (body: Record) => { text: string; failure?: unknown } - -// Loads a real old build, including cold extraction and transforms. -test("an older client shows this host's sentence for a start whose CLI was not found", async () => { - const words = agentSessionFailureWords(agentSessionFailureFact('cliMissing'), { - agentName: 'Codex', - surface: 'row' - }) - expect(words).toEqual({ - text: "Codex wasn't found on the computer running this chat. Install it, or check its Command in Settings → Agents.", - failure: { kind: 'cliMissing' } - }) - - const checkout = await materializeReleaseCheckout(BASELINE_REF) - const [failure, statusBlock] = await Promise.all( - [ - 'src/shared/agent-session-failure.ts', - 'src/shared/structured-agent-session-status-block.ts' - ].map((path) => importReleaseCheckoutModule(checkout, path)) - ) - const isKind = failure.isAgentSessionFailureKind - const render = statusBlock.structuredAgentSessionStatusBlock - if (typeof isKind !== 'function' || typeof render !== 'function') { - throw new Error('the pinned release lacks the failure-kind reader or the status block') - } - expect(isKind('cliMissing')).toBe(false) - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: the pinned release's export, checked to be a function above; a changed shape fails the assertions below. - const block = (render as OldStatusBlock)({ kind: 'status', tone: 'error', ...words }) - expect(block.text).toBe(words.text) - expect(block).not.toHaveProperty('failure') -}, 120_000) diff --git a/tests/e2e/cross-version-wire/agent-session-handle-replacement-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-handle-replacement-downgrade.unit.test.ts deleted file mode 100644 index 44cdcc937d5..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-handle-replacement-downgrade.unit.test.ts +++ /dev/null @@ -1,231 +0,0 @@ -import { expect, test } from 'vitest' -import Database from '../../../src/main/sqlite/sync-database' -import { - agentSessionProviderHandleKey, - claudeProviderHandle, - codexProviderHandle -} from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import { - decodePersistedAgentSessionProviderHandleChain, - encodePersistedAgentSessionProviderHandleChain, - type AgentSessionProviderHandle, - type AgentSessionProviderHandleLink -} from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle' -import { - agentSessionLeaseFixture, - agentSessionRecordFixture -} from '../../../src/shared/agent-session/lifecycle/records/agent-session-record.test-fixture' -import { encodeAgentSessionRecord } from '../../../src/shared/agent-session/lifecycle/records/agent-session-record-stored-form' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' - -// A release before neutral handles: handles stored and held in their typed form. -const RELEASE_REF = 'v1.4.220' -// The main build that made handles neutral; no release has it yet. Move to the first that does. -const NEUTRAL_HANDLE_REF = 'e817b0e23747ffd6f16f2ddefea861950d82a3c0' - -const acp = (nativeId: string): AgentSessionProviderHandle => ({ - transport: 'acp', - agent: 'grok', - nativeId -}) - -function link( - linkId: string, - nativeId: string, - fence: number, - extra: Partial = {} -): AgentSessionProviderHandleLink { - return { - linkId, - handle: acp(nativeId), - origin: 'created', - mintedAtFence: fence, - observedAt: fence * 1_000, - ...extra - } -} - -/** The row a build that runs another agent's chats writes: its provider and handles are neutral. */ -function neutralRow(chain: AgentSessionProviderHandleLink[]): unknown { - const head = chain.at(-1) - const fixture = agentSessionRecordFixture( - agentSessionLeaseFixture({ - provenHandleLinkId: head?.linkId, - runtimeFence: head?.mintedAtFence - }) - ) - return JSON.parse( - JSON.stringify({ - ...fixture, - // Historical leases keep the checkpoint so old readers reach handle validation. - lease: { ...fixture.lease, journalCheckpoint: null }, - provider: 'grok', - accountHome: { variable: 'GROK_HOME', path: '/home/user/.grok' }, - providerHandleChain: encodePersistedAgentSessionProviderHandleChain(chain) - }) - ) -} - -const REOPENED = [link('l1', 's-1', 1), link('l2', 's-1', 2, { origin: 'resumed' })] -const REPLACED = [ - ...REOPENED, - link('l3', 's-2', 3, { - replaces: { - key: agentSessionProviderHandleKey(acp('s-1')), - reason: 'restore-failed', - replacedAt: 3_000 - } - }) -] - -type OldStoreMaps = { - records: Map - unreadableRecords: Map -} - -function hasStoreMaps(value: unknown): value is OldStoreMaps { - return ( - typeof value === 'object' && - value !== null && - 'records' in value && - value.records instanceof Map && - 'unreadableRecords' in value && - value.unreadableRecords instanceof Map - ) -} - -function storeMaps(value: unknown): OldStoreMaps { - if (!hasStoreMaps(value)) { - throw new Error('old store must expose its readable and unreadable rows') - } - return value -} - -function legacyRow(provider: 'claude' | 'codex') { - const fixture = agentSessionRecordFixture( - agentSessionLeaseFixture({ sessionId: `chat-${provider}` }) - ) - const stored = encodeAgentSessionRecord({ - ...fixture, - provider, - accountHome: - provider === 'claude' - ? fixture.accountHome - : { variable: 'CODEX_HOME', path: '/home/user/.codex' }, - providerHandleChain: [ - { - ...fixture.providerHandleChain[0], - handle: - provider === 'claude' - ? claudeProviderHandle('saved-claude', 'leaf-1') - : codexProviderHandle('saved-codex') - } - ] - }) - // Use the same historical lease format as the neutral rows above. - return { ...stored, lease: { ...stored.lease, journalCheckpoint: null } } -} - -// Older readers refuse replacement handles except in rows they already set aside; Claude/Codex chains remain closed. -test.each([RELEASE_REF, NEUTRAL_HANDLE_REF])( - '%s preserves legacy rows and sets aside a replaced neutral row verbatim until re-upgrade', - async (ref) => { - const checkout = await materializeReleaseCheckout(ref) - const records = await importReleaseCheckoutModule( - checkout, - 'src/shared/agent-session-record.ts' - ) - const isRecord = records.isPersistedAgentSessionRecord - if (typeof isRecord !== 'function') { - throw new Error(`${ref} exports no isPersistedAgentSessionRecord`) - } - expect(isRecord(neutralRow(REOPENED))).toBe(false) - expect(isRecord(neutralRow(REPLACED))).toBe(false) - - const [rowModule, draftModule] = await Promise.all([ - importReleaseCheckoutModule(checkout, 'src/main/runtime/agent-session-record-rows.ts'), - importReleaseCheckoutModule(checkout, 'src/main/runtime/agent-session-store-draft.ts') - ]) - const loadRows = rowModule.loadAgentSessionStoreRows - const writeRows = rowModule.writeAgentSessionStoreRows - const draftState = draftModule.draftAgentSessionStoreState - const rowWrites = draftModule.agentSessionStoreDraftRowWrites - if ( - typeof loadRows !== 'function' || - typeof writeRows !== 'function' || - typeof draftState !== 'function' || - typeof rowWrites !== 'function' - ) { - throw new Error(`${ref} must expose the row load and write path`) - } - const db = new Database(':memory:') - try { - db.exec(` - CREATE TABLE agent_session_records (session_id TEXT PRIMARY KEY, record_json TEXT); - CREATE TABLE agent_session_operations (operation_key TEXT PRIMARY KEY, row_json TEXT); - CREATE TABLE agent_session_retired_claim_keys (key_id TEXT PRIMARY KEY, retired_at INTEGER); - CREATE TABLE agent_session_tabs (tab_id TEXT PRIMARY KEY, session_id TEXT, position INTEGER); - CREATE TABLE agent_session_store_meta (key TEXT PRIMARY KEY, value TEXT); - `) - const insert = db.prepare('INSERT INTO agent_session_records VALUES (?, ?)') - const legacyRows = [legacyRow('claude'), legacyRow('codex')] - for (const row of legacyRows) { - expect(isRecord(row)).toBe(true) - insert.run(row.sessionId, JSON.stringify(row)) - } - // Whitespace proves preservation of the stored bytes, not just the parsed value. - const neutralJson = JSON.stringify(neutralRow(REPLACED), null, 2) - insert.run('session-alpha-1', neutralJson) - const loaded = storeMaps(loadRows(db, 'local')) - expect([...loaded.records.keys()]).toEqual(['chat-claude', 'chat-codex']) - expect(loaded.unreadableRecords.get('session-alpha-1')).toEqual({ - reason: 'current_shape_invalid', - raw: JSON.parse(neutralJson) - }) - const draft = storeMaps(draftState(loaded)) - for (const row of legacyRows) { - const record: unknown = loaded.records.get(row.sessionId) - if (typeof record !== 'object' || record === null || !('lease' in record)) { - throw new Error(`${ref} must read the legacy row`) - } - const lease = record.lease - if (typeof lease !== 'object' || lease === null) { - throw new Error(`${ref} must preserve the legacy lease`) - } - // Re-derive the owner after load, forcing the old build's actual serialization path. - draft.records.set(row.sessionId, { ...record, lease: { ...lease, unreconciled: false } }) - } - const writes: unknown = rowWrites(loaded, draft) - expect(writes).not.toBeNull() - writeRows(db, writes) - for (const row of legacyRows) { - expect( - db - .prepare('SELECT record_json FROM agent_session_records WHERE session_id = ?') - .get(row.sessionId)?.record_json - ).toBe(JSON.stringify(row)) - } - const preserved = db - .prepare('SELECT record_json FROM agent_session_records WHERE session_id = ?') - .get('session-alpha-1')?.record_json - expect(preserved).toBe(neutralJson) - if (typeof preserved !== 'string') { - throw new Error('the neutral row must survive the old build') - } - const upgraded: unknown = JSON.parse(preserved) - if ( - typeof upgraded !== 'object' || - upgraded === null || - !('providerHandleChain' in upgraded) - ) { - throw new Error('the preserved row must still contain its chain') - } - expect(decodePersistedAgentSessionProviderHandleChain(upgraded.providerHandleChain)).toEqual( - REPLACED - ) - } finally { - db.close() - } - }, - 300_000 -) diff --git a/tests/e2e/cross-version-wire/agent-session-interrupted-tool-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-interrupted-tool-downgrade.unit.test.ts deleted file mode 100644 index c4dfafed051..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-interrupted-tool-downgrade.unit.test.ts +++ /dev/null @@ -1,116 +0,0 @@ -import { mkdtempSync, rmSync } from 'node:fs' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { expect, test } from 'vitest' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import { - endedRunningAgentJournalToolCall, - interruptedAgentJournalToolCall -} from '../../../src/shared/agent-session/journal/agent-journal-tool-call-lifecycle' -import type { AgentJournalItemIdentity } from '../../../src/shared/agent-session/journal/agent-session-journal-identity' -import { createTrackedJournalOpener } from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { readTestJournalItems } from '../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' -import { - importReleaseCheckoutModule, - materializeReleaseCheckout, - releaseModuleExport -} from './release-checkout' -import { prepareReleaseFixtures } from './release-fixture-setup' - -// Pin a release predating endedAs to prove cut-short tool calls still read as failed. -const BASELINE_REF = 'v1.4.218' -const releaseToolModules = prepareReleaseFixtures([BASELINE_REF], async (ref) => { - const checkout = await materializeReleaseCheckout(ref) - return Promise.all( - [ - 'src/shared/agent-session-journal-schemas.ts', - 'src/shared/structured-agent-session-projection.ts', - 'src/shared/native-chat-tool-run-outcome.ts' - ].map((path) => importReleaseCheckoutModule(checkout, path)) - ) -}) - -const SESSION = 'session-interrupted-tool' - -function call(ordinal: number): AgentJournalItemIdentity { - return { provider: 'codex', threadId: 'thread-1', turnId: 'turn-1', ordinal } -} - -type OldRenderItem = { itemId: string; body: { kind: string; [field: string]: unknown } } -type OldMessage = { blocks: unknown[] } | null -type OldRunOutcome = ( - blocks: readonly unknown[], - options: { activeTurnIsWorking?: boolean } -) => { failedCallCount: number; succeeded: boolean } - -// Loads a real old build, including cold extraction and transforms. -test('an older client reads a call a stop cut short as the failure they always showed', async () => { - const directory = mkdtempSync(join(tmpdir(), 'orca-interrupted-tool-downgrade-')) - const journals = createTrackedJournalOpener() - try { - // This build: a call a stop cut short, with the partial output it left. - const journal = await journals.open({ - identity: { - sessionId: SESSION, - workspaceId: 'ws-1', - hostId: 'host-1', - agent: 'codex', - providerHandle: codexProviderHandle('thread-1') - }, - stateDirectory: directory, - now: () => 1_000 - }) - const cutShort = interruptedAgentJournalToolCall({ - kind: 'tool-call', - name: 'shell', - input: { command: 'sleep 20' }, - state: 'running', - output: { head: 'partial', byteLength: 7, digest: 'd', truncated: false } - }) - await journal.appendItem(call(0), cutShort, { fence: 1, turnScope: { kind: 'thread' } }) - // And one an end nothing proved closed, kept so a later proof can still correct it. - const unverified = endedRunningAgentJournalToolCall( - { kind: 'tool-call', name: 'shell', input: { command: 'sleep 30' }, state: 'running' }, - 'unverifiable' - ) - await journal.appendItem(call(1), unverified, { fence: 1, turnScope: { kind: 'thread' } }) - const current = await readTestJournalItems(journal) - expect(current.map((item) => item.body)).toMatchObject([ - { state: 'failed', endedAs: 'interrupted' }, - { state: 'failed', endedAs: 'unverifiable' } - ]) - - const [schemas, projection, outcome] = releaseToolModules(BASELINE_REF) - const renderItemSchema = releaseModuleExport<{ parse: (value: unknown) => OldRenderItem }>( - schemas, - 'AgentJournalRenderItemSchema' - ) - const project = releaseModuleExport<(item: unknown) => OldMessage>( - projection, - 'projectStructuredItemToNativeChat' - ) - const runOutcome = releaseModuleExport(outcome, 'nativeChatToolRunOutcome') - const settled = { activeTurnIsWorking: false } - - const blocksOf = (items: OldRenderItem[]) => - items.flatMap((item) => project(item)?.blocks ?? []) - - // The older client reads this host's render items, as sent on the wire, as failed calls. - const read = current.map((item) => renderItemSchema.parse(JSON.parse(JSON.stringify(item)))) - expect(runOutcome(blocksOf(read), settled)).toEqual({ - failedCallCount: 2, - succeeded: false - }) - - // Why the fact rides beside `failed` rather than replacing it: that build calls an unknown - // state a success. - const asNewState = renderItemSchema.parse({ - ...current[0], - body: { ...cutShort, state: 'interrupted', endedAs: undefined } - }) - expect(runOutcome(project(asNewState)?.blocks ?? [], settled).succeeded).toBe(true) - } finally { - await journals.closeAll() - rmSync(directory, { recursive: true, force: true }) - } -}) diff --git a/tests/e2e/cross-version-wire/agent-session-kill-delivered-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-kill-delivered-downgrade.unit.test.ts deleted file mode 100644 index b940513e2e7..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-kill-delivered-downgrade.unit.test.ts +++ /dev/null @@ -1,206 +0,0 @@ -import { mkdtemp, rm } from 'node:fs/promises' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { expect, test } from 'vitest' -import { agentSessionConversationView } from '../../../src/shared/agent-session/lifecycle/leases/agent-session-conversation-view' -import { - agentSessionLeaseOwnerVerdict, - agentSessionLeasePossiblyWriting -} from '../../../src/shared/agent-session/lifecycle/leases/agent-session-lease-adjudication' -import { agentSessionRecordFixture } from '../../../src/shared/agent-session/lifecycle/records/agent-session-record.test-fixture' -import { agentModelCatalogReleasedOwner } from '../../../src/main/native-chat/agent-model-catalog/agent-model-catalog-snapshot' -import { - closeTestJournalHostDatabase, - openTestJournalHostDatabase -} from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { upgradeStoredStructuredAgentSessionOwnerExitEvidence } from '../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-lease-release' -import { turnVerdictFromDeathEvidence } from '../../../src/main/native-chat/agent-session-wire/termination/structured-agent-session-stale-turn-verdict' -import { releaseStoredAgentSessionOwnerAfterSurfaceClose } from '../../../src/main/runtime/agent-session/ownership/agent-session-surface-release-transition' -import { - closeTestAgentSessionDatabase, - openTestAgentSessionRecordStore -} from '../../../src/main/runtime/agent-session/records/agent-session-record-store-test-harness' -import { - seedTestAgentSessionRecordStore, - storedTestAgentSessionRecord -} from '../../../src/main/runtime/agent-session/records/agent-session-record-store-persistence.test-fixture' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' - -// The last release before Stop recorded a delivered kill. -const RELEASE_REF = 'v1.4.244' - -type OldStoreMaps = { - records: Map - unreadableRecords: Map -} - -function exported(module: Record, name: string): (...args: unknown[]) => unknown { - const value = module[name] - if (typeof value !== 'function') { - throw new Error(`${RELEASE_REF} exports no ${name}`) - } - return (...args) => value(...args) -} - -function storeMaps(value: unknown): OldStoreMaps { - if ( - typeof value !== 'object' || - value === null || - !('records' in value) || - !(value.records instanceof Map) || - !('unreadableRecords' in value) || - !(value.unreadableRecords instanceof Map) - ) { - throw new Error(`${RELEASE_REF} store must expose its readable and unreadable rows`) - } - return { records: value.records, unreadableRecords: value.unreadableRecords } -} - -function oldRecord(value: unknown) { - if ( - typeof value !== 'object' || - value === null || - !('lease' in value) || - typeof value.lease !== 'object' || - value.lease === null || - !('deathEvidence' in value.lease) - ) { - throw new Error('the old build must expose the chat and its lease') - } - return { ...value, lease: value.lease } -} - -// Materializing the historical source checkout and importing its modules can exceed the default timeout. -// Conversion is one-way: a downgraded build keeps the records as converted, and what it writes -// later is not carried forward, so the upgraded store keeps this build's records. -test(`${RELEASE_REF} keeps the converted records readable and writable; the upgraded store keeps this build's stopped chat`, async () => { - const directory = await mkdtemp(join(tmpdir(), 'orca-kill-downgrade-')) - try { - const live = agentSessionRecordFixture() - const sessionId = live.sessionId - // The chat as an older build saved it, before this build first converts the store. - const legacy = openTestJournalHostDatabase(directory).db - legacy - .prepare('INSERT INTO agent_session_records (session_id, record_json) VALUES (?, ?)') - .run(sessionId, JSON.stringify(storedTestAgentSessionRecord(live))) - const converted = String( - legacy - .prepare('SELECT record_json FROM agent_session_records WHERE session_id = ?') - .get(sessionId)?.record_json - ) - - await closeTestJournalHostDatabase(directory) - await openTestAgentSessionRecordStore(directory) - // Admit this fixture's live owner after installation invalidates previously saved authority. - await seedTestAgentSessionRecordStore(directory, { records: [live] }) - const current = await openTestAgentSessionRecordStore(directory, { mode: 'observe' }) - expect(current.getRecord(sessionId)?.lease.runtimeFence).toBe(7) - await releaseStoredAgentSessionOwnerAfterSurfaceClose(current, { - sessionId, - expectedFence: 7, - now: 40_000, - deathEvidenceKind: 'kill-delivered', - exitReason: 'killed' - }) - const stopped = current.getRecord(sessionId) - expect(stopped?.lease.deathEvidence).toEqual({ - kind: 'kill-delivered', - detail: 'killed', - observedAt: 40_000, - ownerFence: 7 - }) - await closeTestAgentSessionDatabase(directory) - - const checkout = await materializeReleaseCheckout(RELEASE_REF) - const [rows, drafts, restart] = await Promise.all([ - importReleaseCheckoutModule(checkout, 'src/main/runtime/agent-session-record-rows.ts'), - importReleaseCheckoutModule(checkout, 'src/main/runtime/agent-session-store-draft.ts'), - importReleaseCheckoutModule( - checkout, - 'src/main/runtime/agent-session/ownership/agent-session-restart-lease-transitions.ts' - ) - ]) - // The older build reads the records as converted, without this build's Stop. - const db = openTestJournalHostDatabase(directory).db - expect( - db - .prepare('SELECT record_json FROM agent_session_records WHERE session_id = ?') - .get(sessionId)?.record_json - ).toBe(converted) - const loaded = storeMaps(exported(rows, 'loadAgentSessionStoreRows')(db)) - expect(loaded.unreadableRecords.size).toBe(0) - const old = oldRecord(loaded.records.get(sessionId)) - expect(old.lease).toMatchObject({ runtimeFence: 7, deathEvidence: null }) - // It writes its own restart reconciliation over them. - const reconciled = oldRecord( - exported( - restart, - 'applyAgentSessionRestartAdjudication' - )({ - record: old, - probe: { outcome: 'pid-absent' }, - now: 50_000 - }) - ) - const before = exported(rows, 'loadAgentSessionStoreRows')(db) - const draft = exported(drafts, 'draftAgentSessionStoreState')(before) - storeMaps(draft).records.set(sessionId, reconciled) - exported(rows, 'writeAgentSessionStoreRows')( - db, - exported(drafts, 'agentSessionStoreDraftRowWrites')(before, draft) - ) - // Its loader holds every loaded lease unreconciled until that host proves ownership again. - expect( - oldRecord(storeMaps(exported(rows, 'loadAgentSessionStoreRows')(db)).records.get(sessionId)) - ).toEqual({ ...reconciled, lease: { ...reconciled.lease, unreconciled: true } }) - expect( - db - .prepare('SELECT record_json FROM agent_session_records WHERE session_id = ?') - .get(sessionId)?.record_json - ).not.toBe(converted) - await closeTestJournalHostDatabase(directory) - - // Upgraded again over the older build's newer records: this build's stopped chat, unchanged. - const upgraded = await openTestAgentSessionRecordStore(directory) - const restored = upgraded.getRecord(sessionId) - if (!restored) { - throw new Error('the upgraded chat must remain readable') - } - // Opening the store is a restart: loaded leases stay unreconciled until ownership is proved. - expect(restored).toEqual({ ...stopped, lease: { ...stopped?.lease, unreconciled: true } }) - const conversation = agentSessionConversationView(restored) - expect(agentSessionLeaseOwnerVerdict(restored.lease)).toBe('exited') - expect(agentSessionLeasePossiblyWriting(restored.lease)).toBe(false) - expect(agentModelCatalogReleasedOwner(conversation)).toBe(true) - expect(turnVerdictFromDeathEvidence(restored.lease.deathEvidence, 7)).toMatchObject({ - state: 'interrupted' - }) - await upgraded.reconcileOnRestart({ - sessionId, - probe: async () => ({ outcome: 'exit-observed' }), - now: 60_000 - }) - await upgradeStoredStructuredAgentSessionOwnerExitEvidence( - upgraded, - { - type: 'ended', - sessionId, - fence: 7, - acquisitionGeneration: 'stopped-writer', - cause: 'requested-close', - reason: 'late exit', - observedAt: 60_000 - }, - 61_000 - ) - expect(upgraded.getRecord(sessionId)?.lease.deathEvidence).toMatchObject({ - kind: 'exit-observed', - detail: 'killed', - observedAt: 60_000, - ownerFence: 7 - }) - } finally { - await closeTestJournalHostDatabase(directory) - await rm(directory, { recursive: true, force: true }) - } -}, 300_000) diff --git a/tests/e2e/cross-version-wire/agent-session-resume-marker-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-session-resume-marker-downgrade.unit.test.ts deleted file mode 100644 index aa9c8ff5995..00000000000 --- a/tests/e2e/cross-version-wire/agent-session-resume-marker-downgrade.unit.test.ts +++ /dev/null @@ -1,76 +0,0 @@ -import { mkdtempSync, rmSync } from 'node:fs' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { expect, test } from 'vitest' -import { AGENT_JOURNAL_THREAD_SCOPE } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import { createTrackedJournalOpener } from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { structuredAgentSessionWorkingAtStop } from '../../../src/main/native-chat/agent-session-wire/termination/structured-agent-session-working-at-teardown' -import { - NOW, - record, - SESSION, - TEARDOWN_CURRENT, - THREAD -} from '../../../src/main/native-chat/agent-session-wire/recovery/testing/structured-agent-session-restart-resume.test-fixture' -import { AgentSessionRecoveryCapsule } from '../../../src/main/runtime/agent-session/records/agent-session-recovery-capsule' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' -import { prepareReleaseFixtures } from './release-fixture-setup' - -// A release whose marker parser still requires the chat's newest message id. -const BASELINE_REF = 'v1.4.211' -const releaseCapsule = prepareReleaseFixtures([BASELINE_REF], async (ref) => - importReleaseCheckoutModule( - await materializeReleaseCheckout(ref), - 'src/main/runtime/agent-session-recovery-capsule.ts' - ) -) - -test('an older build reads the restart offer this build records at quit', async () => { - const directory = mkdtempSync(join(tmpdir(), 'orca-resume-marker-downgrade-')) - const journals = createTrackedJournalOpener() - try { - // This build: the offer teardown takes for a chat whose turn was running. - const journal = await journals.open({ - identity: { - sessionId: SESSION, - workspaceId: 'workspace-1', - hostId: 'local', - agent: 'codex', - providerHandle: codexProviderHandle(THREAD) - }, - stateDirectory: directory, - now: () => NOW - }) - await journal.appendItem( - { provider: 'codex', threadId: THREAD, turnId: 'turn-1', ordinal: 0 }, - { kind: 'turn', turnId: 'turn-1', state: 'running', startedAt: NOW }, - { fence: 1, turnScope: AGENT_JOURNAL_THREAD_SCOPE } - ) - const marker = await structuredAgentSessionWorkingAtStop({ - sessionId: SESSION, - session: { journal, child: { fence: 1, phase: 'ready' } }, - getRecord: () => record(), - childWork: () => undefined, - childWorkOpen: () => false, - trigger: 'quit', - teardownId: TEARDOWN_CURRENT, - now: NOW - }) - if (!marker) { - throw new Error('this build recorded no offer for a running turn') - } - await new AgentSessionRecoveryCapsule(directory).record([marker], NOW) - - // The older build, after a downgrade, still lists it. - const baseline = releaseCapsule(BASELINE_REF) - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: the pinned release exports this class with the constructor and `list` called below; a missing one fails the test. - const OldCapsule = baseline.AgentSessionRecoveryCapsule as new (directory: string) => { - list: (now: number) => Promise<{ sessionId: string }[]> - } - expect(await new OldCapsule(directory).list(NOW)).toMatchObject([{ sessionId: SESSION }]) - } finally { - await journals.closeAll() - rmSync(directory, { recursive: true, force: true }) - } -}) diff --git a/tests/e2e/cross-version-wire/agent-session-newer-chat-refusal.unit.test.ts b/tests/e2e/cross-version-wire/agent-sessions/agent-session-newer-chat-refusal.unit.test.ts similarity index 63% rename from tests/e2e/cross-version-wire/agent-session-newer-chat-refusal.unit.test.ts rename to tests/e2e/cross-version-wire/agent-sessions/agent-session-newer-chat-refusal.unit.test.ts index 2cf6efaf238..b80b42cf06c 100644 --- a/tests/e2e/cross-version-wire/agent-session-newer-chat-refusal.unit.test.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/agent-session-newer-chat-refusal.unit.test.ts @@ -5,14 +5,14 @@ import { afterAll, beforeAll, describe, expect, it } from 'vitest' import { AGENT_JOURNAL_THREAD_SCOPE, AGENT_SESSION_JOURNAL_TURN_ITEM_SCHEMA_VERSION -} from '../../../src/shared/agent-session/journal/agent-session-journal-types' +} from '../../../../src/shared/agent-session/journal/agent-session-journal-types' import type { AgentSessionJournalIdentity, AgentSessionJournalProviderHandle -} from '../../../src/shared/agent-session/journal/agent-session-journal-identity' -import { agentJournalItemKey } from '../../../src/shared/agent-session/journal/agent-session-journal-item-key' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import type { AgentSessionRefusalReference } from '../../../src/shared/agent-session/failures/agent-session-wire-refusals' +} from '../../../../src/shared/agent-session/journal/agent-session-journal-identity' +import { agentJournalItemKey } from '../../../../src/shared/agent-session/journal/agent-session-journal-item-key' +import { codexProviderHandle } from '../../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' + import { closeTestJournalHostDatabase, createTrackedJournalOpener, @@ -21,20 +21,19 @@ import { openTestJournalHostDatabase, SAVED_BY_NEWER_ORCA, seedLegacyTestJournal -} from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { journalOpenRefusal } from '../../../src/main/native-chat/agent-session-journal/replay/journal-open-failure' +} from '../../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' +import '../../../../src/main/native-chat/agent-session-journal/replay/journal-open-failure' import { importReleaseCheckoutModule, materializeReleaseCheckout, - resolveBaselineReleaseRef, releaseModuleExport -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Newer journals must yield the newer-Orca refusal to old clients, never damage wording. // Unknown bodies refuse as a newer Orca's here; also probe the older host’s handling of those rows. const SUITE_TIMEOUT_MS = 180_000 // The last release that does not know the newer-Orca reason: its words fall back to the code's. -const BEFORE_NEWER_REASON_REF = 'v1.4.218' + // Pin a main build sharing this database/schema for writable downgrade; move to the first release that ships it. const WRITABLE_BASELINE_REF = '3727100cc9dbcea6201f8a3e506676a3c4b53b18' const JOURNAL = 'src/main/native-chat/agent-session-journal' @@ -57,10 +56,6 @@ const OLDER_IDENTITY: OlderJournalIdentity = { providerHandle: { kind: 'codex', threadId: 'thread-1' } } -type ReadHistoryParts = (code: string, details?: unknown, context?: unknown) => unknown[] -type NoticeEnglish = (parts: unknown[]) => string -type IsFinal = (refusal: AgentSessionRefusalReference | undefined) => boolean - let directory: string const journals = createTrackedJournalOpener() @@ -133,66 +128,10 @@ async function storedRows(): Promise { } /** This host's refusal of a newer Orca's chat, as `history` and `subscribe` raise it. */ -async function newerChatRefusal(): Promise { - await journalWithNewerRow() - const failure = await journals.open({ identity: IDENTITY, stateDirectory: directory }).then( - () => null, - (error: unknown) => error - ) - expect(failure).toMatchObject(SAVED_BY_NEWER_ORCA) - await journals.closeAll() - return journalOpenRefusal(failure) -} /** How a released client words a read refusal, and whether it stops retrying on it. */ -async function releasedReader(ref: string) { - const checkout = await materializeReleaseCheckout(ref) - const notice = await importReleaseCheckoutModule( - checkout, - 'src/shared/agent-session-refusal-notice.ts' - ) - const readRefusal = await importReleaseCheckoutModule( - checkout, - 'src/shared/structured-agent-session-read-refusal.ts' - ) - const parts = releaseModuleExport(notice, 'agentSessionReadHistoryRefusalParts') - const english = releaseModuleExport(notice, 'agentSessionWriteNoticeEnglish') - const isFinal = releaseModuleExport(readRefusal, 'isFinalAgentSessionReadRefusal') - // The pane's own Retry stands beside the words, as on desktop. - const words = (refusal: { code: string; details?: unknown }) => - english(parts(refusal.code, refusal.details, { retryControl: true })) - return { words, isFinal } -} describe('a chat a newer Orca saved, across versions', () => { - it( - 'old client against new host: a release before the reason words it as an unreadable history and keeps retrying', - async () => { - const refusal = await newerChatRefusal() - const released = await releasedReader(BEFORE_NEWER_REASON_REF) - const code = { code: refusal.code } - const damage = { code: refusal.code, details: { reason: 'journalCorrupt' } } - expect(released.words(refusal)).toBe(released.words(code)) - expect(released.words(refusal)).not.toBe(released.words(damage)) - expect(released.isFinal(refusal)).toBe(false) - }, - SUITE_TIMEOUT_MS - ) - - it( - 'old client against new host: the newest release words it as its own, never as damage', - async () => { - rmSync(directory, { recursive: true, force: true }) - directory = mkdtempSync(join(tmpdir(), 'orca-newer-chat-xv-')) - const refusal = await newerChatRefusal() - const released = await releasedReader(resolveBaselineReleaseRef()) - const damage = { code: refusal.code, details: { reason: 'journalCorrupt' } } - expect(released.words(refusal)).not.toBe('') - expect(released.words(refusal)).not.toBe(released.words(damage)) - }, - SUITE_TIMEOUT_MS - ) - // Older hosts delete unknown row kinds: ship their reader first or bump v before writing them. // Move this baseline only to a release that preserves unknown bodies. it.each([ diff --git a/tests/e2e/cross-version-wire/agent-session-stop-event-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/agent-sessions/agent-session-stop-event-downgrade.unit.test.ts similarity index 57% rename from tests/e2e/cross-version-wire/agent-session-stop-event-downgrade.unit.test.ts rename to tests/e2e/cross-version-wire/agent-sessions/agent-session-stop-event-downgrade.unit.test.ts index 88547bba642..7632c0c8c10 100644 --- a/tests/e2e/cross-version-wire/agent-session-stop-event-downgrade.unit.test.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/agent-session-stop-event-downgrade.unit.test.ts @@ -5,17 +5,17 @@ import { expect, test } from 'vitest' import { AGENT_JOURNAL_THREAD_SCOPE, AGENT_SESSION_JOURNAL_TURN_ITEM_SCHEMA_VERSION -} from '../../../src/shared/agent-session/journal/agent-session-journal-types' +} from '../../../../src/shared/agent-session/journal/agent-session-journal-types' import type { AgentJournalItemIdentity, AgentSessionJournalIdentity, AgentSessionJournalProviderHandle -} from '../../../src/shared/agent-session/journal/agent-session-journal-identity' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import Database from '../../../src/main/sqlite/sync-database' -import type { AgentSessionJournal } from '../../../src/main/native-chat/agent-session-journal/journal-store' -import { readTestJournalItems } from '../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' -import { journalDatabasePath } from '../../../src/main/native-chat/agent-session-journal/database/journal-host-database' +} from '../../../../src/shared/agent-session/journal/agent-session-journal-identity' +import { codexProviderHandle } from '../../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' +import Database from '../../../../src/main/sqlite/sync-database' + +import '../../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' +import { journalDatabasePath } from '../../../../src/main/native-chat/agent-session-journal/database/journal-host-database' import { closeTestJournalHostDatabase, createTrackedJournalOpener, @@ -24,13 +24,13 @@ import { openTestJournalHostDatabase, SAVED_BY_NEWER_ORCA, seedLegacyTestJournal -} from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' +} from '../../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' import { importReleaseCheckoutModule, materializeReleaseCheckout, releaseModuleExport -} from './release-checkout' -import { agentJournalItemKey } from '../../../src/shared/agent-session/journal/agent-session-journal-item-key' +} from '../release-checkouts/release-checkout' +import { agentJournalItemKey } from '../../../../src/shared/agent-session/journal/agent-session-journal-item-key' const JOURNAL = 'src/main/native-chat/agent-session-journal' // Pin a main build sharing this database/schema for writable downgrade; move to the first release that ships it. @@ -83,8 +83,6 @@ function storedRows(directory: string): string[] { } } -const SCOPE = { fence: 1, turnScope: AGENT_JOURNAL_THREAD_SCOPE } - /** A chat an older build saved, before this build first converts it; returns the row writer. */ function savedBeforeConversion(directory: string) { const database = openTestJournalHostDatabase(directory) @@ -114,57 +112,6 @@ const statusRow = (ordinal: number, text: string) => ({ // Conversion is one-way: a downgraded build sees the chat as converted, and its later writes // are not carried forward, so the upgraded chat is this build's own. -test("an older build opens and appends to the chat as converted; upgraded again, the chat and its Stop pause are this build's", async () => { - const directory = mkdtempSync(join(tmpdir(), 'orca-stop-event-writable-downgrade-')) - const journals = createTrackedJournalOpener() - const savedIds = async (journal: AgentSessionJournal) => - (await readTestJournalItems(journal)).map((entry) => entry.itemId) - const pauses = async (journal: AgentSessionJournal) => - (await journal.queuedMessages.pauses()).map((pause) => pause.reason) - try { - savedBeforeConversion(directory)(2, statusRow(0, 'before the upgrade')) - await closeTestJournalHostDatabase(directory) - const converted = storedRows(directory) - - const journal = await journals.open({ identity: IDENTITY, stateDirectory: directory }) - await journal.appendItem(item(1), { kind: 'status', text: 'before the Stop' }, SCOPE) - await journal.appendStopEvent({ reason: 'user-stop', turnId: 'turn-1', caller: 'client-1' }, 1) - await journal.appendItem(item(2), { kind: 'status', text: 'after the Stop' }, SCOPE) - const wrote = { cursor: journal.cursor(), items: await savedIds(journal) } - expect(wrote.items).toEqual([0, 1, 2].map((ordinal) => agentJournalItemKey(item(ordinal)))) - expect(await pauses(journal)).toEqual(['stopped']) - await journals.closeAll() - expect(storedRows(directory)).toEqual(converted) - - const checkout = await materializeReleaseCheckout(WRITABLE_BASELINE_REF) - const support = await importReleaseCheckoutModule( - checkout, - `${JOURNAL}/journal-host-database-test-support.ts` - ) - const older = releaseModuleExport<() => OlderOpener>(support, 'createTrackedJournalOpener')() - try { - const downgraded = await older.open({ identity: OLDER_IDENTITY, stateDirectory: directory }) - expect(downgraded.isReadOnly).toBe(false) - expect(downgraded.snapshot().items.map((entry) => entry.itemId)).toEqual([ - agentJournalItemKey(item(0)) - ]) - await downgraded.appendItem(item(3), { kind: 'status', text: 'the older build' }, SCOPE) - } finally { - await older.closeAll() - } - const rowsAfter = storedRows(directory) - expect(rowsAfter.slice(0, converted.length)).toEqual(converted) - expect(rowsAfter).toHaveLength(converted.length + 1) - - const upgraded = await journals.open({ identity: IDENTITY, stateDirectory: directory }) - expect(upgraded.cursor()).toEqual(wrote.cursor) - expect(await savedIds(upgraded)).toEqual(wrote.items) - expect(await pauses(upgraded)).toEqual(['stopped']) - } finally { - await journals.closeAll() - rmSync(directory, { recursive: true, force: true }) - } -}, 120_000) // Write a new Stop row kind only after supported readers know it, or bump v; earlier hosts truncate unknown kinds. // Move the pinned baseline once a released reader preserves them. diff --git a/tests/e2e/cross-version-wire/cross-version-host-observed-turn-end.unit.test.ts b/tests/e2e/cross-version-wire/agent-sessions/cross-version-host-observed-turn-end.unit.test.ts similarity index 50% rename from tests/e2e/cross-version-wire/cross-version-host-observed-turn-end.unit.test.ts rename to tests/e2e/cross-version-wire/agent-sessions/cross-version-host-observed-turn-end.unit.test.ts index 575139861c3..ea943610e5e 100644 --- a/tests/e2e/cross-version-wire/cross-version-host-observed-turn-end.unit.test.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/cross-version-host-observed-turn-end.unit.test.ts @@ -1,7 +1,9 @@ import { beforeAll, describe, expect, it } from 'vitest' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' -import { projectStructuredAgentSessionStatusSummary } from '../../../src/shared/agent-session/view/structured-agent-session-projection' -import type { AgentJournalRenderItem } from '../../../src/shared/agent-session/journal/agent-session-journal-types' +import { + importReleaseCheckoutModule, + materializeReleaseCheckout +} from '../release-checkouts/release-checkout' +import '../../../../src/shared/agent-session/view/structured-agent-session-projection' // Pin an older reader that validates mainAgent.outcome; new interruption/unconfirmed arms must retain its normal done fallback. const OLD_REF = 'v1.4.214' @@ -48,66 +50,10 @@ beforeAll(async () => { }, SUITE_TIMEOUT_MS) /** A settled turn row this build journals when a newer request replaces the turn. */ -const SUPERSEDED_TURN = { - kind: 'turn', - turnId: 'turn-1', - state: 'interrupted', - outcome: 'superseded', - startedAt: 1, - completedAt: 2 -} as const /** The summary this build's host projects for a turn it settled with no provider verdict. */ -function newHostSummary( - state: 'interrupted' | 'unverifiable', - turn: Record = { kind: 'turn', turnId: 'turn-1', state } -) { - const items: AgentJournalRenderItem[] = [ - { - itemId: 'u1', - sequence: 1, - revision: 1, - observedAt: 1, - body: { kind: 'message', role: 'user', blocks: [{ type: 'text', text: 'go' }] } - }, - { - itemId: 't1', - sequence: 2, - revision: 1, - observedAt: 2, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a turn body built from the literal fields above, which this build's journal type admits. - body: turn as AgentJournalRenderItem['body'] - } - ] - return JSON.parse(JSON.stringify(projectStructuredAgentSessionStatusSummary(items))) -} describe('an older desktop reading a host-observed turn end', () => { - it('builds a structured row from the summary that reads done, never as a user stop', () => { - for (const summary of [ - newHostSummary('interrupted'), - newHostSummary('unverifiable'), - newHostSummary('interrupted', SUPERSEDED_TURN) - ]) { - const agentStatus = old.structuredAgentSessionAgentStatus(summary) - expect(agentStatus.state, summary.turnOutcome).toBe('done') - expect(old.mainAgentTurnInterrupted(agentStatus.mainAgent), summary.turnOutcome).toBe(false) - } - }) - - it('keeps a journaled superseded turn and reads its verdict as unknown', () => { - const row = { - itemId: 't1', - sequence: 2, - revision: 1, - observedAt: 2, - body: SUPERSEDED_TURN - } - expect(old.isAdmissibleAgentJournalRenderItem(row)).toBe(true) - // Unknown is exactly what this turn carried before it was recorded: an interrupted end. - expect(old.readAgentJournalTurnOutcome(SUPERSEDED_TURN)).toBeNull() - }) - it('keeps a status row carrying a new arm, dropping only the verdict', () => { for (const outcome of NEW_ARMS) { const parsed = old.normalizeAgentStatusPayload({ @@ -120,26 +66,4 @@ describe('an older desktop reading a host-observed turn end', () => { expect(parsed?.interrupted ?? false, outcome).toBe(false) } }) - - it('keeps a sleeping agent record a newer build wrote with a new arm', () => { - for (const outcome of NEW_ARMS) { - const parsed = old.sleepingAgentSessionsByPaneKeySchema.safeParse({ - 'tab1:pane-1': { - paneKey: 'tab1:pane-1', - tabId: 'tab1', - worktreeId: 'wt', - agent: 'codex', - providerSession: { key: 'session_id', id: 'codex-session' }, - prompt: 'continue', - state: 'done', - capturedAt: 10, - updatedAt: 9, - mainAgent: { state: 'done', outcome, stateStartedAt: 9 }, - origin: 'live' - } - }) - expect(parsed.success, outcome).toBe(true) - expect(parsed.data?.['tab1:pane-1'], outcome).toMatchObject({ prompt: 'continue' }) - } - }) }) diff --git a/tests/e2e/cross-version-wire/structured-agent-session-host-fixture.ts b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-host-fixture.ts similarity index 89% rename from tests/e2e/cross-version-wire/structured-agent-session-host-fixture.ts rename to tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-host-fixture.ts index 4eaea0cfe2a..a3886ae1f81 100644 --- a/tests/e2e/cross-version-wire/structured-agent-session-host-fixture.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-host-fixture.ts @@ -1,17 +1,17 @@ -import { agentSessionRecordFixture } from '../../../src/shared/agent-session/lifecycle/records/agent-session-record.test-fixture' -import { agentSessionConversationView } from '../../../src/shared/agent-session/lifecycle/leases/agent-session-conversation-view' +import { agentSessionRecordFixture } from '../../../../src/shared/agent-session/lifecycle/records/agent-session-record.test-fixture' +import { agentSessionConversationView } from '../../../../src/shared/agent-session/lifecycle/leases/agent-session-conversation-view' import { vi, type Mock } from 'vitest' -import type { StructuredAgentSessionAdapter } from '../../../src/main/native-chat/agent-session-wire/providers/structured-agent-session-adapter' -import { startsWhenPublished } from '../../../src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-instant-start.test-fixture' -import type { AgentSessionRecordStore } from '../../../src/main/runtime/agent-session/records/agent-session-record-store' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import type { StructuredAgentSessionHost } from '../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-host' -import { setStructuredAgentSessionHost } from '../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-registry' -import { CODEX_STRUCTURED_AGENT } from '../../../src/main/codex/structured/launch/codex-structured-agent-definition' +import type { StructuredAgentSessionAdapter } from '../../../../src/main/native-chat/agent-session-wire/providers/structured-agent-session-adapter' +import { startsWhenPublished } from '../../../../src/main/native-chat/agent-session-wire/host/testing/structured-agent-session-instant-start.test-fixture' +import type { AgentSessionRecordStore } from '../../../../src/main/runtime/agent-session/records/agent-session-record-store' +import { codexProviderHandle } from '../../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' +import type { StructuredAgentSessionHost } from '../../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-host' +import { setStructuredAgentSessionHost } from '../../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-registry' +import { CODEX_STRUCTURED_AGENT } from '../../../../src/main/codex/structured/launch/codex-structured-agent-definition' import { AGENT_SESSION_TURN_ITEM_CAPABILITY, STRUCTURED_AGENT_SESSION_RUNTIME_CAPABILITY -} from '../../../src/shared/agent-session/capabilities/agent-session-runtime-capabilities' +} from '../../../../src/shared/agent-session/capabilities/agent-session-runtime-capabilities' // Use per-method spies so every skew can prove which call reached the host. export function structuredHostStub( diff --git a/tests/e2e/cross-version-wire/structured-agent-session-surface-calls.ts b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-calls.ts similarity index 99% rename from tests/e2e/cross-version-wire/structured-agent-session-surface-calls.ts rename to tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-calls.ts index f17bbf1b5eb..9cd9f31a1ba 100644 --- a/tests/e2e/cross-version-wire/structured-agent-session-surface-calls.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-calls.ts @@ -1,5 +1,5 @@ import { expect } from 'vitest' -import { AGENT_SESSION_CURRENT_REQUESTS_CLIENT_CAPABILITY } from '../../../src/shared/agent-session/requests/agent-session-current-requests-capability' +import { AGENT_SESSION_CURRENT_REQUESTS_CLIENT_CAPABILITY } from '../../../../src/shared/agent-session/requests/agent-session-current-requests-capability' export const SESSION = 'session-alpha' export const WORKSPACE = 'workspace-1' diff --git a/tests/e2e/cross-version-wire/structured-agent-session-surface-execution.ts b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-execution.ts similarity index 90% rename from tests/e2e/cross-version-wire/structured-agent-session-surface-execution.ts rename to tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-execution.ts index 4326f2c1c96..275a798674e 100644 --- a/tests/e2e/cross-version-wire/structured-agent-session-surface-execution.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-execution.ts @@ -1,20 +1,19 @@ -import { availableRevealWorkspace } from '../../../src/main/runtime/session-tabs/chat/structured-workspace-authority.test-fixture' +import { availableRevealWorkspace } from '../../../../src/main/runtime/session-tabs/chat/structured-workspace-authority.test-fixture' import { expect, vi } from 'vitest' import type { structuredHostStub } from './structured-agent-session-host-fixture' -import { AGENT_SESSION_ITEM_DETAIL_RUNTIME_CAPABILITY } from '../../../src/shared/agent-session/capabilities/agent-session-runtime-capabilities' -import type { OrcaRuntimeService } from '../../../src/main/runtime/orca-runtime' -import type { StructuredSessionSurfaceRuntime } from '../../../src/main/runtime/agent-session/lifecycle/structured-agent-session-close' -import { RuntimeSubscriptionRegistry } from '../../../src/main/runtime/client/runtime-subscription-registry' -import { resetStructuredAgentSessionClosesBeforeCreateForTests } from '../../../src/main/runtime/rpc/methods/structured-sessions/creation/structured-agent-session-close-before-create' -import { AGENT_SESSION_CREATE_MESSAGE_RUNTIME_CAPABILITY } from '../../../src/shared/agent-session/lifecycle/operations/agent-session-create-capabilities' +import { AGENT_SESSION_ITEM_DETAIL_RUNTIME_CAPABILITY } from '../../../../src/shared/agent-session/capabilities/agent-session-runtime-capabilities' +import type { OrcaRuntimeService } from '../../../../src/main/runtime/orca-runtime' +import type { StructuredSessionSurfaceRuntime } from '../../../../src/main/runtime/agent-session/lifecycle/structured-agent-session-close' +import { RuntimeSubscriptionRegistry } from '../../../../src/main/runtime/client/runtime-subscription-registry' +import { resetStructuredAgentSessionClosesBeforeCreateForTests } from '../../../../src/main/runtime/rpc/methods/structured-sessions/creation/structured-agent-session-close-before-create' +import { AGENT_SESSION_CREATE_MESSAGE_RUNTIME_CAPABILITY } from '../../../../src/shared/agent-session/lifecycle/operations/agent-session-create-capabilities' +import { attachParams, paramsFor } from './structured-agent-session-surface-manifest' import { - attachParams, ATTENTION_READ, - paramsFor, SESSION, WORKSPACE, STRUCTURED_CALLS -} from './structured-agent-session-surface-manifest' +} from './structured-agent-session-surface-calls.ts' import type { AgentSessionWireBuild, RpcClientIdentity, diff --git a/tests/e2e/cross-version-wire/structured-agent-session-surface-manifest.ts b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-manifest.ts similarity index 93% rename from tests/e2e/cross-version-wire/structured-agent-session-surface-manifest.ts rename to tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-manifest.ts index a4a6af0ebed..da4a7c74261 100644 --- a/tests/e2e/cross-version-wire/structured-agent-session-surface-manifest.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/structured-agent-session-surface-manifest.ts @@ -3,12 +3,12 @@ import { attachFingerprintFields, type AgentSessionAttachParams -} from '../../../src/main/native-chat/agent-session-wire/acquisition/structured-agent-session-attach' -import { computeAgentSessionPayloadFingerprint } from '../../../src/shared/agent-session/lifecycle/operations/agent-session-mutation-envelope' +} from '../../../../src/main/native-chat/agent-session-wire/acquisition/structured-agent-session-attach' +import { computeAgentSessionPayloadFingerprint } from '../../../../src/shared/agent-session/lifecycle/operations/agent-session-mutation-envelope' import { structuredAgentSessionMessageSendMutation, structuredAgentSessionSendBody -} from '../../../src/shared/agent-session/requests/structured-agent-session-send-mutation' +} from '../../../../src/shared/agent-session/requests/structured-agent-session-send-mutation' import { SESSION, @@ -20,20 +20,6 @@ import { ITEM_DETAIL_METHOD } from './structured-agent-session-surface-calls' -export { - SESSION, - WORKSPACE, - THREAD, - NOW, - ATTENTION_READ, - REWIND_METHOD, - CONVERSATION_OUTLINE_METHOD, - ITEM_DETAIL_METHOD, - STATUS_FEED_METHOD, - TURN_COMPLETION_FEED_METHOD, - STRUCTURED_CALLS -} from './structured-agent-session-surface-calls' - let operations = 0 // Reset ids so one test’s envelopes cannot look like another test’s replays. diff --git a/tests/e2e/cross-version-wire/versioned-agent-session-wire.ts b/tests/e2e/cross-version-wire/agent-sessions/versioned-agent-session-wire.ts similarity index 86% rename from tests/e2e/cross-version-wire/versioned-agent-session-wire.ts rename to tests/e2e/cross-version-wire/agent-sessions/versioned-agent-session-wire.ts index e7a5af946bc..ca78d0ea6e7 100644 --- a/tests/e2e/cross-version-wire/versioned-agent-session-wire.ts +++ b/tests/e2e/cross-version-wire/agent-sessions/versioned-agent-session-wire.ts @@ -1,12 +1,12 @@ -import type * as ClientReducer from '../../../src/shared/agent-session/view/live-read/structured-agent-session-reducer' -import type * as ClientProjection from '../../../src/shared/agent-session/view/structured-agent-session-projection' -import type * as ClientSchemas from '../../../src/shared/agent-session/journal/agent-session-journal-schemas' -import type { sendPlan } from '../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-plans' +import type * as ClientReducer from '../../../../src/shared/agent-session/view/live-read/structured-agent-session-reducer' +import type * as ClientProjection from '../../../../src/shared/agent-session/view/structured-agent-session-projection' +import type * as ClientSchemas from '../../../../src/shared/agent-session/journal/agent-session-journal-schemas' +import type { sendPlan } from '../../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-plans' import { importReleaseCheckoutModule, materializeReleaseCheckout, type ReleaseCheckout -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Read capability strings and registered methods from each real build rather than assuming what the older peer knows. @@ -163,9 +163,9 @@ function capabilityStrings(module: Record): readonly string[] { async function loadWorkingTreeBuild(): Promise { const [protocol, dispatcher, methodRegistry] = await Promise.all([ - import('../../../src/shared/remote-runtime/protocol/protocol-version'), - import('../../../src/main/runtime/rpc/dispatcher'), - import('../../../src/main/runtime/rpc/methods/rpc-method-registry') + import('../../../../src/shared/remote-runtime/protocol/protocol-version'), + import('../../../../src/main/runtime/rpc/dispatcher'), + import('../../../../src/main/runtime/rpc/methods/rpc-method-registry') ]) const module = dispatcher as unknown as DispatcherModule const methods = methodRegistry.ALL_RPC_METHODS as unknown[] @@ -177,9 +177,9 @@ async function loadWorkingTreeBuild(): Promise { methodNames: registeredMethodNames(methods), clientProjection: async () => { const [reducer, projection, schemas] = await Promise.all([ - import('../../../src/shared/agent-session/view/live-read/structured-agent-session-reducer'), - import('../../../src/shared/agent-session/view/structured-agent-session-projection'), - import('../../../src/shared/agent-session/journal/agent-session-journal-schemas') + import('../../../../src/shared/agent-session/view/live-read/structured-agent-session-reducer'), + import('../../../../src/shared/agent-session/view/structured-agent-session-projection'), + import('../../../../src/shared/agent-session/journal/agent-session-journal-schemas') ]) return { ...reducer, ...projection, ...schemas } }, @@ -190,13 +190,13 @@ async function loadWorkingTreeBuild(): Promise { }), installStructuredHost: async (host) => { const registry = - await import('../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-registry') + await import('../../../../src/main/native-chat/agent-session-wire/host/structured-agent-session-registry') applyStructuredHost(registry as unknown as Record, WORKING_TREE, host) }, admitSend: async (sent) => { const [plans, admission] = await Promise.all([ - import('../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-plans'), - import('../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-admission') + import('../../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-plans'), + import('../../../../src/main/native-chat/agent-session-wire/operations/structured-agent-session-mutation-admission') ]) return admitSend(plans, admission, sent) } diff --git a/tests/e2e/cross-version-wire/released-chat-continuation.ts b/tests/e2e/cross-version-wire/chat-journals/released-chat-continuation.ts similarity index 79% rename from tests/e2e/cross-version-wire/released-chat-continuation.ts rename to tests/e2e/cross-version-wire/chat-journals/released-chat-continuation.ts index ef68f15316f..9948a06aef1 100644 --- a/tests/e2e/cross-version-wire/released-chat-continuation.ts +++ b/tests/e2e/cross-version-wire/chat-journals/released-chat-continuation.ts @@ -1,9 +1,9 @@ -import { agentJournalLinkageFields } from '../../../src/shared/agent-session/journal/agent-session-journal-producer' -import { parseAgentJournalItemKey } from '../../../src/shared/agent-session/journal/agent-session-journal-item-key' -import type { AgentJournalMessageItem } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import type { JournalReplacementItem } from '../../../src/main/native-chat/agent-session-journal/context-epochs/journal-epoch-replacement' -import type { AgentSessionJournal } from '../../../src/main/native-chat/agent-session-journal/journal-store' -import { readTestJournalItems } from '../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' +import { agentJournalLinkageFields } from '../../../../src/shared/agent-session/journal/agent-session-journal-producer' +import { parseAgentJournalItemKey } from '../../../../src/shared/agent-session/journal/agent-session-journal-item-key' +import type { AgentJournalMessageItem } from '../../../../src/shared/agent-session/journal/agent-session-journal-types' +import type { JournalReplacementItem } from '../../../../src/main/native-chat/agent-session-journal/context-epochs/journal-epoch-replacement' +import type { SqlAgentSessionJournal as AgentSessionJournal } from '../../../../src/main/native-chat/agent-session-journal/journal-sql-store.ts' +import { readTestJournalItems } from '../../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' // What a user does next with a chat a released build wrote: edit a card it queued (the first write, // over a key the old rows hold), send, and rewind to before that send, which saves every kept message diff --git a/tests/e2e/cross-version-wire/released-chat-journal.ts b/tests/e2e/cross-version-wire/chat-journals/released-chat-journal.ts similarity index 77% rename from tests/e2e/cross-version-wire/released-chat-journal.ts rename to tests/e2e/cross-version-wire/chat-journals/released-chat-journal.ts index ebe8a388458..e928ced7892 100644 --- a/tests/e2e/cross-version-wire/released-chat-journal.ts +++ b/tests/e2e/cross-version-wire/chat-journals/released-chat-journal.ts @@ -1,6 +1,6 @@ -import type { AgentJournalSnapshot } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import type { AgentSessionJournal } from '../../../src/main/native-chat/agent-session-journal/journal-store' -import type { TestJournalOptions } from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' +import type { AgentJournalSnapshot } from '../../../../src/shared/agent-session/journal/agent-session-journal-types' +import type { SqlAgentSessionJournal as AgentSessionJournal } from '../../../../src/main/native-chat/agent-session-journal/journal-sql-store.ts' +import type { TestJournalOptions } from '../../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' import type { queueReleasedCards } from './released-chat-queue' /** A queued card as a release lists it, withdrawn ones included. */ diff --git a/tests/e2e/cross-version-wire/released-chat-queue.ts b/tests/e2e/cross-version-wire/chat-journals/released-chat-queue.ts similarity index 84% rename from tests/e2e/cross-version-wire/released-chat-queue.ts rename to tests/e2e/cross-version-wire/chat-journals/released-chat-queue.ts index 07bd25db51a..d15bdfb6c84 100644 --- a/tests/e2e/cross-version-wire/released-chat-queue.ts +++ b/tests/e2e/cross-version-wire/chat-journals/released-chat-queue.ts @@ -1,6 +1,6 @@ -import type { AgentJournalMessageItem } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import { QUEUED_MESSAGE_PAUSED_SEND_FAILED } from '../../../src/shared/agent-session/requests/agent-session-queued-message-wire' -import type { AgentSessionJournal } from '../../../src/main/native-chat/agent-session-journal/journal-store' +import type { AgentJournalMessageItem } from '../../../../src/shared/agent-session/journal/agent-session-journal-types' +import { QUEUED_MESSAGE_PAUSED_SEND_FAILED } from '../../../../src/shared/agent-session/requests/agent-session-queued-message-wire' +import type { SqlAgentSessionJournal as AgentSessionJournal } from '../../../../src/main/native-chat/agent-session-journal/journal-sql-store.ts' // Queue edits as each release's queue writes them: two cards, an edit, a move, a hold and a // withdrawal. Releases before cards moved into the chat's rows kept them in a table of their own, diff --git a/tests/e2e/cross-version-wire/released-chat-writers.ts b/tests/e2e/cross-version-wire/chat-journals/released-chat-writers.ts similarity index 91% rename from tests/e2e/cross-version-wire/released-chat-writers.ts rename to tests/e2e/cross-version-wire/chat-journals/released-chat-writers.ts index a0c9c20fbb7..1333d512a55 100644 --- a/tests/e2e/cross-version-wire/released-chat-writers.ts +++ b/tests/e2e/cross-version-wire/chat-journals/released-chat-writers.ts @@ -6,17 +6,17 @@ import { AGENT_JOURNAL_THREAD_SCOPE, type AgentJournalMessageItem, type AgentJournalSnapshot -} from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import type { AgentSessionJournalIdentity } from '../../../src/shared/agent-session/journal/agent-session-journal-identity' +} from '../../../../src/shared/agent-session/journal/agent-session-journal-types' +import type { AgentSessionJournalIdentity } from '../../../../src/shared/agent-session/journal/agent-session-journal-identity' import { claudeProviderHandle, codexProviderHandle -} from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import type { agentSessionFailureFact } from '../../../src/shared/agent-session/failures/agent-session-failure' -import type { agentSessionFailureWords } from '../../../src/shared/agent-session/failures/agent-session-failure-words' -import type { createClaudeJournalTranslator } from '../../../src/main/claude/structured/journal/claude-structured-journal-translation' -import type { createCodexJournalTranslator } from '../../../src/main/codex/structured/journal/codex-structured-journal-translation' -import type { createDeferredStructuredAgentSessionEventSink } from '../../../src/main/native-chat/agent-session-wire/journal-ingress/structured-agent-session-event-sink' +} from '../../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' +import type { agentSessionFailureFact } from '../../../../src/shared/agent-session/failures/agent-session-failure' +import type { agentSessionFailureWords } from '../../../../src/shared/agent-session/failures/agent-session-failure-words' +import type { createClaudeJournalTranslator } from '../../../../src/main/claude/structured/journal/claude-structured-journal-translation' +import type { createCodexJournalTranslator } from '../../../../src/main/codex/structured/journal/codex-structured-journal-translation' +import type { createDeferredStructuredAgentSessionEventSink } from '../../../../src/main/native-chat/agent-session-wire/journal-ingress/structured-agent-session-event-sink' import type { ReleasedChat, ReleasedJournal, @@ -27,7 +27,7 @@ import { importReleaseCheckoutModule, materializeReleaseCheckout, releaseModuleExport -} from './release-checkout' +} from '../release-checkouts/release-checkout' import { queueReleasedCards } from './released-chat-queue' import { provideReleasedSqlWorkers } from './released-journal-sql-workers.test-fixture' diff --git a/tests/e2e/cross-version-wire/released-journal-sql-workers.test-fixture.ts b/tests/e2e/cross-version-wire/chat-journals/released-journal-sql-workers.test-fixture.ts similarity index 100% rename from tests/e2e/cross-version-wire/released-journal-sql-workers.test-fixture.ts rename to tests/e2e/cross-version-wire/chat-journals/released-journal-sql-workers.test-fixture.ts diff --git a/tests/e2e/cross-version-wire/cross-version-stopping.unit.test.ts b/tests/e2e/cross-version-wire/cross-version-stopping.unit.test.ts deleted file mode 100644 index eacbe1a29d6..00000000000 --- a/tests/e2e/cross-version-wire/cross-version-stopping.unit.test.ts +++ /dev/null @@ -1,163 +0,0 @@ -import { beforeAll, describe, expect, it } from 'vitest' -import { - importReleaseCheckoutModule, - importWorkingTreeModuleCopy, - materializeReleaseCheckout -} from './release-checkout' - -// Pin pre-Stopping readers: optional status/mainAgent flags must remain plain working rows to old desktop/mobile clients. -// Current clients must not infer Stopping from an old host that sends no flag. -const PRE_CHANGE_REF = 'v1.4.214' -const SUITE_TIMEOUT_MS = 180_000 -const STATUS_FOLD = 'src/shared/structured-agent-session-agent-status.ts' -// Both builds load a copy in the checkout cache, out of reach of `mobile/tsconfig.json`. -// Releases cut before the agent-lineage/ move load it from where they define it. -const PHONE_ROW_READER = 'mobile/src/worktree/agent-lineage/agent-row-display.ts' - -const WORKTREE_ID = 'repo::/worktree' -const NOW = 1_000_000 - -type Summary = Record -type Row = Record -type Fold = (summary: Summary) => { state: string; mainAgent: Record } - -type HostRowModules = { - collectRuntimeWorktreeAgentSources: (args: Record) => unknown - attachRuntimeWorktreeAgentRows: (args: Record) => void -} - -type Build = { - fold: Fold - agentDotState: (row: Row, now: number) => string - host: HostRowModules -} - -/** A working session's summary as the new host publishes it, JSON round-tripped. */ -const STOPPING_SUMMARY: Summary = JSON.parse( - JSON.stringify({ - sessionId: 'session-1', - workspaceId: WORKTREE_ID, - agent: 'claude', - status: 'working', - latestPrompt: 'ship it', - updatedAt: NOW, - stopping: true - }) -) - -/** A host's `worktree ps` rows for one structured session, JSON round-tripped. */ -function publishRow(host: HostRowModules, mainAgent: Record): Row { - const summary: Record = { - worktreeId: WORKTREE_ID, - status: 'inactive', - hasHostSidebarActivity: false, - agents: [] - } - const snapshot = { - paneKey: 'tab-1:11111111-1111-4111-8111-111111111111', - tabId: 'tab-1', - worktreeId: WORKTREE_ID, - connectionId: null, - structuredHost: 'owned', - state: 'working', - prompt: 'ship it', - lastAssistantMessage: 'running the tests', - agentType: 'claude', - receivedAt: NOW - 1_000, - stateStartedAt: NOW - 60_000, - mainAgent - } - const summaries = new Map([[WORKTREE_ID, summary]]) - host.attachRuntimeWorktreeAgentRows({ - summaries, - pathIndex: { byPath: new Map(), byRealPath: new Map() }, - missingWorktreeIds: new Set(), - // Builds read workingTerminalEvidenceByWorktreeId, then terminalTitleEvidenceByWorktreeId, now terminalTitleEvidenceByRow. - workingTerminalEvidenceByWorktreeId: new Map(), - terminalTitleEvidenceByWorktreeId: new Map(), - terminalTitleEvidenceByRow: new Map(), - rowSources: host.collectRuntimeWorktreeAgentSources({ - hookSnapshots: [snapshot], - mirroredWorktreeIdByTabId: new Map(), - connectedPtyEvidence: { - tabIds: new Set(), - paneKeys: new Set(), - ptyIdByTerminalHandle: new Map() - } - }), - orchestrationByPaneKey: null, - // Old builds pass (summaries, pathIndex, missingIds, id), then (id), now (id, hostId). - getSummary: (...args: unknown[]) => - summaries.get(String(args.find((arg) => arg === WORKTREE_ID))) ?? null - }) - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: JSON.parse of the rows the host just attached, which are plain objects. - const [row] = JSON.parse(JSON.stringify(summary.agents)) as Row[] - if (!row) { - throw new Error('expected one row') - } - return row -} - -async function loadBuild(ref: string | null): Promise { - if (ref === null) { - const [fold, display, sources, rows] = await Promise.all([ - import('../../../src/shared/agent-session/view/structured-agent-session-agent-status'), - importWorkingTreeModuleCopy(PHONE_ROW_READER), - import('../../../src/main/runtime/workspaces/process-listing/runtime-worktree-agent-sources'), - import('../../../src/main/runtime/workspaces/process-listing/runtime-worktree-agent-rows') - ]) - return { - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: this spec drives both builds' fold through one untyped surface. - fold: fold.structuredAgentSessionAgentStatus as unknown as Fold, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import of a copy is typed unknown; this is the current phone's row reader by path. - agentDotState: display.agentDotState as unknown as Build['agentDotState'], // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed by its module; this spec drives both builds through one untyped surface. - host: { ...sources, ...rows } as unknown as HostRowModules - } - } - const checkout = await materializeReleaseCheckout(ref) - const [fold, display, sources, rows] = await Promise.all([ - importReleaseCheckoutModule(checkout, STATUS_FOLD), - importReleaseCheckoutModule(checkout, PHONE_ROW_READER), - importReleaseCheckoutModule( - checkout, - 'src/main/runtime/workspaces/process-listing/runtime-worktree-agent-sources.ts' - ), - importReleaseCheckoutModule( - checkout, - 'src/main/runtime/workspaces/process-listing/runtime-worktree-agent-rows.ts' - ) - ]) - return { - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed unknown; this is the old build's summary fold by path. - fold: fold.structuredAgentSessionAgentStatus as unknown as Fold, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed unknown; this is the old phone's row reader by path. - agentDotState: display.agentDotState as unknown as Build['agentDotState'], // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed unknown; these two modules are the old host's row surface by path. - host: { ...sources, ...rows } as unknown as HostRowModules - } -} - -let oldBuild: Build -let newBuild: Build - -beforeAll(async () => { - ;[oldBuild, newBuild] = await Promise.all([loadBuild(PRE_CHANGE_REF), loadBuild(null)]) -}, SUITE_TIMEOUT_MS) - -describe('cross-version Stopping', () => { - it("an OLD phone reads a new host's row as working", () => { - const row = publishRow(newBuild.host, { - state: 'working', - stopping: true, - stateStartedAt: NOW - 60_000 - }) - expect(row.mainAgent).toMatchObject({ stopping: true }) - expect(oldBuild.agentDotState(row, NOW)).toBe('working') - }) - - it('a NEW reader of an old host never reads Stopping, which that host never publishes', () => { - const { stopping: _stopping, ...oldSummary } = STOPPING_SUMMARY - expect(newBuild.fold(oldSummary)).toEqual({ state: 'working', mainAgent: { state: 'working' } }) - const row = publishRow(oldBuild.host, { state: 'working', stateStartedAt: NOW - 60_000 }) - expect(newBuild.agentDotState(row, NOW)).toBe('working') - }) -}) diff --git a/tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts b/tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts deleted file mode 100644 index f627b205690..00000000000 --- a/tests/e2e/cross-version-wire/cross-version-terminal-wire.unit.test.ts +++ /dev/null @@ -1,185 +0,0 @@ -import { afterEach, beforeAll, describe, expect, it } from 'vitest' -import { comparePublishedFieldOccurrences } from './published-field-shape' -import { resolveBaselineReleaseRef } from './release-checkout' -import { - JOURNEY_INPUTS, - JOURNEY_STEPS, - runTerminalSkewJourney, - type JourneyRecord -} from './terminal-skew-journey' -import { - loadTerminalWireBuild, - WORKING_TREE, - type TerminalWireBuild -} from './versioned-terminal-wire' - -// Why: a cold CI run extracts the baseline checkout before the first journey. -const SUITE_TIMEOUT_MS = 180_000 -// Last stable release before SnapshotStart began publishing terminal mode metadata. -const TERMINAL_MODE_METADATA_LEGACY_REF = 'v1.4.190' - -// Name each journey’s expected frames; changed publication/acceptance needs review against remote-wire-compatibility.md. -const EXPECTED_JOURNEY_FRAMES = [ - 'C>H Subscribe', - 'H>C SnapshotStart', - 'H>C SnapshotChunk', - 'H>C SnapshotEnd', - 'C>H Input', - 'H>C Output', - 'C>H SnapshotRequest', - 'H>C SnapshotStart', - 'H>C SnapshotChunk', - 'H>C SnapshotEnd', - 'C>H Subscribe', - 'H>C SnapshotStart', - 'H>C SnapshotChunk', - 'H>C SnapshotEnd', - 'C>H Input', - 'C>H Unsubscribe' -] -const SNAPSHOT_START_OCCURRENCES = ['initial', 'reveal', 'reconnect'] as const - -let baselineRef: string -let current: TerminalWireBuild -let baseline: TerminalWireBuild -/** What a current host publishes to a client of its own version. */ -let currentReference: JourneyRecord -/** What the baseline host publishes to a client of its own version. */ -let baselineReference: JourneyRecord -let legacyTerminalModeMetadata: TerminalWireBuild - -beforeAll(async () => { - baselineRef = resolveBaselineReleaseRef() - const [workingTree, baselineRelease, legacyRelease] = await Promise.all([ - loadTerminalWireBuild(WORKING_TREE), - loadTerminalWireBuild(baselineRef), - loadTerminalWireBuild(TERMINAL_MODE_METADATA_LEGACY_REF) - ]) - current = workingTree - baseline = baselineRelease - legacyTerminalModeMetadata = legacyRelease - currentReference = await runTerminalSkewJourney({ hostBuild: current, clientBuild: current }) - baselineReference = await runTerminalSkewJourney({ hostBuild: baseline, clientBuild: baseline }) -}, SUITE_TIMEOUT_MS) - -afterEach(() => { - // Each journey installs and removes its own window stub; fail loudly if one leaked. - expect(typeof globalThis.window).toBe('undefined') -}) - -function expectJourneyActuallyRan(record: JourneyRecord): void { - // Require an observable journey so an inert harness cannot make every pairing pass. - expect(record.completed).toEqual([...JOURNEY_STEPS]) - expect(record.frameSequence).toEqual(EXPECTED_JOURNEY_FRAMES) - expect(record.subscribedEvents).toHaveLength(2) - expect(record.snapshotStarts).toHaveLength(3) - expect(record.missingRuntimeMethods).toEqual([]) -} - -function expectSnapshotStartFieldsRemainPublished(args: { - older: readonly Record[] - newer: readonly Record[] - olderLabel: string - newerLabel: string -}): void { - const skewByOccurrence = comparePublishedFieldOccurrences(args) - for (const [index, skew] of skewByOccurrence.entries()) { - const occurrence = SNAPSHOT_START_OCCURRENCES[index] ?? `occurrence ${index + 1}` - expect( - skew.removed, - `${args.newerLabel} stopped publishing ${occurrence} SnapshotStart fields ` + - `${args.olderLabel} publishes (it added: ${skew.added.join(', ') || 'nothing'})` - ).toEqual([]) - } -} - -function expectWireCompatible(record: JourneyRecord): void { - // Refused opcodes drop silently, so assert the receiving decoder accepts every frame. - expect(record.rejected).toEqual([]) - expect(record.clientErrors).toEqual([]) - - // Negotiate output-pause before opcode 16; drop notices require both peers to know the pause extension. - for (const event of record.subscribedEvents) { - expect(event.capabilities).toMatchObject({ outputPause: 1 }) - } - - // Input reached the process, before and after the reconnect. - expect(record.inputAtProcess).toEqual([JOURNEY_INPUTS.first, JOURNEY_INPUTS.second]) - - // Rule 3 — what the host publishes, as the client actually rendered it. - expect(record.snapshotsRendered[0]).toBe(JOURNEY_INPUTS.initialBuffer) - expect(record.dataRendered.join('')).toBe(JOURNEY_INPUTS.output) - expect(record.revealSnapshot?.data).toBe( - `${JOURNEY_INPUTS.initialBuffer}${JOURNEY_INPUTS.output}` - ) - expect(record.revealSnapshot).toMatchObject({ cols: 120, rows: 40 }) - for (const start of record.snapshotStarts) { - expect(start).toMatchObject({ kind: 'scrollback', cols: 120, rows: 40, source: 'headless' }) - } -} - -describe('cross-version remote terminal wire', () => { - it('current client against current server completes the journey, and is the reference for a current host', () => { - expectJourneyActuallyRan(currentReference) - expectWireCompatible(currentReference) - for (const event of currentReference.subscribedEvents) { - expect(event.capabilities).toEqual({ outputPause: 1, outputPauseDropNotice: 1 }) - } - expect(currentReference.snapshotStarts).toEqual([ - expect.objectContaining({ alternateScreen: false, terminalOwner: 'shell' }), - expect.objectContaining({ alternateScreen: false, terminalOwner: 'shell' }), - expect.objectContaining({ alternateScreen: false, terminalOwner: 'shell' }) - ]) - }) - - it( - 'old client against new server completes the journey', - async () => { - const record = await runTerminalSkewJourney({ hostBuild: current, clientBuild: baseline }) - expect(record.clientRevision).toBe(baseline.revision) - expectJourneyActuallyRan(record) - expectWireCompatible(record) - expect(record.snapshotStarts).toEqual(currentReference.snapshotStarts) - }, - SUITE_TIMEOUT_MS - ) - - it( - 'new client against old server completes the journey', - async () => { - const record = await runTerminalSkewJourney({ hostBuild: baseline, clientBuild: current }) - expect(record.hostRevision).toBe(baseline.revision) - expectJourneyActuallyRan(record) - expectWireCompatible(record) - expect(record.snapshotStarts).toEqual(baselineReference.snapshotStarts) - }, - SUITE_TIMEOUT_MS - ) - - it('adds SnapshotStart fields rather than dropping ones the old host still publishes', () => { - expectSnapshotStartFieldsRemainPublished({ - older: baselineReference.snapshotStarts, - newer: currentReference.snapshotStarts, - olderLabel: baselineRef, - newerLabel: 'current code' - }) - }) - - it( - 'new client handles a release without terminal mode metadata', - async () => { - const record = await runTerminalSkewJourney({ - hostBuild: legacyTerminalModeMetadata, - clientBuild: current - }) - expect(record.hostLabel).toBe(TERMINAL_MODE_METADATA_LEGACY_REF) - expectJourneyActuallyRan(record) - expectWireCompatible(record) - for (const start of record.snapshotStarts) { - expect(start).not.toHaveProperty('terminalOwner') - expect(start).not.toHaveProperty('alternateScreen') - } - }, - SUITE_TIMEOUT_MS - ) -}) diff --git a/tests/e2e/cross-version-wire/cross-version-worktree-ps-verdict.unit.test.ts b/tests/e2e/cross-version-wire/cross-version-worktree-ps-verdict.unit.test.ts deleted file mode 100644 index 268ac6f8cc2..00000000000 --- a/tests/e2e/cross-version-wire/cross-version-worktree-ps-verdict.unit.test.ts +++ /dev/null @@ -1,218 +0,0 @@ -import { beforeAll, describe, expect, it } from 'vitest' -import { - importReleaseCheckoutModule, - importWorkingTreeModuleCopy, - materializeReleaseCheckout -} from './release-checkout' - -// Pin pre-mainAgent readers: old phones must read new rows by interrupted; new phones must keep that fallback for old hosts. -const PRE_CHANGE_REF = 'v1.4.212' -const SUITE_TIMEOUT_MS = 180_000 -// Both builds load a copy in the checkout cache, out of reach of `mobile/tsconfig.json`. -// Releases cut before the agent-lineage/ move load it from where they define it. -const PHONE_ROW_READER = 'mobile/src/worktree/agent-lineage/agent-row-display.ts' - -const WORKTREE_ID = 'repo::/worktree' -const NOW = 1_000_000 - -type HookSnapshot = Record -type AgentRow = Record -type DotState = (row: AgentRow, now: number) => string - -type HostRowModules = { - collectRuntimeWorktreeAgentSources: (args: Record) => unknown - attachRuntimeWorktreeAgentRows: (args: Record) => void -} - -type Build = { - label: string - host: HostRowModules - agentDotState: DotState -} - -function snapshot( - tabId: string, - fields: Pick & Partial -): HookSnapshot { - return { - paneKey: `${tabId}:11111111-1111-4111-8111-111111111111`, - tabId, - worktreeId: WORKTREE_ID, - connectionId: null, - prompt: 'ship it', - agentType: 'claude', - receivedAt: NOW - 1_000, - stateStartedAt: NOW - 600_000, - ...fields - } -} - -// Separate main-agent failure, failure with working children, and an explicit user stop. -const SNAPSHOTS: HookSnapshot[] = [ - snapshot('failed-done', { - state: 'done', - mainAgent: { state: 'done', outcome: 'failure', stateStartedAt: NOW - 600_000 } - }), - snapshot('failed-working', { - state: 'working', - mainAgent: { state: 'done', outcome: 'failure', stateStartedAt: NOW - 120_000 } - }), - snapshot('stopped', { - state: 'done', - interrupted: true, - mainAgent: { state: 'done', outcome: 'cancellation', stateStartedAt: NOW - 600_000 } - }), - // Host-observed crash/unknown endings set no interrupted flag, so old readers still see done. - snapshot('crash-cut', { - state: 'done', - mainAgent: { state: 'done', outcome: 'interruption', stateStartedAt: NOW - 600_000 } - }), - snapshot('unproven', { - state: 'done', - mainAgent: { state: 'done', outcome: 'unconfirmed', stateStartedAt: NOW - 600_000 } - }), - // A turn a newer request replaced: recorded, not a user's stop, so it sets no flag either. - snapshot('replaced', { - state: 'done', - mainAgent: { state: 'done', outcome: 'superseded', stateStartedAt: NOW - 600_000 } - }) -] - -/** A host's `worktree ps` rows, JSON round-tripped as the wire carries them. */ -function publishRows(host: HostRowModules): Record { - const summary: Record = { - worktreeId: WORKTREE_ID, - status: 'inactive', - hasHostSidebarActivity: false, - agents: [] - } - const summaries = new Map([[WORKTREE_ID, summary]]) - host.attachRuntimeWorktreeAgentRows({ - summaries, - pathIndex: { byPath: new Map(), byRealPath: new Map() }, - missingWorktreeIds: new Set(), - // Builds read workingTerminalEvidenceByWorktreeId, then terminalTitleEvidenceByWorktreeId, now terminalTitleEvidenceByRow. - workingTerminalEvidenceByWorktreeId: new Map(), - terminalTitleEvidenceByWorktreeId: new Map(), - terminalTitleEvidenceByRow: new Map(), - rowSources: host.collectRuntimeWorktreeAgentSources({ - hookSnapshots: SNAPSHOTS, - mirroredWorktreeIdByTabId: new Map(), - connectedPtyEvidence: { - tabIds: new Set(SNAPSHOTS.map((row) => row.tabId)), - paneKeys: new Set(), - ptyIdByTerminalHandle: new Map() - } - }), - orchestrationByPaneKey: null, - // Old builds pass (summaries, pathIndex, missingIds, id), then (id), now (id, hostId). - getSummary: (...args: unknown[]) => - summaries.get(String(args.find((arg) => arg === WORKTREE_ID))) ?? null - }) - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: JSON.parse of the rows the host just attached, which are plain objects keyed by paneKey. - const rows = JSON.parse(JSON.stringify(summary.agents)) as AgentRow[] - return Object.fromEntries(rows.map((row) => [String(row.paneKey).split(':')[0], row])) -} - -function dotStates(build: Build, rows: Record): Record { - return Object.fromEntries( - Object.entries(rows).map(([tabId, row]) => [tabId, build.agentDotState(row, NOW)]) - ) -} - -async function loadBuild(ref: string | null): Promise { - if (ref === null) { - const [sources, rows, display] = await Promise.all([ - import('../../../src/main/runtime/workspaces/process-listing/runtime-worktree-agent-sources'), - import('../../../src/main/runtime/workspaces/process-listing/runtime-worktree-agent-rows'), - importWorkingTreeModuleCopy(PHONE_ROW_READER) - ]) - return { - label: 'current', - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed by its module; this spec drives both builds through one untyped surface. - host: { ...sources, ...rows } as unknown as HostRowModules, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import of a copy is typed unknown; this is the current phone's row reader by path. - agentDotState: display.agentDotState as unknown as DotState - } - } - const checkout = await materializeReleaseCheckout(ref) - const [sources, rows, display] = await Promise.all([ - importReleaseCheckoutModule( - checkout, - 'src/main/runtime/workspaces/process-listing/runtime-worktree-agent-sources.ts' - ), - importReleaseCheckoutModule( - checkout, - 'src/main/runtime/workspaces/process-listing/runtime-worktree-agent-rows.ts' - ), - importReleaseCheckoutModule(checkout, PHONE_ROW_READER) - ]) - return { - label: ref, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed unknown; these two modules are the old host's row surface by path. - host: { ...sources, ...rows } as unknown as HostRowModules, - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: a dynamic import is typed unknown; this is the old phone's row reader by path. - agentDotState: display.agentDotState as unknown as DotState - } -} - -let oldBuild: Build -let newBuild: Build -let agentRowTimeAt: (row: AgentRow) => number - -beforeAll(async () => { - ;[oldBuild, newBuild] = await Promise.all([loadBuild(PRE_CHANGE_REF), loadBuild(null)]) - const display = await importWorkingTreeModuleCopy(PHONE_ROW_READER) - // oxlint-disable-next-line typescript/consistent-type-assertions -- SAFETY: the rows are JSON the current host published, so the current reader's row type holds. - agentRowTimeAt = display.agentRowTimeAt as unknown as (row: AgentRow) => number -}, SUITE_TIMEOUT_MS) - -describe('cross-version worktree ps verdict', () => { - it('an OLD phone reads a new host row by the interrupted flag it always read', () => { - const rows = publishRows(newBuild.host) - expect(rows.stopped).toMatchObject({ interrupted: true }) - expect(dotStates(oldBuild, rows)).toEqual({ - 'failed-done': 'done', - 'failed-working': 'working', - stopped: 'interrupted', - 'crash-cut': 'done', - unproven: 'done', - replaced: 'done' - }) - expect(rows['crash-cut']).toMatchObject({ interrupted: false }) - expect(rows.unproven).toMatchObject({ interrupted: false }) - expect(rows.replaced).toMatchObject({ interrupted: false }) - }) - - it('a NEW phone reads an old host row, which has no mainAgent, by the same flag', () => { - const rows = publishRows(oldBuild.host) - expect(dotStates(newBuild, rows)).toEqual({ - 'failed-done': 'done', - 'failed-working': 'working', - // Both phones draw a user's Stop interrupted; only the new one draws it muted. - stopped: 'interrupted', - 'crash-cut': 'done', - unproven: 'done', - replaced: 'done' - }) - // Without the main agent's clock the row dates itself, as it always did. - expect(agentRowTimeAt(rows['failed-working'])).toBe(NOW - 600_000) - }) - - it('a NEW phone reads a new host failure as failed, dated by the main agent clock', () => { - const rows = publishRows(newBuild.host) - expect(dotStates(newBuild, rows)).toEqual({ - 'failed-done': 'failed', - 'failed-working': 'failed', - stopped: 'interrupted', - 'crash-cut': 'failed', - unproven: 'unconfirmed', - replaced: 'interrupted' - }) - expect(rows['failed-working']).toMatchObject({ - state: 'working', - mainAgent: { state: 'done', outcome: 'failure', stateStartedAt: NOW - 120_000 } - }) - expect(agentRowTimeAt(rows['failed-working'])).toBe(NOW - 120_000) - }) -}) diff --git a/tests/e2e/cross-version-wire/orchestration-delivery-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/orchestration-delivery-downgrade.unit.test.ts deleted file mode 100644 index 5b89372e4d3..00000000000 --- a/tests/e2e/cross-version-wire/orchestration-delivery-downgrade.unit.test.ts +++ /dev/null @@ -1,75 +0,0 @@ -import { mkdtempSync, rmSync } from 'node:fs' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { expect, test } from 'vitest' -import { OrchestrationDb } from '../../../src/main/runtime/orchestration/db/orchestration-db' -import { SCHEMA_VERSION } from '../../../src/main/runtime/orchestration/db/contract-constants' -import '../../../src/main/runtime/orchestration/db/messages/mailbox-routing-page' -import '../../../src/main/runtime/orchestration/db/dispatch-row-writer' -import '../../../src/main/runtime/orchestration/db/attempt-outcome-projection' - -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' - -// Pin the last pre-v41 implementation: this contract specifically exercises status-only readers. -const PRE_V41 = 'aac38d698ff75ac4c8658addab48ef5a83617619' - -// Allow cold checkout extraction, whose 45s deadline exceeds the default test timeout. -test('pre-v41 code opens, acknowledges and writes a current-schema database, then current code reopens it', async () => { - const checkout = await materializeReleaseCheckout(PRE_V41) - const baseline = await importReleaseCheckoutModule( - checkout, - 'src/main/runtime/orchestration/db.ts' - ) - const OldDb = baseline.OrchestrationDb as typeof OrchestrationDb - const directory = mkdtempSync(join(tmpdir(), 'orca-delivery-downgrade-')) - const path = join(directory, 'orchestration.db') - let db: OrchestrationDb | undefined - try { - db = new OldDb(path) - expect(db.db.pragma('user_version', { simple: true })).toBe(40) - const run = db.createRun({ - objective: 'downgrade round trip', - coordinatorHandle: 'coord', - coordinatorPaneKey: 'tab:11111111-1111-4111-8111-111111111111' - }) - const params = { runId: run.id, consumerGeneration: run.consumer_generation } - const insert = (subject: string) => - db!.insertMessage({ - runId: run.id, - from: 'worker', - to: `run:${run.id}`, - subject - }) - const oldMessage = insert('obsolete heartbeat') - const oldBatch = db.getOrCreateRunDelivery(params)! - db.close() - - db = new OrchestrationDb(path) - db.markAsRead([oldMessage.id]) - const completion = insert('completion') - const currentBatch = db.getOrCreateRunDelivery(params)! - expect(currentBatch.messages.map((message) => message.id)).toEqual([completion.id]) - expect(currentBatch.delivery.id).not.toBe(oldBatch.delivery.id) - db.close() - - db = new OldDb(path) - // Old code leaves a newer stamp alone, so the reopen still reads the current schema version. - expect(db.db.pragma('user_version', { simple: true })).toBe(SCHEMA_VERSION) - // Old readers retain their original replay semantics, but can acknowledge either stored batch. - db.acknowledgeRunDelivery({ ...params, deliveryId: oldBatch.delivery.id }) - expect(db.getOrCreateRunDelivery(params)?.delivery.id).toBe(currentBatch.delivery.id) - db.acknowledgeRunDelivery({ ...params, deliveryId: currentBatch.delivery.id }) - const next = insert('written after downgrade') - const nextBatch = db.getOrCreateRunDelivery(params)! - expect(nextBatch.messages.map((message) => message.id)).toEqual([next.id]) - db.close() - - db = new OrchestrationDb(path) - expect(db.getOrCreateRunDelivery(params)?.delivery.id).toBe(nextBatch.delivery.id) - db.acknowledgeRunDelivery({ ...params, deliveryId: nextBatch.delivery.id }) - expect(db.getOrCreateRunDelivery(params)).toBeUndefined() - } finally { - db?.close() - rmSync(directory, { recursive: true, force: true }) - } -}, 120_000) diff --git a/tests/e2e/cross-version-wire/cross-version-device-key-registry.unit.test.ts b/tests/e2e/cross-version-wire/pairing/cross-version-device-key-registry.unit.test.ts similarity index 91% rename from tests/e2e/cross-version-wire/cross-version-device-key-registry.unit.test.ts rename to tests/e2e/cross-version-wire/pairing/cross-version-device-key-registry.unit.test.ts index 67e6d18abcc..147cc19b80a 100644 --- a/tests/e2e/cross-version-wire/cross-version-device-key-registry.unit.test.ts +++ b/tests/e2e/cross-version-wire/pairing/cross-version-device-key-registry.unit.test.ts @@ -3,14 +3,14 @@ import { tmpdir } from 'node:os' import { join } from 'node:path' import nacl from 'tweetnacl' import { beforeAll, describe, expect, it, vi } from 'vitest' -import { encodeDeviceProofMessage } from '../../../src/shared/remote-runtime/pairing/device-key-proof' -import { DeviceRegistry } from '../../../src/main/runtime/rpc/server/pairing/device-registry' -import { SimulatedMobileE2EEV2Peer } from '../../../src/main/runtime/mobile-cloud-relay/testing/simulated-mobile-e2ee-v2-peer' +import { encodeDeviceProofMessage } from '../../../../src/shared/remote-runtime/pairing/device-key-proof' +import { DeviceRegistry } from '../../../../src/main/runtime/rpc/server/pairing/device-registry' +import { SimulatedMobileE2EEV2Peer } from '../../../../src/main/runtime/mobile-cloud-relay/testing/simulated-mobile-e2ee-v2-peer' import { importReleaseCheckoutModule, materializeReleaseCheckout, resolveBaselineReleaseRef -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Across downgrade, preserve keyed rows inertly and keep token auth; refuse unsupported key auth with bad_auth so clients retain their keys. const SUITE_TIMEOUT_MS = 180_000 diff --git a/tests/e2e/cross-version-wire/cross-version-mobile-direct-e2ee-v2.unit.test.ts b/tests/e2e/cross-version-wire/pairing/cross-version-mobile-direct-e2ee-v2.unit.test.ts similarity index 93% rename from tests/e2e/cross-version-wire/cross-version-mobile-direct-e2ee-v2.unit.test.ts rename to tests/e2e/cross-version-wire/pairing/cross-version-mobile-direct-e2ee-v2.unit.test.ts index 34cbccb484f..6929d55c3a6 100644 --- a/tests/e2e/cross-version-wire/cross-version-mobile-direct-e2ee-v2.unit.test.ts +++ b/tests/e2e/cross-version-wire/pairing/cross-version-mobile-direct-e2ee-v2.unit.test.ts @@ -4,17 +4,17 @@ import { encodeMobileE2EEV2Transcript, validateMobileE2EEV2Handshake, type MobileE2EEV2Hello -} from '../../../src/shared/remote-runtime/e2ee/mobile-e2ee-v2-contract' +} from '../../../../src/shared/remote-runtime/e2ee/mobile-e2ee-v2-contract' import { openMobileE2EEV2Frame, sealMobileE2EEV2Frame -} from '../../../src/shared/remote-runtime/e2ee/mobile-e2ee-v2-framing' -import { deriveMobileE2EEV2KeySchedule } from '../../../src/shared/remote-runtime/e2ee/node/mobile-e2ee-v2-node-key-schedule' +} from '../../../../src/shared/remote-runtime/e2ee/mobile-e2ee-v2-framing' +import { deriveMobileE2EEV2KeySchedule } from '../../../../src/shared/remote-runtime/e2ee/node/mobile-e2ee-v2-node-key-schedule' import { importReleaseCheckoutModule, materializeReleaseCheckout, resolveBaselineReleaseRef -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Updated phones must authenticate direct E2EE v2 and route sealed RPCs against the released host without requiring v2. const SUITE_TIMEOUT_MS = 180_000 diff --git a/tests/e2e/cross-version-wire/cross-version-paired-e2ee-handshake-core.unit.test.ts b/tests/e2e/cross-version-wire/pairing/cross-version-paired-e2ee-handshake-core.unit.test.ts similarity index 92% rename from tests/e2e/cross-version-wire/cross-version-paired-e2ee-handshake-core.unit.test.ts rename to tests/e2e/cross-version-wire/pairing/cross-version-paired-e2ee-handshake-core.unit.test.ts index cee72811dab..39dba3dc271 100644 --- a/tests/e2e/cross-version-wire/cross-version-paired-e2ee-handshake-core.unit.test.ts +++ b/tests/e2e/cross-version-wire/pairing/cross-version-paired-e2ee-handshake-core.unit.test.ts @@ -1,14 +1,14 @@ import nacl from 'tweetnacl' import { beforeAll, describe, expect, it, vi } from 'vitest' -import { E2EEChannel as CurrentChannel } from '../../../src/main/runtime/rpc/mobile/e2ee/e2ee-channel' -import { createPairedE2EEClientHandshake } from '../../../src/shared/remote-runtime/e2ee/paired-e2ee-client-handshake' -import { NODE_PAIRED_E2EE_PRIMITIVES } from '../../../src/shared/remote-runtime/e2ee/node/paired-e2ee-node-primitives' -import { remoteRuntimeClientCapabilities } from '../../../src/shared/remote-runtime/remote-runtime-client-capabilities' +import { E2EEChannel as CurrentChannel } from '../../../../src/main/runtime/rpc/mobile/e2ee/e2ee-channel' +import { createPairedE2EEClientHandshake } from '../../../../src/shared/remote-runtime/e2ee/paired-e2ee-client-handshake' +import { NODE_PAIRED_E2EE_PRIMITIVES } from '../../../../src/shared/remote-runtime/e2ee/node/paired-e2ee-node-primitives' +import { remoteRuntimeClientCapabilities } from '../../../../src/shared/remote-runtime/remote-runtime-client-capabilities' import { importReleaseCheckoutModule, materializeReleaseCheckout, resolveBaselineReleaseRef -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Shared handshake-core refactoring must preserve authentication in both directions against real released peers. const SUITE_TIMEOUT_MS = 180_000 diff --git a/tests/e2e/cross-version-wire/cross-version-pairing-ticket.unit.test.ts b/tests/e2e/cross-version-wire/pairing/cross-version-pairing-ticket.unit.test.ts similarity index 88% rename from tests/e2e/cross-version-wire/cross-version-pairing-ticket.unit.test.ts rename to tests/e2e/cross-version-wire/pairing/cross-version-pairing-ticket.unit.test.ts index ebf7622a58d..4b0766cb6e6 100644 --- a/tests/e2e/cross-version-wire/cross-version-pairing-ticket.unit.test.ts +++ b/tests/e2e/cross-version-wire/pairing/cross-version-pairing-ticket.unit.test.ts @@ -2,17 +2,17 @@ import { mkdtempSync } from 'node:fs' import { tmpdir } from 'node:os' import { join } from 'node:path' import { beforeAll, describe, expect, it } from 'vitest' -import { DeviceRegistry } from '../../../src/main/runtime/rpc/server/pairing/device-registry' -import { usesOlderPairingMethod } from '../../../src/main/runtime/rpc/server/pairing/pairing-ticket-exchange' -import '../../../src/shared/remote-runtime/pairing/ticket-exchange-capability' -import '../../../src/shared/remote-runtime/pairing/pairing' -import '../../../src/shared/remote-runtime/pairing/remote-pairing-ticket-exchange' +import { DeviceRegistry } from '../../../../src/main/runtime/rpc/server/pairing/device-registry' +import { usesOlderPairingMethod } from '../../../../src/main/runtime/rpc/server/pairing/pairing-ticket-exchange' +import '../../../../src/shared/remote-runtime/pairing/ticket-exchange-capability' +import '../../../../src/shared/remote-runtime/pairing/pairing' +import '../../../../src/shared/remote-runtime/pairing/remote-pairing-ticket-exchange' import { importReleaseCheckoutModule, materializeReleaseCheckout, releaseModuleExport, resolveBaselineReleaseRef -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Single-use pairing must survive a downgrade, accept rows an older host made, and stay invisible to old clients. const SUITE_TIMEOUT_MS = 180_000 diff --git a/tests/e2e/cross-version-wire/cross-version-web-session-pairing.unit.test.ts b/tests/e2e/cross-version-wire/pairing/cross-version-web-session-pairing.unit.test.ts similarity index 85% rename from tests/e2e/cross-version-wire/cross-version-web-session-pairing.unit.test.ts rename to tests/e2e/cross-version-wire/pairing/cross-version-web-session-pairing.unit.test.ts index 7c30f602c8d..ac5a10ccc4c 100644 --- a/tests/e2e/cross-version-wire/cross-version-web-session-pairing.unit.test.ts +++ b/tests/e2e/cross-version-wire/pairing/cross-version-web-session-pairing.unit.test.ts @@ -3,11 +3,14 @@ import { tmpdir } from 'node:os' import { join } from 'node:path' import nacl from 'tweetnacl' import { beforeAll, describe, expect, it } from 'vitest' -import { DeviceRegistry } from '../../../src/main/runtime/rpc/server/pairing/device-registry' +import { DeviceRegistry } from '../../../../src/main/runtime/rpc/server/pairing/device-registry' -import type { DeviceEntry } from '../../../src/main/runtime/rpc/server/pairing/device-entry' -import { DEVICE_REGISTRY_FILENAME } from '../../../src/main/runtime/rpc/server/pairing/mobile-pairing-files' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' +import type { DeviceEntry } from '../../../../src/main/runtime/rpc/server/pairing/device-entry' +import { DEVICE_REGISTRY_FILENAME } from '../../../../src/main/runtime/rpc/server/pairing/mobile-pairing-files' +import { + importReleaseCheckoutModule, + materializeReleaseCheckout +} from '../release-checkouts/release-checkout' // Across downgrade, preserve ephemeral key rows and token auth; only hosts advertising the capability may receive session-only registration. // The last release without session-only keys; a newer baseline would itself drop the row. diff --git a/tests/e2e/cross-version-wire/qoder-history-search-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/qoder-history-search-downgrade.unit.test.ts deleted file mode 100644 index 861df6c562d..00000000000 --- a/tests/e2e/cross-version-wire/qoder-history-search-downgrade.unit.test.ts +++ /dev/null @@ -1,222 +0,0 @@ -import { afterEach, expect, test, vi } from 'vitest' -import { - createSessionSearchClient, - unavailableSessionSearchStatus -} from '../../../src/shared/ai-vault/search/ai-vault-search-client' -import { - searchHit, - searchResults, - fakeSearchService -} from '../../../src/shared/ai-vault/search/ai-vault-search-test-fixture' -import { - searchSessionService, - sessionSearchServiceStatus, - setSessionSearchService -} from '../../../src/main/ai-vault-search/session-search-service-registry' -import { AI_VAULT_AGENTS } from '../../../src/shared/ai-vault/contracts/ai-vault-types' -import { redactForTransport } from '../../../src/shared/ai-vault/search/ai-vault-search-transport' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' -import { prepareReleaseFixtures } from './release-fixture-setup' - -const PRE_QODER_HOSTS = ['v1.4.211', 'b49abdb1f4da6b3d62dfa9ccf3c74dc9e74d291c'] -const QODER_HOST = 'f97ca2a49d9c711dab54a656a7f8a47ae6c6749c' -const LEGACY_AGENTS = AI_VAULT_AGENTS.filter( - (agent) => !['codebuddy', 'zcode', 'qoder', 'jcode', 'kiro'].includes(agent) -) -afterEach(() => setSessionSearchService(null)) - -const releaseSearchSchemas = prepareReleaseFixtures( - [...PRE_QODER_HOSTS, QODER_HOST], - async (ref) => { - const checkout = await materializeReleaseCheckout(ref) - return importReleaseCheckoutModule(checkout, 'src/shared/ai-vault-search-contract.ts') - } -) - -function releaseParser(schema: unknown) { - if ( - !schema || - typeof schema !== 'object' || - !('parse' in schema) || - typeof schema.parse !== 'function' || - !('safeParse' in schema) || - typeof schema.safeParse !== 'function' - ) { - throw new Error('Pinned release has no search parser') - } - const parse = schema.parse - const safeParse = schema.safeParse - return { - parse: (value: unknown) => parse.call(schema, value), - safeParse: (value: unknown) => safeParse.call(schema, value) - } -} - -test.each(PRE_QODER_HOSTS)( - 'the actual %s response parser accepts complete current-host legacy pages', - async (ref) => { - const baseline = await releaseSearchSchemas(ref) - const responseParser = releaseParser(baseline.AiVaultSearchResponseSchema) - const hits = (['codex', 'codebuddy', 'zcode', 'qoder', 'jcode'] as const).map((agent) => ({ - ...searchHit(), - agent, - sessionId: agent - })) - expect(responseParser.safeParse({ ...searchResults(), hits })).toHaveProperty('success', false) - const service = fakeSearchService() - service.search.mockImplementation(async (request) => ({ - ...searchResults(), - hits: hits.filter( - (hit) => !request.filters?.agents || request.filters.agents.includes(hit.agent) - ), - page: { cursor: 'legacy-next-page', hasMore: true } - })) - setSessionSearchService(service) - const oldResponse = await searchSessionService({ query: 'proof' }, 'relay') - expect(responseParser.safeParse(oldResponse)).toHaveProperty('success', true) - expect(oldResponse).toMatchObject({ - hits: [{ agent: 'codex' }], - page: { cursor: 'legacy-next-page', hasMore: true } - }) - expect(service.search).toHaveBeenLastCalledWith( - { query: 'proof', limit: 20, filters: { agents: LEGACY_AGENTS } }, - undefined - ) - const nextPage = await searchSessionService( - { query: 'proof', cursor: 'legacy-next-page' }, - 'relay' - ) - expect(responseParser.safeParse(nextPage)).toHaveProperty('success', true) - expect(service.search).toHaveBeenLastCalledWith( - { query: 'proof', cursor: 'legacy-next-page', limit: 20, filters: { agents: LEGACY_AGENTS } }, - undefined - ) - const client = createSessionSearchClient( - (method, request) => - method === 'aiVault.searchStatus' - ? sessionSearchServiceStatus(request, 'relay') - : searchSessionService(request, 'relay'), - 'relay' - ) - expect(await client.searchSessions({ query: 'proof' })).toMatchObject({ - hits: hits.map((hit) => redactForTransport(hit, 'relay')) - }) - } -) - -test.each(PRE_QODER_HOSTS)( - 'a current client narrows its entire catalog before the actual %s request parser', - async (ref) => { - const baseline = await releaseSearchSchemas(ref) - const requestParser = releaseParser(baseline.AiVaultSearchRequestSchema) - expect( - requestParser.safeParse({ query: 'proof', filters: { agents: [...AI_VAULT_AGENTS] } }) - ).toHaveProperty('success', false) - const call = vi.fn(async (method: string, request: Record) => { - if (method === 'aiVault.searchStatus') { - return { ...unavailableSessionSearchStatus(), enabled: true, phase: 'current' } - } - requestParser.parse(request) - return searchResults() - }) - const client = createSessionSearchClient(call, 'relay') - const within = { kind: 'workspace' as const, worktreeId: 'folder:/task-owned/folder' } - expect( - await client.searchSessions({ - query: 'proof', - filters: { agents: [...AI_VAULT_AGENTS] }, - within - }) - ).toMatchObject({ hits: [{ agent: 'codex' }] }) - expect(call).toHaveBeenCalledTimes(2) - expect(call).toHaveBeenLastCalledWith( - 'aiVault.searchSessions', - expect.objectContaining({ filters: { agents: LEGACY_AGENTS }, within }) - ) - call.mockClear() - expect( - await client.searchSessions({ - query: 'proof', - filters: { agents: ['qoder', 'jcode', 'codebuddy', 'zcode'] }, - within - }) - ).toEqual({ kind: 'unavailable', reason: 'unsupported-agent' }) - expect(call).toHaveBeenCalledExactlyOnceWith('aiVault.searchStatus', {}) - call.mockClear() - expect( - await client.searchSessions({ query: 'proof', filters: { agents: ['codex'] }, within }) - ).toMatchObject({ hits: [{ agent: 'codex' }] }) - expect(call).toHaveBeenCalledTimes(2) - } -) - -test.each(['codebuddy', 'zcode'] as const)( - 'an actual b49 explicit %s request proves the old client can read that agent', - async (agent) => { - const baseline = await releaseSearchSchemas(PRE_QODER_HOSTS[1]) - const request = releaseParser(baseline.AiVaultSearchRequestSchema).parse({ - query: 'proof', - filters: { agents: [agent] } - }) - const service = fakeSearchService() - service.search.mockResolvedValue({ ...searchResults(), hits: [{ ...searchHit(), agent }] }) - setSessionSearchService(service) - const response = await searchSessionService(request, 'relay') - expect(releaseParser(baseline.AiVaultSearchResponseSchema).safeParse(response)).toHaveProperty( - 'success', - true - ) - expect(response).toMatchObject({ hits: [{ agent }] }) - expect(service.search).toHaveBeenCalledExactlyOnceWith( - { query: 'proof', limit: 20, filters: { agents: [agent] } }, - undefined - ) - } -) - -test('the shipped Qoder capability proves its historical trio while withholding later Jcode', async () => { - const baseline = await releaseSearchSchemas(QODER_HOST) - const requestParser = releaseParser(baseline.AiVaultSearchRequestSchema) - const responseParser = releaseParser(baseline.AiVaultSearchResponseSchema) - const request = requestParser.parse({ query: 'proof', supportsQoderHistory: true }) - const hits = [ - searchHit(), - ...(['codebuddy', 'zcode', 'qoder', 'jcode'] as const).map((agent) => ({ - ...searchHit(), - agent - })) - ] - const service = fakeSearchService() - service.search.mockImplementation(async (projected) => ({ - ...searchResults(), - hits: hits.filter( - (hit) => !projected.filters?.agents || projected.filters.agents.includes(hit.agent) - ) - })) - setSessionSearchService(service) - const response = await searchSessionService(request, 'relay') - expect(responseParser.safeParse(response)).toHaveProperty('success', true) - expect(response).toMatchObject({ - hits: hits.filter((hit) => hit.agent !== 'jcode').map((hit) => redactForTransport(hit, 'relay')) - }) - expect( - responseParser.safeParse({ ...searchResults(), hits: [{ ...searchHit(), agent: 'jcode' }] }) - ).toHaveProperty('success', false) - const call = vi.fn(async (method: string, params: Record) => { - if (method === 'aiVault.searchStatus') { - return { ...unavailableSessionSearchStatus(), supportsQoderHistory: true } - } - requestParser.parse(params) - return searchResults() - }) - await createSessionSearchClient(call, 'relay').searchSessions({ - query: 'proof', - filters: { agents: [...AI_VAULT_AGENTS] } - }) - expect(call).toHaveBeenLastCalledWith( - 'aiVault.searchSessions', - expect.objectContaining({ - filters: { agents: AI_VAULT_AGENTS.filter((agent) => !['jcode', 'kiro'].includes(agent)) } - }) - ) -}) diff --git a/tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts b/tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts similarity index 72% rename from tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts rename to tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts index b96870cf688..d1d034caa7f 100644 --- a/tests/e2e/cross-version-wire/legacy-relay-bridge.unit.test.ts +++ b/tests/e2e/cross-version-wire/relay/legacy-relay-bridge.unit.test.ts @@ -4,43 +4,46 @@ import type { ChildProcess } from 'node:child_process' import { mkdir, mkdtemp, rm, symlink, writeFile } from 'node:fs/promises' import { join } from 'node:path' import { afterAll, beforeAll, describe, expect, it } from 'vitest' -import type { SshRemotePtyLease, SshTarget } from '../../../src/shared/remote-runtime/ssh/ssh-types' -import { SshConnection } from '../../../src/main/ssh/connection/ssh-connection' -import { toAppSshPtyId } from '../../../src/shared/remote-runtime/ssh/ssh-pty-id' +import type { + SshRemotePtyLease, + SshTarget +} from '../../../../src/shared/remote-runtime/ssh/ssh-types' +import { SshConnection } from '../../../../src/main/ssh/connection/ssh-connection' +import '../../../../src/shared/remote-runtime/ssh/ssh-pty-id' import { LegacyRelayClient, LegacyRelayOwnerHeldError -} from '../../../src/main/ssh/legacy-relay/bridge/legacy-relay-client' -import { LegacyRelayTargetBridge } from '../../../src/main/ssh/legacy-relay/bridge/legacy-relay-target-bridge' -import { LegacyRelayPaneOwners } from '../../../src/main/ssh/legacy-relay/bridge/legacy-relay-pane-owners' +} from '../../../../src/main/ssh/legacy-relay/bridge/legacy-relay-client' +import { LegacyRelayTargetBridge } from '../../../../src/main/ssh/legacy-relay/bridge/legacy-relay-target-bridge' +import { LegacyRelayPaneOwners } from '../../../../src/main/ssh/legacy-relay/bridge/legacy-relay-pane-owners' import { listLegacyRelayEndpoints, - posixEndpointExited, - type LegacyRelayEndpoint -} from '../../../src/main/ssh/legacy-relay/endpoints/legacy-relay-endpoints' -import { createLegacyRelayBridgeConnections } from '../../../src/main/ssh/legacy-relay/bridge/legacy-relay-bridge-connections' -import { waitForSentinel } from '../../../src/main/ssh/legacy-relay/handshake/ssh-relay-sentinel' -import { relaySocketNameForInstanceId } from '../../../src/main/ssh/legacy-relay/endpoints/ssh-relay-instance-id' -import { detectRemoteHostPlatform } from '../../../src/main/ssh/remote-host/ssh-remote-platform-detection' + posixEndpointExited +} from '../../../../src/main/ssh/legacy-relay/endpoints/legacy-relay-endpoints' +import { createLegacyRelayBridgeConnections } from '../../../../src/main/ssh/legacy-relay/bridge/legacy-relay-bridge-connections' +import { waitForSentinel } from '../../../../src/main/ssh/legacy-relay/handshake/ssh-relay-sentinel' +import { relaySocketNameForInstanceId } from '../../../../src/main/ssh/legacy-relay/endpoints/ssh-relay-instance-id' +import { detectRemoteHostPlatform } from '../../../../src/main/ssh/remote-host/ssh-remote-platform-detection' import { startRealOpenSshFixture, type RealOpenSshFixture -} from '../../../src/main/ssh/system-transport/testing/real-openssh-sshd-fixture' -import { getRemoteHostPlatform } from '../../../src/main/ssh/remote-host/ssh-remote-platform' -import { materializeReleaseCheckout } from './release-checkout' +} from '../../../../src/main/ssh/system-transport/testing/real-openssh-sshd-fixture' +import '../../../../src/main/ssh/remote-host/ssh-remote-platform' +import { materializeReleaseCheckout } from '../release-checkouts/release-checkout' import { buildReleasedRelayBundle, - connectAsReleasedApp, installReleasedRelay, - leaveShellInReleasedRelay, - openShellRelayTransport, PREVIOUS_RELAY_REF, releasedRelayConnectCommand, startReleasedRelayDaemon, type ReleasedRelayInstall } from './released-relay-daemon' +import { + connectAsReleasedApp, + leaveShellInReleasedRelay, + openShellRelayTransport +} from './released-relay-transport.ts' -const TARGET_ID = 'ssh-upgraded' // Budget for the release build and its 30s owner grace. const SUITE_TIMEOUT_MS = 240_000 const OLD_APP_ID = 'v1.4.224-desktop' @@ -172,80 +175,6 @@ describe.skipIf(process.platform === 'win32')( }, SUITE_TIMEOUT_MS ) - - it( - 'serves the leased pane until its shell exits, then retires it and hangs up', - async () => { - const ptyId = toAppSshPtyId(TARGET_ID, relayPtyId) - const leases: SshRemotePtyLease[] = [ - { - targetId: TARGET_ID, - ptyId: relayPtyId, - tabId: 'tab-1', - leafId: 'leaf-1', - state: 'detached', - createdAt: 1, - updatedAt: 1 - } - ] - const endpoint: LegacyRelayEndpoint = { - endpoint: sockPath, - connectCommand: releasedRelayConnectCommand(install, sockPath), - wrapCommand: true, - host: getRemoteHostPlatform('linux-x64'), - nodePath: process.execPath - } - const data: string[] = [] - const exits: string[] = [] - let exitedTelemetry = 0 - const opened: LegacyRelayClient[] = [] - const bridge = new LegacyRelayTargetBridge({ - targetId: TARGET_ID, - leases: () => leases.filter((lease) => lease.state !== 'terminated'), - retireLease: (id) => { - for (const lease of leases) { - if (lease.ptyId === id) { - lease.state = 'terminated' - } - } - }, - listEndpoints: async () => ({ kind: 'listed', endpoints: [endpoint], exhaustive: true }), - openClient: async (_endpoint, resume) => { - const client = await open(resume) - opened.push(client) - return client - }, - endpointExited: async () => false, - onPanesChanged: () => {}, - onData: (_id, chunk) => data.push(chunk), - onExit: (id) => exits.push(id), - onTerminalExited: () => { - exitedTelemetry += 1 - }, - owners: new LegacyRelayPaneOwners() - }) - try { - await bridge.refresh() - expect(bridge.snapshot()).toEqual([ - { ptyId, targetId: TARGET_ID, tabId: 'tab-1', leafId: 'leaf-1', state: 'live' } - ]) - await expect(bridge.attach(ptyId)).resolves.toMatchObject({ status: 'attached' }) - bridge.write(ptyId, 'bridged\n') - await waitFor(() => data.join('').includes('GOT:bridged'), 10_000) - - bridge.write(ptyId, 'quit\n') - await waitFor(() => exits.includes(ptyId), 10_000) - expect(leases[0].state).toBe('terminated') - expect(bridge.snapshot()).toEqual([]) - expect(exitedTelemetry).toBe(1) - expect(opened.every((client) => client.closed)).toBe(true) - expect(daemon.exitCode).toBeNull() - } finally { - bridge.dispose() - } - }, - SUITE_TIMEOUT_MS - ) } ) diff --git a/tests/e2e/cross-version-wire/released-relay-daemon.ts b/tests/e2e/cross-version-wire/relay/released-relay-daemon.ts similarity index 95% rename from tests/e2e/cross-version-wire/released-relay-daemon.ts rename to tests/e2e/cross-version-wire/relay/released-relay-daemon.ts index f59c7d75de1..86664252305 100644 --- a/tests/e2e/cross-version-wire/released-relay-daemon.ts +++ b/tests/e2e/cross-version-wire/relay/released-relay-daemon.ts @@ -6,8 +6,8 @@ import { mkdir, symlink, writeFile } from 'node:fs/promises' import { connect } from 'node:net' import { join } from 'node:path' import { build, type Plugin } from 'esbuild' -import { JSONC_PARSER_ESM_ALIAS } from '../../../config/build-plugins/jsonc-parser-esm' -import type { ReleaseCheckout } from './release-checkout' +import { JSONC_PARSER_ESM_ALIAS } from '../../../../config/build-plugins/jsonc-parser-esm' +import type { ReleaseCheckout } from '../release-checkouts/release-checkout' export type ReleasedRelayInstall = { /** The version directory: `relay.js` plus the `.version` its handshake reads. */ @@ -144,8 +144,4 @@ export function releasedRelayConnectCommand( return `cd '${install.dir}' && '${process.execPath}' relay.js --connect --sock-path '${sockPath}' --credential-file '${sockPath}.credential'` } -export { - connectAsReleasedApp, - leaveShellInReleasedRelay, - openShellRelayTransport -} from './released-relay-transport' +import './released-relay-transport' diff --git a/tests/e2e/cross-version-wire/released-relay-transport.ts b/tests/e2e/cross-version-wire/relay/released-relay-transport.ts similarity index 93% rename from tests/e2e/cross-version-wire/released-relay-transport.ts rename to tests/e2e/cross-version-wire/relay/released-relay-transport.ts index 27b3329923d..16f00a99b8d 100644 --- a/tests/e2e/cross-version-wire/released-relay-transport.ts +++ b/tests/e2e/cross-version-wire/relay/released-relay-transport.ts @@ -1,9 +1,9 @@ // Use the released relay’s bridge transport without build-tool imports so Playwright can load it. // COMPAT(legacy-relay-bridge): revisit 2027-01-15, with src/main/ssh/legacy-relay/. import { spawn } from 'node:child_process' -import { SshChannelMultiplexer } from '../../../src/main/ssh/protocol/ssh-channel-multiplexer' -import type { MultiplexerTransport } from '../../../src/main/ssh/protocol/ssh-multiplexer-transport-writer' -import { RELAY_SENTINEL } from '../../../src/main/ssh/protocol/relay-handshake' +import { SshChannelMultiplexer } from '../../../../src/main/ssh/protocol/ssh-channel-multiplexer' +import type { MultiplexerTransport } from '../../../../src/main/ssh/protocol/ssh-multiplexer-transport-writer' +import { RELAY_SENTINEL } from '../../../../src/main/ssh/protocol/relay-handshake' const SENTINEL = Buffer.from(RELAY_SENTINEL, 'utf-8') const OWNER_HELD_DISCONNECTED = -32045 diff --git a/tests/e2e/cross-version-wire/release-checkout-prefetch.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-prefetch.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-checkout-prefetch.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout-prefetch.ts diff --git a/tests/e2e/cross-version-wire/release-checkout-process.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-process.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-checkout-process.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout-process.ts diff --git a/tests/e2e/cross-version-wire/release-checkout-publication.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-publication.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-checkout-publication.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout-publication.ts diff --git a/tests/e2e/cross-version-wire/release-checkout-tree.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.ts similarity index 98% rename from tests/e2e/cross-version-wire/release-checkout-tree.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.ts index 9240df28773..3445dced9ce 100644 --- a/tests/e2e/cross-version-wire/release-checkout-tree.ts +++ b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.ts @@ -1,7 +1,7 @@ import { readFile, readdir, rm, writeFile } from 'node:fs/promises' import { dirname, join, relative } from 'node:path' import { parse } from 'yaml' -import { createWorkspaceSourceResolver } from '../../../config/scripts/workspace/source-exports/workspace-source-exports.mjs' +import { createWorkspaceSourceResolver } from '../../../../config/scripts/workspace/source-exports/workspace-source-exports.mjs' import { collectPackageImports, installMissingPackageStandIns, diff --git a/tests/e2e/cross-version-wire/release-checkout-tree.unit.test.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.unit.test.ts similarity index 92% rename from tests/e2e/cross-version-wire/release-checkout-tree.unit.test.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.unit.test.ts index 04b65f0bcdb..e76eae5e2d2 100644 --- a/tests/e2e/cross-version-wire/release-checkout-tree.unit.test.ts +++ b/tests/e2e/cross-version-wire/release-checkouts/release-checkout-tree.unit.test.ts @@ -153,33 +153,6 @@ describe('historical snapshot acquisition', () => { expect(existsSync(join(staging, '.release-checkout.tar'))).toBe(false) expect(missingSnapshotObjects(clone, commit).length).toBeGreaterThan(0) }) - - it('terminates a stalled acquisition at its finite preparation deadline', async () => { - const { repo, commit } = commitRelease({}) - const clone = partialClone(repo) - const pidFile = join(repo, 'upload-pack.pid') - const uploadPack = join(repo, 'slow-upload-pack.cjs') - writeFileSync( - uploadPack, - `require('node:fs').writeFileSync(${JSON.stringify(pidFile)}, String(process.pid)); setTimeout(() => {}, 60000)\n` - ) - execFileSync( - 'git', - [ - 'config', - 'remote.origin.uploadpack', - `${JSON.stringify(process.execPath)} ${JSON.stringify(uploadPack)}` - ], - { cwd: clone } - ) - await expect(prepareReleaseSnapshotSource(clone, commit, { timeoutMs: 2_000 })).rejects.toThrow( - /Historical source preparation: .*timed out after 2000ms/ - ) - const pid = Number(readFileSync(pidFile, 'utf8')) - expect(pid).toBeGreaterThan(0) - expect(() => process.kill(pid, 0)).toThrow() - expect(missingSnapshotObjects(clone, commit).length).toBeGreaterThan(0) - }) }) const RELEASE_PROCESS_HOST = { diff --git a/tests/e2e/cross-version-wire/release-checkout.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout.ts similarity index 95% rename from tests/e2e/cross-version-wire/release-checkout.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout.ts index d066f5c06ac..672ff51cab3 100644 --- a/tests/e2e/cross-version-wire/release-checkout.ts +++ b/tests/e2e/cross-version-wire/release-checkouts/release-checkout.ts @@ -1,7 +1,7 @@ import { execFileSync } from 'node:child_process' import { mkdir, readFile, rename, writeFile } from 'node:fs/promises' import { dirname, isAbsolute, join, relative, resolve, sep } from 'node:path' -import { selectLatestStableReleaseTag } from '../../../config/scripts/release/versioning/stable-release-tags.mjs' +import { selectLatestStableReleaseTag } from '../../../../config/scripts/release/versioning/stable-release-tags.mjs' import { populateReleaseCheckoutSource, resolveSharedReleaseCacheRoot @@ -13,16 +13,8 @@ import { } from './release-checkout-publication.ts' import { releaseModuleLocation } from './release-module-locations.ts' import { prepareReleaseSnapshotSource } from './release-checkout-prefetch.ts' -export type { - CheckoutLockOptions, - CheckoutLifecycleContext, - CheckoutStagingContext, - MaterializeReleaseCheckoutTestHooks -} from './release-checkout-publication.ts' -export { selectLatestStableReleaseTag } - -export const REPO_ROOT = resolve(import.meta.dirname, '..', '..', '..') +export const REPO_ROOT = resolve(import.meta.dirname, '..', '..', '..', '..') const DEFAULT_CACHE_ROOT = join(REPO_ROOT, 'tests', 'e2e', '.cross-version-checkouts') const BASELINE_REF_ENV = 'ORCA_CROSS_VERSION_BASELINE_REF' diff --git a/tests/e2e/cross-version-wire/release-checkout.unit.test.ts b/tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts similarity index 68% rename from tests/e2e/cross-version-wire/release-checkout.unit.test.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts index dc1d01afc4e..b1f7c3e9372 100644 --- a/tests/e2e/cross-version-wire/release-checkout.unit.test.ts +++ b/tests/e2e/cross-version-wire/release-checkouts/release-checkout.unit.test.ts @@ -1,5 +1,5 @@ import { execFileSync } from 'node:child_process' -import { randomUUID } from 'node:crypto' +import 'node:crypto' import { existsSync, mkdirSync, @@ -8,7 +8,6 @@ import { realpathSync, renameSync, rmSync, - statSync, writeFileSync } from 'node:fs' import { tmpdir } from 'node:os' @@ -21,10 +20,9 @@ import { importReleaseCheckoutModule, materializeReleaseCheckout, REPO_ROOT, - type CheckoutLockOptions, - type CheckoutStagingContext, type ReleaseCheckout } from './release-checkout' +import type { CheckoutLockOptions, CheckoutStagingContext } from './release-checkout-publication.ts' const temporaryRoots: string[] = [] const temporaryRefs: { ref: string; commit: string }[] = [] @@ -263,53 +261,6 @@ afterEach(() => { }) describe('release checkout materialization', () => { - it('keeps an import live while another colliding release label materializes', async () => { - // Squash-merged history has no merge parents; create two distinct refs with colliding labels. - const scope = `refs/orca-checkout-test/${randomUUID()}` - const firstRef = `${scope}/release` - const secondRef = `${scope}_release` - for (const [ref, revision] of [ - [firstRef, 'HEAD'], - [secondRef, 'v1.4.190'] - ]) { - const commit = git(['rev-parse', `${revision}^{commit}`]) - git(['update-ref', ref, commit, '0'.repeat(40)]) - temporaryRefs.push({ ref, commit }) - } - expect(git(['rev-parse', `${firstRef}^{commit}`])).not.toBe( - git(['rev-parse', `${secondRef}^{commit}`]) - ) - - const cacheRoot = temporaryCacheRoot() - const options = { cacheRoot, testHooks: { populateStaging: populateMinimalStaging } } - const first = await materializeReleaseCheckout(firstRef, options) - const dependency = join(first.root, 'delayed-dependency.mjs') - const entry = join(first.root, 'delayed-entry.mjs') - const importStarted = join(cacheRoot, 'import-started') - const continueImport = join(cacheRoot, 'continue-import') - writeFileSync(dependency, "export const loaded = 'first-release'\n") - writeFileSync( - entry, - "import { existsSync, writeFileSync } from 'node:fs'\n" + - `writeFileSync(${JSON.stringify(importStarted)}, '')\n` + - `while (!existsSync(${JSON.stringify(continueImport)})) await new Promise((resolve) => setTimeout(resolve, 10))\n` + - "export const loaded = (await import('./delayed-dependency.mjs')).loaded\n" - ) - - const loading = importReleaseCheckoutModule(first, '/delayed-entry.mjs') - let second: ReleaseCheckout - try { - await waitForFile(importStarted, 5_000) - second = await materializeReleaseCheckout(secondRef, options) - } finally { - writeFileSync(continueImport, '') - } - - await expect(loading).resolves.toMatchObject({ loaded: 'first-release' }) - expect(first.label).toBe(second.label) - expect(first.root).not.toBe(second.root) - }) - it('causally single-flights a rival process before publishing an in-use checkout', async () => { const cacheRoot = temporaryCacheRoot() const scratch = temporaryCacheRoot() @@ -323,73 +274,6 @@ describe('release checkout materialization', () => { await expect(runContentionPhase(published, scratch, 'ablated', true)).resolves.toBe(false) }, 120_000) - it('keeps the real lock live while publication work exceeds its stale interval', async () => { - const cacheRoot = temporaryCacheRoot() - const scratch = temporaryCacheRoot() - const attemptMarker = join(scratch, 'heartbeat-rival-attempted') - const acquiredMarker = join(scratch, 'heartbeat-rival-acquired') - const resultPath = join(scratch, 'heartbeat-rival-result.json') - let releaseWork!: () => void - const workGate = new Promise((resolveWork) => { - releaseWork = resolveWork - }) - let acknowledgeStaging!: (context: CheckoutStagingContext) => void - const stagingReady = new Promise((resolveStaging) => { - acknowledgeStaging = resolveStaging - }) - const publisher = materializeReleaseCheckout('v1.4.190', { - cacheRoot, - testHooks: { - lockOptions: COMPRESSED_LOCK_OPTIONS, - onStagingCreated: async (context) => { - acknowledgeStaging(context) - await workGate - }, - populateStaging: populateMinimalStaging - } - }) - const active = await stagingReady - const rival = startMaterializerChild(scratch, 'heartbeat-rival', { - cacheRoot, - ref: 'v1.4.190', - resultPath, - attemptMarker, - acquiredMarker, - lockOptions: COMPRESSED_LOCK_OPTIONS - }) - - try { - await waitForFile(attemptMarker, 30_000) - const blockedAt = Date.now() - const mtimes = new Set() - await waitForCondition( - 'multiple lock heartbeats beyond the stale interval', - () => { - if (existsSync(`${active.root}.lock`)) { - mtimes.add(statSync(`${active.root}.lock`).mtimeMs) - } - return Date.now() - blockedAt > COMPRESSED_LOCK_OPTIONS.stale + 250 && mtimes.size >= 3 - }, - 15_000 - ) - expect(existsSync(acquiredMarker), rival.output()).toBe(false) - expect(existsSync(active.staging)).toBe(true) - - releaseWork() - await publisher - const exitCode = await rival.exited - expect(exitCode, rival.output()).toBe(0) - expect(existsSync(acquiredMarker), rival.output()).toBe(true) - expect(JSON.parse(readFileSync(resultPath, 'utf8')), rival.output()).toEqual({ - root: active.root - }) - } finally { - releaseWork() - await stopMaterializerChild(rival) - await publisher.catch(() => undefined) - } - }, 30_000) - it('recovers a crashed lock owner and scavenges only its orphaned staging trees', async () => { const cacheRoot = temporaryCacheRoot() const scratch = temporaryCacheRoot() @@ -445,24 +329,4 @@ describe('release checkout module importer', () => { expect(() => importReleaseCheckoutModule(checkout, '..')).toThrow(escape) expect(() => importReleaseCheckoutModule(checkout, '')).toThrow(escape) }) - - it('anchors root-relative modules to the checkout root, never the working tree', async () => { - const checkout = syntheticCheckout() - mkdirSync(join(checkout.root, 'src'), { recursive: true }) - writeFileSync( - join(checkout.root, 'src', 'provenance-probe.mjs'), - 'export const moduleUrl = import.meta.url\n' - ) - - const probe = await importReleaseCheckoutModule(checkout, '/src/provenance-probe.mjs') - expect(String(probe.moduleUrl)).toContain(checkout.root.split('\\').join('/')) - - // This module exists only in the working tree; resolving it would silently run current code as the old build. - await expect( - importReleaseCheckoutModule( - checkout, - '/src/shared/remote-runtime/protocol/protocol-version.ts' - ) - ).rejects.toThrow() - }) }) diff --git a/tests/e2e/cross-version-wire/release-fixture-setup.ts b/tests/e2e/cross-version-wire/release-checkouts/release-fixture-setup.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-fixture-setup.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-fixture-setup.ts diff --git a/tests/e2e/cross-version-wire/release-missing-packages.ts b/tests/e2e/cross-version-wire/release-checkouts/release-missing-packages.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-missing-packages.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-missing-packages.ts diff --git a/tests/e2e/cross-version-wire/release-missing-packages.unit.test.ts b/tests/e2e/cross-version-wire/release-checkouts/release-missing-packages.unit.test.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-missing-packages.unit.test.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-missing-packages.unit.test.ts diff --git a/tests/e2e/cross-version-wire/release-module-locations.ts b/tests/e2e/cross-version-wire/release-checkouts/release-module-locations.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-module-locations.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-module-locations.ts diff --git a/tests/e2e/cross-version-wire/release-source-cache.ts b/tests/e2e/cross-version-wire/release-checkouts/release-source-cache.ts similarity index 98% rename from tests/e2e/cross-version-wire/release-source-cache.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-source-cache.ts index 95cad16af4d..42d16085ea4 100644 --- a/tests/e2e/cross-version-wire/release-source-cache.ts +++ b/tests/e2e/cross-version-wire/release-checkouts/release-source-cache.ts @@ -3,7 +3,7 @@ import { join, resolve } from 'node:path' import { makeTreeReadOnlyAsync, shareTreeAsync -} from '../../../config/scripts/artifact-storage/reflink-copy/space-sharing-copy.mjs' +} from '../../../../config/scripts/artifact-storage/reflink-copy/space-sharing-copy.mjs' import { extractReleaseCheckoutTree } from './release-checkout-tree.ts' import { installMissingPackageStandIns, type PackageImports } from './release-missing-packages.ts' import { publishReleaseCheckout } from './release-checkout-publication.ts' diff --git a/tests/e2e/cross-version-wire/release-source-retention.ts b/tests/e2e/cross-version-wire/release-checkouts/release-source-retention.ts similarity index 100% rename from tests/e2e/cross-version-wire/release-source-retention.ts rename to tests/e2e/cross-version-wire/release-checkouts/release-source-retention.ts diff --git a/tests/e2e/cross-version-wire/release-checkouts/release-source-retention.unit.test.ts b/tests/e2e/cross-version-wire/release-checkouts/release-source-retention.unit.test.ts new file mode 100644 index 00000000000..3ee8cec34bd --- /dev/null +++ b/tests/e2e/cross-version-wire/release-checkouts/release-source-retention.unit.test.ts @@ -0,0 +1,29 @@ +import { mkdtemp, rm } from 'node:fs/promises' +import { tmpdir } from 'node:os' +import { join } from 'node:path' +import { afterEach, expect, it } from 'vitest' +import './release-checkout-publication' +import { withReleaseSourceLease } from './release-source-retention' +import './release-source-cache' + +const roots: string[] = [] +async function scratch() { + const root = await mkdtemp(join(tmpdir(), 'orca-release-source-retention-')) + roots.push(root) + return root +} +afterEach(async () => { + for (const root of roots.splice(0)) { + await rm(root, { recursive: true, force: true }) + } +}) + +it('releases the copy lease after an operation fails', async () => { + const root = await scratch() + await expect( + withReleaseSourceLease(root, async () => { + throw new Error('copy failed') + }) + ).rejects.toThrow('copy failed') + await expect(withReleaseSourceLease(root, async () => 'recovered')).resolves.toBe('recovered') +}) diff --git a/tests/e2e/cross-version-wire/release-source-retention.unit.test.ts b/tests/e2e/cross-version-wire/release-source-retention.unit.test.ts deleted file mode 100644 index 530903e710d..00000000000 --- a/tests/e2e/cross-version-wire/release-source-retention.unit.test.ts +++ /dev/null @@ -1,79 +0,0 @@ -import { - chmod, - mkdir, - mkdtemp, - readFile, - readdir, - rm, - stat, - utimes, - writeFile -} from 'node:fs/promises' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { afterEach, expect, it } from 'vitest' -import { CHECKOUT_FORMAT } from './release-checkout-publication' -import { - MAX_SHARED_RELEASE_SEEDS, - pruneSharedReleaseSources, - withReleaseSourceLease -} from './release-source-retention' -import { copySharedReleaseSource } from './release-source-cache' - -const roots: string[] = [] -async function scratch() { - const root = await mkdtemp(join(tmpdir(), 'orca-release-source-retention-')) - roots.push(root) - return root -} -afterEach(async () => { - for (const root of roots.splice(0)) { - await rm(root, { recursive: true, force: true }) - } -}) - -it('caps seeds by recent use, preserves imported copies, and scopes cleanup to its format', async () => { - const root = await scratch() - const oldFormat = join(root, 'format-old', 'old-seed') - await mkdir(oldFormat, { recursive: true }) - await withReleaseSourceLease(root, async (formatRoot, verify) => { - const commits: string[] = [] - for (let index = 0; index < MAX_SHARED_RELEASE_SEEDS + 2; index += 1) { - const commit = index.toString(16).padStart(40, '0') - commits.push(commit) - const seed = join(formatRoot, commit) - await mkdir(seed) - await writeFile(join(seed, 'source.ts'), 'export const release = true\n') - await chmod(join(seed, 'source.ts'), 0o444) - await utimes(seed, index + 1, index + 1) - } - const imported = join(root, 'already-imported') - await copySharedReleaseSource(join(formatRoot, commits[1]), imported) - const orphan = `.staging-${commits[1]}-format-${CHECKOUT_FORMAT}-abc123` - await mkdir(join(formatRoot, orphan)) - await mkdir(join(formatRoot, '.staging-unrelated-live-owner')) - await pruneSharedReleaseSources(formatRoot, commits[0], verify) - const retained = (await readdir(formatRoot)).filter((name) => /^[\da-f]{40}$/.test(name)) - expect(retained).toHaveLength(MAX_SHARED_RELEASE_SEEDS) - expect(retained).toContain(commits[0]) - expect(retained).not.toContain(commits[1]) - expect(retained).not.toContain(commits[2]) - expect(await readFile(join(imported, 'source.ts'), 'utf8')).toBe( - 'export const release = true\n' - ) - expect((await stat(join(imported, 'source.ts'))).mode & 0o222).toBe(0) - await expect(stat(join(formatRoot, orphan))).rejects.toMatchObject({ code: 'ENOENT' }) - expect((await stat(join(formatRoot, '.staging-unrelated-live-owner'))).isDirectory()).toBe(true) - }) - expect((await stat(oldFormat)).isDirectory()).toBe(true) -}) - -it('releases the copy lease after an operation fails', async () => { - const root = await scratch() - await expect( - withReleaseSourceLease(root, async () => { - throw new Error('copy failed') - }) - ).rejects.toThrow('copy failed') - await expect(withReleaseSourceLease(root, async () => 'recovered')).resolves.toBe('recovered') -}) diff --git a/tests/e2e/cross-version-wire/released-chat-upgrade.unit.test.ts b/tests/e2e/cross-version-wire/released-chat-upgrade.unit.test.ts deleted file mode 100644 index 5cc05048557..00000000000 --- a/tests/e2e/cross-version-wire/released-chat-upgrade.unit.test.ts +++ /dev/null @@ -1,255 +0,0 @@ -import { cpSync, mkdtempSync, rmSync } from 'node:fs' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { describe, expect, it } from 'vitest' -import { - closeTestJournalHostDatabase, - createTrackedJournalOpener, - liveTestJournalRows, - openTestJournalHostDatabase, - type TrackedJournalOpener -} from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { restoreJournal } from '../../../src/main/native-chat/agent-session-journal/replay/journal-open' -import type { AgentJournalSnapshot } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import { parseJournalRow } from '../../../src/main/native-chat/agent-session-journal/durable-rows/journal-row-schema' -import { - readJournalSessionEpoch, - type JournalStoredRow -} from '../../../src/main/native-chat/agent-session-journal/durable-rows/journal-row-table' -import type { AgentSessionJournal } from '../../../src/main/native-chat/agent-session-journal/journal-store' -import { readTestJournalSnapshot } from '../../../src/main/native-chat/agent-session-journal/journal-observation.test-support' -import { readAgentSessionHistory } from '../../../src/main/native-chat/agent-session-wire/publication/history/agent-session-history-page' -import { - readQueuePublication, - structuredQueueSendGate -} from '../../../src/main/native-chat/agent-session-wire/delivery/structured-agent-session-queued-publication' -import { resolveBaselineReleaseRef } from './release-checkout' -import { - editReleasedCard, - rewindReleasedChat, - sendAfterUpgrade -} from './released-chat-continuation' -import { - identityOf, - releasedJournalReader, - writeReleasedChat, - type Agent -} from './released-chat-writers' -import type { ReleasedCard, ReleasedReader } from './released-chat-journal' - -// The two releases before outcome storage, and the oldest release whose chat database this build still -// reads, writes a Claude and a Codex chat through its own writers. This build admits every row as -// written, opens the chat as that release had it, then edits a queued card (its first write, over -// a key the old rows hold), sends, and rewinds, which saves the kept chat again in this build's -// form. The release's rows stay its own: this build converts them and never writes them. What this -// build does after the open is checked on its own result, never against a release, so main stays -// free to change it. -const SUITE_TIMEOUT_MS = 180_000 -// v1.4.246 shipped outcome storage, so its chats hold no rows to upgrade; the writers pin the two -// releases before it, and the newest release stays the reader this build must match. -const RELEASES = { - 'the last release before outcome storage': () => 'v1.4.245', - 'the release before it': () => 'v1.4.244', - // The first release with one chat database per host (schema 3, the oldest this build opens); - // earlier releases kept a file per chat, which nothing reads any more. It never changes. - 'the oldest release with this chat database': () => 'v1.4.219' -} as const -type Written = Awaited> - -type Card = Pick & { state?: string } -const byPosition = (cards: readonly T[]): T[] => - [...cards].sort((a, b) => a.position - b.position) - -/** This build's chat and its live cards; a withdrawn card is no longer listed. */ -const view = async (journal: AgentSessionJournal, now: () => number) => { - const publication = await readQueuePublication( - journal, - structuredQueueSendGate( - { - store: { - getConversation: () => null, - getRecord: () => null, - replacedRuntime: () => undefined - }, - sessions: new Map([ - [journal.identity.sessionId, { journal, child: null, operationalRevision: 0 }] - ]) - }, - journal.identity.sessionId, - now - ) - ) - // Nothing moves authority here, so a superseded read is a failure, not an empty queue. - if (!publication) { - throw new Error('the queue publication read was superseded') - } - return { - snapshot: await readTestJournalSnapshot(journal), - cards: byPosition(await journal.queuedMessages.list()), - publishedCards: publication.queuedMessages - } -} - -/** What the release wrote: its items, sends and live cards, in order. Fields a later build adds to - * them are not compared (`toMatchObject`), so main may add one; a changed value or order still fails. */ -const releaseWritten = ({ - snapshot, - cards -}: { - snapshot: AgentJournalSnapshot - cards: readonly Card[] -}) => ({ - items: snapshot.items, - submissions: snapshot.submissions, - cards: cards.filter((card) => card.state !== 'withdrawn') -}) - -const kept = (items: AgentJournalSnapshot['items']) => - items.map(({ itemId, body }) => ({ itemId, body })) - -/** The chat as a release opens it, over a copy so the original stays as the release left it. */ -async function openedBy(reader: ReleasedReader, agent: Agent, stateDirectory: string) { - return reader - .open({ identity: identityOf(agent), stateDirectory }) - .then(reader.read) - .then(({ snapshot, cards }) => ({ - snapshot, - cards: byPosition(cards).filter((card) => card.state !== 'withdrawn') - })) - .finally(() => reader.closeAll()) -} - -/** Opens the chat, edits, sends and rewinds it, then reopens it; checks what the user sees. */ -async function carryOn( - opener: TrackedJournalOpener, - agent: Agent, - stateDirectory: string, - written: Written, - prefix?: JournalStoredRow[] -) { - const options = { - identity: identityOf(agent), - stateDirectory, - now: written.now, - mintEpoch: () => 'epoch-rewound' - } - const carried = await opener - .open(options) - .then(async (journal) => { - const opened = await view(journal, written.now) - await editReleasedCard(journal) - if (prefix) { - // The release's rows stay byte for byte; this build's writes go to its own store. - const database = openTestJournalHostDatabase(stateDirectory) - expect(liveTestJournalRows(database.db, options.identity.sessionId)).toEqual(prefix) - } - await sendAfterUpgrade(journal) - const sent = await view(journal, written.now) - expect(sent.snapshot.submissions).toContainEqual( - expect.objectContaining({ clientMessageId: 'after-upgrade', dispatchState: 'accepted' }) - ) - const beforeRewind = journal.cursor() - const database = openTestJournalHostDatabase(stateDirectory) - const physicalEpoch = readJournalSessionEpoch(database.db, options.identity.sessionId) - expect(physicalEpoch).not.toBeNull() - await rewindReleasedChat(journal, new Set(opened.snapshot.items.map((item) => item.itemId))) - expect(journal.cursor().epoch).toMatch(/^context-v1:/) - expect(journal.cursor().epoch).not.toBe(beforeRewind.epoch) - expect(readJournalSessionEpoch(database.db, options.identity.sessionId)).toBe(physicalEpoch) - // A client still at the old context is told to reload rather than sent a partial history. - expect( - await readAgentSessionHistory(journal, { - sessionId: options.identity.sessionId, - direction: 'after', - cursor: beforeRewind - }) - ).toMatchObject({ ok: false, reset: 'epoch_changed' }) - const seen = await view(journal, written.now) - // The rewind keeps every message the release wrote and every card not taken back, the edit - // included. - expect(kept(seen.snapshot.items)).toEqual(kept(opened.snapshot.items)) - expect(seen.cards.map((card) => card.messageId)).toEqual( - opened.cards.map((card) => card.messageId) - ) - expect(seen.cards).toHaveLength(1) - expect(seen.cards).toEqual(sent.cards) - expect(seen.publishedCards.map((card) => card.messageId)).toEqual(['card-2']) - for (const result of [sent, seen]) { - expect(result.cards.find((card) => card.messageId === 'card-2')?.body.blocks).toEqual([ - { type: 'text', text: 'second, edited after the upgrade' } - ]) - } - return { opened, seen } - }) - .finally(() => opener.closeAll()) - const reopened = await opener - .open(options) - .then(async (journal) => { - const reopened = await view(journal, written.now) - expect(reopened.publishedCards.map((card) => card.messageId)).toEqual(['card-2']) - return reopened - }) - .finally(() => opener.closeAll()) - expect(reopened).toEqual(carried.seen) - return carried -} - -describe('a chat a shipped release wrote, carried on by this build', () => { - it.each([ - ['the last release before outcome storage', 'claude'], - ['the last release before outcome storage', 'codex'], - ['the release before it', 'claude'], - ['the release before it', 'codex'], - ['the oldest release with this chat database', 'claude'], - ['the oldest release with this chat database', 'codex'] - ] as const)( - 'admits every row %s wrote for a %s chat, opens it as the newest release does, then edits, sends and rewinds it', - async (build, agent) => { - const directory = mkdtempSync(join(tmpdir(), 'orca-released-chat-upgrade-')) - const shipped = mkdtempSync(join(tmpdir(), 'orca-released-chat-shipped-')) - const identity = identityOf(agent) - try { - const written = await writeReleasedChat(RELEASES[build](), agent, directory) - // Anti-vacuous: the release's stream (beyond the two sends and the Stop turn), sends and - // queue all reached the chat. - expect(written.snapshot.items.length).toBeGreaterThan(3) - expect(written.snapshot.submissions.map((entry) => entry.clientMessageId)).toEqual( - expect.arrayContaining(['sent', 'refused']) - ) - expect(written.cards).toHaveLength(2) - - const database = openTestJournalHostDatabase(directory) - const rows = liveTestJournalRows(database.db, identity.sessionId) - expect(rows.filter((row) => !parseJournalRow(row.rowJson).ok)).toEqual([]) - // Anti-vacuous: the release wrote every row kind a chat holds (cards in their own table - // before they moved into the rows). - const kinds = new Set(rows.map((row) => JSON.parse(row.rowJson).kind)) - expect([...kinds].filter((kind) => kind !== 'queue').sort()).toEqual( - ['dispatch', 'epoch', 'item', 'lifecycle-batch', 'submission', 'tombstone'].sort() - ) - expect(kinds.has('queue')).toBe(build !== 'the oldest release with this chat database') - expect(restoreJournal(database.db, identity.sessionId)).toMatchObject({ - newer: null, - damage: null - }) - await closeTestJournalHostDatabase(directory) - cpSync(directory, shipped, { recursive: true }) - - const ours = await carryOn(createTrackedJournalOpener(), agent, directory, written, rows) - if (build !== 'the oldest release with this chat database') { - // A release in the window wrote the shapes this build reads, so it opens as written. - expect(releaseWritten(ours.opened)).toMatchObject(releaseWritten(written)) - } - // This build opens the chat as the newest release does. - const newest = await releasedJournalReader(resolveBaselineReleaseRef()) - expect(releaseWritten(ours.opened)).toMatchObject( - releaseWritten(await openedBy(newest, agent, shipped)) - ) - } finally { - rmSync(directory, { recursive: true, force: true }) - rmSync(shipped, { recursive: true, force: true }) - } - }, - SUITE_TIMEOUT_MS - ) -}) diff --git a/tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts b/tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts deleted file mode 100644 index e6c0cc57b36..00000000000 --- a/tests/e2e/cross-version-wire/reported-lossy-initial-snapshot.unit.test.ts +++ /dev/null @@ -1,160 +0,0 @@ -import { afterEach, beforeAll, describe, expect, it, vi } from 'vitest' -import { Terminal } from '@xterm/headless' -import { createHostTerminalRuntimeStub } from './host-terminal-runtime-stub' -import { createTerminalWireLink } from './terminal-wire-link' -import { - loadTerminalWireBuild, - WORKING_TREE, - type TerminalWireBuild -} from './versioned-terminal-wire' - -const REPORTED_HOST_REF = '4bb337741c' -const MARKER = 'REPORTED_LOSSY_INITIAL_MARKER' -const RECOVERED_LIVE_MARKER = 'RECOVERED_LIVE_AFTER_INITIAL' -const CONTINUED_LIVE_MARKER = 'CONTINUED_LIVE_AFTER_RECOVERY' -const TIMEOUT_MS = 180_000 - -let candidate: TerminalWireBuild -let reportedHost: TerminalWireBuild - -beforeAll(async () => { - ;[candidate, reportedHost] = await Promise.all([ - loadTerminalWireBuild(WORKING_TREE), - loadTerminalWireBuild(REPORTED_HOST_REF) - ]) -}, TIMEOUT_MS) - -afterEach(() => { - expect(typeof globalThis.window).toBe('undefined') -}) - -async function runLossyInitialSnapshotPair(args: { - clientBuild: TerminalWireBuild - hostBuild: TerminalWireBuild - exerciseLiveRecovery?: boolean -}): Promise<{ - frames: string[] - missingRuntimeMethods: string[] - rejected: unknown[] - rendered: string - snapshotStarts: Record[] - snapshots: string[] -}> { - const hostStub = createHostTerminalRuntimeStub({ - initialBuffer: MARKER, - overflowInitialSnapshots: true - }) - const link = createTerminalWireLink({ ...args, hostStub }) - const snapshots: string[] = [] - const terminalModel = new Terminal({ cols: 120, rows: 40 }) - let subscribed = 0 - try { - const terminal = await args.clientBuild.client - .getRemoteRuntimeTerminalMultiplexer('reported-lossy-initial') - .subscribeTerminal({ - terminal: hostStub.terminalHandle, - client: { id: 'reported-client', type: 'desktop' }, - callbacks: { - onData: (data) => terminalModel.write(data), - onSnapshot: (data) => { - snapshots.push(data) - terminalModel.write(data) - }, - onSubscribed: () => { - subscribed += 1 - } - } - }) - await vi.waitFor(() => expect(subscribed).toBe(1), { timeout: 10_000 }) - if (args.exerciseLiveRecovery) { - hostStub.emitOutput(RECOVERED_LIVE_MARKER) - await vi.waitFor( - () => expect(readTerminalText(terminalModel)).toContain(RECOVERED_LIVE_MARKER), - { timeout: 10_000 } - ) - hostStub.emitOutput(CONTINUED_LIVE_MARKER) - await vi.waitFor( - () => expect(readTerminalText(terminalModel)).toContain(CONTINUED_LIVE_MARKER), - { timeout: 10_000 } - ) - } - terminal.close() - const snapshotStartOpcode = Number(args.clientBuild.codec.TerminalStreamOpcode.SnapshotStart) - return { - frames: link.observed.map((frame) => { - const codec = - frame.direction === 'host-to-client' ? args.clientBuild.codec : args.hostBuild.codec - const name = codec.TerminalStreamOpcode[frame.opcode] - return `${frame.direction}:${typeof name === 'string' ? name : frame.opcode}` - }), - missingRuntimeMethods: hostStub.missingRuntimeMethods, - rejected: link.rejected, - rendered: readTerminalText(terminalModel), - snapshotStarts: link.observed - .filter( - (frame) => frame.direction === 'host-to-client' && frame.opcode === snapshotStartOpcode - ) - .map((frame) => frame.json ?? {}), - snapshots - } - } finally { - terminalModel.dispose() - await link.dispose() - } -} - -function readTerminalText(terminal: Terminal): string { - const lines: string[] = [] - for (let index = 0; index < terminal.buffer.active.length; index += 1) { - lines.push(terminal.buffer.active.getLine(index)?.translateToString(true) ?? '') - } - return lines.join('\n') -} - -describe('reported mixed-version lossy initial snapshot', () => { - it( - 'paints the old host image exactly once with the candidate client', - async () => { - const record = await runLossyInitialSnapshotPair({ - clientBuild: candidate, - hostBuild: reportedHost, - exerciseLiveRecovery: true - }) - - expect(record.snapshotStarts).toEqual([ - expect.objectContaining({ truncated: true, seq: expect.any(Number) }), - expect.objectContaining({ truncated: false, seq: expect.any(Number) }) - ]) - expect(record.snapshots[0]).toBe(MARKER) - expect(record.rejected).toEqual([]) - expect(record.missingRuntimeMethods).toEqual([]) - expect(record.rendered.split(MARKER)).toHaveLength(2) - expect(record.rendered.split(RECOVERED_LIVE_MARKER)).toHaveLength(2) - expect(record.rendered.split(CONTINUED_LIVE_MARKER)).toHaveLength(2) - }, - TIMEOUT_MS - ) - - it( - 'paints the latest host image exactly once with the candidate client', - async () => { - const record = await runLossyInitialSnapshotPair({ - clientBuild: candidate, - hostBuild: candidate, - exerciseLiveRecovery: true - }) - - expect(record.snapshotStarts).toEqual([ - expect.objectContaining({ truncated: true, seq: expect.any(Number) }), - expect.objectContaining({ truncated: false, seq: expect.any(Number) }) - ]) - expect(record.snapshots[0]).toBe(MARKER) - expect(record.rejected).toEqual([]) - expect(record.missingRuntimeMethods).toEqual([]) - expect(record.rendered.split(MARKER)).toHaveLength(2) - expect(record.rendered.split(RECOVERED_LIVE_MARKER)).toHaveLength(2) - expect(record.rendered.split(CONTINUED_LIVE_MARKER)).toHaveLength(2) - }, - TIMEOUT_MS - ) -}) diff --git a/tests/e2e/cross-version-wire/submission-positions-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/submission-positions-downgrade.unit.test.ts deleted file mode 100644 index ab5c2c5757f..00000000000 --- a/tests/e2e/cross-version-wire/submission-positions-downgrade.unit.test.ts +++ /dev/null @@ -1,200 +0,0 @@ -import { mkdtempSync, rmSync } from 'node:fs' -import { tmpdir } from 'node:os' -import { join } from 'node:path' -import { expect, test } from 'vitest' -import { codexProviderHandle } from '../../../src/shared/agent-session/lifecycle/provider-handles/agent-session-provider-handle-encoding' -import { agentSessionFailureFact } from '../../../src/shared/agent-session/failures/agent-session-failure' -import { agentSessionFailureWords } from '../../../src/shared/agent-session/failures/agent-session-failure-words' -import type { AgentJournalSubmission } from '../../../src/shared/agent-session/journal/agent-session-journal-types' -import type { AgentSessionJournalIdentity } from '../../../src/shared/agent-session/journal/agent-session-journal-identity' -import type { AgentSessionHistoryPage } from '../../../src/shared/agent-session/agent-session-wire' -import { - createTrackedJournalOpener, - type TrackedJournalOpener -} from '../../../src/main/native-chat/agent-session-journal/store-lifecycle/journal-host-database-test-support' -import { - createAgentSessionCatchUpReader, - readAgentSessionHydrationPage -} from '../../../src/main/native-chat/agent-session-wire/publication/history/agent-session-history-page' -import { - importReleaseCheckoutModule, - materializeReleaseCheckout, - releaseModuleExport -} from './release-checkout' - -// Pin readers before submission position/answered turn; new fields must not change their page or incremental rendering. -const BASELINE_REFS = ['v1.4.219', 'v1.4.220'] as const - -const IDENTITY: AgentSessionJournalIdentity = { - sessionId: 'session-positions', - workspaceId: 'ws-1', - hostId: 'host-1', - agent: 'codex', - providerHandle: codexProviderHandle('thread-1') -} - -type OldState = { submissions: Record[]; items: unknown[] } - -/** Submissions as an older host would carry them. */ -function withoutNewFields( - submissions: readonly AgentJournalSubmission[] -): AgentJournalSubmission[] { - return submissions.map( - ({ submittedSequence: _submitted, answeredInTurn: _turn, ...rest }) => rest - ) -} - -/** A chat before and after three rejections: a queued send taken back, one its turn's end - * rejected, and one refused outright. */ -async function journalWithRejections(directory: string, journals: TrackedJournalOpener) { - const journal = await journals.open({ identity: IDENTITY, stateDirectory: directory }) - const message = (text: string) => ({ - kind: 'message' as const, - role: 'user' as const, - blocks: [{ type: 'text' as const, text }] - }) - for (const id of ['taken-back', 'still-queued']) { - await journal.appendSubmission({ - clientMessageId: id, - payloadFingerprint: id, - body: message(id), - fence: 1, - handoverRecorded: true - }) - } - for (const id of ['turn-ended', 'refused']) { - await journal.appendSubmission({ - clientMessageId: id, - payloadFingerprint: id, - body: message(id), - fence: 1 - }) - } - const before = await readAgentSessionHydrationPage(journal, 1) - const seen = journal.cursor() - const cancelled = agentSessionFailureWords(agentSessionFailureFact('cancelled'), { - surface: 'rejection' - }) - await journal.resolveDispatch({ - clientMessageId: 'taken-back', - state: 'rejected', - ...cancelled, - fence: 1, - recovered: true - }) - await journal.resolveDispatch({ - clientMessageId: 'turn-ended', - state: 'rejected', - ...cancelled, - answeredInTurn: { - turn: { - provider: 'legacy', - agent: 'codex', - sessionId: IDENTITY.sessionId, - recordId: 'turn-lifecycle:turn-1' - }, - via: 'start' - }, - fence: 1 - }) - await journal.resolveDispatch({ - clientMessageId: 'refused', - state: 'rejected', - ...agentSessionFailureWords(agentSessionFailureFact('queueFull'), { surface: 'rejection' }), - fence: 1 - }) - // The batch a subscriber's catch-up sends from the page after what it had seen. - const { result: since } = await createAgentSessionCatchUpReader(journal)({ - sessionId: IDENTITY.sessionId, - direction: 'after', - cursor: seen - }) - if (!since.ok) { - throw new Error('the batch did not project') - } - const batch = { - cursor: since.page.window.nextCursor, - items: since.page.items, - removedItemIds: since.page.removedItemIds, - submissions: since.page.submissions - } - return { before, after: await readAgentSessionHydrationPage(journal, 1), batch } -} - -// Loads real release checkouts, cold extraction and transforms included. -test.each(BASELINE_REFS)( - 'a released client (%s) draws a page and a batch carrying journal positions and answered turns as it draws them without', - async (ref) => { - const directory = mkdtempSync(join(tmpdir(), 'orca-submission-positions-downgrade-')) - const journals = createTrackedJournalOpener() - try { - const { before, after, batch } = await journalWithRejections(directory, journals) - // Anti-vacuous: what this build publishes carries a position, a named turn, and stated none. - expect(after.submissions).toEqual( - expect.arrayContaining([ - expect.objectContaining({ clientMessageId: 'taken-back', answeredInTurn: null }), - expect.objectContaining({ - clientMessageId: 'turn-ended', - submittedSequence: expect.any(Number), - answeredInTurn: { turnItemId: expect.any(String), via: 'start' } - }), - expect.objectContaining({ clientMessageId: 'refused', answeredInTurn: null }) - ]) - ) - expect(batch.submissions.map((entry) => entry.answeredInTurn)).toContain(null) - - const checkout = await materializeReleaseCheckout(ref) - const reducer = await importReleaseCheckoutModule( - checkout, - 'src/shared/structured-agent-session-reducer.ts' - ) - const projection = await importReleaseCheckoutModule( - checkout, - 'src/shared/structured-agent-session-message-projection.ts' - ) - const reduce = releaseModuleExport<(state: unknown, action: unknown) => OldState>( - reducer, - 'reduceStructuredAgentSession' - ) - const empty = releaseModuleExport(reducer, 'EMPTY_STRUCTURED_AGENT_SESSION') - const project = releaseModuleExport< - (items: unknown[], outbox: unknown[], submissions: unknown[]) => unknown[] - >(projection, 'projectStructuredAgentSessionMessages') - const draw = (state: OldState) => ({ - submissions: state.submissions.map( - ({ submittedSequence: _s, answeredInTurn: _t, ...rest }) => rest - ), - messages: project(state.items, [], state.submissions) - }) - const fromPage = (page: AgentSessionHistoryPage) => - draw(reduce(empty, { type: 'history-page', page })) - const fromBatch = (stripped: boolean) => - draw( - reduce(reduce(empty, { type: 'history-page', page: before }), { - type: 'event', - event: { - type: 'batch', - sessionId: IDENTITY.sessionId, - batch: stripped - ? { ...batch, submissions: withoutNewFields(batch.submissions) } - : batch, - fence: 1 - } - }) - ) - - expect(fromPage(after)).toEqual( - fromPage({ ...after, submissions: withoutNewFields(after.submissions) }) - ) - expect(fromBatch(false)).toEqual(fromBatch(true)) - // Anti-vacuous: the batch reached the old client's submissions. - expect(fromBatch(false).submissions).toEqual( - expect.arrayContaining([expect.objectContaining({ dispatchState: 'rejected' })]) - ) - } finally { - await journals.closeAll() - rmSync(directory, { recursive: true, force: true }) - } - }, - 180_000 -) diff --git a/tests/e2e/cross-version-wire/host-terminal-runtime-stub.ts b/tests/e2e/cross-version-wire/terminal-streams/host-terminal-runtime-stub.ts similarity index 100% rename from tests/e2e/cross-version-wire/host-terminal-runtime-stub.ts rename to tests/e2e/cross-version-wire/terminal-streams/host-terminal-runtime-stub.ts diff --git a/tests/e2e/cross-version-wire/published-field-shape.ts b/tests/e2e/cross-version-wire/terminal-streams/published-field-shape.ts similarity index 100% rename from tests/e2e/cross-version-wire/published-field-shape.ts rename to tests/e2e/cross-version-wire/terminal-streams/published-field-shape.ts diff --git a/tests/e2e/cross-version-wire/terminal-skew-journey.ts b/tests/e2e/cross-version-wire/terminal-streams/terminal-skew-journey.ts similarity index 100% rename from tests/e2e/cross-version-wire/terminal-skew-journey.ts rename to tests/e2e/cross-version-wire/terminal-streams/terminal-skew-journey.ts diff --git a/tests/e2e/cross-version-wire/terminal-wire-link.ts b/tests/e2e/cross-version-wire/terminal-streams/terminal-wire-link.ts similarity index 100% rename from tests/e2e/cross-version-wire/terminal-wire-link.ts rename to tests/e2e/cross-version-wire/terminal-streams/terminal-wire-link.ts diff --git a/tests/e2e/cross-version-wire/versioned-terminal-wire.ts b/tests/e2e/cross-version-wire/terminal-streams/versioned-terminal-wire.ts similarity index 93% rename from tests/e2e/cross-version-wire/versioned-terminal-wire.ts rename to tests/e2e/cross-version-wire/terminal-streams/versioned-terminal-wire.ts index aa62e24a840..0d8edae8905 100644 --- a/tests/e2e/cross-version-wire/versioned-terminal-wire.ts +++ b/tests/e2e/cross-version-wire/terminal-streams/versioned-terminal-wire.ts @@ -2,7 +2,7 @@ import { importReleaseCheckoutModule, materializeReleaseCheckout, type ReleaseCheckout -} from './release-checkout' +} from '../release-checkouts/release-checkout' // Keep cross-build structural views minimal so legitimate internal differences cannot bind the harness to one version. @@ -95,10 +95,10 @@ export const WORKING_TREE = 'working-tree' as const async function loadWorkingTreeBuild(): Promise { const [codec, dispatcher, terminalMethods, client] = await Promise.all([ - import('../../../src/shared/terminal/stream/terminal-stream-protocol'), - import('../../../src/main/runtime/rpc/dispatcher'), - import('../../../src/main/runtime/rpc/methods/terminal/terminal'), - import('../../../src/renderer/src/runtime/hosted-terminals/streams/registry/remote-runtime-terminal-multiplexer-registry') + import('../../../../src/shared/terminal/stream/terminal-stream-protocol'), + import('../../../../src/main/runtime/rpc/dispatcher'), + import('../../../../src/main/runtime/rpc/methods/terminal/terminal'), + import('../../../../src/renderer/src/runtime/hosted-terminals/streams/registry/remote-runtime-terminal-multiplexer-registry') ]) return { label: WORKING_TREE, diff --git a/tests/e2e/cross-version-wire/cross-version-worktree-identity-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/workspace-identity/cross-version-worktree-identity-downgrade.unit.test.ts similarity index 96% rename from tests/e2e/cross-version-wire/cross-version-worktree-identity-downgrade.unit.test.ts rename to tests/e2e/cross-version-wire/workspace-identity/cross-version-worktree-identity-downgrade.unit.test.ts index de1a1b79339..1b4e06a500e 100644 --- a/tests/e2e/cross-version-wire/cross-version-worktree-identity-downgrade.unit.test.ts +++ b/tests/e2e/cross-version-wire/workspace-identity/cross-version-worktree-identity-downgrade.unit.test.ts @@ -1,5 +1,8 @@ import { beforeAll, describe, expect, it } from 'vitest' -import { importReleaseCheckoutModule, materializeReleaseCheckout } from './release-checkout' +import { + importReleaseCheckoutModule, + materializeReleaseCheckout +} from '../release-checkouts/release-checkout' // Pin the pre-change reader: renamed session rows written by a new build must survive rollback and further renames. const PRE_STACK_REF = 'v1.4.199' @@ -95,7 +98,7 @@ beforeAll(async () => { checkout, 'src/main/persistence/tracking-repos/worktree-identity-migration.ts' ), - import('../../../src/main/persistence/tracking-repos/worktree-identity-migration') + import('../../../../src/main/persistence/tracking-repos/worktree-identity-migration') ]) preStackMigrate = migrateExportOf(oldModule) stackMigrate = migrateExportOf(newModule) diff --git a/tests/e2e/cross-version-wire/runtime-source-fence-downgrade.unit.test.ts b/tests/e2e/cross-version-wire/workspace-identity/runtime-source-fence-downgrade.unit.test.ts similarity index 81% rename from tests/e2e/cross-version-wire/runtime-source-fence-downgrade.unit.test.ts rename to tests/e2e/cross-version-wire/workspace-identity/runtime-source-fence-downgrade.unit.test.ts index 2616fccd4e4..8e10996e322 100644 --- a/tests/e2e/cross-version-wire/runtime-source-fence-downgrade.unit.test.ts +++ b/tests/e2e/cross-version-wire/workspace-identity/runtime-source-fence-downgrade.unit.test.ts @@ -8,17 +8,17 @@ import { tmpdir } from 'node:os' import { join } from 'node:path' import { afterAll, beforeAll, describe, expect, it } from 'vitest' import { z } from 'zod' -import { RUNTIME_CAPABILITIES } from '../../../src/shared/remote-runtime/protocol/protocol-version' -import { RUNTIME_SOURCE_FENCE_RUNTIME_CAPABILITY } from '../../../src/shared/remote-runtime/protocol/host-runtime-capabilities' -import { publishHostDescriptor } from '../../../src/main/runtime/hosts/platform-probe/host-descriptor' -import type { RuntimeMetadata } from '../../../src/shared/remote-runtime/bootstrap/runtime-bootstrap' -import type { ExpectedRuntimeSource } from '../../../src/shared/remote-runtime/rpc/runtime-rpc-envelope' -import { sendRequest } from '../../../src/cli/runtime/connection/transport' +import '../../../../src/shared/remote-runtime/protocol/protocol-version' +import '../../../../src/shared/remote-runtime/protocol/host-runtime-capabilities' +import { publishHostDescriptor } from '../../../../src/main/runtime/hosts/platform-probe/host-descriptor' +import type { RuntimeMetadata } from '../../../../src/shared/remote-runtime/bootstrap/runtime-bootstrap' +import type { ExpectedRuntimeSource } from '../../../../src/shared/remote-runtime/rpc/runtime-rpc-envelope' +import { sendRequest } from '../../../../src/cli/runtime/connection/transport' import { importReleaseCheckoutModule, materializeReleaseCheckout, releaseModuleExport -} from './release-checkout' +} from '../release-checkouts/release-checkout' const SUITE_TIMEOUT_MS = 180_000 // The last release without the fence; a newer baseline would refuse like the current host. @@ -96,8 +96,8 @@ beforeAll(async () => { const [oldDispatcher, oldCore, newDispatcher, newCore] = await Promise.all([ load('src/main/runtime/rpc/dispatcher.ts'), load('src/main/runtime/rpc/core.ts'), - import('../../../src/main/runtime/rpc/dispatcher'), - import('../../../src/main/runtime/rpc/core') + import('../../../../src/main/runtime/rpc/dispatcher'), + import('../../../../src/main/runtime/rpc/core') ]) releasedHost = hostBuildOf(oldDispatcher, oldCore) currentHost = hostBuildOf(newDispatcher, newCore) @@ -157,14 +157,4 @@ describe('runtime-source fence across versions', () => { expect(response).toMatchObject({ ok: false, error: { code: 'runtime_source_mismatch' } }) expect(ran).toBe(0) }) - - it('a new host runs a new CLI’s request meant for it and advertises the fence', async () => { - const { response, ran } = await call(currentHost, { - sourceId: SOURCE_A, - runtimeId: RUNTIME_ID - }) - expect(response).toMatchObject({ ok: true }) - expect(ran).toBe(1) - expect(RUNTIME_CAPABILITIES).toContain(RUNTIME_SOURCE_FENCE_RUNTIME_CAPABILITY) - }) }) diff --git a/tests/e2e/helpers/build-released-relay-bundle.mts b/tests/e2e/helpers/build-released-relay-bundle.mts index 856dfdb26ee..05c4cba6eee 100644 --- a/tests/e2e/helpers/build-released-relay-bundle.mts +++ b/tests/e2e/helpers/build-released-relay-bundle.mts @@ -1,10 +1,10 @@ // Run release bundling through tsx so Playwright never imports its ESM-only build tooling. // COMPAT(legacy-relay-bridge): revisit 2027-01-15, with src/main/ssh/legacy-relay/. -import { materializeReleaseCheckout } from '../cross-version-wire/release-checkout.ts' +import { materializeReleaseCheckout } from '../cross-version-wire/release-checkouts/release-checkout.ts' import { buildReleasedRelayBundle, PREVIOUS_RELAY_REF -} from '../cross-version-wire/released-relay-daemon.ts' +} from '../cross-version-wire/relay/released-relay-daemon.ts' const built = await buildReleasedRelayBundle(await materializeReleaseCheckout(PREVIOUS_RELAY_REF)) process.stdout.write(`${JSON.stringify(built)}\n`) diff --git a/tests/e2e/helpers/legacy-relay-docker-host.ts b/tests/e2e/helpers/legacy-relay-docker-host.ts index 3068d56f191..1ebd78297a5 100644 --- a/tests/e2e/helpers/legacy-relay-docker-host.ts +++ b/tests/e2e/helpers/legacy-relay-docker-host.ts @@ -10,7 +10,7 @@ import { SshChannelMultiplexer } from '../../../src/main/ssh/protocol/ssh-channe import { leaveShellInReleasedRelay, openShellRelayTransport -} from '../cross-version-wire/released-relay-transport' +} from '../cross-version-wire/relay/released-relay-transport' import { execDockerSshHostTargetCommand, type DockerSshHostTarget } from './docker-ssh-host-target' export type DockerReleasedRelay = { dir: string; version: string } diff --git a/tests/e2e/remote-terminal-input-model-link.ts b/tests/e2e/remote-terminal-input-model-link.ts index 97ec39c60e8..fb67dbf04b5 100644 --- a/tests/e2e/remote-terminal-input-model-link.ts +++ b/tests/e2e/remote-terminal-input-model-link.ts @@ -10,7 +10,7 @@ import { import { createHostTerminalRuntimeStub, type HostTerminalRuntimeStub -} from './cross-version-wire/host-terminal-runtime-stub' +} from './cross-version-wire/terminal-streams/host-terminal-runtime-stub' export const MODEL_TERMINAL_HANDLE = 'terminal-1' diff --git a/tests/e2e/session-tabs/active-tab-publication.test-fixture.ts b/tests/e2e/session-tabs/active-tab-publication.test-fixture.ts index 1519611ab5e..b504fb491d6 100644 --- a/tests/e2e/session-tabs/active-tab-publication.test-fixture.ts +++ b/tests/e2e/session-tabs/active-tab-publication.test-fixture.ts @@ -8,7 +8,7 @@ import { MOCK_GIT_WORKTREES, scanLocalRepoWorktreesForResolutionMock } from '../../../src/main/runtime/orca-runtime-test-mocks/setup.spec' -import '../../../src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec' +import '../../../src/main/runtime/construction/test-context/runtime-test-module-registration.spec' import { OrcaRuntimeService } from '../../../src/main/runtime/orca-runtime' import { HEADLESS_LEAF_ID, @@ -17,7 +17,7 @@ import { makeHeadlessTerminalLayout, makeRuntimeStoreWithWorkspaceSession, makeWorkspaceSessionWithHeadlessTerminal -} from '../../../src/main/runtime/orca-runtime-tests/orca-runtime-test-fixtures.spec' +} from '../../../src/main/runtime/construction/test-context/orca-runtime-test-fixtures.spec' export function createRuntimeFixture(attached = true) { vi.mocked(listWorktrees).mockResolvedValue(MOCK_GIT_WORKTREES) diff --git a/tests/e2e/session-tabs/mobile-session-legacy-navigation.unit.test.ts b/tests/e2e/session-tabs/mobile-session-legacy-navigation.unit.test.ts index 30ba99d5457..01298920827 100644 --- a/tests/e2e/session-tabs/mobile-session-legacy-navigation.unit.test.ts +++ b/tests/e2e/session-tabs/mobile-session-legacy-navigation.unit.test.ts @@ -1,10 +1,10 @@ -import '../../../src/main/runtime/orca-runtime-tests/runtime-test-module-registration.spec' +import '../../../src/main/runtime/construction/test-context/runtime-test-module-registration.spec' import { afterEach, describe, expect, it, vi } from 'vitest' import { setRuntimeBrowserCommandsFactory } from '../../../src/main/runtime/browser/installation/runtime-browser-commands-factory' import { RuntimeBrowserCommands } from '../../../src/main/runtime/browser/commands/browser-commands' import { withOpenedServeBrowserTab } from '../../../src/main/runtime/browser/headless/serve-browser-tab-layout' import type { OrcaRuntimeService } from '../../../src/main/runtime/orca-runtime' -import { TEST_WORKTREE_ID as WT } from '../../../src/main/runtime/orca-runtime-tests/orca-runtime-test-fixtures.spec' +import { TEST_WORKTREE_ID as WT } from '../../../src/main/runtime/construction/test-context/orca-runtime-test-fixtures.spec' import { createRuntimeFixture } from './active-tab-publication.test-fixture' import type { RuntimeMobileSessionTabsResult,