@wjarka/cezarion 0.16.0 → 0.17.0
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/LICENSE +1 -0
- package/README.md +594 -207
- package/dist/agent-config/account-identity.d.ts +3 -19
- package/dist/agent-config/account-identity.js +8 -5
- package/dist/agent-config/account-identity.js.map +1 -1
- package/dist/agent-config/catalog.d.ts +3 -14
- package/dist/agent-config/catalog.js.map +1 -1
- package/dist/agent-config/files.d.ts +2 -6
- package/dist/agent-config/files.js +2 -6
- package/dist/agent-config/files.js.map +1 -1
- package/dist/agent-config/model-settings/types.d.ts +1 -1
- package/dist/agent-config/seed.d.ts +11 -3
- package/dist/agent-config/seed.js +52 -48
- package/dist/agent-config/seed.js.map +1 -1
- package/dist/agent-config/service.js +3 -2
- package/dist/agent-config/service.js.map +1 -1
- package/dist/agent-config/validate.d.ts +1 -4
- package/dist/agent-config/validate.js.map +1 -1
- package/dist/application-update/helper.d.ts +2 -2
- package/dist/application-update/helper.js +7 -12
- package/dist/application-update/helper.js.map +1 -1
- package/dist/application-update/launcher.d.ts +4 -0
- package/dist/application-update/launcher.js +18 -12
- package/dist/application-update/launcher.js.map +1 -1
- package/dist/application-update/service.d.ts +3 -3
- package/dist/application-update/service.js +1 -1
- package/dist/application-update/service.js.map +1 -1
- package/dist/archive-on-merge-setting.d.ts +15 -0
- package/dist/archive-on-merge-setting.js +14 -0
- package/dist/archive-on-merge-setting.js.map +1 -0
- package/dist/artifacts/cli.d.ts +8 -0
- package/dist/artifacts/cli.js +21 -2
- package/dist/artifacts/cli.js.map +1 -1
- package/dist/artifacts/resolve.js +2 -1
- package/dist/artifacts/resolve.js.map +1 -1
- package/dist/artifacts/store.js.map +1 -1
- package/dist/automations/automation-cli.d.ts +59 -0
- package/dist/automations/automation-cli.js +509 -0
- package/dist/automations/automation-cli.js.map +1 -0
- package/dist/automations/builtin-skill.d.ts +7 -0
- package/dist/automations/builtin-skill.js +14 -0
- package/dist/automations/builtin-skill.js.map +1 -0
- package/dist/automations/github-baseline.d.ts +3 -0
- package/dist/automations/github-baseline.js +17 -0
- package/dist/automations/github-baseline.js.map +1 -0
- package/dist/automations/github-poller.d.ts +23 -4
- package/dist/automations/github-poller.js +157 -88
- package/dist/automations/github-poller.js.map +1 -1
- package/dist/automations/prompts.d.ts +12 -0
- package/dist/automations/prompts.js +160 -0
- package/dist/automations/prompts.js.map +1 -0
- package/dist/automations/schedule-runner.d.ts +43 -24
- package/dist/automations/schedule-runner.js +207 -20
- package/dist/automations/schedule-runner.js.map +1 -1
- package/dist/automations/scheduler.d.ts +10 -2
- package/dist/automations/scheduler.js +200 -54
- package/dist/automations/scheduler.js.map +1 -1
- package/dist/automations/service.d.ts +777 -0
- package/dist/automations/service.js +444 -0
- package/dist/automations/service.js.map +1 -0
- package/dist/automations/store.d.ts +17 -7
- package/dist/automations/store.js +88 -17
- package/dist/automations/store.js.map +1 -1
- package/dist/automations/task-template.d.ts +7 -2
- package/dist/automations/task-template.js +93 -44
- package/dist/automations/task-template.js.map +1 -1
- package/dist/automations/tool-adapter.d.ts +6 -0
- package/dist/automations/tool-adapter.js +108 -0
- package/dist/automations/tool-adapter.js.map +1 -0
- package/dist/automations/types.d.ts +1 -405
- package/dist/automations/types.js +1 -218
- package/dist/automations/types.js.map +1 -1
- package/dist/autosave-cleanup.d.ts +26 -0
- package/dist/autosave-cleanup.js +87 -0
- package/dist/autosave-cleanup.js.map +1 -0
- package/dist/autosave-git.d.ts +3 -0
- package/dist/autosave-git.js +67 -35
- package/dist/autosave-git.js.map +1 -1
- package/dist/autosave-group.d.ts +8 -0
- package/dist/autosave-group.js +61 -0
- package/dist/autosave-group.js.map +1 -0
- package/dist/autosave-holders.d.ts +31 -4
- package/dist/autosave-holders.js +92 -7
- package/dist/autosave-holders.js.map +1 -1
- package/dist/autosave-windows.d.ts +14 -0
- package/dist/autosave-windows.js +36 -2
- package/dist/autosave-windows.js.map +1 -1
- package/dist/ci-wait/client.d.ts +20 -3
- package/dist/ci-wait/client.js +40 -44
- package/dist/ci-wait/client.js.map +1 -1
- package/dist/ci-wait/controller.d.ts +622 -36
- package/dist/ci-wait/controller.js +152 -20
- package/dist/ci-wait/controller.js.map +1 -1
- package/dist/ci-wait/errors.d.ts +19 -0
- package/dist/ci-wait/errors.js +180 -2
- package/dist/ci-wait/errors.js.map +1 -1
- package/dist/ci-wait/github.d.ts +25 -1
- package/dist/ci-wait/github.js +76 -9
- package/dist/ci-wait/github.js.map +1 -1
- package/dist/ci-wait/mcp.d.ts +0 -1
- package/dist/ci-wait/mcp.js +0 -2
- package/dist/ci-wait/mcp.js.map +1 -1
- package/dist/ci-wait/supervisor.d.ts +7 -0
- package/dist/ci-wait/supervisor.js +113 -17
- package/dist/ci-wait/supervisor.js.map +1 -1
- package/dist/ci-wait/tools.d.ts +536 -16
- package/dist/ci-wait/tools.js +165 -20
- package/dist/ci-wait/tools.js.map +1 -1
- package/dist/config.d.ts +3 -17
- package/dist/config.js +4 -60
- package/dist/config.js.map +1 -1
- package/dist/contract/active-provider.d.ts +12 -0
- package/dist/contract/agent-profiles.d.ts +2 -10
- package/dist/contract/ask-schema.d.ts +22 -4
- package/dist/contract/ask.d.ts +6 -4
- package/dist/contract/attachments.d.ts +35 -0
- package/dist/contract/attention.d.ts +46 -37
- package/dist/contract/automation-requests.d.ts +308 -0
- package/dist/contract/automation-schedule.d.ts +40 -11
- package/dist/contract/automation-storage.d.ts +512 -0
- package/dist/contract/automations.d.ts +421 -40
- package/dist/contract/ci-wait.d.ts +41 -4
- package/dist/contract/config-requests.d.ts +36 -0
- package/dist/contract/conversations.d.ts +24 -10
- package/dist/contract/defined.d.ts +8 -0
- package/dist/contract/delegation.d.ts +312 -8
- package/dist/contract/events.d.ts +24 -3
- package/dist/contract/github-requests.d.ts +26 -0
- package/dist/contract/github.d.ts +60 -27
- package/dist/contract/handoff.d.ts +43 -0
- package/dist/contract/health.d.ts +2 -2
- package/dist/contract/image-path.d.ts +6 -0
- package/dist/contract/index.d.ts +31 -0
- package/dist/contract/index.js +3756 -1525
- package/dist/contract/live-coordination.d.ts +158 -0
- package/dist/contract/live-limits.d.ts +8 -0
- package/dist/contract/live.d.ts +123 -0
- package/dist/contract/pending-ask.d.ts +58 -0
- package/dist/contract/permissions.d.ts +54 -0
- package/dist/contract/preview.d.ts +33 -0
- package/dist/contract/project-limits.d.ts +33 -0
- package/dist/contract/projects.d.ts +486 -20
- package/dist/contract/provider-requests.d.ts +77 -0
- package/dist/contract/query-requests.d.ts +52 -0
- package/dist/contract/repo-requests.d.ts +12 -0
- package/dist/contract/run-labels.d.ts +8 -0
- package/dist/contract/run-limits.d.ts +8 -0
- package/dist/contract/run-predicates.d.ts +32 -0
- package/dist/contract/run-requests.d.ts +33 -0
- package/dist/contract/run-search.d.ts +193 -0
- package/dist/contract/runs.d.ts +2232 -1894
- package/dist/contract/scheduled-tasks.d.ts +187 -0
- package/dist/contract/skills.d.ts +22 -772
- package/dist/contract/team-skill-ref.d.ts +10 -0
- package/dist/{core → contract}/tool-display.d.ts +4 -10
- package/dist/contract/ui-state-requests.d.ts +60 -0
- package/dist/contract/version.d.ts +3 -0
- package/dist/contract/voice.d.ts +213 -0
- package/dist/contract/waits.d.ts +1204 -0
- package/dist/contract/workflow-file.d.ts +37 -0
- package/dist/contract/workflow-requests.d.ts +7 -0
- package/dist/contract/workflows.d.ts +1 -2
- package/dist/contract/workspace.d.ts +34 -82
- package/dist/contract/zoned-time.d.ts +2 -11
- package/dist/core/agent-env.d.ts +4 -16
- package/dist/core/agent-env.js +14 -16
- package/dist/core/agent-env.js.map +1 -1
- package/dist/core/agent-profiles.d.ts +28 -40
- package/dist/core/agent-profiles.js +56 -51
- package/dist/core/agent-profiles.js.map +1 -1
- package/dist/core/agent-runner.d.ts +88 -44
- package/dist/core/agent-runner.js +17 -18
- package/dist/core/agent-runner.js.map +1 -1
- package/dist/core/ask.d.ts +3 -0
- package/dist/core/ask.js +12 -0
- package/dist/core/ask.js.map +1 -1
- package/dist/core/backend-detect.js +16 -2
- package/dist/core/backend-detect.js.map +1 -1
- package/dist/core/claude-cli-runner.d.ts +23 -4
- package/dist/core/claude-cli-runner.js +280 -76
- package/dist/core/claude-cli-runner.js.map +1 -1
- package/dist/core/claude-model-catalog.d.ts +2 -10
- package/dist/core/claude-model-catalog.js +2 -10
- package/dist/core/claude-model-catalog.js.map +1 -1
- package/dist/core/claude-ui-mapper.d.ts +2 -2
- package/dist/core/claude-ui-mapper.js +94 -2
- package/dist/core/claude-ui-mapper.js.map +1 -1
- package/dist/core/codex-app-server-runner.d.ts +3 -4
- package/dist/core/codex-app-server-runner.js +146 -51
- package/dist/core/codex-app-server-runner.js.map +1 -1
- package/dist/core/codex-app-server-transport.d.ts +4 -3
- package/dist/core/codex-app-server-transport.js +11 -7
- package/dist/core/codex-app-server-transport.js.map +1 -1
- package/dist/core/codex-approvals.d.ts +12 -0
- package/dist/core/codex-approvals.js +161 -0
- package/dist/core/codex-approvals.js.map +1 -0
- package/dist/core/codex-permissions.d.ts +1 -1
- package/dist/core/codex-ui-mapper.js +45 -1
- package/dist/core/codex-ui-mapper.js.map +1 -1
- package/dist/core/cursor-acp-runner.d.ts +1 -1
- package/dist/core/cursor-acp-runner.js +39 -15
- package/dist/core/cursor-acp-runner.js.map +1 -1
- package/dist/core/cursor-cli-flags.d.ts +19 -0
- package/dist/core/cursor-cli-flags.js +47 -0
- package/dist/core/cursor-cli-flags.js.map +1 -0
- package/dist/core/cursor-model-catalog.d.ts +22 -0
- package/dist/core/cursor-model-catalog.js +53 -24
- package/dist/core/cursor-model-catalog.js.map +1 -1
- package/dist/core/cursor-print-capabilities.d.ts +16 -0
- package/dist/core/cursor-print-capabilities.js +141 -0
- package/dist/core/cursor-print-capabilities.js.map +1 -0
- package/dist/core/cursor-print-process.d.ts +31 -0
- package/dist/core/cursor-print-process.js +117 -0
- package/dist/core/cursor-print-process.js.map +1 -0
- package/dist/core/cursor-print-runner.d.ts +31 -0
- package/dist/core/cursor-print-runner.js +555 -0
- package/dist/core/cursor-print-runner.js.map +1 -0
- package/dist/core/cursor-print-tool-catalog.d.ts +10 -0
- package/dist/core/cursor-print-tool-catalog.js +91 -0
- package/dist/core/cursor-print-tool-catalog.js.map +1 -0
- package/dist/core/cursor-print-ui-mapper.d.ts +47 -0
- package/dist/core/cursor-print-ui-mapper.js +553 -0
- package/dist/core/cursor-print-ui-mapper.js.map +1 -0
- package/dist/core/cursor-runner.d.ts +24 -0
- package/dist/core/cursor-runner.js +149 -0
- package/dist/core/cursor-runner.js.map +1 -0
- package/dist/core/cursor-ui-mapper.js +5 -2
- package/dist/core/cursor-ui-mapper.js.map +1 -1
- package/dist/core/defined.d.ts +1 -0
- package/dist/core/defined.js +2 -0
- package/dist/core/defined.js.map +1 -0
- package/dist/core/hook-items.d.ts +14 -0
- package/dist/core/hook-items.js +13 -0
- package/dist/core/hook-items.js.map +1 -0
- package/dist/core/host-model-catalog.d.ts +2 -9
- package/dist/core/host-model-catalog.js +2 -9
- package/dist/core/host-model-catalog.js.map +1 -1
- package/dist/core/managed-session.js +15 -3
- package/dist/core/managed-session.js.map +1 -1
- package/dist/core/model-identity.d.ts +4 -21
- package/dist/core/model-identity.js.map +1 -1
- package/dist/core/model-presets.d.ts +2 -13
- package/dist/core/model-presets.js +2 -13
- package/dist/core/model-presets.js.map +1 -1
- package/dist/core/omp-model-catalog.js.map +1 -1
- package/dist/core/omp-runner.d.ts +6 -7
- package/dist/core/omp-runner.js +92 -33
- package/dist/core/omp-runner.js.map +1 -1
- package/dist/core/omp-ui-mapper.js +1 -1
- package/dist/core/omp-ui-mapper.js.map +1 -1
- package/dist/core/opencode-model-catalog.js.map +1 -1
- package/dist/core/opencode-permissions.d.ts +52 -0
- package/dist/core/opencode-permissions.js +101 -0
- package/dist/core/opencode-permissions.js.map +1 -0
- package/dist/core/opencode-server-runner.d.ts +10 -9
- package/dist/core/opencode-server-runner.js +286 -28
- package/dist/core/opencode-server-runner.js.map +1 -1
- package/dist/core/opencode-session-error.d.ts +15 -7
- package/dist/core/opencode-session-error.js +25 -9
- package/dist/core/opencode-session-error.js.map +1 -1
- package/dist/core/opencode-ui-mapper.js +2 -2
- package/dist/core/opencode-ui-mapper.js.map +1 -1
- package/dist/core/pi-model-catalog.js.map +1 -1
- package/dist/core/pi-runner.d.ts +12 -4
- package/dist/core/pi-runner.js +171 -63
- package/dist/core/pi-runner.js.map +1 -1
- package/dist/core/pi-ui-mapper.js +1 -1
- package/dist/core/pi-ui-mapper.js.map +1 -1
- package/dist/core/process-usage.d.ts +5 -0
- package/dist/core/process-usage.js +24 -4
- package/dist/core/process-usage.js.map +1 -1
- package/dist/core/provider-auth.d.ts +16 -107
- package/dist/core/provider-auth.js +16 -132
- package/dist/core/provider-auth.js.map +1 -1
- package/dist/core/runner-factory.d.ts +4 -1
- package/dist/core/runner-factory.js +3 -3
- package/dist/core/runner-factory.js.map +1 -1
- package/dist/core/runner-runtime.d.ts +22 -0
- package/dist/core/runner-runtime.js +66 -5
- package/dist/core/runner-runtime.js.map +1 -1
- package/dist/core/runner-tool-grants.d.ts +21 -0
- package/dist/core/runner-tool-grants.js +64 -0
- package/dist/core/runner-tool-grants.js.map +1 -0
- package/dist/core/secret-redaction.d.ts +3 -20
- package/dist/core/secret-redaction.js +3 -20
- package/dist/core/secret-redaction.js.map +1 -1
- package/dist/core/session-process.d.ts +22 -2
- package/dist/core/session-process.js +170 -12
- package/dist/core/session-process.js.map +1 -1
- package/dist/core/shell-env.d.ts +2 -15
- package/dist/core/shell-env.js +2 -15
- package/dist/core/shell-env.js.map +1 -1
- package/dist/core/ui-events.d.ts +60 -47
- package/dist/core/ui-events.js +0 -23
- package/dist/core/ui-events.js.map +1 -1
- package/dist/core/usage-limit.js.map +1 -1
- package/dist/data-gitignore.js +3 -1
- package/dist/data-gitignore.js.map +1 -1
- package/dist/delegation/capacity.d.ts +4 -8
- package/dist/delegation/capacity.js +4 -8
- package/dist/delegation/capacity.js.map +1 -1
- package/dist/delegation/cli.js +123 -21
- package/dist/delegation/cli.js.map +1 -1
- package/dist/delegation/context.d.ts +19 -3
- package/dist/delegation/context.js +217 -22
- package/dist/delegation/context.js.map +1 -1
- package/dist/delegation/conversations.d.ts +4 -3
- package/dist/delegation/conversations.js +7 -5
- package/dist/delegation/conversations.js.map +1 -1
- package/dist/delegation/destroy-observation.d.ts +1 -1
- package/dist/delegation/destroy-observation.js.map +1 -1
- package/dist/delegation/effort.js.map +1 -1
- package/dist/delegation/execution-identity.d.ts +1 -1
- package/dist/delegation/execution-identity.js +41 -7
- package/dist/delegation/execution-identity.js.map +1 -1
- package/dist/delegation/idle-test-app.d.ts +4 -0
- package/dist/delegation/idle-test-app.js +174 -0
- package/dist/delegation/idle-test-app.js.map +1 -0
- package/dist/delegation/input.js.map +1 -1
- package/dist/delegation/park-notice.d.ts +42 -0
- package/dist/delegation/park-notice.js +71 -0
- package/dist/delegation/park-notice.js.map +1 -0
- package/dist/delegation/policy.d.ts +2 -0
- package/dist/delegation/policy.js +9 -1
- package/dist/delegation/policy.js.map +1 -1
- package/dist/delegation/process-liveness.d.ts +10 -15
- package/dist/delegation/process-liveness.js +11 -35
- package/dist/delegation/process-liveness.js.map +1 -1
- package/dist/delegation/provision.js +21 -19
- package/dist/delegation/provision.js.map +1 -1
- package/dist/delegation/questions.d.ts +3 -1
- package/dist/delegation/questions.js +10 -5
- package/dist/delegation/questions.js.map +1 -1
- package/dist/delegation/readiness.d.ts +2 -2
- package/dist/delegation/results.d.ts +4 -1
- package/dist/delegation/results.js +49 -18
- package/dist/delegation/results.js.map +1 -1
- package/dist/delegation/retry-backoff.d.ts +8 -0
- package/dist/delegation/retry-backoff.js +8 -0
- package/dist/delegation/retry-backoff.js.map +1 -1
- package/dist/delegation/routes.d.ts +114 -30
- package/dist/delegation/routes.js +4 -1
- package/dist/delegation/routes.js.map +1 -1
- package/dist/delegation/scratch-cleanup.d.ts +4 -5
- package/dist/delegation/scratch-cleanup.js +10 -8
- package/dist/delegation/scratch-cleanup.js.map +1 -1
- package/dist/delegation/service.d.ts +12 -4
- package/dist/delegation/service.js +76 -28
- package/dist/delegation/service.js.map +1 -1
- package/dist/delegation/transport.d.ts +154 -70
- package/dist/delegation/wait.d.ts +11 -0
- package/dist/delegation/wait.js +24 -0
- package/dist/delegation/wait.js.map +1 -1
- package/dist/delegation/windows-test-app.d.ts +5 -0
- package/dist/delegation/windows-test-app.js +63 -0
- package/dist/delegation/windows-test-app.js.map +1 -0
- package/dist/delegation/windows-workspace-identity.d.ts +3 -0
- package/dist/delegation/windows-workspace-identity.js +22 -0
- package/dist/delegation/windows-workspace-identity.js.map +1 -0
- package/dist/delegation/workspace.d.ts +5 -10
- package/dist/delegation/workspace.js +136 -75
- package/dist/delegation/workspace.js.map +1 -1
- package/dist/detached-process.d.ts +103 -0
- package/dist/detached-process.js +301 -0
- package/dist/detached-process.js.map +1 -0
- package/dist/discovery/catalog.d.ts +2 -1
- package/dist/discovery/catalog.js.map +1 -1
- package/dist/discovery/cli.js +3 -1
- package/dist/discovery/cli.js.map +1 -1
- package/dist/git-diff-base.d.ts +6 -61
- package/dist/git-diff-base.js +6 -70
- package/dist/git-diff-base.js.map +1 -1
- package/dist/git-index-copy.d.ts +4 -0
- package/dist/git-index-copy.js +10 -0
- package/dist/git-index-copy.js.map +1 -0
- package/dist/git-worktree-lock.d.ts +2 -4
- package/dist/git-worktree-lock.js +2 -4
- package/dist/git-worktree-lock.js.map +1 -1
- package/dist/git-worktree-release.d.ts +2 -2
- package/dist/git-worktree-release.js.map +1 -1
- package/dist/git-worktree.d.ts +47 -76
- package/dist/git-worktree.js +240 -94
- package/dist/git-worktree.js.map +1 -1
- package/dist/handoff.d.ts +51 -41
- package/dist/handoff.js +130 -78
- package/dist/handoff.js.map +1 -1
- package/dist/index.js +60 -39
- package/dist/index.js.map +1 -1
- package/dist/merge-observations.d.ts +13 -0
- package/dist/merge-observations.js +55 -0
- package/dist/merge-observations.js.map +1 -0
- package/dist/open-url.js +4 -14
- package/dist/open-url.js.map +1 -1
- package/dist/paths.d.ts +10 -13
- package/dist/paths.js +36 -17
- package/dist/paths.js.map +1 -1
- package/dist/planner.d.ts +2 -1
- package/dist/planner.js +9 -6
- package/dist/planner.js.map +1 -1
- package/dist/preview/agent-address.d.ts +34 -0
- package/dist/preview/agent-address.js +51 -0
- package/dist/preview/agent-address.js.map +1 -0
- package/dist/preview/agent-marker.d.ts +17 -0
- package/dist/preview/agent-marker.js +71 -0
- package/dist/preview/agent-marker.js.map +1 -0
- package/dist/preview/cdp-proxy.d.ts +54 -0
- package/dist/preview/cdp-proxy.js +151 -0
- package/dist/preview/cdp-proxy.js.map +1 -0
- package/dist/preview/cdp.d.ts +39 -3
- package/dist/preview/cdp.js +155 -57
- package/dist/preview/cdp.js.map +1 -1
- package/dist/preview/chromium.d.ts +18 -6
- package/dist/preview/chromium.js +112 -25
- package/dist/preview/chromium.js.map +1 -1
- package/dist/preview/dev-server.d.ts +1 -1
- package/dist/preview/dev-server.js +20 -44
- package/dist/preview/dev-server.js.map +1 -1
- package/dist/preview/host.d.ts +70 -3
- package/dist/preview/host.js +314 -28
- package/dist/preview/host.js.map +1 -1
- package/dist/preview/registration.d.ts +10 -5
- package/dist/preview/registration.js +2 -0
- package/dist/preview/registration.js.map +1 -1
- package/dist/preview/session.d.ts +2 -0
- package/dist/preview/session.js +10 -0
- package/dist/preview/session.js.map +1 -1
- package/dist/process-wait/exit-file.d.ts +29 -0
- package/dist/process-wait/exit-file.js +67 -0
- package/dist/process-wait/exit-file.js.map +1 -0
- package/dist/process-wait/supervisor.d.ts +30 -0
- package/dist/process-wait/supervisor.js +71 -0
- package/dist/process-wait/supervisor.js.map +1 -0
- package/dist/release/snapshot.d.ts +6 -6
- package/dist/runs/agent-tmpdir.d.ts +51 -36
- package/dist/runs/agent-tmpdir.js +389 -132
- package/dist/runs/agent-tmpdir.js.map +1 -1
- package/dist/runs/auto-name.d.ts +6 -6
- package/dist/runs/auto-name.js +1 -1
- package/dist/runs/auto-name.js.map +1 -1
- package/dist/runs/client-request.d.ts +3 -3
- package/dist/runs/client-request.js +3 -3
- package/dist/runs/client-request.js.map +1 -1
- package/dist/runs/delegation-state.d.ts +11 -2
- package/dist/runs/delegation-state.js.map +1 -1
- package/dist/runs/event-history-agent-context.d.ts +14 -0
- package/dist/runs/event-history-agent-context.js +105 -0
- package/dist/runs/event-history-agent-context.js.map +1 -0
- package/dist/runs/event-history-context.d.ts +15 -0
- package/dist/runs/event-history-context.js +109 -0
- package/dist/runs/event-history-context.js.map +1 -0
- package/dist/runs/event-history.d.ts +4 -1
- package/dist/runs/event-history.js +29 -130
- package/dist/runs/event-history.js.map +1 -1
- package/dist/runs/history-stream.d.ts +2 -0
- package/dist/runs/history-stream.js +62 -0
- package/dist/runs/history-stream.js.map +1 -0
- package/dist/runs/legacy-index.d.ts +6 -19
- package/dist/runs/legacy-index.js +6 -19
- package/dist/runs/legacy-index.js.map +1 -1
- package/dist/runs/live-item-snapshots.d.ts +13 -0
- package/dist/runs/live-item-snapshots.js +79 -0
- package/dist/runs/live-item-snapshots.js.map +1 -0
- package/dist/runs/loaded-run-healing.d.ts +3 -0
- package/dist/runs/loaded-run-healing.js +17 -0
- package/dist/runs/loaded-run-healing.js.map +1 -0
- package/dist/runs/outcome-commit.d.ts +98 -0
- package/dist/runs/outcome-commit.js +132 -0
- package/dist/runs/outcome-commit.js.map +1 -0
- package/dist/runs/pull-requests.d.ts +14 -0
- package/dist/runs/pull-requests.js +96 -0
- package/dist/runs/pull-requests.js.map +1 -0
- package/dist/runs/raw-record.d.ts +3 -15
- package/dist/runs/raw-record.js +3 -15
- package/dist/runs/raw-record.js.map +1 -1
- package/dist/runs/retention.d.ts +2 -2
- package/dist/runs/retention.js +7 -0
- package/dist/runs/retention.js.map +1 -1
- package/dist/runs/review-gate.d.ts +1 -1
- package/dist/runs/review-gate.js.map +1 -1
- package/dist/runs/run-claims.d.ts +2 -9
- package/dist/runs/run-claims.js.map +1 -1
- package/dist/runs/run-database.d.ts +29 -34
- package/dist/runs/run-database.js +124 -46
- package/dist/runs/run-database.js.map +1 -1
- package/dist/runs/run-index.d.ts +6 -25
- package/dist/runs/run-index.js +25 -38
- package/dist/runs/run-index.js.map +1 -1
- package/dist/runs/run-row.d.ts +5 -34
- package/dist/runs/run-row.js +13 -38
- package/dist/runs/run-row.js.map +1 -1
- package/dist/runs/store.d.ts +1597 -744
- package/dist/runs/store.js +1231 -739
- package/dist/runs/store.js.map +1 -1
- package/dist/runs/task-markers.d.ts +1 -0
- package/dist/runs/task-markers.js +5 -1
- package/dist/runs/task-markers.js.map +1 -1
- package/dist/runs/task-refs.d.ts +3 -3
- package/dist/runs/transcript-facts-fold.d.ts +64 -0
- package/dist/runs/transcript-facts-fold.js +109 -0
- package/dist/runs/transcript-facts-fold.js.map +1 -0
- package/dist/runs/transcript-facts-load.d.ts +11 -0
- package/dist/runs/transcript-facts-load.js +66 -0
- package/dist/runs/transcript-facts-load.js.map +1 -0
- package/dist/runs/transcript-facts-queue.d.ts +30 -0
- package/dist/runs/transcript-facts-queue.js +227 -0
- package/dist/runs/transcript-facts-queue.js.map +1 -0
- package/dist/runs/transcript-facts-worker.d.ts +15 -0
- package/dist/runs/transcript-facts-worker.js +26 -0
- package/dist/runs/transcript-facts-worker.js.map +1 -0
- package/dist/runs/transcript-facts.d.ts +13 -51
- package/dist/runs/transcript-facts.js +86 -202
- package/dist/runs/transcript-facts.js.map +1 -1
- package/dist/runs/ui-event-sink.d.ts +5 -30
- package/dist/runs/ui-event-sink.js +8 -30
- package/dist/runs/ui-event-sink.js.map +1 -1
- package/dist/runs/webhook.d.ts +104 -38
- package/dist/runs/webhook.js +180 -77
- package/dist/runs/webhook.js.map +1 -1
- package/dist/server/app-type.d.ts +2 -17
- package/dist/server/archive-on-merge.d.ts +35 -0
- package/dist/server/archive-on-merge.js +202 -0
- package/dist/server/archive-on-merge.js.map +1 -0
- package/dist/server/capabilities.d.ts +3 -15
- package/dist/server/capabilities.js +6 -19
- package/dist/server/capabilities.js.map +1 -1
- package/dist/server/checkout-progress.d.ts +10 -0
- package/dist/server/checkout-progress.js +27 -0
- package/dist/server/checkout-progress.js.map +1 -0
- package/dist/server/checkout.d.ts +10 -19
- package/dist/server/checkout.js +15 -45
- package/dist/server/checkout.js.map +1 -1
- package/dist/server/cockpit-ownership.d.ts +2 -0
- package/dist/server/cockpit-ownership.js +9 -0
- package/dist/server/cockpit-ownership.js.map +1 -1
- package/dist/server/cold-repo-handles.d.ts +2 -7
- package/dist/server/cold-repo-handles.js +2 -7
- package/dist/server/cold-repo-handles.js.map +1 -1
- package/dist/server/completion-actions.d.ts +30 -0
- package/dist/server/completion-actions.js +204 -0
- package/dist/server/completion-actions.js.map +1 -0
- package/dist/server/create-project.d.ts +71 -0
- package/dist/server/create-project.js +448 -0
- package/dist/server/create-project.js.map +1 -0
- package/dist/server/forge/github-filters.d.ts +7 -1
- package/dist/server/forge/github-filters.js +66 -51
- package/dist/server/forge/github-filters.js.map +1 -1
- package/dist/server/forge/github-merge-requirements.d.ts +18 -0
- package/dist/server/forge/github-merge-requirements.js +137 -0
- package/dist/server/forge/github-merge-requirements.js.map +1 -0
- package/dist/server/forge/github.d.ts +98 -111
- package/dist/server/forge/github.js +625 -306
- package/dist/server/forge/github.js.map +1 -1
- package/dist/server/forge/types.d.ts +25 -22
- package/dist/server/fs-browse.d.ts +3 -28
- package/dist/server/fs-browse.js.map +1 -1
- package/dist/server/git-changes.d.ts +5 -15
- package/dist/server/git-changes.js +3 -50
- package/dist/server/git-changes.js.map +1 -1
- package/dist/server/git.d.ts +3 -1
- package/dist/server/git.js +12 -0
- package/dist/server/git.js.map +1 -1
- package/dist/server/github.d.ts +1 -1
- package/dist/server/github.js +1 -1
- package/dist/server/github.js.map +1 -1
- package/dist/server/launch-key.d.ts +2 -4
- package/dist/server/launch-key.js +2 -4
- package/dist/server/launch-key.js.map +1 -1
- package/dist/server/live-routes.d.ts +68 -0
- package/dist/server/live-routes.js +147 -0
- package/dist/server/live-routes.js.map +1 -0
- package/dist/server/open-in-app.d.ts +4 -13
- package/dist/server/open-in-app.js +5 -41
- package/dist/server/open-in-app.js.map +1 -1
- package/dist/server/open-in-targets.d.ts +42 -0
- package/dist/server/open-in-targets.js +110 -0
- package/dist/server/open-in-targets.js.map +1 -0
- package/dist/server/open-in-terminal.d.ts +3 -0
- package/dist/server/open-in-terminal.js +6 -26
- package/dist/server/open-in-terminal.js.map +1 -1
- package/dist/server/preview-cdp-socket.d.ts +21 -0
- package/dist/server/preview-cdp-socket.js +112 -0
- package/dist/server/preview-cdp-socket.js.map +1 -0
- package/dist/server/preview-socket.d.ts +11 -11
- package/dist/server/preview-socket.js +22 -22
- package/dist/server/preview-socket.js.map +1 -1
- package/dist/server/preview-sockets.d.ts +14 -0
- package/dist/server/preview-sockets.js +18 -0
- package/dist/server/preview-sockets.js.map +1 -0
- package/dist/server/project-context.d.ts +54 -18
- package/dist/server/project-context.js +178 -5
- package/dist/server/project-context.js.map +1 -1
- package/dist/server/provider-action-gate.d.ts +0 -2
- package/dist/server/provider-action-gate.js +0 -21
- package/dist/server/provider-action-gate.js.map +1 -1
- package/dist/server/provider-auth-runtime.d.ts +3 -18
- package/dist/server/provider-auth-runtime.js +3 -18
- package/dist/server/provider-auth-runtime.js.map +1 -1
- package/dist/server/repo-branches.d.ts +3 -9
- package/dist/server/repo-branches.js +6 -22
- package/dist/server/repo-branches.js.map +1 -1
- package/dist/server/run-event-feed.d.ts +20 -0
- package/dist/server/run-event-feed.js +190 -0
- package/dist/server/run-event-feed.js.map +1 -0
- package/dist/server/server-deps.d.ts +37 -0
- package/dist/server/server-deps.js +114 -0
- package/dist/server/server-deps.js.map +1 -0
- package/dist/server/server.d.ts +14082 -11998
- package/dist/server/server.js +785 -1647
- package/dist/server/server.js.map +1 -1
- package/dist/server/start-run-options.d.ts +82 -0
- package/dist/server/start-run-options.js +111 -0
- package/dist/server/start-run-options.js.map +1 -0
- package/dist/server/validators.d.ts +3 -29
- package/dist/server/validators.js +1 -2
- package/dist/server/validators.js.map +1 -1
- package/dist/server/ws.d.ts +3 -23
- package/dist/server/ws.js +3 -23
- package/dist/server/ws.js.map +1 -1
- package/dist/server-install/engine.d.ts +6 -9
- package/dist/server-install/engine.js +2 -9
- package/dist/server-install/engine.js.map +1 -1
- package/dist/server-install/platforms/ubuntu-vps.d.ts +1 -1
- package/dist/server-install/state.d.ts +2 -4
- package/dist/server-install/state.js +2 -4
- package/dist/server-install/state.js.map +1 -1
- package/dist/server-install/steps.d.ts +2 -5
- package/dist/server-install/steps.js +3 -6
- package/dist/server-install/steps.js.map +1 -1
- package/dist/server-install/types.d.ts +3 -6
- package/dist/server-install/types.js +2 -5
- package/dist/server-install/types.js.map +1 -1
- package/dist/server-install/ui.d.ts +2 -8
- package/dist/server-install/ui.js +3 -3
- package/dist/server-install/ui.js.map +1 -1
- package/dist/session-context.d.ts +64 -0
- package/dist/session-context.js +264 -0
- package/dist/session-context.js.map +1 -0
- package/dist/skills-provision.d.ts +62 -0
- package/dist/skills-provision.js +325 -0
- package/dist/skills-provision.js.map +1 -0
- package/dist/skills-remote.d.ts +29 -27
- package/dist/skills-remote.js +236 -100
- package/dist/skills-remote.js.map +1 -1
- package/dist/skills.d.ts +25 -36
- package/dist/skills.js +43 -54
- package/dist/skills.js.map +1 -1
- package/dist/subcommands.d.ts +11 -0
- package/dist/subcommands.js +24 -0
- package/dist/subcommands.js.map +1 -0
- package/dist/task-cli/cli.js +78 -25
- package/dist/task-cli/cli.js.map +1 -1
- package/dist/task-cli/discovery.d.ts +4 -2
- package/dist/task-cli/discovery.js +14 -13
- package/dist/task-cli/discovery.js.map +1 -1
- package/dist/task-cli/hint.d.ts +20 -0
- package/dist/task-cli/hint.js +14 -0
- package/dist/task-cli/hint.js.map +1 -0
- package/dist/task-cli/http.d.ts +1 -0
- package/dist/task-cli/http.js +3 -1
- package/dist/task-cli/http.js.map +1 -1
- package/dist/task-cli/projections.d.ts +14 -11
- package/dist/task-cli/projections.js +15 -11
- package/dist/task-cli/projections.js.map +1 -1
- package/dist/task-cli/watch.d.ts +18 -10
- package/dist/task-cli/watch.js +128 -20
- package/dist/task-cli/watch.js.map +1 -1
- package/dist/ui-state.d.ts +17 -3
- package/dist/ui-state.js +56 -9
- package/dist/ui-state.js.map +1 -1
- package/dist/update-check.d.ts +0 -10
- package/dist/update-check.js +1 -16
- package/dist/update-check.js.map +1 -1
- package/dist/voice/decide.d.ts +32 -0
- package/dist/voice/decide.js +297 -0
- package/dist/voice/decide.js.map +1 -0
- package/dist/voice/decision-log.d.ts +52 -0
- package/dist/voice/decision-log.js +107 -0
- package/dist/voice/decision-log.js.map +1 -0
- package/dist/voice/engine.d.ts +119 -0
- package/dist/voice/engine.js +60 -0
- package/dist/voice/engine.js.map +1 -0
- package/dist/voice/fake-engine.d.ts +10 -0
- package/dist/voice/fake-engine.js +192 -0
- package/dist/voice/fake-engine.js.map +1 -0
- package/dist/voice/jev-engine.d.ts +17 -0
- package/dist/voice/jev-engine.js +110 -0
- package/dist/voice/jev-engine.js.map +1 -0
- package/dist/voice/pending-ask.d.ts +17 -0
- package/dist/voice/pending-ask.js +50 -0
- package/dist/voice/pending-ask.js.map +1 -0
- package/dist/voice/routes.d.ts +115 -0
- package/dist/voice/routes.js +91 -0
- package/dist/voice/routes.js.map +1 -0
- package/dist/voice/sentence.d.ts +21 -0
- package/dist/voice/sentence.js +61 -0
- package/dist/voice/sentence.js.map +1 -0
- package/dist/voice/thresholds.d.ts +28 -0
- package/dist/voice/thresholds.js +29 -0
- package/dist/voice/thresholds.js.map +1 -0
- package/dist/webhooks/cli.d.ts +18 -0
- package/dist/webhooks/cli.js +145 -0
- package/dist/webhooks/cli.js.map +1 -0
- package/dist/webhooks/prompt.d.ts +5 -0
- package/dist/webhooks/prompt.js +26 -0
- package/dist/webhooks/prompt.js.map +1 -0
- package/dist/workflows/active-run.d.ts +167 -0
- package/dist/workflows/active-run.js +21 -0
- package/dist/workflows/active-run.js.map +1 -0
- package/dist/workflows/continuation-admission.d.ts +913 -0
- package/dist/workflows/continuation-admission.js +265 -0
- package/dist/workflows/continuation-admission.js.map +1 -0
- package/dist/workflows/execution-account.d.ts +13 -0
- package/dist/workflows/execution-account.js +18 -0
- package/dist/workflows/execution-account.js.map +1 -0
- package/dist/workflows/input-acknowledgement.d.ts +152 -0
- package/dist/workflows/input-acknowledgement.js +38 -0
- package/dist/workflows/input-acknowledgement.js.map +1 -0
- package/dist/workflows/line-order.d.ts +5 -0
- package/dist/workflows/line-order.js +25 -0
- package/dist/workflows/line-order.js.map +1 -0
- package/dist/workflows/outcome-batches.d.ts +20 -0
- package/dist/workflows/outcome-batches.js +25 -0
- package/dist/workflows/outcome-batches.js.map +1 -0
- package/dist/workflows/question-routing.d.ts +8 -0
- package/dist/workflows/question-routing.js +18 -0
- package/dist/workflows/question-routing.js.map +1 -0
- package/dist/workflows/run-scheduling.d.ts +35 -0
- package/dist/workflows/run-scheduling.js +61 -0
- package/dist/workflows/run-scheduling.js.map +1 -0
- package/dist/workflows/run-states.d.ts +190 -0
- package/dist/workflows/run-states.js +295 -0
- package/dist/workflows/run-states.js.map +1 -0
- package/dist/workflows/run.d.ts +1296 -278
- package/dist/workflows/run.js +5730 -3265
- package/dist/workflows/run.js.map +1 -1
- package/dist/workflows/turn-end.d.ts +116 -0
- package/dist/workflows/turn-end.js +68 -0
- package/dist/workflows/turn-end.js.map +1 -0
- package/dist/workflows/types.d.ts +35 -130
- package/dist/workflows/types.js +47 -100
- package/dist/workflows/types.js.map +1 -1
- package/dist/workflows/waits.d.ts +74 -0
- package/dist/workflows/waits.js +197 -0
- package/dist/workflows/waits.js.map +1 -0
- package/dist/workspace/agent-accounts.d.ts +5 -38
- package/dist/workspace/agent-accounts.js +14 -40
- package/dist/workspace/agent-accounts.js.map +1 -1
- package/dist/workspace/agent-profiles.d.ts +40 -16
- package/dist/workspace/agent-profiles.js +77 -17
- package/dist/workspace/agent-profiles.js.map +1 -1
- package/dist/workspace/config.d.ts +48 -49
- package/dist/workspace/config.js +68 -72
- package/dist/workspace/config.js.map +1 -1
- package/dist/workspace/migrations.d.ts +3 -13
- package/dist/workspace/migrations.js.map +1 -1
- package/dist/workspace/projects-cli.d.ts +1 -1
- package/dist/workspace/projects-cli.js.map +1 -1
- package/dist/workspace/projects.d.ts +15 -18
- package/dist/workspace/projects.js +20 -16
- package/dist/workspace/projects.js.map +1 -1
- package/dist/workspace/semaphore.d.ts +11 -45
- package/dist/workspace/semaphore.js +6 -18
- package/dist/workspace/semaphore.js.map +1 -1
- package/dist/workspace/ui-state.d.ts +6 -4
- package/dist/workspace/ui-state.js +6 -4
- package/dist/workspace/ui-state.js.map +1 -1
- package/dist/workspace/webhooks.d.ts +40 -0
- package/dist/workspace/webhooks.js +146 -0
- package/dist/workspace/webhooks.js.map +1 -0
- package/dist/worktree-manifest.d.ts +165 -0
- package/dist/worktree-manifest.js +530 -0
- package/dist/worktree-manifest.js.map +1 -0
- package/dist/worktree-setup.js.map +1 -1
- package/package.json +6 -5
- package/scripts/benchmark-run-store-fixture.ts +7 -3
- package/scripts/check-pack.mjs +3 -1
- package/scripts/inline-contract.mjs +80 -27
- package/scripts/install-as-command.mjs +3 -1
- package/scripts/measure-transcript-facts-health.mjs +87 -0
- package/scripts/measure-transcript-facts-lag.mjs +68 -0
- package/scripts/mock-ci-tool.mjs +49 -6
- package/scripts/mock-claude-model-refusal.mjs +42 -0
- package/scripts/mock-claude.mjs +833 -591
- package/scripts/mock-codex-app-server.mjs +785 -418
- package/scripts/mock-cursor-acp.mjs +296 -125
- package/scripts/mock-cursor-print.mjs +256 -0
- package/scripts/mock-deferred-turn-start.mjs +16 -0
- package/scripts/mock-delivery-control.d.mts +23 -0
- package/scripts/mock-delivery-control.mjs +80 -0
- package/scripts/mock-env-record.mjs +11 -0
- package/scripts/mock-failure-control.d.mts +13 -0
- package/scripts/mock-failure-control.mjs +68 -0
- package/scripts/mock-multi-pr.mjs +7 -0
- package/scripts/mock-nudge.mjs +45 -0
- package/scripts/mock-omp-rpc.mjs +429 -255
- package/scripts/mock-opencode-serve.mjs +972 -557
- package/scripts/mock-pi-rpc.mjs +558 -331
- package/scripts/mock-runner-crash.mjs +18 -2
- package/scripts/mock-session-context.d.mts +5 -0
- package/scripts/mock-session-context.mjs +56 -0
- package/scripts/mock-silent-tail.mjs +10 -3
- package/scripts/pi-default-tools.mjs +22 -0
- package/scripts/pi-project-skills.mjs +59 -0
- package/scripts/probe-cursor-print.mjs +627 -0
- package/scripts/transcript-facts-fixture.mjs +53 -0
- package/scripts/voice-replay.ts +50 -0
- package/scripts/windows-workspace-identity.cs +208 -0
- package/scripts/windows-workspace-identity.ps1 +10 -0
- package/web/dist/assets/alert-dialog-DfctKUMw.js +1 -0
- package/web/dist/assets/button-CeupvoKG.js +41 -0
- package/web/dist/assets/centered-state-hDsyXrnH.js +1 -0
- package/web/dist/assets/cez-idle-D3aj_9lp.js +1 -0
- package/web/dist/assets/diff-BnIXZK3i2.js +3 -0
- package/web/dist/assets/diff-controls-GewpW9aF.js +1 -0
- package/web/dist/assets/diff-view-Byo7gpvW.js +11 -0
- package/web/dist/assets/dropdown-menu-COj_J5wd.js +6 -0
- package/web/dist/assets/eye-B8okNWXU.js +1 -0
- package/web/dist/assets/git-toolbar-DY0z0n4S.js +1 -0
- package/web/dist/assets/github-DwU6ALRK.js +1 -0
- package/web/dist/assets/{image-preview-FOEfqpZP.js → image-preview-C_t9q45f.js} +1 -1
- package/web/dist/assets/index-BOfE8pyD.js +34 -0
- package/web/dist/assets/index-D9HpsmdW.css +1 -0
- package/web/dist/assets/live-protocol-Uce2NwEX.js +64 -0
- package/web/dist/assets/live-worker-BizfZSoh.ts +33 -0
- package/web/dist/assets/markdown-BBDDg-4t.js +1 -0
- package/web/dist/assets/nav-row-styles-AoIhhIwf.js +1 -0
- package/web/dist/assets/popover-D56fhiXj.js +1 -0
- package/web/dist/assets/preview-pane-connected-BmVqfSU5.js +3 -0
- package/web/dist/assets/reference-chip-gQNk-4jc.js +1 -0
- package/web/dist/assets/repo-git-B5ECDUuv.js +1 -0
- package/web/dist/assets/{repo-git-CoKp-g9K.css → repo-git-DVXNOJDT.css} +1 -1
- package/web/dist/assets/run-header-C0Y1NvEM.js +2 -0
- package/web/dist/assets/run-header-CC7VUTg9.css +1 -0
- package/web/dist/assets/skills-DUeTkZ9z.js +1 -0
- package/web/dist/assets/status-dot-1PR0i69P.js +1 -0
- package/web/dist/assets/tab-link-DmWk4l5O.js +1 -0
- package/web/dist/assets/task-changes-DKZXuW89.js +1 -0
- package/web/dist/assets/task-commits-BZ6KxWdF.js +1 -0
- package/web/dist/assets/task-files-DlF7Apcn.js +2 -0
- package/web/dist/assets/task-github-item-CVPo3geZ.js +1 -0
- package/web/dist/assets/task-thread-DtQ6uGfQ.css +1 -0
- package/web/dist/assets/task-thread-mm4-ECyo.js +9 -0
- package/web/dist/assets/thread-state-CIw2BlhT.js +4 -0
- package/web/dist/assets/use-hand-to-agent-state-BCDjzHnG.js +1 -0
- package/web/dist/assets/use-hand-to-agent-state-C7esPJ-N.css +1 -0
- package/web/dist/assets/workflows-D8vYD-ql.js +7 -0
- package/web/dist/assets/zoomable-image-CxQSsfcn.js +1 -0
- package/web/dist/index.html +13 -17
- package/web/dist/live-worker.js +4 -0
- package/dist/core/tool-display.js +0 -179
- package/dist/core/tool-display.js.map +0 -1
- package/dist/runs/human-ask-summary.d.ts +0 -9
- package/dist/runs/human-ask-summary.js +0 -39
- package/dist/runs/human-ask-summary.js.map +0 -1
- package/dist/runs/run-search.d.ts +0 -29
- package/dist/runs/run-search.js +0 -63
- package/dist/runs/run-search.js.map +0 -1
- package/dist/skills-banner.d.ts +0 -22
- package/dist/skills-banner.js +0 -41
- package/dist/skills-banner.js.map +0 -1
- package/dist/skills-update.d.ts +0 -88
- package/dist/skills-update.js +0 -392
- package/dist/skills-update.js.map +0 -1
- package/dist/todos.d.ts +0 -48
- package/dist/todos.js +0 -201
- package/dist/todos.js.map +0 -1
- package/web/dist/assets/agent-accounts-CFOBMVHc.js +0 -1
- package/web/dist/assets/alert-dialog-BrpNUwMt.js +0 -1
- package/web/dist/assets/button-C_rd7CPp.js +0 -43
- package/web/dist/assets/compare-variants-D6WXhvXA.js +0 -1
- package/web/dist/assets/diff-DrEARXTV.js +0 -3
- package/web/dist/assets/diff-controls-B1-j7nFg.js +0 -1
- package/web/dist/assets/diff-view-DvGLjdTk.js +0 -6
- package/web/dist/assets/dropdown-menu-BegOZFrj.js +0 -1
- package/web/dist/assets/format-DpNe3S0A.js +0 -1
- package/web/dist/assets/git-toolbar-Cw4ljmhB.js +0 -1
- package/web/dist/assets/github-CfV5sqL0.js +0 -1
- package/web/dist/assets/index-DgWWlOLy.js +0 -13
- package/web/dist/assets/index-fBFnuvxu.css +0 -1
- package/web/dist/assets/nav-row-styles-vp2JbhuJ.js +0 -1
- package/web/dist/assets/popover-BohP6WTx.js +0 -1
- package/web/dist/assets/preview-pane-connected-qTA5KNoJ.js +0 -3
- package/web/dist/assets/preview-state-vuMviq6q.js +0 -1
- package/web/dist/assets/prompt-templates-Cubdut_C.js +0 -15
- package/web/dist/assets/repo-git-Cf4t5PD0.js +0 -1
- package/web/dist/assets/run-diff-BpkUW37Z.js +0 -3
- package/web/dist/assets/run-header-68WHf9wV.js +0 -1
- package/web/dist/assets/run-header-8GObNx6F.css +0 -1
- package/web/dist/assets/search-x-I9Q8pgUa.js +0 -1
- package/web/dist/assets/skills-DFBiAuJG.js +0 -1
- package/web/dist/assets/skills-DiVIgKeU.js +0 -1
- package/web/dist/assets/square-terminal-B6RYYieR.js +0 -1
- package/web/dist/assets/status-dot-CqTJHSP9.js +0 -1
- package/web/dist/assets/tab-link-B07Hu4QX.js +0 -1
- package/web/dist/assets/task-changes--lQF6EYf.js +0 -1
- package/web/dist/assets/task-commits-Cx0qy4DN.js +0 -1
- package/web/dist/assets/task-files-D50s-gKW.js +0 -2
- package/web/dist/assets/task-github-item-DaqmSwYT.js +0 -1
- package/web/dist/assets/task-thread-BPQ64lui.js +0 -7
- package/web/dist/assets/task-thread-zNE2Q9E-.css +0 -1
- package/web/dist/assets/textarea-D20O4Pw0.js +0 -1
- package/web/dist/assets/thread-state-DWcFMrvb.js +0 -4
- package/web/dist/assets/use-hand-to-agent-state-BLIGmwbd.css +0 -1
- package/web/dist/assets/use-hand-to-agent-state-Cy9eyyfL.js +0 -1
- package/web/dist/assets/utils-JsL3ZsJf.js +0 -64
- package/web/dist/assets/workflows-jwG7uxqi.js +0 -11
- package/web/dist/assets/zoomable-image-BJJ64KGc.js +0 -1
|
@@ -1,21 +1,6 @@
|
|
|
1
1
|
import type { createApp } from './server.ts';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* This is the whole boundary between the cezar service and a typed consumer: Hono infers an
|
|
6
|
-
* app's endpoint table from the app's *type*, and `hc<AppType>` turns that table into a client
|
|
7
|
-
* whose paths, request bodies and response shapes are checked at compile time. No hand-written
|
|
8
|
-
* mirror, no schema to author twice — the routes ARE the contract.
|
|
9
|
-
*
|
|
10
|
-
* Only routes registered through a **chained** builder appear here — a loose `api.get(…)`
|
|
11
|
-
* statement discards its return value and with it the accumulated route type. Every family in
|
|
12
|
-
* `server.ts` is now chained and mounted into the versioned table, so this type covers the whole
|
|
13
|
-
* `/api/v1` surface; `versioned-surface.test.ts` fails on any route that escapes it. A new route
|
|
14
|
-
* added as a link in its family's chain widens this type automatically — nothing here needs
|
|
15
|
-
* updating, and nothing here should be hand-written.
|
|
16
|
-
*
|
|
17
|
-
* Type-only by construction: importing this module pulls in no runtime code (`import type`
|
|
18
|
-
* disappears at build), which is what lets a browser bundle consume it without dragging
|
|
19
|
-
* `node:*` in.
|
|
3
|
+
* Type-only HTTP route table inferred from chained versioned family builders. Loose
|
|
4
|
+
* registrations discard accumulated route types. This module must introduce no runtime imports.
|
|
20
5
|
*/
|
|
21
6
|
export type AppType = ReturnType<typeof createApp>;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import type { ArchivePullRequestIdentity, MergedPullRequest } from '../contract/index.js';
|
|
2
|
+
import type { RunStore } from '../runs/store.ts';
|
|
3
|
+
export interface ArchiveProject {
|
|
4
|
+
id: string;
|
|
5
|
+
root: string;
|
|
6
|
+
status?: string;
|
|
7
|
+
}
|
|
8
|
+
export interface ArchiveOnMergeDeps {
|
|
9
|
+
projects(): Promise<readonly ArchiveProject[]>;
|
|
10
|
+
enabled(project: ArchiveProject): Promise<boolean>;
|
|
11
|
+
repository(project: ArchiveProject): Promise<string | undefined>;
|
|
12
|
+
withStore<T>(project: ArchiveProject, work: (store: RunStore, isActive: (id: string) => boolean, current: () => boolean) => Promise<T>): Promise<T | undefined>;
|
|
13
|
+
lookup(root: string, identities: ArchivePullRequestIdentity[], signal: AbortSignal): Promise<MergedPullRequest[]>;
|
|
14
|
+
}
|
|
15
|
+
/** One browser-independent workspace poller. Never builds a manager or recovers a run. */
|
|
16
|
+
export declare class ArchiveOnMergeCoordinator {
|
|
17
|
+
private readonly deps;
|
|
18
|
+
private readonly interval;
|
|
19
|
+
private timer?;
|
|
20
|
+
private busy;
|
|
21
|
+
private stopped;
|
|
22
|
+
private generation;
|
|
23
|
+
private abort?;
|
|
24
|
+
private projectCursor;
|
|
25
|
+
private readonly cursors;
|
|
26
|
+
private readonly pending;
|
|
27
|
+
private readonly failures;
|
|
28
|
+
constructor(deps: ArchiveOnMergeDeps, interval?: number);
|
|
29
|
+
start(): void;
|
|
30
|
+
stop(): void;
|
|
31
|
+
/** A saved preference invalidates lookups already in flight, even if changed back quickly. */
|
|
32
|
+
invalidate(): void;
|
|
33
|
+
tick(): Promise<void>;
|
|
34
|
+
private tickProject;
|
|
35
|
+
}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
import { pullRequestKey } from '../runs/pull-requests.js';
|
|
2
|
+
/** One browser-independent workspace poller. Never builds a manager or recovers a run. */
|
|
3
|
+
export class ArchiveOnMergeCoordinator {
|
|
4
|
+
deps;
|
|
5
|
+
interval;
|
|
6
|
+
timer;
|
|
7
|
+
busy = false;
|
|
8
|
+
stopped = false;
|
|
9
|
+
generation = 0;
|
|
10
|
+
abort;
|
|
11
|
+
projectCursor = 0;
|
|
12
|
+
cursors = new Map();
|
|
13
|
+
pending = new Map();
|
|
14
|
+
failures = new Map();
|
|
15
|
+
constructor(deps, interval = 60_000) {
|
|
16
|
+
this.deps = deps;
|
|
17
|
+
this.interval = interval;
|
|
18
|
+
}
|
|
19
|
+
start() {
|
|
20
|
+
if (this.timer || this.busy)
|
|
21
|
+
return;
|
|
22
|
+
this.stopped = false;
|
|
23
|
+
const poll = async () => {
|
|
24
|
+
await this.tick();
|
|
25
|
+
if (!this.stopped) {
|
|
26
|
+
this.timer = setTimeout(poll, this.interval);
|
|
27
|
+
this.timer.unref?.();
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
this.timer = setTimeout(poll, 0);
|
|
31
|
+
this.timer.unref?.();
|
|
32
|
+
}
|
|
33
|
+
stop() {
|
|
34
|
+
this.stopped = true;
|
|
35
|
+
this.invalidate();
|
|
36
|
+
if (this.timer)
|
|
37
|
+
clearTimeout(this.timer);
|
|
38
|
+
this.timer = undefined;
|
|
39
|
+
}
|
|
40
|
+
/** A saved preference invalidates lookups already in flight, even if changed back quickly. */
|
|
41
|
+
invalidate() { this.generation++; this.abort?.abort(); this.pending.clear(); }
|
|
42
|
+
async tick() {
|
|
43
|
+
if (this.busy || this.stopped)
|
|
44
|
+
return;
|
|
45
|
+
this.busy = true;
|
|
46
|
+
const generation = this.generation;
|
|
47
|
+
const abort = new AbortController();
|
|
48
|
+
this.abort = abort;
|
|
49
|
+
const timeout = setTimeout(() => abort.abort(), 30_000);
|
|
50
|
+
timeout.unref?.();
|
|
51
|
+
const current = () => !this.stopped && generation === this.generation && !abort.signal.aborted;
|
|
52
|
+
try {
|
|
53
|
+
const projects = (await this.deps.projects()).filter(project => project.status !== 'missing');
|
|
54
|
+
const ids = new Set(projects.map(project => project.id));
|
|
55
|
+
for (const id of this.cursors.keys())
|
|
56
|
+
if (!ids.has(id)) {
|
|
57
|
+
this.cursors.delete(id);
|
|
58
|
+
this.failures.delete(id);
|
|
59
|
+
}
|
|
60
|
+
for (const [key, state] of this.pending)
|
|
61
|
+
if (!ids.has(state.projectId))
|
|
62
|
+
this.pending.delete(key);
|
|
63
|
+
if (!projects.length || !current())
|
|
64
|
+
return;
|
|
65
|
+
// Four projects per tick avoids a minute per unopened project. Each project remains bounded.
|
|
66
|
+
for (let i = 0; i < Math.min(4, projects.length) && current(); i++) {
|
|
67
|
+
const project = projects[this.projectCursor++ % projects.length];
|
|
68
|
+
await this.tickProject(project, abort.signal, current);
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
catch {
|
|
72
|
+
// A registry outage leaves tasks visible until the next bounded poll.
|
|
73
|
+
}
|
|
74
|
+
finally {
|
|
75
|
+
clearTimeout(timeout);
|
|
76
|
+
this.abort = undefined;
|
|
77
|
+
this.busy = false;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
async tickProject(project, signal, current) {
|
|
81
|
+
let roots = [];
|
|
82
|
+
try {
|
|
83
|
+
if ((this.failures.get(project.id)?.nextAt ?? 0) > Date.now() || !await this.deps.enabled(project) || !current())
|
|
84
|
+
return;
|
|
85
|
+
const repoBase = await this.deps.repository(project);
|
|
86
|
+
const snapshots = await this.deps.withStore(project, async (store, isActive, valid) => {
|
|
87
|
+
if (!current() || !valid())
|
|
88
|
+
return [];
|
|
89
|
+
const out = [];
|
|
90
|
+
// Finish admitted large sets before moving the page cursor. Revalidate even when
|
|
91
|
+
// a run stopped being a candidate so stale entries cannot hold capacity forever.
|
|
92
|
+
for (const [key, state] of this.pending) {
|
|
93
|
+
if (state.projectId !== project.id)
|
|
94
|
+
continue;
|
|
95
|
+
await store.prepareArchiveOnMerge(state.rootId);
|
|
96
|
+
if (!current() || !valid())
|
|
97
|
+
return [];
|
|
98
|
+
const snapshot = store.archiveOnMergeSnapshot(state.rootId, repoBase, isActive);
|
|
99
|
+
if (!snapshot)
|
|
100
|
+
this.pending.delete(key);
|
|
101
|
+
else
|
|
102
|
+
out.push(snapshot);
|
|
103
|
+
if (out.length === 4)
|
|
104
|
+
return out;
|
|
105
|
+
}
|
|
106
|
+
if (out.length)
|
|
107
|
+
return out;
|
|
108
|
+
const page = store.listArchiveOnMergeCandidates(this.cursors.get(project.id) ?? 0, 64);
|
|
109
|
+
this.cursors.set(project.id, page.length === 64 ? page.at(-1).seq : 0);
|
|
110
|
+
for (const candidate of page) {
|
|
111
|
+
if (!store.hasArchiveOnMergeAssociations(candidate.id))
|
|
112
|
+
continue;
|
|
113
|
+
await store.prepareArchiveOnMerge(candidate.id);
|
|
114
|
+
if (!current() || !valid())
|
|
115
|
+
break;
|
|
116
|
+
const snapshot = store.archiveOnMergeSnapshot(candidate.id, repoBase, isActive);
|
|
117
|
+
if (snapshot)
|
|
118
|
+
out.push(snapshot);
|
|
119
|
+
if (out.length === 4) {
|
|
120
|
+
this.cursors.set(project.id, candidate.seq);
|
|
121
|
+
break;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
return out;
|
|
125
|
+
});
|
|
126
|
+
if (!snapshots?.length || !current())
|
|
127
|
+
return;
|
|
128
|
+
roots = snapshots.map(snapshot => snapshot.rootId);
|
|
129
|
+
const requests = new Map();
|
|
130
|
+
for (const snapshot of snapshots) {
|
|
131
|
+
const key = `${project.id}:${snapshot.rootId}`;
|
|
132
|
+
let state = this.pending.get(key);
|
|
133
|
+
if (!state || state.token !== snapshot.token) {
|
|
134
|
+
if (!state && this.pending.size >= 32)
|
|
135
|
+
continue;
|
|
136
|
+
state = { projectId: project.id, rootId: snapshot.rootId, token: snapshot.token, offset: 0, merged: new Map() };
|
|
137
|
+
this.pending.set(key, state);
|
|
138
|
+
}
|
|
139
|
+
// Large merge sets progress across ticks; never truncate a set into archive authority.
|
|
140
|
+
for (const pr of snapshot.pullRequests.slice(state.offset, state.offset + 64))
|
|
141
|
+
requests.set(pullRequestKey(pr), pr);
|
|
142
|
+
}
|
|
143
|
+
if (!requests.size)
|
|
144
|
+
return;
|
|
145
|
+
const observed = await this.deps.lookup(project.root, [...requests.values()], signal);
|
|
146
|
+
if (!current())
|
|
147
|
+
return;
|
|
148
|
+
const observedByKey = new Map(observed.map(pr => [pullRequestKey(pr), pr]));
|
|
149
|
+
for (const snapshot of snapshots) {
|
|
150
|
+
const key = `${project.id}:${snapshot.rootId}`, state = this.pending.get(key);
|
|
151
|
+
if (!state)
|
|
152
|
+
continue;
|
|
153
|
+
for (const pr of snapshot.pullRequests.slice(state.offset, state.offset + 64)) {
|
|
154
|
+
const observation = observedByKey.get(pullRequestKey(pr));
|
|
155
|
+
if (observation)
|
|
156
|
+
state.merged.set(pullRequestKey(pr), observation);
|
|
157
|
+
}
|
|
158
|
+
state.offset += 64;
|
|
159
|
+
if (state.offset < snapshot.pullRequests.length)
|
|
160
|
+
continue;
|
|
161
|
+
state.offset = 0;
|
|
162
|
+
if (state.merged.size !== snapshot.pullRequests.length) {
|
|
163
|
+
const missing = snapshot.pullRequests.find(pr => !state.merged.has(pullRequestKey(pr)));
|
|
164
|
+
if (missing)
|
|
165
|
+
await this.deps.withStore(project, async (store, _active, valid) => {
|
|
166
|
+
if (current() && valid())
|
|
167
|
+
store.archiveMergeBlocker(snapshot, missing, repoBase);
|
|
168
|
+
});
|
|
169
|
+
this.pending.delete(key);
|
|
170
|
+
continue;
|
|
171
|
+
}
|
|
172
|
+
await this.deps.withStore(project, async (store, isActive, valid) => {
|
|
173
|
+
if (!await this.deps.enabled(project) || !current() || !valid())
|
|
174
|
+
return;
|
|
175
|
+
const registered = (await this.deps.projects()).some(p => p.id === project.id && p.root === project.root && p.status !== 'missing');
|
|
176
|
+
if (!registered || !current() || !valid())
|
|
177
|
+
return;
|
|
178
|
+
if (await this.deps.repository(project) !== repoBase || !current() || !valid())
|
|
179
|
+
return;
|
|
180
|
+
await store.prepareArchiveOnMerge(snapshot.rootId);
|
|
181
|
+
if (!current() || !valid())
|
|
182
|
+
return;
|
|
183
|
+
store.archiveAfterMerge(snapshot, [...state.merged.values()], repoBase, isActive);
|
|
184
|
+
});
|
|
185
|
+
this.pending.delete(key);
|
|
186
|
+
}
|
|
187
|
+
this.failures.delete(project.id);
|
|
188
|
+
}
|
|
189
|
+
catch {
|
|
190
|
+
if (current()) {
|
|
191
|
+
await this.deps.withStore(project, async (store, _active, valid) => {
|
|
192
|
+
if (current() && valid())
|
|
193
|
+
for (const id of roots)
|
|
194
|
+
store.setArchiveBlocker(id, { message: 'Could not confirm PR merge status. Check GitHub or archive manually.' });
|
|
195
|
+
}).catch(() => undefined);
|
|
196
|
+
const count = Math.min(5, (this.failures.get(project.id)?.count ?? 0) + 1);
|
|
197
|
+
this.failures.set(project.id, { count, nextAt: Date.now() + Math.min(900_000, this.interval * 2 ** (count - 1)) });
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
//# sourceMappingURL=archive-on-merge.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"archive-on-merge.js","sourceRoot":"","sources":["../../src/server/archive-on-merge.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAY1D,0FAA0F;AAC1F,MAAM,OAAO,yBAAyB;IAWP,IAAI;IAAuC,QAAQ;IAVxE,KAAK,CAA6C;IAClD,IAAI,GAAG,KAAK,CAAC;IACb,OAAO,GAAG,KAAK,CAAC;IAChB,UAAU,GAAG,CAAC,CAAC;IACf,KAAK,CAA+B;IACpC,aAAa,GAAG,CAAC,CAAC;IACT,OAAO,GAAG,IAAI,GAAG,EAAkB,CAAC;IACpC,OAAO,GAAG,IAAI,GAAG,EAA2B,CAAC;IAC7C,QAAQ,GAAG,IAAI,GAAG,EAA6C,CAAC;IAEjF,YAA6B,IAAwB,EAAmB,QAAQ,GAAG,MAAM;oBAA5D,IAAI;wBAAuC,QAAQ;IAAY,CAAC;IAE7F,KAAK;QACH,IAAI,IAAI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EAAE,OAAO,EAAE,sEAAsE,EAAE,CAAC,CAAC;gBACrK,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,CAAC;gBAC1B,MAAM,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,EAAE,KAAK,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;gBAC3E,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,OAAO,EAAE,IAAI,CAAC,QAAQ,GAAG,CAAC,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACrH,CAAC;QACH,CAAC;IACH,CAAC;CAEF"}
|
|
@@ -9,12 +9,6 @@
|
|
|
9
9
|
* hosted mode — the UI hides every local-machine affordance and the open-in-*
|
|
10
10
|
* endpoints 409.
|
|
11
11
|
*
|
|
12
|
-
* `followups` (spec 007, #444, #471): the global follow-up inbox is **opt-in**
|
|
13
|
-
* via `CEZ_FOLLOWUPS=1` and off by default. Off, agents are never told to write
|
|
14
|
-
* `todos.json` (they get `HANDOFF_ONLY_INSTRUCTIONS` and an empty
|
|
15
|
-
* `CEZ_TODOS_FILE`), the Inbox nav item is gone and the inbox endpoints refuse.
|
|
16
|
-
* The per-task handoff journal is independent and runs either way.
|
|
17
|
-
*
|
|
18
12
|
* `singleProject` (spec 2026-07-21-cez-single-project): the workspace is
|
|
19
13
|
* deliberately constrained to the launch project when `CEZ_SINGLE_PROJECT=1`.
|
|
20
14
|
* Like the other opt-in capabilities, activation is strict: no other spelling
|
|
@@ -25,7 +19,7 @@
|
|
|
25
19
|
* `Automations` nav item is gone everywhere it is rendered, the
|
|
26
20
|
* `/automations*` endpoints refuse, and the workspace scheduler never polls
|
|
27
21
|
* GitHub — the flag removes the behavior, not only the UI. Activation is
|
|
28
|
-
* strict, like the
|
|
22
|
+
* strict, like the capabilities above. Nothing on disk is touched:
|
|
29
23
|
* definitions, receipts and high-watermarks survive the flag being off, so
|
|
30
24
|
* unsetting it and restarting restores the feature wholesale.
|
|
31
25
|
*
|
|
@@ -55,17 +49,11 @@ export declare function isLoopbackHost(host: string | undefined): boolean;
|
|
|
55
49
|
* loopback" once the value arrives over the wire (#426). */
|
|
56
50
|
export declare function isLoopbackHostHeader(host: string | null | undefined): boolean;
|
|
57
51
|
/** `CEZ_REMOTE=1` or a non-loopback bind host ⇒ hosted mode (no local handoff).
|
|
58
|
-
* `CEZ_FOLLOWUPS=1` ⇒ the follow-up inbox exists (#471).
|
|
59
52
|
* `CEZ_AUTOMATIONS=1` ⇒ GitHub automations exist (#801).
|
|
60
53
|
* `CEZ_PREVIEW=1` ⇒ live preview exists (#781); same boot-time-flag caveat as `automations`.
|
|
54
|
+
* `CEZ_VOICE=1` plus `TYPESAFE_API_KEY` (or `CEZ_DRY_RUN=1`) ⇒ voice mode exists; same caveat.
|
|
61
55
|
*
|
|
62
|
-
* Read per request
|
|
63
|
-
* per request too, but flipping it ON at runtime is only half a switch: the per-dataDir
|
|
64
|
-
* todos watch (step 2.3) is created by an SSE subscription, so connections opened while the
|
|
65
|
-
* flag was off never subscribed and get no live inbox updates until they reconnect. Hence
|
|
66
|
-
* the UI's "set CEZ_FOLLOWUPS=1 and restart cezar" wording — treat it as a boot-time flag.
|
|
67
|
-
*
|
|
68
|
-
* `automations` carries the same caveat and for the same reason: the workspace scheduler is
|
|
56
|
+
* Read per request. The automations flag is a boot-time setting: the workspace scheduler is
|
|
69
57
|
* started once, on the server's `listening` event, so flipping the flag on afterwards gates
|
|
70
58
|
* the routes open without ever starting the poller. Boot-time flag, same wording. */
|
|
71
59
|
export declare function resolveCapabilities(env?: NodeJS.ProcessEnv, bindHost?: string): Capabilities;
|
|
@@ -9,12 +9,6 @@
|
|
|
9
9
|
* hosted mode — the UI hides every local-machine affordance and the open-in-*
|
|
10
10
|
* endpoints 409.
|
|
11
11
|
*
|
|
12
|
-
* `followups` (spec 007, #444, #471): the global follow-up inbox is **opt-in**
|
|
13
|
-
* via `CEZ_FOLLOWUPS=1` and off by default. Off, agents are never told to write
|
|
14
|
-
* `todos.json` (they get `HANDOFF_ONLY_INSTRUCTIONS` and an empty
|
|
15
|
-
* `CEZ_TODOS_FILE`), the Inbox nav item is gone and the inbox endpoints refuse.
|
|
16
|
-
* The per-task handoff journal is independent and runs either way.
|
|
17
|
-
*
|
|
18
12
|
* `singleProject` (spec 2026-07-21-cez-single-project): the workspace is
|
|
19
13
|
* deliberately constrained to the launch project when `CEZ_SINGLE_PROJECT=1`.
|
|
20
14
|
* Like the other opt-in capabilities, activation is strict: no other spelling
|
|
@@ -25,7 +19,7 @@
|
|
|
25
19
|
* `Automations` nav item is gone everywhere it is rendered, the
|
|
26
20
|
* `/automations*` endpoints refuse, and the workspace scheduler never polls
|
|
27
21
|
* GitHub — the flag removes the behavior, not only the UI. Activation is
|
|
28
|
-
* strict, like the
|
|
22
|
+
* strict, like the capabilities above. Nothing on disk is touched:
|
|
29
23
|
* definitions, receipts and high-watermarks survive the flag being off, so
|
|
30
24
|
* unsetting it and restarting restores the feature wholesale.
|
|
31
25
|
*
|
|
@@ -34,7 +28,6 @@
|
|
|
34
28
|
* legacy `CEZ_HIDE_TOKEN_METRICS=1` remains the master hide-all switch. None
|
|
35
29
|
* changes collection, persistence, events, or API run records.
|
|
36
30
|
*/
|
|
37
|
-
import { followupsEnabled } from '../handoff.js';
|
|
38
31
|
/** Every IPv4 address in 127.0.0.0/8, anchored. Anchoring is load-bearing: a
|
|
39
32
|
* `startsWith('127.')` test also matches attacker-controlled *hostnames* like
|
|
40
33
|
* `127.0.0.1.evil.com`, which is exactly the DNS-rebinding bypass #426 is
|
|
@@ -121,17 +114,11 @@ export function isLoopbackHostHeader(host) {
|
|
|
121
114
|
return isLoopbackName(normalizeHostname(host));
|
|
122
115
|
}
|
|
123
116
|
/** `CEZ_REMOTE=1` or a non-loopback bind host ⇒ hosted mode (no local handoff).
|
|
124
|
-
* `CEZ_FOLLOWUPS=1` ⇒ the follow-up inbox exists (#471).
|
|
125
117
|
* `CEZ_AUTOMATIONS=1` ⇒ GitHub automations exist (#801).
|
|
126
118
|
* `CEZ_PREVIEW=1` ⇒ live preview exists (#781); same boot-time-flag caveat as `automations`.
|
|
119
|
+
* `CEZ_VOICE=1` plus `TYPESAFE_API_KEY` (or `CEZ_DRY_RUN=1`) ⇒ voice mode exists; same caveat.
|
|
127
120
|
*
|
|
128
|
-
* Read per request
|
|
129
|
-
* per request too, but flipping it ON at runtime is only half a switch: the per-dataDir
|
|
130
|
-
* todos watch (step 2.3) is created by an SSE subscription, so connections opened while the
|
|
131
|
-
* flag was off never subscribed and get no live inbox updates until they reconnect. Hence
|
|
132
|
-
* the UI's "set CEZ_FOLLOWUPS=1 and restart cezar" wording — treat it as a boot-time flag.
|
|
133
|
-
*
|
|
134
|
-
* `automations` carries the same caveat and for the same reason: the workspace scheduler is
|
|
121
|
+
* Read per request. The automations flag is a boot-time setting: the workspace scheduler is
|
|
135
122
|
* started once, on the server's `listening` event, so flipping the flag on afterwards gates
|
|
136
123
|
* the routes open without ever starting the poller. Boot-time flag, same wording. */
|
|
137
124
|
export function resolveCapabilities(env = process.env, bindHost) {
|
|
@@ -140,12 +127,12 @@ export function resolveCapabilities(env = process.env, bindHost) {
|
|
|
140
127
|
const costMetrics = !hideAllUsage && env.CEZ_HIDE_COST !== '1';
|
|
141
128
|
return {
|
|
142
129
|
localHandoff: env.CEZ_REMOTE !== '1' && isLoopbackHost(bindHost),
|
|
143
|
-
// Deliberately not re-derived here: RunManager enforces the same predicate,
|
|
144
|
-
// and two spellings of "is the inbox on" would eventually disagree.
|
|
145
|
-
followups: followupsEnabled(env),
|
|
146
130
|
singleProject: env.CEZ_SINGLE_PROJECT === '1',
|
|
147
131
|
automations: env.CEZ_AUTOMATIONS === '1',
|
|
148
132
|
preview: env.CEZ_PREVIEW === '1',
|
|
133
|
+
// Boot-time flag, like `automations`. The key is read here only as present or absent; the
|
|
134
|
+
// fake engine under CEZ_DRY_RUN needs none.
|
|
135
|
+
voice: env.CEZ_VOICE === '1' && (!!env.TYPESAFE_API_KEY || env.CEZ_DRY_RUN === '1'),
|
|
149
136
|
tokenMetrics: tokenUsageMetrics && costMetrics,
|
|
150
137
|
tokenUsageMetrics,
|
|
151
138
|
costMetrics,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capabilities.js","sourceRoot":"","sources":["../../src/server/capabilities.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"capabilities.js","sourceRoot":"","sources":["../../src/server/capabilities.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAIH;;;0CAG0C;AAC1C,MAAM,WAAW,GAAG,4CAA4C,CAAC;AAEjE,kEAAkE;AAClE,MAAM,WAAW,GAAG,iBAAiB,CAAC;AAEtC;;;;;;YAMY;AACZ,SAAS,UAAU,CAAC,CAAS;IAC3B,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC7B,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC;QAAE,OAAO,IAAI,CAAC;IACnC,IAAI,MAAgB,CAAC;IACrB,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACxB,MAAM,IAAI,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;QACnD,MAAM,IAAI,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC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ACL,YAAY,EAAE,GAAG,CAAC,UAAU,KAAK,GAAG,IAAI,cAAc,CAAC,QAAQ,CAAC;QAChE,aAAa,EAAE,GAAG,CAAC,kBAAkB,KAAK,GAAG;QAC7C,WAAW,EAAE,GAAG,CAAC,eAAe,KAAK,GAAG;QACxC,OAAO,EAAE,GAAG,CAAC,WAAW,KAAK,GAAG;QAChC,0FAA0F;QAC1F,4CAA4C;QAC5C,KAAK,EAAE,GAAG,CAAC,SAAS,KAAK,GAAG,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,gBAAgB,IAAI,GAAG,CAAC,WAAW,KAAK,GAAG,CAAC;QACnF,YAAY,EAAE,iBAAiB,IAAI,WAAW;QAC9C,iBAAiB;QACjB,WAAW;KACZ,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { CheckoutProgressEvent } from '../contract/index.js';
|
|
2
|
+
/** Recovery cache for the clone and new-project dialogs, never an authority for the mutation's result. */
|
|
3
|
+
export declare class CheckoutProgressCache {
|
|
4
|
+
private readonly now;
|
|
5
|
+
private readonly values;
|
|
6
|
+
constructor(now?: () => number);
|
|
7
|
+
private prune;
|
|
8
|
+
record(progress: CheckoutProgressEvent): void;
|
|
9
|
+
get(id: string): CheckoutProgressEvent | null;
|
|
10
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/** Recovery cache for the clone and new-project dialogs, never an authority for the mutation's result. */
|
|
2
|
+
export class CheckoutProgressCache {
|
|
3
|
+
now;
|
|
4
|
+
values = new Map();
|
|
5
|
+
constructor(now = Date.now) {
|
|
6
|
+
this.now = now;
|
|
7
|
+
}
|
|
8
|
+
prune() {
|
|
9
|
+
for (const [key, value] of this.values)
|
|
10
|
+
if (this.now() - value.at >= 5 * 60_000)
|
|
11
|
+
this.values.delete(key);
|
|
12
|
+
}
|
|
13
|
+
record(progress) {
|
|
14
|
+
if (!progress.checkoutId)
|
|
15
|
+
return;
|
|
16
|
+
this.prune();
|
|
17
|
+
this.values.delete(progress.checkoutId);
|
|
18
|
+
this.values.set(progress.checkoutId, { at: this.now(), progress: { ...progress, ...(progress.line ? { line: progress.line.slice(-4096) } : {}), ...(progress.error ? { error: progress.error.slice(-4096) } : {}), ...(progress.warning ? { warning: progress.warning.slice(0, 4096) } : {}) } });
|
|
19
|
+
while (this.values.size > 128)
|
|
20
|
+
this.values.delete(this.values.keys().next().value);
|
|
21
|
+
}
|
|
22
|
+
get(id) {
|
|
23
|
+
this.prune();
|
|
24
|
+
return this.values.get(id)?.progress ?? null;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=checkout-progress.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkout-progress.js","sourceRoot":"","sources":["../../src/server/checkout-progress.ts"],"names":[],"mappings":"AAEA,0GAA0G;AAC1G,MAAM,OAAO,qBAAqB;IAEH,GAAG;IADf,MAAM,GAAG,IAAI,GAAG,EAA2D,CAAC;IAC7F,YAA6B,GAAG,GAAG,IAAI,CAAC,GAAG;mBAAd,GAAG;IAAc,CAAC;IACvC,KAAK;QACX,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,IAAI,CAAC,MAAM;YAAE,IAAI,IAAI,CAAC,GAAG,EAAE,GAAG,KAAK,CAAC,EAAE,IAAI,CAAC,GAAG,MAAM;gBAAE,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAC3G,CAAC;IACD,MAAM,CAAC,QAA+B;QACpC,IAAI,CAAC,QAAQ,CAAC,UAAU;YAAE,OAAO;QACjC,IAAI,CAAC,KAAK,EAAE,CAAC;QACb,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC,UAAU,EAAE,EAAE,EAAE,EAAE,IAAI,CAAC,GAAG,EAAE,EAAE,QAAQ,EAAE,EAAE,GAAG,QAAQ,EAAE,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;QAClS,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,GAAG,GAAG;YAAE,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,IAAI,EAAE,CAAC,KAAM,CAAC,CAAC;IACtF,CAAC;IACD,GAAG,CAAC,EAAU;QACZ,IAAI,CAAC,KAAK,EAAE,CAAC;QACb,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,QAAQ,IAAI,IAAI,CAAC;IAC/C,CAAC;CACF"}
|
|
@@ -10,6 +10,8 @@ export interface CheckoutProgressEvent {
|
|
|
10
10
|
line?: string;
|
|
11
11
|
/** Human-readable failure (present on `error`). */
|
|
12
12
|
error?: string;
|
|
13
|
+
/** New-project flow only: on `done`, what did not finish (see `create-project.ts`). */
|
|
14
|
+
warning?: string;
|
|
13
15
|
}
|
|
14
16
|
export type CheckoutFailure = {
|
|
15
17
|
ok: false;
|
|
@@ -68,24 +70,9 @@ export declare function parseRepoRef(input: string): RepoRef | null;
|
|
|
68
70
|
*/
|
|
69
71
|
export declare function isValidCheckoutName(name: string): boolean;
|
|
70
72
|
/**
|
|
71
|
-
*
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
* because the directory did not exist and WE created it). Even with that proof
|
|
75
|
-
* in hand, every one of these must hold or nothing is deleted:
|
|
76
|
-
*
|
|
77
|
-
* - `target` is still a real directory and NOT a symlink (`lstat`, not `stat`):
|
|
78
|
-
* between the mkdir and the failure, the directory could have been swapped
|
|
79
|
-
* for a link pointing anywhere.
|
|
80
|
-
* - `projectsDir` and `target` both resolve (`realpath`), and the resolved
|
|
81
|
-
* target's PARENT is exactly the resolved checkout root. That is strict
|
|
82
|
-
* containment (nothing outside the root) *and* a depth limit (a direct child
|
|
83
|
-
* only, never the root itself, never a nested path).
|
|
84
|
-
*
|
|
85
|
-
* Any surprise — a vanished path, an unresolvable root, a `rm` that fails —
|
|
86
|
-
* leaves the directory alone. Leaving a stray folder is a nuisance; deleting
|
|
87
|
-
* the wrong one is unrecoverable, so every ambiguous case resolves toward "do
|
|
88
|
-
* nothing".
|
|
73
|
+
* Remove only an attempt-owned real directory whose canonical parent is the checkout root.
|
|
74
|
+
* Refuse symlinks, the root itself and uncertain paths. Return false on any check or removal
|
|
75
|
+
* failure.
|
|
89
76
|
*/
|
|
90
77
|
export declare function cleanupCheckout(projectsDir: string, target: string): Promise<boolean>;
|
|
91
78
|
/** Injected so the tests can drive a fake clone without a network or a `gh`
|
|
@@ -100,6 +87,10 @@ export type CloneRunner = (ref: RepoRef, dir: string, onLine: (line: string) =>
|
|
|
100
87
|
/** Kept pure so the SAML-safe transport choice is pinned without spawning a
|
|
101
88
|
* real GitHub process in the unit suite. */
|
|
102
89
|
export declare function ghCloneArgs(ref: RepoRef, dir: string): string[];
|
|
90
|
+
/** PR #968: the `git config --local` argument lists that route github.com HTTPS
|
|
91
|
+
* credentials through `gh`. Reset inherited helpers first, as gh setup-git does.
|
|
92
|
+
* Shared with the new-project flow (`create-project.ts`). */
|
|
93
|
+
export declare const GH_CREDENTIAL_HELPER_CONFIG: readonly (readonly string[])[];
|
|
103
94
|
/**
|
|
104
95
|
* `gh repo clone <validated HTTPS URL> <dir> -- --progress`.
|
|
105
96
|
*
|
|
@@ -125,7 +116,7 @@ export interface CheckoutOptions {
|
|
|
125
116
|
checkoutId?: string | undefined;
|
|
126
117
|
signal?: AbortSignal | undefined;
|
|
127
118
|
/** Test seam; defaults to `gh` (or the dry-run fake under `CEZ_DRY_RUN=1`). */
|
|
128
|
-
run?: CloneRunner;
|
|
119
|
+
run?: CloneRunner | undefined;
|
|
129
120
|
}
|
|
130
121
|
/**
|
|
131
122
|
* Clone a GitHub repo into `<projectsDir>/<name>`, streaming progress.
|
package/dist/server/checkout.js
CHANGED
|
@@ -2,28 +2,9 @@ import { execFile, spawn } from 'node:child_process';
|
|
|
2
2
|
import { lstat, mkdir, realpath, rm, writeFile } from 'node:fs/promises';
|
|
3
3
|
import { dirname, join, resolve } from 'node:path';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* The route itself (server.ts) owns the registry write; this module owns the
|
|
9
|
-
* only two things that are genuinely dangerous about cloning on the operator's
|
|
10
|
-
* behalf:
|
|
11
|
-
*
|
|
12
|
-
* 1. **Where the clone lands.** The target is always `<projectsDir>/<name>`
|
|
13
|
-
* with `name` a single, boring path segment. It is never a nested path,
|
|
14
|
-
* never `..`, never absolute — the checkout root is a root, not a starting
|
|
15
|
-
* point for traversal.
|
|
16
|
-
* 2. **What cleanup may delete.** A failed clone must not leave a half-written
|
|
17
|
-
* directory behind (a later attempt would trip over it, and registering it
|
|
18
|
-
* would put a broken project in the sidebar). But "rm -rf the target" is a
|
|
19
|
-
* destructive path reached by a *network failure*, so it is guarded as
|
|
20
|
-
* tightly as `fs-browse.ts` guards containment — see `cleanupCheckout`.
|
|
21
|
-
*
|
|
22
|
-
* The load-bearing trick for (2) is that the target directory is created HERE,
|
|
23
|
-
* with a non-recursive `mkdir`, before `gh` ever runs. That single syscall is
|
|
24
|
-
* both the atomic existence check (EEXIST ⇒ 409, and we never touched what was
|
|
25
|
-
* there) and the proof of ownership that authorizes cleanup: we only ever
|
|
26
|
-
* delete a directory this operation is known to have created.
|
|
5
|
+
* Clone into one validated direct child of projectsDir. Reserve the directory with non-recursive
|
|
6
|
+
* mkdir before cloning; only guarded cleanup may remove a failed attempt. The route owns
|
|
7
|
+
* registration.
|
|
27
8
|
*/
|
|
28
9
|
/** How long a clone may run before it is killed. Long enough for a large repo
|
|
29
10
|
* on a slow link, short enough that a hung `gh` (an auth prompt that will
|
|
@@ -93,24 +74,9 @@ export function isValidCheckoutName(name) {
|
|
|
93
74
|
return name.length <= 128 && NAME_SEGMENT.test(name) && !name.includes('/') && !name.includes('\\');
|
|
94
75
|
}
|
|
95
76
|
/**
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
* because the directory did not exist and WE created it). Even with that proof
|
|
100
|
-
* in hand, every one of these must hold or nothing is deleted:
|
|
101
|
-
*
|
|
102
|
-
* - `target` is still a real directory and NOT a symlink (`lstat`, not `stat`):
|
|
103
|
-
* between the mkdir and the failure, the directory could have been swapped
|
|
104
|
-
* for a link pointing anywhere.
|
|
105
|
-
* - `projectsDir` and `target` both resolve (`realpath`), and the resolved
|
|
106
|
-
* target's PARENT is exactly the resolved checkout root. That is strict
|
|
107
|
-
* containment (nothing outside the root) *and* a depth limit (a direct child
|
|
108
|
-
* only, never the root itself, never a nested path).
|
|
109
|
-
*
|
|
110
|
-
* Any surprise — a vanished path, an unresolvable root, a `rm` that fails —
|
|
111
|
-
* leaves the directory alone. Leaving a stray folder is a nuisance; deleting
|
|
112
|
-
* the wrong one is unrecoverable, so every ambiguous case resolves toward "do
|
|
113
|
-
* nothing".
|
|
77
|
+
* Remove only an attempt-owned real directory whose canonical parent is the checkout root.
|
|
78
|
+
* Refuse symlinks, the root itself and uncertain paths. Return false on any check or removal
|
|
79
|
+
* failure.
|
|
114
80
|
*/
|
|
115
81
|
export async function cleanupCheckout(projectsDir, target) {
|
|
116
82
|
let realRoot;
|
|
@@ -147,14 +113,18 @@ export function ghCloneArgs(ref, dir) {
|
|
|
147
113
|
return ['repo', 'clone', ref.cloneUrl, dir, '--', '--progress',
|
|
148
114
|
'--config', 'url.https://github.com/.insteadOf=git@github.com:'];
|
|
149
115
|
}
|
|
116
|
+
/** PR #968: the `git config --local` argument lists that route github.com HTTPS
|
|
117
|
+
* credentials through `gh`. Reset inherited helpers first, as gh setup-git does.
|
|
118
|
+
* Shared with the new-project flow (`create-project.ts`). */
|
|
119
|
+
export const GH_CREDENTIAL_HELPER_CONFIG = [
|
|
120
|
+
['--replace-all', 'credential.https://github.com.helper', ''],
|
|
121
|
+
['--add', 'credential.https://github.com.helper', '!gh auth git-credential'],
|
|
122
|
+
];
|
|
150
123
|
/** PR #968: gh injects credentials only for the clone command. Persist the
|
|
151
124
|
* helper locally so subsequent raw git pushes (including task worktrees) use
|
|
152
|
-
* the same OAuth grant.
|
|
125
|
+
* the same OAuth grant. */
|
|
153
126
|
async function persistGhCredentialHelper(dir) {
|
|
154
|
-
for (const args of
|
|
155
|
-
['--replace-all', 'credential.https://github.com.helper', ''],
|
|
156
|
-
['--add', 'credential.https://github.com.helper', '!gh auth git-credential'],
|
|
157
|
-
]) {
|
|
127
|
+
for (const args of GH_CREDENTIAL_HELPER_CONFIG) {
|
|
158
128
|
const ok = await new Promise((resolvePromise) => {
|
|
159
129
|
execFile('git', ['-C', dir, 'config', '--local', ...args], { timeout: 10_000 }, (err) => resolvePromise(!err));
|
|
160
130
|
});
|