@prisma/composer-cli 0.36.0-dev.2 → 0.36.0-dev.4

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 (40) hide show
  1. package/dist/config-adapters-BA_IeiX0-CiRnz7z8.mjs +590 -0
  2. package/dist/config-adapters-BA_IeiX0-CiRnz7z8.mjs.map +1 -0
  3. package/dist/{dev-current-BNoPkDRU-D_UIh9Ne.mjs → dev-current-BurA9uhA-BWYAftn9.mjs} +6 -6
  4. package/dist/{dev-current-BNoPkDRU-D_UIh9Ne.mjs.map → dev-current-BurA9uhA-BWYAftn9.mjs.map} +1 -1
  5. package/dist/{dev-environment-name-6eEr5PW8-lIZmJjfr.mjs → dev-environment-name-6eEr5PW8-YyPDRApO.mjs} +2 -2
  6. package/dist/dev-environment-name-6eEr5PW8-YyPDRApO.mjs.map +1 -0
  7. package/dist/{dist-B9-nLeho.mjs → dist-BsONwZNR.mjs} +3 -6
  8. package/dist/{dist-B9-nLeho.mjs.map → dist-BsONwZNR.mjs.map} +1 -1
  9. package/dist/{execute-deploy-destroy-BIqwt1RF-DiqyXoh9.mjs → execute-deploy-destroy-Cww6zOSC-CmOmzLiB.mjs} +50 -11
  10. package/dist/execute-deploy-destroy-Cww6zOSC-CmOmzLiB.mjs.map +1 -0
  11. package/dist/{execute-dev-DIEyloWn-CBl6TlQ0.mjs → execute-dev-4KYkqSMh-uh7gnPyS.mjs} +33 -17
  12. package/dist/{execute-dev-DIEyloWn-CBl6TlQ0.mjs.map → execute-dev-4KYkqSMh-uh7gnPyS.mjs.map} +1 -1
  13. package/dist/{execute-dev-current-CeKI-tiC-BVg5a-5b.mjs → execute-dev-current-Cd4YEUZk-b2L-LwbT.mjs} +6 -6
  14. package/dist/{execute-dev-current-CeKI-tiC-BVg5a-5b.mjs.map → execute-dev-current-Cd4YEUZk-b2L-LwbT.mjs.map} +1 -1
  15. package/dist/{family-Dy3ZQOxG-BGwHvqM_.d.mts → family-DACJfaA5-CBuEC2B3.d.mts} +166 -71
  16. package/dist/family-DACJfaA5-CBuEC2B3.d.mts.map +1 -0
  17. package/dist/family.d.mts +1 -1
  18. package/dist/family.mjs +12 -4
  19. package/dist/family.mjs.map +1 -1
  20. package/dist/{generate-dev-stack-BkkU2HLE-Dek3CkAQ.mjs → generate-dev-stack-DS6U_JHX-wDTViqdg.mjs} +9 -4
  21. package/dist/generate-dev-stack-DS6U_JHX-wDTViqdg.mjs.map +1 -0
  22. package/dist/{list-deployed-s0gjqC-r.mjs → list-deployed-CH3SMsQ4.mjs} +4 -4
  23. package/dist/{list-deployed-s0gjqC-r.mjs.map → list-deployed-CH3SMsQ4.mjs.map} +1 -1
  24. package/dist/result-sR7PBi61.mjs +229 -0
  25. package/dist/result-sR7PBi61.mjs.map +1 -0
  26. package/dist/run-alchemy-B-Z6i3cD-f0MXFCG8.mjs +219 -0
  27. package/dist/run-alchemy-B-Z6i3cD-f0MXFCG8.mjs.map +1 -0
  28. package/dist/testing.d.mts +1 -1
  29. package/dist/testing.mjs +3 -2
  30. package/dist/testing.mjs.map +1 -1
  31. package/dist/{validate-environment-CEhUSEg2-ExABehBM.mjs → validate-environment-BNZC6W46-DY_7cPQJ.mjs} +529 -169
  32. package/dist/validate-environment-BNZC6W46-DY_7cPQJ.mjs.map +1 -0
  33. package/package.json +7 -7
  34. package/dist/dev-environment-name-6eEr5PW8-lIZmJjfr.mjs.map +0 -1
  35. package/dist/execute-deploy-destroy-BIqwt1RF-DiqyXoh9.mjs.map +0 -1
  36. package/dist/family-Dy3ZQOxG-BGwHvqM_.d.mts.map +0 -1
  37. package/dist/generate-dev-stack-BkkU2HLE-Dek3CkAQ.mjs.map +0 -1
  38. package/dist/run-alchemy-Dl_MWw4g-DaWV9tkH.mjs +0 -667
  39. package/dist/run-alchemy-Dl_MWw4g-DaWV9tkH.mjs.map +0 -1
  40. package/dist/validate-environment-CEhUSEg2-ExABehBM.mjs.map +0 -1
@@ -1,10 +1,10 @@
1
- import { a as notOk, c as CliStructuredError, l as InternalError, o as ok } from "./run-alchemy-Dl_MWw4g-DaWV9tkH.mjs";
2
- import { c as toStructured } from "./dev-current-BNoPkDRU-D_UIh9Ne.mjs";
1
+ import { a as InternalError, i as CliStructuredError, n as ok, t as notOk } from "./result-sR7PBi61.mjs";
2
+ import { i as validateEnvironmentName, n as resolveAppIdentity, t as checkConfigSource } from "./validate-environment-BNZC6W46-DY_7cPQJ.mjs";
3
+ import { c as toStructured } from "./dev-current-BurA9uhA-BWYAftn9.mjs";
3
4
  import { n as devEnvironmentDir } from "./app-config-CErnR6NK-6QjHJ7q5.mjs";
4
- import { i as validateEnvironmentName, n as resolveAppIdentity, t as checkConfigSource } from "./validate-environment-CEhUSEg2-ExABehBM.mjs";
5
- import { n as requireDevEnvironmentName, r as resolveLocalTargets } from "./dev-environment-name-6eEr5PW8-lIZmJjfr.mjs";
5
+ import { n as requireDevEnvironmentName, r as resolveLocalTargets } from "./dev-environment-name-6eEr5PW8-YyPDRApO.mjs";
6
6
  import * as path from "node:path";
