@prisma/internals 6.19.0-integration-engines-6-19-0-30-push-otuqumlrponx-17ff4a7bd0bffdf0b40b58a399869660f7f0e368.1 → 6.19.0-integration-feat-remove-library-engine.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-GMW36QQF.js → chunk-22HIO2UL.js} +7 -7
- package/dist/{chunk-JOIIWB3U.js → chunk-2LOGW45F.js} +68 -33
- package/dist/{chunk-SVOYDVK6.js → chunk-2MJNNWBQ.js} +8 -8
- package/dist/{chunk-BVJP43JS.js → chunk-32LLAKF4.js} +13 -784
- package/dist/{chunk-AX5N26KG.js → chunk-33K2EQQZ.js} +10 -10
- package/dist/{chunk-I6WLABB2.js → chunk-3WXUQZS7.js} +14 -5
- package/dist/{chunk-RS2R7COT.js → chunk-5I4ERIIY.js} +3 -9
- package/dist/{chunk-F2OZV76L.js → chunk-5MHUYAV3.js} +9 -9
- package/dist/{chunk-HO5HRHFZ.js → chunk-5W3BSMTH.js} +3 -6
- package/dist/{chunk-46ABODUM.js → chunk-6QTN4DDB.js} +6 -21
- package/dist/{chunk-72WT7DK3.js → chunk-7TNL2X5G.js} +5 -5
- package/dist/{chunk-YQECHDTJ.js → chunk-AAXLNSYL.js} +5 -5
- package/dist/{chunk-6MRKNTJD.js → chunk-AOJ2N25Z.js} +8 -8
- package/dist/{chunk-WFNB7VRA.js → chunk-ARC7TW3L.js} +4 -14
- package/dist/{chunk-HFFWZTVM.js → chunk-BUQN4WLU.js} +7 -9
- package/dist/{chunk-MEMPRTWR.js → chunk-BZV6PVWV.js} +8 -8
- package/dist/{chunk-HHG4DGHC.js → chunk-CGLLQXZE.js} +11 -12
- package/dist/{chunk-47SAWGTD.js → chunk-D7L3VT6R.js} +8 -8
- package/dist/chunk-DYV47NUW.js +796 -0
- package/dist/{chunk-C4DCOB35.js → chunk-EBJBIVXN.js} +5 -5
- package/dist/{chunk-IDINCQMN.js → chunk-FF7OLLBP.js} +12 -784
- package/dist/{chunk-ECMR3OBL.js → chunk-FSQCVENL.js} +7 -7
- package/dist/{chunk-PZMRR772.js → chunk-FURGECAD.js} +6 -6
- package/dist/{chunk-4CGPN5SR.js → chunk-GJSFP4V4.js} +3 -9
- package/dist/{chunk-4JCVHBYR.js → chunk-GL7OANR6.js} +5 -5
- package/dist/{chunk-OAT7ZJED.js → chunk-H5STSTVK.js} +7 -20
- package/dist/{chunk-7QC5VORA.js → chunk-H6PPJ5PX.js} +7 -7
- package/dist/{chunk-FYZCPL2Z.js → chunk-HNRMSI3R.js} +5 -8
- package/dist/{chunk-D4VDA2TZ.js → chunk-IRWX4FCC.js} +6 -6
- package/dist/{chunk-UQUWZJVN.js → chunk-IU77SCOB.js} +9 -9
- package/dist/{chunk-FXUEE7XX.js → chunk-KD7PGGJP.js} +8 -8
- package/dist/{chunk-NVNI2SRU.js → chunk-KNNTV7IN.js} +687 -213
- package/dist/{chunk-5AI4FIZ3.js → chunk-MEOOYUIZ.js} +10 -10
- package/dist/{chunk-L5ZWEYO7.js → chunk-MUZJUPDX.js} +7 -7
- package/dist/{chunk-TQFONRJP.js → chunk-MXAUURHG.js} +5 -5
- package/dist/{chunk-PPB7JLDO.js → chunk-NNYJV66S.js} +5 -5
- package/dist/{chunk-ZBUC6PZX.js → chunk-NVSVTFPX.js} +5 -5
- package/dist/{chunk-EYVG6XQS.js → chunk-OKVM3CW4.js} +3 -39
- package/dist/{chunk-46MGVXWZ.js → chunk-P4JEYG25.js} +5 -5
- package/dist/{chunk-VMKOB234.js → chunk-QQRYY5P4.js} +8 -8
- package/dist/{chunk-FCYHZHVW.js → chunk-R3J2O23S.js} +4 -4
- package/dist/{chunk-4L35EYLD.js → chunk-SFKBYZWG.js} +38 -66
- package/dist/{chunk-AMETUICR.js → chunk-TAKL4AGJ.js} +8 -8
- package/dist/{chunk-75BIJ5PX.js → chunk-UB2X7DGZ.js} +9 -9
- package/dist/{chunk-W7LDAWJF.js → chunk-UMB3Y33W.js} +7 -7
- package/dist/{chunk-TQCLUNM2.js → chunk-VNIE2AZB.js} +4 -4
- package/dist/{chunk-UHI6VYFX.js → chunk-WJKBKH3Y.js} +5 -5
- package/dist/{chunk-ZCMRWYQK.js → chunk-Z2IPE4NA.js} +38 -66
- package/dist/{chunk-DRMVYKKF.js → chunk-ZEBJSCAV.js} +5 -5
- package/dist/{chunk-ZY7BAIKC.js → chunk-ZVTQSH5K.js} +5 -5
- package/dist/cli/checkUnsupportedDataProxy.js +52 -54
- package/dist/cli/checkUnsupportedSchemaEngineWasm.js +52 -54
- package/dist/cli/getGeneratorSuccessMessage.js +2 -3
- package/dist/cli/getSchema.d.ts +1 -15
- package/dist/cli/getSchema.js +4 -5
- package/dist/cli/hashes.js +4 -4
- package/dist/cli/schemaContext.js +52 -54
- package/dist/engine-commands/errorHelpers.js +4 -4
- package/dist/engine-commands/formatSchema.js +51 -53
- package/dist/engine-commands/getConfig.js +10 -10
- package/dist/engine-commands/getDmmf.js +7 -7
- package/dist/engine-commands/getEngineVersion.js +6 -9
- package/dist/engine-commands/getEnginesInfo.d.ts +0 -1
- package/dist/engine-commands/getEnginesInfo.js +7 -9
- package/dist/engine-commands/index.js +63 -65
- package/dist/engine-commands/lintSchema.js +8 -8
- package/dist/engine-commands/mergeSchemas.js +7 -7
- package/dist/engine-commands/validate.js +7 -7
- package/dist/errorReporting.js +6 -6
- package/dist/get-generators/getGenerators.d.ts +0 -1
- package/dist/get-generators/getGenerators.js +54 -56
- package/dist/get-generators/utils/binaryTypeToEngineType.js +2 -2
- package/dist/get-generators/utils/engineTypeToBinaryType.js +2 -2
- package/dist/get-generators/utils/getBinaryPathsByVersion.js +6 -5
- package/dist/getPackedPackage.js +4 -3
- package/dist/highlight/highlight.js +5 -5
- package/dist/index.d.ts +1 -4
- package/dist/index.js +102 -109
- package/dist/{multipart-parser-3AFJFP6K.js → multipart-parser-UV3WZSWW.js} +6 -6
- package/dist/resolveBinary.js +8 -7
- package/dist/schemaEngineCommands.js +9 -8
- package/dist/sendPanic.js +4 -4
- package/dist/utils/canPrompt.js +3 -3
- package/dist/utils/cloudflareD1.js +3 -3
- package/dist/utils/drawBox.js +2 -2
- package/dist/utils/fs-functional.js +10 -10
- package/dist/utils/fs-utils.js +8 -8
- package/dist/utils/getEnvPaths.d.ts +1 -1
- package/dist/utils/getEnvPaths.js +2 -3
- package/dist/utils/getVersionFromPackageJson.js +3 -3
- package/dist/utils/handlePanic.js +8 -8
- package/dist/utils/link.js +2 -2
- package/dist/utils/loadEnvFile.d.ts +1 -1
- package/dist/utils/loadEnvFile.js +3 -4
- package/dist/utils/missingDatasource.js +5 -5
- package/dist/utils/missingGeneratorMessage.js +7 -7
- package/dist/utils/serializeQueryEngineName.js +2 -2
- package/dist/wasm.js +5 -5
- package/package.json +15 -15
- package/dist/chunk-6TTRTZXU.js +0 -37
- package/dist/chunk-DZYINYAA.js +0 -68
- package/dist/chunk-ERSH2BQA.js +0 -58
- package/dist/client/getClientEngineType.d.ts +0 -7
- package/dist/client/getClientEngineType.js +0 -26
- package/dist/utils/handleEngineLoadingErrors.d.ts +0 -8
- package/dist/utils/handleEngineLoadingErrors.js +0 -27
- package/dist/utils/load.d.ts +0 -6
- package/dist/utils/load.js +0 -28
|
@@ -16,15 +16,15 @@ 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
|
|
20
|
-
__export(
|
|
19
|
+
var chunk_33K2EQQZ_exports = {};
|
|
20
|
+
__export(chunk_33K2EQQZ_exports, {
|
|
21
21
|
missingGeneratorMessage: () => missingGeneratorMessage,
|
|
22
22
|
missingModelMessage: () => missingModelMessage,
|
|
23
23
|
missingModelMessageMongoDB: () => missingModelMessageMongoDB
|
|
24
24
|
});
|
|
25
|
-
module.exports = __toCommonJS(
|
|
26
|
-
var
|
|
27
|
-
var
|
|
25
|
+
module.exports = __toCommonJS(chunk_33K2EQQZ_exports);
|
|
26
|
+
var import_chunk_3WXUQZS7 = require("./chunk-3WXUQZS7.js");
|
|
27
|
+
var import_chunk_VNIE2AZB = require("./chunk-VNIE2AZB.js");
|
|
28
28
|
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
29
29
|
var missingGeneratorMessage = `
|
|
30
30
|
${(0, import_chunk_PG5FDKSF.blue)("info")} You don't have any generators defined in your ${(0, import_chunk_PG5FDKSF.bold)(
|
|
@@ -33,7 +33,7 @@ ${(0, import_chunk_PG5FDKSF.blue)("info")} You don't have any generators defined
|
|
|
33
33
|
You can define them like this:
|
|
34
34
|
|
|
35
35
|
${(0, import_chunk_PG5FDKSF.bold)(
|
|
36
|
-
(0,
|
|
36
|
+
(0, import_chunk_VNIE2AZB.highlightDatamodel)(`generator client {
|
|
37
37
|
provider = "prisma-client-js"
|
|
38
38
|
}`)
|
|
39
39
|
)}`;
|
|
@@ -44,7 +44,7 @@ You don't have any ${(0, import_chunk_PG5FDKSF.bold)("models")} defined in your
|
|
|
44
44
|
You can define a model like this:
|
|
45
45
|
|
|
46
46
|
${(0, import_chunk_PG5FDKSF.bold)(
|
|
47
|
-
(0,
|
|
47
|
+
(0, import_chunk_VNIE2AZB.highlightDatamodel)(`model User {
|
|
48
48
|
id Int @id @default(autoincrement())
|
|
49
49
|
email String @unique
|
|
50
50
|
name String?
|
|
@@ -52,7 +52,7 @@ ${(0, import_chunk_PG5FDKSF.bold)(
|
|
|
52
52
|
)}
|
|
53
53
|
|
|
54
54
|
More information in our documentation:
|
|
55
|
-
${(0,
|
|
55
|
+
${(0, import_chunk_3WXUQZS7.link)("https://pris.ly/d/prisma-schema")}
|
|
56
56
|
`;
|
|
57
57
|
var missingModelMessageMongoDB = `
|
|
58
58
|
You don't have any ${(0, import_chunk_PG5FDKSF.bold)("models")} defined in your ${(0, import_chunk_PG5FDKSF.bold)(
|
|
@@ -61,7 +61,7 @@ You don't have any ${(0, import_chunk_PG5FDKSF.bold)("models")} defined in your
|
|
|
61
61
|
You can define a model like this:
|
|
62
62
|
|
|
63
63
|
${(0, import_chunk_PG5FDKSF.bold)(
|
|
64
|
-
(0,
|
|
64
|
+
(0, import_chunk_VNIE2AZB.highlightDatamodel)(`model User {
|
|
65
65
|
id String @id @default(auto()) @map("_id") @db.ObjectId
|
|
66
66
|
email String @unique
|
|
67
67
|
name String?
|
|
@@ -69,5 +69,5 @@ ${(0, import_chunk_PG5FDKSF.bold)(
|
|
|
69
69
|
)}
|
|
70
70
|
|
|
71
71
|
More information in our documentation:
|
|
72
|
-
${(0,
|
|
72
|
+
${(0, import_chunk_3WXUQZS7.link)("https://pris.ly/d/prisma-schema")}
|
|
73
73
|
`;
|
|
@@ -26,11 +26,11 @@ 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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_3WXUQZS7_exports = {};
|
|
30
|
+
__export(chunk_3WXUQZS7_exports, {
|
|
31
31
|
link: () => link2
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
33
|
+
module.exports = __toCommonJS(chunk_3WXUQZS7_exports);
|
|
34
34
|
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
35
35
|
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
36
36
|
var import_node_process = __toESM(require("node:process"));
|
|
@@ -245,9 +245,11 @@ var require_supports_hyperlinks = (0, import_chunk_4VNS5WPM.__commonJS)({
|
|
|
245
245
|
});
|
|
246
246
|
var base_exports = {};
|
|
247
247
|
(0, import_chunk_4VNS5WPM.__export)(base_exports, {
|
|
248
|
+
ConEmu: () => ConEmu,
|
|
248
249
|
beep: () => beep,
|
|
249
250
|
clearScreen: () => clearScreen,
|
|
250
251
|
clearTerminal: () => clearTerminal,
|
|
252
|
+
clearViewport: () => clearViewport,
|
|
251
253
|
cursorBackward: () => cursorBackward,
|
|
252
254
|
cursorDown: () => cursorDown,
|
|
253
255
|
cursorForward: () => cursorForward,
|
|
@@ -275,7 +277,8 @@ var base_exports = {};
|
|
|
275
277
|
image: () => image,
|
|
276
278
|
link: () => link,
|
|
277
279
|
scrollDown: () => scrollDown,
|
|
278
|
-
scrollUp: () => scrollUp
|
|
280
|
+
scrollUp: () => scrollUp,
|
|
281
|
+
setCwd: () => setCwd
|
|
279
282
|
});
|
|
280
283
|
var isBrowser = globalThis.window?.document !== void 0;
|
|
281
284
|
var isNode = globalThis.process?.versions?.node !== void 0;
|
|
@@ -359,6 +362,7 @@ var eraseScreen = ESC + "2J";
|
|
|
359
362
|
var scrollUp = ESC + "S";
|
|
360
363
|
var scrollDown = ESC + "T";
|
|
361
364
|
var clearScreen = "\x1Bc";
|
|
365
|
+
var clearViewport = `${eraseScreen}${ESC}H`;
|
|
362
366
|
var clearTerminal = isWindows2 ? `${eraseScreen}${ESC}0f` : `${eraseScreen}${ESC}3J${ESC}H`;
|
|
363
367
|
var enterAlternativeScreen = ESC + "?1049h";
|
|
364
368
|
var exitAlternativeScreen = ESC + "?1049l";
|
|
@@ -388,7 +392,8 @@ var image = (data, options = {}) => {
|
|
|
388
392
|
if (options.preserveAspectRatio === false) {
|
|
389
393
|
returnValue += ";preserveAspectRatio=0";
|
|
390
394
|
}
|
|
391
|
-
|
|
395
|
+
const imageBuffer = Buffer.from(data);
|
|
396
|
+
return returnValue + `;size=${imageBuffer.byteLength}:` + imageBuffer.toString("base64") + BEL;
|
|
392
397
|
};
|
|
393
398
|
var iTerm = {
|
|
394
399
|
setCwd: (cwd = cwdFunction()) => `${OSC}50;CurrentDir=${cwd}${BEL}`,
|
|
@@ -409,6 +414,10 @@ var iTerm = {
|
|
|
409
414
|
return returnValue + BEL;
|
|
410
415
|
}
|
|
411
416
|
};
|
|
417
|
+
var ConEmu = {
|
|
418
|
+
setCwd: (cwd = cwdFunction()) => `${OSC}9;9;${cwd}${BEL}`
|
|
419
|
+
};
|
|
420
|
+
var setCwd = (cwd = cwdFunction()) => iTerm.setCwd(cwd) + ConEmu.setCwd(cwd);
|
|
412
421
|
var import_supports_hyperlinks = (0, import_chunk_4VNS5WPM.__toESM)(require_supports_hyperlinks(), 1);
|
|
413
422
|
function terminalLink(text, url, { target = "stdout", ...options } = {}) {
|
|
414
423
|
if (!import_supports_hyperlinks.default[target]) {
|
|
@@ -16,21 +16,15 @@ 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
|
|
20
|
-
__export(
|
|
19
|
+
var chunk_5I4ERIIY_exports = {};
|
|
20
|
+
__export(chunk_5I4ERIIY_exports, {
|
|
21
21
|
binaryTypeToEngineType: () => binaryTypeToEngineType
|
|
22
22
|
});
|
|
23
|
-
module.exports = __toCommonJS(
|
|
23
|
+
module.exports = __toCommonJS(chunk_5I4ERIIY_exports);
|
|
24
24
|
var import_fetch_engine = require("@prisma/fetch-engine");
|
|
25
25
|
function binaryTypeToEngineType(binaryType) {
|
|
26
26
|
if (binaryType === import_fetch_engine.BinaryType.SchemaEngineBinary) {
|
|
27
27
|
return "schemaEngine";
|
|
28
28
|
}
|
|
29
|
-
if (binaryType === import_fetch_engine.BinaryType.QueryEngineLibrary) {
|
|
30
|
-
return "libqueryEngine";
|
|
31
|
-
}
|
|
32
|
-
if (binaryType === import_fetch_engine.BinaryType.QueryEngineBinary) {
|
|
33
|
-
return "queryEngine";
|
|
34
|
-
}
|
|
35
29
|
throw new Error(`Could not convert binary type ${binaryType}`);
|
|
36
30
|
}
|
|
@@ -26,21 +26,21 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_5MHUYAV3_exports = {};
|
|
30
|
+
__export(chunk_5MHUYAV3_exports, {
|
|
31
31
|
getBinaryPathsByVersion: () => getBinaryPathsByVersion
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
34
|
-
var
|
|
35
|
-
var
|
|
33
|
+
module.exports = __toCommonJS(chunk_5MHUYAV3_exports);
|
|
34
|
+
var import_chunk_5I4ERIIY = require("./chunk-5I4ERIIY.js");
|
|
35
|
+
var import_chunk_GJSFP4V4 = require("./chunk-GJSFP4V4.js");
|
|
36
36
|
var import_chunk_2SDPW6AX = require("./chunk-2SDPW6AX.js");
|
|
37
37
|
var import_chunk_7B5PXS6N = require("./chunk-7B5PXS6N.js");
|
|
38
|
-
var
|
|
38
|
+
var import_chunk_FF7OLLBP = require("./chunk-FF7OLLBP.js");
|
|
39
39
|
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
40
40
|
var import_engines = require("@prisma/engines");
|
|
41
41
|
var import_fetch_engine = require("@prisma/fetch-engine");
|
|
42
42
|
var import_path = __toESM2(require("path"));
|
|
43
|
-
var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0,
|
|
43
|
+
var import_fs_extra = (0, import_chunk_4VNS5WPM.__toESM)((0, import_chunk_FF7OLLBP.require_lib)());
|
|
44
44
|
async function getBinaryPathsByVersion({
|
|
45
45
|
neededVersions,
|
|
46
46
|
detectBinaryTarget,
|
|
@@ -91,7 +91,7 @@ async function getBinaryPathsByVersion({
|
|
|
91
91
|
}
|
|
92
92
|
const binariesConfig = neededVersion.engines.reduce((acc, curr) => {
|
|
93
93
|
if (!binaryPathsOverride?.[curr]) {
|
|
94
|
-
acc[(0,
|
|
94
|
+
acc[(0, import_chunk_GJSFP4V4.engineTypeToBinaryType)(curr)] = binaryTargetBaseDir;
|
|
95
95
|
}
|
|
96
96
|
return acc;
|
|
97
97
|
}, /* @__PURE__ */ Object.create(null));
|
|
@@ -107,7 +107,7 @@ async function getBinaryPathsByVersion({
|
|
|
107
107
|
skipDownload
|
|
108
108
|
};
|
|
109
109
|
const binaryPathsWithEngineType = await (0, import_fetch_engine.download)(downloadParams);
|
|
110
|
-
const binaryPaths = (0, import_chunk_7B5PXS6N.mapKeys)(binaryPathsWithEngineType,
|
|
110
|
+
const binaryPaths = (0, import_chunk_7B5PXS6N.mapKeys)(binaryPathsWithEngineType, import_chunk_5I4ERIIY.binaryTypeToEngineType);
|
|
111
111
|
binaryPathsByVersion[currentVersion] = binaryPaths;
|
|
112
112
|
}
|
|
113
113
|
if (binaryPathsOverride) {
|
|
@@ -16,15 +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
|
|
20
|
-
__export(
|
|
19
|
+
var chunk_5W3BSMTH_exports = {};
|
|
20
|
+
__export(chunk_5W3BSMTH_exports, {
|
|
21
21
|
serializeQueryEngineName: () => serializeQueryEngineName
|
|
22
22
|
});
|
|
23
|
-
module.exports = __toCommonJS(
|
|
23
|
+
module.exports = __toCommonJS(chunk_5W3BSMTH_exports);
|
|
24
24
|
function serializeQueryEngineName(message) {
|
|
25
25
|
const normalizedName = "query-engine-NORMALIZED";
|
|
26
|
-
if (process.env.PRISMA_CLI_QUERY_ENGINE_TYPE === "binary") {
|
|
27
|
-
return message.replace(/query-engine binary/g, normalizedName);
|
|
28
|
-
}
|
|
29
26
|
return message.replace(/query-engine-node-api library/g, normalizedName);
|
|
30
27
|
}
|
|
@@ -26,13 +26,12 @@ 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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_6QTN4DDB_exports = {};
|
|
30
|
+
__export(chunk_6QTN4DDB_exports, {
|
|
31
31
|
getEnvPaths: () => getEnvPaths
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
33
|
+
module.exports = __toCommonJS(chunk_6QTN4DDB_exports);
|
|
34
34
|
var import_chunk_3FP46GUV = require("./chunk-3FP46GUV.js");
|
|
35
|
-
var import_chunk_EYVG6XQS = require("./chunk-EYVG6XQS.js");
|
|
36
35
|
var import_debug = __toESM(require("@prisma/debug"));
|
|
37
36
|
var import_node_path = __toESM(require("node:path"));
|
|
38
37
|
var import_node_process = __toESM(require("node:process"));
|
|
@@ -127,34 +126,20 @@ function findUpSync(name, options = {}) {
|
|
|
127
126
|
return matches[0];
|
|
128
127
|
}
|
|
129
128
|
var debug = (0, import_debug.default)("prisma:loadEnv");
|
|
130
|
-
|
|
129
|
+
function getEnvPaths(schemaPath, opts = { cwd: process.cwd() }) {
|
|
131
130
|
const rootEnvPath = getProjectRootEnvPath({ cwd: opts.cwd }) ?? null;
|
|
132
131
|
const schemaEnvPathFromArgs = schemaPathToEnvPath(schemaPath);
|
|
133
|
-
const schemaEnvPathFromPkgJson = schemaPathToEnvPath(await readSchemaPathFromPkgJson());
|
|
134
132
|
const schemaEnvPaths = [
|
|
135
133
|
schemaEnvPathFromArgs,
|
|
136
134
|
// 1 - Check --schema directory for .env
|
|
137
|
-
schemaEnvPathFromPkgJson,
|
|
138
|
-
// 2 - Check package.json schema directory for .env
|
|
139
135
|
"./prisma/.env",
|
|
140
|
-
//
|
|
136
|
+
// 2 - Check ./prisma directory for .env
|
|
141
137
|
"./.env"
|
|
142
|
-
//
|
|
138
|
+
// 3 - Check cwd for .env
|
|
143
139
|
];
|
|
144
140
|
const schemaEnvPath = schemaEnvPaths.find(import_chunk_3FP46GUV.exists);
|
|
145
141
|
return { rootEnvPath, schemaEnvPath };
|
|
146
142
|
}
|
|
147
|
-
async function readSchemaPathFromPkgJson() {
|
|
148
|
-
try {
|
|
149
|
-
const pkgJsonSchema = await (0, import_chunk_EYVG6XQS.getSchemaFromPackageJson)(process.cwd());
|
|
150
|
-
if (pkgJsonSchema.ok) {
|
|
151
|
-
pkgJsonSchema.schema.schemaPath;
|
|
152
|
-
}
|
|
153
|
-
return null;
|
|
154
|
-
} catch {
|
|
155
|
-
return null;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
143
|
function getProjectRootEnvPath(opts) {
|
|
159
144
|
const pkgJsonPath = findUpSync((dir) => {
|
|
160
145
|
const pkgPath = import_path.default.join(dir, "package.json");
|
|
@@ -16,20 +16,20 @@ 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
|
|
20
|
-
__export(
|
|
19
|
+
var chunk_7TNL2X5G_exports = {};
|
|
20
|
+
__export(chunk_7TNL2X5G_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(
|
|
28
|
-
var
|
|
27
|
+
module.exports = __toCommonJS(chunk_7TNL2X5G_exports);
|
|
28
|
+
var import_chunk_AAXLNSYL = require("./chunk-AAXLNSYL.js");
|
|
29
29
|
var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
|
|
30
30
|
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
31
31
|
function lintSchema({ schemas }) {
|
|
32
|
-
const lintResult =
|
|
32
|
+
const lintResult = import_chunk_AAXLNSYL.prismaSchemaWasm.lint(JSON.stringify(schemas));
|
|
33
33
|
const lintDiagnostics = JSON.parse(lintResult);
|
|
34
34
|
return lintDiagnostics;
|
|
35
35
|
}
|
|
@@ -26,15 +26,15 @@ 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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_AAXLNSYL_exports = {};
|
|
30
|
+
__export(chunk_AAXLNSYL_exports, {
|
|
31
31
|
prismaSchemaWasm: () => import_prisma_schema_wasm.default,
|
|
32
32
|
prismaSchemaWasmVersion: () => prismaSchemaWasmVersion,
|
|
33
33
|
schemaEngineWasmVersion: () => schemaEngineWasmVersion,
|
|
34
34
|
wasm_exports: () => wasm_exports
|
|
35
35
|
});
|
|
36
|
-
module.exports = __toCommonJS(
|
|
37
|
-
var
|
|
36
|
+
module.exports = __toCommonJS(chunk_AAXLNSYL_exports);
|
|
37
|
+
var import_chunk_QQRYY5P4 = require("./chunk-QQRYY5P4.js");
|
|
38
38
|
var import_chunk_WXRVYSYN = require("./chunk-WXRVYSYN.js");
|
|
39
39
|
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
40
40
|
var import_prisma_schema_wasm = __toESM(require("@prisma/prisma-schema-wasm"));
|
|
@@ -46,6 +46,6 @@ var wasm_exports = {};
|
|
|
46
46
|
});
|
|
47
47
|
var globalWithPanicRegistry = globalThis;
|
|
48
48
|
globalWithPanicRegistry.PRISMA_WASM_PANIC_REGISTRY = new import_chunk_WXRVYSYN.WasmPanicRegistry();
|
|
49
|
-
var { dependencies } = (0,
|
|
49
|
+
var { dependencies } = (0, import_chunk_QQRYY5P4.require_package)();
|
|
50
50
|
var prismaSchemaWasmVersion = dependencies["@prisma/prisma-schema-wasm"];
|
|
51
51
|
var schemaEngineWasmVersion = dependencies["@prisma/schema-engine-wasm"];
|
|
@@ -26,17 +26,17 @@ 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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_AOJ2N25Z_exports = {};
|
|
30
|
+
__export(chunk_AOJ2N25Z_exports, {
|
|
31
31
|
ValidateError: () => ValidateError,
|
|
32
32
|
validate: () => validate
|
|
33
33
|
});
|
|
34
|
-
module.exports = __toCommonJS(
|
|
34
|
+
module.exports = __toCommonJS(chunk_AOJ2N25Z_exports);
|
|
35
35
|
var import_chunk_TZJROXB3 = require("./chunk-TZJROXB3.js");
|
|
36
36
|
var import_chunk_C47SCASR = require("./chunk-C47SCASR.js");
|
|
37
37
|
var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
|
|
38
|
-
var
|
|
39
|
-
var
|
|
38
|
+
var import_chunk_EBJBIVXN = require("./chunk-EBJBIVXN.js");
|
|
39
|
+
var import_chunk_ZVTQSH5K = require("./chunk-ZVTQSH5K.js");
|
|
40
40
|
var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
|
|
41
41
|
var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
|
|
42
42
|
var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
|
|
@@ -59,7 +59,7 @@ ${detailsHeader} ${message}`;
|
|
|
59
59
|
}).exhaustive();
|
|
60
60
|
const errorMessageWithContext = `${constructedErrorMessage}
|
|
61
61
|
[Context: validate]`;
|
|
62
|
-
super((0,
|
|
62
|
+
super((0, import_chunk_EBJBIVXN.addVersionDetailsToErrorMessage)(errorMessageWithContext));
|
|
63
63
|
this.name = "ValidateError";
|
|
64
64
|
}
|
|
65
65
|
};
|
|
@@ -71,13 +71,13 @@ function validate(options) {
|
|
|
71
71
|
() => {
|
|
72
72
|
if (process.env.FORCE_PANIC_QUERY_ENGINE_GET_DMMF) {
|
|
73
73
|
debug("Triggering a Rust panic...");
|
|
74
|
-
|
|
74
|
+
import_chunk_ZVTQSH5K.prismaSchemaWasm.debug_panic();
|
|
75
75
|
}
|
|
76
76
|
const params = JSON.stringify({
|
|
77
77
|
prismaSchema: options.schemas,
|
|
78
78
|
noColor: Boolean(process.env.NO_COLOR)
|
|
79
79
|
});
|
|
80
|
-
|
|
80
|
+
import_chunk_ZVTQSH5K.prismaSchemaWasm.validate(params);
|
|
81
81
|
},
|
|
82
82
|
(e) => ({
|
|
83
83
|
type: "wasm-error",
|
|
@@ -26,13 +26,12 @@ 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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_ARC7TW3L_exports = {};
|
|
30
|
+
__export(chunk_ARC7TW3L_exports, {
|
|
31
31
|
getGeneratorSuccessMessage: () => getGeneratorSuccessMessage
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
33
|
+
module.exports = __toCommonJS(chunk_ARC7TW3L_exports);
|
|
34
34
|
var import_chunk_XYCIH36R = require("./chunk-XYCIH36R.js");
|
|
35
|
-
var import_chunk_ERSH2BQA = require("./chunk-ERSH2BQA.js");
|
|
36
35
|
var import_chunk_IOIAK7V7 = require("./chunk-IOIAK7V7.js");
|
|
37
36
|
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
|
38
37
|
var import_path = __toESM(require("path"));
|
|
@@ -45,16 +44,7 @@ function getGeneratorSuccessMessage(generator, time) {
|
|
|
45
44
|
function formatVersion(generator) {
|
|
46
45
|
const version = generator.manifest?.version;
|
|
47
46
|
if (generator.getProvider() === "prisma-client-js") {
|
|
48
|
-
|
|
49
|
-
let engineHint = "";
|
|
50
|
-
if (generator.options?.noEngine) {
|
|
51
|
-
engineHint = ", engine=none";
|
|
52
|
-
} else if (engineType === "binary") {
|
|
53
|
-
engineHint = ", engine=binary";
|
|
54
|
-
} else if (engineType === "library") {
|
|
55
|
-
engineHint = "";
|
|
56
|
-
}
|
|
57
|
-
return `v${version ?? "?.?.?"}${engineHint}`;
|
|
47
|
+
return `v${version ?? "?.?.?"}`;
|
|
58
48
|
}
|
|
59
49
|
return version;
|
|
60
50
|
}
|
|
@@ -26,14 +26,14 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_BUQN4WLU_exports = {};
|
|
30
|
+
__export(chunk_BUQN4WLU_exports, {
|
|
31
31
|
sendPanic: () => sendPanic
|
|
32
32
|
});
|
|
33
|
-
module.exports = __toCommonJS(
|
|
33
|
+
module.exports = __toCommonJS(chunk_BUQN4WLU_exports);
|
|
34
34
|
var import_chunk_KDHESRKE = require("./chunk-KDHESRKE.js");
|
|
35
35
|
var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
|
|
36
|
-
var
|
|
36
|
+
var import_chunk_MEOOYUIZ = require("./chunk-MEOOYUIZ.js");
|
|
37
37
|
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
|
38
38
|
var import_node_util = require("node:util");
|
|
39
39
|
var import_get_platform = require("@prisma/get-platform");
|
|
@@ -1808,14 +1808,12 @@ async function sendPanic({
|
|
|
1808
1808
|
sqlDump: void 0,
|
|
1809
1809
|
dbVersion
|
|
1810
1810
|
};
|
|
1811
|
-
const signedUrl = await (0,
|
|
1812
|
-
const id = await (0,
|
|
1811
|
+
const signedUrl = await (0, import_chunk_MEOOYUIZ.createErrorReport)(params);
|
|
1812
|
+
const id = await (0, import_chunk_MEOOYUIZ.makeErrorReportCompleted)(signedUrl);
|
|
1813
1813
|
return id;
|
|
1814
1814
|
}
|
|
1815
1815
|
function getCommand() {
|
|
1816
|
-
if (process.argv[2] === "
|
|
1817
|
-
return "introspect";
|
|
1818
|
-
} else if (process.argv[2] === "db" && process.argv[3] === "pull") {
|
|
1816
|
+
if (process.argv[2] === "db" && process.argv[3] === "pull") {
|
|
1819
1817
|
return "db pull";
|
|
1820
1818
|
}
|
|
1821
1819
|
return process.argv.slice(2).join(" ");
|
|
@@ -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
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_BZV6PVWV_exports = {};
|
|
30
|
+
__export(chunk_BZV6PVWV_exports, {
|
|
31
31
|
GetDmmfError: () => GetDmmfError,
|
|
32
32
|
getDMMF: () => getDMMF
|
|
33
33
|
});
|
|
34
|
-
module.exports = __toCommonJS(
|
|
34
|
+
module.exports = __toCommonJS(chunk_BZV6PVWV_exports);
|
|
35
35
|
var import_chunk_TZJROXB3 = require("./chunk-TZJROXB3.js");
|
|
36
36
|
var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
|
|
37
|
-
var
|
|
38
|
-
var
|
|
37
|
+
var import_chunk_EBJBIVXN = require("./chunk-EBJBIVXN.js");
|
|
38
|
+
var import_chunk_ZVTQSH5K = require("./chunk-ZVTQSH5K.js");
|
|
39
39
|
var import_chunk_5DBOS77Y = require("./chunk-5DBOS77Y.js");
|
|
40
40
|
var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
|
|
41
41
|
var import_chunk_LMVSIVKQ = require("./chunk-LMVSIVKQ.js");
|
|
@@ -58,7 +58,7 @@ ${detailsHeader} ${message}`;
|
|
|
58
58
|
}).exhaustive();
|
|
59
59
|
const errorMessageWithContext = `${constructedErrorMessage}
|
|
60
60
|
[Context: getDmmf]`;
|
|
61
|
-
super((0,
|
|
61
|
+
super((0, import_chunk_EBJBIVXN.addVersionDetailsToErrorMessage)(errorMessageWithContext));
|
|
62
62
|
this.name = "GetDmmfError";
|
|
63
63
|
}
|
|
64
64
|
};
|
|
@@ -70,13 +70,13 @@ async function getDMMF(options) {
|
|
|
70
70
|
() => {
|
|
71
71
|
if (process.env.FORCE_PANIC_QUERY_ENGINE_GET_DMMF) {
|
|
72
72
|
debug("Triggering a Rust panic...");
|
|
73
|
-
|
|
73
|
+
import_chunk_ZVTQSH5K.prismaSchemaWasm.debug_panic();
|
|
74
74
|
}
|
|
75
75
|
const params = JSON.stringify({
|
|
76
76
|
prismaSchema: options.datamodel,
|
|
77
77
|
noColor: Boolean(process.env.NO_COLOR)
|
|
78
78
|
});
|
|
79
|
-
const data =
|
|
79
|
+
const data = import_chunk_ZVTQSH5K.prismaSchemaWasm.get_dmmf(params);
|
|
80
80
|
return data;
|
|
81
81
|
},
|
|
82
82
|
(e) => ({
|