@prisma/client-engine-runtime 6.14.0-dev.31 → 6.14.0-dev.33

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
@@ -458,7 +458,7 @@ function rethrowAsUserFacingRawError(error) {
458
458
  throw error;
459
459
  }
460
460
  throw new UserFacingError(
461
- `Raw query failed. Code: ${error.cause.originalCode ?? "N/A"}. Message: ${error.cause.originalMessage ?? renderErrorMessage(error)}`,
461
+ `Raw query failed. Code: \`${error.cause.originalCode ?? "N/A"}\`. Message: \`${error.cause.originalMessage ?? renderErrorMessage(error)}\``,
462
462
  "P2010",
463
463
  { driverAdapterError: error }
464
464
  );
@@ -574,7 +574,7 @@ function renderErrorMessage(err) {
574
574
  return `The column \`${column}\` does not exist in the current database.`;
575
575
  }
576
576
  case "InvalidIsolationLevel":
577
- return `Invalid isolation level \`${err.cause.level}\``;
577
+ return `Error in connector: Conversion error: ${err.cause.level}`;
578
578
  case "InconsistentColumnData":
579
579
  return `Inconsistent column data: ${err.cause.cause}`;
580
580
  case "MissingFullTextSearchIndex":
@@ -1826,7 +1826,7 @@ var TransactionStartTimeoutError = class extends TransactionManagerError {
1826
1826
  var TransactionExecutionTimeoutError = class extends TransactionManagerError {
1827
1827
  constructor(operation, { timeout, timeTaken }) {
1828
1828
  super(
1829
- `A ${operation} cannot be executed on an expired transaction. The timeout for this transaction was ${timeout} ms, however ${timeTaken} ms passed since the start of the transaction. Consider increasing the interactive transaction timeout or doing less work in the transaction`,
1829
+ `A ${operation} cannot be executed on an expired transaction. The timeout for this transaction was ${timeout} ms, however ${timeTaken} ms passed since the start of the transaction. Consider increasing the interactive transaction timeout or doing less work in the transaction.`,
1830
1830
  { operation, timeout, timeTaken }
1831
1831
  );
1832
1832
  }
@@ -1897,7 +1897,7 @@ var TransactionManager = class {
1897
1897
  this.transactions.set(transaction.id, transaction);
1898
1898
  let hasTimedOut = false;
1899
1899
  const startTimer = setTimeout(() => hasTimedOut = true, validatedOptions.maxWait);
1900
- transaction.transaction = await this.driverAdapter.startTransaction(validatedOptions.isolationLevel);
1900
+ transaction.transaction = await this.driverAdapter.startTransaction(validatedOptions.isolationLevel).catch(rethrowAsUserFacing);
1901
1901
  clearTimeout(startTimer);
1902
1902
  switch (transaction.status) {
1903
1903
  case "waiting":
package/dist/index.mjs CHANGED
@@ -408,7 +408,7 @@ function rethrowAsUserFacingRawError(error) {
408
408
  throw error;
409
409
  }
410
410
  throw new UserFacingError(
411
- `Raw query failed. Code: ${error.cause.originalCode ?? "N/A"}. Message: ${error.cause.originalMessage ?? renderErrorMessage(error)}`,
411
+ `Raw query failed. Code: \`${error.cause.originalCode ?? "N/A"}\`. Message: \`${error.cause.originalMessage ?? renderErrorMessage(error)}\``,
412
412
  "P2010",
413
413
  { driverAdapterError: error }
414
414
  );
@@ -524,7 +524,7 @@ function renderErrorMessage(err) {
524
524
  return `The column \`${column}\` does not exist in the current database.`;
525
525
  }
526
526
  case "InvalidIsolationLevel":
527
- return `Invalid isolation level \`${err.cause.level}\``;
527
+ return `Error in connector: Conversion error: ${err.cause.level}`;
528
528
  case "InconsistentColumnData":
529
529
  return `Inconsistent column data: ${err.cause.cause}`;
530
530
  case "MissingFullTextSearchIndex":
@@ -1776,7 +1776,7 @@ var TransactionStartTimeoutError = class extends TransactionManagerError {
1776
1776
  var TransactionExecutionTimeoutError = class extends TransactionManagerError {
1777
1777
  constructor(operation, { timeout, timeTaken }) {
1778
1778
  super(
1779
- `A ${operation} cannot be executed on an expired transaction. The timeout for this transaction was ${timeout} ms, however ${timeTaken} ms passed since the start of the transaction. Consider increasing the interactive transaction timeout or doing less work in the transaction`,
1779
+ `A ${operation} cannot be executed on an expired transaction. The timeout for this transaction was ${timeout} ms, however ${timeTaken} ms passed since the start of the transaction. Consider increasing the interactive transaction timeout or doing less work in the transaction.`,
1780
1780
  { operation, timeout, timeTaken }
1781
1781
  );
1782
1782
  }
@@ -1847,7 +1847,7 @@ var TransactionManager = class {
1847
1847
  this.transactions.set(transaction.id, transaction);
1848
1848
  let hasTimedOut = false;
1849
1849
  const startTimer = setTimeout(() => hasTimedOut = true, validatedOptions.maxWait);
1850
- transaction.transaction = await this.driverAdapter.startTransaction(validatedOptions.isolationLevel);
1850
+ transaction.transaction = await this.driverAdapter.startTransaction(validatedOptions.isolationLevel).catch(rethrowAsUserFacing);
1851
1851
  clearTimeout(startTimer);
1852
1852
  switch (transaction.status) {
1853
1853
  case "waiting":
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prisma/client-engine-runtime",
3
- "version": "6.14.0-dev.31",
3
+ "version": "6.14.0-dev.33",
4
4
  "description": "This package is intended for Prisma's internal use",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -31,8 +31,8 @@
31
31
  "nanoid": "5.1.5",
32
32
  "ulid": "3.0.0",
33
33
  "uuid": "11.1.0",
34
- "@prisma/debug": "6.14.0-dev.31",
35
- "@prisma/driver-adapter-utils": "6.14.0-dev.31"
34
+ "@prisma/debug": "6.14.0-dev.33",
35
+ "@prisma/driver-adapter-utils": "6.14.0-dev.33"
36
36
  },
37
37
  "devDependencies": {
38
38
  "@types/jest": "29.5.14",