7
- //#region ../../0-framework/3-tooling/cli/dist/execute-dev-current-CeKI-tiC.mjs
7
+ //#region ../../0-framework/3-tooling/cli/dist/execute-dev-current-Cd4YEUZk.mjs
8
8
  /**
9
9
  * The `devUrl` and `devStop` executor: config → each extension's local
10
10
  * target → the app's local copy in the environment, read from that
@@ -161,4 +161,4 @@ async function executeDevStop(input, cwd) {
161
161
  //#endregion
162
162
  export { executeDevStop, executeDevUrl };
163
163
 
164
- //# sourceMappingURL=execute-dev-current-CeKI-tiC-BVg5a-5b.mjs.map
164
+ //# sourceMappingURL=execute-dev-current-Cd4YEUZk-b2L-LwbT.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"execute-dev-current-CeKI-tiC-BVg5a-5b.mjs","names":[],"sources":["../../../0-framework/3-tooling/cli/dist/execute-dev-current-CeKI-tiC.mjs"],"sourcesContent":["import { n as checkConfigSource, r as resolveAppIdentity, t as validateEnvironmentName } from \"./validate-environment-CEhUSEg2.mjs\";\nimport { d as toStructured } from \"./dev-current-BNoPkDRU.mjs\";\nimport { n as requireDevEnvironmentName } from \"./dev-environment-name-6eEr5PW8.mjs\";\nimport * as path from \"node:path\";\nimport { CliStructuredError, InternalError } from \"@internal/foundation/errors\";\nimport { notOk, ok } from \"@internal/foundation/result\";\nimport { devEnvironmentDir, resolveLocalTargets } from \"@internal/core/local-target\";\n//#region src/operations/execute-dev-current.ts\n/**\n* The `devUrl` and `devStop` executor: config → each extension's local\n* target → the app's local copy in the environment, read from that\n* environment's dev state. Reached only by lazy import from dev-current.ts —\n* resolving the local targets loads their descriptors, whose graphs reach\n* alchemy's provider tree.\n*/\nfunction platformUnsupported() {\n\treturn new CliStructuredError(\"DEV.PLATFORM_UNSUPPORTED\", \"local dev is not supported on Windows yet.\");\n}\n/** The `prisma dev` command that runs `environment`. */\nfunction runDev(environment) {\n\treturn environment === \"dev\" ? \"`prisma dev`\" : `\\`prisma dev --environment ${environment}\\``;\n}\n/** A call into an extension's local target; its failures that carry no code are the emulator's. */\nasync function fromTarget(call) {\n\ttry {\n\t\treturn await call();\n\t} catch (error) {\n\t\tthrow toStructured(\"DEV.EMULATOR_FAILED\", error);\n\t}\n}\n/** Every extension's record of the app in the environment; fails when none recorded it. */\nasync function currentApps(copy, cwd) {\n\tconst { app, environment } = copy;\n\tconst { value } = checkConfigSource(copy.config, cwd);\n\tconst devDir = path.join(cwd, devEnvironmentDir(environment));\n\trequireDevEnvironmentName(devDir, environment);\n\tconst apps = [];\n\tfor (const target of (await resolveLocalTargets(value)).values()) {\n\t\tconst current = await fromTarget(async () => target.current?.({\n\t\t\tdevDir,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}));\n\t\tif (current !== void 0) apps.push(current);\n\t}\n\tif (apps.length === 0) throw new CliStructuredError(\"DEV.NOT_STARTED_HERE\", `\\`prisma dev\\` has not run ${app} in the environment ${environment} in ${cwd}.`, {\n\t\twhy: `The local services, databases and buckets of an app are recorded in ${devDir} when \\`prisma dev\\` runs it in the environment ${environment}, and ${app} has no such record.`,\n\t\tfix: `Run ${runDev(environment)} for ${app} in this directory.`,\n\t\tmeta: {\n\t\t\tcwd,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}\n\t});\n\treturn apps;\n}\n/** The app a full address starts with: `shop.api` belongs to `shop`. */\nfunction appOfAddress(address) {\n\tconst dot = address.indexOf(\".\");\n\treturn dot === -1 ? address : address.slice(0, dot);\n}\nasync function locate(input, cwd) {\n\tconst environment = input.environment ?? \"dev\";\n\tvalidateEnvironmentName(environment);\n\tconst app = appOfAddress(input.address);\n\tconst apps = await currentApps({\n\t\tconfig: input.config,\n\t\tapp,\n\t\tenvironment\n\t}, cwd);\n\tconst recorded = apps.find((candidate) => candidate.addresses.includes(input.address));\n\tif (recorded === void 0) {\n\t\tconst known = apps.flatMap((candidate) => candidate.addresses).sort();\n\t\tthrow new CliStructuredError(\"DEV.ADDRESS_UNKNOWN\", `\"${app}\" has no node at \"${input.address}\" in the environment ${environment}.`, {\n\t\t\twhy: `The addresses recorded for ${app} in the environment ${environment} are: ${known.join(\", \")}.`,\n\t\t\tfix: \"Pass one of those addresses. A nested node has a dotted address, such as `shop.catalog.database`.\",\n\t\t\tmeta: {\n\t\t\t\taddress: input.address,\n\t\t\t\tknown\n\t\t\t}\n\t\t});\n\t}\n\tconst location = await fromTarget(() => recorded.locate(input.address));\n\tif (location === void 0) throw new InternalError(`the local target recorded \"${input.address}\" but cannot locate it`);\n\tif (location.emulator === \"not-running\") throw new CliStructuredError(\"DEV.EMULATOR_UNREACHABLE\", `The local ${location.kind} emulator that runs \"${input.address}\" is not running.`, {\n\t\twhy: \"The local emulators run your services, databases and buckets on this machine; `prisma dev` starts the ones an app needs.\",\n\t\tfix: `Run ${runDev(environment)} in this directory.`,\n\t\tmeta: {\n\t\t\taddress: input.address,\n\t\t\tkind: location.kind\n\t\t}\n\t});\n\tif (location.condition !== \"running\") throw notRunning(input.address, environment, location);\n\tif (location.url === void 0) throw new InternalError(`the local target reports \"${input.address}\" running with no URL`);\n\tconst runs = location.command !== void 0 ? \"dev-server\" : location.kind === \"service\" ? \"artifact\" : void 0;\n\treturn {\n\t\taddress: input.address,\n\t\tkind: location.kind,\n\t\turl: location.url,\n\t\tstate: location.state,\n\t\t...runs !== void 0 ? { runs } : {}\n\t};\n}\nfunction notRunning(address, environment, location) {\n\tconst rerun = `Run ${runDev(environment)} in this directory.`;\n\tconst { kind, state, condition, logPath } = location;\n\tconst meta = {\n\t\taddress,\n\t\tkind,\n\t\tstate,\n\t\t...logPath === void 0 ? {} : { logPath }\n\t};\n\tconst message = `The ${kind} \"${address}\" is not running (${state}).`;\n\tif (condition === \"crashing\") return new CliStructuredError(\"DEV.NOT_RUNNING\", message, {\n\t\twhy: \"It exited after it started, and it is being restarted or was held after repeated crashes.\",\n\t\tfix: logPath === void 0 ? \"Read its output in the `prisma dev` terminal, fix the cause, and rebuild.\" : `Read its log at ${logPath}, fix the cause, and rebuild.`,\n\t\tmeta\n\t});\n\tif (condition === \"missing\") return new CliStructuredError(\"DEV.NOT_RUNNING\", message, {\n\t\twhy: \"The local emulator no longer has it, for example because a Composer upgrade discarded the emulator’s state.\",\n\t\tfix: `${rerun} It creates the ${kind} again, empty.`,\n\t\tmeta\n\t});\n\treturn new CliStructuredError(\"DEV.NOT_RUNNING\", `The ${kind} \"${address}\" is stopped.`, {\n\t\twhy: \"`prisma dev stop` and `prisma dev` ending both stop an app's services and database servers, and a stopped node has no URL that answers.\",\n\t\tfix: rerun,\n\t\tmeta\n\t});\n}\nasync function executeDevUrl(input, cwd) {\n\tif (process.platform === \"win32\") return notOk(platformUnsupported());\n\ttry {\n\t\treturn ok(await locate(input, cwd));\n\t} catch (error) {\n\t\tif (CliStructuredError.is(error)) return notOk(error);\n\t\tthrow error;\n\t}\n}\nasync function executeDevStop(input, cwd) {\n\tif (process.platform === \"win32\") return notOk(platformUnsupported());\n\ttry {\n\t\tconst environment = input.environment ?? \"dev\";\n\t\tvalidateEnvironmentName(environment);\n\t\tconst { name: app } = await resolveAppIdentity(input.entry, input.name, cwd, input.config);\n\t\tconst apps = await currentApps({\n\t\t\tconfig: input.config,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}, cwd);\n\t\tconst stopped = [];\n\t\tfor (const recorded of apps) stopped.push(...await fromTarget(() => recorded.stop()));\n\t\treturn ok({\n\t\t\tapp,\n\t\t\tenvironment,\n\t\t\tstopped\n\t\t});\n\t} catch (error) {\n\t\tif (CliStructuredError.is(error)) return notOk(error);\n\t\tthrow error;\n\t}\n}\n//#endregion\nexport { executeDevStop, executeDevUrl };\n\n//# sourceMappingURL=execute-dev-current-CeKI-tiC.mjs.map"],"mappings":";;;;;;;;;;;;;;AAeA,SAAS,sBAAsB;CAC9B,OAAO,IAAI,mBAAmB,4BAA4B,4CAA4C;AACvG;;AAEA,SAAS,OAAO,aAAa;CAC5B,OAAO,gBAAgB,QAAQ,iBAAiB,8BAA8B,YAAY;AAC3F;;AAEA,eAAe,WAAW,MAAM;CAC/B,IAAI;EACH,OAAO,MAAM,KAAK;CACnB,SAAS,OAAO;EACf,MAAM,aAAa,uBAAuB,KAAK;CAChD;AACD;;AAEA,eAAe,YAAY,MAAM,KAAK;CACrC,MAAM,EAAE,KAAK,gBAAgB;CAC7B,MAAM,EAAE,UAAU,kBAAkB,KAAK,QAAQ,GAAG;CACpD,MAAM,SAAS,KAAK,KAAK,KAAK,kBAAkB,WAAW,CAAC;CAC5D,0BAA0B,QAAQ,WAAW;CAC7C,MAAM,OAAO,CAAC;CACd,KAAK,MAAM,WAAW,MAAM,oBAAoB,KAAK,EAAA,CAAG,OAAO,GAAG;EACjE,MAAM,UAAU,MAAM,WAAW,YAAY,OAAO,UAAU;GAC7D;GACA;GACA;EACD,CAAC,CAAC;EACF,IAAI,YAAY,KAAK,GAAG,KAAK,KAAK,OAAO;CAC1C;CACA,IAAI,KAAK,WAAW,GAAG,MAAM,IAAI,mBAAmB,wBAAwB,8BAA8B,IAAI,sBAAsB,YAAY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AG,KAAK,GAAG,OAAO,MAAM,KAAK;EACpD,MAAM;CACP;AACD;AACA,eAAe,eAAe,OAAO,KAAK;CACzC,IAAI,QAAQ,aAAa,SAAS,OAAO,MAAM,oBAAoB,CAAC;CACpE,IAAI;EACH,MAAM,cAAc,MAAM,eAAe;EACzC,wBAAwB,WAAW;EACnC,MAAM,EAAE,MAAM,QAAQ,MAAM,mBAAmB,MAAM,OAAO,MAAM,MAAM,KAAK,MAAM,MAAM;EACzF,MAAM,OAAO,MAAM,YAAY;GAC9B,QAAQ,MAAM;GACd;GACA;EACD,GAAG,GAAG;EACN,MAAM,UAAU,CAAC;EACjB,KAAK,MAAM,YAAY,MAAM,QAAQ,KAAK,GAAG,MAAM,iBAAiB,SAAS,KAAK,CAAC,CAAC;EACpF,OAAO,GAAG;GACT;GACA;GACA;EACD,CAAC;CACF,SAAS,OAAO;EACf,IAAI,mBAAmB,GAAG,KAAK,GAAG,OAAO,MAAM,KAAK;EACpD,MAAM;CACP;AACD"}
1
+ {"version":3,"file":"execute-dev-current-Cd4YEUZk-b2L-LwbT.mjs","names":[],"sources":["../../../0-framework/3-tooling/cli/dist/execute-dev-current-Cd4YEUZk.mjs"],"sourcesContent":["import { n as checkConfigSource, r as resolveAppIdentity, t as validateEnvironmentName } from \"./validate-environment-BNZC6W46.mjs\";\nimport { d as toStructured } from \"./dev-current-BurA9uhA.mjs\";\nimport { n as requireDevEnvironmentName } from \"./dev-environment-name-6eEr5PW8.mjs\";\nimport * as path from \"node:path\";\nimport { CliStructuredError, InternalError } from \"@internal/foundation/errors\";\nimport { notOk, ok } from \"@internal/foundation/result\";\nimport { devEnvironmentDir, resolveLocalTargets } from \"@internal/core/local-target\";\n//#region src/operations/execute-dev-current.ts\n/**\n* The `devUrl` and `devStop` executor: config → each extension's local\n* target → the app's local copy in the environment, read from that\n* environment's dev state. Reached only by lazy import from dev-current.ts —\n* resolving the local targets loads their descriptors, whose graphs reach\n* alchemy's provider tree.\n*/\nfunction platformUnsupported() {\n\treturn new CliStructuredError(\"DEV.PLATFORM_UNSUPPORTED\", \"local dev is not supported on Windows yet.\");\n}\n/** The `prisma dev` command that runs `environment`. */\nfunction runDev(environment) {\n\treturn environment === \"dev\" ? \"`prisma dev`\" : `\\`prisma dev --environment ${environment}\\``;\n}\n/** A call into an extension's local target; its failures that carry no code are the emulator's. */\nasync function fromTarget(call) {\n\ttry {\n\t\treturn await call();\n\t} catch (error) {\n\t\tthrow toStructured(\"DEV.EMULATOR_FAILED\", error);\n\t}\n}\n/** Every extension's record of the app in the environment; fails when none recorded it. */\nasync function currentApps(copy, cwd) {\n\tconst { app, environment } = copy;\n\tconst { value } = checkConfigSource(copy.config, cwd);\n\tconst devDir = path.join(cwd, devEnvironmentDir(environment));\n\trequireDevEnvironmentName(devDir, environment);\n\tconst apps = [];\n\tfor (const target of (await resolveLocalTargets(value)).values()) {\n\t\tconst current = await fromTarget(async () => target.current?.({\n\t\t\tdevDir,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}));\n\t\tif (current !== void 0) apps.push(current);\n\t}\n\tif (apps.length === 0) throw new CliStructuredError(\"DEV.NOT_STARTED_HERE\", `\\`prisma dev\\` has not run ${app} in the environment ${environment} in ${cwd}.`, {\n\t\twhy: `The local services, databases and buckets of an app are recorded in ${devDir} when \\`prisma dev\\` runs it in the environment ${environment}, and ${app} has no such record.`,\n\t\tfix: `Run ${runDev(environment)} for ${app} in this directory.`,\n\t\tmeta: {\n\t\t\tcwd,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}\n\t});\n\treturn apps;\n}\n/** The app a full address starts with: `shop.api` belongs to `shop`. */\nfunction appOfAddress(address) {\n\tconst dot = address.indexOf(\".\");\n\treturn dot === -1 ? address : address.slice(0, dot);\n}\nasync function locate(input, cwd) {\n\tconst environment = input.environment ?? \"dev\";\n\tvalidateEnvironmentName(environment);\n\tconst app = appOfAddress(input.address);\n\tconst apps = await currentApps({\n\t\tconfig: input.config,\n\t\tapp,\n\t\tenvironment\n\t}, cwd);\n\tconst recorded = apps.find((candidate) => candidate.addresses.includes(input.address));\n\tif (recorded === void 0) {\n\t\tconst known = apps.flatMap((candidate) => candidate.addresses).sort();\n\t\tthrow new CliStructuredError(\"DEV.ADDRESS_UNKNOWN\", `\"${app}\" has no node at \"${input.address}\" in the environment ${environment}.`, {\n\t\t\twhy: `The addresses recorded for ${app} in the environment ${environment} are: ${known.join(\", \")}.`,\n\t\t\tfix: \"Pass one of those addresses. A nested node has a dotted address, such as `shop.catalog.database`.\",\n\t\t\tmeta: {\n\t\t\t\taddress: input.address,\n\t\t\t\tknown\n\t\t\t}\n\t\t});\n\t}\n\tconst location = await fromTarget(() => recorded.locate(input.address));\n\tif (location === void 0) throw new InternalError(`the local target recorded \"${input.address}\" but cannot locate it`);\n\tif (location.emulator === \"not-running\") throw new CliStructuredError(\"DEV.EMULATOR_UNREACHABLE\", `The local ${location.kind} emulator that runs \"${input.address}\" is not running.`, {\n\t\twhy: \"The local emulators run your services, databases and buckets on this machine; `prisma dev` starts the ones an app needs.\",\n\t\tfix: `Run ${runDev(environment)} in this directory.`,\n\t\tmeta: {\n\t\t\taddress: input.address,\n\t\t\tkind: location.kind\n\t\t}\n\t});\n\tif (location.condition !== \"running\") throw notRunning(input.address, environment, location);\n\tif (location.url === void 0) throw new InternalError(`the local target reports \"${input.address}\" running with no URL`);\n\tconst runs = location.command !== void 0 ? \"dev-server\" : location.kind === \"service\" ? \"artifact\" : void 0;\n\treturn {\n\t\taddress: input.address,\n\t\tkind: location.kind,\n\t\turl: location.url,\n\t\tstate: location.state,\n\t\t...runs !== void 0 ? { runs } : {}\n\t};\n}\nfunction notRunning(address, environment, location) {\n\tconst rerun = `Run ${runDev(environment)} in this directory.`;\n\tconst { kind, state, condition, logPath } = location;\n\tconst meta = {\n\t\taddress,\n\t\tkind,\n\t\tstate,\n\t\t...logPath === void 0 ? {} : { logPath }\n\t};\n\tconst message = `The ${kind} \"${address}\" is not running (${state}).`;\n\tif (condition === \"crashing\") return new CliStructuredError(\"DEV.NOT_RUNNING\", message, {\n\t\twhy: \"It exited after it started, and it is being restarted or was held after repeated crashes.\",\n\t\tfix: logPath === void 0 ? \"Read its output in the `prisma dev` terminal, fix the cause, and rebuild.\" : `Read its log at ${logPath}, fix the cause, and rebuild.`,\n\t\tmeta\n\t});\n\tif (condition === \"missing\") return new CliStructuredError(\"DEV.NOT_RUNNING\", message, {\n\t\twhy: \"The local emulator no longer has it, for example because a Composer upgrade discarded the emulator’s state.\",\n\t\tfix: `${rerun} It creates the ${kind} again, empty.`,\n\t\tmeta\n\t});\n\treturn new CliStructuredError(\"DEV.NOT_RUNNING\", `The ${kind} \"${address}\" is stopped.`, {\n\t\twhy: \"`prisma dev stop` and `prisma dev` ending both stop an app's services and database servers, and a stopped node has no URL that answers.\",\n\t\tfix: rerun,\n\t\tmeta\n\t});\n}\nasync function executeDevUrl(input, cwd) {\n\tif (process.platform === \"win32\") return notOk(platformUnsupported());\n\ttry {\n\t\treturn ok(await locate(input, cwd));\n\t} catch (error) {\n\t\tif (CliStructuredError.is(error)) return notOk(error);\n\t\tthrow error;\n\t}\n}\nasync function executeDevStop(input, cwd) {\n\tif (process.platform === \"win32\") return notOk(platformUnsupported());\n\ttry {\n\t\tconst environment = input.environment ?? \"dev\";\n\t\tvalidateEnvironmentName(environment);\n\t\tconst { name: app } = await resolveAppIdentity(input.entry, input.name, cwd, input.config);\n\t\tconst apps = await currentApps({\n\t\t\tconfig: input.config,\n\t\t\tapp,\n\t\t\tenvironment\n\t\t}, cwd);\n\t\tconst stopped = [];\n\t\tfor (const recorded of apps) stopped.push(...await fromTarget(() => recorded.stop()));\n\t\treturn ok({\n\t\t\tapp,\n\t\t\tenvironment,\n\t\t\tstopped\n\t\t});\n\t} catch (error) {\n\t\tif (CliStructuredError.is(error)) return notOk(error);\n\t\tthrow error;\n\t}\n}\n//#endregion\nexport { executeDevStop, executeDevUrl };\n\n//# sourceMappingURL=execute-dev-current-Cd4YEUZk.mjs.map"],"mappings":";;;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,KAAK,GAAG,MAAM,iBAAiB,SAAS,KAAK,CAAC,CAAC;EACpF,OAAO,GAAG;GACT;GACA;GACA;EACD,CAAC;CACF,SAAS,OAAO;EACf,IAAI,mBAAmB,GAAG,KAAK,GAAG,OAAO,MAAM,KAAK;EACpD,MAAM;CACP;AACD"}
@@ -81,6 +81,36 @@ declare class CliStructuredError extends Error implements StructuredError {
81
81
  static is(error: unknown): error is CliStructuredError;
82
82
  }
