oh-my-copilot 5.26.0 → 5.27.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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +2 -1
- package/bridge/claude-md-coordinator.cjs +2 -2
- package/bridge/cli.cjs +20832 -15745
- package/bridge/mcp-server.cjs +165 -53
- package/bridge/runtime-cli.cjs +4707 -1925
- package/bridge/team-mcp.cjs +2917 -816
- package/bridge/team.js +5397 -2381
- package/copilot/hooks.json +3 -3
- package/dist/__tests__/arguments-literal-substitution.test.d.ts +2 -0
- package/dist/__tests__/arguments-literal-substitution.test.d.ts.map +1 -0
- package/dist/__tests__/arguments-literal-substitution.test.js +34 -0
- package/dist/__tests__/arguments-literal-substitution.test.js.map +1 -0
- package/dist/__tests__/bridge-self-contained.test.d.ts +2 -0
- package/dist/__tests__/bridge-self-contained.test.d.ts.map +1 -0
- package/dist/__tests__/bridge-self-contained.test.js +44 -0
- package/dist/__tests__/bridge-self-contained.test.js.map +1 -0
- package/dist/__tests__/context-safety.test.js +1 -1
- package/dist/__tests__/context-safety.test.js.map +1 -1
- package/dist/__tests__/copilot-hook-dispatch.test.js +5 -1
- package/dist/__tests__/copilot-hook-dispatch.test.js.map +1 -1
- package/dist/__tests__/copilot-hooks-manifest.test.js +15 -1
- package/dist/__tests__/copilot-hooks-manifest.test.js.map +1 -1
- package/dist/__tests__/directory-context-injector-registration.test.js +5 -2
- package/dist/__tests__/directory-context-injector-registration.test.js.map +1 -1
- package/dist/__tests__/doctor-conflicts.test.js +61 -0
- package/dist/__tests__/doctor-conflicts.test.js.map +1 -1
- package/dist/__tests__/hook-command-normalizer.test.js +41 -49
- package/dist/__tests__/hook-command-normalizer.test.js.map +1 -1
- package/dist/__tests__/hooks/session-end-cleanup.test.js +87 -1
- package/dist/__tests__/hooks/session-end-cleanup.test.js.map +1 -1
- package/dist/__tests__/hooks-command-escaping.test.js +18 -16
- package/dist/__tests__/hooks-command-escaping.test.js.map +1 -1
- package/dist/__tests__/hud/omc-state.test.js +62 -1
- package/dist/__tests__/hud/omc-state.test.js.map +1 -1
- package/dist/__tests__/installer-mcp-config.test.js +39 -1
- package/dist/__tests__/installer-mcp-config.test.js.map +1 -1
- package/dist/__tests__/issue-2652-runtime-wiring-and-output-contract.test.js +1 -1
- package/dist/__tests__/issue-2652-runtime-wiring-and-output-contract.test.js.map +1 -1
- package/dist/__tests__/keyword-detector-echo-guard.test.js +13 -1
- package/dist/__tests__/keyword-detector-echo-guard.test.js.map +1 -1
- package/dist/__tests__/keyword-detector-script.test.js +201 -0
- package/dist/__tests__/keyword-detector-script.test.js.map +1 -1
- package/dist/__tests__/npm-package-surface-helpers.d.ts.map +1 -1
- package/dist/__tests__/npm-package-surface-helpers.js +8 -4
- package/dist/__tests__/npm-package-surface-helpers.js.map +1 -1
- package/dist/__tests__/plugin-setup-deps.test.js +103 -68
- package/dist/__tests__/plugin-setup-deps.test.js.map +1 -1
- package/dist/__tests__/preemptive-compaction-hook.test.js +62 -5
- package/dist/__tests__/preemptive-compaction-hook.test.js.map +1 -1
- package/dist/__tests__/ralph-prd-mandatory.test.js +3 -0
- package/dist/__tests__/ralph-prd-mandatory.test.js.map +1 -1
- package/dist/__tests__/rate-limit-wait/herdr-daemon.test.d.ts +10 -0
- package/dist/__tests__/rate-limit-wait/herdr-daemon.test.d.ts.map +1 -0
- package/dist/__tests__/rate-limit-wait/herdr-daemon.test.js +241 -0
- package/dist/__tests__/rate-limit-wait/herdr-daemon.test.js.map +1 -0
- package/dist/__tests__/rate-limit-wait/herdr-detector.test.d.ts +9 -0
- package/dist/__tests__/rate-limit-wait/herdr-detector.test.d.ts.map +1 -0
- package/dist/__tests__/rate-limit-wait/herdr-detector.test.js +162 -0
- package/dist/__tests__/rate-limit-wait/herdr-detector.test.js.map +1 -0
- package/dist/__tests__/repair-plugin-cache-script.test.js +7 -1
- package/dist/__tests__/repair-plugin-cache-script.test.js.map +1 -1
- package/dist/__tests__/run-cjs-graceful-fallback.test.js +3 -2
- package/dist/__tests__/run-cjs-graceful-fallback.test.js.map +1 -1
- package/dist/__tests__/run-cjs-windows-stdio-contract.test.js +4 -1
- package/dist/__tests__/run-cjs-windows-stdio-contract.test.js.map +1 -1
- package/dist/__tests__/setup-contracts-regression.test.js +13 -10
- package/dist/__tests__/setup-contracts-regression.test.js.map +1 -1
- package/dist/__tests__/skills.test.js +10 -9
- package/dist/__tests__/skills.test.js.map +1 -1
- package/dist/alias-retirement/__tests__/registry.test.js +2 -2
- package/dist/cli/__tests__/doctor-conflicts-json.test.js +2 -2
- package/dist/cli/__tests__/doctor-conflicts-json.test.js.map +1 -1
- package/dist/cli/__tests__/herdr-no-raw-calls.test.d.ts +10 -0
- package/dist/cli/__tests__/herdr-no-raw-calls.test.d.ts.map +1 -0
- package/dist/cli/__tests__/herdr-no-raw-calls.test.js +54 -0
- package/dist/cli/__tests__/herdr-no-raw-calls.test.js.map +1 -0
- package/dist/cli/__tests__/interop-herdr.test.d.ts +9 -0
- package/dist/cli/__tests__/interop-herdr.test.d.ts.map +1 -0
- package/dist/cli/__tests__/interop-herdr.test.js +138 -0
- package/dist/cli/__tests__/interop-herdr.test.js.map +1 -0
- package/dist/cli/__tests__/launch-herdr.test.d.ts +10 -0
- package/dist/cli/__tests__/launch-herdr.test.d.ts.map +1 -0
- package/dist/cli/__tests__/launch-herdr.test.js +133 -0
- package/dist/cli/__tests__/launch-herdr.test.js.map +1 -0
- package/dist/cli/__tests__/launch.test.js +140 -10
- package/dist/cli/__tests__/launch.test.js.map +1 -1
- package/dist/cli/__tests__/plugin-dir-capture.test.js +2 -0
- package/dist/cli/__tests__/plugin-dir-capture.test.js.map +1 -1
- package/dist/cli/__tests__/ralph-afk.test.js +392 -2
- package/dist/cli/__tests__/ralph-afk.test.js.map +1 -1
- package/dist/cli/__tests__/ralph-closeout.test.d.ts +2 -0
- package/dist/cli/__tests__/ralph-closeout.test.d.ts.map +1 -0
- package/dist/cli/__tests__/ralph-closeout.test.js +156 -0
- package/dist/cli/__tests__/ralph-closeout.test.js.map +1 -0
- package/dist/cli/__tests__/subcommand-json-flag.test.d.ts +2 -0
- package/dist/cli/__tests__/subcommand-json-flag.test.d.ts.map +1 -0
- package/dist/cli/__tests__/subcommand-json-flag.test.js +86 -0
- package/dist/cli/__tests__/subcommand-json-flag.test.js.map +1 -0
- package/dist/cli/__tests__/team-resume-v2.test.js +46 -0
- package/dist/cli/__tests__/team-resume-v2.test.js.map +1 -1
- package/dist/cli/__tests__/team.test.js +24 -0
- package/dist/cli/__tests__/team.test.js.map +1 -1
- package/dist/cli/__tests__/wait-teleport-json.test.js +2 -2
- package/dist/cli/__tests__/wait-teleport-json.test.js.map +1 -1
- package/dist/cli/commands/__tests__/teleport.test.js +42 -0
- package/dist/cli/commands/__tests__/teleport.test.js.map +1 -1
- package/dist/cli/commands/__tests__/wait.test.js +33 -1
- package/dist/cli/commands/__tests__/wait.test.js.map +1 -1
- package/dist/cli/commands/doctor-conflicts.d.ts.map +1 -1
- package/dist/cli/commands/doctor-conflicts.js +6 -2
- package/dist/cli/commands/doctor-conflicts.js.map +1 -1
- package/dist/cli/commands/ralph.d.ts +36 -1
- package/dist/cli/commands/ralph.d.ts.map +1 -1
- package/dist/cli/commands/ralph.js +298 -50
- package/dist/cli/commands/ralph.js.map +1 -1
- package/dist/cli/commands/team.d.ts.map +1 -1
- package/dist/cli/commands/team.js +2 -0
- package/dist/cli/commands/team.js.map +1 -1
- package/dist/cli/commands/teleport.d.ts.map +1 -1
- package/dist/cli/commands/teleport.js +6 -1
- package/dist/cli/commands/teleport.js.map +1 -1
- package/dist/cli/commands/wait.d.ts.map +1 -1
- package/dist/cli/commands/wait.js +3 -1
- package/dist/cli/commands/wait.js.map +1 -1
- package/dist/cli/index.js +8 -8
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/interop.d.ts +4 -3
- package/dist/cli/interop.d.ts.map +1 -1
- package/dist/cli/interop.js +95 -4
- package/dist/cli/interop.js.map +1 -1
- package/dist/cli/launch.d.ts +17 -2
- package/dist/cli/launch.d.ts.map +1 -1
- package/dist/cli/launch.js +110 -12
- package/dist/cli/launch.js.map +1 -1
- package/dist/cli/team.d.ts.map +1 -1
- package/dist/cli/team.js +4 -1
- package/dist/cli/team.js.map +1 -1
- package/dist/commands/index.js +1 -1
- package/dist/commands/index.js.map +1 -1
- package/dist/config/loader.d.ts.map +1 -1
- package/dist/config/loader.js +17 -0
- package/dist/config/loader.js.map +1 -1
- package/dist/features/__tests__/checkpoint.test.js +118 -1
- package/dist/features/__tests__/checkpoint.test.js.map +1 -1
- package/dist/features/__tests__/jev-model-routing.test.js +20 -2
- package/dist/features/__tests__/jev-model-routing.test.js.map +1 -1
- package/dist/features/__tests__/jev-slop-warning.test.js +22 -2
- package/dist/features/__tests__/jev-slop-warning.test.js.map +1 -1
- package/dist/features/checkpoint/index.d.ts.map +1 -1
- package/dist/features/checkpoint/index.js +25 -8
- package/dist/features/checkpoint/index.js.map +1 -1
- package/dist/features/jev-slop-warning.d.ts +3 -2
- package/dist/features/jev-slop-warning.d.ts.map +1 -1
- package/dist/features/jev-slop-warning.js +5 -3
- package/dist/features/jev-slop-warning.js.map +1 -1
- package/dist/features/rate-limit-wait/daemon.d.ts.map +1 -1
- package/dist/features/rate-limit-wait/daemon.js +55 -9
- package/dist/features/rate-limit-wait/daemon.js.map +1 -1
- package/dist/features/rate-limit-wait/tmux-detector.d.ts +33 -0
- package/dist/features/rate-limit-wait/tmux-detector.d.ts.map +1 -1
- package/dist/features/rate-limit-wait/tmux-detector.js +156 -0
- package/dist/features/rate-limit-wait/tmux-detector.js.map +1 -1
- package/dist/hooks/__tests__/precompact-restore.test.js +38 -0
- package/dist/hooks/__tests__/precompact-restore.test.js.map +1 -1
- package/dist/hooks/__tests__/workflow-drift-guard-script.test.js +7 -2
- package/dist/hooks/__tests__/workflow-drift-guard-script.test.js.map +1 -1
- package/dist/hooks/auto-slash-command/executor.js +1 -1
- package/dist/hooks/auto-slash-command/executor.js.map +1 -1
- package/dist/hooks/code-simplifier/__tests__/jev-trigger-shadow.test.js +24 -2
- package/dist/hooks/code-simplifier/__tests__/jev-trigger-shadow.test.js.map +1 -1
- package/dist/hooks/code-simplifier/jev-shadow.d.ts.map +1 -1
- package/dist/hooks/code-simplifier/jev-shadow.js +6 -4
- package/dist/hooks/code-simplifier/jev-shadow.js.map +1 -1
- package/dist/hooks/jev/__tests__/client.test.js +20 -1
- package/dist/hooks/jev/__tests__/client.test.js.map +1 -1
- package/dist/hooks/jev/__tests__/log-context.test.d.ts +2 -0
- package/dist/hooks/jev/__tests__/log-context.test.d.ts.map +1 -0
- package/dist/hooks/jev/__tests__/log-context.test.js +97 -0
- package/dist/hooks/jev/__tests__/log-context.test.js.map +1 -0
- package/dist/hooks/jev/__tests__/log-rotation.test.d.ts +2 -0
- package/dist/hooks/jev/__tests__/log-rotation.test.d.ts.map +1 -0
- package/dist/hooks/jev/__tests__/log-rotation.test.js +148 -0
- package/dist/hooks/jev/__tests__/log-rotation.test.js.map +1 -0
- package/dist/hooks/jev/__tests__/resolver-request-count.test.d.ts +2 -0
- package/dist/hooks/jev/__tests__/resolver-request-count.test.d.ts.map +1 -0
- package/dist/hooks/jev/__tests__/resolver-request-count.test.js +117 -0
- package/dist/hooks/jev/__tests__/resolver-request-count.test.js.map +1 -0
- package/dist/hooks/jev/__tests__/resolver.test.js +63 -1
- package/dist/hooks/jev/__tests__/resolver.test.js.map +1 -1
- package/dist/hooks/jev/__tests__/shared-breaker.test.d.ts +2 -0
- package/dist/hooks/jev/__tests__/shared-breaker.test.d.ts.map +1 -0
- package/dist/hooks/jev/__tests__/shared-breaker.test.js +294 -0
- package/dist/hooks/jev/__tests__/shared-breaker.test.js.map +1 -0
- package/dist/hooks/jev/__tests__/state-omit-ids.test.d.ts +2 -0
- package/dist/hooks/jev/__tests__/state-omit-ids.test.d.ts.map +1 -0
- package/dist/hooks/jev/__tests__/state-omit-ids.test.js +88 -0
- package/dist/hooks/jev/__tests__/state-omit-ids.test.js.map +1 -0
- package/dist/hooks/jev/client.d.ts +34 -2
- package/dist/hooks/jev/client.d.ts.map +1 -1
- package/dist/hooks/jev/client.js +80 -5
- package/dist/hooks/jev/client.js.map +1 -1
- package/dist/hooks/jev/config.d.ts +78 -4
- package/dist/hooks/jev/config.d.ts.map +1 -1
- package/dist/hooks/jev/config.js +123 -9
- package/dist/hooks/jev/config.js.map +1 -1
- package/dist/hooks/jev/points.d.ts +2 -0
- package/dist/hooks/jev/points.d.ts.map +1 -1
- package/dist/hooks/jev/points.js +41 -10
- package/dist/hooks/jev/points.js.map +1 -1
- package/dist/hooks/jev/resolver.d.ts +27 -2
- package/dist/hooks/jev/resolver.d.ts.map +1 -1
- package/dist/hooks/jev/resolver.js +176 -20
- package/dist/hooks/jev/resolver.js.map +1 -1
- package/dist/hooks/jev/types.d.ts +21 -4
- package/dist/hooks/jev/types.d.ts.map +1 -1
- package/dist/hooks/keyword-detector/__tests__/autopilot-command-parity.test.d.ts +2 -0
- package/dist/hooks/keyword-detector/__tests__/autopilot-command-parity.test.d.ts.map +1 -0
- package/dist/hooks/keyword-detector/__tests__/autopilot-command-parity.test.js +209 -0
- package/dist/hooks/keyword-detector/__tests__/autopilot-command-parity.test.js.map +1 -0
- package/dist/hooks/keyword-detector/__tests__/index.test.js +6 -1
- package/dist/hooks/keyword-detector/__tests__/index.test.js.map +1 -1
- package/dist/hooks/keyword-detector/__tests__/jev-shadow.test.js +15 -0
- package/dist/hooks/keyword-detector/__tests__/jev-shadow.test.js.map +1 -1
- package/dist/hooks/keyword-detector/index.d.ts.map +1 -1
- package/dist/hooks/keyword-detector/index.js +200 -2
- package/dist/hooks/keyword-detector/index.js.map +1 -1
- package/dist/hooks/keyword-detector/jev-shadow.js +3 -3
- package/dist/hooks/keyword-detector/jev-shadow.js.map +1 -1
- package/dist/hooks/learner/__tests__/jev-extraction-shadow.test.js +20 -1
- package/dist/hooks/learner/__tests__/jev-extraction-shadow.test.js.map +1 -1
- package/dist/hooks/learner/jev-shadow.js +3 -3
- package/dist/hooks/learner/jev-shadow.js.map +1 -1
- package/dist/hooks/persistent-mode/__tests__/architect-approval-transcript.test.d.ts +2 -0
- package/dist/hooks/persistent-mode/__tests__/architect-approval-transcript.test.d.ts.map +1 -0
- package/dist/hooks/persistent-mode/__tests__/architect-approval-transcript.test.js +280 -0
- package/dist/hooks/persistent-mode/__tests__/architect-approval-transcript.test.js.map +1 -0
- package/dist/hooks/persistent-mode/__tests__/error-handling.test.js +2 -2
- package/dist/hooks/persistent-mode/__tests__/error-handling.test.js.map +1 -1
- package/dist/hooks/persistent-mode/__tests__/jev-loop-continuation-shadow.test.js +47 -1
- package/dist/hooks/persistent-mode/__tests__/jev-loop-continuation-shadow.test.js.map +1 -1
- package/dist/hooks/persistent-mode/index.d.ts.map +1 -1
- package/dist/hooks/persistent-mode/index.js +136 -40
- package/dist/hooks/persistent-mode/index.js.map +1 -1
- package/dist/hooks/persistent-mode/jev-shadow.d.ts.map +1 -1
- package/dist/hooks/persistent-mode/jev-shadow.js +11 -7
- package/dist/hooks/persistent-mode/jev-shadow.js.map +1 -1
- package/dist/hooks/pre-compact/index.d.ts.map +1 -1
- package/dist/hooks/pre-compact/index.js +8 -5
- package/dist/hooks/pre-compact/index.js.map +1 -1
- package/dist/hooks/project-memory/__tests__/rescan-concurrency.test.d.ts +11 -0
- package/dist/hooks/project-memory/__tests__/rescan-concurrency.test.d.ts.map +1 -0
- package/dist/hooks/project-memory/__tests__/rescan-concurrency.test.js +227 -0
- package/dist/hooks/project-memory/__tests__/rescan-concurrency.test.js.map +1 -0
- package/dist/hooks/project-memory/index.d.ts.map +1 -1
- package/dist/hooks/project-memory/index.js +26 -6
- package/dist/hooks/project-memory/index.js.map +1 -1
- package/dist/hooks/ralph/__tests__/closeout.test.d.ts +2 -0
- package/dist/hooks/ralph/__tests__/closeout.test.d.ts.map +1 -0
- package/dist/hooks/ralph/__tests__/closeout.test.js +82 -0
- package/dist/hooks/ralph/__tests__/closeout.test.js.map +1 -0
- package/dist/hooks/ralph/__tests__/feedback-baseline.test.js +572 -4
- package/dist/hooks/ralph/__tests__/feedback-baseline.test.js.map +1 -1
- package/dist/hooks/ralph/__tests__/jev-verdict-shadow.test.js +23 -2
- package/dist/hooks/ralph/__tests__/jev-verdict-shadow.test.js.map +1 -1
- package/dist/hooks/ralph/closeout.d.ts +34 -0
- package/dist/hooks/ralph/closeout.d.ts.map +1 -0
- package/dist/hooks/ralph/closeout.js +66 -0
- package/dist/hooks/ralph/closeout.js.map +1 -0
- package/dist/hooks/ralph/feedback-baseline.d.ts +60 -6
- package/dist/hooks/ralph/feedback-baseline.d.ts.map +1 -1
- package/dist/hooks/ralph/feedback-baseline.js +302 -15
- package/dist/hooks/ralph/feedback-baseline.js.map +1 -1
- package/dist/hooks/ralph/index.d.ts +1 -1
- package/dist/hooks/ralph/index.d.ts.map +1 -1
- package/dist/hooks/ralph/index.js +1 -1
- package/dist/hooks/ralph/index.js.map +1 -1
- package/dist/hooks/ralph/jev-shadow.js +3 -3
- package/dist/hooks/ralph/jev-shadow.js.map +1 -1
- package/dist/hooks/ralph/verifier.d.ts +5 -0
- package/dist/hooks/ralph/verifier.d.ts.map +1 -1
- package/dist/hooks/ralph/verifier.js +21 -10
- package/dist/hooks/ralph/verifier.js.map +1 -1
- package/dist/hooks/registry/__tests__/registry.test.js +6 -0
- package/dist/hooks/registry/__tests__/registry.test.js.map +1 -1
- package/dist/hooks/registry/registry.d.ts +6 -2
- package/dist/hooks/registry/registry.d.ts.map +1 -1
- package/dist/hooks/registry/registry.js +21 -6
- package/dist/hooks/registry/registry.js.map +1 -1
- package/dist/hooks/registry/types.d.ts +2 -0
- package/dist/hooks/registry/types.d.ts.map +1 -1
- package/dist/hooks/session-end/__tests__/callbacks.test.js +10 -1
- package/dist/hooks/session-end/__tests__/callbacks.test.js.map +1 -1
- package/dist/hooks/session-end/__tests__/worker.test.js +111 -2
- package/dist/hooks/session-end/__tests__/worker.test.js.map +1 -1
- package/dist/hooks/session-end/callbacks.js +1 -1
- package/dist/hooks/session-end/callbacks.js.map +1 -1
- package/dist/hooks/session-end/cleanup-manifest.d.ts +2 -0
- package/dist/hooks/session-end/cleanup-manifest.d.ts.map +1 -1
- package/dist/hooks/session-end/cleanup-manifest.js +8 -0
- package/dist/hooks/session-end/cleanup-manifest.js.map +1 -1
- package/dist/hooks/session-end/index.d.ts.map +1 -1
- package/dist/hooks/session-end/index.js +21 -3
- package/dist/hooks/session-end/index.js.map +1 -1
- package/dist/hooks/session-end/worker.d.ts.map +1 -1
- package/dist/hooks/session-end/worker.js +32 -2
- package/dist/hooks/session-end/worker.js.map +1 -1
- package/dist/hooks/setup/__tests__/windows-patch.test.js +89 -17
- package/dist/hooks/setup/__tests__/windows-patch.test.js.map +1 -1
- package/dist/hooks/setup/index.d.ts +10 -21
- package/dist/hooks/setup/index.d.ts.map +1 -1
- package/dist/hooks/setup/index.js +14 -48
- package/dist/hooks/setup/index.js.map +1 -1
- package/dist/hooks/task-size-detector/__tests__/jev-shadow.test.js +2 -1
- package/dist/hooks/task-size-detector/__tests__/jev-shadow.test.js.map +1 -1
- package/dist/hud/omc-state.d.ts +8 -0
- package/dist/hud/omc-state.d.ts.map +1 -1
- package/dist/hud/omc-state.js +23 -2
- package/dist/hud/omc-state.js.map +1 -1
- package/dist/installer/__tests__/claude-mcp-config-path.test.d.ts +2 -0
- package/dist/installer/__tests__/claude-mcp-config-path.test.d.ts.map +1 -0
- package/dist/installer/__tests__/claude-mcp-config-path.test.js +323 -0
- package/dist/installer/__tests__/claude-mcp-config-path.test.js.map +1 -0
- package/dist/installer/__tests__/mcp-registry.test.js +81 -3
- package/dist/installer/__tests__/mcp-registry.test.js.map +1 -1
- package/dist/installer/__tests__/standalone-hook-reconcile.test.js +36 -0
- package/dist/installer/__tests__/standalone-hook-reconcile.test.js.map +1 -1
- package/dist/installer/index.d.ts.map +1 -1
- package/dist/installer/index.js +16 -4
- package/dist/installer/index.js.map +1 -1
- package/dist/installer/mcp-registry.d.ts +21 -1
- package/dist/installer/mcp-registry.d.ts.map +1 -1
- package/dist/installer/mcp-registry.js +101 -20
- package/dist/installer/mcp-registry.js.map +1 -1
- package/dist/lib/atomic-write.d.ts.map +1 -1
- package/dist/lib/atomic-write.js +61 -2
- package/dist/lib/atomic-write.js.map +1 -1
- package/dist/mcp/__tests__/team-cleanup.test.js +13 -0
- package/dist/mcp/__tests__/team-cleanup.test.js.map +1 -1
- package/dist/mcp/team-job-convergence.d.ts.map +1 -1
- package/dist/mcp/team-job-convergence.js +4 -1
- package/dist/mcp/team-job-convergence.js.map +1 -1
- package/dist/mcp/team-server.js +2 -2
- package/dist/mcp/team-server.js.map +1 -1
- package/dist/notifications/__tests__/approval-reply.test.js +8 -0
- package/dist/notifications/__tests__/approval-reply.test.js.map +1 -1
- package/dist/notifications/__tests__/reply-herdr.test.d.ts +8 -0
- package/dist/notifications/__tests__/reply-herdr.test.d.ts.map +1 -0
- package/dist/notifications/__tests__/reply-herdr.test.js +125 -0
- package/dist/notifications/__tests__/reply-herdr.test.js.map +1 -0
- package/dist/notifications/__tests__/tmux.test.js +56 -1
- package/dist/notifications/__tests__/tmux.test.js.map +1 -1
- package/dist/notifications/index.d.ts +1 -1
- package/dist/notifications/index.d.ts.map +1 -1
- package/dist/notifications/index.js +22 -7
- package/dist/notifications/index.js.map +1 -1
- package/dist/notifications/reply-listener.d.ts +28 -12
- package/dist/notifications/reply-listener.d.ts.map +1 -1
- package/dist/notifications/reply-listener.js +326 -172
- package/dist/notifications/reply-listener.js.map +1 -1
- package/dist/notifications/tmux.d.ts +22 -2
- package/dist/notifications/tmux.d.ts.map +1 -1
- package/dist/notifications/tmux.js +57 -2
- package/dist/notifications/tmux.js.map +1 -1
- package/dist/shared/types.d.ts +5 -0
- package/dist/shared/types.d.ts.map +1 -1
- package/dist/team/__tests__/herdr-session-realherdr.test.d.ts +9 -0
- package/dist/team/__tests__/herdr-session-realherdr.test.d.ts.map +1 -0
- package/dist/team/__tests__/herdr-session-realherdr.test.js +140 -0
- package/dist/team/__tests__/herdr-session-realherdr.test.js.map +1 -0
- package/dist/team/__tests__/herdr-session.test.d.ts +9 -0
- package/dist/team/__tests__/herdr-session.test.d.ts.map +1 -0
- package/dist/team/__tests__/herdr-session.test.js +270 -0
- package/dist/team/__tests__/herdr-session.test.js.map +1 -0
- package/dist/team/__tests__/idle-nudge.test.js +17 -0
- package/dist/team/__tests__/idle-nudge.test.js.map +1 -1
- package/dist/team/__tests__/mailbox-notification-guard.test.js +403 -181
- package/dist/team/__tests__/mailbox-notification-guard.test.js.map +1 -1
- package/dist/team/__tests__/scaling-launch-config.test.js +12 -0
- package/dist/team/__tests__/scaling-launch-config.test.js.map +1 -1
- package/dist/team/__tests__/scaling.test.js +12 -0
- package/dist/team/__tests__/scaling.test.js.map +1 -1
- package/dist/team/__tests__/task-claim-renewal.test.d.ts +2 -0
- package/dist/team/__tests__/task-claim-renewal.test.d.ts.map +1 -0
- package/dist/team/__tests__/task-claim-renewal.test.js +421 -0
- package/dist/team/__tests__/task-claim-renewal.test.js.map +1 -0
- package/dist/team/__tests__/task-storage-integrity.test.js +34 -0
- package/dist/team/__tests__/task-storage-integrity.test.js.map +1 -1
- package/dist/team/__tests__/tmux-session.create-team-herdr.test.d.ts +11 -0
- package/dist/team/__tests__/tmux-session.create-team-herdr.test.d.ts.map +1 -0
- package/dist/team/__tests__/tmux-session.create-team-herdr.test.js +99 -0
- package/dist/team/__tests__/tmux-session.create-team-herdr.test.js.map +1 -0
- package/dist/team/__tests__/tmux-session.herdr-arms.test.d.ts +10 -0
- package/dist/team/__tests__/tmux-session.herdr-arms.test.d.ts.map +1 -0
- package/dist/team/__tests__/tmux-session.herdr-arms.test.js +226 -0
- package/dist/team/__tests__/tmux-session.herdr-arms.test.js.map +1 -0
- package/dist/team/__tests__/tmux-session.test.js +888 -721
- package/dist/team/__tests__/tmux-session.test.js.map +1 -1
- package/dist/team/__tests__/worker-bootstrap.test.js +19 -0
- package/dist/team/__tests__/worker-bootstrap.test.js.map +1 -1
- package/dist/team/api-interop.d.ts +1 -1
- package/dist/team/api-interop.d.ts.map +1 -1
- package/dist/team/api-interop.js +13 -1
- package/dist/team/api-interop.js.map +1 -1
- package/dist/team/herdr-session.d.ts +267 -0
- package/dist/team/herdr-session.d.ts.map +1 -0
- package/dist/team/herdr-session.js +508 -0
- package/dist/team/herdr-session.js.map +1 -0
- package/dist/team/idle-nudge.d.ts +1 -1
- package/dist/team/idle-nudge.d.ts.map +1 -1
- package/dist/team/idle-nudge.js +4 -4
- package/dist/team/idle-nudge.js.map +1 -1
- package/dist/team/mailbox-notification-guard.d.ts +24 -19
- package/dist/team/mailbox-notification-guard.d.ts.map +1 -1
- package/dist/team/mailbox-notification-guard.js +241 -148
- package/dist/team/mailbox-notification-guard.js.map +1 -1
- package/dist/team/model-contract.d.ts.map +1 -1
- package/dist/team/model-contract.js +1 -0
- package/dist/team/model-contract.js.map +1 -1
- package/dist/team/runtime-v2.d.ts +33 -33
- package/dist/team/runtime-v2.d.ts.map +1 -1
- package/dist/team/runtime-v2.js +2810 -1591
- package/dist/team/runtime-v2.js.map +1 -1
- package/dist/team/scaling.d.ts +3 -3
- package/dist/team/scaling.d.ts.map +1 -1
- package/dist/team/scaling.js +766 -402
- package/dist/team/scaling.js.map +1 -1
- package/dist/team/state/tasks.d.ts +15 -1
- package/dist/team/state/tasks.d.ts.map +1 -1
- package/dist/team/state/tasks.js +56 -2
- package/dist/team/state/tasks.js.map +1 -1
- package/dist/team/team-ops.d.ts +3 -2
- package/dist/team/team-ops.d.ts.map +1 -1
- package/dist/team/team-ops.js +32 -5
- package/dist/team/team-ops.js.map +1 -1
- package/dist/team/tmux-session.d.ts +66 -40
- package/dist/team/tmux-session.d.ts.map +1 -1
- package/dist/team/tmux-session.js +1733 -1096
- package/dist/team/tmux-session.js.map +1 -1
- package/dist/team/types.d.ts +8 -0
- package/dist/team/types.d.ts.map +1 -1
- package/dist/team/types.js.map +1 -1
- package/dist/team/worker-bootstrap.d.ts.map +1 -1
- package/dist/team/worker-bootstrap.js +3 -0
- package/dist/team/worker-bootstrap.js.map +1 -1
- package/dist/tools/lsp/__tests__/devcontainer.test.js +39 -5
- package/dist/tools/lsp/__tests__/devcontainer.test.js.map +1 -1
- package/dist/tools/lsp/devcontainer.d.ts.map +1 -1
- package/dist/tools/lsp/devcontainer.js +25 -8
- package/dist/tools/lsp/devcontainer.js.map +1 -1
- package/dist/utils/__tests__/windows-search.test.js +17 -3
- package/dist/utils/__tests__/windows-search.test.js.map +1 -1
- package/dist/utils/plugin-cache-validation.d.ts.map +1 -1
- package/dist/utils/plugin-cache-validation.js +27 -18
- package/dist/utils/plugin-cache-validation.js.map +1 -1
- package/dist/workflow/__tests__/projections.test.js +3 -3
- package/dist/workflow/__tests__/projections.test.js.map +1 -1
- package/dist/workflow/__tests__/registry.test.js +3 -3
- package/dist/workflow/__tests__/registry.test.js.map +1 -1
- package/dist/workflow/registry.d.ts.map +1 -1
- package/dist/workflow/registry.js +1 -0
- package/dist/workflow/registry.js.map +1 -1
- package/docs/ARCHITECTURE.md +1 -1
- package/docs/CLAUDE.md +1 -1
- package/docs/CREDITS.md +1 -0
- package/docs/FEATURES.md +18 -0
- package/docs/HOOKS.md +339 -36
- package/docs/REFERENCE.md +8 -6
- package/docs/TEAM-MULTIPLEXER.md +107 -0
- package/hooks/hooks.json +204 -66
- package/hooks/jev-compaction.mjs +2404 -0
- package/package.json +2 -2
- package/plugin.json +1 -1
- package/scripts/check-omc-playbooks.mjs +214 -124
- package/scripts/code-simplifier.mjs +26 -3
- package/scripts/copilot/build-hooks.mjs +24 -7
- package/scripts/generate-inventory-graph.mjs +77 -92
- package/scripts/jev-eval.mjs +123 -22
- package/scripts/jev-repair-transcript.mjs +331 -0
- package/scripts/jev-resolve.mjs +374 -22
- package/scripts/keyword-detector.mjs +427 -29
- package/scripts/lib/hook-command-normalizer.d.mts +18 -0
- package/scripts/lib/hook-command-normalizer.mjs +97 -60
- package/scripts/lib/jev-breaker.d.mts +73 -0
- package/scripts/lib/jev-breaker.mjs +830 -0
- package/scripts/lib/jev-compaction-state.mjs +320 -0
- package/scripts/lib/jev-delivery-guard.mjs +567 -0
- package/scripts/lib/jev-mask.mjs +36 -0
- package/scripts/lib/jev-shadow.mjs +363 -14
- package/scripts/lib/shell-checks.mjs +1121 -0
- package/scripts/lib/state-root.cjs +19 -8
- package/scripts/lib/state-root.mjs +19 -8
- package/scripts/persistent-mode.cjs +289 -1
- package/scripts/persistent-mode.mjs +540 -91
- package/scripts/plugin-setup.mjs +22 -22
- package/scripts/plugin-shipping-surface.mjs +4 -1
- package/scripts/post-tool-use-failure.mjs +18 -0
- package/scripts/post-tool-verifier.mjs +49 -3
- package/scripts/pre-tool-enforcer.mjs +658 -64
- package/scripts/run.cjs +4 -2
- package/scripts/session-start.mjs +54 -0
- package/skills/AGENTS.md +1 -0
- package/skills/ai-slop-cleaner/SKILL.md +14 -0
- package/skills/arena/SKILL.md +8 -1
- package/skills/create-formal-verification-skill/SKILL.md +6 -4
- package/skills/figure-it-out/SKILL.md +5 -0
- package/skills/how/references/explainer-prompt.md +7 -4
- package/skills/interrogate/SKILL.md +10 -6
- package/skills/ralph/SKILL.md +25 -2
- package/skills/sdd/SKILL.md +67 -0
- package/skills/sdd/phases/criteria.md +144 -0
- package/skills/sdd/phases/execute.md +226 -0
- package/skills/sdd/phases/review.md +216 -0
- package/skills/sdd/phases/rules.md +195 -0
- package/skills/sdd/phases/spec.md +75 -0
- package/skills/sdd/phases/tasks.md +162 -0
- package/skills/statechart/scripts/run.ts +6 -3
- package/skills/statechart/scripts/test/child-env.test.ts +53 -0
- package/templates/hooks/keyword-detector.mjs +172 -5
- package/templates/hooks/lib/state-root.mjs +19 -8
- package/templates/hooks/persistent-mode.mjs +296 -1
package/bridge/mcp-server.cjs
CHANGED
|
@@ -11538,6 +11538,33 @@ function ensureDirSync(dir) {
|
|
|
11538
11538
|
throw err;
|
|
11539
11539
|
}
|
|
11540
11540
|
}
|
|
11541
|
+
function shouldRetryRename(error2) {
|
|
11542
|
+
if (process.platform !== "win32") {
|
|
11543
|
+
return false;
|
|
11544
|
+
}
|
|
11545
|
+
const err = error2;
|
|
11546
|
+
return err?.code === "EPERM" || err?.code === "EBUSY" || err?.code === "EACCES";
|
|
11547
|
+
}
|
|
11548
|
+
async function renameWithRetry(tempPath, filePath, maxAttempts = 10, delayMs = 3) {
|
|
11549
|
+
let lastError = null;
|
|
11550
|
+
for (let attempt = 0; attempt < maxAttempts; attempt++) {
|
|
11551
|
+
try {
|
|
11552
|
+
await fs2.rename(tempPath, filePath);
|
|
11553
|
+
return;
|
|
11554
|
+
} catch (error2) {
|
|
11555
|
+
if (!shouldRetryRename(error2)) {
|
|
11556
|
+
throw error2;
|
|
11557
|
+
}
|
|
11558
|
+
lastError = error2;
|
|
11559
|
+
if (attempt < maxAttempts - 1) {
|
|
11560
|
+
await new Promise((resolve63) => setTimeout(resolve63, delayMs));
|
|
11561
|
+
}
|
|
11562
|
+
}
|
|
11563
|
+
}
|
|
11564
|
+
if (lastError) {
|
|
11565
|
+
throw lastError;
|
|
11566
|
+
}
|
|
11567
|
+
}
|
|
11541
11568
|
function writeAllSync(fd, content, label) {
|
|
11542
11569
|
const bytes = Buffer.from(content, "utf-8");
|
|
11543
11570
|
let offset = 0;
|
|
@@ -11690,7 +11717,7 @@ async function atomicWriteJson(filePath, data, hooks) {
|
|
|
11690
11717
|
verifyPrivateTempFile(fd.fd, tempPath, "atomic JSON write");
|
|
11691
11718
|
backupPath = preservePriorTarget(filePath);
|
|
11692
11719
|
hooks?.beforeRename?.();
|
|
11693
|
-
await
|
|
11720
|
+
await renameWithRetry(tempPath, filePath);
|
|
11694
11721
|
let publishedIdentity = null;
|
|
11695
11722
|
try {
|
|
11696
11723
|
verifyPublishedFile(fd.fd, filePath, "atomic JSON write");
|
|
@@ -12949,12 +12976,12 @@ function containerUriToHostUri(uri, context) {
|
|
|
12949
12976
|
if (!context || !uri.startsWith("file://")) {
|
|
12950
12977
|
return uri;
|
|
12951
12978
|
}
|
|
12952
|
-
const
|
|
12953
|
-
if (
|
|
12954
|
-
|
|
12979
|
+
const containerPath = containerFileUriToPath(uri);
|
|
12980
|
+
if (containerPath === null) {
|
|
12981
|
+
return uri;
|
|
12955
12982
|
}
|
|
12956
|
-
const
|
|
12957
|
-
return (0, import_url2.pathToFileURL)(
|
|
12983
|
+
const hostPath = containerPathToHostPath(containerPath, context);
|
|
12984
|
+
return hostPath === containerPath ? uri : (0, import_url2.pathToFileURL)(hostPath).href;
|
|
12958
12985
|
}
|
|
12959
12986
|
function resolveDevContainerConfigPath(workspaceRoot) {
|
|
12960
12987
|
let dir = workspaceRoot;
|
|
@@ -13090,14 +13117,14 @@ function scoreContainerMatch(inspect, hostWorkspaceRoot, configFilePath) {
|
|
|
13090
13117
|
let hasDevContainerLabelMatch = false;
|
|
13091
13118
|
const expectedLocalFolder = configFilePath ? deriveHostDevContainerRoot(configFilePath) : (0, import_path10.resolve)(hostWorkspaceRoot);
|
|
13092
13119
|
for (const label of DEVCONTAINER_LOCAL_FOLDER_LABELS) {
|
|
13093
|
-
if (labels[label] && (
|
|
13120
|
+
if (labels[label] && isSameHostPath(labels[label], expectedLocalFolder)) {
|
|
13094
13121
|
score += 4;
|
|
13095
13122
|
hasDevContainerLabelMatch = true;
|
|
13096
13123
|
}
|
|
13097
13124
|
}
|
|
13098
13125
|
if (configFilePath) {
|
|
13099
13126
|
for (const label of DEVCONTAINER_CONFIG_FILE_LABELS) {
|
|
13100
|
-
if (labels[label] && (
|
|
13127
|
+
if (labels[label] && isSameHostPath(labels[label], configFilePath)) {
|
|
13101
13128
|
score += 3;
|
|
13102
13129
|
hasDevContainerLabelMatch = true;
|
|
13103
13130
|
}
|
|
@@ -13109,6 +13136,9 @@ function scoreContainerMatch(inspect, hostWorkspaceRoot, configFilePath) {
|
|
|
13109
13136
|
}
|
|
13110
13137
|
return score;
|
|
13111
13138
|
}
|
|
13139
|
+
function isSameHostPath(left, right) {
|
|
13140
|
+
return (0, import_path10.relative)((0, import_path10.resolve)(left), (0, import_path10.resolve)(right)) === "";
|
|
13141
|
+
}
|
|
13112
13142
|
function normalizeContainerPath(filePath) {
|
|
13113
13143
|
return import_path11.posix.normalize(filePath.replace(/\\/g, "/"));
|
|
13114
13144
|
}
|
|
@@ -13117,6 +13147,14 @@ function containerPathToFileUri(filePath) {
|
|
|
13117
13147
|
const encodedPath = normalizedPath.split("/").map((segment) => encodeURIComponent(segment)).join("/");
|
|
13118
13148
|
return `file://${encodedPath.startsWith("/") ? encodedPath : `/${encodedPath}`}`;
|
|
13119
13149
|
}
|
|
13150
|
+
function containerFileUriToPath(uri) {
|
|
13151
|
+
try {
|
|
13152
|
+
const { pathname } = new URL(uri);
|
|
13153
|
+
return /%2f/i.test(pathname) ? null : normalizeContainerPath(decodeURIComponent(pathname));
|
|
13154
|
+
} catch {
|
|
13155
|
+
return null;
|
|
13156
|
+
}
|
|
13157
|
+
}
|
|
13120
13158
|
function runDocker(args) {
|
|
13121
13159
|
const result = (0, import_child_process5.spawnSync)("docker", args, {
|
|
13122
13160
|
encoding: "utf8",
|
|
@@ -29117,10 +29155,13 @@ var init_types8 = __esm({
|
|
|
29117
29155
|
});
|
|
29118
29156
|
|
|
29119
29157
|
// src/hooks/jev/config.ts
|
|
29158
|
+
var BYTES_PER_MB, MAX_LOG_MB;
|
|
29120
29159
|
var init_config = __esm({
|
|
29121
29160
|
"src/hooks/jev/config.ts"() {
|
|
29122
29161
|
"use strict";
|
|
29123
29162
|
init_worktree_paths();
|
|
29163
|
+
BYTES_PER_MB = 1024 * 1024;
|
|
29164
|
+
MAX_LOG_MB = Math.floor(Number.MAX_SAFE_INTEGER / BYTES_PER_MB);
|
|
29124
29165
|
}
|
|
29125
29166
|
});
|
|
29126
29167
|
|
|
@@ -29148,11 +29189,41 @@ var init_task_size_detector = __esm({
|
|
|
29148
29189
|
});
|
|
29149
29190
|
|
|
29150
29191
|
// src/hooks/keyword-detector/index.ts
|
|
29151
|
-
var KEYWORD_PRIORITY, CANONICAL_WORKFLOW_SLASH_SKILLS, WORKFLOW_SLASH_PATTERN, PATH_SEGMENT_CHARS, FILE_PATH_PATTERN;
|
|
29192
|
+
var AUTOPILOT_ALIAS_PATTERN, AUTOPILOT_OTHER_PATTERN, KEYWORD_PATTERNS, KEYWORD_PRIORITY, CANONICAL_WORKFLOW_SLASH_SKILLS, WORKFLOW_SLASH_PATTERN, PATH_SEGMENT_CHARS, FILE_PATH_PATTERN, AUTOPILOT_COMMAND_VERBS, AUTOPILOT_HYPHENATED_VERB, AUTOPILOT_COMMAND_WORD, AUTOPILOT_STATUS_CONTINUATION, AUTOPILOT_NOT_A_COMMAND_AFTER, AUTOPILOT_NON_COMMAND_WORDS, AUTOPILOT_LEADING_STATUS, AUTOPILOT_COMMAND_AFTER, AUTOPILOT_COLON_VERB, AUTOPILOT_NON_ENGLISH_LINE;
|
|
29152
29193
|
var init_keyword_detector = __esm({
|
|
29153
29194
|
"src/hooks/keyword-detector/index.ts"() {
|
|
29154
29195
|
"use strict";
|
|
29155
29196
|
init_task_size_detector();
|
|
29197
|
+
AUTOPILOT_ALIAS_PATTERN = /\b(autopilot|auto[\s-]?pilot|fullsend|full\s+auto)\b/i;
|
|
29198
|
+
AUTOPILOT_OTHER_PATTERN = /\b(?:build|create|make)\s+me\s+(?:an?\s+)?(?:app|feature|project|tool|plugin|website|api|server|cli|script|system|service|dashboard|bot|extension)\b|\bi\s+want\s+an?\s+(?:app|feature|project|tool|plugin|website|api|server|cli|script|system|service|dashboard|bot|extension)\b|(오토파일럿)|(オートパイロット)/i;
|
|
29199
|
+
KEYWORD_PATTERNS = {
|
|
29200
|
+
cancel: /\b(cancelomc|stopomc)\b/i,
|
|
29201
|
+
ralph: /\b(ralph)\b(?!-)|(랄프)(?!로렌)|(ラルフ)(?!・?ローレン)/i,
|
|
29202
|
+
autopilot: new RegExp(`${AUTOPILOT_ALIAS_PATTERN.source}|${AUTOPILOT_OTHER_PATTERN.source}`, "i"),
|
|
29203
|
+
// Team keyword detection disabled — team mode is now explicit-only via /team skill.
|
|
29204
|
+
// This prevents infinite spawning when Claude workers receive prompts containing "team".
|
|
29205
|
+
team: /(?!x)x/,
|
|
29206
|
+
// never-match placeholder (type system requires the key)
|
|
29207
|
+
ralplan: /\b(ralplan)\b|(랄플랜)|(ラルプラン)/i,
|
|
29208
|
+
tdd: /\b(tdd)\b|\btest\s+first\b|(테스트\s?퍼스트)|(テスト\s?ファースト)/i,
|
|
29209
|
+
"code-review": /\b(code\s+review|review\s+code)\b|(코드\s?리뷰)(?!어)|(コード\s?レビュー)(?!ア)/i,
|
|
29210
|
+
"security-review": /\b(security\s+review|review\s+security)\b|(보안\s?리뷰)(?!어)|(セキュリティ[ー]?\s?レビュー)(?!ア)/i,
|
|
29211
|
+
ultrathink: /\b(ultrathink)\b|(울트라씽크)|(ウルトラシンク)/i,
|
|
29212
|
+
deepsearch: /\b(deepsearch)\b|\bsearch\s+the\s+codebase\b|\bfind\s+in\s+(the\s+)?codebase\b|(딥\s?서치)|(ディープ\s?サーチ)/i,
|
|
29213
|
+
analyze: /\b(deep[\s-]?analyze|deepanalyze)\b|(딥\s?분석)|(ディープ\s?アナライズ)/i,
|
|
29214
|
+
"deep-interview": /\b(deep[\s-]interview|ouroboros)\b|(딥인터뷰)|(ディープインタビュー)/i,
|
|
29215
|
+
// Script-only triggers: never-match placeholders (script detects them, TypeScript doesn't)
|
|
29216
|
+
ultragoal: /(?!x)x/,
|
|
29217
|
+
// Script-only detection
|
|
29218
|
+
"ai-slop-cleaner": /(?!x)x/,
|
|
29219
|
+
// Script-only detection
|
|
29220
|
+
wiki: /(?!x)x/,
|
|
29221
|
+
// Script-only detection
|
|
29222
|
+
codex: /\b(ask|use|delegate\s+to)\s+(codex|gpt)\b/i,
|
|
29223
|
+
gemini: /\b(ask|use|delegate\s+to)\s+gemini\b/i,
|
|
29224
|
+
cursor: /\b(ask|use|delegate\s+to)\s+cursor\b/i,
|
|
29225
|
+
antigravity: /\b(ask|use|delegate\s+to)\s+(antigravity|agy)\b/i
|
|
29226
|
+
};
|
|
29156
29227
|
KEYWORD_PRIORITY = [
|
|
29157
29228
|
"cancel",
|
|
29158
29229
|
"ralph",
|
|
@@ -29191,6 +29262,16 @@ var init_keyword_detector = __esm({
|
|
|
29191
29262
|
"(^|[\\s\"'`(])(?:\\/)?(?:" + PATH_SEGMENT_CHARS + "+\\/)+(?:" + PATH_SEGMENT_CHARS + "*\\.\\w+|[\\w.\\-]+)",
|
|
29192
29263
|
"gm"
|
|
29193
29264
|
);
|
|
29265
|
+
AUTOPILOT_COMMAND_VERBS = "fix|debug|investigate|resolve|handle|patch|address|implement|build|create|make|run|start|enable|activate|invoke|trigger|launch|plan|add|write|refactor|update|remove|migrate|finish|continue|do|go|test|review|check|verify|audit|analy[sz]e|inspect|deploy|install|configure|document|explain|find|search|generate|convert|ship|release|merge|prepare|design|draft|upgrade|rename|clean|optimi[sz]e|rewrite|summari[sz]e|compare|bring|ping|seed";
|
|
29266
|
+
AUTOPILOT_HYPHENATED_VERB = "(?:re-(?:run|test|check|build|deploy|install|implement|review|verify|try|apply|start|launch|write|format|generate|create)|double-check|cross-check|un-install)";
|
|
29267
|
+
AUTOPILOT_COMMAND_WORD = `(?:(?:${AUTOPILOT_COMMAND_VERBS})|${AUTOPILOT_HYPHENATED_VERB})`;
|
|
29268
|
+
AUTOPILOT_STATUS_CONTINUATION = "\\s+(?:fails|was|were|is|are|has|had|looks|takes|keeps|hangs|hung|timed\\s+out|succeeds|passes|completes|finishes|works)(?![\\p{L}\\d])|\\s+(?:failed|crashed|errored|ok|okay|done|green|succeeded|passed|completed|finished|worked)(?![\\p{L}\\d])(?=[ \\t]*(?:[.,;:!?)]|\\r?\\n|$)|[ \\t]+(?:on|at|in|with|after|during|for|because|again|twice|and|but|so|before|when|while|since|until|due|once|yesterday|today|overnight|too|earlier|already)(?![\\p{L}\\d]))|\\s+(?:step|phase|exit|status|log|suite|mode|output|report|results?|summary)\\s+(?:\\d+|is|are|was|were|has|had|failed|fails|passed|passes|succeeded|looks|takes|keeps|crashed|errored|ok|okay|red|green)(?![\\p{L}\\d])";
|
|
29269
|
+
AUTOPILOT_NOT_A_COMMAND_AFTER = `(?!${AUTOPILOT_STATUS_CONTINUATION})`;
|
|
29270
|
+
AUTOPILOT_NON_COMMAND_WORDS = "a|an|the|this|that|these|those|my|our|your|his|her|its|their|i|we|you|he|she|it|they|me|us|them|is|are|was|were|be|been|am|has|have|had|do|does|did|will|would|can|could|should|may|might|must|shall|not|no|nor|and|or|but|so|if|then|than|as|at|in|on|of|to|for|from|with|by|about|into|onto|over|under|after|before|during|until|while|when|where|which|who|whom|what|why|how|also|just|only|still|already|always|never|now|currently|ready|idle|off|none|nothing|active|inactive|enabled|disabled|available|unavailable|busy|pending|offline|online|yes|here|there|too|very|really|actually|maybe|perhaps|however|hung|hangs|stuck|ran|went|got|took|broke|broken|froze|frozen|became|seems|seemed|remains|lost|left|hit|began|saw|said|gave|found|kept|knew|thought|told|wrote|made|built|sent|spent|stood|held|fell|drew|drove|chose|came|won|threw|grew|met|paid|rose|sold|taught|understood|wore|sat|slept|spoke|swept|sank";
|
|
29271
|
+
AUTOPILOT_LEADING_STATUS = new RegExp(`^(?:[ \\t]*[:\\uFF1A][ \\t]*(?:(?:${AUTOPILOT_NON_COMMAND_WORDS})|(?!(?:bring|ping|seed|feed|embed|proceed|succeed|speed|need|shred|string|swing|sing|ring|fling|sling|sting|wring|spring|cling)(?![\\p{L}\\d]))\\p{L}*(?:ing|ed))(?![\\p{L}\\d])|[ \\t]+(?:${AUTOPILOT_COMMAND_VERBS})(?![\\p{L}\\d])(?:${AUTOPILOT_STATUS_CONTINUATION}))`, "iu");
|
|
29272
|
+
AUTOPILOT_COMMAND_AFTER = new RegExp(`^(?:[ \\t]*[,;!\\u2014\\u2013][ \\t]*|[ \\t]+-[ \\t]+|[ \\t]+)${AUTOPILOT_COMMAND_WORD}(?![\\p{L}\\d])${AUTOPILOT_NOT_A_COMMAND_AFTER}`, "iu");
|
|
29273
|
+
AUTOPILOT_COLON_VERB = new RegExp(`^[ \\t]*[:\\uFF1A][ \\t]*${AUTOPILOT_COMMAND_WORD}(?![\\p{L}\\d])${AUTOPILOT_NOT_A_COMMAND_AFTER}`, "iu");
|
|
29274
|
+
AUTOPILOT_NON_ENGLISH_LINE = new RegExp("[\\p{Script=Hangul}\\p{Script=Hiragana}\\p{Script=Katakana}\\p{Script=Han}\\p{Script=Thai}]|(?![A-Za-z])\\p{L}", "u");
|
|
29194
29275
|
}
|
|
29195
29276
|
});
|
|
29196
29277
|
|
|
@@ -29220,7 +29301,7 @@ function defineJudgmentPoint(definition) {
|
|
|
29220
29301
|
blocking: definition.blocking
|
|
29221
29302
|
};
|
|
29222
29303
|
}
|
|
29223
|
-
var INTENT_QUESTIONS, NOUL_QUESTIONS, SCORE_QUESTIONS, MODEL_ROUTING_QUESTIONS, STALENESS_QUESTIONS, VERDICT_QUESTIONS, TASK_SIZE_QUESTIONS, LEARNER_EXTRACTION_QUESTIONS, SLOP_WARNING_QUESTIONS, SIMPLIFIER_TRIGGER_QUESTIONS, JUDGMENT_POINTS;
|
|
29304
|
+
var INTENT_QUESTIONS, NOUL_QUESTIONS, SCORE_QUESTIONS, MODEL_ROUTING_QUESTIONS, STALENESS_QUESTIONS, VERDICT_QUESTIONS, TASK_SIZE_QUESTIONS, LEARNER_EXTRACTION_QUESTIONS, SLOP_WARNING_QUESTIONS, SIMPLIFIER_TRIGGER_QUESTIONS, COMPACTION_QUESTIONS, JUDGMENT_POINTS;
|
|
29224
29305
|
var init_points = __esm({
|
|
29225
29306
|
"src/hooks/jev/points.ts"() {
|
|
29226
29307
|
"use strict";
|
|
@@ -29258,21 +29339,22 @@ var init_points = __esm({
|
|
|
29258
29339
|
MODEL_ROUTING_QUESTIONS = {
|
|
29259
29340
|
"model-tier": {
|
|
29260
29341
|
type: "choice",
|
|
29261
|
-
instructions: "Which model
|
|
29342
|
+
instructions: "Which model should do this delegated task? Choose the cheapest model that will do the work well, meaning correctly and completely. Reasoning effort is chosen by a separate question, so the length of the brief and the number of steps do not by themselves call for a more expensive model. Judge the work the delegated agent must actually do; the formal conditions of the brief (language and style rules, permission to use subagents, bans, file locations, report format, words in capitals) and the name of the agent type do not raise the choice. A more expensive model is needed when a cheaper one would clearly be more likely to get this work wrong or to miss something important. When the brief fits several descriptions, judge by the hardest important part of the work.",
|
|
29262
29343
|
criteria: {
|
|
29263
|
-
haiku: "
|
|
29264
|
-
sonnet: "
|
|
29265
|
-
opus: "
|
|
29344
|
+
haiku: "Haiku: mechanical work whose result follows directly from the data and is easy to check: look up, read, list, count, copy, compile a list, run a command and report the result, one obvious fix",
|
|
29345
|
+
sonnet: "Sonnet: typical developer and analyst work with a clear goal: code changes in one or a few files, tests, a diagnosis with clear leads, gathering and summarising information from several files or sources, assessment following given instructions, translation, a document written from given sources, a deployment following given steps, coordinating agents",
|
|
29346
|
+
opus: "Opus: work where a mistake is costly or hard to notice and that needs deep reasoning: architecture with tradeoffs, a hard bug without clear leads, an independent high-stakes review or fact-check, a letter or document on which money or important decisions depend, hard mathematics and proofs, deciding between conflicting sources, planning a large change"
|
|
29266
29347
|
}
|
|
29267
29348
|
},
|
|
29268
29349
|
effort: {
|
|
29269
29350
|
type: "score",
|
|
29270
|
-
instructions: "How much reasoning effort does this delegated task need?",
|
|
29351
|
+
instructions: "How much reasoning effort does this delegated task need? Judge the work the delegated agent must actually do. The length of the brief and its formal conditions (language and style rules, permission to use subagents, bans, file locations, report format, words in capitals) do not raise the level.",
|
|
29271
29352
|
criteria: {
|
|
29272
|
-
|
|
29273
|
-
|
|
29274
|
-
|
|
29275
|
-
|
|
29353
|
+
low: "Low: mechanical work: read, look up, list, copy or transcribe, count; the result follows directly from the data",
|
|
29354
|
+
medium: "Medium: a typical change or analysis with clear steps, in one place or following a given procedure or brief",
|
|
29355
|
+
high: "High: multi-file work that needs its own decisions, a diagnosis weighing a few hypotheses, or writing a document",
|
|
29356
|
+
xhigh: "Extra high: in-depth analysis, architecture, a high-stakes review, or a hard bug",
|
|
29357
|
+
max: "Maximum: exceptionally hard, hours of reasoning at the limit of difficulty; rare"
|
|
29276
29358
|
}
|
|
29277
29359
|
}
|
|
29278
29360
|
};
|
|
@@ -29339,6 +29421,18 @@ var init_points = __esm({
|
|
|
29339
29421
|
}
|
|
29340
29422
|
}
|
|
29341
29423
|
};
|
|
29424
|
+
COMPACTION_QUESTIONS = {
|
|
29425
|
+
"result-need": {
|
|
29426
|
+
type: "score",
|
|
29427
|
+
instructions: "How much will the tool result described under this question's name in state.results still be needed for further work on the user's task (state.task)? Judge whether further work will use it, not whether it was needed before.",
|
|
29428
|
+
criteria: {
|
|
29429
|
+
not_needed: "Not needed: the work it served is finished, or the result is easy to reproduce (a file listing, repository status, a write confirmation, a result repeated later).",
|
|
29430
|
+
probably_not_needed: "Probably not needed: background from which further work needs at most a conclusion already written in the conversation.",
|
|
29431
|
+
may_be_useful: "May be useful: details that further work may come back to.",
|
|
29432
|
+
needed: "Needed: data that further work relies on and that is nowhere else in the conversation (file contents before an edit, numbers for later calculations, findings, an error to fix)."
|
|
29433
|
+
}
|
|
29434
|
+
}
|
|
29435
|
+
};
|
|
29342
29436
|
JUDGMENT_POINTS = {
|
|
29343
29437
|
intent: defineJudgmentPoint({ name: "intent", questions: INTENT_QUESTIONS, blocking: false }),
|
|
29344
29438
|
"loop-continuation": defineJudgmentPoint({
|
|
@@ -29361,7 +29455,8 @@ var init_points = __esm({
|
|
|
29361
29455
|
name: "simplifier-trigger",
|
|
29362
29456
|
questions: SIMPLIFIER_TRIGGER_QUESTIONS,
|
|
29363
29457
|
blocking: false
|
|
29364
|
-
})
|
|
29458
|
+
}),
|
|
29459
|
+
compaction: defineJudgmentPoint({ name: "compaction", questions: COMPACTION_QUESTIONS, blocking: true })
|
|
29365
29460
|
};
|
|
29366
29461
|
}
|
|
29367
29462
|
});
|
|
@@ -31965,11 +32060,11 @@ function evaluateSdkSandbox(probe) {
|
|
|
31965
32060
|
if (probe.applyError) return { id, ok: false, detail: `supported, capabilities ${caps}; the review policy was not applied: ${probe.applyError}` };
|
|
31966
32061
|
const enf = probe.enforcement;
|
|
31967
32062
|
if (enf === void 0 || typeof enf === "string") return { id, ok: false, detail: `supported, capabilities ${caps}; review policy applied; enforcement unread: ${enf ?? "not asked"}` };
|
|
31968
|
-
const
|
|
32063
|
+
const spawn9 = probe.spawn ?? { ok: false, detail: "not run" };
|
|
31969
32064
|
return {
|
|
31970
32065
|
id,
|
|
31971
|
-
ok: !enf.blocked &&
|
|
31972
|
-
detail: `supported, capabilities ${caps}; review policy applied (options.update), enforcement required=${enf.required} blocked=${enf.blocked}${enf.reason ? ` (${enf.reason})` : ""}; spawn canary: ${
|
|
32066
|
+
ok: !enf.blocked && spawn9.ok,
|
|
32067
|
+
detail: `supported, capabilities ${caps}; review policy applied (options.update), enforcement required=${enf.required} blocked=${enf.blocked}${enf.reason ? ` (${enf.reason})` : ""}; spawn canary: ${spawn9.detail}`
|
|
31973
32068
|
};
|
|
31974
32069
|
}
|
|
31975
32070
|
function sliceLogByTime(text3, starts) {
|
|
@@ -33382,8 +33477,8 @@ function rpcMethod(root, path15, name) {
|
|
|
33382
33477
|
return null;
|
|
33383
33478
|
}
|
|
33384
33479
|
}
|
|
33385
|
-
function bwrapTrialLaunchError(
|
|
33386
|
-
const r =
|
|
33480
|
+
function bwrapTrialLaunchError(spawn9 = defaultTrialSpawner, timeoutMs = 1e4) {
|
|
33481
|
+
const r = spawn9("bwrap", BWRAP_TRIAL_ARGS, timeoutMs);
|
|
33387
33482
|
if (r.error?.code === "ENOENT") return "bwrap (bubblewrap) is not on PATH, and the Linux sandbox runs every shell under it: install bubblewrap";
|
|
33388
33483
|
if (r.error) return `a trial bwrap launch failed: ${errText(r.error)}`;
|
|
33389
33484
|
if (r.status === 0) return null;
|
|
@@ -41489,6 +41584,17 @@ var init_worktree_cleanup_safety = __esm({
|
|
|
41489
41584
|
}
|
|
41490
41585
|
});
|
|
41491
41586
|
|
|
41587
|
+
// src/team/herdr-session.ts
|
|
41588
|
+
var import_node_child_process3, import_node_util, execFileAsync4;
|
|
41589
|
+
var init_herdr_session = __esm({
|
|
41590
|
+
"src/team/herdr-session.ts"() {
|
|
41591
|
+
"use strict";
|
|
41592
|
+
import_node_child_process3 = require("node:child_process");
|
|
41593
|
+
import_node_util = require("node:util");
|
|
41594
|
+
execFileAsync4 = (0, import_node_util.promisify)(import_node_child_process3.execFile);
|
|
41595
|
+
}
|
|
41596
|
+
});
|
|
41597
|
+
|
|
41492
41598
|
// src/team/types.ts
|
|
41493
41599
|
var init_types9 = __esm({
|
|
41494
41600
|
"src/team/types.ts"() {
|
|
@@ -41624,14 +41730,18 @@ var init_runtime_owner_client = __esm({
|
|
|
41624
41730
|
function sanitizeName(name) {
|
|
41625
41731
|
const sanitized = name.replace(/[^a-zA-Z0-9-]/g, "");
|
|
41626
41732
|
if (sanitized.length === 0) {
|
|
41627
|
-
throw new Error(
|
|
41733
|
+
throw new Error(
|
|
41734
|
+
`Invalid name: "${name}" contains no valid characters (alphanumeric or hyphen)`
|
|
41735
|
+
);
|
|
41628
41736
|
}
|
|
41629
41737
|
if (sanitized.length < 2) {
|
|
41630
|
-
throw new Error(
|
|
41738
|
+
throw new Error(
|
|
41739
|
+
`Invalid name: "${name}" too short after sanitization (minimum 2 characters)`
|
|
41740
|
+
);
|
|
41631
41741
|
}
|
|
41632
41742
|
return sanitized.slice(0, 50);
|
|
41633
41743
|
}
|
|
41634
|
-
var import_fs66, import_crypto19, import_child_process20, import_util10, import_path83, import_os13,
|
|
41744
|
+
var import_fs66, import_crypto19, import_child_process20, import_util10, import_path83, import_os13, execFileAsync5;
|
|
41635
41745
|
var init_tmux_session = __esm({
|
|
41636
41746
|
"src/team/tmux-session.ts"() {
|
|
41637
41747
|
"use strict";
|
|
@@ -41641,7 +41751,9 @@ var init_tmux_session = __esm({
|
|
|
41641
41751
|
import_util10 = require("util");
|
|
41642
41752
|
import_path83 = require("path");
|
|
41643
41753
|
import_os13 = require("os");
|
|
41754
|
+
init_loader();
|
|
41644
41755
|
init_team_name();
|
|
41756
|
+
init_herdr_session();
|
|
41645
41757
|
init_tmux_utils();
|
|
41646
41758
|
init_types9();
|
|
41647
41759
|
init_team_owner_epoch();
|
|
@@ -41650,7 +41762,7 @@ var init_tmux_session = __esm({
|
|
|
41650
41762
|
init_worker_launch_ack();
|
|
41651
41763
|
init_runtime_owner_client();
|
|
41652
41764
|
init_psmux_adapter();
|
|
41653
|
-
|
|
41765
|
+
execFileAsync5 = (0, import_util10.promisify)(import_child_process20.execFile);
|
|
41654
41766
|
}
|
|
41655
41767
|
});
|
|
41656
41768
|
|
|
@@ -41713,7 +41825,7 @@ function hostGitEnv(args, base = process.env) {
|
|
|
41713
41825
|
function hostGitDriverOverrides(cwd, env2, timeout) {
|
|
41714
41826
|
let out;
|
|
41715
41827
|
try {
|
|
41716
|
-
out = (0,
|
|
41828
|
+
out = (0, import_node_child_process4.execFileSync)(hostGitExe(), [...hostGitHardeningArgs(), "config", "--null", "--show-scope", "--name-only", "--get-regexp", "^(filter|diff)\\."], { cwd, env: env2, encoding: "utf8", stdio: "pipe", windowsHide: true, timeout });
|
|
41717
41829
|
} catch (err) {
|
|
41718
41830
|
return err.status === 1 ? [] : null;
|
|
41719
41831
|
}
|
|
@@ -41745,11 +41857,11 @@ function hostGitExe() {
|
|
|
41745
41857
|
}
|
|
41746
41858
|
function runHostGit(cwd, args, timeout, baseEnv = process.env, input) {
|
|
41747
41859
|
const { argv, env: env2 } = hostGitCommand(cwd, args, timeout, baseEnv);
|
|
41748
|
-
return (0,
|
|
41860
|
+
return (0, import_node_child_process4.execFileSync)(hostGitExe(), argv, { cwd, env: env2, encoding: "utf-8", stdio: "pipe", windowsHide: true, timeout, maxBuffer: HOST_GIT_MAX_BUFFER, ...input !== void 0 ? { input } : {} });
|
|
41749
41861
|
}
|
|
41750
41862
|
function runHostGitBuffer(cwd, args, timeout, baseEnv = process.env, input) {
|
|
41751
41863
|
const { argv, env: env2 } = hostGitCommand(cwd, args, timeout, baseEnv);
|
|
41752
|
-
return (0,
|
|
41864
|
+
return (0, import_node_child_process4.execFileSync)(hostGitExe(), argv, { cwd, env: env2, stdio: "pipe", windowsHide: true, timeout, maxBuffer: 512 * 1024 * 1024, ...input !== void 0 ? { input } : {} });
|
|
41753
41865
|
}
|
|
41754
41866
|
function hostGitCommand(cwd, args, timeout, baseEnv) {
|
|
41755
41867
|
const env2 = hostGitEnv(args, baseEnv);
|
|
@@ -41777,7 +41889,7 @@ function hostGitAttrSourceProblem(version2) {
|
|
|
41777
41889
|
if (version2 === void 0) {
|
|
41778
41890
|
if (hostGitVersionCache === void 0) {
|
|
41779
41891
|
try {
|
|
41780
|
-
hostGitVersionCache = (0,
|
|
41892
|
+
hostGitVersionCache = (0, import_node_child_process4.execFileSync)(hostGitExe(), ["--version"], { encoding: "utf-8", stdio: "pipe", windowsHide: true }).trim();
|
|
41781
41893
|
} catch {
|
|
41782
41894
|
hostGitVersionCache = null;
|
|
41783
41895
|
}
|
|
@@ -41838,7 +41950,7 @@ function recordWorktreeGitLinks(wtPath, links) {
|
|
|
41838
41950
|
throw new Error(`sandbox-escaped: other git links are already recorded for ${wtPath}; the record is never replaced`);
|
|
41839
41951
|
}
|
|
41840
41952
|
const args = ["--git-dir", links.adminDir, "--work-tree", wtPath];
|
|
41841
|
-
const format2 = (0,
|
|
41953
|
+
const format2 = (0, import_node_child_process4.execFileSync)(hostGitExe(), [...hostGitHardeningArgs(), ...args, "rev-parse", "--show-object-format"], { cwd: wtPath, env: hostGitEnv(args), encoding: "utf-8", stdio: "pipe", windowsHide: true }).trim();
|
|
41842
41954
|
const emptyTree = EMPTY_TREE[format2];
|
|
41843
41955
|
if (!emptyTree) throw new Error(`host git: unknown object format ${JSON.stringify(format2)} in ${wtPath}`);
|
|
41844
41956
|
recordedGitDirs.set((0, import_node_path10.resolve)(links.adminDir), { wtPath, links, emptyTree });
|
|
@@ -42311,7 +42423,7 @@ function ensureWorkerWorktree(teamName, workerName, repoRoot, options = {}) {
|
|
|
42311
42423
|
const wtDir = (0, import_node_path10.join)(getOmcRoot(repoRoot), "team", sanitizeName(teamName), "worktrees");
|
|
42312
42424
|
ensureDirWithMode(wtDir);
|
|
42313
42425
|
const args = mode === "named" ? ["worktree", "add", "-b", branch2, wtPath, options.baseRef ?? "HEAD"] : ["worktree", "add", "--detach", wtPath, options.baseRef ?? "HEAD"];
|
|
42314
|
-
(0,
|
|
42426
|
+
(0, import_node_child_process4.execFileSync)(hostGitExe(), args, { cwd: repoRoot, stdio: "pipe", windowsHide: true });
|
|
42315
42427
|
const baseCommit = gitOrNull(["rev-parse", "HEAD"], wtPath);
|
|
42316
42428
|
const info = {
|
|
42317
42429
|
...baseCommit ? { baseCommit } : {},
|
|
@@ -42574,14 +42686,14 @@ function removeTamperedWorktree(repoRoot, teamName, workerName, wtPath, links, c
|
|
|
42574
42686
|
forgetMetadataUnlocked(repoRoot, teamName, workerName);
|
|
42575
42687
|
return `the git links of ${wtPath} (its .git file, or its admin dir's gitdir, commondir or config.worktree) changed or are gone, so no git ran in it; the worktree and its admin dir were removed by path and branch ${getBranchName(teamName, workerName)} was kept for inspection`;
|
|
42576
42688
|
}
|
|
42577
|
-
var import_node_fs9, import_node_os4, import_node_path10,
|
|
42689
|
+
var import_node_fs9, import_node_os4, import_node_path10, import_node_child_process4, import_node_crypto2, emptyHooksDir, EXEC_KEY_OVERRIDES, emptyAttributesFile, WORK_TREE_SUBCOMMANDS, GLOBAL_OPTIONS_WITH_VALUE, HOST_GIT_MAX_BUFFER, LANE_SUBMODULE_OVERRIDES, IGNORE_SUBMODULES_SUBCOMMANDS, EMPTY_TREE, HOST_GIT_ATTR_SOURCE_MIN, hostGitVersionCache, recordedGitDirs, pathKey, UNTRACKED_OMC_STATE, WORKTREE_RUNTIME_STATE_DIRS, RUNTIME_LEFTOVER_RETRY_MS;
|
|
42578
42690
|
var init_git_worktree = __esm({
|
|
42579
42691
|
"src/team/git-worktree.ts"() {
|
|
42580
42692
|
"use strict";
|
|
42581
42693
|
import_node_fs9 = require("node:fs");
|
|
42582
42694
|
import_node_os4 = require("node:os");
|
|
42583
42695
|
import_node_path10 = require("node:path");
|
|
42584
|
-
|
|
42696
|
+
import_node_child_process4 = require("node:child_process");
|
|
42585
42697
|
import_node_crypto2 = require("node:crypto");
|
|
42586
42698
|
init_windows_search();
|
|
42587
42699
|
init_fs_utils();
|
|
@@ -46125,7 +46237,7 @@ function defaultCopilotRunDeps(env2 = process.env) {
|
|
|
46125
46237
|
return {
|
|
46126
46238
|
env: env2,
|
|
46127
46239
|
platform: process.platform,
|
|
46128
|
-
loadSdk: () => loadCopilotSdk(env2,
|
|
46240
|
+
loadSdk: () => loadCopilotSdk(env2, import_node_child_process5.spawnSync),
|
|
46129
46241
|
resolveBin: () => resolveCopilotBinary(void 0, env2).bin,
|
|
46130
46242
|
pluginRoot: () => resolveDefaultPluginRoot(env2),
|
|
46131
46243
|
userConfigDir: () => getCopilotConfigDir(),
|
|
@@ -46137,15 +46249,15 @@ function defaultCopilotRunDeps(env2 = process.env) {
|
|
|
46137
46249
|
return err.code === "EPERM";
|
|
46138
46250
|
}
|
|
46139
46251
|
},
|
|
46140
|
-
killTree: (pid) => killProcessTree(pid,
|
|
46252
|
+
killTree: (pid) => killProcessTree(pid, import_node_child_process5.spawnSync)
|
|
46141
46253
|
};
|
|
46142
46254
|
}
|
|
46143
|
-
var
|
|
46255
|
+
var import_node_child_process5, import_node_crypto4, import_node_fs12, import_node_os6, import_node_path13, DEFAULT_TIMEOUT_MS, MAX_TIMEOUT_MS, DEFAULT_MAX_CREDITS, MAX_RUNNING_JOBS, MAX_PROMPT_CHARS, WORKTREE_TEAM, MCP_SERVER, START_TIMEOUT_MS2, RPC_TIMEOUT_MS2, ABORT_GRACE_MS2, SHUTDOWN_GRACE_MS2, STOP_TIMEOUT_MS2, SERVER_EXIT_GRACE_MS, GIT_TIMEOUT_MS2, DENIED_LOG_MAX, JOB_ID, MAX_START_REF_CHARS, STOP_CONTINUATION_SKIP_TOKEN, PROJECT_MEMORY_SKIP_TOKEN, CopilotRunError, REVIEW_SHELL_DENY_PATTERNS, IDENTITY_TIMEOUT_MS, sleep5, isTerminal2, git2, lines, JOB_REF_PREFIX, PLAIN_REF, CopilotRunManager;
|
|
46144
46256
|
var init_job = __esm({
|
|
46145
46257
|
"src/copilot-run/job.ts"() {
|
|
46146
46258
|
"use strict";
|
|
46147
46259
|
init_windows_search();
|
|
46148
|
-
|
|
46260
|
+
import_node_child_process5 = require("node:child_process");
|
|
46149
46261
|
import_node_crypto4 = require("node:crypto");
|
|
46150
46262
|
import_node_fs12 = require("node:fs");
|
|
46151
46263
|
import_node_os6 = require("node:os");
|
|
@@ -49752,7 +49864,7 @@ function readGateProcs(path15) {
|
|
|
49752
49864
|
async function listWindowsChildren(rootPid) {
|
|
49753
49865
|
const exe = (0, import_path102.join)(process.env.SystemRoot || "C:\\Windows", "System32", "WindowsPowerShell", "v1.0", "powershell.exe");
|
|
49754
49866
|
const script = `Get-CimInstance Win32_Process -Filter "ParentProcessId = ${rootPid}" | ForEach-Object { "$($_.ProcessId) " + ([DateTime]$_.CreationDate).ToUniversalTime().Ticks }`;
|
|
49755
|
-
const { stdout } = await
|
|
49867
|
+
const { stdout } = await execFileAsync6(exe, ["-NoProfile", "-NonInteractive", "-Command", script], { timeout: STEP_DEADLINE_MS, windowsHide: true });
|
|
49756
49868
|
const out = [];
|
|
49757
49869
|
for (const line of stdout.split(/\r?\n/)) {
|
|
49758
49870
|
const m = /^(\d+) (\d+)$/.exec(line.trim());
|
|
@@ -49867,7 +49979,7 @@ async function sweepGateProcs(dir, deps = defaultGateProcDeps()) {
|
|
|
49867
49979
|
if (/^[0-9a-f]{40}\.json$/.test(name)) await reapGateProcs((0, import_path102.join)(dir, name), deps).catch(() => void 0);
|
|
49868
49980
|
}
|
|
49869
49981
|
}
|
|
49870
|
-
var import_child_process21, import_child_process22, import_fs85, import_path102, import_util11,
|
|
49982
|
+
var import_child_process21, import_child_process22, import_fs85, import_path102, import_util11, execFileAsync6, STEP_DEADLINE_MS, HEX4011, GateProcsUnreadableError, gateProcsPath, isProc, TICKS_AT_EPOCH, ticksOfMs, sameMicrosecond, defaultGateProcDeps, swept;
|
|
49871
49983
|
var init_gate_procs = __esm({
|
|
49872
49984
|
"src/factory/run/gate-procs.ts"() {
|
|
49873
49985
|
"use strict";
|
|
@@ -49879,7 +49991,7 @@ var init_gate_procs = __esm({
|
|
|
49879
49991
|
init_mirror();
|
|
49880
49992
|
init_store();
|
|
49881
49993
|
init_process_utils();
|
|
49882
|
-
|
|
49994
|
+
execFileAsync6 = (0, import_util11.promisify)(import_child_process21.execFile);
|
|
49883
49995
|
STEP_DEADLINE_MS = 15e3;
|
|
49884
49996
|
HEX4011 = /^[0-9a-f]{40}$/;
|
|
49885
49997
|
GateProcsUnreadableError = class extends Error {
|
|
@@ -52243,11 +52355,11 @@ function applyCopyBack(checkout, tar, platform) {
|
|
|
52243
52355
|
}
|
|
52244
52356
|
return null;
|
|
52245
52357
|
}
|
|
52246
|
-
var
|
|
52358
|
+
var import_node_child_process6, import_node_crypto6, import_node_fs14, import_node_path15, GATE_CONTAINER_UNAVAILABLE_GATE, CONTAINER_INCOMPATIBLE_ADVICE, CONTAINER_NAME_PREFIX, RUN_LABEL2, GATE_LABEL, CACHE_LABEL, CONTAINER_PATH, CONTAINER_USER, WORK, SRC, NPM_REGISTRY, REGISTRY_PREFIXES, PROBE_TIMEOUT_MS, PULL_TIMEOUT_MS, COPY_TIMEOUT_MS, KILL_TIMEOUT_MS, IN_CONTAINER_GRACE_S, DISK_WATCH_MS, OUTPUT_TAIL_BYTES, COPY_BACK_MAX_BYTES, COPY_BACK_MAX_ENTRIES, SCAN_MAX_ENTRIES, LOCKFILE_MAX_BYTES, defaultContainerExec, isNodeExe, GIT_VIEW_MOUNT, copyLines, NPMRC_HELD, HOLD_NPMRC, RESTORE_NPMRC, NPM_FETCH_ENV, SCRIPTS_SCRIPT, tail2, firstLine, lastLines, IGNORABLE, dropIgnorable, foldsCase;
|
|
52247
52359
|
var init_container_gate = __esm({
|
|
52248
52360
|
"src/factory/run/container-gate.ts"() {
|
|
52249
52361
|
"use strict";
|
|
52250
|
-
|
|
52362
|
+
import_node_child_process6 = require("node:child_process");
|
|
52251
52363
|
import_node_crypto6 = require("node:crypto");
|
|
52252
52364
|
import_node_fs14 = require("node:fs");
|
|
52253
52365
|
import_node_path15 = require("node:path");
|
|
@@ -52297,7 +52409,7 @@ var init_container_gate = __esm({
|
|
|
52297
52409
|
let hardKill;
|
|
52298
52410
|
let child;
|
|
52299
52411
|
try {
|
|
52300
|
-
child = (0,
|
|
52412
|
+
child = (0, import_node_child_process6.spawn)(bin, [...args], { stdio: ["ignore", "pipe", "pipe"], windowsHide: true, shell: false });
|
|
52301
52413
|
} catch (error2) {
|
|
52302
52414
|
done({ status: null, tail: "", overflow: false, timedOut: false, spawnError: error2 instanceof Error ? error2.message : String(error2) });
|
|
52303
52415
|
return;
|
|
@@ -56466,16 +56578,16 @@ function listLinux() {
|
|
|
56466
56578
|
}
|
|
56467
56579
|
return rows;
|
|
56468
56580
|
}
|
|
56469
|
-
var
|
|
56581
|
+
var import_node_child_process7, import_node_fs16, import_node_path17, import_node_util2, execFileAsync7, LANE_PROCS_QUERY_TIMEOUT_MS, KILL_DEADLINE_MS2, under3, WIN_QUERY, defaultLaneProcsDeps;
|
|
56470
56582
|
var init_lane_procs = __esm({
|
|
56471
56583
|
"src/factory/run/lane-procs.ts"() {
|
|
56472
56584
|
"use strict";
|
|
56473
|
-
|
|
56585
|
+
import_node_child_process7 = require("node:child_process");
|
|
56474
56586
|
import_node_fs16 = require("node:fs");
|
|
56475
56587
|
import_node_path17 = require("node:path");
|
|
56476
|
-
|
|
56588
|
+
import_node_util2 = require("node:util");
|
|
56477
56589
|
init_process_utils();
|
|
56478
|
-
|
|
56590
|
+
execFileAsync7 = (0, import_node_util2.promisify)(import_node_child_process7.execFile);
|
|
56479
56591
|
LANE_PROCS_QUERY_TIMEOUT_MS = 1e4;
|
|
56480
56592
|
KILL_DEADLINE_MS2 = 1e4;
|
|
56481
56593
|
under3 = (dir, path15) => {
|
|
@@ -56489,10 +56601,10 @@ var init_lane_procs = __esm({
|
|
|
56489
56601
|
list: async () => {
|
|
56490
56602
|
if (process.platform === "linux") return listLinux();
|
|
56491
56603
|
if (process.platform === "win32") {
|
|
56492
|
-
const { stdout: stdout2 } = await
|
|
56604
|
+
const { stdout: stdout2 } = await execFileAsync7("powershell", ["-NoProfile", "-NonInteractive", "-Command", WIN_QUERY], { timeout: LANE_PROCS_QUERY_TIMEOUT_MS, windowsHide: true, maxBuffer: 16 * 1024 * 1024 });
|
|
56493
56605
|
return parseWindowsRows(stdout2);
|
|
56494
56606
|
}
|
|
56495
|
-
const { stdout } = await
|
|
56607
|
+
const { stdout } = await execFileAsync7("ps", ["-A", "-o", "pid=,ppid=,lstart="], { timeout: LANE_PROCS_QUERY_TIMEOUT_MS, env: { ...process.env, LC_ALL: "C" }, maxBuffer: 16 * 1024 * 1024 });
|
|
56496
56608
|
return parsePsRows(stdout);
|
|
56497
56609
|
},
|
|
56498
56610
|
identity: (pid) => getProcessStartIdentity(pid, Date.now() + KILL_DEADLINE_MS2),
|