@prisma/client 6.19.0-integration-feat-remove-library-engine.4 → 6.19.0-integration-next.15

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prisma/client",
3
- "version": "6.19.0-integration-feat-remove-library-engine.4",
3
+ "version": "6.19.0-integration-next.15",
4
4
  "description": "Prisma Client is an auto-generated, type-safe and modern JavaScript/TypeScript ORM for Node.js that's tailored to your data. Supports PostgreSQL, CockroachDB, MySQL, MariaDB, SQL Server, SQLite & MongoDB databases.",
5
5
  "keywords": [
6
6
  "ORM",
@@ -87,6 +87,18 @@
87
87
  "import": "./runtime/client.mjs",
88
88
  "default": "./runtime/client.mjs"
89
89
  },
90
+ "./runtime/library": {
91
+ "types": "./runtime/library.d.ts",
92
+ "require": "./runtime/library.js",
93
+ "import": "./runtime/library.mjs",
94
+ "default": "./runtime/library.mjs"
95
+ },
96
+ "./runtime/binary": {
97
+ "types": "./runtime/binary.d.ts",
98
+ "require": "./runtime/binary.js",
99
+ "import": "./runtime/binary.mjs",
100
+ "default": "./runtime/binary.mjs"
101
+ },
90
102
  "./runtime/wasm-compiler-edge": {
91
103
  "types": "./runtime/wasm-compiler-edge.d.ts",
92
104
  "require": "./runtime/wasm-compiler-edge.js",
@@ -150,7 +162,7 @@
150
162
  "sql.mjs"
151
163
  ],