83
83
  //#endregion
84
+ //#region ../../0-framework/0-foundation/foundation/dist/secret-CHOw4LBU.d.mts
85
+ //#region src/secret.d.ts
86
+ declare const SECRET_BOX: unique symbol;
87
+ declare class SecretBox<T> {
88
+ #private;
89
+ readonly [SECRET_BOX] = true;
90
+ constructor(value: T);
91
+ /** The sole explicit door to the wrapped value. */
92
+ expose(): T;
93
+ toString(): string;
94
+ toJSON(): string;
95
+ valueOf(): string;
96
+ [Symbol.toPrimitive](): string;
97
+ }
98
+ /** The common case: a secret string. */
99
+ type SecretString = SecretBox<string>;
100
+ //#endregion
101
+ //#region ../../0-framework/0-foundation/foundation/dist/pointer-CyQZZugO.d.mts
102
+ //#region src/pointer.d.ts
103
+ declare const POINTER: unique symbol;
104
+ declare const POINTER_TYPE: unique symbol;
105
+ /** Whether the variable a pointer names holds a secret. */
106
+ type PointerKind = 'secret' | 'plain';
107
+ interface PointerWithKind<T, K extends PointerKind> {
108
+ readonly [POINTER]: K;
109
+ readonly [POINTER_TYPE]?: T;
110
+ }
111
+ /** The real value at deploy of a value known only at boot: it names the platform variable that holds the text of a `T`. Its kind is `'secret'` when `T` is a `SecretString` and `'plain'` otherwise. */
112
+ type Pointer<T> = PointerWithKind<T, unknown extends T ? PointerKind : T extends SecretString ? 'secret' : 'plain'>;
113
+ //#endregion
84
114
  //#region ../../../node_modules/@standard-schema/spec/dist/index.d.ts
