@prisma/composer 0.39.0-dev.6 → 0.39.0-dev.8
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/{app-config-Ubi4CftJ-DUSDjI2i.d.mts → app-config-DriAu5RU-C8hYpR38.d.mts} +17 -15
- package/dist/app-config-DriAu5RU-C8hYpR38.d.mts.map +1 -0
- package/dist/{app-configuration-file-Bbfq5PR3-D4DUNKUM.mjs → app-configuration-file-D0rB5g65-CdMrjkCc.mjs} +10 -40
- package/dist/app-configuration-file-D0rB5g65-CdMrjkCc.mjs.map +1 -0
- package/dist/app-converge-CVlo9uw2-B-fdr0nr.mjs +88 -0
- package/dist/app-converge-CVlo9uw2-B-fdr0nr.mjs.map +1 -0
- package/dist/arktype.d.mts +7 -5
- package/dist/arktype.d.mts.map +1 -1
- package/dist/arktype.mjs +7 -5
- package/dist/arktype.mjs.map +1 -1
- package/dist/config-Bpi8QVLB.d.mts +1 -0
- package/dist/config.d.mts +2 -2
- package/dist/config.mjs +1 -1
- package/dist/control.d.mts +8 -23
- package/dist/control.d.mts.map +1 -1
- package/dist/control.mjs +4 -4
- package/dist/control.mjs.map +1 -1
- package/dist/{converge-in-process-BBBeood8-C7VG5b35.d.mts → converge-in-process-CTomEXaD-BnDylZP8.d.mts} +5 -5
- package/dist/{converge-in-process-BBBeood8-C7VG5b35.d.mts.map → converge-in-process-CTomEXaD-BnDylZP8.d.mts.map} +1 -1
- package/dist/converge-in-process-x89zb2MF-Dvj-J8xo.mjs +258 -0
- package/dist/converge-in-process-x89zb2MF-Dvj-J8xo.mjs.map +1 -0
- package/dist/{deploy-NArSOken.mjs → deploy-CSU0kr4j.mjs} +65 -5
- package/dist/{deploy-NArSOken.mjs.map → deploy-CSU0kr4j.mjs.map} +1 -1
- package/dist/deploy-DHgEJDpg.d.mts +32 -0
- package/dist/deploy-DHgEJDpg.d.mts.map +1 -0
- package/dist/deploy.d.mts +4 -4
- package/dist/deploy.mjs +3 -3
- package/dist/{deployment-summary-6LgQDUuu-DtCvw9UQ.d.mts → deployment-summary-6LgQDUuu-Cu_6UNhc.d.mts} +4 -4
- package/dist/{deployment-summary-6LgQDUuu-DtCvw9UQ.d.mts.map → deployment-summary-6LgQDUuu-Cu_6UNhc.d.mts.map} +1 -1
- package/dist/{deployment-summary-YP7eMPJI-CQsj7BHh.mjs → deployment-summary-CVJZn2v0-Dz-gX1rp.mjs} +3 -3
- package/dist/{deployment-summary-YP7eMPJI-CQsj7BHh.mjs.map → deployment-summary-CVJZn2v0-Dz-gX1rp.mjs.map} +1 -1
- package/dist/{describe-kind-Cpm_euxo-D9WDxl5C.mjs → describe-kind-Cpm_euxo-DsSPENQa.mjs} +3 -3
- package/dist/describe-kind-Cpm_euxo-DsSPENQa.mjs.map +1 -0
- package/dist/dev-converge-messages-DML4rTz7-C_EAB5M_.mjs +165 -0
- package/dist/dev-converge-messages-DML4rTz7-C_EAB5M_.mjs.map +1 -0
- package/dist/dev-converge-worker.d.mts +1 -0
- package/dist/dev-converge-worker.mjs +142 -0
- package/dist/dev-converge-worker.mjs.map +1 -0
- package/dist/{dev-current-BT66YKUB-CFI8HmP7.mjs → dev-current-ByY2RrbK-DbU6y3PF.mjs} +11 -7
- package/dist/dev-current-ByY2RrbK-DbU6y3PF.mjs.map +1 -0
- package/dist/{dev-environment-name-6eEr5PW8-6sPgQZG3.mjs → dev-environment-name-6eEr5PW8-7ntm9Xhs.mjs} +3 -3
- package/dist/{dev-environment-name-6eEr5PW8-6sPgQZG3.mjs.map → dev-environment-name-6eEr5PW8-7ntm9Xhs.mjs.map} +1 -1
- package/dist/{dist-BxtsHOfP.mjs → dist-Cf_mZHaH.mjs} +2 -2
- package/dist/{dist-BxtsHOfP.mjs.map → dist-Cf_mZHaH.mjs.map} +1 -1
- package/dist/{emulator-retry-CV8rl69G-BgUzkxc-.mjs → emulator-retry-CV8rl69G-scQ105wk.mjs} +2 -2
- package/dist/{emulator-retry-CV8rl69G-BgUzkxc-.mjs.map → emulator-retry-CV8rl69G-scQ105wk.mjs.map} +1 -1
- package/dist/{errors-0e8IVwzi.mjs → errors-DI3TBXE-.mjs} +7 -2
- package/dist/{errors-0e8IVwzi.mjs.map → errors-DI3TBXE-.mjs.map} +1 -1
- package/dist/{execute-deploy-destroy-C67FX_2B-DIKGa3gS.mjs → execute-deploy-destroy-D1jnaYqU-RAlTx-NX.mjs} +246 -193
- package/dist/execute-deploy-destroy-D1jnaYqU-RAlTx-NX.mjs.map +1 -0
- package/dist/{execute-dev-CVjdm1y1-DyFJDp6x.mjs → execute-dev-BP0Shlpd-BNFvs2LF.mjs} +434 -261
- package/dist/execute-dev-BP0Shlpd-BNFvs2LF.mjs.map +1 -0
- package/dist/{execute-dev-current-D5ANAZnU-CJQEjEnc.mjs → execute-dev-current-B792f_1m-BYJ-Rl8m.mjs} +7 -7
- package/dist/{execute-dev-current-D5ANAZnU-CJQEjEnc.mjs.map → execute-dev-current-B792f_1m-BYJ-Rl8m.mjs.map} +1 -1
- package/dist/{execute-log-BpiGoJwe-DYQw_hSp.mjs → execute-log-BiRHQq6Q-BkQk0Kvo.mjs} +8 -8
- package/dist/{execute-log-BpiGoJwe-DYQw_hSp.mjs.map → execute-log-BiRHQq6Q-BkQk0Kvo.mjs.map} +1 -1
- package/dist/{graph-DU0omY5O-BHO71z0F.d.mts → graph-CUYXjK8S-BzL-mhjq.d.mts} +3 -3
- package/dist/graph-CUYXjK8S-BzL-mhjq.d.mts.map +1 -0
- package/dist/{graph-C6Fqe2gn-DMa2udEA.mjs → graph-D2WMLL43-CeiC5wdy.mjs} +19 -10
- package/dist/graph-D2WMLL43-CeiC5wdy.mjs.map +1 -0
- package/dist/{graph-types-Bzj1fahC-C8rOVj0c.d.mts → graph-types-D4PrtP-l-B0uuchTl.d.mts} +15 -13
- package/dist/{graph-types-Bzj1fahC-C8rOVj0c.d.mts.map → graph-types-D4PrtP-l-B0uuchTl.d.mts.map} +1 -1
- package/dist/http.d.mts +2 -2
- package/dist/http.mjs +2 -2
- package/dist/{index-B8s0bLZY.d.mts → index-D8chHe55.d.mts} +3 -3
- package/dist/{index-B8s0bLZY.d.mts.map → index-D8chHe55.d.mts.map} +1 -1
- package/dist/index.d.mts +5 -5
- package/dist/index.mjs +3 -3
- package/dist/internal-app-configuration-file.d.mts +5 -9
- package/dist/internal-app-configuration-file.d.mts.map +1 -1
- package/dist/internal-app-configuration-file.mjs +2 -2
- package/dist/internal-converge-contract.d.mts +6 -4
- package/dist/internal-converge-contract.d.mts.map +1 -1
- package/dist/internal-converge-contract.mjs +7 -5
- package/dist/internal-converge-contract.mjs.map +1 -1
- package/dist/internal-converge.d.mts +5 -4
- package/dist/internal-converge.mjs +4 -228
- package/dist/load-entry-CEoVBdMj-CHOz7jKf.mjs +527 -0
- package/dist/load-entry-CEoVBdMj-CHOz7jKf.mjs.map +1 -0
- package/dist/local-target-7KRsLMDO.d.mts +31 -0
- package/dist/local-target-7KRsLMDO.d.mts.map +1 -0
- package/dist/{local-target-COdS1iNs.mjs → local-target-DhU1vaxd.mjs} +6 -6
- package/dist/{local-target-COdS1iNs.mjs.map → local-target-DhU1vaxd.mjs.map} +1 -1
- package/dist/local-target.d.mts +3 -31
- package/dist/local-target.mjs +1 -1
- package/dist/{nextjs-DLyeRR7M-Z_xX74Cp.d.mts → nextjs-DLyeRR7M-CzUbvPaJ.d.mts} +3 -3
- package/dist/{nextjs-DLyeRR7M-Z_xX74Cp.d.mts.map → nextjs-DLyeRR7M-CzUbvPaJ.d.mts.map} +1 -1
- package/dist/nextjs-control.d.mts +4 -4
- package/dist/nextjs.d.mts +1 -1
- package/dist/node-control.d.mts +3 -3
- package/dist/node.d.mts +2 -2
- package/dist/{pointer-DclJZFQi-DJa4t8Wa.d.mts → pointer-BX2KJ720-BxcfpaHP.d.mts} +7 -5
- package/dist/{pointer-DclJZFQi-DJa4t8Wa.d.mts.map → pointer-BX2KJ720-BxcfpaHP.d.mts.map} +1 -1
- package/dist/{preflight-transport-C7_3abXW-Bza_hn9G.mjs → preflight-transport-2d6iIchu-B-v7Di6I.mjs} +5 -4
- package/dist/preflight-transport-2d6iIchu-B-v7Di6I.mjs.map +1 -0
- package/dist/{redaction-CjMYXtGp-CEQ5z1PK.mjs → redaction-DY6eDC12-W-FzW7_r.mjs} +16 -4
- package/dist/{redaction-CjMYXtGp-CEQ5z1PK.mjs.map → redaction-DY6eDC12-W-FzW7_r.mjs.map} +1 -1
- package/dist/{redaction-CIaE4m9U-DJGrkcn3.d.mts → redaction-Dn7BRdaP-BcLSPhLV.d.mts} +58 -17
- package/dist/redaction-Dn7BRdaP-BcLSPhLV.d.mts.map +1 -0
- package/dist/report.d.mts +3 -3
- package/dist/report.mjs +2 -2
- package/dist/report.mjs.map +1 -1
- package/dist/service-rpc.d.mts +2 -2
- package/dist/service-rpc.mjs +2 -2
- package/dist/steps-BZXNqW6U-C_ME2VLd.mjs +112 -0
- package/dist/steps-BZXNqW6U-C_ME2VLd.mjs.map +1 -0
- package/dist/testing.d.mts +1 -1
- package/dist/validate-environment-DCZiNSlR-C7lv0cH1.mjs +344 -0
- package/dist/validate-environment-DCZiNSlR-C7lv0cH1.mjs.map +1 -0
- package/dist/zod.d.mts +6 -5
- package/dist/zod.d.mts.map +1 -1
- package/dist/zod.mjs +6 -5
- package/dist/zod.mjs.map +1 -1
- package/package.json +11 -11
- package/skills/prisma-composer-core-concepts/SKILL.md +13 -10
- package/src/exports/dev-converge-worker.ts +2 -0
- package/dist/app-config-Ubi4CftJ-DUSDjI2i.d.mts.map +0 -1
- package/dist/app-configuration-file-Bbfq5PR3-D4DUNKUM.mjs.map +0 -1
- package/dist/config-BmRE_eTa.d.mts +0 -1
- package/dist/deploy-BW_F4Y9W.d.mts +0 -12
- package/dist/deploy-BW_F4Y9W.d.mts.map +0 -1
- package/dist/describe-kind-Cpm_euxo-D9WDxl5C.mjs.map +0 -1
- package/dist/dev-current-BT66YKUB-CFI8HmP7.mjs.map +0 -1
- package/dist/execute-deploy-destroy-C67FX_2B-DIKGa3gS.mjs.map +0 -1
- package/dist/execute-dev-CVjdm1y1-DyFJDp6x.mjs.map +0 -1
- package/dist/graph-C6Fqe2gn-DMa2udEA.mjs.map +0 -1
- package/dist/graph-DU0omY5O-BHO71z0F.d.mts.map +0 -1
- package/dist/internal-converge.mjs.map +0 -1
- package/dist/local-target.d.mts.map +0 -1
- package/dist/preflight-transport-C7_3abXW-Bza_hn9G.mjs.map +0 -1
- package/dist/redaction-CIaE4m9U-DJGrkcn3.d.mts.map +0 -1
- package/dist/run-alchemy-BlYyc4Oh-mIzYC4lq.mjs +0 -236
- package/dist/run-alchemy-BlYyc4Oh-mIzYC4lq.mjs.map +0 -1
- package/dist/validate-environment-XwVDifWN-BhPOzWN8.mjs +0 -739
- package/dist/validate-environment-XwVDifWN-BhPOzWN8.mjs.map +0 -1
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { n as StreamRedactor } from "./redaction-DY6eDC12-W-FzW7_r.mjs";
|
|
2
|
+
import { s as withComposerAdvice } from "./deployment-summary-CVJZn2v0-Dz-gX1rp.mjs";
|
|
3
|
+
//#region ../../0-framework/3-tooling/cli/dist/steps-BZXNqW6U.mjs
|
|
4
|
+
/**
|
|
5
|
+
* Times each step for the host's `onEvent`. Steps are matched by `keyOf`, so
|
|
6
|
+
* a step can finish under a newer status than it started with. `emit` sends
|
|
7
|
+
* the operation's other events. A host `onEvent` that throws is the host's
|
|
8
|
+
* bug and cannot fail the operation.
|
|
9
|
+
*/
|
|
10
|
+
function stepTracker(keyOf, onEvent) {
|
|
11
|
+
const open = /* @__PURE__ */ new Map();
|
|
12
|
+
const emit = (event) => {
|
|
13
|
+
try {
|
|
14
|
+
onEvent?.(event);
|
|
15
|
+
} catch {}
|
|
16
|
+
};
|
|
17
|
+
const finish = (step, outcome, data) => {
|
|
18
|
+
const entry = open.get(keyOf(step));
|
|
19
|
+
if (entry === void 0) return;
|
|
20
|
+
open.delete(keyOf(step));
|
|
21
|
+
const durationMs = Math.round(performance.now() - entry.startedAt);
|
|
22
|
+
emit({
|
|
23
|
+
kind: "step-finished",
|
|
24
|
+
step,
|
|
25
|
+
outcome,
|
|
26
|
+
durationMs,
|
|
27
|
+
data
|
|
28
|
+
});
|
|
29
|
+
};
|
|
30
|
+
return {
|
|
31
|
+
start(step) {
|
|
32
|
+
open.set(keyOf(step), {
|
|
33
|
+
step,
|
|
34
|
+
startedAt: performance.now()
|
|
35
|
+
});
|
|
36
|
+
emit({
|
|
37
|
+
kind: "step-started",
|
|
38
|
+
step
|
|
39
|
+
});
|
|
40
|
+
},
|
|
41
|
+
finish(step, data) {
|
|
42
|
+
finish(step, "ok", data);
|
|
43
|
+
},
|
|
44
|
+
fail(step) {
|
|
45
|
+
finish(step, "failed");
|
|
46
|
+
},
|
|
47
|
+
/** Closes every open step with `outcome`, innermost first. */
|
|
48
|
+
closeOpen(outcome) {
|
|
49
|
+
for (const { step } of [...open.values()].reverse()) finish(step, outcome);
|
|
50
|
+
},
|
|
51
|
+
isOpen(step) {
|
|
52
|
+
return open.has(keyOf(step));
|
|
53
|
+
},
|
|
54
|
+
message(severity, text) {
|
|
55
|
+
emit({
|
|
56
|
+
kind: "message",
|
|
57
|
+
severity,
|
|
58
|
+
text
|
|
59
|
+
});
|
|
60
|
+
},
|
|
61
|
+
emit
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
/** One converge event as step events: each resource is a step, made by `resourceStep`; a log line is a message. */
|
|
65
|
+
function reportConvergeEvent(steps, event, redact, resourceStep) {
|
|
66
|
+
if (event.kind === "log") {
|
|
67
|
+
steps.message(event.severity, redact(withComposerAdvice(event.text)));
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
const step = resourceStep({
|
|
71
|
+
resourceId: event.fqn,
|
|
72
|
+
resourceType: event.resourceType,
|
|
73
|
+
status: event.status
|
|
74
|
+
});
|
|
75
|
+
switch (event.phase) {
|
|
76
|
+
case "running":
|
|
77
|
+
if (!steps.isOpen(step)) steps.start(step);
|
|
78
|
+
return;
|
|
79
|
+
case "done":
|
|
80
|
+
if (!steps.isOpen(step)) steps.start(step);
|
|
81
|
+
steps.finish(step);
|
|
82
|
+
return;
|
|
83
|
+
case "failed":
|
|
84
|
+
if (!steps.isOpen(step)) steps.start(step);
|
|
85
|
+
steps.fail(step);
|
|
86
|
+
if (event.message !== void 0) steps.message("warn", redact(`${event.fqn}: ${withComposerAdvice(event.message)}`));
|
|
87
|
+
return;
|
|
88
|
+
case "pending": return;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Alchemy's terminal text as `info` messages, one per complete line, redacted. A secret split
|
|
93
|
+
* across writes or lines is still found, because the text passes through a `StreamRedactor`
|
|
94
|
+
* before it is cut into lines. `end` sends the last line that has no line break.
|
|
95
|
+
*/
|
|
96
|
+
function interactionMessages(steps, redaction) {
|
|
97
|
+
const stream = new StreamRedactor(redaction.allValues());
|
|
98
|
+
let partial = "";
|
|
99
|
+
const send = (text, last) => {
|
|
100
|
+
const lines = (partial + text).split("\n");
|
|
101
|
+
partial = last ? "" : lines.pop() ?? "";
|
|
102
|
+
for (const line of lines) if (line.trim() !== "") steps.message("info", redaction.redact(line));
|
|
103
|
+
};
|
|
104
|
+
return {
|
|
105
|
+
push: (text) => send(stream.push(text), false),
|
|
106
|
+
end: () => send(stream.end(), true)
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
//#endregion
|
|
110
|
+
export { reportConvergeEvent as n, stepTracker as r, interactionMessages as t };
|
|
111
|
+
|
|
112
|
+
//# sourceMappingURL=steps-BZXNqW6U-C_ME2VLd.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"steps-BZXNqW6U-C_ME2VLd.mjs","names":[],"sources":["../../../0-framework/3-tooling/cli/dist/steps-BZXNqW6U.mjs"],"sourcesContent":["import { n as StreamRedactor } from \"./redaction-DY6eDC12.mjs\";\nimport { s as withComposerAdvice } from \"./deployment-summary-CVJZn2v0.mjs\";\n//#region src/operations/steps.ts\n/**\n* Times each step for the host's `onEvent`. Steps are matched by `keyOf`, so\n* a step can finish under a newer status than it started with. `emit` sends\n* the operation's other events. A host `onEvent` that throws is the host's\n* bug and cannot fail the operation.\n*/\nfunction stepTracker(keyOf, onEvent) {\n\tconst open = /* @__PURE__ */ new Map();\n\tconst emit = (event) => {\n\t\ttry {\n\t\t\tonEvent?.(event);\n\t\t} catch {}\n\t};\n\tconst finish = (step, outcome, data) => {\n\t\tconst entry = open.get(keyOf(step));\n\t\tif (entry === void 0) return;\n\t\topen.delete(keyOf(step));\n\t\tconst durationMs = Math.round(performance.now() - entry.startedAt);\n\t\temit({\n\t\t\tkind: \"step-finished\",\n\t\t\tstep,\n\t\t\toutcome,\n\t\t\tdurationMs,\n\t\t\tdata\n\t\t});\n\t};\n\treturn {\n\t\tstart(step) {\n\t\t\topen.set(keyOf(step), {\n\t\t\t\tstep,\n\t\t\t\tstartedAt: performance.now()\n\t\t\t});\n\t\t\temit({\n\t\t\t\tkind: \"step-started\",\n\t\t\t\tstep\n\t\t\t});\n\t\t},\n\t\tfinish(step, data) {\n\t\t\tfinish(step, \"ok\", data);\n\t\t},\n\t\tfail(step) {\n\t\t\tfinish(step, \"failed\");\n\t\t},\n\t\t/** Closes every open step with `outcome`, innermost first. */\n\t\tcloseOpen(outcome) {\n\t\t\tfor (const { step } of [...open.values()].reverse()) finish(step, outcome);\n\t\t},\n\t\tisOpen(step) {\n\t\t\treturn open.has(keyOf(step));\n\t\t},\n\t\tmessage(severity, text) {\n\t\t\temit({\n\t\t\t\tkind: \"message\",\n\t\t\t\tseverity,\n\t\t\t\ttext\n\t\t\t});\n\t\t},\n\t\temit\n\t};\n}\n/** One converge event as step events: each resource is a step, made by `resourceStep`; a log line is a message. */\nfunction reportConvergeEvent(steps, event, redact, resourceStep) {\n\tif (event.kind === \"log\") {\n\t\tsteps.message(event.severity, redact(withComposerAdvice(event.text)));\n\t\treturn;\n\t}\n\tconst step = resourceStep({\n\t\tresourceId: event.fqn,\n\t\tresourceType: event.resourceType,\n\t\tstatus: event.status\n\t});\n\tswitch (event.phase) {\n\t\tcase \"running\":\n\t\t\tif (!steps.isOpen(step)) steps.start(step);\n\t\t\treturn;\n\t\tcase \"done\":\n\t\t\tif (!steps.isOpen(step)) steps.start(step);\n\t\t\tsteps.finish(step);\n\t\t\treturn;\n\t\tcase \"failed\":\n\t\t\tif (!steps.isOpen(step)) steps.start(step);\n\t\t\tsteps.fail(step);\n\t\t\tif (event.message !== void 0) steps.message(\"warn\", redact(`${event.fqn}: ${withComposerAdvice(event.message)}`));\n\t\t\treturn;\n\t\tcase \"pending\": return;\n\t}\n}\n/**\n* Alchemy's terminal text as `info` messages, one per complete line, redacted. A secret split\n* across writes or lines is still found, because the text passes through a `StreamRedactor`\n* before it is cut into lines. `end` sends the last line that has no line break.\n*/\nfunction interactionMessages(steps, redaction) {\n\tconst stream = new StreamRedactor(redaction.allValues());\n\tlet partial = \"\";\n\tconst send = (text, last) => {\n\t\tconst lines = (partial + text).split(\"\\n\");\n\t\tpartial = last ? \"\" : lines.pop() ?? \"\";\n\t\tfor (const line of lines) if (line.trim() !== \"\") steps.message(\"info\", redaction.redact(line));\n\t};\n\treturn {\n\t\tpush: (text) => send(stream.push(text), false),\n\t\tend: () => send(stream.end(), true)\n\t};\n}\n//#endregion\nexport { reportConvergeEvent as n, stepTracker as r, interactionMessages as t };\n\n//# sourceMappingURL=steps-BZXNqW6U.mjs.map"],"mappings":";;;;;;;;;AASA,SAAS,YAAY,OAAO,SAAS;CACpC,MAAM,uBAAuB,IAAI,IAAI;CACrC,MAAM,QAAQ,UAAU;EACvB,IAAI;GACH,UAAU,KAAK;EAChB,QAAQ,CAAC;CACV;CACA,MAAM,UAAU,MAAM,SAAS,SAAS;EACvC,MAAM,QAAQ,KAAK,IAAI,MAAM,IAAI,CAAC;EAClC,IAAI,UAAU,KAAK,GAAG;EACtB,KAAK,OAAO,MAAM,IAAI,CAAC;EACvB,MAAM,aAAa,KAA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,OAAO,GAAG,MAAM,IAAI,IAAI,mBAAmB,MAAM,OAAO,GAAG,CAAC;GAChH;EACD,KAAK,WAAW;CACjB;AACD;;;;;;AAMA,SAAS,oBAAoB,OAAO,WAAW;CAC9C,MAAM,SAAS,IAAI,eAAe,UAAU,UAAU,CAAC;CACvD,IAAI,UAAU;CACd,MAAM,QAAQ,MAAM,SAAS;EAC5B,MAAM,SAAS,UAAU,KAAA,CAAM,MAAM,IAAI;EACzC,UAAU,OAAO,KAAK,MAAM,IAAI,KAAK;EACrC,KAAK,MAAM,QAAQ,OAAO,IAAI,KAAK,KAAK,MAAM,IAAI,MAAM,QAAQ,QAAQ,UAAU,OAAO,IAAI,CAAC;CAC/F;CACA,OAAO;EACN,OAAO,SAAS,KAAK,OAAO,KAAK,IAAI,GAAG,KAAK;EAC7C,WAAW,KAAK,OAAO,IAAI,GAAG,IAAI;CACnC;AACD"}
|
package/dist/testing.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as HydratedDeps, O as InputValueOf, U as Params, h as Deps, nt as RunnableServiceNode, v as Expose } from "./graph-types-
|
|
1
|
+
import { C as HydratedDeps, O as InputValueOf, U as Params, h as Deps, nt as RunnableServiceNode, v as Expose } from "./graph-types-D4PrtP-l-B0uuchTl.mjs";
|
|
2
2
|
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
3
3
|
//#region ../../0-framework/1-core/core/dist/testing.d.mts
|
|
4
4
|
//#region src/testing.d.ts
|
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
import { t as describeKind } from "./describe-kind-Cpm_euxo-DsSPENQa.mjs";
|
|
2
|
+
import { E as secretsKeys, c as assertAppName, n as Load, t as GraphCheckError } from "./graph-D2WMLL43-CeiC5wdy.mjs";
|
|
3
|
+
import { t as InternalError } from "./internal-error-Dfur7Zqt-D96dWHZK.mjs";
|
|
4
|
+
import { t as CliStructuredError } from "./errors-DI3TBXE-.mjs";
|
|
5
|
+
import "./dist-Cf_mZHaH.mjs";
|
|
6
|
+
import { n as environmentVariables } from "./config-adapters-DG-uhGfv-Bt1M9f8b.mjs";
|
|
7
|
+
import "./deploy-CSU0kr4j.mjs";
|
|
8
|
+
import { a as checkComposerConfig, n as loadEntry, o as configFileMissing, s as entryMissing } from "./load-entry-CEoVBdMj-CHOz7jKf.mjs";
|
|
9
|
+
import { r as credentialLookingValues, t as SecretRedaction, u as valuesUnderSecretsKeys } from "./redaction-DY6eDC12-W-FzW7_r.mjs";
|
|
10
|
+
import * as path$1 from "node:path";
|
|
11
|
+
import * as fs$1 from "node:fs";
|
|
12
|
+
import { spawnSync } from "node:child_process";
|
|
13
|
+
//#region ../../0-framework/3-tooling/assemble/dist/index.mjs
|
|
14
|
+
/**
|
|
15
|
+
* A user-facing assembly failure, structured at origin (base-type rule 6):
|
|
16
|
+
* a `CliStructuredError` whose code names which way assembly went wrong.
|
|
17
|
+
* This package's second consumer is the programmatic deploy API, not just
|
|
18
|
+
* the CLI — hosts branch on `error.code`, the CLI renders the envelope.
|
|
19
|
+
*/
|
|
20
|
+
var AssembleError = class extends CliStructuredError {
|
|
21
|
+
constructor(code, summary, options) {
|
|
22
|
+
super(code, summary, options);
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* The registry route for one service's build: extension by
|
|
27
|
+
* `build.extension`, node descriptor by `build.type`, kind must be "build".
|
|
28
|
+
* The CLI's coverage validation reports the same misses earlier with the
|
|
29
|
+
* config fix; these errors are the backstop for programmatic callers.
|
|
30
|
+
*/
|
|
31
|
+
function buildDescriptorAssemble(config, node, address, cwd, report) {
|
|
32
|
+
const { extension, type } = node.build;
|
|
33
|
+
const extensionDescriptor = config.extensions.find((candidate) => candidate.id === extension);
|
|
34
|
+
if (extensionDescriptor === void 0) throw new AssembleError("ASSEMBLE.EXTENSION_MISSING", `No extension "${extension}" is configured (needed by service "${node.name}"'s build).`, { fix: "Add it to `extensions` in the `composer` section of prisma.config.ts." });
|
|
35
|
+
const nodeDescriptor = extensionDescriptor.nodes[type];
|
|
36
|
+
if (nodeDescriptor === void 0) throw new AssembleError("ASSEMBLE.DESCRIPTOR_MISSING", `Extension "${extension}" has no descriptor for build type "${type}".`, { why: `Known types: ${Object.keys(extensionDescriptor.nodes).join(", ")}.` });
|
|
37
|
+
if (nodeDescriptor.kind !== "build") throw new AssembleError("ASSEMBLE.DESCRIPTOR_KIND_MISMATCH", `Extension "${extension}"'s descriptor for type "${type}" is a "${nodeDescriptor.kind}" descriptor.`, { why: "Assembling a service build needs a \"build\" descriptor." });
|
|
38
|
+
return nodeDescriptor.assemble({
|
|
39
|
+
build: node.build,
|
|
40
|
+
address,
|
|
41
|
+
cwd,
|
|
42
|
+
report
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* The dev server a service's build descriptor declares, or `undefined` when it
|
|
47
|
+
* declares none — including when the registry route misses, which the
|
|
48
|
+
* assemble that follows reports with its own pinned error.
|
|
49
|
+
*/
|
|
50
|
+
async function buildDescriptorServe(config, node, address) {
|
|
51
|
+
const { extension, type } = node.build;
|
|
52
|
+
const nodeDescriptor = config.extensions.find((candidate) => candidate.id === extension)?.nodes[type];
|
|
53
|
+
if (nodeDescriptor?.kind !== "build" || nodeDescriptor.serve === void 0) return void 0;
|
|
54
|
+
try {
|
|
55
|
+
return await nodeDescriptor.serve({
|
|
56
|
+
build: node.build,
|
|
57
|
+
address
|
|
58
|
+
});
|
|
59
|
+
} catch (error) {
|
|
60
|
+
if (CliStructuredError.is(error)) throw error;
|
|
61
|
+
throw new CliStructuredError("DEV.DEV_SERVER_UNAVAILABLE", `service "${address}" cannot run its dev server: ${error instanceof Error ? error.message : String(error)}`, {
|
|
62
|
+
meta: { address },
|
|
63
|
+
cause: error
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
async function assembleServices(graph, config, cwd, run, onEvent, options = {}) {
|
|
68
|
+
const runAssembler = run ?? ((node, address, nodeCwd, report) => buildDescriptorAssemble(config, node, address, nodeCwd, report));
|
|
69
|
+
const serviceNodes = graph.nodes.filter((n) => n.node.kind === "service");
|
|
70
|
+
if (serviceNodes.length === 0) throw new AssembleError("ASSEMBLE.SERVICE_MISSING", "The loaded graph has no service to assemble.");
|
|
71
|
+
const bundles = {};
|
|
72
|
+
const devServers = {};
|
|
73
|
+
for (const { id, node } of serviceNodes) {
|
|
74
|
+
if (options.devServers === true) {
|
|
75
|
+
const server = await buildDescriptorServe(config, node, id);
|
|
76
|
+
if (server !== void 0) {
|
|
77
|
+
devServers[id] = server;
|
|
78
|
+
continue;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
onEvent?.({
|
|
82
|
+
kind: "service-started",
|
|
83
|
+
address: id
|
|
84
|
+
});
|
|
85
|
+
const data = {};
|
|
86
|
+
let artifact;
|
|
87
|
+
try {
|
|
88
|
+
artifact = await runAssembler(node, id, cwd, (reported) => Object.assign(data, reported));
|
|
89
|
+
} catch (error) {
|
|
90
|
+
if (CliStructuredError.is(error)) throw error;
|
|
91
|
+
throw new AssembleError("ASSEMBLE.BUILD_FAILED", error instanceof Error ? error.message : String(error), {
|
|
92
|
+
meta: { address: id },
|
|
93
|
+
cause: error
|
|
94
|
+
});
|
|
95
|
+
}
|
|
96
|
+
bundles[id] = artifact;
|
|
97
|
+
onEvent?.({
|
|
98
|
+
kind: "service-assembled",
|
|
99
|
+
address: id,
|
|
100
|
+
data
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
return {
|
|
104
|
+
bundles,
|
|
105
|
+
devServers
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
//#endregion
|
|
109
|
+
//#region ../../0-framework/3-tooling/cli/dist/validate-environment-DCZiNSlR.mjs
|
|
110
|
+
function adapterInvalid(list, index, input, summary, fix) {
|
|
111
|
+
return new CliStructuredError("CONFIG.ADAPTER_INVALID", summary, {
|
|
112
|
+
fix,
|
|
113
|
+
where: { path: input.configFile },
|
|
114
|
+
meta: { field: `${list}[${index}]` }
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
function isValues(value) {
|
|
118
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
119
|
+
}
|
|
120
|
+
function isText(values) {
|
|
121
|
+
return Object.values(values).every((value) => typeof value === "string");
|
|
122
|
+
}
|
|
123
|
+
async function readAdapters(list, adapters, input) {
|
|
124
|
+
const adapterInput = Object.freeze({
|
|
125
|
+
environment: input.environment,
|
|
126
|
+
configDirectory: path$1.dirname(input.configFile)
|
|
127
|
+
});
|
|
128
|
+
const merged = Object.create(null);
|
|
129
|
+
for (const [index, adapter] of adapters.entries()) {
|
|
130
|
+
const field = `composer.${list}[${index}]`;
|
|
131
|
+
let values;
|
|
132
|
+
try {
|
|
133
|
+
values = await adapter(adapterInput);
|
|
134
|
+
} catch (thrown) {
|
|
135
|
+
throw new CliStructuredError("CONFIG.ADAPTER_FAILED", `\`${field}\` failed to read the values for the environment "${input.environment}".`, {
|
|
136
|
+
why: `It threw: ${thrown instanceof Error ? thrown.message : String(thrown)}`,
|
|
137
|
+
fix: `Fix the adapter, or remove it from \`composer.${list}\` in prisma.config.ts.`,
|
|
138
|
+
where: { path: input.configFile },
|
|
139
|
+
meta: { field: `${list}[${index}]` },
|
|
140
|
+
cause: thrown
|
|
141
|
+
});
|
|
142
|
+
}
|
|
143
|
+
if (typeof values === "function") throw adapterInvalid(list, index, input, `\`${field}\` returned a function, not an object of values.`, "An adapter factory was put in the list instead of the adapter it makes: write `dotenv()`, not `dotenv`.");
|
|
144
|
+
if (!isValues(values)) throw adapterInvalid(list, index, input, `\`${field}\` returned ${describeKind(values)}, not an object of values.`, "Return an object whose keys are the names of the values, e.g. `{ EMAIL_FROM: 'shop@example.com' }`.");
|
|
145
|
+
for (const [key, value] of Object.entries(values)) {
|
|
146
|
+
if (value === void 0) continue;
|
|
147
|
+
if (list === "secrets" && typeof value !== "string") throw adapterInvalid(list, index, input, `\`${field}\` returned ${describeKind(value)} for "${key}", but a secret is text.`, "Return the secret as a string. A platform variable holds text.");
|
|
148
|
+
merged[key] = value;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
return Object.freeze(merged);
|
|
152
|
+
}
|
|
153
|
+
/** Calls the section's `config` adapters (default `[environmentVariables()]`) and merges what they return: the app configuration. */
|
|
154
|
+
function readAppConfiguration(section, input) {
|
|
155
|
+
return readAdapters("config", section.config ?? [environmentVariables()], input);
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Calls the section's `secrets` adapters (default `[environmentVariables()]`) and merges what they
|
|
159
|
+
* return: the app secrets. Every value must be text. A value is a known secret only once the graph
|
|
160
|
+
* names it, so this adds none.
|
|
161
|
+
*/
|
|
162
|
+
async function readAppSecrets(section, input) {
|
|
163
|
+
const merged = await readAdapters("secrets", section.secrets ?? [environmentVariables()], input);
|
|
164
|
+
if (!isText(merged)) throw new InternalError("readAdapters admitted a secret that is not text");
|
|
165
|
+
return merged;
|
|
166
|
+
}
|
|
167
|
+
function lookup(extensions, extension, type, expectedKind, what) {
|
|
168
|
+
const ext = extensions.get(extension);
|
|
169
|
+
if (ext === void 0) throw new CliStructuredError("CONFIG.EXTENSION_MISSING", `No extension "${extension}" is configured (needed by ${what}).`, {
|
|
170
|
+
fix: "Add it to `extensions` in the `composer` section of prisma.config.ts (import its /control entry and list its descriptor).",
|
|
171
|
+
meta: {
|
|
172
|
+
extension,
|
|
173
|
+
type
|
|
174
|
+
}
|
|
175
|
+
});
|
|
176
|
+
const descriptor = ext.nodes[type];
|
|
177
|
+
if (descriptor === void 0) throw new CliStructuredError("CONFIG.DESCRIPTOR_MISSING", `Extension "${extension}" has no descriptor for node type "${type}" (needed by ${what}).`, {
|
|
178
|
+
why: `Known types: ${Object.keys(ext.nodes).join(", ")}.`,
|
|
179
|
+
meta: {
|
|
180
|
+
extension,
|
|
181
|
+
type
|
|
182
|
+
}
|
|
183
|
+
});
|
|
184
|
+
if (descriptor.kind !== expectedKind) throw new CliStructuredError("CONFIG.DESCRIPTOR_KIND_MISMATCH", `Extension "${extension}"'s descriptor for node type "${type}" is a "${descriptor.kind}" descriptor — ${what} needs a "${expectedKind}" descriptor.`, { meta: {
|
|
185
|
+
extension,
|
|
186
|
+
type,
|
|
187
|
+
kind: descriptor.kind
|
|
188
|
+
} });
|
|
189
|
+
}
|
|
190
|
+
/** Throws a structured CONFIG.* error on the first uncovered `(extension, type)`; silent when the config covers the whole graph. */
|
|
191
|
+
function validateRegistryCoverage(graph, config) {
|
|
192
|
+
const extensions = new Map(config.extensions.map((descriptor) => [descriptor.id, descriptor]));
|
|
193
|
+
for (const { id, node } of graph.nodes) {
|
|
194
|
+
if (node.kind === "resource") {
|
|
195
|
+
lookup(extensions, node.extension, node.type, "resource", `resource node "${id}"`);
|
|
196
|
+
continue;
|
|
197
|
+
}
|
|
198
|
+
if (node.kind !== "service") continue;
|
|
199
|
+
lookup(extensions, node.extension, node.type, "service", `service node "${id}"`);
|
|
200
|
+
lookup(extensions, node.build.extension, node.build.type, "build", `service node "${id}"'s build descriptor`);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
/**
|
|
204
|
+
* The shared prefix of `deploy`/`destroy`/`dev` (deploy-cli.md § The
|
|
205
|
+
* pipeline; local-dev spec § 6): entry load, Load,
|
|
206
|
+
* registry coverage validation, name resolution, assemble. Deploy and dev
|
|
207
|
+
* diverge after this — deploy resolves containers/preflight/stack file
|
|
208
|
+
* against the hosted providers, dev against the local ones — so everything
|
|
209
|
+
* up to and including assemble lives here once, consumed verbatim by both
|
|
210
|
+
* `run()` (main.ts) and `runDev()` (dev/run-dev.ts), so the two pipelines
|
|
211
|
+
* cannot drift.
|
|
212
|
+
*/
|
|
213
|
+
const NO_SECRETS = Object.freeze({});
|
|
214
|
+
function configError(findings, file) {
|
|
215
|
+
const [first] = findings;
|
|
216
|
+
return new CliStructuredError(first.code, first.summary, {
|
|
217
|
+
...first.why === void 0 ? {} : { why: first.why },
|
|
218
|
+
fix: first.fix,
|
|
219
|
+
where: { path: first.where ?? file },
|
|
220
|
+
meta: {
|
|
221
|
+
...first.field === void 0 ? {} : { field: first.field },
|
|
222
|
+
findings
|
|
223
|
+
}
|
|
224
|
+
});
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* Refuses a caller's config with the same findings, in the same order, as the CLI's section validator.
|
|
228
|
+
* The error is the first finding and carries all of them in `meta.findings`. Returns the config with `file` resolved against `cwd`.
|
|
229
|
+
*/
|
|
230
|
+
function checkConfigSource(source, cwd) {
|
|
231
|
+
const file = path$1.resolve(cwd, source.file);
|
|
232
|
+
if (!fs$1.existsSync(file)) throw configError([configFileMissing(file)], file);
|
|
233
|
+
const checked = checkComposerConfig(source.value, file);
|
|
234
|
+
if (!checked.ok) throw configError(checked.findings, file);
|
|
235
|
+
return {
|
|
236
|
+
value: checked.value,
|
|
237
|
+
file
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
/**
|
|
241
|
+
* Resolves the entry module. An override (`--entry`, or an operation's `entry` input) resolves
|
|
242
|
+
* against `cwd`; the section's `entry` resolves against the directory of the file that declares it,
|
|
243
|
+
* as the CLI engine resolves path fields in prisma.config.ts.
|
|
244
|
+
*/
|
|
245
|
+
function resolveEntryPath(override, source, cwd) {
|
|
246
|
+
if (override !== void 0) return {
|
|
247
|
+
path: path$1.resolve(cwd, override),
|
|
248
|
+
fix: `Check the \`--entry\` path (the \`entry\` input when calling @prisma/composer/control) "${override}". It is relative to the current directory, ${cwd}.`
|
|
249
|
+
};
|
|
250
|
+
const configured = source.value.entry;
|
|
251
|
+
if (configured === void 0) throw configError([entryMissing], source.file);
|
|
252
|
+
return {
|
|
253
|
+
path: path$1.resolve(path$1.dirname(source.file), configured),
|
|
254
|
+
fix: `Check \`entry: "${configured}"\` in ${source.file}. It is relative to that file's directory.`
|
|
255
|
+
};
|
|
256
|
+
}
|
|
257
|
+
/**
|
|
258
|
+
* The pipeline's front — entry load and name resolution —
|
|
259
|
+
* WITHOUT Load, coverage, or assemble. `log` needs only who the app is (its
|
|
260
|
+
* config and resolved name) to reach the already-running local instance; it
|
|
261
|
+
* neither builds nor provisions, so it must not require the user's built
|
|
262
|
+
* output the way the full pipeline does.
|
|
263
|
+
*/
|
|
264
|
+
async function resolveAppIdentity(entry, overrideName, cwd, config) {
|
|
265
|
+
const checked = checkConfigSource(config, cwd);
|
|
266
|
+
const { value } = checked;
|
|
267
|
+
const resolved = resolveEntryPath(entry, checked, cwd);
|
|
268
|
+
const entryModule = await loadEntry(resolved.path, cwd, resolved.fix);
|
|
269
|
+
const name = overrideName ?? entryModule.root.name;
|
|
270
|
+
if (name.length === 0) throw new CliStructuredError("COMPOSE.NAME_MISSING", "The root node has no name.", { fix: "Name it at authoring, or pass --name." });
|
|
271
|
+
assertAppName(name);
|
|
272
|
+
return {
|
|
273
|
+
config: value,
|
|
274
|
+
name
|
|
275
|
+
};
|
|
276
|
+
}
|
|
277
|
+
/**
|
|
278
|
+
* Runs entry load, name resolution, Load, registry coverage, and assemble — steps 1–5 of `run()`. `onAssembleError`, when
|
|
279
|
+
* given, lets a caller decorate an assemble failure with command-specific
|
|
280
|
+
* guidance (destroy's "build first" hint) without this shared step knowing
|
|
281
|
+
* about any one command.
|
|
282
|
+
*/
|
|
283
|
+
async function runPipeline(entry, overrideName, environment, cwd, source, deps = {}, onAssembleError) {
|
|
284
|
+
const configSource = checkConfigSource(source, cwd);
|
|
285
|
+
const config = configSource.value;
|
|
286
|
+
const resolved = resolveEntryPath(entry, configSource, cwd);
|
|
287
|
+
const entryModule = await loadEntry(resolved.path, cwd, resolved.fix);
|
|
288
|
+
const name = overrideName ?? entryModule.root.name;
|
|
289
|
+
if (name.length === 0) throw new CliStructuredError("COMPOSE.NAME_MISSING", "The root node has no name.", { fix: "Name it at authoring, or pass --name." });
|
|
290
|
+
const redaction = deps.redaction ?? new SecretRedaction(process.env);
|
|
291
|
+
const adapterInput = {
|
|
292
|
+
environment,
|
|
293
|
+
configFile: configSource.file
|
|
294
|
+
};
|
|
295
|
+
const secrets = deps.readSecrets === true ? await readAppSecrets(config, adapterInput) : NO_SECRETS;
|
|
296
|
+
const configuration = await readAppConfiguration(config, adapterInput);
|
|
297
|
+
redaction.addCredentialLookingValues(credentialLookingValues(configuration));
|
|
298
|
+
const graph = Load(entryModule.root, {
|
|
299
|
+
id: name,
|
|
300
|
+
environment: { name: environment },
|
|
301
|
+
configuration
|
|
302
|
+
});
|
|
303
|
+
redaction.addKnownSecrets(valuesUnderSecretsKeys(configuration, secrets, secretsKeys(graph)));
|
|
304
|
+
checkGraph(graph, config.extensions);
|
|
305
|
+
validateRegistryCoverage(graph, config);
|
|
306
|
+
deps.onEvent?.({ kind: "loaded" });
|
|
307
|
+
let assembled;
|
|
308
|
+
try {
|
|
309
|
+
assembled = await assembleServices(graph, config, cwd, deps.runAssembler, deps.onEvent, { devServers: deps.devServers === true });
|
|
310
|
+
} catch (error) {
|
|
311
|
+
if (onAssembleError !== void 0 && error instanceof Error) throw onAssembleError(error);
|
|
312
|
+
throw error;
|
|
313
|
+
}
|
|
314
|
+
return {
|
|
315
|
+
configSource,
|
|
316
|
+
entryModule,
|
|
317
|
+
graph,
|
|
318
|
+
name,
|
|
319
|
+
assembled,
|
|
320
|
+
configuration,
|
|
321
|
+
secrets
|
|
322
|
+
};
|
|
323
|
+
}
|
|
324
|
+
function checkGraph(graph, extensions) {
|
|
325
|
+
for (const extension of extensions) try {
|
|
326
|
+
extension.checkGraph?.(graph);
|
|
327
|
+
} catch (error) {
|
|
328
|
+
if (error instanceof GraphCheckError) throw new GraphCheckError(error.message, { extension: extension.id });
|
|
329
|
+
throw error;
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
/** Letters, digits, `-` and `_`, starting with a letter or digit: always a valid git ref, so no `git` is needed to check it. */
|
|
333
|
+
const PLAIN_ENVIRONMENT_NAME = /^[A-Za-z0-9][A-Za-z0-9_-]*$/;
|
|
334
|
+
/** An environment name must be a valid git ref (deploy-cli.md) — checked via `git check-ref-format`, never silently normalized. Runs before anything platform-specific. */
|
|
335
|
+
function validateEnvironmentName(environment, spawn = spawnSync) {
|
|
336
|
+
if (PLAIN_ENVIRONMENT_NAME.test(environment)) return;
|
|
337
|
+
const result = spawn("git", ["check-ref-format", `refs/heads/${environment}`], { stdio: "ignore" });
|
|
338
|
+
if (result.error) throw new CliStructuredError("DEPLOY.ENVIRONMENT_UNVALIDATABLE", `git is required to validate --environment "${environment}" (git check-ref-format): ${result.error.message}.`, { cause: result.error });
|
|
339
|
+
if (result.status !== 0) throw new CliStructuredError("DEPLOY.ENVIRONMENT_INVALID", `Invalid --environment "${environment}": must be a valid git ref name (git check-ref-format rejected "refs/heads/${environment}").`);
|
|
340
|
+
}
|
|
341
|
+
//#endregion
|
|
342
|
+
export { validateEnvironmentName as i, resolveAppIdentity as n, runPipeline as r, checkConfigSource as t };
|
|
343
|
+
|
|
344
|
+
//# sourceMappingURL=validate-environment-DCZiNSlR-C7lv0cH1.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-environment-DCZiNSlR-C7lv0cH1.mjs","names":["path","fs"],"sources":["../../../0-framework/3-tooling/assemble/dist/index.mjs","../../../0-framework/3-tooling/cli/dist/validate-environment-DCZiNSlR.mjs"],"sourcesContent":["import { CliStructuredError } from \"@internal/foundation/errors\";\n//#region src/assemble-error.ts\n/**\n* A user-facing assembly failure, structured at origin (base-type rule 6):\n* a `CliStructuredError` whose code names which way assembly went wrong.\n* This package's second consumer is the programmatic deploy API, not just\n* the CLI — hosts branch on `error.code`, the CLI renders the envelope.\n*/\nvar AssembleError = class extends CliStructuredError {\n\tconstructor(code, summary, options) {\n\t\tsuper(code, summary, options);\n\t}\n};\n//#endregion\n//#region src/assemble-services.ts\n/**\n* The registry route for one service's build: extension by\n* `build.extension`, node descriptor by `build.type`, kind must be \"build\".\n* The CLI's coverage validation reports the same misses earlier with the\n* config fix; these errors are the backstop for programmatic callers.\n*/\nfunction buildDescriptorAssemble(config, node, address, cwd, report) {\n\tconst { extension, type } = node.build;\n\tconst extensionDescriptor = config.extensions.find((candidate) => candidate.id === extension);\n\tif (extensionDescriptor === void 0) throw new AssembleError(\"ASSEMBLE.EXTENSION_MISSING\", `No extension \"${extension}\" is configured (needed by service \"${node.name}\"'s build).`, { fix: \"Add it to `extensions` in the `composer` section of prisma.config.ts.\" });\n\tconst nodeDescriptor = extensionDescriptor.nodes[type];\n\tif (nodeDescriptor === void 0) throw new AssembleError(\"ASSEMBLE.DESCRIPTOR_MISSING\", `Extension \"${extension}\" has no descriptor for build type \"${type}\".`, { why: `Known types: ${Object.keys(extensionDescriptor.nodes).join(\", \")}.` });\n\tif (nodeDescriptor.kind !== \"build\") throw new AssembleError(\"ASSEMBLE.DESCRIPTOR_KIND_MISMATCH\", `Extension \"${extension}\"'s descriptor for type \"${type}\" is a \"${nodeDescriptor.kind}\" descriptor.`, { why: \"Assembling a service build needs a \\\"build\\\" descriptor.\" });\n\treturn nodeDescriptor.assemble({\n\t\tbuild: node.build,\n\t\taddress,\n\t\tcwd,\n\t\treport\n\t});\n}\n/**\n* The dev server a service's build descriptor declares, or `undefined` when it\n* declares none — including when the registry route misses, which the\n* assemble that follows reports with its own pinned error.\n*/\nasync function buildDescriptorServe(config, node, address) {\n\tconst { extension, type } = node.build;\n\tconst nodeDescriptor = config.extensions.find((candidate) => candidate.id === extension)?.nodes[type];\n\tif (nodeDescriptor?.kind !== \"build\" || nodeDescriptor.serve === void 0) return void 0;\n\ttry {\n\t\treturn await nodeDescriptor.serve({\n\t\t\tbuild: node.build,\n\t\t\taddress\n\t\t});\n\t} catch (error) {\n\t\tif (CliStructuredError.is(error)) throw error;\n\t\tthrow new CliStructuredError(\"DEV.DEV_SERVER_UNAVAILABLE\", `service \"${address}\" cannot run its dev server: ${error instanceof Error ? error.message : String(error)}`, {\n\t\t\tmeta: { address },\n\t\t\tcause: error\n\t\t});\n\t}\n}\nasync function assembleServices(graph, config, cwd, run, onEvent, options = {}) {\n\tconst runAssembler = run ?? ((node, address, nodeCwd, report) => buildDescriptorAssemble(config, node, address, nodeCwd, report));\n\tconst serviceNodes = graph.nodes.filter((n) => n.node.kind === \"service\");\n\tif (serviceNodes.length === 0) throw new AssembleError(\"ASSEMBLE.SERVICE_MISSING\", \"The loaded graph has no service to assemble.\");\n\tconst bundles = {};\n\tconst devServers = {};\n\tfor (const { id, node } of serviceNodes) {\n\t\tif (options.devServers === true) {\n\t\t\tconst server = await buildDescriptorServe(config, node, id);\n\t\t\tif (server !== void 0) {\n\t\t\t\tdevServers[id] = server;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t}\n\t\tonEvent?.({\n\t\t\tkind: \"service-started\",\n\t\t\taddress: id\n\t\t});\n\t\tconst data = {};\n\t\tlet artifact;\n\t\ttry {\n\t\t\tartifact = await runAssembler(node, id, cwd, (reported) => Object.assign(data, reported));\n\t\t} catch (error) {\n\t\t\tif (CliStructuredError.is(error)) throw error;\n\t\t\tthrow new AssembleError(\"ASSEMBLE.BUILD_FAILED\", error instanceof Error ? error.message : String(error), {\n\t\t\t\tmeta: { address: id },\n\t\t\t\tcause: error\n\t\t\t});\n\t\t}\n\t\tbundles[id] = artifact;\n\t\tonEvent?.({\n\t\t\tkind: \"service-assembled\",\n\t\t\taddress: id,\n\t\t\tdata\n\t\t});\n\t}\n\treturn {\n\t\tbundles,\n\t\tdevServers\n\t};\n}\n//#endregion\nexport { AssembleError, assembleServices };\n\n//# sourceMappingURL=index.mjs.map","import { n as environmentVariables } from \"./config-adapters-DG-uhGfv.mjs\";\nimport { n as configFileMissing, r as entryMissing, t as checkComposerConfig } from \"./composer-config-QKdY85G-.mjs\";\nimport { t as loadEntry } from \"./load-entry-CEoVBdMj.mjs\";\nimport { r as credentialLookingValues, t as SecretRedaction, u as valuesUnderSecretsKeys } from \"./redaction-DY6eDC12.mjs\";\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\nimport { assembleServices } from \"@internal/assemble\";\nimport { GraphCheckError, Load, assertAppName } from \"@internal/core\";\nimport { secretsKeys } from \"@internal/core/deploy\";\nimport { CliStructuredError, InternalError, describeKind } from \"@internal/foundation/errors\";\nimport { spawnSync } from \"node:child_process\";\n//#region src/app-configuration.ts\nfunction adapterInvalid(list, index, input, summary, fix) {\n\treturn new CliStructuredError(\"CONFIG.ADAPTER_INVALID\", summary, {\n\t\tfix,\n\t\twhere: { path: input.configFile },\n\t\tmeta: { field: `${list}[${index}]` }\n\t});\n}\nfunction isValues(value) {\n\treturn typeof value === \"object\" && value !== null && !Array.isArray(value);\n}\nfunction isText(values) {\n\treturn Object.values(values).every((value) => typeof value === \"string\");\n}\nasync function readAdapters(list, adapters, input) {\n\tconst adapterInput = Object.freeze({\n\t\tenvironment: input.environment,\n\t\tconfigDirectory: path.dirname(input.configFile)\n\t});\n\tconst merged = Object.create(null);\n\tfor (const [index, adapter] of adapters.entries()) {\n\t\tconst field = `composer.${list}[${index}]`;\n\t\tlet values;\n\t\ttry {\n\t\t\tvalues = await adapter(adapterInput);\n\t\t} catch (thrown) {\n\t\t\tthrow new CliStructuredError(\"CONFIG.ADAPTER_FAILED\", `\\`${field}\\` failed to read the values for the environment \"${input.environment}\".`, {\n\t\t\t\twhy: `It threw: ${thrown instanceof Error ? thrown.message : String(thrown)}`,\n\t\t\t\tfix: `Fix the adapter, or remove it from \\`composer.${list}\\` in prisma.config.ts.`,\n\t\t\t\twhere: { path: input.configFile },\n\t\t\t\tmeta: { field: `${list}[${index}]` },\n\t\t\t\tcause: thrown\n\t\t\t});\n\t\t}\n\t\tif (typeof values === \"function\") throw adapterInvalid(list, index, input, `\\`${field}\\` returned a function, not an object of values.`, \"An adapter factory was put in the list instead of the adapter it makes: write `dotenv()`, not `dotenv`.\");\n\t\tif (!isValues(values)) throw adapterInvalid(list, index, input, `\\`${field}\\` returned ${describeKind(values)}, not an object of values.`, \"Return an object whose keys are the names of the values, e.g. `{ EMAIL_FROM: 'shop@example.com' }`.\");\n\t\tfor (const [key, value] of Object.entries(values)) {\n\t\t\tif (value === void 0) continue;\n\t\t\tif (list === \"secrets\" && typeof value !== \"string\") throw adapterInvalid(list, index, input, `\\`${field}\\` returned ${describeKind(value)} for \"${key}\", but a secret is text.`, \"Return the secret as a string. A platform variable holds text.\");\n\t\t\tmerged[key] = value;\n\t\t}\n\t}\n\treturn Object.freeze(merged);\n}\n/** Calls the section's `config` adapters (default `[environmentVariables()]`) and merges what they return: the app configuration. */\nfunction readAppConfiguration(section, input) {\n\treturn readAdapters(\"config\", section.config ?? [environmentVariables()], input);\n}\n/**\n* Calls the section's `secrets` adapters (default `[environmentVariables()]`) and merges what they\n* return: the app secrets. Every value must be text. A value is a known secret only once the graph\n* names it, so this adds none.\n*/\nasync function readAppSecrets(section, input) {\n\tconst merged = await readAdapters(\"secrets\", section.secrets ?? [environmentVariables()], input);\n\tif (!isText(merged)) throw new InternalError(\"readAdapters admitted a secret that is not text\");\n\treturn merged;\n}\n//#endregion\n//#region src/validate-coverage.ts\nfunction lookup(extensions, extension, type, expectedKind, what) {\n\tconst ext = extensions.get(extension);\n\tif (ext === void 0) throw new CliStructuredError(\"CONFIG.EXTENSION_MISSING\", `No extension \"${extension}\" is configured (needed by ${what}).`, {\n\t\tfix: \"Add it to `extensions` in the `composer` section of prisma.config.ts (import its /control entry and list its descriptor).\",\n\t\tmeta: {\n\t\t\textension,\n\t\t\ttype\n\t\t}\n\t});\n\tconst descriptor = ext.nodes[type];\n\tif (descriptor === void 0) throw new CliStructuredError(\"CONFIG.DESCRIPTOR_MISSING\", `Extension \"${extension}\" has no descriptor for node type \"${type}\" (needed by ${what}).`, {\n\t\twhy: `Known types: ${Object.keys(ext.nodes).join(\", \")}.`,\n\t\tmeta: {\n\t\t\textension,\n\t\t\ttype\n\t\t}\n\t});\n\tif (descriptor.kind !== expectedKind) throw new CliStructuredError(\"CONFIG.DESCRIPTOR_KIND_MISMATCH\", `Extension \"${extension}\"'s descriptor for node type \"${type}\" is a \"${descriptor.kind}\" descriptor — ${what} needs a \"${expectedKind}\" descriptor.`, { meta: {\n\t\textension,\n\t\ttype,\n\t\tkind: descriptor.kind\n\t} });\n}\n/** Throws a structured CONFIG.* error on the first uncovered `(extension, type)`; silent when the config covers the whole graph. */\nfunction validateRegistryCoverage(graph, config) {\n\tconst extensions = new Map(config.extensions.map((descriptor) => [descriptor.id, descriptor]));\n\tfor (const { id, node } of graph.nodes) {\n\t\tif (node.kind === \"resource\") {\n\t\t\tlookup(extensions, node.extension, node.type, \"resource\", `resource node \"${id}\"`);\n\t\t\tcontinue;\n\t\t}\n\t\tif (node.kind !== \"service\") continue;\n\t\tlookup(extensions, node.extension, node.type, \"service\", `service node \"${id}\"`);\n\t\tlookup(extensions, node.build.extension, node.build.type, \"build\", `service node \"${id}\"'s build descriptor`);\n\t}\n}\n//#endregion\n//#region src/pipeline.ts\n/**\n* The shared prefix of `deploy`/`destroy`/`dev` (deploy-cli.md § The\n* pipeline; local-dev spec § 6): entry load, Load,\n* registry coverage validation, name resolution, assemble. Deploy and dev\n* diverge after this — deploy resolves containers/preflight/stack file\n* against the hosted providers, dev against the local ones — so everything\n* up to and including assemble lives here once, consumed verbatim by both\n* `run()` (main.ts) and `runDev()` (dev/run-dev.ts), so the two pipelines\n* cannot drift.\n*/\nconst NO_SECRETS = Object.freeze({});\nfunction configError(findings, file) {\n\tconst [first] = findings;\n\treturn new CliStructuredError(first.code, first.summary, {\n\t\t...first.why === void 0 ? {} : { why: first.why },\n\t\tfix: first.fix,\n\t\twhere: { path: first.where ?? file },\n\t\tmeta: {\n\t\t\t...first.field === void 0 ? {} : { field: first.field },\n\t\t\tfindings\n\t\t}\n\t});\n}\n/**\n* Refuses a caller's config with the same findings, in the same order, as the CLI's section validator.\n* The error is the first finding and carries all of them in `meta.findings`. Returns the config with `file` resolved against `cwd`.\n*/\nfunction checkConfigSource(source, cwd) {\n\tconst file = path.resolve(cwd, source.file);\n\tif (!fs.existsSync(file)) throw configError([configFileMissing(file)], file);\n\tconst checked = checkComposerConfig(source.value, file);\n\tif (!checked.ok) throw configError(checked.findings, file);\n\treturn {\n\t\tvalue: checked.value,\n\t\tfile\n\t};\n}\n/**\n* Resolves the entry module. An override (`--entry`, or an operation's `entry` input) resolves\n* against `cwd`; the section's `entry` resolves against the directory of the file that declares it,\n* as the CLI engine resolves path fields in prisma.config.ts.\n*/\nfunction resolveEntryPath(override, source, cwd) {\n\tif (override !== void 0) return {\n\t\tpath: path.resolve(cwd, override),\n\t\tfix: `Check the \\`--entry\\` path (the \\`entry\\` input when calling @prisma/composer/control) \"${override}\". It is relative to the current directory, ${cwd}.`\n\t};\n\tconst configured = source.value.entry;\n\tif (configured === void 0) throw configError([entryMissing], source.file);\n\treturn {\n\t\tpath: path.resolve(path.dirname(source.file), configured),\n\t\tfix: `Check \\`entry: \"${configured}\"\\` in ${source.file}. It is relative to that file's directory.`\n\t};\n}\n/**\n* The pipeline's front — entry load and name resolution —\n* WITHOUT Load, coverage, or assemble. `log` needs only who the app is (its\n* config and resolved name) to reach the already-running local instance; it\n* neither builds nor provisions, so it must not require the user's built\n* output the way the full pipeline does.\n*/\nasync function resolveAppIdentity(entry, overrideName, cwd, config) {\n\tconst checked = checkConfigSource(config, cwd);\n\tconst { value } = checked;\n\tconst resolved = resolveEntryPath(entry, checked, cwd);\n\tconst entryModule = await loadEntry(resolved.path, cwd, resolved.fix);\n\tconst name = overrideName ?? entryModule.root.name;\n\tif (name.length === 0) throw new CliStructuredError(\"COMPOSE.NAME_MISSING\", \"The root node has no name.\", { fix: \"Name it at authoring, or pass --name.\" });\n\tassertAppName(name);\n\treturn {\n\t\tconfig: value,\n\t\tname\n\t};\n}\n/**\n* Runs entry load, name resolution, Load, registry coverage, and assemble — steps 1–5 of `run()`. `onAssembleError`, when\n* given, lets a caller decorate an assemble failure with command-specific\n* guidance (destroy's \"build first\" hint) without this shared step knowing\n* about any one command.\n*/\nasync function runPipeline(entry, overrideName, environment, cwd, source, deps = {}, onAssembleError) {\n\tconst configSource = checkConfigSource(source, cwd);\n\tconst config = configSource.value;\n\tconst resolved = resolveEntryPath(entry, configSource, cwd);\n\tconst entryModule = await loadEntry(resolved.path, cwd, resolved.fix);\n\tconst name = overrideName ?? entryModule.root.name;\n\tif (name.length === 0) throw new CliStructuredError(\"COMPOSE.NAME_MISSING\", \"The root node has no name.\", { fix: \"Name it at authoring, or pass --name.\" });\n\tconst redaction = deps.redaction ?? new SecretRedaction(process.env);\n\tconst adapterInput = {\n\t\tenvironment,\n\t\tconfigFile: configSource.file\n\t};\n\tconst secrets = deps.readSecrets === true ? await readAppSecrets(config, adapterInput) : NO_SECRETS;\n\tconst configuration = await readAppConfiguration(config, adapterInput);\n\tredaction.addCredentialLookingValues(credentialLookingValues(configuration));\n\tconst graph = Load(entryModule.root, {\n\t\tid: name,\n\t\tenvironment: { name: environment },\n\t\tconfiguration\n\t});\n\tredaction.addKnownSecrets(valuesUnderSecretsKeys(configuration, secrets, secretsKeys(graph)));\n\tcheckGraph(graph, config.extensions);\n\tvalidateRegistryCoverage(graph, config);\n\tdeps.onEvent?.({ kind: \"loaded\" });\n\tlet assembled;\n\ttry {\n\t\tassembled = await assembleServices(graph, config, cwd, deps.runAssembler, deps.onEvent, { devServers: deps.devServers === true });\n\t} catch (error) {\n\t\tif (onAssembleError !== void 0 && error instanceof Error) throw onAssembleError(error);\n\t\tthrow error;\n\t}\n\treturn {\n\t\tconfigSource,\n\t\tentryModule,\n\t\tgraph,\n\t\tname,\n\t\tassembled,\n\t\tconfiguration,\n\t\tsecrets\n\t};\n}\nfunction checkGraph(graph, extensions) {\n\tfor (const extension of extensions) try {\n\t\textension.checkGraph?.(graph);\n\t} catch (error) {\n\t\tif (error instanceof GraphCheckError) throw new GraphCheckError(error.message, { extension: extension.id });\n\t\tthrow error;\n\t}\n}\n//#endregion\n//#region src/validate-environment.ts\n/** Letters, digits, `-` and `_`, starting with a letter or digit: always a valid git ref, so no `git` is needed to check it. */\nconst PLAIN_ENVIRONMENT_NAME = /^[A-Za-z0-9][A-Za-z0-9_-]*$/;\n/** An environment name must be a valid git ref (deploy-cli.md) — checked via `git check-ref-format`, never silently normalized. Runs before anything platform-specific. */\nfunction validateEnvironmentName(environment, spawn = spawnSync) {\n\tif (PLAIN_ENVIRONMENT_NAME.test(environment)) return;\n\tconst result = spawn(\"git\", [\"check-ref-format\", `refs/heads/${environment}`], { stdio: \"ignore\" });\n\tif (result.error) throw new CliStructuredError(\"DEPLOY.ENVIRONMENT_UNVALIDATABLE\", `git is required to validate --environment \"${environment}\" (git check-ref-format): ${result.error.message}.`, { cause: result.error });\n\tif (result.status !== 0) throw new CliStructuredError(\"DEPLOY.ENVIRONMENT_INVALID\", `Invalid --environment \"${environment}\": must be a valid git ref name (git check-ref-format rejected \"refs/heads/${environment}\").`);\n}\n//#endregion\nexport { runPipeline as i, checkConfigSource as n, resolveAppIdentity as r, validateEnvironmentName as t };\n\n//# sourceMappingURL=validate-environment-DCZiNSlR.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;;AAQA,IAAI,gBAAgB,cAAc,mBAAmB;CACpD,YAAY,MAAM,SAAS,SAAS;EACnC,MAAM,MAAM,SAAS,OAAO;CAC7B;AACD;;;;;;;AASA,SAAS,wBAAwB,QAAQ,MAAM,SAAS,KAAK,QAAQ;CACpE,MAAM,EAAE,WAAW,SAAS,KAAK;CACjC,MAAM,sBAAsB,OAAO,WAAW,MAAM,cAAc,UAAU,OAAO,SAAS;CAC5F,IAAI,wBAAwB,KAAK,GAAG,MAAM,IAAI,cAAc,8BAA8B,iBAAiB,UAAU,sCAAsC,KAAK,KAAK,cAAc,EAAE,KAAK,wEAAwE,CAAC;CACnQ,MAAM,iBAAiB,oBAAoB,MAAM;CACjD,IAAI,mBAAmB,KAAK,GAAG,MAAM,IAAI,cAAc,+BAA+B,cAAc,UAAU,sCAAsC,KAAK,KAAK,EAAE,KAAK,gBAAgB,OAAO,KAAK,oBAAoB,KAAK,CAAC,CAAC,KAAK,IAAI,EAAE,GAAG,CAAC;CAC3O,IAAI,eAAe,SAAS,SAAS,MA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M;CACP;CACA,OAAO;EACN;EACA;EACA;EACA;EACA;EACA;EACA;CACD;AACD;AACA,SAAS,WAAW,OAAO,YAAY;CACtC,KAAK,MAAM,aAAa,YAAY,IAAI;EACvC,UAAU,aAAa,KAAK;CAC7B,SAAS,OAAO;EACf,IAAI,iBAAiB,iBAAiB,MAAM,IAAI,gBAAgB,MAAM,SAAS,EAAE,WAAW,UAAU,GAAG,CAAC;EAC1G,MAAM;CACP;AACD;;AAIA,MAAM,yBAAyB;;AAE/B,SAAS,wBAAwB,aAAa,QAAQ,WAAW;CAChE,IAAI,uBAAuB,KAAK,WAAW,GAAG;CAC9C,MAAM,SAAS,MAAM,OAAO,CAAC,oBAAoB,cAAc,aAAa,GAAG,EAAE,OAAO,SAAS,CAAC;CAClG,IAAI,OAAO,OAAO,MAAM,IAAI,mBAAmB,oCAAoC,8CAA8C,YAAY,4BAA4B,OAAO,MAAM,QAAQ,IAAI,EAAE,OAAO,OAAO,MAAM,CAAC;CACzN,IAAI,OAAO,WAAW,GAAG,MAAM,IAAI,mBAAmB,8BAA8B,0BAA0B,YAAY,6EAA6E,YAAY,IAAI;AACxN"}
|
package/dist/zod.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { n as Pointer, o as SecretString } from "./pointer-BX2KJ720-BxcfpaHP.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
//#region ../../0-framework/0-foundation/foundation/dist/zod.d.mts
|
|
4
4
|
//#region src/zod.d.ts
|
|
@@ -14,11 +14,12 @@ import { z } from "zod";
|
|
|
14
14
|
*/
|
|
15
15
|
declare const secretString: () => z.ZodCustom<SecretString | Pointer<SecretString>, SecretString | Pointer<SecretString>>;
|
|
16
16
|
/**
|
|
17
|
-
* Wraps the schema of one
|
|
18
|
-
*
|
|
19
|
-
*
|
|
17
|
+
* Wraps the schema of one field so the field also accepts a plain pointer,
|
|
18
|
+
* which stands for a value known only at boot. The field's input type is
|
|
19
|
+
* `In | Pointer<In>` and its output type `Out | Pointer<In>`, where `In` and
|
|
20
20
|
* `Out` are `inner`'s. A value that is not a pointer gets `inner`'s error.
|
|
21
|
-
*
|
|
21
|
+
* The field holds the whole value its source supplies, which may be an object
|
|
22
|
+
* or an array.
|
|
22
23
|
*
|
|
23
24
|
* ```ts
|
|
24
25
|
* input: z.object({ from: field(z.string()), port: field(z.string().transform(Number)) })
|
package/dist/zod.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"zod.d.mts","names":[],"sources":["../../../0-framework/0-foundation/foundation/dist/zod.d.mts"],"mappings":";;;;;;;;;;;;;;cAcc,oBAAoB,EAAE,UAAU,eAAe,QAAQ,eAAe,eAAe,QAAQ
|
|
1
|
+
{"version":3,"file":"zod.d.mts","names":[],"sources":["../../../0-framework/0-foundation/foundation/dist/zod.d.mts"],"mappings":";;;;;;;;;;;;;;cAcc,oBAAoB,EAAE,UAAU,eAAe,QAAQ,eAAe,eAAe,QAAQ;;;;;;;;;;;;;iBAa1F,MAAM,UAAU,EAAE,SAAS,OAAO,IAAI,EAAE,QAAQ,EAAE,OAAO,KAAK,QAAQ,EAAE,MAAM,KAAK,EAAE,MAAM,KAAK,QAAQ,EAAE,MAAM"}
|
package/dist/zod.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as blindCast } from "./casts-DpaahrlC-C5XMnP9S.mjs";
|
|
2
|
-
import { a as isPlainPointer, o as isSecretPointer, r as isSecretString, t as describeKind } from "./describe-kind-Cpm_euxo-
|
|
2
|
+
import { a as isPlainPointer, o as isSecretPointer, r as isSecretString, t as describeKind } from "./describe-kind-Cpm_euxo-DsSPENQa.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region ../../0-framework/0-foundation/foundation/dist/zod.mjs
|
|
5
5
|
/**
|
|
@@ -19,11 +19,12 @@ import { z } from "zod";
|
|
|
19
19
|
*/
|
|
20
20
|
const secretString = () => z.custom((value) => isSecretString(value) || isSecretPointer(value), { error: (issue) => `must be a SecretString box — bind this field to a secret (was ${isPlainPointer(issue.input) ? "a value known only at boot that is not a secret" : describeKind(issue.input)})` });
|
|
21
21
|
/**
|
|
22
|
-
* Wraps the schema of one
|
|
23
|
-
*
|
|
24
|
-
*
|
|
22
|
+
* Wraps the schema of one field so the field also accepts a plain pointer,
|
|
23
|
+
* which stands for a value known only at boot. The field's input type is
|
|
24
|
+
* `In | Pointer<In>` and its output type `Out | Pointer<In>`, where `In` and
|
|
25
25
|
* `Out` are `inner`'s. A value that is not a pointer gets `inner`'s error.
|
|
26
|
-
*
|
|
26
|
+
* The field holds the whole value its source supplies, which may be an object
|
|
27
|
+
* or an array.
|
|
27
28
|
*
|
|
28
29
|
* ```ts
|
|
29
30
|
* input: z.object({ from: field(z.string()), port: field(z.string().transform(Number)) })
|
package/dist/zod.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"zod.mjs","names":[],"sources":["../../../0-framework/0-foundation/foundation/dist/zod.mjs"],"sourcesContent":["import { t as blindCast } from \"./casts-DpaahrlC.mjs\";\nimport { t as describeKind } from \"./describe-kind-Cpm_euxo.mjs\";\nimport { n as isSecretString } from \"./secret-DoWGmN7m.mjs\";\nimport { n as isPlainPointer, r as isSecretPointer } from \"./pointer-
|
|
1
|
+
{"version":3,"file":"zod.mjs","names":[],"sources":["../../../0-framework/0-foundation/foundation/dist/zod.mjs"],"sourcesContent":["import { t as blindCast } from \"./casts-DpaahrlC.mjs\";\nimport { t as describeKind } from \"./describe-kind-Cpm_euxo.mjs\";\nimport { n as isSecretString } from \"./secret-DoWGmN7m.mjs\";\nimport { n as isPlainPointer, r as isSecretPointer } from \"./pointer-B3LgR6R4.mjs\";\nimport { z } from \"zod\";\n//#region src/zod.ts\n/**\n* Zod spellings of the framework's schema leaves. Opt-in: the framework\n* accepts any Standard Schema library (ADR-0042) and nothing outside this\n* module imports zod, so an app that uses ArkType never loads it.\n*/\n/**\n* A schema leaf that accepts only a redacting `SecretString` box or a secret\n* pointer, so `input().<field>.expose()` type-checks and binding a plain\n* literal there fails the deploy (ADR-0042). Its error names the refused\n* value's kind, never the value.\n*\n* ```ts\n* input: z.object({ signingKey: secretString() })\n* ```\n*/\nconst secretString = () => z.custom((value) => isSecretString(value) || isSecretPointer(value), { error: (issue) => `must be a SecretString box — bind this field to a secret (was ${isPlainPointer(issue.input) ? \"a value known only at boot that is not a secret\" : describeKind(issue.input)})` });\n/**\n* Wraps the schema of one field so the field also accepts a plain pointer,\n* which stands for a value known only at boot. The field's input type is\n* `In | Pointer<In>` and its output type `Out | Pointer<In>`, where `In` and\n* `Out` are `inner`'s. A value that is not a pointer gets `inner`'s error.\n* The field holds the whole value its source supplies, which may be an object\n* or an array.\n*\n* ```ts\n* input: z.object({ from: field(z.string()), port: field(z.string().transform(Number)) })\n* ```\n*/\nfunction field(inner) {\n\tconst pointer = z.custom((value) => isPlainPointer(value));\n\treturn blindCast(z.union([inner, pointer], { error: (issue) => issue.code === \"invalid_union\" ? issue.errors[0]?.[0]?.message : void 0 }));\n}\n//#endregion\nexport { field, secretString };\n\n//# sourceMappingURL=zod.mjs.map"],"mappings":";;;;;;;;;;;;;;;;;;;AAqBA,MAAM,qBAAqB,EAAE,QAAQ,UAAU,eAAe,KAAK,KAAK,gBAAgB,KAAK,GAAG,EAAE,QAAQ,UAAU,iEAAiE,eAAe,MAAM,KAAK,IAAI,oDAAoD,aAAa,MAAM,KAAK,EAAE,GAAG,CAAC;;;;;;;;;;;;;AAarS,SAAS,MAAM,OAAO;CACrB,MAAM,UAAU,EAAE,QAAQ,UAAU,eAAe,KAAK,CAAC;CACzD,OAAO,UAAU,EAAE,MAAM,CAAC,OAAO,OAAO,GAAG,EAAE,QAAQ,UAAU,MAAM,SAAS,kBAAkB,MAAM,OAAO,EAAE,GAAG,EAAE,EAAE,UAAU,KAAK,EAAE,CAAC,CAAC;AAC1I"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/composer",
|
|
3
|
-
"version": "0.39.0-dev.
|
|
3
|
+
"version": "0.39.0-dev.8",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Prisma Composer — build a Prisma App by composing Modules. Core authoring, deploy pipeline, and the service-rpc/http/node/nextjs authoring surfaces. The command family the `prisma` CLI mounts lives in @prisma/composer-cli.",
|
|
6
6
|
"exports": {
|
|
@@ -53,16 +53,16 @@
|
|
|
53
53
|
}
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
|
-
"@internal/assemble": "0.39.0-dev.
|
|
57
|
-
"@internal/cli": "0.39.0-dev.
|
|
58
|
-
"@internal/core": "0.39.0-dev.
|
|
59
|
-
"@internal/foundation": "0.39.0-dev.
|
|
60
|
-
"@internal/http": "0.39.0-dev.
|
|
61
|
-
"@internal/lowering": "0.39.0-dev.
|
|
62
|
-
"@internal/nextjs": "0.39.0-dev.
|
|
63
|
-
"@internal/node": "0.39.0-dev.
|
|
64
|
-
"@internal/service-rpc": "0.39.0-dev.
|
|
65
|
-
"@internal/tsdown-config": "0.39.0-dev.
|
|
56
|
+
"@internal/assemble": "0.39.0-dev.8",
|
|
57
|
+
"@internal/cli": "0.39.0-dev.8",
|
|
58
|
+
"@internal/core": "0.39.0-dev.8",
|
|
59
|
+
"@internal/foundation": "0.39.0-dev.8",
|
|
60
|
+
"@internal/http": "0.39.0-dev.8",
|
|
61
|
+
"@internal/lowering": "0.39.0-dev.8",
|
|
62
|
+
"@internal/nextjs": "0.39.0-dev.8",
|
|
63
|
+
"@internal/node": "0.39.0-dev.8",
|
|
64
|
+
"@internal/service-rpc": "0.39.0-dev.8",
|
|
65
|
+
"@internal/tsdown-config": "0.39.0-dev.8",
|
|
66
66
|
"@types/node": "^26.0.1",
|
|
67
67
|
"tsdown": "^0.22.7",
|
|
68
68
|
"typescript": "^6.0.3",
|