commandmate 0.33.1 → 0.33.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/BUILD_ID +1 -1
- package/.next/app-build-manifest.json +307 -307
- package/.next/app-path-routes-manifest.json +28 -28
- package/.next/build-manifest.json +5 -5
- package/.next/diagnostics/framework.json +1 -1
- package/.next/next-server.js.nft.json +1 -1
- package/.next/prerender-manifest.json +15 -15
- package/.next/required-server-files.json +1 -2
- package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/server/app/api/agents/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/agents/versions/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/app/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/app/update-check/route.js +1 -1
- package/.next/server/app/api/app/update-check/route.js.nft.json +1 -1
- package/.next/server/app/api/app/update-check/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/conversation/route.js +1 -1
- package/.next/server/app/api/assistant/conversation/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/conversation/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/current-output/route.js +1 -1
- package/.next/server/app/api/assistant/current-output/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/current-output/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/messages/route.js +1 -1
- package/.next/server/app/api/assistant/messages/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/messages/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/session/route.js +1 -1
- package/.next/server/app/api/assistant/session/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/session/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/start/route.js +32 -1
- package/.next/server/app/api/assistant/start/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/start/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/terminal/route.js +33 -2
- package/.next/server/app/api/assistant/terminal/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/terminal/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/assistant/tools/route.js +1 -1
- package/.next/server/app/api/assistant/tools/route.js.nft.json +1 -1
- package/.next/server/app/api/assistant/tools/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/login/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/logout/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/auth/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/capabilities/route.js +1 -1
- package/.next/server/app/api/capabilities/route.js.nft.json +1 -1
- package/.next/server/app/api/capabilities/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/daily-summary/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/daily-summary/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/[id]/health/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/external-apps/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/fs/browse/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/fs/recent-paths/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/agent-event/route.js +1 -1
- package/.next/server/app/api/hooks/agent-event/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/agent-event/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/claude-done/route.js +2 -2
- package/.next/server/app/api/hooks/claude-done/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/claude-done/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/hooks/permission-request/route.js +1 -1
- package/.next/server/app/api/hooks/permission-request/route.js.nft.json +1 -1
- package/.next/server/app/api/hooks/permission-request/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/metrics/vibe/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/ollama/models/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/escalation/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/subscriptions/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/push/vapid/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/relays/[relayId]/cancel/route.js +1 -1
- package/.next/server/app/api/relays/[relayId]/cancel/route.js.nft.json +1 -1
- package/.next/server/app/api/relays/[relayId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/relays/route.js +1 -1
- package/.next/server/app/api/relays/route.js.nft.json +1 -1
- package/.next/server/app/api/relays/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/remote/pair/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/[id]/todos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route.js +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/clone/[jobId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/clone/route.js +1 -1
- package/.next/server/app/api/repositories/clone/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/clone/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/excluded/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/restore/route.js +1 -1
- package/.next/server/app/api/repositories/restore/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/restore/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/route.js +1 -1
- package/.next/server/app/api/repositories/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/scan/route.js +1 -1
- package/.next/server/app/api/repositories/scan/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/scan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/sync/route.js +1 -1
- package/.next/server/app/api/repositories/sync/route.js.nft.json +1 -1
- package/.next/server/app/api/repositories/sync/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/repositories/validate-path/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/settings/default-agents/route.js +1 -1
- package/.next/server/app/api/settings/default-agents/route.js.nft.json +1 -1
- package/.next/server/app/api/settings/default-agents/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/settings/default-surface-mode/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/sidebar/group-order/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/[id]/route.js +1 -1
- package/.next/server/app/api/skills/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/skills/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/installations/route.js +1 -1
- package/.next/server/app/api/skills/installations/route.js.nft.json +1 -1
- package/.next/server/app/api/skills/installations/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/operations/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/reindex/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/skills/route.js +1 -1
- package/.next/server/app/api/skills/route.js.nft.json +1 -1
- package/.next/server/app/api/skills/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/slash-commands/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/tasks/[taskId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/tasks/[taskId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/templates/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/templates/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/todos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/verification/runs/[runId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/verification/runs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/auto-yes/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/capture/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/clear-composer/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cli-reference/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cli-tool/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/cmate/schedules/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/current-output/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/env/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/execution-logs/[logId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/execution-logs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/files/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branch/create/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branch/delete/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/branches/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/checkout/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/commit/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/fetch/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/log/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/pull/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/push/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/reset/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/revert/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/show/[commitHash]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stage/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/staged/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/[index]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/apply/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/pop/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/push/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/stash/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/status/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/unstage/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/git/working-diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/notes/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/opencode/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/instances/opencode/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/interrupt/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/kill-session/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/logs/[filename]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/logs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/marp-render/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/memos/[memoId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/memos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/messages/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/diff/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/session/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/opencode/share/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/prompt-response/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/resolve-target/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/respond/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/[scheduleId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/active/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/schedules/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/search/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/send/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/git-workflow/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/install/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/uninstall-plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/[skillId]/update-plan/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/skills/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/slash-commands/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/special-keys/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tasks/route.js +2 -2
- package/.next/server/app/api/worktrees/[id]/tasks/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/tasks/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route.js +103 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/terminal/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/history/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/timers/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/todos/[todoId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/todos/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tree/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/tree/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/upload/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/config/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/cancel/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/[runId]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/verify/runs/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/[id]/viewed/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/apply-default-agents/route_client-reference-manifest.js +1 -1
- package/.next/server/app/api/worktrees/route.js +1 -1
- package/.next/server/app/api/worktrees/route.js.nft.json +1 -1
- package/.next/server/app/api/worktrees/route_client-reference-manifest.js +1 -1
- package/.next/server/app/chat/page_client-reference-manifest.js +1 -1
- package/.next/server/app/login/page_client-reference-manifest.js +1 -1
- package/.next/server/app/manifest.webmanifest/route_client-reference-manifest.js +1 -1
- package/.next/server/app/more/page_client-reference-manifest.js +1 -1
- package/.next/server/app/offline/page_client-reference-manifest.js +1 -1
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/app/proxy/[...path]/route_client-reference-manifest.js +1 -1
- package/.next/server/app/repositories/page_client-reference-manifest.js +1 -1
- package/.next/server/app/review/page_client-reference-manifest.js +1 -1
- package/.next/server/app/sessions/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/[skillId]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/installed/page_client-reference-manifest.js +1 -1
- package/.next/server/app/skills/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/files/[...path]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/page.js +10 -10
- package/.next/server/app/worktrees/[id]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/worktrees/[id]/terminal/page_client-reference-manifest.js +1 -1
- package/.next/server/app-paths-manifest.json +28 -28
- package/.next/server/chunks/1068.js +1 -0
- package/.next/server/chunks/1210.js +1 -1
- package/.next/server/chunks/1331.js +2 -2
- package/.next/server/chunks/1366.js +5 -3
- package/.next/server/chunks/1501.js +6 -2
- package/.next/server/chunks/1886.js +2 -2
- package/.next/server/chunks/2119.js +1 -1
- package/.next/server/chunks/2445.js +1 -1
- package/.next/server/chunks/2839.js +1 -0
- package/.next/server/chunks/3123.js +1 -1
- package/.next/server/chunks/3241.js +1 -1
- package/.next/server/chunks/3323.js +1 -0
- package/.next/server/chunks/3707.js +1 -1
- package/.next/server/chunks/3708.js +1 -1
- package/.next/server/chunks/4443.js +1 -1
- package/.next/server/chunks/5220.js +1 -1
- package/.next/server/chunks/595.js +2 -2
- package/.next/server/chunks/6130.js +1 -0
- package/.next/server/chunks/650.js +1 -0
- package/.next/server/chunks/6661.js +1 -1
- package/.next/server/chunks/6781.js +1 -0
- package/.next/server/chunks/6808.js +1 -0
- package/.next/server/chunks/7875.js +3 -3
- package/.next/server/chunks/7905.js +1 -1
- package/.next/server/chunks/8918.js +107 -5
- package/.next/server/chunks/9553.js +1 -0
- package/.next/server/chunks/9627.js +1 -1
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/middleware-manifest.json +5 -5
- package/.next/server/pages/500.html +1 -1
- package/.next/server/server-reference-manifest.json +1 -1
- package/.next/server/src/middleware.js.map +1 -1
- package/.next/static/chunks/1255-7e5873f06b25e129.js +1 -0
- package/.next/static/chunks/{4718-2bc5cdf06573bf54.js → 4718-814f4ecfd7fcc513.js} +1 -1
- package/.next/static/chunks/6022-7a7d1760fc9814c7.js +1 -0
- package/.next/static/chunks/app/worktrees/[id]/page-3af707e74a75172b.js +1 -0
- package/.next/static/chunks/{main-6092074a0dc78280.js → main-ac91ed6e71380841.js} +1 -1
- package/.next/trace +13 -14
- package/dist/server/locales/en/worktree.json +9 -2
- package/dist/server/locales/ja/worktree.json +9 -2
- package/dist/server/src/lib/assistant-response-saver.js +168 -12
- package/dist/server/src/lib/cli-tools/vibe-local.js +10 -0
- package/dist/server/src/lib/hooks/hook-settings-generator.js +61 -1
- package/dist/server/src/lib/hooks/sources/antigravity/history.js +497 -27
- package/dist/server/src/lib/hooks/sources/antigravity/transcript.js +103 -0
- package/dist/server/src/lib/hooks/sources/claude/history.js +29 -3
- package/dist/server/src/lib/hooks/sources/codex/history.js +29 -3
- package/dist/server/src/lib/hooks/sources/command-code/history.js +29 -3
- package/dist/server/src/lib/hooks/stop-history-capture.js +30 -4
- package/dist/server/src/lib/polling/response-checker.js +258 -9
- package/dist/server/src/lib/polling/response-poller-core.js +20 -0
- package/dist/server/src/lib/polling/structured-history-gate.js +94 -10
- package/dist/server/src/lib/response-cleaner.js +84 -0
- package/dist/server/src/lib/session/agent-session-lifecycle.js +31 -1
- package/dist/server/src/lib/session/session-generation-archive.js +194 -0
- package/dist/server/src/lib/tasks/contract-message.js +83 -9
- package/dist/server/src/lib/tasks/contract-parser.js +2 -0
- package/package.json +2 -2
- package/.next/server/chunks/153.js +0 -1
- package/.next/server/chunks/21.js +0 -1
- package/.next/server/chunks/3086.js +0 -1
- package/.next/server/chunks/3270.js +0 -1
- package/.next/server/chunks/3925.js +0 -1
- package/.next/server/chunks/4299.js +0 -1
- package/.next/server/chunks/5043.js +0 -1
- package/.next/server/chunks/6306.js +0 -1
- package/.next/server/chunks/6363.js +0 -1
- package/.next/server/chunks/6491.js +0 -103
- package/.next/server/chunks/6838.js +0 -1
- package/.next/server/chunks/7366.js +0 -5
- package/.next/server/chunks/7890.js +0 -1
- package/.next/server/chunks/8063.js +0 -32
- package/.next/server/chunks/8687.js +0 -1
- package/.next/static/chunks/1255-8cb587d9170b45ed.js +0 -1
- package/.next/static/chunks/6022-2fa0b5a82d4ce7b6.js +0 -1
- package/.next/static/chunks/app/worktrees/[id]/page-13ca0ba551fe5cfb.js +0 -1
- /package/.next/static/{9lgw9hA727UMyFhXryGWG → 9x6U1h52hH_r6pOsGwI_p}/_buildManifest.js +0 -0
- /package/.next/static/{9lgw9hA727UMyFhXryGWG → 9x6U1h52hH_r6pOsGwI_p}/_ssgManifest.js +0 -0
|
@@ -76,6 +76,8 @@ exports.isAntigravityTurnClosingRecord = isAntigravityTurnClosingRecord;
|
|
|
76
76
|
exports.isAntigravityTurnWritable = isAntigravityTurnWritable;
|
|
77
77
|
exports.isAntigravityPromptRecord = isAntigravityPromptRecord;
|
|
78
78
|
exports.renderAntigravityTurn = renderAntigravityTurn;
|
|
79
|
+
exports.antigravityTurnLastRecordAt = antigravityTurnLastRecordAt;
|
|
80
|
+
exports.resolveAntigravityTurnCompletion = resolveAntigravityTurnCompletion;
|
|
79
81
|
const event_mapper_1 = require("../event-mapper");
|
|
80
82
|
const turn_body_1 = require("../turn-body");
|
|
81
83
|
/**
|
|
@@ -444,3 +446,104 @@ function renderAntigravityTurn(turn) {
|
|
|
444
446
|
unknownRecordTypes: [...unknown],
|
|
445
447
|
};
|
|
446
448
|
}
|
|
449
|
+
/**
|
|
450
|
+
* Epoch ms of the newest record agy wrote inside this turn, or 0 (Issue #2443).
|
|
451
|
+
*
|
|
452
|
+
* The maximum rather than `records.at(-1)`: `created_at` is agy's own field and
|
|
453
|
+
* a record that carries none reads as null, so the last record in file order is
|
|
454
|
+
* not always the last one with a clock on it. The prompt record is deliberately
|
|
455
|
+
* outside the walk — `records` holds everything *after* the `USER_INPUT` — which
|
|
456
|
+
* is why {@link resolveAntigravityTurnCompletion} floors the comparison at
|
|
457
|
+
* {@link AntigravityTurnAccumulator.startedAt} as well.
|
|
458
|
+
*
|
|
459
|
+
* @returns Epoch ms, or 0 when the turn has no timestamped record
|
|
460
|
+
*/
|
|
461
|
+
function antigravityTurnLastRecordAt(turn) {
|
|
462
|
+
let at = 0;
|
|
463
|
+
for (const record of turn.records) {
|
|
464
|
+
if (record.timestampMs !== null && record.timestampMs > at)
|
|
465
|
+
at = record.timestampMs;
|
|
466
|
+
}
|
|
467
|
+
return at;
|
|
468
|
+
}
|
|
469
|
+
/**
|
|
470
|
+
* Whether agy has vouched for this turn's body (Issue #2443).
|
|
471
|
+
*
|
|
472
|
+
* ## What this is separate from, and why the separation is the Issue
|
|
473
|
+
*
|
|
474
|
+
* {@link isAntigravityTurnWritable} answers "may a row be written from this
|
|
475
|
+
* turn". It has to be generous — agy writes **no record that closes a turn**, so
|
|
476
|
+
* the shape of the last thing it wrote is all there is, and an interim report
|
|
477
|
+
* ("waiting for the worker") is prose with no `tool_calls` exactly like a
|
|
478
|
+
* conclusion is. #2438 made the row that follows from that repairable. What it
|
|
479
|
+
* could not make repairable is everything a save *triggers*: a relay delivering
|
|
480
|
+
* the interim body to the session that asked for the answer cannot be taken
|
|
481
|
+
* back, and `broadcastMessage('message_updated', …)` does not rewind it.
|
|
482
|
+
*
|
|
483
|
+
* So this is the second question — "is this body final" — and it is answered
|
|
484
|
+
* from a different kind of evidence, deliberately:
|
|
485
|
+
*
|
|
486
|
+
* - **not the wording.** "waiting", "Waiting for" and their translations are a
|
|
487
|
+
* model's prose, and a rule keyed on them is wrong the first time the model
|
|
488
|
+
* is asked to answer in another language or writes a conclusion that mentions
|
|
489
|
+
* waiting.
|
|
490
|
+
* - **not a fixed quiet period.** The gaps measured on the reporting machine
|
|
491
|
+
* were 3 / 58 / 156 s from an interim candidate to the next record and 9 /
|
|
492
|
+
* 113 / 118 s from the final one, which overlap: no constant separates them.
|
|
493
|
+
* - **not `status: DONE`** (all 15 measured candidates carry it, early and
|
|
494
|
+
* final alike) **and not `truncated_fields`**, which is agy saying it
|
|
495
|
+
* shortened a field.
|
|
496
|
+
*
|
|
497
|
+
* ## The evidence that is used
|
|
498
|
+
*
|
|
499
|
+
* agy's own `Stop` hook, correlated by instant. `Stop` is agy reporting that its
|
|
500
|
+
* loop ended, and CommandMate already records when one arrived
|
|
501
|
+
* (`session/agent-event-state`'s `getLastStopEventAt`). What makes it usable
|
|
502
|
+
* despite `source.ts`'s warning that a `Stop` can be answered with
|
|
503
|
+
* `{"decision":"continue"}` is that the correlation is an ordering rather than a
|
|
504
|
+
* flag: a stop is evidence about the file **as it was when the stop arrived**.
|
|
505
|
+
*
|
|
506
|
+
* - A resumed loop appends records *after* the stop, which pushes
|
|
507
|
+
* `lastRecordAt` past `stopAt` and takes the confirmation away again. The
|
|
508
|
+
* evidence therefore withdraws itself in exactly the case the warning is
|
|
509
|
+
* about, with no `continue`-detection of its own.
|
|
510
|
+
* - A stop belonging to the *previous* turn is older than this turn's records
|
|
511
|
+
* and confirms nothing.
|
|
512
|
+
* - No stop at all — hooks not wired up, agy killed, CommandMate restarted
|
|
513
|
+
* since — is `no-stop-event`, and the caller keeps the body provisional
|
|
514
|
+
* rather than promoting it.
|
|
515
|
+
*
|
|
516
|
+
* The residual is agy's clock resolution: `created_at` is written to the second,
|
|
517
|
+
* so a record appended in the same second as the stop compares equal to it.
|
|
518
|
+
* That is a sub-second window, it is bounded by one `created_at` tick, and the
|
|
519
|
+
* direction of the error is a body confirmed one record early rather than a turn
|
|
520
|
+
* confirmed that never ended.
|
|
521
|
+
*
|
|
522
|
+
* Pure: the stop instant is a parameter, so this file keeps its no-filesystem,
|
|
523
|
+
* no-database, no-`globalThis` contract and the rule is a property a test states
|
|
524
|
+
* against values rather than against a running server.
|
|
525
|
+
*
|
|
526
|
+
* @param turn - The turn to judge
|
|
527
|
+
* @param stopAt - Epoch ms of this instance's last `Stop`, or null when none has
|
|
528
|
+
* been received
|
|
529
|
+
*/
|
|
530
|
+
function resolveAntigravityTurnCompletion(turn, stopAt) {
|
|
531
|
+
const lastRecordAt = antigravityTurnLastRecordAt(turn);
|
|
532
|
+
const base = { confirmed: false, lastRecordAt, stopAt };
|
|
533
|
+
// A turn agy is still working through has no final body to vouch for. Asked
|
|
534
|
+
// before the clock questions so that "it is still running" never reads as
|
|
535
|
+
// "its records are unstamped".
|
|
536
|
+
if (!isAntigravityTurnWritable(turn))
|
|
537
|
+
return { ...base, reason: 'turn-open' };
|
|
538
|
+
if (lastRecordAt <= 0)
|
|
539
|
+
return { ...base, reason: 'no-timestamped-record' };
|
|
540
|
+
if (stopAt === null)
|
|
541
|
+
return { ...base, reason: 'no-stop-event' };
|
|
542
|
+
// `startedAt` as well as the newest record: a turn whose records all predate
|
|
543
|
+
// its own prompt is a shape this reader has not seen, and taking the later of
|
|
544
|
+
// the two cannot make the test easier to pass.
|
|
545
|
+
if (stopAt < Math.max(lastRecordAt, turn.startedAt)) {
|
|
546
|
+
return { ...base, reason: 'stop-before-last-record' };
|
|
547
|
+
}
|
|
548
|
+
return { confirmed: true, reason: 'stop-after-last-record', lastRecordAt, stopAt };
|
|
549
|
+
}
|
|
@@ -104,6 +104,7 @@ const os_1 = require("os");
|
|
|
104
104
|
const path_1 = require("path");
|
|
105
105
|
const auto_yes_state_1 = require("../../../../lib/auto-yes-state");
|
|
106
106
|
const user_turn_recorder_1 = require("../../../../lib/history/user-turn-recorder");
|
|
107
|
+
const assistant_response_saver_1 = require("../../../../lib/assistant-response-saver");
|
|
107
108
|
const logger_1 = require("../../../../lib/logger");
|
|
108
109
|
const agent_transcript_1 = require("../../../../types/agent-transcript");
|
|
109
110
|
const transcript_1 = require("./transcript");
|
|
@@ -266,10 +267,18 @@ function acceptClaudeTranscriptHint(homeDir, hint) {
|
|
|
266
267
|
*
|
|
267
268
|
* Never throws.
|
|
268
269
|
*
|
|
270
|
+
* Since Issue #2436 the false can explain itself: pass a
|
|
271
|
+
* `StructuredHistoryCaptureReport` and `outcome` is set to `'not_yet_closed'`
|
|
272
|
+
* when the newest turn is one the agent has not finished writing — the case the
|
|
273
|
+
* `-turn-open` line below reports, and the one where the caller's scraped copy
|
|
274
|
+
* is worth holding rather than saving. Every other false leaves it unset, which
|
|
275
|
+
* the gate reads as `'unavailable'`.
|
|
276
|
+
*
|
|
269
277
|
* @param target - The instance whose turn just ended
|
|
278
|
+
* @param report - Optional out-parameter; see `StructuredHistoryCaptureReport`
|
|
270
279
|
* @returns Whether History now holds this instance's newest turn as Markdown
|
|
271
280
|
*/
|
|
272
|
-
async function captureClaudeTranscriptTurn(target, capture) {
|
|
281
|
+
async function captureClaudeTranscriptTurn(target, capture, report) {
|
|
273
282
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
274
283
|
try {
|
|
275
284
|
const homeDir = capture.homeDir ?? (0, os_1.homedir)();
|
|
@@ -340,6 +349,9 @@ async function captureClaudeTranscriptTurn(target, capture) {
|
|
|
340
349
|
instanceId,
|
|
341
350
|
turnsInWindow: built.turns.length,
|
|
342
351
|
});
|
|
352
|
+
// Issue #2437: this turn is already History's Markdown, so the pane rows
|
|
353
|
+
// behind it must stop being "unsaved output" the pre-send flush can pick up.
|
|
354
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
343
355
|
return true;
|
|
344
356
|
}
|
|
345
357
|
if (pending.turns.length > 1) {
|
|
@@ -374,7 +386,14 @@ async function captureClaudeTranscriptTurn(target, capture) {
|
|
|
374
386
|
let captured = false;
|
|
375
387
|
for (let index = 0; index < pending.turns.length; index += 1) {
|
|
376
388
|
const turn = pending.turns[index];
|
|
377
|
-
captured = await writeClaudeTurn(target, turn, (0, transcript_1.renderClaudeTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.promptUuid) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), path);
|
|
389
|
+
captured = await writeClaudeTurn(target, turn, (0, transcript_1.renderClaudeTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.promptUuid) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), path, report);
|
|
390
|
+
}
|
|
391
|
+
if (captured) {
|
|
392
|
+
// Issue #2437: History now holds this turn as the agent's own Markdown.
|
|
393
|
+
// Park the pre-send flush's cursor past the pane rows it covers, or a
|
|
394
|
+
// `/send` arriving before the next poll tick saves the whole finished turn
|
|
395
|
+
// a second time.
|
|
396
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
378
397
|
}
|
|
379
398
|
return captured;
|
|
380
399
|
}
|
|
@@ -925,8 +944,13 @@ async function refreshClaudeTurnRows(target, candidates, path) {
|
|
|
925
944
|
*
|
|
926
945
|
* @returns Whether History holds this turn as the agent's own Markdown
|
|
927
946
|
*/
|
|
928
|
-
async function writeClaudeTurn(target, turn, rendered, timestampMs, path) {
|
|
947
|
+
async function writeClaudeTurn(target, turn, rendered, timestampMs, path, report) {
|
|
929
948
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
949
|
+
// Issue #2436: the caller's report is about the turn THIS call is deciding.
|
|
950
|
+
// The loop above walks oldest-first, so a verdict left by an earlier turn has
|
|
951
|
+
// to be cleared before this one's is written.
|
|
952
|
+
if (report)
|
|
953
|
+
report.outcome = undefined;
|
|
930
954
|
if (!(0, transcript_1.isClaudeTurnWritable)(turn)) {
|
|
931
955
|
// The agent has not said `end_turn` for this prompt and no later prompt has
|
|
932
956
|
// taken over, so what is in the file is a turn in progress. Writing it would
|
|
@@ -941,6 +965,8 @@ async function writeClaudeTurn(target, turn, rendered, timestampMs, path) {
|
|
|
941
965
|
// Handing it back to the scraper costs the Markdown rendering for this turn
|
|
942
966
|
// and nothing else: the Stop receiver asks again after a short delay, and
|
|
943
967
|
// the poller asks again when the pane returns to the composer.
|
|
968
|
+
if (report)
|
|
969
|
+
report.outcome = 'not_yet_closed';
|
|
944
970
|
logger.info('claude-transcript-turn-open', {
|
|
945
971
|
worktreeId: target.worktreeId,
|
|
946
972
|
instanceId,
|
|
@@ -101,6 +101,7 @@ const path_1 = require("path");
|
|
|
101
101
|
const auto_yes_state_1 = require("../../../../lib/auto-yes-state");
|
|
102
102
|
const transcript_tail_1 = require("../../../../lib/history/transcript-tail");
|
|
103
103
|
const user_turn_recorder_1 = require("../../../../lib/history/user-turn-recorder");
|
|
104
|
+
const assistant_response_saver_1 = require("../../../../lib/assistant-response-saver");
|
|
104
105
|
const logger_1 = require("../../../../lib/logger");
|
|
105
106
|
const agent_transcript_1 = require("../../../../types/agent-transcript");
|
|
106
107
|
const transcript_1 = require("./transcript");
|
|
@@ -332,11 +333,19 @@ async function scanForRollout(dir, sessionId, depth) {
|
|
|
332
333
|
*
|
|
333
334
|
* Never throws.
|
|
334
335
|
*
|
|
336
|
+
* Since Issue #2436 the false can explain itself: pass a
|
|
337
|
+
* `StructuredHistoryCaptureReport` and `outcome` is set to `'not_yet_closed'`
|
|
338
|
+
* when the newest turn is one the agent has not finished writing — the case the
|
|
339
|
+
* `-turn-open` line below reports, and the one where the caller's scraped copy
|
|
340
|
+
* is worth holding rather than saving. Every other false leaves it unset, which
|
|
341
|
+
* the gate reads as `'unavailable'`.
|
|
342
|
+
*
|
|
335
343
|
* @param target - The instance whose turn just ended
|
|
336
344
|
* @param capture - See {@link CodexTranscriptCapture}
|
|
345
|
+
* @param report - Optional out-parameter; see `StructuredHistoryCaptureReport`
|
|
337
346
|
* @returns Whether History now holds this turn as the agent's own Markdown
|
|
338
347
|
*/
|
|
339
|
-
async function captureCodexTranscriptTurn(target, capture = {}) {
|
|
348
|
+
async function captureCodexTranscriptTurn(target, capture = {}, report) {
|
|
340
349
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
341
350
|
try {
|
|
342
351
|
const codexHome = capture.codexHome ?? resolveCodexHome();
|
|
@@ -395,6 +404,9 @@ async function captureCodexTranscriptTurn(target, capture = {}) {
|
|
|
395
404
|
instanceId,
|
|
396
405
|
turnsInWindow: built.turns.length,
|
|
397
406
|
});
|
|
407
|
+
// Issue #2437: this turn is already History's Markdown, so the pane rows
|
|
408
|
+
// behind it must stop being "unsaved output" the pre-send flush can pick up.
|
|
409
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
398
410
|
return true;
|
|
399
411
|
}
|
|
400
412
|
if (pending.turns.length > 1) {
|
|
@@ -428,7 +440,14 @@ async function captureCodexTranscriptTurn(target, capture = {}) {
|
|
|
428
440
|
let captured = false;
|
|
429
441
|
for (let index = 0; index < pending.turns.length; index += 1) {
|
|
430
442
|
const turn = pending.turns[index];
|
|
431
|
-
captured = await writeCodexTurn(target, turn, (0, transcript_1.renderCodexTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.turnId) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), windowFacts);
|
|
443
|
+
captured = await writeCodexTurn(target, turn, (0, transcript_1.renderCodexTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.turnId) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), windowFacts, report);
|
|
444
|
+
}
|
|
445
|
+
if (captured) {
|
|
446
|
+
// Issue #2437: History now holds this turn as the agent's own Markdown.
|
|
447
|
+
// Park the pre-send flush's cursor past the pane rows it covers, or a
|
|
448
|
+
// `/send` arriving before the next poll tick saves the whole finished turn
|
|
449
|
+
// a second time.
|
|
450
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
432
451
|
}
|
|
433
452
|
return captured;
|
|
434
453
|
}
|
|
@@ -670,14 +689,21 @@ function nextTurnOpensAt(turns, userRows, index) {
|
|
|
670
689
|
*
|
|
671
690
|
* @returns Whether History holds this turn as the agent's own Markdown
|
|
672
691
|
*/
|
|
673
|
-
async function writeCodexTurn(target, turn, rendered, timestampMs, windowFacts) {
|
|
692
|
+
async function writeCodexTurn(target, turn, rendered, timestampMs, windowFacts, report) {
|
|
674
693
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
694
|
+
// Issue #2436: the caller's report is about the turn THIS call is deciding.
|
|
695
|
+
// The loop above walks oldest-first, so a verdict left by an earlier turn has
|
|
696
|
+
// to be cleared before this one's is written.
|
|
697
|
+
if (report)
|
|
698
|
+
report.outcome = undefined;
|
|
675
699
|
if (!turn.closed) {
|
|
676
700
|
// codex has not written the `task_complete` for this `turn_id` yet, so what
|
|
677
701
|
// is in the file is a turn in progress. Writing it would put a truncated
|
|
678
702
|
// reply in History permanently — and unlike an empty one, a truncated one
|
|
679
703
|
// looks finished. Handing it back to the scraper costs the Markdown
|
|
680
704
|
// rendering for this turn and nothing else.
|
|
705
|
+
if (report)
|
|
706
|
+
report.outcome = 'not_yet_closed';
|
|
681
707
|
logger.info('codex-transcript-turn-open', {
|
|
682
708
|
worktreeId: target.worktreeId,
|
|
683
709
|
instanceId,
|
|
@@ -135,6 +135,7 @@ const path_1 = require("path");
|
|
|
135
135
|
const auto_yes_state_1 = require("../../../../lib/auto-yes-state");
|
|
136
136
|
const transcript_tail_1 = require("../../../../lib/history/transcript-tail");
|
|
137
137
|
const user_turn_recorder_1 = require("../../../../lib/history/user-turn-recorder");
|
|
138
|
+
const assistant_response_saver_1 = require("../../../../lib/assistant-response-saver");
|
|
138
139
|
const logger_1 = require("../../../../lib/logger");
|
|
139
140
|
const agent_transcript_1 = require("../../../../types/agent-transcript");
|
|
140
141
|
const transcript_1 = require("./transcript");
|
|
@@ -325,10 +326,18 @@ async function findCommandCodeTranscriptPath(homeDir, sessionId) {
|
|
|
325
326
|
*
|
|
326
327
|
* Never throws.
|
|
327
328
|
*
|
|
329
|
+
* Since Issue #2436 the false can explain itself: pass a
|
|
330
|
+
* `StructuredHistoryCaptureReport` and `outcome` is set to `'not_yet_closed'`
|
|
331
|
+
* when the newest turn is one the agent has not finished writing — the case the
|
|
332
|
+
* `-turn-open` line below reports, and the one where the caller's scraped copy
|
|
333
|
+
* is worth holding rather than saving. Every other false leaves it unset, which
|
|
334
|
+
* the gate reads as `'unavailable'`.
|
|
335
|
+
*
|
|
328
336
|
* @param target - The instance whose turn just ended
|
|
337
|
+
* @param report - Optional out-parameter; see `StructuredHistoryCaptureReport`
|
|
329
338
|
* @returns Whether History now holds this instance's newest turn as Markdown
|
|
330
339
|
*/
|
|
331
|
-
async function captureCommandCodeTranscriptTurn(target, capture) {
|
|
340
|
+
async function captureCommandCodeTranscriptTurn(target, capture, report) {
|
|
332
341
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
333
342
|
try {
|
|
334
343
|
const homeDir = capture.commandCodeHome ?? (0, os_1.homedir)();
|
|
@@ -394,6 +403,9 @@ async function captureCommandCodeTranscriptTurn(target, capture) {
|
|
|
394
403
|
instanceId,
|
|
395
404
|
turnsInWindow: built.turns.length,
|
|
396
405
|
});
|
|
406
|
+
// Issue #2437: this turn is already History's Markdown, so the pane rows
|
|
407
|
+
// behind it must stop being "unsaved output" the pre-send flush can pick up.
|
|
408
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
397
409
|
return true;
|
|
398
410
|
}
|
|
399
411
|
if (pending.turns.length > 1) {
|
|
@@ -426,7 +438,14 @@ async function captureCommandCodeTranscriptTurn(target, capture) {
|
|
|
426
438
|
let captured = false;
|
|
427
439
|
for (let index = 0; index < pending.turns.length; index += 1) {
|
|
428
440
|
const turn = pending.turns[index];
|
|
429
|
-
captured = await writeCommandCodeTurn(target, turn, (0, transcript_1.renderCommandCodeTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.promptId) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), path);
|
|
441
|
+
captured = await writeCommandCodeTurn(target, turn, (0, transcript_1.renderCommandCodeTurn)(turn), resolveAssistantTimestampMs(turn, userRows[index], lastRecordAt.get(turn.promptId) ?? 0, nextTurnOpensAt(pending.turns, userRows, index)), path, report);
|
|
442
|
+
}
|
|
443
|
+
if (captured) {
|
|
444
|
+
// Issue #2437: History now holds this turn as the agent's own Markdown.
|
|
445
|
+
// Park the pre-send flush's cursor past the pane rows it covers, or a
|
|
446
|
+
// `/send` arriving before the next poll tick saves the whole finished turn
|
|
447
|
+
// a second time.
|
|
448
|
+
await (0, assistant_response_saver_1.advanceCapturedLineForTranscriptTurn)(target);
|
|
430
449
|
}
|
|
431
450
|
return captured;
|
|
432
451
|
}
|
|
@@ -773,8 +792,13 @@ async function refreshCommandCodeTurnRows(target, candidates, path) {
|
|
|
773
792
|
*
|
|
774
793
|
* @returns Whether History holds this turn as the agent's own Markdown
|
|
775
794
|
*/
|
|
776
|
-
async function writeCommandCodeTurn(target, turn, rendered, timestampMs, path) {
|
|
795
|
+
async function writeCommandCodeTurn(target, turn, rendered, timestampMs, path, report) {
|
|
777
796
|
const instanceId = target.instanceId ?? target.cliToolId;
|
|
797
|
+
// Issue #2436: the caller's report is about the turn THIS call is deciding.
|
|
798
|
+
// The loop above walks oldest-first, so a verdict left by an earlier turn has
|
|
799
|
+
// to be cleared before this one's is written.
|
|
800
|
+
if (report)
|
|
801
|
+
report.outcome = undefined;
|
|
778
802
|
if (!(0, transcript_1.isCommandCodeTurnWritable)(turn)) {
|
|
779
803
|
// The agent's last word in this turn reached for a tool and no later prompt
|
|
780
804
|
// has taken over, so what is in the file is a turn in progress. Writing it
|
|
@@ -789,6 +813,8 @@ async function writeCommandCodeTurn(target, turn, rendered, timestampMs, path) {
|
|
|
789
813
|
// Handing it back to the scraper costs the Markdown rendering for this turn
|
|
790
814
|
// and nothing else: the Stop receiver asks again after a short delay, and
|
|
791
815
|
// the poller asks again when the pane returns to the composer.
|
|
816
|
+
if (report)
|
|
817
|
+
report.outcome = 'not_yet_closed';
|
|
792
818
|
logger.info('command-code-transcript-turn-open', {
|
|
793
819
|
worktreeId: target.worktreeId,
|
|
794
820
|
instanceId,
|
|
@@ -248,7 +248,12 @@ async function readAfterResponding(gate, worktree, cliToolId, instanceId, captur
|
|
|
248
248
|
try {
|
|
249
249
|
for (const [index, delayMs] of delaysMs.entries()) {
|
|
250
250
|
await sleep(delayMs);
|
|
251
|
-
|
|
251
|
+
// Issue #2436: the boolean is the verdict, the report says why. Read
|
|
252
|
+
// explicitly rather than as truthiness — an open turn answers `false`
|
|
253
|
+
// here and must keep the loop going, which is exactly the misreading the
|
|
254
|
+
// Issue's requirement C is about.
|
|
255
|
+
const report = {};
|
|
256
|
+
const captured = await gate.captureStructuredHistoryTurn(worktree.id, cliToolId, instanceId, capture, report);
|
|
252
257
|
if (captured) {
|
|
253
258
|
// The line an operator greps when a codex reply did reach the chat
|
|
254
259
|
// surface: the receiver's own `agent-event-stop-applied` cannot carry
|
|
@@ -269,6 +274,10 @@ async function readAfterResponding(gate, worktree, cliToolId, instanceId, captur
|
|
|
269
274
|
instanceId,
|
|
270
275
|
attempt: index + 1,
|
|
271
276
|
attempts: delaysMs.length,
|
|
277
|
+
// Issue #2436: `not_yet_closed` here means the next read is worth
|
|
278
|
+
// taking; anything else means these delays are being spent on a turn
|
|
279
|
+
// that will never be written by this reader.
|
|
280
|
+
outcome: report.outcome ?? 'unavailable',
|
|
272
281
|
elapsedMs: Date.now() - startedAt,
|
|
273
282
|
});
|
|
274
283
|
}
|
|
@@ -324,7 +333,15 @@ async function resolveStopTranscriptCapture(worktree, cliToolId, instanceId, opt
|
|
|
324
333
|
// found that way has no session pointer either, and therefore sends no stop
|
|
325
334
|
// event this path could act on.
|
|
326
335
|
const capture = { worktreePath: worktree.path, transcriptPathHint: null };
|
|
327
|
-
|
|
336
|
+
// Issue #2436: `captureStructuredHistoryTurn` still answers a boolean, and
|
|
337
|
+
// `true` still means — and only means — "the row is written NOW". That is
|
|
338
|
+
// load-bearing here: the three statuses below are decided by reading this
|
|
339
|
+
// value as a boolean, and a tri-state RETURN would have made every one of
|
|
340
|
+
// them truthy, turning an open turn into `captured` and cancelling the very
|
|
341
|
+
// reads that go on to write it. The third value arrives beside the boolean
|
|
342
|
+
// instead, in `firstReport`, and is used explicitly.
|
|
343
|
+
const firstReport = {};
|
|
344
|
+
if (await gate.captureStructuredHistoryTurn(worktree.id, cliToolId, instanceId, capture, firstReport)) {
|
|
328
345
|
return { status: 'captured' };
|
|
329
346
|
}
|
|
330
347
|
// Asked once, before any waiting, on either path: every failure other than
|
|
@@ -333,7 +350,14 @@ async function resolveStopTranscriptCapture(worktree, cliToolId, instanceId, opt
|
|
|
333
350
|
// nor deferring can fix, and an instance with no transcript will not have
|
|
334
351
|
// one in 150 ms either. A transcript that exists does not stop existing
|
|
335
352
|
// between attempts, so this is not re-asked.
|
|
336
|
-
|
|
353
|
+
//
|
|
354
|
+
// Issue #2436: a reader that answered `not_yet_closed` HAS just read the
|
|
355
|
+
// file — that is what "the turn in it is still open" is a statement about —
|
|
356
|
+
// so the probe is skipped and the answer taken from the report. The
|
|
357
|
+
// fallback is the pre-#2436 round-trip, for a reader that reported nothing.
|
|
358
|
+
const hasTranscript = () => firstReport.outcome === 'not_yet_closed'
|
|
359
|
+
? Promise.resolve(true)
|
|
360
|
+
: gate.hasStructuredHistoryTranscript(worktree.id, cliToolId, instanceId, capture);
|
|
337
361
|
if (exports.STOP_HOOK_BLOCKS_TRANSCRIPT_CLOSE.has(cliToolId)) {
|
|
338
362
|
const delaysMs = options.deferredDelaysMs ?? exports.STOP_TRANSCRIPT_DEFERRED_DELAYS_MS;
|
|
339
363
|
if (delaysMs.length === 0)
|
|
@@ -357,7 +381,8 @@ async function resolveStopTranscriptCapture(worktree, cliToolId, instanceId, opt
|
|
|
357
381
|
const maxAttempts = Math.max(1, options.maxAttempts ?? exports.STOP_TRANSCRIPT_MAX_ATTEMPTS);
|
|
358
382
|
for (let attempt = 2; attempt <= maxAttempts; attempt += 1) {
|
|
359
383
|
await sleep(retryDelayMs);
|
|
360
|
-
const
|
|
384
|
+
const report = {};
|
|
385
|
+
const captured = await gate.captureStructuredHistoryTurn(worktree.id, cliToolId, instanceId, capture, report);
|
|
361
386
|
logger.debug('stop-history-capture-retried', {
|
|
362
387
|
worktreeId: worktree.id,
|
|
363
388
|
cliToolId,
|
|
@@ -365,6 +390,7 @@ async function resolveStopTranscriptCapture(worktree, cliToolId, instanceId, opt
|
|
|
365
390
|
attempt,
|
|
366
391
|
maxAttempts,
|
|
367
392
|
captured,
|
|
393
|
+
outcome: report.outcome ?? 'unavailable',
|
|
368
394
|
});
|
|
369
395
|
if (captured)
|
|
370
396
|
return { status: 'captured' };
|