@songsid/agend 2.3.0-beta.9 → 2.3.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/README.md +16 -8
- package/README.zh-TW.md +16 -8
- package/dist/adapter-world.js.map +1 -1
- package/dist/agend-home.d.ts +5 -0
- package/dist/agend-home.js +7 -0
- package/dist/agend-home.js.map +1 -0
- package/dist/agent-cli-instructions.md +7 -1
- package/dist/agent-cli.js +41 -0
- package/dist/agent-cli.js.map +1 -1
- package/dist/agent-endpoint.d.ts +9 -0
- package/dist/agent-endpoint.js +23 -0
- package/dist/agent-endpoint.js.map +1 -1
- package/dist/agent-file-read.js +1 -1
- package/dist/agent-file-read.js.map +1 -1
- package/dist/agent-whats-new.d.ts +16 -0
- package/dist/agent-whats-new.js +53 -12
- package/dist/agent-whats-new.js.map +1 -1
- package/dist/apply-job.js.map +1 -1
- package/dist/atomic-write.js.map +1 -1
- package/dist/auth-api.d.ts +12 -0
- package/dist/auth-api.js +77 -22
- package/dist/auth-api.js.map +1 -1
- package/dist/authority/authority-state.d.ts +4 -0
- package/dist/authority/authority-state.js +17 -8
- package/dist/authority/authority-state.js.map +1 -1
- package/dist/authority/session-authorizations.js.map +1 -1
- package/dist/authority/web-authority.d.ts +16 -8
- package/dist/authority/web-authority.js +19 -5
- package/dist/authority/web-authority.js.map +1 -1
- package/dist/backend/antigravity.d.ts +2 -2
- package/dist/backend/antigravity.js +2 -1
- package/dist/backend/antigravity.js.map +1 -1
- package/dist/backend/claude-code.js +13 -4
- package/dist/backend/claude-code.js.map +1 -1
- package/dist/backend/codex-metadata.d.ts +8 -0
- package/dist/backend/codex-metadata.js +74 -17
- package/dist/backend/codex-metadata.js.map +1 -1
- package/dist/backend/codex-package.d.ts +30 -0
- package/dist/backend/codex-package.js +133 -0
- package/dist/backend/codex-package.js.map +1 -0
- package/dist/backend/codex-session-lookup.js.map +1 -1
- package/dist/backend/codex.d.ts +2 -0
- package/dist/backend/codex.js +25 -5
- package/dist/backend/codex.js.map +1 -1
- package/dist/backend/credential-profile.d.ts +2 -0
- package/dist/backend/credential-profile.js +2 -0
- package/dist/backend/credential-profile.js.map +1 -1
- package/dist/backend/effort-metadata.js.map +1 -1
- package/dist/backend/grok.js +58 -3
- package/dist/backend/grok.js.map +1 -1
- package/dist/backend/kiro-engine-ledger.js.map +1 -1
- package/dist/backend/kiro-kas-store.js.map +1 -1
- package/dist/backend/kiro-v2-store.js.map +1 -1
- package/dist/backend/kiro-v3-identity.js.map +1 -1
- package/dist/backend/kiro.d.ts +9 -1
- package/dist/backend/kiro.js +102 -1
- package/dist/backend/kiro.js.map +1 -1
- package/dist/backend/launch-effort.js.map +1 -1
- package/dist/backend/mock.js.map +1 -1
- package/dist/backend/muse.js.map +1 -1
- package/dist/backend/opencode-permission.js +1 -1
- package/dist/backend/opencode-permission.js.map +1 -1
- package/dist/backend/opencode.js +2 -1
- package/dist/backend/opencode.js.map +1 -1
- package/dist/backend/session-signals.js.map +1 -1
- package/dist/backend-availability.js.map +1 -1
- package/dist/backend-command.d.ts +2 -0
- package/dist/backend-command.js +3 -1
- package/dist/backend-command.js.map +1 -1
- package/dist/backend-outage.js.map +1 -1
- package/dist/binary-probe.js +1 -1
- package/dist/binary-probe.js.map +1 -1
- package/dist/bug-report-cli.d.ts +30 -0
- package/dist/bug-report-cli.js +139 -0
- package/dist/bug-report-cli.js.map +1 -0
- package/dist/bug-report.d.ts +47 -0
- package/dist/bug-report.js +137 -0
- package/dist/bug-report.js.map +1 -0
- package/dist/bundled-skills.d.ts +18 -0
- package/dist/bundled-skills.js +38 -0
- package/dist/bundled-skills.js.map +1 -0
- package/dist/cache-service.js +1 -1
- package/dist/cache-service.js.map +1 -1
- package/dist/channel/adapters/discord-client-retirement.d.ts +5 -0
- package/dist/channel/adapters/discord-client-retirement.js +57 -0
- package/dist/channel/adapters/discord-client-retirement.js.map +1 -0
- package/dist/channel/adapters/discord.d.ts +4 -0
- package/dist/channel/adapters/discord.js +57 -12
- package/dist/channel/adapters/discord.js.map +1 -1
- package/dist/channel/adapters/telegram.d.ts +6 -0
- package/dist/channel/adapters/telegram.js +54 -14
- package/dist/channel/adapters/telegram.js.map +1 -1
- package/dist/channel/mcp-server.js +21 -4
- package/dist/channel/mcp-server.js.map +1 -1
- package/dist/channel/mcp-tools.d.ts +3 -1
- package/dist/channel/mcp-tools.js +41 -4
- package/dist/channel/mcp-tools.js.map +1 -1
- package/dist/channel/message-queue.js.map +1 -1
- package/dist/channel/sticker-download.js.map +1 -1
- package/dist/channel/tool-router.js.map +1 -1
- package/dist/child-process.d.ts +21 -0
- package/dist/child-process.js +54 -0
- package/dist/child-process.js.map +1 -0
- package/dist/classic-channel-manager.js +3 -2
- package/dist/classic-channel-manager.js.map +1 -1
- package/dist/cli-entry.js.map +1 -1
- package/dist/cli-flags.js.map +1 -1
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +443 -311
- package/dist/cli.js.map +1 -1
- package/dist/command-table.d.ts +1 -1
- package/dist/command-table.js +1 -1
- package/dist/command-table.js.map +1 -1
- package/dist/compact-watch.js.map +1 -1
- package/dist/completion-install.js.map +1 -1
- package/dist/completion.js.map +1 -1
- package/dist/config-validator.d.ts +6 -0
- package/dist/config-validator.js +81 -8
- package/dist/config-validator.js.map +1 -1
- package/dist/config.d.ts +15 -3
- package/dist/config.js +41 -10
- package/dist/config.js.map +1 -1
- package/dist/connection-secrets.js.map +1 -1
- package/dist/context-guardian.js.map +1 -1
- package/dist/coredump-filter.js.map +1 -1
- package/dist/cpu-profile.js.map +1 -1
- package/dist/cross-instance-envelope.js.map +1 -1
- package/dist/cross-instance-notice.d.ts +7 -0
- package/dist/cross-instance-notice.js +10 -0
- package/dist/cross-instance-notice.js.map +1 -1
- package/dist/daemon.d.ts +39 -1
- package/dist/daemon.js +234 -15
- package/dist/daemon.js.map +1 -1
- package/dist/daily-summary.js.map +1 -1
- package/dist/darwin-memory.js +1 -1
- package/dist/darwin-memory.js.map +1 -1
- package/dist/dashboard-live.d.ts +8 -0
- package/dist/dashboard-live.js +35 -0
- package/dist/dashboard-live.js.map +1 -0
- package/dist/dashboard-permissions.d.ts +69 -0
- package/dist/dashboard-permissions.js +138 -0
- package/dist/dashboard-permissions.js.map +1 -0
- package/dist/decision-list.js.map +1 -1
- package/dist/delivery-consumed-watch.js.map +1 -1
- package/dist/delivery-outbox.js +5 -0
- package/dist/delivery-outbox.js.map +1 -1
- package/dist/delivery-outbox.test.js.map +1 -1
- package/dist/delivery-reconciliation.test.js.map +1 -1
- package/dist/diagnostic-redaction.d.ts +10 -0
- package/dist/diagnostic-redaction.js +167 -0
- package/dist/diagnostic-redaction.js.map +1 -0
- package/dist/doctor.d.ts +8 -0
- package/dist/doctor.js +52 -0
- package/dist/doctor.js.map +1 -1
- package/dist/e2e-isolation.js.map +1 -1
- package/dist/event-log.js.map +1 -1
- package/dist/export-import.js +7 -5
- package/dist/export-import.js.map +1 -1
- package/dist/fleet-control-audit.js.map +1 -1
- package/dist/fleet-label.js.map +1 -1
- package/dist/fleet-level-config.d.ts +1 -1
- package/dist/fleet-level-config.js +2 -0
- package/dist/fleet-level-config.js.map +1 -1
- package/dist/fleet-lock.js +3 -2
- package/dist/fleet-lock.js.map +1 -1
- package/dist/fleet-manager.d.ts +249 -13
- package/dist/fleet-manager.js +1561 -292
- package/dist/fleet-manager.js.map +1 -1
- package/dist/fleet-process-handlers.d.ts +18 -0
- package/dist/fleet-process-handlers.js +70 -0
- package/dist/fleet-process-handlers.js.map +1 -0
- package/dist/fleet-startup.d.ts +14 -0
- package/dist/fleet-startup.js +30 -0
- package/dist/fleet-startup.js.map +1 -0
- package/dist/fleet-traffic.js.map +1 -1
- package/dist/forged-envelope-scan.d.ts +0 -20
- package/dist/forged-envelope-scan.js +3 -2
- package/dist/forged-envelope-scan.js.map +1 -1
- package/dist/full-restart.d.ts +5 -5
- package/dist/full-restart.js +5 -5
- package/dist/full-restart.js.map +1 -1
- package/dist/general-knowledge/skills/bug-report/SKILL.md +31 -0
- package/dist/general-knowledge/skills/credential-profiles/SKILL.md +52 -11
- package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +5 -1
- package/dist/general-knowledge/skills/fleet-config/SKILL.md +3 -1
- package/dist/general-knowledge/skills/fleet-restart/SKILL.md +8 -9
- package/dist/general-knowledge/skills/multi-channel/SKILL.md +1 -1
- package/dist/general-knowledge/skills/persona-emoji/SKILL.md +1 -1
- package/dist/general-knowledge/skills/scheduling/SKILL.md +4 -0
- package/dist/general-knowledge/skills/web-appearance/SKILL.canvas-worker-off.md +321 -0
- package/dist/general-knowledge/skills/web-appearance/SKILL.md +24 -4
- package/dist/general-knowledge/skills/web-dashboard/SKILL.canvas-worker-off.md +553 -0
- package/dist/general-knowledge/skills/web-dashboard/SKILL.md +154 -31
- package/dist/general-knowledge/skills/worker-collaboration/SKILL.md +1 -1
- package/dist/general-knowledge/steering/core-rules.md +1 -1
- package/dist/host-memory.js.map +1 -1
- package/dist/idle-gate-log.d.ts +19 -0
- package/dist/idle-gate-log.js +15 -0
- package/dist/idle-gate-log.js.map +1 -0
- package/dist/instance-config-impact.js +25 -4
- package/dist/instance-config-impact.js.map +1 -1
- package/dist/instance-lifecycle.d.ts +10 -1
- package/dist/instance-lifecycle.js +86 -25
- package/dist/instance-lifecycle.js.map +1 -1
- package/dist/instructions.d.ts +12 -6
- package/dist/instructions.js +19 -10
- package/dist/instructions.js.map +1 -1
- package/dist/kiro-compact-pane.js.map +1 -1
- package/dist/kiro-db-reader.js.map +1 -1
- package/dist/kiro-engine-status.js.map +1 -1
- package/dist/kiro-log-gate.js.map +1 -1
- package/dist/kiro-transcript-lane.js.map +1 -1
- package/dist/locale.js +428 -20
- package/dist/locale.js.map +1 -1
- package/dist/log-service.js.map +1 -1
- package/dist/log-steps.d.ts +1 -0
- package/dist/log-steps.js +15 -0
- package/dist/log-steps.js.map +1 -1
- package/dist/logger.js +3 -2
- package/dist/logger.js.map +1 -1
- package/dist/login-controller.d.ts +45 -0
- package/dist/login-controller.js +101 -5
- package/dist/login-controller.js.map +1 -1
- package/dist/login-flows.js +1 -1
- package/dist/login-manager.js.map +1 -1
- package/dist/login-shell.js +3 -1
- package/dist/login-shell.js.map +1 -1
- package/dist/ls-attach-resolve.d.ts +96 -0
- package/dist/ls-attach-resolve.js +180 -0
- package/dist/ls-attach-resolve.js.map +1 -0
- package/dist/ls-rows.d.ts +12 -0
- package/dist/ls-rows.js +83 -4
- package/dist/ls-rows.js.map +1 -1
- package/dist/memory-pressure.js.map +1 -1
- package/dist/muse-usage-relay.js.map +1 -1
- package/dist/needs-you-hub.d.ts +98 -1
- package/dist/needs-you-hub.js +313 -44
- package/dist/needs-you-hub.js.map +1 -1
- package/dist/needs-you-live.d.ts +5 -2
- package/dist/needs-you-live.js +6 -3
- package/dist/needs-you-live.js.map +1 -1
- package/dist/needs-you.d.ts +68 -3
- package/dist/needs-you.js +38 -4
- package/dist/needs-you.js.map +1 -1
- package/dist/network-family.js.map +1 -1
- package/dist/operator-control-paths.js +3 -4
- package/dist/operator-control-paths.js.map +1 -1
- package/dist/outbound-handlers.d.ts +3 -0
- package/dist/outbound-handlers.js +76 -19
- package/dist/outbound-handlers.js.map +1 -1
- package/dist/outbound-schemas.d.ts +106 -60
- package/dist/outbound-schemas.js +33 -10
- package/dist/outbound-schemas.js.map +1 -1
- package/dist/outbox-open-error.js.map +1 -1
- package/dist/pane-context-cache.js.map +1 -1
- package/dist/paths.js.map +1 -1
- package/dist/private-dir.js.map +1 -1
- package/dist/probe-worker-pool.js.map +1 -1
- package/dist/profile-control.js.map +1 -1
- package/dist/prompt-file-ref.js.map +1 -1
- package/dist/provider-probe.js.map +1 -1
- package/dist/provider-secret-registry.d.ts +5 -3
- package/dist/provider-secret-registry.js +8 -2
- package/dist/provider-secret-registry.js.map +1 -1
- package/dist/public-link-auto-open.d.ts +32 -0
- package/dist/public-link-auto-open.js +86 -0
- package/dist/public-link-auto-open.js.map +1 -0
- package/dist/public-link-owner.d.ts +10 -0
- package/dist/public-link-owner.js +36 -0
- package/dist/public-link-owner.js.map +1 -0
- package/dist/public-link-progress.d.ts +12 -1
- package/dist/public-link-progress.js +5 -10
- package/dist/public-link-progress.js.map +1 -1
- package/dist/public-preview.js.map +1 -1
- package/dist/public-tunnel-config.d.ts +11 -0
- package/dist/public-tunnel-config.js +68 -0
- package/dist/public-tunnel-config.js.map +1 -0
- package/dist/public-web-gateway.d.ts +2 -0
- package/dist/public-web-gateway.js +19 -6
- package/dist/public-web-gateway.js.map +1 -1
- package/dist/public-web-link.d.ts +48 -3
- package/dist/public-web-link.js +177 -51
- package/dist/public-web-link.js.map +1 -1
- package/dist/quickstart-api.d.ts +9 -0
- package/dist/quickstart-api.js +82 -0
- package/dist/quickstart-api.js.map +1 -1
- package/dist/quickstart.d.ts +5 -0
- package/dist/quickstart.js +40 -25
- package/dist/quickstart.js.map +1 -1
- package/dist/reply-buttons-controller.js.map +1 -1
- package/dist/reply-dedup.js.map +1 -1
- package/dist/resource-report.js +1 -1
- package/dist/resource-report.js.map +1 -1
- package/dist/restart-guard.js.map +1 -1
- package/dist/restart-progress.d.ts +80 -1
- package/dist/restart-progress.js +306 -21
- package/dist/restart-progress.js.map +1 -1
- package/dist/rollout-index.js.map +1 -1
- package/dist/runtime-cpu-profile.js.map +1 -1
- package/dist/scheduler/db.d.ts +40 -13
- package/dist/scheduler/db.js +123 -89
- package/dist/scheduler/db.js.map +1 -1
- package/dist/scheduler/scheduler.js.map +1 -1
- package/dist/scheduler/task-board-text.d.ts +26 -0
- package/dist/scheduler/task-board-text.js +140 -0
- package/dist/scheduler/task-board-text.js.map +1 -0
- package/dist/scheduler/task-board.d.ts +730 -0
- package/dist/scheduler/task-board.js +2179 -0
- package/dist/scheduler/task-board.js.map +1 -0
- package/dist/scheduler/types.d.ts +6 -1
- package/dist/sd-notify.js +2 -1
- package/dist/sd-notify.js.map +1 -1
- package/dist/search/search-docs.d.ts +58 -0
- package/dist/search/search-docs.js +63 -0
- package/dist/search/search-docs.js.map +1 -0
- package/dist/search/search-index.d.ts +141 -0
- package/dist/search/search-index.js +440 -0
- package/dist/search/search-index.js.map +1 -0
- package/dist/search/search-store.d.ts +122 -0
- package/dist/search/search-store.js +236 -0
- package/dist/search/search-store.js.map +1 -0
- package/dist/search/search-worker.d.ts +1 -0
- package/dist/search/search-worker.js +163 -0
- package/dist/search/search-worker.js.map +1 -0
- package/dist/secret-file.js.map +1 -1
- package/dist/secret-store.d.ts +2 -0
- package/dist/secret-store.js +21 -0
- package/dist/secret-store.js.map +1 -1
- package/dist/service-installer.d.ts +75 -0
- package/dist/service-installer.js +206 -0
- package/dist/service-installer.js.map +1 -1
- package/dist/service-owner.d.ts +44 -0
- package/dist/service-owner.js +48 -0
- package/dist/service-owner.js.map +1 -0
- package/dist/service-plan.d.ts +39 -2
- package/dist/service-plan.js +188 -6
- package/dist/service-plan.js.map +1 -1
- package/dist/session-oom.d.ts +21 -0
- package/dist/session-oom.js +139 -0
- package/dist/session-oom.js.map +1 -0
- package/dist/settings-api.d.ts +13 -0
- package/dist/settings-api.js +73 -12
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-baseline.js.map +1 -1
- package/dist/settings-change.d.ts +5 -0
- package/dist/settings-change.js +167 -6
- package/dist/settings-change.js.map +1 -1
- package/dist/settings-confirmation.d.ts +9 -1
- package/dist/settings-confirmation.js +18 -8
- package/dist/settings-confirmation.js.map +1 -1
- package/dist/settings-control.js +2 -1
- package/dist/settings-control.js.map +1 -1
- package/dist/settings-effect.js +29 -4
- package/dist/settings-effect.js.map +1 -1
- package/dist/settings-http-confirmation.d.ts +13 -0
- package/dist/settings-http-confirmation.js +15 -3
- package/dist/settings-http-confirmation.js.map +1 -1
- package/dist/settings-instance-patch.js +13 -1
- package/dist/settings-instance-patch.js.map +1 -1
- package/dist/settings-request-capability.d.ts +4 -1
- package/dist/settings-request-capability.js +11 -3
- package/dist/settings-request-capability.js.map +1 -1
- package/dist/settings-transaction.js.map +1 -1
- package/dist/setup-auth.d.ts +1 -0
- package/dist/setup-auth.js +2 -1
- package/dist/setup-auth.js.map +1 -1
- package/dist/setup-form.d.ts +1 -1
- package/dist/setup-form.js +23 -7
- package/dist/setup-form.js.map +1 -1
- package/dist/setup-host.d.ts +6 -1
- package/dist/setup-host.js +15 -4
- package/dist/setup-host.js.map +1 -1
- package/dist/setup-wizard.js +6 -3
- package/dist/setup-wizard.js.map +1 -1
- package/dist/spawn-gate.d.ts +5 -0
- package/dist/spawn-gate.js +28 -8
- package/dist/spawn-gate.js.map +1 -1
- package/dist/start-attempt.d.ts +1 -0
- package/dist/start-attempt.js +18 -0
- package/dist/start-attempt.js.map +1 -0
- package/dist/start-failure-notice.d.ts +4 -0
- package/dist/start-failure-notice.js +20 -0
- package/dist/start-failure-notice.js.map +1 -0
- package/dist/start-failure.d.ts +147 -0
- package/dist/start-failure.js +281 -0
- package/dist/start-failure.js.map +1 -0
- package/dist/startup-memory-deadline.d.ts +23 -0
- package/dist/startup-memory-deadline.js +55 -0
- package/dist/startup-memory-deadline.js.map +1 -0
- package/dist/statusline-watcher.js.map +1 -1
- package/dist/storm-window.js.map +1 -1
- package/dist/systemd-peer-bus.js.map +1 -1
- package/dist/target-queue-worker.js.map +1 -1
- package/dist/task-board-summary.d.ts +101 -0
- package/dist/task-board-summary.js +177 -0
- package/dist/task-board-summary.js.map +1 -0
- package/dist/task-board-tool.d.ts +25 -0
- package/dist/task-board-tool.js +155 -0
- package/dist/task-board-tool.js.map +1 -0
- package/dist/task-board-waker.d.ts +51 -0
- package/dist/task-board-waker.js +141 -0
- package/dist/task-board-waker.js.map +1 -0
- package/dist/tips.js.map +1 -1
- package/dist/tmux-control.js +1 -1
- package/dist/tmux-control.js.map +1 -1
- package/dist/tmux-exec-helper.d.ts +104 -0
- package/dist/tmux-exec-helper.js +412 -0
- package/dist/tmux-exec-helper.js.map +1 -0
- package/dist/tmux-manager.d.ts +1 -0
- package/dist/tmux-manager.js +29 -13
- package/dist/tmux-manager.js.map +1 -1
- package/dist/tmux-read.js +2 -2
- package/dist/tmux-read.js.map +1 -1
- package/dist/tool-permissions.js.map +1 -1
- package/dist/tool-progress.js.map +1 -1
- package/dist/topic-archiver.js.map +1 -1
- package/dist/topic-commands.d.ts +13 -0
- package/dist/topic-commands.js +56 -33
- package/dist/topic-commands.js.map +1 -1
- package/dist/topic-link.js.map +1 -1
- package/dist/transcript-delta-reader.js.map +1 -1
- package/dist/transcript-jsonl.js.map +1 -1
- package/dist/transcript-monitor.js +5 -0
- package/dist/transcript-monitor.js.map +1 -1
- package/dist/transcript-sources.d.ts +2 -0
- package/dist/transcript-sources.js +4 -0
- package/dist/transcript-sources.js.map +1 -1
- package/dist/tunnel/cloudflared-install.js +3 -1
- package/dist/tunnel/cloudflared-install.js.map +1 -1
- package/dist/tunnel/cloudflared.d.ts +7 -16
- package/dist/tunnel/cloudflared.js +100 -13
- package/dist/tunnel/cloudflared.js.map +1 -1
- package/dist/tunnel/lease.js +3 -2
- package/dist/tunnel/lease.js.map +1 -1
- package/dist/tunnel/manager.js.map +1 -1
- package/dist/tunnel/named-diagnostics.d.ts +13 -0
- package/dist/tunnel/named-diagnostics.js +52 -0
- package/dist/tunnel/named-diagnostics.js.map +1 -0
- package/dist/tunnel/public-fetch.js.map +1 -1
- package/dist/tunnel/purpose-lane.js.map +1 -1
- package/dist/tunnel/types.d.ts +4 -1
- package/dist/tunnel/types.js.map +1 -1
- package/dist/types.d.ts +55 -2
- package/dist/ui/app-effects.js +23 -5
- package/dist/ui/app.html +2 -0
- package/dist/ui/backend-signin.js +297 -0
- package/dist/ui/chat-effects.js +10 -3
- package/dist/ui/chat-msg-actions.js +176 -0
- package/dist/ui/chat-render.js +62 -18
- package/dist/ui/chat-store.js +218 -48
- package/dist/ui/chat-strings.js +40 -8
- package/dist/ui/chat-thread.js +119 -10
- package/dist/ui/effect-trial-offer.js +2 -31
- package/dist/ui/effects-waker.js +2 -0
- package/dist/ui/fleet-canvas-layout.js +13 -4
- package/dist/ui/fleet-canvas.js +69 -28
- package/dist/ui/fleet-office-editor.js +149 -0
- package/dist/ui/fleet-office-model.js +358 -0
- package/dist/ui/fleet-office-pack.js +199 -0
- package/dist/ui/fleet-office-skin.js +474 -0
- package/dist/ui/fleet-office-store.js +49 -0
- package/dist/ui/fleet-office-zones.js +177 -0
- package/dist/ui/fleet-office.js +434 -0
- package/dist/ui/fleet-org.js +18 -5
- package/dist/ui/fleet-route-scene.js +272 -0
- package/dist/ui/fleet-route-worker.js +21 -0
- package/dist/ui/fleet-route.js +88 -0
- package/dist/ui/fleet-task-card.js +436 -0
- package/dist/ui/fleet-task-common.js +482 -0
- package/dist/ui/fleet-task-work.js +107 -0
- package/dist/ui/fleet-tasks.js +569 -0
- package/dist/ui/fleet-traffic.js +81 -18
- package/dist/ui/fleet-usage.js +36 -2
- package/dist/ui/guest-refused.html +41 -0
- package/dist/ui/icons/icon-192.png +0 -0
- package/dist/ui/icons/icon-512.png +0 -0
- package/dist/ui/image-lightbox.js +45 -1
- package/dist/ui/image-zoom.js +242 -0
- package/dist/ui/panel-chat.js +200 -56
- package/dist/ui/panel-details.js +2 -0
- package/dist/ui/panel-fleet.js +32 -71
- package/dist/ui/panel-needs.js +23 -6
- package/dist/ui/panel-settings.js +158 -32
- package/dist/ui/preview-panel.js +2 -1
- package/dist/ui/search-dialog.js +350 -0
- package/dist/ui/settings-appearance.js +170 -10
- package/dist/ui/settings-apply.js +3 -3
- package/dist/ui/settings-confirm.js +7 -2
- package/dist/ui/settings-dialogs.js +46 -21
- package/dist/ui/settings-discord.js +6 -2
- package/dist/ui/settings-guests.js +2 -1
- package/dist/ui/settings-learn.js +1 -0
- package/dist/ui/settings-model.js +51 -18
- package/dist/ui/settings-mods.js +8 -3
- package/dist/ui/settings-owner-effects.js +6 -4
- package/dist/ui/settings-strings.js +180 -6
- package/dist/ui/settings-token.js +3 -1
- package/dist/ui/settings-web-authority.js +13 -5
- package/dist/ui/settings-wizard.js +13 -7
- package/dist/ui/shared/agend-auth.js +2 -0
- package/dist/ui/shared/app-i18n.js +12 -5
- package/dist/ui/shared/app-needs.js +2 -2
- package/dist/ui/shared/app-prefs.js +15 -0
- package/dist/ui/shared/app-route.js +18 -0
- package/dist/ui/shared/app-shell.js +172 -28
- package/dist/ui/shared/app-store.js +3 -2
- package/dist/ui/shared/app-stream.js +5 -1
- package/dist/ui/shared/app-themes.js +116 -1
- package/dist/ui/shared/app.css +662 -48
- package/dist/ui/shared/app.js +9 -1
- package/dist/ui/shared/card-strings.js +4 -0
- package/dist/ui/shared/effect-app-runtime.js +7 -5
- package/dist/ui/shared/effect-chat-runtime.js +2 -7
- package/dist/ui/shared/effect-cursor.js +3 -2
- package/dist/ui/shared/effect-display-metadata.js +39 -0
- package/dist/ui/shared/effect-owner-source.js +8 -1
- package/dist/ui/shared/effect-registry.js +14 -4
- package/dist/ui/shared/effect-runtime-loader.js +3 -1
- package/dist/ui/shared/effect-stock-trust.js +5 -5
- package/dist/ui/shared/feature-flags.js +127 -0
- package/dist/ui/shared/guest-refused.js +35 -0
- package/dist/ui/shared/header-tools.js +2 -2
- package/dist/ui/shared/identity-card.js +26 -8
- package/dist/ui/shared/identity-color.js +17 -10
- package/dist/ui/shared/instance-nav.js +183 -28
- package/dist/ui/shared/owner-css.js +30 -1
- package/dist/ui/shared/panel-view.js +14 -29
- package/dist/ui/shared/text-undo.js +210 -0
- package/dist/ui/shared/tokens.css +4 -0
- package/dist/ui/shared/ui-dialog.js +5 -4
- package/dist/ui/shared/ui-icons.js +4 -0
- package/dist/ui/shared/ui-menu.js +20 -7
- package/dist/ui/shared/ui-toast.js +16 -3
- package/dist/ui/shared/usage-dialog.js +206 -16
- package/dist/ui/shared/view-strings.js +68 -4
- package/dist/ui/shared/web-authorize.js +50 -1
- package/dist/ui/signin.html +2 -0
- package/dist/ui/web-terminal/terminal.html +10 -10
- package/dist/ui/web-terminal/terminal.js +58 -12
- package/dist/update-check.js.map +1 -1
- package/dist/update-dispatch.js +1 -1
- package/dist/update-dispatch.js.map +1 -1
- package/dist/update-install.js.map +1 -1
- package/dist/update-launch.d.ts +10 -1
- package/dist/update-launch.js +39 -14
- package/dist/update-launch.js.map +1 -1
- package/dist/update-marker.js.map +1 -1
- package/dist/update-preflight.js +1 -1
- package/dist/update-preflight.js.map +1 -1
- package/dist/update-progress.d.ts +3 -1
- package/dist/update-progress.js +3 -1
- package/dist/update-progress.js.map +1 -1
- package/dist/usage/format-rich.js +6 -3
- package/dist/usage/format-rich.js.map +1 -1
- package/dist/usage/i18n-keys.d.ts +1 -1
- package/dist/usage/i18n-keys.js +2 -1
- package/dist/usage/i18n-keys.js.map +1 -1
- package/dist/usage/i18n.d.ts +13 -1
- package/dist/usage/i18n.js +29 -0
- package/dist/usage/i18n.js.map +1 -1
- package/dist/usage/providers.d.ts +89 -2
- package/dist/usage/providers.js +247 -41
- package/dist/usage/providers.js.map +1 -1
- package/dist/usage/statusline-usage.js.map +1 -1
- package/dist/usage/usage-api.d.ts +5 -1
- package/dist/usage/usage-api.js +185 -58
- package/dist/usage/usage-api.js.map +1 -1
- package/dist/usage-report.js.map +1 -1
- package/dist/usage-rollup.js +1 -1
- package/dist/usage-rollup.js.map +1 -1
- package/dist/user-systemd.d.ts +24 -0
- package/dist/user-systemd.js +75 -0
- package/dist/user-systemd.js.map +1 -0
- package/dist/view-api.d.ts +7 -0
- package/dist/view-api.js +16 -4
- package/dist/view-api.js.map +1 -1
- package/dist/wake-coordinator.js.map +1 -1
- package/dist/web-ambient.js.map +1 -1
- package/dist/web-api.d.ts +57 -10
- package/dist/web-api.js +1103 -70
- package/dist/web-api.js.map +1 -1
- package/dist/web-app-icon-worker.d.ts +1 -0
- package/dist/web-app-icon-worker.js +16 -0
- package/dist/web-app-icon-worker.js.map +1 -0
- package/dist/web-app-icon.d.ts +109 -0
- package/dist/web-app-icon.js +257 -0
- package/dist/web-app-icon.js.map +1 -0
- package/dist/web-appearance-policy.js.map +1 -1
- package/dist/web-appearance-tools.d.ts +1 -0
- package/dist/web-appearance-tools.js +7 -3
- package/dist/web-appearance-tools.js.map +1 -1
- package/dist/web-appearance-view.js.map +1 -1
- package/dist/web-appearance.d.ts +4 -10
- package/dist/web-appearance.js +7 -4
- package/dist/web-appearance.js.map +1 -1
- package/dist/web-auth.d.ts +8 -4
- package/dist/web-auth.js +33 -21
- package/dist/web-auth.js.map +1 -1
- package/dist/web-backend-login.d.ts +130 -0
- package/dist/web-backend-login.js +225 -0
- package/dist/web-backend-login.js.map +1 -0
- package/dist/web-card.js.map +1 -1
- package/dist/web-channel-echo.js.map +1 -1
- package/dist/web-chat-history.d.ts +118 -8
- package/dist/web-chat-history.js +220 -25
- package/dist/web-chat-history.js.map +1 -1
- package/dist/web-commands.d.ts +5 -1
- package/dist/web-commands.js +1 -1
- package/dist/web-commands.js.map +1 -1
- package/dist/web-cookie-names.d.ts +5 -0
- package/dist/web-cookie-names.js +12 -0
- package/dist/web-cookie-names.js.map +1 -0
- package/dist/web-effect-bundle.d.ts +2 -2
- package/dist/web-effect-library.js.map +1 -1
- package/dist/web-effect-playback.js.map +1 -1
- package/dist/web-effect-profiles.d.ts +16 -16
- package/dist/web-effect-profiles.js +3 -2
- package/dist/web-effect-profiles.js.map +1 -1
- package/dist/web-effect-service.js.map +1 -1
- package/dist/web-effect-tools.js.map +1 -1
- package/dist/web-effect-trials.js.map +1 -1
- package/dist/web-effect-upload.js.map +1 -1
- package/dist/web-effect.d.ts +6 -6
- package/dist/web-effect.js.map +1 -1
- package/dist/web-experimental-http.d.ts +2 -0
- package/dist/web-experimental-http.js +12 -0
- package/dist/web-experimental-http.js.map +1 -0
- package/dist/web-experimental.d.ts +11 -0
- package/dist/web-experimental.js +49 -0
- package/dist/web-experimental.js.map +1 -0
- package/dist/web-guest-access.d.ts +4 -2
- package/dist/web-guest-access.js +22 -10
- package/dist/web-guest-access.js.map +1 -1
- package/dist/web-guest-rooms.js.map +1 -1
- package/dist/web-host-guard.d.ts +11 -0
- package/dist/web-host-guard.js +11 -0
- package/dist/web-host-guard.js.map +1 -1
- package/dist/web-icons.d.ts +33 -1
- package/dist/web-icons.js +83 -11
- package/dist/web-icons.js.map +1 -1
- package/dist/web-identity-color.js.map +1 -1
- package/dist/web-image-meta.d.ts +13 -0
- package/dist/web-image-meta.js +62 -0
- package/dist/web-image-meta.js.map +1 -1
- package/dist/web-images.js.map +1 -1
- package/dist/web-libavoid.d.ts +14 -0
- package/dist/web-libavoid.js +46 -0
- package/dist/web-libavoid.js.map +1 -0
- package/dist/web-login.js.map +1 -1
- package/dist/web-mentions.js.map +1 -1
- package/dist/web-mod-agent.js.map +1 -1
- package/dist/web-mod-store.d.ts +2 -0
- package/dist/web-mod-store.js +10 -0
- package/dist/web-mod-store.js.map +1 -1
- package/dist/web-office-store.d.ts +104 -0
- package/dist/web-office-store.js +236 -0
- package/dist/web-office-store.js.map +1 -0
- package/dist/web-owner-css-store.d.ts +44 -1
- package/dist/web-owner-css-store.js +70 -9
- package/dist/web-owner-css-store.js.map +1 -1
- package/dist/web-owner-css.js.map +1 -1
- package/dist/web-png.d.ts +33 -0
- package/dist/web-png.js +329 -0
- package/dist/web-png.js.map +1 -0
- package/dist/web-prefs.d.ts +6 -0
- package/dist/web-prefs.js +29 -3
- package/dist/web-prefs.js.map +1 -1
- package/dist/web-preview.d.ts +2 -0
- package/dist/web-preview.js +2 -0
- package/dist/web-preview.js.map +1 -1
- package/dist/web-profile.js.map +1 -1
- package/dist/web-reactions.d.ts +35 -0
- package/dist/web-reactions.js +47 -0
- package/dist/web-reactions.js.map +1 -0
- package/dist/web-request-context.d.ts +5 -0
- package/dist/web-request-context.js.map +1 -1
- package/dist/web-returning-device.d.ts +4 -2
- package/dist/web-returning-device.js +13 -6
- package/dist/web-returning-device.js.map +1 -1
- package/dist/web-schedules.js.map +1 -1
- package/dist/web-send-dedupe.d.ts +36 -0
- package/dist/web-send-dedupe.js +69 -0
- package/dist/web-send-dedupe.js.map +1 -0
- package/dist/web-session-authorization.js.map +1 -1
- package/dist/web-session.js +1 -1
- package/dist/web-session.js.map +1 -1
- package/dist/web-settings-patch.d.ts +3 -1
- package/dist/web-settings-patch.js +11 -5
- package/dist/web-settings-patch.js.map +1 -1
- package/dist/web-settings-tools.d.ts +6 -0
- package/dist/web-settings-tools.js +52 -17
- package/dist/web-settings-tools.js.map +1 -1
- package/dist/web-terminal-http.js +15 -2
- package/dist/web-terminal-http.js.map +1 -1
- package/dist/web-terminal.js +1 -1
- package/dist/web-terminal.js.map +1 -1
- package/dist/web-theme-store.d.ts +2 -2
- package/dist/web-theme-store.js +6 -3
- package/dist/web-theme-store.js.map +1 -1
- package/dist/web-theme.d.ts +29 -0
- package/dist/web-theme.js +89 -1
- package/dist/web-theme.js.map +1 -1
- package/dist/web-upload.d.ts +18 -1
- package/dist/web-upload.js +45 -7
- package/dist/web-upload.js.map +1 -1
- package/dist/web-widget.js.map +1 -1
- package/dist/webhook-emitter.js.map +1 -1
- package/dist/windows-shortcuts.d.ts +78 -0
- package/dist/windows-shortcuts.js +203 -0
- package/dist/windows-shortcuts.js.map +1 -0
- package/dist/workflow-templates/default.md +3 -0
- package/dist/ws-server.js.map +1 -1
- package/dist/yaml-shared-nodes.d.ts +25 -0
- package/dist/yaml-shared-nodes.js +185 -0
- package/dist/yaml-shared-nodes.js.map +1 -0
- package/launcher/agend-install.cjs +828 -0
- package/launcher/install-admission.cjs +4 -39
- package/launcher/postinstall.cjs +14 -12
- package/launcher/private-home.cjs +43 -0
- package/package.json +16 -13
- package/scripts/preinstall-guard.cjs +2 -5
- package/templates/windows-shortcuts.ps1 +181 -0
- package/launcher/old-updater-note.cjs +0 -48
package/dist/daemon.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { agentWhatsNew, agendVersion, planWhatsNew, readWhatsNewRecord, recordWhatsNew, whatsNewNotice } from "./agent-whats-new.js";
|
|
2
2
|
import { join, dirname, resolve } from "node:path";
|
|
3
3
|
import { checkoutTarget, readCheckouts, releaseCandidate, reposRoot, verifyWorktree, writeCheckouts } from "./repo-worktree-guard.js";
|
|
4
4
|
import { mkdirSync, writeFileSync, readFileSync, readdirSync, existsSync, unlinkSync, rmSync, appendFileSync, statSync, renameSync } from "node:fs";
|
|
@@ -10,6 +10,7 @@ import { createHash, randomBytes, randomUUID } from "node:crypto";
|
|
|
10
10
|
import { EventEmitter } from "node:events";
|
|
11
11
|
import { rotateLogIfNeededAsync } from "./logger.js";
|
|
12
12
|
import { coredumpFilterLaunchPrefix } from "./coredump-filter.js";
|
|
13
|
+
import { observeCliOomIdentity, confirmedCliOom, consecutiveSessionOoms } from "./session-oom.js";
|
|
13
14
|
import { mcpServerState } from "./mcp-liveness.js";
|
|
14
15
|
import { clearPausedMarker, writePausedMarker } from "./pause-marker.js";
|
|
15
16
|
import { writeBackgroundWorkEndedMarker } from "./background-work-ended.js";
|
|
@@ -19,7 +20,9 @@ import { createTranscriptSource } from "./transcript-sources.js";
|
|
|
19
20
|
import { TranscriptTurnLedger } from "./transcript-turns.js";
|
|
20
21
|
import { credentialProfileStoreHome, resolveCredentialProfile } from "./backend/credential-profile.js";
|
|
21
22
|
import { resolveToolSet } from "./tool-permissions.js";
|
|
23
|
+
import { dashboardAccessProblem, dashboardFeaturesOff } from "./dashboard-permissions.js";
|
|
22
24
|
import { getAgendHome } from "./paths.js";
|
|
25
|
+
import { readCanvasWorkerEnabled, scopedFleetConfigEnvironment } from "./web-experimental.js";
|
|
23
26
|
import { readAgentEffect, sendEffectInParts } from "./web-effect-upload.js";
|
|
24
27
|
import { readAgentFile } from "./agent-file-read.js";
|
|
25
28
|
import { ASSET_UPLOAD_MAX_BYTES, MOD_FILE, MOD_MAX_PARTS, MOD_UPLOAD_MAX_BYTES, receiveFiles, receivePreview, sendAssetInParts, writeModFile, writePreview } from "./web-asset-parts.js";
|
|
@@ -53,6 +56,7 @@ import { measureSyncWork, noteSyncWork } from "./sync-work-attribution.js";
|
|
|
53
56
|
import { TranscriptDeltaReader } from "./transcript-delta-reader.js";
|
|
54
57
|
import { buildResumeContinuation, clearInFlightTurnMarker, consumeInFlightTurnMarker, decideTurnResume, normalizeResumeBackend, readResumeFingerprint, RESUME_BLOCKING_DELIVERY_STATES, writeInFlightTurnMarker, } from "./turn-resume.js";
|
|
55
58
|
import { codexLiveRowMatches } from "./backend/codex.js";
|
|
59
|
+
import { codexPackageProblemMessage } from "./backend/codex-package.js";
|
|
56
60
|
import { claudeConfigDirFor, claudeProfileConfigDir, claudeSwitchDialog, claudeSwitchTargetMatches } from "./backend/claude-code.js";
|
|
57
61
|
import { InteractionObservation, INTERACTION_CONFIRM_MS, sameInteractionOwner } from "./interaction-observation.js";
|
|
58
62
|
import { unrecognisedPromptShape } from "./unrecognised-prompt.js";
|
|
@@ -1157,6 +1161,18 @@ export class Daemon extends EventEmitter {
|
|
|
1157
1161
|
// injected by FleetManager below.
|
|
1158
1162
|
healthCheckTimer = null;
|
|
1159
1163
|
crashCount = 0;
|
|
1164
|
+
cliOomObservation = null;
|
|
1165
|
+
consecutiveOoms = null;
|
|
1166
|
+
oomSessionKey() {
|
|
1167
|
+
// Claude's per-instance statusline owns its ID. Other current getters
|
|
1168
|
+
// either return null or select by cwd (Muse/Grok): those are not proof
|
|
1169
|
+
// of this pane's session and must not trigger this destructive decision.
|
|
1170
|
+
if ((this.config.backend ?? "claude-code") !== "claude-code")
|
|
1171
|
+
return null;
|
|
1172
|
+
const session = this.backend?.getSessionId?.();
|
|
1173
|
+
return typeof session === "string" && session.trim() && session.length <= 512
|
|
1174
|
+
? JSON.stringify([this.config.backend ?? "claude-code", session.trim()]) : null;
|
|
1175
|
+
}
|
|
1160
1176
|
lastCrashAt = 0;
|
|
1161
1177
|
lastSpawnAt = 0;
|
|
1162
1178
|
crashTimestamps = [];
|
|
@@ -1565,6 +1581,7 @@ export class Daemon extends EventEmitter {
|
|
|
1565
1581
|
windowQueryFailureTicks = 0;
|
|
1566
1582
|
mcpRestartPending = false;
|
|
1567
1583
|
mcpRestartStaleTimer = null;
|
|
1584
|
+
mcpRestartCooldownTimer = null;
|
|
1568
1585
|
/** In-flight replacement grace; also the guard against three triggers stacking. */
|
|
1569
1586
|
mcpRestartGraceTimer = null;
|
|
1570
1587
|
/**
|
|
@@ -1601,6 +1618,20 @@ export class Daemon extends EventEmitter {
|
|
|
1601
1618
|
get isErrorState() {
|
|
1602
1619
|
return this.errorWaitingForRecovery || (this.healthCheckPaused && !this.isPaused) || this.stormWindow?.isActive() === true;
|
|
1603
1620
|
}
|
|
1621
|
+
/**
|
|
1622
|
+
* #2327: which of isErrorState's conditions holds, so a warning names the one actually observed. A CLI no longer
|
|
1623
|
+
* supervised outranks a tmux recovery, which outranks a detected error pattern — one match is enough for that last
|
|
1624
|
+
* one, so it proves neither a pause nor a repetition.
|
|
1625
|
+
*/
|
|
1626
|
+
get errorStateCause() {
|
|
1627
|
+
if (this.healthCheckPaused && !this.isPaused)
|
|
1628
|
+
return "unsupervised";
|
|
1629
|
+
if (this.stormWindow?.isActive() === true)
|
|
1630
|
+
return "tmux_recovering";
|
|
1631
|
+
if (this.errorWaitingForRecovery)
|
|
1632
|
+
return "error_detected";
|
|
1633
|
+
return null;
|
|
1634
|
+
}
|
|
1604
1635
|
get isPaused() { return this.pauseWakeState !== "active"; }
|
|
1605
1636
|
/** Current CLI process state for status surfaces and recovery commands. */
|
|
1606
1637
|
getProcessStatus() {
|
|
@@ -2356,6 +2387,7 @@ export class Daemon extends EventEmitter {
|
|
|
2356
2387
|
ackIfPending();
|
|
2357
2388
|
this.recordRecentEvent({ type: "assistant_text", preview: text.slice(0, 100) });
|
|
2358
2389
|
});
|
|
2390
|
+
this.transcriptMonitor.on("codex_package_missing_host", (root) => this.noteCodexPackageMissingHost(root));
|
|
2359
2391
|
this.transcriptMonitor.startPolling();
|
|
2360
2392
|
// HangDetector is the notification bridge to the fleet manager; pane state
|
|
2361
2393
|
// transitions below are the sole source of hang events (see hang-detector.ts).
|
|
@@ -2583,6 +2615,24 @@ export class Daemon extends EventEmitter {
|
|
|
2583
2615
|
this.fireMcpRestartRequest("already_idle");
|
|
2584
2616
|
}
|
|
2585
2617
|
}
|
|
2618
|
+
/** Keep a cooldown-suppressed revival alive without bypassing the idle gate. */
|
|
2619
|
+
deferMcpRestart(delayMs) {
|
|
2620
|
+
this.clearMcpRestartRequest();
|
|
2621
|
+
if (this.config.mcp_auto_restart === false || this.authFailureUnresolved
|
|
2622
|
+
|| this.mcpRestartCancelledByRecovery("cooldown"))
|
|
2623
|
+
return;
|
|
2624
|
+
this.mcpRestartPending = true;
|
|
2625
|
+
this.mcpRestartCooldownTimer = setTimeout(() => {
|
|
2626
|
+
this.mcpRestartCooldownTimer = null;
|
|
2627
|
+
if (this.mcpRestartCancelledByRecovery("cooldown_expired"))
|
|
2628
|
+
return;
|
|
2629
|
+
this.clearMcpRestartRequest();
|
|
2630
|
+
if (this.config.mcp_auto_restart === false || this.authFailureUnresolved || this.mcpServerAlive().alive)
|
|
2631
|
+
return;
|
|
2632
|
+
this.armMcpRestartWhenIdle();
|
|
2633
|
+
}, Math.max(0, delayMs));
|
|
2634
|
+
this.mcpRestartCooldownTimer.unref?.();
|
|
2635
|
+
}
|
|
2586
2636
|
/**
|
|
2587
2637
|
* Single chokepoint for all three revival triggers (already_idle, idle_edge,
|
|
2588
2638
|
* stale_timeout) — and therefore the one place worth re-checking reality.
|
|
@@ -2600,6 +2650,8 @@ export class Daemon extends EventEmitter {
|
|
|
2600
2650
|
fireMcpRestartRequest(trigger) {
|
|
2601
2651
|
if (this.mcpRestartCancelledByRecovery(trigger))
|
|
2602
2652
|
return;
|
|
2653
|
+
if (this.mcpRestartCooldownTimer)
|
|
2654
|
+
return;
|
|
2603
2655
|
// Authoritative re-read — the CLI may have replaced the server since the
|
|
2604
2656
|
// health tick that armed this.
|
|
2605
2657
|
if (this.mcpServerAlive().alive) {
|
|
@@ -2794,6 +2846,10 @@ export class Daemon extends EventEmitter {
|
|
|
2794
2846
|
}
|
|
2795
2847
|
clearMcpRestartRequest() {
|
|
2796
2848
|
this.mcpRestartPending = false;
|
|
2849
|
+
if (this.mcpRestartCooldownTimer) {
|
|
2850
|
+
clearTimeout(this.mcpRestartCooldownTimer);
|
|
2851
|
+
this.mcpRestartCooldownTimer = null;
|
|
2852
|
+
}
|
|
2797
2853
|
if (this.mcpRestartStaleTimer) {
|
|
2798
2854
|
clearTimeout(this.mcpRestartStaleTimer);
|
|
2799
2855
|
this.mcpRestartStaleTimer = null;
|
|
@@ -2862,6 +2918,19 @@ export class Daemon extends EventEmitter {
|
|
|
2862
2918
|
if (discardStaleHealth())
|
|
2863
2919
|
return;
|
|
2864
2920
|
if (paneStatus?.alive) {
|
|
2921
|
+
// Capture only a known primary while it lives. No extra tmux call: PID comes
|
|
2922
|
+
// from this same status read. Fast/unobserved deaths remain ordinary crashes.
|
|
2923
|
+
const key = this.oomSessionKey();
|
|
2924
|
+
if (this.cliOomObservation?.key !== key)
|
|
2925
|
+
this.cliOomObservation = null;
|
|
2926
|
+
if (paneStatus.pid && key && !this.cliOomObservation) {
|
|
2927
|
+
const identity = await observeCliOomIdentity(paneStatus.pid, cliLabel);
|
|
2928
|
+
if (discardStaleHealth())
|
|
2929
|
+
return;
|
|
2930
|
+
if (identity && this.oomSessionKey() === key) {
|
|
2931
|
+
this.cliOomObservation = { identity, key, owner: healthOwner, tmux: healthTmux };
|
|
2932
|
+
}
|
|
2933
|
+
}
|
|
2865
2934
|
this.windowQueryFailureTicks = 0;
|
|
2866
2935
|
this.stormWindow?.noteWindowAlive(this.name);
|
|
2867
2936
|
// Instance output.log is fed by tmux pipe-pane and was previously never
|
|
@@ -3016,6 +3085,30 @@ export class Daemon extends EventEmitter {
|
|
|
3016
3085
|
return;
|
|
3017
3086
|
this.setProcessStatus("crashed");
|
|
3018
3087
|
this.logPaneDeath(cliLabel, exitCode, lastOutput);
|
|
3088
|
+
const observed = this.cliOomObservation;
|
|
3089
|
+
const key = this.oomSessionKey();
|
|
3090
|
+
const oom = paneStatus && exitCode === 137 && observed && observed.key === key
|
|
3091
|
+
&& observed.tmux === healthTmux && sameInteractionOwner(observed.owner, healthOwner)
|
|
3092
|
+
? await confirmedCliOom(observed.identity, Date.now()) : null;
|
|
3093
|
+
if (discardStaleHealth())
|
|
3094
|
+
return;
|
|
3095
|
+
this.cliOomObservation = null;
|
|
3096
|
+
const decisionKey = this.oomSessionKey();
|
|
3097
|
+
this.consecutiveOoms = consecutiveSessionOoms(this.consecutiveOoms, decisionKey, decisionKey === key && oom !== null);
|
|
3098
|
+
if (this.consecutiveOoms && this.consecutiveOoms.count >= 2) {
|
|
3099
|
+
// Stop supervision, not an idle pause: queued work must not auto-wake
|
|
3100
|
+
// the same session. An explicit restart is the person's retry choice.
|
|
3101
|
+
this.healthCheckPaused = true;
|
|
3102
|
+
try {
|
|
3103
|
+
this.appendCrashHistory({ exitCode, lastOutput, crashType, reason: "session_oom" });
|
|
3104
|
+
}
|
|
3105
|
+
catch (error) {
|
|
3106
|
+
this.logger.warn({ error }, "Could not append session OOM history");
|
|
3107
|
+
}
|
|
3108
|
+
this.logger.error({ pid: oom.pid, count: this.consecutiveOoms.count }, "Repeated confirmed CLI OOM — automatic resume stopped; session preserved");
|
|
3109
|
+
this.emitSupervisionEnded(t("inst.session_oom_stopped"), t("inst.session_oom_remedy"), exitCode, "session_oom");
|
|
3110
|
+
return;
|
|
3111
|
+
}
|
|
3019
3112
|
// Kill the dead window (remain-on-exit keeps it around) before respawn
|
|
3020
3113
|
if (paneStatus) {
|
|
3021
3114
|
await healthTmux.killWindow();
|
|
@@ -3126,14 +3219,14 @@ export class Daemon extends EventEmitter {
|
|
|
3126
3219
|
// (bounded) session lookup. They only stop LATER ticks; this continuation is already
|
|
3127
3220
|
// past that check and must not clear the process/window or respawn an instance that
|
|
3128
3221
|
// was just stopped or paused (#1160 review).
|
|
3129
|
-
if (
|
|
3222
|
+
if (discardStaleHealth())
|
|
3130
3223
|
return;
|
|
3131
3224
|
// Reset is synchronous for file sources, but Kiro's baseline is
|
|
3132
3225
|
// read off-thread. Finish it before starting the replacement CLI,
|
|
3133
3226
|
// otherwise its first work could become part of that baseline.
|
|
3134
3227
|
if (!await this.resetTranscriptBeforeAdmission())
|
|
3135
3228
|
return;
|
|
3136
|
-
if (
|
|
3229
|
+
if (discardStaleHealth())
|
|
3137
3230
|
return;
|
|
3138
3231
|
// Kill orphan MCP server from the crashed CLI session.
|
|
3139
3232
|
// MCP server writes its PID to channel.mcp.pid on startup.
|
|
@@ -3157,6 +3250,8 @@ export class Daemon extends EventEmitter {
|
|
|
3157
3250
|
}
|
|
3158
3251
|
}
|
|
3159
3252
|
catch { /* tmux server may be dead — ensureSession in trySpawn will recover */ }
|
|
3253
|
+
if (discardStaleHealth())
|
|
3254
|
+
return;
|
|
3160
3255
|
// Write snapshot before spawn — consumed only if resume fails
|
|
3161
3256
|
this.writeRotationSnapshot("crash");
|
|
3162
3257
|
// Try --resume first; spawnClaudeWindow falls back to fresh session if resume fails
|
|
@@ -3651,6 +3746,17 @@ export class Daemon extends EventEmitter {
|
|
|
3651
3746
|
const key = Daemon.errorPatternKey(ep);
|
|
3652
3747
|
const count = countMatches(ep.pattern);
|
|
3653
3748
|
const seen = this.lastErrorCount.get(key) ?? 0;
|
|
3749
|
+
// #2282: a resumed exhausted429 row is history, not even a new
|
|
3750
|
+
// notification/failover incident. Wait for the first live composer to
|
|
3751
|
+
// establish its baseline; later appended occurrences remain eligible.
|
|
3752
|
+
if (ep.type === "rate_limit" && ep.action === "nudge_continue") {
|
|
3753
|
+
const baseline = this.nudgeBaselines?.get(key);
|
|
3754
|
+
if (baseline === undefined || count <= baseline) {
|
|
3755
|
+
if (baseline !== undefined)
|
|
3756
|
+
this.lastErrorCount.set(key, count);
|
|
3757
|
+
continue;
|
|
3758
|
+
}
|
|
3759
|
+
}
|
|
3654
3760
|
// The generic Codex usage-limit line remains in scrollback after the
|
|
3655
3761
|
// user selects Luna Reserve. What proves that is NOT a live composer —
|
|
3656
3762
|
// codex paints one after a plain hit too, and the old live-composer guard
|
|
@@ -4677,7 +4783,9 @@ export class Daemon extends EventEmitter {
|
|
|
4677
4783
|
static AUTH_RECONFIRM_ROWS = 15;
|
|
4678
4784
|
/** Why the deferred pause was requested; what its marker records (Phase 2a). */
|
|
4679
4785
|
pendingPauseReason = "auth";
|
|
4680
|
-
async pause(reason = "operator") {
|
|
4786
|
+
async pause(reason = "operator", admission) {
|
|
4787
|
+
if (admission && !admission.current())
|
|
4788
|
+
return;
|
|
4681
4789
|
if (this.pauseWakeState === "paused")
|
|
4682
4790
|
return;
|
|
4683
4791
|
if (this.pauseWakeState === "pausing" || this.pauseWakeState === "waking") {
|
|
@@ -4685,6 +4793,8 @@ export class Daemon extends EventEmitter {
|
|
|
4685
4793
|
if (this.getPauseWakeState() !== "active")
|
|
4686
4794
|
return;
|
|
4687
4795
|
}
|
|
4796
|
+
if (admission && !admission.current())
|
|
4797
|
+
return;
|
|
4688
4798
|
// `pauseAllowStuck` is consumed here, not merely read: it authorises exactly
|
|
4689
4799
|
// one pause from a stuck pane (the auth-deferred one) and must never leak
|
|
4690
4800
|
// into an ordinary idle-timeout pause of a busy instance.
|
|
@@ -4704,7 +4814,7 @@ export class Daemon extends EventEmitter {
|
|
|
4704
4814
|
// this cycle while the backend reports background work; the next idle
|
|
4705
4815
|
// tick retries once the task ends. A pane-capture failure proceeds (the
|
|
4706
4816
|
// quit-menu handler below stays the backstop), never wedges unpaused.
|
|
4707
|
-
if (this.backend?.backgroundWorkRunning && this.tmux) {
|
|
4817
|
+
if ((admission || this.backend?.backgroundWorkRunning) && this.tmux) {
|
|
4708
4818
|
const tmux = this.tmux;
|
|
4709
4819
|
const windowId = tmux.getWindowId?.();
|
|
4710
4820
|
const generation = this.spawnGeneration;
|
|
@@ -4716,7 +4826,8 @@ export class Daemon extends EventEmitter {
|
|
|
4716
4826
|
// #1730 P2-2: the await yields — the pane read is only valid for the
|
|
4717
4827
|
// world it was taken from. Revalidate owner, phase, state and queue
|
|
4718
4828
|
// before acting on it; anything that moved defers this cycle.
|
|
4719
|
-
if (
|
|
4829
|
+
if ((admission && (!admission.current() || pane === null || !admission.accepts(pane)))
|
|
4830
|
+
|| this.tmux !== tmux
|
|
4720
4831
|
|| this.tmux?.getWindowId?.() !== windowId
|
|
4721
4832
|
|| this.spawnGeneration !== generation
|
|
4722
4833
|
|| this.getPauseWakeState() !== "active"
|
|
@@ -4913,7 +5024,9 @@ export class Daemon extends EventEmitter {
|
|
|
4913
5024
|
this.logger.info({ notLogged: this.stateEdgesNotLogged }, "Instance execution state edges were not logged while it was flapping");
|
|
4914
5025
|
this.stateEdgesNotLogged = 0;
|
|
4915
5026
|
}
|
|
4916
|
-
|
|
5027
|
+
// #2482: idle ↔ working is every turn (40% of daemon.log): debug. Anything involving stuck stays INFO.
|
|
5028
|
+
const routine = previous !== "stuck" && snapshot.state !== "stuck";
|
|
5029
|
+
this.logger[routine ? "debug" : "info"](fields, "Instance execution state changed");
|
|
4917
5030
|
return;
|
|
4918
5031
|
}
|
|
4919
5032
|
if (this.stateEdgesNotLogged === 0) {
|
|
@@ -6353,6 +6466,15 @@ export class Daemon extends EventEmitter {
|
|
|
6353
6466
|
this.config.cross_instance_visibility = update.cross_instance_visibility;
|
|
6354
6467
|
else if (update.cross_instance_visibility === null)
|
|
6355
6468
|
delete this.config.cross_instance_visibility;
|
|
6469
|
+
if (Number.isInteger(update.board_cards_at_once) && update.board_cards_at_once >= 1)
|
|
6470
|
+
this.config.board_cards_at_once = update.board_cards_at_once;
|
|
6471
|
+
else if (update.board_cards_at_once === null)
|
|
6472
|
+
delete this.config.board_cards_at_once;
|
|
6473
|
+
// The fleet reads it at each tool call; kept current here for the next spawn's tool menu.
|
|
6474
|
+
if (update.dashboard && typeof update.dashboard === "object" && !dashboardAccessProblem(update.dashboard))
|
|
6475
|
+
this.config.dashboard = update.dashboard;
|
|
6476
|
+
else if (update.dashboard === null)
|
|
6477
|
+
delete this.config.dashboard;
|
|
6356
6478
|
if (["trace", "debug", "info", "warn", "error"].includes(String(update.log_level))) {
|
|
6357
6479
|
const level = update.log_level;
|
|
6358
6480
|
if (this.config.log_level !== level) {
|
|
@@ -7612,6 +7734,46 @@ export class Daemon extends EventEmitter {
|
|
|
7612
7734
|
this.logger.info({ delayMs }, "Model-capacity nudge armed");
|
|
7613
7735
|
return true;
|
|
7614
7736
|
}
|
|
7737
|
+
/**
|
|
7738
|
+
* Consume an exhausted nudge only if its failed turn still owns an empty,
|
|
7739
|
+
* idle pane. Unlike arming, this verifies all input/work gates before pause.
|
|
7740
|
+
* The returned owner survives pause's own monitor freeze (which advances the
|
|
7741
|
+
* launch fence), but never another spawn/launch, cancel, delivery or episode.
|
|
7742
|
+
*/
|
|
7743
|
+
async prepareCapacityNudgePause() {
|
|
7744
|
+
const nudge = this.capacityNudge, episode = this.lastErrorEpisode;
|
|
7745
|
+
const tmux = this.tmux, attempt = this.launchAttempt, boot = this.bootId;
|
|
7746
|
+
this.cancelCapacityNudge("retries exhausted");
|
|
7747
|
+
if (!nudge || !episode || !tmux)
|
|
7748
|
+
return null;
|
|
7749
|
+
const window = tmux.getWindowId?.();
|
|
7750
|
+
const current = () => this.tmux === tmux && tmux.getWindowId?.() === window
|
|
7751
|
+
&& boot === this.bootId && nudge.spawn === this.spawnGeneration && attempt === this.launchAttempt
|
|
7752
|
+
&& episode === this.lastErrorEpisode && this.isDeliveryEpochCurrent(nudge.epoch)
|
|
7753
|
+
&& !this.startupAborted && !this.spawning && !this.isPaused
|
|
7754
|
+
&& this.getProcessStatus() === "running" && this.instanceState === "idle" && this.pasteQueueDepth === 0;
|
|
7755
|
+
const accepts = (pane) => pane === nudge.pane && this.paneAuthoritativelyIdle(pane)
|
|
7756
|
+
&& this.backend?.isPeriodicRedrawIdlePane?.(pane) === true
|
|
7757
|
+
&& codexLiveRowMatches(pane, nudge.pattern) && !this.backend?.backgroundWorkRunning?.(pane);
|
|
7758
|
+
const revalidate = () => this.paneWriteLock.run(async () => {
|
|
7759
|
+
if (!current())
|
|
7760
|
+
return false;
|
|
7761
|
+
try {
|
|
7762
|
+
const pane = await tmux.capturePane();
|
|
7763
|
+
return current() && accepts(pane);
|
|
7764
|
+
}
|
|
7765
|
+
catch {
|
|
7766
|
+
return false;
|
|
7767
|
+
}
|
|
7768
|
+
});
|
|
7769
|
+
// Initial admission must also respect the captured monitor fence. Later
|
|
7770
|
+
// revalidation deliberately tolerates only pause's own fence advancement.
|
|
7771
|
+
if (nudge.fence !== this.launchFenceEpoch || this.healthCheckPaused || this.runtimeMonitorsFrozen)
|
|
7772
|
+
return null;
|
|
7773
|
+
if (!await revalidate() || nudge.fence !== this.launchFenceEpoch || this.healthCheckPaused || this.runtimeMonitorsFrozen)
|
|
7774
|
+
return null;
|
|
7775
|
+
return { current, accepts, revalidate };
|
|
7776
|
+
}
|
|
7615
7777
|
/** Drop an armed nudge (the user stopped / paused the instance, or the lifecycle gave up on it). */
|
|
7616
7778
|
cancelCapacityNudge(reason) {
|
|
7617
7779
|
if (!this.capacityNudge)
|
|
@@ -7954,6 +8116,21 @@ export class Daemon extends EventEmitter {
|
|
|
7954
8116
|
this.footerFallbackEpoch = null;
|
|
7955
8117
|
}
|
|
7956
8118
|
footerFallbackWarnedGeneration = null;
|
|
8119
|
+
/** #2357: the launch (spawn generation and attempt) the missing code-mode host was last reported for. */
|
|
8120
|
+
codexPackageNoticeEpoch = null;
|
|
8121
|
+
/**
|
|
8122
|
+
* #2357: codex recorded that a tool call could not start its code-mode host. Every tool call of a code-mode-only
|
|
8123
|
+
* account fails this way (AgEnD's reply too) while the pane shows only `⚠ N warnings · f2 to view`. Told once per
|
|
8124
|
+
* launch however often the model retries; the launch check (CodexBackend.buildCommand) may already have said so.
|
|
8125
|
+
*/
|
|
8126
|
+
noteCodexPackageMissingHost(root) {
|
|
8127
|
+
const epoch = `${this.spawnGeneration}:${this.launchAttempt}`;
|
|
8128
|
+
if (this.codexPackageNoticeEpoch === epoch)
|
|
8129
|
+
return;
|
|
8130
|
+
this.codexPackageNoticeEpoch = epoch;
|
|
8131
|
+
this.logger.warn({ root }, "Codex tool call failed: code-mode host missing");
|
|
8132
|
+
this.emit("backend_launch_warning", { name: this.name, message: codexPackageProblemMessage(root, { file: "bin/codex-code-mode-host", reason: "missing" }) });
|
|
8133
|
+
}
|
|
7957
8134
|
/**
|
|
7958
8135
|
* The input-row proof used before a paste (#931/#947), with one fallback
|
|
7959
8136
|
* (#1031). Codex sometimes paints an idle composer without its Context
|
|
@@ -10414,7 +10591,11 @@ export class Daemon extends EventEmitter {
|
|
|
10414
10591
|
}
|
|
10415
10592
|
}
|
|
10416
10593
|
// ── MCP server env (dual-track: still passes env vars for MCP instructions fallback) ──
|
|
10594
|
+
const configEnvironment = scopedFleetConfigEnvironment(join(this.instanceDir, "..", ".."));
|
|
10417
10595
|
const mcpEnv = {
|
|
10596
|
+
// Empty values clear an unrelated reference inherited by the CLI or tmux server.
|
|
10597
|
+
AGEND_FLEET_DATA_DIR: configEnvironment.AGEND_FLEET_DATA_DIR ?? "",
|
|
10598
|
+
AGEND_FLEET_CONFIG_PATH: configEnvironment.AGEND_FLEET_CONFIG_PATH ?? "",
|
|
10418
10599
|
AGEND_SOCKET_PATH: sockPath,
|
|
10419
10600
|
AGEND_INSTANCE_NAME: this.name,
|
|
10420
10601
|
AGEND_WORKING_DIR: this.config.working_directory,
|
|
@@ -10437,6 +10618,11 @@ export class Daemon extends EventEmitter {
|
|
|
10437
10618
|
? resolveToolSet(this.config, this.name, "general")
|
|
10438
10619
|
: resolveToolSet(this.config, this.name);
|
|
10439
10620
|
mcpEnv.AGEND_TOOL_SET = toolSet;
|
|
10621
|
+
// The dashboard features the person switched off: out of the tool menu from this start (the fleet refuses them
|
|
10622
|
+
// at once, whatever the menu still shows).
|
|
10623
|
+
const dashboardOff = dashboardFeaturesOff(this.config.dashboard);
|
|
10624
|
+
if (dashboardOff.length)
|
|
10625
|
+
mcpEnv.AGEND_DASHBOARD_OFF = dashboardOff.join(",");
|
|
10440
10626
|
if (this.config.display_name)
|
|
10441
10627
|
mcpEnv.AGEND_DISPLAY_NAME = this.config.display_name;
|
|
10442
10628
|
if (this.config.description)
|
|
@@ -10469,6 +10655,7 @@ export class Daemon extends EventEmitter {
|
|
|
10469
10655
|
catch { /* fallback to empty */ }
|
|
10470
10656
|
instructions = buildFleetInstructions({
|
|
10471
10657
|
instanceName: this.name,
|
|
10658
|
+
taskBoard: !dashboardOff.includes("task_board"),
|
|
10472
10659
|
workingDirectory: this.config.working_directory,
|
|
10473
10660
|
runtimeIdentity: this.runtimeIdentity,
|
|
10474
10661
|
displayName: this.config.display_name,
|
|
@@ -10483,6 +10670,7 @@ export class Daemon extends EventEmitter {
|
|
|
10483
10670
|
else {
|
|
10484
10671
|
instructions = buildFleetInstructions({
|
|
10485
10672
|
instanceName: this.name,
|
|
10673
|
+
taskBoard: !dashboardOff.includes("task_board"),
|
|
10486
10674
|
workingDirectory: this.config.working_directory,
|
|
10487
10675
|
runtimeIdentity: this.runtimeIdentity,
|
|
10488
10676
|
displayName: this.config.display_name,
|
|
@@ -10585,6 +10773,7 @@ export class Daemon extends EventEmitter {
|
|
|
10585
10773
|
this.clearReplyGuardConfirm();
|
|
10586
10774
|
this.sawBlockedInput = false;
|
|
10587
10775
|
if (this.spawnDepth === 0) {
|
|
10776
|
+
this.cliOomObservation = null;
|
|
10588
10777
|
this.spawnGeneration++;
|
|
10589
10778
|
this.interactionObservation.reset(this.interactionOwner());
|
|
10590
10779
|
this.clearInteractionConfirmation();
|
|
@@ -10888,6 +11077,10 @@ export class Daemon extends EventEmitter {
|
|
|
10888
11077
|
// is reachable again (a fresh prompt is local and proves nothing).
|
|
10889
11078
|
this.backendOutage?.clear(this.backendKey());
|
|
10890
11079
|
}
|
|
11080
|
+
// A pre-existing fresh fallback is not another resume of the old session.
|
|
11081
|
+
// Providers may not have rewritten their session reading yet.
|
|
11082
|
+
if (!resumedSuccessfully)
|
|
11083
|
+
this.consecutiveOoms = null;
|
|
10891
11084
|
this.lastSpawnAt = Date.now();
|
|
10892
11085
|
// #1217: whatever session this CLI writes from here on is this backend's.
|
|
10893
11086
|
this.recordSessionOwner();
|
|
@@ -11404,16 +11597,41 @@ export class Daemon extends EventEmitter {
|
|
|
11404
11597
|
this.pendingWhatsNew = null;
|
|
11405
11598
|
return null;
|
|
11406
11599
|
}
|
|
11407
|
-
|
|
11408
|
-
|
|
11409
|
-
|
|
11600
|
+
// Rebuild even when ids are unchanged: an experimental switch may have changed
|
|
11601
|
+
// while this delivery waited. Never paste the old enabled capability text.
|
|
11602
|
+
// #2163: rebuilt as planned — only the entries this instance's roles are told; the rest are recorded with them.
|
|
11603
|
+
const roles = this.whatsNewRoles();
|
|
11604
|
+
const shown = agentWhatsNew(readCanvasWorkerEnabled(join(this.instanceDir, "..", ".."))).filter(e => ids.includes(e.id) && (!e.audience || e.audience.some(r => roles.includes(r))));
|
|
11605
|
+
if (!shown.length) {
|
|
11606
|
+
this.pendingWhatsNew = null;
|
|
11607
|
+
try {
|
|
11608
|
+
recordWhatsNew(this.instanceDir, ids, pending.version);
|
|
11609
|
+
}
|
|
11610
|
+
catch (err) {
|
|
11611
|
+
this.logger.warn({ err }, "what's-new record not written — the notice may repeat once");
|
|
11612
|
+
}
|
|
11613
|
+
return null;
|
|
11614
|
+
}
|
|
11615
|
+
const narrowed = { notice: whatsNewNotice(pending.version, shown), ids, version: pending.version };
|
|
11410
11616
|
this.pendingWhatsNew = narrowed;
|
|
11411
11617
|
return narrowed;
|
|
11412
11618
|
}
|
|
11619
|
+
/**
|
|
11620
|
+
* #2163: who this instance is to the what's-new notices — a ClassicBot room's agent, General, or a fleet worker (with
|
|
11621
|
+
* `coordinator` too when its tool set is coordinator or full, the ones that carry get_/set_web_settings).
|
|
11622
|
+
*/
|
|
11623
|
+
whatsNewRoles() {
|
|
11624
|
+
if (this.runtimeIdentity?.kind === "classic")
|
|
11625
|
+
return ["classic"];
|
|
11626
|
+
if (this.config.general_topic === true || this.name === "general")
|
|
11627
|
+
return ["general"];
|
|
11628
|
+
const set = resolveToolSet(this.config, this.name);
|
|
11629
|
+
return set === "coordinator" || set === "full" ? ["worker", "coordinator"] : ["worker"];
|
|
11630
|
+
}
|
|
11413
11631
|
/** #1633: what this instance has not been told about its AgEnD version yet (see agent-whats-new.ts). */
|
|
11414
11632
|
prepareWhatsNew(fresh, version = agendVersion()) {
|
|
11415
11633
|
try {
|
|
11416
|
-
const plan = planWhatsNew({ record: readWhatsNewRecord(this.instanceDir), fresh, version });
|
|
11634
|
+
const plan = planWhatsNew({ record: readWhatsNewRecord(this.instanceDir), fresh, version, roles: this.whatsNewRoles(), canvasWorker: readCanvasWorkerEnabled(join(this.instanceDir, "..", "..")) });
|
|
11417
11635
|
if (!plan) {
|
|
11418
11636
|
this.pendingWhatsNew = null;
|
|
11419
11637
|
return;
|
|
@@ -11505,7 +11723,8 @@ export class Daemon extends EventEmitter {
|
|
|
11505
11723
|
// AGEND_HOME points the child's agent-cli at the same data dir the daemon
|
|
11506
11724
|
// is using, so it can locate <instanceDir>/agent.token.
|
|
11507
11725
|
const agendHome = join(this.instanceDir, "..", "..");
|
|
11508
|
-
|
|
11726
|
+
const configEnvironment = scopedFleetConfigEnvironment(agendHome);
|
|
11727
|
+
let envPrefix = `TERM=xterm-256color AGEND_INSTANCE_NAME=${shellQuote(this.name)} AGEND_HOME=${shellQuote(agendHome)} AGEND_FLEET_DATA_DIR=${shellQuote(configEnvironment.AGEND_FLEET_DATA_DIR ?? "")} AGEND_FLEET_CONFIG_PATH=${shellQuote(configEnvironment.AGEND_FLEET_CONFIG_PATH ?? "")}`;
|
|
11509
11728
|
if (backendConfig.agentMode === "cli" && backendConfig.agentPort) {
|
|
11510
11729
|
envPrefix += ` AGEND_PORT=${backendConfig.agentPort}`;
|
|
11511
11730
|
}
|
|
@@ -12228,7 +12447,7 @@ export class Daemon extends EventEmitter {
|
|
|
12228
12447
|
}
|
|
12229
12448
|
// ── Repo Checkout ─────────────────────────────────────────
|
|
12230
12449
|
async handleCheckoutRepo(args, respond) {
|
|
12231
|
-
const { execFile: execFileCb } = await import("
|
|
12450
|
+
const { execFile: execFileCb } = await import("./child-process.js");
|
|
12232
12451
|
const { promisify } = await import("node:util");
|
|
12233
12452
|
const execFileAsync = promisify(execFileCb);
|
|
12234
12453
|
const rawSource = args.source;
|
|
@@ -12264,7 +12483,7 @@ export class Daemon extends EventEmitter {
|
|
|
12264
12483
|
respond(null, `Not a git repository: ${source}`);
|
|
12265
12484
|
return;
|
|
12266
12485
|
}
|
|
12267
|
-
mkdirSync(join(this.instanceDir, "repos"), { recursive: true });
|
|
12486
|
+
mkdirSync(join(this.instanceDir, "repos"), { recursive: true, mode: 0o700 });
|
|
12268
12487
|
// Only a fresh direct child of a real repos/ directory (never through a symlinked repos/, never an existing path).
|
|
12269
12488
|
const target = checkoutTarget(this.instanceDir, source, branch);
|
|
12270
12489
|
if (!target.ok) {
|
|
@@ -12306,7 +12525,7 @@ export class Daemon extends EventEmitter {
|
|
|
12306
12525
|
respond(null, `Cannot release: ${root.reason}`);
|
|
12307
12526
|
return;
|
|
12308
12527
|
}
|
|
12309
|
-
const { execFile: execFileCb } = await import("
|
|
12528
|
+
const { execFile: execFileCb } = await import("./child-process.js");
|
|
12310
12529
|
const { promisify } = await import("node:util");
|
|
12311
12530
|
const execFileAsync = promisify(execFileCb);
|
|
12312
12531
|
const git = async (gitArgs, cwd) => (await execFileAsync("git", gitArgs, { cwd })).stdout;
|