maxsimcli 1.2.1 → 1.2.2

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 (21) hide show
  1. package/dist/assets/CHANGELOG.md +11 -0
  2. package/dist/assets/dashboard/packages/dashboard/.next/BUILD_ID +1 -1
  3. package/dist/assets/dashboard/packages/dashboard/.next/app-build-manifest.json +9 -9
  4. package/dist/assets/dashboard/packages/dashboard/.next/app-path-routes-manifest.json +2 -2
  5. package/dist/assets/dashboard/packages/dashboard/.next/build-manifest.json +2 -2
  6. package/dist/assets/dashboard/packages/dashboard/.next/prerender-manifest.json +3 -3
  7. package/dist/assets/dashboard/packages/dashboard/.next/server/app/_not-found.html +1 -1
  8. package/dist/assets/dashboard/packages/dashboard/.next/server/app/_not-found.rsc +1 -1
  9. package/dist/assets/dashboard/packages/dashboard/.next/server/app/index.html +1 -1
  10. package/dist/assets/dashboard/packages/dashboard/.next/server/app/index.rsc +1 -1
  11. package/dist/assets/dashboard/packages/dashboard/.next/server/app-paths-manifest.json +2 -2
  12. package/dist/assets/dashboard/packages/dashboard/.next/server/pages/404.html +1 -1
  13. package/dist/assets/dashboard/packages/dashboard/.next/server/pages/500.html +1 -1
  14. package/dist/assets/dashboard/packages/dashboard/.next/server/pages-manifest.json +1 -1
  15. package/dist/assets/dashboard/packages/dashboard/.next/server/server-reference-manifest.json +1 -1
  16. package/dist/assets/dashboard/packages/dashboard/package.json +1 -1
  17. package/dist/assets/dashboard/server.js +253 -248
  18. package/dist/install.cjs +1 -1
  19. package/package.json +3 -3
  20. /package/dist/assets/dashboard/.next/static/{y_1FCDP_R3OKEcgSQAecP → TRIRNxUoxM2848l9uYGkr}/_buildManifest.js +0 -0
  21. /package/dist/assets/dashboard/.next/static/{y_1FCDP_R3OKEcgSQAecP → TRIRNxUoxM2848l9uYGkr}/_ssgManifest.js +0 -0
@@ -1,23 +1,3 @@
1
- import { createRequire } from "node:module";
2
- import { createServer } from "node:http";
3
- import { fileURLToPath, parse } from "node:url";
4
- import next from "next";
5
- import { createServer as createServer$1 } from "node:net";
6
- import { debuglog, promisify } from "node:util";
7
- import os from "node:os";
8
- import fs, { constants, lstat, readdir, realpath, stat } from "node:fs/promises";
9
- import childProcess, { execFile } from "node:child_process";
10
- import process$1 from "node:process";
11
- import { Buffer as Buffer$1 } from "node:buffer";
12
- import path, { join, relative, resolve, sep } from "node:path";
13
- import fs$1 from "node:fs";
14
- import { EventEmitter } from "events";
15
- import { stat as stat$1, unwatchFile, watch, watchFile } from "fs";
16
- import { lstat as lstat$1, open, readdir as readdir$1, realpath as realpath$1, stat as stat$2 } from "fs/promises";
17
- import * as sysPath from "path";
18
- import { Readable } from "node:stream";
19
- import { type } from "os";
20
-
21
1
  //#region \0rolldown/runtime.js
22
2
  var __create = Object.create;
23
3
  var __defProp = Object.defineProperty;
@@ -44,13 +24,39 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
44
24
  value: mod,
45
25
  enumerable: true
46
26
  }) : target, mod));
47
- var __require = /* @__PURE__ */ createRequire(import.meta.url);
48
27
 
49
28
  //#endregion
29
+ let node_http = require("node:http");
30
+ let node_url = require("node:url");
31
+ let next = require("next");
32
+ next = __toESM(next);
33
+ let node_net = require("node:net");
34
+ let node_util = require("node:util");
35
+ let node_os = require("node:os");
36
+ node_os = __toESM(node_os);
37
+ let node_fs_promises = require("node:fs/promises");
38
+ node_fs_promises = __toESM(node_fs_promises);
39
+ let node_child_process = require("node:child_process");
40
+ node_child_process = __toESM(node_child_process);
41
+ let node_process = require("node:process");
42
+ node_process = __toESM(node_process);
43
+ let node_buffer = require("node:buffer");
44
+ let node_path = require("node:path");
45
+ node_path = __toESM(node_path);
46
+ let node_fs = require("node:fs");
47
+ node_fs = __toESM(node_fs);
48
+ let events = require("events");
49
+ let fs = require("fs");
50
+ let fs_promises = require("fs/promises");
51
+ let path = require("path");
52
+ path = __toESM(path);
53
+ let node_stream = require("node:stream");
54
+ let os = require("os");
55
+
50
56
  //#region ../../node_modules/.pnpm/address@2.0.3/node_modules/address/dist/esm/address.js
