@prisma/client-generator-js 6.7.0-dev.32 → 6.7.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 CHANGED
@@ -4413,7 +4413,7 @@ var package_default = {
4413
4413
  test: "dotenv -e ../../.db.env -- jest --silent",
4414
4414
  "test:e2e": "dotenv -e ../../.db.env -- tsx tests/e2e/_utils/run.ts",
4415
4415
  "test:functional": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts",
4416
- "test:functional:client": "PRISMA_UNSTABLE_CLIENT_ENGINE_TYPE=1 pnpm run test:functional --adapter js_pg --client-runtime client --preview-features driverAdapters --engine-type client --runInBand --json --outputFile tests/functional/results.json decimal",
4416
+ "test:functional:client": "pnpm run test:functional --adapter js_pg --client-runtime client --preview-features driverAdapters,queryCompiler --engine-type client --runInBand --json --outputFile tests/functional/results.json decimal",
4417
4417
  "test:memory": "dotenv -e ../../.db.env -- tsx helpers/memory-tests.ts",
4418
4418
  "test:functional:code": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --no-types",
4419
4419
  "test:functional:types": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --types-only",
@@ -8806,6 +8806,9 @@ async function generateClient(options) {
8806
8806
  typedSql
8807
8807
  } = options;
8808
8808
  const clientEngineType = (0, import_internals10.getClientEngineType)(generator);
8809
+ if (clientEngineType === import_internals10.ClientEngineType.Client && !generator.previewFeatures.includes("queryCompiler")) {
8810
+ throw new Error('`engineType = "client"` requires enabling the `queryCompiler` preview feature');
8811
+ }
8809
8812
  const { runtimeBase, outputDir } = await getGenerationDirs(options);
8810
8813
  const { prismaClientDmmf, fileMap } = await buildClient({
8811
8814
  datamodel,
@@ -9068,11 +9071,6 @@ function getNodeRuntimeName(engineType) {
9068
9071
  return "library";
9069
9072
  }
9070
9073
  if (engineType === import_internals10.ClientEngineType.Client) {
9071
- if (!process.env.PRISMA_UNSTABLE_CLIENT_ENGINE_TYPE) {
9072
- throw new Error(
9073
- 'Unstable Feature: engineType="client" is in a proof of concept phase and not ready to be used publicly yet!'
9074
- );
9075
- }
9076
9074
  return "client";
9077
9075
  }
9078
9076
  (0, import_internals10.assertNever)(engineType, "Unknown engine type");
@@ -9126,7 +9124,7 @@ var import_internals12 = require("@prisma/internals");
9126
9124
  var import_ts_pattern = require("ts-pattern");
9127
9125
 
9128
9126
  // package.json
9129
- var version = "6.7.0-dev.32";
9127
+ var version = "6.7.0-dev.34";
9130
9128
 
9131
9129
  // src/resolvePrismaClient.ts
9132
9130
  var import_promises2 = __toESM(require("node:fs/promises"));
package/dist/index.mjs CHANGED
@@ -4408,7 +4408,7 @@ var package_default = {
4408
4408
  test: "dotenv -e ../../.db.env -- jest --silent",
4409
4409
  "test:e2e": "dotenv -e ../../.db.env -- tsx tests/e2e/_utils/run.ts",
4410
4410
  "test:functional": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts",
4411
- "test:functional:client": "PRISMA_UNSTABLE_CLIENT_ENGINE_TYPE=1 pnpm run test:functional --adapter js_pg --client-runtime client --preview-features driverAdapters --engine-type client --runInBand --json --outputFile tests/functional/results.json decimal",
4411
+ "test:functional:client": "pnpm run test:functional --adapter js_pg --client-runtime client --preview-features driverAdapters,queryCompiler --engine-type client --runInBand --json --outputFile tests/functional/results.json decimal",
4412
4412
  "test:memory": "dotenv -e ../../.db.env -- tsx helpers/memory-tests.ts",
4413
4413
  "test:functional:code": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --no-types",
4414
4414
  "test:functional:types": "dotenv -e ../../.db.env -- tsx helpers/functional-test/run-tests.ts --types-only",
@@ -8804,6 +8804,9 @@ async function generateClient(options) {
8804
8804
  typedSql
8805
8805
  } = options;
8806
8806
  const clientEngineType = getClientEngineType2(generator);
8807
+ if (clientEngineType === ClientEngineType3.Client && !generator.previewFeatures.includes("queryCompiler")) {
8808
+ throw new Error('`engineType = "client"` requires enabling the `queryCompiler` preview feature');
8809
+ }
8807
8810
  const { runtimeBase, outputDir } = await getGenerationDirs(options);
8808
8811
  const { prismaClientDmmf, fileMap } = await buildClient({
8809
8812
  datamodel,
@@ -9066,11 +9069,6 @@ function getNodeRuntimeName(engineType) {
9066
9069
  return "library";
9067
9070
  }
9068
9071
  if (engineType === ClientEngineType3.Client) {
9069
- if (!process.env.PRISMA_UNSTABLE_CLIENT_ENGINE_TYPE) {
9070
- throw new Error(
9071
- 'Unstable Feature: engineType="client" is in a proof of concept phase and not ready to be used publicly yet!'
9072
- );
9073
- }
9074
9072
  return "client";
9075
9073
  }
9076
9074
  assertNever3(engineType, "Unknown engine type");
@@ -9124,7 +9122,7 @@ import { ClientEngineType as ClientEngineType4, getClientEngineType as getClient
9124
9122
  import { match } from "ts-pattern";
9125
9123
 
9126
9124
  // package.json
9127
- var version = "6.7.0-dev.32";
9125
+ var version = "6.7.0-dev.34";
9128
9126
 
9129
9127
  // src/resolvePrismaClient.ts
9130
9128
  var import_execa = __toESM(require_execa());
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prisma/client-generator-js",
3
- "version": "6.7.0-dev.32",
3
+ "version": "6.7.0-dev.34",
4
4
  "description": "This package is intended for Prisma's internal use",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -33,14 +33,14 @@
33
33
  "pkg-up": "3.1.0",
34
34
  "pluralize": "8.0.0",
35
35
  "ts-pattern": "5.6.2",
36
- "@prisma/debug": "6.7.0-dev.32",
37
- "@prisma/dmmf": "6.7.0-dev.32",
38
- "@prisma/client-common": "6.7.0-dev.32",
39
- "@prisma/fetch-engine": "6.7.0-dev.32",
40
- "@prisma/get-platform": "6.7.0-dev.32",
41
- "@prisma/generator": "6.7.0-dev.32",
42
- "@prisma/ts-builders": "6.7.0-dev.32",
43
- "@prisma/internals": "6.7.0-dev.32"
36
+ "@prisma/client-common": "6.7.0-dev.34",
37
+ "@prisma/debug": "6.7.0-dev.34",
38
+ "@prisma/fetch-engine": "6.7.0-dev.34",
39
+ "@prisma/dmmf": "6.7.0-dev.34",
40
+ "@prisma/generator": "6.7.0-dev.34",
41
+ "@prisma/get-platform": "6.7.0-dev.34",
42
+ "@prisma/internals": "6.7.0-dev.34",
43
+ "@prisma/ts-builders": "6.7.0-dev.34"
44
44
  },
45
45
  "devDependencies": {
46
46
  "@types/pluralize": "0.0.33",