@prisma/internals 5.23.0-dev.18 → 5.23.0-dev.19

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.
Files changed (40) hide show
  1. package/dist/chunk-2DXAGCPS.js +177 -0
  2. package/dist/{chunk-A6YJGOAZ.js → chunk-2MI66B2K.js} +8 -8
  3. package/dist/{chunk-OQEFNMS4.js → chunk-3F7YBP5D.js} +7 -7
  4. package/dist/{chunk-Y7KUHH27.js → chunk-3XOL7USL.js} +5 -5
  5. package/dist/chunk-5XRQ7ONW.js +122 -0
  6. package/dist/{chunk-YXNA7OV2.js → chunk-CRMPQZ4W.js} +8 -8
  7. package/dist/{chunk-L7FTLPKQ.js → chunk-IFMDTCUD.js} +19 -19
  8. package/dist/{chunk-I57EV5MU.js → chunk-KJ6ETQRZ.js} +8 -8
  9. package/dist/{chunk-IC5FCEGD.js → chunk-PTDF5V63.js} +5 -5
  10. package/dist/chunk-QIVUAERL.js +2202 -0
  11. package/dist/chunk-QJZIYUVB.js +110 -0
  12. package/dist/{chunk-SCATLSVE.js → chunk-QOA32UW5.js} +5 -5
  13. package/dist/chunk-TFSZCVKC.js +166 -0
  14. package/dist/{chunk-XPCE3TES.js → chunk-UPKJODIS.js} +24 -795
  15. package/dist/chunk-V2VWODV3.js +54 -0
  16. package/dist/{chunk-I7H5XPIN.js → chunk-XDN6ROV6.js} +5 -5
  17. package/dist/{chunk-TBWP26DR.js → chunk-ZTNSQE4R.js} +4 -4
  18. package/dist/cli/checkUnsupportedDataProxy.js +12 -12
  19. package/dist/cli/getSchema.js +17 -17
  20. package/dist/cli/hashes.js +12 -12
  21. package/dist/engine-commands/errorHelpers.js +4 -4
  22. package/dist/engine-commands/formatSchema.js +11 -11
  23. package/dist/engine-commands/getConfig.js +10 -10
  24. package/dist/engine-commands/getDmmf.js +7 -7
  25. package/dist/engine-commands/index.js +20 -20
  26. package/dist/engine-commands/lintSchema.js +8 -8
  27. package/dist/engine-commands/mergeSchemas.js +7 -7
  28. package/dist/engine-commands/validate.js +7 -7
  29. package/dist/get-generators/generatorResolvers/generatorResolvers.js +11 -11
  30. package/dist/get-generators/generatorResolvers/prisma-client-js/check-dependencies/checkTypeScriptVersion.js +11 -11
  31. package/dist/get-generators/generatorResolvers/prisma-client-js/prismaClientResolver.js +12 -12
  32. package/dist/get-generators/getGenerators.js +14 -14
  33. package/dist/index.js +39 -39
  34. package/dist/sendPanic.js +11 -11
  35. package/dist/utils/getEnvPaths.js +11 -11
  36. package/dist/utils/getVersionFromPackageJson.js +3 -3
  37. package/dist/utils/handlePanic.js +11 -11
  38. package/dist/utils/loadEnvFile.js +11 -11
  39. package/dist/wasm.js +4 -4
  40. package/package.json +7 -7
@@ -26,8 +26,8 @@ var __toESM2 = (mod, isNodeMode, target) => (target = mod != null ? __create(__g
26
26
  mod
27
27
  ));
28
28
  var __toCommonJS2 = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var chunk_XPCE3TES_exports = {};
