@prisma/engine-core
Advanced tools
Comparing version 4.14.0-integration-fix-client-custom-output-mismatch.7 to 4.14.0-integration-fix-client-custom-output-mismatch.8
@@ -34,6 +34,6 @@ "use strict"; | ||
var import_get_platform = require("@prisma/get-platform"); | ||
var import_chalk = __toESM(require("chalk")); | ||
var import_child_process = require("child_process"); | ||
var import_execa = __toESM(require("execa")); | ||
var import_fs = __toESM(require("fs")); | ||
var import_colors = require("kleur/colors"); | ||
var import_net = __toESM(require("net")); | ||
@@ -179,3 +179,3 @@ var import_p_retry = __toESM(require("p-retry")); | ||
console.log( | ||
`${import_chalk.default.blueBright("info")} The preview flags \`${removedFlagsUsed.join( | ||
`${(0, import_colors.blue)((0, import_colors.bold)("info"))} The preview flags \`${removedFlagsUsed.join( | ||
"`, `" | ||
@@ -194,8 +194,6 @@ )}\` were removed, you can now safely remove them from your schema.prisma.` | ||
throw new import_PrismaClientInitializationError.PrismaClientInitializationError( | ||
`Unknown ${import_chalk.default.red("PRISMA_QUERY_ENGINE_BINARY")} ${import_chalk.default.redBright.bold( | ||
this.platform | ||
)}. Possible binaryTargets: ${import_chalk.default.greenBright( | ||
`Unknown ${(0, import_colors.red)("PRISMA_QUERY_ENGINE_BINARY")} ${(0, import_colors.red)((0, import_colors.bold)(this.platform))}. Possible binaryTargets: ${(0, import_colors.green)( | ||
knownPlatforms.join(", ") | ||
)} or a path to the query engine binary. | ||
You may have to run ${import_chalk.default.greenBright("prisma generate")} for your changes to take effect.`, | ||
You may have to run ${(0, import_colors.green)("prisma generate")} for your changes to take effect.`, | ||
this.clientVersion | ||
@@ -234,3 +232,3 @@ ); | ||
console.warn( | ||
`${import_chalk.default.yellow("warn(prisma-client)")} There are already 10 instances of Prisma Client actively running.` | ||
`${(0, import_colors.bold)((0, import_colors.yellow)("warn(prisma-client)"))} There are already 10 instances of Prisma Client actively running.` | ||
); | ||
@@ -318,9 +316,7 @@ } | ||
const pinnedStr = this.incorrectlyPinnedBinaryTarget ? ` | ||
You incorrectly pinned it to ${import_chalk.default.redBright.bold(`${this.incorrectlyPinnedBinaryTarget}`)} | ||
You incorrectly pinned it to ${(0, import_colors.red)((0, import_colors.bold)(`${this.incorrectlyPinnedBinaryTarget}`))} | ||
` : ""; | ||
let errorText = `Query engine binary for current platform "${import_chalk.default.bold( | ||
platform2 | ||
)}" could not be found.${pinnedStr} | ||
let errorText = `Query engine binary for current platform "${(0, import_colors.bold)(platform2)}" could not be found.${pinnedStr} | ||
This probably happens, because you built Prisma Client on a different platform. | ||
(Prisma Client looked in "${import_chalk.default.underline(prismaPath)}") | ||
(Prisma Client looked in "${(0, import_colors.underline)(prismaPath)}") | ||
@@ -341,3 +337,3 @@ Searched Locations: | ||
errorText += ` | ||
You already added the platform${this.generator.binaryTargets.length > 1 ? "s" : ""} ${this.generator.binaryTargets.map((t) => `"${import_chalk.default.bold(t.value)}"`).join(", ")} to the "${import_chalk.default.underline("generator")}" block | ||
You already added the platform${this.generator.binaryTargets.length > 1 ? "s" : ""} ${this.generator.binaryTargets.map((t) => `"${(0, import_colors.bold)(t.value)}"`).join(", ")} to the "${(0, import_colors.underline)("generator")}" block | ||
in the "schema.prisma" file as described in https://pris.ly/d/client-generator, | ||
@@ -351,8 +347,8 @@ but something went wrong. That's suboptimal. | ||
To solve this problem, add the platform "${this.platform}" to the "${import_chalk.default.underline( | ||
To solve this problem, add the platform "${this.platform}" to the "${(0, import_colors.underline)( | ||
"binaryTargets" | ||
)}" attribute in the "${import_chalk.default.underline("generator")}" block in the "schema.prisma" file: | ||
${import_chalk.default.greenBright(this.getFixedGenerator())} | ||
)}" attribute in the "${(0, import_colors.underline)("generator")}" block in the "schema.prisma" file: | ||
${(0, import_colors.green)(this.getFixedGenerator())} | ||
Then run "${import_chalk.default.greenBright("prisma generate")}" for your changes to take effect. | ||
Then run "${(0, import_colors.green)("prisma generate")}" for your changes to take effect. | ||
Read more about deploying Prisma Client: https://pris.ly/d/client-generator`; | ||
@@ -369,7 +365,7 @@ } | ||
if (this.incorrectlyPinnedBinaryTarget) { | ||
console.error(`${import_chalk.default.yellow("Warning:")} You pinned the platform ${import_chalk.default.bold( | ||
console.error(`${(0, import_colors.bold)((0, import_colors.yellow)("Warning:"))} You pinned the platform ${(0, import_colors.bold)( | ||
this.incorrectlyPinnedBinaryTarget | ||
)}, but Prisma Client detects ${import_chalk.default.bold(await this.getPlatform())}. | ||
This means you should very likely pin the platform ${import_chalk.default.greenBright(await this.getPlatform())} instead. | ||
${import_chalk.default.dim("In case we're mistaken, please report this to us \u{1F64F}.")}`); | ||
)}, but Prisma Client detects ${(0, import_colors.bold)(await this.getPlatform())}. | ||
This means you should very likely pin the platform ${(0, import_colors.green)(await this.getPlatform())} instead. | ||
${(0, import_colors.dim)("In case we're mistaken, please report this to us \u{1F64F}.")}`); | ||
} | ||
@@ -376,0 +372,0 @@ if (process.platform !== "win32") { |
@@ -32,3 +32,3 @@ "use strict"; | ||
var import_debug = require("@prisma/debug"); | ||
var import_chalk = __toESM(require("chalk")); | ||
var import_colors = require("kleur/colors"); | ||
var import_strip_ansi = __toESM(require("strip-ansi")); | ||
@@ -93,3 +93,3 @@ var import_util = require("../../utils/util"); | ||
${import_chalk.default.underline(url)} | ||
${(0, import_colors.underline)(url)} | ||
@@ -96,0 +96,0 @@ If you want the Prisma team to look into it, please open the link above \u{1F64F} |
"use strict"; | ||
var __create = Object.create; | ||
var __defProp = Object.defineProperty; | ||
var __getOwnPropDesc = Object.getOwnPropertyDescriptor; | ||
var __getOwnPropNames = Object.getOwnPropertyNames; | ||
var __getProtoOf = Object.getPrototypeOf; | ||
var __hasOwnProp = Object.prototype.hasOwnProperty; | ||
@@ -21,6 +19,2 @@ var __name = (target, value) => __defProp(target, "name", { value, configurable: true }); | ||
}; | ||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps( | ||
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target, | ||
mod | ||
)); | ||
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); | ||
@@ -33,3 +27,3 @@ var handleEngineLoadingErrors_exports = {}; | ||
var import_get_platform = require("@prisma/get-platform"); | ||
var import_chalk = __toESM(require("chalk")); | ||
var import_colors = require("kleur/colors"); | ||
var import_ts_pattern = require("ts-pattern"); | ||
@@ -43,3 +37,3 @@ function handleLibraryLoadingErrors(args) { | ||
)}`; | ||
const errorTitle = `Unable to require(\`${import_chalk.default.dim(args.id)}\`).`; | ||
const errorTitle = `Unable to require(\`${(0, import_colors.dim)(args.id)}\`).`; | ||
const potentialReasonMessage = (0, import_ts_pattern.match)({ message: error.message, code: error.code }).with({ code: "ENOENT" }, () => `File does not exist.`).when( | ||
@@ -46,0 +40,0 @@ ({ message }) => hasLinkingProblem && message.includes("libz"), |
@@ -133,3 +133,3 @@ export type EngineValidationError = EmptySelectionError | UnknownSelectionFieldError | SelectionSetOnScalarError | UnknownArgumentError | UnknownInputFieldError | RequiredArgumentMissingError | InvalidArgumentTypeError | InvalidArgumentValueError | ValueTooLargeError | SomeFieldsMissingError | TooManyFieldsGivenError | UnionError; | ||
*/ | ||
underlyingError: string; | ||
underlyingError: string | null; | ||
}; | ||
@@ -136,0 +136,0 @@ /** |
@@ -35,4 +35,4 @@ "use strict"; | ||
var import_get_platform = require("@prisma/get-platform"); | ||
var import_chalk = __toESM(require("chalk")); | ||
var import_fs = __toESM(require("fs")); | ||
var import_colors = require("kleur/colors"); | ||
var import_os = __toESM(require("os")); | ||
@@ -108,9 +108,9 @@ var import_path = __toESM(require("path")); | ||
const incorrectPinnedPlatformErrorStr = this.platform ? ` | ||
You incorrectly pinned it to ${import_chalk.default.redBright.bold(`${this.platform}`)} | ||
You incorrectly pinned it to ${(0, import_colors.bold)((0, import_colors.red)(`${this.platform}`))} | ||
` : ""; | ||
let errorText = `Query engine library for current platform "${import_chalk.default.bold( | ||
let errorText = `Query engine library for current platform "${(0, import_colors.bold)( | ||
this.platform | ||
)}" could not be found.${incorrectPinnedPlatformErrorStr} | ||
This probably happens, because you built Prisma Client on a different platform. | ||
(Prisma Client looked in "${import_chalk.default.underline(enginePath2)}") | ||
(Prisma Client looked in "${(0, import_colors.underline)(enginePath2)}") | ||
@@ -132,3 +132,5 @@ Searched Locations: | ||
errorText += ` | ||
You already added the platform${this.config.generator.binaryTargets.length > 1 ? "s" : ""} ${this.config.generator.binaryTargets.map((t) => `"${import_chalk.default.bold(t.value)}"`).join(", ")} to the "${import_chalk.default.underline("generator")}" block | ||
You already added the platform${this.config.generator.binaryTargets.length > 1 ? "s" : ""} ${this.config.generator.binaryTargets.map((t) => `"${(0, import_colors.bold)(t.value)}"`).join(", ")} to the "${(0, import_colors.underline)( | ||
"generator" | ||
)}" block | ||
in the "schema.prisma" file as described in https://pris.ly/d/client-generator, | ||
@@ -142,8 +144,8 @@ but something went wrong. That's suboptimal. | ||
To solve this problem, add the platform "${this.platform}" to the "${import_chalk.default.underline( | ||
To solve this problem, add the platform "${this.platform}" to the "${(0, import_colors.underline)( | ||
"binaryTargets" | ||
)}" attribute in the "${import_chalk.default.underline("generator")}" block in the "schema.prisma" file: | ||
${import_chalk.default.greenBright(this.getFixedGenerator())} | ||
)}" attribute in the "${(0, import_colors.underline)("generator")}" block in the "schema.prisma" file: | ||
${(0, import_colors.green)(this.getFixedGenerator())} | ||
Then run "${import_chalk.default.greenBright("prisma generate")}" for your changes to take effect. | ||
Then run "${(0, import_colors.green)("prisma generate")}" for your changes to take effect. | ||
Read more about deploying Prisma Client: https://pris.ly/d/client-generator`; | ||
@@ -150,0 +152,0 @@ } |
@@ -33,4 +33,4 @@ "use strict"; | ||
var import_get_platform = require("@prisma/get-platform"); | ||
var import_chalk = __toESM(require("chalk")); | ||
var import_fs = __toESM(require("fs")); | ||
var import_colors = require("kleur/colors"); | ||
var import_Engine = require("../common/Engine"); | ||
@@ -108,5 +108,3 @@ var import_PrismaClientInitializationError = require("../common/errors/PrismaClientInitializationError"); | ||
if (engineInstanceCount === 10) { | ||
console.warn( | ||
`${import_chalk.default.yellow("warn(prisma-client)")} There are already 10 instances of Prisma Client actively running.` | ||
); | ||
console.warn(`${(0, import_colors.yellow)("warn(prisma-client)")} There are already 10 instances of Prisma Client actively running.`); | ||
} | ||
@@ -156,8 +154,6 @@ } | ||
throw new import_PrismaClientInitializationError.PrismaClientInitializationError( | ||
`Unknown ${import_chalk.default.red("PRISMA_QUERY_ENGINE_LIBRARY")} ${import_chalk.default.redBright.bold( | ||
platform | ||
)}. Possible binaryTargets: ${import_chalk.default.greenBright( | ||
`Unknown ${(0, import_colors.red)("PRISMA_QUERY_ENGINE_LIBRARY")} ${(0, import_colors.red)((0, import_colors.bold)(platform))}. Possible binaryTargets: ${(0, import_colors.green)( | ||
knownPlatforms.join(", ") | ||
)} or a path to the query engine library. | ||
You may have to run ${import_chalk.default.greenBright("prisma generate")} for your changes to take effect.`, | ||
You may have to run ${(0, import_colors.green)("prisma generate")} for your changes to take effect.`, | ||
this.config.clientVersion | ||
@@ -164,0 +160,0 @@ ); |
{ | ||
"name": "@prisma/engine-core", | ||
"version": "4.14.0-integration-fix-client-custom-output-mismatch.7", | ||
"version": "4.14.0-integration-fix-client-custom-output-mismatch.8", | ||
"description": "This package is intended for Prisma's internal use", | ||
@@ -29,6 +29,6 @@ "license": "Apache-2.0", | ||
"@opentelemetry/sdk-trace-base": "1.8.0", | ||
"chalk": "4.1.2", | ||
"execa": "5.1.1", | ||
"get-stream": "6.0.1", | ||
"indent-string": "4.0.0", | ||
"kleur": "4.1.5", | ||
"new-github-issue-url": "0.2.1", | ||
@@ -39,6 +39,6 @@ "p-retry": "4.6.2", | ||
"undici": "5.21.0", | ||
"@prisma/debug": "4.14.0-integration-fix-client-custom-output-mismatch.7", | ||
"@prisma/engines": "4.14.0-integration-fix-client-custom-output-mismatch.7", | ||
"@prisma/generator-helper": "4.14.0-integration-fix-client-custom-output-mismatch.7", | ||
"@prisma/get-platform": "4.14.0-integration-fix-client-custom-output-mismatch.7" | ||
"@prisma/debug": "4.14.0-integration-fix-client-custom-output-mismatch.8", | ||
"@prisma/engines": "4.14.0-integration-fix-client-custom-output-mismatch.8", | ||
"@prisma/generator-helper": "4.14.0-integration-fix-client-custom-output-mismatch.8", | ||
"@prisma/get-platform": "4.14.0-integration-fix-client-custom-output-mismatch.8" | ||
}, | ||
@@ -45,0 +45,0 @@ "files": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
272678
6613
+ Addedkleur@4.1.5
+ Added@prisma/debug@4.14.0-integration-fix-client-custom-output-mismatch.8(transitive)
+ Added@prisma/engines@4.14.0-integration-fix-client-custom-output-mismatch.8(transitive)
+ Added@prisma/generator-helper@4.14.0-integration-fix-client-custom-output-mismatch.8(transitive)
+ Added@prisma/get-platform@4.14.0-integration-fix-client-custom-output-mismatch.8(transitive)
+ Addedkleur@4.1.5(transitive)
- Removedchalk@4.1.2
- Removed@prisma/debug@4.14.0-integration-fix-client-custom-output-mismatch.7(transitive)
- Removed@prisma/engines@4.14.0-integration-fix-client-custom-output-mismatch.7(transitive)
- Removed@prisma/generator-helper@4.14.0-integration-fix-client-custom-output-mismatch.7(transitive)
- Removed@prisma/get-platform@4.14.0-integration-fix-client-custom-output-mismatch.7(transitive)
- Removedansi-styles@4.3.0(transitive)
- Removedchalk@4.1.2(transitive)
- Removedcolor-convert@2.0.1(transitive)
- Removedcolor-name@1.1.4(transitive)
Updated@prisma/debug@4.14.0-integration-fix-client-custom-output-mismatch.8
Updated@prisma/engines@4.14.0-integration-fix-client-custom-output-mismatch.8
Updated@prisma/generator-helper@4.14.0-integration-fix-client-custom-output-mismatch.8
Updated@prisma/get-platform@4.14.0-integration-fix-client-custom-output-mismatch.8