@prisma/internals 6.6.0-dev.87 → 6.6.0-dev.89
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-PGWWIFB5.js → chunk-5FNXF4NQ.js} +7 -7
- package/dist/{chunk-KFUDUQDJ.js → chunk-73COFT7A.js} +5 -5
- package/dist/{chunk-AZV6HVKA.js → chunk-7QC5VORA.js} +5 -5
- package/dist/{chunk-XLTQGAI2.js → chunk-AX5N26KG.js} +6 -6
- package/dist/{chunk-2ZQ3EIFP.js → chunk-AXYQWZXV.js} +8 -8
- package/dist/{chunk-7IVVITJ4.js → chunk-BAJOXNL3.js} +8 -8
- package/dist/{chunk-GN564DM5.js → chunk-FFJGOJXV.js} +5 -5
- package/dist/{chunk-KM4DBT3Q.js → chunk-FRNDDXVT.js} +25 -25
- package/dist/{chunk-PKUJNUQP.js → chunk-HTYEU5FC.js} +5 -5
- package/dist/{chunk-HAGJ64PM.js → chunk-I6WLABB2.js} +158 -83
- package/dist/{chunk-BKPPMNV3.js → chunk-IRTBJKYB.js} +5 -5
- package/dist/{chunk-HIXGTIDR.js → chunk-LKR4OOFJ.js} +5 -5
- package/dist/{chunk-CLTELV3Y.js → chunk-N6H26BQE.js} +5 -5
- package/dist/{chunk-R5ST7KPY.js → chunk-NYVGEUNR.js} +25 -25
- package/dist/{chunk-BWCZJO3J.js → chunk-O3X5PEOU.js} +8 -8
- package/dist/{chunk-7QOOXY6F.js → chunk-OESCEI3R.js} +8 -8
- package/dist/{chunk-GQDD4SEU.js → chunk-OQ27GQAK.js} +5 -5
- package/dist/{chunk-BZHB4FYD.js → chunk-P2DQFS3G.js} +8 -8
- package/dist/{chunk-43EZSZMB.js → chunk-Q4DQV7QD.js} +5 -5
- package/dist/{chunk-YEKB3CIU.js → chunk-TWSSYOC7.js} +4 -4
- package/dist/{chunk-DJBBHZ23.js → chunk-XF3D7LPL.js} +5 -5
- package/dist/{chunk-2QTAK7KO.js → chunk-XR4RJTDM.js} +5 -5
- package/dist/{chunk-NGX7QQSC.js → chunk-Y4AIQAU4.js} +8 -8
- package/dist/{chunk-67VG7QKN.js → chunk-YKMFYZPB.js} +7 -7
- package/dist/cli/checkUnsupportedDataProxy.js +16 -16
- package/dist/cli/getSchema.js +19 -19
- package/dist/cli/hashes.js +16 -16
- package/dist/cli/schemaContext.js +16 -16
- package/dist/engine-commands/errorHelpers.js +4 -4
- package/dist/engine-commands/formatSchema.js +15 -15
- package/dist/engine-commands/getConfig.js +10 -10
- package/dist/engine-commands/getDmmf.js +7 -7
- package/dist/engine-commands/index.js +24 -24
- 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/get-generators/getGenerators.js +18 -18
- package/dist/index.js +45 -45
- package/dist/utils/getEnvPaths.js +15 -15
- package/dist/utils/getVersionFromPackageJson.js +3 -3
- package/dist/utils/handlePanic.js +3 -3
- package/dist/utils/link.js +2 -2
- package/dist/utils/loadEnvFile.js +15 -15
- package/dist/utils/missingDatasource.js +3 -3
- package/dist/utils/missingGeneratorMessage.js +5 -5
- package/dist/wasm.js +4 -4
- package/package.json +11 -11
@@ -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_5FNXF4NQ_exports = {};
|
30
|
+
__export(chunk_5FNXF4NQ_exports, {
|
31
31
|
MergeSchemasError: () => MergeSchemasError,
|
32
32
|
mergeSchemas: () => mergeSchemas
|
33
33
|
});
|
34
|
-
module.exports = __toCommonJS(
|
34
|
+
module.exports = __toCommonJS(chunk_5FNXF4NQ_exports);
|
35
35
|
var import_chunk_WSZXPLJQ = require("./chunk-WSZXPLJQ.js");
|
36
36
|
var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
|
37
37
|
var import_chunk_C47SCASR = require("./chunk-C47SCASR.js");
|
38
|
-
var
|
39
|
-
var
|
38
|
+
var import_chunk_HTYEU5FC = require("./chunk-HTYEU5FC.js");
|
39
|
+
var import_chunk_OQ27GQAK = require("./chunk-OQ27GQAK.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: mergeSchemas]`;
|
62
|
-
super((0,
|
62
|
+
super((0, import_chunk_HTYEU5FC.addVersionDetailsToErrorMessage)(errorMessageWithContext));
|
63
63
|
this.name = "MergeSchemasError";
|
64
64
|
}
|
65
65
|
};
|
@@ -72,7 +72,7 @@ function mergeSchemas(options) {
|
|
72
72
|
const params = JSON.stringify({
|
73
73
|
schema: options.schemas
|
74
74
|
});
|
75
|
-
return
|
75
|
+
return import_chunk_OQ27GQAK.prismaSchemaWasm.merge_schemas(params);
|
76
76
|
},
|
77
77
|
(e) => ({
|
78
78
|
type: "wasm-error",
|
@@ -16,17 +16,17 @@ 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_73COFT7A_exports = {};
|
20
|
+
__export(chunk_73COFT7A_exports, {
|
21
21
|
require_package: () => require_package
|
22
22
|
});
|
23
|
-
module.exports = __toCommonJS(
|
23
|
+
module.exports = __toCommonJS(chunk_73COFT7A_exports);
|
24
24
|
var import_chunk_4VNS5WPM = require("./chunk-4VNS5WPM.js");
|
25
25
|
var require_package = (0, import_chunk_4VNS5WPM.__commonJS)({
|
26
26
|
"package.json"(exports, module2) {
|
27
27
|
module2.exports = {
|
28
28
|
name: "@prisma/internals",
|
29
|
-
version: "6.6.0-dev.
|
29
|
+
version: "6.6.0-dev.89",
|
30
30
|
description: "This package is intended for Prisma's internal use",
|
31
31
|
main: "dist/index.js",
|
32
32
|
types: "dist/index.d.ts",
|
@@ -95,7 +95,7 @@ var require_package = (0, import_chunk_4VNS5WPM.__commonJS)({
|
|
95
95
|
"strip-indent": "4.0.0",
|
96
96
|
"temp-dir": "2.0.0",
|
97
97
|
tempy: "1.0.1",
|
98
|
-
"terminal-link": "
|
98
|
+
"terminal-link": "4.0.0",
|
99
99
|
tmp: "0.2.3",
|
100
100
|
"ts-node": "10.9.2",
|
101
101
|
"ts-pattern": "5.6.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
|
20
|
-
__export(
|
19
|
+
var chunk_7QC5VORA_exports = {};
|
20
|
+
__export(chunk_7QC5VORA_exports, {
|
21
21
|
missingDatasource: () => missingDatasource
|
22
22
|
});
|
23
|
-
module.exports = __toCommonJS(
|
24
|
-
var
|
23
|
+
module.exports = __toCommonJS(chunk_7QC5VORA_exports);
|
24
|
+
var import_chunk_I6WLABB2 = require("./chunk-I6WLABB2.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,
|
39
|
+
${(0, import_chunk_I6WLABB2.link)("https://pris.ly/d/prisma-schema")}
|
40
40
|
`;
|
@@ -16,14 +16,14 @@ 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_AX5N26KG_exports = {};
|
20
|
+
__export(chunk_AX5N26KG_exports, {
|
21
21
|
missingGeneratorMessage: () => missingGeneratorMessage,
|
22
22
|
missingModelMessage: () => missingModelMessage,
|
23
23
|
missingModelMessageMongoDB: () => missingModelMessageMongoDB
|
24
24
|
});
|
25
|
-
module.exports = __toCommonJS(
|
26
|
-
var
|
25
|
+
module.exports = __toCommonJS(chunk_AX5N26KG_exports);
|
26
|
+
var import_chunk_I6WLABB2 = require("./chunk-I6WLABB2.js");
|
27
27
|
var import_chunk_TQCLUNM2 = require("./chunk-TQCLUNM2.js");
|
28
28
|
var import_chunk_PG5FDKSF = require("./chunk-PG5FDKSF.js");
|
29
29
|
var missingGeneratorMessage = `
|
@@ -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_I6WLABB2.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)(
|
@@ -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_I6WLABB2.link)("https://pris.ly/d/prisma-schema")}
|
73
73
|
`;
|
@@ -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_AXYQWZXV_exports = {};
|
30
|
+
__export(chunk_AXYQWZXV_exports, {
|
31
31
|
GetDmmfError: () => GetDmmfError,
|
32
32
|
getDMMF: () => getDMMF
|
33
33
|
});
|
34
|
-
module.exports = __toCommonJS(
|
34
|
+
module.exports = __toCommonJS(chunk_AXYQWZXV_exports);
|
35
35
|
var import_chunk_WSZXPLJQ = require("./chunk-WSZXPLJQ.js");
|
36
36
|
var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
|
37
|
-
var
|
38
|
-
var
|
37
|
+
var import_chunk_LKR4OOFJ = require("./chunk-LKR4OOFJ.js");
|
38
|
+
var import_chunk_XF3D7LPL = require("./chunk-XF3D7LPL.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_LKR4OOFJ.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_XF3D7LPL.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_XF3D7LPL.prismaSchemaWasm.get_dmmf(params);
|
80
80
|
return data;
|
81
81
|
},
|
82
82
|
(e) => ({
|
@@ -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_BAJOXNL3_exports = {};
|
30
|
+
__export(chunk_BAJOXNL3_exports, {
|
31
31
|
GetDmmfError: () => GetDmmfError,
|
32
32
|
getDMMF: () => getDMMF
|
33
33
|
});
|
34
|
-
module.exports = __toCommonJS(
|
34
|
+
module.exports = __toCommonJS(chunk_BAJOXNL3_exports);
|
35
35
|
var import_chunk_WSZXPLJQ = require("./chunk-WSZXPLJQ.js");
|
36
36
|
var import_chunk_R6QH57HZ = require("./chunk-R6QH57HZ.js");
|
37
|
-
var
|
38
|
-
var
|
37
|
+
var import_chunk_HTYEU5FC = require("./chunk-HTYEU5FC.js");
|
38
|
+
var import_chunk_OQ27GQAK = require("./chunk-OQ27GQAK.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_HTYEU5FC.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_OQ27GQAK.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_OQ27GQAK.prismaSchemaWasm.get_dmmf(params);
|
80
80
|
return data;
|
81
81
|
},
|
82
82
|
(e) => ({
|
@@ -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_FFJGOJXV_exports = {};
|
20
|
+
__export(chunk_FFJGOJXV_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_FFJGOJXV_exports);
|
28
|
+
var import_chunk_OQ27GQAK = require("./chunk-OQ27GQAK.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_OQ27GQAK.prismaSchemaWasm.lint(JSON.stringify(schemas));
|
33
33
|
const lintDiagnostics = JSON.parse(lintResult);
|
34
34
|
return lintDiagnostics;
|
35
35
|
}
|
@@ -26,8 +26,8 @@ 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_FRNDDXVT_exports = {};
|
30
|
+
__export(chunk_FRNDDXVT_exports, {
|
31
31
|
checkUnsupportedDataProxy: () => checkUnsupportedDataProxy,
|
32
32
|
forbiddenCmdWithDataProxyFlagMessage: () => forbiddenCmdWithDataProxyFlagMessage,
|
33
33
|
formatSchema: () => formatSchema,
|
@@ -49,7 +49,7 @@ __export(chunk_KM4DBT3Q_exports, {
|
|
49
49
|
processSchemaResult: () => processSchemaResult,
|
50
50
|
skipIndex: () => skipIndex
|
51
51
|
});
|
52
|
-
module.exports = __toCommonJS(
|
52
|
+
module.exports = __toCommonJS(chunk_FRNDDXVT_exports);
|
53
53
|
var import_chunk_X77CS5RK = require("./chunk-X77CS5RK.js");
|
54
54
|
var import_chunk_EPXBOIA5 = require("./chunk-EPXBOIA5.js");
|
55
55
|
var import_chunk_RS2R7COT = require("./chunk-RS2R7COT.js");
|
@@ -57,16 +57,16 @@ var import_chunk_X3P4J7WW = require("./chunk-X3P4J7WW.js");
|
|
57
57
|
var import_chunk_LRU47BGE = require("./chunk-LRU47BGE.js");
|
58
58
|
var import_chunk_5FJ3MENK = require("./chunk-5FJ3MENK.js");
|
59
59
|
var import_chunk_UTJGRVMG = require("./chunk-UTJGRVMG.js");
|
60
|
-
var
|
60
|
+
var import_chunk_AX5N26KG = require("./chunk-AX5N26KG.js");
|
61
61
|
var import_chunk_5V36RLCO = require("./chunk-5V36RLCO.js");
|
62
|
-
var
|
63
|
-
var
|
62
|
+
var import_chunk_7QC5VORA = require("./chunk-7QC5VORA.js");
|
63
|
+
var import_chunk_I6WLABB2 = require("./chunk-I6WLABB2.js");
|
64
64
|
var import_chunk_CRVLHWC5 = require("./chunk-CRVLHWC5.js");
|
65
|
-
var
|
66
|
-
var
|
67
|
-
var
|
68
|
-
var
|
69
|
-
var
|
65
|
+
var import_chunk_AXYQWZXV = require("./chunk-AXYQWZXV.js");
|
66
|
+
var import_chunk_IRTBJKYB = require("./chunk-IRTBJKYB.js");
|
67
|
+
var import_chunk_YKMFYZPB = require("./chunk-YKMFYZPB.js");
|
68
|
+
var import_chunk_OESCEI3R = require("./chunk-OESCEI3R.js");
|
69
|
+
var import_chunk_XF3D7LPL = require("./chunk-XF3D7LPL.js");
|
70
70
|
var import_chunk_2B26F5N3 = require("./chunk-2B26F5N3.js");
|
71
71
|
var import_chunk_M3GBKLGE = require("./chunk-M3GBKLGE.js");
|
72
72
|
var import_chunk_XKZ6CBLA = require("./chunk-XKZ6CBLA.js");
|
@@ -104,7 +104,7 @@ var debug = (0, import_debug2.default)("prisma:format");
|
|
104
104
|
async function formatSchema({ schemas }, inputFormattingOptions) {
|
105
105
|
if (process.env.FORCE_PANIC_PRISMA_SCHEMA) {
|
106
106
|
handleFormatPanic(() => {
|
107
|
-
|
107
|
+
import_chunk_XF3D7LPL.prismaSchemaWasm.debug_panic();
|
108
108
|
});
|
109
109
|
}
|
110
110
|
const defaultFormattingOptions = {
|
@@ -121,10 +121,10 @@ async function formatSchema({ schemas }, inputFormattingOptions) {
|
|
121
121
|
const { formattedMultipleSchemas, lintDiagnostics } = handleFormatPanic(() => {
|
122
122
|
const formattedMultipleSchemasRaw = formatWasm(JSON.stringify(schemas), documentFormattingParams);
|
123
123
|
const formattedMultipleSchemas2 = JSON.parse(formattedMultipleSchemasRaw);
|
124
|
-
const lintDiagnostics2 = (0,
|
124
|
+
const lintDiagnostics2 = (0, import_chunk_IRTBJKYB.lintSchema)({ schemas: formattedMultipleSchemas2 });
|
125
125
|
return { formattedMultipleSchemas: formattedMultipleSchemas2, lintDiagnostics: lintDiagnostics2 };
|
126
126
|
});
|
127
|
-
const lintWarnings = (0,
|
127
|
+
const lintWarnings = (0, import_chunk_IRTBJKYB.getLintWarningsAsText)(lintDiagnostics);
|
128
128
|
if (lintWarnings && import_chunk_ZJWZK45Z.logger_exports.should.warn()) {
|
129
129
|
console.warn(lintWarnings);
|
130
130
|
}
|
@@ -151,7 +151,7 @@ function handleFormatPanic(tryCb) {
|
|
151
151
|
}
|
152
152
|
}
|
153
153
|
function formatWasm(schema, documentFormattingParams) {
|
154
|
-
const formattedSchema =
|
154
|
+
const formattedSchema = import_chunk_XF3D7LPL.prismaSchemaWasm.format(schema, JSON.stringify(documentFormattingParams));
|
155
155
|
return formattedSchema;
|
156
156
|
}
|
157
157
|
var readFile = (0, import_util.promisify)(import_fs.default.readFile);
|
@@ -195,7 +195,7 @@ async function readSchemaFromDirectory(schemaPath2) {
|
|
195
195
|
}
|
196
196
|
const files = await (0, import_schema_files_loader.loadSchemaFiles)(schemaPath2);
|
197
197
|
debug2("Loading config");
|
198
|
-
const config = await (0,
|
198
|
+
const config = await (0, import_chunk_OESCEI3R.getConfig)({
|
199
199
|
datamodel: files,
|
200
200
|
ignoreEnvVarErrors: true
|
201
201
|
});
|
@@ -405,7 +405,7 @@ async function processSchemaResult({
|
|
405
405
|
if (printLoadMessage) {
|
406
406
|
printSchemaLoadedMessage(loadedFromPathForLogMessages);
|
407
407
|
}
|
408
|
-
const configFromPsl = await (0,
|
408
|
+
const configFromPsl = await (0, import_chunk_OESCEI3R.getConfig)({ datamodel: schemaResult.schemas, ignoreEnvVarErrors });
|
409
409
|
const primaryDatasource = configFromPsl.datasources.at(0);
|
410
410
|
const schemaRootDir = schemaResult.schemaRootDir || cwd;
|
411
411
|
return {
|
@@ -479,19 +479,19 @@ async function getGenerators(options) {
|
|
479
479
|
}
|
480
480
|
}
|
481
481
|
if (!schemaContext.primaryDatasource) {
|
482
|
-
throw new Error(
|
482
|
+
throw new Error(import_chunk_7QC5VORA.missingDatasource);
|
483
483
|
}
|
484
484
|
(0, import_chunk_5FJ3MENK.printConfigWarnings)(schemaContext.warnings);
|
485
485
|
const previewFeatures = (0, import_chunk_CRVLHWC5.extractPreviewFeatures)(schemaContext.generators);
|
486
|
-
const dmmf = await (0,
|
486
|
+
const dmmf = await (0, import_chunk_AXYQWZXV.getDMMF)({
|
487
487
|
datamodel: schemaContext.schemaFiles,
|
488
488
|
previewFeatures
|
489
489
|
});
|
490
490
|
if (dmmf.datamodel.models.length === 0 && !allowNoModels) {
|
491
491
|
if (schemaContext.primaryDatasource.provider === "mongodb") {
|
492
|
-
throw new Error(
|
492
|
+
throw new Error(import_chunk_AX5N26KG.missingModelMessageMongoDB);
|
493
493
|
}
|
494
|
-
throw new Error(
|
494
|
+
throw new Error(import_chunk_AX5N26KG.missingModelMessage);
|
495
495
|
}
|
496
496
|
const generatorConfigs = filterGenerators(overrideGenerators || schemaContext.generators, generatorNames);
|
497
497
|
await validateGenerators(generatorConfigs);
|
@@ -534,7 +534,7 @@ You need to define \`output\` in the generator block in the schema file.`
|
|
534
534
|
fromEnvVar: null
|
535
535
|
};
|
536
536
|
}
|
537
|
-
const datamodel = (0,
|
537
|
+
const datamodel = (0, import_chunk_YKMFYZPB.mergeSchemas)({ schemas: schemaContext.schemaFiles });
|
538
538
|
const envPaths = await getEnvPaths(schemaContext.schemaPath, { cwd: generatorConfig.output.value });
|
539
539
|
const options2 = {
|
540
540
|
datamodel,
|
@@ -618,7 +618,7 @@ generator gen {
|
|
618
618
|
debug3({ generatorBinaryPaths });
|
619
619
|
generator.setBinaryPaths(generatorBinaryPaths);
|
620
620
|
if (engineVersion !== version && generator.options && generator.manifest.requiresEngines.includes(queryEngineType) && generatorBinaryPaths[queryEngineType] && generatorBinaryPaths[queryEngineType]?.[binaryTarget]) {
|
621
|
-
const customDmmf = await (0,
|
621
|
+
const customDmmf = await (0, import_chunk_AXYQWZXV.getDMMF)({
|
622
622
|
datamodel: schemaContext.schemaFiles,
|
623
623
|
previewFeatures
|
624
624
|
});
|
@@ -880,7 +880,7 @@ var forbiddenCmdWithDataProxyFlagMessage = (command) => `
|
|
880
880
|
Using an Accelerate URL is not supported for this CLI command ${(0, import_chunk_PG5FDKSF.green)(`prisma ${command}`)} yet.
|
881
881
|
Please use a direct connection to your database via the datasource \`directUrl\` setting.
|
882
882
|
|
883
|
-
More information about this limitation: ${(0,
|
883
|
+
More information about this limitation: ${(0, import_chunk_I6WLABB2.link)("https://pris.ly/d/accelerate-limitations")}
|
884
884
|
`;
|
885
885
|
function checkUnsupportedDataProxy({
|
886
886
|
cmd,
|
@@ -893,7 +893,7 @@ function checkUnsupportedDataProxy({
|
|
893
893
|
}
|
894
894
|
}
|
895
895
|
if (!schemaContext2?.primaryDatasource) return;
|
896
|
-
const url = (0,
|
896
|
+
const url = (0, import_chunk_OESCEI3R.resolveUrl)((0, import_chunk_OESCEI3R.getEffectiveUrl)(schemaContext2.primaryDatasource));
|
897
897
|
if (url?.startsWith("prisma://")) {
|
898
898
|
throw new Error(forbiddenCmdWithDataProxyFlagMessage(cmd));
|
899
899
|
}
|
@@ -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_HTYEU5FC_exports = {};
|
20
|
+
__export(chunk_HTYEU5FC_exports, {
|
21
21
|
addVersionDetailsToErrorMessage: () => addVersionDetailsToErrorMessage
|
22
22
|
});
|
23
|
-
module.exports = __toCommonJS(
|
24
|
-
var
|
23
|
+
module.exports = __toCommonJS(chunk_HTYEU5FC_exports);
|
24
|
+
var import_chunk_Q4DQV7QD = require("./chunk-Q4DQV7QD.js");
|
25
25
|
var import_chunk_QN6PSQY7 = require("./chunk-QN6PSQY7.js");
|
26
26
|
function addVersionDetailsToErrorMessage(message) {
|
27
|
-
const rows = [["Prisma CLI Version",
|
27
|
+
const rows = [["Prisma CLI Version", import_chunk_Q4DQV7QD.version]];
|
28
28
|
return `${message}
|
29
29
|
|
30
30
|
${(0, import_chunk_QN6PSQY7.formatTable)(rows)}`;
|