85
115
  /** The Standard Typed interface. This is a base type extended by other specs. */
86
116
  interface StandardTypedV1<Input = unknown, Output = Input> {
@@ -158,7 +188,7 @@ declare namespace StandardSchemaV1 {
158
188
  type InferOutput<Schema extends StandardTypedV1> = StandardTypedV1.InferOutput<Schema>;
159
189
  }
160
190
  //#endregion
161
- //#region ../../0-framework/1-core/core/dist/graph-types-DfsG9Rkg.d.mts
191
+ //#region ../../0-framework/1-core/core/dist/graph-types-R38xjBnN.d.mts
162
192
  //#region src/contract.d.ts
163
193
  /**
164
194
  * A Contract is the declared interface of a service-to-service dependency: a
@@ -239,18 +269,34 @@ type ValueOrigin<T> = {
239
269
  readonly kind: 'computed';
240
270
  readonly dependencies: readonly Value<unknown>[];
241
271
  readonly compute: (values: readonly unknown[]) => T;
272
+ } | {
273
+ readonly kind: 'input';
274
+ /** The address of the module whose input this field is. */
275
+ readonly module: string;
276
+ /** The key path inside that module's input; `[]` is the whole input. */
277
+ readonly path: readonly string[];
278
+ } | {
279
+ readonly kind: 'source';
280
+ /** How an error names the source, e.g. `envSecret('STRIPE_KEY')`. */
281
+ readonly label: string;
282
+ /** The config pool key whose value at deploy is the real value, as for `envParam()`. `undefined` for a value known only at boot, whose real value is `source`, a pointer. */
283
+ readonly poolKey: string | undefined;
284
+ /** The source itself. Not enumerable, so a copy's origin compares equal and the origin holds no cycle. */
285
+ readonly source: ParamSource | SecretSource;
242
286
  };
243
287
  /**
244
- * An opaque stand-in a module body can pass wherever a `T` is accepted; its
245
- * real value is known by the end of Load (ADR-0062). `environment.name` is one;
246
- * `resolve()` returns one computed from others.
288
+ * An opaque stand-in a module body can pass wherever a `T` is accepted
289
+ * (ADR-0062). `environment.name` is one; each field of a module's `input` is
290
+ * one; `resolve()` returns one computed from others; a deploy target's source,
291
+ * such as `envParam()` or `envSecret()`, is one too. A deploy-time value's real
292
+ * value is known by the end of Load; a runtime value's real value at deploy is a pointer.
247
293
  */
248
294
  interface Value<T> {
249
295
  readonly [VALUE]: true;
250
296
  readonly [VALUE_TYPE]?: T;
251
297
  readonly [VALUE_ORIGIN]: ValueOrigin<T>;
252
298
  }
253
- /** Plain data: what a `resolve()` function may return, and the only thing a value may stand for in a binding. */
299
+ /** Plain data: what a `resolve()` function may return. */
254
300
  type PlainData = string | number | boolean | null | readonly PlainData[] | {
255
301
  readonly [key: string]: PlainData;
256
302
  };
