looply-cli 0.0.0-stage → 0.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/LICENSE +21 -0
- package/README.md +137 -3
- package/dist/.src-hash +1 -0
- package/dist/acceptance-observe.d.ts +108 -0
- package/dist/acceptance-observe.d.ts.map +1 -0
- package/dist/acceptance-observe.js +152 -0
- package/dist/acceptance-observe.js.map +1 -0
- package/dist/agent-cmd.d.ts +131 -0
- package/dist/agent-cmd.d.ts.map +1 -0
- package/dist/agent-cmd.js +154 -0
- package/dist/agent-cmd.js.map +1 -0
- package/dist/agent-contained.d.ts +114 -0
- package/dist/agent-contained.d.ts.map +1 -0
- package/dist/agent-contained.js +292 -0
- package/dist/agent-contained.js.map +1 -0
- package/dist/agent-driver.d.ts +130 -0
- package/dist/agent-driver.d.ts.map +1 -0
- package/dist/agent-driver.js +170 -0
- package/dist/agent-driver.js.map +1 -0
- package/dist/agent-envelope.d.ts +94 -0
- package/dist/agent-envelope.d.ts.map +1 -0
- package/dist/agent-envelope.js +214 -0
- package/dist/agent-envelope.js.map +1 -0
- package/dist/agent-exec.d.ts +182 -0
- package/dist/agent-exec.d.ts.map +1 -0
- package/dist/agent-exec.js +125 -0
- package/dist/agent-exec.js.map +1 -0
- package/dist/agent-runtime.d.ts +23 -0
- package/dist/agent-runtime.d.ts.map +1 -0
- package/dist/agent-runtime.js +143 -0
- package/dist/agent-runtime.js.map +1 -0
- package/dist/approval-gate-read.d.ts +66 -0
- package/dist/approval-gate-read.d.ts.map +1 -0
- package/dist/approval-gate-read.js +138 -0
- package/dist/approval-gate-read.js.map +1 -0
- package/dist/approval-resolution.d.ts +87 -0
- package/dist/approval-resolution.d.ts.map +1 -0
- package/dist/approval-resolution.js +100 -0
- package/dist/approval-resolution.js.map +1 -0
- package/dist/approval-resumes.d.ts +102 -0
- package/dist/approval-resumes.d.ts.map +1 -0
- package/dist/approval-resumes.js +167 -0
- package/dist/approval-resumes.js.map +1 -0
- package/dist/ask-brain.d.ts +167 -0
- package/dist/ask-brain.d.ts.map +1 -0
- package/dist/ask-brain.js +355 -0
- package/dist/ask-brain.js.map +1 -0
- package/dist/autonomy-authority.d.ts +80 -0
- package/dist/autonomy-authority.d.ts.map +1 -0
- package/dist/autonomy-authority.js +82 -0
- package/dist/autonomy-authority.js.map +1 -0
- package/dist/autonomy-controller.d.ts +321 -0
- package/dist/autonomy-controller.d.ts.map +1 -0
- package/dist/autonomy-controller.js +517 -0
- package/dist/autonomy-controller.js.map +1 -0
- package/dist/autonomy-store.d.ts +327 -0
- package/dist/autonomy-store.d.ts.map +1 -0
- package/dist/autonomy-store.js +581 -0
- package/dist/autonomy-store.js.map +1 -0
- package/dist/autonomy-tick.d.ts +257 -0
- package/dist/autonomy-tick.d.ts.map +1 -0
- package/dist/autonomy-tick.js +616 -0
- package/dist/autonomy-tick.js.map +1 -0
- package/dist/bin.d.ts +3 -0
- package/dist/bin.d.ts.map +1 -0
- package/dist/bin.js +2727 -0
- package/dist/bin.js.map +1 -0
- package/dist/brain-advice.d.ts +21 -0
- package/dist/brain-advice.d.ts.map +1 -0
- package/dist/brain-advice.js +51 -0
- package/dist/brain-advice.js.map +1 -0
- package/dist/candidate-replay-runtime.d.ts +125 -0
- package/dist/candidate-replay-runtime.d.ts.map +1 -0
- package/dist/candidate-replay-runtime.js +188 -0
- package/dist/candidate-replay-runtime.js.map +1 -0
- package/dist/checkout-carry.d.ts +76 -0
- package/dist/checkout-carry.d.ts.map +1 -0
- package/dist/checkout-carry.js +125 -0
- package/dist/checkout-carry.js.map +1 -0
- package/dist/citation-readers.d.ts +26 -0
- package/dist/citation-readers.d.ts.map +1 -0
- package/dist/citation-readers.js +102 -0
- package/dist/citation-readers.js.map +1 -0
- package/dist/command-receipts.d.ts +79 -0
- package/dist/command-receipts.d.ts.map +1 -0
- package/dist/command-receipts.js +143 -0
- package/dist/command-receipts.js.map +1 -0
- package/dist/command-runner.d.ts +32 -0
- package/dist/command-runner.d.ts.map +1 -0
- package/dist/command-runner.js +108 -0
- package/dist/command-runner.js.map +1 -0
- package/dist/compatible-sets.d.ts +67 -0
- package/dist/compatible-sets.d.ts.map +1 -0
- package/dist/compatible-sets.js +81 -0
- package/dist/compatible-sets.js.map +1 -0
- package/dist/compile-check.d.ts +31 -0
- package/dist/compile-check.d.ts.map +1 -0
- package/dist/compile-check.js +34 -0
- package/dist/compile-check.js.map +1 -0
- package/dist/compile-store.d.ts +16 -0
- package/dist/compile-store.d.ts.map +1 -0
- package/dist/compile-store.js +21 -0
- package/dist/compile-store.js.map +1 -0
- package/dist/completion.d.ts +106 -0
- package/dist/completion.d.ts.map +1 -0
- package/dist/completion.js +131 -0
- package/dist/completion.js.map +1 -0
- package/dist/config.d.ts +549 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +763 -0
- package/dist/config.js.map +1 -0
- package/dist/control-file.d.ts +142 -0
- package/dist/control-file.d.ts.map +1 -0
- package/dist/control-file.js +144 -0
- package/dist/control-file.js.map +1 -0
- package/dist/coordinator-state.d.ts +131 -0
- package/dist/coordinator-state.d.ts.map +1 -0
- package/dist/coordinator-state.js +380 -0
- package/dist/coordinator-state.js.map +1 -0
- package/dist/coordinator.d.ts +95 -0
- package/dist/coordinator.d.ts.map +1 -0
- package/dist/coordinator.js +97 -0
- package/dist/coordinator.js.map +1 -0
- package/dist/cursor-store.d.ts +53 -0
- package/dist/cursor-store.d.ts.map +1 -0
- package/dist/cursor-store.js +98 -0
- package/dist/cursor-store.js.map +1 -0
- package/dist/daemon-cmd.d.ts +239 -0
- package/dist/daemon-cmd.d.ts.map +1 -0
- package/dist/daemon-cmd.js +1751 -0
- package/dist/daemon-cmd.js.map +1 -0
- package/dist/daemon-lock.d.ts +140 -0
- package/dist/daemon-lock.d.ts.map +1 -0
- package/dist/daemon-lock.js +352 -0
- package/dist/daemon-lock.js.map +1 -0
- package/dist/daemon-recovery.d.ts +78 -0
- package/dist/daemon-recovery.d.ts.map +1 -0
- package/dist/daemon-recovery.js +161 -0
- package/dist/daemon-recovery.js.map +1 -0
- package/dist/daemon.d.ts +368 -0
- package/dist/daemon.d.ts.map +1 -0
- package/dist/daemon.js +601 -0
- package/dist/daemon.js.map +1 -0
- package/dist/declared-response-shape.d.ts +93 -0
- package/dist/declared-response-shape.d.ts.map +1 -0
- package/dist/declared-response-shape.js +200 -0
- package/dist/declared-response-shape.js.map +1 -0
- package/dist/declared-surfaces.d.ts +16 -0
- package/dist/declared-surfaces.d.ts.map +1 -0
- package/dist/declared-surfaces.js +19 -0
- package/dist/declared-surfaces.js.map +1 -0
- package/dist/depends-review.d.ts +113 -0
- package/dist/depends-review.d.ts.map +1 -0
- package/dist/depends-review.js +110 -0
- package/dist/depends-review.js.map +1 -0
- package/dist/doctor.d.ts +91 -0
- package/dist/doctor.d.ts.map +1 -0
- package/dist/doctor.js +71 -0
- package/dist/doctor.js.map +1 -0
- package/dist/edge-approval.d.ts +105 -0
- package/dist/edge-approval.d.ts.map +1 -0
- package/dist/edge-approval.js +100 -0
- package/dist/edge-approval.js.map +1 -0
- package/dist/evidence-cache.d.ts +45 -0
- package/dist/evidence-cache.d.ts.map +1 -0
- package/dist/evidence-cache.js +90 -0
- package/dist/evidence-cache.js.map +1 -0
- package/dist/evidence-cmd.d.ts +133 -0
- package/dist/evidence-cmd.d.ts.map +1 -0
- package/dist/evidence-cmd.js +347 -0
- package/dist/evidence-cmd.js.map +1 -0
- package/dist/evidence-facts.d.ts +40 -0
- package/dist/evidence-facts.d.ts.map +1 -0
- package/dist/evidence-facts.js +114 -0
- package/dist/evidence-facts.js.map +1 -0
- package/dist/exclusive-lock.d.ts +52 -0
- package/dist/exclusive-lock.d.ts.map +1 -0
- package/dist/exclusive-lock.js +150 -0
- package/dist/exclusive-lock.js.map +1 -0
- package/dist/exec-domains.d.ts +140 -0
- package/dist/exec-domains.d.ts.map +1 -0
- package/dist/exec-domains.js +287 -0
- package/dist/exec-domains.js.map +1 -0
- package/dist/exemption-store.d.ts +197 -0
- package/dist/exemption-store.d.ts.map +1 -0
- package/dist/exemption-store.js +266 -0
- package/dist/exemption-store.js.map +1 -0
- package/dist/explicit-start-gate.d.ts +96 -0
- package/dist/explicit-start-gate.d.ts.map +1 -0
- package/dist/explicit-start-gate.js +103 -0
- package/dist/explicit-start-gate.js.map +1 -0
- package/dist/fs-trouble.d.ts +70 -0
- package/dist/fs-trouble.d.ts.map +1 -0
- package/dist/fs-trouble.js +98 -0
- package/dist/fs-trouble.js.map +1 -0
- package/dist/gate.d.ts +278 -0
- package/dist/gate.d.ts.map +1 -0
- package/dist/gate.js +278 -0
- package/dist/gate.js.map +1 -0
- package/dist/git-driver.d.ts +519 -0
- package/dist/git-driver.d.ts.map +1 -0
- package/dist/git-driver.js +900 -0
- package/dist/git-driver.js.map +1 -0
- package/dist/git-push-executor.d.ts +41 -0
- package/dist/git-push-executor.d.ts.map +1 -0
- package/dist/git-push-executor.js +142 -0
- package/dist/git-push-executor.js.map +1 -0
- package/dist/glob.d.ts +26 -0
- package/dist/glob.d.ts.map +1 -0
- package/dist/glob.js +93 -0
- package/dist/glob.js.map +1 -0
- package/dist/goal-adaptive.d.ts +295 -0
- package/dist/goal-adaptive.d.ts.map +1 -0
- package/dist/goal-adaptive.js +393 -0
- package/dist/goal-adaptive.js.map +1 -0
- package/dist/goal-compile.d.ts +342 -0
- package/dist/goal-compile.d.ts.map +1 -0
- package/dist/goal-compile.js +444 -0
- package/dist/goal-compile.js.map +1 -0
- package/dist/goal-depends-executor.d.ts +55 -0
- package/dist/goal-depends-executor.d.ts.map +1 -0
- package/dist/goal-depends-executor.js +202 -0
- package/dist/goal-depends-executor.js.map +1 -0
- package/dist/goal-execution-evidence.d.ts +135 -0
- package/dist/goal-execution-evidence.d.ts.map +1 -0
- package/dist/goal-execution-evidence.js +159 -0
- package/dist/goal-execution-evidence.js.map +1 -0
- package/dist/goal-gap.d.ts +140 -0
- package/dist/goal-gap.d.ts.map +1 -0
- package/dist/goal-gap.js +197 -0
- package/dist/goal-gap.js.map +1 -0
- package/dist/goal-met-target.d.ts +98 -0
- package/dist/goal-met-target.d.ts.map +1 -0
- package/dist/goal-met-target.js +92 -0
- package/dist/goal-met-target.js.map +1 -0
- package/dist/goal-ownership.d.ts +416 -0
- package/dist/goal-ownership.d.ts.map +1 -0
- package/dist/goal-ownership.js +576 -0
- package/dist/goal-ownership.js.map +1 -0
- package/dist/goal-runs.d.ts +82 -0
- package/dist/goal-runs.d.ts.map +1 -0
- package/dist/goal-runs.js +120 -0
- package/dist/goal-runs.js.map +1 -0
- package/dist/goal-store.d.ts +146 -0
- package/dist/goal-store.d.ts.map +1 -0
- package/dist/goal-store.js +294 -0
- package/dist/goal-store.js.map +1 -0
- package/dist/goal-view.d.ts +156 -0
- package/dist/goal-view.d.ts.map +1 -0
- package/dist/goal-view.js +499 -0
- package/dist/goal-view.js.map +1 -0
- package/dist/governed-approvals.d.ts +152 -0
- package/dist/governed-approvals.d.ts.map +1 -0
- package/dist/governed-approvals.js +246 -0
- package/dist/governed-approvals.js.map +1 -0
- package/dist/governed-broker.d.ts +169 -0
- package/dist/governed-broker.d.ts.map +1 -0
- package/dist/governed-broker.js +196 -0
- package/dist/governed-broker.js.map +1 -0
- package/dist/governed-run.d.ts +220 -0
- package/dist/governed-run.d.ts.map +1 -0
- package/dist/governed-run.js +406 -0
- package/dist/governed-run.js.map +1 -0
- package/dist/grant-reconcile.d.ts +63 -0
- package/dist/grant-reconcile.d.ts.map +1 -0
- package/dist/grant-reconcile.js +121 -0
- package/dist/grant-reconcile.js.map +1 -0
- package/dist/index-for-head.d.ts +56 -0
- package/dist/index-for-head.d.ts.map +1 -0
- package/dist/index-for-head.js +103 -0
- package/dist/index-for-head.js.map +1 -0
- package/dist/index.d.ts +39 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +55 -0
- package/dist/index.js.map +1 -0
- package/dist/init-detect.d.ts +39 -0
- package/dist/init-detect.d.ts.map +1 -0
- package/dist/init-detect.js +188 -0
- package/dist/init-detect.js.map +1 -0
- package/dist/integration-deps.d.ts +62 -0
- package/dist/integration-deps.d.ts.map +1 -0
- package/dist/integration-deps.js +251 -0
- package/dist/integration-deps.js.map +1 -0
- package/dist/integration-runtime.d.ts +458 -0
- package/dist/integration-runtime.d.ts.map +1 -0
- package/dist/integration-runtime.js +681 -0
- package/dist/integration-runtime.js.map +1 -0
- package/dist/integration.d.ts +45 -0
- package/dist/integration.d.ts.map +1 -0
- package/dist/integration.js +87 -0
- package/dist/integration.js.map +1 -0
- package/dist/integrator.d.ts +84 -0
- package/dist/integrator.d.ts.map +1 -0
- package/dist/integrator.js +193 -0
- package/dist/integrator.js.map +1 -0
- package/dist/lane-claims.d.ts +174 -0
- package/dist/lane-claims.d.ts.map +1 -0
- package/dist/lane-claims.js +218 -0
- package/dist/lane-claims.js.map +1 -0
- package/dist/lane-coverage.d.ts +87 -0
- package/dist/lane-coverage.d.ts.map +1 -0
- package/dist/lane-coverage.js +129 -0
- package/dist/lane-coverage.js.map +1 -0
- package/dist/ledger-replay.d.ts +115 -0
- package/dist/ledger-replay.d.ts.map +1 -0
- package/dist/ledger-replay.js +155 -0
- package/dist/ledger-replay.js.map +1 -0
- package/dist/ledger-store.d.ts +68 -0
- package/dist/ledger-store.d.ts.map +1 -0
- package/dist/ledger-store.js +111 -0
- package/dist/ledger-store.js.map +1 -0
- package/dist/loop-safety-observer.d.ts +132 -0
- package/dist/loop-safety-observer.d.ts.map +1 -0
- package/dist/loop-safety-observer.js +76 -0
- package/dist/loop-safety-observer.js.map +1 -0
- package/dist/loop-safety-store.d.ts +339 -0
- package/dist/loop-safety-store.d.ts.map +1 -0
- package/dist/loop-safety-store.js +800 -0
- package/dist/loop-safety-store.js.map +1 -0
- package/dist/machine-store.d.ts +54 -0
- package/dist/machine-store.d.ts.map +1 -0
- package/dist/machine-store.js +149 -0
- package/dist/machine-store.js.map +1 -0
- package/dist/mcp-main.d.ts +2 -0
- package/dist/mcp-main.d.ts.map +1 -0
- package/dist/mcp-main.js +116 -0
- package/dist/mcp-main.js.map +1 -0
- package/dist/mcp-server.d.ts +72 -0
- package/dist/mcp-server.d.ts.map +1 -0
- package/dist/mcp-server.js +259 -0
- package/dist/mcp-server.js.map +1 -0
- package/dist/model-routing.d.ts +75 -0
- package/dist/model-routing.d.ts.map +1 -0
- package/dist/model-routing.js +108 -0
- package/dist/model-routing.js.map +1 -0
- package/dist/model-transport.d.ts +188 -0
- package/dist/model-transport.d.ts.map +1 -0
- package/dist/model-transport.js +625 -0
- package/dist/model-transport.js.map +1 -0
- package/dist/notify-cadence.d.ts +55 -0
- package/dist/notify-cadence.d.ts.map +1 -0
- package/dist/notify-cadence.js +68 -0
- package/dist/notify-cadence.js.map +1 -0
- package/dist/notify-channel.d.ts +69 -0
- package/dist/notify-channel.d.ts.map +1 -0
- package/dist/notify-channel.js +151 -0
- package/dist/notify-channel.js.map +1 -0
- package/dist/notify.d.ts +71 -0
- package/dist/notify.d.ts.map +1 -0
- package/dist/notify.js +125 -0
- package/dist/notify.js.map +1 -0
- package/dist/observation-inventory.d.ts +65 -0
- package/dist/observation-inventory.d.ts.map +1 -0
- package/dist/observation-inventory.js +139 -0
- package/dist/observation-inventory.js.map +1 -0
- package/dist/owned-children.d.ts +45 -0
- package/dist/owned-children.d.ts.map +1 -0
- package/dist/owned-children.js +64 -0
- package/dist/owned-children.js.map +1 -0
- package/dist/packet-for-goal.d.ts +19 -0
- package/dist/packet-for-goal.d.ts.map +1 -0
- package/dist/packet-for-goal.js +32 -0
- package/dist/packet-for-goal.js.map +1 -0
- package/dist/pair-cmd.d.ts +85 -0
- package/dist/pair-cmd.d.ts.map +1 -0
- package/dist/pair-cmd.js +205 -0
- package/dist/pair-cmd.js.map +1 -0
- package/dist/partial-asker.d.ts +96 -0
- package/dist/partial-asker.d.ts.map +1 -0
- package/dist/partial-asker.js +117 -0
- package/dist/partial-asker.js.map +1 -0
- package/dist/pdf-text-lines.d.ts +17 -0
- package/dist/pdf-text-lines.d.ts.map +1 -0
- package/dist/pdf-text-lines.js +70 -0
- package/dist/pdf-text-lines.js.map +1 -0
- package/dist/pdf-text-worker.d.ts +2 -0
- package/dist/pdf-text-worker.d.ts.map +1 -0
- package/dist/pdf-text-worker.js +81 -0
- package/dist/pdf-text-worker.js.map +1 -0
- package/dist/pdf-text.d.ts +56 -0
- package/dist/pdf-text.d.ts.map +1 -0
- package/dist/pdf-text.js +64 -0
- package/dist/pdf-text.js.map +1 -0
- package/dist/pending-action.d.ts +154 -0
- package/dist/pending-action.d.ts.map +1 -0
- package/dist/pending-action.js +148 -0
- package/dist/pending-action.js.map +1 -0
- package/dist/preemptor.d.ts +40 -0
- package/dist/preemptor.d.ts.map +1 -0
- package/dist/preemptor.js +49 -0
- package/dist/preemptor.js.map +1 -0
- package/dist/programme-mode.d.ts +29 -0
- package/dist/programme-mode.d.ts.map +1 -0
- package/dist/programme-mode.js +50 -0
- package/dist/programme-mode.js.map +1 -0
- package/dist/progress-view.d.ts +14 -0
- package/dist/progress-view.d.ts.map +1 -0
- package/dist/progress-view.js +114 -0
- package/dist/progress-view.js.map +1 -0
- package/dist/project-graph-builder.d.ts +81 -0
- package/dist/project-graph-builder.d.ts.map +1 -0
- package/dist/project-graph-builder.js +246 -0
- package/dist/project-graph-builder.js.map +1 -0
- package/dist/project-graph-runtime.d.ts +86 -0
- package/dist/project-graph-runtime.d.ts.map +1 -0
- package/dist/project-graph-runtime.js +112 -0
- package/dist/project-graph-runtime.js.map +1 -0
- package/dist/project-index-builder.d.ts +96 -0
- package/dist/project-index-builder.d.ts.map +1 -0
- package/dist/project-index-builder.js +298 -0
- package/dist/project-index-builder.js.map +1 -0
- package/dist/project-index-facts.d.ts +51 -0
- package/dist/project-index-facts.d.ts.map +1 -0
- package/dist/project-index-facts.js +117 -0
- package/dist/project-index-facts.js.map +1 -0
- package/dist/project-index-store.d.ts +97 -0
- package/dist/project-index-store.d.ts.map +1 -0
- package/dist/project-index-store.js +140 -0
- package/dist/project-index-store.js.map +1 -0
- package/dist/project-memory-store.d.ts +127 -0
- package/dist/project-memory-store.d.ts.map +1 -0
- package/dist/project-memory-store.js +302 -0
- package/dist/project-memory-store.js.map +1 -0
- package/dist/proposal-store.d.ts +14 -0
- package/dist/proposal-store.d.ts.map +1 -0
- package/dist/proposal-store.js +19 -0
- package/dist/proposal-store.js.map +1 -0
- package/dist/prover.d.ts +80 -0
- package/dist/prover.d.ts.map +1 -0
- package/dist/prover.js +137 -0
- package/dist/prover.js.map +1 -0
- package/dist/provider-identity-store.d.ts +34 -0
- package/dist/provider-identity-store.d.ts.map +1 -0
- package/dist/provider-identity-store.js +72 -0
- package/dist/provider-identity-store.js.map +1 -0
- package/dist/provider-identity.d.ts +104 -0
- package/dist/provider-identity.d.ts.map +1 -0
- package/dist/provider-identity.js +167 -0
- package/dist/provider-identity.js.map +1 -0
- package/dist/provider-limit.d.ts +79 -0
- package/dist/provider-limit.d.ts.map +1 -0
- package/dist/provider-limit.js +148 -0
- package/dist/provider-limit.js.map +1 -0
- package/dist/provider-preflight.d.ts +171 -0
- package/dist/provider-preflight.d.ts.map +1 -0
- package/dist/provider-preflight.js +395 -0
- package/dist/provider-preflight.js.map +1 -0
- package/dist/provider-state.d.ts +120 -0
- package/dist/provider-state.d.ts.map +1 -0
- package/dist/provider-state.js +182 -0
- package/dist/provider-state.js.map +1 -0
- package/dist/providers.d.ts +132 -0
- package/dist/providers.d.ts.map +1 -0
- package/dist/providers.js +161 -0
- package/dist/providers.js.map +1 -0
- package/dist/publication-recorder.d.ts +117 -0
- package/dist/publication-recorder.d.ts.map +1 -0
- package/dist/publication-recorder.js +124 -0
- package/dist/publication-recorder.js.map +1 -0
- package/dist/pursuit-delivery.d.ts +24 -0
- package/dist/pursuit-delivery.d.ts.map +1 -0
- package/dist/pursuit-delivery.js +38 -0
- package/dist/pursuit-delivery.js.map +1 -0
- package/dist/queue-store.d.ts +132 -0
- package/dist/queue-store.d.ts.map +1 -0
- package/dist/queue-store.js +185 -0
- package/dist/queue-store.js.map +1 -0
- package/dist/queue-summary.d.ts +14 -0
- package/dist/queue-summary.d.ts.map +1 -0
- package/dist/queue-summary.js +82 -0
- package/dist/queue-summary.js.map +1 -0
- package/dist/queue-view.d.ts +20 -0
- package/dist/queue-view.d.ts.map +1 -0
- package/dist/queue-view.js +163 -0
- package/dist/queue-view.js.map +1 -0
- package/dist/queue-write-lease.d.ts +106 -0
- package/dist/queue-write-lease.d.ts.map +1 -0
- package/dist/queue-write-lease.js +282 -0
- package/dist/queue-write-lease.js.map +1 -0
- package/dist/rails-home.d.ts +162 -0
- package/dist/rails-home.d.ts.map +1 -0
- package/dist/rails-home.js +452 -0
- package/dist/rails-home.js.map +1 -0
- package/dist/rails-migrations.d.ts +75 -0
- package/dist/rails-migrations.d.ts.map +1 -0
- package/dist/rails-migrations.js +199 -0
- package/dist/rails-migrations.js.map +1 -0
- package/dist/rails-stores.d.ts +49 -0
- package/dist/rails-stores.d.ts.map +1 -0
- package/dist/rails-stores.js +100 -0
- package/dist/rails-stores.js.map +1 -0
- package/dist/reaper.d.ts +69 -0
- package/dist/reaper.d.ts.map +1 -0
- package/dist/reaper.js +152 -0
- package/dist/reaper.js.map +1 -0
- package/dist/record-store.d.ts +36 -0
- package/dist/record-store.d.ts.map +1 -0
- package/dist/record-store.js +78 -0
- package/dist/record-store.js.map +1 -0
- package/dist/recovery-io.d.ts +50 -0
- package/dist/recovery-io.d.ts.map +1 -0
- package/dist/recovery-io.js +122 -0
- package/dist/recovery-io.js.map +1 -0
- package/dist/recovery.d.ts +146 -0
- package/dist/recovery.d.ts.map +1 -0
- package/dist/recovery.js +110 -0
- package/dist/recovery.js.map +1 -0
- package/dist/redraw.d.ts +34 -0
- package/dist/redraw.d.ts.map +1 -0
- package/dist/redraw.js +62 -0
- package/dist/redraw.js.map +1 -0
- package/dist/rejected-evidence.d.ts +255 -0
- package/dist/rejected-evidence.d.ts.map +1 -0
- package/dist/rejected-evidence.js +324 -0
- package/dist/rejected-evidence.js.map +1 -0
- package/dist/report-cmd.d.ts +32 -0
- package/dist/report-cmd.d.ts.map +1 -0
- package/dist/report-cmd.js +201 -0
- package/dist/report-cmd.js.map +1 -0
- package/dist/repos-cmd.d.ts +80 -0
- package/dist/repos-cmd.d.ts.map +1 -0
- package/dist/repos-cmd.js +240 -0
- package/dist/repos-cmd.js.map +1 -0
- package/dist/request-body-shape.d.ts +93 -0
- package/dist/request-body-shape.d.ts.map +1 -0
- package/dist/request-body-shape.js +407 -0
- package/dist/request-body-shape.js.map +1 -0
- package/dist/requirement-claims.d.ts +89 -0
- package/dist/requirement-claims.d.ts.map +1 -0
- package/dist/requirement-claims.js +92 -0
- package/dist/requirement-claims.js.map +1 -0
- package/dist/retention-apply-runtime.d.ts +105 -0
- package/dist/retention-apply-runtime.d.ts.map +1 -0
- package/dist/retention-apply-runtime.js +269 -0
- package/dist/retention-apply-runtime.js.map +1 -0
- package/dist/reverify.d.ts +41 -0
- package/dist/reverify.d.ts.map +1 -0
- package/dist/reverify.js +69 -0
- package/dist/reverify.js.map +1 -0
- package/dist/round-records.d.ts +65 -0
- package/dist/round-records.d.ts.map +1 -0
- package/dist/round-records.js +61 -0
- package/dist/round-records.js.map +1 -0
- package/dist/round-runner.d.ts +924 -0
- package/dist/round-runner.d.ts.map +1 -0
- package/dist/round-runner.js +1693 -0
- package/dist/round-runner.js.map +1 -0
- package/dist/run-approval.d.ts +180 -0
- package/dist/run-approval.d.ts.map +1 -0
- package/dist/run-approval.js +199 -0
- package/dist/run-approval.js.map +1 -0
- package/dist/run-cmd.d.ts +359 -0
- package/dist/run-cmd.d.ts.map +1 -0
- package/dist/run-cmd.js +4418 -0
- package/dist/run-cmd.js.map +1 -0
- package/dist/run-delivery.d.ts +71 -0
- package/dist/run-delivery.d.ts.map +1 -0
- package/dist/run-delivery.js +104 -0
- package/dist/run-delivery.js.map +1 -0
- package/dist/run-ended.d.ts +75 -0
- package/dist/run-ended.d.ts.map +1 -0
- package/dist/run-ended.js +27 -0
- package/dist/run-ended.js.map +1 -0
- package/dist/run-ending-locator.d.ts +125 -0
- package/dist/run-ending-locator.d.ts.map +1 -0
- package/dist/run-ending-locator.js +133 -0
- package/dist/run-ending-locator.js.map +1 -0
- package/dist/run-launcher.d.ts +459 -0
- package/dist/run-launcher.d.ts.map +1 -0
- package/dist/run-launcher.js +652 -0
- package/dist/run-launcher.js.map +1 -0
- package/dist/run-lease.d.ts +208 -0
- package/dist/run-lease.d.ts.map +1 -0
- package/dist/run-lease.js +301 -0
- package/dist/run-lease.js.map +1 -0
- package/dist/run-refusal-marks.d.ts +189 -0
- package/dist/run-refusal-marks.d.ts.map +1 -0
- package/dist/run-refusal-marks.js +249 -0
- package/dist/run-refusal-marks.js.map +1 -0
- package/dist/run-start-marks.d.ts +153 -0
- package/dist/run-start-marks.d.ts.map +1 -0
- package/dist/run-start-marks.js +269 -0
- package/dist/run-start-marks.js.map +1 -0
- package/dist/scan-cmd.d.ts +14 -0
- package/dist/scan-cmd.d.ts.map +1 -0
- package/dist/scan-cmd.js +270 -0
- package/dist/scan-cmd.js.map +1 -0
- package/dist/scan-events.d.ts +50 -0
- package/dist/scan-events.d.ts.map +1 -0
- package/dist/scan-events.js +91 -0
- package/dist/scan-events.js.map +1 -0
- package/dist/scan.d.ts +191 -0
- package/dist/scan.d.ts.map +1 -0
- package/dist/scan.js +417 -0
- package/dist/scan.js.map +1 -0
- package/dist/scope-rule.d.ts +148 -0
- package/dist/scope-rule.d.ts.map +1 -0
- package/dist/scope-rule.js +121 -0
- package/dist/scope-rule.js.map +1 -0
- package/dist/self-repo-id.d.ts +18 -0
- package/dist/self-repo-id.d.ts.map +1 -0
- package/dist/self-repo-id.js +70 -0
- package/dist/self-repo-id.js.map +1 -0
- package/dist/serve-cmd.d.ts +115 -0
- package/dist/serve-cmd.d.ts.map +1 -0
- package/dist/serve-cmd.js +505 -0
- package/dist/serve-cmd.js.map +1 -0
- package/dist/serve.d.ts +167 -0
- package/dist/serve.d.ts.map +1 -0
- package/dist/serve.js +336 -0
- package/dist/serve.js.map +1 -0
- package/dist/server-client.d.ts +766 -0
- package/dist/server-client.d.ts.map +1 -0
- package/dist/server-client.js +475 -0
- package/dist/server-client.js.map +1 -0
- package/dist/session-adapter-runtime.d.ts +195 -0
- package/dist/session-adapter-runtime.d.ts.map +1 -0
- package/dist/session-adapter-runtime.js +373 -0
- package/dist/session-adapter-runtime.js.map +1 -0
- package/dist/session-checkpoint-runtime.d.ts +62 -0
- package/dist/session-checkpoint-runtime.d.ts.map +1 -0
- package/dist/session-checkpoint-runtime.js +268 -0
- package/dist/session-checkpoint-runtime.js.map +1 -0
- package/dist/session-control-transport.d.ts +106 -0
- package/dist/session-control-transport.d.ts.map +1 -0
- package/dist/session-control-transport.js +232 -0
- package/dist/session-control-transport.js.map +1 -0
- package/dist/session-observation-store.d.ts +98 -0
- package/dist/session-observation-store.d.ts.map +1 -0
- package/dist/session-observation-store.js +155 -0
- package/dist/session-observation-store.js.map +1 -0
- package/dist/session-observe-runtime.d.ts +123 -0
- package/dist/session-observe-runtime.d.ts.map +1 -0
- package/dist/session-observe-runtime.js +317 -0
- package/dist/session-observe-runtime.js.map +1 -0
- package/dist/session-store.d.ts +98 -0
- package/dist/session-store.d.ts.map +1 -0
- package/dist/session-store.js +116 -0
- package/dist/session-store.js.map +1 -0
- package/dist/sessions-cmd.d.ts +202 -0
- package/dist/sessions-cmd.d.ts.map +1 -0
- package/dist/sessions-cmd.js +609 -0
- package/dist/sessions-cmd.js.map +1 -0
- package/dist/settings-overlay.d.ts +53 -0
- package/dist/settings-overlay.d.ts.map +1 -0
- package/dist/settings-overlay.js +175 -0
- package/dist/settings-overlay.js.map +1 -0
- package/dist/setup-prompt.d.ts +34 -0
- package/dist/setup-prompt.d.ts.map +1 -0
- package/dist/setup-prompt.js +92 -0
- package/dist/setup-prompt.js.map +1 -0
- package/dist/setup.d.ts +103 -0
- package/dist/setup.d.ts.map +1 -0
- package/dist/setup.js +283 -0
- package/dist/setup.js.map +1 -0
- package/dist/shared-grants.d.ts +164 -0
- package/dist/shared-grants.d.ts.map +1 -0
- package/dist/shared-grants.js +242 -0
- package/dist/shared-grants.js.map +1 -0
- package/dist/signals.d.ts +55 -0
- package/dist/signals.d.ts.map +1 -0
- package/dist/signals.js +85 -0
- package/dist/signals.js.map +1 -0
- package/dist/source-cmd.d.ts +201 -0
- package/dist/source-cmd.d.ts.map +1 -0
- package/dist/source-cmd.js +684 -0
- package/dist/source-cmd.js.map +1 -0
- package/dist/source-verdict.d.ts +99 -0
- package/dist/source-verdict.d.ts.map +1 -0
- package/dist/source-verdict.js +182 -0
- package/dist/source-verdict.js.map +1 -0
- package/dist/spend-ledger.d.ts +350 -0
- package/dist/spend-ledger.d.ts.map +1 -0
- package/dist/spend-ledger.js +546 -0
- package/dist/spend-ledger.js.map +1 -0
- package/dist/stale-run-sweep.d.ts +79 -0
- package/dist/stale-run-sweep.d.ts.map +1 -0
- package/dist/stale-run-sweep.js +116 -0
- package/dist/stale-run-sweep.js.map +1 -0
- package/dist/start-attempts.d.ts +385 -0
- package/dist/start-attempts.d.ts.map +1 -0
- package/dist/start-attempts.js +613 -0
- package/dist/start-attempts.js.map +1 -0
- package/dist/status-cmd.d.ts +28 -0
- package/dist/status-cmd.d.ts.map +1 -0
- package/dist/status-cmd.js +116 -0
- package/dist/status-cmd.js.map +1 -0
- package/dist/stop-follow-up.d.ts +107 -0
- package/dist/stop-follow-up.d.ts.map +1 -0
- package/dist/stop-follow-up.js +172 -0
- package/dist/stop-follow-up.js.map +1 -0
- package/dist/surface-lease.d.ts +118 -0
- package/dist/surface-lease.d.ts.map +1 -0
- package/dist/surface-lease.js +485 -0
- package/dist/surface-lease.js.map +1 -0
- package/dist/sync.d.ts +54 -0
- package/dist/sync.d.ts.map +1 -0
- package/dist/sync.js +93 -0
- package/dist/sync.js.map +1 -0
- package/dist/syncing-ledger.d.ts +45 -0
- package/dist/syncing-ledger.d.ts.map +1 -0
- package/dist/syncing-ledger.js +53 -0
- package/dist/syncing-ledger.js.map +1 -0
- package/dist/temp-fixtures.d.ts +68 -0
- package/dist/temp-fixtures.d.ts.map +1 -0
- package/dist/temp-fixtures.js +38 -0
- package/dist/temp-fixtures.js.map +1 -0
- package/dist/token-window.d.ts +84 -0
- package/dist/token-window.d.ts.map +1 -0
- package/dist/token-window.js +143 -0
- package/dist/token-window.js.map +1 -0
- package/dist/tool-bridge.d.ts +177 -0
- package/dist/tool-bridge.d.ts.map +1 -0
- package/dist/tool-bridge.js +329 -0
- package/dist/tool-bridge.js.map +1 -0
- package/dist/tool-call-record.d.ts +197 -0
- package/dist/tool-call-record.d.ts.map +1 -0
- package/dist/tool-call-record.js +276 -0
- package/dist/tool-call-record.js.map +1 -0
- package/dist/tool-protocol.d.ts +135 -0
- package/dist/tool-protocol.d.ts.map +1 -0
- package/dist/tool-protocol.js +104 -0
- package/dist/tool-protocol.js.map +1 -0
- package/dist/tool-worker.d.ts +3 -0
- package/dist/tool-worker.d.ts.map +1 -0
- package/dist/tool-worker.js +478 -0
- package/dist/tool-worker.js.map +1 -0
- package/dist/toolchain-mirror.d.ts +86 -0
- package/dist/toolchain-mirror.d.ts.map +1 -0
- package/dist/toolchain-mirror.js +307 -0
- package/dist/toolchain-mirror.js.map +1 -0
- package/dist/trusted-git.d.ts +243 -0
- package/dist/trusted-git.d.ts.map +1 -0
- package/dist/trusted-git.js +920 -0
- package/dist/trusted-git.js.map +1 -0
- package/dist/ui.d.ts +76 -0
- package/dist/ui.d.ts.map +1 -0
- package/dist/ui.js +118 -0
- package/dist/ui.js.map +1 -0
- package/dist/untrusted-exec.d.ts +275 -0
- package/dist/untrusted-exec.d.ts.map +1 -0
- package/dist/untrusted-exec.js +479 -0
- package/dist/untrusted-exec.js.map +1 -0
- package/dist/untrusted-gate.d.ts +73 -0
- package/dist/untrusted-gate.d.ts.map +1 -0
- package/dist/untrusted-gate.js +226 -0
- package/dist/untrusted-gate.js.map +1 -0
- package/dist/uploader.d.ts +153 -0
- package/dist/uploader.d.ts.map +1 -0
- package/dist/uploader.js +204 -0
- package/dist/uploader.js.map +1 -0
- package/dist/verifier.d.ts +66 -0
- package/dist/verifier.d.ts.map +1 -0
- package/dist/verifier.js +170 -0
- package/dist/verifier.js.map +1 -0
- package/dist/verify-apply.d.ts +26 -0
- package/dist/verify-apply.d.ts.map +1 -0
- package/dist/verify-apply.js +36 -0
- package/dist/verify-apply.js.map +1 -0
- package/dist/verify-cmd.d.ts +44 -0
- package/dist/verify-cmd.d.ts.map +1 -0
- package/dist/verify-cmd.js +125 -0
- package/dist/verify-cmd.js.map +1 -0
- package/dist/verify-pass.d.ts +73 -0
- package/dist/verify-pass.d.ts.map +1 -0
- package/dist/verify-pass.js +103 -0
- package/dist/verify-pass.js.map +1 -0
- package/dist/welcome.d.ts +43 -0
- package/dist/welcome.d.ts.map +1 -0
- package/dist/welcome.js +116 -0
- package/dist/welcome.js.map +1 -0
- package/dist/workspace-provisioner.d.ts +65 -0
- package/dist/workspace-provisioner.d.ts.map +1 -0
- package/dist/workspace-provisioner.js +66 -0
- package/dist/workspace-provisioner.js.map +1 -0
- package/dist/workspace-quarantine.d.ts +64 -0
- package/dist/workspace-quarantine.d.ts.map +1 -0
- package/dist/workspace-quarantine.js +156 -0
- package/dist/workspace-quarantine.js.map +1 -0
- package/dist/workspace-residue-sweep.d.ts +113 -0
- package/dist/workspace-residue-sweep.d.ts.map +1 -0
- package/dist/workspace-residue-sweep.js +158 -0
- package/dist/workspace-residue-sweep.js.map +1 -0
- package/dist/workspace.d.ts +639 -0
- package/dist/workspace.d.ts.map +1 -0
- package/dist/workspace.js +2026 -0
- package/dist/workspace.js.map +1 -0
- package/package.json +52 -4
- package/win/CredProbe.cs +64 -0
- package/win/FakeClaude.cs +56 -0
- package/win/HandleProbe.cs +116 -0
- package/win/TokenProbe.cs +53 -0
- package/win/appcontainer.ps1 +500 -0
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AGENT_SCHEMA_VERSION = void 0;
|
|
4
|
+
exports.suggestion = suggestion;
|
|
5
|
+
exports.buildSnapshot = buildSnapshot;
|
|
6
|
+
exports.renderAgentJson = renderAgentJson;
|
|
7
|
+
exports.renderAgentText = renderAgentText;
|
|
8
|
+
/**
|
|
9
|
+
* `looply agent` — the machine-readable surface.
|
|
10
|
+
*
|
|
11
|
+
* Everything else in this CLI is written for a person: boxes, colour, a next
|
|
12
|
+
* step spelled out. This one is written for another program, and the two goals
|
|
13
|
+
* fight each other badly enough that mixing them produces output neither can
|
|
14
|
+
* use. So the split is explicit.
|
|
15
|
+
*
|
|
16
|
+
* Three promises, because a tool that consumes this has no way to ask:
|
|
17
|
+
*
|
|
18
|
+
* 1. `schemaVersion` changes when a field's meaning changes. A consumer can
|
|
19
|
+
* refuse to guess rather than silently misread.
|
|
20
|
+
* 2. Every field is either present or explicitly `null`. Nothing is omitted,
|
|
21
|
+
* so `undefined` never has to be told apart from "absent because false".
|
|
22
|
+
* 3. It exits 0 whenever it could answer at all, including "nothing is
|
|
23
|
+
* running". A non-zero exit means the question could not be answered —
|
|
24
|
+
* never that the answer was boring.
|
|
25
|
+
*/
|
|
26
|
+
exports.AGENT_SCHEMA_VERSION = 1;
|
|
27
|
+
const DEFAULT_STALE_MS = 3 * 60 * 1000;
|
|
28
|
+
const DEFAULT_LIMIT = 50;
|
|
29
|
+
/**
|
|
30
|
+
* What a caller should probably do next, as a stable token rather than prose.
|
|
31
|
+
*
|
|
32
|
+
* Deliberately not a sentence: a program branching on `"scan"` keeps working
|
|
33
|
+
* when the wording changes, and a program branching on English does not.
|
|
34
|
+
*/
|
|
35
|
+
function suggestion(input) {
|
|
36
|
+
if (!input.configured)
|
|
37
|
+
return 'init';
|
|
38
|
+
if (input.openQuestions > 0)
|
|
39
|
+
return 'answer-question';
|
|
40
|
+
if (input.live)
|
|
41
|
+
return 'wait';
|
|
42
|
+
if (input.ready === 0 && input.draft === 0)
|
|
43
|
+
return 'scan';
|
|
44
|
+
return 'run';
|
|
45
|
+
}
|
|
46
|
+
function buildSnapshot(input) {
|
|
47
|
+
const status = input.status;
|
|
48
|
+
const staleAfter = input.staleAfterMs ?? DEFAULT_STALE_MS;
|
|
49
|
+
const limit = input.limit ?? DEFAULT_LIMIT;
|
|
50
|
+
const ready = input.items.filter((i) => i.state === 'ready').length;
|
|
51
|
+
const draft = input.items.filter((i) => i.state === 'draft' || i.state === 'verifying').length;
|
|
52
|
+
const blocked = input.items.filter((i) => i.state === 'blocked').length;
|
|
53
|
+
const live = status?.live === true;
|
|
54
|
+
const lastEventAt = status?.lastEventAt ? Date.parse(status.lastEventAt) : null;
|
|
55
|
+
return {
|
|
56
|
+
schemaVersion: exports.AGENT_SCHEMA_VERSION,
|
|
57
|
+
cliVersion: input.cliVersion,
|
|
58
|
+
project: {
|
|
59
|
+
name: input.config?.project.name ?? 'unknown',
|
|
60
|
+
configured: input.config !== null,
|
|
61
|
+
id: input.config?.project.id ?? null,
|
|
62
|
+
},
|
|
63
|
+
machine: input.machine,
|
|
64
|
+
run: {
|
|
65
|
+
live,
|
|
66
|
+
id: status?.runId ?? null,
|
|
67
|
+
branch: status?.branch ?? null,
|
|
68
|
+
startedAt: status?.startedAt ?? null,
|
|
69
|
+
endedAt: status?.endedAt ?? null,
|
|
70
|
+
stopReason: status?.stopReason ?? null,
|
|
71
|
+
// Null rather than false when nothing has ever run: "not stale" and "no
|
|
72
|
+
// run to be stale" are different answers.
|
|
73
|
+
stale: status === null ? null : live && lastEventAt !== null ? input.now - lastEventAt > staleAfter : false,
|
|
74
|
+
},
|
|
75
|
+
round: status?.round
|
|
76
|
+
? {
|
|
77
|
+
n: status.round.n,
|
|
78
|
+
itemId: status.round.itemId,
|
|
79
|
+
title: status.round.title,
|
|
80
|
+
attempt: status.round.attempt,
|
|
81
|
+
phase: status.round.state,
|
|
82
|
+
checks: status.round.steps.map((s) => ({
|
|
83
|
+
name: s.step,
|
|
84
|
+
ok: s.ok,
|
|
85
|
+
skipped: s.skipped === true,
|
|
86
|
+
ms: s.ms,
|
|
87
|
+
})),
|
|
88
|
+
}
|
|
89
|
+
: null,
|
|
90
|
+
totals: status?.totals ?? { rounds: 0, committed: 0, discarded: 0, abandoned: 0 },
|
|
91
|
+
queue: {
|
|
92
|
+
ready,
|
|
93
|
+
draft,
|
|
94
|
+
blocked,
|
|
95
|
+
total: input.items.length,
|
|
96
|
+
items: input.items.slice(0, limit).map(toAgentItem),
|
|
97
|
+
},
|
|
98
|
+
questions: (status?.openQuestions ?? []).map((q) => ({
|
|
99
|
+
id: q.qId,
|
|
100
|
+
text: q.text,
|
|
101
|
+
default: q.default,
|
|
102
|
+
deadline: q.deadline,
|
|
103
|
+
})),
|
|
104
|
+
suggests: suggestion({
|
|
105
|
+
configured: input.config !== null,
|
|
106
|
+
live,
|
|
107
|
+
ready,
|
|
108
|
+
draft,
|
|
109
|
+
openQuestions: status?.openQuestions.length ?? 0,
|
|
110
|
+
}),
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
function toAgentItem(item) {
|
|
114
|
+
return {
|
|
115
|
+
id: item.id,
|
|
116
|
+
title: item.title,
|
|
117
|
+
tag: item.tag,
|
|
118
|
+
state: item.state,
|
|
119
|
+
attempts: item.attempts,
|
|
120
|
+
lastFailure: item.lastFailure ?? null,
|
|
121
|
+
evidence: item.evidence.map((e) => ({ path: e.path, line: e.line ?? null })),
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
/** Stable two-space JSON — diffable, and readable when a human ends up reading it. */
|
|
125
|
+
function renderAgentJson(snapshot) {
|
|
126
|
+
return `${JSON.stringify(snapshot, null, 2)}\n`;
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* The same snapshot as lines of `key=value`.
|
|
130
|
+
*
|
|
131
|
+
* For shell callers, where reaching for `jq` to learn whether a run is going is
|
|
132
|
+
* more ceremony than the question deserves.
|
|
133
|
+
*/
|
|
134
|
+
function renderAgentText(s) {
|
|
135
|
+
const lines = [
|
|
136
|
+
`schema=${s.schemaVersion}`,
|
|
137
|
+
`project=${s.project.name}`,
|
|
138
|
+
`configured=${s.project.configured}`,
|
|
139
|
+
`paired=${s.machine.paired}`,
|
|
140
|
+
`run.live=${s.run.live}`,
|
|
141
|
+
`run.stale=${s.run.stale ?? 'null'}`,
|
|
142
|
+
`round=${s.round?.n ?? 'null'}`,
|
|
143
|
+
`phase=${s.round?.phase ?? 'null'}`,
|
|
144
|
+
`queue.ready=${s.queue.ready}`,
|
|
145
|
+
`queue.draft=${s.queue.draft}`,
|
|
146
|
+
`queue.blocked=${s.queue.blocked}`,
|
|
147
|
+
`questions=${s.questions.length}`,
|
|
148
|
+
`totals.committed=${s.totals.committed}`,
|
|
149
|
+
`totals.discarded=${s.totals.discarded}`,
|
|
150
|
+
`suggests=${s.suggests ?? 'null'}`,
|
|
151
|
+
];
|
|
152
|
+
return `${lines.join('\n')}\n`;
|
|
153
|
+
}
|
|
154
|
+
//# sourceMappingURL=agent-cmd.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-cmd.js","sourceRoot":"","sources":["../src/agent-cmd.ts"],"names":[],"mappings":";;;AAsFA,gCAYC;AAED,sCAqEC;AAeD,0CAEC;AAQD,0CAmBC;AAlND;;;;;;;;;;;;;;;;;GAiBG;AAEU,QAAA,oBAAoB,GAAG,CAAC,CAAC;AAuDtC,MAAM,gBAAgB,GAAG,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC;AACvC,MAAM,aAAa,GAAG,EAAE,CAAC;AAEzB;;;;;GAKG;AACH,SAAgB,UAAU,CAAC,KAM1B;IACC,IAAI,CAAC,KAAK,CAAC,UAAU;QAAE,OAAO,MAAM,CAAC;IACrC,IAAI,KAAK,CAAC,aAAa,GAAG,CAAC;QAAE,OAAO,iBAAiB,CAAC;IACtD,IAAI,KAAK,CAAC,IAAI;QAAE,OAAO,MAAM,CAAC;IAC9B,IAAI,KAAK,CAAC,KAAK,KAAK,CAAC,IAAI,KAAK,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ToolchainResult } from './toolchain-mirror';
|
|
4
|
+
import { type UntrustedExecutionBackend } from './untrusted-exec';
|
|
5
|
+
/**
|
|
6
|
+
* THE CODING AGENT, INSIDE THE BOUNDARY.
|
|
7
|
+
*
|
|
8
|
+
* The gate was contained first because it was easier to reason about. The agent
|
|
9
|
+
* is the one that matters: it is the process a model drives, and it ran as the
|
|
10
|
+
* daemon with `--dangerously-skip-permissions`, which is to say with a shell and
|
|
11
|
+
* the machine's whole environment.
|
|
12
|
+
*
|
|
13
|
+
* Two independent changes, and neither is sufficient alone.
|
|
14
|
+
*
|
|
15
|
+
* THE CAPABILITY SURFACE. The agent gets an explicit tool allowlist and no
|
|
16
|
+
* `Bash`. That is not a request — a tool absent from the set is a tool the CLI
|
|
17
|
+
* does not offer, so there is no shell to reach for. `--strict-mcp-config` with
|
|
18
|
+
* an empty server set means no MCP server configured anywhere on the machine
|
|
19
|
+
* becomes a capability by accident.
|
|
20
|
+
*
|
|
21
|
+
* THE CONTAINER. Even if the capability surface were wrong tomorrow, the agent
|
|
22
|
+
* runs in its own AppContainer: no machine token, no broker secret, no daemon
|
|
23
|
+
* profile, no `.git`, no `.looply/state`, no other project. The two layers are
|
|
24
|
+
* tested separately on purpose, because each is supposed to hold on its own.
|
|
25
|
+
*
|
|
26
|
+
* The agent keeps its OWN provider credential. Using the model is its job;
|
|
27
|
+
* speaking for the machine is not.
|
|
28
|
+
*/
|
|
29
|
+
/**
|
|
30
|
+
* What the agent may do, named without reference to any provider.
|
|
31
|
+
*
|
|
32
|
+
* The approval work that follows must never branch on a Claude flag, so the
|
|
33
|
+
* contract is written in terms of what an agent needs rather than how one CLI
|
|
34
|
+
* spells it.
|
|
35
|
+
*/
|
|
36
|
+
/**
|
|
37
|
+
* The built-in tools the agent is allowed.
|
|
38
|
+
*
|
|
39
|
+
* `Bash` is absent, and that is the whole point: the implementer's job is to
|
|
40
|
+
* edit files and report, and Looply runs the commands. `Task` is absent because
|
|
41
|
+
* a sub-agent is another process with its own tool set; `WebFetch` because
|
|
42
|
+
* fetching is not editing.
|
|
43
|
+
*/
|
|
44
|
+
export declare const AGENT_TOOLS: readonly string[];
|
|
45
|
+
/** An MCP configuration with no servers in it. */
|
|
46
|
+
export declare const EMPTY_MCP = "{\"mcpServers\":{}}";
|
|
47
|
+
export interface ClaudeInvocation {
|
|
48
|
+
executable: string;
|
|
49
|
+
argv: readonly string[];
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Where the installed Claude actually lives.
|
|
53
|
+
*
|
|
54
|
+
* `claude.cmd` is a shim that runs a native executable inside the npm package,
|
|
55
|
+
* so the package is what the container needs — and only the package. The
|
|
56
|
+
* directory the shim sits in also holds `eas` and `heroku` shims on this
|
|
57
|
+
* machine, and an agent that could resolve those would be an agent that could
|
|
58
|
+
* deploy.
|
|
59
|
+
*/
|
|
60
|
+
export declare function claudePackageDir(nodeExe?: string): string | null;
|
|
61
|
+
/**
|
|
62
|
+
* The command line for one agent turn.
|
|
63
|
+
*
|
|
64
|
+
* The prompt is NOT here. It goes on stdin, because it is many lines of
|
|
65
|
+
* instructions and a command line is neither a safe nor a large enough place
|
|
66
|
+
* for it — the previous implementation already knew that, and this keeps it
|
|
67
|
+
* true now that a container is involved.
|
|
68
|
+
*/
|
|
69
|
+
export declare function claudeInvocation(packageDir: string, format?: 'text' | 'json'): ClaudeInvocation;
|
|
70
|
+
/**
|
|
71
|
+
* Names `agent.env` may never forward, whatever a config asks for.
|
|
72
|
+
*
|
|
73
|
+
* `agent.env` exists so a provider key reaches the agent without being written
|
|
74
|
+
* into a file. It is a list of NAMES read from the daemon's own environment,
|
|
75
|
+
* which means a config that named `LOOPLY_MACHINE_SECRET` would have handed the
|
|
76
|
+
* agent the machine's identity — the one thing the whole containment arc exists
|
|
77
|
+
* to withhold. Nothing else in the chain would have objected.
|
|
78
|
+
*
|
|
79
|
+
* The reserved family is matched by PREFIX rather than by a list of the four
|
|
80
|
+
* names that exist today, so a credential added later is covered the day it is
|
|
81
|
+
* added rather than the day somebody remembers this file.
|
|
82
|
+
*/
|
|
83
|
+
export declare function isReservedEnvName(name: string): boolean;
|
|
84
|
+
/** A name that is not a name. `agent.env` takes variables, not patterns. */
|
|
85
|
+
export declare function isEnvPattern(name: string): boolean;
|
|
86
|
+
export type ForwardResult = {
|
|
87
|
+
ok: true;
|
|
88
|
+
env: Record<string, string>;
|
|
89
|
+
} | {
|
|
90
|
+
ok: false;
|
|
91
|
+
because: string;
|
|
92
|
+
};
|
|
93
|
+
export interface ContainedAgentDeps {
|
|
94
|
+
backend?: UntrustedExecutionBackend;
|
|
95
|
+
toolchain?: () => ToolchainResult;
|
|
96
|
+
/** Overridable so tests can drive a fake provider through the real route. */
|
|
97
|
+
packageDir?: string | null;
|
|
98
|
+
/** `scan` reads a structured envelope; the round reads the transcript. */
|
|
99
|
+
format?: 'text' | 'json';
|
|
100
|
+
/** Overridable for tests; production reads the platform's own shell. */
|
|
101
|
+
shell?: string;
|
|
102
|
+
/** The daemon home the provider credential is seeded from. Tests override it. */
|
|
103
|
+
providerHome?: ProviderStateDeps['home'];
|
|
104
|
+
now?: () => number;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* An {@link AgentInvoke} that runs the agent contained.
|
|
108
|
+
*
|
|
109
|
+
* Fails closed in both directions it can: no containment, no run; no provider
|
|
110
|
+
* runtime, no run. Neither ever falls back to running the agent as the daemon,
|
|
111
|
+
* which is the outcome this whole arc exists to prevent.
|
|
112
|
+
*/
|
|
113
|
+
export declare function makeContainedAgentRunner(projectDir: string, spec?: AgentSpec, deps?: ContainedAgentDeps): AgentInvoke;
|
|
114
|
+
//# sourceMappingURL=agent-contained.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-contained.d.ts","sourceRoot":"","sources":["../src/agent-contained.ts"],"names":[],"mappings":"AAGA,OAAO,EAAmC,KAAK,WAAW,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAGjG,OAAO,KA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0E;IAC1E,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACzB,wEAAwE;IACxE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iFAAiF;IACjF,YAAY,CAAC,EAAE,iBAAiB,CAAC,MAAM,CAAC,CAAC;IACzC,GAAG,CAAC,EAAE,MAAM,MAAM,CAAC;CACpB;AAED;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,UAAU,EAAE,MAAM,EAClB,IAAI,GAAE,SAAyB,EAC/B,IAAI,GAAE,kBAAuB,GAC5B,WAAW,CAiJb"}
|
|
@@ -0,0 +1,292 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EMPTY_MCP = exports.AGENT_TOOLS = void 0;
|
|
4
|
+
exports.claudePackageDir = claudePackageDir;
|
|
5
|
+
exports.claudeInvocation = claudeInvocation;
|
|
6
|
+
exports.isReservedEnvName = isReservedEnvName;
|
|
7
|
+
exports.isEnvPattern = isEnvPattern;
|
|
8
|
+
exports.makeContainedAgentRunner = makeContainedAgentRunner;
|
|
9
|
+
const agent_runtime_1 = require("./agent-runtime");
|
|
10
|
+
const node_fs_1 = require("node:fs");
|
|
11
|
+
const node_path_1 = require("node:path");
|
|
12
|
+
const agent_exec_1 = require("./agent-exec");
|
|
13
|
+
const exec_domains_1 = require("./exec-domains");
|
|
14
|
+
const toolchain_mirror_1 = require("./toolchain-mirror");
|
|
15
|
+
const untrusted_exec_1 = require("./untrusted-exec");
|
|
16
|
+
/**
|
|
17
|
+
* THE CODING AGENT, INSIDE THE BOUNDARY.
|
|
18
|
+
*
|
|
19
|
+
* The gate was contained first because it was easier to reason about. The agent
|
|
20
|
+
* is the one that matters: it is the process a model drives, and it ran as the
|
|
21
|
+
* daemon with `--dangerously-skip-permissions`, which is to say with a shell and
|
|
22
|
+
* the machine's whole environment.
|
|
23
|
+
*
|
|
24
|
+
* Two independent changes, and neither is sufficient alone.
|
|
25
|
+
*
|
|
26
|
+
* THE CAPABILITY SURFACE. The agent gets an explicit tool allowlist and no
|
|
27
|
+
* `Bash`. That is not a request — a tool absent from the set is a tool the CLI
|
|
28
|
+
* does not offer, so there is no shell to reach for. `--strict-mcp-config` with
|
|
29
|
+
* an empty server set means no MCP server configured anywhere on the machine
|
|
30
|
+
* becomes a capability by accident.
|
|
31
|
+
*
|
|
32
|
+
* THE CONTAINER. Even if the capability surface were wrong tomorrow, the agent
|
|
33
|
+
* runs in its own AppContainer: no machine token, no broker secret, no daemon
|
|
34
|
+
* profile, no `.git`, no `.looply/state`, no other project. The two layers are
|
|
35
|
+
* tested separately on purpose, because each is supposed to hold on its own.
|
|
36
|
+
*
|
|
37
|
+
* The agent keeps its OWN provider credential. Using the model is its job;
|
|
38
|
+
* speaking for the machine is not.
|
|
39
|
+
*/
|
|
40
|
+
/**
|
|
41
|
+
* What the agent may do, named without reference to any provider.
|
|
42
|
+
*
|
|
43
|
+
* The approval work that follows must never branch on a Claude flag, so the
|
|
44
|
+
* contract is written in terms of what an agent needs rather than how one CLI
|
|
45
|
+
* spells it.
|
|
46
|
+
*/
|
|
47
|
+
/**
|
|
48
|
+
* The built-in tools the agent is allowed.
|
|
49
|
+
*
|
|
50
|
+
* `Bash` is absent, and that is the whole point: the implementer's job is to
|
|
51
|
+
* edit files and report, and Looply runs the commands. `Task` is absent because
|
|
52
|
+
* a sub-agent is another process with its own tool set; `WebFetch` because
|
|
53
|
+
* fetching is not editing.
|
|
54
|
+
*/
|
|
55
|
+
exports.AGENT_TOOLS = ['Read', 'Glob', 'Grep', 'Edit', 'Write'];
|
|
56
|
+
/** An MCP configuration with no servers in it. */
|
|
57
|
+
exports.EMPTY_MCP = '{"mcpServers":{}}';
|
|
58
|
+
/**
|
|
59
|
+
* Where the installed Claude actually lives.
|
|
60
|
+
*
|
|
61
|
+
* `claude.cmd` is a shim that runs a native executable inside the npm package,
|
|
62
|
+
* so the package is what the container needs — and only the package. The
|
|
63
|
+
* directory the shim sits in also holds `eas` and `heroku` shims on this
|
|
64
|
+
* machine, and an agent that could resolve those would be an agent that could
|
|
65
|
+
* deploy.
|
|
66
|
+
*/
|
|
67
|
+
function claudePackageDir(nodeExe = process.execPath) {
|
|
68
|
+
let base;
|
|
69
|
+
try {
|
|
70
|
+
base = (0, node_path_1.dirname)((0, node_fs_1.realpathSync)(nodeExe));
|
|
71
|
+
}
|
|
72
|
+
catch {
|
|
73
|
+
base = (0, node_path_1.dirname)(nodeExe);
|
|
74
|
+
}
|
|
75
|
+
const pkg = (0, node_path_1.join)(base, 'node_modules', '@anthropic-ai', 'claude-code');
|
|
76
|
+
return (0, node_fs_1.existsSync)((0, node_path_1.join)(pkg, 'bin', 'claude.exe')) ? pkg : null;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* The command line for one agent turn.
|
|
80
|
+
*
|
|
81
|
+
* The prompt is NOT here. It goes on stdin, because it is many lines of
|
|
82
|
+
* instructions and a command line is neither a safe nor a large enough place
|
|
83
|
+
* for it — the previous implementation already knew that, and this keeps it
|
|
84
|
+
* true now that a container is involved.
|
|
85
|
+
*/
|
|
86
|
+
function claudeInvocation(packageDir, format = 'text') {
|
|
87
|
+
return {
|
|
88
|
+
executable: (0, node_path_1.join)(packageDir, 'bin', 'claude.exe'),
|
|
89
|
+
argv: [
|
|
90
|
+
'-p',
|
|
91
|
+
'--output-format',
|
|
92
|
+
format,
|
|
93
|
+
// An allowlist, not a denylist: a tool that is not named is not offered.
|
|
94
|
+
'--tools',
|
|
95
|
+
exports.AGENT_TOOLS.join(','),
|
|
96
|
+
// No MCP server from the user's profile becomes a capability by accident.
|
|
97
|
+
'--strict-mcp-config',
|
|
98
|
+
'--mcp-config',
|
|
99
|
+
exports.EMPTY_MCP,
|
|
100
|
+
],
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* Names `agent.env` may never forward, whatever a config asks for.
|
|
105
|
+
*
|
|
106
|
+
* `agent.env` exists so a provider key reaches the agent without being written
|
|
107
|
+
* into a file. It is a list of NAMES read from the daemon's own environment,
|
|
108
|
+
* which means a config that named `LOOPLY_MACHINE_SECRET` would have handed the
|
|
109
|
+
* agent the machine's identity — the one thing the whole containment arc exists
|
|
110
|
+
* to withhold. Nothing else in the chain would have objected.
|
|
111
|
+
*
|
|
112
|
+
* The reserved family is matched by PREFIX rather than by a list of the four
|
|
113
|
+
* names that exist today, so a credential added later is covered the day it is
|
|
114
|
+
* added rather than the day somebody remembers this file.
|
|
115
|
+
*/
|
|
116
|
+
function isReservedEnvName(name) {
|
|
117
|
+
return /^LOOPLY_/i.test(name.trim());
|
|
118
|
+
}
|
|
119
|
+
/** A name that is not a name. `agent.env` takes variables, not patterns. */
|
|
120
|
+
function isEnvPattern(name) {
|
|
121
|
+
return /[*?[\]]/.test(name);
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* The named environment variables, with the values the daemon actually holds.
|
|
125
|
+
*
|
|
126
|
+
* Absent ones are simply not forwarded: a config that names something unset
|
|
127
|
+
* should not hand the child an empty string that reads as configured.
|
|
128
|
+
*
|
|
129
|
+
* REFUSES rather than filtering silently. A config asking for the machine
|
|
130
|
+
* credential is a mistake somebody needs to see and fix; quietly dropping it
|
|
131
|
+
* would leave the agent failing for a reason nothing explains.
|
|
132
|
+
*/
|
|
133
|
+
function forwarded(spec) {
|
|
134
|
+
const out = {};
|
|
135
|
+
for (const name of spec.env ?? []) {
|
|
136
|
+
if (isReservedEnvName(name)) {
|
|
137
|
+
return { ok: false, because: `agent.env may not forward ${name} — that name is Looply's own` };
|
|
138
|
+
}
|
|
139
|
+
if (isEnvPattern(name)) {
|
|
140
|
+
return { ok: false, because: `agent.env takes variable names, not patterns (${name})` };
|
|
141
|
+
}
|
|
142
|
+
const v = process.env[name];
|
|
143
|
+
if (typeof v === 'string' && v.length > 0)
|
|
144
|
+
out[name] = v;
|
|
145
|
+
}
|
|
146
|
+
return { ok: true, env: out };
|
|
147
|
+
}
|
|
148
|
+
/**
|
|
149
|
+
* An {@link AgentInvoke} that runs the agent contained.
|
|
150
|
+
*
|
|
151
|
+
* Fails closed in both directions it can: no containment, no run; no provider
|
|
152
|
+
* runtime, no run. Neither ever falls back to running the agent as the daemon,
|
|
153
|
+
* which is the outcome this whole arc exists to prevent.
|
|
154
|
+
*/
|
|
155
|
+
function makeContainedAgentRunner(projectDir, spec = agent_exec_1.DEFAULT_AGENT, deps = {}) {
|
|
156
|
+
const backend = deps.backend ?? new untrusted_exec_1.AppContainerBackend();
|
|
157
|
+
const now = deps.now ?? (() => Date.now());
|
|
158
|
+
const ensureToolchain = deps.toolchain ?? (() => (0, toolchain_mirror_1.ensureToolchainMirror)());
|
|
159
|
+
return async (prompt, timeoutMs) => {
|
|
160
|
+
const started = now();
|
|
161
|
+
const fail = (why) => ({
|
|
162
|
+
ok: false,
|
|
163
|
+
timedOut: false,
|
|
164
|
+
ms: now() - started,
|
|
165
|
+
output: why,
|
|
166
|
+
});
|
|
167
|
+
const tools = ensureToolchain();
|
|
168
|
+
if (!tools.ok) {
|
|
169
|
+
return fail(`the agent did not run: no contained toolchain — ${tools.because}`);
|
|
170
|
+
}
|
|
171
|
+
const pass = forwarded(spec);
|
|
172
|
+
if (!pass.ok)
|
|
173
|
+
return fail(`the agent did not run: ${pass.because}`);
|
|
174
|
+
const format = deps.format ?? 'text';
|
|
175
|
+
/**
|
|
176
|
+
* ⚠️ NO SHARED-PATH GRANT HERE, AND THE ABSENCE IS DELIBERATE RATHER THAN
|
|
177
|
+
* AN OVERSIGHT. `makeContainedAgentRunner` has no production caller — that
|
|
178
|
+
* is pinned by `production-routing.spec.ts` — so wiring it to the
|
|
179
|
+
* shared-grant lock would add a locked ACL write on a path nothing takes,
|
|
180
|
+
* and the toolchain grant it used to request is exactly the per-launch
|
|
181
|
+
* grant the n122 repair removed. If this path is ever revived, it needs
|
|
182
|
+
* `ensureSharedAccess` before the launch, the way the gate runner and the
|
|
183
|
+
* tool bridge now do.
|
|
184
|
+
*/
|
|
185
|
+
const grants = [...(0, exec_domains_1.untrustedGrants)('agent', projectDir)];
|
|
186
|
+
// WHICH AGENT WAS CONFIGURED.
|
|
187
|
+
//
|
|
188
|
+
// `agent.command` is a real seam — it is how another provider is pointed at,
|
|
189
|
+
// and how the round end-to-end runs with a stub and no model at all. An
|
|
190
|
+
// adapter that ignored it would silently replace whatever the person chose
|
|
191
|
+
// with Claude, which is both wrong and the way to break every test that
|
|
192
|
+
// relies on the seam.
|
|
193
|
+
let executable;
|
|
194
|
+
let argv;
|
|
195
|
+
let rawCommandLine;
|
|
196
|
+
if (spec.command === agent_exec_1.DEFAULT_AGENT.command) {
|
|
197
|
+
const pkg = deps.packageDir === undefined ? claudePackageDir() : deps.packageDir;
|
|
198
|
+
if (pkg === null) {
|
|
199
|
+
// Distinguished from a containment failure on purpose: a missing
|
|
200
|
+
// provider runtime is not a sandbox problem, and reporting it as one
|
|
201
|
+
// sends the next person to the wrong place.
|
|
202
|
+
return fail('the agent did not run: no provider runtime was found');
|
|
203
|
+
}
|
|
204
|
+
// THE CREDENTIAL, AND NOTHING ELSE FROM THE DAEMON'S PROFILE.
|
|
205
|
+
//
|
|
206
|
+
/**
|
|
207
|
+
* 🔴 NO CREDENTIAL SEEDING. It used to copy the operator's credential in
|
|
208
|
+
* here, and that mechanism is gone everywhere — the provider owns its own
|
|
209
|
+
* login now, in a persistent profile Looply only names.
|
|
210
|
+
*
|
|
211
|
+
* This path is NOT wired to that profile, deliberately.
|
|
212
|
+
* `makeContainedAgentRunner` has no production caller, pinned by
|
|
213
|
+
* `production-routing.spec.ts`, and pointing a dead path at the operator's
|
|
214
|
+
* real provider profile would create a second, untested way to reach it.
|
|
215
|
+
* If this is ever revived it needs `checkProviderAuth` and
|
|
216
|
+
* `CLAUDE_CONFIG_DIR`, the way `model-transport` does — and it will fail
|
|
217
|
+
* closed until then, because a contained profile has no credential and
|
|
218
|
+
* nothing puts one there any more.
|
|
219
|
+
*/
|
|
220
|
+
const invocation = claudeInvocation(pkg, format);
|
|
221
|
+
executable = invocation.executable;
|
|
222
|
+
argv = invocation.argv;
|
|
223
|
+
// Read and execute. An agent that could rewrite its own provider runtime
|
|
224
|
+
// would be an agent choosing what the next turn runs.
|
|
225
|
+
grants.push({ path: pkg });
|
|
226
|
+
}
|
|
227
|
+
else {
|
|
228
|
+
// A configured command is a shell line, exactly as the gate's steps are,
|
|
229
|
+
// and it runs the same way: inside the container, where what it says
|
|
230
|
+
// matters much less than where it can reach.
|
|
231
|
+
// EXPLICIT, never inferred. A configured provider's runtime lives where
|
|
232
|
+
// the person said it lives; the command line is not consulted for it.
|
|
233
|
+
const declared = (0, agent_runtime_1.checkRuntimeGrants)(spec.runtime ?? [], undefined, projectDir);
|
|
234
|
+
if (!declared.ok)
|
|
235
|
+
return fail(`the agent did not run: ${declared.because}`);
|
|
236
|
+
for (const p of declared.paths)
|
|
237
|
+
grants.push({ path: p });
|
|
238
|
+
// Doubled: `'C:\Windows'` evaluates to `C:Windows`, a RELATIVE path.
|
|
239
|
+
// See the note in `exec-domains.ts`, where the same literal appeared.
|
|
240
|
+
const shell = deps.shell ?? (0, node_path_1.join)((0, untrusted_exec_1.systemRoot)(), 'System32', 'cmd.exe');
|
|
241
|
+
const line = (0, agent_exec_1.agentCommandLine)(spec, format);
|
|
242
|
+
executable = shell;
|
|
243
|
+
argv = ['/d', '/s', '/c', line];
|
|
244
|
+
rawCommandLine = `"${shell}" /d /s /c "${line}"`;
|
|
245
|
+
}
|
|
246
|
+
const out = await backend.run({
|
|
247
|
+
kind: 'agent',
|
|
248
|
+
projectKey: projectDir,
|
|
249
|
+
executable,
|
|
250
|
+
argv,
|
|
251
|
+
...(rawCommandLine === undefined ? {} : { rawCommandLine }),
|
|
252
|
+
cwd: projectDir,
|
|
253
|
+
env: (0, exec_domains_1.buildAgentEnv)(projectDir, pass.env, tools.path),
|
|
254
|
+
grants,
|
|
255
|
+
protect: (0, exec_domains_1.protectedPaths)(projectDir),
|
|
256
|
+
// The agent has to reach its model. It holds no machine or broker
|
|
257
|
+
// credential, so what it can reach is not what it could send.
|
|
258
|
+
network: 'internet-client',
|
|
259
|
+
stdin: prompt,
|
|
260
|
+
timeoutMs,
|
|
261
|
+
});
|
|
262
|
+
if (!out.ok) {
|
|
263
|
+
return fail(`the agent did not run: untrusted execution was unavailable (${out.reason} at ${out.stage}) — ${out.because}`);
|
|
264
|
+
}
|
|
265
|
+
const said = `${out.stdout}${out.stderr}`;
|
|
266
|
+
// A CHILD THAT SAID NOTHING AT ALL IS ITS OWN SYMPTOM.
|
|
267
|
+
//
|
|
268
|
+
// A timeout with empty output reads exactly like a model call that ran long,
|
|
269
|
+
// and it is usually not that: it is a provider runtime that never finished
|
|
270
|
+
// starting. Measured here, the packaged Claude binary answers `--version` in
|
|
271
|
+
// about a second inside the container and then hangs indefinitely on
|
|
272
|
+
// anything that loads its bundle — ten minutes, no output, no file written —
|
|
273
|
+
// while the same binary with the same environment runs in under two seconds
|
|
274
|
+
// outside it. Reporting a bare timeout would send the next person to raise
|
|
275
|
+
// the time limit, which is the one thing that cannot help.
|
|
276
|
+
if (out.timedOut && said.trim().length === 0) {
|
|
277
|
+
return {
|
|
278
|
+
ok: false,
|
|
279
|
+
timedOut: true,
|
|
280
|
+
ms: now() - started,
|
|
281
|
+
output: 'the agent produced no output before the timeout — the provider runtime may not start under containment',
|
|
282
|
+
};
|
|
283
|
+
}
|
|
284
|
+
return {
|
|
285
|
+
ok: out.exitCode === 0 && !out.timedOut,
|
|
286
|
+
timedOut: out.timedOut,
|
|
287
|
+
ms: now() - started,
|
|
288
|
+
output: said,
|
|
289
|
+
};
|
|
290
|
+
};
|
|
291
|
+
}
|
|
292
|
+
//# sourceMappingURL=agent-contained.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-contained.js","sourceRoot":"","sources":["../src/agent-contained.ts"],"names":[],"mappings":";;;AA2EA,4CASC;AAUD,4CAmBC;AAeD,8CAEC;AAGD,oCAEC;AAoDD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