@intentius/chant 0.124.55 → 0.124.56
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/ci-agent.d.ts.map +1 -1
- package/dist/ci-agent.js +1 -2
- package/dist/ci-audit/attribution.d.ts +111 -0
- package/dist/ci-audit/attribution.d.ts.map +1 -0
- package/dist/ci-audit/attribution.js +194 -0
- package/dist/ci-audit/audit-log.d.ts +144 -0
- package/dist/ci-audit/audit-log.d.ts.map +1 -0
- package/dist/ci-audit/audit-log.js +149 -0
- package/dist/ci-audit/index.d.ts +12 -0
- package/dist/ci-audit/index.d.ts.map +1 -0
- package/dist/ci-audit/index.js +12 -0
- package/dist/ci-audit/unrecorded.d.ts +74 -0
- package/dist/ci-audit/unrecorded.d.ts.map +1 -0
- package/dist/ci-audit/unrecorded.js +95 -0
- package/dist/ci-audit.d.ts +3 -0
- package/dist/ci-audit.d.ts.map +1 -0
- package/dist/ci-audit.js +2 -0
- package/dist/ci-control.d.ts.map +1 -1
- package/dist/ci-control.js +3 -4
- package/dist/ci-estate.d.ts +24 -0
- package/dist/ci-estate.d.ts.map +1 -1
- package/dist/ci-estate.js +1 -2
- package/dist/ci-identity.d.ts.map +1 -1
- package/dist/ci-identity.js +2 -3
- package/dist/ci-job-guard.d.ts +139 -0
- package/dist/ci-job-guard.d.ts.map +1 -0
- package/dist/ci-job-guard.js +287 -0
- package/dist/ci-jobs.d.ts +7 -0
- package/dist/ci-jobs.d.ts.map +1 -1
- package/dist/ci-jobs.js +7 -0
- package/dist/ci-product-words.d.ts +7 -1
- package/dist/ci-product-words.d.ts.map +1 -1
- package/dist/ci-product-words.js +38 -4
- package/dist/ci-product.d.ts +35 -0
- package/dist/ci-product.d.ts.map +1 -1
- package/dist/ci-product.js +38 -3
- package/dist/ci-respond-run.d.ts +73 -0
- package/dist/ci-respond-run.d.ts.map +1 -0
- package/dist/ci-respond-run.js +247 -0
- package/dist/ci-respond.d.ts +189 -0
- package/dist/ci-respond.d.ts.map +1 -0
- package/dist/ci-respond.js +285 -0
- package/dist/cli/handlers/audit-log.d.ts +12 -0
- package/dist/cli/handlers/audit-log.d.ts.map +1 -0
- package/dist/cli/handlers/audit-log.js +81 -0
- package/dist/cli/handlers/build.d.ts +7 -0
- package/dist/cli/handlers/build.d.ts.map +1 -1
- package/dist/cli/handlers/build.js +81 -0
- package/dist/cli/handlers/ci-check-job.d.ts +11 -0
- package/dist/cli/handlers/ci-check-job.d.ts.map +1 -0
- package/dist/cli/handlers/ci-check-job.js +27 -0
- package/dist/cli/handlers/ci-check.d.ts.map +1 -1
- package/dist/cli/handlers/ci-check.js +38 -9
- package/dist/cli/handlers/e2e-safe-run.d.ts +12 -0
- package/dist/cli/handlers/e2e-safe-run.d.ts.map +1 -0
- package/dist/cli/handlers/e2e-safe-run.js +23 -0
- package/dist/cli/handlers/pr.d.ts +5 -0
- package/dist/cli/handlers/pr.d.ts.map +1 -1
- package/dist/cli/handlers/pr.js +259 -4
- package/dist/cli/handlers/run-wave.js +89 -1
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +56 -2
- package/dist/cli/parse-args.d.ts.map +1 -1
- package/dist/cli/parse-args.js +107 -0
- package/dist/cli/registry.d.ts +38 -0
- package/dist/cli/registry.d.ts.map +1 -1
- package/dist/components/adoption.d.ts.map +1 -1
- package/dist/components/adoption.js +1 -2
- package/dist/components/capability.d.ts +37 -0
- package/dist/components/capability.d.ts.map +1 -1
- package/dist/components/capability.js +25 -0
- package/dist/components/check-hooks.d.ts +4 -1
- package/dist/components/check-hooks.d.ts.map +1 -1
- package/dist/components/check-steps.d.ts +74 -0
- package/dist/components/check-steps.d.ts.map +1 -0
- package/dist/components/check-steps.js +102 -0
- package/dist/components/ci-services.d.ts.map +1 -1
- package/dist/components/ci-services.js +1 -2
- package/dist/components/driver.d.ts +12 -0
- package/dist/components/driver.d.ts.map +1 -1
- package/dist/components/driver.js +35 -1
- package/dist/components/groups.d.ts.map +1 -1
- package/dist/components/groups.js +4 -3
- package/dist/components/pr-env-ledger.d.ts.map +1 -1
- package/dist/components/pr-env-ledger.js +1 -2
- package/dist/components/pr-environment.d.ts +1 -1
- package/dist/components/pr-environment.d.ts.map +1 -1
- package/dist/components/pr-environment.js +1 -1
- package/dist/components/pr-pipeline.d.ts +129 -3
- package/dist/components/pr-pipeline.d.ts.map +1 -1
- package/dist/components/pr-pipeline.js +153 -17
- package/dist/components/pr-run.d.ts +8 -0
- package/dist/components/pr-run.d.ts.map +1 -1
- package/dist/components/pr-run.js +9 -4
- package/dist/components/product-pipeline.d.ts +35 -2
- package/dist/components/product-pipeline.d.ts.map +1 -1
- package/dist/components/product-pipeline.js +24 -5
- package/dist/components/wave-plan.d.ts +8 -0
- package/dist/components/wave-plan.d.ts.map +1 -1
- package/dist/components/wave-plan.js +18 -2
- package/dist/e2e-harness/bucket.d.ts +21 -0
- package/dist/e2e-harness/bucket.d.ts.map +1 -0
- package/dist/e2e-harness/bucket.js +61 -0
- package/dist/e2e-harness/claim.d.ts +70 -0
- package/dist/e2e-harness/claim.d.ts.map +1 -0
- package/dist/e2e-harness/claim.js +98 -0
- package/dist/e2e-harness/driver.d.ts +64 -0
- package/dist/e2e-harness/driver.d.ts.map +1 -0
- package/dist/e2e-harness/driver.js +243 -0
- package/dist/e2e-harness/forgejo.d.ts +77 -0
- package/dist/e2e-harness/forgejo.d.ts.map +1 -0
- package/dist/e2e-harness/forgejo.js +205 -0
- package/dist/e2e-harness/git.d.ts +32 -0
- package/dist/e2e-harness/git.d.ts.map +1 -0
- package/dist/e2e-harness/git.js +67 -0
- package/dist/e2e-harness/index.d.ts +22 -0
- package/dist/e2e-harness/index.d.ts.map +1 -0
- package/dist/e2e-harness/index.js +48 -0
- package/dist/e2e-harness/jobs.d.ts +8 -0
- package/dist/e2e-harness/jobs.d.ts.map +1 -0
- package/dist/e2e-harness/jobs.js +34 -0
- package/dist/e2e-harness/pins.d.ts +45 -0
- package/dist/e2e-harness/pins.d.ts.map +1 -0
- package/dist/e2e-harness/pins.js +44 -0
- package/dist/e2e-harness/ports.d.ts +113 -0
- package/dist/e2e-harness/ports.d.ts.map +1 -0
- package/dist/e2e-harness/ports.js +4 -0
- package/dist/e2e-harness/reports.d.ts +45 -0
- package/dist/e2e-harness/reports.d.ts.map +1 -0
- package/dist/e2e-harness/reports.js +57 -0
- package/dist/e2e-harness/safe-run-cli.d.ts +17 -0
- package/dist/e2e-harness/safe-run-cli.d.ts.map +1 -0
- package/dist/e2e-harness/safe-run-cli.js +43 -0
- package/dist/e2e-harness/safe-run.d.ts +61 -0
- package/dist/e2e-harness/safe-run.d.ts.map +1 -0
- package/dist/e2e-harness/safe-run.js +172 -0
- package/dist/e2e-harness/scenario.d.ts +11 -0
- package/dist/e2e-harness/scenario.d.ts.map +1 -0
- package/dist/e2e-harness/scenario.js +89 -0
- package/dist/e2e-harness/schemas/demo-cycle.schema.json +282 -0
- package/dist/e2e-harness/schemas/demo-step.schema.json +245 -0
- package/dist/e2e-harness/schemas/e2e-claim-row.schema.json +33 -0
- package/dist/e2e-harness/schemas/e2e-claims.schema.json +18 -0
- package/dist/e2e-harness/schemas/e2e-scenario.schema.json +150 -0
- package/dist/e2e-harness/schemas/index.d.ts +191 -0
- package/dist/e2e-harness/schemas/index.d.ts.map +1 -0
- package/dist/e2e-harness/schemas/index.js +62 -0
- package/dist/e2e-harness/stack.d.ts +124 -0
- package/dist/e2e-harness/stack.d.ts.map +1 -0
- package/dist/e2e-harness/stack.js +207 -0
- package/dist/e2e-harness/steps.d.ts +11 -0
- package/dist/e2e-harness/steps.d.ts.map +1 -0
- package/dist/e2e-harness/steps.js +22 -0
- package/dist/e2e-harness.d.ts +3 -0
- package/dist/e2e-harness.d.ts.map +1 -0
- package/dist/e2e-harness.js +2 -0
- package/dist/exit-codes.d.ts +7 -1
- package/dist/exit-codes.d.ts.map +1 -1
- package/dist/exit-codes.js +7 -1
- package/dist/lexicon.d.ts +46 -0
- package/dist/lexicon.d.ts.map +1 -1
- package/dist/lifecycle/gate-ledger.d.ts.map +1 -1
- package/dist/lifecycle/gate-ledger.js +2 -3
- package/dist/lifecycle/gated-request.d.ts.map +1 -1
- package/dist/lifecycle/gated-request.js +1 -2
- package/dist/lifecycle/query.d.ts.map +1 -1
- package/dist/lifecycle/query.js +4 -5
- package/dist/lifecycle/release-catalog.d.ts.map +1 -1
- package/dist/lifecycle/release-catalog.js +1 -1
- package/dist/lifecycle/release-ledger.d.ts.map +1 -1
- package/dist/lifecycle/release-ledger.js +1 -2
- package/dist/lifecycle/release-status.d.ts +20 -0
- package/dist/lifecycle/release-status.d.ts.map +1 -1
- package/dist/lifecycle/release-status.js +1 -22
- package/dist/lifecycle/wave-plans.d.ts +23 -7
- package/dist/lifecycle/wave-plans.d.ts.map +1 -1
- package/dist/lifecycle/wave-plans.js +9 -2
- package/dist/op/approval-status.d.ts +103 -0
- package/dist/op/approval-status.d.ts.map +1 -0
- package/dist/op/approval-status.js +197 -0
- package/dist/op/index.d.ts +1 -1
- package/dist/op/index.d.ts.map +1 -1
- package/dist/op/index.js +1 -1
- package/dist/op/op-waves-capability-spec.d.ts +8 -0
- package/dist/op/op-waves-capability-spec.d.ts.map +1 -1
- package/dist/op/op-waves-capability-spec.js +21 -0
- package/dist/op/op-waves-release.d.ts.map +1 -1
- package/dist/op/op-waves-release.js +1 -2
- package/dist/op/op-waves-run.d.ts +7 -2
- package/dist/op/op-waves-run.d.ts.map +1 -1
- package/dist/op/op-waves-run.js +96 -4
- package/dist/op/op-waves-stand-down.d.ts.map +1 -1
- package/dist/op/op-waves-stand-down.js +1 -2
- package/dist/op/op-waves.d.ts +35 -0
- package/dist/op/op-waves.d.ts.map +1 -1
- package/dist/op/op-waves.js +46 -6
- package/dist/op/runtime.d.ts +4 -0
- package/dist/op/runtime.d.ts.map +1 -1
- package/dist/op/runtime.js +2 -3
- package/dist/otlp.d.ts.map +1 -1
- package/dist/otlp.js +1 -2
- package/dist/parallelism.d.ts +17 -0
- package/dist/parallelism.d.ts.map +1 -0
- package/dist/parallelism.js +33 -0
- package/dist/policy-source.d.ts.map +1 -1
- package/dist/policy-source.js +1 -2
- package/dist/pr-forge.d.ts.map +1 -1
- package/dist/pr-forge.js +56 -39
- package/dist/pr-loop.d.ts +9 -0
- package/dist/pr-loop.d.ts.map +1 -1
- package/dist/pr-loop.js +22 -3
- package/dist/pr-merge.d.ts +64 -0
- package/dist/pr-merge.d.ts.map +1 -0
- package/dist/pr-merge.js +78 -0
- package/dist/pr-post.d.ts +70 -1
- package/dist/pr-post.d.ts.map +1 -1
- package/dist/pr-post.js +116 -5
- package/dist/pr-report-url.d.ts.map +1 -1
- package/dist/pr-report-url.js +1 -2
- package/dist/release-floors.d.ts +1 -1
- package/dist/release-floors.js +1 -1
- package/dist/run-event.d.ts.map +1 -1
- package/dist/run-event.js +1 -2
- package/dist/scheduled-op-cloud.d.ts +32 -0
- package/dist/scheduled-op-cloud.d.ts.map +1 -0
- package/dist/scheduled-op-cloud.js +69 -0
- package/dist/wave-runtime.mjs +340 -327
- package/dist/workspace/ci-lock-grain.d.ts +5 -0
- package/dist/workspace/ci-lock-grain.d.ts.map +1 -1
- package/dist/workspace/ci-lock-grain.js +1 -7
- package/dist/workspace/ci-run.d.ts.map +1 -1
- package/dist/workspace/ci-run.js +5 -1
- package/dist/workspace/pr-report.schema.json +5 -0
- package/package.json +1 -1
- package/src/ci-agent.ts +1 -2
- package/src/ci-audit/__fixtures__/cloudtrail-lookup-bucket.json +37 -0
- package/src/ci-audit/__fixtures__/cloudtrail-writes-window.json +59 -0
- package/src/ci-audit/attribution.ts +260 -0
- package/src/ci-audit/audit-log.ts +220 -0
- package/src/ci-audit/ci-audit.test.ts +175 -0
- package/src/ci-audit/index.ts +15 -0
- package/src/ci-audit/unrecorded.ts +140 -0
- package/src/ci-audit.ts +2 -0
- package/src/ci-control.ts +3 -4
- package/src/ci-estate.ts +1 -2
- package/src/ci-identity-database.test.ts +2 -3
- package/src/ci-identity-targets.test.ts +1 -3
- package/src/ci-identity.ts +2 -3
- package/src/ci-job-guard.test.ts +154 -0
- package/src/ci-job-guard.ts +319 -0
- package/src/ci-jobs.ts +8 -0
- package/src/ci-product-comment-targets.test.ts +45 -0
- package/src/ci-product-words.ts +35 -6
- package/src/ci-product.ts +55 -3
- package/src/ci-respond-run.ts +291 -0
- package/src/ci-respond.test.ts +264 -0
- package/src/ci-respond.ts +412 -0
- package/src/cli/handlers/audit-log.ts +74 -0
- package/src/cli/handlers/build-pr-loop-flags.test.ts +98 -0
- package/src/cli/handlers/build.ts +69 -0
- package/src/cli/handlers/ci-check-job.test.ts +114 -0
- package/src/cli/handlers/ci-check-job.ts +33 -0
- package/src/cli/handlers/ci-check.ts +38 -8
- package/src/cli/handlers/e2e-safe-run.ts +27 -0
- package/src/cli/handlers/pr-plan-comment-targets.test.ts +166 -0
- package/src/cli/handlers/pr-plan-flags.test.ts +161 -0
- package/src/cli/handlers/pr.ts +228 -4
- package/src/cli/handlers/run-wave.ts +79 -1
- package/src/cli/main.test.ts +1 -1
- package/src/cli/main.ts +56 -2
- package/src/cli/parse-args.ts +77 -0
- package/src/cli/registry.ts +38 -0
- package/src/components/adoption.ts +1 -2
- package/src/components/capability.ts +50 -0
- package/src/components/check-hooks.ts +4 -1
- package/src/components/check-steps.test.ts +70 -0
- package/src/components/check-steps.ts +158 -0
- package/src/components/ci-services.ts +1 -2
- package/src/components/driver.ts +35 -1
- package/src/components/groups.ts +4 -2
- package/src/components/plan-flags.test.ts +46 -0
- package/src/components/pr-comment-preview-targets.test.ts +34 -0
- package/src/components/pr-env-ledger.ts +1 -2
- package/src/components/pr-env-run-bundle.test.ts +0 -20
- package/src/components/pr-environment.ts +1 -1
- package/src/components/pr-pipeline-runners.test.ts +80 -0
- package/src/components/pr-pipeline.ts +232 -17
- package/src/components/pr-run.ts +17 -6
- package/src/components/pr-stale-job.test.ts +34 -0
- package/src/components/product-pipeline.ts +50 -8
- package/src/components/wave-plan.ts +18 -2
- package/src/e2e-harness/__project__/chant.config.ts +4 -0
- package/src/e2e-harness/__project__/src/compose.ts +33 -0
- package/src/e2e-harness/bucket.ts +69 -0
- package/src/e2e-harness/claim.test.ts +150 -0
- package/src/e2e-harness/claim.ts +140 -0
- package/src/e2e-harness/driver.test.ts +304 -0
- package/src/e2e-harness/driver.ts +294 -0
- package/src/e2e-harness/forgejo.ts +267 -0
- package/src/e2e-harness/git.ts +96 -0
- package/src/e2e-harness/index.ts +50 -0
- package/src/e2e-harness/jobs.ts +35 -0
- package/src/e2e-harness/pins.ts +52 -0
- package/src/e2e-harness/ports.ts +130 -0
- package/src/e2e-harness/reports.ts +79 -0
- package/src/e2e-harness/safe-run-cli.test.ts +102 -0
- package/src/e2e-harness/safe-run-cli.ts +54 -0
- package/src/e2e-harness/safe-run.ts +198 -0
- package/src/e2e-harness/scenario.ts +89 -0
- package/src/e2e-harness/schemas/README.md +62 -0
- package/src/e2e-harness/schemas/demo-cycle.schema.json +282 -0
- package/src/e2e-harness/schemas/demo-step.schema.json +245 -0
- package/src/e2e-harness/schemas/e2e-claim-row.schema.json +33 -0
- package/src/e2e-harness/schemas/e2e-claims.schema.json +18 -0
- package/src/e2e-harness/schemas/e2e-scenario.schema.json +150 -0
- package/src/e2e-harness/schemas/index.ts +220 -0
- package/src/e2e-harness/schemas.test.ts +145 -0
- package/src/e2e-harness/stack.test.ts +124 -0
- package/src/e2e-harness/stack.ts +306 -0
- package/src/e2e-harness/steps.ts +30 -0
- package/src/e2e-harness.ts +2 -0
- package/src/exit-codes.test.ts +3 -2
- package/src/exit-codes.ts +7 -1
- package/src/gate-decision-bundle.test.ts +0 -2
- package/src/lexicon.ts +48 -0
- package/src/lifecycle/control-entries-ledger.test.ts +2 -3
- package/src/lifecycle/gate-ledger.ts +2 -3
- package/src/lifecycle/gated-request.ts +1 -2
- package/src/lifecycle/query.ts +4 -5
- package/src/lifecycle/release-catalog.test.ts +3 -4
- package/src/lifecycle/release-catalog.ts +1 -1
- package/src/lifecycle/release-ledger.ts +1 -2
- package/src/lifecycle/release-status.test.ts +3 -4
- package/src/lifecycle/release-status.ts +1 -2
- package/src/lifecycle/wave-plans.ts +33 -5
- package/src/op/approval-status.test.ts +134 -0
- package/src/op/approval-status.ts +235 -0
- package/src/op/gate-review.test.ts +2 -1
- package/src/op/index.ts +2 -0
- package/src/op/op-waves-after-plan.test.ts +12 -0
- package/src/op/op-waves-capability-spec.ts +20 -0
- package/src/op/op-waves-parallelism.test.ts +89 -0
- package/src/op/op-waves-pull-request.test.ts +78 -1
- package/src/op/op-waves-release.ts +1 -2
- package/src/op/op-waves-run.ts +94 -4
- package/src/op/op-waves-stand-down.ts +1 -2
- package/src/op/op-waves.ts +63 -6
- package/src/op/runtime.ts +6 -3
- package/src/otlp.ts +1 -2
- package/src/parallelism.test.ts +38 -0
- package/src/parallelism.ts +33 -0
- package/src/policy-source.ts +1 -2
- package/src/pr-forge-bundle.test.ts +1 -1
- package/src/pr-forge.ts +54 -35
- package/src/pr-loop-bundle.test.ts +1 -1
- package/src/pr-loop-narrowed.test.ts +63 -0
- package/src/pr-loop.ts +30 -3
- package/src/pr-merge.test.ts +100 -0
- package/src/pr-merge.ts +105 -0
- package/src/pr-post-stale.test.ts +163 -0
- package/src/pr-post.ts +159 -5
- package/src/pr-report-url.ts +1 -2
- package/src/product-subpaths-plain-node.e2e.test.ts +1 -0
- package/src/release-floors.ts +1 -1
- package/src/run-event.ts +1 -2
- package/src/scheduled-op-cloud.ts +68 -0
- package/src/stage-hooks-bundle.test.ts +0 -2
- package/src/workspace/ci-lock-grain.ts +1 -2
- package/src/workspace/ci-run.ts +5 -1
- package/src/workspace/pr-report.schema.json +5 -0
|
@@ -85,11 +85,13 @@
|
|
|
85
85
|
* that one of its units reaches selects that unit.
|
|
86
86
|
*/
|
|
87
87
|
import type { ForgeKind } from "../pr-forge.js";
|
|
88
|
+
import { type CiRunner } from "../ci-jobs.js";
|
|
88
89
|
import type { DriverComponent } from "./driver.js";
|
|
89
90
|
import type { GatedWavePipelineOptions } from "./gated-wave-pipeline.js";
|
|
90
91
|
import type { CloudTradeSpec, PipelineCloudIdentity } from "../ci-identity.js";
|
|
91
92
|
import { type CiProductWords, type CiProductWordsInput } from "../ci-product-words.js";
|
|
92
93
|
import type { ControlTarget } from "../control/dispatch.js";
|
|
94
|
+
import { type CiResponses } from "../ci-respond.js";
|
|
93
95
|
/** Where both jobs write their reports, kept as a CI artifact. */
|
|
94
96
|
export declare const PR_LOOP_REPORT_DIR = ".chant/pr";
|
|
95
97
|
/**
|
|
@@ -162,6 +164,17 @@ export interface PrLoopPipelineOptions {
|
|
|
162
164
|
* four. Only with `applyBeforeMerge`.
|
|
163
165
|
*/
|
|
164
166
|
applyRequires?: readonly string[];
|
|
167
|
+
/**
|
|
168
|
+
* Merge the pull request once its update before merge applied (#4636):
|
|
169
|
+
* `pr-apply --merge auto --merge-token-env <tokenEnv>`. The token is the
|
|
170
|
+
* merge's alone: on GitHub and Forgejo the job maps it from the secret of
|
|
171
|
+
* that name, on GitLab it is a protected variable the project sets. Only
|
|
172
|
+
* with `applyBeforeMerge`.
|
|
173
|
+
*/
|
|
174
|
+
applyMerge?: {
|
|
175
|
+
tokenEnv: string;
|
|
176
|
+
method?: "merge" | "squash" | "rebase";
|
|
177
|
+
};
|
|
165
178
|
/**
|
|
166
179
|
* Stream each job's run events (#4007): `--events-json` on both commands,
|
|
167
180
|
* and `CHANT_RUN_EVENTS_DIR` set to {@link PR_LOOP_EVENTS_DIR}. Default false.
|
|
@@ -274,7 +287,104 @@ export interface PrLoopPipelineOptions {
|
|
|
274
287
|
* Default false.
|
|
275
288
|
*/
|
|
276
289
|
previewComment?: boolean;
|
|
290
|
+
/**
|
|
291
|
+
* Where the pull request loop's jobs run (#4625), by stage: `plan` for the
|
|
292
|
+
* plan and the comment preview, `apply` for the apply jobs, the record
|
|
293
|
+
* job and a pull request environment's up, down and sweep, and `default`
|
|
294
|
+
* for every other job (the note jobs, the lock jobs, the control
|
|
295
|
+
* dispatch) and for a stage left out. A plywood `runners` key maps
|
|
296
|
+
* `preview` onto `plan` and `up` onto `apply`. Absent: the forge's
|
|
297
|
+
* default runner.
|
|
298
|
+
*/
|
|
299
|
+
runners?: PrLoopRunners;
|
|
300
|
+
/**
|
|
301
|
+
* Variables for the jobs that plan or apply (#4625): the plan, the
|
|
302
|
+
* comment preview, the apply and the record. Values as the forge reads
|
|
303
|
+
* them; a name of a forge token or a token request variable is refused.
|
|
304
|
+
*/
|
|
305
|
+
variables?: Record<string, string>;
|
|
306
|
+
/**
|
|
307
|
+
* Secrets passed to the same jobs (#4625), as `{ <variable>: <secret> }`:
|
|
308
|
+
* the repository secret named `<secret>` as `<variable>`. GitHub and
|
|
309
|
+
* Forgejo map `secrets.<secret>`; GitLab, where every job has the CI/CD
|
|
310
|
+
* variables, maps `$<secret>` when the names differ. The plan job still
|
|
311
|
+
* drops the forge tokens before the change's code runs, and a passed name
|
|
312
|
+
* of a forge token is refused.
|
|
313
|
+
*/
|
|
314
|
+
secrets?: Record<string, string>;
|
|
315
|
+
/**
|
|
316
|
+
* How many members of a wave the plan job plans at once (#4625): `pr-plan
|
|
317
|
+
* --parallelism <n>`, on the plan and the comment preview. Absent: all of
|
|
318
|
+
* a wave's members at once.
|
|
319
|
+
*/
|
|
320
|
+
parallelism?: number;
|
|
321
|
+
/**
|
|
322
|
+
* The plan narrows to the `--target` addresses of the preview comment
|
|
323
|
+
* (#4626): `pr-plan --comment-targets`, which reads the comment from
|
|
324
|
+
* {@link PREVIEW_COMMENT_ENV}. {@link prCommentPreviewJob} sets it on its
|
|
325
|
+
* own plan; a caller never needs to.
|
|
326
|
+
*/
|
|
327
|
+
commentTargets?: boolean;
|
|
328
|
+
/**
|
|
329
|
+
* The plan and the comment preview refresh each step's state first
|
|
330
|
+
* (#4627): `pr-plan --refresh`, pulumi/actions' `refresh`. A member whose
|
|
331
|
+
* capability cannot is refused by name. Default false.
|
|
332
|
+
*/
|
|
333
|
+
refresh?: boolean;
|
|
334
|
+
/**
|
|
335
|
+
* Stale marking (#4628): the plan note carries the target branch's commit
|
|
336
|
+
* it was posted against, and a `stale-notes` job on each push to the
|
|
337
|
+
* target branch marks every open pull request's note posted against
|
|
338
|
+
* another commit stale, naming the plan comment under `previewComment`,
|
|
339
|
+
* and sets its plan status back to pending ({@link prStaleJob}). Set
|
|
340
|
+
* from `--stale-notes` beside `--pr-loop`. Default false.
|
|
341
|
+
*/
|
|
342
|
+
staleNotes?: boolean;
|
|
343
|
+
/**
|
|
344
|
+
* The responses to pipeline events (#4629, ../ci-respond.ts), from
|
|
345
|
+
* `chant build --pr-loop --respond <list>`: the apply job and the
|
|
346
|
+
* plan-note job carry the list as `CHANT_RESPOND`. Absent, or every event
|
|
347
|
+
* at its default: neither job sets it.
|
|
348
|
+
*/
|
|
349
|
+
respond?: CiResponses;
|
|
350
|
+
/**
|
|
351
|
+
* The decide service the description check asks (#4629), from
|
|
352
|
+
* `--decide-backend` and `--decide-model`: the plan-note job passes both
|
|
353
|
+
* to `pr-post`. Needed with `respond.description: "check"`.
|
|
354
|
+
*/
|
|
355
|
+
decide?: {
|
|
356
|
+
backend: string;
|
|
357
|
+
model: string;
|
|
358
|
+
};
|
|
277
359
|
}
|
|
360
|
+
/** The `CHANT_RESPOND` value of `respond` (#4629), or undefined when every event is at its default. Throws on a description check with no decide service. */
|
|
361
|
+
export declare function prLoopRespondEnv(options: Pick<PrLoopPipelineOptions, "respond" | "decide">): Record<string, string>;
|
|
362
|
+
/** The variable the comment preview's plan reads the comment from (#4626); never a shell argument. */
|
|
363
|
+
export declare const PREVIEW_COMMENT_ENV = "CHANT_PREVIEW_COMMENT";
|
|
364
|
+
/** Where the pull request loop's jobs run, by stage (#4625). */
|
|
365
|
+
export interface PrLoopRunners {
|
|
366
|
+
plan?: CiRunner;
|
|
367
|
+
apply?: CiRunner;
|
|
368
|
+
default?: CiRunner;
|
|
369
|
+
}
|
|
370
|
+
/** A pull request loop job's stage for its runner (#4625). */
|
|
371
|
+
export type PrLoopRunnerStage = keyof PrLoopRunners;
|
|
372
|
+
/** The runner of `stage` (#4625): the stage's own, else `default`, else undefined for the forge's default. */
|
|
373
|
+
export declare function prLoopRunner(options: Pick<PrLoopPipelineOptions, "runners">, stage: PrLoopRunnerStage): CiRunner | undefined;
|
|
374
|
+
/**
|
|
375
|
+
* The runner stage of a pull request loop job by its name (#4625), with a
|
|
376
|
+
* workspace member's `<member>-` prefix taken off first: the plan and the
|
|
377
|
+
* comment preview plan; the apply jobs, the record job and a pull request
|
|
378
|
+
* environment's up, down and sweep apply; every other job runs on the
|
|
379
|
+
* default.
|
|
380
|
+
*/
|
|
381
|
+
export declare function prLoopJobStage(name: string, member?: string): PrLoopRunnerStage;
|
|
382
|
+
/**
|
|
383
|
+
* The variables and passed secrets of the jobs that plan or apply (#4625),
|
|
384
|
+
* as the forge spells them. Throws on a name the loop sets itself or a
|
|
385
|
+
* forge token, which the plan must be able to drop.
|
|
386
|
+
*/
|
|
387
|
+
export declare function prLoopPassedEnv(forge: ForgeKind, options: Pick<PrLoopPipelineOptions, "variables" | "secrets">): Record<string, string>;
|
|
278
388
|
/** The lock job's step names and commands (#4327), shared by the GitHub-shaped generators. */
|
|
279
389
|
export declare const PR_LOCK_JOB = "lock";
|
|
280
390
|
export declare const PR_UNLOCK_JOB = "unlock";
|
|
@@ -423,6 +533,8 @@ export interface PrLoopJob {
|
|
|
423
533
|
command: string;
|
|
424
534
|
env: Record<string, string>;
|
|
425
535
|
};
|
|
536
|
+
/** Where the job runs (#4625), from the loop's `runners`: the plan's or the apply's, else `default`. Absent: the forge's default. */
|
|
537
|
+
runner?: CiRunner;
|
|
426
538
|
}
|
|
427
539
|
/** The lines `build` (#4088) runs before a job's command: the build, then the lint. Empty without the option. */
|
|
428
540
|
export declare function prLoopBuildLines(env: string, options?: PrLoopPipelineOptions): string[];
|
|
@@ -451,10 +563,25 @@ export declare const PR_PLAN_NOTE_JOB = "plan-note";
|
|
|
451
563
|
* asks GitLab for each open merge request's plan job and reads its report
|
|
452
564
|
* from the job's artifacts.
|
|
453
565
|
*/
|
|
454
|
-
export declare function prLoopPostJob(forge: ForgeKind, env: string, member?: string, words?: Pick<CiProductWordsInput, "bin"
|
|
566
|
+
export declare function prLoopPostJob(forge: ForgeKind, env: string, member?: string, words?: Pick<CiProductWordsInput, "bin">, opts?: {
|
|
567
|
+
staleNotes?: boolean;
|
|
568
|
+
} & Pick<PrLoopPipelineOptions, "respond" | "decide">): {
|
|
455
569
|
command: string;
|
|
456
570
|
env: Record<string, string>;
|
|
457
571
|
};
|
|
572
|
+
/** The job that marks the open pull requests' notes stale after a push to the target branch (#4628). */
|
|
573
|
+
export declare const PR_STALE_JOB = "stale-notes";
|
|
574
|
+
/**
|
|
575
|
+
* The stale job's command and the values it reads (#4628), with
|
|
576
|
+
* `staleNotes`: on a push to the target branch, at its commit, `pr-post
|
|
577
|
+
* --stale` marks each open pull request's note posted against another
|
|
578
|
+
* commit stale and sets its plan status back to pending. It names the plan
|
|
579
|
+
* comment with `previewComment`. Undefined without `staleNotes`.
|
|
580
|
+
*/
|
|
581
|
+
export declare function prStaleJob(forge: ForgeKind, env: string, options?: Pick<PrLoopPipelineOptions, "staleNotes" | "previewComment" | "branch" | "words">, member?: string): {
|
|
582
|
+
command: string;
|
|
583
|
+
env: Record<string, string>;
|
|
584
|
+
} | undefined;
|
|
458
585
|
/** The plan job's name in a GitLab merge request pipeline (#3465, #4328): `plan`, or `<member>-plan` in a workspace member's included file. */
|
|
459
586
|
export declare function gitlabPlanJobName(member?: string): string;
|
|
460
587
|
/**
|
|
@@ -556,8 +683,7 @@ export declare function gitlabBaseFallback(branch?: string): string;
|
|
|
556
683
|
* generators' default.
|
|
557
684
|
*/
|
|
558
685
|
export declare function githubBaseFallback(branch?: string): string;
|
|
559
|
-
|
|
560
|
-
export declare const PR_ENV_REPORT_DIR = ".chant/pr-env";
|
|
686
|
+
export { PR_ENV_REPORT_DIR } from "../ci-jobs.js";
|
|
561
687
|
/** The cron the generated `env-sweep` job runs on (#4298): hourly, at a minute off the hour. */
|
|
562
688
|
export declare const PR_ENV_SWEEP_CRON = "17 * * * *";
|
|
563
689
|
/** One job of a pull request's environment (#4298): its command and the forge values it reads. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pr-pipeline.d.ts","sourceRoot":"","sources":["../../src/components/pr-pipeline.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqFG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"pr-pipeline.d.ts","sourceRoot":"","sources":["../../src/components/pr-pipeline.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqFG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAG7C,OAAO,EAA+D,KAAK,QAAQ,EAAE,MAAM,YAAY,CAAC;AAMxG,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAChD,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAC;AACtE,OAAO,KAAK,EAAE,cAAc,EAAE,qBAAqB,EAAE,MAAM,gBAAgB,CAAC;AAC5E,OAAO,EAAoC,KAAK,cAAc,EAAE,KAAK,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AACtH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACzD,OAAO,EAA+B,KAAK,WAAW,EAAE,MAAM,eAAe,CAAC;AAK9E,kEAAkE;AAClE,eAAO,MAAM,kBAAkB,cAAc,CAAC;AAE9C;;;;GAIG;AACH,eAAO,MAAM,eAAe,mCAAmC,CAAC;AAEhE;;;;;GAKG;AACH,eAAO,MAAM,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H,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,SAAS,GAAG,MAAM,CAG5D;AAED;;;;GAIG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAEpD;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAE1D;AAOD;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAE1D;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAE1D;AAED,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAE/C,gGAAgG;AAChG,eAAO,MAAM,iBAAiB,eAAe,CAAC;AAE9C,kGAAkG;AAClG,MAAM,WAAW,QAAQ;IACvB,OAAO,EAAE,QAAQ,GAAG,UAAU,GAAG,UAAU,GAAG,WAAW,CAAC;IAC1D,8FAA8F;IAC9F,OAAO,EAAE,MAAM,CAAC;IAChB,yGAAyG;IACzG,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC5B,sEAAsE;IACtE,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB;AAED,gGAAgG;AAChG,eAAO,MAAM,eAAe,aAAa,CAAC;AAE1C;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,SAAS,EAAE,OAAO,GAAE,qBAA0B,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,QAAQ,EAAE,CAkC5G"}
|
|
@@ -86,11 +86,14 @@
|
|
|
86
86
|
*/
|
|
87
87
|
import { PR_APPLY_GATE } from "../pr-loop.js";
|
|
88
88
|
import { parseRequiresList } from "../pr-requires.js";
|
|
89
|
-
import { CI_IMAGE, GITHUB_JOB_TOKEN } from "../ci-jobs.js";
|
|
90
|
-
import { withoutForgeTokens } from "../ci-handover.js";
|
|
89
|
+
import { CI_IMAGE, GITHUB_JOB_TOKEN, githubSecret, PR_ENV_REPORT_DIR } from "../ci-jobs.js";
|
|
90
|
+
import { FORGE_TOKEN_VARS, withoutForgeTokens } from "../ci-handover.js";
|
|
91
|
+
import { OIDC_REQUEST_VARS } from "../ci-identity.js";
|
|
92
|
+
import { parallelismProblem } from "../parallelism.js";
|
|
91
93
|
import { EMPTY_TREE_SHA } from "./changed-files.js";
|
|
92
94
|
import { layerWaves } from "../gated-waves.js";
|
|
93
95
|
import { commentLine, resolveProductWords } from "../ci-product-words.js";
|
|
96
|
+
import { CI_RESPOND_ENV, respondList } from "../ci-respond.js";
|
|
94
97
|
/** The variable `chant ci run` reads its runner key from (`RUNNER_KEY_ENV` in ../workspace/ci-green.ts). */
|
|
95
98
|
const RUNNER_KEY_ENV = "CHANT_RUNNER_KEY";
|
|
96
99
|
/** Where both jobs write their reports, kept as a CI artifact. */
|
|
@@ -138,6 +141,66 @@ export function engineSetupLines(perLexicon) {
|
|
|
138
141
|
* artifact carries them.
|
|
139
142
|
*/
|
|
140
143
|
export const PR_LOOP_EVENTS_DIR = `${PR_LOOP_REPORT_DIR}/run-events`;
|
|
144
|
+
/** The `CHANT_RESPOND` value of `respond` (#4629), or undefined when every event is at its default. Throws on a description check with no decide service. */
|
|
145
|
+
export function prLoopRespondEnv(options) {
|
|
146
|
+
if (options.respond?.description === "check" && !options.decide)
|
|
147
|
+
throw new Error("respond.description: check asks a decide service, so the pipeline needs decide: { backend, model }");
|
|
148
|
+
const list = options.respond ? respondList(options.respond) : "";
|
|
149
|
+
return list ? { [CI_RESPOND_ENV]: list } : {};
|
|
150
|
+
}
|
|
151
|
+
/** The variable the comment preview's plan reads the comment from (#4626); never a shell argument. */
|
|
152
|
+
export const PREVIEW_COMMENT_ENV = "CHANT_PREVIEW_COMMENT";
|
|
153
|
+
/** The runner of `stage` (#4625): the stage's own, else `default`, else undefined for the forge's default. */
|
|
154
|
+
export function prLoopRunner(options, stage) {
|
|
155
|
+
return options.runners?.[stage] ?? options.runners?.default;
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* The runner stage of a pull request loop job by its name (#4625), with a
|
|
159
|
+
* workspace member's `<member>-` prefix taken off first: the plan and the
|
|
160
|
+
* comment preview plan; the apply jobs, the record job and a pull request
|
|
161
|
+
* environment's up, down and sweep apply; every other job runs on the
|
|
162
|
+
* default.
|
|
163
|
+
*/
|
|
164
|
+
export function prLoopJobStage(name, member) {
|
|
165
|
+
const bare = member && name.startsWith(`${member}-`) ? name.slice(member.length + 1) : name;
|
|
166
|
+
if (bare === "plan" || bare === PR_COMMENT_PREVIEW_JOB)
|
|
167
|
+
return "plan";
|
|
168
|
+
if (bare === "apply" || bare === "record" || /^apply-wave-\d+$/.test(bare) || bare === "env-up" || bare === "env-down" || bare === "env-sweep")
|
|
169
|
+
return "apply";
|
|
170
|
+
return "default";
|
|
171
|
+
}
|
|
172
|
+
/**
|
|
173
|
+
* The variables and passed secrets of the jobs that plan or apply (#4625),
|
|
174
|
+
* as the forge spells them. Throws on a name the loop sets itself or a
|
|
175
|
+
* forge token, which the plan must be able to drop.
|
|
176
|
+
*/
|
|
177
|
+
export function prLoopPassedEnv(forge, options) {
|
|
178
|
+
const reserved = new Set([...FORGE_TOKEN_VARS, ...OIDC_REQUEST_VARS, "BASE_SHA", "PR_NUMBER", "HEAD_SHA", "GREEN_SHA", "CHANT_RUN_EVENTS_DIR", "CHANT_RUNNER_KEY"]);
|
|
179
|
+
const out = {};
|
|
180
|
+
const name = /^[A-Za-z_][A-Za-z0-9_]*$/;
|
|
181
|
+
for (const [key, value] of Object.entries(options.variables ?? {})) {
|
|
182
|
+
if (!name.test(key))
|
|
183
|
+
throw new Error(`the pull request jobs' variable ${JSON.stringify(key)} is not a variable name`);
|
|
184
|
+
if (reserved.has(key))
|
|
185
|
+
throw new Error(`the pull request jobs' variable ${key} is one the jobs set or drop themselves; give it another name`);
|
|
186
|
+
out[key] = value;
|
|
187
|
+
}
|
|
188
|
+
for (const [key, secret] of Object.entries(options.secrets ?? {})) {
|
|
189
|
+
if (!name.test(key) || !name.test(secret))
|
|
190
|
+
throw new Error(`the passed secret ${JSON.stringify(key)}: ${JSON.stringify(secret)} must map a variable name to a secret name`);
|
|
191
|
+
if (reserved.has(key))
|
|
192
|
+
throw new Error(`the passed secret ${key} is a name the jobs set or drop themselves, and the plan job drops the forge tokens before the change's code runs; pass it under another name`);
|
|
193
|
+
if (key in out)
|
|
194
|
+
throw new Error(`${key} is both a variable and a passed secret of the pull request jobs; give one`);
|
|
195
|
+
if (forge === "gitlab") {
|
|
196
|
+
if (key !== secret)
|
|
197
|
+
out[key] = `$${secret}`;
|
|
198
|
+
}
|
|
199
|
+
else
|
|
200
|
+
out[key] = githubSecret(secret);
|
|
201
|
+
}
|
|
202
|
+
return out;
|
|
203
|
+
}
|
|
141
204
|
/** The lock job's step names and commands (#4327), shared by the GitHub-shaped generators. */
|
|
142
205
|
export const PR_LOCK_JOB = "lock";
|
|
143
206
|
export const PR_UNLOCK_JOB = "unlock";
|
|
@@ -225,13 +288,15 @@ export function prCommentPreviewJob(forge, env, options = {}, member) {
|
|
|
225
288
|
if (!comment)
|
|
226
289
|
throw new Error(`--preview-comment answers /${words.product} <plan command>, and the words name no plan command; name one in the words' commands, or drop --preview-comment`);
|
|
227
290
|
// The plan job's own command: the apply side's options never reach it, so they are left out here.
|
|
228
|
-
const { applyBeforeMerge: _early, applyRequires: _requires, applyOnMerge: _onMerge, ...planSide } = options;
|
|
229
|
-
|
|
291
|
+
const { applyBeforeMerge: _early, applyRequires: _requires, applyMerge: _merge, applyOnMerge: _onMerge, respond: _respond, decide: _decide, ...planSide } = options;
|
|
292
|
+
// #4626: the comment's --target addresses narrow the preview, read from the comment in a variable.
|
|
293
|
+
const [plan] = prLoopJobs(forge, env, { ...planSide, commentTargets: true }, member);
|
|
230
294
|
const github = forge !== "gitlab";
|
|
231
295
|
const prNumber = github ? "${{ github.event.issue.number }}" : `$${GITLAB_PREVIEW_PR_VAR}`;
|
|
296
|
+
// GitLab: whoever starts the target-branch pipeline passes the comment as CHANT_PREVIEW_COMMENT, a pipeline variable every job has.
|
|
232
297
|
const fromComment = (jobEnv) => {
|
|
233
298
|
const { BASE_SHA: _base, ...rest } = jobEnv;
|
|
234
|
-
return github ? { ...rest, PR_NUMBER: prNumber } : { ...rest, PR_NUMBER: prNumber, BASE_SHA: "$CI_COMMIT_SHA" };
|
|
299
|
+
return github ? { ...rest, PR_NUMBER: prNumber, [PREVIEW_COMMENT_ENV]: "${{ github.event.comment.body }}" } : { ...rest, PR_NUMBER: prNumber, BASE_SHA: "$CI_COMMIT_SHA" };
|
|
235
300
|
};
|
|
236
301
|
const branch = options.branch ?? "main";
|
|
237
302
|
const base = github
|
|
@@ -242,7 +307,10 @@ export function prCommentPreviewJob(forge, env, options = {}, member) {
|
|
|
242
307
|
"--env", env, "--output", PR_LOOP_REPORT_DIR, "--forge", forge,
|
|
243
308
|
...(member ? ["--member", member] : []),
|
|
244
309
|
...(github ? ["--result", '"$PLAN_RESULT"'] : []),
|
|
310
|
+
// #4628: the target branch's commit the preview measured from, for the note's tip line.
|
|
311
|
+
...(options.staleNotes ? ["--tip", '"$TIP_SHA"'] : []),
|
|
245
312
|
].join(" "), words.bin);
|
|
313
|
+
const tipEnv = options.staleNotes ? { TIP_SHA: github ? "${{ github.sha }}" : "$CI_COMMIT_SHA" } : {};
|
|
246
314
|
return {
|
|
247
315
|
jobName: PR_COMMENT_PREVIEW_JOB,
|
|
248
316
|
noteJobName: PR_COMMENT_PREVIEW_NOTE_JOB,
|
|
@@ -257,12 +325,13 @@ export function prCommentPreviewJob(forge, env, options = {}, member) {
|
|
|
257
325
|
PR_NUMBER: prNumber,
|
|
258
326
|
HEAD_SHA: `\${{ needs.${PR_COMMENT_PREVIEW_JOB}.outputs.${PREVIEW_HEAD_OUTPUT} }}`,
|
|
259
327
|
PLAN_RESULT: `\${{ needs.${PR_COMMENT_PREVIEW_JOB}.result }}`,
|
|
328
|
+
...tipEnv,
|
|
260
329
|
GITHUB_TOKEN: GITHUB_JOB_TOKEN,
|
|
261
330
|
},
|
|
262
331
|
}
|
|
263
332
|
: {
|
|
264
333
|
command: postCommand,
|
|
265
|
-
env: { PR_NUMBER: prNumber },
|
|
334
|
+
env: { PR_NUMBER: prNumber, ...tipEnv },
|
|
266
335
|
setup: ['HEAD_SHA="$(git ls-remote origin "refs/merge-requests/$PR_NUMBER/head" | cut -f1)" && export HEAD_SHA'],
|
|
267
336
|
},
|
|
268
337
|
...(github ? {} : { gitlabVar: GITLAB_PREVIEW_PR_VAR }),
|
|
@@ -295,6 +364,12 @@ export function prLoopJobs(forge, env, options = {}, member) {
|
|
|
295
364
|
if (asked && "error" in asked)
|
|
296
365
|
throw new Error(asked.error);
|
|
297
366
|
const requires = early && asked ? ["--requires", asked.checks.join(",")] : [];
|
|
367
|
+
if (options.applyMerge && !early)
|
|
368
|
+
throw new Error("--merge auto merges a pull request after its update before merge, so it needs --apply-before-merge");
|
|
369
|
+
if (options.applyMerge && !/^[A-Za-z_][A-Za-z0-9_]*$/.test(options.applyMerge.tokenEnv))
|
|
370
|
+
throw new Error(`the merge token variable ${JSON.stringify(options.applyMerge.tokenEnv)} is not a variable name`);
|
|
371
|
+
// #4636: the merge after the update, with its own token.
|
|
372
|
+
const merge = early && options.applyMerge ? ["--merge", "auto", "--merge-token-env", options.applyMerge.tokenEnv, ...(options.applyMerge.method ? ["--merge-method", options.applyMerge.method] : [])] : [];
|
|
298
373
|
const common = [
|
|
299
374
|
"--env", env, "--gate", gate, "--output", PR_LOOP_REPORT_DIR, "--forge", forge,
|
|
300
375
|
...(member ? ["--member", member] : []),
|
|
@@ -304,15 +379,28 @@ export function prLoopJobs(forge, env, options = {}, member) {
|
|
|
304
379
|
const github = forge !== "gitlab";
|
|
305
380
|
const buildLines = prLoopBuildLines(env, options);
|
|
306
381
|
const build = buildLines.length > 0 ? { build: buildLines } : {};
|
|
382
|
+
// #4625: the caller's variables and passed secrets, in every job that plans or applies.
|
|
307
383
|
const jobEnv = {
|
|
384
|
+
...prLoopPassedEnv(forge, options),
|
|
308
385
|
...(github ? { GITHUB_TOKEN: GITHUB_JOB_TOKEN } : {}),
|
|
309
386
|
...(options.events ? { CHANT_RUN_EVENTS_DIR: PR_LOOP_EVENTS_DIR } : {}),
|
|
310
387
|
};
|
|
388
|
+
const planRunner = prLoopRunner(options, "plan");
|
|
389
|
+
if (options.parallelism !== undefined) {
|
|
390
|
+
const problem = parallelismProblem("parallelism", options.parallelism);
|
|
391
|
+
if (problem)
|
|
392
|
+
throw new Error(`the pull request plan's ${problem}`);
|
|
393
|
+
}
|
|
394
|
+
const parallelism = options.parallelism !== undefined ? ["--parallelism", String(options.parallelism)] : [];
|
|
395
|
+
const applyRunner = prLoopRunner(options, "apply");
|
|
311
396
|
// #4156: the flags `chant ci run` rebuilds `command` from. It finds the member from the directory it runs in.
|
|
312
397
|
const ciRun = (job) => [
|
|
313
398
|
"chant", "ci", "run", job, "--in-place", ...(job === "plan" ? ["--no-push"] : []),
|
|
314
399
|
...(job === "apply" && !early ? [] : ["--base", '"$BASE_SHA"']), ...(job === "plan" || (job === "apply" && early) ? ["--pr", '"$PR_NUMBER"'] : []),
|
|
315
|
-
...(job === "apply" && early ? ["--apply-before-merge", ...requires] : []),
|
|
400
|
+
...(job === "apply" && early ? ["--apply-before-merge", ...requires, ...merge] : []),
|
|
401
|
+
...(job === "plan" ? parallelism : []),
|
|
402
|
+
...(job === "plan" && options.commentTargets ? ["--comment-targets"] : []),
|
|
403
|
+
...(job === "plan" && options.refresh ? ["--refresh"] : []),
|
|
316
404
|
"--env", env, "--gate", gate, "--forge", forge,
|
|
317
405
|
...(job !== "record" && options.waveGate ? ["--wave-gate", options.waveGate] : []),
|
|
318
406
|
...(job !== "plan" && options.branch ? ["--branch", JSON.stringify(options.branch)] : []),
|
|
@@ -330,8 +418,9 @@ export function prLoopJobs(forge, env, options = {}, member) {
|
|
|
330
418
|
const greenBranch = github ? JSON.stringify(options.branch ?? "main") : options.branch ? JSON.stringify(options.branch) : "$CI_DEFAULT_BRANCH";
|
|
331
419
|
const applyEnv = github ? { BASE_SHA: "${{ github.event.before }}", ...jobEnv } : { BASE_SHA: "$CI_COMMIT_BEFORE_SHA", ...jobEnv };
|
|
332
420
|
// #4301: the apply before merge runs in a job of the target branch, whose commit is the base, at the pull request's head.
|
|
421
|
+
const mergeSecret = github && options.applyMerge ? { [options.applyMerge.tokenEnv]: `\${{ secrets.${options.applyMerge.tokenEnv} }}` } : {};
|
|
333
422
|
const earlyEnv = github
|
|
334
|
-
? { BASE_SHA: "${{ github.sha }}", PR_NUMBER: "${{ github.event.issue.number }}", ...jobEnv }
|
|
423
|
+
? { BASE_SHA: "${{ github.sha }}", PR_NUMBER: "${{ github.event.issue.number }}", ...jobEnv, ...mergeSecret }
|
|
335
424
|
: { BASE_SHA: "$CI_COMMIT_SHA", PR_NUMBER: `$${GITLAB_APPLY_PR_VAR}`, ...jobEnv };
|
|
336
425
|
const greenApply = {
|
|
337
426
|
// #4168 step 9: the apply applies the newest green commit, measured from the one applied before it.
|
|
@@ -345,6 +434,7 @@ export function prLoopJobs(forge, env, options = {}, member) {
|
|
|
345
434
|
env: jobEnv,
|
|
346
435
|
checkout: [greenCheckout(greenBranch)],
|
|
347
436
|
greenBranch,
|
|
437
|
+
...(applyRunner !== undefined ? { runner: applyRunner } : {}),
|
|
348
438
|
...build,
|
|
349
439
|
run: { command: ciRun("apply").join(" "), env: runEnv(jobEnv) },
|
|
350
440
|
};
|
|
@@ -352,32 +442,39 @@ export function prLoopJobs(forge, env, options = {}, member) {
|
|
|
352
442
|
// #4301: the requires checks run inside pr-apply, before any of the head's code loads.
|
|
353
443
|
jobName: "apply",
|
|
354
444
|
command: [
|
|
355
|
-
"chant", "components", "pr-apply", "--before-merge", ...requires, "--base", '"$BASE_SHA"', "--pr", '"$PR_NUMBER"', ...common,
|
|
445
|
+
"chant", "components", "pr-apply", "--before-merge", ...requires, ...merge, "--base", '"$BASE_SHA"', "--pr", '"$PR_NUMBER"', ...common,
|
|
356
446
|
...(options.requireReview === true ? ["--require-review"] : []),
|
|
357
447
|
"--resume", PR_APPLY_RECORD,
|
|
358
448
|
].join(" "),
|
|
359
449
|
env: earlyEnv,
|
|
360
450
|
checkout: [pullRequestCheckout(forge)],
|
|
451
|
+
...(applyRunner !== undefined ? { runner: applyRunner } : {}),
|
|
361
452
|
run: { command: ciRun("apply").join(" "), env: runEnv(earlyEnv) },
|
|
362
453
|
};
|
|
363
454
|
const bin = options.words?.bin;
|
|
455
|
+
// #4629: the apply posts a failed apply's triage and a refused one's diff as CHANT_RESPOND says.
|
|
456
|
+
const respondEnv = prLoopRespondEnv(options);
|
|
457
|
+
const withRespond = (job) => (Object.keys(respondEnv).length > 0 ? { ...job, env: { ...job.env, ...respondEnv }, run: { ...job.run, env: { ...job.run.env, ...respondEnv } } } : job);
|
|
364
458
|
return [
|
|
365
459
|
{
|
|
366
460
|
jobName: "plan",
|
|
367
461
|
// With `waveGate` the plan's note says the later waves may stop at their own gates (#4003).
|
|
368
|
-
command: ["chant", "components", "pr-plan", "--base", '"$BASE_SHA"', "--pr", '"$PR_NUMBER"', ...common, ...(options.waveGate ? ["--wave-gate", options.waveGate] : []), "--no-status"].join(" "),
|
|
462
|
+
command: ["chant", "components", "pr-plan", "--base", '"$BASE_SHA"', "--pr", '"$PR_NUMBER"', ...common, ...(options.waveGate ? ["--wave-gate", options.waveGate] : []), ...parallelism, ...(options.commentTargets ? ["--comment-targets"] : []), ...(options.refresh ? ["--refresh"] : []), "--no-status"].join(" "),
|
|
369
463
|
env: planEnv,
|
|
370
464
|
...build,
|
|
465
|
+
...(planRunner !== undefined ? { runner: planRunner } : {}),
|
|
371
466
|
// #4328: no runner key either. The step drops it, but the job's environment is the pull request's code's too.
|
|
372
467
|
run: { command: ciRun("plan").join(" "), env: planEnv },
|
|
373
468
|
},
|
|
374
|
-
early ? earlyApply : greenApply,
|
|
469
|
+
withRespond(early ? earlyApply : greenApply),
|
|
375
470
|
{
|
|
376
471
|
jobName: "record",
|
|
377
472
|
command: ["chant", "components", "pr-record", "--base", '"$BASE_SHA"', ...common].join(" "),
|
|
378
473
|
env: applyEnv,
|
|
379
474
|
setup: [github ? githubBaseFallback(options.branch) : gitlabBaseFallback(options.branch)],
|
|
380
475
|
...build,
|
|
476
|
+
// The record runs on merge, where the apply would.
|
|
477
|
+
...(applyRunner !== undefined ? { runner: applyRunner } : {}),
|
|
381
478
|
run: { command: ciRun("record").join(" "), env: runEnv(applyEnv) },
|
|
382
479
|
},
|
|
383
480
|
].map((job) => jobWithBin(job, bin));
|
|
@@ -400,11 +497,20 @@ export const PR_PLAN_NOTE_JOB = "plan-note";
|
|
|
400
497
|
* asks GitLab for each open merge request's plan job and reads its report
|
|
401
498
|
* from the job's artifacts.
|
|
402
499
|
*/
|
|
403
|
-
export function prLoopPostJob(forge, env, member, words) {
|
|
500
|
+
export function prLoopPostJob(forge, env, member, words, opts = {}) {
|
|
501
|
+
// #4629: the responses as CHANT_RESPOND, and with the description check its decide service on the line.
|
|
502
|
+
const respondEnv = prLoopRespondEnv(opts);
|
|
503
|
+
const decide = opts.respond?.description === "check" && opts.decide ? ` --decide-backend ${JSON.stringify(opts.decide.backend)} --decide-model ${JSON.stringify(opts.decide.model)}` : "";
|
|
504
|
+
const job = prLoopPostJobBase(forge, env, member, words, opts);
|
|
505
|
+
return decide || Object.keys(respondEnv).length > 0 ? { command: `${job.command}${decide}`, env: { ...job.env, ...respondEnv } } : job;
|
|
506
|
+
}
|
|
507
|
+
function prLoopPostJobBase(forge, env, member, words, opts) {
|
|
508
|
+
// #4628: with staleNotes the note carries the target branch's commit, so a later push can mark it stale.
|
|
509
|
+
const tip = opts.staleNotes ? ["--tip", '"$TIP_SHA"'] : [];
|
|
404
510
|
if (forge === "gitlab") {
|
|
405
511
|
return {
|
|
406
|
-
command: withProductBin(["chant", "components", "pr-post", "--open", "--env", env, "--output", PR_LOOP_REPORT_DIR, "--forge", forge, ...(member ? ["--member", member] : [])].join(" "), words?.bin),
|
|
407
|
-
env: {},
|
|
512
|
+
command: withProductBin(["chant", "components", "pr-post", "--open", "--env", env, "--output", PR_LOOP_REPORT_DIR, "--forge", forge, ...(member ? ["--member", member] : []), ...tip].join(" "), words?.bin),
|
|
513
|
+
env: opts.staleNotes ? { TIP_SHA: "$CI_COMMIT_SHA" } : {},
|
|
408
514
|
};
|
|
409
515
|
}
|
|
410
516
|
const command = [
|
|
@@ -412,10 +518,41 @@ export function prLoopPostJob(forge, env, member, words) {
|
|
|
412
518
|
"--env", env, "--output", PR_LOOP_REPORT_DIR, "--forge", forge,
|
|
413
519
|
...(member ? ["--member", member] : []),
|
|
414
520
|
"--result", '"$PLAN_RESULT"',
|
|
521
|
+
...tip,
|
|
415
522
|
].join(" ");
|
|
416
523
|
return {
|
|
417
524
|
command: withProductBin(command, words?.bin),
|
|
418
|
-
env: {
|
|
525
|
+
env: {
|
|
526
|
+
PR_NUMBER: "${{ github.event.pull_request.number }}",
|
|
527
|
+
HEAD_SHA: "${{ github.sha }}",
|
|
528
|
+
PLAN_RESULT: "${{ needs.plan.result }}",
|
|
529
|
+
...(opts.staleNotes ? { TIP_SHA: "${{ github.event.pull_request.base.sha }}" } : {}),
|
|
530
|
+
GITHUB_TOKEN: GITHUB_JOB_TOKEN,
|
|
531
|
+
},
|
|
532
|
+
};
|
|
533
|
+
}
|
|
534
|
+
/** The job that marks the open pull requests' notes stale after a push to the target branch (#4628). */
|
|
535
|
+
export const PR_STALE_JOB = "stale-notes";
|
|
536
|
+
/**
|
|
537
|
+
* The stale job's command and the values it reads (#4628), with
|
|
538
|
+
* `staleNotes`: on a push to the target branch, at its commit, `pr-post
|
|
539
|
+
* --stale` marks each open pull request's note posted against another
|
|
540
|
+
* commit stale and sets its plan status back to pending. It names the plan
|
|
541
|
+
* comment with `previewComment`. Undefined without `staleNotes`.
|
|
542
|
+
*/
|
|
543
|
+
export function prStaleJob(forge, env, options = {}, member) {
|
|
544
|
+
if (!options.staleNotes)
|
|
545
|
+
return undefined;
|
|
546
|
+
const words = resolveProductWords(options.words);
|
|
547
|
+
const command = [
|
|
548
|
+
"chant", "components", "pr-post", "--stale", "--tip", '"$TIP_SHA"', "--env", env, "--forge", forge,
|
|
549
|
+
...(options.branch ? ["--branch", JSON.stringify(options.branch)] : []),
|
|
550
|
+
...(member ? ["--member", member] : []),
|
|
551
|
+
...(options.previewComment ? ["--preview-comment"] : []),
|
|
552
|
+
].join(" ");
|
|
553
|
+
return {
|
|
554
|
+
command: withProductBin(command, words.bin),
|
|
555
|
+
env: forge === "gitlab" ? { TIP_SHA: "$CI_COMMIT_SHA" } : { TIP_SHA: "${{ github.sha }}", GITHUB_TOKEN: GITHUB_JOB_TOKEN },
|
|
419
556
|
};
|
|
420
557
|
}
|
|
421
558
|
/** The plan job's name in a GitLab merge request pipeline (#3465, #4328): `plan`, or `<member>-plan` in a workspace member's included file. */
|
|
@@ -603,8 +740,7 @@ export function gitlabBaseFallback(branch) {
|
|
|
603
740
|
export function githubBaseFallback(branch) {
|
|
604
741
|
return pushBaseFallback(JSON.stringify(branch ?? "main"), "$GITHUB_SHA");
|
|
605
742
|
}
|
|
606
|
-
|
|
607
|
-
export const PR_ENV_REPORT_DIR = ".chant/pr-env";
|
|
743
|
+
export { PR_ENV_REPORT_DIR } from "../ci-jobs.js";
|
|
608
744
|
/** The cron the generated `env-sweep` job runs on (#4298): hourly, at a minute off the hour. */
|
|
609
745
|
export const PR_ENV_SWEEP_CRON = "17 * * * *";
|
|
610
746
|
/** The name of the job that keeps an environment's record and posts its note (#4298, #4295). */
|
|
@@ -103,6 +103,12 @@ export interface PrPlanSetOptions {
|
|
|
103
103
|
seededOutputs?: Record<string, Record<string, unknown>>;
|
|
104
104
|
/** The addresses each component narrows to (#4300), by component: its steps' `DeployContext.targets`. */
|
|
105
105
|
targets?: Readonly<Record<string, readonly string[]>>;
|
|
106
|
+
/** How many members of a wave plan at once (#4625, `pr-plan --parallelism`); a group counts as one. Default: all of them. */
|
|
107
|
+
parallelism?: number;
|
|
108
|
+
/** `pr-plan --refresh` (#4627): every step's `DeployContext.refresh`. */
|
|
109
|
+
refresh?: boolean;
|
|
110
|
+
/** `pr-plan --target-dependents` (#4627): `DeployContext.targetDependents` for each component with targets. */
|
|
111
|
+
targetDependents?: boolean;
|
|
106
112
|
/** `ci.lockGrain` as declared at base (#4552); absent, each member takes its lexicon's default. */
|
|
107
113
|
lockGrain?: LockGrain;
|
|
108
114
|
/** The commit policy is read at (#4613), every step's `DeployContext.policyBase`: the pull request's base. */
|
|
@@ -158,6 +164,8 @@ export interface PrPlanSet {
|
|
|
158
164
|
groups?: PrPlanGroup[];
|
|
159
165
|
/** The components that could have grouped and did not, with why (ws-107, ruling 1): the fan-out's `fallbacks`. */
|
|
160
166
|
fallbacks?: FanOutGroupFallback[];
|
|
167
|
+
/** The addresses each component's plan was narrowed to (#4626, `pr-plan --target`), by component. Absent when nothing was narrowed. */
|
|
168
|
+
targets?: Record<string, string[]>;
|
|
161
169
|
/** Whether any component failed to plan. */
|
|
162
170
|
failed: boolean;
|
|
163
171
|
/** A capability's plan threw `policyDenied` (#4550): the stage exits 7, not 1. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pr-run.d.ts","sourceRoot":"","sources":["../../src/components/pr-run.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6EG;AAEH,OAAO,EAAmC,KAAK,SAAS,EAAE,KAAK,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC3G,OAAO,EAA2C,KAAK,iBAAiB,EAA2C,MAAM,eAAe,CAAC;AACzI,OAAO,EAAgB,KAAK,SAAS,EAAE,KAAK,cAAc,EAAE,MAAM,YAAY,CAAC;AAC/E,OAAO,EAML,KAAK,UAAU,EAEf,KAAK,QAAQ,EAEb,KAAK,SAAS,EACd,KAAK,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