152
164
  "devDependencies": {
153
- "@cloudflare/workers-types": "^4.20251014.0",
165
+ "@cloudflare/workers-types": "^4.20250408.0",
154
166
  "@codspeed/benchmark.js-plugin": "4.0.0",
155
167
  "@faker-js/faker": "9.6.0",
156
168
  "@fast-check/jest": "2.0.3",
@@ -181,7 +193,7 @@
181
193
  "@types/jest": "29.5.14",
182
194
  "@types/js-levenshtein": "1.1.3",
183
195
  "@types/mssql": "9.1.8",
184
- "@types/node": "~20.19.24",
196
+ "@types/node": "~20.19.0",
185
197
  "@types/pg": "8.11.11",
186
198
  "arg": "5.0.2",
187
199
  "benchmark": "2.1.4",
@@ -219,35 +231,35 @@
219
231
  "typescript": "5.4.5",
220
232
  "undici": "7.4.0",
221
233
  "zx": "8.4.1",
222
- "@prisma/adapter-libsql": "6.19.0-integration-feat-remove-library-engine.4",
223
- "@prisma/adapter-mariadb": "6.19.0-integration-feat-remove-library-engine.4",
224
- "@prisma/adapter-d1": "6.19.0-integration-feat-remove-library-engine.4",
225
- "@prisma/adapter-mssql": "6.19.0-integration-feat-remove-library-engine.4",
226
- "@prisma/adapter-neon": "6.19.0-integration-feat-remove-library-engine.4",
227
- "@prisma/adapter-better-sqlite3": "6.19.0-integration-feat-remove-library-engine.4",
228
- "@prisma/adapter-pg": "6.19.0-integration-feat-remove-library-engine.4",
229
- "@prisma/adapter-planetscale": "6.19.0-integration-feat-remove-library-engine.4",
230
- "@prisma/client-common": "6.19.0-integration-feat-remove-library-engine.4",
231
- "@prisma/client-engine-runtime": "6.19.0-integration-feat-remove-library-engine.4",
232
- "@prisma/client-generator-js": "6.19.0-integration-feat-remove-library-engine.4",
233
- "@prisma/debug": "6.19.0-integration-feat-remove-library-engine.4",
234
- "@prisma/client-generator-ts": "6.19.0-integration-feat-remove-library-engine.4",
235
- "@prisma/config": "6.19.0-integration-feat-remove-library-engine.4",
236
- "@prisma/driver-adapter-utils": "6.19.0-integration-feat-remove-library-engine.4",
237
- "@prisma/dmmf": "6.19.0-integration-feat-remove-library-engine.4",
238
- "@prisma/engines": "6.19.0-integration-feat-remove-library-engine.4",
239
- "@prisma/generator": "6.19.0-integration-feat-remove-library-engine.4",
240
- "@prisma/generator-helper": "6.19.0-integration-feat-remove-library-engine.4",
241
- "@prisma/get-platform": "6.19.0-integration-feat-remove-library-engine.4",
242
- "@prisma/fetch-engine": "6.19.0-integration-feat-remove-library-engine.4",
243
- "@prisma/instrumentation": "6.19.0-integration-feat-remove-library-engine.4",
244
- "@prisma/internals": "6.19.0-integration-feat-remove-library-engine.4",
245
- "@prisma/migrate": "6.19.0-integration-feat-remove-library-engine.4",
246
- "@prisma/query-plan-executor": "6.19.0-integration-feat-remove-library-engine.4",
247
- "@prisma/ts-builders": "6.19.0-integration-feat-remove-library-engine.4"
234
+ "@prisma/adapter-d1": "6.19.0-integration-next.15",
235
+ "@prisma/adapter-libsql": "6.19.0-integration-next.15",
236
+ "@prisma/adapter-mariadb": "6.19.0-integration-next.15",
237
+ "@prisma/adapter-better-sqlite3": "6.19.0-integration-next.15",
238
+ "@prisma/adapter-mssql": "6.19.0-integration-next.15",
239
+ "@prisma/adapter-neon": "6.19.0-integration-next.15",
240
+ "@prisma/adapter-pg": "6.19.0-integration-next.15",
241
+ "@prisma/adapter-planetscale": "6.19.0-integration-next.15",
242
+ "@prisma/client-common": "6.19.0-integration-next.15",
243
+ "@prisma/client-engine-runtime": "6.19.0-integration-next.15",
244
+ "@prisma/client-generator-ts": "6.19.0-integration-next.15",
245
+ "@prisma/client-generator-js": "6.19.0-integration-next.15",
246
+ "@prisma/config": "6.19.0-integration-next.15",
247
+ "@prisma/debug": "6.19.0-integration-next.15",
248
+ "@prisma/driver-adapter-utils": "6.19.0-integration-next.15",
249
+ "@prisma/engines": "6.19.0-integration-next.15",
250
+ "@prisma/dmmf": "6.19.0-integration-next.15",
251
+ "@prisma/generator": "6.19.0-integration-next.15",
252
+ "@prisma/generator-helper": "6.19.0-integration-next.15",
253
+ "@prisma/instrumentation": "6.19.0-integration-next.15",
254
+ "@prisma/fetch-engine": "6.19.0-integration-next.15",
255
+ "@prisma/internals": "6.19.0-integration-next.15",
256
+ "@prisma/get-platform": "6.19.0-integration-next.15",
257
+ "@prisma/query-plan-executor": "6.19.0-integration-next.15",
258
+ "@prisma/migrate": "6.19.0-integration-next.15",
259
+ "@prisma/ts-builders": "6.19.0-integration-next.15"
248
260
  },
249
261
  "dependencies": {
250
- "@prisma/client-runtime-utils": "6.19.0-integration-feat-remove-library-engine.4"
262
+ "@prisma/client-runtime-utils": "6.19.0-integration-next.15"
251
263
  },