@@ -260,25 +306,30 @@ interface EnvironmentFacts {
260
306
  readonly name: Value<string>;
261
307
  }
262
308
  //#endregion
309
+ //#region src/module-input.d.ts
310
+ type PlainObject = {
311
+ readonly [key: string]: unknown;
312
+ };
313
+ /**
314
+ * What a module body holds for an input field whose real value has type `T`:
315
+ * a value, plus one `ModuleInputField` per key when `T` is a plain object.
316
+ */
317
+ type ModuleInputField<T> = Value<T> & FieldsOf<T>;
318
+ type FieldsOf<T> = [NonNullable<T>] extends [never] ? unknown : [NonNullable<T>] extends [readonly unknown[]] ? unknown : [NonNullable<T>] extends [PlainObject] ? Fields<NonNullable<T>, undefined extends T ? undefined : never> : unknown;
319
+ type Fields<O, Absent> = { readonly [K in keyof O & string]-?: ModuleInputField<FieldType<O, K> | Absent>; };
320
+ type FieldType<O, K extends keyof O> = Record<never, never> extends Pick<O, K> ? O[K] | undefined : O[K];
321
+ /** The `input` a module body receives for its input schema `S`: one value per field, typed from the schema's output (ADR-0061). */
322
+ type ModuleInput<S extends StandardSchemaV1> = ModuleInputField<StandardSchemaV1.InferOutput<S>>;
323
+ //#endregion
263
324
  //#region src/node.d.ts
264
325
  declare const NODE: unique symbol;
265
- declare const SECRET_NEED: unique symbol;
266
326
  declare const SECRET_SOURCE: unique symbol;
