@cloudflare/vite-plugin 1.54.9 → 1.54.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -18,7 +18,6 @@ import events, { EventEmitter } from "node:events";
18
18
  import { Buffer as Buffer$1 } from "node:buffer";
19
19
  import crypto$1, { createCipheriv, createDecipheriv, createHash, randomBytes, randomUUID, webcrypto } from "node:crypto";
20
20
  import { AsyncLocalStorage } from "node:async_hooks";
21
- import { assert } from "node:console";
22
21
  import * as fsp from "node:fs/promises";
23
22
  import fs, { constants as constants$1 } from "node:fs/promises";
24
23
  import childProcess, { execFile, execFileSync, spawn, spawnSync } from "node:child_process";
@@ -137,7 +136,7 @@ function createFatalError$1(message, isJson, options) {
137
136
  __name$6(createFatalError$1, "createFatalError");
138
137
 
139
138
  //#endregion
140
- //#region ../workers-utils/dist/chunk-T5JQYOMX.mjs
139
+ //#region ../workers-utils/dist/chunk-JGKSDUFK.mjs
141
140
  function hasKnownExportType(entry) {
142
141
  const type = entry?.type;
143
142
  return type === "durable-object" || type === "worker";
@@ -173,6 +172,17 @@ function getDurableObjectContainerApps(containers) {
173
172
  return Array.isArray(containers) ? containers.filter(isDurableObjectContainerApp) : [];
174
173
  }
175
174
  __name$6(getDurableObjectContainerApps, "getDurableObjectContainerApps");
175
+ function getResolvedDurableObjectContainerApps(containers, exports$1) {
176
+ return getDurableObjectContainerApps(containers).map((container) => {
177
+ const className = resolveContainerClassName(container, exports$1);
178
+ if (typeof className !== "string" || className.length === 0) throw new UserError(`The container "${container.name}" is not linked to a Durable Object. Either set "containers.class_name", or reference this container from a Durable Object's \`exports\` entry via its "container" field.`, { telemetryMessage: "durable object container class unresolved" });
179
+ return {
180
+ ...container,
181
+ class_name: className
182
+ };
183
+ });
184
+ }
185
+ __name$6(getResolvedDurableObjectContainerApps, "getResolvedDurableObjectContainerApps");
176
186
  function getContainerNameToClassNameMap(exports$1) {
177
187
  const containerNameToClassName = /* @__PURE__ */ new Map();
178
188
  for (const [className, entry] of Object.entries(getDurableObjectExports(exports$1))) if ("container" in entry && typeof entry.container === "string" && !containerNameToClassName.has(entry.container)) containerNameToClassName.set(entry.container, className);
@@ -227,7 +237,7 @@ function getDurableObjectClassNameToUseSQLiteMap(migrations, exports$1) {
227
237
  __name$6(getDurableObjectClassNameToUseSQLiteMap, "getDurableObjectClassNameToUseSQLiteMap");
228
238
  function validateDurableObjectContainerApplications(config$2, containers = getDurableObjectContainerApps(config$2.containers)) {
229
239
  const allDOs = getDurableObjectClassNameToUseSQLiteMap(config$2.migrations, config$2.exports);
230
- for (const container of containers) {
240
+ for (const container of getResolvedDurableObjectContainerApps(containers, config$2.exports)) {
231
241
  const maybeBoundDO = config$2.durable_objects.bindings.find((durableObject) => durableObject.class_name === container.class_name);
232
242
  const useSQLite = allDOs.get(container.class_name);
233
243
  if (useSQLite === void 0 && maybeBoundDO === void 0) throw new UserError(`The container class_name ${container.class_name} does not match any durable object class_name defined in your Wrangler config file. Note that the durable object must be defined in the same script as the container.`, { telemetryMessage: "no DO defined that matches container class_name" });
@@ -2195,7 +2205,12 @@ var APIError = class extends ParseError {
2195
2205
  return this.#status;
2196
2206
  }
2197
2207
  isGatewayError() {
2198
- if (this.#status !== void 0) return [524].includes(this.#status);
2208
+ if (this.#status !== void 0) return [
2209
+ 502,
2210
+ 503,
2211
+ 504,
2212
+ 524
2213
+ ].includes(this.#status);
2199
2214
  return false;
2200
2215
  }
2201
2216
  isRetryable() {
@@ -2599,8 +2614,8 @@ function formatConfigSnippet(snippet, configPath, formatted = true) {
2599
2614
  __name$6(formatConfigSnippet, "formatConfigSnippet");
2600
2615
 
2601
2616
  //#endregion
2602
- //#region ../workers-utils/dist/chunk-KBTXSRPS.mjs
2603
- var DEFAULT_COMPAT_DATE = "2026-09-11";
2617
+ //#region ../workers-utils/dist/chunk-YZWVNJ5I.mjs
2618
+ var DEFAULT_COMPAT_DATE = "2026-09-16";
2604
2619
  function assertNever(_value) {}
2605
2620
  __name$6(assertNever, "assertNever");
2606
2621
  function mapWorkerMetadataBindings(bindings) {
@@ -2772,9 +2787,6 @@ function mapWorkerMetadataBindings(bindings) {
2772
2787
  instance_name: binding.instance_name
2773
2788
  }];
2774
2789
  break;
2775
- case "websearch":
2776
- configObj.websearch = { binding: binding.name };
2777
- break;
2778
2790
  case "agent_memory":
2779
2791
  configObj.agent_memory = [...configObj.agent_memory ?? [], {
2780
2792
  binding: binding.name,
@@ -4648,7 +4660,7 @@ var require_tree = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undi
4648
4660
  //#endregion
4649
4661
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/util.js
4650
4662
  var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/util.js": ((exports, module) => {
4651
- const assert$35 = __require$2("node:assert");
4663
+ const assert$34 = __require$2("node:assert");
4652
4664
  const { kDestroyed: kDestroyed$2, kBodyUsed: kBodyUsed$1, kListeners, kBody: kBody$2 } = require_symbols();
4653
4665
  const { IncomingMessage } = __require$2("node:http");
4654
4666
  const stream$1 = __require$2("node:stream");
@@ -4666,7 +4678,7 @@ var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
4666
4678
  this[kBodyUsed$1] = false;
4667
4679
  }
4668
4680
  async *[Symbol.asyncIterator]() {
4669
- assert$35(!this[kBodyUsed$1], "disturbed");
4681
+ assert$34(!this[kBodyUsed$1], "disturbed");
4670
4682
  this[kBodyUsed$1] = true;
4671
4683
  yield* this[kBody$2];
4672
4684
  }
@@ -4679,7 +4691,7 @@ var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
4679
4691
  function wrapRequestBody$1(body) {
4680
4692
  if (isStream$1(body)) {
4681
4693
  if (bodyLength(body) === 0) body.on("data", function() {
4682
- assert$35(false);
4694
+ assert$34(false);
4683
4695
  });
4684
4696
  if (typeof body.readableDidRead !== "boolean") {
4685
4697
  body[kBodyUsed$1] = false;
@@ -4796,7 +4808,7 @@ var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
4796
4808
  function getHostname(host) {
4797
4809
  if (host[0] === "[") {
4798
4810
  const idx$1 = host.indexOf("]");
4799
- assert$35(idx$1 !== -1);
4811
+ assert$34(idx$1 !== -1);
4800
4812
  return host.substring(1, idx$1);
4801
4813
  }
4802
4814
  const idx = host.indexOf(":");
@@ -4811,7 +4823,7 @@ var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
4811
4823
  */
4812
4824
  function getServerName$1(host) {
4813
4825
  if (!host) return null;
4814
- assert$35(typeof host === "string");
4826
+ assert$34(typeof host === "string");
4815
4827
  const servername = getHostname(host);
4816
4828
  if (net$4.isIP(servername)) return "";
4817
4829
  return servername;
@@ -5431,7 +5443,7 @@ var require_util$5 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
5431
5443
  function errorRequest(client, request$2, err) {
5432
5444
  try {
5433
5445
  request$2.onError(err);
5434
- assert$35(request$2.aborted);
5446
+ assert$34(request$2.aborted);
5435
5447
  } catch (err$1) {
5436
5448
  client.emit("error", err$1);
5437
5449
  }
@@ -5718,7 +5730,7 @@ var require_diagnostics = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
5718
5730
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/request.js
5719
5731
  var require_request$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/request.js": ((exports, module) => {
5720
5732
  const { InvalidArgumentError: InvalidArgumentError$36, NotSupportedError: NotSupportedError$1 } = require_errors();
5721
- const assert$34 = __require$2("node:assert");
5733
+ const assert$33 = __require$2("node:assert");
5722
5734
  const { isValidHTTPToken: isValidHTTPToken$3, isValidHeaderValue: isValidHeaderValue$2, isStream, destroy, isBuffer, isFormDataLike, isIterable, hasSafeIterator: hasSafeIterator$2, isBlobLike, serializePathWithQuery: serializePathWithQuery$3, assertRequestHandler, getServerName, normalizedMethodRecords: normalizedMethodRecords$1, getProtocolFromUrlString } = require_util$5();
5723
5735
  const { channels: channels$6 } = require_diagnostics();
5724
5736
  const { headerNameLowerCasedRecord } = require_constants$6();
@@ -5825,8 +5837,8 @@ var require_request$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
5825
5837
  }
5826
5838
  }
5827
5839
  onConnect(abort$1) {
5828
- assert$34(!this.aborted);
5829
- assert$34(!this.completed);
5840
+ assert$33(!this.aborted);
5841
+ assert$33(!this.completed);
5830
5842
  if (this.error) abort$1(this.error);
5831
5843
  else {
5832
5844
  this.abort = abort$1;
@@ -5837,8 +5849,8 @@ var require_request$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
5837
5849
  return this[kHandler].onResponseStarted?.();
5838
5850
  }
5839
5851
  onHeaders(statusCode, headers, resume$1, statusText) {
5840
- assert$34(!this.aborted);
5841
- assert$34(!this.completed);
5852
+ assert$33(!this.aborted);
5853
+ assert$33(!this.completed);
5842
5854
  if (channels$6.headers.hasSubscribers) channels$6.headers.publish({
5843
5855
  request: this,
5844
5856
  response: {
@@ -5854,8 +5866,8 @@ var require_request$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
5854
5866
  }
5855
5867
  }
5856
5868
  onData(chunk) {
5857
- assert$34(!this.aborted);
5858
- assert$34(!this.completed);
5869
+ assert$33(!this.aborted);
5870
+ assert$33(!this.completed);
5859
5871
  if (channels$6.bodyChunkReceived.hasSubscribers) channels$6.bodyChunkReceived.publish({
5860
5872
  request: this,
5861
5873
  chunk
@@ -5868,14 +5880,14 @@ var require_request$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
5868
5880
  }
5869
5881
  }
5870
5882
  onUpgrade(statusCode, headers, socket) {
5871
- assert$34(!this.aborted);
5872
- assert$34(!this.completed);
5883
+ assert$33(!this.aborted);
5884
+ assert$33(!this.completed);
5873
5885
  return this[kHandler].onUpgrade(statusCode, headers, socket);
5874
5886
  }
5875
5887
  onComplete(trailers) {
5876
5888
  this.onFinally();
5877
- assert$34(!this.aborted);
5878
- assert$34(!this.completed);
5889
+ assert$33(!this.aborted);
5890
+ assert$33(!this.completed);
5879
5891
  this.completed = true;
5880
5892
  if (channels$6.trailers.hasSubscribers) channels$6.trailers.publish({
5881
5893
  request: this,
@@ -6266,7 +6278,7 @@ var require_dispatcher_base = /* @__PURE__ */ __commonJS$2({ "../../node_modules
6266
6278
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/connect.js
6267
6279
  var require_connect = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/core/connect.js": ((exports, module) => {
6268
6280
  const net$3 = __require$2("node:net");
6269
- const assert$33 = __require$2("node:assert");
6281
+ const assert$32 = __require$2("node:assert");
6270
6282
  const util$23 = require_util$5();
6271
6283
  const { InvalidArgumentError: InvalidArgumentError$32 } = require_errors();
6272
6284
  let tls$1;
@@ -6314,7 +6326,7 @@ var require_connect = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
6314
6326
  if (!tls$1) tls$1 = __require$2("node:tls");
6315
6327
  servername = servername || options.servername || util$23.getServerName(host) || null;
6316
6328
  const sessionKey = servername || hostname$1;
6317
- assert$33(sessionKey);
6329
+ assert$32(sessionKey);
6318
6330
  const session = customSession || sessionCache.get(sessionKey) || null;
6319
6331
  port = port || 443;
6320
6332
  socket = tls$1.connect({
@@ -6332,7 +6344,7 @@ var require_connect = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
6332
6344
  sessionCache.set(sessionKey, session$1);
6333
6345
  });
6334
6346
  } else {
6335
- assert$33(!httpSocket, "httpSocket can only be sent on TLS update");
6347
+ assert$32(!httpSocket, "httpSocket can only be sent on TLS update");
6336
6348
  port = port || 80;
6337
6349
  socket = net$3.connect({
6338
6350
  highWaterMark: 64 * 1024,
@@ -7270,7 +7282,7 @@ var require_encoding = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
7270
7282
  //#endregion
7271
7283
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/infra/index.js
7272
7284
  var require_infra = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/infra/index.js": ((exports, module) => {
7273
- const assert$32 = __require$2("node:assert");
7285
+ const assert$31 = __require$2("node:assert");
7274
7286
  const { utf8DecodeBytes: utf8DecodeBytes$2 } = require_encoding();
7275
7287
  /**
7276
7288
  * @param {(char: string) => boolean} condition
@@ -7363,7 +7375,7 @@ var require_infra = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
7363
7375
  * @see https://infra.spec.whatwg.org/#isomorphic-encode
7364
7376
  */
7365
7377
  function isomorphicEncode$3(input) {
7366
- assert$32(!invalidIsomorphicEncodeValueRegex.test(input));
7378
+ assert$31(!invalidIsomorphicEncodeValueRegex.test(input));
7367
7379
  return input;
7368
7380
  }
7369
7381
  /**
@@ -7401,7 +7413,7 @@ var require_infra = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
7401
7413
  function serializeJavascriptValueToJSONString$1(value) {
7402
7414
  const result = JSON.stringify(value);
7403
7415
  if (result === void 0) throw new TypeError("Value is not JSON serializable");
7404
- assert$32(typeof result === "string");
7416
+ assert$31(typeof result === "string");
7405
7417
  return result;
7406
7418
  }
7407
7419
  module.exports = {
@@ -7421,7 +7433,7 @@ var require_infra = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
7421
7433
  //#endregion
7422
7434
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/fetch/data-url.js
7423
7435
  var require_data_url = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/fetch/data-url.js": ((exports, module) => {
7424
- const assert$31 = __require$2("node:assert");
7436
+ const assert$30 = __require$2("node:assert");
7425
7437
  const { forgivingBase64, collectASequenceOfCodePoints: collectASequenceOfCodePoints$1, collectASequenceOfCodePointsFast: collectASequenceOfCodePointsFast$2, isomorphicDecode: isomorphicDecode$1, removeASCIIWhitespace, removeChars: removeChars$2 } = require_infra();
7426
7438
  const encoder = new TextEncoder();
7427
7439
  /**
@@ -7435,7 +7447,7 @@ var require_data_url = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
7435
7447
  const HTTP_QUOTED_STRING_TOKENS = /^[\u0009\u0020-\u007E\u0080-\u00FF]+$/u;
7436
7448
  /** @param {URL} dataURL */
7437
7449
  function dataURLProcessor$1(dataURL) {
7438
- assert$31(dataURL.protocol === "data:");
7450
+ assert$30(dataURL.protocol === "data:");
7439
7451
  let input = URLSerializer$4(dataURL, true);
7440
7452
  input = input.slice(5);
7441
7453
  const position = { position: 0 };
@@ -7557,7 +7569,7 @@ var require_data_url = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
7557
7569
  function collectAnHTTPQuotedString$1(input, position, extractValue$2 = false) {
7558
7570
  const positionStart = position.position;
7559
7571
  let value = "";
7560
- assert$31(input[position.position] === "\"");
7572
+ assert$30(input[position.position] === "\"");
7561
7573
  position.position++;
7562
7574
  while (true) {
7563
7575
  value += collectASequenceOfCodePoints$1((char) => char !== "\"" && char !== "\\", input, position);
@@ -7572,7 +7584,7 @@ var require_data_url = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
7572
7584
  value += input[position.position];
7573
7585
  position.position++;
7574
7586
  } else {
7575
- assert$31(quoteOrBackslash === "\"");
7587
+ assert$30(quoteOrBackslash === "\"");
7576
7588
  break;
7577
7589
  }
7578
7590
  }
@@ -7583,7 +7595,7 @@ var require_data_url = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
7583
7595
  * @see https://mimesniff.spec.whatwg.org/#serialize-a-mime-type
7584
7596
  */
7585
7597
  function serializeAMimeType$3(mimeType) {
7586
- assert$31(mimeType !== "failure");
7598
+ assert$30(mimeType !== "failure");
7587
7599
  const { parameters, essence } = mimeType;
7588
7600
  let serialization = essence;
7589
7601
  for (let [name, value] of parameters.entries()) {
@@ -7762,7 +7774,7 @@ var require_runtime_features = /* @__PURE__ */ __commonJS$2({ "../../node_module
7762
7774
  //#endregion
7763
7775
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/webidl/index.js
7764
7776
  var require_webidl = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/webidl/index.js": ((exports, module) => {
7765
- const assert$30 = __require$2("node:assert");
7777
+ const assert$29 = __require$2("node:assert");
7766
7778
  const { types: types$3, inspect: inspect$1 } = __require$2("node:util");
7767
7779
  const { runtimeFeatures: runtimeFeatures$7 } = require_runtime_features();
7768
7780
  const UNDEFINED = 1;
@@ -8077,7 +8089,7 @@ var require_webidl = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8077
8089
  offset = jsBufferSource.byteOffset;
8078
8090
  length = jsBufferSource.byteLength;
8079
8091
  } else {
8080
- assert$30(types$3.isAnyArrayBuffer(jsBufferSource));
8092
+ assert$29(types$3.isAnyArrayBuffer(jsBufferSource));
8081
8093
  length = jsBufferSource.byteLength;
8082
8094
  }
8083
8095
  if (jsArrayBuffer.detached) return new Uint8Array(0);
@@ -8271,7 +8283,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8271
8283
  const { collectAnHTTPQuotedString, parseMIMEType: parseMIMEType$2 } = require_data_url();
8272
8284
  const { performance: performance$1 } = __require$2("node:perf_hooks");
8273
8285
  const { ReadableStreamFrom: ReadableStreamFrom$2, isValidHTTPToken: isValidHTTPToken$2, normalizedMethodRecordsBase: normalizedMethodRecordsBase$1 } = require_util$5();
8274
- const assert$29 = __require$2("node:assert");
8286
+ const assert$28 = __require$2("node:assert");
8275
8287
  const { isUint8Array: isUint8Array$1 } = __require$2("node:util/types");
8276
8288
  const { webidl: webidl$15 } = require_webidl();
8277
8289
  const { isomorphicEncode: isomorphicEncode$2, collectASequenceOfCodePoints, removeChars: removeChars$1 } = require_infra();
@@ -8458,7 +8470,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8458
8470
  */
8459
8471
  function determineRequestsReferrer$1(request$2) {
8460
8472
  const policy = request$2.referrerPolicy;
8461
- assert$29(policy);
8473
+ assert$28(policy);
8462
8474
  let referrerSource = null;
8463
8475
  if (request$2.referrer === "client") {
8464
8476
  const globalOrigin$1 = getGlobalOrigin$1();
@@ -8511,7 +8523,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8511
8523
  * @param {boolean} [originOnly=false]
8512
8524
  */
8513
8525
  function stripURLForReferrer(url$2, originOnly = false) {
8514
- assert$29(webidl$15.is.URL(url$2));
8526
+ assert$28(webidl$15.is.URL(url$2));
8515
8527
  url$2 = new URL(url$2);
8516
8528
  if (urlIsLocal$1(url$2)) return "no-referrer";
8517
8529
  url$2.username = "";
@@ -8803,7 +8815,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8803
8815
  * @returns {boolean}
8804
8816
  */
8805
8817
  function urlIsLocal$1(url$2) {
8806
- assert$29("protocol" in url$2);
8818
+ assert$28("protocol" in url$2);
8807
8819
  const protocol = url$2.protocol;
8808
8820
  return protocol === "about:" || protocol === "blob:" || protocol === "data:";
8809
8821
  }
@@ -8819,7 +8831,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8819
8831
  * @param {URL} url
8820
8832
  */
8821
8833
  function urlIsHttpHttpsScheme$2(url$2) {
8822
- assert$29("protocol" in url$2);
8834
+ assert$28("protocol" in url$2);
8823
8835
  const protocol = url$2.protocol;
8824
8836
  return protocol === "http:" || protocol === "https:";
8825
8837
  }
@@ -8952,7 +8964,7 @@ var require_util$4 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
8952
8964
  temporaryValue += collectAnHTTPQuotedString(input, position);
8953
8965
  if (position.position < input.length) continue;
8954
8966
  } else {
8955
- assert$29(input.charCodeAt(position.position) === 44);
8967
+ assert$28(input.charCodeAt(position.position) === 44);
8956
8968
  position.position++;
8957
8969
  }
8958
8970
  temporaryValue = removeChars$1(temporaryValue, true, true, (char) => char === 9 || char === 32);
@@ -9206,7 +9218,7 @@ var require_formdata_parser = /* @__PURE__ */ __commonJS$2({ "../../node_modules
9206
9218
  const { HTTP_TOKEN_CODEPOINTS } = require_data_url();
9207
9219
  const { makeEntry } = require_formdata();
9208
9220
  const { webidl: webidl$13 } = require_webidl();
9209
- const assert$28 = __require$2("node:assert");
9221
+ const assert$27 = __require$2("node:assert");
9210
9222
  const { isomorphicDecode } = require_infra();
9211
9223
  const dd = Buffer.from("--");
9212
9224
  const decoder = new TextDecoder();
@@ -9237,7 +9249,7 @@ var require_formdata_parser = /* @__PURE__ */ __commonJS$2({ "../../node_modules
9237
9249
  * @param {ReturnType<import('./data-url')['parseMIMEType']>} mimeType
9238
9250
  */
9239
9251
  function multipartFormDataParser$1(input, mimeType) {
9240
- assert$28(mimeType !== "failure" && mimeType.essence === "multipart/form-data");
9252
+ assert$27(mimeType !== "failure" && mimeType.essence === "multipart/form-data");
9241
9253
  const boundaryString = mimeType.parameters.get("boundary");
9242
9254
  if (boundaryString === void 0) throw parsingError("missing boundary in content-type header");
9243
9255
  const boundary = Buffer.from(`--${boundaryString}`, "utf8");
@@ -9270,8 +9282,8 @@ var require_formdata_parser = /* @__PURE__ */ __commonJS$2({ "../../node_modules
9270
9282
  if (!isAsciiString(contentType)) contentType = "";
9271
9283
  value = new File([body], filename, { type: contentType });
9272
9284
  } else value = decoderIgnoreBOM.decode(Buffer.from(body));
9273
- assert$28(webidl$13.is.USVString(name));
9274
- assert$28(typeof value === "string" && webidl$13.is.USVString(value) || webidl$13.is.File(value));
9285
+ assert$27(webidl$13.is.USVString(name));
9286
+ assert$27(typeof value === "string" && webidl$13.is.USVString(value) || webidl$13.is.File(value));
9275
9287
  entryList.push(makeEntry(name, value, filename));
9276
9288
  }
9277
9289
  }
@@ -9483,7 +9495,7 @@ var require_body = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undi
9483
9495
  const { ReadableStreamFrom: ReadableStreamFrom$1, readableStreamClose: readableStreamClose$1, fullyReadBody: fullyReadBody$1, extractMimeType: extractMimeType$1 } = require_util$4();
9484
9496
  const { FormData: FormData$3, setFormDataState } = require_formdata();
9485
9497
  const { webidl: webidl$12 } = require_webidl();
9486
- const assert$27 = __require$2("node:assert");
9498
+ const assert$26 = __require$2("node:assert");
9487
9499
  const { isErrored: isErrored$1, isDisturbed: isDisturbed$2 } = __require$2("node:stream");
9488
9500
  const { isUint8Array } = __require$2("node:util/types");
9489
9501
  const { serializeAMimeType: serializeAMimeType$2 } = require_data_url();
@@ -9521,7 +9533,7 @@ var require_body = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undi
9521
9533
  cancel() {},
9522
9534
  type: "bytes"
9523
9535
  });
9524
- assert$27(webidl$12.is.ReadableStream(stream$2));
9536
+ assert$26(webidl$12.is.ReadableStream(stream$2));
9525
9537
  let action = null;
9526
9538
  let source = null;
9527
9539
  let length = null;
@@ -9610,8 +9622,8 @@ Content-Type: ${value.type || "application/octet-stream"}\r\n\r\n`);
9610
9622
  */
9611
9623
  function safelyExtractBody$1(object$2, keepalive = false) {
9612
9624
  if (webidl$12.is.ReadableStream(object$2)) {
9613
- assert$27(!util$22.isDisturbed(object$2), "The body has already been consumed.");
9614
- assert$27(!object$2.locked, "The stream is locked.");
9625
+ assert$26(!util$22.isDisturbed(object$2), "The body has already been consumed.");
9626
+ assert$26(!object$2.locked, "The stream is locked.");
9615
9627
  }
9616
9628
  return extractBody$5(object$2, keepalive);
9617
9629
  }
@@ -9738,7 +9750,7 @@ Content-Type: ${value.type || "application/octet-stream"}\r\n\r\n`);
9738
9750
  //#endregion
9739
9751
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h1.js
9740
9752
  var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h1.js": ((exports, module) => {
9741
- const assert$26 = __require$2("node:assert");
9753
+ const assert$25 = __require$2("node:assert");
9742
9754
  const util$21 = require_util$5();
9743
9755
  const { channels: channels$5 } = require_diagnostics();
9744
9756
  const timers = require_timers();
@@ -9767,35 +9779,35 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
9767
9779
  return 0;
9768
9780
  },
9769
9781
  wasm_on_status: (p$2, at$1, len) => {
9770
- assert$26(currentParser.ptr === p$2);
9782
+ assert$25(currentParser.ptr === p$2);
9771
9783
  const start = at$1 - currentBufferPtr + currentBufferRef.byteOffset;
9772
9784
  return currentParser.onStatus(new FastBuffer(currentBufferRef.buffer, start, len));
9773
9785
  },
9774
9786
  wasm_on_message_begin: (p$2) => {
9775
- assert$26(currentParser.ptr === p$2);
9787
+ assert$25(currentParser.ptr === p$2);
9776
9788
  return currentParser.onMessageBegin();
9777
9789
  },
9778
9790
  wasm_on_header_field: (p$2, at$1, len) => {
9779
- assert$26(currentParser.ptr === p$2);
9791
+ assert$25(currentParser.ptr === p$2);
9780
9792
  const start = at$1 - currentBufferPtr + currentBufferRef.byteOffset;
9781
9793
  return currentParser.onHeaderField(new FastBuffer(currentBufferRef.buffer, start, len));
9782
9794
  },
9783
9795
  wasm_on_header_value: (p$2, at$1, len) => {
9784
- assert$26(currentParser.ptr === p$2);
9796
+ assert$25(currentParser.ptr === p$2);
9785
9797
  const start = at$1 - currentBufferPtr + currentBufferRef.byteOffset;
9786
9798
  return currentParser.onHeaderValue(new FastBuffer(currentBufferRef.buffer, start, len));
9787
9799
  },
9788
9800
  wasm_on_headers_complete: (p$2, statusCode, upgrade$1, shouldKeepAlive) => {
9789
- assert$26(currentParser.ptr === p$2);
9801
+ assert$25(currentParser.ptr === p$2);
9790
9802
  return currentParser.onHeadersComplete(statusCode, upgrade$1 === 1, shouldKeepAlive === 1);
9791
9803
  },
9792
9804
  wasm_on_body: (p$2, at$1, len) => {
9793
- assert$26(currentParser.ptr === p$2);
9805
+ assert$25(currentParser.ptr === p$2);
9794
9806
  const start = at$1 - currentBufferPtr + currentBufferRef.byteOffset;
9795
9807
  return currentParser.onBody(new FastBuffer(currentBufferRef.buffer, start, len));
9796
9808
  },
9797
9809
  wasm_on_message_complete: (p$2) => {
9798
- assert$26(currentParser.ptr === p$2);
9810
+ assert$25(currentParser.ptr === p$2);
9799
9811
  return currentParser.onMessageComplete();
9800
9812
  }
9801
9813
  } });
@@ -9868,10 +9880,10 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
9868
9880
  }
9869
9881
  resume() {
9870
9882
  if (this.socket.destroyed || !this.paused) return;
9871
- assert$26(this.ptr != null);
9872
- assert$26(currentParser === null);
9883
+ assert$25(this.ptr != null);
9884
+ assert$25(currentParser === null);
9873
9885
  this.llhttp.llhttp_resume(this.ptr);
9874
- assert$26(this.timeoutType === TIMEOUT_BODY);
9886
+ assert$25(this.timeoutType === TIMEOUT_BODY);
9875
9887
  if (this.timeout) {
9876
9888
  if (this.timeout.refresh) this.timeout.refresh();
9877
9889
  }
@@ -9890,9 +9902,9 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
9890
9902
  * @param {Buffer} chunk
9891
9903
  */
9892
9904
  execute(chunk) {
9893
- assert$26(currentParser === null);
9894
- assert$26(this.ptr != null);
9895
- assert$26(!this.paused);
9905
+ assert$25(currentParser === null);
9906
+ assert$25(this.ptr != null);
9907
+ assert$25(!this.paused);
9896
9908
  const { socket, llhttp } = this;
9897
9909
  if (chunk.length > currentBufferSize) {
9898
9910
  if (currentBufferPtr) llhttp.free(currentBufferPtr);
@@ -9923,9 +9935,9 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
9923
9935
  }
9924
9936
  }
9925
9937
  finish() {
9926
- assert$26(currentParser === null);
9927
- assert$26(this.ptr != null);
9928
- assert$26(!this.paused);
9938
+ assert$25(currentParser === null);
9939
+ assert$25(this.ptr != null);
9940
+ assert$25(!this.paused);
9929
9941
  const { llhttp } = this;
9930
9942
  let ret;
9931
9943
  try {
@@ -9953,8 +9965,8 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
9953
9965
  return new HTTPParserError(message, constants$6.ERROR[ret], data$1);
9954
9966
  }
9955
9967
  destroy() {
9956
- assert$26(currentParser === null);
9957
- assert$26(this.ptr != null);
9968
+ assert$25(currentParser === null);
9969
+ assert$25(this.ptr != null);
9958
9970
  this.llhttp.llhttp_free(this.ptr);
9959
9971
  this.ptr = null;
9960
9972
  this.timeout && timers.clearTimeout(this.timeout);
@@ -10028,14 +10040,14 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10028
10040
  */
10029
10041
  onUpgrade(head) {
10030
10042
  const { upgrade: upgrade$1, client, socket, headers, statusCode } = this;
10031
- assert$26(upgrade$1);
10032
- assert$26(client[kSocket$1] === socket);
10033
- assert$26(!socket.destroyed);
10034
- assert$26(!this.paused);
10035
- assert$26((headers.length & 1) === 0);
10043
+ assert$25(upgrade$1);
10044
+ assert$25(client[kSocket$1] === socket);
10045
+ assert$25(!socket.destroyed);
10046
+ assert$25(!this.paused);
10047
+ assert$25((headers.length & 1) === 0);
10036
10048
  const request$2 = client[kQueue$3][client[kRunningIdx$2]];
10037
- assert$26(request$2);
10038
- assert$26(request$2.upgrade || request$2.method === "CONNECT");
10049
+ assert$25(request$2);
10050
+ assert$25(request$2.upgrade || request$2.method === "CONNECT");
10039
10051
  this.statusCode = 0;
10040
10052
  this.statusText = "";
10041
10053
  this.shouldKeepAlive = false;
@@ -10073,8 +10085,8 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10073
10085
  }
10074
10086
  const request$2 = client[kQueue$3][client[kRunningIdx$2]];
10075
10087
  if (!request$2) return -1;
10076
- assert$26(!this.upgrade);
10077
- assert$26(this.statusCode < 200);
10088
+ assert$25(!this.upgrade);
10089
+ assert$25(this.statusCode < 200);
10078
10090
  if (statusCode === 100) {
10079
10091
  util$21.destroy(socket, new SocketError$3("bad response", util$21.getSocketInfo(socket)));
10080
10092
  return -1;
@@ -10083,7 +10095,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10083
10095
  util$21.destroy(socket, new SocketError$3("bad upgrade", util$21.getSocketInfo(socket)));
10084
10096
  return -1;
10085
10097
  }
10086
- assert$26(this.timeoutType === TIMEOUT_HEADERS);
10098
+ assert$25(this.timeoutType === TIMEOUT_HEADERS);
10087
10099
  this.statusCode = statusCode;
10088
10100
  this.shouldKeepAlive = shouldKeepAlive || request$2.method === "HEAD" && !socket[kReset$1] && this.connection.toLowerCase() === "keep-alive";
10089
10101
  if (this.statusCode >= 200) {
@@ -10093,16 +10105,16 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10093
10105
  if (this.timeout.refresh) this.timeout.refresh();
10094
10106
  }
10095
10107
  if (request$2.method === "CONNECT") {
10096
- assert$26(client[kRunning$4] === 1);
10108
+ assert$25(client[kRunning$4] === 1);
10097
10109
  this.upgrade = true;
10098
10110
  return 2;
10099
10111
  }
10100
10112
  if (upgrade$1) {
10101
- assert$26(client[kRunning$4] === 1);
10113
+ assert$25(client[kRunning$4] === 1);
10102
10114
  this.upgrade = true;
10103
10115
  return 2;
10104
10116
  }
10105
- assert$26((this.headers.length & 1) === 0);
10117
+ assert$25((this.headers.length & 1) === 0);
10106
10118
  this.headers = [];
10107
10119
  this.headersSize = 0;
10108
10120
  if (this.shouldKeepAlive && client[kPipelining$1]) {
@@ -10131,12 +10143,12 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10131
10143
  const { client, socket, statusCode, maxResponseSize } = this;
10132
10144
  if (socket.destroyed) return -1;
10133
10145
  const request$2 = client[kQueue$3][client[kRunningIdx$2]];
10134
- assert$26(request$2);
10135
- assert$26(this.timeoutType === TIMEOUT_BODY);
10146
+ assert$25(request$2);
10147
+ assert$25(this.timeoutType === TIMEOUT_BODY);
10136
10148
  if (this.timeout) {
10137
10149
  if (this.timeout.refresh) this.timeout.refresh();
10138
10150
  }
10139
- assert$26(statusCode >= 200);
10151
+ assert$25(statusCode >= 200);
10140
10152
  if (maxResponseSize > -1 && this.bytesRead + buf.length > maxResponseSize) {
10141
10153
  util$21.destroy(socket, new ResponseExceededMaxSizeError());
10142
10154
  return -1;
@@ -10152,10 +10164,10 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10152
10164
  const { client, socket, statusCode, upgrade: upgrade$1, headers, contentLength, bytesRead, shouldKeepAlive } = this;
10153
10165
  if (socket.destroyed && (!statusCode || shouldKeepAlive)) return -1;
10154
10166
  if (upgrade$1) return 0;
10155
- assert$26(statusCode >= 100);
10156
- assert$26((this.headers.length & 1) === 0);
10167
+ assert$25(statusCode >= 100);
10168
+ assert$25((this.headers.length & 1) === 0);
10157
10169
  const request$2 = client[kQueue$3][client[kRunningIdx$2]];
10158
- assert$26(request$2);
10170
+ assert$25(request$2);
10159
10171
  this.statusCode = 0;
10160
10172
  this.statusText = "";
10161
10173
  this.bytesRead = 0;
@@ -10173,7 +10185,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10173
10185
  client[kQueue$3][client[kRunningIdx$2]++] = null;
10174
10186
  socket[kSocketUsed] = client[kPending$3] === 0;
10175
10187
  if (socket[kWriting]) {
10176
- assert$26(client[kRunning$4] === 0);
10188
+ assert$25(client[kRunning$4] === 0);
10177
10189
  util$21.destroy(socket, new InformationalError$3("reset"));
10178
10190
  return constants$6.ERROR.PAUSED;
10179
10191
  } else if (!shouldKeepAlive) {
@@ -10193,13 +10205,13 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10193
10205
  const { socket, timeoutType, client, paused } = parser;
10194
10206
  if (timeoutType === TIMEOUT_HEADERS) {
10195
10207
  if (!socket[kWriting] || socket.writableNeedDrain || client[kRunning$4] > 1) {
10196
- assert$26(!paused, "cannot be paused while waiting for headers");
10208
+ assert$25(!paused, "cannot be paused while waiting for headers");
10197
10209
  util$21.destroy(socket, new HeadersTimeoutError());
10198
10210
  }
10199
10211
  } else if (timeoutType === TIMEOUT_BODY) {
10200
10212
  if (!paused) util$21.destroy(socket, new BodyTimeoutError());
10201
10213
  } else if (timeoutType === TIMEOUT_KEEP_ALIVE) {
10202
- assert$26(client[kRunning$4] === 0 && client[kKeepAliveTimeoutValue$1]);
10214
+ assert$25(client[kRunning$4] === 0 && client[kKeepAliveTimeoutValue$1]);
10203
10215
  util$21.destroy(socket, new InformationalError$3("socket idle timeout"));
10204
10216
  }
10205
10217
  }
@@ -10258,7 +10270,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10258
10270
  };
10259
10271
  }
10260
10272
  function onHttpSocketError(err) {
10261
- assert$26(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10273
+ assert$25(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10262
10274
  const parser = this[kParser];
10263
10275
  if (err.code === "ECONNRESET" && parser.statusCode && !parser.shouldKeepAlive) {
10264
10276
  const parserErr = parser.finish();
@@ -10296,7 +10308,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10296
10308
  client[kSocket$1] = null;
10297
10309
  client[kHTTPContext$2] = null;
10298
10310
  if (client.destroyed) {
10299
- assert$26(client[kPending$3] === 0);
10311
+ assert$25(client[kPending$3] === 0);
10300
10312
  const requests = client[kQueue$3].splice(client[kRunningIdx$2]);
10301
10313
  for (let i$1 = 0; i$1 < requests.length; i$1++) {
10302
10314
  const request$2 = requests[i$1];
@@ -10308,7 +10320,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10308
10320
  util$21.errorRequest(client, request$2, err);
10309
10321
  }
10310
10322
  client[kPendingIdx$2] = client[kRunningIdx$2];
10311
- assert$26(client[kRunning$4] === 0);
10323
+ assert$25(client[kRunning$4] === 0);
10312
10324
  client.emit("disconnect", client[kUrl$7], [client], err);
10313
10325
  client[kResume$3]();
10314
10326
  }
@@ -10462,7 +10474,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10462
10474
  else writeBlob$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload);
10463
10475
  else if (util$21.isStream(body)) writeStream$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload);
10464
10476
  else if (util$21.isIterable(body)) writeIterable$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload);
10465
- else assert$26(false);
10477
+ else assert$25(false);
10466
10478
  return true;
10467
10479
  }
10468
10480
  /**
@@ -10476,7 +10488,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10476
10488
  * @param {boolean} expectsPayload
10477
10489
  */
10478
10490
  function writeStream$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload) {
10479
- assert$26(contentLength !== 0 || client[kRunning$4] === 0, "stream body cannot be pipelined");
10491
+ assert$25(contentLength !== 0 || client[kRunning$4] === 0, "stream body cannot be pipelined");
10480
10492
  let finished$2 = false;
10481
10493
  const writer = new AsyncWriter({
10482
10494
  abort: abort$1,
@@ -10525,7 +10537,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10525
10537
  const onFinished = function(err) {
10526
10538
  if (finished$2) return;
10527
10539
  finished$2 = true;
10528
- assert$26(socket.destroyed || socket[kWriting] && client[kRunning$4] <= 1);
10540
+ assert$25(socket.destroyed || socket[kWriting] && client[kRunning$4] <= 1);
10529
10541
  socket.off("drain", onDrain).off("error", onFinished);
10530
10542
  body.removeListener("data", onData).removeListener("end", onFinished).removeListener("close", onClose);
10531
10543
  if (!err) try {
@@ -10565,11 +10577,11 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10565
10577
  try {
10566
10578
  if (!body) if (contentLength === 0) socket.write(`${header}content-length: 0\r\n\r\n`, "latin1");
10567
10579
  else {
10568
- assert$26(contentLength === null, "no body must not have content length");
10580
+ assert$25(contentLength === null, "no body must not have content length");
10569
10581
  socket.write(`${header}\r\n`, "latin1");
10570
10582
  }
10571
10583
  else if (util$21.isBuffer(body)) {
10572
- assert$26(contentLength === body.byteLength, "buffer body must have content length");
10584
+ assert$25(contentLength === body.byteLength, "buffer body must have content length");
10573
10585
  socket.cork();
10574
10586
  socket.write(`${header}content-length: ${contentLength}\r\n\r\n`, "latin1");
10575
10587
  socket.write(body);
@@ -10595,7 +10607,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10595
10607
  * @returns {Promise<void>}
10596
10608
  */
10597
10609
  async function writeBlob$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload) {
10598
- assert$26(contentLength === body.size, "blob body must have content length");
10610
+ assert$25(contentLength === body.size, "blob body must have content length");
10599
10611
  try {
10600
10612
  if (contentLength != null && contentLength !== body.size) throw new RequestContentLengthMismatchError$1();
10601
10613
  const buffer$1 = Buffer.from(await body.arrayBuffer());
@@ -10623,7 +10635,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10623
10635
  * @returns {Promise<void>}
10624
10636
  */
10625
10637
  async function writeIterable$1(abort$1, body, client, request$2, socket, contentLength, header, expectsPayload) {
10626
- assert$26(contentLength !== 0 || client[kRunning$4] === 0, "iterator body cannot be pipelined");
10638
+ assert$25(contentLength !== 0 || client[kRunning$4] === 0, "iterator body cannot be pipelined");
10627
10639
  let callback$1 = null;
10628
10640
  function onDrain() {
10629
10641
  if (callback$1) {
@@ -10633,7 +10645,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10633
10645
  }
10634
10646
  }
10635
10647
  const waitForDrain = () => new Promise((resolve$4, reject) => {
10636
- assert$26(callback$1 === null);
10648
+ assert$25(callback$1 === null);
10637
10649
  if (socket[kError$2]) reject(socket[kError$2]);
10638
10650
  else callback$1 = resolve$4;
10639
10651
  });
@@ -10741,7 +10753,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10741
10753
  const { socket, client, abort: abort$1 } = this;
10742
10754
  socket[kWriting] = false;
10743
10755
  if (err) {
10744
- assert$26(client[kRunning$4] <= 1, "pipeline should only contain this request");
10756
+ assert$25(client[kRunning$4] <= 1, "pipeline should only contain this request");
10745
10757
  abort$1(err);
10746
10758
  }
10747
10759
  }
@@ -10752,7 +10764,7 @@ var require_client_h1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10752
10764
  //#endregion
10753
10765
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h2.js
10754
10766
  var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client-h2.js": ((exports, module) => {
10755
- const assert$25 = __require$2("node:assert");
10767
+ const assert$24 = __require$2("node:assert");
10756
10768
  const { pipeline: pipeline$4 } = __require$2("node:stream");
10757
10769
  const util$20 = require_util$5();
10758
10770
  const { RequestContentLengthMismatchError, RequestAbortedError: RequestAbortedError$7, SocketError: SocketError$2, InformationalError: InformationalError$2, InvalidArgumentError: InvalidArgumentError$30 } = require_errors();
@@ -10885,7 +10897,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10885
10897
  }
10886
10898
  }
10887
10899
  function onHttp2SessionError(err) {
10888
- assert$25(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10900
+ assert$24(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10889
10901
  this[kSocket][kError$1] = err;
10890
10902
  this[kClient$2][kOnError$1](err);
10891
10903
  }
@@ -10923,7 +10935,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10923
10935
  util$20.errorRequest(client, request$2, err);
10924
10936
  client[kPendingIdx$1] = client[kRunningIdx$1];
10925
10937
  }
10926
- assert$25(client[kRunning$3] === 0);
10938
+ assert$24(client[kRunning$3] === 0);
10927
10939
  client.emit("disconnect", client[kUrl$6], [client], err);
10928
10940
  client.emit("connectionError", client[kUrl$6], [client], err);
10929
10941
  client[kResume$2]();
@@ -10939,7 +10951,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10939
10951
  state.ping.interval = null;
10940
10952
  }
10941
10953
  if (client.destroyed) {
10942
- assert$25(client[kPending$2] === 0);
10954
+ assert$24(client[kPending$2] === 0);
10943
10955
  const requests = client[kQueue$2].splice(client[kRunningIdx$1]);
10944
10956
  for (let i$1 = 0; i$1 < requests.length; i$1++) {
10945
10957
  const request$2 = requests[i$1];
@@ -10954,12 +10966,12 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
10954
10966
  client[kHTTPContext$1] = null;
10955
10967
  if (this[kHTTP2Session] !== null) this[kHTTP2Session].destroy(err);
10956
10968
  client[kPendingIdx$1] = client[kRunningIdx$1];
10957
- assert$25(client[kRunning$3] === 0);
10969
+ assert$24(client[kRunning$3] === 0);
10958
10970
  client.emit("disconnect", client[kUrl$6], [client], err);
10959
10971
  client[kResume$2]();
10960
10972
  }
10961
10973
  function onHttp2SocketError(err) {
10962
- assert$25(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10974
+ assert$24(err.code !== "ERR_TLS_CERT_ALTNAME_INVALID");
10963
10975
  this[kError$1] = err;
10964
10976
  this[kClient$2][kOnError$1](err);
10965
10977
  }
@@ -11092,7 +11104,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11092
11104
  process.emitWarning(new RequestContentLengthMismatchError());
11093
11105
  }
11094
11106
  if (contentLength != null) {
11095
- assert$25(body || contentLength === 0, "no body must not have content length");
11107
+ assert$24(body || contentLength === 0, "no body must not have content length");
11096
11108
  headers[HTTP2_HEADER_CONTENT_LENGTH] = `${contentLength}`;
11097
11109
  }
11098
11110
  session.ref();
@@ -11188,13 +11200,13 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11188
11200
  else writeBlob(abort$1, stream$2, body, client, request$2, client[kSocket], contentLength, expectsPayload);
11189
11201
  else if (util$20.isStream(body)) writeStream(abort$1, client[kSocket], expectsPayload, stream$2, body, client, request$2, contentLength);
11190
11202
  else if (util$20.isIterable(body)) writeIterable(abort$1, stream$2, body, client, request$2, client[kSocket], contentLength, expectsPayload);
11191
- else assert$25(false);
11203
+ else assert$24(false);
11192
11204
  }
11193
11205
  }
11194
11206
  function writeBuffer(abort$1, h2stream, body, client, request$2, socket, contentLength, expectsPayload) {
11195
11207
  try {
11196
11208
  if (body != null && util$20.isBuffer(body)) {
11197
- assert$25(contentLength === body.byteLength, "buffer body must have content length");
11209
+ assert$24(contentLength === body.byteLength, "buffer body must have content length");
11198
11210
  h2stream.cork();
11199
11211
  h2stream.write(body);
11200
11212
  h2stream.uncork();
@@ -11209,7 +11221,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11209
11221
  }
11210
11222
  }
11211
11223
  function writeStream(abort$1, socket, expectsPayload, h2stream, body, client, request$2, contentLength) {
11212
- assert$25(contentLength !== 0 || client[kRunning$3] === 0, "stream body cannot be pipelined");
11224
+ assert$24(contentLength !== 0 || client[kRunning$3] === 0, "stream body cannot be pipelined");
11213
11225
  const pipe$2 = pipeline$4(body, h2stream, (err) => {
11214
11226
  if (err) {
11215
11227
  util$20.destroy(pipe$2, err);
@@ -11227,7 +11239,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11227
11239
  }
11228
11240
  }
11229
11241
  async function writeBlob(abort$1, h2stream, body, client, request$2, socket, contentLength, expectsPayload) {
11230
- assert$25(contentLength === body.size, "blob body must have content length");
11242
+ assert$24(contentLength === body.size, "blob body must have content length");
11231
11243
  try {
11232
11244
  if (contentLength != null && contentLength !== body.size) throw new RequestContentLengthMismatchError();
11233
11245
  const buffer$1 = Buffer.from(await body.arrayBuffer());
@@ -11244,7 +11256,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11244
11256
  }
11245
11257
  }
11246
11258
  async function writeIterable(abort$1, h2stream, body, client, request$2, socket, contentLength, expectsPayload) {
11247
- assert$25(contentLength !== 0 || client[kRunning$3] === 0, "iterator body cannot be pipelined");
11259
+ assert$24(contentLength !== 0 || client[kRunning$3] === 0, "iterator body cannot be pipelined");
11248
11260
  let callback$1 = null;
11249
11261
  function onDrain() {
11250
11262
  if (callback$1) {
@@ -11254,7 +11266,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11254
11266
  }
11255
11267
  }
11256
11268
  const waitForDrain = () => new Promise((resolve$4, reject) => {
11257
- assert$25(callback$1 === null);
11269
+ assert$24(callback$1 === null);
11258
11270
  if (socket[kError$1]) reject(socket[kError$1]);
11259
11271
  else callback$1 = resolve$4;
11260
11272
  });
@@ -11282,7 +11294,7 @@ var require_client_h2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm
11282
11294
  //#endregion
11283
11295
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client.js
11284
11296
  var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/dispatcher/client.js": ((exports, module) => {
11285
- const assert$24 = __require$2("node:assert");
11297
+ const assert$23 = __require$2("node:assert");
11286
11298
  const net$2 = __require$2("node:net");
11287
11299
  const http$1 = __require$2("node:http");
11288
11300
  const util$19 = require_util$5();
@@ -11460,13 +11472,13 @@ var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
11460
11472
  };
11461
11473
  function onError(client, err) {
11462
11474
  if (client[kRunning$2] === 0 && err.code !== "UND_ERR_INFO" && err.code !== "UND_ERR_SOCKET") {
11463
- assert$24(client[kPendingIdx] === client[kRunningIdx]);
11475
+ assert$23(client[kPendingIdx] === client[kRunningIdx]);
11464
11476
  const requests = client[kQueue$1].splice(client[kRunningIdx]);
11465
11477
  for (let i$1 = 0; i$1 < requests.length; i$1++) {
11466
11478
  const request$2 = requests[i$1];
11467
11479
  util$19.errorRequest(client, request$2, err);
11468
11480
  }
11469
- assert$24(client[kSize$2] === 0);
11481
+ assert$23(client[kSize$2] === 0);
11470
11482
  }
11471
11483
  }
11472
11484
  /**
@@ -11474,14 +11486,14 @@ var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
11474
11486
  * @returns {void}
11475
11487
  */
11476
11488
  function connect$1(client) {
11477
- assert$24(!client[kConnecting]);
11478
- assert$24(!client[kHTTPContext]);
11489
+ assert$23(!client[kConnecting]);
11490
+ assert$23(!client[kHTTPContext]);
11479
11491
  let { host, hostname: hostname$1, protocol, port } = client[kUrl$5];
11480
11492
  if (hostname$1[0] === "[") {
11481
11493
  const idx = hostname$1.indexOf("]");
11482
- assert$24(idx !== -1);
11494
+ assert$23(idx !== -1);
11483
11495
  const ip = hostname$1.substring(1, idx);
11484
- assert$24(net$2.isIPv6(ip));
11496
+ assert$23(net$2.isIPv6(ip));
11485
11497
  hostname$1 = ip;
11486
11498
  }
11487
11499
  client[kConnecting] = true;
@@ -11521,7 +11533,7 @@ var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
11521
11533
  client[kResume$1]();
11522
11534
  return;
11523
11535
  }
11524
- assert$24(socket);
11536
+ assert$23(socket);
11525
11537
  try {
11526
11538
  client[kHTTPContext] = socket.alpnProtocol === "h2" ? connectH2(client, socket) : connectH1(client, socket);
11527
11539
  } catch (err$1) {
@@ -11583,7 +11595,7 @@ var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
11583
11595
  error: err
11584
11596
  });
11585
11597
  if (err.code === "ERR_TLS_CERT_ALTNAME_INVALID") {
11586
- assert$24(client[kRunning$2] === 0);
11598
+ assert$23(client[kRunning$2] === 0);
11587
11599
  while (client[kPending$1] > 0 && client[kQueue$1][client[kPendingIdx]].servername === client[kServerName]) {
11588
11600
  const request$2 = client[kQueue$1][client[kPendingIdx]++];
11589
11601
  util$19.errorRequest(client, request$2, err);
@@ -11609,7 +11621,7 @@ var require_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
11609
11621
  function _resume(client, sync$2) {
11610
11622
  while (true) {
11611
11623
  if (client.destroyed) {
11612
- assert$24(client[kPending$1] === 0);
11624
+ assert$23(client[kPending$1] === 0);
11613
11625
  return;
11614
11626
  }
11615
11627
  if (client[kClosedResolve$1] && !client[kSize$2]) {
@@ -13211,7 +13223,7 @@ var require_env_http_proxy_agent = /* @__PURE__ */ __commonJS$2({ "../../node_mo
13211
13223
  //#endregion
13212
13224
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/retry-handler.js
13213
13225
  var require_retry_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/retry-handler.js": ((exports, module) => {
13214
- const assert$23 = __require$2("node:assert");
13226
+ const assert$22 = __require$2("node:assert");
13215
13227
  const { kRetryHandlerDefaultRetry } = require_symbols();
13216
13228
  const { RequestRetryError } = require_errors();
13217
13229
  const WrapHandler$2 = require_wrap_handler();
@@ -13378,8 +13390,8 @@ var require_retry_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.
13378
13390
  });
13379
13391
  validatePartialResponseContentLength(headers, contentRange, statusCode, this.retryCount);
13380
13392
  const { start, size, end = size ? size - 1 : null } = contentRange;
13381
- assert$23(this.start === start, "content-range mismatch");
13382
- assert$23(this.end == null || this.end === end, "content-range mismatch");
13393
+ assert$22(this.start === start, "content-range mismatch");
13394
+ assert$22(this.end == null || this.end === end, "content-range mismatch");
13383
13395
  return;
13384
13396
  }
13385
13397
  if (this.end == null) {
@@ -13392,8 +13404,8 @@ var require_retry_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.
13392
13404
  }
13393
13405
  validatePartialResponseContentLength(headers, range, statusCode, this.retryCount);
13394
13406
  const { start, size, end = size ? size - 1 : null } = range;
13395
- assert$23(start != null && Number.isFinite(start), "content-range mismatch");
13396
- assert$23(end != null && Number.isFinite(end), "invalid content-length");
13407
+ assert$22(start != null && Number.isFinite(start), "content-range mismatch");
13408
+ assert$22(end != null && Number.isFinite(end), "invalid content-length");
13397
13409
  this.start = start;
13398
13410
  this.end = end;
13399
13411
  }
@@ -13401,8 +13413,8 @@ var require_retry_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.
13401
13413
  const contentLength = headers["content-length"];
13402
13414
  this.end = contentLength != null ? Number(contentLength) - 1 : null;
13403
13415
  }
13404
- assert$23(Number.isFinite(this.start));
13405
- assert$23(this.end == null || Number.isFinite(this.end), "invalid content-length");
13416
+ assert$22(Number.isFinite(this.start));
13417
+ assert$22(this.end == null || Number.isFinite(this.end), "invalid content-length");
13406
13418
  this.resume = true;
13407
13419
  this.etag = headers.etag != null ? headers.etag : null;
13408
13420
  if (this.etag != null && this.etag[0] === "W" && this.etag[1] === "/") this.etag = null;
@@ -13534,7 +13546,7 @@ var require_h2c_client = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnp
13534
13546
  //#endregion
13535
13547
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/readable.js
13536
13548
  var require_readable = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/readable.js": ((exports, module) => {
13537
- const assert$22 = __require$2("node:assert");
13549
+ const assert$21 = __require$2("node:assert");
13538
13550
  const { Readable: Readable$4 } = __require$2("node:stream");
13539
13551
  const { RequestAbortedError: RequestAbortedError$5, NotSupportedError, InvalidArgumentError: InvalidArgumentError$19, AbortError: AbortError$1 } = require_errors();
13540
13552
  const util$14 = require_util$5();
@@ -13730,7 +13742,7 @@ var require_readable = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
13730
13742
  this[kBody$1] = ReadableStreamFrom(this);
13731
13743
  if (this[kConsume]) {
13732
13744
  this[kBody$1].getReader();
13733
- assert$22(this[kBody$1].locked);
13745
+ assert$21(this[kBody$1].locked);
13734
13746
  }
13735
13747
  }
13736
13748
  return this[kBody$1];
@@ -13820,7 +13832,7 @@ var require_readable = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
13820
13832
  * @returns {Promise<ConsumeReturnType<T>>}
13821
13833
  */
13822
13834
  function consume(stream$2, type) {
13823
- assert$22(!stream$2[kConsume]);
13835
+ assert$21(!stream$2[kConsume]);
13824
13836
  return new Promise((resolve$4, reject) => {
13825
13837
  if (isUnusable(stream$2)) {
13826
13838
  const rState = stream$2._readableState;
@@ -13948,7 +13960,7 @@ var require_readable = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
13948
13960
  //#endregion
13949
13961
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-request.js
13950
13962
  var require_api_request = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-request.js": ((exports, module) => {
13951
- const assert$21 = __require$2("node:assert");
13963
+ const assert$20 = __require$2("node:assert");
13952
13964
  const { AsyncResource: AsyncResource$4 } = __require$2("node:async_hooks");
13953
13965
  const { Readable: Readable$3 } = require_readable();
13954
13966
  const { InvalidArgumentError: InvalidArgumentError$18, RequestAbortedError: RequestAbortedError$4 } = require_errors();
@@ -13994,7 +14006,7 @@ var require_api_request = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
13994
14006
  abort$1(this.reason);
13995
14007
  return;
13996
14008
  }
13997
- assert$21(this.callback);
14009
+ assert$20(this.callback);
13998
14010
  this.abort = abort$1;
13999
14011
  this.context = context;
14000
14012
  }
@@ -14138,7 +14150,7 @@ var require_abort_signal = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.p
14138
14150
  //#endregion
14139
14151
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-stream.js
14140
14152
  var require_api_stream = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-stream.js": ((exports, module) => {
14141
- const assert$20 = __require$2("node:assert");
14153
+ const assert$19 = __require$2("node:assert");
14142
14154
  const { finished: finished$1 } = __require$2("node:stream");
14143
14155
  const { AsyncResource: AsyncResource$3 } = __require$2("node:async_hooks");
14144
14156
  const { InvalidArgumentError: InvalidArgumentError$17, InvalidReturnValueError: InvalidReturnValueError$1 } = require_errors();
@@ -14180,7 +14192,7 @@ var require_api_stream = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnp
14180
14192
  abort$1(this.reason);
14181
14193
  return;
14182
14194
  }
14183
- assert$20(this.callback);
14195
+ assert$19(this.callback);
14184
14196
  this.abort = abort$1;
14185
14197
  this.context = context;
14186
14198
  }
@@ -14270,7 +14282,7 @@ var require_api_stream = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnp
14270
14282
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-pipeline.js
14271
14283
  var require_api_pipeline = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-pipeline.js": ((exports, module) => {
14272
14284
  const { Readable: Readable$2, Duplex, PassThrough } = __require$2("node:stream");
14273
- const assert$19 = __require$2("node:assert");
14285
+ const assert$18 = __require$2("node:assert");
14274
14286
  const { AsyncResource: AsyncResource$2 } = __require$2("node:async_hooks");
14275
14287
  const { InvalidArgumentError: InvalidArgumentError$16, InvalidReturnValueError, RequestAbortedError: RequestAbortedError$2 } = require_errors();
14276
14288
  const util$11 = require_util$5();
@@ -14358,7 +14370,7 @@ var require_api_pipeline = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.p
14358
14370
  abort$1(this.reason);
14359
14371
  return;
14360
14372
  }
14361
- assert$19(!res, "pipeline cannot be retried");
14373
+ assert$18(!res, "pipeline cannot be retried");
14362
14374
  this.abort = abort$1;
14363
14375
  this.context = context;
14364
14376
  }
@@ -14440,7 +14452,7 @@ var require_api_pipeline = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.p
14440
14452
  var require_api_upgrade = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-upgrade.js": ((exports, module) => {
14441
14453
  const { InvalidArgumentError: InvalidArgumentError$15, SocketError: SocketError$1 } = require_errors();
14442
14454
  const { AsyncResource: AsyncResource$1 } = __require$2("node:async_hooks");
14443
- const assert$18 = __require$2("node:assert");
14455
+ const assert$17 = __require$2("node:assert");
14444
14456
  const util$10 = require_util$5();
14445
14457
  const { kHTTP2Stream } = require_symbols();
14446
14458
  const { addSignal: addSignal$1, removeSignal: removeSignal$1 } = require_abort_signal();
@@ -14463,7 +14475,7 @@ var require_api_upgrade = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
14463
14475
  abort$1(this.reason);
14464
14476
  return;
14465
14477
  }
14466
- assert$18(this.callback);
14478
+ assert$17(this.callback);
14467
14479
  this.abort = abort$1;
14468
14480
  this.context = null;
14469
14481
  }
@@ -14471,7 +14483,7 @@ var require_api_upgrade = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
14471
14483
  throw new SocketError$1("bad upgrade", null);
14472
14484
  }
14473
14485
  onUpgrade(statusCode, rawHeaders, socket) {
14474
- assert$18(socket[kHTTP2Stream] === true ? statusCode === 200 : statusCode === 101);
14486
+ assert$17(socket[kHTTP2Stream] === true ? statusCode === 200 : statusCode === 101);
14475
14487
  const { callback: callback$1, opaque, context } = this;
14476
14488
  removeSignal$1(this);
14477
14489
  this.callback = null;
@@ -14520,7 +14532,7 @@ var require_api_upgrade = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
14520
14532
  //#endregion
14521
14533
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-connect.js
14522
14534
  var require_api_connect = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/api/api-connect.js": ((exports, module) => {
14523
- const assert$17 = __require$2("node:assert");
14535
+ const assert$16 = __require$2("node:assert");
14524
14536
  const { AsyncResource } = __require$2("node:async_hooks");
14525
14537
  const { InvalidArgumentError: InvalidArgumentError$14, SocketError } = require_errors();
14526
14538
  const util$9 = require_util$5();
@@ -14543,7 +14555,7 @@ var require_api_connect = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
14543
14555
  abort$1(this.reason);
14544
14556
  return;
14545
14557
  }
14546
- assert$17(this.callback);
14558
+ assert$16(this.callback);
14547
14559
  this.abort = abort$1;
14548
14560
  this.context = context;
14549
14561
  }
@@ -16380,7 +16392,7 @@ var require_global = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
16380
16392
  //#endregion
16381
16393
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/decorator-handler.js
16382
16394
  var require_decorator_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/decorator-handler.js": ((exports, module) => {
16383
- const assert$16 = __require$2("node:assert");
16395
+ const assert$15 = __require$2("node:assert");
16384
16396
  const WrapHandler = require_wrap_handler();
16385
16397
  /**
16386
16398
  * @deprecated
@@ -16398,25 +16410,25 @@ var require_decorator_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modul
16398
16410
  this.#handler.onRequestStart?.(...args);
16399
16411
  }
16400
16412
  onRequestUpgrade(...args) {
16401
- assert$16(!this.#onCompleteCalled);
16402
- assert$16(!this.#onErrorCalled);
16413
+ assert$15(!this.#onCompleteCalled);
16414
+ assert$15(!this.#onErrorCalled);
16403
16415
  return this.#handler.onRequestUpgrade?.(...args);
16404
16416
  }
16405
16417
  onResponseStart(...args) {
16406
- assert$16(!this.#onCompleteCalled);
16407
- assert$16(!this.#onErrorCalled);
16408
- assert$16(!this.#onResponseStartCalled);
16418
+ assert$15(!this.#onCompleteCalled);
16419
+ assert$15(!this.#onErrorCalled);
16420
+ assert$15(!this.#onResponseStartCalled);
16409
16421
  this.#onResponseStartCalled = true;
16410
16422
  return this.#handler.onResponseStart?.(...args);
16411
16423
  }
16412
16424
  onResponseData(...args) {
16413
- assert$16(!this.#onCompleteCalled);
16414
- assert$16(!this.#onErrorCalled);
16425
+ assert$15(!this.#onCompleteCalled);
16426
+ assert$15(!this.#onErrorCalled);
16415
16427
  return this.#handler.onResponseData?.(...args);
16416
16428
  }
16417
16429
  onResponseEnd(...args) {
16418
- assert$16(!this.#onCompleteCalled);
16419
- assert$16(!this.#onErrorCalled);
16430
+ assert$15(!this.#onCompleteCalled);
16431
+ assert$15(!this.#onErrorCalled);
16420
16432
  this.#onCompleteCalled = true;
16421
16433
  return this.#handler.onResponseEnd?.(...args);
16422
16434
  }
@@ -16436,7 +16448,7 @@ var require_decorator_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modul
16436
16448
  var require_redirect_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/redirect-handler.js": ((exports, module) => {
16437
16449
  const util$8 = require_util$5();
16438
16450
  const { kBodyUsed } = require_symbols();
16439
- const assert$15 = __require$2("node:assert");
16451
+ const assert$14 = __require$2("node:assert");
16440
16452
  const { InvalidArgumentError: InvalidArgumentError$3 } = require_errors();
16441
16453
  const EE$2 = __require$2("node:events");
16442
16454
  const redirectableStatusCodes = [
@@ -16455,7 +16467,7 @@ var require_redirect_handler = /* @__PURE__ */ __commonJS$2({ "../../node_module
16455
16467
  this[kBodyUsed] = false;
16456
16468
  }
16457
16469
  async *[Symbol.asyncIterator]() {
16458
- assert$15(!this[kBodyUsed], "disturbed");
16470
+ assert$14(!this[kBodyUsed], "disturbed");
16459
16471
  this[kBodyUsed] = true;
16460
16472
  yield* this[kBody];
16461
16473
  }
@@ -16477,7 +16489,7 @@ var require_redirect_handler = /* @__PURE__ */ __commonJS$2({ "../../node_module
16477
16489
  this.history = [];
16478
16490
  if (util$8.isStream(this.opts.body)) {
16479
16491
  if (util$8.bodyLength(this.opts.body) === 0) this.opts.body.on("data", function() {
16480
- assert$15(false);
16492
+ assert$14(false);
16481
16493
  });
16482
16494
  if (typeof this.opts.body.readableDidRead !== "boolean") {
16483
16495
  this.opts.body[kBodyUsed] = false;
@@ -16551,7 +16563,7 @@ var require_redirect_handler = /* @__PURE__ */ __commonJS$2({ "../../node_module
16551
16563
  } else if (headers && typeof headers === "object") {
16552
16564
  const entries = util$8.hasSafeIterator(headers) ? headers : Object.entries(headers);
16553
16565
  for (const [key, value] of entries) if (!shouldRemoveHeader(key, removeContent, unknownOrigin)) ret.push(key, value);
16554
- } else assert$15(headers == null, "headers must be an object or an array");
16566
+ } else assert$14(headers == null, "headers must be an object or an array");
16555
16567
  return ret;
16556
16568
  }
16557
16569
  module.exports = RedirectHandler$2;
@@ -18444,7 +18456,7 @@ var require_memory_cache_store = /* @__PURE__ */ __commonJS$2({ "../../node_modu
18444
18456
  //#endregion
18445
18457
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/cache-revalidation-handler.js
18446
18458
  var require_cache_revalidation_handler = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/handler/cache-revalidation-handler.js": ((exports, module) => {
18447
- const assert$14 = __require$2("node:assert");
18459
+ const assert$13 = __require$2("node:assert");
18448
18460
  /**
18449
18461
  * This takes care of revalidation requests we send to the origin. If we get
18450
18462
  * a response indicating that what we have is cached (via a HTTP 304), we can
@@ -18492,7 +18504,7 @@ var require_cache_revalidation_handler = /* @__PURE__ */ __commonJS$2({ "../../n
18492
18504
  this.#handler.onRequestUpgrade?.(controller, statusCode, headers, socket);
18493
18505
  }
18494
18506
  onResponseStart(controller, statusCode, headers, statusMessage) {
18495
- assert$14(this.#callback != null);
18507
+ assert$13(this.#callback != null);
18496
18508
  this.#successful = statusCode === 304 || this.#allowErrorStatusCodes && statusCode >= 500 && statusCode <= 504;
18497
18509
  this.#callback(this.#successful, this.#context, statusCode, headers);
18498
18510
  this.#callback = null;
@@ -18524,7 +18536,7 @@ var require_cache_revalidation_handler = /* @__PURE__ */ __commonJS$2({ "../../n
18524
18536
  //#endregion
18525
18537
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/interceptor/cache.js
18526
18538
  var require_cache$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/interceptor/cache.js": ((exports, module) => {
18527
- const assert$13 = __require$2("node:assert");
18539
+ const assert$12 = __require$2("node:assert");
18528
18540
  const { Readable: Readable$1 } = __require$2("node:stream");
18529
18541
  const util$6 = require_util$5();
18530
18542
  const CacheHandler = require_cache_handler();
@@ -18689,8 +18701,8 @@ var require_cache$1 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
18689
18701
  */
18690
18702
  function sendCachedValue(handler, opts, result, age, context, isStale$1) {
18691
18703
  const stream$2 = util$6.isStream(result.body) ? result.body : Readable$1.from(result.body ?? []);
18692
- assert$13(!stream$2.destroyed, "stream should not be destroyed");
18693
- assert$13(!stream$2.readableDidRead, "stream should not be readableDidRead");
18704
+ assert$12(!stream$2.destroyed, "stream should not be destroyed");
18705
+ assert$12(!stream$2.readableDidRead, "stream should not be readableDidRead");
18694
18706
  const controller = {
18695
18707
  resume() {
18696
18708
  stream$2.resume();
@@ -19786,7 +19798,7 @@ var require_headers = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
19786
19798
  const { kEnumerableProperty: kEnumerableProperty$9 } = require_util$5();
19787
19799
  const { iteratorMixin, isValidHeaderName: isValidHeaderName$1, isValidHeaderValue } = require_util$4();
19788
19800
  const { webidl: webidl$11 } = require_webidl();
19789
- const assert$12 = __require$2("node:assert");
19801
+ const assert$11 = __require$2("node:assert");
19790
19802
  const util$4 = __require$2("node:util");
19791
19803
  /**
19792
19804
  * @param {number} code
@@ -19981,11 +19993,11 @@ var require_headers = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
19981
19993
  const iterator = this.headersMap[Symbol.iterator]();
19982
19994
  const firstValue = iterator.next().value;
19983
19995
  array$2[0] = [firstValue[0], firstValue[1].value];
19984
- assert$12(firstValue[1].value !== null);
19996
+ assert$11(firstValue[1].value !== null);
19985
19997
  for (let i$1 = 1, j$1 = 0, right = 0, left = 0, pivot = 0, x, value; i$1 < size; ++i$1) {
19986
19998
  value = iterator.next().value;
19987
19999
  x = array$2[i$1] = [value[0], value[1].value];
19988
- assert$12(x[1] !== null);
20000
+ assert$11(x[1] !== null);
19989
20001
  left = 0;
19990
20002
  right = i$1;
19991
20003
  while (left < right) {
@@ -20006,7 +20018,7 @@ var require_headers = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
20006
20018
  let i$1 = 0;
20007
20019
  for (const { 0: name, 1: { value } } of this.headersMap) {
20008
20020
  array$2[i$1++] = [name, value];
20009
- assert$12(value !== null);
20021
+ assert$11(value !== null);
20010
20022
  }
20011
20023
  return array$2.sort(compareHeaderName);
20012
20024
  }
@@ -20186,7 +20198,7 @@ var require_response = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
20186
20198
  const { webidl: webidl$10 } = require_webidl();
20187
20199
  const { URLSerializer: URLSerializer$3 } = require_data_url();
20188
20200
  const { kConstruct: kConstruct$6 } = require_symbols();
20189
- const assert$11 = __require$2("node:assert");
20201
+ const assert$10 = __require$2("node:assert");
20190
20202
  const { isomorphicEncode: isomorphicEncode$1, serializeJavascriptValueToJSONString } = require_infra();
20191
20203
  const textEncoder = new TextEncoder("utf-8");
20192
20204
  var Response$3 = class Response$3 {
@@ -20408,7 +20420,7 @@ var require_response = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
20408
20420
  return p$2 in state ? state[p$2] : target$1[p$2];
20409
20421
  },
20410
20422
  set(target$1, p$2, value) {
20411
- assert$11(!(p$2 in state));
20423
+ assert$10(!(p$2 in state));
20412
20424
  target$1[p$2] = value;
20413
20425
  return true;
20414
20426
  }
@@ -20437,10 +20449,10 @@ var require_response = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
20437
20449
  headersList: [],
20438
20450
  body: null
20439
20451
  });
20440
- else assert$11(false);
20452
+ else assert$10(false);
20441
20453
  }
20442
20454
  function makeAppropriateNetworkError$1(fetchParams, err = null) {
20443
- assert$11(isCancelled$1(fetchParams));
20455
+ assert$10(isCancelled$1(fetchParams));
20444
20456
  return isAborted$1(fetchParams) ? makeNetworkError$1(Object.assign(new DOMException("The operation was aborted.", "AbortError"), { cause: err })) : makeNetworkError$1(Object.assign(new DOMException("Request was cancelled."), { cause: err }));
20445
20457
  }
20446
20458
  function initializeResponse(response, init, body) {
@@ -20532,7 +20544,7 @@ var require_request = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
20532
20544
  const { webidl: webidl$9 } = require_webidl();
20533
20545
  const { URLSerializer: URLSerializer$2 } = require_data_url();
20534
20546
  const { kConstruct: kConstruct$5 } = require_symbols();
20535
- const assert$10 = __require$2("node:assert");
20547
+ const assert$9 = __require$2("node:assert");
20536
20548
  const { getMaxListeners, setMaxListeners, defaultMaxListeners } = __require$2("node:events");
20537
20549
  const kAbortController = Symbol("abortController");
20538
20550
  const requestFinalizer = new FinalizationRegistry(({ signal, abort: abort$1 }) => {
@@ -20598,7 +20610,7 @@ var require_request = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
20598
20610
  request$2 = makeRequest$2({ urlList: [parsedURL] });
20599
20611
  fallbackMode = "cors";
20600
20612
  } else {
20601
- assert$10(webidl$9.is.Request(input));
20613
+ assert$9(webidl$9.is.Request(input));
20602
20614
  request$2 = input.#state;
20603
20615
  signal = input.#signal;
20604
20616
  this.#dispatcher = init.dispatcher || input.#dispatcher;
@@ -21112,7 +21124,7 @@ var require_request = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
21112
21124
  //#endregion
21113
21125
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/subresource-integrity/subresource-integrity.js
21114
21126
  var require_subresource_integrity = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/subresource-integrity/subresource-integrity.js": ((exports, module) => {
21115
- const assert$9 = __require$2("node:assert");
21127
+ const assert$8 = __require$2("node:assert");
21116
21128
  const { runtimeFeatures: runtimeFeatures$3 } = require_runtime_features();
21117
21129
  /**
21118
21130
  * @typedef {object} Metadata
@@ -21190,7 +21202,7 @@ var require_subresource_integrity = /* @__PURE__ */ __commonJS$2({ "../../node_m
21190
21202
  /** @type {Metadata|null} */
21191
21203
  let strongest = null;
21192
21204
  for (const item of metadataList) {
21193
- assert$9(isValidSRIHashAlgorithm(item.alg), "Invalid SRI hash algorithm token");
21205
+ assert$8(isValidSRIHashAlgorithm(item.alg), "Invalid SRI hash algorithm token");
21194
21206
  if (result.length === 0) {
21195
21207
  result.push(item);
21196
21208
  strongest = item;
@@ -21284,7 +21296,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21284
21296
  const { Request: Request$3, cloneRequest, getRequestDispatcher, getRequestState: getRequestState$1 } = require_request();
21285
21297
  const zlib = __require$2("node:zlib");
21286
21298
  const { makePolicyContainer, clonePolicyContainer, requestBadPort, TAOCheck, appendRequestOriginHeader, responseLocationURL, requestCurrentURL, setRequestReferrerPolicyOnRedirect, tryUpgradeRequestToAPotentiallyTrustworthyURL, createOpaqueTimingInfo, appendFetchMetadata, corsCheck, crossOriginResourcePolicyCheck, determineRequestsReferrer, coarsenedSharedCurrentTime, sameOrigin, isCancelled, isAborted, isErrorLike, fullyReadBody, readableStreamClose, urlIsLocal, urlIsHttpHttpsScheme: urlIsHttpHttpsScheme$1, urlHasHttpsScheme, clampAndCoarsenConnectionTimingInfo, simpleRangeHeaderValue, buildContentRange, createInflate, extractMimeType, hasAuthenticationEntry, includesCredentials, isTraversableNavigable } = require_util$4();
21287
- const assert$8 = __require$2("node:assert");
21299
+ const assert$7 = __require$2("node:assert");
21288
21300
  const { safelyExtractBody, extractBody } = require_body();
21289
21301
  const { redirectStatusSet, nullBodyStatus, safeMethodsSet, requestBodyHeader, subresourceSet } = require_constants$4();
21290
21302
  const EE$1 = __require$2("node:events");
@@ -21350,7 +21362,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21350
21362
  let controller = null;
21351
21363
  addAbortListener(requestObject.signal, () => {
21352
21364
  locallyAborted = true;
21353
- assert$8(controller != null);
21365
+ assert$7(controller != null);
21354
21366
  controller.abort(requestObject.signal.reason);
21355
21367
  const realResponse = responseObject?.deref();
21356
21368
  abortFetch(p$2, request$2, realResponse, requestObject.signal.reason, controller.controller);
@@ -21406,7 +21418,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21406
21418
  if (response.body?.stream != null && isReadable(response.body.stream)) controller.error(error$2);
21407
21419
  }
21408
21420
  function fetching$3({ request: request$2, processRequestBodyChunkLength, processRequestEndOfBody, processResponse, processResponseEndOfBody, processResponseConsumeBody, useParallelQueue = false, dispatcher = getGlobalDispatcher$2(), requestObject = null }) {
21409
- assert$8(dispatcher);
21421
+ assert$7(dispatcher);
21410
21422
  let taskDestination = null;
21411
21423
  let crossOriginIsolatedCapability = false;
21412
21424
  if (request$2.client != null) {
@@ -21427,7 +21439,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21427
21439
  crossOriginIsolatedCapability,
21428
21440
  requestObject
21429
21441
  };
21430
- assert$8(!request$2.body || request$2.body.stream);
21442
+ assert$7(!request$2.body || request$2.body.stream);
21431
21443
  if (request$2.window === "client") request$2.window = request$2.client?.globalObject?.constructor?.name === "Window" ? request$2.client : "no-window";
21432
21444
  if (request$2.origin === "client") request$2.origin = request$2.client.origin;
21433
21445
  if (request$2.policyContainer === "client") if (request$2.client != null) request$2.policyContainer = clonePolicyContainer(request$2.client.policyContainer);
@@ -21471,7 +21483,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21471
21483
  if (request$2.responseTainting === "basic") response = filterResponse(response, "basic");
21472
21484
  else if (request$2.responseTainting === "cors") response = filterResponse(response, "cors");
21473
21485
  else if (request$2.responseTainting === "opaque") response = filterResponse(response, "opaque");
21474
- else assert$8(false);
21486
+ else assert$7(false);
21475
21487
  }
21476
21488
  let internalResponse = response.status === 0 ? response : response.internalResponse;
21477
21489
  if (internalResponse.urlList.length === 0) internalResponse.urlList.push(...request$2.urlList);
@@ -21627,7 +21639,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21627
21639
  if (request$2.redirect === "error") response = makeNetworkError("unexpected redirect");
21628
21640
  else if (request$2.redirect === "manual") response = actualResponse;
21629
21641
  else if (request$2.redirect === "follow") response = await httpRedirectFetch(fetchParams, response);
21630
- else assert$8(false);
21642
+ else assert$7(false);
21631
21643
  }
21632
21644
  response.timingInfo = timingInfo;
21633
21645
  return response;
@@ -21660,7 +21672,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21660
21672
  request$2.headersList.delete("host", true);
21661
21673
  }
21662
21674
  if (request$2.body != null) {
21663
- assert$8(request$2.body.source != null);
21675
+ assert$7(request$2.body.source != null);
21664
21676
  request$2.body = safelyExtractBody(request$2.body.source)[0];
21665
21677
  }
21666
21678
  const timingInfo = fetchParams.timingInfo;
@@ -21752,7 +21764,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
21752
21764
  return response;
21753
21765
  }
21754
21766
  async function httpNetworkFetch(fetchParams, includeCredentials = false, forceNewConnection = false) {
21755
- assert$8(!fetchParams.controller.connection || fetchParams.controller.connection.destroyed);
21767
+ assert$7(!fetchParams.controller.connection || fetchParams.controller.connection.destroyed);
21756
21768
  fetchParams.controller.connection = {
21757
21769
  abort: null,
21758
21770
  destroyed: false,
@@ -22032,7 +22044,7 @@ var require_fetch = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
22032
22044
  //#endregion
22033
22045
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/cache/util.js
22034
22046
  var require_util$3 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/cache/util.js": ((exports, module) => {
22035
- const assert$7 = __require$2("node:assert");
22047
+ const assert$6 = __require$2("node:assert");
22036
22048
  const { URLSerializer: URLSerializer$1 } = require_data_url();
22037
22049
  const { isValidHeaderName } = require_util$4();
22038
22050
  /**
@@ -22050,7 +22062,7 @@ var require_util$3 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
22050
22062
  * @param {string} header
22051
22063
  */
22052
22064
  function getFieldValues$1(header) {
22053
- assert$7(header !== null);
22065
+ assert$6(header !== null);
22054
22066
  const values = [];
22055
22067
  for (let value of header.split(",")) {
22056
22068
  value = value.trim();
@@ -22067,7 +22079,7 @@ var require_util$3 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/un
22067
22079
  //#endregion
22068
22080
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/cache/cache.js
22069
22081
  var require_cache = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/cache/cache.js": ((exports, module) => {
22070
- const assert$6 = __require$2("node:assert");
22082
+ const assert$5 = __require$2("node:assert");
22071
22083
  const { kConstruct: kConstruct$4 } = require_symbols();
22072
22084
  const { urlEquals, getFieldValues } = require_util$3();
22073
22085
  const { kEnumerableProperty: kEnumerableProperty$6, isDisturbed } = require_util$5();
@@ -22282,7 +22294,7 @@ var require_cache = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
22282
22294
  r$1 = getRequestState(request$2);
22283
22295
  if (r$1.method !== "GET" && !options.ignoreMethod) return false;
22284
22296
  } else {
22285
- assert$6(typeof request$2 === "string");
22297
+ assert$5(typeof request$2 === "string");
22286
22298
  r$1 = getRequestState(new Request$2(request$2));
22287
22299
  }
22288
22300
  /** @type {CacheBatchOperation[]} */
@@ -22370,7 +22382,7 @@ var require_cache = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
22370
22382
  if (requestResponses.length === 0) return [];
22371
22383
  for (const requestResponse of requestResponses) {
22372
22384
  const idx = cache$2.indexOf(requestResponse);
22373
- assert$6(idx !== -1);
22385
+ assert$5(idx !== -1);
22374
22386
  cache$2.splice(idx, 1);
22375
22387
  }
22376
22388
  } else if (operation.type === "put") {
@@ -22394,7 +22406,7 @@ var require_cache = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/und
22394
22406
  requestResponses = this.#queryCache(operation.request);
22395
22407
  for (const requestResponse of requestResponses) {
22396
22408
  const idx = cache$2.indexOf(requestResponse);
22397
- assert$6(idx !== -1);
22409
+ assert$5(idx !== -1);
22398
22410
  cache$2.splice(idx, 1);
22399
22411
  }
22400
22412
  cache$2.push([operation.request, operation.response]);
@@ -22858,7 +22870,7 @@ var require_parse$2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
22858
22870
  const { collectASequenceOfCodePointsFast: collectASequenceOfCodePointsFast$1 } = require_infra();
22859
22871
  const { maxNameValuePairSize, maxAttributeValueSize } = require_constants$3();
22860
22872
  const { isCTLExcludingHtab } = require_util$2();
22861
- const assert$5 = __require$2("node:assert");
22873
+ const assert$4 = __require$2("node:assert");
22862
22874
  /**
22863
22875
  * @description Parses the field-value attributes of a set-cookie header string.
22864
22876
  * @see https://datatracker.ietf.org/doc/html/draft-ietf-httpbis-rfc6265bis#section-5.4
@@ -22899,7 +22911,7 @@ var require_parse$2 = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/u
22899
22911
  */
22900
22912
  function parseUnparsedAttributes(unparsedAttributes, cookieAttributeList = {}) {
22901
22913
  if (unparsedAttributes.length === 0) return cookieAttributeList;
22902
- assert$5(unparsedAttributes[0] === ";");
22914
+ assert$4(unparsedAttributes[0] === ";");
22903
22915
  unparsedAttributes = unparsedAttributes.slice(1);
22904
22916
  let cookieAv = "";
22905
22917
  if (unparsedAttributes.includes(";")) {
@@ -23824,7 +23836,7 @@ var require_connection = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnp
23824
23836
  const { Headers: Headers$2, getHeadersList } = require_headers();
23825
23837
  const { getDecodeSplit } = require_util$4();
23826
23838
  const { WebsocketFrameSend: WebsocketFrameSend$4 } = require_frame();
23827
- const assert$4 = __require$2("node:assert");
23839
+ const assert$3 = __require$2("node:assert");
23828
23840
  const { runtimeFeatures } = require_runtime_features();
23829
23841
  const crypto$2 = runtimeFeatures.has("crypto") ? __require$2("node:crypto") : null;
23830
23842
  let warningEmitted = false;
@@ -23930,7 +23942,7 @@ var require_connection = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnp
23930
23942
  } else if (!object$2.closeState.has(sentCloseFrameState$3.SENT) && !object$2.closeState.has(sentCloseFrameState$3.RECEIVED)) {
23931
23943
  const frame = new WebsocketFrameSend$4();
23932
23944
  if (reason.length !== 0 && code === null) code = 1e3;
23933
- assert$4(code === null || Number.isInteger(code));
23945
+ assert$3(code === null || Number.isInteger(code));
23934
23946
  if (code === null && reason.length === 0) frame.frameData = emptyBuffer$1;
23935
23947
  else if (code !== null && reason === null) {
23936
23948
  frame.frameData = Buffer.allocUnsafe(2);
@@ -24049,7 +24061,7 @@ var require_permessage_deflate = /* @__PURE__ */ __commonJS$2({ "../../node_modu
24049
24061
  //#region ../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/websocket/receiver.js
24050
24062
  var require_receiver = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/undici@7.29.0/node_modules/undici/lib/web/websocket/receiver.js": ((exports, module) => {
24051
24063
  const { Writable } = __require$2("node:stream");
24052
- const assert$3 = __require$2("node:assert");
24064
+ const assert$2 = __require$2("node:assert");
24053
24065
  const { parserStates, opcodes: opcodes$3, states: states$2, emptyBuffer, sentCloseFrameState: sentCloseFrameState$2 } = require_constants$2();
24054
24066
  const { isValidStatusCode, isValidOpcode, websocketMessageReceived, utf8Decode: utf8Decode$2, isControlFrame, isTextBinaryFrame, isContinuationFrame } = require_util$1();
24055
24067
  const { failWebsocketConnection: failWebsocketConnection$2 } = require_connection();
@@ -24287,7 +24299,7 @@ var require_receiver = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pnpm/
24287
24299
  return output;
24288
24300
  }
24289
24301
  parseCloseBody(data$1) {
24290
- assert$3(data$1.length !== 1);
24302
+ assert$2(data$1.length !== 1);
24291
24303
  /** @type {number|undefined} */
24292
24304
  let code;
24293
24305
  if (data$1.length >= 2) code = data$1.readUInt16BE(0);
@@ -27263,7 +27275,6 @@ var defaultWranglerConfig = {
27263
27275
  vectorize: [],
27264
27276
  ai_search_namespaces: [],
27265
27277
  ai_search: [],
27266
- websearch: void 0,
27267
27278
  agent_memory: [],
27268
27279
  hyperdrive: [],
27269
27280
  workflows: [],
@@ -27940,7 +27951,7 @@ __export(util_exports$1, {
27940
27951
  NUMBER_FORMAT_RANGES: () => NUMBER_FORMAT_RANGES$1,
27941
27952
  aborted: () => aborted$1,
27942
27953
  allowsEval: () => allowsEval$1,
27943
- assert: () => assert$2,
27954
+ assert: () => assert$1,
27944
27955
  assertEqual: () => assertEqual,
27945
27956
  assertIs: () => assertIs,
27946
27957
  assertNever: () => assertNever2,
@@ -28013,8 +28024,8 @@ function assertNever2(_x) {
28013
28024
  throw new Error("Unexpected value in exhaustive check");
28014
28025
  }
28015
28026
  __name$6(assertNever2, "assertNever");
28016
- function assert$2(_) {}
28017
- __name$6(assert$2, "assert");
28027
+ function assert$1(_) {}
28028
+ __name$6(assert$1, "assert");
28018
28029
  function getEnumValues$1(entries) {
28019
28030
  const numericValues = Object.values(entries).filter((v) => typeof v === "number");
28020
28031
  return Object.entries(entries).filter(([k, _]) => numericValues.indexOf(+k) === -1).map(([_, v]) => v);
@@ -41341,7 +41352,6 @@ var friendlyBindingNames = {
41341
41352
  vectorize: "Vectorize Index",
41342
41353
  ai_search_namespaces: "AI Search Namespace",
41343
41354
  ai_search: "AI Search Instance",
41344
- websearch: "Web Search",
41345
41355
  agent_memory: "Agent Memory",
41346
41356
  hyperdrive: "Hyperdrive Config",
41347
41357
  r2_buckets: "R2 Bucket",
@@ -41394,7 +41404,6 @@ var bindingTypeFriendlyNames = {
41394
41404
  vectorize: "Vectorize Index",
41395
41405
  ai_search_namespace: "AI Search Namespace",
41396
41406
  ai_search: "AI Search Instance",
41397
- websearch: "Web Search",
41398
41407
  agent_memory: "Agent Memory",
41399
41408
  hyperdrive: "Hyperdrive Config",
41400
41409
  service: "Worker",
@@ -41763,45 +41772,61 @@ function validateRoutes(diagnostics, topLevelEnv, rawEnv, envName) {
41763
41772
  return result;
41764
41773
  }
41765
41774
  __name$6(validateRoutes, "validateRoutes");
41766
- function normalizeAndValidatePlacement(diagnostics, topLevelEnv, rawEnv) {
41767
- if (rawEnv.placement) {
41775
+ function normalizeAndValidatePlacement(diagnostics, topLevelEnv, rawEnv, diagnosticField = "placement") {
41776
+ if (rawEnv.placement !== void 0) {
41777
+ if (typeof rawEnv.placement !== "object" || rawEnv.placement === null || Array.isArray(rawEnv.placement)) {
41778
+ diagnostics.errors.push(`The field "${diagnosticField}" should be an object but got ${JSON.stringify(rawEnv.placement)}.`);
41779
+ return inheritable(diagnostics, topLevelEnv, rawEnv, "placement", () => true, void 0);
41780
+ }
41768
41781
  const placement = rawEnv.placement;
41769
41782
  const hasHint = "hint" in placement;
41770
- const hasRegion = "region" in placement;
41771
- const hasHost = "host" in placement;
41772
- const hasHostname = "hostname" in placement;
41773
- const hasTargetedFields = hasRegion || hasHost || hasHostname;
41783
+ const presentTargetedFields = [
41784
+ "region",
41785
+ "host",
41786
+ "hostname"
41787
+ ].filter((field) => field in placement);
41788
+ const hasTargetedFields = presentTargetedFields.length > 0;
41774
41789
  if (hasHint && hasTargetedFields) {
41775
- diagnostics.errors.push(`"placement" cannot have both "hint" (smart format) and "region"/"host"/"hostname" (targeted format) fields`);
41790
+ diagnostics.errors.push(`"${diagnosticField}" cannot have both "hint" (smart format) and "region"/"host"/"hostname" (targeted format) fields`);
41776
41791
  return inheritable(diagnostics, topLevelEnv, rawEnv, "placement", () => true, void 0);
41777
41792
  }
41778
41793
  if (hasHint) {
41779
- validateRequiredProperty(diagnostics, "placement", "mode", placement.mode, "string", ["off", "smart"]);
41794
+ validateRequiredProperty(diagnostics, diagnosticField, "mode", placement.mode, "string", ["off", "smart"]);
41780
41795
  const mode = placement.mode;
41781
41796
  const hint = placement.hint;
41782
- if (hint !== void 0 && typeof hint !== "string") diagnostics.errors.push(`"placement.hint" must be a string when "placement.mode" is "${mode}"`);
41783
- if (hint && mode !== "smart") diagnostics.errors.push(`"placement.hint" can only be set when "placement.mode" is "smart"`);
41797
+ if (hint !== void 0 && typeof hint !== "string") diagnostics.errors.push(`"${diagnosticField}.hint" must be a string when "${diagnosticField}.mode" is "${mode}"`);
41798
+ if (hint && mode !== "smart") diagnostics.errors.push(`"${diagnosticField}.hint" can only be set when "${diagnosticField}.mode" is "smart"`);
41784
41799
  } else if (hasTargetedFields) {
41785
- validateOptionalProperty(diagnostics, "placement", "mode", placement.mode, "string", ["off", "targeted"]);
41786
- if (hasRegion) validateOptionalProperty(diagnostics, "placement", "region", placement.region, "string");
41787
- if (hasHost) validateOptionalProperty(diagnostics, "placement", "host", placement.host, "string");
41788
- if (hasHostname) validateOptionalProperty(diagnostics, "placement", "hostname", placement.hostname, "string");
41789
- if ([
41790
- hasRegion,
41791
- hasHost,
41792
- hasHostname
41793
- ].filter(Boolean).length > 1) {
41794
- const presentFields = [];
41795
- if (hasRegion) presentFields.push("region");
41796
- if (hasHost) presentFields.push("host");
41797
- if (hasHostname) presentFields.push("hostname");
41798
- diagnostics.errors.push(`"placement" fields ${presentFields.map((f) => `"${f}"`).join(", ")} are mutually exclusive. Only one can be specified.`);
41799
- }
41800
- } else validateRequiredProperty(diagnostics, "placement", "mode", placement.mode, "string", [
41801
- "off",
41802
- "smart",
41803
- "targeted"
41804
- ]);
41800
+ validateOptionalProperty(diagnostics, diagnosticField, "mode", placement.mode, "string", ["targeted"]);
41801
+ for (const field of presentTargetedFields) {
41802
+ validateRequiredProperty(diagnostics, diagnosticField, field, placement[field], "string");
41803
+ if (placement[field] === "") diagnostics.errors.push(`"${diagnosticField}.${field}" must be a non-empty string.`);
41804
+ }
41805
+ if (presentTargetedFields.length > 1) diagnostics.errors.push(`"${diagnosticField}" fields ${presentTargetedFields.map((field) => `"${field}"`).join(", ")} are mutually exclusive. Only one can be specified.`);
41806
+ } else {
41807
+ validateRequiredProperty(diagnostics, diagnosticField, "mode", placement.mode, "string", [
41808
+ "off",
41809
+ "smart",
41810
+ "targeted"
41811
+ ]);
41812
+ if (placement.mode === "targeted") validateAtLeastOnePropertyRequired(diagnostics, diagnosticField, [
41813
+ {
41814
+ key: "region",
41815
+ value: placement.region,
41816
+ type: "string"
41817
+ },
41818
+ {
41819
+ key: "host",
41820
+ value: placement.host,
41821
+ type: "string"
41822
+ },
41823
+ {
41824
+ key: "hostname",
41825
+ value: placement.hostname,
41826
+ type: "string"
41827
+ }
41828
+ ]);
41829
+ }
41805
41830
  }
41806
41831
  return inheritable(diagnostics, topLevelEnv, rawEnv, "placement", () => true, void 0);
41807
41832
  }
@@ -41897,7 +41922,6 @@ function normalizeAndValidateEnvironment(diagnostics, configPath, rawEnv, isDisp
41897
41922
  vectorize: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "vectorize", validateBindingArray(envName, validateVectorizeBinding), []),
41898
41923
  ai_search_namespaces: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "ai_search_namespaces", validateBindingArray(envName, validateAISearchNamespaceBinding), []),
41899
41924
  ai_search: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "ai_search", validateBindingArray(envName, validateAISearchBinding), []),
41900
- websearch: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "websearch", validateNamedSimpleBinding(envName), void 0),
41901
41925
  agent_memory: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "agent_memory", validateBindingArray(envName, validateAgentMemoryBinding), []),
41902
41926
  hyperdrive: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "hyperdrive", validateBindingArray(envName, validateHyperdriveBinding), []),
41903
41927
  services: notInheritable(diagnostics, topLevelEnv, rawConfig, rawEnv, envName, "services", validateBindingArray(envName, validateServiceBinding), []),
@@ -42437,7 +42461,6 @@ var validateUnsafeBinding = /* @__PURE__ */ __name$6((diagnostics, field, value)
42437
42461
  "ai",
42438
42462
  "ai_search_namespace",
42439
42463
  "ai_search",
42440
- "websearch",
42441
42464
  "agent_memory",
42442
42465
  "kv_namespace",
42443
42466
  "durable_object_namespace",
@@ -42583,7 +42606,18 @@ function validateDurableObjectContainerImages(diagnostics, field, images, compli
42583
42606
  valid$2 = false;
42584
42607
  }
42585
42608
  }
42586
- const unsupportedFields = Object.keys(image).filter((property) => property !== "dockerfile" && property !== "image");
42609
+ const isDockerfileBuild = hasDockerfile && !hasImage;
42610
+ if (isDockerfileBuild) {
42611
+ if (image.build_context !== void 0 && (typeof image.build_context !== "string" || image.build_context.length === 0)) {
42612
+ diagnostics.errors.push(`"${imageField}.build_context" must be a non-empty string.`);
42613
+ valid$2 = false;
42614
+ }
42615
+ if (image.build_vars !== void 0 && (typeof image.build_vars !== "object" || image.build_vars === null || Array.isArray(image.build_vars) || Object.values(image.build_vars).some((value) => typeof value !== "string"))) {
42616
+ diagnostics.errors.push(`"${imageField}.build_vars" must be an object with string values.`);
42617
+ valid$2 = false;
42618
+ }
42619
+ }
42620
+ const unsupportedFields = Object.keys(image).filter((property) => property !== "dockerfile" && property !== "image" && !(isDockerfileBuild && (property === "build_context" || property === "build_vars")));
42587
42621
  if (unsupportedFields.length > 0) {
42588
42622
  diagnostics.errors.push(`Unexpected fields found in ${imageField} field: ${unsupportedFields.map((property) => `"${property}"`).join(", ")}`);
42589
42623
  valid$2 = false;
@@ -42592,6 +42626,24 @@ function validateDurableObjectContainerImages(diagnostics, field, images, compli
42592
42626
  return valid$2;
42593
42627
  }
42594
42628
  __name$6(validateDurableObjectContainerImages, "validateDurableObjectContainerImages");
42629
+ function validateDurableObjectContainerUnsafe(diagnostics, field, value) {
42630
+ if (value === void 0) return;
42631
+ if (typeof value !== "object" || value === null || Array.isArray(value)) {
42632
+ diagnostics.errors.push(`"${field}" should be an object.`);
42633
+ return;
42634
+ }
42635
+ const unsafe = value;
42636
+ const configuration = unsafe.configuration;
42637
+ if (Object.keys(unsafe).some((key) => key !== "configuration") || configuration !== void 0 && (typeof configuration !== "object" || configuration === null || Array.isArray(configuration) || Object.keys(configuration).some((key) => key !== "experimental_flags"))) {
42638
+ diagnostics.errors.push(`Only "${field}.configuration.experimental_flags" is supported for Durable Object-managed Containers.`);
42639
+ return;
42640
+ }
42641
+ if (configuration !== void 0) {
42642
+ const flags = configuration.experimental_flags;
42643
+ if (flags !== void 0 && (!Array.isArray(flags) || flags.some((flag) => typeof flag !== "string"))) diagnostics.errors.push(`"${field}.configuration.experimental_flags" should be an array of strings.`);
42644
+ }
42645
+ }
42646
+ __name$6(validateDurableObjectContainerUnsafe, "validateDurableObjectContainerUnsafe");
42595
42647
  function validateContainerApp(envName, topLevelName, configPath, options = {}) {
42596
42648
  const { generateDefaultName = true } = options;
42597
42649
  return (diagnostics, field, value, config2) => {
@@ -42603,11 +42655,10 @@ function validateContainerApp(envName, topLevelName, configPath, options = {}) {
42603
42655
  for (const containerAppOptional of value) {
42604
42656
  const isDurableObjectManaged = containerAppOptional.scheduling_policy === "durable_object";
42605
42657
  const hasValidDurableObjectClassName = typeof containerAppOptional.class_name === "string" && containerAppOptional.class_name.length > 0;
42606
- if (isDurableObjectManaged) {
42607
- if (!hasValidDurableObjectClassName) diagnostics.errors.push(`"containers.class_name" must be a non-empty string when "containers.scheduling_policy" is "durable_object".`);
42608
- } else validateOptionalProperty(diagnostics, field, "class_name", containerAppOptional.class_name, "string");
42658
+ validateOptionalProperty(diagnostics, field, "class_name", containerAppOptional.class_name, "string");
42659
+ if (isDurableObjectManaged && containerAppOptional.class_name === "") diagnostics.errors.push(`"containers.class_name" must be a non-empty string when specified for a Durable Object-managed Container.`);
42609
42660
  validateOptionalProperty(diagnostics, field, "name", containerAppOptional.name, "string");
42610
- if (generateDefaultName && !containerAppOptional.name && (!isDurableObjectManaged || hasValidDurableObjectClassName)) if (containerAppOptional.class_name === void 0) diagnostics.errors.push(`"containers.name" is required when "containers.class_name" is not defined, because there is no class name to derive a default name from. Either name this container and reference it from a Durable Object's \`exports\` entry, or set "containers.class_name".`);
42661
+ if (generateDefaultName && !containerAppOptional.name && (!isDurableObjectManaged || containerAppOptional.class_name === void 0 || hasValidDurableObjectClassName)) if (containerAppOptional.class_name === void 0) diagnostics.errors.push(`"containers.name" is required when "containers.class_name" is not defined, because there is no class name to derive a default name from. Either name this container and reference it from a Durable Object's \`exports\` entry, or set "containers.class_name".`);
42611
42662
  else if (!topLevelName) diagnostics.errors.push(`Must have either a top level "name" and "containers.class_name" field defined, or have field "containers.name" defined.`);
42612
42663
  else {
42613
42664
  let name = `${topLevelName}-${containerAppOptional.class_name}`;
@@ -42616,13 +42667,18 @@ function validateContainerApp(envName, topLevelName, configPath, options = {}) {
42616
42667
  }
42617
42668
  if (isDurableObjectManaged) {
42618
42669
  validateDurableObjectContainerImages(diagnostics, `${field}.images`, containerAppOptional.images, options.complianceConfig);
42670
+ validateContainerObservability(diagnostics, `${field}.observability`, containerAppOptional.observability, config2);
42671
+ if (containerAppOptional.observability?.target_instance_count !== void 0 || containerAppOptional.observability?.target_instance_percentage !== void 0) diagnostics.errors.push(`"${field}.observability" only supports enabling or disabling logs for Durable Object-managed Containers; instance targeting is not supported.`);
42672
+ validateDurableObjectContainerUnsafe(diagnostics, `${field}.unsafe`, containerAppOptional.unsafe);
42619
42673
  const unsupportedFields = Object.keys(containerAppOptional).filter((key) => ![
42620
42674
  "name",
42621
42675
  "class_name",
42622
42676
  "scheduling_policy",
42623
- "images"
42677
+ "images",
42678
+ "observability",
42679
+ "unsafe"
42624
42680
  ].includes(key));
42625
- if (unsupportedFields.length > 0) diagnostics.errors.push(`Unsupported fields for Durable Object-managed Containers in ${field}: ${unsupportedFields.map((key) => `"${key}"`).join(",")}. Only "name", "class_name", "scheduling_policy", and "images" are supported.`);
42681
+ if (unsupportedFields.length > 0) diagnostics.errors.push(`Unsupported fields for Durable Object-managed Containers in ${field}: ${unsupportedFields.map((key) => `"${key}"`).join(",")}. Only "name", "class_name", "scheduling_policy", "images", "observability", and restricted "unsafe" settings are supported.`);
42626
42682
  continue;
42627
42683
  }
42628
42684
  if (!containerAppOptional.configuration?.image && !containerAppOptional.image) diagnostics.errors.push(`"containers.image" field must be defined for each container app. This should be the path to your Dockerfile or an image URI pointing to the Cloudflare registry.`);
@@ -43693,6 +43749,8 @@ var validatePreviewsConfig = /* @__PURE__ */ __name$6((envName, configPath) => (
43693
43749
  "d1_databases",
43694
43750
  "r2_buckets",
43695
43751
  "vectorize",
43752
+ "ai_search_namespaces",
43753
+ "ai_search",
43696
43754
  "hyperdrive",
43697
43755
  "services",
43698
43756
  "analytics_engine_datasets",
@@ -43719,10 +43777,12 @@ var validatePreviewsConfig = /* @__PURE__ */ __name$6((envName, configPath) => (
43719
43777
  "logpush",
43720
43778
  "observability",
43721
43779
  "limits",
43780
+ "placement",
43722
43781
  "cache"
43723
43782
  ]) && isValid;
43724
43783
  isValid = validateVars(envName)(diagnostics, `${field}.vars`, previews.vars, void 0) && isValid;
43725
43784
  isValid = validateDefines(envName)(diagnostics, `${field}.define`, previews.define, void 0) && isValid;
43785
+ normalizeAndValidatePlacement(diagnostics, void 0, previews, `${field}.placement`);
43726
43786
  isValid = validateBindingsProperty(envName, validateDurableObjectBinding)(diagnostics, `${field}.durable_objects`, previews.durable_objects, void 0) && isValid;
43727
43787
  isValid = all(validateBindingArray(envName, validateWorkflowBinding), validateUniqueNameProperty)(diagnostics, `${field}.workflows`, previews.workflows, void 0) && isValid;
43728
43788
  isValid = validateBindingArray(envName, validateKVBinding)(diagnostics, `${field}.kv_namespaces`, previews.kv_namespaces, void 0) && isValid;
@@ -43731,6 +43791,8 @@ var validatePreviewsConfig = /* @__PURE__ */ __name$6((envName, configPath) => (
43731
43791
  isValid = validateBindingArray(envName, validateD1Binding)(diagnostics, `${field}.d1_databases`, previews.d1_databases, void 0) && isValid;
43732
43792
  isValid = validateBindingArray(envName, validateR2Binding)(diagnostics, `${field}.r2_buckets`, previews.r2_buckets, void 0) && isValid;
43733
43793
  isValid = validateBindingArray(envName, validateVectorizeBinding)(diagnostics, `${field}.vectorize`, previews.vectorize, void 0) && isValid;
43794
+ isValid = validateBindingArray(envName, validateAISearchNamespaceBinding)(diagnostics, `${field}.ai_search_namespaces`, previews.ai_search_namespaces, void 0) && isValid;
43795
+ isValid = validateBindingArray(envName, validateAISearchBinding)(diagnostics, `${field}.ai_search`, previews.ai_search, void 0) && isValid;
43734
43796
  isValid = validateBindingArray(envName, validateHyperdriveBinding)(diagnostics, `${field}.hyperdrive`, previews.hyperdrive, void 0) && isValid;
43735
43797
  isValid = validateBindingArray(envName, validateServiceBinding)(diagnostics, `${field}.services`, previews.services, void 0) && isValid;
43736
43798
  isValid = validateBindingArray(envName, validateAnalyticsEngineBinding)(diagnostics, `${field}.analytics_engine_datasets`, previews.analytics_engine_datasets, void 0) && isValid;
@@ -44291,7 +44353,6 @@ var BINDING_LOCAL_SUPPORT = {
44291
44353
  flagship: "DO-NOT-USE-this-resource-will-never-have-a-local-simulator",
44292
44354
  vpc_service: "DO-NOT-USE-this-resource-will-never-have-a-local-simulator",
44293
44355
  vpc_network: "DO-NOT-USE-this-resource-will-never-have-a-local-simulator",
44294
- websearch: "DO-NOT-USE-this-resource-will-never-have-a-local-simulator",
44295
44356
  agent_memory: "DO-NOT-USE-this-resource-will-never-have-a-local-simulator"
44296
44357
  };
44297
44358
  function getBindingLocalSupport(type) {
@@ -44649,14 +44710,6 @@ function convertConfigToBindings(config2, options) {
44649
44710
  ...x
44650
44711
  };
44651
44712
  break;
44652
- case "websearch": {
44653
- const { binding,...x } = info$1;
44654
- output[binding] = {
44655
- type: "websearch",
44656
- ...x
44657
- };
44658
- break;
44659
- }
44660
44713
  case "agent_memory":
44661
44714
  for (const { binding,...x } of info$1) output[binding] = {
44662
44715
  type: "agent_memory",
@@ -44802,7 +44855,6 @@ function printBindings(bindings, options) {
44802
44855
  const vectorize = extractBindingsOfType("vectorize", bindings);
44803
44856
  const ai_search_namespaces = extractBindingsOfType("ai_search_namespace", bindings);
44804
44857
  const ai_search = extractBindingsOfType("ai_search", bindings);
44805
- const websearch = extractBindingsOfType("websearch", bindings);
44806
44858
  const agent_memory = extractBindingsOfType("agent_memory", bindings);
44807
44859
  const hyperdrive = extractBindingsOfType("hyperdrive", bindings);
44808
44860
  const r2_buckets = extractBindingsOfType("r2_bucket", bindings);
@@ -44942,12 +44994,6 @@ function printBindings(bindings, options) {
44942
44994
  value: instance_name ? String(instance_name) : void 0,
44943
44995
  mode: getMode({ isSimulatedLocally: false })
44944
44996
  })));
44945
- if (websearch.length > 0) output.push(...websearch.map(({ binding }) => ({
44946
- name: binding,
44947
- type: getBindingTypeFriendlyName("websearch"),
44948
- value: void 0,
44949
- mode: getMode({ isSimulatedLocally: false })
44950
- })));
44951
44997
  if (agent_memory.length > 0) output.push(...agent_memory.map(({ binding, namespace }) => ({
44952
44998
  name: binding,
44953
44999
  type: getBindingTypeFriendlyName("agent_memory"),
@@ -45236,7 +45282,7 @@ ${allTailConsumers.map(({ service, streaming }) => {
45236
45282
  let containersTitle = "The following containers are available:";
45237
45283
  if (context.name && isMultiWorker) containersTitle = `The following containers are available from ${source_default.blue(context.name)}:`;
45238
45284
  log$2(`${containersTitle}
45239
- ${containers.map((container) => container.scheduling_policy === "durable_object" ? `- ${container.class_name} (durable_object)` : `- ${container.name} (${container.image})`).join("\n")}`);
45285
+ ${containers.map((container) => container.scheduling_policy === "durable_object" ? `- ${container.class_name ?? container.name} (durable_object)` : `- ${container.name} (${container.image})`).join("\n")}`);
45240
45286
  log$2("");
45241
45287
  }
45242
45288
  if (context.unsafeMetadata) {
@@ -46653,7 +46699,7 @@ function getWorkerNameFromProject(projectPath) {
46653
46699
  }
46654
46700
  __name$6(getWorkerNameFromProject, "getWorkerNameFromProject");
46655
46701
  function toUrlPath(filePath) {
46656
- assert(!/^[a-z]:/i.test(filePath), "Tried to convert a Windows file path with a drive to a URL path.");
46702
+ assert2(!/^[a-z]:/i.test(filePath), "Tried to convert a Windows file path with a drive to a URL path.");
46657
46703
  return filePath.replace(/\\/g, "/");
46658
46704
  }
46659
46705
  __name$6(toUrlPath, "toUrlPath");
@@ -55442,10 +55488,6 @@ const KnownBindingSchema = discriminatedUnion("type", [
55442
55488
  const value = input;
55443
55489
  return value.tunnelId !== void 0 && value.networkId !== void 0 ? `"vpc-network" bindings must specify exactly one of "tunnelId" or "networkId", not both` : `"vpc-network" bindings must specify either "tunnelId" or "networkId"`;
55444
55490
  } }),
55445
- strictObject({
55446
- type: literal$1("web-search"),
55447
- dev: RemoteBindingDevSchema.optional()
55448
- }),
55449
55491
  WorkerBindingSchema,
55450
55492
  strictObject({ type: literal$1("worker-loader") })
55451
55493
  ]);
@@ -55484,8 +55526,7 @@ const SINGLETON_BINDING_TYPES = new Set([
55484
55526
  "images",
55485
55527
  "media",
55486
55528
  "stream",
55487
- "version-metadata",
55488
- "web-search"
55529
+ "version-metadata"
55489
55530
  ]);
55490
55531
  const listFormatter = new Intl.ListFormat("en-US");
55491
55532
  function validateSingletonBindings(env$3, ctx) {
@@ -56424,12 +56465,6 @@ function convertBindingsAndAssets(config$2, result) {
56424
56465
  remote: binding.dev?.remote
56425
56466
  }));
56426
56467
  break;
56427
- case "web-search":
56428
- result.websearch = omitUndefined({
56429
- binding: name,
56430
- remote: binding.dev?.remote
56431
- });
56432
- break;
56433
56468
  case "worker":
56434
56469
  services.push(omitUndefined({
56435
56470
  binding: name,
@@ -57144,9 +57179,25 @@ const MAX_ROUTES_RULE_LENGTH = 100;
57144
57179
 
57145
57180
  //#endregion
57146
57181
  //#region ../workers-shared/utils/configuration/parseStaticRouting.ts
57182
+ const MAX_REPORTED_DUPLICATED_RULES = 5;
57147
57183
  function parseStaticRouting(input) {
57148
57184
  if (input.length === 0) throw new Error("No `run_worker_first` rules were provided; must provide at least 1 rule.");
57149
- if (input.length > MAX_ROUTES_RULES) throw new Error(`Too many \`run_worker_first\` rules were provided; ${input.length} rules provided exceeds max of ${MAX_ROUTES_RULES}.`);
57185
+ if (input.length > MAX_ROUTES_RULES) {
57186
+ const seenRules = /* @__PURE__ */ new Set();
57187
+ const duplicatedRules = /* @__PURE__ */ new Set();
57188
+ for (const rule of input) {
57189
+ if (seenRules.has(rule)) duplicatedRules.add(rule);
57190
+ seenRules.add(rule);
57191
+ }
57192
+ if (duplicatedRules.size > 0) {
57193
+ const duplicateEntryCount = input.length - seenRules.size;
57194
+ const reportedDuplicatedRules = [...seenRules].filter((rule) => duplicatedRules.has(rule)).slice(0, MAX_REPORTED_DUPLICATED_RULES);
57195
+ const unreportedDuplicatedRuleCount = duplicatedRules.size - reportedDuplicatedRules.length;
57196
+ const unreportedDuplicatedRulesMessage = unreportedDuplicatedRuleCount > 0 ? `\n...and ${unreportedDuplicatedRuleCount} more duplicated ${unreportedDuplicatedRuleCount === 1 ? "rule" : "rules"}.` : "";
57197
+ throw new Error(`Too many \`run_worker_first\` rules were provided; ${input.length} rules provided (${seenRules.size} distinct, ${duplicateEntryCount} duplicate ${duplicateEntryCount === 1 ? "entry" : "entries"}) exceeds max of ${MAX_ROUTES_RULES}. Note: duplicate entries count towards the route limit. Ensure that no duplicate rules are present in your \`run_worker_first\` configuration.\n\nThe duplicated rules found are:\n${reportedDuplicatedRules.map((rule) => `- ${JSON.stringify(rule)}`).join("\n")}${unreportedDuplicatedRulesMessage}`);
57198
+ }
57199
+ throw new Error(`Too many \`run_worker_first\` rules were provided; ${input.length} rules provided exceeds max of ${MAX_ROUTES_RULES}.`);
57200
+ }
57150
57201
  const rawAssetWorkerRules = [];
57151
57202
  const assetWorkerRules = [];
57152
57203
  const userWorkerRules = [];
@@ -66349,8 +66400,9 @@ function maybeAddAgentHint(server, mode) {
66349
66400
  * Prints the Local Explorer API URL and useful routes to stdout so that
66350
66401
  * headless AI agents can discover and call them programmatically.
66351
66402
  *
66352
- * Keep the message in sync with the wrangler copy in
66353
- * packages/wrangler/src/dev/start-dev.ts.
66403
+ * Keep the message in sync with:
66404
+ * - packages/wrangler/src/dev/start-dev.ts (printLocalExplorerAgentHint)
66405
+ * - packages/create-cloudflare/src/agents-md.ts (Local Explorer section)
66354
66406
  *
66355
66407
  * @param server - The Vite dev or preview server (must have `resolvedUrls` populated)
66356
66408
  * @param mode - Whether this is a "dev" or "preview" session
@@ -66372,6 +66424,7 @@ function printLocalExplorerAgentHint(server, mode) {
66372
66424
  ` GET ${explorerApiUrl}/workflows - Workflows`,
66373
66425
  ` POST ${explorerApiUrl}/local/observability/query - run a read-only SQL query (SELECT/WITH only) over captured request traces and console logs. Tables: spans, logs (read attributes via json(attributes)). Example:`,
66374
66426
  ` curl -X POST ${explorerApiUrl}/local/observability/query -H 'Content-Type: application/json' -d '{"sql":"SELECT service, name, outcome, duration_ms FROM spans WHERE parent_id IS NULL LIMIT 20"}'`,
66427
+ ` POST ${explorerApiUrl}/local/observability/clear - clear all captured traces and logs`,
66375
66428
  `If the routes above don't cover what you need, fetch the full OpenAPI schema (large - use only as a last resort):`,
66376
66429
  ` GET ${explorerApiUrl} - OpenAPI schema`,
66377
66430
  ""
@@ -70704,7 +70757,7 @@ var require_signal_exit = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
70704
70757
  return function() {};
70705
70758
  };
70706
70759
  else {
70707
- var assert$1 = __require$2("assert");
70760
+ var assert = __require$2("assert");
70708
70761
  var signals = require_signals();
70709
70762
  var isWin$1 = /^win/i.test(process$2.platform);
70710
70763
  var EE = __require$2("events");
@@ -70724,7 +70777,7 @@ var require_signal_exit = /* @__PURE__ */ __commonJS$2({ "../../node_modules/.pn
70724
70777
  module.exports = function(cb, opts) {
70725
70778
  /* istanbul ignore if */
70726
70779
  if (!processOk(global.process)) return function() {};
70727
- assert$1.equal(typeof cb, "function", "a callback must be provided for exit handler");
70780
+ assert.equal(typeof cb, "function", "a callback must be provided for exit handler");
70728
70781
  if (loaded === false) load();
70729
70782
  var ev = "exit";
70730
70783
  if (opts && opts.alwaysLast) ev = "afterexit";
@@ -74597,19 +74650,25 @@ async function pushBuiltContainerImage(builtImage, versionId, pathToDocker, acco
74597
74650
  }
74598
74651
  __name$2(pushBuiltContainerImage, "pushBuiltContainerImage");
74599
74652
  async function cleanupBuiltImages(builtImages, pathToDocker) {
74653
+ const aliasesByTag = /* @__PURE__ */ new Map();
74600
74654
  for (const builtImage of builtImages) {
74601
- if (builtImage.localTagCleaned) continue;
74602
- try {
74603
- logger$1.debug(`Untagging built image: ${builtImage.localTag}.`);
74655
+ const aliases = aliasesByTag.get(builtImage.localTag);
74656
+ if (aliases) aliases.push(builtImage);
74657
+ else aliasesByTag.set(builtImage.localTag, [builtImage]);
74658
+ }
74659
+ for (const [localTag, aliases] of aliasesByTag) {
74660
+ if (!aliases.some((alias) => alias.localTagCleaned)) try {
74661
+ logger$1.debug(`Untagging built image: ${localTag}.`);
74604
74662
  await runDockerCmd(pathToDocker, [
74605
74663
  "image",
74606
74664
  "rm",
74607
- builtImage.localTag
74665
+ localTag
74608
74666
  ]);
74609
- builtImage.localTagCleaned = true;
74610
74667
  } catch (error$2) {
74611
- if (error$2 instanceof Error) logger$1.debug(`Cleaning up built image ${builtImage.localTag} failed with error: ${error$2.message}`);
74668
+ if (error$2 instanceof Error) logger$1.debug(`Cleaning up built image ${localTag} failed with error: ${error$2.message}`);
74669
+ continue;
74612
74670
  }
74671
+ for (const alias of aliases) alias.localTagCleaned = true;
74613
74672
  }
74614
74673
  }
74615
74674
  __name$2(cleanupBuiltImages, "cleanupBuiltImages");
@@ -78402,7 +78461,7 @@ function scrubEncryptedCredentials(options) {
78402
78461
  __name$1(scrubEncryptedCredentials, "scrubEncryptedCredentials");
78403
78462
 
78404
78463
  //#endregion
78405
- //#region ../workers-auth/dist/chunk-YCVYA5LL.mjs
78464
+ //#region ../workers-auth/dist/chunk-T63LVVAX.mjs
78406
78465
  function createPreferences(getConfigPath) {
78407
78466
  function getUserPreferencesPath() {
78408
78467
  return path__default.resolve(getConfigPath(), "preferences.json");
@@ -79181,7 +79240,7 @@ Run \`${descriptor.commands.whoami}\` to check your current authentication statu
79181
79240
  return oauthFlow.requireApiToken();
79182
79241
  }
79183
79242
  __name$1(requireApiToken$1, "requireApiToken");
79184
- function withDefaultScopes(complianceConfig, props) {
79243
+ function withLoginDefaults(complianceConfig, props) {
79185
79244
  return {
79186
79245
  complianceConfig,
79187
79246
  scopes: props?.scopes ?? descriptor.getDefaultScopeKeys(),
@@ -79189,12 +79248,12 @@ Run \`${descriptor.commands.whoami}\` to check your current authentication statu
79189
79248
  callbackHost: props?.callbackHost,
79190
79249
  callbackPort: props?.callbackPort,
79191
79250
  profile: props?.profile,
79192
- device: props?.device
79251
+ device: props?.device ?? descriptor.useDeviceFlowByDefault ?? false
79193
79252
  };
79194
79253
  }
79195
- __name$1(withDefaultScopes, "withDefaultScopes");
79254
+ __name$1(withLoginDefaults, "withLoginDefaults");
79196
79255
  async function login(complianceConfig, props) {
79197
- return oauthFlow.login(withDefaultScopes(complianceConfig, props));
79256
+ return oauthFlow.login(withLoginDefaults(complianceConfig, props));
79198
79257
  }
79199
79258
  __name$1(login, "login");
79200
79259
  async function logout(profile) {
@@ -79203,7 +79262,7 @@ Run \`${descriptor.commands.whoami}\` to check your current authentication statu
79203
79262
  __name$1(logout, "logout");
79204
79263
  async function loginOrRefreshIfRequired(complianceConfig, props) {
79205
79264
  if (oauthFlow.getActiveTemporaryAccount()) return { loggedIn: true };
79206
- return oauthFlow.loginOrRefreshIfRequired(withDefaultScopes(complianceConfig, props));
79265
+ return oauthFlow.loginOrRefreshIfRequired(withLoginDefaults(complianceConfig, props));
79207
79266
  }
79208
79267
  __name$1(loginOrRefreshIfRequired, "loginOrRefreshIfRequired");
79209
79268
  async function getOAuthTokenFromLocalState() {
@@ -79236,10 +79295,7 @@ Run \`${descriptor.commands.whoami}\` to check your current authentication statu
79236
79295
  return configCache.getConfigCache(getAccountCacheFileName()).account;
79237
79296
  }
79238
79297
  __name$1(getAccountFromCache, "getAccountFromCache");
79239
- async function fetchAccountsPaged(complianceConfig, resource) {
79240
- const result = await loginOrRefreshIfRequired(complianceConfig);
79241
- if (!result.loggedIn) throw new UserError(`Not logged in. ${NOT_LOGGED_IN_ERROR_BODIES[result.reason]}${NOT_LOGGED_IN_WHOAMI_TIP}`, { telemetryMessage: "cfetch auth login required" });
79242
- const credentials = requireApiToken$1();
79298
+ async function fetchAccountsPaged(complianceConfig, resource, credentials) {
79243
79299
  const results = [];
79244
79300
  let getMoreResults = true;
79245
79301
  let page = 1;
@@ -79259,7 +79315,10 @@ Run \`${descriptor.commands.whoami}\` to check your current authentication statu
79259
79315
  __name$1(fetchAccountsPaged, "fetchAccountsPaged");
79260
79316
  async function fetchAllAccounts(complianceConfig, options = {}) {
79261
79317
  const { throwOnEmpty = true } = options;
79262
- const [accountsRes, membershipsRes] = await Promise.allSettled([fetchAccountsPaged(complianceConfig, `/accounts`), fetchAccountsPaged(complianceConfig, `/memberships`)]);
79318
+ const loginResult = await loginOrRefreshIfRequired(complianceConfig);
79319
+ if (!loginResult.loggedIn) throw new UserError(`Not logged in. ${NOT_LOGGED_IN_ERROR_BODIES[loginResult.reason]}${NOT_LOGGED_IN_WHOAMI_TIP}`, { telemetryMessage: "cfetch auth login required" });
79320
+ const credentials = requireApiToken$1();
79321
+ const [accountsRes, membershipsRes] = await Promise.allSettled([fetchAccountsPaged(complianceConfig, `/accounts`, credentials), fetchAccountsPaged(complianceConfig, `/memberships`, credentials)]);
79263
79322
  if (accountsRes.status === "rejected") throw accountsRes.reason;
79264
79323
  if (membershipsRes.status === "rejected") if (isMembershipsInaccessible(membershipsRes.reason)) {
79265
79324
  if (accountsRes.status === "fulfilled" && accountsRes.value.length > 0) return accountsRes.value;
@@ -79556,7 +79615,483 @@ function getCfConfigPath() {
79556
79615
  });
79557
79616
  }
79558
79617
  __name$1(getCfConfigPath, "getCfConfigPath");
79559
- var CF_SCOPES = [
79618
+ var CF_REGISTERED_SCOPES = [
79619
+ "access:read",
79620
+ "access:write",
79621
+ "account:read",
79622
+ "agw:read",
79623
+ "agw:run",
79624
+ "agw:write",
79625
+ "ai:read",
79626
+ "ai:write",
79627
+ "ai-search:read",
79628
+ "ai-search:run",
79629
+ "ai-search:write",
79630
+ "aiaudit:read",
79631
+ "aiaudit:write",
79632
+ "aig:read",
79633
+ "aig:write",
79634
+ "auditlogs:read",
79635
+ "billing:read",
79636
+ "billing:write",
79637
+ "browser:read",
79638
+ "browser:write",
79639
+ "cfone:read",
79640
+ "cfone:write",
79641
+ "cloudchamber:write",
79642
+ "connectivity:admin",
79643
+ "connectivity:bind",
79644
+ "connectivity:read",
79645
+ "constellation:write",
79646
+ "containers:write",
79647
+ "d1:write",
79648
+ "dex:read",
79649
+ "dex:write",
79650
+ "dns_analytics:read",
79651
+ "dns_records:edit",
79652
+ "dns_records:read",
79653
+ "dns_settings:read",
79654
+ "email_routing:read",
79655
+ "email_routing:write",
79656
+ "email_sending:read",
79657
+ "email_sending:write",
79658
+ "firstpartytags:write",
79659
+ "images:read",
79660
+ "images:write",
79661
+ "lb:edit",
79662
+ "lb:read",
79663
+ "logpush:read",
79664
+ "logpush:write",
79665
+ "mcp_portals:read",
79666
+ "mcp_portals:write",
79667
+ "notebook-examples:read",
79668
+ "notebook-managed:read",
79669
+ "notification:read",
79670
+ "notification:write",
79671
+ "oauth_account_ssl_and_certificates_write",
79672
+ "offline",
79673
+ "openid",
79674
+ "pages:read",
79675
+ "pages:write",
79676
+ "pipelines:read",
79677
+ "pipelines:setup",
79678
+ "pipelines:write",
79679
+ "query_cache:write",
79680
+ "queues:write",
79681
+ "r2_catalog:write",
79682
+ "radar:read",
79683
+ "rag:read",
79684
+ "rag:write",
79685
+ "registrar:read",
79686
+ "registrar:write",
79687
+ "secrets_store:read",
79688
+ "secrets_store:write",
79689
+ "sso-connector:read",
79690
+ "sso-connector:write",
79691
+ "ssl_certs:write",
79692
+ "teams:pii",
79693
+ "teams:read",
79694
+ "teams:secure_location",
79695
+ "teams:write",
79696
+ "url_scanner:read",
79697
+ "url_scanner:write",
79698
+ "user:read",
79699
+ "vectorize:write",
79700
+ "workers:read",
79701
+ "workers:write",
79702
+ "workers_builds:read",
79703
+ "workers_builds:write",
79704
+ "workers_deployments:read",
79705
+ "workers_kv:write",
79706
+ "workers_observability:read",
79707
+ "workers_observability:write",
79708
+ "workers_observability_telemetry:write",
79709
+ "workers_routes:write",
79710
+ "workers_scripts:write",
79711
+ "workers_tail:read",
79712
+ "zone:read",
79713
+ "account-analytics.read",
79714
+ "account-ssl-and-certificates.write",
79715
+ "ssl-and-certificates.read",
79716
+ "ssl-and-certificates.write",
79717
+ "registrar-domains.read",
79718
+ "registrar-domains.admin",
79719
+ "logs.read",
79720
+ "logs.write",
79721
+ "websearch.run",
79722
+ "snippets.read",
79723
+ "snippets.write",
79724
+ "access-acct.read",
79725
+ "access-acct.revoke",
79726
+ "access-acct.write",
79727
+ "access-app.read",
79728
+ "access-app.revoke",
79729
+ "access-app.write",
79730
+ "access-audit-log.read",
79731
+ "access-certificate.read",
79732
+ "access-certificate.write",
79733
+ "access-custom-page.read",
79734
+ "access-custom-page.write",
79735
+ "access-device-posture.read",
79736
+ "access-device-posture.write",
79737
+ "access-group.read",
79738
+ "access-group.write",
79739
+ "access-idp.read",
79740
+ "access-idp.write",
79741
+ "access-key.read",
79742
+ "access-key.write",
79743
+ "access-org.read",
79744
+ "access-org.revoke",
79745
+ "access-org.write",
79746
+ "access-policy-test.read",
79747
+ "access-policy-test.write",
79748
+ "access-policy.read",
79749
+ "access-policy.write",
79750
+ "access-population.read",
79751
+ "access-population.write",
79752
+ "access-saml-certificate.read",
79753
+ "access-saml-certificate.write",
79754
+ "access-scim-log.read",
79755
+ "access-seats.write",
79756
+ "access-service-token.read",
79757
+ "access-service-token.write",
79758
+ "access-ssh-auditing.read",
79759
+ "access-ssh-auditing.write",
79760
+ "access-tag.read",
79761
+ "access-tag.write",
79762
+ "access-users.read",
79763
+ "access-users.write",
79764
+ "access.read",
79765
+ "access.revoke",
79766
+ "access.write",
79767
+ "account-api-gateway.read",
79768
+ "account-api-gateway.write",
79769
+ "account-custom-asset.read",
79770
+ "account-custom-asset.write",
79771
+ "account-custom-error-rules.read",
79772
+ "account-custom-error-rules.write",
79773
+ "account-custom-pages.read",
79774
+ "account-custom-pages.write",
79775
+ "account-disable-esc.read",
79776
+ "account-disable-esc.write",
79777
+ "account-dns-settings.read",
79778
+ "account-dns-settings.write",
79779
+ "account-firewall-access-rules.read",
79780
+ "account-firewall-access-rules.write",
79781
+ "account-logs.read",
79782
+ "account-logs.write",
79783
+ "account-rule-lists.read",
79784
+ "account-rule-lists.write",
79785
+ "account-rulesets.read",
79786
+ "account-rulesets.write",
79787
+ "account-security-center-insights.read",
79788
+ "account-security-center-insights.write",
79789
+ "account-settings.read",
79790
+ "account-settings.write",
79791
+ "account-ssl-and-certificates.read",
79792
+ "account-waf.read",
79793
+ "account-waf.write",
79794
+ "account-waiting-rooms.read",
79795
+ "address-maps.read",
79796
+ "address-maps.write",
79797
+ "agent-memory.write",
79798
+ "agw.read",
79799
+ "agw.run",
79800
+ "agw.write",
79801
+ "ai-search.index",
79802
+ "ai-search.metadata_read",
79803
+ "ai-search.read",
79804
+ "ai-search.run",
79805
+ "ai-search.write",
79806
+ "ai.read",
79807
+ "ai.write",
79808
+ "aiaudit.read",
79809
+ "aiaudit.write",
79810
+ "aig.metadata_read",
79811
+ "aig.read",
79812
+ "aig.run",
79813
+ "aig.write",
79814
+ "analytics.read",
79815
+ "api-gateway.read",
79816
+ "api-gateway.write",
79817
+ "apps.write",
79818
+ "argotunnel.read",
79819
+ "argotunnel.write",
79820
+ "artifacts.read",
79821
+ "artifacts.write",
79822
+ "bot-management-feedback.read",
79823
+ "bot-management-feedback.write",
79824
+ "bot-management.read",
79825
+ "bot-management.write",
79826
+ "browser-rendering.read",
79827
+ "browser-rendering.write",
79828
+ "cache-settings.read",
79829
+ "cache-settings.write",
79830
+ "cache.purge",
79831
+ "calls.read",
79832
+ "calls.write",
79833
+ "casb.read",
79834
+ "casb.write",
79835
+ "cf-agents.read",
79836
+ "cf-agents.write",
79837
+ "challenge-widgets.read",
79838
+ "challenge-widgets.write",
79839
+ "chinanetwork-steering.read",
79840
+ "chinanetwork-steering.write",
79841
+ "cloud-connector.read",
79842
+ "cloud-connector.write",
79843
+ "cloud-email-security.read",
79844
+ "cloud-email-security.write",
79845
+ "cloudchamber.read",
79846
+ "cloudchamber.write",
79847
+ "cloudforce-one.read",
79848
+ "cloudforce-one.write",
79849
+ "config-settings.read",
79850
+ "config-settings.write",
79851
+ "connectivity-directory.admin",
79852
+ "connectivity-directory.bind",
79853
+ "connectivity-directory.read",
79854
+ "constellation.read",
79855
+ "constellation.write",
79856
+ "containers.read",
79857
+ "containers.write",
79858
+ "custom-errors.read",
79859
+ "custom-errors.write",
79860
+ "custom-pages.read",
79861
+ "custom-pages.write",
79862
+ "d1.metadata_read",
79863
+ "d1.read",
79864
+ "d1.write",
79865
+ "ddos-botnet-feed.read",
79866
+ "ddos-botnet-feed.write",
79867
+ "ddos-protection.read",
79868
+ "ddos-protection.write",
79869
+ "dls.read",
79870
+ "dls.write",
79871
+ "dns-firewall.read",
79872
+ "dns-firewall.write",
79873
+ "dns-view.read",
79874
+ "dns-view.write",
79875
+ "dns.read",
79876
+ "dns.write",
79877
+ "domain-page-shield.read",
79878
+ "domain-page.shield",
79879
+ "dynamic-redirect.read",
79880
+ "dynamic-redirect.write",
79881
+ "email-routing-account-rule.read",
79882
+ "email-routing-address.read",
79883
+ "email-routing-address.write",
79884
+ "email-routing-rule.read",
79885
+ "email-routing-rule.write",
79886
+ "email-routing-suppression.read",
79887
+ "email-routing-suppression.write",
79888
+ "email-security-dmarcreports.read",
79889
+ "email-security-dmarcreports.write",
79890
+ "email-sending.read",
79891
+ "email-sending.write",
79892
+ "fbm.admin",
79893
+ "fbm.read",
79894
+ "fbm.write",
79895
+ "field-extractor.read",
79896
+ "field-extractor.write",
79897
+ "firewall-for-ai.read",
79898
+ "firewall-for-ai.write",
79899
+ "firewall-services.read",
79900
+ "firewall-services.write",
79901
+ "flagship.evaluate",
79902
+ "flagship.read",
79903
+ "flagship.write",
79904
+ "fraud-detection-pii.read",
79905
+ "fraud-detection.read",
79906
+ "fraud-detection.write",
79907
+ "fraud-events.write",
79908
+ "fraud-feedback.read",
79909
+ "fraud-feedback.write",
79910
+ "healthcheck.read",
79911
+ "healthcheck.write",
79912
+ "http-applications.read",
79913
+ "http-applications.write",
79914
+ "http-ddos-managed-ruleset.read",
79915
+ "http-ddos-managed-ruleset.write",
79916
+ "images.metadata_read",
79917
+ "images.read",
79918
+ "images.write",
79919
+ "integration.write",
79920
+ "intel.read",
79921
+ "intel.write",
79922
+ "iot.read",
79923
+ "iot.write",
79924
+ "ip-prefix-bgp-on-demand.read",
79925
+ "ip-prefix-bgp-on-demand.write",
79926
+ "ip-prefix.read",
79927
+ "ip-prefix.write",
79928
+ "l4-ddos-managed-ruleset.read",
79929
+ "l4-ddos-managed-ruleset.write",
79930
+ "load-balancers-account.read",
79931
+ "load-balancers-account.write",
79932
+ "load-balancers.read",
79933
+ "load-balancers.write",
79934
+ "load-balancing-monitors-and-pools.read",
79935
+ "load-balancing-monitors-and-pools.write",
79936
+ "magic-firewall.read",
79937
+ "magic-firewall.write",
79938
+ "magic-transit.read",
79939
+ "magic-transit.write",
79940
+ "magic-wan.read",
79941
+ "magic-wan.write",
79942
+ "managed-headers.read",
79943
+ "managed-headers.write",
79944
+ "mass-url-redirects.read",
79945
+ "mass-url-redirects.write",
79946
+ "mcp-portals.read",
79947
+ "mcp-portals.write",
79948
+ "memberships.read",
79949
+ "memberships.write",
79950
+ "messaging.edit",
79951
+ "messaging.metadata_read",
79952
+ "messaging.read",
79953
+ "moq.read",
79954
+ "moq.write",
79955
+ "notifications.read",
79956
+ "notifications.write",
79957
+ "origin.read",
79958
+ "origin.write",
79959
+ "page-rules.read",
79960
+ "page-rules.write",
79961
+ "page-shield.read",
79962
+ "page.read",
79963
+ "page.shield",
79964
+ "page.write",
79965
+ "pages.metadata_read",
79966
+ "payments-gateway.read",
79967
+ "payments-gateway.write",
79968
+ "pcaps-api.read",
79969
+ "pcaps-api.write",
79970
+ "pipelines.read",
79971
+ "pipelines.send",
79972
+ "pipelines.write",
79973
+ "precursor.read",
79974
+ "precursor.write",
79975
+ "pubsub.read",
79976
+ "pubsub.write",
79977
+ "query-cache.read",
79978
+ "query-cache.write",
79979
+ "queues.metadata_read",
79980
+ "queues.read",
79981
+ "queues.write",
79982
+ "r2-catalog-sql.read",
79983
+ "r2-catalog.read",
79984
+ "r2-catalog.write",
79985
+ "radar.read",
79986
+ "rag.read",
79987
+ "rag.run",
79988
+ "rag.write",
79989
+ "realtime.admin",
79990
+ "realtime.read",
79991
+ "realtime.write",
79992
+ "registrar-sandbox-domains.admin",
79993
+ "registrar-sandbox-domains.read",
79994
+ "reports-application-security-report.read",
79995
+ "request-tracer.read",
79996
+ "resource-library.read",
79997
+ "resource-library.write",
79998
+ "resource-sharing.read",
79999
+ "response-compression.read",
80000
+ "response-compression.write",
80001
+ "sanitize.read",
80002
+ "sanitize.write",
80003
+ "secrets-store.read",
80004
+ "secrets-store.write",
80005
+ "select-configuration.read",
80006
+ "select-configuration.write",
80007
+ "stream.metadata_read",
80008
+ "stream.read",
80009
+ "stream.write",
80010
+ "tag.read",
80011
+ "tag.write",
80012
+ "teams-cds-compute-account.read",
80013
+ "teams-cds-compute-account.write",
80014
+ "teams-connector-cloudflared.monitoring",
80015
+ "teams-connector-cloudflared.read",
80016
+ "teams-connector-cloudflared.write",
80017
+ "teams-connector-warp.read",
80018
+ "teams-connector-warp.write",
80019
+ "teams-connectors.read",
80020
+ "teams-connectors.write",
80021
+ "teams-dex.read",
80022
+ "teams-dex.write",
80023
+ "teams-networks.read",
80024
+ "teams-networks.write",
80025
+ "teams-pii.read",
80026
+ "teams-resilience.read",
80027
+ "teams-resilience.write",
80028
+ "teams-secure.location",
80029
+ "teams.read",
80030
+ "teams.report",
80031
+ "teams.write",
80032
+ "transform-rules.read",
80033
+ "transform-rules.write",
80034
+ "trust-and-safety.read",
80035
+ "trust-and-safety.write",
80036
+ "url-scanner.read",
80037
+ "url-scanner.write",
80038
+ "user-details.read",
80039
+ "user-details.write",
80040
+ "vectorize.read",
80041
+ "vectorize.write",
80042
+ "waiting-rooms.read",
80043
+ "waiting-rooms.write",
80044
+ "web3-hostnames.read",
80045
+ "web3-hostnames.write",
80046
+ "websearch.metadata_read",
80047
+ "websearch.read",
80048
+ "websearch.write",
80049
+ "workers-ci.read",
80050
+ "workers-ci.write",
80051
+ "workers-kv-storage.metadata_read",
80052
+ "workers-kv-storage.read",
80053
+ "workers-kv-storage.write",
80054
+ "workers-observability-telemetry.write",
80055
+ "workers-observability.read",
80056
+ "workers-observability.write",
80057
+ "workers-r2-bucket-item.read",
80058
+ "workers-r2-bucket-item.write",
80059
+ "workers-r2.metadata_read",
80060
+ "workers-r2.read",
80061
+ "workers-r2.write",
80062
+ "workers-routes.read",
80063
+ "workers-routes.write",
80064
+ "workers-scripts.bind",
80065
+ "workers-scripts.read",
80066
+ "workers-scripts.write",
80067
+ "workers-tail.read",
80068
+ "workers_ai.metadata_read",
80069
+ "zaraz.edit",
80070
+ "zaraz.read",
80071
+ "zaraz.write",
80072
+ "zone-access.read",
80073
+ "zone-access.revoke",
80074
+ "zone-access.write",
80075
+ "zone-custom-asset.read",
80076
+ "zone-custom-asset.write",
80077
+ "zone-disable-esc.read",
80078
+ "zone-disable-esc.write",
80079
+ "zone-dns-settings.read",
80080
+ "zone-dns-settings.write",
80081
+ "zone-security-center-insights.read",
80082
+ "zone-security-center-insights.write",
80083
+ "zone-settings.read",
80084
+ "zone-settings.write",
80085
+ "zone-transform-rules.read",
80086
+ "zone-transform-rules.write",
80087
+ "zone-versioning.read",
80088
+ "zone-versioning.write",
80089
+ "zone-waf.read",
80090
+ "zone-waf.write",
80091
+ "zone.read",
80092
+ "zone.write"
80093
+ ];
80094
+ var DefaultScopeKeys$1 = [...[
79560
80095
  "openid",
79561
80096
  "offline",
79562
80097
  "user:read",
@@ -79645,13 +80180,12 @@ var CF_SCOPES = [
79645
80180
  "workers_scripts:write",
79646
80181
  "workers_tail:read",
79647
80182
  "zone:read"
79648
- ];
79649
- var DefaultScopeKeys$1 = [...CF_SCOPES];
80183
+ ]];
79650
80184
  function setLoginScopeKeys$1(scopes) {
79651
80185
  DefaultScopeKeys$1 = scopes;
79652
80186
  }
79653
80187
  __name$1(setLoginScopeKeys$1, "setLoginScopeKeys");
79654
- var CF_SCOPE_SET = new Set(CF_SCOPES);
80188
+ var CF_SCOPE_SET = new Set(CF_REGISTERED_SCOPES);
79655
80189
  function validateScopeKeys$1(scopes) {
79656
80190
  return scopes.every((scope) => CF_SCOPE_SET.has(scope));
79657
80191
  }
@@ -79680,12 +80214,13 @@ var CF_CLI = {
79680
80214
  login: "cf auth login",
79681
80215
  whoami: "cf auth whoami",
79682
80216
  createProfile: "cf auth create",
79683
- deviceLogin: "cf auth login --device"
80217
+ deviceLogin: "cf auth login"
79684
80218
  },
79685
80219
  keyringServiceName: CF_KEYRING_SERVICE_NAME,
79686
80220
  clientId: getClientIdFromEnv$1,
79687
80221
  consent: CF_CONSENT_PAGES,
79688
80222
  redirectUri: CF_OAUTH_CALLBACK_URL,
80223
+ useDeviceFlowByDefault: true,
79689
80224
  allowGlobalAuthKey: false,
79690
80225
  getConfigPath: getCfConfigPath,
79691
80226
  getTemporaryAccountConfigPath: getCfTemporaryAccountConfigPath,
@@ -79740,7 +80275,6 @@ var DefaultScopes = {
79740
80275
  "ai:write": "See and change Workers AI catalog and assets",
79741
80276
  "ai-search:write": "See and change AI Search data",
79742
80277
  "ai-search:run": "Run search queries on your AI Search instances",
79743
- "websearch.run": "Run search queries against Cloudflare Web Search",
79744
80278
  "agent-memory:write": "See and change Agent Memory data such as keys and namespaces.",
79745
80279
  "queues:write": "See and change Cloudflare Queues settings and data",
79746
80280
  "pipelines:write": "See and change Cloudflare Pipelines configurations and data",
@@ -79967,7 +80501,7 @@ var require_command_exists = /* @__PURE__ */ __commonJS$2({ "../../node_modules/
79967
80501
  }) });
79968
80502
 
79969
80503
  //#endregion
79970
- //#region ../deploy-helpers/dist/chunk-3G6JZQDH.mjs
80504
+ //#region ../deploy-helpers/dist/chunk-QBZBEHZB.mjs
79971
80505
  var import_undici$1 = require_undici();
79972
80506
  var import_command_exists = require_command_exists();
79973
80507
  function handleUnsafeCapnp(capnp) {
@@ -80044,7 +80578,6 @@ function createWorkerUploadForm(worker, bindings, options) {
80044
80578
  const vectorize = extractBindingsOfType("vectorize", bindings);
80045
80579
  const ai_search_namespaces = extractBindingsOfType("ai_search_namespace", bindings);
80046
80580
  const ai_search = extractBindingsOfType("ai_search", bindings);
80047
- const websearch = extractBindingsOfType("websearch", bindings)[0];
80048
80581
  const agent_memory = extractBindingsOfType("agent_memory", bindings);
80049
80582
  const hyperdrive = extractBindingsOfType("hyperdrive", bindings);
80050
80583
  const secrets_store_secrets = extractBindingsOfType("secrets_store_secret", bindings);
@@ -80220,10 +80753,6 @@ function createWorkerUploadForm(worker, bindings, options) {
80220
80753
  instance_name
80221
80754
  });
80222
80755
  });
80223
- if (websearch !== void 0) metadataBindings.push({
80224
- name: websearch.binding,
80225
- type: "websearch"
80226
- });
80227
80756
  agent_memory.forEach(({ binding, namespace }) => {
80228
80757
  if (options?.dryRun) namespace ??= INHERIT_SYMBOL;
80229
80758
  if (namespace === void 0) throw new UserError(`${binding} bindings must have a "namespace" field. Add a "namespace" field to the binding in your Worker configuration specifying the namespace to bind to.`, { telemetryMessage: false });
@@ -80527,7 +81056,7 @@ __name(createWorkerUploadForm, "createWorkerUploadForm");
80527
81056
  //#endregion
80528
81057
  //#region ../remote-bindings/dist/index.mjs
80529
81058
  var import_undici = require_undici();
80530
- var version$2 = "0.0.24";
81059
+ var version$2 = "0.0.26";
80531
81060
  var NoDefaultValueProvided = class extends UserError {
80532
81061
  constructor() {
80533
81062
  super("This command cannot be run in a non-interactive context", { telemetryMessage: "remote bindings prompt default missing" });