252
264
  "peerDependencies": {
253
265
  "prisma": "*",
@@ -268,7 +280,7 @@
268
280
  "test": "dotenv -e ../../.db.env -- jest --silent",
269
281
  "test:e2e": "dotenv -e ../../.db.env -- tsx tests/e2e/_utils/run.ts",
270
282
  "test:functional": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts",
271
- "test:functional:client": "pnpm run test:functional --client-runtime client",
283
+ "test:functional:client": "pnpm run test:functional --client-runtime client --engine-type client",
272
284
  "test:memory": "dotenv -e ../../.db.env -- tsx helpers/memory-tests.ts",
273
285
  "test:functional:code": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --no-types",
274
286
  "test:functional:types": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --types-only",
@@ -25,6 +25,20 @@ import { Value } from '@prisma/client-runtime-utils';
25
25
  */
26
26
  declare function $extends(this: Client, extension: ExtensionArgs | ((client: Client) => Client)): Client;
27
27
 
28
+ /**
29
+ * Used by `@prisma/extension-accelerate` until we migrate it to a better API.
30
+ */
31
+ declare interface AccelerateEngineConfig extends EngineConfig {
32
+ /**
33
+ * Allows Accelerate to use runtime utilities from the client. These are
34
+ * necessary for `@prisma/extension-accelerate` to function correctly.
35
+ * See <https://github.com/prisma/prisma-extension-accelerate/blob/b6ffa853f038780f5ab2fc01bff584ca251f645b/src/extension.ts#L518>
36
+ */
37
+ accelerateUtils: {
38
+ resolveDatasourceUrl: () => string;
39
+ };
40
+ }
41
+
28
42
  /**
29
43
  * A stripped down interface of `fetch` that `@prisma/extension-accelerate`
30
44
  * relies on. It must be in sync with the corresponding definition in the
@@ -792,6 +806,10 @@ declare interface EngineConfig {
792
806
  * @remarks only used by LibraryEngine.ts
793
807
  */
794
808
  adapter?: SqlDriverAdapterFactory;
809
+ /**
810
+ * Prisma Accelerate URL allowing the client to connect through Accelerate instead of a direct database.
811
+ */
812
+ accelerateUrl?: string;
795
813
  /**
796
814
  * The contents of the schema encoded into a string
797
815
  */
@@ -818,21 +836,6 @@ declare interface EngineConfig {
818
836
  */
819
837
  engineWasm?: EngineWasmLoadingConfig;
820
838
  compilerWasm?: CompilerWasmLoadingConfig;
821
- /**
822
- * Allows Accelerate to use runtime utilities from the client. These are
823
- * necessary for the AccelerateEngine to function correctly.
824
- */
825
- accelerateUtils?: {
826
- resolveDatasourceUrl: typeof resolveDatasourceUrl;
827
- getBatchRequestPayload: typeof getBatchRequestPayload;
828
- prismaGraphQLToJSError: typeof prismaGraphQLToJSError;
829
- PrismaClientUnknownRequestError: typeof PrismaClientUnknownRequestError;
830
- PrismaClientInitializationError: typeof PrismaClientInitializationError;
831
- PrismaClientKnownRequestError: typeof PrismaClientKnownRequestError;
832
- debug: (...args: any[]) => void;
833
- engineVersion: string;
834
- clientVersion: string;
835
- };
836
839
  }
837
840
 
838
841
  declare type EngineEvent<E extends EngineEventType> = E extends QueryEventType ? QueryEvent : LogEvent;
@@ -1204,8 +1207,6 @@ export declare type GetAggregateResult<P extends OperationPayload, A> = {
1204
1207
  };
1205
1208
  };
1206
1209
 
1207
- declare function getBatchRequestPayload(batch: JsonQuery[], transaction?: TransactionOptions_2<unknown>): QueryEngineBatchRequest;
1208
-
1209
1210
  export declare type GetBatchResult = {
1210
1211
  count: number;
1211
1212
  };
