mirror of
https://github.com/stablyai/orca.git
synced 2026-10-30 08:37:49 +00:00
refactor(renderer): group agent-status records and reducers (#33665)
* refactor(renderer): group agent-status records and reducers * refactor(renderer): consolidate concrete type owner imports
This commit is contained in:
@@ -21509,15 +21509,15 @@
|
||||
"oracle": "Send a full Claude child roster, interleave Codex review lifecycle/tool/approval/completion hooks, and require identical snapshots plus zero publications. A later Claude child event must retain the original prompt and roster, and a real child completion must shrink it. After Claude Stop, keep its mobile transcript and saved resume identity while its identified process remains live or unverifiable; accept the first provider replacement after confirmed exit or suspension. Replay must admit records in order, retain the file on failed admission, and concurrent starts, stop during replay, or a second stop during a queued restart must not leave a listener. Pending owner probes cannot publish or accept an old request after stop, restart, or status disable/re-enable; interrupted replay stays durable.",
|
||||
"commands": [
|
||||
"SKIP_BUILD=1 ORCA_BACKGROUND_LAUNCH=1 xvfb-run -a pnpm exec playwright test --config tests/playwright.config.ts tests/e2e/nested-agent-idle-session-owner.spec.ts --project=electron-headless --workers=1 --repeat-each=3",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts src/wsl-guest/relay-http-owner-probe-lifecycle.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts src/wsl-guest/relay-http-owner-probe-lifecycle.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 ORCA_E2E_RECORD_VIDEO=1 pnpm exec playwright test --config tests/playwright.config.ts tests/e2e/nested-agent-idle-session-owner.spec.ts --project=electron-headless --workers=1 --repeat-each=3",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec playwright test --config tests/playwright.config.ts tests/e2e/nested-agent-idle-session-owner.spec.ts --project=electron-headless --workers=1",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/renderer/src/store/slices/agent-status-provider-session.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts --maxWorkers=2"
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/renderer/src/store/slices/agent-status-provider-session.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts --maxWorkers=2"
|
||||
],
|
||||
"testFiles": [
|
||||
"src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts",
|
||||
@@ -21534,7 +21534,7 @@
|
||||
"src/wsl-guest/agent-hook-provider-normalization.test.ts",
|
||||
"src/main/agent-hooks/server-nested-agent-boundaries.test.ts",
|
||||
"src/main/agent-hooks/server-nested-agent-consumers.test.ts",
|
||||
"src/renderer/src/store/slices/agent-status-entry-contracts.test.ts",
|
||||
"src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts",
|
||||
"src/main/agent-hooks/server-nested-agent-roster.test.ts",
|
||||
"src/main/agent-hooks/server-nested-agent-model.test.ts",
|
||||
"src/main/agent-hooks/server-ingest-remote.test.ts"
|
||||
@@ -21563,7 +21563,7 @@
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-nested-resume.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts src/wsl-guest/relay-http-owner-probe-lifecycle.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts src/wsl-guest/relay-http-owner-probe-lifecycle.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts src/main/agent-hooks/server-http-owner-probe-lifecycle.test.ts src/wsl-guest/relay-http-owner-probe-lifecycle.test.ts --maxWorkers=2",
|
||||
"result": "passed",
|
||||
"durationSeconds": 75.69,
|
||||
"summary": "197 tests across 24 files pass after adversarial review. New regressions cover pending HTTP and process-probe publication after stop/restart/status disable/re-enable, fixed-token relay restarts, interrupted spool durability, and a second stop while a restart is queued."
|
||||
@@ -21582,7 +21582,7 @@
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-nested-resume.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-idle-process-owner.test.ts src/wsl-guest/relay-idle-process-owner.test.ts tests/e2e/nested-agent-idle-owner.unit.test.ts src/shared/agent-process-presence-probe.test.ts src/shared/agent-hook-spool-drain.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/wsl-guest/relay-agent-presence.test.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts src/main/agent-hooks/server-start-failure-lifecycle.test.ts src/main/agent-hooks/server-startup-lifecycle.test.ts src/main/agent-hooks/spool.test.ts src/shared/agent-hook-spool-read.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"result": "passed",
|
||||
"durationSeconds": 8.34,
|
||||
"summary": "187 tests across 22 files pass on the final follow-up, covering idle process ownership, stale suspension/resume/unavailable/exit, legacy hosts, relay cache isolation, saved resume records, concurrent startup and durable ordered spool replay."
|
||||
@@ -21601,7 +21601,7 @@
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-tool-assistant-fields.test.ts src/renderer/src/store/slices/agent-status-provider-session.test.ts src/renderer/src/store/slices/agent-status-nested-resume.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/renderer/src/store/slices/agent-status-provider-session.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-boundaries.test.ts src/main/agent-hooks/server-nested-agent-consumers.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/renderer/src/store/slices/agent-status-provider-session.test.ts src/wsl-guest/agent-hook-provider-normalization.test.ts --maxWorkers=2",
|
||||
"result": "passed",
|
||||
"durationSeconds": 8.75,
|
||||
"summary": "132 tests across 13 files passed after review and CI boundary fixes, including actual mobile transcript selection, renderer Claude resume argv, host/workspace collision replacement, WSL transport equivalence, legacy unstamped local renderer entries, Pi identity-only boundaries, clock rollback and provider-isolated relay HTTP/spool/reconnect/teardown."
|
||||
@@ -21611,7 +21611,7 @@
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/renderer/src/store/slices/agent-status-tool-assistant-fields.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-agent-presence.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/wsl-guest/agent-hook-server.test.ts --maxWorkers=2",
|
||||
"result": "passed",
|
||||
"durationSeconds": 91.45,
|
||||
"summary": "97 tests across seven files passed, including full 32-child local and relay HTTP flows, legacy remote snapshots, model isolation, owner process contracts and renderer ownership. Finished/stale replacement controls added afterward are validated separately."
|
||||
@@ -21621,7 +21621,7 @@
|
||||
"runner": "local",
|
||||
"platform": "macos",
|
||||
"command": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-tool-assistant-fields.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status-entry-contracts.test.ts --maxWorkers=2",
|
||||
"currentCommand": "ORCA_BACKGROUND_LAUNCH=1 pnpm exec vitest run --config config/vitest.config.ts src/main/agent-hooks/server-nested-agent-roster.test.ts src/main/agent-hooks/server-ingest-remote.test.ts src/main/agent-hooks/server-nested-agent-model.test.ts src/main/agent-hooks/server-hook-http-ingest.test.ts src/main/agent-hooks/server-turn-started-at.test.ts src/main/agent-hooks/server-status-listener-fanout.test.ts src/main/agent-hooks/terminal-handle-row-identity.test.ts src/renderer/src/store/slices/agent-status/agent-status-entry-contracts.test.ts --maxWorkers=2",
|
||||
"result": "passed",
|
||||
"durationSeconds": 180.43,
|
||||
"summary": "Final implementation passes 64 tests in six files, including local/relay finished-provider replacement, stale-provider replacement, 32-child ownership, legacy remote snapshots, turn clocks and renderer identity."
|
||||
|
||||
@@ -6,8 +6,9 @@ import { tmpdir } from 'node:os'
|
||||
import { join } from 'node:path'
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { AppState } from '@/store/types'
|
||||
import type { AgentStatusBatchUpdate } from '@/store/slices/agent-status'
|
||||
import { MAX_LIVE_AGENT_STATUSES } from '@/store/slices/agent-status'
|
||||
import type { AgentStatusBatchUpdate } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import '@/store/slices/agent-status'
|
||||
import { MAX_LIVE_AGENT_STATUSES } from '@/store/slices/agent-status/agent-status-capacity-eviction'
|
||||
import {
|
||||
createTestStore,
|
||||
makeTab,
|
||||
|
||||
@@ -10618,7 +10618,7 @@
|
||||
"src/renderer/src/store/slices/agent-status-live-map-leak.test.ts": 2819,
|
||||
"src/renderer/src/store/slices/agent-status-main-agent-fact.test.ts": 1531,
|
||||
"src/renderer/src/store/slices/agent-status-manual-sleep-capture.test.ts": 1409,
|
||||
"src/renderer/src/store/slices/agent-status-pane-keyed-records.test.ts": 56,
|
||||
"src/renderer/src/store/slices/agent-status/agent-status-pane-keyed-records.test.ts": 56,
|
||||
"src/renderer/src/store/slices/agent-status-pr-refresh-handoff.test.ts": 1240,
|
||||
"src/renderer/src/store/slices/agent-status-provider-session.test.ts": 1400,
|
||||
"src/renderer/src/store/slices/agent-status-quit-capture-resumable-agents.test.ts": 1480,
|
||||
|
||||
@@ -3,7 +3,7 @@ import type { Repo } from '../../../../shared/repo-types'
|
||||
import { makePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { Worktree } from '../../../../shared/worktree/types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { buildActivityEvents } from './activity-event-builder'
|
||||
import { buildAgentPaneThreads } from './activity-thread-builder'
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @vitest-environment happy-dom
|
||||
import { afterEach, beforeEach, expect, it, vi } from 'vitest'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { ActivityEvent, AgentPaneThread } from './activity-thread-types'
|
||||
import { makeTab, makeWorktree } from './ActivityPrototypePage-test-fixtures'
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { ActivityEvent, AgentPaneThread } from './activity-thread-types'
|
||||
import { makeTab, makeWorktree } from './ActivityPrototypePage-test-fixtures'
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { toast } from 'sonner'
|
||||
import { useAppStore } from '@/store'
|
||||
import { translate } from '@/i18n/i18n'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AgentStatusCacheIdentity } from '../../../../shared/agent-status-types'
|
||||
import { activityThreadStatusId } from './activity-thread-presentation'
|
||||
import type { AgentPaneThread } from './activity-thread-types'
|
||||
|
||||
@@ -3,7 +3,7 @@ import type {
|
||||
AgentStatusEntry,
|
||||
AgentStateHistoryEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { makePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import {
|
||||
buildActivityEvents,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { freshActivityLiveAgentState } from './activity-event-state'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type {
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { AutomationRun } from '../../../../shared/automations-types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { hasAutomationRunCompletionEvidence } from './automation-run-completion-evidence'
|
||||
|
||||
const PANE = 'tab-1:11111111-1111-4111-8111-111111111111'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { AutomationRun } from '../../../../shared/automations-types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { automationRunMatchesPaneKey } from './automation-run-open-target'
|
||||
|
||||
function isCompletionAfterDispatch(entry: AgentStatusEntry, dispatchedAt: number): boolean {
|
||||
|
||||
@@ -3,7 +3,7 @@ import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import { makePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { Worktree } from '../../../../shared/worktree/types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import {
|
||||
buildDashboardSnapshot,
|
||||
type DashboardSnapshotInput as DashboardSnapshotState
|
||||
|
||||
@@ -3,7 +3,7 @@ import { useShallow } from 'zustand/react/shallow'
|
||||
import { useAppStore } from '@/store'
|
||||
import { isExplicitAgentStatusFresh } from '@/lib/agent-status'
|
||||
import type { DashboardAgentRow } from './useDashboardData'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { FolderWorkspace } from '../../../../shared/folder-workspace-types'
|
||||
import type { Repo } from '../../../../shared/repo-types'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
|
||||
@@ -5,7 +5,7 @@ import type {
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { TerminalLayoutSnapshot, TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import { migrationUnsupportedToAgentStatusEntry } from '../../../../shared/migration-unsupported-agent-entry'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AppState } from '@/store/types'
|
||||
import { applyAgentRowLineage, type DashboardAgentRowWithLineage } from './agent-row-lineage'
|
||||
import { buildWorktreeAgentRows } from '../sidebar/worktree-agent-rows'
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ import {
|
||||
structuredAgentSessionRowStateStartedAt
|
||||
} from '../../../../shared/structured-agent-session-status-started-at'
|
||||
import { agentMainAgentVerdict } from '../../../../shared/agent-main-agent-verdict'
|
||||
import type { AgentStatusBatchTransaction } from '@/store/slices/agent-status-contract'
|
||||
import type { AgentStatusBatchTransaction } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { StructuredTab } from './structured-agent-session-tabs'
|
||||
|
||||
/** Copy modern child views verbatim; convert legacy host task lists and retain the legacy live-agent roster. */
|
||||
|
||||
@@ -4,7 +4,7 @@ import {
|
||||
type AgentStatusEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { TerminalLayoutSnapshot, TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { applyAgentRowLineage } from '@/components/dashboard/agent-row-lineage'
|
||||
import { makePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import { comparePaneKeysOrdinal } from './worktree-agent-row-order'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type {
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext
|
||||
|
||||
@@ -3,7 +3,7 @@ import type {
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import { makePaneKey, parsePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import {
|
||||
|
||||
@@ -5,7 +5,7 @@ import type {
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { Tab } from '../../../../shared/tab-types'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { makePaneKey } from '../../../../shared/stable-pane-id'
|
||||
import { getLiveEntriesFullRebuildCountForTests } from './worktree-agent-live-index-patch'
|
||||
import {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AppState } from '@/store/types'
|
||||
import type {
|
||||
AgentStatusEntry,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { DashboardAgentRow } from '@/components/dashboard/useDashboardData'
|
||||
import { isExplicitAgentStatusFresh } from '@/lib/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import {
|
||||
AGENT_STATUS_STALE_AFTER_MS,
|
||||
type AgentStatusEntry,
|
||||
|
||||
+1
-1
@@ -21,7 +21,7 @@ import {
|
||||
import { buildPaneConnectionDeps } from './pty-connection-test-deps'
|
||||
import { createInitialStoreState } from './pty-connection-test-store-fixtures'
|
||||
import type { StoreState } from './pty-connection-test-store-state'
|
||||
import type { AgentStatusSlice } from '@/store/slices/agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from '@/store/slices/agent-status/agent-status-slice-contract'
|
||||
import { normalizeLaunchConfigRegistrationMetadata } from '@/store/slices/agent-status-launch-config'
|
||||
import type { MockTransport } from './pty-connection-test-pane-fixtures'
|
||||
import {
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@ import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import type {
|
||||
AgentLaunchConfigRegistryEntry,
|
||||
AgentLaunchConfigRegistrationMetadata
|
||||
} from '@/store/slices/agent-status-contract'
|
||||
} from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { ColdRestoreAgentResumeStartup } from './fresh-spawn-types'
|
||||
import type { ConnectPanePtySession } from './connect-pane-pty-session'
|
||||
import { bindSettlePaneSerializer } from './pane-serializer-settle'
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
import { afterEach, beforeEach, expect, it, vi } from 'vitest'
|
||||
import type { TerminalAttachmentLaunchResult } from '../../../../shared/terminal-attachment-launch-result'
|
||||
import type { ConnectPanePtySession } from './pty-connection/connect-pane-pty-session'
|
||||
import type { AgentLaunchConfigRegistryEntry } from '@/store/slices/agent-status-contract'
|
||||
import type { AgentLaunchConfigRegistryEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { bindCaptureTransportOutputCallbacks } from './pty-connection/transport-output-callbacks'
|
||||
import { bindSettlePaneSerializer } from './pty-connection/pane-serializer-settle'
|
||||
import { applyTerminalLaunchResult } from './pty-connection/terminal-launch-result-policy'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { expect, vi } from 'vitest'
|
||||
import type {
|
||||
AgentStatusBatchTransaction,
|
||||
AgentStatusBatchUpdate
|
||||
} from '../store/slices/agent-status'
|
||||
} from '../store/slices/agent-status/agent-status-contract'
|
||||
import type { AppState } from '../store/types'
|
||||
import { makePaneKey } from '../../../shared/stable-pane-id'
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { AgentStatusIpcPayload } from '../../../../shared/agent-status-types'
|
||||
import type { AgentStatusBatchTransaction } from '@/store/slices/agent-status'
|
||||
import type { AgentStatusBatchTransaction } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AgentStatusPaneRoutingIndex } from './agent-status-pane-routing-index'
|
||||
|
||||
export type PendingAgentStatusEvent = {
|
||||
|
||||
@@ -6,7 +6,7 @@ import { normalizeProgramStatusFacet } from '../../../../shared/program-status/f
|
||||
import { resolveAgentStatusTerminalTitle } from '@/lib/agent-status-terminal-title'
|
||||
import { track } from '@/lib/telemetry'
|
||||
import { resolveAgentPaneAuthorityKey } from '@/store/slices/agent-pane-authority'
|
||||
import type { AgentStatusUpdate } from '@/store/slices/agent-status'
|
||||
import type { AgentStatusUpdate } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { observeAgentHookCompletionForNotification } from '../agent-hook-completion-notifications'
|
||||
import { useAppStore } from '../../store'
|
||||
import {
|
||||
|
||||
@@ -4,7 +4,7 @@ import type { AppState } from '@/store/types'
|
||||
import type {
|
||||
AgentProgramStatusUpdate,
|
||||
AgentProviderSessionUpdate
|
||||
} from '@/store/slices/agent-status'
|
||||
} from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type {
|
||||
AgentStatusApplyResult,
|
||||
AgentStatusBatchContext,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { AgentStatusBatchUpdate } from '../../store/slices/agent-status'
|
||||
import type { AgentStatusBatchUpdate } from '../../store/slices/agent-status/agent-status-contract'
|
||||
import {
|
||||
buildStoreState,
|
||||
FUTURE_LEAF_ID,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { AgentStatusMetadata } from '../../store/slices/agent-status-contract'
|
||||
import type { AgentStatusMetadata } from '../../store/slices/agent-status/agent-status-contract'
|
||||
import {
|
||||
normalizeAgentStatusPayload,
|
||||
type AgentStatusIpcPayload,
|
||||
|
||||
@@ -5,7 +5,10 @@ import {
|
||||
makeWorktree,
|
||||
TEST_REPO
|
||||
} from '../store/slices/store-test-helpers'
|
||||
import type { AgentStatusBatchUpdate, AgentStatusUpdate } from '../store/slices/agent-status'
|
||||
import type {
|
||||
AgentStatusBatchUpdate,
|
||||
AgentStatusUpdate
|
||||
} from '../store/slices/agent-status/agent-status-contract'
|
||||
import type { AppState } from '../store/types'
|
||||
import { makePaneKey } from '../../../shared/stable-pane-id'
|
||||
import { folderWorkspaceKey } from '../../../shared/workspace-scope'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { AgentStatusUpdate } from '../store/slices/agent-status'
|
||||
import type { AgentStatusUpdate } from '../store/slices/agent-status/agent-status-contract'
|
||||
import {
|
||||
buildStoreState,
|
||||
expectWorktreeRouting,
|
||||
|
||||
@@ -6,7 +6,7 @@ import {
|
||||
resolveViewedUnreadSubjectKey
|
||||
} from '@/attention/agent-attention-acknowledgement'
|
||||
import { createTestStore, makeTab, makeUnifiedTab } from '../store/slices/store-test-helpers'
|
||||
import type { RetainedAgentEntry } from '../store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '../store/slices/agent-status/agent-status-contract'
|
||||
import { FLOATING_TERMINAL_WORKTREE_ID, getDefaultSettings } from '../../../shared/constants'
|
||||
import { makePaneKey } from '../../../shared/stable-pane-id'
|
||||
|
||||
|
||||
@@ -3,7 +3,8 @@ import { useAppStore } from '@/store'
|
||||
import type { AppState } from '@/store/types'
|
||||
import type { TerminalTab } from '../../../shared/terminal-tab-types'
|
||||
import { parsePaneKey } from '../../../shared/stable-pane-id'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from '@/store/slices/agent-status'
|
||||
import '@/store/slices/agent-status'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from '@/store/slices/agent-status/agent-status-recovery-collection'
|
||||
import { singlePaneLayoutSnapshot } from '@/store/slices/terminal-helpers'
|
||||
import { readLastTerminalInputAt } from './terminal-input-activity-coalescing'
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { SleepingAgentSessionRecord } from '../../../shared/agent-session-resume'
|
||||
import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
import { makePaneKey } from '../../../shared/stable-pane-id'
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { PaneForegroundAgentEntry } from '@/store/slices/pane-foreground-agent'
|
||||
import type { SleepingAgentSessionRecord } from '../../../shared/agent-session-resume'
|
||||
import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
|
||||
@@ -16,7 +16,7 @@ import type {
|
||||
} from '../../../shared/agent-status-types'
|
||||
import type { TerminalLayoutSnapshot, TerminalTab } from '../../../shared/terminal-tab-types'
|
||||
import type { TerminalAgent } from '../../../shared/terminal-agent'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
|
||||
// Keep pre-index scans as the randomized differential oracle for exact resolver behavior.
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
import type { TerminalAgent } from '../../../shared/terminal-agent'
|
||||
import { parsePaneKey } from '../../../shared/stable-pane-id'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { agentTypeToIconAgent } from './agent-status'
|
||||
|
||||
/** Index iconable panes once per status-map identity instead of scanning globally per mounted tab. Preserve insertion order: first-match resolution decides split-tab icons. */
|
||||
|
||||
@@ -10,7 +10,7 @@ import {
|
||||
import type { AgentStatusEntry, AgentType } from '../../../shared/agent-status-types'
|
||||
import type { TerminalLayoutSnapshot, TerminalTab } from '../../../shared/terminal-tab-types'
|
||||
import type { TerminalAgent } from '../../../shared/terminal-agent'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
|
||||
// Compose focused then sibling resolution exactly as useTabAgent does.
|
||||
function resolveTabAgent(
|
||||
|
||||
@@ -2,7 +2,7 @@ import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
import type { TerminalLayoutSnapshot } from '../../../shared/terminal-tab-types'
|
||||
import type { TerminalAgent } from '../../../shared/terminal-agent'
|
||||
import { isTerminalLeafId, makePaneKey } from '../../../shared/stable-pane-id'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import { agentTypeToIconAgent } from './agent-status'
|
||||
import {
|
||||
firstTabAgentExcludingLeaf,
|
||||
|
||||
@@ -4,7 +4,7 @@ import { act, createElement } from 'react'
|
||||
import { createRoot, type Root } from 'react-dom/client'
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import { useAppStore } from '@/store'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AgentStatusEntry, AgentType } from '../../../shared/agent-status-types'
|
||||
import { makePaneKey } from '../../../shared/stable-pane-id'
|
||||
import type { TerminalLayoutSnapshot, TerminalTab } from '../../../shared/terminal-tab-types'
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
import type { SleepingAgentSessionRecord } from '../../../shared/agent-session-resume'
|
||||
import { agentStatusEvidenceObservedAt } from '../../../shared/agent-status-freshness'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import path from 'node:path'
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status'
|
||||
import type { RetainedAgentEntry } from '@/store/slices/agent-status/agent-status-contract'
|
||||
import type { OpenFile } from '@/store/slices/editor'
|
||||
import type { AgentStatusEntry } from '../../../shared/agent-status-types'
|
||||
import type { SleepingAgentSessionRecord } from '../../../shared/agent-session-resume'
|
||||
|
||||
@@ -2,7 +2,7 @@ import { afterEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import { AGENT_STATUS_HYDRATE_MAX_AGE_MS } from '../../../../shared/agent-status-freshness'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from './agent-status'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import { createTestStore } from './store-test-helpers'
|
||||
import {
|
||||
sanitizeAcknowledgedAgentsByPaneKey,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { rendererAgentStatusObservations } from '../../lib/renderer-agent-status-observations'
|
||||
import {
|
||||
@@ -10,7 +10,7 @@ import {
|
||||
boundRecentlyRetiredAgentStatusPaneKeys,
|
||||
movePaneKeyedRecord,
|
||||
removePaneKeys
|
||||
} from './agent-status-pane-keyed-records'
|
||||
} from './agent-status/agent-status-pane-keyed-records'
|
||||
import {
|
||||
getLeafIdFromPaneKey,
|
||||
getTabIdFromPaneKey,
|
||||
|
||||
@@ -4,11 +4,12 @@ import {
|
||||
type AgentStatusEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { AppState } from '../types'
|
||||
import {
|
||||
MAX_LIVE_AGENT_STATUSES,
|
||||
type AgentStatusBatchUpdate,
|
||||
type RetainedAgentEntry
|
||||
} from './agent-status'
|
||||
import './agent-status'
|
||||
import { MAX_LIVE_AGENT_STATUSES } from './agent-status/agent-status-capacity-eviction'
|
||||
import type {
|
||||
AgentStatusBatchUpdate,
|
||||
RetainedAgentEntry
|
||||
} from './agent-status/agent-status-contract'
|
||||
import type { GeneratedTabTitleUpdate } from './terminal-tab-title-batch'
|
||||
import { createTestStore, makeTab, makeUnifiedTab } from './store-test-helpers'
|
||||
import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/layout-owner-switch'
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { collectWorktreeIdsForConnection } from './agent-status-connection-worktree-scope'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status-migration-unsupported-entries'
|
||||
import { removePaneKeys, removePaneKeysByTabPrefix } from './agent-status-pane-keyed-records'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status/agent-status-migration-unsupported-entries'
|
||||
import {
|
||||
removePaneKeys,
|
||||
removePaneKeysByTabPrefix
|
||||
} from './agent-status/agent-status-pane-keyed-records'
|
||||
|
||||
/** Actions for removing transient rows and migration-era cache entries. */
|
||||
export function createAgentStatusCleanupActions(
|
||||
|
||||
@@ -3,11 +3,11 @@ import type {
|
||||
DropAgentStatusByTabPrefixOptions,
|
||||
DropAgentStatusOptions,
|
||||
DropHibernatedAgentPaneOptions
|
||||
} from './agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
} from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { buildAgentStatusTabPrefixDropPatch } from './agent-status-drop-reducer'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status-migration-unsupported-entries'
|
||||
import { buildAgentStatusTabPrefixDropPatch } from './agent-status/agent-status-drop-reducer'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status/agent-status-migration-unsupported-entries'
|
||||
import {
|
||||
retainedAgentEntryFromLive,
|
||||
shouldReplaceRetainedWithLive
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from './agent-status'
|
||||
import { RECENTLY_CLOSED_AGENT_STATUS_TAB_IDS_MAX } from './agent-status'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import './agent-status'
|
||||
import { RECENTLY_CLOSED_AGENT_STATUS_TAB_IDS_MAX } from './agent-status/agent-status-pane-keyed-records'
|
||||
import { createTestStore } from './store-test-helpers'
|
||||
|
||||
// Propagate renderer dismissal to main’s persisted hook cache or restart resurrects dismissed paneKeys.
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
import { describe } from 'vitest'
|
||||
import { registerAgentStatusNestedResumeTests } from './agent-status-nested-resume.spec'
|
||||
import { registerAgentStatusToolAssistantFieldsTests } from './agent-status-tool-assistant-fields.spec'
|
||||
import { registerAgentStatusPrRefreshHandoffTests } from './agent-status-pr-refresh-handoff.spec'
|
||||
|
||||
describe('agent-status-nested-resume', registerAgentStatusNestedResumeTests)
|
||||
describe('agent-status-tool-assistant-fields', registerAgentStatusToolAssistantFieldsTests)
|
||||
describe('agent-status-pr-refresh-handoff', registerAgentStatusPrRefreshHandoffTests)
|
||||
@@ -1,8 +1,8 @@
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import type { AgentLaunchConfigRegistryEntry } from './agent-status-contract'
|
||||
import type { AgentLaunchConfigRegistryEntry } from './agent-status/agent-status-contract'
|
||||
import { copyLaunchConfig } from '../../../../shared/agent-resume-record-from-status'
|
||||
import { sleepingRecordFromEntry } from './agent-status-sleeping-records'
|
||||
import { sleepingRecordFromEntry } from './agent-status/agent-status-sleeping-records'
|
||||
import {
|
||||
getLaunchConfigForEntry,
|
||||
launchConfigRegistryEntriesEqual,
|
||||
|
||||
@@ -8,7 +8,7 @@ import {
|
||||
import type {
|
||||
AgentLaunchConfigRegistryEntry,
|
||||
AgentLaunchConfigRegistrationMetadata
|
||||
} from './agent-status-contract'
|
||||
} from './agent-status/agent-status-contract'
|
||||
import { getLeafIdFromPaneKey, getTabIdFromPaneKey } from './agent-status-pane-key-tab-binding'
|
||||
import { launchConfigsEqual } from '../../../../shared/agent-resume-record-equivalence'
|
||||
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import { resolvePaneKey } from '../../lib/agent-status-pane-ownership'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import type {
|
||||
AgentStatusMetadata,
|
||||
AgentStatusPayload,
|
||||
AgentStatusRouting,
|
||||
AgentStatusTiming
|
||||
} from './agent-status-contract'
|
||||
} from './agent-status/agent-status-contract'
|
||||
import {
|
||||
resolveAgentPaneAuthorityKey,
|
||||
transferAgentPaneAuthorityAlias
|
||||
@@ -15,8 +15,8 @@ import {
|
||||
buildAgentStatusLiveEntry,
|
||||
type AgentStatusLiveEntryBuild,
|
||||
type AgentStatusLiveEntryRejection
|
||||
} from './agent-status-live-entry-builder'
|
||||
import { reduceAgentStatusLiveUpdate } from './agent-status-live-reducer'
|
||||
} from './agent-status/agent-status-live-entry-builder'
|
||||
import { reduceAgentStatusLiveUpdate } from './agent-status/agent-status-live-reducer'
|
||||
import type { FreshnessLiveEntryDelta } from './agent-status-freshness-scheduler'
|
||||
import {
|
||||
agentStatusTabAlreadyHasProtectedOrGeneratedTitle,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { describe, expect, it, vi } from 'vitest'
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { AgentStatusPayload } from './agent-status-contract'
|
||||
import type { AgentStatusPayload } from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { createAgentStatusLiveActions } from './agent-status-live-actions'
|
||||
|
||||
|
||||
@@ -5,7 +5,8 @@ import {
|
||||
type ParsedAgentStatusPayload
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { SleepingAgentSessionRecord } from '../../../../shared/agent-session-resume'
|
||||
import { MAX_LIVE_AGENT_STATUSES } from './agent-status'
|
||||
import './agent-status'
|
||||
import { MAX_LIVE_AGENT_STATUSES } from './agent-status/agent-status-capacity-eviction'
|
||||
import { createTestStore, makeTab, makeWorktree } from './store-test-helpers'
|
||||
import type { AppState } from '../types'
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest'
|
||||
import { createTestStore } from './store-test-helpers'
|
||||
import { sleepingRecordFromEntry } from './agent-status-sleeping-records'
|
||||
import { sleepingRecordFromEntry } from './agent-status/agent-status-sleeping-records'
|
||||
import { getAgentResumeArgv } from '../../../../shared/agent-session-resume'
|
||||
|
||||
export function registerAgentStatusNestedResumeTests(): void {
|
||||
|
||||
@@ -2,7 +2,7 @@ import type {
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import {
|
||||
getAgentRowGeneratedTitleText,
|
||||
|
||||
@@ -6,8 +6,11 @@ import type {
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import { tabHasProtectedTitle } from '../../../../shared/agent-generated-tab-title-rules'
|
||||
import type { DropAgentStatusByWorktreeOptions, RetainedAgentEntry } from './agent-status-contract'
|
||||
import type { AgentStatusTabPrefixDropState } from './agent-status-drop-reducer'
|
||||
import type {
|
||||
DropAgentStatusByWorktreeOptions,
|
||||
RetainedAgentEntry
|
||||
} from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusTabPrefixDropState } from './agent-status/agent-status-drop-reducer'
|
||||
|
||||
export function paneKeyMatchesAnyTabPrefix(paneKey: string, tabPrefixes: string[]): boolean {
|
||||
for (const prefix of tabPrefixes) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import {
|
||||
programStatusFacetsEqual,
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import type {
|
||||
AgentProviderSessionRecordMetadata,
|
||||
AgentProviderSessionRouting,
|
||||
AgentProviderSessionTiming
|
||||
} from './agent-status-contract'
|
||||
} from './agent-status/agent-status-contract'
|
||||
import {
|
||||
agentProviderSessionsEqual,
|
||||
getAgentResumeArgv,
|
||||
@@ -18,7 +18,7 @@ import {
|
||||
getTabIdFromPaneKey,
|
||||
isRecentlyClosedAgentStatusTab
|
||||
} from './agent-status-pane-key-tab-binding'
|
||||
import { removePaneKeys } from './agent-status-pane-keyed-records'
|
||||
import { removePaneKeys } from './agent-status/agent-status-pane-keyed-records'
|
||||
import { registryEntryMatchesStatus } from './agent-status-launch-config'
|
||||
import { copyLaunchConfig } from '../../../../shared/agent-resume-record-from-status'
|
||||
import { agentVerdictFields } from '../../../../shared/agent-main-agent-verdict'
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import { describe, expect, it } from 'vitest'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { AppState } from '../types'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from './agent-status'
|
||||
import './agent-status'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from './agent-status/agent-status-recovery-collection'
|
||||
import { createTestStore, makeTab } from './store-test-helpers'
|
||||
|
||||
function makeAgentEntry(overrides: {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import type { SleepingAgentSessionRecord } from '../../../../shared/agent-session-resume'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from './agent-status-recovery-collection'
|
||||
import { removeSleepingRecordsReplacedByManualWorktreeSleep } from './agent-status-sleeping-records'
|
||||
import { collectSleepingAgentSessionRecordsForWorktree } from './agent-status/agent-status-recovery-collection'
|
||||
import { removeSleepingRecordsReplacedByManualWorktreeSleep } from './agent-status/agent-status-sleeping-records'
|
||||
import { capturedResumeRecord } from '../../../../shared/agent-resume-record-from-status'
|
||||
import { getLaunchConfigForEntry } from './agent-status-launch-config'
|
||||
import { findAgentPaneWorktreeId, findTabForAgentEntry } from './agent-status-pane-key-tab-binding'
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import type { RetainedAgentEntry } from './agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { mergeCurrentOrchestrationContext } from './agent-status-orchestration-context'
|
||||
import { capRetainedAgents } from './agent-status-capacity-eviction'
|
||||
import { capRetainedAgents } from './agent-status/agent-status-capacity-eviction'
|
||||
|
||||
export function createAgentStatusRetentionActions(
|
||||
runtime: AgentStatusRuntime
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { AppState } from '../types'
|
||||
import type { RetainedAgentEntry } from './agent-status'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import { createTestStore, makeTab } from './store-test-helpers'
|
||||
|
||||
describe('agent status retention + prefix sweep', () => {
|
||||
|
||||
@@ -4,7 +4,7 @@ import {
|
||||
type AgentStatusState,
|
||||
AGENT_STATUS_STALE_AFTER_MS
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { RetainedAgentEntry } from './agent-status'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import { createTestStore, makeTab } from './store-test-helpers'
|
||||
import type { AgentStatusObservation } from '../../../../shared/agent-status-observation'
|
||||
import { isExplicitAgentStatusFresh } from '@/lib/pane-agent-evidence'
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
import type { StateCreator } from 'zustand'
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusBatchTransaction, AgentStatusBatchUpdate } from './agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type {
|
||||
AgentStatusBatchTransaction,
|
||||
AgentStatusBatchUpdate
|
||||
} from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { GeneratedTabTitleUpdate } from './terminal-tab-title-batch'
|
||||
import { createFreshnessScheduler } from './agent-status-freshness-scheduler'
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ import type { AppState } from '../types'
|
||||
import { agentMeta, agentTitle } from '@/components/activity/activity-thread-presentation'
|
||||
import { activationTreatsNoteAsFinished } from '@/lib/sleeping-agent-pane-ownership'
|
||||
import { resolveAgentStatusLiveEntryStateHistory } from '../../../../shared/agent-status-live-entry-state-history'
|
||||
import { deriveAgentStatusLiveFacts } from './agent-status-live-facts'
|
||||
import { deriveAgentStatusLiveFacts } from './agent-status/agent-status-live-facts'
|
||||
import {
|
||||
recoveryRecordMatches,
|
||||
sleepingRecordsEquivalentIgnoringCaptureTime
|
||||
@@ -17,7 +17,7 @@ import {
|
||||
isValidCompletedAgentHibernationEntry,
|
||||
manualSleepCaptureEntry,
|
||||
sleepingRecordFromEntry
|
||||
} from './agent-status-sleeping-records'
|
||||
} from './agent-status/agent-status-sleeping-records'
|
||||
|
||||
// Every copy of a row's verdict carries it: history, sleep records and their equality checks.
|
||||
// A copy that kept only `interrupted` would read a failure as a clean finish.
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
import type { DropAgentStatusByWorktreeOptions, RetainedAgentEntry } from './agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type {
|
||||
DropAgentStatusByWorktreeOptions,
|
||||
RetainedAgentEntry
|
||||
} from './agent-status/agent-status-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import type { AgentStatusRuntime } from './agent-status-runtime'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status-migration-unsupported-entries'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status/agent-status-migration-unsupported-entries'
|
||||
import {
|
||||
getTabIdFromPaneKey,
|
||||
normalizePaneKeySet,
|
||||
@@ -10,7 +13,7 @@ import {
|
||||
retainedAgentEntryFromLive,
|
||||
shouldReplaceRetainedWithLive
|
||||
} from './agent-status-pane-key-tab-binding'
|
||||
import { removePaneKeys } from './agent-status-pane-keyed-records'
|
||||
import { removePaneKeys } from './agent-status/agent-status-pane-keyed-records'
|
||||
import { agentTurnEndedOnPurpose } from '../../../../shared/agent-main-agent-verdict'
|
||||
|
||||
export function createAgentStatusWorktreeDropActions(
|
||||
|
||||
@@ -6,12 +6,12 @@ import {
|
||||
import { flushMicrotasks } from './agent-status-test-harness'
|
||||
import { createTestStore, makeTab, makeTabGroup, makeUnifiedTab } from './store-test-helpers'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from './agent-status'
|
||||
import type { RetainedAgentEntry } from './agent-status/agent-status-contract'
|
||||
import {
|
||||
structuredAgentSessionPaneKey,
|
||||
structuredAgentSessionTabId
|
||||
} from '../../../../shared/structured-agent-session-projection'
|
||||
import { buildAgentStatusTabPrefixDropPatch } from './agent-status-drop-reducer'
|
||||
import { buildAgentStatusTabPrefixDropPatch } from './agent-status/agent-status-drop-reducer'
|
||||
import { createStoreSessionMockApi } from './store-session-test-harness'
|
||||
import { drawTabsFromMain } from './tabs-drawn-from-main.test-fixture'
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { StateCreator } from 'zustand'
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
import type { AgentStatusSlice } from './agent-status/agent-status-slice-contract'
|
||||
import { createAgentStatusRuntime } from './agent-status-runtime'
|
||||
import { createAgentStatusAuthorityActions } from './agent-status-authority-actions'
|
||||
import { createAgentStatusCleanupActions } from './agent-status-cleanup-actions'
|
||||
@@ -15,53 +15,12 @@ import { createAgentStatusRecoveryActions } from './agent-status-recovery-action
|
||||
import { createAgentStatusRetentionActions } from './agent-status-retention-actions'
|
||||
|
||||
// Keep this path as the public contract for callers while implementation details live beside it.
|
||||
export type {
|
||||
AgentLaunchConfigRegistryEntry,
|
||||
AgentLaunchConfigRegistrationMetadata,
|
||||
AgentProviderSessionRecordMetadata,
|
||||
AgentProviderSessionRouting,
|
||||
AgentProviderSessionTiming,
|
||||
AgentStatusBatchTransaction,
|
||||
AgentStatusBatchUpdate,
|
||||
AgentStatusMetadata,
|
||||
AgentStatusPayload,
|
||||
AgentStatusRouting,
|
||||
AgentStatusTiming,
|
||||
AgentStatusUpdate,
|
||||
AgentProviderSessionUpdate,
|
||||
AgentProgramStatusUpdate,
|
||||
AgentStatusWorktreeShutdownReason,
|
||||
AllAgentSessionCaptureMode,
|
||||
DropAgentStatusByTabPrefixOptions,
|
||||
DropAgentStatusByWorktreeOptions,
|
||||
DropHibernatedAgentPaneOptions,
|
||||
RetainedAgentEntry,
|
||||
AgentStateHistoryEntry,
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext,
|
||||
AgentType,
|
||||
MigrationUnsupportedPtyEntry,
|
||||
ParsedAgentStatusPayload,
|
||||
AgentProviderSessionMetadata,
|
||||
ResumableTuiAgent,
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
} from './agent-status-contract'
|
||||
export type { AgentStatusSlice } from './agent-status-slice-contract'
|
||||
export {
|
||||
collectSleepingAgentSessionRecordsForWorktree,
|
||||
collectHibernatedCompletionEvidenceForWorktree
|
||||
} from './agent-status-recovery-collection'
|
||||
export { removeSleepingRecordsReplacedByManualWorktreeSleep } from './agent-status-sleeping-records'
|
||||
export {
|
||||
buildAgentStatusTabPrefixDropPatch,
|
||||
type AgentStatusTabPrefixDropState
|
||||
} from './agent-status-drop-reducer'
|
||||
export { MAX_LIVE_AGENT_STATUSES } from './agent-status-capacity-eviction'
|
||||
export {
|
||||
RECENTLY_CLOSED_AGENT_STATUS_TAB_IDS_MAX,
|
||||
RECENTLY_RETIRED_AGENT_STATUS_PANE_KEYS_MAX
|
||||
} from './agent-status-pane-keyed-records'
|
||||
|
||||
import './agent-status/agent-status-recovery-collection'
|
||||
import './agent-status/agent-status-sleeping-records'
|
||||
import './agent-status/agent-status-drop-reducer'
|
||||
import './agent-status/agent-status-capacity-eviction'
|
||||
import './agent-status/agent-status-pane-keyed-records'
|
||||
|
||||
export const createAgentStatusSlice: StateCreator<AppState, [], [], AgentStatusSlice> = (
|
||||
storeSet,
|
||||
|
||||
+6
-5
@@ -1,9 +1,10 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { TerminalPaneLayoutNode } from '../../../../shared/terminal-tab-types'
|
||||
import type { AppState } from '../../types'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import type { TerminalPaneLayoutNode } from '../../../../../shared/terminal-tab-types'
|
||||
import type { RetainedAgentEntry } from './agent-status-contract'
|
||||
import { AGENT_STATUS_STALE_AFTER_MS } from '../../../../shared/agent-status-types'
|
||||
import { getTabIdFromPaneKey } from './agent-status-pane-key-tab-binding'
|
||||
import '../../../../../shared/agent-status-types'
|
||||
import { AGENT_STATUS_STALE_AFTER_MS } from '../../../../../shared/agent-status-freshness'
|
||||
import { getTabIdFromPaneKey } from '../agent-status-pane-key-tab-binding'
|
||||
|
||||
const MAX_RETAINED_AGENTS = 500
|
||||
|
||||
+7
-23
@@ -1,22 +1,19 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AppState } from '../../types'
|
||||
import type {
|
||||
AgentStateHistoryEntry,
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext,
|
||||
AgentType,
|
||||
MigrationUnsupportedPtyEntry,
|
||||
ParsedAgentStatusPayload,
|
||||
TurnEndDisposition
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { AgentStatusObservation } from '../../../../shared/agent-status-observation'
|
||||
import type { ProgramStatusFacet } from '../../../../shared/program-status/facet'
|
||||
} from '../../../../../shared/agent-status-types'
|
||||
import type { AgentStatusObservation } from '../../../../../shared/agent-status-observation'
|
||||
import type { ProgramStatusFacet } from '../../../../../shared/program-status/facet'
|
||||
import type {
|
||||
AgentProviderSessionMetadata,
|
||||
ResumableTuiAgent,
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
SleepingAgentLaunchConfig
|
||||
} from '../../../../../shared/agent-session-resume'
|
||||
import type { TerminalTab } from '../../../../../shared/terminal-tab-types'
|
||||
|
||||
export type RetainedAgentEntry = {
|
||||
entry: AgentStatusEntry
|
||||
@@ -163,16 +160,3 @@ export type AgentStatusBatchTransaction = {
|
||||
apply: (update: AgentStatusBatchUpdate) => boolean
|
||||
afterCommit: (effect: () => void) => void
|
||||
}
|
||||
|
||||
export type {
|
||||
AgentStateHistoryEntry,
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext,
|
||||
AgentType,
|
||||
MigrationUnsupportedPtyEntry,
|
||||
ParsedAgentStatusPayload,
|
||||
AgentProviderSessionMetadata,
|
||||
ResumableTuiAgent,
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
}
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AppState } from '../../types'
|
||||
import type { DropAgentStatusByTabPrefixOptions } from './agent-status-contract'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status-migration-unsupported-entries'
|
||||
import {
|
||||
@@ -8,7 +8,7 @@ import {
|
||||
closedAgentStatusRetirementKeys,
|
||||
removePaneKeysByTabPrefix
|
||||
} from './agent-status-pane-keyed-records'
|
||||
import { findCompletedOrphanPaneKeysForTabClose } from './agent-status-pane-key-tab-binding'
|
||||
import { findCompletedOrphanPaneKeysForTabClose } from '../agent-status-pane-key-tab-binding'
|
||||
|
||||
/** The slice of app state the tab-prefix drop reduces over — narrow so callers
|
||||
* outside the store (the paired snapshot apply) can build the same patch. */
|
||||
@@ -0,0 +1,8 @@
|
||||
import { describe } from 'vitest'
|
||||
import { registerAgentStatusNestedResumeTests } from '../agent-status-nested-resume.spec'
|
||||
import { registerAgentStatusToolAssistantFieldsTests } from '../agent-status-tool-assistant-fields.spec'
|
||||
import { registerAgentStatusPrRefreshHandoffTests } from '../agent-status-pr-refresh-handoff.spec'
|
||||
|
||||
describe('agent-status-nested-resume', registerAgentStatusNestedResumeTests)
|
||||
describe('agent-status-tool-assistant-fields', registerAgentStatusToolAssistantFieldsTests)
|
||||
describe('agent-status-pr-refresh-handoff', registerAgentStatusPrRefreshHandoffTests)
|
||||
+13
-15
@@ -1,39 +1,37 @@
|
||||
import { sameAgentStatusTerminalOwner } from '../../../../shared/agent-status-terminal-owner'
|
||||
import type { AppState } from '../types'
|
||||
import { sameAgentStatusTerminalOwner } from '../../../../../shared/agent-status-terminal-owner'
|
||||
import type { AppState } from '../../types'
|
||||
import { resolveAgentStatusLiveEntryMainAgent } from './agent-status-live-entry-main-agent'
|
||||
import { resolveAgentStatusLiveEntryStateHistory } from '../../../../shared/agent-status-live-entry-state-history'
|
||||
import {
|
||||
pickHostTurnEnd,
|
||||
type MigrationUnsupportedPtyEntry,
|
||||
type AgentStatusEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import { resolveAgentStatusLiveEntryStateHistory } from '../../../../../shared/agent-status-live-entry-state-history'
|
||||
import { pickHostTurnEnd } from '../../../../../shared/agent-status-types'
|
||||
import type { MigrationUnsupportedPtyEntry } from '../../../../../shared/agent-status-ipc-payload'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import {
|
||||
agentProviderSessionsEqual,
|
||||
type AgentProviderSessionMetadata,
|
||||
type SleepingAgentLaunchConfig,
|
||||
type SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
} from '../../../../../shared/agent-session-resume'
|
||||
import {
|
||||
resolveAgentStatusIdentity,
|
||||
shouldSuppressInheritedTerminalStatus
|
||||
} from '../../../../shared/agent-status-identity'
|
||||
import { isCommandCodeNewTurnWhileWorking } from '../../../../shared/command-code-turn-boundary'
|
||||
} from '../../../../../shared/agent-status-identity'
|
||||
import { isCommandCodeNewTurnWhileWorking } from '../../../../../shared/command-code-turn-boundary'
|
||||
import type {
|
||||
AgentStatusMetadata,
|
||||
AgentStatusPayload,
|
||||
AgentStatusRouting,
|
||||
AgentStatusTiming
|
||||
} from './agent-status-contract'
|
||||
import { registryEntryMatchesStatus } from './agent-status-launch-config'
|
||||
import { findAgentPaneWorktreeId, getTabIdFromPaneKey } from './agent-status-pane-key-tab-binding'
|
||||
import { mergeCurrentOrchestrationContext } from './agent-status-orchestration-context'
|
||||
import { registryEntryMatchesStatus } from '../agent-status-launch-config'
|
||||
import { findAgentPaneWorktreeId, getTabIdFromPaneKey } from '../agent-status-pane-key-tab-binding'
|
||||
import { mergeCurrentOrchestrationContext } from '../agent-status-orchestration-context'
|
||||
import { deriveAgentStatusLiveFacts } from './agent-status-live-facts'
|
||||
import { liveEntryChildFields } from './agent-status-live-entry-children'
|
||||
import {
|
||||
canReuseStatusProviderSession,
|
||||
recordLaunchConfigForStatus,
|
||||
statusRetainsResumableIdentity
|
||||
} from '../../../../shared/agent-resume-record-from-status'
|
||||
} from '../../../../../shared/agent-resume-record-from-status'
|
||||
|
||||
export type AgentStatusLiveEntryBuild = {
|
||||
entry: AgentStatusEntry
|
||||
+4
-3
@@ -1,6 +1,7 @@
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import { agentSubagentsEqual } from '../../../../shared/agent-status-types'
|
||||
import { agentChildWorkViewsEqual } from '../../../../shared/agent-status-child-work-view-wire'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import '../../../../../shared/agent-status-types'
|
||||
import { agentSubagentsEqual } from '../../../../../shared/agent-status-subagent-snapshot'
|
||||
import { agentChildWorkViewsEqual } from '../../../../../shared/agent-status-child-work-view-wire'
|
||||
import type { AgentStatusPayload } from './agent-status-contract'
|
||||
|
||||
/** Reuse equal child arrays for derived-row identity; children are host views, subagents the legacy roster. */
|
||||
+5
-4
@@ -1,9 +1,10 @@
|
||||
import '../../../../../shared/agent-status-types'
|
||||
import {
|
||||
mainAgentStatusEqual,
|
||||
type AgentMainAgentStatus,
|
||||
type AgentStatusEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
import type { AgentStatusObservationOrigin } from '../../../../shared/agent-status-observation'
|
||||
type AgentMainAgentStatus
|
||||
} from '../../../../../shared/main-agent-status'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import type { AgentStatusObservationOrigin } from '../../../../../shared/agent-status-observation'
|
||||
import type { AgentStatusPayload } from './agent-status-contract'
|
||||
|
||||
/** Byte/launch writers omit mainAgent; hook omission authoritatively clears it for mobile/CLI parity. */
|
||||
+7
-7
@@ -1,19 +1,19 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { AppState } from '../../types'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import type {
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
import { isSmartSortRelevantAgentChange } from '../../../../shared/sidebar-list/smart-sort-agent-change'
|
||||
} from '../../../../../shared/agent-session-resume'
|
||||
import { isSmartSortRelevantAgentChange } from '../../../../../shared/sidebar-list/smart-sort-agent-change'
|
||||
import { recordHibernationBoundaryResolved } from '@/lib/agent-hibernation-pane-age'
|
||||
import {
|
||||
findAgentPaneWorktreeId,
|
||||
findTabForAgentEntry,
|
||||
isAgentCompletionState
|
||||
} from './agent-status-pane-key-tab-binding'
|
||||
} from '../agent-status-pane-key-tab-binding'
|
||||
import { pruneMigrationUnsupportedEntries } from './agent-status-migration-unsupported-entries'
|
||||
import { liveResumeRecord } from '../../../../shared/agent-resume-record-from-status'
|
||||
import { agentMainAgentVerdict } from '../../../../shared/agent-main-agent-verdict'
|
||||
import { liveResumeRecord } from '../../../../../shared/agent-resume-record-from-status'
|
||||
import { agentMainAgentVerdict } from '../../../../../shared/agent-main-agent-verdict'
|
||||
|
||||
export type AgentStatusLiveFacts = {
|
||||
existingSleepingRecord: SleepingAgentSessionRecord | undefined
|
||||
+4
-4
@@ -1,5 +1,5 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import type { AppState } from '../../types'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import {
|
||||
capLiveAgentStatusesInPlace,
|
||||
classifyPaneKeyLiveness,
|
||||
@@ -8,8 +8,8 @@ import {
|
||||
} from './agent-status-capacity-eviction'
|
||||
import { removePaneKeys } from './agent-status-pane-keyed-records'
|
||||
import type { AgentStatusLiveEntryBuild } from './agent-status-live-entry-builder'
|
||||
import { agentProviderSessionsEqual } from '../../../../shared/agent-session-resume'
|
||||
import { liveResumeRecordChange } from '../../../../shared/agent-resume-record-from-status'
|
||||
import { agentProviderSessionsEqual } from '../../../../../shared/agent-session-resume'
|
||||
import { liveResumeRecordChange } from '../../../../../shared/agent-resume-record-from-status'
|
||||
|
||||
export type AgentStatusLiveUpdateReduction = {
|
||||
patch: Partial<AppState>
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
import type { MigrationUnsupportedPtyEntry } from '../../../../shared/agent-status-types'
|
||||
import type { MigrationUnsupportedPtyEntry } from '../../../../../shared/agent-status-ipc-payload'
|
||||
|
||||
export function pruneMigrationUnsupportedEntries(
|
||||
entries: Record<string, MigrationUnsupportedPtyEntry>,
|
||||
+8
-9
@@ -1,14 +1,13 @@
|
||||
import type { AppState } from '../types'
|
||||
import {
|
||||
getAgentResumeArgv,
|
||||
type SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
import type { AppState } from '../../types'
|
||||
import '../../../../../shared/agent-session-resume'
|
||||
import { getAgentResumeArgv } from '../../../../../shared/agent-resume-argv'
|
||||
import type { SleepingAgentSessionRecord } from '../../../../../shared/agent-session-resume'
|
||||
import type { RetainedAgentEntry } from './agent-status-contract'
|
||||
import {
|
||||
normalizePaneKeySet,
|
||||
paneKeyMatchesAnyTabPrefix,
|
||||
retainedAgentEntryFromLive
|
||||
} from './agent-status-pane-key-tab-binding'
|
||||
} from '../agent-status-pane-key-tab-binding'
|
||||
import {
|
||||
isValidCompletedAgentHibernationEntry,
|
||||
manualSleepCaptureEntry,
|
||||
@@ -17,9 +16,9 @@ import {
|
||||
sleepingRecordFromEntry,
|
||||
type CollectSleepingAgentSessionRecordsOptions
|
||||
} from './agent-status-sleeping-records'
|
||||
import { getLaunchConfigForEntry } from './agent-status-launch-config'
|
||||
import { agentTurnEndedOnPurpose } from '../../../../shared/agent-main-agent-verdict'
|
||||
import { isCompletedPiCompatibleAgentWithLiveRecoveryRecord } from '../../../../shared/live-resume-anchor-record'
|
||||
import { getLaunchConfigForEntry } from '../agent-status-launch-config'
|
||||
import { agentTurnEndedOnPurpose } from '../../../../../shared/agent-main-agent-verdict'
|
||||
import { isCompletedPiCompatibleAgentWithLiveRecoveryRecord } from '../../../../../shared/live-resume-anchor-record'
|
||||
|
||||
export function collectSleepingAgentSessionRecordsForWorktree(
|
||||
state: AppState,
|
||||
+7
-7
@@ -1,13 +1,13 @@
|
||||
import type { AppState } from '../types'
|
||||
import type { AgentStatusEntry } from '../../../../shared/agent-status-types'
|
||||
import { agentTurnEndedUncleanly } from '../../../../shared/agent-main-agent-verdict'
|
||||
import type { AppState } from '../../types'
|
||||
import type { AgentStatusEntry } from '../../../../../shared/agent-status-types'
|
||||
import { agentTurnEndedUncleanly } from '../../../../../shared/agent-main-agent-verdict'
|
||||
import type {
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
import { resumeRecordFromStatus } from '../../../../shared/agent-resume-record-from-status'
|
||||
import type { TerminalTab } from '../../../../shared/terminal-tab-types'
|
||||
import { findTabForAgentEntry } from './agent-status-pane-key-tab-binding'
|
||||
} from '../../../../../shared/agent-session-resume'
|
||||
import { resumeRecordFromStatus } from '../../../../../shared/agent-resume-record-from-status'
|
||||
import type { TerminalTab } from '../../../../../shared/terminal-tab-types'
|
||||
import { findTabForAgentEntry } from '../agent-status-pane-key-tab-binding'
|
||||
|
||||
export function sleepingRecordFromEntry(args: {
|
||||
state: AppState
|
||||
+6
-6
@@ -10,7 +10,6 @@ import type {
|
||||
AgentStatusPayload,
|
||||
AgentStatusRouting,
|
||||
AgentStatusTiming,
|
||||
AgentProviderSessionMetadata,
|
||||
DropAgentStatusByTabPrefixOptions,
|
||||
DropAgentStatusByWorktreeOptions,
|
||||
DropAgentStatusOptions,
|
||||
@@ -20,15 +19,16 @@ import type {
|
||||
} from './agent-status-contract'
|
||||
import type {
|
||||
AgentStatusEntry,
|
||||
AgentStatusOrchestrationContext,
|
||||
MigrationUnsupportedPtyEntry
|
||||
} from '../../../../shared/agent-status-types'
|
||||
AgentStatusOrchestrationContext
|
||||
} from '../../../../../shared/agent-status-types'
|
||||
import type { MigrationUnsupportedPtyEntry } from '../../../../../shared/agent-status-ipc-payload'
|
||||
import type {
|
||||
AgentProviderSessionMetadata,
|
||||
ResumableTuiAgent,
|
||||
SleepingAgentLaunchConfig,
|
||||
SleepingAgentSessionRecord
|
||||
} from '../../../../shared/agent-session-resume'
|
||||
import type { ProgramStatusFacet } from '../../../../shared/program-status/facet'
|
||||
} from '../../../../../shared/agent-session-resume'
|
||||
import type { ProgramStatusFacet } from '../../../../../shared/program-status/facet'
|
||||
|
||||
export type AgentStatusSlice = {
|
||||
/** Explicit agent status entries keyed by `${tabId}:${leafId}`; real-time only, not persisted. */
|
||||
@@ -1,4 +1,4 @@
|
||||
import { removePaneKeys } from './agent-status-pane-keyed-records'
|
||||
import { removePaneKeys } from './agent-status/agent-status-pane-keyed-records'
|
||||
import type { AppState } from '../types'
|
||||
import { forgetAgentHibernationTabOutput } from '@/lib/agent-hibernation-output-activity'
|
||||
import { forgetForegroundTerminalTabs } from '@/lib/foreground-terminal-tabs'
|
||||
@@ -7,10 +7,11 @@ import { forgetAgentStartupDeliveriesForTabs } from '@/lib/agent-startup-deliver
|
||||
import { retireParkedTerminalTab } from '@/components/terminal-pane/terminal-parked-watcher-registry'
|
||||
import { forgetNativeChatPromptDismissalsForTab } from '@/components/native-chat/native-chat-prompt-dismissals'
|
||||
import { retireAgentPaneAuthorityAliasesByOwnerTab } from './agent-pane-authority'
|
||||
import './agent-status'
|
||||
import {
|
||||
buildAgentStatusTabPrefixDropPatch,
|
||||
type AgentStatusTabPrefixDropState
|
||||
} from './agent-status'
|
||||
} from './agent-status/agent-status-drop-reducer'
|
||||
import { buildPaneForegroundAgentTabPrefixClearPatch } from './pane-foreground-agent'
|
||||
|
||||
export type RetiredTerminalTabSweepActions = Pick<
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import type { StoredAgentAttentionUnread } from '@/attention/agent-attention-contract'
|
||||
import type { AppState } from '../../types'
|
||||
import { movePaneKeyedRecord, removePaneKeys } from '../agent-status-pane-keyed-records'
|
||||
import {
|
||||
movePaneKeyedRecord,
|
||||
removePaneKeys
|
||||
} from '../agent-status/agent-status-pane-keyed-records'
|
||||
import { omitRecordKeys } from '../worktrees/teardown/record-key-omission'
|
||||
import { paneKeyTabId } from './workspace-live-markers'
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ import type {
|
||||
TerminalTabTitleUpdate
|
||||
} from '../slices/terminal-tab-title-batch'
|
||||
import type { NativeChatLaunchDraft, NativeChatLaunchPrompt } from '@/lib/native-chat-launch-prompt'
|
||||
import type { AgentStatusWorktreeShutdownReason } from '../slices/agent-status'
|
||||
import type { AgentStatusWorktreeShutdownReason } from '../slices/agent-status/agent-status-contract'
|
||||
import type {
|
||||
TerminalTabCloseReason,
|
||||
TerminalTabRetirementPlan
|
||||
|
||||
@@ -7,10 +7,11 @@ import {
|
||||
import { shutdownBufferCaptures } from '@/components/terminal-pane/shutdown-buffer-captures'
|
||||
import { callRuntimeRpc } from '@/runtime/runtime-rpc-client'
|
||||
import { toRuntimeWorktreeSelector } from '@/runtime/runtime-worktree-selector'
|
||||
import '../slices/agent-status'
|
||||
import {
|
||||
collectHibernatedCompletionEvidenceForWorktree,
|
||||
collectSleepingAgentSessionRecordsForWorktree
|
||||
} from '../slices/agent-status'
|
||||
} from '../slices/agent-status/agent-status-recovery-collection'
|
||||
import type { TerminalSlice, TerminalStoreGet, TerminalStoreSet } from './terminal-state'
|
||||
import { equalStringSets, sortedUniquePtyIds } from './terminal-pty-identities'
|
||||
import { resolveTerminalPtyOwner } from '@/lib/terminal-worktree-route'
|
||||
|
||||
@@ -6,11 +6,12 @@ import {
|
||||
markCommittedPtyShutdowns,
|
||||
settleDeferredPtyShutdownExits
|
||||
} from '@/components/terminal-pane/pty-shutdown-exit-deferral'
|
||||
import {
|
||||
removeSleepingRecordsReplacedByManualWorktreeSleep,
|
||||
type AgentStatusWorktreeShutdownReason,
|
||||
type RetainedAgentEntry
|
||||
} from '../slices/agent-status'
|
||||
import '../slices/agent-status'
|
||||
import { removeSleepingRecordsReplacedByManualWorktreeSleep } from '../slices/agent-status/agent-status-sleeping-records'
|
||||
import type {
|
||||
AgentStatusWorktreeShutdownReason,
|
||||
RetainedAgentEntry
|
||||
} from '../slices/agent-status/agent-status-contract'
|
||||
import type { TerminalStoreGet, TerminalStoreSet } from './terminal-state'
|
||||
import { copyOnWriteRecord } from '../copy-on-write-record'
|
||||
import { removeTabsAttention } from '../slices/workspace-attention/subject-attention-transitions'
|
||||
|
||||
@@ -2,11 +2,12 @@ import type { SleepingAgentSessionRecord } from '../../../../shared/agent-sessio
|
||||
import { shutdownBufferCaptures } from '@/components/terminal-pane/shutdown-buffer-captures'
|
||||
import { callRuntimeRpc } from '@/runtime/runtime-rpc-client'
|
||||
import { toRuntimeWorktreeSelector } from '@/runtime/runtime-worktree-selector'
|
||||
import '../slices/agent-status'
|
||||
import {
|
||||
collectHibernatedCompletionEvidenceForWorktree,
|
||||
collectSleepingAgentSessionRecordsForWorktree,
|
||||
type AgentStatusWorktreeShutdownReason
|
||||
} from '../slices/agent-status'
|
||||
collectSleepingAgentSessionRecordsForWorktree
|
||||
} from '../slices/agent-status/agent-status-recovery-collection'
|
||||
import type { AgentStatusWorktreeShutdownReason } from '../slices/agent-status/agent-status-contract'
|
||||
import type { TerminalSlice, TerminalStoreGet, TerminalStoreSet } from './terminal-state'
|
||||
import { equalStringSets, sortedUniquePtyIds } from './terminal-pty-identities'
|
||||
import { resolveTerminalPtyOwner } from '@/lib/terminal-worktree-route'
|
||||
|
||||
@@ -18,7 +18,7 @@ import { commitTerminalSurfaceClose } from './terminal-surface-close-intent'
|
||||
import { recordTerminalTabCloseThroughLayoutOwner } from './terminal-tab-close-layout-owner'
|
||||
import { ORCA_LAYOUT_OWNER_IS_MAIN } from '../../../../shared/layout-owner-switch'
|
||||
import { omitUnverifiedPtyLossTabIds } from './terminal-unverified-pty-loss'
|
||||
import { removePaneKeysByTabPrefix } from '../slices/agent-status-pane-keyed-records'
|
||||
import { removePaneKeysByTabPrefix } from '../slices/agent-status/agent-status-pane-keyed-records'
|
||||
import { removeTabsAttention } from '../slices/workspace-attention/subject-attention-transitions'
|
||||
import { omitRecordKeys } from '../slices/worktrees/teardown/record-key-omission'
|
||||
import { deleteNativeChatComposerDraftsForTab } from '@/components/native-chat/native-chat-composer-draft-store'
|
||||
|
||||
@@ -26,7 +26,7 @@ import type { RateLimitSlice } from './slices/rate-limits'
|
||||
import type { SshSlice } from './slices/ssh'
|
||||
import type { RuntimeEnvironmentSshSlice } from './slices/runtime-environment-ssh'
|
||||
import type { WslHostsSlice } from './slices/wsl-hosts'
|
||||
import type { AgentStatusSlice } from './slices/agent-status'
|
||||
import type { AgentStatusSlice } from './slices/agent-status/agent-status-slice-contract'
|
||||
import type { PaneForegroundAgentSlice } from './slices/pane-foreground-agent'
|
||||
import type { DiffCommentsSlice } from './slices/diffComments'
|
||||
import type { DetectedAgentsSlice } from './slices/detected-agents'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { afterEach, expect, it, vi } from 'vitest'
|
||||
import { createTestStore } from '../../src/renderer/src/store/slices/store-test-helpers'
|
||||
import { sleepingRecordFromEntry } from '../../src/renderer/src/store/slices/agent-status-sleeping-records'
|
||||
import { sleepingRecordFromEntry } from '../../src/renderer/src/store/slices/agent-status/agent-status-sleeping-records'
|
||||
import { getAgentResumeArgv } from '../../src/shared/agent-session-resume'
|
||||
import { readAgentProcess } from '../../src/shared/agent-process-presence-probe'
|
||||
import { AgentHookServer } from '../../src/main/agent-hooks/server'
|
||||
|
||||
Reference in New Issue
Block a user