@prisma/internals 6.6.0-dev.8 → 6.6.0-dev.80

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 (240) hide show
  1. package/dist/Generator.d.ts +23 -5
  2. package/dist/Generator.js +5 -3
  3. package/dist/WasmPanicRegistry.js +3 -3
  4. package/dist/{chunk-VPICIMIC.js → chunk-2GJT77IG.js} +9 -9
  5. package/dist/{chunk-PIPE5DSU.js → chunk-2H6XXXKO.js} +18 -21
  6. package/dist/chunk-2QTAK7KO.js +101 -0
  7. package/dist/{chunk-XLGODPZH.js → chunk-3DQANJMY.js} +12 -12
  8. package/dist/{chunk-WWAWV7DQ.js → chunk-4VNS5WPM.js} +3 -33
  9. package/dist/{chunk-KQOJB3ZW.js → chunk-5AI4FIZ3.js} +10 -10
  10. package/dist/{chunk-7MD6344A.js → chunk-5DBOS77Y.js} +3 -5
  11. package/dist/chunk-5UGQREP4.js +900 -0
  12. package/dist/{chunk-TZCE3PWZ.js → chunk-5VQNKCKW.js} +7 -7
  13. package/dist/{chunk-YXD4CJDK.js → chunk-67I7CEQJ.js} +30 -31
  14. package/dist/{chunk-I7IEEULS.js → chunk-6TTRTZXU.js} +5 -5
  15. package/dist/{chunk-5RV3EMX6.js → chunk-75BIJ5PX.js} +57 -57
  16. package/dist/{chunk-UCHV3Z5R.js → chunk-7NYW3PWT.js} +11 -10
  17. package/dist/{chunk-BGFWFIPR.js → chunk-AZV6HVKA.js} +5 -5
  18. package/dist/{chunk-5NV5K6XV.js → chunk-BC34NF2J.js} +30 -34
  19. package/dist/{chunk-JM6GGURA.js → chunk-BEXIOTQB.js} +11 -15
  20. package/dist/{chunk-ZYW3HGSH.js → chunk-BPDMLM32.js} +49 -17
  21. package/dist/{chunk-5MCWLJSR.js → chunk-CR3XKUEA.js} +10 -10
  22. package/dist/{chunk-TSJICM5S.js → chunk-CRVLHWC5.js} +5 -5
  23. package/dist/{chunk-WUCN2R47.js → chunk-CXHJXPSQ.js} +30 -34
  24. package/dist/{chunk-SHJNE6T7.js → chunk-D4VDA2TZ.js} +7 -7
  25. package/dist/{chunk-Q22BLLK3.js → chunk-D4VZUY3O.js} +6 -6
  26. package/dist/{chunk-KTBNIQ7N.js → chunk-DKSUHQGA.js} +8 -8
  27. package/dist/{chunk-EUTJYQDW.js → chunk-DODIJPCS.js} +13 -25
  28. package/dist/{chunk-UNUCCAXA.js → chunk-DTPFRZWV.js} +5 -5
  29. package/dist/{chunk-MVFJNP56.js → chunk-ECGN6YCE.js} +5 -5
  30. package/dist/{chunk-NJQWZ447.js → chunk-EPXBOIA5.js} +6 -6
  31. package/dist/{chunk-7XNZDY2V.js → chunk-ETYWYJBX.js} +60 -60
  32. package/dist/{chunk-5SN5JBT2.js → chunk-FXMGS3L5.js} +21 -40
  33. package/dist/{chunk-L6GBFCXG.js → chunk-HAGJ64PM.js} +142 -155
  34. package/dist/{chunk-3ERIN7PH.js → chunk-HG3YOAAE.js} +10 -10
  35. package/dist/{chunk-JQPAMLKP.js → chunk-HI7ARG5F.js} +11 -15
  36. package/dist/{chunk-GXDYIY4M.js → chunk-IDINCQMN.js} +56 -57
  37. package/dist/{chunk-X3G7MBLY.js → chunk-JDD3IDSP.js} +12 -11
  38. package/dist/{chunk-53LS3WUO.js → chunk-JOIIWB3U.js} +116 -116
  39. package/dist/{chunk-CZL7DCL2.js → chunk-JYMY3OAI.js} +6 -6
  40. package/dist/{chunk-TATYN3T2.js → chunk-KB5DKCI4.js} +29 -29
  41. package/dist/{chunk-LKTTJWFT.js → chunk-KDP6C3CB.js} +5 -5
  42. package/dist/{chunk-ATFQZVBS.js → chunk-LMVSIVKQ.js} +9 -14
  43. package/dist/{chunk-ZKAW5JSN.js → chunk-LRJ4X43J.js} +5 -5
  44. package/dist/{chunk-ONHKZPSV.js → chunk-LRU47BGE.js} +6 -6
  45. package/dist/{chunk-JAEPGZRE.js → chunk-M2QAZV2Z.js} +46 -79
  46. package/dist/{chunk-C2WD2XUT.js → chunk-MJIP3FY5.js} +968 -1220
  47. package/dist/{chunk-4E7A3GDU.js → chunk-MM4ARWWY.js} +5 -5
  48. package/dist/{chunk-V2ZF7ETH.js → chunk-NVNI2SRU.js} +66 -68
  49. package/dist/{chunk-YEF2M3FP.js → chunk-O77NRE3W.js} +5 -5
  50. package/dist/{chunk-JHQHVXIR.js → chunk-OSHZ4P3G.js} +6 -7
  51. package/dist/{chunk-IPKE37QC.js → chunk-PFYALFCY.js} +6 -5
  52. package/dist/{chunk-ZWOYFHSK.js → chunk-QD673IZB.js} +5 -5
  53. package/dist/{chunk-FCYHZHVW.js → chunk-R3J2O23S.js} +4 -4
  54. package/dist/{chunk-PFLLVWZX.js → chunk-R6QH57HZ.js} +5 -5
  55. package/dist/{chunk-25KZYQQJ.js → chunk-RCBHUFH6.js} +22 -26
  56. package/dist/chunk-RE7QRBEC.js +900 -0
  57. package/dist/{chunk-NNL52KLF.js → chunk-RKIDRPS5.js} +23 -27
  58. package/dist/{chunk-63J6Y3F6.js → chunk-SZHOH2HW.js} +22 -26
  59. package/dist/{chunk-ICXPZGKG.js → chunk-TMB3FAZO.js} +46 -79
  60. package/dist/{chunk-Y3OWT3K2.js → chunk-TQFONRJP.js} +7 -7
  61. package/dist/{chunk-3BND5XB4.js → chunk-UTJGRVMG.js} +11 -11
  62. package/dist/{chunk-CHMJ5V7I.js → chunk-UZTXEBTM.js} +7 -7
  63. package/dist/{chunk-RAZRBWTZ.js → chunk-W4YDEAHM.js} +23 -27
  64. package/dist/{chunk-6TXVGFQA.js → chunk-WSZXPLJQ.js} +11 -11
  65. package/dist/{chunk-BPZFDGKN.js → chunk-WXRVYSYN.js} +4 -7
  66. package/dist/{chunk-OB3JSSO6.js → chunk-X5FON43L.js} +5 -5
  67. package/dist/{chunk-5CJA6QCN.js → chunk-X6ECL5J5.js} +9 -9
  68. package/dist/{chunk-2MWIMEFK.js → chunk-XLTQGAI2.js} +6 -6
  69. package/dist/chunk-YR5KNFKN.js +1834 -0
  70. package/dist/{chunk-AZNLB67U.js → chunk-ZJWZK45Z.js} +5 -5
  71. package/dist/chunk-ZSINRHD4.js +43 -0
  72. package/dist/cli/Help.js +1 -1
  73. package/dist/cli/checkUnsupportedDataProxy.d.ts +12 -17
  74. package/dist/cli/checkUnsupportedDataProxy.js +75 -78
  75. package/dist/cli/directoryConfig.d.ts +7 -0
  76. package/dist/cli/directoryConfig.js +25 -0
  77. package/dist/cli/getGeneratorSuccessMessage.js +1 -1
  78. package/dist/cli/getSchema.d.ts +3 -28
  79. package/dist/cli/getSchema.js +78 -82
  80. package/dist/cli/getTypescriptVersion.js +1 -1
  81. package/dist/cli/hashes.d.ts +1 -2
  82. package/dist/cli/hashes.js +75 -78
  83. package/dist/cli/schemaContext.d.ts +59 -0
  84. package/dist/cli/schemaContext.js +133 -0
  85. package/dist/cli/utils.js +5 -5
  86. package/dist/client/getClientEngineType.d.ts +1 -1
  87. package/dist/client/getClientEngineType.js +1 -1
  88. package/dist/convertCredentials.d.ts +1 -1
  89. package/dist/convertCredentials.js +1 -1
  90. package/dist/dotenvExpand.js +1 -1
  91. package/dist/engine-commands/errorHelpers.js +5 -5
  92. package/dist/engine-commands/formatSchema.js +74 -77
  93. package/dist/engine-commands/getConfig.d.ts +1 -5
  94. package/dist/engine-commands/getConfig.js +16 -17
  95. package/dist/engine-commands/getDmmf.d.ts +3 -6
  96. package/dist/engine-commands/getDmmf.js +13 -14
  97. package/dist/engine-commands/getEngineVersion.js +12 -12
  98. package/dist/engine-commands/getEnginesMetaInfo.js +15 -15
  99. package/dist/engine-commands/index.js +85 -88
  100. package/dist/engine-commands/lintSchema.d.ts +1 -1
  101. package/dist/engine-commands/lintSchema.js +11 -12
  102. package/dist/engine-commands/mergeSchemas.js +13 -14
  103. package/dist/engine-commands/queryEngineCommons.js +8 -8
  104. package/dist/engine-commands/relativizePathInPSLError.js +1 -1
  105. package/dist/engine-commands/validate.js +13 -14
  106. package/dist/errorReporting.d.ts +0 -1
  107. package/dist/errorReporting.js +7 -7
  108. package/dist/get-generators/getGenerators.d.ts +22 -9
  109. package/dist/get-generators/getGenerators.js +77 -80
  110. package/dist/get-generators/utils/binaryTypeToEngineType.d.ts +1 -1
  111. package/dist/get-generators/utils/binaryTypeToEngineType.js +1 -1
  112. package/dist/get-generators/utils/engineTypeToBinaryType.d.ts +1 -1
  113. package/dist/get-generators/utils/engineTypeToBinaryType.js +1 -1
  114. package/dist/get-generators/utils/fixBinaryTargets.d.ts +1 -1
  115. package/dist/get-generators/utils/fixBinaryTargets.js +1 -1
  116. package/dist/get-generators/utils/getBinaryPathsByVersion.d.ts +1 -1
  117. package/dist/get-generators/utils/getBinaryPathsByVersion.js +4 -4
  118. package/dist/get-generators/utils/getEngineVersionForGenerator.d.ts +1 -1
  119. package/dist/get-generators/utils/getEngineVersionForGenerator.js +1 -1
  120. package/dist/get-generators/utils/printGeneratorConfig.d.ts +1 -1
  121. package/dist/get-generators/utils/printGeneratorConfig.js +7 -7
  122. package/dist/getPackedPackage.js +9 -9
  123. package/dist/highlight/highlight.js +1 -1
  124. package/dist/highlight/languages/dml.js +1 -1
  125. package/dist/highlight/languages/sql.js +1 -1
  126. package/dist/highlight/prism.js +1 -1
  127. package/dist/highlight/theme.js +1 -1
  128. package/dist/index.d.ts +7 -7
  129. package/dist/index.js +141 -145
  130. package/dist/logger.js +9 -9
  131. package/dist/migrateTypes.d.ts +63 -0
  132. package/dist/{multipart-parser-32AROPTR.js → multipart-parser-3AFJFP6K.js} +7 -7
  133. package/dist/panic.d.ts +1 -4
  134. package/dist/panic.js +7 -7
  135. package/dist/resolveBinary.js +10 -10
  136. package/dist/resolveOutput.js +1 -1
  137. package/dist/resolvePkg.d.ts +7 -0
  138. package/dist/{get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.js → resolvePkg.js} +6 -6
  139. package/dist/schemaEngineCommands.js +13 -13
  140. package/dist/sendPanic.js +7 -111
  141. package/dist/types.d.ts +1 -1
  142. package/dist/utils/__tests__/isCi.test.js +1 -1
  143. package/dist/utils/__tests__/isInteractive.test.js +1 -1
  144. package/dist/utils/__tests__/maskSchema.test.js +1 -1
  145. package/dist/utils/assertAlways.js +1 -1
  146. package/dist/utils/assertNever.js +1 -1
  147. package/dist/utils/binaryTargetRegex.js +3 -3
  148. package/dist/utils/byline.js +1 -1
  149. package/dist/utils/callOnce.js +1 -1
  150. package/dist/utils/callOnce.test.js +1 -1
  151. package/dist/utils/canPrompt.js +4 -4
  152. package/dist/utils/chmodPlusX.js +1 -1
  153. package/dist/utils/cloudflareD1.js +4 -4
  154. package/dist/utils/drawBox.js +1 -1
  155. package/dist/utils/extractPreviewFeatures.d.ts +2 -2
  156. package/dist/utils/extractPreviewFeatures.js +3 -3
  157. package/dist/utils/formatTable.js +1 -1
  158. package/dist/utils/formatms.js +1 -1
  159. package/dist/utils/fs-functional.js +12 -12
  160. package/dist/utils/fs-utils.js +9 -9
  161. package/dist/utils/getCommandWithExecutor.js +4 -4
  162. package/dist/utils/getEnvPaths.d.ts +1 -1
  163. package/dist/utils/getEnvPaths.js +74 -77
  164. package/dist/utils/getGitHubIssueUrl.js +5 -4
  165. package/dist/utils/getMigrateConfigDir.js +1 -1
  166. package/dist/utils/getVersionFromPackageJson.js +4 -4
  167. package/dist/utils/handleEngineLoadingErrors.js +1 -1
  168. package/dist/utils/handlePanic.js +13 -110
  169. package/dist/utils/hasOwnProperty.js +1 -1
  170. package/dist/utils/isCi.js +1 -1
  171. package/dist/utils/isCurrentBinInstalledGlobally.js +3 -3
  172. package/dist/utils/isInContainer.js +1 -1
  173. package/dist/utils/isInNpmLifecycleHook.js +1 -1
  174. package/dist/utils/isInteractive.js +1 -1
  175. package/dist/utils/isPromiseLike.js +1 -1
  176. package/dist/utils/isValidJsIdentifier.js +4 -4
  177. package/dist/utils/keyBy.js +1 -1
  178. package/dist/utils/link.js +3 -3
  179. package/dist/utils/load.js +3 -3
  180. package/dist/utils/loadEnvFile.js +74 -77
  181. package/dist/utils/mapKeys.js +1 -1
  182. package/dist/utils/mapObjectValues.js +1 -1
  183. package/dist/utils/maskSchema.js +1 -1
  184. package/dist/utils/max.js +1 -1
  185. package/dist/utils/max.test.js +1 -1
  186. package/dist/utils/maybeInGitHook.js +1 -1
  187. package/dist/utils/missingDatasource.js +4 -4
  188. package/dist/utils/missingGeneratorMessage.js +6 -6
  189. package/dist/utils/now.js +1 -1
  190. package/dist/utils/omit.js +1 -1
  191. package/dist/utils/parseAWSNodejsRuntimeEnvVarVersion.js +1 -1
  192. package/dist/utils/parseEnvValue.d.ts +1 -1
  193. package/dist/utils/parseEnvValue.js +1 -1
  194. package/dist/utils/path.js +1 -1
  195. package/dist/utils/path.test.js +1 -1
  196. package/dist/utils/pick.js +1 -1
  197. package/dist/utils/printConfigWarnings.js +1 -1
  198. package/dist/utils/prismaPostgres.js +1 -1
  199. package/dist/utils/prismaPostgres.test.js +1 -1
  200. package/dist/utils/schemaFileInput.d.ts +0 -4
  201. package/dist/utils/schemaFileInput.js +3 -7
  202. package/dist/utils/serializeQueryEngineName.js +1 -1
  203. package/dist/utils/setClassName.js +1 -1
  204. package/dist/utils/toSchemasContainer.d.ts +2 -3
  205. package/dist/utils/toSchemasContainer.js +4 -5
  206. package/dist/utils/tryLoadEnvs.js +6 -6
  207. package/dist/utils/unique.js +1 -1
  208. package/dist/utils/vercelPkgPathRegex.js +1 -1
  209. package/dist/warnOnce.js +4 -4
  210. package/dist/wasm.js +6 -6
  211. package/package.json +14 -13
  212. package/dist/chunk-77IC3DNO.js +0 -35
  213. package/dist/chunk-AOQIUJT4.js +0 -41
  214. package/dist/chunk-MGZOEY6N.js +0 -28
  215. package/dist/chunk-MUDGDTP6.js +0 -15631
  216. package/dist/chunk-S57RMXZW.js +0 -28
  217. package/dist/chunk-SH3FWTQI.js +0 -15631
  218. package/dist/chunk-VRT7T6MF.js +0 -4959
  219. package/dist/chunk-YRBRUREX.js +0 -57
  220. package/dist/get-generators/generatorResolvers/generatorResolvers.d.ts +0 -15
  221. package/dist/get-generators/generatorResolvers/generatorResolvers.js +0 -135
  222. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/findPrismaClientDir.d.ts +0 -6
  223. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/findPrismaClientDir.js +0 -26
  224. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/getPackageCmd.d.ts +0 -9
  225. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/getPackageCmd.js +0 -26
  226. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/runPackageCmd.d.ts +0 -8
  227. package/dist/get-generators/generatorResolvers/prisma-client-js/auto-installation/runPackageCmd.js +0 -29
  228. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkTypeScriptVersion.d.ts +0 -6
  229. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkTypeScriptVersion.js +0 -135
  230. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/isYarnUsed.d.ts +0 -1
  231. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/isYarnUsed.js +0 -26
  232. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/resolve.d.ts +0 -20
  233. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/resolve.js +0 -26
  234. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.d.ts +0 -7
  235. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.test.d.ts +0 -1
  236. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/semverLt.test.js +0 -17
  237. package/dist/get-generators/generatorResolvers/prisma-client-js/prismaClientResolver.d.ts +0 -20
  238. package/dist/get-generators/generatorResolvers/prisma-client-js/prismaClientResolver.js +0 -136
  239. package/dist/get-generators/utils/check-feature-flags/checkFeatureFlags.d.ts +0 -8
  240. package/dist/get-generators/utils/check-feature-flags/checkFeatureFlags.js +0 -25