@@ -1264,6 +1265,7 @@ export declare function getPrismaClient(config: GetPrismaClientConfig): {
1264
1265
  _connectionPromise?: Promise<any> | undefined;
1265
1266
  _disconnectionPromise?: Promise<any> | undefined;
1266
1267
  _engineConfig: EngineConfig;
1268
+ _accelerateEngineConfig: AccelerateEngineConfig;
1267
1269
  _clientVersion: string;
1268
1270
  _errorFormat: ErrorFormat;
1269
1271
  _tracingHelper: TracingHelper;
@@ -2243,7 +2245,11 @@ export declare type PrismaClientOptions = {
2243
2245
  /**
2244
2246
  * Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale.
2245
2247
  */
2246
- adapter?: SqlDriverAdapterFactory | null;
2248
+ adapter?: SqlDriverAdapterFactory;
2249
+ /**
2250
+ * Prisma Accelerate URL allowing the client to connect through Accelerate instead of a direct database.
2251
+ */
2252
+ accelerateUrl?: string;
2247
2253
  /**
2248
2254
  * Overwrites the datasource url from your schema.prisma file
2249
2255
  */
@@ -2298,8 +2304,6 @@ export { PrismaClientUnknownRequestError }
2298
2304
 
2299
2305
  export { PrismaClientValidationError }
2300
2306
 
2301
- declare function prismaGraphQLToJSError({ error, user_facing_error }: RequestError, clientVersion: string, activeProvider: string): PrismaClientKnownRequestError | PrismaClientUnknownRequestError;
2302
-
2303
2307
  declare type PrismaOperationSpec<TArgs, TAction = string> = {
2304
2308
  args: TArgs;
2305
2309
  action: TAction;
@@ -2445,14 +2449,6 @@ declare type QueryCompilerOptions = {
2445
2449
  connectionInfo: ConnectionInfo;
2446
2450
  };
2447
2451
 
2448
- declare type QueryEngineBatchGraphQLRequest = {
2449
- batch: QueryEngineRequest[];
2450
- transaction?: boolean;
2451
- isolationLevel?: IsolationLevel_2;
2452
- };
2453
-
2454
- declare type QueryEngineBatchRequest = QueryEngineBatchGraphQLRequest | JsonBatchQuery;
2455
-
2456
2452
  declare type QueryEngineConfig = {
2457
2453
  datamodel: string;
2458
2454
  configDir: string;
@@ -2493,11 +2489,6 @@ declare type QueryEngineLogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error'
2493
2489
 
2494
2490
  declare type QueryEngineProtocol = 'graphql' | 'json';
2495
2491
 
2496
- declare type QueryEngineRequest = {
2497
- query: string;
2498
- variables: Object;
2499
- };
2500
-
2501
2492
  declare type QueryEngineResultData<T> = {
2502
2493
  data: T;
2503
2494
  };
@@ -2723,17 +2714,6 @@ declare type RequestBatchOptions<InteractiveTransactionPayload> = {
2723
2714
  customDataProxyFetch?: AccelerateExtensionFetchDecorator;
2724
2715
  };
2725
2716
 
2726
- declare interface RequestError {
2727
- error: string;
2728
- user_facing_error: {
2729
- is_panic: boolean;
2730
- message: string;
2731
- meta?: Record<string, unknown>;
2732
- error_code?: string;
2733
- batch_request_idx?: number;
2734
- };
2735
- }
2736
-
2737
2717
  declare class RequestHandler {
2738
2718
  client: Client;
2739
2719
  dataloader: DataLoader<RequestParams>;
@@ -2786,13 +2766,6 @@ export declare type RequiredKeys<O> = {
2786
2766
  [K in keyof O]-?: {} extends Pick_2<O, K> ? never : K;
2787
2767
  }[keyof O];
2788
2768
 
2789
- declare function resolveDatasourceUrl({ inlineDatasources, overrideDatasources, env, clientVersion, }: {
2790
- inlineDatasources: GetPrismaClientConfig['inlineDatasources'];
2791
- overrideDatasources: Datasources;
2792
- env: Record<string, string | undefined>;
2793
- clientVersion: string;
2794
- }): string;
2795
-
2796
2769
  export declare type Result<T, A, F extends Operation> = T extends {
2797
2770
  [K: symbol]: {
2798
2771
  types: {
@@ -25,6 +25,20 @@ import { Value } from '@prisma/client-runtime-utils';
25
25
  */
26
26
  declare function $extends(this: Client, extension: ExtensionArgs | ((client: Client) => Client)): Client;
27
27
 
28
+ /**
29
+ * Used by `@prisma/extension-accelerate` until we migrate it to a better API.
30
+ */
31
+ declare interface AccelerateEngineConfig extends EngineConfig {
32
+ /**
33
+ * Allows Accelerate to use runtime utilities from the client. These are
34
+ * necessary for `@prisma/extension-accelerate` to function correctly.
35
+ * See <https://github.com/prisma/prisma-extension-accelerate/blob/b6ffa853f038780f5ab2fc01bff584ca251f645b/src/extension.ts#L518>
36
+ */
37
+ accelerateUtils: {
38
+ resolveDatasourceUrl: () => string;
39
+ };
40
+ }
41
+
28
42
  /**
29
43
  * A stripped down interface of `fetch` that `@prisma/extension-accelerate`
30
44
  * relies on. It must be in sync with the corresponding definition in the
@@ -792,6 +806,10 @@ declare interface EngineConfig {
792
806
  * @remarks only used by LibraryEngine.ts
793
807
  */
794
808
  adapter?: SqlDriverAdapterFactory;
809
+ /**
810
+ * Prisma Accelerate URL allowing the client to connect through Accelerate instead of a direct database.
811
+ */
812
+ accelerateUrl?: string;
795
813
  /**
796
814
  * The contents of the schema encoded into a string
797
815
  */
@@ -818,21 +836,6 @@ declare interface EngineConfig {
818
836
  */
819
837
  engineWasm?: EngineWasmLoadingConfig;
820
838
  compilerWasm?: CompilerWasmLoadingConfig;
821
- /**
822
- * Allows Accelerate to use runtime utilities from the client. These are
823
- * necessary for the AccelerateEngine to function correctly.
824
- */
825
- accelerateUtils?: {
826
- resolveDatasourceUrl: typeof resolveDatasourceUrl;
827
- getBatchRequestPayload: typeof getBatchRequestPayload;
828
- prismaGraphQLToJSError: typeof prismaGraphQLToJSError;
829
- PrismaClientUnknownRequestError: typeof PrismaClientUnknownRequestError;
830
- PrismaClientInitializationError: typeof PrismaClientInitializationError;
831
- PrismaClientKnownRequestError: typeof PrismaClientKnownRequestError;
832
- debug: (...args: any[]) => void;
833
- engineVersion: string;
834
- clientVersion: string;
835
- };
836
839
  }
837
840
 
838
841
  declare type EngineEvent<E extends EngineEventType> = E extends QueryEventType ? QueryEvent : LogEvent;
@@ -1204,8 +1207,6 @@ export declare type GetAggregateResult<P extends OperationPayload, A> = {
1204
1207
  };
1205
1208
  };
1206
1209
 
1207
- declare function getBatchRequestPayload(batch: JsonQuery[], transaction?: TransactionOptions_2<unknown>): QueryEngineBatchRequest;
1208
-
1209
1210
  export declare type GetBatchResult = {
1210
1211
  count: number;
1211
1212
  };
@@ -1264,6 +1265,7 @@ export declare function getPrismaClient(config: GetPrismaClientConfig): {
1264
1265
  _connectionPromise?: Promise<any> | undefined;
1265
1266
  _disconnectionPromise?: Promise<any> | undefined;
1266
1267
  _engineConfig: EngineConfig;
1268
+ _accelerateEngineConfig: AccelerateEngineConfig;
1267
1269
  _clientVersion: string;
1268
1270
  _errorFormat: ErrorFormat;
1269
1271
  _tracingHelper: TracingHelper;
@@ -2243,7 +2245,11 @@ export declare type PrismaClientOptions = {
2243
2245
  /**
2244
2246
  * Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale.
2245
2247
  */
2246
- adapter?: SqlDriverAdapterFactory | null;
2248
+ adapter?: SqlDriverAdapterFactory;
2249
+ /**
2250
+ * Prisma Accelerate URL allowing the client to connect through Accelerate instead of a direct database.
2251
+ */
2252
+ accelerateUrl?: string;
2247
2253
  /**
2248
2254
  * Overwrites the datasource url from your schema.prisma file
2249
2255
  */
@@ -2298,8 +2304,6 @@ export { PrismaClientUnknownRequestError }
2298
2304
 
2299
2305
  export { PrismaClientValidationError }
2300
2306
 
2301
- declare function prismaGraphQLToJSError({ error, user_facing_error }: RequestError, clientVersion: string, activeProvider: string): PrismaClientKnownRequestError | PrismaClientUnknownRequestError;
2302
-
2303
2307
  declare type PrismaOperationSpec<TArgs, TAction = string> = {
2304
2308
  args: TArgs;
2305
2309
  action: TAction;
@@ -2445,14 +2449,6 @@ declare type QueryCompilerOptions = {
2445
2449
  connectionInfo: ConnectionInfo;
2446
2450
  };
2447
2451
 
2448
- declare type QueryEngineBatchGraphQLRequest = {
2449
- batch: QueryEngineRequest[];
2450
- transaction?: boolean;
2451
- isolationLevel?: IsolationLevel_2;
2452
- };
2453
-
2454
- declare type QueryEngineBatchRequest = QueryEngineBatchGraphQLRequest | JsonBatchQuery;
2455
-
2456
2452
  declare type QueryEngineConfig = {
2457
2453
  datamodel: string;
2458
2454
  configDir: string;
@@ -2493,11 +2489,6 @@ declare type QueryEngineLogLevel = 'trace' | 'debug' | 'info' | 'warn' | 'error'
2493
2489
 
2494
2490
  declare type QueryEngineProtocol = 'graphql' | 'json';
2495
2491
 
2496
- declare type QueryEngineRequest = {
2497
- query: string;
2498
- variables: Object;
2499
- };
2500
-
2501
2492
  declare type QueryEngineResultData<T> = {
2502
2493
  data: T;
2503
2494
  };
@@ -2723,17 +2714,6 @@ declare type RequestBatchOptions<InteractiveTransactionPayload> = {
2723
2714
  customDataProxyFetch?: AccelerateExtensionFetchDecorator;
2724
2715
  };
2725
2716
 
2726
- declare interface RequestError {
2727
- error: string;
2728
- user_facing_error: {
2729
- is_panic: boolean;
2730
- message: string;
2731
- meta?: Record<string, unknown>;
2732
- error_code?: string;
2733
- batch_request_idx?: number;
2734
- };
2735
- }
2736
-
2737
2717
  declare class RequestHandler {
2738
2718
  client: Client;
2739
2719
  dataloader: DataLoader<RequestParams>;
@@ -2786,13 +2766,6 @@ export declare type RequiredKeys<O> = {
2786
2766
  [K in keyof O]-?: {} extends Pick_2<O, K> ? never : K;
2787
2767
  }[keyof O];
2788
2768
 
2789
- declare function resolveDatasourceUrl({ inlineDatasources, overrideDatasources, env, clientVersion, }: {
2790
- inlineDatasources: GetPrismaClientConfig['inlineDatasources'];
2791
- overrideDatasources: Datasources;
2792
- env: Record<string, string | undefined>;
2793
- clientVersion: string;
2794
- }): string;
2795
-
2796
2769
  export declare type Result<T, A, F extends Operation> = T extends {
2797
2770
  [K: symbol]: {
2798
2771
  types: {