@intentius/chant 0.124.44 → 0.124.45

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.
Files changed (72) hide show
  1. package/dist/ci-identity.d.ts +183 -12
  2. package/dist/ci-identity.d.ts.map +1 -1
  3. package/dist/ci-identity.js +362 -53
  4. package/dist/cli/handlers/build.d.ts.map +1 -1
  5. package/dist/cli/handlers/build.js +17 -1
  6. package/dist/cli/handlers/pr-env.d.ts +8 -2
  7. package/dist/cli/handlers/pr-env.d.ts.map +1 -1
  8. package/dist/cli/handlers/pr-env.js +126 -225
  9. package/dist/cli/handlers/pr.d.ts +3 -0
  10. package/dist/cli/handlers/pr.d.ts.map +1 -1
  11. package/dist/cli/handlers/pr.js +1 -0
  12. package/dist/components/cli-support.d.ts +2 -0
  13. package/dist/components/cli-support.d.ts.map +1 -1
  14. package/dist/components/cli-support.js +4 -2
  15. package/dist/components/fan-out-support.d.ts +3 -0
  16. package/dist/components/fan-out-support.d.ts.map +1 -1
  17. package/dist/components/fan-out-support.js +1 -1
  18. package/dist/components/pr-env-run.d.ts +270 -0
  19. package/dist/components/pr-env-run.d.ts.map +1 -0
  20. package/dist/components/pr-env-run.js +440 -0
  21. package/dist/components/pr-environment.d.ts +89 -14
  22. package/dist/components/pr-environment.d.ts.map +1 -1
  23. package/dist/components/pr-environment.js +94 -8
  24. package/dist/components/pr-pipeline.d.ts +10 -1
  25. package/dist/components/pr-pipeline.d.ts.map +1 -1
  26. package/dist/op/op-waves.d.ts +17 -0
  27. package/dist/op/op-waves.d.ts.map +1 -1
  28. package/dist/op/op-waves.js +23 -1
  29. package/dist/pr-forge.d.ts +15 -1
  30. package/dist/pr-forge.d.ts.map +1 -1
  31. package/dist/pr-forge.js +28 -16
  32. package/dist/pr-requires.d.ts +5 -1
  33. package/dist/pr-requires.d.ts.map +1 -1
  34. package/dist/wave-runtime.mjs +179 -179
  35. package/dist/workspace/ci-cloud-identity.d.ts +3 -1
  36. package/dist/workspace/ci-cloud-identity.d.ts.map +1 -1
  37. package/dist/workspace/ci-cloud-identity.js +16 -1
  38. package/dist/workspace/ci-run.d.ts +35 -8
  39. package/dist/workspace/ci-run.d.ts.map +1 -1
  40. package/dist/workspace/ci-run.js +95 -21
  41. package/dist/workspace/ci-secrets.d.ts.map +1 -1
  42. package/dist/workspace/ci-secrets.js +4 -3
  43. package/dist/workspace/declaration.d.ts +10 -0
  44. package/dist/workspace/declaration.d.ts.map +1 -1
  45. package/dist/workspace/declaration.js +17 -1
  46. package/dist/workspace/declaration.schema.json +36 -1
  47. package/package.json +1 -1
  48. package/src/ci-identity-targets.test.ts +275 -0
  49. package/src/ci-identity.ts +394 -61
  50. package/src/cli/handlers/build.ts +15 -1
  51. package/src/cli/handlers/pr-env.ts +136 -227
  52. package/src/cli/handlers/pr.ts +4 -0
  53. package/src/components/cli-support.ts +6 -1
  54. package/src/components/fan-out-support.ts +4 -1
  55. package/src/components/pr-env-run.test.ts +290 -0
  56. package/src/components/pr-env-run.ts +634 -0
  57. package/src/components/pr-environment.ts +159 -12
  58. package/src/components/pr-pipeline.ts +10 -1
  59. package/src/op/op-waves.ts +38 -1
  60. package/src/pr-forge-bundle.test.ts +1 -1
  61. package/src/pr-forge.ts +44 -17
  62. package/src/pr-requires.test.ts +43 -6
  63. package/src/pr-requires.ts +5 -1
  64. package/src/workspace/ci-cloud-identity.test.ts +20 -0
  65. package/src/workspace/ci-cloud-identity.ts +14 -1
  66. package/src/workspace/ci-run.test.ts +74 -1
  67. package/src/workspace/ci-run.ts +122 -29
  68. package/src/workspace/ci-secrets.test.ts +1 -1
  69. package/src/workspace/ci-secrets.ts +4 -3
  70. package/src/workspace/declaration.schema.json +36 -1
  71. package/src/workspace/declaration.test.ts +7 -0
  72. package/src/workspace/declaration.ts +24 -2