267
- /** A declared secret input slot — nameless; the root binds it and the topology forwards it in. */
268
- interface SecretNeed {
269
- readonly [SECRET_NEED]: true;
270
- readonly kind: 'secret';
271
- }
272
- /** A module's secret-forwarding slots: name → the need it declares. */
273
- type Secrets = Record<string, SecretNeed>;
274
- /** The wiring value bound to a secret slot: a target-defined payload core forwards but never inspects. A target (e.g. @prisma/composer-prisma-cloud's `envSecret`) builds one via `secretSource()`. */
275
- interface SecretSource<T = unknown> {
327
+ /** A secret's source: a target-defined payload core forwards but never inspects. It is a value too, known only at boot; its real value at deploy is the source itself, a secret pointer. A target (e.g. @prisma/composer-prisma-cloud's `envSecret`) builds one with `secretSource()`. */
328
+ interface SecretSource<T = unknown> extends Value<unknown> {
276
329
  readonly [SECRET_SOURCE]: true;
277
330
  /** Target-defined. Core never reads this; the target that authored the source reads it back. */
278
331
  readonly payload: T;
279
332
  }
280
- /** What `provision(moduleChild, { secrets })` supplies: one source per declared secret slot. */
281
- type SecretBindings<S extends Secrets> = { [K in keyof S]: SecretSource; };
282
333
  declare const PROVISION_NEED: unique symbol;
283
334
  /** A param value the framework mints. Opaque to core: it forwards the payload to the resolved provisioner and never reads it (ADR-0031). */
284
335
  interface ProvisionNeed<T = unknown> {
@@ -289,24 +340,18 @@ interface ProvisionNeed<T = unknown> {
289
340
  readonly payload: T;
290
341
  }
291
342
  declare const PARAM_SOURCE: unique symbol;
292
- declare const PARAM_NEED: unique symbol;
293
- /** The wiring value bound to a param at provision time: a target-defined payload core forwards but never inspects. A target (e.g. @prisma/composer-prisma-cloud's `envParam`) builds one via `paramSource()`. */
294
- interface ParamSource<T = unknown> {
343
+ /** A param's source: a target-defined payload core forwards but never inspects. It is a value too: known at deploy when it names a config pool key (`envParam`), otherwise known only at boot, with the source itself as its real value: a secret pointer when it is redacted, a plain pointer otherwise. A target builds one with `paramSource()`. */
344
+ interface ParamSource<T = unknown> extends Value<unknown> {
295
345
  readonly [PARAM_SOURCE]: true;
296
346
  /** Target-defined. Core never reads this; the target that authored the source reads it back. */
297
347
  readonly payload: T;
298
348
  }
299
- /** A module's declared param-forwarding slot — nameless, schema-less; the root (or an ancestor module) binds a `ParamSource` and the topology forwards it into a child's real, schema-bearing param. */
300
- interface ParamNeed {
301
- readonly [PARAM_NEED]: true;
302
- readonly kind: 'param';
303
- }
304
- /** A module's param-forwarding slots: name → the need it declares. */
305
- type ParamNeeds = Record<string, ParamNeed>;
306
349
  /** What `provision(service, { params })` accepts per declared param: a literal (schema-validated when config is built) or an opaque `ParamSource`, taking precedence over `param.default`. Every entry is optional — an unbound param falls back to its `default`. */
307
350
  type ParamBindings<P extends Params> = { readonly [K in keyof P]?: StandardSchemaV1.InferOutput<P[K]['schema']> | ParamSource | (StandardSchemaV1.InferOutput<P[K]['schema']> extends PlainData ? Value<StandardSchemaV1.InferOutput<P[K]['schema']>> : never); };
308
- /** What `provision(moduleChild, { params })` accepts per declared `ParamNeed`: a `ParamSource` only — a need carries no schema to validate a literal against. */
309
- type ParamNeedBindings<PN extends ParamNeeds> = { readonly [K in keyof PN]?: ParamSource; };
351
+ /** What a value in a service's input binding may stand for: plain data, a `SecretString` at any depth (a forwarded secret field), a pointer (a forwarded wrapped field), and `undefined` (an optional field the binding left out). */
352
+ type InputBindingData = string | number | boolean | null | undefined | SecretString | Pointer<unknown> | readonly InputBindingData[] | {
353
+ readonly [key: string]: InputBindingData;
354
+ };
310
355
  /**
311
356
  * What `provision(service, { input })` accepts (ADR-0042): a plain object
312
357
  * mirroring the service's input schema, whose leaves are literals,
@@ -315,9 +360,20 @@ type ParamNeedBindings<PN extends ParamNeeds> = { readonly [K in keyof PN]?: Par
315
360
  * Schema, so the binding's exact shape cannot be derived from it — deploy-time
316
361
  * validation of the resolved binding is the real check.
317
362
  */
318
- type InputBinding = string | number | boolean | null | ParamSource | SecretSource | Value<PlainData> | readonly InputBinding[] | {
363
+ type InputBinding = string | number | boolean | null | ParamSource | SecretSource | Value<InputBindingData> | readonly InputBinding[] | {
319
364
  readonly [key: string]: InputBinding;
320
365
  };
366
+ /**
367
+ * What `provision(module, { input })` accepts where the module's input schema
368
+ * expects `T` (its Standard Schema input type): the data, a value standing for
369
+ * it, or, for a `SecretString` field, a secret source. An optional key also
370
+ * takes a value that may stand for `undefined`.
371
+ */
372
+ type ModuleInputBinding<T> = Value<T> | (T extends SecretString ? SecretSource : T extends readonly (infer E)[] ? T | readonly ModuleInputBinding<E>[] : T extends {
373
+ readonly [key: string]: unknown;
374
+ } ? { readonly [K in keyof T]: ModuleInputBinding<T[K]> | (Record<never, never> extends Pick<T, K> ? Value<T[K] | undefined> : never); } : T);
375
+ /** A module input schema's Standard Schema input type. */
376
+ type ModuleInputOf<I extends StandardSchemaV1 | undefined> = StandardSchemaV1.InferInput<NonNullable<I>>;
321
377
  /** Opaque `Contract<any, any>` bound shared by every node/port type that doesn't care which contract. */
322
378
  type AnyContract = Contract<any, any>;
323
379
  /** How a service's app becomes a runnable artifact — the build descriptor's routing key (`extension`/`type`) plus paths resolved relative to the authoring module. */
@@ -400,30 +456,26 @@ interface DependencyEnd<C = unknown, Req = unknown> {
400
456
  readonly required: Req | undefined;
401
457
  }
402
458
  /** A Module: the same Deps/Expose boundary a service has, around transparent wiring instead of a black-box body — its `body` runs at Load, not at authoring. */
403
- interface ModuleNode<D extends Deps = Deps, E extends Expose = Expose, S extends Secrets = Secrets, PN extends ParamNeeds = ParamNeeds> {
459
+ interface ModuleNode<D extends Deps = Deps, E extends Expose = Expose, I extends StandardSchemaV1 | undefined = StandardSchemaV1 | undefined> {
404
460
  readonly [NODE]: true;
405
461
  readonly kind: 'module';
406
462
  /** Human-readable, given at authoring — logs/diagnostics only. */
407
463
  readonly name: string;
408
464
  readonly deps: D;
409
- /** Declared secret input slots (authored as `secrets`) — forwarded to internals via `ctx.secrets` (ADR-0029). */
410
- readonly secretSlots: S;
411
- /** Declared param-forwarding slots (authored as `params`) — forwarded to internals via `ctx.params`, the same rail secrets ride on. */
412
- readonly paramSlots: PN;
465
+ /** The module's whole incoming configuration as one Standard Schema (authored as `input`, ADR-0061), or `undefined` when it takes none. Load only calls its `~standard.validate`. */
466
+ readonly inputSchema: I;
413
467
  readonly expose: E;
414
- body(ctx: ModuleContext<D, S, PN>): ModuleOutputs<E> | void;
468
+ body(ctx: ModuleContext<D, I>): ModuleOutputs<E> | void;
415
469
  }
416
470
  /**
417
471
  * What a module's body receives: its declared dependencies as forwardable wiring
418
472
  * values, plus `provision` to register the owned services/modules it wires them into.
419
473
  */
420
- interface ModuleContext<D extends Deps, S extends Secrets = Secrets, PN extends ParamNeeds = ParamNeeds> {
474
+ interface ModuleContext<D extends Deps, I extends StandardSchemaV1 | undefined = StandardSchemaV1 | undefined> {
421
475
  /** The module's declared dependencies as wiring values — pass them into provision(). */
422
476
  readonly deps: { [K in keyof D]: InputRef<D[K]>; };
423
- /** The module's declared secret slots as forwardable sources — pass them into a child's `secrets` (ADR-0029). */
424
- readonly secrets: { readonly [K in keyof S]: SecretSource; };
425
- /** The module's declared param-forwarding slots as forwardable sources — pass them into a child's `params`. */
426
- readonly params: { readonly [K in keyof PN]: ParamSource; };
477
+ /** The module's input: one value per field, typed from its input schema's output (ADR-0061); `undefined` when it declares none. A root's input is the config pool, validated by its schema; a root passes on its fields one by one, never its whole input. Pass a field into a provision() binding or list it as a resolve() dependency. */
478
+ readonly input: I extends StandardSchemaV1 ? ModuleInput<I> : undefined;
427
479
  /** The deploy-time facts of the environment, each a value (ADR-0062). List `environment.name` as a `resolve()` dependency. Never environment variables: user code never reads those. */
428
480
  readonly environment: EnvironmentFacts;
429
481
  /** Registers an owned child (service or module) under a stable id. */
@@ -488,27 +540,18 @@ type ServiceProvisionArgs<D extends Deps, I extends StandardSchemaV1 | undefined
488
540
  params?: PB;
489
541
  }];
490
542
  /**
491
- * A child-MODULE provision's trailing options: `deps`/`secrets` required
492
- * exactly when the module declares the slots; a declared param-forwarding
493
- * slot may be bound to a `ParamSource`.
543
+ * A child-MODULE provision's trailing options: `deps` and `input` each
544
+ * required exactly when the module declares them.
494
545
  */
495
- type ModuleProvisionArgs<D extends Deps, S extends Secrets, PB> = [keyof D] extends [never] ? [keyof S] extends [never] ? [opts?: {
496
- id?: string;
497
- params?: PB;
498
- }] : [opts: {
499
- id?: string;
500
- secrets: SecretBindings<S>;
501
- params?: PB;
502
- }] : [keyof S] extends [never] ? [opts: {
546
+ type ModuleProvisionOptions<D extends Deps, I extends StandardSchemaV1 | undefined> = {
503
547
  id?: string;
548
+ } & ([keyof D] extends [never] ? unknown : {
504
549
  deps: DepBindings<D>;
505
- params?: PB;
506
- }] : [opts: {
507
- id?: string;
508
- deps: DepBindings<D>;
509
- secrets: SecretBindings<S>;
510
- params?: PB;
511
- }];
550
+ }) & ([I] extends [StandardSchemaV1] ? {
551
+ input: ModuleInputBinding<ModuleInputOf<I>>;
552
+ } : unknown);
553
+ /** The options are optional exactly when nothing is required. */
554
+ type ModuleProvisionArgs<D extends Deps, I extends StandardSchemaV1 | undefined> = [keyof D] extends [never] ? [I] extends [StandardSchemaV1] ? [opts: ModuleProvisionOptions<D, I>] : [opts?: ModuleProvisionOptions<D, I>] : [opts: ModuleProvisionOptions<D, I>];
512
555
  interface ModuleBuilder {
513
556
  /** Provisions an owned resource; its id defaults to the node's `name`. */
514
557
  provision<C extends AnyContract | undefined>(resource: ResourceNode<C>, opts?: {
@@ -530,14 +573,13 @@ interface ModuleBuilder {
530
573
  input?: InputBinding;
531
574
  params?: ParamBindings<P>;
532
575
  }): ProvisionedRef<E>;
533
- /** Registers an owned child module; its id defaults to the node's `name`; `deps`/`secrets` are required iff it declares them; a declared param-forwarding slot may be bound to a `ParamSource`. */
534
- provision<D extends Deps, E extends Expose, S extends Secrets, PN extends ParamNeeds>(child: ModuleNode<D, E, S, PN>, ...args: ModuleProvisionArgs<D, S, ParamNeedBindings<PN>>): ProvisionedRef<E>;
535
- /** The child-module call with `deps`/`secrets` spelled out — the same generic-wrapper escape as the service overload above. */
536
- provision<D extends Deps, E extends Expose, S extends Secrets, PN extends ParamNeeds>(child: ModuleNode<D, E, S, PN>, opts: {
576
+ /** Registers an owned child module; its id defaults to the node's `name`; `deps` and `input` are required iff it declares them. */
577
+ provision<D extends Deps, E extends Expose, I extends StandardSchemaV1 | undefined>(child: ModuleNode<D, E, I>, ...args: ModuleProvisionArgs<D, I>): ProvisionedRef<E>;
578
+ /** The child-module call with `deps` spelled out — the same generic-wrapper escape as the service overload above. */
579
+ provision<D extends Deps, E extends Expose, I extends StandardSchemaV1 | undefined>(child: ModuleNode<D, E, I>, opts: {
537
580
  id?: string;
538
581
  deps: DepBindings<D>;
539
- secrets?: SecretBindings<S>;
540
- params?: ParamNeedBindings<PN>;
582
+ input?: ModuleInputBinding<ModuleInputOf<I>>;
541
583
  }): ProvisionedRef<E>;
542
584
  }
543
585
  /** Dependency map: name → the slot the service declares. Only declarations are admitted, never a concrete ResourceNode. */
@@ -630,6 +672,15 @@ interface ParamBinding {
630
672
  /** A literal value (schema-validated by `buildConfig`) or an opaque `ParamSource` (the deploy target reads its own payload back) — check with `isParamSource`. Core never inspects a `ParamSource`'s payload. */
631
673
  readonly binding: unknown;
632
674
  }
675
+ /** A secret source a binding in the graph names, wherever it sits (ADR-0029). Deploy preflight checks every one, including one in a module's input that no service receives. */
676
+ interface SecretSourceUse {
677
+ /** The source, as its target built it. Core never reads its payload. */
678
+ readonly source: SecretSource;
679
+ /** A service whose final binding holds it, if one does. Otherwise the module whose input holds it. */
680
+ readonly address: NodeId;
681
+ /** That node's kind. */
682
+ readonly nodeKind: 'service' | 'module' | 'resource';
683
+ }
633
684
  interface Graph {
634
685
  readonly root: GraphNode;
635
686
  /** Root + one per input, topo-ordered (deps first). */
@@ -643,9 +694,11 @@ interface Graph {
643
694
  readonly inputBindings: readonly ServiceInputBinding[];
644
695
  /** Every service param bound at provision — literal or source; unbound params are absent here and fall back to their `default` (see `buildConfig`). */
645
696
  readonly params: readonly ParamBinding[];
697
+ /** Every secret source a binding names, once each, in the order Load met them (ADR-0029). */
698
+ readonly secretSources: readonly SecretSourceUse[];
646
699
  }
647
700
  //#endregion
648
- //#region ../../0-framework/1-core/core/dist/app-config-CWm3wlNA.d.mts
701
+ //#region ../../0-framework/1-core/core/dist/app-config-BvxeTt2h.d.mts
649
702
  //#region src/container-transport.d.ts
650
703
  /**
651
704
  * Carries resolved containers from the CLI process into the alchemy process
@@ -889,6 +942,8 @@ interface LowerOptions {
889
942
  readonly name: string;
890
943
  /** The environment being deployed, as `--environment` gave it. Required by any value over `environment.name`; the generated stack files always pass it. */
891
944
  readonly environment?: string;
945
+ /** The config pool Load reads a source's pool key and the root's input from, and the Prisma Cloud serializer reads a service's envParam() leaves from. The generated stack files pass what readConfigPool() returns. */
946
+ readonly configPool?: Readonly<Record<string, unknown>>;
892
947
  readonly bundles: Record<string, Bundle>;
893
948
  /** Alchemy state store for the stack. Defaults to the config's own state layer. */
894
949
  readonly state?: AlchemyStateLayer;
@@ -1048,6 +1103,8 @@ interface PreflightInput<C = unknown> {
1048
1103
  readonly container: ContainerInstance | undefined;
1049
1104
  /** The environment name. */
1050
1105
  readonly environment: string;
1106
+ /** The pools the command read for this environment. Preflight fills a missing `envSecret()` platform variable from `pools.secrets` and an `envParam()` param's from `pools.config`. */
1107
+ readonly pools: ConfigPools;
1051
1108
  /** What the caller has already authenticated, for the platform calls preflight makes. Absent means the extension falls back to its own credential protocol. */
1052
1109
  readonly credentials?: ContainerCredentials<C> | undefined;
1053
1110
  /** Hands the deploy's progress output what the check covered, as counts (e.g. `{ checked: 53, filled: 0, missing: 0 }`). Counts only: never a name or a value. */
@@ -1225,6 +1282,8 @@ interface LocalTargetProvidersInput {
1225
1282
  readonly container: ContainerInstance | undefined;
1226
1283
  /** Absolute path of the environment's dev state directory (`devEnvironmentDir`, under the cwd). */
1227
1284
  readonly devDir: string;
1285
+ /** The pools the command read for this environment. A local deployment takes the values its rows point at from them. */
1286
+ readonly pools: ConfigPools;
1228
1287
  }
1229
1288
  interface LocalTargetEmulatorsInput {
1230
1289
  /** The loaded application graph — inspected for which node kinds need an emulator. */
@@ -1264,6 +1323,8 @@ interface LocalTargetAttachment {
1264
1323
  readonly address: string;
1265
1324
  readonly node: ServiceNode;
1266
1325
  readonly server: DevServer;
1326
+ /** The pools the command read for this environment. The command takes the values the service's rows point at from them. */
1327
+ readonly pools: ConfigPools;
1267
1328
  }): Promise<{
1268
1329
  readonly restarted: boolean;
1269
1330
  }>;
@@ -1288,16 +1349,46 @@ type NodeDescriptor = ({
1288
1349
  */
1289
1350
  serve?(input: ServeInput): Promise<DevServer | undefined>;
1290
1351
  };
1352
+ /** What a config adapter receives (ADR-0062). */
1353
+ interface ConfigAdapterInput {
1354
+ /** The environment's name, as `--environment` gave it. */
1355
+ readonly environment: string;
1356
+ /** The absolute directory of the prisma.config.ts that declares the `composer` section. A file adapter reads its files relative to it (ADR-0004). */
1357
+ readonly configDirectory: string;
1358
+ }
1359
+ /** The values one adapter returns, by name. */
1360
+ type ConfigValues = Readonly<Record<string, unknown>>;
1361
+ /**
1362
+ * A function in the `config` or `secrets` list of the `composer` section (ADR-0062):
1363
+ * it receives the environment and returns that environment's values. Composer calls it
1364
+ * in the CLI and again in the deploy engine's process, so it must return the same
1365
+ * values for the same environment both times.
1366
+ */
1367
+ type ConfigAdapter = (input: ConfigAdapterInput) => ConfigValues | Promise<ConfigValues>;
1368
+ /** What the `config` adapters return, merged by top-level key, a later adapter winning: the root's input, and what `envParam()` reads. */
1369
+ type ConfigPool = Readonly<Record<string, unknown>>;
1370
+ /** What the `secrets` adapters return, merged the same way. Every value is text. Only preflight and local dev read it; it is never logged, reported or written anywhere but the platform variable it fills. */
1371
+ type SecretsPool = Readonly<Record<string, string>>;
1372
+ /** The two pools one command read for one environment. */
1373
+ interface ConfigPools {
1374
+ readonly config: ConfigPool;
1375
+ readonly secrets: SecretsPool;
1376
+ }
1291
1377
  /**
1292
1378
  * The config file's default export. `extensions` lists every extension the
1293
1379
  * app deploys through; `state` is the ONE state store per deploy — explicit,
1294
- * platform-agnostic, never defaulted by an extension.
1380
+ * platform-agnostic, never defaulted by an extension. `config` and `secrets`
1381
+ * list the adapters the two pools come from.
1295
1382
  */
1296
1383
  interface PrismaAppConfig {
1297
1384
  /** The module whose default export is the app root, relative to `prisma.config.ts`. `--entry` overrides it. */
1298
1385
  readonly entry?: string;
1299
1386
  readonly extensions: ExtensionDescriptor[];
1300
1387
  readonly state: StateDescriptor;
1388
+ /** Where the config pool comes from. Defaults to `[environmentVariables()]`; a list given here replaces the default. */
1389
+ readonly config?: readonly ConfigAdapter[];
1390
+ /** Where the secrets pool comes from. Defaults to `[environmentVariables()]`; a list given here replaces the default. */
1391
+ readonly secrets?: readonly ConfigAdapter[];
1301
1392
  }
1302
1393
  //#endregion
1303
1394
  //#region ../../0-framework/3-tooling/cli/dist/composer-config-BJrPWlDx.d.mts
@@ -1310,7 +1401,7 @@ interface ComposerConfigSource {
1310
1401
  readonly file: string;
1311
1402
  }
1312
1403
  //#endregion
1313
- //#region ../../0-framework/3-tooling/cli/dist/deployment-summary-p88NV5m5.d.mts
1404
+ //#region ../../0-framework/3-tooling/cli/dist/deployment-summary-Cm4lN6w9.d.mts
1314
1405
  //#region src/deployment-summary.d.ts
1315
1406
  /** The serializable projection of DeploymentResult — what CAN cross the process
1316
1407
  * boundary. Writer (report hook) and reader (deploy operation) share this shape. */
@@ -1365,7 +1456,7 @@ interface NotOk<F> {
1365
1456
  */
1366
1457
  type Result$1<T, F> = Ok<T> | NotOk<F>;
1367
1458
  //#endregion
1368
- //#region ../../0-framework/3-tooling/cli/dist/dev-current-DfJfxg2y.d.mts
1459
+ //#region ../../0-framework/3-tooling/cli/dist/dev-current-3VmwctUt.d.mts
1369
1460
  //#region src/dev/watch.d.ts
1370
1461
  interface WatchTarget {
1371
1462
  readonly address: string;
@@ -1569,6 +1660,10 @@ type DevEvent =
1569
1660
  readonly kind: 'config-changed';
1570
1661
  readonly file: string;
1571
1662
  } |
1663
+ /** What the `config` or `secrets` adapters return changed since the session started. The session keeps the values it started with and stops rebuilding until it is restarted. */
1664
+ {
1665
+ readonly kind: 'values-changed';
1666
+ } |
1572
1667
  /** The app keeps running, still watching. */
1573
1668
  {
1574
1669
  readonly kind: 'converge-failed';
@@ -1691,7 +1786,7 @@ declare function devUrl(input: DevUrlInput): Promise<Result$1<DevUrl, CliStructu
1691
1786
  /** Stops the app's local copy in the environment: its service processes and database servers. Data and ports stay. */
1692
1787
  declare function devStop(input: DevStopInput): Promise<Result$1<DevStopped, CliStructuredError>>;
1693
1788
  //#endregion
1694
- //#region ../../0-framework/3-tooling/cli/dist/family-Dy3ZQOxG.d.mts
1789
+ //#region ../../0-framework/3-tooling/cli/dist/family-DACJfaA5.d.mts
1695
1790
  //#region src/family/family.d.ts
1696
1791
  /**
1697
1792
  * The control-plane operations the family's handlers call. These are the
@@ -1718,4 +1813,4 @@ interface CreateComposerFamilyOptions {
1718
1813
  }
1719
1814
  //#endregion
1720
1815
  export { Result$1 as _, DeployEvent as a, CliStructuredError as b, DevEvent as c, DevStopInput as d, DevStopped as f, ServiceEndpoint as g, OperationDeps as h, DEFAULT_DEPLOY_ENVIRONMENT as i, DevInput as l, DevUrlInput as m, CreateComposerFamilyOptions as n, DeployInput as o, DevUrl as p, realOperations as r, DeploySuccess as s, ComposerOperations as t, DevSession as u, AssembledServices as v, ComposerConfigSource as y };
1721
- //# sourceMappingURL=family-Dy3ZQOxG-BGwHvqM_.d.mts.map
1816
+ //# sourceMappingURL=family-DACJfaA5-CBuEC2B3.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"family-DACJfaA5-CBuEC2B3.d.mts","names":[],"sources":["../../../0-framework/0-foundation/foundation/dist/errors.d.mts","../../../0-framework/0-foundation/foundation/dist/secret-CHOw4LBU.d.mts","../../../0-framework/0-foundation/foundation/dist/pointer-CyQZZugO.d.mts","../../../../node_modules/@standard-schema/spec/dist/index.d.ts","../../../0-framework/1-core/core/dist/graph-types-R38xjBnN.d.mts","../../../0-framework/1-core/core/dist/app-config-BvxeTt2h.d.mts","../../../0-framework/3-tooling/cli/dist/composer-config-BJrPWlDx.d.mts","../../../0-framework/3-tooling/cli/dist/deployment-summary-Cm4lN6w9.d.mts","../../../0-framework/3-tooling/assemble/dist/index.d.mts","../../../0-framework/0-foundation/foundation/dist/result.d.mts","../../../0-framework/3-tooling/cli/dist/dev-current-3VmwctUt.d.mts","../../../0-framework/3-tooling/cli/dist/family-DACJfaA5.d.mts"],"x_google_ignoreList":[3],"mappings":";;;;;;;UACU,wBAAwB;WACvB;WACA;WACA;WACA;aACE;aACA;;WAEF;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gB,QAAQ,SAAO,YAAY;;;UAGrF;;WAEC,QAAQ;;WAER;;WAEA;;WAEA;;UAED;WACC;;WAEA;;WAEA;;WAEA;;WAEA;;UAED;WACC,QAAQ;;WAER;;WAEA;;WAEA;;WAEA;;UAED;;WAEC;;WAEA;;WAEA;aACE;aACA;;;;iBAII,OAAO,OAAO,cAAc,QAAQ,SAAO,QAAQ;;iBAEnD,QAAQ,OAAO,eAAe,QAAQ,SAAO,YAAY;;;;;;;;;;;;UC/VhE;WACC,eAAe;WACf,YAAY;WACZ,eAAe;WACf,gBAAgB;;cAEb,gBAAgB;UACpB;;WAEC,aAAa;;WAEb,WAAW;;WAEX,qBAAqB"}
package/dist/family.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { _ as Result, b as CliStructuredError$1, i as DEFAULT_DEPLOY_ENVIRONMENT, n as CreateComposerFamilyOptions$1, r as realOperations, t as ComposerOperations, y as ComposerConfigSource } from "./family-Dy3ZQOxG-BGwHvqM_.mjs";
1
+ import { _ as Result, b as CliStructuredError$1, i as DEFAULT_DEPLOY_ENVIRONMENT, n as CreateComposerFamilyOptions$1, r as realOperations, t as ComposerOperations, y as ComposerConfigSource } from "./family-DACJfaA5-CBuEC2B3.mjs";
2
2
  import { CommandFamily, ConfigSection, ManagementApiClient } from "@prisma/cli-engine";
3
3
  import { CliStructuredError } from "@prisma/cli-engine/protocol";
4
4
  import "effect/Layer";
package/dist/family.mjs CHANGED
@@ -1,5 +1,6 @@
1
- import { d as checkComposerConfig, h as sectionMissing, t as alchemyCommandLine } from "./run-alchemy-Dl_MWw4g-DaWV9tkH.mjs";
2
- import { a as devWithDeps, i as devUrl, n as deployWithDeps, o as executionDiagnostics, r as devStop, t as DEFAULT_DEPLOY_ENVIRONMENT } from "./dev-current-BNoPkDRU-D_UIh9Ne.mjs";
1
+ import { r as checkComposerConfig, s as sectionMissing } from "./config-adapters-BA_IeiX0-CiRnz7z8.mjs";
2
+ import { a as devWithDeps, i as devUrl, n as deployWithDeps, o as executionDiagnostics, r as devStop, t as DEFAULT_DEPLOY_ENVIRONMENT } from "./dev-current-BurA9uhA-BWYAftn9.mjs";
3
+ import { t as alchemyCommandLine } from "./run-alchemy-B-Z6i3cD-f0MXFCG8.mjs";
3
4
  import * as path from "node:path";
4
5
  import { defineCommand, defineCommandFamily, defineConfigSection, defineSessionCommand, exitWithChildStatus, flag, positional } from "@prisma/cli-engine";
5
6
  import { CliStructuredError, notOk, ok } from "@prisma/cli-engine/protocol";
@@ -470,6 +471,13 @@ function reportDevEvent(report, lastChild, cwd) {
470
471
  text: `${event.file} changed. Restart dev to apply it; rebuilds are paused until then.`
471
472
  });
472
473
  return;
474
+ case "values-changed":
475
+ report({
476
+ kind: "message",
477
+ severity: "warn",
478
+ text: "The values the config or secrets adapters return changed since dev started. Restart dev to apply them; rebuilds are paused until then."
479
+ });
480
+ return;
473
481
  case "watch-error":
474
482
  report({
475
483
  kind: "message",
@@ -764,7 +772,7 @@ function createComposerFamily$1(options = {}) {
764
772
  * assembled into the family here, where both domains may be imported.
765
773
  */
766
774
  /** Loaded on first use, so nothing of the Management API reads loads with the family. */
767
- const listDeployed = async (input) => (await import("./list-deployed-s0gjqC-r.mjs")).listDeployed(input);
775
+ const listDeployed = async (input) => (await import("./list-deployed-CH3SMsQ4.mjs")).listDeployed(input);
768
776
  const createDeployListCommand = (list) => defineCommand({
769
777
  help: {
770
778
  summary: "List every node the app has deployed in an environment, with its platform ID and URL.",
@@ -843,7 +851,7 @@ const createDeployListCommand = (list) => defineCommand({
843
851
  * family here, where both domains may be imported.
844
852
  */
845
853
  /** Loaded on first use, so nothing of the emulators' clients loads with the family. */
846
- const listEmulators = async () => (await import("./dist-B9-nLeho.mjs")).listEmulators();
854
+ const listEmulators = async () => (await import("./dist-BsONwZNR.mjs")).listEmulators();
847
855
  const EMULATOR_NAMES = {
848
856
  service: "Service emulator",
849
857
  database: "Database emulator",