@intentius/chant 0.124.52 → 0.124.54
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/dist/audit/discover.d.ts.map +1 -1
- package/dist/audit/discover.js +3 -1
- package/dist/behaviour.d.ts +1 -1
- package/dist/behaviour.d.ts.map +1 -1
- package/dist/capabilities/templates.d.ts +65 -0
- package/dist/capabilities/templates.d.ts.map +1 -0
- package/dist/capabilities/templates.js +193 -0
- package/dist/capabilities/templates.json +145 -0
- package/dist/change-set-graph.d.ts +35 -3
- package/dist/change-set-graph.d.ts.map +1 -1
- package/dist/change-set-graph.js +60 -9
- package/dist/change-set.d.ts +65 -7
- package/dist/change-set.d.ts.map +1 -1
- package/dist/change-set.js +23 -12
- package/dist/ci-identity.d.ts +7 -2
- package/dist/ci-identity.d.ts.map +1 -1
- package/dist/ci-identity.js +4 -1
- package/dist/cli/commands/import-index.d.ts +52 -0
- package/dist/cli/commands/import-index.d.ts.map +1 -0
- package/dist/cli/commands/import-index.js +226 -0
- package/dist/cli/commands/lint.d.ts.map +1 -1
- package/dist/cli/commands/lint.js +4 -2
- package/dist/cli/handlers/components.d.ts.map +1 -1
- package/dist/cli/handlers/components.js +11 -2
- package/dist/cli/handlers/fan-out.d.ts.map +1 -1
- package/dist/cli/handlers/fan-out.js +16 -3
- package/dist/cli/handlers/graph.d.ts.map +1 -1
- package/dist/cli/handlers/graph.js +22 -4
- package/dist/cli/handlers/index-cloud.d.ts +14 -0
- package/dist/cli/handlers/index-cloud.d.ts.map +1 -0
- package/dist/cli/handlers/index-cloud.js +22 -0
- package/dist/cli/handlers/index-diff.d.ts +18 -0
- package/dist/cli/handlers/index-diff.d.ts.map +1 -0
- package/dist/cli/handlers/index-diff.js +142 -0
- package/dist/cli/handlers/lifecycle-drift.d.ts +25 -0
- package/dist/cli/handlers/lifecycle-drift.d.ts.map +1 -0
- package/dist/cli/handlers/lifecycle-drift.js +64 -0
- package/dist/cli/handlers/lifecycle.d.ts.map +1 -1
- package/dist/cli/handlers/lifecycle.js +188 -28
- package/dist/cli/handlers/misc.d.ts +9 -0
- package/dist/cli/handlers/misc.d.ts.map +1 -1
- package/dist/cli/handlers/misc.js +77 -0
- package/dist/cli/handlers/pr.d.ts.map +1 -1
- package/dist/cli/handlers/pr.js +15 -2
- package/dist/cli/handlers/promote.d.ts.map +1 -1
- package/dist/cli/handlers/promote.js +89 -15
- package/dist/cli/handlers/query.d.ts.map +1 -1
- package/dist/cli/handlers/query.js +28 -4
- package/dist/cli/handlers/scenario.d.ts.map +1 -1
- package/dist/cli/handlers/scenario.js +8 -7
- package/dist/cli/handlers/search.d.ts +34 -4
- package/dist/cli/handlers/search.d.ts.map +1 -1
- package/dist/cli/handlers/search.js +216 -36
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +55 -1
- package/dist/cli/mcp/lifecycle-tools.d.ts.map +1 -1
- package/dist/cli/mcp/lifecycle-tools.js +3 -2
- package/dist/cli/mcp/resource-handlers.d.ts.map +1 -1
- package/dist/cli/mcp/resource-handlers.js +4 -3
- package/dist/cli/mcp/workspace-tools.js +1 -1
- package/dist/cli/parse-args.d.ts.map +1 -1
- package/dist/cli/parse-args.js +55 -2
- package/dist/cli/registry.d.ts +19 -1
- package/dist/cli/registry.d.ts.map +1 -1
- package/dist/cloud-lister/aws.d.ts +35 -0
- package/dist/cloud-lister/aws.d.ts.map +1 -0
- package/dist/cloud-lister/aws.js +203 -0
- package/dist/cloud-lister/azure.d.ts +34 -0
- package/dist/cloud-lister/azure.d.ts.map +1 -0
- package/dist/cloud-lister/azure.js +129 -0
- package/dist/cloud-lister/common.d.ts +40 -0
- package/dist/cloud-lister/common.d.ts.map +1 -0
- package/dist/cloud-lister/common.js +83 -0
- package/dist/cloud-lister/credentials.d.ts +50 -0
- package/dist/cloud-lister/credentials.d.ts.map +1 -0
- package/dist/cloud-lister/credentials.js +86 -0
- package/dist/cloud-lister/fakes.d.ts +27 -0
- package/dist/cloud-lister/fakes.d.ts.map +1 -0
- package/dist/cloud-lister/fakes.js +50 -0
- package/dist/cloud-lister/gcp.d.ts +42 -0
- package/dist/cloud-lister/gcp.d.ts.map +1 -0
- package/dist/cloud-lister/gcp.js +143 -0
- package/dist/cloud-lister/guard.d.ts +49 -0
- package/dist/cloud-lister/guard.d.ts.map +1 -0
- package/dist/cloud-lister/guard.js +103 -0
- package/dist/cloud-lister/ids.d.ts +23 -0
- package/dist/cloud-lister/ids.d.ts.map +1 -0
- package/dist/cloud-lister/ids.js +42 -0
- package/dist/cloud-lister/index.d.ts +67 -0
- package/dist/cloud-lister/index.d.ts.map +1 -0
- package/dist/cloud-lister/index.js +102 -0
- package/dist/cloud-lister/kubernetes.d.ts +64 -0
- package/dist/cloud-lister/kubernetes.d.ts.map +1 -0
- package/dist/cloud-lister/kubernetes.js +276 -0
- package/dist/cloud-lister/markers.d.ts +31 -0
- package/dist/cloud-lister/markers.d.ts.map +1 -0
- package/dist/cloud-lister/markers.js +73 -0
- package/dist/cloud-lister/mask.d.ts +31 -0
- package/dist/cloud-lister/mask.d.ts.map +1 -0
- package/dist/cloud-lister/mask.js +74 -0
- package/dist/cloud-lister/sigv4.d.ts +29 -0
- package/dist/cloud-lister/sigv4.d.ts.map +1 -0
- package/dist/cloud-lister/sigv4.js +54 -0
- package/dist/cloud-lister/transport.d.ts +55 -0
- package/dist/cloud-lister/transport.d.ts.map +1 -0
- package/dist/cloud-lister/transport.js +86 -0
- package/dist/cloud-lister/types.d.ts +121 -0
- package/dist/cloud-lister/types.d.ts.map +1 -0
- package/dist/cloud-lister/types.js +24 -0
- package/dist/components/capability-plugin-loader.d.ts.map +1 -1
- package/dist/components/capability-plugin-loader.js +6 -0
- package/dist/components/capability-plugin.d.ts +9 -0
- package/dist/components/capability-plugin.d.ts.map +1 -1
- package/dist/components/capability.d.ts +215 -0
- package/dist/components/capability.d.ts.map +1 -1
- package/dist/components/cli-support.d.ts +21 -0
- package/dist/components/cli-support.d.ts.map +1 -1
- package/dist/components/cli-support.js +58 -14
- package/dist/components/declared-reads.d.ts +38 -0
- package/dist/components/declared-reads.d.ts.map +1 -0
- package/dist/components/declared-reads.js +131 -0
- package/dist/components/deploy-units.d.ts.map +1 -1
- package/dist/components/deploy-units.js +4 -0
- package/dist/components/driver.d.ts +34 -1
- package/dist/components/driver.d.ts.map +1 -1
- package/dist/components/driver.js +66 -3
- package/dist/components/fan-out-run.d.ts +23 -1
- package/dist/components/fan-out-run.d.ts.map +1 -1
- package/dist/components/fan-out-run.js +82 -14
- package/dist/components/fan-out-support.d.ts +6 -0
- package/dist/components/fan-out-support.d.ts.map +1 -1
- package/dist/components/fan-out-support.js +4 -1
- package/dist/components/fan-out.d.ts +28 -0
- package/dist/components/fan-out.d.ts.map +1 -1
- package/dist/components/groups.d.ts +229 -0
- package/dist/components/groups.d.ts.map +1 -0
- package/dist/components/groups.js +760 -0
- package/dist/components/index.d.ts +6 -2
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +4 -0
- package/dist/components/plan-shape-conformance.d.ts +48 -0
- package/dist/components/plan-shape-conformance.d.ts.map +1 -0
- package/dist/components/plan-shape-conformance.js +122 -0
- package/dist/components/pr-run.d.ts +41 -4
- package/dist/components/pr-run.d.ts.map +1 -1
- package/dist/components/pr-run.js +209 -39
- package/dist/components/promote-rounds.d.ts +9 -0
- package/dist/components/promote-rounds.d.ts.map +1 -1
- package/dist/components/promote-rounds.js +23 -2
- package/dist/components/promote.d.ts +17 -0
- package/dist/components/promote.d.ts.map +1 -1
- package/dist/components/promote.js +36 -6
- package/dist/components/release-gate.d.ts +23 -1
- package/dist/components/release-gate.d.ts.map +1 -1
- package/dist/components/release-gate.js +97 -33
- package/dist/components/run-groups.d.ts +58 -0
- package/dist/components/run-groups.d.ts.map +1 -0
- package/dist/components/run-groups.js +78 -0
- package/dist/components/starter-plugin.d.ts +1 -0
- package/dist/components/starter-plugin.d.ts.map +1 -1
- package/dist/components/starter-plugin.js +6 -1
- package/dist/components/verbs/index.d.ts +1 -0
- package/dist/components/verbs/index.d.ts.map +1 -1
- package/dist/components/verbs/index.js +1 -0
- package/dist/components/verbs/member-outputs.d.ts +187 -0
- package/dist/components/verbs/member-outputs.d.ts.map +1 -0
- package/dist/components/verbs/member-outputs.js +218 -0
- package/dist/config.d.ts +60 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +27 -0
- package/dist/deep-observation.d.ts +1 -13
- package/dist/deep-observation.d.ts.map +1 -1
- package/dist/deep-observation.js +5 -22
- package/dist/drift-record.d.ts +542 -0
- package/dist/drift-record.d.ts.map +1 -0
- package/dist/drift-record.js +886 -0
- package/dist/engine-facts.d.ts +144 -0
- package/dist/engine-facts.d.ts.map +1 -0
- package/dist/engine-facts.js +14 -0
- package/dist/graph-ir.d.ts +153 -2
- package/dist/graph-ir.d.ts.map +1 -1
- package/dist/graph-ir.js +224 -6
- package/dist/graph-refs.d.ts +145 -0
- package/dist/graph-refs.d.ts.map +1 -1
- package/dist/graph-refs.js +305 -0
- package/dist/graph-schema/fixtures/adopt.json +15 -0
- package/dist/graph-schema/fixtures/choudoufu.engine-graph.json +169 -0
- package/dist/graph-schema/fixtures/index.json +68 -0
- package/dist/graph-schema/fixtures/plunge.engine-graph.json +158 -0
- package/dist/graph-schema/fixtures.d.ts +23 -0
- package/dist/graph-schema/fixtures.d.ts.map +1 -0
- package/dist/graph-schema/fixtures.js +246 -0
- package/dist/graph-schema/generate.d.ts +15 -0
- package/dist/graph-schema/generate.d.ts.map +1 -0
- package/dist/graph-schema/generate.js +267 -0
- package/dist/graph-schema/graph.schema.json +1387 -0
- package/dist/health.schema.json +2 -1
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/instance-nodes.d.ts +159 -0
- package/dist/instance-nodes.d.ts.map +1 -0
- package/dist/instance-nodes.js +231 -0
- package/dist/lexicon.d.ts +72 -0
- package/dist/lexicon.d.ts.map +1 -1
- package/dist/lifecycle/adoption-file.d.ts +56 -0
- package/dist/lifecycle/adoption-file.d.ts.map +1 -0
- package/dist/lifecycle/adoption-file.js +123 -0
- package/dist/lifecycle/cloud-index.d.ts +186 -0
- package/dist/lifecycle/cloud-index.d.ts.map +1 -0
- package/dist/lifecycle/cloud-index.js +618 -0
- package/dist/lifecycle/derive-edges.d.ts +59 -0
- package/dist/lifecycle/derive-edges.d.ts.map +1 -0
- package/dist/lifecycle/derive-edges.js +126 -0
- package/dist/lifecycle/git.d.ts +10 -9
- package/dist/lifecycle/git.d.ts.map +1 -1
- package/dist/lifecycle/git.js +7 -1
- package/dist/lifecycle/identity-match.d.ts +133 -0
- package/dist/lifecycle/identity-match.d.ts.map +1 -0
- package/dist/lifecycle/identity-match.js +147 -0
- package/dist/lifecycle/index-diff.d.ts +224 -0
- package/dist/lifecycle/index-diff.d.ts.map +1 -0
- package/dist/lifecycle/index-diff.js +327 -0
- package/dist/lifecycle/index-document.d.ts +130 -0
- package/dist/lifecycle/index-document.d.ts.map +1 -0
- package/dist/lifecycle/index-document.js +189 -0
- package/dist/lifecycle/index-drift.d.ts +121 -0
- package/dist/lifecycle/index-drift.d.ts.map +1 -0
- package/dist/lifecycle/index-drift.js +178 -0
- package/dist/lifecycle/index-import.d.ts +168 -0
- package/dist/lifecycle/index-import.d.ts.map +1 -0
- package/dist/lifecycle/index-import.js +515 -0
- package/dist/lifecycle/index-join.d.ts +129 -0
- package/dist/lifecycle/index-join.d.ts.map +1 -0
- package/dist/lifecycle/index-join.js +248 -0
- package/dist/lifecycle/index.d.ts +4 -0
- package/dist/lifecycle/index.d.ts.map +1 -1
- package/dist/lifecycle/index.js +4 -0
- package/dist/lifecycle/observation-baseline.d.ts +61 -21
- package/dist/lifecycle/observation-baseline.d.ts.map +1 -1
- package/dist/lifecycle/observation-baseline.js +144 -19
- package/dist/lifecycle/observe.d.ts.map +1 -1
- package/dist/lifecycle/observe.js +6 -1
- package/dist/lifecycle/query.d.ts +45 -4
- package/dist/lifecycle/query.d.ts.map +1 -1
- package/dist/lifecycle/query.js +89 -7
- package/dist/lifecycle/replay.d.ts +10 -3
- package/dist/lifecycle/replay.d.ts.map +1 -1
- package/dist/lifecycle/replay.js +10 -6
- package/dist/lifecycle/scenario.d.ts +4 -3
- package/dist/lifecycle/scenario.d.ts.map +1 -1
- package/dist/lifecycle/snapshot-store-fake.d.ts +9 -0
- package/dist/lifecycle/snapshot-store-fake.d.ts.map +1 -0
- package/dist/lifecycle/snapshot-store-fake.js +21 -0
- package/dist/lifecycle/snapshot-store-s3.d.ts +102 -0
- package/dist/lifecycle/snapshot-store-s3.d.ts.map +1 -0
- package/dist/lifecycle/snapshot-store-s3.js +254 -0
- package/dist/lifecycle/snapshot-store.d.ts +170 -0
- package/dist/lifecycle/snapshot-store.d.ts.map +1 -0
- package/dist/lifecycle/snapshot-store.js +832 -0
- package/dist/lifecycle/snapshot.d.ts +11 -0
- package/dist/lifecycle/snapshot.d.ts.map +1 -1
- package/dist/lifecycle/snapshot.js +18 -5
- package/dist/lifecycle/type-listing.d.ts +148 -0
- package/dist/lifecycle/type-listing.d.ts.map +1 -0
- package/dist/lifecycle/type-listing.js +166 -0
- package/dist/lint/component-checks.d.ts +15 -1
- package/dist/lint/component-checks.d.ts.map +1 -1
- package/dist/lint/component-checks.js +1 -0
- package/dist/lint/presets/relaxed.json +2 -1
- package/dist/lint/presets/strict.json +2 -1
- package/dist/lint/rules/__fixtures__/comp/comp008/fail/dns.component.d.ts +4 -0
- package/dist/lint/rules/__fixtures__/comp/comp008/fail/dns.component.d.ts.map +1 -0
- package/dist/lint/rules/__fixtures__/comp/comp008/fail/dns.component.js +13 -0
- package/dist/lint/rules/__fixtures__/comp/comp008/pass/dns.component.d.ts +4 -0
- package/dist/lint/rules/__fixtures__/comp/comp008/pass/dns.component.d.ts.map +1 -0
- package/dist/lint/rules/__fixtures__/comp/comp008/pass/dns.component.js +8 -0
- package/dist/lint/rules/comp/comp008-applies-signal-only-root.d.ts +33 -0
- package/dist/lint/rules/comp/comp008-applies-signal-only-root.d.ts.map +1 -0
- package/dist/lint/rules/comp/comp008-applies-signal-only-root.js +123 -0
- package/dist/lint/rules/comp/index.d.ts +2 -1
- package/dist/lint/rules/comp/index.d.ts.map +1 -1
- package/dist/lint/rules/comp/index.js +4 -1
- package/dist/observation.d.ts +19 -2
- package/dist/observation.d.ts.map +1 -1
- package/dist/observation.js +18 -1
- package/dist/op/activities/activity-contracts.d.ts +1 -1
- package/dist/op/activities/activity-contracts.js +1 -1
- package/dist/op/activities/change-set.d.ts +6 -4
- package/dist/op/activities/change-set.d.ts.map +1 -1
- package/dist/op/activities/change-set.js +4 -2
- package/dist/op/activity-failure.d.ts +27 -0
- package/dist/op/activity-failure.d.ts.map +1 -1
- package/dist/op/activity-failure.js +31 -0
- package/dist/op/index.d.ts +2 -1
- package/dist/op/index.d.ts.map +1 -1
- package/dist/op/index.js +1 -1
- package/dist/op/local-executor.d.ts +5 -1
- package/dist/op/local-executor.d.ts.map +1 -1
- package/dist/op/local-executor.js +22 -8
- package/dist/pr-loop.d.ts +56 -1
- package/dist/pr-loop.d.ts.map +1 -1
- package/dist/pr-loop.js +51 -1
- package/dist/pulumi-urn.d.ts +101 -0
- package/dist/pulumi-urn.d.ts.map +1 -0
- package/dist/pulumi-urn.js +131 -0
- package/dist/release-floors.d.ts +23 -0
- package/dist/release-floors.d.ts.map +1 -0
- package/dist/release-floors.js +22 -0
- package/dist/sensitive-key.d.ts +23 -0
- package/dist/sensitive-key.d.ts.map +1 -0
- package/dist/sensitive-key.js +31 -0
- package/dist/wave-runtime.mjs +234 -234
- package/dist/workspace/adoption-report.d.ts +53 -0
- package/dist/workspace/adoption-report.d.ts.map +1 -0
- package/dist/workspace/adoption-report.js +76 -0
- package/dist/workspace/capabilities-contract.d.ts +7 -0
- package/dist/workspace/capabilities-contract.d.ts.map +1 -1
- package/dist/workspace/capabilities-contract.js +2 -1
- package/dist/workspace/capabilities.schema.json +98 -0
- package/dist/workspace/change-set.schema.json +42 -3
- package/dist/workspace/ci-cloud-identity.d.ts +13 -1
- package/dist/workspace/ci-cloud-identity.d.ts.map +1 -1
- package/dist/workspace/ci-cloud-identity.js +30 -1
- package/dist/workspace/compose-graph.d.ts +10 -1
- package/dist/workspace/compose-graph.d.ts.map +1 -1
- package/dist/workspace/compose-graph.js +6 -1
- package/dist/workspace/conformance/index.d.ts +1 -1
- package/dist/workspace/conformance/index.d.ts.map +1 -1
- package/dist/workspace/conformance/index.js +6 -1
- package/dist/workspace/drift-cli.d.ts +81 -0
- package/dist/workspace/drift-cli.d.ts.map +1 -0
- package/dist/workspace/drift-cli.js +317 -0
- package/dist/workspace/drift.schema.json +672 -0
- package/dist/workspace/graph-cli.d.ts +2 -0
- package/dist/workspace/graph-cli.d.ts.map +1 -1
- package/dist/workspace/graph-cli.js +3 -0
- package/dist/workspace/graph.schema.json +72 -0
- package/dist/workspace/init.d.ts +5 -1
- package/dist/workspace/init.d.ts.map +1 -1
- package/dist/workspace/init.js +55 -9
- package/dist/workspace/ledger.schema.json +1 -1
- package/dist/workspace/nested-graph.d.ts.map +1 -1
- package/dist/workspace/nested-graph.js +2 -0
- package/dist/workspace/pr-report.schema.json +51 -2
- package/dist/workspace/promote-waves.d.ts +112 -0
- package/dist/workspace/promote-waves.d.ts.map +1 -0
- package/dist/workspace/promote-waves.js +290 -0
- package/dist/workspace/promote.d.ts +84 -2
- package/dist/workspace/promote.d.ts.map +1 -1
- package/dist/workspace/promote.js +347 -61
- package/dist/workspace/reason-codes.d.ts +12 -0
- package/dist/workspace/reason-codes.d.ts.map +1 -1
- package/dist/workspace/reason-codes.js +14 -0
- package/dist/workspace/search-contract.d.ts +3 -3
- package/dist/workspace/search-contract.d.ts.map +1 -1
- package/dist/workspace/search-contract.js +2 -0
- package/dist/workspace/search.schema.json +103 -5
- package/package.json +14 -1
- package/src/__fixtures__/drift-record/README.md +58 -0
- package/src/__fixtures__/drift-record/choudoufu-cone.ndjson +4 -0
- package/src/__fixtures__/drift-record/choudoufu-resource.ndjson +3 -0
- package/src/__fixtures__/drift-record/component-status-ledger.json +65 -0
- package/src/__fixtures__/drift-record/component-status.json +91 -0
- package/src/__fixtures__/drift-record/deep-diff.json +259 -0
- package/src/__fixtures__/drift-record/lifecycle-diff-live.json +825 -0
- package/src/__fixtures__/drift-record/live-diff.json +125 -0
- package/src/audit/discover.e2e.test.ts +14 -0
- package/src/audit/discover.ts +3 -1
- package/src/behaviour.ts +1 -1
- package/src/capabilities/templates.json +145 -0
- package/src/capabilities/templates.test.ts +212 -0
- package/src/capabilities/templates.ts +204 -0
- package/src/change-set-bundle.test.ts +83 -0
- package/src/change-set-graph.ts +80 -9
- package/src/change-set.test.ts +24 -0
- package/src/change-set.ts +77 -14
- package/src/ci-identity-targets.test.ts +23 -0
- package/src/ci-identity.ts +10 -4
- package/src/cli/commands/import-index.test.ts +117 -0
- package/src/cli/commands/import-index.ts +265 -0
- package/src/cli/commands/lint.ts +4 -2
- package/src/cli/handlers/components.test.ts +9 -0
- package/src/cli/handlers/components.ts +12 -2
- package/src/cli/handlers/fan-out.ts +17 -3
- package/src/cli/handlers/graph.test.ts +42 -0
- package/src/cli/handlers/graph.ts +26 -4
- package/src/cli/handlers/index-cloud.ts +32 -0
- package/src/cli/handlers/index-diff.test.ts +68 -0
- package/src/cli/handlers/index-diff.ts +146 -0
- package/src/cli/handlers/ledger-root-member.test.ts +161 -0
- package/src/cli/handlers/lifecycle-drift.ts +68 -0
- package/src/cli/handlers/lifecycle.test.ts +33 -11
- package/src/cli/handlers/lifecycle.ts +205 -30
- package/src/cli/handlers/misc.ts +73 -0
- package/src/cli/handlers/pr-waves-blocked.test.ts +37 -2
- package/src/cli/handlers/pr.ts +14 -2
- package/src/cli/handlers/promote.test.ts +64 -0
- package/src/cli/handlers/promote.ts +81 -6
- package/src/cli/handlers/query.ts +27 -4
- package/src/cli/handlers/run-declared-reads-cli.test.ts +187 -0
- package/src/cli/handlers/run-groups-cli.test.ts +229 -0
- package/src/cli/handlers/scenario.test.ts +13 -0
- package/src/cli/handlers/scenario.ts +8 -7
- package/src/cli/handlers/search-index.test.ts +255 -0
- package/src/cli/handlers/search-json.test.ts +1 -1
- package/src/cli/handlers/search-ownership.test.ts +194 -0
- package/src/cli/handlers/search.ts +271 -38
- package/src/cli/main.test.ts +7 -0
- package/src/cli/main.ts +56 -1
- package/src/cli/mcp/lifecycle-tools.ts +3 -2
- package/src/cli/mcp/resource-handlers.ts +4 -3
- package/src/cli/mcp/workspace-tools.ts +1 -1
- package/src/cli/parse-args.ts +40 -2
- package/src/cli/registry.ts +19 -1
- package/src/cloud-lister/aws.test.ts +202 -0
- package/src/cloud-lister/aws.ts +226 -0
- package/src/cloud-lister/azure.test.ts +132 -0
- package/src/cloud-lister/azure.ts +142 -0
- package/src/cloud-lister/common.ts +115 -0
- package/src/cloud-lister/credentials.ts +110 -0
- package/src/cloud-lister/fakes.ts +66 -0
- package/src/cloud-lister/gcp.test.ts +121 -0
- package/src/cloud-lister/gcp.ts +159 -0
- package/src/cloud-lister/guard.test.ts +198 -0
- package/src/cloud-lister/guard.ts +111 -0
- package/src/cloud-lister/ids.ts +54 -0
- package/src/cloud-lister/index.ts +134 -0
- package/src/cloud-lister/kubernetes.test.ts +160 -0
- package/src/cloud-lister/kubernetes.ts +284 -0
- package/src/cloud-lister/markers.ts +74 -0
- package/src/cloud-lister/mask.ts +77 -0
- package/src/cloud-lister/shape.test.ts +81 -0
- package/src/cloud-lister/sigv4.ts +70 -0
- package/src/cloud-lister/transport.ts +118 -0
- package/src/cloud-lister/types.ts +135 -0
- package/src/components/capability-plugin-loader.ts +4 -0
- package/src/components/capability-plugin.ts +10 -0
- package/src/components/capability.ts +229 -0
- package/src/components/cli-support.ts +70 -14
- package/src/components/declared-reads.test.ts +103 -0
- package/src/components/declared-reads.ts +134 -0
- package/src/components/deploy-units.ts +4 -0
- package/src/components/driver.ts +89 -4
- package/src/components/fan-out-run.ts +95 -15
- package/src/components/fan-out-support.ts +10 -1
- package/src/components/fan-out.ts +30 -0
- package/src/components/groups.test.ts +320 -0
- package/src/components/groups.ts +880 -0
- package/src/components/index.ts +42 -0
- package/src/components/plan-shape-conformance.ts +130 -0
- package/src/components/pr-env-run-bundle.test.ts +2 -0
- package/src/components/pr-run.test.ts +516 -3
- package/src/components/pr-run.ts +231 -41
- package/src/components/promote-rounds.ts +25 -2
- package/src/components/promote.ts +55 -5
- package/src/components/registry.test.ts +1 -1
- package/src/components/release-gate.ts +115 -30
- package/src/components/release-groups.test.ts +362 -0
- package/src/components/run-groups.ts +113 -0
- package/src/components/starter-plugin.ts +6 -0
- package/src/components/verbs/index.ts +1 -0
- package/src/components/verbs/member-outputs.test.ts +205 -0
- package/src/components/verbs/member-outputs.ts +308 -0
- package/src/config.ts +44 -0
- package/src/deep-observation.ts +5 -23
- package/src/drift-record.test.ts +596 -0
- package/src/drift-record.ts +1206 -0
- package/src/engine-facts.guard.test.ts +111 -0
- package/src/engine-facts.test.ts +178 -0
- package/src/engine-facts.ts +154 -0
- package/src/gated-waves-bundle.test.ts +2 -0
- package/src/graph-ir-live.test.ts +92 -0
- package/src/graph-ir.ts +317 -7
- package/src/graph-refs.ts +416 -0
- package/src/graph-schema/fixtures/adopt.json +15 -0
- package/src/graph-schema/fixtures/choudoufu.engine-graph.json +169 -0
- package/src/graph-schema/fixtures/index.json +68 -0
- package/src/graph-schema/fixtures/plunge.engine-graph.json +158 -0
- package/src/graph-schema/fixtures.ts +267 -0
- package/src/graph-schema/generate.ts +263 -0
- package/src/graph-schema/graph-schema.test.ts +153 -0
- package/src/graph-schema/graph.schema.json +1387 -0
- package/src/health.schema.json +2 -1
- package/src/identity.ts +2 -0
- package/src/index.ts +2 -0
- package/src/instance-nodes.ts +288 -0
- package/src/lexicon.ts +76 -0
- package/src/lifecycle/__fixtures__/index-diff/20261026T120000Z-aaaaaaaaaaaa.json +149 -0
- package/src/lifecycle/__fixtures__/index-diff/20261026T130000Z-bbbbbbbbbbbb.json +127 -0
- package/src/lifecycle/adoption-file.test.ts +100 -0
- package/src/lifecycle/adoption-file.ts +154 -0
- package/src/lifecycle/cloud-index.test.ts +517 -0
- package/src/lifecycle/cloud-index.ts +736 -0
- package/src/lifecycle/derive-edges.test.ts +193 -0
- package/src/lifecycle/derive-edges.ts +182 -0
- package/src/lifecycle/git.ts +10 -4
- package/src/lifecycle/identity-match.test.ts +308 -0
- package/src/lifecycle/identity-match.ts +257 -0
- package/src/lifecycle/index-diff.test.ts +198 -0
- package/src/lifecycle/index-diff.ts +476 -0
- package/src/lifecycle/index-document.test.ts +64 -0
- package/src/lifecycle/index-document.ts +299 -0
- package/src/lifecycle/index-drift.test.ts +191 -0
- package/src/lifecycle/index-drift.ts +304 -0
- package/src/lifecycle/index-import.test.ts +255 -0
- package/src/lifecycle/index-import.ts +634 -0
- package/src/lifecycle/index-join.test.ts +250 -0
- package/src/lifecycle/index-join.ts +304 -0
- package/src/lifecycle/index-store-load-bearing.test.ts +187 -0
- package/src/lifecycle/index.ts +4 -0
- package/src/lifecycle/member-ledger.test.ts +25 -7
- package/src/lifecycle/observation-baseline.test.ts +72 -1
- package/src/lifecycle/observation-baseline.ts +190 -27
- package/src/lifecycle/observe.ts +6 -1
- package/src/lifecycle/query.test.ts +69 -1
- package/src/lifecycle/query.ts +103 -10
- package/src/lifecycle/replay.test.ts +9 -5
- package/src/lifecycle/replay.ts +9 -5
- package/src/lifecycle/scenario.ts +4 -3
- package/src/lifecycle/snapshot-store-fake.ts +29 -0
- package/src/lifecycle/snapshot-store-s3.ts +316 -0
- package/src/lifecycle/snapshot-store.test.ts +385 -0
- package/src/lifecycle/snapshot-store.ts +981 -0
- package/src/lifecycle/snapshot.test.ts +13 -0
- package/src/lifecycle/snapshot.ts +23 -6
- package/src/lifecycle/type-listing.test.ts +166 -0
- package/src/lifecycle/type-listing.ts +309 -0
- package/src/lint/component-checks.ts +17 -1
- package/src/lint/config.test.ts +3 -0
- package/src/lint/presets/relaxed.json +2 -1
- package/src/lint/presets/strict.json +2 -1
- package/src/lint/rules/__fixtures__/comp/comp008/fail/dns.component.ts +15 -0
- package/src/lint/rules/__fixtures__/comp/comp008/pass/dns.component.ts +10 -0
- package/src/lint/rules/comp/comp.test.ts +2 -1
- package/src/lint/rules/comp/comp008-applies-signal-only-root.ts +121 -0
- package/src/lint/rules/comp/comp008.test.ts +77 -0
- package/src/lint/rules/comp/index.ts +4 -1
- package/src/observation-edges.test.ts +33 -0
- package/src/observation.ts +36 -1
- package/src/op/activities/activity-contracts.ts +1 -1
- package/src/op/activities/change-set.ts +8 -5
- package/src/op/activity-failure.ts +36 -0
- package/src/op/index.ts +2 -1
- package/src/op/local-executor.test.ts +80 -0
- package/src/op/local-executor.ts +27 -9
- package/src/pr-loop-bundle.test.ts +5 -2
- package/src/pr-loop.test.ts +43 -0
- package/src/pr-loop.ts +111 -2
- package/src/pulumi-urn.ts +151 -0
- package/src/release-floors.ts +22 -0
- package/src/sensitive-key.ts +34 -0
- package/src/workspace/adoption-report.test.ts +61 -0
- package/src/workspace/adoption-report.ts +103 -0
- package/src/workspace/capabilities-contract.test.ts +4 -0
- package/src/workspace/capabilities-contract.ts +9 -1
- package/src/workspace/capabilities.schema.json +98 -0
- package/src/workspace/change-set.schema.json +42 -3
- package/src/workspace/ci-cloud-identity.ts +31 -1
- package/src/workspace/compose-graph.test.ts +12 -0
- package/src/workspace/compose-graph.ts +12 -1
- package/src/workspace/conformance/conformance.e2e.test.ts +2 -1
- package/src/workspace/conformance/index.ts +6 -1
- package/src/workspace/drift-cli.test.ts +65 -0
- package/src/workspace/drift-cli.ts +365 -0
- package/src/workspace/drift.schema.json +672 -0
- package/src/workspace/graph-cli.ts +5 -0
- package/src/workspace/graph.schema.json +72 -0
- package/src/workspace/init.test.ts +38 -1
- package/src/workspace/init.ts +50 -8
- package/src/workspace/intent-gaps.test.ts +18 -2
- package/src/workspace/ledger.schema.json +1 -1
- package/src/workspace/nested-graph.ts +1 -0
- package/src/workspace/pr-report.schema.json +51 -2
- package/src/workspace/promote-waves.test.ts +296 -0
- package/src/workspace/promote-waves.ts +340 -0
- package/src/workspace/promote.test.ts +158 -4
- package/src/workspace/promote.ts +398 -57
- package/src/workspace/reason-codes.test.ts +4 -1
- package/src/workspace/reason-codes.ts +14 -0
- package/src/workspace/search-contract.ts +2 -0
- package/src/workspace/search.schema.json +103 -5
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* behold#1029: the lister's one way onto the network.
|
|
3
|
+
*
|
|
4
|
+
* {@link Transport.send} runs, in order: the read-only check
|
|
5
|
+
* (packages/core/src/cloud-lister/guard.ts), the origin pin, then the fetcher. The pin is
|
|
6
|
+
* the goal's never-public-cloud rule in code: when a run names its own
|
|
7
|
+
* endpoint (an emulator), every call must go to that endpoint's origin, so a
|
|
8
|
+
* URL built wrong can never reach a public cloud host. A test passes its own
|
|
9
|
+
* {@link Fetcher}; production uses {@link nodeFetcher}, which is node's own
|
|
10
|
+
* http/https so a cluster's CA and client certificate can be passed
|
|
11
|
+
* explicitly.
|
|
12
|
+
*/
|
|
13
|
+
import { request as httpRequest } from "node:http";
|
|
14
|
+
import { request as httpsRequest } from "node:https";
|
|
15
|
+
import { assertReadCall } from "./guard.js";
|
|
16
|
+
export class OriginRefused extends Error {
|
|
17
|
+
constructor(url, allowed) {
|
|
18
|
+
super(`chant's cloud lister refused ${url}: this run is pinned to ${allowed}`);
|
|
19
|
+
this.url = url;
|
|
20
|
+
this.allowed = allowed;
|
|
21
|
+
this.name = "OriginRefused";
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
export class Transport {
|
|
25
|
+
constructor(options = {}) {
|
|
26
|
+
this.options = options;
|
|
27
|
+
this.calls = [];
|
|
28
|
+
this.fetcher = options.fetcher ?? nodeFetcher;
|
|
29
|
+
}
|
|
30
|
+
async send(call) {
|
|
31
|
+
const operation = assertReadCall(call);
|
|
32
|
+
if (this.options.pinnedOrigin !== undefined) {
|
|
33
|
+
const origin = new URL(call.url).origin;
|
|
34
|
+
if (origin !== new URL(this.options.pinnedOrigin).origin)
|
|
35
|
+
throw new OriginRefused(call.url, this.options.pinnedOrigin);
|
|
36
|
+
}
|
|
37
|
+
this.calls.push({ call, operation });
|
|
38
|
+
this.options.onSend?.(call, operation);
|
|
39
|
+
return this.fetcher(call, this.options.tls);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
/** node's http/https, one request, the whole body read as text. */
|
|
43
|
+
export const nodeFetcher = (call, tls) => new Promise((resolve, reject) => {
|
|
44
|
+
const url = new URL(call.url);
|
|
45
|
+
const secure = url.protocol === "https:";
|
|
46
|
+
const send = secure ? httpsRequest : httpRequest;
|
|
47
|
+
const req = send(url, {
|
|
48
|
+
method: call.method,
|
|
49
|
+
headers: call.headers,
|
|
50
|
+
...(secure && tls
|
|
51
|
+
? {
|
|
52
|
+
...(tls.ca !== undefined ? { ca: tls.ca } : {}),
|
|
53
|
+
...(tls.cert !== undefined ? { cert: tls.cert } : {}),
|
|
54
|
+
...(tls.key !== undefined ? { key: tls.key } : {}),
|
|
55
|
+
...(tls.insecureSkipVerify ? { rejectUnauthorized: false } : {}),
|
|
56
|
+
}
|
|
57
|
+
: {}),
|
|
58
|
+
timeout: 60000,
|
|
59
|
+
}, (res) => {
|
|
60
|
+
const chunks = [];
|
|
61
|
+
res.on("data", (c) => chunks.push(c));
|
|
62
|
+
res.on("end", () => {
|
|
63
|
+
const headers = {};
|
|
64
|
+
for (const [k, v] of Object.entries(res.headers)) {
|
|
65
|
+
if (v !== undefined)
|
|
66
|
+
headers[k] = Array.isArray(v) ? v.join(", ") : v;
|
|
67
|
+
}
|
|
68
|
+
resolve({ status: res.statusCode ?? 0, headers, body: Buffer.concat(chunks).toString("utf8") });
|
|
69
|
+
});
|
|
70
|
+
res.on("error", reject);
|
|
71
|
+
});
|
|
72
|
+
req.on("timeout", () => req.destroy(new Error(`timed out: ${call.method} ${call.url}`)));
|
|
73
|
+
req.on("error", reject);
|
|
74
|
+
if (call.body !== undefined)
|
|
75
|
+
req.write(call.body);
|
|
76
|
+
req.end();
|
|
77
|
+
});
|
|
78
|
+
/** The body parsed as JSON, or `undefined` when it is not JSON. */
|
|
79
|
+
export function jsonBody(res) {
|
|
80
|
+
try {
|
|
81
|
+
return res.body === "" ? undefined : JSON.parse(res.body);
|
|
82
|
+
}
|
|
83
|
+
catch {
|
|
84
|
+
return undefined;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* behold#1029: the cloud lister's output, the "listing result" source shape
|
|
3
|
+
* of behold#1025's design (https://github.com/INTENTIUS/behold/issues/1025#issuecomment-6430966093,
|
|
4
|
+
* ruled in #issuecomment-6431259469).
|
|
5
|
+
*
|
|
6
|
+
* The ruling puts the index schema's TypeScript types in chant core (Q5), and
|
|
7
|
+
* chant's `typeListing` (../lifecycle/type-listing.ts, chant#4521) turns a
|
|
8
|
+
* `ListingResult` into an `IndexDocument`. type-listing.ts reads the shape
|
|
9
|
+
* loosely (an optional id and facts, any source name); this module is the
|
|
10
|
+
* lister's exact output, and ../lifecycle/cloud-index.ts hands one to the
|
|
11
|
+
* other, so the type checker holds them together.
|
|
12
|
+
*
|
|
13
|
+
* What the lister fills, per the design and chant#4520's ruled `EngineFacts`:
|
|
14
|
+
*
|
|
15
|
+
* - every resource gets the path-style id the ruling names (Q2),
|
|
16
|
+
* `<substrate>/<scopeId>/<location>/<listedType>/<nativeId>` (packages/core/src/cloud-lister/ids.ts);
|
|
17
|
+
* - `facts` carries only what a cloud listing can read: `markers` (from tags
|
|
18
|
+
* and labels), `cloudIds` and `observedAt`. `ownership`, `ownedBy` and
|
|
19
|
+
* `recordVersions` stay absent, because they are relative to an estate or
|
|
20
|
+
* stack and a record the lister never reads;
|
|
21
|
+
* - properties, tags and every string under them are masked before the
|
|
22
|
+
* result exists (packages/core/src/cloud-lister/mask.ts).
|
|
23
|
+
*/
|
|
24
|
+
import type { UnobservedReason } from "../observation.js";
|
|
25
|
+
/** The four substrates the lister reads, one per run (ruling Q6). */
|
|
26
|
+
export type Substrate = "aws" | "azure" | "gcp" | "kubernetes";
|
|
27
|
+
/** A tag or label filter: every pair must match. */
|
|
28
|
+
export type TagFilter = Readonly<Record<string, string>>;
|
|
29
|
+
/**
|
|
30
|
+
* One run's scope (ruling Q6): one substrate and one account, subscription,
|
|
31
|
+
* project or cluster, with every location and type the flags name. `"*"`
|
|
32
|
+
* means every location or every type the inventory API returns.
|
|
33
|
+
*/
|
|
34
|
+
export interface CloudScope {
|
|
35
|
+
substrate: Substrate;
|
|
36
|
+
/** AWS account id, Azure subscription id, GCP project id, or a cluster name. */
|
|
37
|
+
scopeId: string;
|
|
38
|
+
/** Regions or locations (Kubernetes: namespaces), sorted and deduplicated, or `"*"`. */
|
|
39
|
+
locations: readonly string[] | "*";
|
|
40
|
+
/** Types as the inventory API names them, sorted and deduplicated, or `"*"`. */
|
|
41
|
+
types: readonly string[] | "*";
|
|
42
|
+
tagFilter?: TagFilter;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* What was looked at, per type and location (#1025 "Coverage"). A
|
|
46
|
+
* (type, location) with no entry is not observed. `"*"` in `listedType` or
|
|
47
|
+
* `location` means "every": a reader that does not know the wildcard compares
|
|
48
|
+
* it as a literal, matches nothing, and so reads the entity as not observed,
|
|
49
|
+
* which is the safe direction.
|
|
50
|
+
*/
|
|
51
|
+
export interface CoverageEntry {
|
|
52
|
+
listedType: string;
|
|
53
|
+
location: string;
|
|
54
|
+
verdict: "listed" | UnobservedReason;
|
|
55
|
+
detail?: string;
|
|
56
|
+
}
|
|
57
|
+
/** Why something was not listed, said once (#1029: "a type it cannot list goes in the notes"). */
|
|
58
|
+
export interface IndexNote {
|
|
59
|
+
code: "no-lister" | "needs-parent" | "api-disabled" | "read-failed" | "no-credentials" | "default-types" | "tag-filter";
|
|
60
|
+
message: string;
|
|
61
|
+
listedType?: string;
|
|
62
|
+
location?: string;
|
|
63
|
+
/** A command the person can run themselves (never run by the lister). */
|
|
64
|
+
command?: string;
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* A cloud id, kinds as chant#4520 ruled them (`EngineFacts.cloudIds`):
|
|
68
|
+
* `arn` for an ARN, `import-id` for Cloud Control's identifier (what
|
|
69
|
+
* `declaredIdentifier` builds and an import takes), `provider-id` for an ARM
|
|
70
|
+
* id (as returned and once lowercased, since Resource Graph lowercases) or a
|
|
71
|
+
* GCP asset name, `self-link` for a GCP selfLink, `k8s-uid` for a
|
|
72
|
+
* Kubernetes UID.
|
|
73
|
+
*/
|
|
74
|
+
export interface CloudId {
|
|
75
|
+
kind: "import-id" | "arn" | "provider-id" | "self-link" | "k8s-uid";
|
|
76
|
+
value: string;
|
|
77
|
+
}
|
|
78
|
+
/** chant#4520's `EngineFacts.markers`, as read off the live object's tags or labels. */
|
|
79
|
+
export interface MarkerFact {
|
|
80
|
+
owner?: string;
|
|
81
|
+
address?: string;
|
|
82
|
+
encoding: "plain" | "escaped" | "digest";
|
|
83
|
+
source: "live";
|
|
84
|
+
}
|
|
85
|
+
/** The facts a cloud listing can supply (ruling Q1: one nested object). */
|
|
86
|
+
export interface ListedFacts {
|
|
87
|
+
markers?: MarkerFact;
|
|
88
|
+
cloudIds: CloudId[];
|
|
89
|
+
observedAt: string;
|
|
90
|
+
}
|
|
91
|
+
/** One listed object (#1025 `ListedResource`, plus the ruled id and facts). */
|
|
92
|
+
export interface ListedResource {
|
|
93
|
+
/** `<substrate>/<scopeId>/<location>/<listedType>/<nativeId>` (ruling Q2). */
|
|
94
|
+
id: string;
|
|
95
|
+
listedType: string;
|
|
96
|
+
location: string;
|
|
97
|
+
/** Cloud Control `Identifier`, the ARM id, the asset `name`, `namespace/name` or `name` for Kubernetes. */
|
|
98
|
+
nativeId: string;
|
|
99
|
+
cloudIds: CloudId[];
|
|
100
|
+
tags: Record<string, string>;
|
|
101
|
+
/** As returned, unnormalized, already masked. */
|
|
102
|
+
properties: Record<string, unknown>;
|
|
103
|
+
/** When the call that returned it answered. */
|
|
104
|
+
observedAt: string;
|
|
105
|
+
facts: ListedFacts;
|
|
106
|
+
}
|
|
107
|
+
/** The lister's whole output for one run (#1025 `ListingResult`). */
|
|
108
|
+
export interface ListingResult {
|
|
109
|
+
listing: "v1";
|
|
110
|
+
source: {
|
|
111
|
+
name: "chant-lister";
|
|
112
|
+
version: string;
|
|
113
|
+
};
|
|
114
|
+
scope: CloudScope;
|
|
115
|
+
startedAt: string;
|
|
116
|
+
completedAt: string;
|
|
117
|
+
resources: ListedResource[];
|
|
118
|
+
coverage: CoverageEntry[];
|
|
119
|
+
notes: IndexNote[];
|
|
120
|
+
}
|
|
121
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/cloud-lister/types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,qEAAqE;AACrE,MAAM,MAAM,SAAS,GAAG,KAAK,GAAG,OAAO,GAAG,KAAK,GAAG,YAAY,CAAC;AAE/D,oDAAoD;AACpD,MAAM,MAAM,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;AAEzD;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACzB,SAAS,EAAE,SAAS,CAAC;IACrB,gFAAgF;IAChF,OAAO,EAAE,MAAM,CAAC;IAChB,wFAAwF;IACxF,SAAS,EAAE,SAAS,MAAM,EAAE,GAAG,GAAG,CAAC;IACnC,gFAAgF;IAChF,KAAK,EAAE,SAAS,MAAM,EAAE,GAAG,GAAG,CAAC;IAC/B,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB;AAED;;;;;;GAMG;AACH,MAAM,WAAW,aAAa;IAC5B,UAAU,EAAE,MAAM,CAA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UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACpC,+CAA+C;IAC/C,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,WAAW,CAAC;CACpB;AAED,qEAAqE;AACrE,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,IAAI,CAAC;IACd,MAAM,EAAE;QAAE,IAAI,EAAE,cAAc,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;IAClD,KAAK,EAAE,UAAU,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,cAAc,EAAE,CAAC;IAC5B,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,KAAK,EAAE,SAAS,EAAE,CAAC;CACpB"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* behold#1029: the cloud lister's output, the "listing result" source shape
|
|
3
|
+
* of behold#1025's design (https://github.com/INTENTIUS/behold/issues/1025#issuecomment-6430966093,
|
|
4
|
+
* ruled in #issuecomment-6431259469).
|
|
5
|
+
*
|
|
6
|
+
* The ruling puts the index schema's TypeScript types in chant core (Q5), and
|
|
7
|
+
* chant's `typeListing` (../lifecycle/type-listing.ts, chant#4521) turns a
|
|
8
|
+
* `ListingResult` into an `IndexDocument`. type-listing.ts reads the shape
|
|
9
|
+
* loosely (an optional id and facts, any source name); this module is the
|
|
10
|
+
* lister's exact output, and ../lifecycle/cloud-index.ts hands one to the
|
|
11
|
+
* other, so the type checker holds them together.
|
|
12
|
+
*
|
|
13
|
+
* What the lister fills, per the design and chant#4520's ruled `EngineFacts`:
|
|
14
|
+
*
|
|
15
|
+
* - every resource gets the path-style id the ruling names (Q2),
|
|
16
|
+
* `<substrate>/<scopeId>/<location>/<listedType>/<nativeId>` (packages/core/src/cloud-lister/ids.ts);
|
|
17
|
+
* - `facts` carries only what a cloud listing can read: `markers` (from tags
|
|
18
|
+
* and labels), `cloudIds` and `observedAt`. `ownership`, `ownedBy` and
|
|
19
|
+
* `recordVersions` stay absent, because they are relative to an estate or
|
|
20
|
+
* stack and a record the lister never reads;
|
|
21
|
+
* - properties, tags and every string under them are masked before the
|
|
22
|
+
* result exists (packages/core/src/cloud-lister/mask.ts).
|
|
23
|
+
*/
|
|
24
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capability-plugin-loader.d.ts","sourceRoot":"","sources":["../../src/components/capability-plugin-loader.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"capability-plugin-loader.d.ts","sourceRoot":"","sources":["../../src/components/capability-plugin-loader.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAO5D,iLAAiL;AACjL,qBAAa,8BAA+B,SAAQ,KAAK;aAErC,WAAW,EAAE,MAAM;IADrC,YACkB,WAAW,EAAE,MAAM,EACnC,MAAM,EAAE,MAAM,EAIf;CACF;AAED,+HAA+H;AAC/H,qBAAa,4BAA6B,SAAQ,KAAK;aAEnC,IAAI,EAAE,MAAM;aACZ,OAAO,EAAE,MAAM,EAAE;IAFnC,YACkB,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EAAE,EAIlC;CACF;AAED;;;;;;;;GAQG;AACH,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAqBlF;AAED;;;;GAIG;AACH,wBAAsB,qBAAqB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC,CAUxF;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAsB,+BAA+B,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,GAAG,IAAI,CAAC,CAapG;AAED,8HAA8H;AAC9H,wBAAsB,iCAAiC,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC,CASpG;AAED;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,QAAQ,EAAE,kBAAkB,EAC5B,OAAO,EAAE,gBAAgB,EAAE,GAC1B,kBAAkB,CAkCpB;AAED,MAAM,WAAW,8BAA8B;IAC7C;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB;;;;OAIG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED;;;;;;;;GAQG;AACH,wBAAsB,uBAAuB,CAC3C,OAAO,GAAE,8BAAmC,GAC3C,OAAO,CAAC,kBAAkB,CAAC,CAS7B"}
|
|
@@ -25,6 +25,7 @@ import { lexiconModulePath, importLexiconPackage } from "../lexicon-module.js";
|
|
|
25
25
|
import { isCapabilityPlugin } from "./capability-plugin.js";
|
|
26
26
|
import { starterCapabilityPlugin } from "./starter-plugin.js";
|
|
27
27
|
import { isRegistryBackendConsumer } from "./verbs/publish-image.js";
|
|
28
|
+
import { isEngineOutputSourceConsumer } from "./verbs/member-outputs.js";
|
|
28
29
|
import { isStorageBackendConsumer } from "./verbs/publish-artifact.js";
|
|
29
30
|
/** Thrown when a dynamically-imported capability package does not satisfy `CapabilityPlugin` — the "malformed capability package" case #559 asks doctor/validation to detect. */
|
|
30
31
|
export class MalformedCapabilityPluginError extends Error {
|
|
@@ -155,6 +156,9 @@ export function registerCapabilityPlugins(registry, plugins) {
|
|
|
155
156
|
const storage = [];
|
|
156
157
|
for (const plugin of plugins)
|
|
157
158
|
storage.push(...(plugin.storageBackends?.() ?? []));
|
|
159
|
+
const engines = [];
|
|
160
|
+
for (const plugin of plugins)
|
|
161
|
+
engines.push(...(plugin.engineOutputSources?.() ?? []));
|
|
158
162
|
for (const plugin of plugins) {
|
|
159
163
|
for (const capability of plugin.capabilities()) {
|
|
160
164
|
// A capability that consumes registry login backends (`publish-image`)
|
|
@@ -164,6 +168,8 @@ export function registerCapabilityPlugins(registry, plugins) {
|
|
|
164
168
|
bound = bound.withRegistryBackends(backends);
|
|
165
169
|
if (isStorageBackendConsumer(bound))
|
|
166
170
|
bound = bound.withStorageBackends(storage);
|
|
171
|
+
if (isEngineOutputSourceConsumer(bound))
|
|
172
|
+
bound = bound.withEngineOutputSources(engines);
|
|
167
173
|
registry.register(bound);
|
|
168
174
|
}
|
|
169
175
|
}
|
|
@@ -30,6 +30,7 @@
|
|
|
30
30
|
import type { Capability } from "./capability.js";
|
|
31
31
|
import type { RegistryLoginBackend } from "./verbs/publish-image.js";
|
|
32
32
|
import type { ArtifactStorageBackend } from "./verbs/publish-artifact.js";
|
|
33
|
+
import type { EngineOutputSource } from "./verbs/member-outputs.js";
|
|
33
34
|
/**
|
|
34
35
|
* Manifest for a packaged capability plugin — the capability-side analogue
|
|
35
36
|
* of `LexiconManifest` (../lexicon.ts). Kept as a plain data shape (rather
|
|
@@ -89,6 +90,14 @@ export interface CapabilityPlugin {
|
|
|
89
90
|
* `registryBackends`, not capabilities, so several plugins may contribute.
|
|
90
91
|
*/
|
|
91
92
|
storageBackends?(): ArtifactStorageBackend[];
|
|
93
|
+
/**
|
|
94
|
+
* Engine output sources this plugin contributes to core's `member-outputs`
|
|
95
|
+
* verb (#4455): how another workspace member's outputs are read, applied
|
|
96
|
+
* and planned, for the member kinds the source names (terraform:
|
|
97
|
+
* `choudoufu`; pulumi: `pulumi`). Like `registryBackends`, not capabilities, so several
|
|
98
|
+
* engines may contribute.
|
|
99
|
+
*/
|
|
100
|
+
engineOutputSources?(): EngineOutputSource[];
|
|
92
101
|
/** Optional initialization hook, called once after load (mirrors `LexiconPlugin.init`). */
|
|
93
102
|
init?(): void | Promise<void>;
|
|
94
103
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capability-plugin.d.ts","sourceRoot":"","sources":["../../src/components/capability-plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"capability-plugin.d.ts","sourceRoot":"","sources":["../../src/components/capability-plugin.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC/C,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE;;;;;;;GAOG;AACH,MAAM,WAAW,kBAAkB;IACjC,wEAAwE;IACxE,IAAI,EAAE,MAAM,CAAC;IACb,2EAA2E;IAC3E,OAAO,EAAE,MAAM,CAAC;IAChB,gKAAgK;IAChK,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,yIAAyI;IACzI,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB;AAED;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,gBAAgB;IAE/B,uFAAuF;IACvF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB;;;;;;OAMG;IACH,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IAEzB,mGAAmG;IACnG,YAAY,IAAI,KAAK,CAAC,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC;IAGlD,qIAAqI;IACrI,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAE/B,gLAAgL;IAChL,QAAQ,CAAC,IAAI,MAAM,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC,CAAC;IAE/C;;;;OAIG;IACH,gBAAgB,CAAC,IAAI,oBAAoB,EAAE,CAAC;IAE5C;;;;OAIG;IACH,eAAe,CAAC,IAAI,sBAAsB,EAAE,CAAC;IAE7C;;;;;;OAMG;IACH,mBAAmB,CAAC,IAAI,kBAAkB,EAAE,CAAC;IAE7C,2FAA2F;IAC3F,IAAI,CAAC,IAAI,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/B;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,gBAAgB,CAa5E;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,iBAAiB,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAM3D"}
|
|
@@ -203,6 +203,221 @@ export interface Capability<In = unknown, Out = unknown> {
|
|
|
203
203
|
* why. Unset refuses too, with a reason that names the verb.
|
|
204
204
|
*/
|
|
205
205
|
readonly targets?: TargetSupport;
|
|
206
|
+
/**
|
|
207
|
+
* Optional (#4435, ws-107): why this capability will not plan and apply
|
|
208
|
+
* `members` as one group, or `undefined` when it will. Core asks before
|
|
209
|
+
* anything is planned, so the answer must come from the declaration and
|
|
210
|
+
* the files alone, never from a plan. A fallback with
|
|
211
|
+
* {@link GroupFallback.drop} leaves only those members out: core forms
|
|
212
|
+
* the group again from the rest and asks again (#4419 ruling 1). A
|
|
213
|
+
* capability with `planGroup` and no `groupFallback` takes every group
|
|
214
|
+
* core forms.
|
|
215
|
+
*/
|
|
216
|
+
groupFallback?(ctx: GroupContext, members: readonly GroupMember<In>[]): Promise<GroupFallback | undefined>;
|
|
217
|
+
/**
|
|
218
|
+
* Optional (#4447): reads between this capability's components that core
|
|
219
|
+
* cannot see in their declarations, such as a Terraform root's
|
|
220
|
+
* `terraform_remote_state` block. Core asks once per capability, before
|
|
221
|
+
* groups form, with every component of the change whose step this
|
|
222
|
+
* capability takes (`ctx.components` in plan order, no `input`), and adds
|
|
223
|
+
* each read to the reads it joins, orders and splits groups by, and to
|
|
224
|
+
* the group reads the report names. The answer must come from the
|
|
225
|
+
* declaration and the files alone. A read naming a component outside
|
|
226
|
+
* `members` is ignored; a throw counts as no reads.
|
|
227
|
+
*/
|
|
228
|
+
groupReads?(ctx: GroupContext, members: readonly GroupMember<In>[]): Promise<ReportedGroupRead[]>;
|
|
229
|
+
/**
|
|
230
|
+
* Optional (#4466): reads between this capability's steps that sit in the
|
|
231
|
+
* files a step names rather than in its wiring, such as a CloudFormation
|
|
232
|
+
* template's `Fn::ImportValue` of an export another stack's template
|
|
233
|
+
* declares. Core asks once, after discovery and before the order is
|
|
234
|
+
* derived, with every step of this kind in the project. Each read becomes
|
|
235
|
+
* a `stackOutput()` reference at {@link DeclaredRead.at} in the reader's
|
|
236
|
+
* step and a `dependsOn` on the upstream, so it orders the reader after
|
|
237
|
+
* the upstream, is listed under `unknownInputs` while the upstream's plan
|
|
238
|
+
* cannot say the value, and holds the reader for a round, like a read the
|
|
239
|
+
* declaration states. A place the declaration already fills is left as it
|
|
240
|
+
* is. The answer must come from the declaration and the files alone; a
|
|
241
|
+
* throw counts as no reads.
|
|
242
|
+
*/
|
|
243
|
+
declaredReads?(ctx: DeclaredReadsContext, members: readonly DeclaredReadMember[]): Promise<DeclaredRead[]> | DeclaredRead[];
|
|
244
|
+
/**
|
|
245
|
+
* Optional (#4435, ws-107): plan `members` as one, in one call. Declared
|
|
246
|
+
* together with `runGroup`; a capability with only one of the two never
|
|
247
|
+
* gets a group. Throwing makes every member plan-failed.
|
|
248
|
+
*/
|
|
249
|
+
planGroup?(ctx: GroupContext, members: readonly GroupMember<In>[]): Promise<CapabilityGroupPlan>;
|
|
250
|
+
/**
|
|
251
|
+
* Optional (#4435, ws-107): apply the group `planGroup` planned, in one
|
|
252
|
+
* call, and say how each member's part ended. It should not throw: a throw
|
|
253
|
+
* reads as every member `failed`, or every member `not-started` when the
|
|
254
|
+
* error is a moved plan ({@link isPlanMovedError}).
|
|
255
|
+
*/
|
|
256
|
+
runGroup?(ctx: GroupContext, run: GroupRun, members: readonly GroupMember<In>[]): Promise<CapabilityGroupOutcome>;
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* What a group's calls share (ws-107): the run's environment and variables,
|
|
260
|
+
* and the group's components in apply order. Each member's own context is
|
|
261
|
+
* {@link GroupMember.ctx}.
|
|
262
|
+
*/
|
|
263
|
+
export interface GroupContext {
|
|
264
|
+
env: string;
|
|
265
|
+
vars?: Record<string, unknown>;
|
|
266
|
+
/** The group's components, upstreams first. */
|
|
267
|
+
components: string[];
|
|
268
|
+
}
|
|
269
|
+
/**
|
|
270
|
+
* A read of one group member's output by another (ws-107). Core leaves the
|
|
271
|
+
* value out of the reader's `input` (it is `undefined` at `at`) and the
|
|
272
|
+
* capability wires it inside its own apply.
|
|
273
|
+
*/
|
|
274
|
+
export interface GroupRead {
|
|
275
|
+
/** Where in the reader's step input the value goes, as a JSON Pointer. */
|
|
276
|
+
at: string;
|
|
277
|
+
/** `<component>.<output>`, as `PrMember.reads` and `unknownInputs` name it. */
|
|
278
|
+
ref: string;
|
|
279
|
+
/** The member whose output it is. */
|
|
280
|
+
component: string;
|
|
281
|
+
output: string;
|
|
282
|
+
}
|
|
283
|
+
/**
|
|
284
|
+
* A read of one component by another that a capability reports through
|
|
285
|
+
* `groupReads` (#4447), with no place in the reader's step input.
|
|
286
|
+
*/
|
|
287
|
+
export interface ReportedGroupRead {
|
|
288
|
+
/** The component that reads. */
|
|
289
|
+
reader: string;
|
|
290
|
+
/** The component whose output it reads. */
|
|
291
|
+
upstream: string;
|
|
292
|
+
/** The read as the report names it, e.g. `data.terraform_remote_state.network`. */
|
|
293
|
+
ref: string;
|
|
294
|
+
/**
|
|
295
|
+
* The upstream output read, when the capability knows it. Without it the
|
|
296
|
+
* read counts as known at plan only when the upstream's plan knows every
|
|
297
|
+
* output it names.
|
|
298
|
+
*/
|
|
299
|
+
output?: string;
|
|
300
|
+
}
|
|
301
|
+
/** What `declaredReads` is asked with (#4466). */
|
|
302
|
+
export interface DeclaredReadsContext {
|
|
303
|
+
/** The project root, which a step's relative file paths are read against. */
|
|
304
|
+
root: string;
|
|
305
|
+
}
|
|
306
|
+
/** One step a capability's `declaredReads` is asked about (#4466). */
|
|
307
|
+
export interface DeclaredReadMember {
|
|
308
|
+
component: string;
|
|
309
|
+
/** Which of the component's steps of this kind, counting from 0 in declaration order. */
|
|
310
|
+
index: number;
|
|
311
|
+
/** The step as declared, without `kind`, wiring unresolved. */
|
|
312
|
+
step: Record<string, unknown>;
|
|
313
|
+
}
|
|
314
|
+
/**
|
|
315
|
+
* A read `declaredReads` found (#4466): `reader`'s step `index` reads
|
|
316
|
+
* `upstream`'s output `output`. Core puts `{ stackOutput: { stack:
|
|
317
|
+
* upstream, name: output } }` at `at` in that step, so the read is named
|
|
318
|
+
* `<upstream>.<output>` wherever reads are.
|
|
319
|
+
*/
|
|
320
|
+
export interface DeclaredRead {
|
|
321
|
+
reader: string;
|
|
322
|
+
/** The reader's step, as {@link DeclaredReadMember.index}. Default 0. */
|
|
323
|
+
index?: number;
|
|
324
|
+
upstream: string;
|
|
325
|
+
output: string;
|
|
326
|
+
/** Where in the reader's step the reference goes, as a JSON Pointer. */
|
|
327
|
+
at: string;
|
|
328
|
+
}
|
|
329
|
+
/** One component of a group, as core hands it to the capability (ws-107). */
|
|
330
|
+
export interface GroupMember<In = unknown> {
|
|
331
|
+
component: string;
|
|
332
|
+
/** The component's one step as declared, without `kind`, wiring unresolved. */
|
|
333
|
+
step: Record<string, unknown>;
|
|
334
|
+
/**
|
|
335
|
+
* The step's input resolved against the outputs from outside the group.
|
|
336
|
+
* Each {@link GroupRead} is `undefined` here. Absent in `groupFallback`,
|
|
337
|
+
* which is asked before any output is read.
|
|
338
|
+
*/
|
|
339
|
+
input?: In;
|
|
340
|
+
/** The member's reads of other members, sorted by `ref`. */
|
|
341
|
+
reads: GroupRead[];
|
|
342
|
+
/**
|
|
343
|
+
* The component's `dependsOn` as declared (#4447): an order with no read,
|
|
344
|
+
* which a capability that applies the group in one call has to keep or
|
|
345
|
+
* refuse.
|
|
346
|
+
*/
|
|
347
|
+
dependsOn?: string[];
|
|
348
|
+
/**
|
|
349
|
+
* The member's own context: `component`, `targets`, `carried` and `carry`
|
|
350
|
+
* as for a single step. `unresolvedInputs` names only components outside
|
|
351
|
+
* the group. In `runGroup`, `plans` holds this member's plan.
|
|
352
|
+
*/
|
|
353
|
+
ctx: DeployContext;
|
|
354
|
+
}
|
|
355
|
+
/**
|
|
356
|
+
* Why a set of components does not run as one group (ws-107). `kind` is a
|
|
357
|
+
* short stable word the report keys on; `reason` is one line for a person.
|
|
358
|
+
* Core's own kinds are `steps`, `split` and `cycle`; a capability names its
|
|
359
|
+
* own. A capability's `off` is recorded and not printed in the note.
|
|
360
|
+
*
|
|
361
|
+
* Without `drop`, the fallback is every member's and the group dissolves.
|
|
362
|
+
* With `drop`, only the members it names leave, each with its own `kind`
|
|
363
|
+
* and `reason` or else the fallback's; core forms the group again from the
|
|
364
|
+
* rest by its own rules (`split`, `steps`, `cycle`, and a set of one is no
|
|
365
|
+
* group) and asks again for each set that changed (#4419 ruling 1). A
|
|
366
|
+
* `drop` that names no member of the group dissolves it.
|
|
367
|
+
*/
|
|
368
|
+
export interface GroupFallback {
|
|
369
|
+
kind: string;
|
|
370
|
+
reason: string;
|
|
371
|
+
/** The members to leave out, when not the whole group. */
|
|
372
|
+
drop?: GroupDrop[];
|
|
373
|
+
}
|
|
374
|
+
/** A member a {@link GroupFallback} leaves out of its group (#4419 ruling 1). */
|
|
375
|
+
export interface GroupDrop {
|
|
376
|
+
component: string;
|
|
377
|
+
/** Default: the fallback's `kind`. */
|
|
378
|
+
kind?: string;
|
|
379
|
+
/** Default: the fallback's `reason`. */
|
|
380
|
+
reason?: string;
|
|
381
|
+
}
|
|
382
|
+
/** What `planGroup` returns (ws-107). */
|
|
383
|
+
export interface CapabilityGroupPlan {
|
|
384
|
+
/**
|
|
385
|
+
* One plan per member, by component: what `plan` would give for that
|
|
386
|
+
* member, with `planDigest` before the group is folded in. Core folds the
|
|
387
|
+
* group digest into each `planDigest` and its change-set part. `artifact`
|
|
388
|
+
* on these is ignored; the group's artifact is below.
|
|
389
|
+
*/
|
|
390
|
+
members: Record<string, CapabilityPlan>;
|
|
391
|
+
/** The capability's digest of what the group adds to its members' plans. */
|
|
392
|
+
digest: string;
|
|
393
|
+
/** Handed back to `runGroup` in {@link GroupRun}. Core never reads it. */
|
|
394
|
+
artifact?: unknown;
|
|
395
|
+
}
|
|
396
|
+
/** What core hands `runGroup` (ws-107): the plan that was approved. */
|
|
397
|
+
export interface GroupRun {
|
|
398
|
+
artifact?: unknown;
|
|
399
|
+
/** The group digest core bound: the capability's digest with the members folded in. */
|
|
400
|
+
digest: string;
|
|
401
|
+
/** Each member's plan as bound into the change set, by component. */
|
|
402
|
+
plans: Record<string, CapabilityPlan>;
|
|
403
|
+
}
|
|
404
|
+
/**
|
|
405
|
+
* How one member's part of a group apply ended (ws-107). `partial`: some of
|
|
406
|
+
* its planned changes applied. `not-started`: the apply stopped before its
|
|
407
|
+
* part began. `no-changes`: it planned none.
|
|
408
|
+
*/
|
|
409
|
+
export type GroupMemberStatus = "applied" | "partial" | "failed" | "not-started" | "no-changes";
|
|
410
|
+
export interface GroupMemberOutcome {
|
|
411
|
+
status: GroupMemberStatus;
|
|
412
|
+
/** What the member exposes now, as `run`'s outputs: set for `applied` and `no-changes`. */
|
|
413
|
+
outputs?: Record<string, unknown>;
|
|
414
|
+
error?: string;
|
|
415
|
+
}
|
|
416
|
+
/** What `runGroup` returns (ws-107): every member's outcome, by component. */
|
|
417
|
+
export interface CapabilityGroupOutcome {
|
|
418
|
+
members: Record<string, GroupMemberOutcome>;
|
|
419
|
+
/** An error no member's part names. */
|
|
420
|
+
error?: string;
|
|
206
421
|
}
|
|
207
422
|
/** A capability's relationship to rollback — see `Capability.rollbackPolicy`. */
|
|
208
423
|
export type RollbackPolicy = "native" | "none-by-design" | "needs-opt-out";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capability.d.ts","sourceRoot":"","sources":["../../src/components/capability.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAEnD;;;;;;;GAOG;AACH,MAAM,WAAW,aAAa;IAC5B,+DAA+D;IAC/D,GAAG,EAAE,MAAM,CAAC;IACZ,mEAAmE;IACnE,SAAS,EAAE,MAAM,CAAC;IAClB,qGAAqG;IACrG,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC/B;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B;;;;;;;;OAQG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAChC;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAClC;;;;;OAKG;IACH,KAAK,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IACjD;;;;;;;OAOG;IACH,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;CACpB;AAED;;;GAGG;AACH,MAA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CAAC,GAAG,IAAI,CAMvD;IAED,6FAA6F;IAC7F,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAC,KAAK,EAAE,OAAO,CAAC,CAOhD;IAED,qDAAqD;IACrD,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAEzB;IAED,oCAAoC;IACpC,KAAK,IAAI,MAAM,EAAE,CAEhB;CACF;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,EAAE,KAAK,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAatH"}
|
|
@@ -30,6 +30,7 @@ import { type ComponentPipelineOptions } from "../lexicon.js";
|
|
|
30
30
|
import type { RunProgressEvent } from "./run-progress.js";
|
|
31
31
|
import { type RunEventSink } from "../run-event-stream.js";
|
|
32
32
|
import type { CapabilityRegistry } from "./capability.js";
|
|
33
|
+
import type { FanOutPlan } from "./fan-out.js";
|
|
33
34
|
import { type ChantConfig } from "../config.js";
|
|
34
35
|
/** One component in `chant list --components` output. */
|
|
35
36
|
export interface ListedComponent {
|
|
@@ -293,6 +294,8 @@ export interface RunComponentsResult {
|
|
|
293
294
|
};
|
|
294
295
|
/** This run's resolved build-time parameters (chant #1108) — the component-driver counterpart of `../cli/commands/build.ts`'s `BuildResult.buildParams`. Present only once the run actually reached dispatch (mirrors `BuildResult.buildParams`, which is likewise absent on an early-error return). */
|
|
295
296
|
buildParams?: BuildParamProvenance[];
|
|
297
|
+
/** The grouped fan-out the run applied (ws-107, #4465), when a group formed or a component fell back from one. */
|
|
298
|
+
grouped?: FanOutPlan;
|
|
296
299
|
}
|
|
297
300
|
/**
|
|
298
301
|
* Run one named component, or every discovered component (`selector ===
|
|
@@ -327,6 +330,16 @@ export interface ResolvedComponentTargets {
|
|
|
327
330
|
targets: DriverComponent[];
|
|
328
331
|
/** For a list selector (#3950): the dependencies the closure added that the list did not name, in discovery order. */
|
|
329
332
|
added?: string[];
|
|
333
|
+
/**
|
|
334
|
+
* For a list selector: the names the list gave, and every enabled component
|
|
335
|
+
* the closure was taken over (#4516). `runComponents` takes the closure again
|
|
336
|
+
* once the declared reads are written in, so a listed importer pulls in the
|
|
337
|
+
* component whose export it reads.
|
|
338
|
+
*/
|
|
339
|
+
list?: {
|
|
340
|
+
named: string[];
|
|
341
|
+
enabled: DriverComponent[];
|
|
342
|
+
};
|
|
330
343
|
/** Component name to the environments it declares (#3153), for the components that declare any (#4330). */
|
|
331
344
|
sites?: Record<string, ComponentEnvironmentDeclaration[]>;
|
|
332
345
|
error?: string;
|
|
@@ -343,5 +356,13 @@ export declare function isComponentList(selector: string): boolean;
|
|
|
343
356
|
export declare function resolveComponentTargets(path: string, selector: string, sandbox?: boolean,
|
|
344
357
|
/** chant #1108 — this invocation's resolved build-time parameter values, forwarded into `discoverComponents` so a `params.<name>` reference inside a discovered `*.component.ts` file resolves instead of reading `{}`. See `discoverComponents`'s `buildParams` option (./discover.ts). */
|
|
345
358
|
buildParams?: BuildParamProvenance[]): Promise<ResolvedComponentTargets>;
|
|
359
|
+
/**
|
|
360
|
+
* `names` and every component of `enabled` they depend on, transitively, in
|
|
361
|
+
* `enabled`'s order, and which of those the names did not give (#3950).
|
|
362
|
+
*/
|
|
363
|
+
export declare function dependencyClosure(names: readonly string[], enabled: readonly DriverComponent[]): {
|
|
364
|
+
targets: DriverComponent[];
|
|
365
|
+
added: string[];
|
|
366
|
+
};
|
|
346
367
|
export declare function runComponents(path: string, selector: string, options?: RunComponentsOptions): Promise<RunComponentsResult>;
|
|
347
368
|
//# sourceMappingURL=cli-support.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-support.d.ts","sourceRoot":"","sources":["../../src/components/cli-support.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAKH,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,e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