@@ -0,0 +1,270 @@
1
+ /**
2
+ * Running a pull request's environment (#4330): `up`, `down` and `sweep` as
3
+ * functions over an adapter, so a product that plans and applies with a tool
4
+ * chant does not run (terragucci, with Terraform roots under suffixed state
5
+ * keys) keeps its own plan, apply and teardown and takes the rest from chant:
6
+ *
7
+ * - the gate: a non-empty plan applies only once a person's approval of its
8
+ * digest stands under gate `pr-env` (ws-080, ws-104), and an empty one
9
+ * applies at once;
10
+ * - the records on chant/lifecycle (`_pr-envs/records.jsonl`), the TTL and
11
+ * which environments stand ({@link livePrEnvironments});
12
+ * - the ownership check on teardown ({@link teardownRefusal}), and the
13
+ * marker check on every candidate before anything is deleted
14
+ * ({@link tearDownPrEnvironment});
15
+ * - the sweep over expired and closed pull requests;
16
+ * - the report and the note ({@link renderPrEnvNote}).
17
+ *
18
+ * `chant components pr-env` (../cli/handlers/pr-env.ts) runs these with the
19
+ * components adapter and the lexicons' teardown. The ports default to
20
+ * chant/lifecycle in the working directory and the gate ledger there
21
+ * ({@link lifecyclePrEnvPorts}).
22
+ */
23
+ import type { ChantConfig } from "../config.js";
24
+ import type { TeardownCandidate, TeardownHole, TeardownOutcome } from "../lexicon.js";
25
+ import type { ObservationLexicon } from "../lexicon.js";
26
+ import type { PrForge } from "../pr-forge.js";
27
+ import { type LivePrEnvironment, type PrEnvRecord, type PrEnvReport, type PrEnvReportRow, type PrEnvTeardownAdapter } from "./pr-environment.js";
28
+ /** The environment one run works on. */
29
+ export interface PrEnvTarget {
30
+ pr: number;
31
+ /** `pr-<n>`. */
32
+ env: string;
33
+ template: string;
34
+ /** The marker every resource of the environment carries. */
35
+ marker: {
36
+ stack: string;
37
+ env: string;
38
+ };
39
+ /** The commit planned and applied: the pull request's head. */
40
+ head: string;
41
+ member?: string;
42
+ /** The op the gate is recorded under: `pr-<n>`, or `pr-<n>-<member>`. */
43
+ op: string;
44
+ endpoint?: string;
45
+ }
46
+ /** What an adapter's plan came to. */
47
+ export interface PrEnvPlanned {
48
+ /** The digest an approval binds. */
49
+ digest: string;
50
+ /** Nothing changes: the plan applies with no approval (ws-104). */
51
+ empty: boolean;
52
+ /** Something failed to plan, or a hook stopped it: nothing applies. */
53
+ failed?: boolean;
54
+ /** One row per component (a Terraform root, a chant component), in apply order. None: the change reaches nothing deployed, and the environment gets nothing. */
55
+ rows: PrEnvReportRow[];
56
+ message?: string;
57
+ }
58
+ /** What an adapter's apply came to. */
59
+ export interface PrEnvApplied {
60
+ /**
61
+ * `waiting`: a component read an upstream output that moved, so it waits
62
+ * for the next run. `stopped`: nothing was applied (a before-apply hook
63
+ * failed), so no record is kept.
64
+ */
65
+ status: "applied" | "failed" | "waiting" | "stopped";
66
+ /** The rows again, with each component's status after the apply. */
67
+ rows: PrEnvReportRow[];
68
+ /** Where each component's copy lives, kept on the record for the teardown (a suffixed state key). */
69
+ locations?: Record<string, string>;
70
+ message?: string;
71
+ /** The apply stands, and something after it failed (an after-apply hook): the record says applied and the run exits 1. */
72
+ afterFailure?: string;
73
+ }
74
+ /** What `up` hands an adapter's apply: the plan, and who approved it. */
75
+ export interface PrEnvApplyInput {
76
+ planned: PrEnvPlanned;
77
+ /** Who approved the digest; absent for an empty plan. */
78
+ approvedBy?: string[];
79
+ }
80
+ /**
81
+ * The plan and apply of a pull request's environment, which a product
82
+ * supplies. `plan` must not change anything; `apply` applies exactly what
83
+ * `plan` answered, once `up` decided it may.
84
+ */
85
+ export interface PrEnvAdapter {
86
+ plan(target: PrEnvTarget): Promise<PrEnvPlanned>;
87
+ apply(target: PrEnvTarget, input: PrEnvApplyInput): Promise<PrEnvApplied>;
88
+ }
89
+ /** Where the approval of a digest stands, as `decideGate` answers. */
90
+ export interface PrEnvApproval {
91
+ status: "approved" | "changed" | "pending";
92
+ approvedBy?: string[];
93
+ }
94
+ /** What the runs read and write, which tests and products replace. */
95
+ export interface PrEnvPorts {
96
+ /** Every record, oldest first. */
97
+ readRecords(): Promise<PrEnvRecord[]>;
98
+ /** Keep one record. A failure should warn: what was applied or torn down stands. */
99
+ appendRecord(record: PrEnvRecord): Promise<void>;
100
+ /** Where the approval of `digest` stands under `gate` of `op`. Throws when the ledger cannot be read. */
101
+ decideGate(input: {
102
+ op: string;
103
+ gate: string;
104
+ digest: string;
105
+ description: string;
106
+ }): Promise<PrEnvApproval>;
107
+ /** Post the report: the note and the commit status. Absent: nothing is posted. */
108
+ publish?(report: PrEnvReport): Promise<void>;
109
+ /** Whether a pull request is still open, for the sweep. Absent: only the TTL counts. */
110
+ pullRequestState?(pr: number): Promise<"open" | "closed" | "merged">;
111
+ log?(line: string): void;
112
+ warn?(message: string): void;
113
+ }
114
+ /** What one run came to. */
115
+ export interface PrEnvRunResult {
116
+ /** {@link PR_ENV_EXIT}: 0 done, 1 failed or refused, 3 waiting on an approval. */
117
+ exit: number;
118
+ report: PrEnvReport;
119
+ /** The record kept, when the run kept one. */
120
+ record?: PrEnvRecord;
121
+ }
122
+ /** The op a pull request's gate is recorded under, as `prOp` in ../pr-loop.ts names it. */
123
+ export declare function prEnvOp(pr: number, member?: string): string;
124
+ /** The approve command an adapter's caller prints, the same the note shows. */
125
+ export { prEnvApproveCommand } from "./pr-environment.js";
126
+ export interface PrEnvUpInput {
127
+ pr: number;
128
+ /** The pull request's head, which is planned and applied. */
129
+ head: string;
130
+ /** `ci.prEnvironment.template`, read at base. */
131
+ template: string;
132
+ /** `ci.prEnvironment.ttl`, read at base: `72h`, `90m`, `7d`. Default 72h. */
133
+ ttl?: string;
134
+ /** The ownership stack every resource's marker names. */
135
+ stack: string;
136
+ member?: string;
137
+ endpoint?: string;
138
+ adapter: PrEnvAdapter;
139
+ ports: PrEnvPorts;
140
+ /** Who the record names. Default `chant`. */
141
+ actor?: string;
142
+ runUrl?: string;
143
+ now?: () => Date;
144
+ }
145
+ /**
146
+ * Plan pull request `pr`'s environment through the adapter and apply it once
147
+ * the plan is empty or an approval of its digest stands under gate `pr-env`.
148
+ * An apply that failed part way is kept as live too, so what applied is torn
149
+ * down with the rest.
150
+ */
151
+ export declare function prEnvUp(input: PrEnvUpInput): Promise<PrEnvRunResult>;
152
+ /** What tears an environment down: the lexicons, and the adapters a product supplies. */
153
+ export interface PrEnvTeardownSources {
154
+ /** The project's config, for its declared environments and stacks. */
155
+ config?: ChantConfig;
156
+ plugins?: ObservationLexicon[];
157
+ adapters?: PrEnvTeardownAdapter[];
158
+ }
159
+ export interface PrEnvDownInput extends PrEnvTeardownSources {
160
+ pr: number;
161
+ reason: "closed" | "expired";
162
+ member?: string;
163
+ ports: PrEnvPorts;
164
+ /** The environment as the records say it stands. Default: read through `ports`. */
165
+ live?: LivePrEnvironment;
166
+ /** The commit the teardown runs at, for the record. */
167
+ commit: string;
168
+ actor?: string;
169
+ runUrl?: string;
170
+ now?: () => Date;
171
+ }
172
+ /**
173
+ * Tear down pull request `pr`'s environment: the ownership check first, then
174
+ * only what carries `{ stack, env: "pr-<n>" }`, through the lexicons and the
175
+ * adapters. No gate holds it: closing the pull request, or the TTL the base
176
+ * set, is the decision. A teardown that left something keeps the
177
+ * environment live for the next sweep.
178
+ */
179
+ export declare function prEnvDown(input: PrEnvDownInput): Promise<PrEnvRunResult>;
180
+ export interface PrEnvSweepInput extends PrEnvTeardownSources {
181
+ ports: PrEnvPorts;
182
+ /** Only this member's environments. Default: every environment the records name. */
183
+ member?: string;
184
+ commit: string;
185
+ actor?: string;
186
+ runUrl?: string;
187
+ now?: () => Date;
188
+ }
189
+ /**
190
+ * Tear down each live environment whose TTL passed, or whose pull request
191
+ * the forge says is closed or merged. A state that cannot be read leaves the
192
+ * TTL to decide. Exits 1 when any teardown did not finish.
193
+ */
194
+ export declare function prEnvSweep(input: PrEnvSweepInput): Promise<{
195
+ exit: number;
196
+ results: PrEnvRunResult[];
197
+ }>;
198
+ /**
199
+ * The note and the `chant/pr-env` status on the forge. A refusal from the
200
+ * forge warns and never fails the run.
201
+ */
202
+ export declare function forgePrEnvPublisher(forge: PrForge, warn?: (message: string) => void): (report: PrEnvReport) => Promise<void>;
203
+ /**
204
+ * The ports over chant/lifecycle in `cwd` (default the working directory):
205
+ * the records at `_pr-envs/records.jsonl`, appended and pushed, and the gate
206
+ * ledger read without writing a pending fact. With `forge`, the note and
207
+ * status are posted and the sweep asks it whether a pull request is open.
208
+ */
209
+ export declare function lifecyclePrEnvPorts(opts?: {
210
+ cwd?: string;
211
+ forge?: PrForge;
212
+ log?: (line: string) => void;
213
+ warn?: (message: string) => void;
214
+ }): PrEnvPorts;
215
+ /** `ci.prEnvironment.teardown` (#4330): a command that tears down what no lexicon does. */
216
+ export interface PrEnvTeardownCommand {
217
+ /** The name its outcomes are attributed to. Default `teardown`. */
218
+ name?: string;
219
+ /** Argv. `{env}`, `{pr}` and `{stage}` are filled in. */
220
+ command: string[];
221
+ /** The lexicons it tears down in place of, as {@link PrEnvTeardownAdapter.lexicons}. */
222
+ lexicons?: string[];
223
+ }
224
+ /** The variables a teardown command reads. */
225
+ export declare const PR_ENV_TEARDOWN_ENV: {
226
+ /** `owned` or `teardown`. */
227
+ readonly stage: "CHANT_PR_ENV_STAGE";
228
+ /** `pr-<n>`. */
229
+ readonly env: "CHANT_PR_ENV";
230
+ readonly pr: "CHANT_PR_NUMBER";
231
+ readonly stack: "CHANT_PR_ENV_STACK";
232
+ readonly template: "CHANT_PR_ENV_TEMPLATE";
233
+ /** The commit last applied to the environment. */
234
+ readonly commit: "CHANT_PR_ENV_COMMIT";
235
+ /** A JSON file: `{ components, locations }` from the records. */
236
+ readonly live: "CHANT_PR_ENV_LIVE";
237
+ /** `teardown` only: a JSON file holding the candidates to delete. */
238
+ readonly candidates: "CHANT_PR_ENV_CANDIDATES";
239
+ /** The JSON file the command writes its answer to. */
240
+ readonly result: "CHANT_PR_ENV_RESULT";
241
+ };
242
+ /** Runs one argv in `cwd` with `env` as its whole environment; returns its exit code. Injected so tests run no processes. */
243
+ export type PrEnvTeardownExec = (argv: string[], cwd: string, env: Record<string, string>) => number;
244
+ /** The candidates and holes a teardown command wrote, checked as data. Throws when they do not read. */
245
+ export declare function readTeardownEnumeration(raw: unknown): {
246
+ candidates: TeardownCandidate[];
247
+ holes: TeardownHole[];
248
+ };
249
+ /** The outcomes a teardown command wrote, checked as data. A candidate it leaves out counts as failed in core. */
250
+ export declare function readTeardownOutcomes(raw: unknown): TeardownOutcome[];
251
+ /**
252
+ * `ci.prEnvironment.teardown` as an adapter (#4330). chant runs the command
253
+ * twice, in `cwd`, with the job's environment less every forge token
254
+ * variable, and these besides ({@link PR_ENV_TEARDOWN_ENV}):
255
+ *
256
+ * - `CHANT_PR_ENV_STAGE=owned`: the command writes `{ candidates, holes }`
257
+ * to `CHANT_PR_ENV_RESULT`, each candidate with the marker it read back.
258
+ * - `CHANT_PR_ENV_STAGE=teardown`: it deletes the candidates in
259
+ * `CHANT_PR_ENV_CANDIDATES`, which chant has checked against the marker,
260
+ * and writes `{ outcomes }` to `CHANT_PR_ENV_RESULT`.
261
+ *
262
+ * A non-zero exit, or an answer that does not read, is a hole (`owned`) or a
263
+ * failure for every candidate (`teardown`), so the environment stays live.
264
+ */
265
+ export declare function commandTeardownAdapter(hook: PrEnvTeardownCommand, opts: {
266
+ cwd: string;
267
+ env?: Record<string, string | undefined>;
268
+ exec?: PrEnvTeardownExec;
269
+ }): PrEnvTeardownAdapter;
270
+ //# sourceMappingURL=pr-env-run.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pr-env-run.d.ts","sourceRoot":"","sources":["../../src/components/pr-env-run.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAOH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,KAAK,EAAE,iBAAiB,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AACnF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AACrD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAC3C,OAAO,EAkBL,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,cAAc,EACnB,KAAK,oBAAoB,EAE1B,MAAM,kBAAkB,CAAC;AAE1B,wCAAwC;AACxC,M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