@@ -16,13 +16,13 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_UCHV3Z5R_exports = {};
20
- __export(chunk_UCHV3Z5R_exports, {
19
+ var chunk_7NYW3PWT_exports = {};
20
+ __export(chunk_7NYW3PWT_exports, {
21
21
  require_package: () => require_package
22
22
  });
23
- module.exports = __toCommonJS(chunk_UCHV3Z5R_exports);
24
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
25
- var require_package = (0, import_chunk_WWAWV7DQ.__commonJS)({
23
+ module.exports = __toCommonJS(chunk_7NYW3PWT_exports);
24
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
25
+ var require_package = (0, import_chunk_4VNS5WPM.__commonJS)({
26
26
  "package.json"(exports, module2) {
27
27
  module2.exports = {
28
28
  name: "@prisma/internals",
@@ -53,7 +53,6 @@ var require_package = (0, import_chunk_WWAWV7DQ.__commonJS)({
53
53
  "scripts"
54
54
  ],
55
55
  devDependencies: {
56
- "@antfu/ni": "0.21.12",
57
56
  "@babel/helper-validator-identifier": "7.25.9",
58
57
  "@opentelemetry/api": "1.9.0",
59
58
  "@swc/core": "1.11.5",
@@ -66,8 +65,8 @@ var require_package = (0, import_chunk_WWAWV7DQ.__commonJS)({
66
65
  "checkpoint-client": "1.1.33",
67
66
  "cli-truncate": "4.0.0",
68
67
  dotenv: "16.4.7",
69
- esbuild: "0.24.2",
70
- "escape-string-regexp": "4.0.0",
68
+ esbuild: "0.25.1",
69
+ "escape-string-regexp": "5.0.0",
71
70
  execa: "5.1.1",
72
71
  "fast-glob": "3.3.3",
73
72
  "find-up": "7.0.0",
@@ -96,7 +95,7 @@ var require_package = (0, import_chunk_WWAWV7DQ.__commonJS)({
96
95
  "strip-indent": "4.0.0",
97
96
  "temp-dir": "2.0.0",
98
97
  tempy: "1.0.1",
99
- "terminal-link": "2.1.1",
98
+ "terminal-link": "3.0.0",
100
99
  tmp: "0.2.3",
101
100
  "ts-node": "10.9.2",
102
101
  "ts-pattern": "5.6.2",
@@ -107,11 +106,13 @@ var require_package = (0, import_chunk_WWAWV7DQ.__commonJS)({
107
106
  dependencies: {
108
107
  "@prisma/config": "workspace:*",
109
108
  "@prisma/debug": "workspace:*",
109
+ "@prisma/dmmf": "workspace:*",
110
110
  "@prisma/engines": "workspace:*",
111
111
  "@prisma/fetch-engine": "workspace:*",
112
+ "@prisma/generator": "workspace:*",
112
113
  "@prisma/generator-helper": "workspace:*",
113
114
  "@prisma/get-platform": "workspace:*",
114
- "@prisma/prisma-schema-wasm": "6.6.0-7.2b764cb9f34cacff7ce8a50073e91424535bb5d7",
115
+ "@prisma/prisma-schema-wasm": "6.6.0-41.9061db3b0058e3d3731c6fe68a1b77061bed4861",
115
116
  "@prisma/schema-files-loader": "workspace:*",
116
117
  arg: "5.0.2",
117
118
  prompts: "2.4.2"
@@ -16,12 +16,12 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_BGFWFIPR_exports = {};
20
- __export(chunk_BGFWFIPR_exports, {
19
+ var chunk_AZV6HVKA_exports = {};
20
+ __export(chunk_AZV6HVKA_exports, {
21
21
  missingDatasource: () => missingDatasource
22
22
  });
23
- module.exports = __toCommonJS(chunk_BGFWFIPR_exports);
24
- var import_chunk_L6GBFCXG = require("./chunk-L6GBFCXG.js");
23
+ module.exports = __toCommonJS(chunk_AZV6HVKA_exports);
24
+ var import_chunk_HAGJ64PM = require("./chunk-HAGJ64PM.js");
25
25
  var import_chunk_TQCLUNM2 = require("./chunk-TQCLUNM2.js");
26
26
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
27
27
  var missingDatasource = `
@@ -36,5 +36,5 @@ ${(0, import_chunk_PG5FDKSF.bold)(
36
36
  )}
37
37
 
38
38
  More information in our documentation:
39
- ${(0, import_chunk_L6GBFCXG.link)("https://pris.ly/d/prisma-schema")}
39
+ ${(0, import_chunk_HAGJ64PM.link)("https://pris.ly/d/prisma-schema")}
40
40
  `;
@@ -26,29 +26,28 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_5NV5K6XV_exports = {};
30
- __export(chunk_5NV5K6XV_exports, {
29
+ var chunk_BC34NF2J_exports = {};
30
+ __export(chunk_BC34NF2J_exports, {
31
31
  GetConfigError: () => GetConfigError,
32
32
  getConfig: () => getConfig,
33
33
  getDirectUrl: () => getDirectUrl,
34
34
  getEffectiveUrl: () => getEffectiveUrl,
35
35
  resolveUrl: () => resolveUrl
36
36
  });
37
- module.exports = __toCommonJS(chunk_5NV5K6XV_exports);
38
- var import_chunk_YRBRUREX = require("./chunk-YRBRUREX.js");
39
- var import_chunk_6TXVGFQA = require("./chunk-6TXVGFQA.js");
37
+ module.exports = __toCommonJS(chunk_BC34NF2J_exports);
38
+ var import_chunk_WSZXPLJQ = require("./chunk-WSZXPLJQ.js");
39
+ var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
40
40
  var import_chunk_C47SCASR = require("./chunk-C47SCASR.js");
41
- var import_chunk_YEF2M3FP = require("./chunk-YEF2M3FP.js");
42
- var import_chunk_PFLLVWZX = require("./chunk-PFLLVWZX.js");
41
+ var import_chunk_QD673IZB = require("./chunk-QD673IZB.js");
42
+ var import_chunk_2GJT77IG = require("./chunk-2GJT77IG.js");
43
+ var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
43
44
  var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
44
- var import_chunk_VPICIMIC = require("./chunk-VPICIMIC.js");
45
- var import_chunk_ATFQZVBS = require("./chunk-ATFQZVBS.js");
46
- var import_chunk_7MD6344A = require("./chunk-7MD6344A.js");
45
+ var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
47
46
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
48
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
47
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
49
48
  var import_debug = __toESM(require("@prisma/debug"));
50
49
  var import_get_platform = require("@prisma/get-platform");
51
- var import_function = (0, import_chunk_WWAWV7DQ.__toESM)((0, import_chunk_PFLLVWZX.require_function)());
50
+ var import_function = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_R6QH57HZ.require_function)());
52
51
  var debug = (0, import_debug.default)("prisma:getConfig");
53
52
  var SCHEMA_VALIDATION_ERROR_CODE = "P1012";
54
53
  var GetConfigError = class extends Error {
@@ -65,7 +64,7 @@ ${detailsHeader} ${message}`;
65
64
  }).exhaustive();
66
65
  const errorMessageWithContext = `${constructedErrorMessage}
67
66
  [Context: getConfig]`;
68
- super((0, import_chunk_YEF2M3FP.addVersionDetailsToErrorMessage)(errorMessageWithContext));
67
+ super((0, import_chunk_QD673IZB.addVersionDetailsToErrorMessage)(errorMessageWithContext));
69
68
  this.name = "GetConfigError";
70
69
  }
71
70
  };
@@ -83,14 +82,14 @@ function resolveUrl(envValue) {
83
82
  return urlFromValue ?? urlEnvVarValue;
84
83
  }
85
84
  async function getConfig(options) {
86
- const debugErrorType = (0, import_chunk_6TXVGFQA.createDebugErrorType)(debug, "getConfigWasm");
85
+ const debugErrorType = (0, import_chunk_WSZXPLJQ.createDebugErrorType)(debug, "getConfigWasm");
87
86
  debug(`Using getConfig Wasm`);
88
87
  const configEither = (0, import_function.pipe)(
89
- (0, import_chunk_7MD6344A.tryCatch)(
88
+ (0, import_chunk_5DBOS77Y.tryCatch)(
90
89
  () => {
91
90
  if (process.env.FORCE_PANIC_QUERY_ENGINE_GET_CONFIG) {
92
91
  debug("Triggering a Rust panic...");
93
- import_chunk_VPICIMIC.prismaSchemaWasm.debug_panic();
92
+ import_chunk_2GJT77IG.prismaSchemaWasm.debug_panic();
94
93
  }
95
94
  const params = JSON.stringify({
96
95
  prismaSchema: options.datamodel,
@@ -98,7 +97,7 @@ async function getConfig(options) {
98
97
  ignoreEnvVarErrors: options.ignoreEnvVarErrors ?? false,
99
98
  env: process.env
100
99
  });
101
- const data = import_chunk_VPICIMIC.prismaSchemaWasm.get_config(params);
100
+ const data = import_chunk_2GJT77IG.prismaSchemaWasm.get_config(params);
102
101
  return data;
103
102
  },
104
103
  (e) => ({
@@ -107,11 +106,11 @@ async function getConfig(options) {
107
106
  error: e
108
107
  })
109
108
  ),
110
- (0, import_chunk_7MD6344A.map)((result) => ({ result })),
111
- (0, import_chunk_7MD6344A.chainW)(
109
+ (0, import_chunk_5DBOS77Y.map)((result) => ({ result })),
110
+ (0, import_chunk_5DBOS77Y.chainW)(
112
111
  ({ result }) => (
113
112
  // NOTE: this should never fail, as we expect returned values to be valid JSON-serializable strings
114
- (0, import_chunk_7MD6344A.tryCatch)(
113
+ (0, import_chunk_5DBOS77Y.tryCatch)(
115
114
  () => JSON.parse(result),
116
115
  (e) => ({
117
116
  type: "parse-json",
@@ -121,18 +120,18 @@ async function getConfig(options) {
121
120
  )
122
121
  )
123
122
  ),
124
- (0, import_chunk_7MD6344A.chainW)((response) => {
123
+ (0, import_chunk_5DBOS77Y.chainW)((response) => {
125
124
  if (response.errors.length > 0) {
126
- return (0, import_chunk_7MD6344A.left)({
125
+ return (0, import_chunk_5DBOS77Y.left)({
127
126
  type: "validation-error",
128
127
  reason: "(get-config wasm)",
129
128
  error: response.errors
130
129
  });
131
130
  }
132
- return (0, import_chunk_7MD6344A.right)(response.config);
131
+ return (0, import_chunk_5DBOS77Y.right)(response.config);
133
132
  })
134
133
  );
135
- if ((0, import_chunk_7MD6344A.isRight)(configEither)) {
134
+ if ((0, import_chunk_5DBOS77Y.isRight)(configEither)) {
136
135
  debug("config data retrieved without errors in getConfig Wasm");
137
136
  const { right: data } = configEither;
138
137
  for (const generator of data.generators) {
@@ -142,30 +141,27 @@ async function getConfig(options) {
142
141
  }
143
142
  const error = (0, import_chunk_XKZ6CBLA.z)(configEither.left).with({ type: "wasm-error" }, (e) => {
144
143
  debugErrorType(e);
145
- if ((0, import_chunk_ATFQZVBS.isWasmPanic)(e.error)) {
146
- const { message, stack } = (0, import_chunk_ATFQZVBS.getWasmError)(e.error);
147
- const panic = new import_chunk_ATFQZVBS.RustPanic(
144
+ if ((0, import_chunk_LMVSIVKQ.isWasmPanic)(e.error)) {
145
+ const { message, stack } = (0, import_chunk_LMVSIVKQ.getWasmError)(e.error);
146
+ const panic = new import_chunk_LMVSIVKQ.RustPanic(
148
147
  /* message */
149
148
  message,
150
149
  /* rustStack */
151
150
  stack,
152
151
  /* request */
153
152
  "@prisma/prisma-schema-wasm get_config",
154
- "FMT_CLI",
155
- /* schemaPath */
156
- options.prismaPath,
157
- /* schema */
158
- (0, import_chunk_YRBRUREX.toMultipleSchemas)(options.datamodel)
153
+ "FMT_CLI"
154
+ /* FMT_CLI */
159
155
  );
160
156
  return panic;
161
157
  }
162
158
  const errorOutput = e.error.message;
163
- return new GetConfigError((0, import_chunk_6TXVGFQA.parseQueryEngineError)({ errorOutput, reason: e.reason }));
159
+ return new GetConfigError((0, import_chunk_WSZXPLJQ.parseQueryEngineError)({ errorOutput, reason: e.reason }));
164
160
  }).with({ type: "validation-error" }, (e) => {
165
161
  return new GetConfigError({
166
162
  _tag: "parsed",
167
163
  errorCode: SCHEMA_VALIDATION_ERROR_CODE,
168
- reason: (0, import_chunk_6TXVGFQA.createSchemaValidationError)(e.reason),
164
+ reason: (0, import_chunk_WSZXPLJQ.createSchemaValidationError)(e.reason),
169
165
  message: formatErrors(e.error)
170
166
  });
171
167
  }).otherwise((e) => {
@@ -16,41 +16,37 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_JM6GGURA_exports = {};
20
- __export(chunk_JM6GGURA_exports, {
19
+ var chunk_BEXIOTQB_exports = {};
20
+ __export(chunk_BEXIOTQB_exports, {
21
21
  getLintWarnings: () => getLintWarnings,
22
22
  getLintWarningsAsText: () => getLintWarningsAsText,
23
23
  handleLintPanic: () => handleLintPanic,
24
24
  lintSchema: () => lintSchema,
25
25
  warningToString: () => warningToString
26
26
  });
27
- module.exports = __toCommonJS(chunk_JM6GGURA_exports);
28
- var import_chunk_YRBRUREX = require("./chunk-YRBRUREX.js");
29
- var import_chunk_5CJA6QCN = require("./chunk-5CJA6QCN.js");
30
- var import_chunk_ATFQZVBS = require("./chunk-ATFQZVBS.js");
27
+ module.exports = __toCommonJS(chunk_BEXIOTQB_exports);
28
+ var import_chunk_2GJT77IG = require("./chunk-2GJT77IG.js");
29
+ var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
31
30
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
32
31
  function lintSchema({ schemas }) {
33
- const lintResult = import_chunk_5CJA6QCN.prismaSchemaWasm.lint(JSON.stringify(schemas));
32
+ const lintResult = import_chunk_2GJT77IG.prismaSchemaWasm.lint(JSON.stringify(schemas));
34
33
  const lintDiagnostics = JSON.parse(lintResult);
35
34
  return lintDiagnostics;
36
35
  }
37
- function handleLintPanic(tryCb, { schemas }) {
36
+ function handleLintPanic(tryCb) {
38
37
  try {
39
38
  return tryCb();
40
39
  } catch (e) {
41
- const { message, stack } = (0, import_chunk_ATFQZVBS.getWasmError)(e);
42
- const panic = new import_chunk_ATFQZVBS.RustPanic(
40
+ const { message, stack } = (0, import_chunk_LMVSIVKQ.getWasmError)(e);
41
+ const panic = new import_chunk_LMVSIVKQ.RustPanic(
43
42
  /* message */
44
43
  message,
45
44
  /* rustStack */
46
45
  stack,
47
46
  /* request */
48
47
  "@prisma/prisma-schema-wasm lint",
49
- "FMT_CLI",
50
- /* schemaPath */
51
- (0, import_chunk_YRBRUREX.debugMultipleSchemaPaths)(schemas),
52
- /* schema */
53
- schemas
48
+ "FMT_CLI"
49
+ /* FMT_CLI */
54
50
  );
55
51
  throw panic;
56
52
  }
@@ -16,35 +16,31 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_ZYW3HGSH_exports = {};
20
- __export(chunk_ZYW3HGSH_exports, {
21
- Generator: () => Generator
19
+ var chunk_BPDMLM32_exports = {};
20
+ __export(chunk_BPDMLM32_exports, {
21
+ Generator: () => Generator,
22
+ InProcessGenerator: () => InProcessGenerator,
23
+ JsonRpcGenerator: () => JsonRpcGenerator
22
24
  });
23
- module.exports = __toCommonJS(chunk_ZYW3HGSH_exports);
25
+ module.exports = __toCommonJS(chunk_BPDMLM32_exports);
24
26
  var import_chunk_IOIAK7V7 = require("./chunk-IOIAK7V7.js");
25
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
26
27
  var import_generator_helper = require("@prisma/generator-helper");
27
28
  var Generator = class {
28
- constructor(executablePath, config, isNode) {
29
- (0, import_chunk_WWAWV7DQ.__publicField)(this, "generatorProcess");
30
- (0, import_chunk_WWAWV7DQ.__publicField)(this, "manifest", null);
31
- (0, import_chunk_WWAWV7DQ.__publicField)(this, "config");
32
- (0, import_chunk_WWAWV7DQ.__publicField)(this, "options");
29
+ manifest = null;
30
+ config;
31
+ options;
32
+ constructor(config) {
33
33
  this.config = config;
34
- this.generatorProcess = new import_generator_helper.GeneratorProcess(executablePath, { isNode });
35
34
  }
36
35
  async init() {
37
- await this.generatorProcess.init();
38
- this.manifest = await this.generatorProcess.getManifest(this.config);
39
- }
40
- stop() {
41
- this.generatorProcess.stop();
36
+ await this.initImpl();
37
+ this.manifest = await this.getManifest();
42
38
  }
43
39
  generate() {
44
40
  if (!this.options) {
45
41
  throw new Error(`Please first run .setOptions() on the Generator to initialize the options`);
46
42
  }
47
- return this.generatorProcess.generate(this.options);
43
+ return this.generateImpl(this.options);
48
44
  }
49
45
  setOptions(options) {
50
46
  this.options = options;
@@ -71,3 +67,39 @@ var Generator = class {
71
67
  return (0, import_chunk_IOIAK7V7.parseEnvValue)(this.config.provider);
72
68
  }
73
69
  };
70
+ var JsonRpcGenerator = class extends Generator {
71
+ #generatorProcess;
72
+ constructor(executablePath, config, isNode) {
73
+ super(config);
74
+ this.#generatorProcess = new import_generator_helper.GeneratorProcess(executablePath, { isNode });
75
+ }
76
+ async initImpl() {
77
+ await this.#generatorProcess.init();
78
+ }
79
+ async getManifest() {
80
+ return await this.#generatorProcess.getManifest(this.config);
81
+ }
82
+ async generateImpl(options) {
83
+ await this.#generatorProcess.generate(options);
84
+ }
85
+ stop() {
86
+ this.#generatorProcess.stop();
87
+ }
88
+ };
89
+ var InProcessGenerator = class extends Generator {
90
+ #generator;
91
+ constructor(config, generator) {
92
+ super(config);
93
+ this.#generator = generator;
94
+ }
95
+ async initImpl() {
96
+ }
97
+ async getManifest() {
98
+ return await this.#generator.getManifest(this.config);
99
+ }
100
+ async generateImpl(options) {
101
+ await this.#generator.generate(options);
102
+ }
103
+ stop() {
104
+ }
105
+ };
@@ -26,14 +26,14 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_5MCWLJSR_exports = {};
30
- __export(chunk_5MCWLJSR_exports, {
29
+ var chunk_CR3XKUEA_exports = {};
30
+ __export(chunk_CR3XKUEA_exports, {
31
31
  isCurrentBinInstalledGlobally: () => isCurrentBinInstalledGlobally
32
32
  });
33
- module.exports = __toCommonJS(chunk_5MCWLJSR_exports);
34
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
33
+ module.exports = __toCommonJS(chunk_CR3XKUEA_exports);
34
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
35
35
  var import_fs = __toESM(require("fs"));
36
- var require_ini = (0, import_chunk_WWAWV7DQ.__commonJS)({
36
+ var require_ini = (0, import_chunk_4VNS5WPM.__commonJS)({
37
37
  "../../node_modules/.pnpm/ini@2.0.0/node_modules/ini/ini.js"(exports, module2) {
38
38
  "use strict";
39
39
  var { hasOwnProperty } = Object.prototype;
@@ -186,12 +186,12 @@ var require_ini = (0, import_chunk_WWAWV7DQ.__commonJS)({
186
186
  };
187
187
  }
188
188
  });
189
- var require_global_dirs = (0, import_chunk_WWAWV7DQ.__commonJS)({
189
+ var require_global_dirs = (0, import_chunk_4VNS5WPM.__commonJS)({
190
190
  "../../node_modules/.pnpm/global-dirs@4.0.0/node_modules/global-dirs/index.js"(exports) {
191
191
  "use strict";
192
- var path = (0, import_chunk_WWAWV7DQ.__require)("path");
193
- var os = (0, import_chunk_WWAWV7DQ.__require)("os");
194
- var fs2 = (0, import_chunk_WWAWV7DQ.__require)("fs");
192
+ var path = (0, import_chunk_4VNS5WPM.__require)("path");
193
+ var os = (0, import_chunk_4VNS5WPM.__require)("os");
194
+ var fs2 = (0, import_chunk_4VNS5WPM.__require)("fs");
195
195
  var ini = require_ini();
196
196
  var isWindows = process.platform === "win32";
197
197
  var readRc = (filePath) => {
@@ -282,7 +282,7 @@ var require_global_dirs = (0, import_chunk_WWAWV7DQ.__commonJS)({
282
282
  exports.yarn.binaries = path.join(exports.yarn.packages, ".bin");
283
283
  }
284
284
  });
285
- var import_global_dirs = (0, import_chunk_WWAWV7DQ.__toESM)(require_global_dirs());
285
+ var import_global_dirs = (0, import_chunk_4VNS5WPM.__toESM)(require_global_dirs());
286
286
  function isCurrentBinInstalledGlobally() {
287
287
  try {
288
288
  const realPrismaPath = import_fs.default.realpathSync(process.argv[1]);
@@ -16,12 +16,12 @@ var __copyProps = (to, from, except, desc) => {
16
16
  return to;
17
17
  };
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
- var chunk_TSJICM5S_exports = {};
20
- __export(chunk_TSJICM5S_exports, {
19
+ var chunk_CRVLHWC5_exports = {};
20
+ __export(chunk_CRVLHWC5_exports, {
21
21
  extractPreviewFeatures: () => extractPreviewFeatures
22
22
  });
23
- module.exports = __toCommonJS(chunk_TSJICM5S_exports);
23
+ module.exports = __toCommonJS(chunk_CRVLHWC5_exports);
24
24
  var import_chunk_IOIAK7V7 = require("./chunk-IOIAK7V7.js");
25
- function extractPreviewFeatures(config) {
26
- return config.generators.find((g) => (0, import_chunk_IOIAK7V7.parseEnvValue)(g.provider) === "prisma-client-js")?.previewFeatures || [];
25
+ function extractPreviewFeatures(generators) {
26
+ return generators.find((g) => (0, import_chunk_IOIAK7V7.parseEnvValue)(g.provider) === "prisma-client-js")?.previewFeatures || [];
27
27
  }
@@ -26,29 +26,28 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_WUCN2R47_exports = {};
30
- __export(chunk_WUCN2R47_exports, {
29
+ var chunk_CXHJXPSQ_exports = {};
30
+ __export(chunk_CXHJXPSQ_exports, {
31
31
  GetConfigError: () => GetConfigError,
32
32
  getConfig: () => getConfig,
33
33
  getDirectUrl: () => getDirectUrl,
34
34
  getEffectiveUrl: () => getEffectiveUrl,
35
35
  resolveUrl: () => resolveUrl
36
36
  });
37
- module.exports = __toCommonJS(chunk_WUCN2R47_exports);
38
- var import_chunk_YRBRUREX = require("./chunk-YRBRUREX.js");
39
- var import_chunk_6TXVGFQA = require("./chunk-6TXVGFQA.js");
37
+ module.exports = __toCommonJS(chunk_CXHJXPSQ_exports);
38
+ var import_chunk_WSZXPLJQ = require("./chunk-WSZXPLJQ.js");
39
+ var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
40
40
  var import_chunk_C47SCASR = require("./chunk-C47SCASR.js");
41
- var import_chunk_ZWOYFHSK = require("./chunk-ZWOYFHSK.js");
42
- var import_chunk_PFLLVWZX = require("./chunk-PFLLVWZX.js");
41
+ var import_chunk_O77NRE3W = require("./chunk-O77NRE3W.js");
42
+ var import_chunk_X6ECL5J5 = require("./chunk-X6ECL5J5.js");
43
+ var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
43
44
  var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
44
- var import_chunk_5CJA6QCN = require("./chunk-5CJA6QCN.js");
45
- var import_chunk_ATFQZVBS = require("./chunk-ATFQZVBS.js");
46
- var import_chunk_7MD6344A = require("./chunk-7MD6344A.js");
45
+ var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
47
46
  var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
48
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
47
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
49
48
  var import_debug = __toESM(require("@prisma/debug"));
50
49
  var import_get_platform = require("@prisma/get-platform");
51
- var import_function = (0, import_chunk_WWAWV7DQ.__toESM)((0, import_chunk_PFLLVWZX.require_function)());
50
+ var import_function = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_R6QH57HZ.require_function)());
52
51
  var debug = (0, import_debug.default)("prisma:getConfig");
53
52
  var SCHEMA_VALIDATION_ERROR_CODE = "P1012";
54
53
  var GetConfigError = class extends Error {
@@ -65,7 +64,7 @@ ${detailsHeader} ${message}`;
65
64
  }).exhaustive();
66
65
  const errorMessageWithContext = `${constructedErrorMessage}
67
66
  [Context: getConfig]`;
68
- super((0, import_chunk_ZWOYFHSK.addVersionDetailsToErrorMessage)(errorMessageWithContext));
67
+ super((0, import_chunk_O77NRE3W.addVersionDetailsToErrorMessage)(errorMessageWithContext));
69
68
  this.name = "GetConfigError";
70
69
  }
71
70
  };
@@ -83,14 +82,14 @@ function resolveUrl(envValue) {
83
82
  return urlFromValue ?? urlEnvVarValue;
84
83
  }
85
84
  async function getConfig(options) {
86
- const debugErrorType = (0, import_chunk_6TXVGFQA.createDebugErrorType)(debug, "getConfigWasm");
85
+ const debugErrorType = (0, import_chunk_WSZXPLJQ.createDebugErrorType)(debug, "getConfigWasm");
87
86
  debug(`Using getConfig Wasm`);
88
87
  const configEither = (0, import_function.pipe)(
89
- (0, import_chunk_7MD6344A.tryCatch)(
88
+ (0, import_chunk_5DBOS77Y.tryCatch)(
90
89
  () => {
91
90
  if (process.env.FORCE_PANIC_QUERY_ENGINE_GET_CONFIG) {
92
91
  debug("Triggering a Rust panic...");
93
- import_chunk_5CJA6QCN.prismaSchemaWasm.debug_panic();
92
+ import_chunk_X6ECL5J5.prismaSchemaWasm.debug_panic();
94
93
  }
95
94
  const params = JSON.stringify({
96
95
  prismaSchema: options.datamodel,
@@ -98,7 +97,7 @@ async function getConfig(options) {
98
97
  ignoreEnvVarErrors: options.ignoreEnvVarErrors ?? false,
99
98
  env: process.env
100
99
  });
101
- const data = import_chunk_5CJA6QCN.prismaSchemaWasm.get_config(params);
100
+ const data = import_chunk_X6ECL5J5.prismaSchemaWasm.get_config(params);
102
101
  return data;
103
102
  },
104
103
  (e) => ({
@@ -107,11 +106,11 @@ async function getConfig(options) {
107
106
  error: e
108
107
  })
109
108
  ),
110
- (0, import_chunk_7MD6344A.map)((result) => ({ result })),
111
- (0, import_chunk_7MD6344A.chainW)(
109
+ (0, import_chunk_5DBOS77Y.map)((result) => ({ result })),
110
+ (0, import_chunk_5DBOS77Y.chainW)(
112
111
  ({ result }) => (
113
112
  // NOTE: this should never fail, as we expect returned values to be valid JSON-serializable strings
114
- (0, import_chunk_7MD6344A.tryCatch)(
113
+ (0, import_chunk_5DBOS77Y.tryCatch)(
115
114
  () => JSON.parse(result),
116
115
  (e) => ({
117
116
  type: "parse-json",
@@ -121,18 +120,18 @@ async function getConfig(options) {
121
120
  )
122
121
  )
123
122
  ),
124
- (0, import_chunk_7MD6344A.chainW)((response) => {
123
+ (0, import_chunk_5DBOS77Y.chainW)((response) => {
125
124
  if (response.errors.length > 0) {
126
- return (0, import_chunk_7MD6344A.left)({
125
+ return (0, import_chunk_5DBOS77Y.left)({
127
126
  type: "validation-error",
128
127
  reason: "(get-config wasm)",
129
128
  error: response.errors
130
129
  });
131
130
  }
132
- return (0, import_chunk_7MD6344A.right)(response.config);
131
+ return (0, import_chunk_5DBOS77Y.right)(response.config);
133
132
  })
134
133
  );
135
- if ((0, import_chunk_7MD6344A.isRight)(configEither)) {
134
+ if ((0, import_chunk_5DBOS77Y.isRight)(configEither)) {
136
135
  debug("config data retrieved without errors in getConfig Wasm");
137
136
  const { right: data } = configEither;
138
137
  for (const generator of data.generators) {
@@ -142,30 +141,27 @@ async function getConfig(options) {
142
141
  }
143
142
  const error = (0, import_chunk_XKZ6CBLA.z)(configEither.left).with({ type: "wasm-error" }, (e) => {
144
143
  debugErrorType(e);
145
- if ((0, import_chunk_ATFQZVBS.isWasmPanic)(e.error)) {
146
- const { message, stack } = (0, import_chunk_ATFQZVBS.getWasmError)(e.error);
147
- const panic = new import_chunk_ATFQZVBS.RustPanic(
144
+ if ((0, import_chunk_LMVSIVKQ.isWasmPanic)(e.error)) {
145
+ const { message, stack } = (0, import_chunk_LMVSIVKQ.getWasmError)(e.error);
146
+ const panic = new import_chunk_LMVSIVKQ.RustPanic(
148
147
  /* message */
149
148
  message,
150
149
  /* rustStack */
151
150
  stack,
152
151
  /* request */
153
152
  "@prisma/prisma-schema-wasm get_config",
154
- "FMT_CLI",
155
- /* schemaPath */
156
- options.prismaPath,
157
- /* schema */
158
- (0, import_chunk_YRBRUREX.toMultipleSchemas)(options.datamodel)
153
+ "FMT_CLI"
154
+ /* FMT_CLI */
159
155
  );
160
156
  return panic;
161
157
  }
162
158
  const errorOutput = e.error.message;
163
- return new GetConfigError((0, import_chunk_6TXVGFQA.parseQueryEngineError)({ errorOutput, reason: e.reason }));
159
+ return new GetConfigError((0, import_chunk_WSZXPLJQ.parseQueryEngineError)({ errorOutput, reason: e.reason }));
164
160
  }).with({ type: "validation-error" }, (e) => {
165
161
  return new GetConfigError({
166
162
  _tag: "parsed",
167
163
  errorCode: SCHEMA_VALIDATION_ERROR_CODE,
168
- reason: (0, import_chunk_6TXVGFQA.createSchemaValidationError)(e.reason),
164
+ reason: (0, import_chunk_WSZXPLJQ.createSchemaValidationError)(e.reason),
169
165
  message: formatErrors(e.error)
170
166
  });
171
167
  }).otherwise((e) => {
@@ -26,18 +26,18 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_SHJNE6T7_exports = {};
30
- __export(chunk_SHJNE6T7_exports, {
29
+ var chunk_D4VDA2TZ_exports = {};
30
+ __export(chunk_D4VDA2TZ_exports, {
31
31
  locateLocalCloudflareD1: () => locateLocalCloudflareD1
32
32
  });
33
- module.exports = __toCommonJS(chunk_SHJNE6T7_exports);
33
+ module.exports = __toCommonJS(chunk_D4VDA2TZ_exports);
34
34
  var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
35
- var import_chunk_53LS3WUO = require("./chunk-53LS3WUO.js");
36
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
35
+ var import_chunk_JOIIWB3U = require("./chunk-JOIIWB3U.js");
36
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
37
37
  var import_node_path = __toESM(require("node:path"));
38
38
  var import_node_process = __toESM(require("node:process"));
39
- var import_fast_glob = (0, import_chunk_WWAWV7DQ.__toESM)((0, import_chunk_53LS3WUO.require_out)());
40
- var import_globby = (0, import_chunk_WWAWV7DQ.__toESM)((0, import_chunk_53LS3WUO.require_globby)());
39
+ var import_fast_glob = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_JOIIWB3U.require_out)());
40
+ var import_globby = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_JOIIWB3U.require_globby)());
41
41
  var defaultD1DirPath = import_node_path.default.join(".wrangler", "state", "v3", "d1", "miniflare-D1DatabaseObject");
42
42
  async function locateLocalCloudflareD1({ arg }) {
43
43
  const cwd = import_node_process.default.cwd();
@@ -26,16 +26,16 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_Q22BLLK3_exports = {};
30
- __export(chunk_Q22BLLK3_exports, {
29
+ var chunk_D4VZUY3O_exports = {};
30
+ __export(chunk_D4VZUY3O_exports, {
31
31
  arg: () => arg,
32
32
  format: () => format,
33
33
  isError: () => isError
34
34
  });
35
- module.exports = __toCommonJS(chunk_Q22BLLK3_exports);
36
- var import_chunk_WWAWV7DQ = require("./chunk-WWAWV7DQ.js");
35
+ module.exports = __toCommonJS(chunk_D4VZUY3O_exports);
36
+ var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
37
37
  var import_arg = __toESM(require("arg"));
38
- var require_min_indent = (0, import_chunk_WWAWV7DQ.__commonJS)({
38
+ var require_min_indent = (0, import_chunk_4VNS5WPM.__commonJS)({
39
39
  "../../node_modules/.pnpm/min-indent@1.0.1/node_modules/min-indent/index.js"(exports, module2) {
40
40
  "use strict";
41
41
  module2.exports = (string) => {
@@ -47,7 +47,7 @@ var require_min_indent = (0, import_chunk_WWAWV7DQ.__commonJS)({
47
47
  };
48
48
  }
49
49
  });
50
- var import_min_indent = (0, import_chunk_WWAWV7DQ.__toESM)(require_min_indent(), 1);
50
+ var import_min_indent = (0, import_chunk_4VNS5WPM.__toESM)(require_min_indent(), 1);
51
51
  function stripIndent(string) {
52
52
  const indent = (0, import_min_indent.default)(string);
53
53
  if (indent === 0) {