@prisma/fetch-engine 6.6.0 → 6.7.0-dev.1

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.
@@ -17,7 +17,7 @@ var __copyProps = (to, from, except, desc) => {
17
17
  }
18
18
  return to;
19
19
  };
20
- var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
21
  // If the importer is in node compatibility mode or this is not an ESM
22
22
  // file that has been converted to a CommonJS file using a Babel-
23
23
  // compatible transform (i.e. "__esModule" has not been set), then set
@@ -26,8 +26,8 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_J2EYJ4KV_exports = {};
30
- __export(chunk_J2EYJ4KV_exports, {
29
+ var chunk_YM7NA3FO_exports = {};
30
+ __export(chunk_YM7NA3FO_exports, {
31
31
  download: () => download,
32
32
  getBinaryName: () => getBinaryName,
33
33
  getVersion: () => getVersion,
@@ -35,7 +35,7 @@ __export(chunk_J2EYJ4KV_exports, {
35
35
  plusX: () => plusX,
36
36
  vercelPkgPathRegex: () => vercelPkgPathRegex
37
37
  });
38
- module.exports = __toCommonJS(chunk_J2EYJ4KV_exports);
38
+ module.exports = __toCommonJS(chunk_YM7NA3FO_exports);
39
39
  var import_chunk_MWVY55RY = require("./chunk-MWVY55RY.js");
40
40
  var import_chunk_MX3HXAU2 = require("./chunk-MX3HXAU2.js");
41
41
  var import_chunk_4GLRZ2GS = require("./chunk-4GLRZ2GS.js");
@@ -44,10 +44,10 @@ var import_chunk_YJOPKU47 = require("./chunk-YJOPKU47.js");
44
44
  var import_chunk_PXQVM7NP = require("./chunk-PXQVM7NP.js");
45
45
  var import_chunk_CWGQAQ3T = require("./chunk-CWGQAQ3T.js");
46
46
  var import_chunk_QGM4M3NI = require("./chunk-QGM4M3NI.js");
47
- var import_debug = __toESM2(require("@prisma/debug"));
47
+ var import_debug = __toESM(require("@prisma/debug"));
48
48
  var import_get_platform = require("@prisma/get-platform");
49
- var import_fs = __toESM2(require("fs"));
50
- var import_path = __toESM2(require("path"));
49
+ var import_fs = __toESM(require("fs"));
50
+ var import_path = __toESM(require("path"));
51
51
  var import_util = require("util");
52
52
  var require_windows = (0, import_chunk_QGM4M3NI.__commonJS)({
53
53
  "../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js"(exports, module2) {
@@ -55,8 +55,8 @@ var require_windows = (0, import_chunk_QGM4M3NI.__commonJS)({
55
55
  module2.exports = isexe;
56
56
  isexe.sync = sync;
57
57
  var fs2 = (0, import_chunk_QGM4M3NI.__require)("fs");
58
- function checkPathExt(path2, options2) {
59
- var pathext = options2.pathExt !== void 0 ? options2.pathExt : process.env.PATHEXT;
58
+ function checkPathExt(path2, options) {
59
+ var pathext = options.pathExt !== void 0 ? options.pathExt : process.env.PATHEXT;
60
60
  if (!pathext) {
61
61
  return true;
62
62
  }
@@ -72,19 +72,19 @@ var require_windows = (0, import_chunk_QGM4M3NI.__commonJS)({
72
72
  }
73
73
  return false;
74
74
  }
75
- function checkStat(stat, path2, options2) {
75
+ function checkStat(stat, path2, options) {
76
76
  if (!stat.isSymbolicLink() && !stat.isFile()) {
77
77
  return false;
78
78
  }
79
- return checkPathExt(path2, options2);
79
+ return checkPathExt(path2, options);
80
80
  }
81
- function isexe(path2, options2, cb) {
81
+ function isexe(path2, options, cb) {
82
82
  fs2.stat(path2, function(er, stat) {
83
- cb(er, er ? false : checkStat(stat, path2, options2));
83
+ cb(er, er ? false : checkStat(stat, path2, options));
84
84
  });
85
85
  }
86
- function sync(path2, options2) {
87
- return checkStat(fs2.statSync(path2), path2, options2);
86
+ function sync(path2, options) {
87
+ return checkStat(fs2.statSync(path2), path2, options);
88
88
  }
89
89
  }
90
90
  });
@@ -94,23 +94,23 @@ var require_mode = (0, import_chunk_QGM4M3NI.__commonJS)({
94
94
  module2.exports = isexe;
95
95
  isexe.sync = sync;
96
96
  var fs2 = (0, import_chunk_QGM4M3NI.__require)("fs");
97
- function isexe(path2, options2, cb) {
97
+ function isexe(path2, options, cb) {
98
98
  fs2.stat(path2, function(er, stat) {
99
- cb(er, er ? false : checkStat(stat, options2));
99
+ cb(er, er ? false : checkStat(stat, options));
100
100
  });
101
101
  }
102
- function sync(path2, options2) {
103
- return checkStat(fs2.statSync(path2), options2);
102
+ function sync(path2, options) {
103
+ return checkStat(fs2.statSync(path2), options);
104
104
  }
105
- function checkStat(stat, options2) {
106
- return stat.isFile() && checkMode(stat, options2);
105
+ function checkStat(stat, options) {
106
+ return stat.isFile() && checkMode(stat, options);
107
107
  }
108
- function checkMode(stat, options2) {
108
+ function checkMode(stat, options) {
109
109
  var mod = stat.mode;
110
110
  var uid = stat.uid;
111
111
  var gid = stat.gid;
112
- var myUid = options2.uid !== void 0 ? options2.uid : process.getuid && process.getuid();
113
- var myGid = options2.gid !== void 0 ? options2.gid : process.getgid && process.getgid();
112
+ var myUid = options.uid !== void 0 ? options.uid : process.getuid && process.getuid();
113
+ var myGid = options.gid !== void 0 ? options.gid : process.getgid && process.getgid();
114
114
  var u = parseInt("100", 8);
115
115
  var g = parseInt("010", 8);
116
116
  var o = parseInt("001", 8);
@@ -132,17 +132,17 @@ var require_isexe = (0, import_chunk_QGM4M3NI.__commonJS)({
132
132
  }
133
133
  module2.exports = isexe;
134
134
  isexe.sync = sync;
135
- function isexe(path2, options2, cb) {
136
- if (typeof options2 === "function") {
137
- cb = options2;
138
- options2 = {};
135
+ function isexe(path2, options, cb) {
136
+ if (typeof options === "function") {
137
+ cb = options;
138
+ options = {};
139
139
  }
140
140
  if (!cb) {
141
141
  if (typeof Promise !== "function") {
142
142
  throw new TypeError("callback not provided");
143
143
  }
144
144
  return new Promise(function(resolve, reject) {
145
- isexe(path2, options2 || {}, function(er, is) {
145
+ isexe(path2, options || {}, function(er, is) {
146
146
  if (er) {
147
147
  reject(er);
148
148
  } else {
@@ -151,9 +151,9 @@ var require_isexe = (0, import_chunk_QGM4M3NI.__commonJS)({
151
151
  });
152
152
  });
153
153
  }
154
- core(path2, options2 || {}, function(er, is) {
154
+ core(path2, options || {}, function(er, is) {
155
155
  if (er) {
156
- if (er.code === "EACCES" || options2 && options2.ignoreErrors) {
156
+ if (er.code === "EACCES" || options && options.ignoreErrors) {
157
157
  er = null;
158
158
  is = false;
159
159
  }
@@ -161,11 +161,11 @@ var require_isexe = (0, import_chunk_QGM4M3NI.__commonJS)({
161
161
  cb(er, is);
162
162
  });
163
163
  }
164
- function sync(path2, options2) {
164
+ function sync(path2, options) {
165
165
  try {
166
- return core.sync(path2, options2 || {});
166
+ return core.sync(path2, options || {});
167
167
  } catch (er) {
168
- if (options2 && options2.ignoreErrors || er.code === "EACCES") {
168
+ if (options && options.ignoreErrors || er.code === "EACCES") {
169
169
  return false;
170
170
  } else {
171
171
  throw er;
@@ -272,9 +272,9 @@ var require_which = (0, import_chunk_QGM4M3NI.__commonJS)({
272
272
  var require_path_key = (0, import_chunk_QGM4M3NI.__commonJS)({
273
273
  "../../node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js"(exports, module2) {
274
274
  "use strict";
275
- var pathKey = (options2 = {}) => {
276
- const environment = options2.env || process.env;
277
- const platform = options2.platform || process.platform;
275
+ var pathKey = (options = {}) => {
276
+ const environment = options.env || process.env;
277
+ const platform = options.platform || process.platform;
278
278
  if (platform !== "win32") {
279
279
  return "PATH";
280
280
  }
@@ -429,24 +429,24 @@ var require_parse = (0, import_chunk_QGM4M3NI.__commonJS)({
429
429
  }
430
430
  return parsed;
431
431
  }
432
- function parse(command, args, options2) {
432
+ function parse(command, args, options) {
433
433
  if (args && !Array.isArray(args)) {
434
- options2 = args;
434
+ options = args;
435
435
  args = null;
436
436
  }
437
437
  args = args ? args.slice(0) : [];
438
- options2 = Object.assign({}, options2);
438
+ options = Object.assign({}, options);
439
439
  const parsed = {
440
440
  command,
441
441
  args,
442
- options: options2,
442
+ options,
443
443
  file: void 0,
444
444
  original: {
445
445
  command,
446
446
  args
447
447
  }
448
448
  };
449
- return options2.shell ? parsed : parseNonShell(parsed);
449
+ return options.shell ? parsed : parseNonShell(parsed);
450
450
  }
451
451
  module2.exports = parse;
452
452
  }
@@ -505,14 +505,14 @@ var require_cross_spawn = (0, import_chunk_QGM4M3NI.__commonJS)({
505
505
  var cp = (0, import_chunk_QGM4M3NI.__require)("child_process");
506
506
  var parse = require_parse();
507
507
  var enoent = require_enoent();
508
- function spawn(command, args, options2) {
509
- const parsed = parse(command, args, options2);
508
+ function spawn(command, args, options) {
509
+ const parsed = parse(command, args, options);
510
510
  const spawned = cp.spawn(parsed.command, parsed.args, parsed.options);
511
511
  enoent.hookChildProcess(spawned, parsed);
512
512
  return spawned;
513
513
  }
514
- function spawnSync(command, args, options2) {
515
- const parsed = parse(command, args, options2);
514
+ function spawnSync(command, args, options) {
515
+ const parsed = parse(command, args, options);
516
516
  const result = cp.spawnSync(parsed.command, parsed.args, parsed.options);
517
517
  result.error = result.error || enoent.verifyENOENTSync(result.status, parsed);
518
518
  return result;
@@ -545,36 +545,36 @@ var require_npm_run_path = (0, import_chunk_QGM4M3NI.__commonJS)({
545
545
  "use strict";
546
546
  var path2 = (0, import_chunk_QGM4M3NI.__require)("path");
547
547
  var pathKey = require_path_key();
548
- var npmRunPath = (options2) => {
549
- options2 = {
548
+ var npmRunPath = (options) => {
549
+ options = {
550
550
  cwd: process.cwd(),
551
551
  path: process.env[pathKey()],
552
552
  execPath: process.execPath,
553
- ...options2
553
+ ...options
554
554
  };
555
555
  let previous;
556
- let cwdPath = path2.resolve(options2.cwd);
556
+ let cwdPath = path2.resolve(options.cwd);
557
557
  const result = [];
558
558
  while (previous !== cwdPath) {
559
559
  result.push(path2.join(cwdPath, "node_modules/.bin"));
560
560
  previous = cwdPath;
561
561
  cwdPath = path2.resolve(cwdPath, "..");
562
562
  }
563
- const execPathDir = path2.resolve(options2.cwd, options2.execPath, "..");
563
+ const execPathDir = path2.resolve(options.cwd, options.execPath, "..");
564
564
  result.push(execPathDir);
565
- return result.concat(options2.path).join(path2.delimiter);
565
+ return result.concat(options.path).join(path2.delimiter);
566
566
  };
567
567
  module2.exports = npmRunPath;
568
568
  module2.exports.default = npmRunPath;
569
- module2.exports.env = (options2) => {
570
- options2 = {
569
+ module2.exports.env = (options) => {
570
+ options = {
571
571
  env: process.env,
572
- ...options2
572
+ ...options
573
573
  };
574
- const env = { ...options2.env };
574
+ const env = { ...options.env };
575
575
  const path3 = pathKey({ env });
576
- options2.path = env[path3];
577
- env[path3] = module2.exports(options2);
576
+ options.path = env[path3];
577
+ env[path3] = module2.exports(options);
578
578
  return env;
579
579
  };
580
580
  }
@@ -597,7 +597,7 @@ var require_onetime = (0, import_chunk_QGM4M3NI.__commonJS)({
597
597
  "use strict";
598
598
  var mimicFn = require_mimic_fn();
599
599
  var calledFunctions = /* @__PURE__ */ new WeakMap();
600
- var onetime = (function_, options2 = {}) => {
600
+ var onetime = (function_, options = {}) => {
601
601
  if (typeof function_ !== "function") {
602
602
  throw new TypeError("Expected a function");
603
603
  }
@@ -609,7 +609,7 @@ var require_onetime = (0, import_chunk_QGM4M3NI.__commonJS)({
609
609
  if (callCount === 1) {
610
610
  returnValue = function_.apply(this, arguments_);
611
611
  function_ = null;
612
- } else if (options2.throw === true) {
612
+ } else if (options.throw === true) {
613
613
  throw new Error(`Function \`${functionName}\` can only be called once`);
614
614
  }
615
615
  return returnValue;
@@ -1096,16 +1096,16 @@ var require_stdio = (0, import_chunk_QGM4M3NI.__commonJS)({
1096
1096
  "../../node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stdio.js"(exports, module2) {
1097
1097
  "use strict";
1098
1098
  var aliases = ["stdin", "stdout", "stderr"];
1099
- var hasAlias = (options2) => aliases.some((alias) => options2[alias] !== void 0);
1100
- var normalizeStdio = (options2) => {
1101
- if (!options2) {
1099
+ var hasAlias = (options) => aliases.some((alias) => options[alias] !== void 0);
1100
+ var normalizeStdio = (options) => {
1101
+ if (!options) {
1102
1102
  return;
1103
1103
  }
1104
- const { stdio } = options2;
1104
+ const { stdio } = options;
1105
1105
  if (stdio === void 0) {
1106
- return aliases.map((alias) => options2[alias]);
1106
+ return aliases.map((alias) => options[alias]);
1107
1107
  }
1108
- if (hasAlias(options2)) {
1108
+ if (hasAlias(options)) {
1109
1109
  throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${aliases.map((alias) => `\`${alias}\``).join(", ")}`);
1110
1110
  }
1111
1111
  if (typeof stdio === "string") {
@@ -1118,8 +1118,8 @@ var require_stdio = (0, import_chunk_QGM4M3NI.__commonJS)({
1118
1118
  return Array.from({ length }, (value, index) => stdio[index]);
1119
1119
  };
1120
1120
  module2.exports = normalizeStdio;
1121
- module2.exports.node = (options2) => {
1122
- const stdio = normalizeStdio(options2);
1121
+ module2.exports.node = (options) => {
1122
+ const stdio = normalizeStdio(options);
1123
1123
  if (stdio === "ipc") {
1124
1124
  return "ipc";
1125
1125
  }
@@ -1200,7 +1200,7 @@ var require_signal_exit = (0, import_chunk_QGM4M3NI.__commonJS)({
1200
1200
  emitter.setMaxListeners(Infinity);
1201
1201
  emitter.infinite = true;
1202
1202
  }
1203
- module2.exports = function(cb, opts2) {
1203
+ module2.exports = function(cb, opts) {
1204
1204
  if (!processOk(global.process)) {
1205
1205
  return function() {
1206
1206
  };
@@ -1210,7 +1210,7 @@ var require_signal_exit = (0, import_chunk_QGM4M3NI.__commonJS)({
1210
1210
  load();
1211
1211
  }
1212
1212
  var ev = "exit";
1213
- if (opts2 && opts2.alwaysLast) {
1213
+ if (opts && opts.alwaysLast) {
1214
1214
  ev = "afterexit";
1215
1215
  }
1216
1216
  var remove = function() {
@@ -1330,19 +1330,19 @@ var require_signal_exit = (0, import_chunk_QGM4M3NI.__commonJS)({
1330
1330
  var require_kill = (0, import_chunk_QGM4M3NI.__commonJS)({
1331
1331
  "../../node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/kill.js"(exports, module2) {
1332
1332
  "use strict";
1333
- var os2 = (0, import_chunk_QGM4M3NI.__require)("os");
1333
+ var os = (0, import_chunk_QGM4M3NI.__require)("os");
1334
1334
  var onExit = require_signal_exit();
1335
1335
  var DEFAULT_FORCE_KILL_TIMEOUT = 1e3 * 5;
1336
- var spawnedKill = (kill, signal = "SIGTERM", options2 = {}) => {
1336
+ var spawnedKill = (kill, signal = "SIGTERM", options = {}) => {
1337
1337
  const killResult = kill(signal);
1338
- setKillTimeout(kill, signal, options2, killResult);
1338
+ setKillTimeout(kill, signal, options, killResult);
1339
1339
  return killResult;
1340
1340
  };
1341
- var setKillTimeout = (kill, signal, options2, killResult) => {
1342
- if (!shouldForceKill(signal, options2, killResult)) {
1341
+ var setKillTimeout = (kill, signal, options, killResult) => {
1342
+ if (!shouldForceKill(signal, options, killResult)) {
1343
1343
  return;
1344
1344
  }
1345
- const timeout = getForceKillAfterTimeout(options2);
1345
+ const timeout = getForceKillAfterTimeout(options);
1346
1346
  const t = setTimeout(() => {
1347
1347
  kill("SIGKILL");
1348
1348
  }, timeout);
@@ -1354,7 +1354,7 @@ var require_kill = (0, import_chunk_QGM4M3NI.__commonJS)({
1354
1354
  return isSigterm(signal) && forceKillAfterTimeout !== false && killResult;
1355
1355
  };
1356
1356
  var isSigterm = (signal) => {
1357
- return signal === os2.constants.signals.SIGTERM || typeof signal === "string" && signal.toUpperCase() === "SIGTERM";
1357
+ return signal === os.constants.signals.SIGTERM || typeof signal === "string" && signal.toUpperCase() === "SIGTERM";
1358
1358
  };
1359
1359
  var getForceKillAfterTimeout = ({ forceKillAfterTimeout = true }) => {
1360
1360
  if (forceKillAfterTimeout === true) {
@@ -1419,10 +1419,10 @@ var require_buffer_stream = (0, import_chunk_QGM4M3NI.__commonJS)({
1419
1419
  "../../node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js"(exports, module2) {
1420
1420
  "use strict";
1421
1421
  var { PassThrough: PassThroughStream } = (0, import_chunk_QGM4M3NI.__require)("stream");
1422
- module2.exports = (options2) => {
1423
- options2 = { ...options2 };
1424
- const { array } = options2;
1425
- let { encoding } = options2;
1422
+ module2.exports = (options) => {
1423
+ options = { ...options };
1424
+ const { array } = options;
1425
+ let { encoding } = options;
1426
1426
  const isBuffer = encoding === "buffer";
1427
1427
  let objectMode = false;
1428
1428
  if (array) {
@@ -1472,16 +1472,16 @@ var require_get_stream = (0, import_chunk_QGM4M3NI.__commonJS)({
1472
1472
  this.name = "MaxBufferError";
1473
1473
  }
1474
1474
  };
1475
- async function getStream(inputStream, options2) {
1475
+ async function getStream(inputStream, options) {
1476
1476
  if (!inputStream) {
1477
1477
  throw new Error("Expected a stream");
1478
1478
  }
1479
- options2 = {
1479
+ options = {
1480
1480
  maxBuffer: Infinity,
1481
- ...options2
1481
+ ...options
1482
1482
  };
1483
- const { maxBuffer } = options2;
1484
- const stream2 = bufferStream(options2);
1483
+ const { maxBuffer } = options;
1484
+ const stream2 = bufferStream(options);
1485
1485
  await new Promise((resolve, reject) => {
1486
1486
  const rejectPromise = (error) => {
1487
1487
  if (error && stream2.getBufferedLength() <= BufferConstants.MAX_LENGTH) {
@@ -1506,8 +1506,8 @@ var require_get_stream = (0, import_chunk_QGM4M3NI.__commonJS)({
1506
1506
  return stream2.getBufferedValue();
1507
1507
  }
1508
1508
  module2.exports = getStream;
1509
- module2.exports.buffer = (stream2, options2) => getStream(stream2, { ...options2, encoding: "buffer" });
1510
- module2.exports.array = (stream2, options2) => getStream(stream2, { ...options2, array: true });
1509
+ module2.exports.buffer = (stream2, options) => getStream(stream2, { ...options, encoding: "buffer" });
1510
+ module2.exports.array = (stream2, options) => getStream(stream2, { ...options, array: true });
1511
1511
  module2.exports.MaxBufferError = MaxBufferError;
1512
1512
  }
1513
1513
  });
@@ -1666,11 +1666,11 @@ var require_promise = (0, import_chunk_QGM4M3NI.__commonJS)({
1666
1666
  var require_command = (0, import_chunk_QGM4M3NI.__commonJS)({
1667
1667
  "../../node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/command.js"(exports, module2) {
1668
1668
  "use strict";
1669
- var normalizeArgs = (file2, args = []) => {
1669
+ var normalizeArgs = (file, args = []) => {
1670
1670
  if (!Array.isArray(args)) {
1671
- return [file2];
1671
+ return [file];
1672
1672
  }
1673
- return [file2, ...args];
1673
+ return [file, ...args];
1674
1674
  };
1675
1675
  var NO_ESCAPE_REGEXP = /^[\w.-]+$/;
1676
1676
  var DOUBLE_QUOTES_REGEXP = /"/g;
@@ -1680,11 +1680,11 @@ var require_command = (0, import_chunk_QGM4M3NI.__commonJS)({
1680
1680
  }
1681
1681
  return `"${arg.replace(DOUBLE_QUOTES_REGEXP, '\\"')}"`;
1682
1682
  };
1683
- var joinCommand = (file2, args) => {
1684
- return normalizeArgs(file2, args).join(" ");
1683
+ var joinCommand = (file, args) => {
1684
+ return normalizeArgs(file, args).join(" ");
1685
1685
  };
1686
- var getEscapedCommand = (file2, args) => {
1687
- return normalizeArgs(file2, args).map((arg) => escapeArg(arg)).join(" ");
1686
+ var getEscapedCommand = (file, args) => {
1687
+ return normalizeArgs(file, args).map((arg) => escapeArg(arg)).join(" ");
1688
1688
  };
1689
1689
  var SPACES_REGEXP = / +/g;
1690
1690
  var parseCommand = (command) => {
@@ -1729,46 +1729,46 @@ var require_execa = (0, import_chunk_QGM4M3NI.__commonJS)({
1729
1729
  }
1730
1730
  return env;
1731
1731
  };
1732
- var handleArguments = (file2, args, options2 = {}) => {
1733
- const parsed = crossSpawn._parse(file2, args, options2);
1734
- file2 = parsed.command;
1732
+ var handleArguments = (file, args, options = {}) => {
1733
+ const parsed = crossSpawn._parse(file, args, options);
1734
+ file = parsed.command;
1735
1735
  args = parsed.args;
1736
- options2 = parsed.options;
1737
- options2 = {
1736
+ options = parsed.options;
1737
+ options = {
1738
1738
  maxBuffer: DEFAULT_MAX_BUFFER,
1739
1739
  buffer: true,
1740
1740
  stripFinalNewline: true,
1741
1741
  extendEnv: true,
1742
1742
  preferLocal: false,
1743
- localDir: options2.cwd || process.cwd(),
1743
+ localDir: options.cwd || process.cwd(),
1744
1744
  execPath: process.execPath,
1745
1745
  encoding: "utf8",
1746
1746
  reject: true,
1747
1747
  cleanup: true,
1748
1748
  all: false,
1749
1749
  windowsHide: true,
1750
- ...options2
1750
+ ...options
1751
1751
  };
1752
- options2.env = getEnv(options2);
1753
- options2.stdio = normalizeStdio(options2);
1754
- if (process.platform === "win32" && path2.basename(file2, ".exe") === "cmd") {
1752
+ options.env = getEnv(options);
1753
+ options.stdio = normalizeStdio(options);
1754
+ if (process.platform === "win32" && path2.basename(file, ".exe") === "cmd") {
1755
1755
  args.unshift("/q");
1756
1756
  }
1757
- return { file: file2, args, options: options2, parsed };
1757
+ return { file, args, options, parsed };
1758
1758
  };
1759
- var handleOutput = (options2, value, error) => {
1759
+ var handleOutput = (options, value, error) => {
1760
1760
  if (typeof value !== "string" && !Buffer.isBuffer(value)) {
1761
1761
  return error === void 0 ? void 0 : "";
1762
1762
  }
1763
- if (options2.stripFinalNewline) {
1763
+ if (options.stripFinalNewline) {
1764
1764
  return stripFinalNewline(value);
1765
1765
  }
1766
1766
  return value;
1767
1767
  };
1768
- var execa2 = (file2, args, options2) => {
1769
- const parsed = handleArguments(file2, args, options2);
1770
- const command = joinCommand(file2, args);
1771
- const escapedCommand = getEscapedCommand(file2, args);
1768
+ var execa2 = (file, args, options) => {
1769
+ const parsed = handleArguments(file, args, options);
1770
+ const command = joinCommand(file, args);
1771
+ const escapedCommand = getEscapedCommand(file, args);
1772
1772
  validateTimeout(parsed.options);
1773
1773
  let spawned;
1774
1774
  try {
@@ -1839,10 +1839,10 @@ var require_execa = (0, import_chunk_QGM4M3NI.__commonJS)({
1839
1839
  return mergePromise(spawned, handlePromiseOnce);
1840
1840
  };
1841
1841
  module2.exports = execa2;
1842
- module2.exports.sync = (file2, args, options2) => {
1843
- const parsed = handleArguments(file2, args, options2);
1844
- const command = joinCommand(file2, args);
1845
- const escapedCommand = getEscapedCommand(file2, args);
1842
+ module2.exports.sync = (file, args, options) => {
1843
+ const parsed = handleArguments(file, args, options);
1844
+ const command = joinCommand(file, args);
1845
+ const escapedCommand = getEscapedCommand(file, args);
1846
1846
  validateInputSync(parsed.options);
1847
1847
  let result;
1848
1848
  try {
@@ -1894,25 +1894,25 @@ var require_execa = (0, import_chunk_QGM4M3NI.__commonJS)({
1894
1894
  killed: false
1895
1895
  };
1896
1896
  };
1897
- module2.exports.command = (command, options2) => {
1898
- const [file2, ...args] = parseCommand(command);
1899
- return execa2(file2, args, options2);
1897
+ module2.exports.command = (command, options) => {
1898
+ const [file, ...args] = parseCommand(command);
1899
+ return execa2(file, args, options);
1900
1900
  };
1901
- module2.exports.commandSync = (command, options2) => {
1902
- const [file2, ...args] = parseCommand(command);
1903
- return execa2.sync(file2, args, options2);
1901
+ module2.exports.commandSync = (command, options) => {
1902
+ const [file, ...args] = parseCommand(command);
1903
+ return execa2.sync(file, args, options);
1904
1904
  };
1905
- module2.exports.node = (scriptPath, args, options2 = {}) => {
1905
+ module2.exports.node = (scriptPath, args, options = {}) => {
1906
1906
  if (args && !Array.isArray(args) && typeof args === "object") {
1907
- options2 = args;
1907
+ options = args;
1908
1908
  args = [];
1909
1909
  }
1910
- const stdio = normalizeStdio.node(options2);
1910
+ const stdio = normalizeStdio.node(options);
1911
1911
  const defaultExecArgv = process.execArgv.filter((arg) => !arg.startsWith("--inspect"));
1912
1912
  const {
1913
1913
  nodePath = process.execPath,
1914
1914
  nodeOptions = defaultExecArgv
1915
- } = options2;
1915
+ } = options;
1916
1916
  return execa2(
1917
1917
  nodePath,
1918
1918
  [
@@ -1921,7 +1921,7 @@ var require_execa = (0, import_chunk_QGM4M3NI.__commonJS)({
1921
1921
  ...Array.isArray(args) ? args : []
1922
1922
  ],
1923
1923
  {
1924
- ...options2,
1924
+ ...options,
1925
1925
  stdin: void 0,
1926
1926
  stdout: void 0,
1927
1927
  stderr: void 0,
@@ -1936,7 +1936,7 @@ var require_package = (0, import_chunk_QGM4M3NI.__commonJS)({
1936
1936
  "package.json"(exports, module2) {
1937
1937
  module2.exports = {
1938
1938
  name: "@prisma/fetch-engine",
1939
- version: "6.6.0",
1939
+ version: "6.7.0-dev.1",
1940
1940
  description: "This package is intended for Prisma's internal use",
1941
1941
  main: "dist/index.js",
1942
1942
  types: "dist/index.d.ts",
@@ -2119,11 +2119,11 @@ async function pMap(iterable, mapper, {
2119
2119
  });
2120
2120
  }
2121
2121
  var pMapSkip = Symbol("skip");
2122
- async function pFilter(iterable, filterer, options2) {
2122
+ async function pFilter(iterable, filterer, options) {
2123
2123
  const values = await pMap(
2124
2124
  iterable,
2125
2125
  (element, index) => Promise.all([filterer(element, index), element]),
2126
- options2
2126
+ options
2127
2127
  );
2128
2128
  return values.filter((value) => Boolean(value[0])).map((value) => value[1]);
2129
2129
  }
@@ -2225,8 +2225,7 @@ async function download(options) {
2225
2225
  }
2226
2226
  }
2227
2227
  const binaryPaths = binaryJobsToBinaryPaths(binaryJobs);
2228
- const dir = eval("__dirname");
2229
- if (dir.match(vercelPkgPathRegex)) {
2228
+ if (__dirname.match(vercelPkgPathRegex)) {
2230
2229
  for (const engineType in binaryPaths) {
2231
2230
  const binaryTargets2 = binaryPaths[engineType];
2232
2231
  for (const binaryTarget2 in binaryTargets2) {
@@ -2237,21 +2236,21 @@ async function download(options) {
2237
2236
  }
2238
2237
  return binaryPaths;
2239
2238
  }
2240
- function getCollectiveBar(options2) {
2241
- const hasNodeAPI = "libquery-engine" in options2.binaries;
2239
+ function getCollectiveBar(options) {
2240
+ const hasNodeAPI = "libquery-engine" in options.binaries;
2242
2241
  const bar = (0, import_chunk_MWVY55RY.getBar)(
2243
- `Downloading Prisma engines${hasNodeAPI ? " for Node-API" : ""} for ${options2.binaryTargets?.map((p) => (0, import_chunk_PXQVM7NP.bold)(p)).join(" and ")}`
2242
+ `Downloading Prisma engines${hasNodeAPI ? " for Node-API" : ""} for ${options.binaryTargets?.map((p) => (0, import_chunk_PXQVM7NP.bold)(p)).join(" and ")}`
2244
2243
  );
2245
2244
  const progressMap = {};
2246
- const numDownloads = Object.values(options2.binaries).length * Object.values(options2?.binaryTargets ?? []).length;
2245
+ const numDownloads = Object.values(options.binaries).length * Object.values(options?.binaryTargets ?? []).length;
2247
2246
  const setProgress = (sourcePath) => (progress) => {
2248
2247
  progressMap[sourcePath] = progress;
2249
2248
  const progressValues = Object.values(progressMap);
2250
2249
  const totalProgress = progressValues.reduce((acc, curr) => {
2251
2250
  return acc + curr;
2252
2251
  }, 0) / numDownloads;
2253
- if (options2.progressCb) {
2254
- options2.progressCb(totalProgress);
2252
+ if (options.progressCb) {
2253
+ options.progressCb(totalProgress);
2255
2254
  }
2256
2255
  if (bar) {
2257
2256
  bar.update(totalProgress);
@@ -2351,19 +2350,19 @@ async function getVersion(enginePath, binaryName) {
2351
2350
  }
2352
2351
  return void 0;
2353
2352
  }
2354
- function getBinaryName(binaryName, binaryTarget2) {
2353
+ function getBinaryName(binaryName, binaryTarget) {
2355
2354
  if (binaryName === "libquery-engine") {
2356
- return `${(0, import_get_platform.getNodeAPIName)(binaryTarget2, "fs")}`;
2355
+ return `${(0, import_get_platform.getNodeAPIName)(binaryTarget, "fs")}`;
2357
2356
  }
2358
- const extension = binaryTarget2 === "windows" ? ".exe" : "";
2359
- return `${binaryName}-${binaryTarget2}${extension}`;
2357
+ const extension = binaryTarget === "windows" ? ".exe" : "";
2358
+ return `${binaryName}-${binaryTarget}${extension}`;
2360
2359
  }
2361
2360
  async function getCachedBinaryPath({
2362
2361
  version,
2363
- binaryTarget: binaryTarget2,
2362
+ binaryTarget,
2364
2363
  binaryName
2365
2364
  }) {
2366
- const cacheDir = await (0, import_chunk_YJOPKU47.getCacheDir)(channel, version, binaryTarget2);
2365
+ const cacheDir = await (0, import_chunk_YJOPKU47.getCacheDir)(channel, version, binaryTarget);
2367
2366
  if (!cacheDir) {
2368
2367
  return null;
2369
2368
  }
@@ -2379,14 +2378,14 @@ async function getCachedBinaryPath({
2379
2378
  }
2380
2379
  return null;
2381
2380
  }
2382
- async function downloadBinary(options2) {
2383
- const { version, progressCb, targetFilePath, downloadUrl } = options2;
2381
+ async function downloadBinary(options) {
2382
+ const { version, progressCb, targetFilePath, downloadUrl } = options;
2384
2383
  const targetDir = import_path.default.dirname(targetFilePath);
2385
2384
  try {
2386
2385
  import_fs.default.accessSync(targetDir, import_fs.default.constants.W_OK);
2387
2386
  await (0, import_fs_extra.ensureDir)(targetDir);
2388
2387
  } catch (e) {
2389
- if (options2.failSilent || e.code !== "EACCES") {
2388
+ if (options.failSilent || e.code !== "EACCES") {
2390
2389
  return;
2391
2390
  } else {
2392
2391
  throw new Error(`Can't write to ${targetDir} please make sure you install "prisma" with the right permissions.`);
@@ -2401,7 +2400,7 @@ async function downloadBinary(options2) {
2401
2400
  progressCb(1);
2402
2401
  }
2403
2402
  (0, import_chunk_MX3HXAU2.chmodPlusX)(targetFilePath);
2404
- await saveFileToCache(options2, version, sha256, zippedSha256);
2403
+ await saveFileToCache(options, version, sha256, zippedSha256);
2405
2404
  }
2406
2405
  async function saveFileToCache(job, version, sha256, zippedSha256) {
2407
2406
  const cacheDir = await (0, import_chunk_YJOPKU47.getCacheDir)(channel, version, job.binaryTarget);
@@ -2424,8 +2423,7 @@ async function saveFileToCache(job, version, sha256, zippedSha256) {
2424
2423
  }
2425
2424
  }
2426
2425
  async function maybeCopyToTmp(file) {
2427
- const dir = eval("__dirname");
2428
- if (dir.match(vercelPkgPathRegex)) {
2426
+ if (__dirname.match(vercelPkgPathRegex)) {
2429
2427
  const targetDir = import_path.default.join(import_temp_dir.default, "prisma-binaries");
2430
2428
  await (0, import_fs_extra.ensureDir)(targetDir);
2431
2429
  const target = import_path.default.join(targetDir, import_path.default.basename(file));
@@ -2436,12 +2434,12 @@ async function maybeCopyToTmp(file) {
2436
2434
  }
2437
2435
  return file;
2438
2436
  }
2439
- function plusX(file2) {
2440
- const s = import_fs.default.statSync(file2);
2437
+ function plusX(file) {
2438
+ const s = import_fs.default.statSync(file);
2441
2439
  const newMode = s.mode | 64 | 8 | 1;
2442
2440
  if (s.mode === newMode) {
2443
2441
  return;
2444
2442
  }
2445
2443
  const base8 = newMode.toString(8).slice(-3);
2446
- import_fs.default.chmodSync(file2, base8);
2444
+ import_fs.default.chmodSync(file, base8);
2447
2445
  }