30
- __export2(chunk_XPCE3TES_exports, {
29
+ var chunk_UPKJODIS_exports = {};
30
+ __export2(chunk_UPKJODIS_exports, {
31
31
  checkTypeScriptVersion: () => checkTypeScriptVersion,
32
32
  checkUnsupportedDataProxy: () => checkUnsupportedDataProxy,
33
33
  debug: () => debug5,
@@ -55,7 +55,7 @@ __export2(chunk_XPCE3TES_exports, {
55
55
  sendPanic: () => sendPanic,
56
56
  skipIndex: () => skipIndex
57
57
  });
58
- module.exports = __toCommonJS2(chunk_XPCE3TES_exports);
58
+ module.exports = __toCommonJS2(chunk_UPKJODIS_exports);
59
59
  var import_chunk_IABMG3F4 = require("./chunk-IABMG3F4.js");
60
60
  var import_chunk_3U2ANLD3 = require("./chunk-3U2ANLD3.js");
61
61
  var import_chunk_FTS2IEWX = require("./chunk-FTS2IEWX.js");
@@ -63,7 +63,7 @@ var import_chunk_EUTJYQDW = require("./chunk-EUTJYQDW.js");
63
63
  var import_chunk_IPKE37QC = require("./chunk-IPKE37QC.js");
64
64
  var import_chunk_KEBDP2C3 = require("./chunk-KEBDP2C3.js");
65
65
  var import_chunk_X77CS5RK = require("./chunk-X77CS5RK.js");
66
- var import_chunk_D4MCOTL5 = require("./chunk-D4MCOTL5.js");
66
+ var import_chunk_5XRQ7ONW = require("./chunk-5XRQ7ONW.js");
67
67
  var import_chunk_RS2R7COT = require("./chunk-RS2R7COT.js");
68
68
  var import_chunk_X3P4J7WW = require("./chunk-X3P4J7WW.js");
69
69
  var import_chunk_ONHKZPSV = require("./chunk-ONHKZPSV.js");
@@ -80,17 +80,18 @@ var import_chunk_XLYQ6PQW = require("./chunk-XLYQ6PQW.js");
80
80
  var import_chunk_EPJYKNCQ = require("./chunk-EPJYKNCQ.js");
81
81
  var import_chunk_ODI3VNBD = require("./chunk-ODI3VNBD.js");
82
82
  var import_chunk_TSJICM5S = require("./chunk-TSJICM5S.js");
83
- var import_chunk_Y7KUHH27 = require("./chunk-Y7KUHH27.js");
84
- var import_chunk_OQEFNMS4 = require("./chunk-OQEFNMS4.js");
85
- var import_chunk_YXNA7OV2 = require("./chunk-YXNA7OV2.js");
86
- var import_chunk_I57EV5MU = require("./chunk-I57EV5MU.js");
83
+ var import_chunk_ASJ5LZTB = require("./chunk-ASJ5LZTB.js");
84
+ var import_chunk_XE4JX3AP = require("./chunk-XE4JX3AP.js");
85
+ var import_chunk_OBCNUIOJ = require("./chunk-OBCNUIOJ.js");
86
+ var import_chunk_SOZJQQOQ = require("./chunk-SOZJQQOQ.js");
87
87
  var import_chunk_YRBRUREX = require("./chunk-YRBRUREX.js");
88
88
  var import_chunk_H3T4L34H = require("./chunk-H3T4L34H.js");
89
- var import_chunk_IC5FCEGD = require("./chunk-IC5FCEGD.js");
89
+ var import_chunk_YVDQPNPO = require("./chunk-YVDQPNPO.js");
90
90
  var import_chunk_MUPZUVSI = require("./chunk-MUPZUVSI.js");
91
91
  var import_chunk_A4QWQE3W = require("./chunk-A4QWQE3W.js");
92
92
  var import_chunk_2B26F5N3 = require("./chunk-2B26F5N3.js");
93
93
  var import_chunk_M3GBKLGE = require("./chunk-M3GBKLGE.js");
94
+ var import_chunk_QIVUAERL = require("./chunk-QIVUAERL.js");
94
95
  var import_chunk_635TMBAP = require("./chunk-635TMBAP.js");
95
96
  var import_chunk_IOIAK7V7 = require("./chunk-IOIAK7V7.js");
96
97
  var import_chunk_4NFLAUKD = require("./chunk-4NFLAUKD.js");
@@ -2504,778 +2505,6 @@ var init_async = (0, import_chunk_WWAWV7DQ.__esm)({
2504
2505
  async_default = index;
2505
2506
  }
2506
2507
  });
2507
- var require_polyfills = (0, import_chunk_WWAWV7DQ.__commonJS)({
2508
- "../../node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/polyfills.js"(exports2, module2) {
2509
- "use strict";
2510
- var constants2 = (0, import_chunk_WWAWV7DQ.__require)("constants");
2511
- var origCwd = process.cwd;
2512
- var cwd = null;
2513
- var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform;
2514
- process.cwd = function() {
2515
- if (!cwd)
2516
- cwd = origCwd.call(process);
2517
- return cwd;
2518
- };
2519
- try {
2520
- process.cwd();
2521
- } catch (er) {
2522
- }
2523
- if (typeof process.chdir === "function") {
2524
- chdir = process.chdir;
2525
- process.chdir = function(d2) {
2526
- cwd = null;
2527
- chdir.call(process, d2);
2528
- };
2529
- if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir);
2530
- }
2531
- var chdir;
2532
- module2.exports = patch;
2533
- function patch(fs8) {
2534
- if (constants2.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) {
2535
- patchLchmod(fs8);
2536
- }
2537
- if (!fs8.lutimes) {
2538
- patchLutimes(fs8);
2539
- }
2540
- fs8.chown = chownFix(fs8.chown);
2541
- fs8.fchown = chownFix(fs8.fchown);
2542
- fs8.lchown = chownFix(fs8.lchown);
2543
- fs8.chmod = chmodFix(fs8.chmod);
2544
- fs8.fchmod = chmodFix(fs8.fchmod);
2545
- fs8.lchmod = chmodFix(fs8.lchmod);
2546
- fs8.chownSync = chownFixSync(fs8.chownSync);
2547
- fs8.fchownSync = chownFixSync(fs8.fchownSync);
2548
- fs8.lchownSync = chownFixSync(fs8.lchownSync);
2549
- fs8.chmodSync = chmodFixSync(fs8.chmodSync);
2550
- fs8.fchmodSync = chmodFixSync(fs8.fchmodSync);
2551
- fs8.lchmodSync = chmodFixSync(fs8.lchmodSync);
2552
- fs8.stat = statFix(fs8.stat);
2553
- fs8.fstat = statFix(fs8.fstat);
2554
- fs8.lstat = statFix(fs8.lstat);
2555
- fs8.statSync = statFixSync(fs8.statSync);
2556
- fs8.fstatSync = statFixSync(fs8.fstatSync);
2557
- fs8.lstatSync = statFixSync(fs8.lstatSync);
2558
- if (fs8.chmod && !fs8.lchmod) {
2559
- fs8.lchmod = function(path8, mode, cb) {
2560
- if (cb) process.nextTick(cb);
2561
- };
2562
- fs8.lchmodSync = function() {
2563
- };
2564
- }
2565
- if (fs8.chown && !fs8.lchown) {
2566
- fs8.lchown = function(path8, uid, gid, cb) {
2567
- if (cb) process.nextTick(cb);
2568
- };
2569
- fs8.lchownSync = function() {
2570
- };
2571
- }
2572
- if (platform === "win32") {
2573
- fs8.rename = typeof fs8.rename !== "function" ? fs8.rename : function(fs$rename) {
2574
- function rename(from, to, cb) {
2575
- var start = Date.now();
2576
- var backoff = 0;
2577
- fs$rename(from, to, function CB(er) {
2578
- if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) {
2579
- setTimeout(function() {
2580
- fs8.stat(to, function(stater, st) {
2581
- if (stater && stater.code === "ENOENT")
2582
- fs$rename(from, to, CB);
2583
- else
2584
- cb(er);
2585
- });
2586
- }, backoff);
2587
- if (backoff < 100)
2588
- backoff += 10;
2589
- return;
2590
- }
2591
- if (cb) cb(er);
2592
- });
2593
- }
2594
- if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename);
2595
- return rename;
2596
- }(fs8.rename);
2597
- }
2598
- fs8.read = typeof fs8.read !== "function" ? fs8.read : function(fs$read) {
2599
- function read(fd, buffer, offset, length, position, callback_) {
2600
- var callback;
2601
- if (callback_ && typeof callback_ === "function") {
2602
- var eagCounter = 0;
2603
- callback = function(er, _2, __) {
2604
- if (er && er.code === "EAGAIN" && eagCounter < 10) {
2605
- eagCounter++;
2606
- return fs$read.call(fs8, fd, buffer, offset, length, position, callback);
2607
- }
2608
- callback_.apply(this, arguments);
2609
- };
2610
- }
2611
- return fs$read.call(fs8, fd, buffer, offset, length, position, callback);
2612
- }
2613
- if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read);
2614
- return read;
2615
- }(fs8.read);
2616
- fs8.readSync = typeof fs8.readSync !== "function" ? fs8.readSync : /* @__PURE__ */ function(fs$readSync) {
2617
- return function(fd, buffer, offset, length, position) {
2618
- var eagCounter = 0;
2619
- while (true) {
2620
- try {
2621
- return fs$readSync.call(fs8, fd, buffer, offset, length, position);
2622
- } catch (er) {
2623
- if (er.code === "EAGAIN" && eagCounter < 10) {
2624
- eagCounter++;
2625
- continue;
2626
- }
2627
- throw er;
2628
- }
2629
- }
2630
- };
2631
- }(fs8.readSync);
2632
- function patchLchmod(fs9) {
2633
- fs9.lchmod = function(path8, mode, callback) {
2634
- fs9.open(
2635
- path8,
2636
- constants2.O_WRONLY | constants2.O_SYMLINK,
2637
- mode,
2638
- function(err, fd) {
2639
- if (err) {
2640
- if (callback) callback(err);
2641
- return;
2642
- }
2643
- fs9.fchmod(fd, mode, function(err2) {
2644
- fs9.close(fd, function(err22) {
2645
- if (callback) callback(err2 || err22);
2646
- });
2647
- });
2648
- }
2649
- );
2650
- };
2651
- fs9.lchmodSync = function(path8, mode) {
2652
- var fd = fs9.openSync(path8, constants2.O_WRONLY | constants2.O_SYMLINK, mode);
2653
- var threw = true;
2654
- var ret;
2655
- try {
2656
- ret = fs9.fchmodSync(fd, mode);
2657
- threw = false;
2658
- } finally {
2659
- if (threw) {
2660
- try {
2661
- fs9.closeSync(fd);
2662
- } catch (er) {
2663
- }
2664
- } else {
2665
- fs9.closeSync(fd);
2666
- }
2667
- }
2668
- return ret;
2669
- };
2670
- }
2671
- function patchLutimes(fs9) {
2672
- if (constants2.hasOwnProperty("O_SYMLINK") && fs9.futimes) {
2673
- fs9.lutimes = function(path8, at, mt, cb) {
2674
- fs9.open(path8, constants2.O_SYMLINK, function(er, fd) {
2675
- if (er) {
2676
- if (cb) cb(er);
2677
- return;
2678
- }
2679
- fs9.futimes(fd, at, mt, function(er2) {
2680
- fs9.close(fd, function(er22) {
2681
- if (cb) cb(er2 || er22);
2682
- });
2683
- });
2684
- });
2685
- };
2686
- fs9.lutimesSync = function(path8, at, mt) {
2687
- var fd = fs9.openSync(path8, constants2.O_SYMLINK);
2688
- var ret;
2689
- var threw = true;
2690
- try {
2691
- ret = fs9.futimesSync(fd, at, mt);
2692
- threw = false;
2693
- } finally {
2694
- if (threw) {
2695
- try {
2696
- fs9.closeSync(fd);
2697
- } catch (er) {
2698
- }
2699
- } else {
2700
- fs9.closeSync(fd);
2701
- }
2702
- }
2703
- return ret;
2704
- };
2705
- } else if (fs9.futimes) {
2706
- fs9.lutimes = function(_a, _b, _c, cb) {
2707
- if (cb) process.nextTick(cb);
2708
- };
2709
- fs9.lutimesSync = function() {
2710
- };
2711
- }
2712
- }
2713
- function chmodFix(orig) {
2714
- if (!orig) return orig;
2715
- return function(target, mode, cb) {
2716
- return orig.call(fs8, target, mode, function(er) {
2717
- if (chownErOk(er)) er = null;
2718
- if (cb) cb.apply(this, arguments);
2719
- });
2720
- };
2721
- }
2722
- function chmodFixSync(orig) {
2723
- if (!orig) return orig;
2724
- return function(target, mode) {
2725
- try {
2726
- return orig.call(fs8, target, mode);
2727
- } catch (er) {
2728
- if (!chownErOk(er)) throw er;
2729
- }
2730
- };
2731
- }
2732
- function chownFix(orig) {
2733
- if (!orig) return orig;
2734
- return function(target, uid, gid, cb) {
2735
- return orig.call(fs8, target, uid, gid, function(er) {
2736
- if (chownErOk(er)) er = null;
2737
- if (cb) cb.apply(this, arguments);
2738
- });
2739
- };
2740
- }
2741
- function chownFixSync(orig) {
2742
- if (!orig) return orig;
2743
- return function(target, uid, gid) {
2744
- try {
2745
- return orig.call(fs8, target, uid, gid);
2746
- } catch (er) {
2747
- if (!chownErOk(er)) throw er;
2748
- }
2749
- };
2750
- }
2751
- function statFix(orig) {
2752
- if (!orig) return orig;
2753
- return function(target, options2, cb) {
2754
- if (typeof options2 === "function") {
2755
- cb = options2;
2756
- options2 = null;
2757
- }
2758
- function callback(er, stats) {
2759
- if (stats) {
2760
- if (stats.uid < 0) stats.uid += 4294967296;
2761
- if (stats.gid < 0) stats.gid += 4294967296;
2762
- }
2763
- if (cb) cb.apply(this, arguments);
2764
- }
2765
- return options2 ? orig.call(fs8, target, options2, callback) : orig.call(fs8, target, callback);
2766
- };
2767
- }
2768
- function statFixSync(orig) {
2769
- if (!orig) return orig;
2770
- return function(target, options2) {
2771
- var stats = options2 ? orig.call(fs8, target, options2) : orig.call(fs8, target);
2772
- if (stats) {
2773
- if (stats.uid < 0) stats.uid += 4294967296;
2774
- if (stats.gid < 0) stats.gid += 4294967296;
2775
- }
2776
- return stats;
2777
- };
2778
- }
2779
- function chownErOk(er) {
2780
- if (!er)
2781
- return true;
2782
- if (er.code === "ENOSYS")
2783
- return true;
2784
- var nonroot = !process.getuid || process.getuid() !== 0;
2785
- if (nonroot) {
2786
- if (er.code === "EINVAL" || er.code === "EPERM")
2787
- return true;
2788
- }
2789
- return false;
2790
- }
2791
- }
2792
- }
2793
- });
2794
- var require_legacy_streams = (0, import_chunk_WWAWV7DQ.__commonJS)({
2795
- "../../node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/legacy-streams.js"(exports2, module2) {
2796
- "use strict";
2797
- var Stream = (0, import_chunk_WWAWV7DQ.__require)("stream").Stream;
2798
- module2.exports = legacy;
2799
- function legacy(fs8) {
2800
- return {
2801
- ReadStream,
2802
- WriteStream
2803
- };
2804
- function ReadStream(path8, options2) {
2805
- if (!(this instanceof ReadStream)) return new ReadStream(path8, options2);
2806
- Stream.call(this);
2807
- var self2 = this;
2808
- this.path = path8;
2809
- this.fd = null;
2810
- this.readable = true;
2811
- this.paused = false;
2812
- this.flags = "r";
2813
- this.mode = 438;
2814
- this.bufferSize = 64 * 1024;
2815
- options2 = options2 || {};
2816
- var keys = Object.keys(options2);
2817
- for (var index2 = 0, length = keys.length; index2 < length; index2++) {
2818
- var key = keys[index2];
2819
- this[key] = options2[key];
2820
- }
2821
- if (this.encoding) this.setEncoding(this.encoding);
2822
- if (this.start !== void 0) {
2823
- if ("number" !== typeof this.start) {
2824
- throw TypeError("start must be a Number");
2825
- }
2826
- if (this.end === void 0) {
2827
- this.end = Infinity;
2828
- } else if ("number" !== typeof this.end) {
2829
- throw TypeError("end must be a Number");
2830
- }
2831
- if (this.start > this.end) {
2832
- throw new Error("start must be <= end");
2833
- }
2834
- this.pos = this.start;
2835
- }
2836
- if (this.fd !== null) {
2837
- process.nextTick(function() {
2838
- self2._read();
2839
- });
2840
- return;
2841
- }
2842
- fs8.open(this.path, this.flags, this.mode, function(err, fd) {
2843
- if (err) {
2844
- self2.emit("error", err);
2845
- self2.readable = false;
2846
- return;
2847
- }
2848
- self2.fd = fd;
2849
- self2.emit("open", fd);
2850
- self2._read();
2851
- });
2852
- }
2853
- function WriteStream(path8, options2) {
2854
- if (!(this instanceof WriteStream)) return new WriteStream(path8, options2);
2855
- Stream.call(this);
2856
- this.path = path8;
2857
- this.fd = null;
2858
- this.writable = true;
2859
- this.flags = "w";
2860
- this.encoding = "binary";
2861
- this.mode = 438;
2862
- this.bytesWritten = 0;
2863
- options2 = options2 || {};
2864
- var keys = Object.keys(options2);
2865
- for (var index2 = 0, length = keys.length; index2 < length; index2++) {
2866
- var key = keys[index2];
2867
- this[key] = options2[key];
2868
- }
2869
- if (this.start !== void 0) {
2870
- if ("number" !== typeof this.start) {
2871
- throw TypeError("start must be a Number");
2872
- }
2873
- if (this.start < 0) {
2874
- throw new Error("start must be >= zero");
2875
- }
2876
- this.pos = this.start;
2877
- }
2878
- this.busy = false;
2879
- this._queue = [];
2880
- if (this.fd === null) {
2881
- this._open = fs8.open;
2882
- this._queue.push([this._open, this.path, this.flags, this.mode, void 0]);
2883
- this.flush();
2884
- }
2885
- }
2886
- }
2887
- }
2888
- });
2889
- var require_clone = (0, import_chunk_WWAWV7DQ.__commonJS)({
2890
- "../../node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/clone.js"(exports2, module2) {
2891
- "use strict";
2892
- module2.exports = clone;
2893
- var getPrototypeOf = Object.getPrototypeOf || function(obj) {
2894
- return obj.__proto__;
2895
- };
2896
- function clone(obj) {
2897
- if (obj === null || typeof obj !== "object")
2898
- return obj;
2899
- if (obj instanceof Object)
2900
- var copy = { __proto__: getPrototypeOf(obj) };
2901
- else
2902
- var copy = /* @__PURE__ */ Object.create(null);
2903
- Object.getOwnPropertyNames(obj).forEach(function(key) {
2904
- Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key));
2905
- });
2906
- return copy;
2907
- }
2908
- }
2909
- });
2910
- var require_graceful_fs = (0, import_chunk_WWAWV7DQ.__commonJS)({
2911
- "../../node_modules/.pnpm/graceful-fs@4.2.11/node_modules/graceful-fs/graceful-fs.js"(exports2, module2) {
2912
- "use strict";
2913
- var fs8 = (0, import_chunk_WWAWV7DQ.__require)("fs");
2914
- var polyfills = require_polyfills();
2915
- var legacy = require_legacy_streams();
2916
- var clone = require_clone();
2917
- var util = (0, import_chunk_WWAWV7DQ.__require)("util");
2918
- var gracefulQueue;
2919
- var previousSymbol;
2920
- if (typeof Symbol === "function" && typeof Symbol.for === "function") {
2921
- gracefulQueue = Symbol.for("graceful-fs.queue");
2922
- previousSymbol = Symbol.for("graceful-fs.previous");
2923
- } else {
2924
- gracefulQueue = "___graceful-fs.queue";
2925
- previousSymbol = "___graceful-fs.previous";
2926
- }
2927
- function noop() {
2928
- }
2929
- function publishQueue(context, queue3) {
2930
- Object.defineProperty(context, gracefulQueue, {
2931
- get: function() {
2932
- return queue3;
2933
- }
2934
- });
2935
- }
2936
- var debug8 = noop;
2937
- if (util.debuglog)
2938
- debug8 = util.debuglog("gfs4");
2939
- else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || ""))
2940
- debug8 = function() {
2941
- var m2 = util.format.apply(util, arguments);
2942
- m2 = "GFS4: " + m2.split(/\n/).join("\nGFS4: ");
2943
- console.error(m2);
2944
- };
2945
- if (!fs8[gracefulQueue]) {
2946
- queue2 = global[gracefulQueue] || [];
2947
- publishQueue(fs8, queue2);
2948
- fs8.close = function(fs$close) {
2949
- function close(fd, cb) {
2950
- return fs$close.call(fs8, fd, function(err) {
2951
- if (!err) {
2952
- resetQueue();
2953
- }
2954
- if (typeof cb === "function")
2955
- cb.apply(this, arguments);
2956
- });
2957
- }
2958
- Object.defineProperty(close, previousSymbol, {
2959
- value: fs$close
2960
- });
2961
- return close;
2962
- }(fs8.close);
2963
- fs8.closeSync = function(fs$closeSync) {
2964
- function closeSync(fd) {
2965
- fs$closeSync.apply(fs8, arguments);
2966
- resetQueue();
2967
- }
2968
- Object.defineProperty(closeSync, previousSymbol, {
2969
- value: fs$closeSync
2970
- });
2971
- return closeSync;
2972
- }(fs8.closeSync);
2973
- if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) {
2974
- process.on("exit", function() {
2975
- debug8(fs8[gracefulQueue]);
2976
- (0, import_chunk_WWAWV7DQ.__require)("assert").equal(fs8[gracefulQueue].length, 0);
2977
- });
2978
- }
2979
- }
2980
- var queue2;
2981
- if (!global[gracefulQueue]) {
2982
- publishQueue(global, fs8[gracefulQueue]);
2983
- }
2984
- module2.exports = patch(clone(fs8));
2985
- if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs8.__patched) {
2986
- module2.exports = patch(fs8);
2987
- fs8.__patched = true;
2988
- }
2989
- function patch(fs9) {
2990
- polyfills(fs9);
2991
- fs9.gracefulify = patch;
2992
- fs9.createReadStream = createReadStream;
2993
- fs9.createWriteStream = createWriteStream;
2994
- var fs$readFile = fs9.readFile;
2995
- fs9.readFile = readFile2;
2996
- function readFile2(path8, options2, cb) {
2997
- if (typeof options2 === "function")
2998
- cb = options2, options2 = null;
2999
- return go$readFile(path8, options2, cb);
3000
- function go$readFile(path9, options3, cb2, startTime) {
3001
- return fs$readFile(path9, options3, function(err) {
3002
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3003
- enqueue([go$readFile, [path9, options3, cb2], err, startTime || Date.now(), Date.now()]);
3004
- else {
3005
- if (typeof cb2 === "function")
3006
- cb2.apply(this, arguments);
3007
- }
3008
- });
3009
- }
3010
- }
3011
- var fs$writeFile = fs9.writeFile;
3012
- fs9.writeFile = writeFile;
3013
- function writeFile(path8, data, options2, cb) {
3014
- if (typeof options2 === "function")
3015
- cb = options2, options2 = null;
3016
- return go$writeFile(path8, data, options2, cb);
3017
- function go$writeFile(path9, data2, options3, cb2, startTime) {
3018
- return fs$writeFile(path9, data2, options3, function(err) {
3019
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3020
- enqueue([go$writeFile, [path9, data2, options3, cb2], err, startTime || Date.now(), Date.now()]);
3021
- else {
3022
- if (typeof cb2 === "function")
3023
- cb2.apply(this, arguments);
3024
- }
3025
- });
3026
- }
3027
- }
3028
- var fs$appendFile = fs9.appendFile;
3029
- if (fs$appendFile)
3030
- fs9.appendFile = appendFile;
3031
- function appendFile(path8, data, options2, cb) {
3032
- if (typeof options2 === "function")
3033
- cb = options2, options2 = null;
3034
- return go$appendFile(path8, data, options2, cb);
3035
- function go$appendFile(path9, data2, options3, cb2, startTime) {
3036
- return fs$appendFile(path9, data2, options3, function(err) {
3037
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3038
- enqueue([go$appendFile, [path9, data2, options3, cb2], err, startTime || Date.now(), Date.now()]);
3039
- else {
3040
- if (typeof cb2 === "function")
3041
- cb2.apply(this, arguments);
3042
- }
3043
- });
3044
- }
3045
- }
3046
- var fs$copyFile = fs9.copyFile;
3047
- if (fs$copyFile)
3048
- fs9.copyFile = copyFile;
3049
- function copyFile(src, dest, flags, cb) {
3050
- if (typeof flags === "function") {
3051
- cb = flags;
3052
- flags = 0;
3053
- }
3054
- return go$copyFile(src, dest, flags, cb);
3055
- function go$copyFile(src2, dest2, flags2, cb2, startTime) {
3056
- return fs$copyFile(src2, dest2, flags2, function(err) {
3057
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3058
- enqueue([go$copyFile, [src2, dest2, flags2, cb2], err, startTime || Date.now(), Date.now()]);
3059
- else {
3060
- if (typeof cb2 === "function")
3061
- cb2.apply(this, arguments);
3062
- }
3063
- });
3064
- }
3065
- }
3066
- var fs$readdir = fs9.readdir;
3067
- fs9.readdir = readdir;
3068
- var noReaddirOptionVersions = /^v[0-5]\./;
3069
- function readdir(path8, options2, cb) {
3070
- if (typeof options2 === "function")
3071
- cb = options2, options2 = null;
3072
- var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path9, options3, cb2, startTime) {
3073
- return fs$readdir(path9, fs$readdirCallback(
3074
- path9,
3075
- options3,
3076
- cb2,
3077
- startTime
3078
- ));
3079
- } : function go$readdir2(path9, options3, cb2, startTime) {
3080
- return fs$readdir(path9, options3, fs$readdirCallback(
3081
- path9,
3082
- options3,
3083
- cb2,
3084
- startTime
3085
- ));
3086
- };
3087
- return go$readdir(path8, options2, cb);
3088
- function fs$readdirCallback(path9, options3, cb2, startTime) {
3089
- return function(err, files) {
3090
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3091
- enqueue([
3092
- go$readdir,
3093
- [path9, options3, cb2],
3094
- err,
3095
- startTime || Date.now(),
3096
- Date.now()
3097
- ]);
3098
- else {
3099
- if (files && files.sort)
3100
- files.sort();
3101
- if (typeof cb2 === "function")
3102
- cb2.call(this, err, files);
3103
- }
3104
- };
3105
- }
3106
- }
3107
- if (process.version.substr(0, 4) === "v0.8") {
3108
- var legStreams = legacy(fs9);
3109
- ReadStream = legStreams.ReadStream;
3110
- WriteStream = legStreams.WriteStream;
3111
- }
3112
- var fs$ReadStream = fs9.ReadStream;
3113
- if (fs$ReadStream) {
3114
- ReadStream.prototype = Object.create(fs$ReadStream.prototype);
3115
- ReadStream.prototype.open = ReadStream$open;
3116
- }
3117
- var fs$WriteStream = fs9.WriteStream;
3118
- if (fs$WriteStream) {
3119
- WriteStream.prototype = Object.create(fs$WriteStream.prototype);
3120
- WriteStream.prototype.open = WriteStream$open;
3121
- }
3122
- Object.defineProperty(fs9, "ReadStream", {
3123
- get: function() {
3124
- return ReadStream;
3125
- },
3126
- set: function(val) {
3127
- ReadStream = val;
3128
- },
3129
- enumerable: true,
3130
- configurable: true
3131
- });
3132
- Object.defineProperty(fs9, "WriteStream", {
3133
- get: function() {
3134
- return WriteStream;
3135
- },
3136
- set: function(val) {
3137
- WriteStream = val;
3138
- },
3139
- enumerable: true,
3140
- configurable: true
3141
- });
3142
- var FileReadStream = ReadStream;
3143
- Object.defineProperty(fs9, "FileReadStream", {
3144
- get: function() {
3145
- return FileReadStream;
3146
- },
3147
- set: function(val) {
3148
- FileReadStream = val;
3149
- },
3150
- enumerable: true,
3151
- configurable: true
3152
- });
3153
- var FileWriteStream = WriteStream;
3154
- Object.defineProperty(fs9, "FileWriteStream", {
3155
- get: function() {
3156
- return FileWriteStream;
3157
- },
3158
- set: function(val) {
3159
- FileWriteStream = val;
3160
- },
3161
- enumerable: true,
3162
- configurable: true
3163
- });
3164
- function ReadStream(path8, options2) {
3165
- if (this instanceof ReadStream)
3166
- return fs$ReadStream.apply(this, arguments), this;
3167
- else
3168
- return ReadStream.apply(Object.create(ReadStream.prototype), arguments);
3169
- }
3170
- function ReadStream$open() {
3171
- var that = this;
3172
- open(that.path, that.flags, that.mode, function(err, fd) {
3173
- if (err) {
3174
- if (that.autoClose)
3175
- that.destroy();
3176
- that.emit("error", err);
3177
- } else {
3178
- that.fd = fd;
3179
- that.emit("open", fd);
3180
- that.read();
3181
- }
3182
- });
3183
- }
3184
- function WriteStream(path8, options2) {
3185
- if (this instanceof WriteStream)
3186
- return fs$WriteStream.apply(this, arguments), this;
3187
- else
3188
- return WriteStream.apply(Object.create(WriteStream.prototype), arguments);
3189
- }
3190
- function WriteStream$open() {
3191
- var that = this;
3192
- open(that.path, that.flags, that.mode, function(err, fd) {
3193
- if (err) {
3194
- that.destroy();
3195
- that.emit("error", err);
3196
- } else {
3197
- that.fd = fd;
3198
- that.emit("open", fd);
3199
- }
3200
- });
3201
- }
3202
- function createReadStream(path8, options2) {
3203
- return new fs9.ReadStream(path8, options2);
3204
- }
3205
- function createWriteStream(path8, options2) {
3206
- return new fs9.WriteStream(path8, options2);
3207
- }
3208
- var fs$open = fs9.open;
3209
- fs9.open = open;
3210
- function open(path8, flags, mode, cb) {
3211
- if (typeof mode === "function")
3212
- cb = mode, mode = null;
3213
- return go$open(path8, flags, mode, cb);
3214
- function go$open(path9, flags2, mode2, cb2, startTime) {
3215
- return fs$open(path9, flags2, mode2, function(err, fd) {
3216
- if (err && (err.code === "EMFILE" || err.code === "ENFILE"))
3217
- enqueue([go$open, [path9, flags2, mode2, cb2], err, startTime || Date.now(), Date.now()]);
3218
- else {
3219
- if (typeof cb2 === "function")
3220
- cb2.apply(this, arguments);
3221
- }
3222
- });
3223
- }
3224
- }
3225
- return fs9;
3226
- }
3227
- function enqueue(elem) {
3228
- debug8("ENQUEUE", elem[0].name, elem[1]);
3229
- fs8[gracefulQueue].push(elem);
3230
- retry2();
3231
- }
3232
- var retryTimer;
3233
- function resetQueue() {
3234
- var now = Date.now();
3235
- for (var i = 0; i < fs8[gracefulQueue].length; ++i) {
3236
- if (fs8[gracefulQueue][i].length > 2) {
3237
- fs8[gracefulQueue][i][3] = now;
3238
- fs8[gracefulQueue][i][4] = now;
3239
- }
3240
- }
3241
- retry2();
3242
- }
3243
- function retry2() {
3244
- clearTimeout(retryTimer);
3245
- retryTimer = void 0;
3246
- if (fs8[gracefulQueue].length === 0)
3247
- return;
3248
- var elem = fs8[gracefulQueue].shift();
3249
- var fn = elem[0];
3250
- var args = elem[1];
3251
- var err = elem[2];
3252
- var startTime = elem[3];
3253
- var lastTime = elem[4];
3254
- if (startTime === void 0) {
3255
- debug8("RETRY", fn.name, args);
3256
- fn.apply(null, args);
3257
- } else if (Date.now() - startTime >= 6e4) {
3258
- debug8("TIMEOUT", fn.name, args);
3259
- var cb = args.pop();
3260
- if (typeof cb === "function")
3261
- cb.call(null, err);
3262
- } else {
3263
- var sinceAttempt = Date.now() - lastTime;
3264
- var sinceStart = Math.max(lastTime - startTime, 1);
3265
- var desiredDelay = Math.min(sinceStart * 1.2, 100);
3266
- if (sinceAttempt >= desiredDelay) {
3267
- debug8("RETRY", fn.name, args);
3268
- fn.apply(null, args.concat([startTime]));
3269
- } else {
3270
- fs8[gracefulQueue].push(elem);
3271
- }
3272
- }
3273
- if (retryTimer === void 0) {
3274
- retryTimer = setTimeout(retry2, 0);
3275
- }
3276
- }
3277
- }
3278
- });
3279
2508
  var require_process_nextick_args = (0, import_chunk_WWAWV7DQ.__commonJS)({
3280
2509
  "../../node_modules/.pnpm/process-nextick-args@2.0.1/node_modules/process-nextick-args/index.js"(exports2, module2) {
3281
2510
  "use strict";
@@ -9313,7 +8542,7 @@ var require_isPlainObject = (0, import_chunk_WWAWV7DQ.__commonJS)({
9313
8542
  var require_file = (0, import_chunk_WWAWV7DQ.__commonJS)({
9314
8543
  "../../node_modules/.pnpm/archiver-utils@4.0.1/node_modules/archiver-utils/file.js"(exports2, module2) {
9315
8544
  "use strict";
9316
- var fs8 = require_graceful_fs();
8545
+ var fs8 = (0, import_chunk_QIVUAERL.require_graceful_fs)();
9317
8546
  var path8 = (0, import_chunk_WWAWV7DQ.__require)("path");
9318
8547
  var flatten = require_flatten();
9319
8548
  var difference = require_difference();
@@ -9465,7 +8694,7 @@ var require_file = (0, import_chunk_WWAWV7DQ.__commonJS)({
9465
8694
  var require_archiver_utils = (0, import_chunk_WWAWV7DQ.__commonJS)({
9466
8695
  "../../node_modules/.pnpm/archiver-utils@4.0.1/node_modules/archiver-utils/index.js"(exports2, module2) {
9467
8696
  "use strict";
9468
- var fs8 = require_graceful_fs();
8697
+ var fs8 = (0, import_chunk_QIVUAERL.require_graceful_fs)();
9469
8698
  var path8 = (0, import_chunk_WWAWV7DQ.__require)("path");
9470
8699
  var lazystream = require_lazystream();
9471
8700
  var normalizePath = require_normalize_path();
@@ -15514,7 +14743,7 @@ async function readSchemaFromDirectory(schemaPath2) {
15514
14743
  }
15515
14744
  const files = await (0, import_schema_files_loader.loadSchemaFiles)(schemaPath2);
15516
14745
  debug2("Loading config");
15517
- const config2 = await (0, import_chunk_YXNA7OV2.getConfig)({
14746
+ const config2 = await (0, import_chunk_OBCNUIOJ.getConfig)({
15518
14747
  datamodel: files,
15519
14748
  ignoreEnvVarErrors: true
15520
14749
  });
@@ -15822,8 +15051,8 @@ async function checkUnsupportedDataProxyMessage(command, args, implicitSchema) {
15822
15051
  if (argName.includes("schema")) {
15823
15052
  await loadEnvFile({ schemaPath: argValue, printMessage: false });
15824
15053
  const datamodel = await import_fs.default.promises.readFile(argValue, "utf-8");
15825
- const config2 = await (0, import_chunk_YXNA7OV2.getConfig)({ datamodel, ignoreEnvVarErrors: true });
15826
- const url = (0, import_chunk_YXNA7OV2.resolveUrl)((0, import_chunk_YXNA7OV2.getEffectiveUrl)(config2.datasources[0]));
15054
+ const config2 = await (0, import_chunk_OBCNUIOJ.getConfig)({ datamodel, ignoreEnvVarErrors: true });
15055
+ const url = (0, import_chunk_OBCNUIOJ.resolveUrl)((0, import_chunk_OBCNUIOJ.getEffectiveUrl)(config2.datasources[0]));
15827
15056
  if (url?.startsWith("prisma://")) {
15828
15057
  return forbiddenCmdWithDataProxyFlagMessage(command);
15829
15058
  }
@@ -15995,7 +15224,7 @@ async function getGenerators(options) {
15995
15224
  prismaPath = binaryPathsWithEngineType[queryEngineBinaryType][binaryTarget];
15996
15225
  }
15997
15226
  }
15998
- const config = await (0, import_chunk_YXNA7OV2.getConfig)({
15227
+ const config = await (0, import_chunk_OBCNUIOJ.getConfig)({
15999
15228
  datamodel: schemas,
16000
15229
  datamodelPath: schemaPath,
16001
15230
  prismaPath,
@@ -16006,7 +15235,7 @@ async function getGenerators(options) {
16006
15235
  }
16007
15236
  (0, import_chunk_5FJ3MENK.printConfigWarnings)(config.warnings);
16008
15237
  const previewFeatures = (0, import_chunk_TSJICM5S.extractPreviewFeatures)(config);
16009
- const dmmf = await (0, import_chunk_I57EV5MU.getDMMF)({
15238
+ const dmmf = await (0, import_chunk_SOZJQQOQ.getDMMF)({
16010
15239
  datamodel: schemas,
16011
15240
  datamodelPath: schemaPath,
16012
15241
  prismaPath,
@@ -16067,7 +15296,7 @@ The generator needs to either define the \`defaultOutput\` path in the manifest
16067
15296
  fromEnvVar: "null"
16068
15297
  };
16069
15298
  }
16070
- const datamodel = (0, import_chunk_OQEFNMS4.mergeSchemas)({ schemas });
15299
+ const datamodel = (0, import_chunk_XE4JX3AP.mergeSchemas)({ schemas });
16071
15300
  const envPaths2 = await getEnvPaths(schemaPath, { cwd: generator.output.value });
16072
15301
  const options2 = {
16073
15302
  datamodel,
@@ -16134,7 +15363,7 @@ generator gen {
16134
15363
  }
16135
15364
  }
16136
15365
  debug6("neededVersions", JSON.stringify(neededVersions, null, 2));
16137
- const binaryPathsByVersion = await (0, import_chunk_D4MCOTL5.getBinaryPathsByVersion)({
15366
+ const binaryPathsByVersion = await (0, import_chunk_5XRQ7ONW.getBinaryPathsByVersion)({
16138
15367
  neededVersions,
16139
15368
  binaryTarget,
16140
15369
  version,
@@ -16150,7 +15379,7 @@ generator gen {
16150
15379
  debug6({ generatorBinaryPaths });
16151
15380
  generator.setBinaryPaths(generatorBinaryPaths);
16152
15381
  if (engineVersion !== version && generator.options && generator.manifest.requiresEngines.includes(queryEngineType) && generatorBinaryPaths[queryEngineType] && generatorBinaryPaths[queryEngineType]?.[binaryTarget]) {
16153
- const customDmmf = await (0, import_chunk_I57EV5MU.getDMMF)({
15382
+ const customDmmf = await (0, import_chunk_SOZJQQOQ.getDMMF)({
16154
15383
  datamodel: schemas,
16155
15384
  datamodelPath: schemaPath,
16156
15385
  prismaPath: generatorBinaryPaths[queryEngineType]?.[binaryTarget],
@@ -16448,7 +15677,7 @@ async function formatSchema({ schemas: schemas2 }, inputFormattingOptions) {
16448
15677
  if (process.env.FORCE_PANIC_PRISMA_SCHEMA) {
16449
15678
  handleFormatPanic(
16450
15679
  () => {
16451
- import_chunk_IC5FCEGD.prismaSchemaWasm.debug_panic();
15680
+ import_chunk_YVDQPNPO.prismaSchemaWasm.debug_panic();
16452
15681
  },
16453
15682
  { schemas: schemas2 }
16454
15683
  );
@@ -16468,12 +15697,12 @@ async function formatSchema({ schemas: schemas2 }, inputFormattingOptions) {
16468
15697
  () => {
16469
15698
  const formattedMultipleSchemasRaw = formatWasm(JSON.stringify(schemas2), documentFormattingParams);
16470
15699
  const formattedMultipleSchemas2 = JSON.parse(formattedMultipleSchemasRaw);
16471
- const lintDiagnostics2 = (0, import_chunk_Y7KUHH27.lintSchema)({ schemas: formattedMultipleSchemas2 });
15700
+ const lintDiagnostics2 = (0, import_chunk_ASJ5LZTB.lintSchema)({ schemas: formattedMultipleSchemas2 });
16472
15701
  return { formattedMultipleSchemas: formattedMultipleSchemas2, lintDiagnostics: lintDiagnostics2 };
16473
15702
  },
16474
15703
  { schemas: schemas2 }
16475
15704
  );
16476
- const lintWarnings = (0, import_chunk_Y7KUHH27.getLintWarningsAsText)(lintDiagnostics);
15705
+ const lintWarnings = (0, import_chunk_ASJ5LZTB.getLintWarningsAsText)(lintDiagnostics);
16477
15706
  if (lintWarnings && import_chunk_AZNLB67U.logger_exports.should.warn()) {
16478
15707
  console.warn(lintWarnings);
16479
15708
  }
@@ -16503,7 +15732,7 @@ function handleFormatPanic(tryCb, { schemas: schemas2 }) {
16503
15732
  }
16504
15733
  }
16505
15734
  function formatWasm(schema, documentFormattingParams) {
16506
- const formattedSchema = import_chunk_IC5FCEGD.prismaSchemaWasm.format(schema, JSON.stringify(documentFormattingParams));
15735
+ const formattedSchema = import_chunk_YVDQPNPO.prismaSchemaWasm.format(schema, JSON.stringify(documentFormattingParams));
16507
15736
  return formattedSchema;
16508
15737
  }
16509
15738
  /*! Bundled license information: