sdd-agent-platform 0.4.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -23
- package/node_modules/@sdd-agent-platform/core/dist/ai-tools.js +31 -28
- package/node_modules/@sdd-agent-platform/core/dist/ai-tools.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/config/init-project.js +3 -2
- package/node_modules/@sdd-agent-platform/core/dist/config/init-project.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/config/starter-documents.d.ts +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/config/starter-documents.js +14 -5
- package/node_modules/@sdd-agent-platform/core/dist/config/starter-documents.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/contracts.d.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/contracts.js +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/contracts.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/doctor/checks/run-evidence.js +3 -3
- package/node_modules/@sdd-agent-platform/core/dist/doctor/checks/run-evidence.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/doctor/doctor.js +155 -1
- package/node_modules/@sdd-agent-platform/core/dist/doctor/doctor.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/evidence/lookup.d.ts +23 -0
- package/node_modules/@sdd-agent-platform/core/dist/evidence/lookup.js +54 -0
- package/node_modules/@sdd-agent-platform/core/dist/evidence/lookup.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/evidence-runtime/contracts.d.ts +11 -0
- package/node_modules/@sdd-agent-platform/core/dist/execution/agent-execution-records.js +15 -8
- package/node_modules/@sdd-agent-platform/core/dist/execution/agent-execution-records.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/execution/resident-worker.js +14 -6
- package/node_modules/@sdd-agent-platform/core/dist/execution/resident-worker.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/execution/stage-team-runtime.d.ts +112 -0
- package/node_modules/@sdd-agent-platform/core/dist/execution/stage-team-runtime.js +145 -0
- package/node_modules/@sdd-agent-platform/core/dist/execution/stage-team-runtime.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/instructions.js +36 -36
- package/node_modules/@sdd-agent-platform/core/dist/instructions.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/lifecycle/ship.d.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/lifecycle/ship.js +37 -17
- package/node_modules/@sdd-agent-platform/core/dist/lifecycle/ship.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-capability-catalog.d.ts +16 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-capability-catalog.js +174 -16
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-capability-catalog.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-registry.js +2 -2
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-registry.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-runtime-static.d.ts +10 -0
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-runtime-static.js +31 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/agent-runtime-static.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/capability-sources.d.ts +2 -17
- package/node_modules/@sdd-agent-platform/core/dist/registries/capability-sources.js +222 -10
- package/node_modules/@sdd-agent-platform/core/dist/registries/capability-sources.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/registries/workflow-gates.js +5 -5
- package/node_modules/@sdd-agent-platform/core/dist/registries/workflow-gates.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/agent-runtime-config.js +27 -12
- package/node_modules/@sdd-agent-platform/core/dist/router/agent-runtime-config.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/agent-runtime.d.ts +59 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/route-projection.d.ts +3 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/route-projection.js +191 -0
- package/node_modules/@sdd-agent-platform/core/dist/router/route-projection.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/routing.js +32 -6
- package/node_modules/@sdd-agent-platform/core/dist/router/routing.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/runtime-inspection.js +11 -4
- package/node_modules/@sdd-agent-platform/core/dist/router/runtime-inspection.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/router/runtime-validation.js +31 -3
- package/node_modules/@sdd-agent-platform/core/dist/router/runtime-validation.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/artifacts.js +48 -15
- package/node_modules/@sdd-agent-platform/core/dist/run-state/artifacts.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/events.js +2 -2
- package/node_modules/@sdd-agent-platform/core/dist/run-state/events.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/inspect-run.d.ts +3 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/inspect-run.js +15 -49
- package/node_modules/@sdd-agent-platform/core/dist/run-state/inspect-run.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/invocation-ledger.js +2 -2
- package/node_modules/@sdd-agent-platform/core/dist/run-state/invocation-ledger.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/model.d.ts +25 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/run-state.js +21 -14
- package/node_modules/@sdd-agent-platform/core/dist/run-state/run-state.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/run-state/task-evidence.d.ts +62 -0
- package/node_modules/@sdd-agent-platform/core/dist/run-state/task-evidence.js +130 -0
- package/node_modules/@sdd-agent-platform/core/dist/run-state/task-evidence.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/run-state.d.ts +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/run-state.js +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/run-state.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/runtime-paths.d.ts +10 -0
- package/node_modules/@sdd-agent-platform/core/dist/runtime-paths.js +44 -14
- package/node_modules/@sdd-agent-platform/core/dist/runtime-paths.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/context.js +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/context.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/document-hashes.d.ts +4 -0
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/document-hashes.js +189 -0
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/document-hashes.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/run-binding.js +12 -3
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/run-binding.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/task-parser.d.ts +20 -0
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/task-parser.js +101 -21
- package/node_modules/@sdd-agent-platform/core/dist/sdd-docs/task-parser.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/status/project-status.d.ts +62 -1
- package/node_modules/@sdd-agent-platform/core/dist/status/project-status.js +192 -4
- package/node_modules/@sdd-agent-platform/core/dist/status/project-status.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/storage/runtime-store.d.ts +195 -2
- package/node_modules/@sdd-agent-platform/core/dist/storage/runtime-store.js +499 -2
- package/node_modules/@sdd-agent-platform/core/dist/storage/runtime-store.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sync-back/apply.js +23 -1
- package/node_modules/@sdd-agent-platform/core/dist/sync-back/apply.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/sync-back/inspect.d.ts +19 -0
- package/node_modules/@sdd-agent-platform/core/dist/sync-back/inspect.js +114 -12
- package/node_modules/@sdd-agent-platform/core/dist/sync-back/inspect.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/test-support/fixtures.js +21 -0
- package/node_modules/@sdd-agent-platform/core/dist/test-support/fixtures.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/test-support/run-state.js +16 -2
- package/node_modules/@sdd-agent-platform/core/dist/test-support/run-state.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/tsconfig.tsbuildinfo +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/goal-verify.js +34 -2
- package/node_modules/@sdd-agent-platform/core/dist/verification/goal-verify.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/rendering.js +15 -5
- package/node_modules/@sdd-agent-platform/core/dist/verification/rendering.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/review-gate.d.ts +22 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/review-gate.js +53 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/review-gate.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/single-task-loop.js +102 -9
- package/node_modules/@sdd-agent-platform/core/dist/verification/single-task-loop.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/test-runtime.d.ts +16 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/test-runtime.js +355 -69
- package/node_modules/@sdd-agent-platform/core/dist/verification/test-runtime.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification/validation-wave.d.ts +58 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/validation-wave.js +428 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/validation-wave.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/verify-contract.d.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification/verify-contract.js +116 -18
- package/node_modules/@sdd-agent-platform/core/dist/verification/verify-contract.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/verification.d.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification.js +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/verification.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/evidence-packet.d.ts +24 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/evidence-packet.js +182 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/evidence-packet.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/hard-checks.d.ts +4 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/hard-checks.js +130 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/hard-checks.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/policy.d.ts +4 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/policy.js +146 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/policy.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/types.d.ts +89 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/types.js +2 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-gate/types.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/affected-file-conflicts.d.ts +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/affected-file-conflicts.js +16 -1
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/affected-file-conflicts.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/dependencies.d.ts +8 -4
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/dependencies.js +25 -11
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/dependencies.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/latest-eligible-run.d.ts +38 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/latest-eligible-run.js +122 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/latest-eligible-run.js.map +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/resolve.d.ts +27 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/resolve.js +166 -37
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state/resolve.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state.d.ts +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state.js +1 -0
- package/node_modules/@sdd-agent-platform/core/dist/workflow-state.js.map +1 -1
- package/node_modules/@sdd-agent-platform/core/package.json +1 -1
- package/node_modules/@sdd-agent-platform/core/src/ai-tools.ts +31 -28
- package/node_modules/@sdd-agent-platform/core/src/artifacts/sdd-result.test.ts +50 -4
- package/node_modules/@sdd-agent-platform/core/src/config/init-project.test.ts +13 -10
- package/node_modules/@sdd-agent-platform/core/src/config/init-project.ts +3 -2
- package/node_modules/@sdd-agent-platform/core/src/config/starter-documents.ts +15 -5
- package/node_modules/@sdd-agent-platform/core/src/contracts.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/src/doctor/checks/run-evidence.ts +3 -3
- package/node_modules/@sdd-agent-platform/core/src/doctor/doctor.test.ts +117 -5
- package/node_modules/@sdd-agent-platform/core/src/doctor/doctor.ts +164 -1
- package/node_modules/@sdd-agent-platform/core/src/evidence/lookup.ts +80 -0
- package/node_modules/@sdd-agent-platform/core/src/evidence-runtime/contracts.ts +12 -0
- package/node_modules/@sdd-agent-platform/core/src/execution/agent-execution-records.ts +16 -11
- package/node_modules/@sdd-agent-platform/core/src/execution/background-executor.test.ts +7 -0
- package/node_modules/@sdd-agent-platform/core/src/execution/resident-worker.test.ts +5 -0
- package/node_modules/@sdd-agent-platform/core/src/execution/resident-worker.ts +14 -6
- package/node_modules/@sdd-agent-platform/core/src/execution/stage-team-runtime.test.ts +102 -0
- package/node_modules/@sdd-agent-platform/core/src/execution/stage-team-runtime.ts +271 -0
- package/node_modules/@sdd-agent-platform/core/src/execution/wave-executor.test.ts +4 -0
- package/node_modules/@sdd-agent-platform/core/src/governance/policy.test.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/src/instructions.test.ts +11 -5
- package/node_modules/@sdd-agent-platform/core/src/instructions.ts +36 -36
- package/node_modules/@sdd-agent-platform/core/src/lifecycle/ship.ts +39 -17
- package/node_modules/@sdd-agent-platform/core/src/phase8-contracts.test.ts +3 -2
- package/node_modules/@sdd-agent-platform/core/src/phase8-risk-kernel.test.ts +5 -0
- package/node_modules/@sdd-agent-platform/core/src/planning/task-graph.test.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/src/planning/wave-plan.test.ts +3 -0
- package/node_modules/@sdd-agent-platform/core/src/registries/agent-capability-catalog.ts +269 -17
- package/node_modules/@sdd-agent-platform/core/src/registries/agent-registry.ts +2 -2
- package/node_modules/@sdd-agent-platform/core/src/registries/agent-runtime-static.ts +41 -1
- package/node_modules/@sdd-agent-platform/core/src/registries/capability-sources.ts +238 -15
- package/node_modules/@sdd-agent-platform/core/src/registries/registries.test.ts +27 -2
- package/node_modules/@sdd-agent-platform/core/src/registries/workflow-gates.ts +5 -5
- package/node_modules/@sdd-agent-platform/core/src/router/agent-runtime-config.ts +31 -12
- package/node_modules/@sdd-agent-platform/core/src/router/agent-runtime.ts +66 -1
- package/node_modules/@sdd-agent-platform/core/src/router/route-projection.ts +211 -0
- package/node_modules/@sdd-agent-platform/core/src/router/route-sdd-task.test.ts +151 -3
- package/node_modules/@sdd-agent-platform/core/src/router/routing.ts +35 -6
- package/node_modules/@sdd-agent-platform/core/src/router/runtime-inspection.ts +11 -4
- package/node_modules/@sdd-agent-platform/core/src/router/runtime-validation.ts +32 -3
- package/node_modules/@sdd-agent-platform/core/src/run-state/artifacts.ts +48 -15
- package/node_modules/@sdd-agent-platform/core/src/run-state/events.ts +2 -2
- package/node_modules/@sdd-agent-platform/core/src/run-state/inspect-run.ts +17 -52
- package/node_modules/@sdd-agent-platform/core/src/run-state/invocation-ledger.ts +2 -2
- package/node_modules/@sdd-agent-platform/core/src/run-state/model.ts +28 -1
- package/node_modules/@sdd-agent-platform/core/src/run-state/run-state.test.ts +3 -0
- package/node_modules/@sdd-agent-platform/core/src/run-state/run-state.ts +22 -18
- package/node_modules/@sdd-agent-platform/core/src/run-state/task-evidence.ts +206 -0
- package/node_modules/@sdd-agent-platform/core/src/run-state.ts +1 -0
- package/node_modules/@sdd-agent-platform/core/src/runtime-paths.ts +54 -14
- package/node_modules/@sdd-agent-platform/core/src/sdd-docs/context.ts +1 -1
- package/node_modules/@sdd-agent-platform/core/src/sdd-docs/document-hashes.ts +207 -0
- package/node_modules/@sdd-agent-platform/core/src/sdd-docs/run-binding.ts +12 -3
- package/node_modules/@sdd-agent-platform/core/src/sdd-docs/task-parser.test.ts +139 -0
- package/node_modules/@sdd-agent-platform/core/src/sdd-docs/task-parser.ts +137 -24
- package/node_modules/@sdd-agent-platform/core/src/status/project-status.ts +268 -5
- package/node_modules/@sdd-agent-platform/core/src/storage/runtime-store.test.ts +368 -4
- package/node_modules/@sdd-agent-platform/core/src/storage/runtime-store.ts +697 -2
- package/node_modules/@sdd-agent-platform/core/src/sync-back/apply.ts +23 -1
- package/node_modules/@sdd-agent-platform/core/src/sync-back/inspect.ts +145 -12
- package/node_modules/@sdd-agent-platform/core/src/sync-back/sync-back.test.ts +132 -9
- package/node_modules/@sdd-agent-platform/core/src/test-support/fixtures.ts +21 -0
- package/node_modules/@sdd-agent-platform/core/src/test-support/run-state.ts +16 -2
- package/node_modules/@sdd-agent-platform/core/src/verification/goal-verify.test.ts +1 -1
- package/node_modules/@sdd-agent-platform/core/src/verification/goal-verify.ts +38 -5
- package/node_modules/@sdd-agent-platform/core/src/verification/rendering.ts +15 -5
- package/node_modules/@sdd-agent-platform/core/src/verification/review-gate.test.ts +77 -0
- package/node_modules/@sdd-agent-platform/core/src/verification/review-gate.ts +77 -0
- package/node_modules/@sdd-agent-platform/core/src/verification/single-task-loop.test.ts +64 -4
- package/node_modules/@sdd-agent-platform/core/src/verification/single-task-loop.ts +110 -12
- package/node_modules/@sdd-agent-platform/core/src/verification/test-runtime.test.ts +72 -25
- package/node_modules/@sdd-agent-platform/core/src/verification/test-runtime.ts +402 -77
- package/node_modules/@sdd-agent-platform/core/src/verification/validation-wave.test.ts +341 -0
- package/node_modules/@sdd-agent-platform/core/src/verification/validation-wave.ts +513 -0
- package/node_modules/@sdd-agent-platform/core/src/verification/verify-contract.test.ts +144 -5
- package/node_modules/@sdd-agent-platform/core/src/verification/verify-contract.ts +129 -18
- package/node_modules/@sdd-agent-platform/core/src/verification.ts +2 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/evidence-packet.ts +196 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/hard-checks.test.ts +171 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/hard-checks.ts +143 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/policy.test.ts +137 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/policy.ts +155 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-gate/types.ts +114 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/affected-file-conflicts.ts +18 -1
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/dependencies.test.ts +1 -1
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/dependencies.ts +33 -11
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/latest-eligible-run.ts +156 -0
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/resolve.test.ts +351 -2
- package/node_modules/@sdd-agent-platform/core/src/workflow-state/resolve.ts +227 -39
- package/node_modules/@sdd-agent-platform/core/src/workflow-state.ts +1 -0
- package/package.json +1 -1
- package/packages/cli/dist/commands/status.js +2 -2
- package/packages/cli/dist/commands/status.js.map +1 -1
- package/packages/cli/dist/commands/sync-back.js +1 -1
- package/packages/cli/dist/commands/sync-back.js.map +1 -1
- package/packages/cli/dist/commands/tasks.js +4 -4
- package/packages/cli/dist/commands/tasks.js.map +1 -1
- package/packages/cli/dist/commands/test.js +94 -5
- package/packages/cli/dist/commands/test.js.map +1 -1
- package/packages/cli/dist/commands/verifies.js +5 -3
- package/packages/cli/dist/commands/verifies.js.map +1 -1
- package/packages/cli/dist/commands/verify.js +48 -7
- package/packages/cli/dist/commands/verify.js.map +1 -1
- package/packages/cli/dist/help.js +32 -18
- package/packages/cli/dist/help.js.map +1 -1
- package/packages/cli/dist/renderers/artifacts.js +1 -1
- package/packages/cli/dist/renderers/artifacts.js.map +1 -1
- package/packages/cli/dist/renderers/registry-runtime.js +7 -2
- package/packages/cli/dist/renderers/registry-runtime.js.map +1 -1
- package/packages/cli/dist/renderers/router.js +4 -2
- package/packages/cli/dist/renderers/router.js.map +1 -1
- package/packages/cli/dist/renderers/workflow.js +33 -12
- package/packages/cli/dist/renderers/workflow.js.map +1 -1
- package/packages/cli/dist/tsconfig.tsbuildinfo +1 -1
- package/packages/cli/package.json +2 -2
- package/packages/core/dist/ai-tools.js +31 -28
- package/packages/core/dist/ai-tools.js.map +1 -1
- package/packages/core/dist/config/init-project.js +3 -2
- package/packages/core/dist/config/init-project.js.map +1 -1
- package/packages/core/dist/config/starter-documents.d.ts +1 -1
- package/packages/core/dist/config/starter-documents.js +14 -5
- package/packages/core/dist/config/starter-documents.js.map +1 -1
- package/packages/core/dist/contracts.d.ts +2 -0
- package/packages/core/dist/contracts.js +2 -0
- package/packages/core/dist/contracts.js.map +1 -1
- package/packages/core/dist/doctor/checks/run-evidence.js +3 -3
- package/packages/core/dist/doctor/checks/run-evidence.js.map +1 -1
- package/packages/core/dist/doctor/doctor.js +155 -1
- package/packages/core/dist/doctor/doctor.js.map +1 -1
- package/packages/core/dist/evidence/lookup.d.ts +23 -0
- package/packages/core/dist/evidence/lookup.js +54 -0
- package/packages/core/dist/evidence/lookup.js.map +1 -0
- package/packages/core/dist/evidence-runtime/contracts.d.ts +11 -0
- package/packages/core/dist/execution/agent-execution-records.js +15 -8
- package/packages/core/dist/execution/agent-execution-records.js.map +1 -1
- package/packages/core/dist/execution/resident-worker.js +14 -6
- package/packages/core/dist/execution/resident-worker.js.map +1 -1
- package/packages/core/dist/execution/stage-team-runtime.d.ts +112 -0
- package/packages/core/dist/execution/stage-team-runtime.js +145 -0
- package/packages/core/dist/execution/stage-team-runtime.js.map +1 -0
- package/packages/core/dist/instructions.js +36 -36
- package/packages/core/dist/instructions.js.map +1 -1
- package/packages/core/dist/lifecycle/ship.d.ts +2 -0
- package/packages/core/dist/lifecycle/ship.js +37 -17
- package/packages/core/dist/lifecycle/ship.js.map +1 -1
- package/packages/core/dist/registries/agent-capability-catalog.d.ts +16 -1
- package/packages/core/dist/registries/agent-capability-catalog.js +174 -16
- package/packages/core/dist/registries/agent-capability-catalog.js.map +1 -1
- package/packages/core/dist/registries/agent-registry.js +2 -2
- package/packages/core/dist/registries/agent-registry.js.map +1 -1
- package/packages/core/dist/registries/agent-runtime-static.d.ts +10 -0
- package/packages/core/dist/registries/agent-runtime-static.js +31 -1
- package/packages/core/dist/registries/agent-runtime-static.js.map +1 -1
- package/packages/core/dist/registries/capability-sources.d.ts +2 -17
- package/packages/core/dist/registries/capability-sources.js +222 -10
- package/packages/core/dist/registries/capability-sources.js.map +1 -1
- package/packages/core/dist/registries/workflow-gates.js +5 -5
- package/packages/core/dist/registries/workflow-gates.js.map +1 -1
- package/packages/core/dist/router/agent-runtime-config.js +27 -12
- package/packages/core/dist/router/agent-runtime-config.js.map +1 -1
- package/packages/core/dist/router/agent-runtime.d.ts +59 -1
- package/packages/core/dist/router/route-projection.d.ts +3 -1
- package/packages/core/dist/router/route-projection.js +191 -0
- package/packages/core/dist/router/route-projection.js.map +1 -1
- package/packages/core/dist/router/routing.js +32 -6
- package/packages/core/dist/router/routing.js.map +1 -1
- package/packages/core/dist/router/runtime-inspection.js +11 -4
- package/packages/core/dist/router/runtime-inspection.js.map +1 -1
- package/packages/core/dist/router/runtime-validation.js +31 -3
- package/packages/core/dist/router/runtime-validation.js.map +1 -1
- package/packages/core/dist/run-state/artifacts.js +48 -15
- package/packages/core/dist/run-state/artifacts.js.map +1 -1
- package/packages/core/dist/run-state/events.js +2 -2
- package/packages/core/dist/run-state/events.js.map +1 -1
- package/packages/core/dist/run-state/inspect-run.d.ts +3 -1
- package/packages/core/dist/run-state/inspect-run.js +15 -49
- package/packages/core/dist/run-state/inspect-run.js.map +1 -1
- package/packages/core/dist/run-state/invocation-ledger.js +2 -2
- package/packages/core/dist/run-state/invocation-ledger.js.map +1 -1
- package/packages/core/dist/run-state/model.d.ts +25 -1
- package/packages/core/dist/run-state/run-state.js +21 -14
- package/packages/core/dist/run-state/run-state.js.map +1 -1
- package/packages/core/dist/run-state/task-evidence.d.ts +62 -0
- package/packages/core/dist/run-state/task-evidence.js +130 -0
- package/packages/core/dist/run-state/task-evidence.js.map +1 -0
- package/packages/core/dist/run-state.d.ts +1 -0
- package/packages/core/dist/run-state.js +1 -0
- package/packages/core/dist/run-state.js.map +1 -1
- package/packages/core/dist/runtime-paths.d.ts +10 -0
- package/packages/core/dist/runtime-paths.js +44 -14
- package/packages/core/dist/runtime-paths.js.map +1 -1
- package/packages/core/dist/sdd-docs/context.js +1 -1
- package/packages/core/dist/sdd-docs/context.js.map +1 -1
- package/packages/core/dist/sdd-docs/document-hashes.d.ts +4 -0
- package/packages/core/dist/sdd-docs/document-hashes.js +189 -0
- package/packages/core/dist/sdd-docs/document-hashes.js.map +1 -0
- package/packages/core/dist/sdd-docs/run-binding.js +12 -3
- package/packages/core/dist/sdd-docs/run-binding.js.map +1 -1
- package/packages/core/dist/sdd-docs/task-parser.d.ts +20 -0
- package/packages/core/dist/sdd-docs/task-parser.js +101 -21
- package/packages/core/dist/sdd-docs/task-parser.js.map +1 -1
- package/packages/core/dist/status/project-status.d.ts +62 -1
- package/packages/core/dist/status/project-status.js +192 -4
- package/packages/core/dist/status/project-status.js.map +1 -1
- package/packages/core/dist/storage/runtime-store.d.ts +195 -2
- package/packages/core/dist/storage/runtime-store.js +499 -2
- package/packages/core/dist/storage/runtime-store.js.map +1 -1
- package/packages/core/dist/sync-back/apply.js +23 -1
- package/packages/core/dist/sync-back/apply.js.map +1 -1
- package/packages/core/dist/sync-back/inspect.d.ts +19 -0
- package/packages/core/dist/sync-back/inspect.js +114 -12
- package/packages/core/dist/sync-back/inspect.js.map +1 -1
- package/packages/core/dist/test-support/fixtures.js +21 -0
- package/packages/core/dist/test-support/fixtures.js.map +1 -1
- package/packages/core/dist/test-support/run-state.js +16 -2
- package/packages/core/dist/test-support/run-state.js.map +1 -1
- package/packages/core/dist/tsconfig.tsbuildinfo +1 -1
- package/packages/core/dist/verification/goal-verify.js +34 -2
- package/packages/core/dist/verification/goal-verify.js.map +1 -1
- package/packages/core/dist/verification/rendering.js +15 -5
- package/packages/core/dist/verification/rendering.js.map +1 -1
- package/packages/core/dist/verification/review-gate.d.ts +22 -0
- package/packages/core/dist/verification/review-gate.js +53 -0
- package/packages/core/dist/verification/review-gate.js.map +1 -0
- package/packages/core/dist/verification/single-task-loop.js +102 -9
- package/packages/core/dist/verification/single-task-loop.js.map +1 -1
- package/packages/core/dist/verification/test-runtime.d.ts +16 -1
- package/packages/core/dist/verification/test-runtime.js +355 -69
- package/packages/core/dist/verification/test-runtime.js.map +1 -1
- package/packages/core/dist/verification/validation-wave.d.ts +58 -0
- package/packages/core/dist/verification/validation-wave.js +428 -0
- package/packages/core/dist/verification/validation-wave.js.map +1 -0
- package/packages/core/dist/verification/verify-contract.d.ts +2 -0
- package/packages/core/dist/verification/verify-contract.js +116 -18
- package/packages/core/dist/verification/verify-contract.js.map +1 -1
- package/packages/core/dist/verification.d.ts +2 -0
- package/packages/core/dist/verification.js +2 -0
- package/packages/core/dist/verification.js.map +1 -1
- package/packages/core/dist/workflow-gate/evidence-packet.d.ts +24 -0
- package/packages/core/dist/workflow-gate/evidence-packet.js +182 -0
- package/packages/core/dist/workflow-gate/evidence-packet.js.map +1 -0
- package/packages/core/dist/workflow-gate/hard-checks.d.ts +4 -0
- package/packages/core/dist/workflow-gate/hard-checks.js +130 -0
- package/packages/core/dist/workflow-gate/hard-checks.js.map +1 -0
- package/packages/core/dist/workflow-gate/policy.d.ts +4 -0
- package/packages/core/dist/workflow-gate/policy.js +146 -0
- package/packages/core/dist/workflow-gate/policy.js.map +1 -0
- package/packages/core/dist/workflow-gate/types.d.ts +89 -0
- package/packages/core/dist/workflow-gate/types.js +2 -0
- package/packages/core/dist/workflow-gate/types.js.map +1 -0
- package/packages/core/dist/workflow-state/affected-file-conflicts.d.ts +1 -0
- package/packages/core/dist/workflow-state/affected-file-conflicts.js +16 -1
- package/packages/core/dist/workflow-state/affected-file-conflicts.js.map +1 -1
- package/packages/core/dist/workflow-state/dependencies.d.ts +8 -4
- package/packages/core/dist/workflow-state/dependencies.js +25 -11
- package/packages/core/dist/workflow-state/dependencies.js.map +1 -1
- package/packages/core/dist/workflow-state/latest-eligible-run.d.ts +38 -0
- package/packages/core/dist/workflow-state/latest-eligible-run.js +122 -0
- package/packages/core/dist/workflow-state/latest-eligible-run.js.map +1 -0
- package/packages/core/dist/workflow-state/resolve.d.ts +27 -0
- package/packages/core/dist/workflow-state/resolve.js +166 -37
- package/packages/core/dist/workflow-state/resolve.js.map +1 -1
- package/packages/core/dist/workflow-state.d.ts +1 -0
- package/packages/core/dist/workflow-state.js +1 -0
- package/packages/core/dist/workflow-state.js.map +1 -1
- package/packages/core/package.json +1 -1
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { WORKFLOW_STATE_RESOLVER_CONTRACT_VERSION } from '../contracts.js';
|
|
2
2
|
import { recordRuntimeProjection } from '../storage/runtime-store.js';
|
|
3
|
-
import type { RunState, RunSummary } from '../run-state/model.js';
|
|
3
|
+
import type { RunState, RunStateTaskRuntime, RunSummary } from '../run-state/model.js';
|
|
4
4
|
import { affectedFileConflictsForSelectedRun, type WorkflowAffectedFileConflict } from './affected-file-conflicts.js';
|
|
5
5
|
import { readAllRunStates, summarizeRunState } from '../run-state/run-state.js';
|
|
6
6
|
import { resolveSddContext, type ContextBranchSource, type ContextResolverContract } from '../sdd-docs/context.js';
|
|
7
|
-
import { parseSddBranch, type SddTaskGap, type SddTaskModel } from '../sdd-docs/task-parser.js';
|
|
8
|
-
import { workflowDependencyBlockers, type WorkflowDependencyBlocker } from './dependencies.js';
|
|
7
|
+
import { parseSddBranch, type SddTask, type SddTaskGap, type SddTaskModel } from '../sdd-docs/task-parser.js';
|
|
8
|
+
import { dependencyBlockingReasonsForTask, workflowDependencyBlockers, type WorkflowDependencyBlocker } from './dependencies.js';
|
|
9
|
+
import { selectLatestEligibleRunsByTask, type DocumentCompatibilityClass, type LatestEligibleRunSelection } from './latest-eligible-run.js';
|
|
9
10
|
|
|
10
11
|
export interface WorkflowTaskCounts {
|
|
11
12
|
total: number;
|
|
@@ -28,6 +29,33 @@ export interface WorkflowLatestTaskRun {
|
|
|
28
29
|
syncBackStatus: RunState['syncBack']['status'];
|
|
29
30
|
affectedFiles: string[];
|
|
30
31
|
updatedAt: string;
|
|
32
|
+
compatibility: DocumentCompatibilityClass;
|
|
33
|
+
eligibleForDefaultApply: boolean;
|
|
34
|
+
reasons: string[];
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export type WorkflowCommandSemantics = 'inspection_navigation' | 'gate_execution';
|
|
38
|
+
export type WorkflowHostProjectionStatus = 'active' | 'future' | 'unsupported';
|
|
39
|
+
export type WorkflowNextStage = 'spec' | 'tasks' | 'do' | 'test' | 'ship';
|
|
40
|
+
export type WorkflowNextIntentKind = 'start_spec' | 'resolve_task_gaps' | 'inspect_dependency' | 'ship_readiness' | 'inspect_task' | 'list_tasks' | 'continue_do' | 'run_task_validation' | 'run_batch_validation' | 'run_wave_validation';
|
|
41
|
+
|
|
42
|
+
export interface WorkflowHostCommandProjection {
|
|
43
|
+
host: 'claude_code' | 'codex' | 'opencode';
|
|
44
|
+
status: WorkflowHostProjectionStatus;
|
|
45
|
+
entry: string | null;
|
|
46
|
+
projectionSurfaces: string[];
|
|
47
|
+
permissionProjection: string;
|
|
48
|
+
reason: string;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface WorkflowNextIntent {
|
|
52
|
+
stage: WorkflowNextStage;
|
|
53
|
+
intent: WorkflowNextIntentKind;
|
|
54
|
+
canonicalCommand: string;
|
|
55
|
+
commandSemantics: WorkflowCommandSemantics;
|
|
56
|
+
evidenceRequirement: string;
|
|
57
|
+
blockingReason: string | null;
|
|
58
|
+
hostProjections: WorkflowHostCommandProjection[];
|
|
31
59
|
}
|
|
32
60
|
|
|
33
61
|
|
|
@@ -44,10 +72,12 @@ export interface WorkflowStateResolution {
|
|
|
44
72
|
latestRun: RunSummary | null;
|
|
45
73
|
latestRunState: RunState | null;
|
|
46
74
|
latestRunsByTask: WorkflowLatestTaskRun[];
|
|
75
|
+
latestEligibleRunsByTask: LatestEligibleRunSelection[];
|
|
47
76
|
affectedFileConflicts: WorkflowAffectedFileConflict[];
|
|
48
77
|
blockingReasons: string[];
|
|
49
78
|
dependencyBlockers: WorkflowDependencyBlocker[];
|
|
50
79
|
recommendedNextCommand: string;
|
|
80
|
+
nextIntent: WorkflowNextIntent;
|
|
51
81
|
}
|
|
52
82
|
|
|
53
83
|
export async function resolveWorkflowState(projectRoot: string, options: { branch?: string | null; branchSource?: ContextBranchSource; taskId?: string | null } = {}): Promise<WorkflowStateResolution> {
|
|
@@ -55,13 +85,15 @@ export async function resolveWorkflowState(projectRoot: string, options: { branc
|
|
|
55
85
|
const branch = context.partition;
|
|
56
86
|
const [model, states] = await Promise.all([parseSddBranch(projectRoot, branch), readAllRunStates(projectRoot)]);
|
|
57
87
|
const visibleGaps = workflowIsActive(model) ? model.gaps : [];
|
|
58
|
-
const
|
|
88
|
+
const latestEligibleRunsByTask = selectLatestEligibleRunsByTask({ states, model, partition: branch, currentGitBranch: context.currentGitBranch });
|
|
89
|
+
const latestRunsByTask = selectedLatestTaskRuns(latestEligibleRunsByTask);
|
|
59
90
|
const selectedTaskRun = options.taskId
|
|
60
91
|
? latestRunsByTask.find((entry) => entry.taskId === options.taskId) ?? null
|
|
61
92
|
: latestRunsByTask.slice().sort((left, right) => Date.parse(right.updatedAt) - Date.parse(left.updatedAt))[0] ?? null;
|
|
62
93
|
const latestRunState = selectedTaskRun ? states.find((state) => state.runId === selectedTaskRun.runId) ?? null : null;
|
|
63
94
|
const affectedFileConflicts = latestRunState ? affectedFileConflictsForSelectedRun(states, latestRunState) : [];
|
|
64
|
-
const
|
|
95
|
+
const runtimeByTask = latestRuntimeTaskStates(latestEligibleRunsByTask, states);
|
|
96
|
+
const dependencyBlockers = workflowDependencyBlockers(model, { runtimeByTask });
|
|
65
97
|
const blockingReasons = blockingWorkflowReasons(visibleGaps, affectedFileConflicts, dependencyBlockers);
|
|
66
98
|
const resolution: WorkflowStateResolution = {
|
|
67
99
|
contract: WORKFLOW_STATE_RESOLVER_CONTRACT_VERSION,
|
|
@@ -76,12 +108,19 @@ export async function resolveWorkflowState(projectRoot: string, options: { branc
|
|
|
76
108
|
latestRun: latestRunState ? summarizeRunState(latestRunState) : null,
|
|
77
109
|
latestRunState,
|
|
78
110
|
latestRunsByTask,
|
|
111
|
+
latestEligibleRunsByTask,
|
|
79
112
|
affectedFileConflicts,
|
|
80
113
|
dependencyBlockers,
|
|
81
114
|
blockingReasons,
|
|
82
|
-
|
|
115
|
+
nextIntent: recommendedWorkflowNextIntent(context, model, latestRunsByTask, visibleGaps, dependencyBlockers, runtimeByTask),
|
|
116
|
+
recommendedNextCommand: ''
|
|
83
117
|
};
|
|
84
|
-
|
|
118
|
+
resolution.recommendedNextCommand = resolution.nextIntent.canonicalCommand;
|
|
119
|
+
try {
|
|
120
|
+
await recordRuntimeProjection(projectRoot, 'workflow_state', branch, projectWorkflowStateProjection(resolution));
|
|
121
|
+
} catch {
|
|
122
|
+
// Projection writes are rebuildable and must not block workflow resolution.
|
|
123
|
+
}
|
|
85
124
|
return resolution;
|
|
86
125
|
}
|
|
87
126
|
|
|
@@ -102,29 +141,24 @@ function taskCounts(model: SddTaskModel, gaps: SddTaskGap[]): WorkflowTaskCounts
|
|
|
102
141
|
};
|
|
103
142
|
}
|
|
104
143
|
|
|
105
|
-
function
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
if (!existing || Date.parse(entry.updatedAt) > Date.parse(existing.updatedAt) || (entry.updatedAt === existing.updatedAt && entry.runId.localeCompare(existing.runId) > 0)) {
|
|
124
|
-
latest.set(entry.taskId, entry);
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
return Array.from(latest.values()).sort((left, right) => left.taskId.localeCompare(right.taskId));
|
|
144
|
+
function selectedLatestTaskRuns(selections: LatestEligibleRunSelection[]): WorkflowLatestTaskRun[] {
|
|
145
|
+
return selections
|
|
146
|
+
.flatMap((selection) => selection.selected ? [selection.selected] : [])
|
|
147
|
+
.map((candidate) => ({
|
|
148
|
+
partition: candidate.partition,
|
|
149
|
+
gitBranch: candidate.gitBranch,
|
|
150
|
+
taskId: candidate.taskId,
|
|
151
|
+
runId: candidate.runId,
|
|
152
|
+
runStatus: candidate.runStatus,
|
|
153
|
+
validationStatus: candidate.validationStatus,
|
|
154
|
+
syncBackStatus: candidate.syncBackStatus,
|
|
155
|
+
affectedFiles: candidate.affectedFiles,
|
|
156
|
+
updatedAt: candidate.updatedAt,
|
|
157
|
+
compatibility: candidate.compatibility,
|
|
158
|
+
eligibleForDefaultApply: candidate.eligibleForDefaultApply,
|
|
159
|
+
reasons: candidate.reasons
|
|
160
|
+
}))
|
|
161
|
+
.sort((left, right) => left.taskId.localeCompare(right.taskId));
|
|
128
162
|
}
|
|
129
163
|
|
|
130
164
|
|
|
@@ -139,22 +173,174 @@ function blockingWorkflowReasons(gaps: SddTaskGap[], conflicts: WorkflowAffected
|
|
|
139
173
|
return reasons;
|
|
140
174
|
}
|
|
141
175
|
|
|
142
|
-
function
|
|
176
|
+
function recommendedWorkflowNextIntent(
|
|
177
|
+
context: ContextResolverContract,
|
|
178
|
+
model: SddTaskModel,
|
|
179
|
+
latestRunsByTask: WorkflowLatestTaskRun[],
|
|
180
|
+
gaps: SddTaskGap[],
|
|
181
|
+
dependencyBlockers: WorkflowDependencyBlocker[],
|
|
182
|
+
runtimeByTask: Map<string, RunStateTaskRuntime>
|
|
183
|
+
): WorkflowNextIntent {
|
|
143
184
|
if (!workflowIsActive(model)) {
|
|
144
|
-
return
|
|
185
|
+
return workflowNextIntent('spec', 'start_spec', `sdd spec --branch ${context.partition}`, 'Start the spec stage before planning or task execution.', null);
|
|
186
|
+
}
|
|
187
|
+
const blockingGap = gaps.find((gap) => gap.severity === 'blocking');
|
|
188
|
+
if (blockingGap) {
|
|
189
|
+
return workflowNextIntent('tasks', 'resolve_task_gaps', `sdd tasks gaps --branch ${context.partition}`, 'Resolve blocking task document gaps before execution evidence can be trusted.', `${blockingGap.field}: ${blockingGap.message}`);
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
const strictTask = model.tasks.find((task) => needsTaskValidation(task, runtimeByTask.get(task.id)));
|
|
193
|
+
if (strictTask) {
|
|
194
|
+
return workflowNextIntent('test', 'run_task_validation', `sdd test task ${strictTask.id} --branch ${context.partition}`, 'Validate this strict or task_end task before more implementation proceeds.', null);
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
const readyBoundary = readyValidationBoundary(model, runtimeByTask);
|
|
198
|
+
if (readyBoundary?.kind === 'batch') {
|
|
199
|
+
return workflowNextIntent('test', 'run_batch_validation', `sdd test batch ${readyBoundary.id} --branch ${context.partition}`, `Validate accumulated implementation evidence for batch ${readyBoundary.id}.`, null);
|
|
145
200
|
}
|
|
146
|
-
if (
|
|
147
|
-
return `
|
|
201
|
+
if (readyBoundary?.kind === 'wave') {
|
|
202
|
+
return workflowNextIntent('test', 'run_wave_validation', waveValidationCommand(context.partition, readyBoundary.wave), `Validate accumulated implementation evidence for wave ${readyBoundary.wave ?? 'all'}.`, null);
|
|
148
203
|
}
|
|
204
|
+
|
|
205
|
+
if (latestRunsByTask.some(latestEligibleRunReadyForShip)) {
|
|
206
|
+
return workflowNextIntent('ship', 'ship_readiness', `sdd ship --branch ${context.partition} --dry-run`, 'Run release readiness after validation PASS; create a decision card only if the gate requires human review.', null);
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
const nextTask = model.tasks.find((task) => task.status === 'pending' && !runtimeTaskImplemented(runtimeByTask.get(task.id)) && dependencyBlockingReasonsForTask(model, task.id, { runtimeByTask }).length === 0);
|
|
210
|
+
if (nextTask) {
|
|
211
|
+
return workflowNextIntent('do', 'continue_do', `sdd do task ${nextTask.id} --branch ${context.partition}`, 'Continue sequential implementation; validation can wait until the declared task or batch boundary.', null);
|
|
212
|
+
}
|
|
213
|
+
|
|
149
214
|
const dependencyBlocker = dependencyBlockers[0];
|
|
150
215
|
if (dependencyBlocker) {
|
|
151
|
-
return `sdd tasks inspect ${dependencyBlocker.dependencyId} --branch ${context.partition}
|
|
152
|
-
}
|
|
153
|
-
if (latestRun?.syncBack.status === 'proposed' && latestRun.currentTask) {
|
|
154
|
-
return `sdd sync-back inspect --branch ${context.partition} --task ${latestRun.currentTask}`;
|
|
216
|
+
return workflowNextIntent('tasks', 'inspect_dependency', `sdd tasks inspect ${dependencyBlocker.dependencyId} --branch ${context.partition}`, 'Inspect the dependency task before continuing this workflow.', dependencyBlocker.reason);
|
|
155
217
|
}
|
|
218
|
+
|
|
156
219
|
const pendingTask = model.tasks.find((task) => task.status === 'pending');
|
|
157
|
-
return pendingTask
|
|
220
|
+
return pendingTask
|
|
221
|
+
? workflowNextIntent('tasks', 'inspect_task', `sdd tasks inspect ${pendingTask.id} --branch ${context.partition}`, 'Inspect task boundary, acceptance, validation, and capability needs before do/test.', null)
|
|
222
|
+
: workflowNextIntent('tasks', 'list_tasks', `sdd tasks list --branch ${context.partition}`, 'Inspect task state and decide whether to continue or ship.', null);
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
function latestRuntimeTaskStates(selections: LatestEligibleRunSelection[], states: RunState[]): Map<string, RunStateTaskRuntime> {
|
|
226
|
+
const stateByRunId = new Map(states.map((state) => [state.runId, state]));
|
|
227
|
+
const result = new Map<string, RunStateTaskRuntime>();
|
|
228
|
+
for (const selection of selections) {
|
|
229
|
+
const selected = selection.selected;
|
|
230
|
+
if (!selected) {
|
|
231
|
+
continue;
|
|
232
|
+
}
|
|
233
|
+
const taskState = stateByRunId.get(selected.runId)?.tasks[selected.taskId];
|
|
234
|
+
if (taskState) {
|
|
235
|
+
result.set(selected.taskId, taskState);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
return result;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
function needsTaskValidation(task: SddTask, runtime: RunStateTaskRuntime | undefined): boolean {
|
|
242
|
+
return Boolean(runtimeTaskImplemented(runtime) && runtime?.verificationStatus !== 'pass' && (task.requiresVerifyBeforeNext || task.validationTiming === 'task_end'));
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
function readyValidationBoundary(model: SddTaskModel, runtimeByTask: Map<string, RunStateTaskRuntime>): { kind: 'batch'; id: string } | { kind: 'wave'; wave: number | null } | null {
|
|
246
|
+
const batchGroups = new Map<string, SddTask[]>();
|
|
247
|
+
const waveGroups = new Map<string, { wave: number | null; tasks: SddTask[] }>();
|
|
248
|
+
for (const task of model.tasks) {
|
|
249
|
+
if (task.validationTiming === 'batch_end' && task.validationBatch) {
|
|
250
|
+
batchGroups.set(task.validationBatch, [...(batchGroups.get(task.validationBatch) ?? []), task]);
|
|
251
|
+
}
|
|
252
|
+
if (task.validationTiming === 'wave_end') {
|
|
253
|
+
const key = String(task.wave ?? 'all');
|
|
254
|
+
const group = waveGroups.get(key) ?? { wave: task.wave, tasks: [] };
|
|
255
|
+
group.tasks.push(task);
|
|
256
|
+
waveGroups.set(key, group);
|
|
257
|
+
}
|
|
258
|
+
}
|
|
259
|
+
for (const [id, tasks] of batchGroups) {
|
|
260
|
+
if (validationBoundaryReady(tasks, runtimeByTask)) {
|
|
261
|
+
return { kind: 'batch', id };
|
|
262
|
+
}
|
|
263
|
+
}
|
|
264
|
+
for (const group of waveGroups.values()) {
|
|
265
|
+
if (validationBoundaryReady(group.tasks, runtimeByTask)) {
|
|
266
|
+
return { kind: 'wave', wave: group.wave };
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
return null;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
function validationBoundaryReady(tasks: SddTask[], runtimeByTask: Map<string, RunStateTaskRuntime>): boolean {
|
|
273
|
+
return tasks.every((task) => runtimeTaskImplemented(runtimeByTask.get(task.id)))
|
|
274
|
+
&& tasks.some((task) => runtimeByTask.get(task.id)?.verificationStatus !== 'pass');
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
function runtimeTaskImplemented(runtime: RunStateTaskRuntime | undefined): boolean {
|
|
278
|
+
return runtime?.implementationStatus === 'implemented' || runtime?.status === 'implemented_pending_validation' || runtime?.status === 'implemented_verified';
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
function latestEligibleRunReadyForShip(run: WorkflowLatestTaskRun): boolean {
|
|
282
|
+
return run.runStatus === 'completed' && run.validationStatus === 'pass';
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
function waveValidationCommand(branch: string, wave: number | null): string {
|
|
286
|
+
return wave === null ? `sdd test wave --branch ${branch}` : `sdd test wave --branch ${branch} --wave ${wave}`;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
function workflowNextIntent(
|
|
291
|
+
stage: WorkflowNextStage,
|
|
292
|
+
intent: WorkflowNextIntentKind,
|
|
293
|
+
canonicalCommand: string,
|
|
294
|
+
evidenceRequirement: string,
|
|
295
|
+
blockingReason: string | null
|
|
296
|
+
): WorkflowNextIntent {
|
|
297
|
+
return {
|
|
298
|
+
stage,
|
|
299
|
+
intent,
|
|
300
|
+
canonicalCommand,
|
|
301
|
+
commandSemantics: stage === 'do' || stage === 'test' || stage === 'ship' ? 'gate_execution' : 'inspection_navigation',
|
|
302
|
+
evidenceRequirement,
|
|
303
|
+
blockingReason,
|
|
304
|
+
hostProjections: hostCommandProjections(canonicalCommand)
|
|
305
|
+
};
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
function hostCommandProjections(canonicalCommand: string): WorkflowHostCommandProjection[] {
|
|
309
|
+
return [
|
|
310
|
+
{
|
|
311
|
+
host: 'claude_code',
|
|
312
|
+
status: 'active',
|
|
313
|
+
entry: claudeCodeSlashEntry(canonicalCommand),
|
|
314
|
+
projectionSurfaces: ['slash command', 'skill', 'settings/hooks/statusline metadata'],
|
|
315
|
+
permissionProjection: 'Claude Code permission mode/tool prompts remain host enforcement, not SDD lifecycle truth.',
|
|
316
|
+
reason: 'Claude Code supports slash/skill/statusline projections; the canonical CLI command remains the portable source of workflow intent.'
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
host: 'codex',
|
|
320
|
+
status: 'future',
|
|
321
|
+
entry: null,
|
|
322
|
+
projectionSurfaces: ['config.toml profile', 'AGENTS.md instruction surface', 'approval_policy', 'sandbox_mode'],
|
|
323
|
+
permissionProjection: 'Codex approval and sandbox controls can project execution policy; custom command/skill projection is not marked active without stronger evidence.',
|
|
324
|
+
reason: 'Codex exposes approval, sandbox, AGENTS.md, and built-in slash surfaces, but project custom workflow command semantics stay future until validated.'
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
host: 'opencode',
|
|
328
|
+
status: 'active',
|
|
329
|
+
entry: opencodeCommandEntry(canonicalCommand),
|
|
330
|
+
projectionSurfaces: ['opencode.json/jsonc', '.opencode/commands', '.opencode/agents', '.opencode/skills', 'permissions'],
|
|
331
|
+
permissionProjection: 'OpenCode allow/ask/deny permissions can project SDD tool policy; SDD artifacts remain authoritative evidence.',
|
|
332
|
+
reason: 'OpenCode documents project commands, agents, skills, and permissions suitable for host-specific projection.'
|
|
333
|
+
}
|
|
334
|
+
];
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
function claudeCodeSlashEntry(canonicalCommand: string): string {
|
|
338
|
+
const [command, ...rest] = canonicalCommand.replace(/^sdd\s+/, '').split(' ');
|
|
339
|
+
return `/sdd:${command}${rest.length > 0 ? ` ${rest.join(' ')}` : ''}`;
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
function opencodeCommandEntry(canonicalCommand: string): string {
|
|
343
|
+
return `/sdd ${canonicalCommand.replace(/^sdd\s+/, '')}`;
|
|
158
344
|
}
|
|
159
345
|
|
|
160
346
|
function projectWorkflowStateProjection(resolution: WorkflowStateResolution): unknown {
|
|
@@ -167,9 +353,11 @@ function projectWorkflowStateProjection(resolution: WorkflowStateResolution): un
|
|
|
167
353
|
taskCounts: resolution.taskCounts,
|
|
168
354
|
latestRun: resolution.latestRun,
|
|
169
355
|
latestRunsByTask: resolution.latestRunsByTask,
|
|
356
|
+
latestEligibleRunsByTask: resolution.latestEligibleRunsByTask,
|
|
170
357
|
affectedFileConflicts: resolution.affectedFileConflicts,
|
|
171
358
|
dependencyBlockers: resolution.dependencyBlockers,
|
|
172
359
|
blockingReasons: resolution.blockingReasons,
|
|
360
|
+
nextIntent: resolution.nextIntent,
|
|
173
361
|
recommendedNextCommand: resolution.recommendedNextCommand
|
|
174
362
|
};
|
|
175
363
|
}
|
package/package.json
CHANGED
|
@@ -11,14 +11,14 @@ export async function handleStatusCommand(projectRoot, command, subcommand, rest
|
|
|
11
11
|
const projection = await getStatuslineProjection(projectRoot, readBranchContext(statusArgs));
|
|
12
12
|
const json = wantsJson(statusArgs);
|
|
13
13
|
return {
|
|
14
|
-
exitCode:
|
|
14
|
+
exitCode: 0,
|
|
15
15
|
output: json ? jsonOutput(projection, statusArgs) : renderStatuslineProjection(projection)
|
|
16
16
|
};
|
|
17
17
|
}
|
|
18
18
|
const result = await getProjectStatus(projectRoot, readBranchContext(statusArgs));
|
|
19
19
|
const json = wantsJson(statusArgs);
|
|
20
20
|
return {
|
|
21
|
-
exitCode:
|
|
21
|
+
exitCode: 0,
|
|
22
22
|
output: json ? jsonOutput(result, statusArgs) : renderProjectStatus(result)
|
|
23
23
|
};
|
|
24
24
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/commands/status.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAC5F,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,0BAA0B,EAAE,MAAM,0BAA0B,CAAC;AAQ3F,MAAM,CAAC,KAAK,UAAU,mBAAmB,CAAC,WAAmB,EAAE,OAA2B,EAAE,UAA8B,EAAE,IAAc;IACxI,IAAI,OAAO,KAAK,QAAQ,IAAI,OAAO,KAAK,YAAY,IAAI,OAAO,KAAK,UAAU,EAAE,CAAC;QAC/E,OAAO,IAAI,CAAC;IACd,CAAC;IAED,MAAM,UAAU,GAAG,CAAC,UAAU,EAAE,GAAG,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,EAAkB,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;IACzF,IAAI,OAAO,KAAK,YAAY,IAAI,OAAO,KAAK,UAAU,IAAI,UAAU,CAAC,QAAQ,CAAC,cAAc,CAAC,EAAE,CAAC;QAC9F,MAAM,UAAU,GAAG,MAAM,uBAAuB,CAAC,WAAW,EAAE,iBAAiB,CAAC,UAAU,CAAC,CAAC,CAAC;QAC7F,MAAM,IAAI,GAAG,SAAS,CAAC,UAAU,CAAC,CAAC;QACnC,OAAO;YACL,QAAQ,EAAE,
|
|
1
|
+
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/commands/status.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE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MAAM,EAAE,IAAI,CAAC,CAAC,CAAC,UAAU,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC,mBAAmB,CAAC,MAAM,CAAC;KAC5E,CAAC;AACJ,CAAC"}
|
|
@@ -30,7 +30,7 @@ export async function handleSyncBackCommand(projectRoot, command, subcommand, re
|
|
|
30
30
|
});
|
|
31
31
|
const json = wantsJson(rest);
|
|
32
32
|
return {
|
|
33
|
-
exitCode:
|
|
33
|
+
exitCode: 0,
|
|
34
34
|
output: json ? jsonOutput(result, rest) : renderSyncBackInspection(result)
|
|
35
35
|
};
|
|
36
36
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sync-back.js","sourceRoot":"","sources":["../../src/commands/sync-back.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,gBAAgB,EAAE,8BAA8B,EAAE,MAAM,YAAY,CAAC;AAC9E,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC1E,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAC7D,OAAO,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAQ/F,MAAM,CAAC,KAAK,UAAU,qBAAqB,CAAC,WAAmB,EAAE,OAA2B,EAAE,UAA8B,EAAE,IAAc;IAC1I,IAAI,OAAO,KAAK,WAAW,EAAE,CAAC;QAC5B,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,WAAW,CAAC,CAAC,UAAU,EAAE,GAAG,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,EAAkB,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC;QACvF,OAAO;YACL,QAAQ,EAAE,CAAC;YACX,M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K,IAAI,IAAI,EAAE,MAAM,EAAE,MAAM,IAAI,IAAI,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,EAAE,IAAI,CAAC,CAAC;IACnL,CAAC;IACD,OAAO,4DAA4D,KAAK,IAAI,QAAQ,UAAU,MAAM,IAAI,MAAM,qBAAqB,CAAC;AACtI,CAAC"}
|
|
@@ -19,7 +19,7 @@ export async function handleTasksCommand(projectRoot, command, subcommand, rest)
|
|
|
19
19
|
if (subcommand === 'list') {
|
|
20
20
|
const model = await parseSddBranch(projectRoot, await readResolvedBranch(projectRoot, rest));
|
|
21
21
|
return {
|
|
22
|
-
exitCode:
|
|
22
|
+
exitCode: 0,
|
|
23
23
|
output: renderTaskList(model)
|
|
24
24
|
};
|
|
25
25
|
}
|
|
@@ -41,7 +41,7 @@ export async function handleTasksCommand(projectRoot, command, subcommand, rest)
|
|
|
41
41
|
}
|
|
42
42
|
const json = wantsJson(rest);
|
|
43
43
|
return {
|
|
44
|
-
exitCode: result.task === null
|
|
44
|
+
exitCode: result.task === null ? 1 : 0,
|
|
45
45
|
output: json ? jsonOutput(result, rest) : renderTaskInspect(result.task, result.gaps)
|
|
46
46
|
};
|
|
47
47
|
}
|
|
@@ -62,14 +62,14 @@ export async function handleTasksCommand(projectRoot, command, subcommand, rest)
|
|
|
62
62
|
approved: rest.includes('--approved'),
|
|
63
63
|
});
|
|
64
64
|
return {
|
|
65
|
-
exitCode:
|
|
65
|
+
exitCode: 0,
|
|
66
66
|
output: wantsJson(rest) ? jsonOutput(decision, rest) : renderAgentRouterDecision(decision)
|
|
67
67
|
};
|
|
68
68
|
}
|
|
69
69
|
if (subcommand === 'gaps') {
|
|
70
70
|
const model = await parseSddBranch(projectRoot, await readResolvedBranch(projectRoot, rest));
|
|
71
71
|
return {
|
|
72
|
-
exitCode:
|
|
72
|
+
exitCode: 0,
|
|
73
73
|
output: renderTaskGapReport(model)
|
|
74
74
|
};
|
|
75
75
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tasks.js","sourceRoot":"","sources":["../../src/commands/tasks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAC3G,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AAC1F,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAC7D,OAAO,EAAE,yBAAyB,EAAE,MAAM,wBAAwB,CAAC;AAQnE,MAAM,CAAC,KAAK,UAAU,kBAAkB,CAAC,WAAmB,EAAE,OAA2B,EAAE,UAA8B,EAAE,IAAc;IACvI,IAAI,OAAO,KAAK,OAAO,EAAE,CAAC;QACxB,OAAO,IAAI,CAAC;IACd,CAAC;IAED,IAAI,UAAU,KAAK,QAAQ,EAAE,CAAC;QAC5B,OAAO;YACL,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,cAAc,EAAE;SACzB,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,MAAM,EAAE,CAAC;QAC1B,MAAM,KAAK,GAAG,MAAM,cAAc,CAAC,WAAW,EAAE,MAAM,kBAAkB,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC,CAAC;QAC7F,OAAO;YACL,QAAQ,EAAE,
|
|
1
|
+
{"version":3,"file":"tasks.js","sourceRoot":"","sources":["../../src/commands/tasks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAA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AW,CAAC;YACnC,KAAK,EAAE,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC;YAC/B,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC;SACtC,CAAC,CAAC;QACH,OAAO;YACL,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,yBAAyB,CAAC,QAAQ,CAAC;SAC3F,CAAC;IACJ,CAAC;IAED,IAAI,UAAU,KAAK,MAAM,EAAE,CAAC;QAC1B,MAAM,KAAK,GAAG,MAAM,cAAc,CAAC,WAAW,EAAE,MAAM,kBAAkB,CAAC,WAAW,EAAE,IAAI,CAAC,CAAC,CAAC;QAC7F,OAAO;YACL,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,mBAAmB,CAAC,KAAK,CAAC;SACnC,CAAC;IACJ,CAAC;IAED,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { readFile } from 'node:fs/promises';
|
|
2
2
|
import path from 'node:path';
|
|
3
|
-
import { renderSddTestResult, runSddTest } from '@sdd-agent-platform/core/verification';
|
|
4
|
-
import {
|
|
3
|
+
import { renderSddTestResult, renderValidationWaveResult, runSddTest, runValidationWave } from '@sdd-agent-platform/core/verification';
|
|
4
|
+
import { parseSddBranch } from '@sdd-agent-platform/core/sdd-docs';
|
|
5
|
+
import { readBranchOption, readOptionalPositionalArgument, readResolvedBranch } from '../args.js';
|
|
5
6
|
import { hasHelpFlag, hasPreflightFlag, readOption, readPositiveIntegerOption, readRepeatedOptions } from '../options.js';
|
|
6
7
|
import { jsonOutput, wantsJson } from '../renderers/json.js';
|
|
7
8
|
export async function handleTestCommand(projectRoot, command, subcommand, rest) {
|
|
@@ -11,13 +12,19 @@ export async function handleTestCommand(projectRoot, command, subcommand, rest)
|
|
|
11
12
|
if (hasHelpFlag([subcommand, ...rest].filter((item) => Boolean(item)))) {
|
|
12
13
|
return {
|
|
13
14
|
exitCode: 0,
|
|
14
|
-
output:
|
|
15
|
+
output: testUsage()
|
|
15
16
|
};
|
|
16
17
|
}
|
|
18
|
+
if (subcommand === 'wave') {
|
|
19
|
+
return handleTestWaveCommand(projectRoot, rest);
|
|
20
|
+
}
|
|
21
|
+
if (subcommand === 'batch') {
|
|
22
|
+
return handleTestBatchCommand(projectRoot, rest);
|
|
23
|
+
}
|
|
17
24
|
if (subcommand !== 'task') {
|
|
18
25
|
return {
|
|
19
26
|
exitCode: 2,
|
|
20
|
-
error:
|
|
27
|
+
error: testUsage()
|
|
21
28
|
};
|
|
22
29
|
}
|
|
23
30
|
const passthroughIndex = rest.indexOf('--');
|
|
@@ -36,6 +43,25 @@ export async function handleTestCommand(projectRoot, command, subcommand, rest)
|
|
|
36
43
|
output: wantsJson(cliArgs) ? jsonOutput({ contract: 'sdd-command-preflight-v1', command: 'test task', taskId, sideEffects: 'none', status: 'PASS' }, cliArgs) : `SDD command preflight PASS\ncommand=test task\ntask=${taskId}\nside_effects=none`
|
|
37
44
|
};
|
|
38
45
|
}
|
|
46
|
+
const branch = readBranchOption(cliArgs);
|
|
47
|
+
const explicitSingleTaskOverride = hasSingleTaskOverride(cliArgs, passthroughArgv);
|
|
48
|
+
if (!explicitSingleTaskOverride) {
|
|
49
|
+
const model = await parseSddBranch(projectRoot, await readResolvedBranch(projectRoot, cliArgs));
|
|
50
|
+
const task = model.tasks.find((candidate) => candidate.id === taskId) ?? null;
|
|
51
|
+
if (task && shouldValidateAsGroupedBoundary(task)) {
|
|
52
|
+
const result = await runValidationWave(projectRoot, {
|
|
53
|
+
branch,
|
|
54
|
+
batchId: task.validationTiming === 'batch_end' ? task.validationBatch ?? undefined : undefined,
|
|
55
|
+
wave: task.validationTiming === 'wave_end' ? task.wave ?? undefined : undefined,
|
|
56
|
+
timeoutMs: readPositiveIntegerOption(cliArgs, '--timeout-ms') ?? undefined,
|
|
57
|
+
approved: cliArgs.includes('--approved')
|
|
58
|
+
});
|
|
59
|
+
return {
|
|
60
|
+
exitCode: result.status === 'PASS' ? 0 : 1,
|
|
61
|
+
output: wantsJson(cliArgs) ? jsonOutput(result, cliArgs) : renderValidationWaveResult(result)
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
}
|
|
39
65
|
let commandInputs;
|
|
40
66
|
try {
|
|
41
67
|
commandInputs = await readCommandInputs(projectRoot, cliArgs, passthroughArgv);
|
|
@@ -48,7 +74,7 @@ export async function handleTestCommand(projectRoot, command, subcommand, rest)
|
|
|
48
74
|
}
|
|
49
75
|
const result = await runSddTest(projectRoot, {
|
|
50
76
|
taskId,
|
|
51
|
-
branch
|
|
77
|
+
branch,
|
|
52
78
|
runId: readOption(cliArgs, '--run') ?? undefined,
|
|
53
79
|
commands: readRepeatedOptions(cliArgs, '--command'),
|
|
54
80
|
commandInputs,
|
|
@@ -60,6 +86,60 @@ export async function handleTestCommand(projectRoot, command, subcommand, rest)
|
|
|
60
86
|
output: wantsJson(cliArgs) ? jsonOutput(result, cliArgs) : renderSddTestResult(result)
|
|
61
87
|
};
|
|
62
88
|
}
|
|
89
|
+
async function handleTestWaveCommand(projectRoot, rest) {
|
|
90
|
+
if (hasPreflightFlag(rest)) {
|
|
91
|
+
return {
|
|
92
|
+
exitCode: 0,
|
|
93
|
+
output: wantsJson(rest) ? jsonOutput({ contract: 'sdd-command-preflight-v1', command: 'test wave', sideEffects: 'none', status: 'PASS' }, rest) : 'SDD command preflight PASS\ncommand=test wave\nside_effects=none'
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
const result = await runValidationWave(projectRoot, {
|
|
97
|
+
branch: readBranchOption(rest),
|
|
98
|
+
wave: readPositiveIntegerOption(rest, '--wave') ?? undefined,
|
|
99
|
+
taskIds: readRepeatedOptions(rest, '--task'),
|
|
100
|
+
timeoutMs: readPositiveIntegerOption(rest, '--timeout-ms') ?? undefined,
|
|
101
|
+
approved: rest.includes('--approved')
|
|
102
|
+
});
|
|
103
|
+
return {
|
|
104
|
+
exitCode: result.status === 'PASS' ? 0 : 1,
|
|
105
|
+
output: wantsJson(rest) ? jsonOutput(result, rest) : renderValidationWaveResult(result)
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
async function handleTestBatchCommand(projectRoot, rest) {
|
|
109
|
+
const batchId = readOptionalPositionalArgument(rest);
|
|
110
|
+
if (!batchId) {
|
|
111
|
+
return {
|
|
112
|
+
exitCode: 2,
|
|
113
|
+
error: testBatchUsage()
|
|
114
|
+
};
|
|
115
|
+
}
|
|
116
|
+
if (hasPreflightFlag(rest)) {
|
|
117
|
+
return {
|
|
118
|
+
exitCode: 0,
|
|
119
|
+
output: wantsJson(rest) ? jsonOutput({ contract: 'sdd-command-preflight-v1', command: 'test batch', batchId, sideEffects: 'none', status: 'PASS' }, rest) : `SDD command preflight PASS\ncommand=test batch\nbatch=${batchId}\nside_effects=none`
|
|
120
|
+
};
|
|
121
|
+
}
|
|
122
|
+
const result = await runValidationWave(projectRoot, {
|
|
123
|
+
branch: readBranchOption(rest),
|
|
124
|
+
batchId,
|
|
125
|
+
timeoutMs: readPositiveIntegerOption(rest, '--timeout-ms') ?? undefined,
|
|
126
|
+
approved: rest.includes('--approved')
|
|
127
|
+
});
|
|
128
|
+
return {
|
|
129
|
+
exitCode: result.status === 'PASS' ? 0 : 1,
|
|
130
|
+
output: wantsJson(rest) ? jsonOutput(result, rest) : renderValidationWaveResult(result)
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
function hasSingleTaskOverride(cliArgs, passthroughArgv) {
|
|
134
|
+
return Boolean(readOption(cliArgs, '--run')
|
|
135
|
+
|| readRepeatedOptions(cliArgs, '--command').length > 0
|
|
136
|
+
|| readRepeatedOptions(cliArgs, '--command-json').length > 0
|
|
137
|
+
|| readRepeatedOptions(cliArgs, '--command-file').length > 0
|
|
138
|
+
|| passthroughArgv.length > 0);
|
|
139
|
+
}
|
|
140
|
+
function shouldValidateAsGroupedBoundary(task) {
|
|
141
|
+
return Boolean(task.validationBatch && !task.requiresVerifyBeforeNext && (task.validationTiming === 'batch_end' || task.validationTiming === 'wave_end'));
|
|
142
|
+
}
|
|
63
143
|
async function readCommandInputs(projectRoot, cliArgs, passthroughArgv) {
|
|
64
144
|
const commandInputs = readRepeatedOptions(cliArgs, '--command').map((command) => ({ command }));
|
|
65
145
|
const commandJsonValues = readRepeatedOptions(cliArgs, '--command-json');
|
|
@@ -100,7 +180,16 @@ function parseCommandInputValue(value) {
|
|
|
100
180
|
}
|
|
101
181
|
throw new Error('Command JSON object must include command or argv.');
|
|
102
182
|
}
|
|
183
|
+
function testUsage() {
|
|
184
|
+
return `${testTaskUsage()}\n${testWaveUsage()}\n${testBatchUsage()}`;
|
|
185
|
+
}
|
|
103
186
|
function testTaskUsage() {
|
|
104
187
|
return 'Usage: sdd test task <task_id> [--branch <branch>] [--run <run_id>] [--approved] [--command <command>] [--command-json <json>] [--command-file <path>] [--timeout-ms <ms>] [--preflight] [--json] [-- <executable> [...args]]';
|
|
105
188
|
}
|
|
189
|
+
function testWaveUsage() {
|
|
190
|
+
return 'Usage: sdd test wave [--branch <branch>] [--wave <n>] [--task <task_id>]... [--approved] [--timeout-ms <ms>] [--preflight] [--json]';
|
|
191
|
+
}
|
|
192
|
+
function testBatchUsage() {
|
|
193
|
+
return 'Usage: sdd test batch <batch_id> [--branch <branch>] [--approved] [--timeout-ms <ms>] [--preflight] [--json]';
|
|
194
|
+
}
|
|
106
195
|
//# sourceMappingURL=test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"test.js","sourceRoot":"","sources":["../../src/commands/test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,mBAAmB,EAAE,UAAU,EAA4B,MAAM,uCAAuC,CAAC;
|
|
1
|
+
{"version":3,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