@prisma/query-plan-executor 7.10.0-dev.32 → 7.10.0-dev.34
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/index.js +20 -14
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -62073,7 +62073,7 @@ var require_stream2 = __commonJS({
|
|
|
62073
62073
|
}
|
|
62074
62074
|
});
|
|
62075
62075
|
Stream.Stream = Stream;
|
|
62076
|
-
Stream._isUint8Array = function
|
|
62076
|
+
Stream._isUint8Array = function isUint8Array2(value) {
|
|
62077
62077
|
return value instanceof Uint8Array;
|
|
62078
62078
|
};
|
|
62079
62079
|
Stream._uint8ArrayToBuffer = function _uint8ArrayToBuffer(chunk) {
|
|
@@ -88897,7 +88897,7 @@ var require_utils5 = __commonJS({
|
|
|
88897
88897
|
"use strict";
|
|
88898
88898
|
var defaults2 = require_defaults();
|
|
88899
88899
|
var util4 = require("util");
|
|
88900
|
-
var { isDate } = util4.types || util4;
|
|
88900
|
+
var { isDate: isDate2 } = util4.types || util4;
|
|
88901
88901
|
function escapeElement(elementRepresentation) {
|
|
88902
88902
|
const escaped = elementRepresentation.replace(/\\/g, "\\\\").replace(/"/g, '\\"');
|
|
88903
88903
|
return '"' + escaped + '"';
|
|
@@ -88945,7 +88945,7 @@ var require_utils5 = __commonJS({
|
|
|
88945
88945
|
}
|
|
88946
88946
|
return buf.slice(val.byteOffset, val.byteOffset + val.byteLength);
|
|
88947
88947
|
}
|
|
88948
|
-
if (
|
|
88948
|
+
if (isDate2(val)) {
|
|
88949
88949
|
if (defaults2.parseInputDatesAsUTC) {
|
|
88950
88950
|
return dateToStringUTC(val);
|
|
88951
88951
|
} else {
|
|
@@ -92936,7 +92936,7 @@ __export(index_exports, {
|
|
|
92936
92936
|
module.exports = __toCommonJS(index_exports);
|
|
92937
92937
|
|
|
92938
92938
|
// package.json
|
|
92939
|
-
var version = "7.10.0-dev.
|
|
92939
|
+
var version = "7.10.0-dev.34";
|
|
92940
92940
|
|
|
92941
92941
|
// ../../node_modules/.pnpm/temporal-polyfill@0.3.0/node_modules/temporal-polyfill/chunks/internal.js
|
|
92942
92942
|
function clampProp(e2, n2, t2, o2, r2) {
|
|
@@ -102896,6 +102896,12 @@ function ulid(seedTime, prng) {
|
|
|
102896
102896
|
|
|
102897
102897
|
// ../client-engine-runtime/dist/index.mjs
|
|
102898
102898
|
init_dist_node();
|
|
102899
|
+
function isUint8Array(value) {
|
|
102900
|
+
return ArrayBuffer.isView(value) && Object.prototype.toString.call(value) === "[object Uint8Array]";
|
|
102901
|
+
}
|
|
102902
|
+
function isDate(value) {
|
|
102903
|
+
return Object.prototype.toString.call(value) === "[object Date]";
|
|
102904
|
+
}
|
|
102899
102905
|
function assertNever(_3, message) {
|
|
102900
102906
|
throw new Error(message);
|
|
102901
102907
|
}
|
|
@@ -102914,11 +102920,11 @@ function doKeysMatch(lhs, rhs) {
|
|
|
102914
102920
|
const lhsDecimal = asDecimal(lhs[key]);
|
|
102915
102921
|
const rhsDecimal = asDecimal(rhs[key]);
|
|
102916
102922
|
return lhsDecimal && rhsDecimal && lhsDecimal.equals(rhsDecimal);
|
|
102917
|
-
} else if (lhs[key]
|
|
102923
|
+
} else if (isUint8Array(lhs[key]) || isUint8Array(rhs[key])) {
|
|
102918
102924
|
const lhsBuffer = asBuffer(lhs[key]);
|
|
102919
102925
|
const rhsBuffer = asBuffer(rhs[key]);
|
|
102920
102926
|
return lhsBuffer && rhsBuffer && lhsBuffer.equals(rhsBuffer);
|
|
102921
|
-
} else if (lhs[key]
|
|
102927
|
+
} else if (isDate(lhs[key]) || isDate(rhs[key])) {
|
|
102922
102928
|
return asDate(lhs[key])?.getTime() === asDate(rhs[key])?.getTime();
|
|
102923
102929
|
} else if (typeof lhs[key] === "bigint" || typeof rhs[key] === "bigint") {
|
|
102924
102930
|
return asBigInt(lhs[key]) === asBigInt(rhs[key]);
|
|
@@ -102940,7 +102946,7 @@ function asDecimal(value) {
|
|
|
102940
102946
|
function asBuffer(value) {
|
|
102941
102947
|
if (Buffer.isBuffer(value)) {
|
|
102942
102948
|
return value;
|
|
102943
|
-
} else if (value
|
|
102949
|
+
} else if (isUint8Array(value)) {
|
|
102944
102950
|
return Buffer.from(value.buffer, value.byteOffset, value.byteLength);
|
|
102945
102951
|
} else if (typeof value === "string") {
|
|
102946
102952
|
return Buffer.from(value, "base64");
|
|
@@ -102949,7 +102955,7 @@ function asBuffer(value) {
|
|
|
102949
102955
|
}
|
|
102950
102956
|
}
|
|
102951
102957
|
function asDate(value) {
|
|
102952
|
-
if (value
|
|
102958
|
+
if (isDate(value)) {
|
|
102953
102959
|
return value;
|
|
102954
102960
|
} else if (typeof value === "string" || typeof value === "number") {
|
|
102955
102961
|
return new Date(value);
|
|
@@ -103433,7 +103439,7 @@ function mapValue(value, columnName, scalarType, enums) {
|
|
|
103433
103439
|
throw new DataMapperError(`Expected a boolean in column '${columnName}', got ${typeof value}: ${value}`);
|
|
103434
103440
|
}
|
|
103435
103441
|
}
|
|
103436
|
-
if (Array.isArray(value) || value
|
|
103442
|
+
if (Array.isArray(value) || isUint8Array(value)) {
|
|
103437
103443
|
for (const byte of value) {
|
|
103438
103444
|
if (byte !== 0) return true;
|
|
103439
103445
|
}
|
|
@@ -103450,7 +103456,7 @@ function mapValue(value, columnName, scalarType, enums) {
|
|
|
103450
103456
|
if (typeof value === "string") {
|
|
103451
103457
|
return { $type: "DateTime", value: normalizeDateTime(value) };
|
|
103452
103458
|
}
|
|
103453
|
-
if (typeof value === "number" || value
|
|
103459
|
+
if (typeof value === "number" || isDate(value)) {
|
|
103454
103460
|
return { $type: "DateTime", value };
|
|
103455
103461
|
}
|
|
103456
103462
|
throw new DataMapperError(`Expected a date in column '${columnName}', got ${typeof value}: ${value}`);
|
|
@@ -103481,7 +103487,7 @@ function mapValue(value, columnName, scalarType, enums) {
|
|
|
103481
103487
|
if (Array.isArray(value)) {
|
|
103482
103488
|
return { $type: "Bytes", value: Buffer.from(value).toString("base64") };
|
|
103483
103489
|
}
|
|
103484
|
-
if (value
|
|
103490
|
+
if (isUint8Array(value)) {
|
|
103485
103491
|
return { $type: "Bytes", value: Buffer.from(value).toString("base64") };
|
|
103486
103492
|
}
|
|
103487
103493
|
throw new DataMapperError(`Expected a byte array in column '${columnName}', got ${typeof value}: ${value}`);
|
|
@@ -113101,15 +113107,15 @@ var $ZodDate = /* @__PURE__ */ $constructor("$ZodDate", (inst, def) => {
|
|
|
113101
113107
|
}
|
|
113102
113108
|
}
|
|
113103
113109
|
const input = payload.value;
|
|
113104
|
-
const
|
|
113105
|
-
const isValidDate =
|
|
113110
|
+
const isDate2 = input instanceof Date;
|
|
113111
|
+
const isValidDate = isDate2 && !Number.isNaN(input.getTime());
|
|
113106
113112
|
if (isValidDate)
|
|
113107
113113
|
return payload;
|
|
113108
113114
|
payload.issues.push({
|
|
113109
113115
|
expected: "date",
|
|
113110
113116
|
code: "invalid_type",
|
|
113111
113117
|
input,
|
|
113112
|
-
...
|
|
113118
|
+
...isDate2 ? { received: "Invalid Date" } : {},
|
|
113113
113119
|
inst
|
|
113114
113120
|
});
|
|
113115
113121
|
return payload;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/query-plan-executor",
|
|
3
|
-
"version": "7.10.0-dev.
|
|
3
|
+
"version": "7.10.0-dev.34",
|
|
4
4
|
"description": "This package is intended for Prisma's internal use",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
"hono": "^4.12.23",
|
|
20
20
|
"temporal-polyfill": "0.3.0",
|
|
21
21
|
"zod": "4.1.3",
|
|
22
|
-
"@prisma/adapter-
|
|
23
|
-
"@prisma/adapter-
|
|
24
|
-
"@prisma/
|
|
25
|
-
"@prisma/
|
|
26
|
-
"@prisma/
|
|
22
|
+
"@prisma/adapter-pg": "7.10.0-dev.34",
|
|
23
|
+
"@prisma/adapter-mariadb": "7.10.0-dev.34",
|
|
24
|
+
"@prisma/adapter-mssql": "7.10.0-dev.34",
|
|
25
|
+
"@prisma/driver-adapter-utils": "7.10.0-dev.34",
|
|
26
|
+
"@prisma/client-engine-runtime": "7.10.0-dev.34"
|
|
27
27
|
},
|
|
28
28
|
"files": [
|
|
29
29
|
"dist"
|