51
57
  function getDefaultInterfaceName() {
52
58
  let val = "eth";
53
- const platform = os.platform();
59
+ const platform = node_os.default.platform();
54
60
  if (platform === "darwin") val = "en";
55
61
  else if (platform === "win32") val = void 0;
56
62
  return val;
@@ -72,7 +78,7 @@ function findAddressFromInterface(items, expectedFamily, ignoreLoAddress = false
72
78
  return firstMatchItem;
73
79
  }
74
80
  function getInterfaceAddress(family, name) {
75
- const interfaces = os.networkInterfaces();
81
+ const interfaces = node_os.default.networkInterfaces();
76
82
  const noName = !name;
77
83
  name = name || getDefaultInterfaceName();
78
84
  family = family || "IPv4";
@@ -102,7 +108,7 @@ function ip(interfaceName) {
102
108
 
103
109
  //#endregion
104
110
  //#region ../../node_modules/.pnpm/detect-port@2.1.0/node_modules/detect-port/dist/esm/detect-port.js
105
- const debug$1 = debuglog("detect-port");
111
+ const debug$1 = (0, node_util.debuglog)("detect-port");
106
112
  var IPAddressNotAvailableError = class extends Error {
107
113
  constructor(options) {
108
114
  super("The IP address is not available on this machine", options);
@@ -170,7 +176,7 @@ async function tryListen(port, maxPort, hostname) {
170
176
  }
171
177
  }
172
178
  function listen(port, hostname) {
173
- const server = createServer$1();
179
+ const server = (0, node_net.createServer)();
174
180
  return new Promise((resolve, reject) => {
175
181
  server.once("error", (err) => {
176
182
  debug$1("listen %s:%s error: %s", hostname, port, err);
@@ -193,7 +199,7 @@ function listen(port, hostname) {
193
199
 
194
200
  //#endregion
195
201
  //#region ../../node_modules/.pnpm/detect-port@2.1.0/node_modules/detect-port/dist/esm/wait-port.js
196
- const debug = debuglog("detect-port:wait-port");
202
+ const debug = (0, node_util.debuglog)("detect-port:wait-port");
197
203
 
198
204
  //#endregion
199
205
  //#region ../../node_modules/.pnpm/detect-port@2.1.0/node_modules/detect-port/dist/esm/index.js
@@ -204,7 +210,7 @@ var esm_default = detectPort;
204
210
  let isDockerCached;
205
211
  function hasDockerEnv() {
206
212
  try {
207
- fs$1.statSync("/.dockerenv");
213
+ node_fs.default.statSync("/.dockerenv");
208
214
  return true;
209
215
  } catch {
210
216
  return false;
@@ -212,7 +218,7 @@ function hasDockerEnv() {
212
218
  }
213
219
  function hasDockerCGroup() {
214
220
  try {
215
- return fs$1.readFileSync("/proc/self/cgroup", "utf8").includes("docker");
221
+ return node_fs.default.readFileSync("/proc/self/cgroup", "utf8").includes("docker");
216
222
  } catch {
217
223
  return false;
218
224
  }
@@ -227,7 +233,7 @@ function isDocker() {
227
233
  let cachedResult;
228
234
  const hasContainerEnv = () => {
229
235
  try {
230
- fs$1.statSync("/run/.containerenv");
236
+ node_fs.default.statSync("/run/.containerenv");
231
237
  return true;
232
238
  } catch {
233
239
  return false;
@@ -241,18 +247,18 @@ function isInsideContainer() {
241
247
  //#endregion
242
248
  //#region ../../node_modules/.pnpm/is-wsl@3.1.1/node_modules/is-wsl/index.js
243
249
  const isWsl = () => {
244
- if (process$1.platform !== "linux") return false;
245
- if (os.release().toLowerCase().includes("microsoft")) {
250
+ if (node_process.default.platform !== "linux") return false;
251
+ if (node_os.default.release().toLowerCase().includes("microsoft")) {
246
252
  if (isInsideContainer()) return false;
247
253
  return true;
248
254
  }
249
255
  try {
250
- if (fs$1.readFileSync("/proc/version", "utf8").toLowerCase().includes("microsoft")) return !isInsideContainer();
256
+ if (node_fs.default.readFileSync("/proc/version", "utf8").toLowerCase().includes("microsoft")) return !isInsideContainer();
251
257
  } catch {}
252
- if (fs$1.existsSync("/proc/sys/fs/binfmt_misc/WSLInterop") || fs$1.existsSync("/run/WSL")) return !isInsideContainer();
258
+ if (node_fs.default.existsSync("/proc/sys/fs/binfmt_misc/WSLInterop") || node_fs.default.existsSync("/run/WSL")) return !isInsideContainer();
253
259
  return false;
254
260
  };
255
- var is_wsl_default = process$1.env.__IS_WSL_TEST__ ? isWsl : isWsl();
261
+ var is_wsl_default = node_process.default.env.__IS_WSL_TEST__ ? isWsl : isWsl();
256
262
 
257
263
  //#endregion
258
264
  //#region ../../node_modules/.pnpm/wsl-utils@0.1.0/node_modules/wsl-utils/index.js
@@ -264,11 +270,11 @@ const wslDrivesMountPoint = (() => {
264
270
  const configFilePath = "/etc/wsl.conf";
265
271
  let isConfigFileExists = false;
266
272
  try {
267
- await fs.access(configFilePath, constants.F_OK);
273
+ await node_fs_promises.default.access(configFilePath, node_fs_promises.constants.F_OK);
268
274
  isConfigFileExists = true;
269
275
  } catch {}
270
276
  if (!isConfigFileExists) return defaultMountPoint;
271
- const configContent = await fs.readFile(configFilePath, { encoding: "utf8" });
277
+ const configContent = await node_fs_promises.default.readFile(configFilePath, { encoding: "utf8" });
272
278
  const configMountPoint = /(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(configContent);
273
279
  if (!configMountPoint) return defaultMountPoint;
274
280
  mountPoint = configMountPoint.groups.mountPoint.trim();
@@ -281,7 +287,7 @@ const powerShellPathFromWsl = async () => {
281
287
  };
282
288
  const powerShellPath = async () => {
283
289
  if (is_wsl_default) return powerShellPathFromWsl();
284
- return `${process$1.env.SYSTEMROOT || process$1.env.windir || String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;
290
+ return `${node_process.default.env.SYSTEMROOT || node_process.default.env.windir || String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;
285
291
  };
286
292
 
287
293
  //#endregion
@@ -309,9 +315,9 @@ function defineLazyProperty(object, propertyName, valueGetter) {
309
315
 
310
316
  //#endregion
311
317
  //#region ../../node_modules/.pnpm/default-browser-id@5.0.1/node_modules/default-browser-id/index.js
312
- const execFileAsync$3 = promisify(execFile);
318
+ const execFileAsync$3 = (0, node_util.promisify)(node_child_process.execFile);
313
319
  async function defaultBrowserId() {
314
- if (process$1.platform !== "darwin") throw new Error("macOS only");
320
+ if (node_process.default.platform !== "darwin") throw new Error("macOS only");
315
321
  const { stdout } = await execFileAsync$3("defaults", [
316
322
  "read",
317
323
  "com.apple.LaunchServices/com.apple.launchservices.secure",
@@ -324,9 +330,9 @@ async function defaultBrowserId() {
324
330
 
325
331
  //#endregion
326
332
  //#region ../../node_modules/.pnpm/run-applescript@7.1.0/node_modules/run-applescript/index.js
327
- const execFileAsync$2 = promisify(execFile);
333
+ const execFileAsync$2 = (0, node_util.promisify)(node_child_process.execFile);
328
334
  async function runAppleScript(script, { humanReadableOutput = true, signal } = {}) {
329
- if (process$1.platform !== "darwin") throw new Error("macOS only");
335
+ if (node_process.default.platform !== "darwin") throw new Error("macOS only");
330
336
  const outputArguments = humanReadableOutput ? [] : ["-ss"];
331
337
  const execOptions = {};
332
338
  if (signal) execOptions.signal = signal;
@@ -346,7 +352,7 @@ async function bundleName(bundleId) {
346
352
 
347
353
  //#endregion
348
354
  //#region ../../node_modules/.pnpm/default-browser@5.5.0/node_modules/default-browser/windows.js
349
- const execFileAsync$1 = promisify(execFile);
355
+ const execFileAsync$1 = (0, node_util.promisify)(node_child_process.execFile);
350
356
  const windowsBrowserProgIds = {
351
357
  MSEdgeHTM: {
352
358
  name: "Edge",
@@ -437,17 +443,17 @@ async function defaultBrowser$1(_execFileAsync = execFileAsync$1) {
437
443
 
438
444
  //#endregion
439
445
  //#region ../../node_modules/.pnpm/default-browser@5.5.0/node_modules/default-browser/index.js
440
- const execFileAsync = promisify(execFile);
446
+ const execFileAsync = (0, node_util.promisify)(node_child_process.execFile);
441
447
  const titleize = (string) => string.toLowerCase().replaceAll(/(?:^|\s|-)\S/g, (x) => x.toUpperCase());
442
448
  async function defaultBrowser() {
443
- if (process$1.platform === "darwin") {
449
+ if (node_process.default.platform === "darwin") {
444
450
  const id = await defaultBrowserId();
445
451
  return {
446
452
  name: await bundleName(id),
447
453
  id
448
454
  };
449
455
  }
450
- if (process$1.platform === "linux") {
456
+ if (node_process.default.platform === "linux") {
451
457
  const { stdout } = await execFileAsync("xdg-mime", [
452
458
  "query",
453
459
  "default",
@@ -459,16 +465,16 @@ async function defaultBrowser() {
459
465
  id
460
466
  };
461
467
  }
462
- if (process$1.platform === "win32") return defaultBrowser$1();
468
+ if (node_process.default.platform === "win32") return defaultBrowser$1();
463
469
  throw new Error("Only macOS, Linux, and Windows are supported");
464
470
  }
465
471
 
466
472
  //#endregion
467
473
  //#region ../../node_modules/.pnpm/open@10.2.0/node_modules/open/index.js
468
- const execFile$1 = promisify(childProcess.execFile);
469
- const __dirname = path.dirname(fileURLToPath(import.meta.url));
470
- const localXdgOpenPath = path.join(__dirname, "xdg-open");
471
- const { platform, arch } = process$1;
474
+ const execFile = (0, node_util.promisify)(node_child_process.default.execFile);
475
+ const __dirname$1 = node_path.default.dirname((0, node_url.fileURLToPath)(require("url").pathToFileURL(__filename).href));
476
+ const localXdgOpenPath = node_path.default.join(__dirname$1, "xdg-open");
477
+ const { platform, arch } = node_process.default;
472
478
  /**
473
479
  Get the default browser name in Windows from WSL.
474
480
 
@@ -477,13 +483,13 @@ Get the default browser name in Windows from WSL.
477
483
  async function getWindowsDefaultBrowserFromWsl() {
478
484
  const powershellPath = await powerShellPath();
479
485
  const rawCommand = String.raw`(Get-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http\UserChoice").ProgId`;
480
- const { stdout } = await execFile$1(powershellPath, [
486
+ const { stdout } = await execFile(powershellPath, [
481
487
  "-NoProfile",
482
488
  "-NonInteractive",
483
489
  "-ExecutionPolicy",
484
490
  "Bypass",
485
491
  "-EncodedCommand",
486
- Buffer$1.from(rawCommand, "utf16le").toString("base64")
492
+ node_buffer.Buffer.from(rawCommand, "utf16le").toString("base64")
487
493
  ], { encoding: "utf8" });
488
494
  const progId = stdout.trim();
489
495
  const browserMap = {
@@ -579,17 +585,17 @@ const baseOpen = async (options) => {
579
585
  appArguments = appArguments.map((argument) => `"\`"${argument}\`""`);
580
586
  encodedArguments.push("-ArgumentList", appArguments.join(","));
581
587
  }
582
- options.target = Buffer$1.from(encodedArguments.join(" "), "utf16le").toString("base64");
588
+ options.target = node_buffer.Buffer.from(encodedArguments.join(" "), "utf16le").toString("base64");
583
589
  } else {
584
590
  if (app) command = app;
585
591
  else {
586
- const isBundled = !__dirname || __dirname === "/";
592
+ const isBundled = !__dirname$1 || __dirname$1 === "/";
587
593
  let exeLocalXdgOpen = false;
588
594
  try {
589
- await fs.access(localXdgOpenPath, constants.X_OK);
595
+ await node_fs_promises.default.access(localXdgOpenPath, node_fs_promises.constants.X_OK);
590
596
  exeLocalXdgOpen = true;
591
597
  } catch {}
592
- command = process$1.versions.electron ?? (platform === "android" || isBundled || !exeLocalXdgOpen) ? "xdg-open" : localXdgOpenPath;
598
+ command = node_process.default.versions.electron ?? (platform === "android" || isBundled || !exeLocalXdgOpen) ? "xdg-open" : localXdgOpenPath;
593
599
  }
594
600
  if (appArguments.length > 0) cliArguments.push(...appArguments);
595
601
  if (!options.wait) {
@@ -599,7 +605,7 @@ const baseOpen = async (options) => {
599
605
  }
600
606
  if (platform === "darwin" && appArguments.length > 0) cliArguments.push("--args", ...appArguments);
601
607
  if (options.target) cliArguments.push(options.target);
602
- const subprocess = childProcess.spawn(command, cliArguments, childProcessOptions);
608
+ const subprocess = node_child_process.default.spawn(command, cliArguments, childProcessOptions);
603
609
  if (options.wait) return new Promise((resolve, reject) => {
604
610
  subprocess.once("error", reject);
605
611
  subprocess.once("close", (exitCode) => {
@@ -778,7 +784,7 @@ var require_buffer_util = /* @__PURE__ */ __commonJSMin(((exports, module) => {
778
784
  };
779
785
  /* istanbul ignore else */
780
786
  if (!process.env.WS_NO_BUFFER_UTIL) try {
781
- const bufferUtil = __require("bufferutil");
787
+ const bufferUtil = require("bufferutil");
782
788
  module.exports.mask = function(source, mask, output, offset, length) {
783
789
  if (length < 48) _mask(source, mask, output, offset, length);
784
790
  else bufferUtil.mask(source, mask, output, offset, length);
@@ -845,7 +851,7 @@ var require_limiter = /* @__PURE__ */ __commonJSMin(((exports, module) => {
845
851
  //#endregion
846
852
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/permessage-deflate.js
847
853
  var require_permessage_deflate = /* @__PURE__ */ __commonJSMin(((exports, module) => {
848
- const zlib = __require("zlib");
854
+ const zlib = require("zlib");
849
855
  const bufferUtil = require_buffer_util();
850
856
  const Limiter = require_limiter();
851
857
  const { kStatusCode } = require_constants();
@@ -1179,7 +1185,7 @@ var require_permessage_deflate = /* @__PURE__ */ __commonJSMin(((exports, module
1179
1185
  //#endregion
1180
1186
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/validation.js
1181
1187
  var require_validation = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1182
- const { isUtf8 } = __require("buffer");
1188
+ const { isUtf8 } = require("buffer");
1183
1189
  const { hasBlob } = require_constants();
1184
1190
  const tokenChars = [
1185
1191
  0,
@@ -1366,7 +1372,7 @@ var require_validation = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1366
1372
  return buf.length < 24 ? _isValidUTF8(buf) : isUtf8(buf);
1367
1373
  };
1368
1374
  else if (!process.env.WS_NO_UTF_8_VALIDATE) try {
1369
- const isValidUTF8 = __require("utf-8-validate");
1375
+ const isValidUTF8 = require("utf-8-validate");
1370
1376
  module.exports.isValidUTF8 = function(buf) {
1371
1377
  return buf.length < 32 ? _isValidUTF8(buf) : isValidUTF8(buf);
1372
1378
  };
@@ -1376,7 +1382,7 @@ var require_validation = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1376
1382
  //#endregion
1377
1383
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/receiver.js
1378
1384
  var require_receiver = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1379
- const { Writable } = __require("stream");
1385
+ const { Writable } = require("stream");
1380
1386
  const PerMessageDeflate = require_permessage_deflate();
1381
1387
  const { BINARY_TYPES, EMPTY_BUFFER, kStatusCode, kWebSocket } = require_constants();
1382
1388
  const { concat, toArrayBuffer, unmask } = require_buffer_util();
@@ -1824,8 +1830,8 @@ var require_receiver = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1824
1830
  //#endregion
1825
1831
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/sender.js
1826
1832
  var require_sender = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1827
- const { Duplex: Duplex$3 } = __require("stream");
1828
- const { randomFillSync } = __require("crypto");
1833
+ const { Duplex: Duplex$3 } = require("stream");
1834
+ const { randomFillSync } = require("crypto");
1829
1835
  const PerMessageDeflate = require_permessage_deflate();
1830
1836
  const { EMPTY_BUFFER, kWebSocket, NOOP } = require_constants();
1831
1837
  const { isBlob, isValidStatusCode } = require_validation();
@@ -2684,14 +2690,14 @@ var require_extension = /* @__PURE__ */ __commonJSMin(((exports, module) => {
2684
2690
  //#endregion
2685
2691
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/websocket.js
2686
2692
  var require_websocket = /* @__PURE__ */ __commonJSMin(((exports, module) => {
2687
- const EventEmitter$2 = __require("events");
2688
- const https = __require("https");
2689
- const http$1 = __require("http");
2690
- const net = __require("net");
2691
- const tls = __require("tls");
2692
- const { randomBytes, createHash: createHash$1 } = __require("crypto");
2693
- const { Duplex: Duplex$2, Readable: Readable$1 } = __require("stream");
2694
- const { URL } = __require("url");
2693
+ const EventEmitter$2 = require("events");
2694
+ const https = require("https");
2695
+ const http$1 = require("http");
2696
+ const net = require("net");
2697
+ const tls = require("tls");
2698
+ const { randomBytes, createHash: createHash$1 } = require("crypto");
2699
+ const { Duplex: Duplex$2, Readable: Readable$1 } = require("stream");
2700
+ const { URL } = require("url");
2695
2701
  const PerMessageDeflate = require_permessage_deflate();
2696
2702
  const Receiver = require_receiver();
2697
2703
  const Sender = require_sender();
@@ -3657,7 +3663,7 @@ var require_websocket = /* @__PURE__ */ __commonJSMin(((exports, module) => {
3657
3663
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/stream.js
3658
3664
  var require_stream = /* @__PURE__ */ __commonJSMin(((exports, module) => {
3659
3665
  require_websocket();
3660
- const { Duplex: Duplex$1 } = __require("stream");
3666
+ const { Duplex: Duplex$1 } = require("stream");
3661
3667
  /**
3662
3668
  * Emits the `'close'` event on a stream.
3663
3669
  *
@@ -3813,10 +3819,10 @@ var require_subprotocol = /* @__PURE__ */ __commonJSMin(((exports, module) => {
3813
3819
  //#endregion
3814
3820
  //#region ../../node_modules/.pnpm/ws@8.19.0/node_modules/ws/lib/websocket-server.js
3815
3821
  var require_websocket_server = /* @__PURE__ */ __commonJSMin(((exports, module) => {
3816
- const EventEmitter$1 = __require("events");
3817
- const http = __require("http");
3818
- const { Duplex } = __require("stream");
3819
- const { createHash } = __require("crypto");
3822
+ const EventEmitter$1 = require("events");
3823
+ const http = require("http");
3824
+ const { Duplex } = require("stream");
3825
+ const { createHash } = require("crypto");
3820
3826
  const extension = require_extension();
3821
3827
  const PerMessageDeflate = require_permessage_deflate();
3822
3828
  const subprotocol = require_subprotocol();
@@ -4292,7 +4298,7 @@ const normalizeFilter = (filter) => {
4292
4298
  return emptyFn;
4293
4299
  };
4294
4300
  /** Readable readdir stream, emitting new files as they're being listed. */
4295
- var ReaddirpStream = class extends Readable {
4301
+ var ReaddirpStream = class extends node_stream.Readable {
4296
4302
  constructor(options = {}) {
4297
4303
  super({
4298
4304
  objectMode: true,
@@ -4306,14 +4312,14 @@ var ReaddirpStream = class extends Readable {
4306
4312
  const { root, type } = opts;
4307
4313
  this._fileFilter = normalizeFilter(opts.fileFilter);
4308
4314
  this._directoryFilter = normalizeFilter(opts.directoryFilter);
4309
- const statMethod = opts.lstat ? lstat : stat;
4315
+ const statMethod = opts.lstat ? node_fs_promises.lstat : node_fs_promises.stat;
4310
4316
  if (wantBigintFsStats) this._stat = (path) => statMethod(path, { bigint: true });
4311
4317
  else this._stat = statMethod;
4312
4318
  this._maxDepth = opts.depth ?? defaultOptions.depth;
4313
4319
  this._wantsDir = type ? DIR_TYPES.has(type) : false;
4314
4320
  this._wantsFile = type ? FILE_TYPES.has(type) : false;
4315
4321
  this._wantsEverything = type === EntryTypes.EVERYTHING_TYPE;
4316
- this._root = resolve(root);
4322
+ this._root = (0, node_path.resolve)(root);
4317
4323
  this._isDirent = !opts.alwaysStat;
4318
4324
  this._statsProp = this._isDirent ? "dirent" : "stats";
4319
4325
  this._rdOptions = {
@@ -4371,7 +4377,7 @@ var ReaddirpStream = class extends Readable {
4371
4377
  async _exploreDir(path, depth) {
4372
4378
  let files;
4373
4379
  try {
4374
- files = await readdir(path, this._rdOptions);
4380
+ files = await (0, node_fs_promises.readdir)(path, this._rdOptions);
4375
4381
  } catch (error) {
4376
4382
  this._onError(error);
4377
4383
  }
@@ -4385,9 +4391,9 @@ var ReaddirpStream = class extends Readable {
4385
4391
  let entry;
4386
4392
  const basename = this._isDirent ? dirent.name : dirent;
4387
4393
  try {
4388
- const fullPath = resolve(join(path, basename));
4394
+ const fullPath = (0, node_path.resolve)((0, node_path.join)(path, basename));
4389
4395
  entry = {
4390
- path: relative(this._root, fullPath),
4396
+ path: (0, node_path.relative)(this._root, fullPath),
4391
4397
  fullPath,
4392
4398
  basename
4393
4399
  };
@@ -4410,12 +4416,12 @@ var ReaddirpStream = class extends Readable {
4410
4416
  if (stats && stats.isSymbolicLink()) {
4411
4417
  const full = entry.fullPath;
4412
4418
  try {
4413
- const entryRealPath = await realpath(full);
4414
- const entryRealPathStats = await lstat(entryRealPath);
4419
+ const entryRealPath = await (0, node_fs_promises.realpath)(full);
4420
+ const entryRealPathStats = await (0, node_fs_promises.lstat)(entryRealPath);
4415
4421
  if (entryRealPathStats.isFile()) return "file";
4416
4422
  if (entryRealPathStats.isDirectory()) {
4417
4423
  const len = entryRealPath.length;
4418
- if (full.startsWith(entryRealPath) && full.substr(len, 1) === sep) {
4424
+ if (full.startsWith(entryRealPath) && full.substr(len, 1) === node_path.sep) {
4419
4425
  const recursiveError = /* @__PURE__ */ new Error(`Circular symlink detected: "${full}" points to "${entryRealPath}"`);
4420
4426
  recursiveError.code = RECURSIVE_ERROR_CODE;
4421
4427
  return this._onError(recursiveError);
@@ -4461,7 +4467,7 @@ const isWindows = pl === "win32";
4461
4467
  const isMacos = pl === "darwin";
4462
4468
  const isLinux = pl === "linux";
4463
4469
  const isFreeBSD = pl === "freebsd";
4464
- const isIBMi = type() === "OS400";
4470
+ const isIBMi = (0, os.type)() === "OS400";
4465
4471
  const EVENTS = {
4466
4472
  ALL: "all",
4467
4473
  READY: "ready",
@@ -4476,8 +4482,8 @@ const EVENTS = {
4476
4482
  const EV = EVENTS;
4477
4483
  const THROTTLE_MODE_WATCH = "watch";
4478
4484
  const statMethods = {
4479
- lstat: lstat$1,
4480
- stat: stat$2
4485
+ lstat: fs_promises.lstat,
4486
+ stat: fs_promises.stat
4481
4487
  };
4482
4488
  const KEY_LISTENERS = "listeners";
4483
4489
  const KEY_ERR = "errHandlers";
@@ -4750,7 +4756,7 @@ const binaryExtensions = new Set([
4750
4756
  "zip",
4751
4757
  "zipx"
4752
4758
  ]);
4753
- const isBinaryPath = (filePath) => binaryExtensions.has(sysPath.extname(filePath).slice(1).toLowerCase());
4759
+ const isBinaryPath = (filePath) => binaryExtensions.has(path.extname(filePath).slice(1).toLowerCase());
4754
4760
  const foreach = (val, fn) => {
4755
4761
  if (val instanceof Set) val.forEach(fn);
4756
4762
  else fn(val);
@@ -4781,14 +4787,14 @@ const FsWatchInstances = /* @__PURE__ */ new Map();
4781
4787
  * @param emitRaw emits raw event data
4782
4788
  * @returns {NativeFsWatcher}
4783
4789
  */
4784
- function createFsWatchInstance(path, options, listener, errHandler, emitRaw) {
4790
+ function createFsWatchInstance(path$23, options, listener, errHandler, emitRaw) {
4785
4791
  const handleEvent = (rawEvent, evPath) => {
4786
- listener(path);
4787
- emitRaw(rawEvent, evPath, { watchedPath: path });
4788
- if (evPath && path !== evPath) fsWatchBroadcast(sysPath.resolve(path, evPath), KEY_LISTENERS, sysPath.join(path, evPath));
4792
+ listener(path$23);
4793
+ emitRaw(rawEvent, evPath, { watchedPath: path$23 });
4794
+ if (evPath && path$23 !== evPath) fsWatchBroadcast(path.resolve(path$23, evPath), KEY_LISTENERS, path.join(path$23, evPath));
4789
4795
  };
4790
4796
  try {
4791
- return watch(path, { persistent: options.persistent }, handleEvent);
4797
+ return (0, fs.watch)(path$23, { persistent: options.persistent }, handleEvent);
4792
4798
  } catch (error) {
4793
4799
  errHandler(error);
4794
4800
  return;
@@ -4813,12 +4819,12 @@ const fsWatchBroadcast = (fullPath, listenerType, val1, val2, val3) => {
4813
4819
  * @param options to be passed to fs_watch
4814
4820
  * @param handlers container for event listener functions
4815
4821
  */
4816
- const setFsWatchListener = (path, fullPath, options, handlers) => {
4822
+ const setFsWatchListener = (path$27, fullPath, options, handlers) => {
4817
4823
  const { listener, errHandler, rawEmitter } = handlers;
4818
4824
  let cont = FsWatchInstances.get(fullPath);
4819
4825
  let watcher;
4820
4826
  if (!options.persistent) {
4821
- watcher = createFsWatchInstance(path, options, listener, errHandler, rawEmitter);
4827
+ watcher = createFsWatchInstance(path$27, options, listener, errHandler, rawEmitter);
4822
4828
  if (!watcher) return;
4823
4829
  return watcher.close.bind(watcher);
4824
4830
  }
@@ -4827,13 +4833,13 @@ const setFsWatchListener = (path, fullPath, options, handlers) => {
4827
4833
  addAndConvert(cont, KEY_ERR, errHandler);
4828
4834
  addAndConvert(cont, KEY_RAW, rawEmitter);
4829
4835
  } else {
4830
- watcher = createFsWatchInstance(path, options, fsWatchBroadcast.bind(null, fullPath, KEY_LISTENERS), errHandler, fsWatchBroadcast.bind(null, fullPath, KEY_RAW));
4836
+ watcher = createFsWatchInstance(path$27, options, fsWatchBroadcast.bind(null, fullPath, KEY_LISTENERS), errHandler, fsWatchBroadcast.bind(null, fullPath, KEY_RAW));
4831
4837
  if (!watcher) return;
4832
4838
  watcher.on(EV.ERROR, async (error) => {
4833
4839
  const broadcastErr = fsWatchBroadcast.bind(null, fullPath, KEY_ERR);
4834
4840
  if (cont) cont.watcherUnusable = true;
4835
4841
  if (isWindows && error.code === "EPERM") try {
4836
- await (await open(path, "r")).close();
4842
+ await (await (0, fs_promises.open)(path$27, "r")).close();
4837
4843
  broadcastErr(error);
4838
4844
  } catch (err) {}
4839
4845
  else broadcastErr(error);
@@ -4869,12 +4875,12 @@ const FsWatchFileInstances = /* @__PURE__ */ new Map();
4869
4875
  * @param handlers container for event listener functions
4870
4876
  * @returns closer
4871
4877
  */
4872
- const setFsWatchFileListener = (path, fullPath, options, handlers) => {
4878
+ const setFsWatchFileListener = (path$28, fullPath, options, handlers) => {
4873
4879
  const { listener, rawEmitter } = handlers;
4874
4880
  let cont = FsWatchFileInstances.get(fullPath);
4875
4881
  const copts = cont && cont.options;
4876
4882
  if (copts && (copts.persistent < options.persistent || copts.interval > options.interval)) {
4877
- unwatchFile(fullPath);
4883
+ (0, fs.unwatchFile)(fullPath);
4878
4884
  cont = void 0;
4879
4885
  }
4880
4886
  if (cont) {
@@ -4885,7 +4891,7 @@ const setFsWatchFileListener = (path, fullPath, options, handlers) => {
4885
4891
  listeners: listener,
4886
4892
  rawEmitters: rawEmitter,
4887
4893
  options,
4888
- watcher: watchFile(fullPath, options, (curr, prev) => {
4894
+ watcher: (0, fs.watchFile)(fullPath, options, (curr, prev) => {
4889
4895
  foreach(cont.rawEmitters, (rawEmitter) => {
4890
4896
  rawEmitter(EV.CHANGE, fullPath, {
4891
4897
  curr,
@@ -4893,7 +4899,7 @@ const setFsWatchFileListener = (path, fullPath, options, handlers) => {
4893
4899
  });
4894
4900
  });
4895
4901
  const currmtime = curr.mtimeMs;
4896
- if (curr.size !== prev.size || currmtime > prev.mtimeMs || currmtime === 0) foreach(cont.listeners, (listener) => listener(path, curr));
4902
+ if (curr.size !== prev.size || currmtime > prev.mtimeMs || currmtime === 0) foreach(cont.listeners, (listener) => listener(path$28, curr));
4897
4903
  })
4898
4904
  };
4899
4905
  FsWatchFileInstances.set(fullPath, cont);
@@ -4903,7 +4909,7 @@ const setFsWatchFileListener = (path, fullPath, options, handlers) => {
4903
4909
  delFromSet(cont, KEY_RAW, rawEmitter);
4904
4910
  if (isEmptySet(cont.listeners)) {
4905
4911
  FsWatchFileInstances.delete(fullPath);
4906
- unwatchFile(fullPath);
4912
+ (0, fs.unwatchFile)(fullPath);
4907
4913
  cont.options = cont.watcher = void 0;
4908
4914
  Object.freeze(cont);
4909
4915
  }
@@ -4923,22 +4929,22 @@ var NodeFsHandler = class {
4923
4929
  * @param listener on fs change
4924
4930
  * @returns closer for the watcher instance
4925
4931
  */
4926
- _watchWithNodeFs(path, listener) {
4932
+ _watchWithNodeFs(path$24, listener) {
4927
4933
  const opts = this.fsw.options;
4928
- const directory = sysPath.dirname(path);
4929
- const basename = sysPath.basename(path);
4934
+ const directory = path.dirname(path$24);
4935
+ const basename = path.basename(path$24);
4930
4936
  this.fsw._getWatchedDir(directory).add(basename);
4931
- const absolutePath = sysPath.resolve(path);
4937
+ const absolutePath = path.resolve(path$24);
4932
4938
  const options = { persistent: opts.persistent };
4933
4939
  if (!listener) listener = EMPTY_FN;
4934
4940
  let closer;
4935
4941
  if (opts.usePolling) {
4936
4942
  options.interval = opts.interval !== opts.binaryInterval && isBinaryPath(basename) ? opts.binaryInterval : opts.interval;
4937
- closer = setFsWatchFileListener(path, absolutePath, options, {
4943
+ closer = setFsWatchFileListener(path$24, absolutePath, options, {
4938
4944
  listener,
4939
4945
  rawEmitter: this.fsw._emitRaw
4940
4946
  });
4941
- } else closer = setFsWatchListener(path, absolutePath, options, {
4947
+ } else closer = setFsWatchListener(path$24, absolutePath, options, {
4942
4948
  listener,
4943
4949
  errHandler: this._boundHandleError,
4944
4950
  rawEmitter: this.fsw._emitRaw
@@ -4951,24 +4957,24 @@ var NodeFsHandler = class {
4951
4957
  */
4952
4958
  _handleFile(file, stats, initialAdd) {
4953
4959
  if (this.fsw.closed) return;
4954
- const dirname = sysPath.dirname(file);
4955
- const basename = sysPath.basename(file);
4960
+ const dirname = path.dirname(file);
4961
+ const basename = path.basename(file);
4956
4962
  const parent = this.fsw._getWatchedDir(dirname);
4957
4963
  let prevStats = stats;
4958
4964
  if (parent.has(basename)) return;
4959
- const listener = async (path, newStats) => {
4965
+ const listener = async (path$29, newStats) => {
4960
4966
  if (!this.fsw._throttle(THROTTLE_MODE_WATCH, file, 5)) return;
4961
4967
  if (!newStats || newStats.mtimeMs === 0) try {
4962
- const newStats = await stat$2(file);
4968
+ const newStats = await (0, fs_promises.stat)(file);
4963
4969
  if (this.fsw.closed) return;
4964
4970
  const at = newStats.atimeMs;
4965
4971
  const mt = newStats.mtimeMs;
4966
4972
  if (!at || at <= mt || mt !== prevStats.mtimeMs) this.fsw._emit(EV.CHANGE, file, newStats);
4967
4973
  if ((isMacos || isLinux || isFreeBSD) && prevStats.ino !== newStats.ino) {
4968
- this.fsw._closeFile(path);
4974
+ this.fsw._closeFile(path$29);
4969
4975
  prevStats = newStats;
4970
4976
  const closer = this._watchWithNodeFs(file, listener);
4971
- if (closer) this.fsw._addPathCloser(path, closer);
4977
+ if (closer) this.fsw._addPathCloser(path$29, closer);
4972
4978
  } else prevStats = newStats;
4973
4979
  } catch (error) {
4974
4980
  this.fsw._remove(dirname, basename);
@@ -4995,7 +5001,7 @@ var NodeFsHandler = class {
4995
5001
  * @param item basename of this item
4996
5002
  * @returns true if no more processing is needed for this entry.
4997
5003
  */
4998
- async _handleSymlink(entry, directory, path, item) {
5004
+ async _handleSymlink(entry, directory, path$30, item) {
4999
5005
  if (this.fsw.closed) return;
5000
5006
  const full = entry.fullPath;
5001
5007
  const dir = this.fsw._getWatchedDir(directory);
@@ -5003,7 +5009,7 @@ var NodeFsHandler = class {
5003
5009
  this.fsw._incrReadyCount();
5004
5010
  let linkPath;
5005
5011
  try {
5006
- linkPath = await realpath$1(path);
5012
+ linkPath = await (0, fs_promises.realpath)(path$30);
5007
5013
  } catch (e) {
5008
5014
  this.fsw._emitReady();
5009
5015
  return true;
@@ -5012,12 +5018,12 @@ var NodeFsHandler = class {
5012
5018
  if (dir.has(item)) {
5013
5019
  if (this.fsw._symlinkPaths.get(full) !== linkPath) {
5014
5020
  this.fsw._symlinkPaths.set(full, linkPath);
5015
- this.fsw._emit(EV.CHANGE, path, entry.stats);
5021
+ this.fsw._emit(EV.CHANGE, path$30, entry.stats);
5016
5022
  }
5017
5023
  } else {
5018
5024
  dir.add(item);
5019
5025
  this.fsw._symlinkPaths.set(full, linkPath);
5020
- this.fsw._emit(EV.ADD, path, entry.stats);
5026
+ this.fsw._emit(EV.ADD, path$30, entry.stats);
5021
5027
  }
5022
5028
  this.fsw._emitReady();
5023
5029
  return true;
@@ -5026,7 +5032,7 @@ var NodeFsHandler = class {
5026
5032
  this.fsw._symlinkPaths.set(full, true);
5027
5033
  }
5028
5034
  _handleRead(directory, initialAdd, wh, target, dir, depth, throttler) {
5029
- directory = sysPath.join(directory, "");
5035
+ directory = path.join(directory, "");
5030
5036
  throttler = this.fsw._throttle("readdir", directory, 1e3);
5031
5037
  if (!throttler) return;
5032
5038
  const previous = this.fsw._getWatchedDir(wh.path);
@@ -5042,17 +5048,17 @@ var NodeFsHandler = class {
5042
5048
  return;
5043
5049
  }
5044
5050
  const item = entry.path;
5045
- let path = sysPath.join(directory, item);
5051
+ let path$25 = path.join(directory, item);
5046
5052
  current.add(item);
5047
- if (entry.stats.isSymbolicLink() && await this._handleSymlink(entry, directory, path, item)) return;
5053
+ if (entry.stats.isSymbolicLink() && await this._handleSymlink(entry, directory, path$25, item)) return;
5048
5054
  if (this.fsw.closed) {
5049
5055
  stream = void 0;
5050
5056
  return;
5051
5057
  }
5052
5058
  if (item === target || !target && !previous.has(item)) {
5053
5059
  this.fsw._incrReadyCount();
5054
- path = sysPath.join(dir, sysPath.relative(dir, path));
5055
- this._addToNodeFs(path, initialAdd, wh, depth + 1);
5060
+ path$25 = path.join(dir, path.relative(dir, path$25));
5061
+ this._addToNodeFs(path$25, initialAdd, wh, depth + 1);
5056
5062
  }
5057
5063
  }).on(EV.ERROR, this._boundHandleError);
5058
5064
  return new Promise((resolve, reject) => {
@@ -5086,10 +5092,10 @@ var NodeFsHandler = class {
5086
5092
  * @returns closer for the watcher instance.
5087
5093
  */
5088
5094
  async _handleDir(dir, stats, initialAdd, depth, target, wh, realpath) {
5089
- const parentDir = this.fsw._getWatchedDir(sysPath.dirname(dir));
5090
- const tracked = parentDir.has(sysPath.basename(dir));
5095
+ const parentDir = this.fsw._getWatchedDir(path.dirname(dir));
5096
+ const tracked = parentDir.has(path.basename(dir));
5091
5097
  if (!(initialAdd && this.fsw.options.ignoreInitial) && !target && !tracked) this.fsw._emit(EV.ADD_DIR, dir, stats);
5092
- parentDir.add(sysPath.basename(dir));
5098
+ parentDir.add(path.basename(dir));
5093
5099
  this.fsw._getWatchedDir(dir);
5094
5100
  let throttler;
5095
5101
  let closer;
@@ -5115,13 +5121,13 @@ var NodeFsHandler = class {
5115
5121
  * @param depth Child path actually targeted for watch
5116
5122
  * @param target Child path actually targeted for watch
5117
5123
  */
5118
- async _addToNodeFs(path, initialAdd, priorWh, depth, target) {
5124
+ async _addToNodeFs(path$26, initialAdd, priorWh, depth, target) {
5119
5125
  const ready = this.fsw._emitReady;
5120
- if (this.fsw._isIgnored(path) || this.fsw.closed) {
5126
+ if (this.fsw._isIgnored(path$26) || this.fsw.closed) {
5121
5127
  ready();
5122
5128
  return false;
5123
5129
  }
5124
- const wh = this.fsw._getWatchHelpers(path);
5130
+ const wh = this.fsw._getWatchHelpers(path$26);
5125
5131
  if (priorWh) {
5126
5132
  wh.filterPath = (entry) => priorWh.filterPath(entry);
5127
5133
  wh.filterDir = (entry) => priorWh.filterDir(entry);
@@ -5136,29 +5142,29 @@ var NodeFsHandler = class {
5136
5142
  const follow = this.fsw.options.followSymlinks;
5137
5143
  let closer;
5138
5144
  if (stats.isDirectory()) {
5139
- const absPath = sysPath.resolve(path);
5140
- const targetPath = follow ? await realpath$1(path) : path;
5145
+ const absPath = path.resolve(path$26);
5146
+ const targetPath = follow ? await (0, fs_promises.realpath)(path$26) : path$26;
5141
5147
  if (this.fsw.closed) return;
5142
5148
  closer = await this._handleDir(wh.watchPath, stats, initialAdd, depth, target, wh, targetPath);
5143
5149
  if (this.fsw.closed) return;
5144
5150
  if (absPath !== targetPath && targetPath !== void 0) this.fsw._symlinkPaths.set(absPath, targetPath);
5145
5151
  } else if (stats.isSymbolicLink()) {
5146
- const targetPath = follow ? await realpath$1(path) : path;
5152
+ const targetPath = follow ? await (0, fs_promises.realpath)(path$26) : path$26;
5147
5153
  if (this.fsw.closed) return;
5148
- const parent = sysPath.dirname(wh.watchPath);
5154
+ const parent = path.dirname(wh.watchPath);
5149
5155
  this.fsw._getWatchedDir(parent).add(wh.watchPath);
5150
5156
  this.fsw._emit(EV.ADD, wh.watchPath, stats);
5151
- closer = await this._handleDir(parent, stats, initialAdd, depth, path, wh, targetPath);
5157
+ closer = await this._handleDir(parent, stats, initialAdd, depth, path$26, wh, targetPath);
5152
5158
  if (this.fsw.closed) return;
5153
- if (targetPath !== void 0) this.fsw._symlinkPaths.set(sysPath.resolve(path), targetPath);
5159
+ if (targetPath !== void 0) this.fsw._symlinkPaths.set(path.resolve(path$26), targetPath);
5154
5160
  } else closer = this._handleFile(wh.watchPath, stats, initialAdd);
5155
5161
  ready();
5156
- if (closer) this.fsw._addPathCloser(path, closer);
5162
+ if (closer) this.fsw._addPathCloser(path$26, closer);
5157
5163
  return false;
5158
5164
  } catch (error) {
5159
5165
  if (this.fsw._handleError(error)) {
5160
5166
  ready();
5161
- return path;
5167
+ return path$26;
5162
5168
  }
5163
5169
  }
5164
5170
  }
@@ -5187,30 +5193,30 @@ function createPattern(matcher) {
5187
5193
  if (typeof matcher === "object" && matcher !== null) return (string) => {
5188
5194
  if (matcher.path === string) return true;
5189
5195
  if (matcher.recursive) {
5190
- const relative = sysPath.relative(matcher.path, string);
5196
+ const relative = path.relative(matcher.path, string);
5191
5197
  if (!relative) return false;
5192
- return !relative.startsWith("..") && !sysPath.isAbsolute(relative);
5198
+ return !relative.startsWith("..") && !path.isAbsolute(relative);
5193
5199
  }
5194
5200
  return false;
5195
5201
  };
5196
5202
  return () => false;
5197
5203
  }
5198
- function normalizePath$1(path) {
5199
- if (typeof path !== "string") throw new Error("string expected");
5200
- path = sysPath.normalize(path);
5201
- path = path.replace(/\\/g, "/");
5204
+ function normalizePath$1(path$2) {
5205
+ if (typeof path$2 !== "string") throw new Error("string expected");
5206
+ path$2 = path.normalize(path$2);
5207
+ path$2 = path$2.replace(/\\/g, "/");
5202
5208
  let prepend = false;
5203
- if (path.startsWith("//")) prepend = true;
5209
+ if (path$2.startsWith("//")) prepend = true;
5204
5210
  const DOUBLE_SLASH_RE = /\/\//;
5205
- while (path.match(DOUBLE_SLASH_RE)) path = path.replace(DOUBLE_SLASH_RE, "/");
5206
- if (prepend) path = "/" + path;
5207
- return path;
5211
+ while (path$2.match(DOUBLE_SLASH_RE)) path$2 = path$2.replace(DOUBLE_SLASH_RE, "/");
5212
+ if (prepend) path$2 = "/" + path$2;
5213
+ return path$2;
5208
5214
  }
5209
5215
  function matchPatterns(patterns, testString, stats) {
5210
- const path = normalizePath$1(testString);
5216
+ const path$12 = normalizePath$1(testString);
5211
5217
  for (let index = 0; index < patterns.length; index++) {
5212
5218
  const pattern = patterns[index];
5213
- if (pattern(path, stats)) return true;
5219
+ if (pattern(path$12, stats)) return true;
5214
5220
  }
5215
5221
  return false;
5216
5222
  }
@@ -5235,14 +5241,14 @@ const toUnix = (string) => {
5235
5241
  if (prepend) str = SLASH + str;
5236
5242
  return str;
5237
5243
  };
5238
- const normalizePathToUnix = (path) => toUnix(sysPath.normalize(toUnix(path)));
5239
- const normalizeIgnored = (cwd = "") => (path) => {
5240
- if (typeof path === "string") return normalizePathToUnix(sysPath.isAbsolute(path) ? path : sysPath.join(cwd, path));
5241
- else return path;
5244
+ const normalizePathToUnix = (path$3) => toUnix(path.normalize(toUnix(path$3)));
5245
+ const normalizeIgnored = (cwd = "") => (path$4) => {
5246
+ if (typeof path$4 === "string") return normalizePathToUnix(path.isAbsolute(path$4) ? path$4 : path.join(cwd, path$4));
5247
+ else return path$4;
5242
5248
  };
5243
- const getAbsolutePath = (path, cwd) => {
5244
- if (sysPath.isAbsolute(path)) return path;
5245
- return sysPath.join(cwd, path);
5249
+ const getAbsolutePath = (path$5, cwd) => {
5250
+ if (path.isAbsolute(path$5)) return path$5;
5251
+ return path.join(cwd, path$5);
5246
5252
  };
5247
5253
  const EMPTY_SET = Object.freeze(/* @__PURE__ */ new Set());
5248
5254
  /**
@@ -5266,9 +5272,9 @@ var DirEntry = class {
5266
5272
  if (items.size > 0) return;
5267
5273
  const dir = this.path;
5268
5274
  try {
5269
- await readdir$1(dir);
5275
+ await (0, fs_promises.readdir)(dir);
5270
5276
  } catch (err) {
5271
- if (this._removeWatcher) this._removeWatcher(sysPath.dirname(dir), sysPath.basename(dir));
5277
+ if (this._removeWatcher) this._removeWatcher(path.dirname(dir), path.basename(dir));
5272
5278
  }
5273
5279
  }
5274
5280
  has(item) {
@@ -5292,12 +5298,12 @@ var DirEntry = class {
5292
5298
  const STAT_METHOD_F = "stat";
5293
5299
  const STAT_METHOD_L = "lstat";
5294
5300
  var WatchHelper = class {
5295
- constructor(path, follow, fsw) {
5301
+ constructor(path$6, follow, fsw) {
5296
5302
  this.fsw = fsw;
5297
- const watchPath = path;
5298
- this.path = path = path.replace(REPLACER_RE, "");
5303
+ const watchPath = path$6;
5304
+ this.path = path$6 = path$6.replace(REPLACER_RE, "");
5299
5305
  this.watchPath = watchPath;
5300
- this.fullWatchPath = sysPath.resolve(watchPath);
5306
+ this.fullWatchPath = path.resolve(watchPath);
5301
5307
  this.dirParts = [];
5302
5308
  this.dirParts.forEach((parts) => {
5303
5309
  if (parts.length > 1) parts.pop();
@@ -5306,7 +5312,7 @@ var WatchHelper = class {
5306
5312
  this.statMethod = follow ? STAT_METHOD_F : STAT_METHOD_L;
5307
5313
  }
5308
5314
  entryPath(entry) {
5309
- return sysPath.join(this.watchPath, sysPath.relative(this.watchPath, entry.fullPath));
5315
+ return path.join(this.watchPath, path.relative(this.watchPath, entry.fullPath));
5310
5316
  }
5311
5317
  filterPath(entry) {
5312
5318
  const { stats } = entry;
@@ -5326,7 +5332,7 @@ var WatchHelper = class {
5326
5332
  * .add(directories)
5327
5333
  * .on('add', path => log('File', path, 'was added'))
5328
5334
  */
5329
- var FSWatcher = class extends EventEmitter {
5335
+ var FSWatcher = class extends events.EventEmitter {
5330
5336
  constructor(_opts = {}) {
5331
5337
  super();
5332
5338
  this.closed = false;
@@ -5408,23 +5414,23 @@ var FSWatcher = class extends EventEmitter {
5408
5414
  this.closed = false;
5409
5415
  this._closePromise = void 0;
5410
5416
  let paths = unifyPaths(paths_);
5411
- if (cwd) paths = paths.map((path) => {
5412
- return getAbsolutePath(path, cwd);
5417
+ if (cwd) paths = paths.map((path$13) => {
5418
+ return getAbsolutePath(path$13, cwd);
5413
5419
  });
5414
- paths.forEach((path) => {
5415
- this._removeIgnoredPath(path);
5420
+ paths.forEach((path$14) => {
5421
+ this._removeIgnoredPath(path$14);
5416
5422
  });
5417
5423
  this._userIgnored = void 0;
5418
5424
  if (!this._readyCount) this._readyCount = 0;
5419
5425
  this._readyCount += paths.length;
5420
- Promise.all(paths.map(async (path) => {
5421
- const res = await this._nodeFsHandler._addToNodeFs(path, !_internal, void 0, 0, _origAdd);
5426
+ Promise.all(paths.map(async (path$15) => {
5427
+ const res = await this._nodeFsHandler._addToNodeFs(path$15, !_internal, void 0, 0, _origAdd);
5422
5428
  if (res) this._emitReady();
5423
5429
  return res;
5424
5430
  })).then((results) => {
5425
5431
  if (this.closed) return;
5426
5432
  results.forEach((item) => {
5427
- if (item) this.add(sysPath.dirname(item), sysPath.basename(_origAdd || item));
5433
+ if (item) this.add(path.dirname(item), path.basename(_origAdd || item));
5428
5434
  });
5429
5435
  });
5430
5436
  return this;
@@ -5436,15 +5442,15 @@ var FSWatcher = class extends EventEmitter {
5436
5442
  if (this.closed) return this;
5437
5443
  const paths = unifyPaths(paths_);
5438
5444
  const { cwd } = this.options;
5439
- paths.forEach((path) => {
5440
- if (!sysPath.isAbsolute(path) && !this._closers.has(path)) {
5441
- if (cwd) path = sysPath.join(cwd, path);
5442
- path = sysPath.resolve(path);
5445
+ paths.forEach((path$7) => {
5446
+ if (!path.isAbsolute(path$7) && !this._closers.has(path$7)) {
5447
+ if (cwd) path$7 = path.join(cwd, path$7);
5448
+ path$7 = path.resolve(path$7);
5443
5449
  }
5444
- this._closePath(path);
5445
- this._addIgnoredPath(path);
5446
- if (this._watched.has(path)) this._addIgnoredPath({
5447
- path,
5450
+ this._closePath(path$7);
5451
+ this._addIgnoredPath(path$7);
5452
+ if (this._watched.has(path$7)) this._addIgnoredPath({
5453
+ path: path$7,
5448
5454
  recursive: true
5449
5455
  });
5450
5456
  this._userIgnored = void 0;
@@ -5483,7 +5489,7 @@ var FSWatcher = class extends EventEmitter {
5483
5489
  getWatched() {
5484
5490
  const watchList = {};
5485
5491
  this._watched.forEach((entry, dir) => {
5486
- const index = (this.options.cwd ? sysPath.relative(this.options.cwd, dir) : dir) || ONE_DOT;
5492
+ const index = (this.options.cwd ? path.relative(this.options.cwd, dir) : dir) || ONE_DOT;
5487
5493
  watchList[index] = entry.getChildren().sort();
5488
5494
  });
5489
5495
  return watchList;
@@ -5500,34 +5506,34 @@ var FSWatcher = class extends EventEmitter {
5500
5506
  * @param stats arguments to be passed with event
5501
5507
  * @returns the error if defined, otherwise the value of the FSWatcher instance's `closed` flag
5502
5508
  */
5503
- async _emit(event, path, stats) {
5509
+ async _emit(event, path$8, stats) {
5504
5510
  if (this.closed) return;
5505
5511
  const opts = this.options;
5506
- if (isWindows) path = sysPath.normalize(path);
5507
- if (opts.cwd) path = sysPath.relative(opts.cwd, path);
5508
- const args = [path];
5512
+ if (isWindows) path$8 = path.normalize(path$8);
5513
+ if (opts.cwd) path$8 = path.relative(opts.cwd, path$8);
5514
+ const args = [path$8];
5509
5515
  if (stats != null) args.push(stats);
5510
5516
  const awf = opts.awaitWriteFinish;
5511
5517
  let pw;
5512
- if (awf && (pw = this._pendingWrites.get(path))) {
5518
+ if (awf && (pw = this._pendingWrites.get(path$8))) {
5513
5519
  pw.lastChange = /* @__PURE__ */ new Date();
5514
5520
  return this;
5515
5521
  }
5516
5522
  if (opts.atomic) {
5517
5523
  if (event === EVENTS.UNLINK) {
5518
- this._pendingUnlinks.set(path, [event, ...args]);
5524
+ this._pendingUnlinks.set(path$8, [event, ...args]);
5519
5525
  setTimeout(() => {
5520
- this._pendingUnlinks.forEach((entry, path) => {
5526
+ this._pendingUnlinks.forEach((entry, path$16) => {
5521
5527
  this.emit(...entry);
5522
5528
  this.emit(EVENTS.ALL, ...entry);
5523
- this._pendingUnlinks.delete(path);
5529
+ this._pendingUnlinks.delete(path$16);
5524
5530
  });
5525
5531
  }, typeof opts.atomic === "number" ? opts.atomic : 100);
5526
5532
  return this;
5527
5533
  }
5528
- if (event === EVENTS.ADD && this._pendingUnlinks.has(path)) {
5534
+ if (event === EVENTS.ADD && this._pendingUnlinks.has(path$8)) {
5529
5535
  event = EVENTS.CHANGE;
5530
- this._pendingUnlinks.delete(path);
5536
+ this._pendingUnlinks.delete(path$8);
5531
5537
  }
5532
5538
  }
5533
5539
  if (awf && (event === EVENTS.ADD || event === EVENTS.CHANGE) && this._readyEmitted) {
@@ -5542,17 +5548,17 @@ var FSWatcher = class extends EventEmitter {
5542
5548
  this.emitWithAll(event, args);
5543
5549
  }
5544
5550
  };
5545
- this._awaitWriteFinish(path, awf.stabilityThreshold, event, awfEmit);
5551
+ this._awaitWriteFinish(path$8, awf.stabilityThreshold, event, awfEmit);
5546
5552
  return this;
5547
5553
  }
5548
5554
  if (event === EVENTS.CHANGE) {
5549
- if (!this._throttle(EVENTS.CHANGE, path, 50)) return this;
5555
+ if (!this._throttle(EVENTS.CHANGE, path$8, 50)) return this;
5550
5556
  }
5551
5557
  if (opts.alwaysStat && stats === void 0 && (event === EVENTS.ADD || event === EVENTS.ADD_DIR || event === EVENTS.CHANGE)) {
5552
- const fullPath = opts.cwd ? sysPath.join(opts.cwd, path) : path;
5558
+ const fullPath = opts.cwd ? path.join(opts.cwd, path$8) : path$8;
5553
5559
  let stats;
5554
5560
  try {
5555
- stats = await stat$2(fullPath);
5561
+ stats = await (0, fs_promises.stat)(fullPath);
5556
5562
  } catch (err) {}
5557
5563
  if (!stats || this.closed) return;
5558
5564
  args.push(stats);
@@ -5576,20 +5582,20 @@ var FSWatcher = class extends EventEmitter {
5576
5582
  * @param timeout duration of time to suppress duplicate actions
5577
5583
  * @returns tracking object or false if action should be suppressed
5578
5584
  */
5579
- _throttle(actionType, path, timeout) {
5585
+ _throttle(actionType, path$17, timeout) {
5580
5586
  if (!this._throttled.has(actionType)) this._throttled.set(actionType, /* @__PURE__ */ new Map());
5581
5587
  const action = this._throttled.get(actionType);
5582
5588
  if (!action) throw new Error("invalid throttle");
5583
- const actionPath = action.get(path);
5589
+ const actionPath = action.get(path$17);
5584
5590
  if (actionPath) {
5585
5591
  actionPath.count++;
5586
5592
  return false;
5587
5593
  }
5588
5594
  let timeoutObject;
5589
5595
  const clear = () => {
5590
- const item = action.get(path);
5596
+ const item = action.get(path$17);
5591
5597
  const count = item ? item.count : 0;
5592
- action.delete(path);
5598
+ action.delete(path$17);
5593
5599
  clearTimeout(timeoutObject);
5594
5600
  if (item) clearTimeout(item.timeoutObject);
5595
5601
  return count;
@@ -5600,7 +5606,7 @@ var FSWatcher = class extends EventEmitter {
5600
5606
  clear,
5601
5607
  count: 0
5602
5608
  };
5603
- action.set(path, thr);
5609
+ action.set(path$17, thr);
5604
5610
  return thr;
5605
5611
  }
5606
5612
  _incrReadyCount() {
@@ -5614,34 +5620,34 @@ var FSWatcher = class extends EventEmitter {
5614
5620
  * @param event
5615
5621
  * @param awfEmit Callback to be called when ready for event to be emitted.
5616
5622
  */
5617
- _awaitWriteFinish(path, threshold, event, awfEmit) {
5623
+ _awaitWriteFinish(path$9, threshold, event, awfEmit) {
5618
5624
  const awf = this.options.awaitWriteFinish;
5619
5625
  if (typeof awf !== "object") return;
5620
5626
  const pollInterval = awf.pollInterval;
5621
5627
  let timeoutHandler;
5622
- let fullPath = path;
5623
- if (this.options.cwd && !sysPath.isAbsolute(path)) fullPath = sysPath.join(this.options.cwd, path);
5628
+ let fullPath = path$9;
5629
+ if (this.options.cwd && !path.isAbsolute(path$9)) fullPath = path.join(this.options.cwd, path$9);
5624
5630
  const now = /* @__PURE__ */ new Date();
5625
5631
  const writes = this._pendingWrites;
5626
5632
  function awaitWriteFinishFn(prevStat) {
5627
- stat$1(fullPath, (err, curStat) => {
5628
- if (err || !writes.has(path)) {
5633
+ (0, fs.stat)(fullPath, (err, curStat) => {
5634
+ if (err || !writes.has(path$9)) {
5629
5635
  if (err && err.code !== "ENOENT") awfEmit(err);
5630
5636
  return;
5631
5637
  }
5632
5638
  const now = Number(/* @__PURE__ */ new Date());
5633
- if (prevStat && curStat.size !== prevStat.size) writes.get(path).lastChange = now;
5634
- if (now - writes.get(path).lastChange >= threshold) {
5635
- writes.delete(path);
5639
+ if (prevStat && curStat.size !== prevStat.size) writes.get(path$9).lastChange = now;
5640
+ if (now - writes.get(path$9).lastChange >= threshold) {
5641
+ writes.delete(path$9);
5636
5642
  awfEmit(void 0, curStat);
5637
5643
  } else timeoutHandler = setTimeout(awaitWriteFinishFn, pollInterval, curStat);
5638
5644
  });
5639
5645
  }
5640
- if (!writes.has(path)) {
5641
- writes.set(path, {
5646
+ if (!writes.has(path$9)) {
5647
+ writes.set(path$9, {
5642
5648
  lastChange: now,
5643
5649
  cancelWait: () => {
5644
- writes.delete(path);
5650
+ writes.delete(path$9);
5645
5651
  clearTimeout(timeoutHandler);
5646
5652
  return event;
5647
5653
  }
@@ -5652,31 +5658,31 @@ var FSWatcher = class extends EventEmitter {
5652
5658
  /**
5653
5659
  * Determines whether user has asked to ignore this path.
5654
5660
  */
5655
- _isIgnored(path, stats) {
5656
- if (this.options.atomic && DOT_RE.test(path)) return true;
5661
+ _isIgnored(path$18, stats) {
5662
+ if (this.options.atomic && DOT_RE.test(path$18)) return true;
5657
5663
  if (!this._userIgnored) {
5658
5664
  const { cwd } = this.options;
5659
5665
  const ignored = (this.options.ignored || []).map(normalizeIgnored(cwd));
5660
5666
  this._userIgnored = anymatch([...[...this._ignoredPaths].map(normalizeIgnored(cwd)), ...ignored], void 0);
5661
5667
  }
5662
- return this._userIgnored(path, stats);
5668
+ return this._userIgnored(path$18, stats);
5663
5669
  }
5664
- _isntIgnored(path, stat) {
5665
- return !this._isIgnored(path, stat);
5670
+ _isntIgnored(path$19, stat) {
5671
+ return !this._isIgnored(path$19, stat);
5666
5672
  }
5667
5673
  /**
5668
5674
  * Provides a set of common helpers and properties relating to symlink handling.
5669
5675
  * @param path file or directory pattern being watched
5670
5676
  */
5671
- _getWatchHelpers(path) {
5672
- return new WatchHelper(path, this.options.followSymlinks, this);
5677
+ _getWatchHelpers(path$20) {
5678
+ return new WatchHelper(path$20, this.options.followSymlinks, this);
5673
5679
  }
5674
5680
  /**
5675
5681
  * Provides directory tracking objects
5676
5682
  * @param directory path of the directory
5677
5683
  */
5678
5684
  _getWatchedDir(directory) {
5679
- const dir = sysPath.resolve(directory);
5685
+ const dir = path.resolve(directory);
5680
5686
  if (!this._watched.has(dir)) this._watched.set(dir, new DirEntry(dir, this._boundRemove));
5681
5687
  return this._watched.get(dir);
5682
5688
  }
@@ -5695,50 +5701,50 @@ var FSWatcher = class extends EventEmitter {
5695
5701
  * @param item base path of item/directory
5696
5702
  */
5697
5703
  _remove(directory, item, isDirectory) {
5698
- const path = sysPath.join(directory, item);
5699
- const fullPath = sysPath.resolve(path);
5700
- isDirectory = isDirectory != null ? isDirectory : this._watched.has(path) || this._watched.has(fullPath);
5701
- if (!this._throttle("remove", path, 100)) return;
5704
+ const path$10 = path.join(directory, item);
5705
+ const fullPath = path.resolve(path$10);
5706
+ isDirectory = isDirectory != null ? isDirectory : this._watched.has(path$10) || this._watched.has(fullPath);
5707
+ if (!this._throttle("remove", path$10, 100)) return;
5702
5708
  if (!isDirectory && this._watched.size === 1) this.add(directory, item, true);
5703
- this._getWatchedDir(path).getChildren().forEach((nested) => this._remove(path, nested));
5709
+ this._getWatchedDir(path$10).getChildren().forEach((nested) => this._remove(path$10, nested));
5704
5710
  const parent = this._getWatchedDir(directory);
5705
5711
  const wasTracked = parent.has(item);
5706
5712
  parent.remove(item);
5707
5713
  if (this._symlinkPaths.has(fullPath)) this._symlinkPaths.delete(fullPath);
5708
- let relPath = path;
5709
- if (this.options.cwd) relPath = sysPath.relative(this.options.cwd, path);
5714
+ let relPath = path$10;
5715
+ if (this.options.cwd) relPath = path.relative(this.options.cwd, path$10);
5710
5716
  if (this.options.awaitWriteFinish && this._pendingWrites.has(relPath)) {
5711
5717
  if (this._pendingWrites.get(relPath).cancelWait() === EVENTS.ADD) return;
5712
5718
  }
5713
- this._watched.delete(path);
5719
+ this._watched.delete(path$10);
5714
5720
  this._watched.delete(fullPath);
5715
5721
  const eventName = isDirectory ? EVENTS.UNLINK_DIR : EVENTS.UNLINK;
5716
- if (wasTracked && !this._isIgnored(path)) this._emit(eventName, path);
5717
- this._closePath(path);
5722
+ if (wasTracked && !this._isIgnored(path$10)) this._emit(eventName, path$10);
5723
+ this._closePath(path$10);
5718
5724
  }
5719
5725
  /**
5720
5726
  * Closes all watchers for a path
5721
5727
  */
5722
- _closePath(path) {
5723
- this._closeFile(path);
5724
- const dir = sysPath.dirname(path);
5725
- this._getWatchedDir(dir).remove(sysPath.basename(path));
5728
+ _closePath(path$11) {
5729
+ this._closeFile(path$11);
5730
+ const dir = path.dirname(path$11);
5731
+ this._getWatchedDir(dir).remove(path.basename(path$11));
5726
5732
  }
5727
5733
  /**
5728
5734
  * Closes only file-specific watchers
5729
5735
  */
5730
- _closeFile(path) {
5731
- const closers = this._closers.get(path);
5736
+ _closeFile(path$21) {
5737
+ const closers = this._closers.get(path$21);
5732
5738
  if (!closers) return;
5733
5739
  closers.forEach((closer) => closer());
5734
- this._closers.delete(path);
5740
+ this._closers.delete(path$21);
5735
5741
  }
5736
- _addPathCloser(path, closer) {
5742
+ _addPathCloser(path$22, closer) {
5737
5743
  if (!closer) return;
5738
- let list = this._closers.get(path);
5744
+ let list = this._closers.get(path$22);
5739
5745
  if (!list) {
5740
5746
  list = [];
5741
- this._closers.set(path, list);
5747
+ this._closers.set(path$22, list);
5742
5748
  }
5743
5749
  list.push(closer);
5744
5750
  }
@@ -5773,7 +5779,7 @@ var FSWatcher = class extends EventEmitter {
5773
5779
  * const watcher = watch('.').on('all', (event, path) => { console.log(event, path); });
5774
5780
  * watch('.', { atomic: true, awaitWriteFinish: true, ignored: (f, stats) => stats?.isFile() && !f.endsWith('.js') })
5775
5781
  */
5776
- function watch$1(paths, options = {}) {
5782
+ function watch(paths, options = {}) {
5777
5783
  const watcher = new FSWatcher(options);
5778
5784
  watcher.add(paths);
5779
5785
  return watcher;
@@ -5814,7 +5820,7 @@ function normalizePath(p) {
5814
5820
  function setupWatcher(cwd, wss) {
5815
5821
  const planningDir = normalizePath(`${cwd}/.planning`);
5816
5822
  console.error(`[watcher] Watching ${planningDir}`);
5817
- const watcher = watch$1(planningDir, {
5823
+ const watcher = watch(planningDir, {
5818
5824
  persistent: true,
5819
5825
  ignoreInitial: true,
5820
5826
  awaitWriteFinish: {
@@ -5860,17 +5866,17 @@ function setupWatcher(cwd, wss) {
5860
5866
  //#region server.ts
5861
5867
  const dev = process.env.NODE_ENV !== "production";
5862
5868
  const projectCwd = process.env.MAXSIM_PROJECT_CWD || process.cwd();
5863
- const app = next({ dev });
5869
+ const app = (0, next.default)({ dev });
5864
5870
  const handle = app.getRequestHandler();
5865
5871
  async function main() {
5866
5872
  await app.prepare();
5867
5873
  const upgradeHandler = app.getUpgradeHandler();
5868
5874
  const wss = createWSS();
5869
- const server = createServer((req, res) => {
5870
- handle(req, res, parse(req.url || "/", true));
5875
+ const server = (0, node_http.createServer)((req, res) => {
5876
+ handle(req, res, (0, node_url.parse)(req.url || "/", true));
5871
5877
  });
5872
5878
  server.on("upgrade", (req, socket, head) => {
5873
- const { pathname } = parse(req.url || "/", true);
5879
+ const { pathname } = (0, node_url.parse)(req.url || "/", true);
5874
5880
  if (pathname === "/api/ws") wss.handleUpgrade(req, socket, head, (ws) => {
5875
5881
  wss.emit("connection", ws, req);
5876
5882
  });
@@ -5909,5 +5915,4 @@ main().catch((err) => {
5909
5915
  process.exit(1);
5910
5916
  });
5911
5917
 
5912
- //#endregion
5913
- export { };
5918
+ //#endregion