Compare commits

..
19 Commits
Author SHA1 Message Date
Danny MurphyandZoltan Kochan 73e46992e0 docs: clarify manifest-based version selection (#244)
* updating readme to include devEngines.packageManager.version in selecting version

* docs: check out the manifest before inferring pnpm version

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2026-11-03 14:48:37 +01:00
Zoltan Kochan c05d46d6ff fix: skip saving missing cache directories (#294)
* fix: skip saving missing cache directories

* ci: run cache regression tests on Node.js 24
2026-11-03 14:40:50 +01:00
Andreas Deininger 343d2b1d95 Bump GitHub action workflows (#223) 2026-11-03 14:32:29 +01:00
rstacruz25andRico Sta. Cruz 9a15f15afb fix: update pnpm 11 bootstrap to 11.28.10 (#292)
Co-authored-by: Rico Sta. Cruz <rstacruz25@users.noreply.github.com>
2026-11-03 14:31:54 +01:00
Zoltan Kochan 7cf8c4cab0 fix: refresh native bootstrap and test shared store reuse (#293)
* fix: refresh native bootstrap and test shared store reuse

* fix: initialize shared store paths in a workflow step

* test: verify installed versions outside the pinned project
2026-11-03 11:33:56 +01:00
Zoltan Kochan ea17c68df8 feat: support pnpm v12 (#288)
* feat: support pnpm v12

Approve the pinned @pnpm/exe install script for npm 12, add pnpm 12 coverage across supported runner platforms, and clarify that action-setup remains supported alongside pnpm/setup.

* refactor: use pnpm 12 native bootstrap

Install the plain pnpm v12 package as the single native bootstrap, remove the legacy @pnpm/exe lockfile and runtime path, and retain the standalone input as a no-op for workflow compatibility.

* fix: keep bootstrap updates on pnpm 12

Handle npm's array-shaped view output and resolve only pnpm 12 distribution tags.

* fix: use native bootstrap only for pnpm 12

Route pnpm 12-only versions and ranges through the plain pnpm native package while preserving the existing Node and @pnpm/exe bootstrap paths for older releases.

* style: remove updater narrative comments
2026-09-05 01:42:41 +02:00
Eric Nemchik 0977fd9972 docs: Update README to include devEngines.packageManager (#273)
Support added in #211 and #256
2026-08-03 13:44:13 +02:00
Jamie TannaandClaude Sonnet 5 48261aca05 fix: update pnpm to v11.19.0 (#283)
* fix: update pnpm to v11.19.0

Via `scripts/update-bootstrap.mjs 11.19.0`

Co-authored-by: Claude Sonnet 5 <jamie.tanna+claude-code@mend.io>

* fixup! fix: update pnpm to v11.19.0

As it needs to be rebuilt on Linux.

---------

Co-authored-by: Claude Sonnet 5 <jamie.tanna+claude-code@mend.io>
2026-08-03 11:54:52 +02:00
Jamie Tanna 75677f717d ci: use pnpm 11 for pr-check (#284)
Noticed while working on #283.
2026-08-03 11:02:17 +02:00
Sukka 769ae71fb3 refactor: introduce restore keys for cache (#280) 2026-08-03 10:32:23 +02:00
Kevin Cui 6fed91f804 docs(README): point users to the successor pnpm/setup action (#282)
* docs(README): point users to the successor pnpm/setup action

The pnpm setup action has moved to `pnpm/setup`, which installs
pnpm v11+ as a self-contained native executable and can install a
JavaScript runtime (Node.js, Bun, or Deno) in the same step,
replacing `actions/setup-node`.

Add a notice at the top of the README, a migration section with a
before/after workflow example and an input/output mapping table,
and mention the successor in the Notes section. The rest of the
docs stay intact since `pnpm/action-setup` remains the way to
install pnpm v10 and older.

Signed-off-by: Kevin Cui <bh@bugs.cc>

* docs(README): address review feedback on migration section

Add an explicit version: 11 to the migration example and note when the
input can be omitted, since pnpm/setup requires pnpm v11+ and a repo
migrating from version: 10 may have no packageManager field or one that
pins v10.

Move the v2 upgrade warning below the page title so the two callouts
are no longer adjacent blockquotes (markdownlint MD028), keeping the
successor notice and the legacy warning as separate blocks.

Fix the comma splice and use "set up" as the verb in the Notes
section.

Signed-off-by: Kevin Cui <bh@bugs.cc>

---------

Signed-off-by: Kevin Cui <bh@bugs.cc>
2026-08-02 22:56:56 -04:00
Zoltan Kochan 0ebf47130e fix: update pnpm to v11.7.0 (#267)
* fix: update pnpm to v11.7.0

* fix: update bundle
2026-06-15 14:04:13 +02:00
mungodewarandZoltan Kochan 0e279bb959 fix: update pnpm to 11.1.1 (#248)
* fix: update pnpm to v11.1.1

* fix: update bundle

---------

Co-authored-by: Zoltan Kochan <z@kochan.io>
2026-05-12 14:32:25 +02:00
Zoltan Kochan 3e835812ef fix: drop patchPnpmEnv so standalone+self-update works on Windows (#258)
`patchPnpmEnv` prepended `dest/node_modules/.bin` to PATH before
spawning `pnpm install` / `pnpm store prune`. On Windows in standalone
mode, `.bin/pnpm.cmd` is an npm-created shim that always points at the
BOOTSTRAP pnpm (currently 11.0.4) — the binary npm linked when it
installed `@pnpm/exe` into `node_modules`. The self-updated pnpm
written by `pnpm self-update` lives at `$PNPM_HOME/bin`, which is
separately added to PATH via `addPath()` in install-pnpm.

When the user requested a pnpm version different from the bootstrap
under `standalone: true` on Windows, patchPnpmEnv's `.bin` entry
shadowed the self-updated `$PNPM_HOME/bin` and the action's internal
`pnpm install` ran on the bootstrap. On a pnpm 11.0.x bootstrap this
broke any 11.1+ install flag (e.g. `--no-runtime`), reporting:

    ERROR  Unknown option: 'runtime'

POSIX standalone got lucky because `.bin` and `$PNPM_HOME` resolve to
the same directory there. Non-standalone never tripped on this since
the `.bin/pnpm` symlink for a regular `pnpm` package keeps working
across self-updates.

Removed `patchPnpmEnv` and the now-empty `src/utils/` module.
`spawnSync` now inherits `process.env`, whose PATH is already
correctly fronted by `$PNPM_HOME/bin` and `$PNPM_HOME` via the
`addPath` calls in install-pnpm.

Added `standalone_windows_self_update` to test.yaml as a regression
guard: standalone on Windows + target 11.1.0 + `run_install` with
`--no-runtime`. With the previous code, the install would have run
under the bootstrap (11.0.4) and errored on the unknown flag.

Originally found while building pnpm/setup (the new combined
pnpm + runtime action).
2026-05-11 22:48:51 +02:00
Andrew Haines 551b42e879 docs(README): fix cache_dependency_path type (#257)
* docs(README): fix `cache_dependency_path` type

* docs(README): add multiple lockfile example

* docs: update input description to match README
2026-05-11 16:41:41 +02:00
Zoltan Kochan 739bfe42ca fix: self-update bootstrap to packageManager-pinned version (#233) (#256)
* fix: self-update bootstrap to packageManager-pinned version (#233)

When package.json pins pnpm via `packageManager` or an exact
`devEngines.packageManager.version`, self-update the bootstrap up
front. The bootstrap's `pnpm store path` skips pnpm's auto-switch
(the `store` command sets `skipPackageManagerCheck = true`), so it
reports the bootstrap's `STORE_VERSION` while the user's actual
install runs under the pinned version and writes to a different
STORE_VERSION — breaking `cache: true` and `setup-node`'s
`cache: pnpm` on cold caches.

* fix: check bin/ dir instead of pnpm.exe for self-update detection

On Windows pnpm self-update writes `.bin/bin/pnpm` (a JS launcher),
not `.bin/bin/pnpm.exe`, so the previous existsSync probe always
fell back to pnpmHome and the bin_dest output pointed at the
bootstrap pnpm. Check whether the `bin` directory itself exists.

* fix: self-update accepts ranges; drop exact-semver gate

`pnpm self-update` resolves semver ranges to a specific version, so
`devEngines.packageManager.version: ">=10 <11"` can also go through
the self-update path. That makes readTargetVersion total — it always
returns a string or throws — so the runtime auto-switch fallback (and
the `pnpm_config_pm_on_fail=download` export from #252) is no longer
reachable and gets removed.

Adds a range case to the cache_store_path matrix.
2026-05-11 14:06:33 +02:00
Zoltan Kochan f61705d907 chore: add CODEOWNERS 2026-05-11 12:46:12 +02:00
Andrew Haines 7a5507b117 fix: restore inputs from state in post (#255) 2026-05-11 12:44:49 +02:00
Zoltan Kochan 1155470f3e fix: honor devEngines.packageManager.onFail=error (#252) (#254)
## Summary
- Export `pnpm_config_pm_on_fail=download` from the action so the bootstrap pnpm switches versions via `manage-package-manager-versions` instead of throwing `BAD_PM_VERSION` when a project pins `devEngines.packageManager.onFail = "error"` without supplying a `version:` input.
- Adds a `test_dev_engines_on_fail_error` workflow job (Linux/macOS/Windows, exact + range) that reproduces #252.

Fixes #252.
2026-05-11 01:51:30 +02:00
20 changed files with 1079 additions and 584 deletions

No files matched your search

+1
View File
@@ -0,0 +1 @@
* @zkochan
+10 -3
View File
@@ -13,13 +13,20 @@ jobs:
check-dist: check-dist:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Setup pnpm - name: Setup pnpm
uses: pnpm/action-setup@fc06bc1257f339d1d5d8b3a19a8cae5388b55320 # v5.0.0 uses: pnpm/action-setup@ea17c68df8912ef543352723c149a84f56e3d413 # v6.1.0
with: with:
run_install: true run_install: true
version: 9 version: 11
- uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6
with:
node-version: 24
- name: Test
run: pnpm test
- name: Update dist/index.js - name: Update dist/index.js
run: pnpm run build run: pnpm run build
+332 -257
View File
@@ -1,43 +1,85 @@
name: Test Action name: Test Action
on: on:
- push pull_request:
- pull_request push:
- workflow_dispatch branches:
- master
workflow_dispatch:
jobs: jobs:
test_default_inputs: smoke:
name: Test with default inputs # Cross-OS coverage. Exercises the bootstrap install + PATH on each platform,
# the version-respects-request regression (#225 / #230 — Windows PATH shadow),
# and the bin_dest output regression (#247). Multi-version coverage on Linux
# so we don't pay 3x for major-version differences.
name: 'Smoke (${{ matrix.name }})'
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
pnpm: include:
- 9.15.5 - name: 'ubuntu / v9.15.5'
os: os: ubuntu-latest
- ubuntu-latest version: '9.15.5'
- macos-latest - name: 'ubuntu / v10.33.0'
- windows-latest os: ubuntu-latest
version: '10.33.0'
- name: 'ubuntu / v11.25.0'
os: ubuntu-latest
version: '11.25.0'
- name: 'ubuntu / v12.3.4'
os: ubuntu-latest
version: '12.3.4'
- name: 'ubuntu / v9.15.5 / custom-dest'
os: ubuntu-latest
version: '9.15.5'
dest: '~/test/pnpm'
- name: 'macos / v9.15.5'
os: macos-latest
version: '9.15.5'
- name: 'macos / v12.3.4'
os: macos-latest
version: '12.3.4'
- name: 'windows / v9.15.5'
os: windows-latest
version: '9.15.5'
- name: 'windows / v12.3.4'
os: windows-latest
version: '12.3.4'
steps: steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Run the action - id: pnpm
name: Run the action
uses: ./ uses: ./
with: with:
version: 9.15.5 version: ${{ matrix.version }}
dest: ${{ matrix.dest || '~/setup-pnpm' }}
- name: 'Test: which' - name: 'Test: pnpm/pnpx on PATH report the requested version (incl. via bin_dest)'
run: which pnpm; which pnpx # Pass paths via env, not template interpolation, so Windows
# backslashes in `bin_dest` aren't eaten by bash's escape handling.
- name: 'Test: version' env:
BIN_DEST: ${{ steps.pnpm.outputs.bin_dest }}
REQUIRED: ${{ matrix.version }}
run: | run: |
set -e
which pnpm
which pnpx
actual="$(pnpm --version)" actual="$(pnpm --version)"
echo "pnpm version: ${actual}" echo "pnpm --version: ${actual}"
if [[ ! "${actual}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-.+)?$ ]]; then if [ "${actual}" != "${REQUIRED}" ]; then
echo "ERROR: pnpm --version did not produce valid output" echo "Expected pnpm version ${REQUIRED}, but got ${actual}"
exit 1
fi
bin_dest_version="$("$BIN_DEST/pnpm" --version)"
echo "bin_dest pnpm --version: ${bin_dest_version}"
if [ "${bin_dest_version}" != "${REQUIRED}" ]; then
echo "Expected ${REQUIRED} via bin_dest, but got ${bin_dest_version}"
exit 1 exit 1
fi fi
shell: bash shell: bash
@@ -50,268 +92,302 @@ jobs:
pnpm add is-odd pnpm add is-odd
shell: bash shell: bash
test_dest: manifest_pin:
name: Test with dest # Folds the old test_package_manager_field, test_dev_engines, and
# test_dev_engines_on_fail_error jobs. The action's manifest handling is
# OS-independent, so ubuntu-only is sufficient.
name: 'Manifest pin: ${{ matrix.label }}'
runs-on: ${{ matrix.os }} runs-on: ubuntu-latest
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
pnpm: include:
- 9.15.5 - label: 'packageManager pnpm@9.15.5 (#227)'
os: manifest: '{"packageManager":"pnpm@9.15.5"}'
- ubuntu-latest version: '9.15.5'
- macos-latest - label: 'packageManager pnpm@10.33.0'
- windows-latest manifest: '{"packageManager":"pnpm@10.33.0"}'
version: '10.33.0'
- label: 'devEngines onFail=download, exact'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":"9.15.5","onFail":"download"}}}'
version: '9.15.5'
- label: 'devEngines onFail=download, range'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":">=9.15.0","onFail":"download"}}}'
version: '>=9.15.0'
- label: 'devEngines onFail=error, exact (#252)'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":"9.15.5","onFail":"error"}}}'
version: '9.15.5'
- label: 'devEngines onFail=error, range (#252)'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":">=9.15.0","onFail":"error"}}}'
version: '>=9.15.0'
- label: 'explicit version: pnpm_config_pm_on_fail not exported'
# Regression guard for the af8e203 scope fix: when the user passes an
# explicit `version:` input, the action must NOT export
# pnpm_config_pm_on_fail=download, so the user's strict onFail policy
# is preserved. Asserted directly on the env var rather than pnpm
# runtime behavior — different pnpm majors read devEngines
# differently (v10 ignores it, v11+ honors it).
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":"9.15.5","onFail":"error"}}}'
explicit_version: '10.33.0'
expect_pm_on_fail_unset: true
steps: steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up package.json
run: echo '${{ matrix.manifest }}' > package.json
shell: bash
- name: Run the action - name: Run the action
uses: ./ uses: ./
with: with:
version: 9.15.5 version: ${{ matrix.explicit_version }}
dest: ~/test/pnpm
- name: 'Test: which' - name: 'Test: pnpm reports the pinned version'
run: which pnpm && which pnpx if: ${{ !matrix.expect_pm_on_fail_unset }}
- name: 'Test: version'
run: |
actual="$(pnpm --version)"
echo "pnpm version: ${actual}"
if [[ ! "${actual}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-.+)?$ ]]; then
echo "ERROR: pnpm --version did not produce valid output"
exit 1
fi
shell: bash
test_standalone:
name: Test with standalone
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- name: Run the action
uses: ./
with:
version: 9.15.0
standalone: true
- name: 'Test: which'
run: which pnpm
- name: 'Test: version'
run: |
actual="$(pnpm --version)"
echo "pnpm version: ${actual}"
if [[ ! "${actual}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-.+)?$ ]]; then
echo "ERROR: pnpm --version did not produce valid output"
exit 1
fi
shell: bash
- name: 'Test: install in a fresh project'
run: |
mkdir /tmp/test-standalone
cd /tmp/test-standalone
pnpm init
pnpm add is-odd
shell: bash
test_version_respects_request:
name: 'Test version input is actually installed (${{ matrix.version }}, ${{ matrix.os }})'
# Regression test for #225 / #230: the bootstrap pnpm on PATH was shadowing the self-updated binary,
# so a user requesting e.g. `version: 9.15.5` would silently get the bootstrap version.
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
version:
- '9.15.5'
- '10.33.0'
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- name: Run the action
uses: ./
with:
version: ${{ matrix.version }}
- name: 'Test: exact version installed'
run: |
required='${{ matrix.version }}'
actual="$(pnpm --version)"
echo "pnpm version: ${actual}"
if [ "${actual}" != "${required}" ]; then
echo "Expected pnpm version ${required}, but got ${actual}"
exit 1
fi
shell: bash
test_bin_dest_output:
name: 'Test bin_dest output points to requested version (${{ matrix.version }}, ${{ matrix.os }})'
# Regression test for #247: invoking pnpm via the `bin_dest` output returned the
# bootstrap version because self-update writes the target to `${bin_dest}/bin/`,
# not directly into `${bin_dest}/`.
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
version:
- '9.15.5'
- '10.33.2'
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- id: pnpm
name: Run the action
uses: ./
with:
version: ${{ matrix.version }}
- name: 'Test: bin_dest/pnpm reports requested version'
# Pass paths via env, not template interpolation, so Windows
# backslashes in `bin_dest` aren't eaten by bash's escape handling.
env: env:
BIN_DEST: ${{ steps.pnpm.outputs.bin_dest }}
REQUIRED: ${{ matrix.version }} REQUIRED: ${{ matrix.version }}
run: |
actual="$("$BIN_DEST/pnpm" --version)"
echo "pnpm version via bin_dest: ${actual}"
if [ "${actual}" != "${REQUIRED}" ]; then
echo "Expected pnpm version ${REQUIRED}, but got ${actual}"
exit 1
fi
shell: bash
test_package_manager_field:
name: 'Test packageManager field is respected (${{ matrix.version }}, ${{ matrix.os }})'
# Reproduces #227: when `packageManager` is set in package.json and no `version:` input is given,
# the action should install the version specified there.
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
version:
- '9.15.5'
- '10.33.0'
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- name: Set up package.json with packageManager field
run: echo '{"packageManager":"pnpm@${{ matrix.version }}"}' > package.json
shell: bash
- name: Run the action
uses: ./
- name: 'Test: exact version installed'
run: |
required='${{ matrix.version }}'
actual="$(pnpm --version)"
echo "pnpm version: ${actual}"
if [ "${actual}" != "${required}" ]; then
echo "Expected pnpm version ${required}, but got ${actual}"
exit 1
fi
shell: bash
test_dev_engines:
name: Test with devEngines.packageManager
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
version:
- '9.15.5'
- '>=9.15.0'
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
- name: Set up package.json with devEngines.packageManager
run: echo '{"devEngines":{"packageManager":{"name":"pnpm","version":"${{ matrix.version }}","onFail":"download"}}}' > package.json
shell: bash
- name: Run the action
uses: ./
- name: 'Test: which'
run: which pnpm; which pnpx
- name: 'Test: version'
run: | run: |
set -e set -e
required='${{ matrix.version }}'
actual="$(pnpm --version)" actual="$(pnpm --version)"
echo "pnpm version: ${actual}" echo "pnpm version: ${actual}"
if [ "${REQUIRED}" = ">=9.15.0" ]; then
if [ "${required}" = ">=9.15.0" ]; then
min="9.15.0" min="9.15.0"
if [ "$(printf '%s\n' "${min}" "${actual}" | sort -V | head -n1)" != "${min}" ]; then if [ "$(printf '%s\n' "${min}" "${actual}" | sort -V | head -n1)" != "${min}" ]; then
echo "Expected pnpm version >= ${min}, but got ${actual}" echo "Expected pnpm version >= ${min}, but got ${actual}"
exit 1 exit 1
fi fi
else else
if [ "${actual}" != "${required}" ]; then if [ "${actual}" != "${REQUIRED}" ]; then
echo "Expected pnpm version ${required}, but got ${actual}" echo "Expected pnpm version ${REQUIRED}, but got ${actual}"
exit 1 exit 1
fi fi
fi fi
shell: bash shell: bash
test_run_install: - name: 'Test: pnpm_config_pm_on_fail not exported (explicit version preserves strict policy)'
name: 'Test with run_install (${{ matrix.run_install.name }}, ${{ matrix.os }})' if: ${{ matrix.expect_pm_on_fail_unset }}
run: |
if [ -n "${pnpm_config_pm_on_fail:-}" ]; then
echo "Expected pnpm_config_pm_on_fail to be unset, but got: '${pnpm_config_pm_on_fail}'"
exit 1
fi
echo "pnpm_config_pm_on_fail is unset, as expected"
shell: bash
runs-on: ${{ matrix.os }} standalone:
name: 'Native pnpm bootstrap (npm 12)'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- uses: actions/setup-node@249970729cb0ef3589644e2896645e5dc5ba9c38 # v6
with:
node-version: 26
- name: Use npm 12
run: |
npm install --global npm@12.0.2
test "$(npm --version)" = "12.0.2"
- id: pnpm
name: Run the action
uses: ./
with:
version: 12
standalone: true
- name: 'Test: pnpm works'
env:
PNPM_DEST: ${{ steps.pnpm.outputs.dest }}
run: |
set -e
test -x "$PNPM_DEST/node_modules/pnpm/pnpm"
test ! -d "$PNPM_DEST/node_modules/@pnpm/exe"
which pnpm
actual="$(pnpm --version)"
if [ "${actual}" != "12.17.0" ]; then
echo "Expected 12.17.0, got ${actual}"
exit 1
fi
mkdir /tmp/test-standalone
cd /tmp/test-standalone
pnpm init
pnpm add is-odd
shell: bash
shared_store:
name: 'Repeated install with shared store (pnpm ${{ matrix.version }})'
runs-on: ubuntu-latest
permissions:
contents: read
strategy:
fail-fast: false
matrix:
version: ['12.11.2', '12.16.1']
env:
REQUIRED: ${{ matrix.version }}
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Configure the shared store and project pin
run: |
config_home="$RUNNER_TEMP/pnpm-config"
store_dir="$RUNNER_TEMP/pnpm-store"
mkdir -p "$config_home/pnpm"
printf 'storeDir: %s\nenableGlobalVirtualStore: true\n' "$store_dir" > "$config_home/pnpm/config.yaml"
printf 'XDG_CONFIG_HOME=%s\nPNPM_STORE_DIR=%s\n' "$config_home" "$store_dir" >> "$GITHUB_ENV"
printf '{"packageManager":"pnpm@%s"}\n' "$REQUIRED" > package.json
- id: first
name: Install pnpm into a fresh destination
uses: ./
with:
dest: ${{ runner.temp }}/setup-pnpm
standalone: false
- name: Verify the first installation and populated store
working-directory: ${{ runner.temp }}
env:
BIN_DEST: ${{ steps.first.outputs.bin_dest }}
run: |
test "$("$BIN_DEST/pnpm" --version)" = "$REQUIRED"
store_path="$("$BIN_DEST/pnpm" store path --silent)"
case "$store_path/" in
"$PNPM_STORE_DIR/"*) ;;
*) echo "Unexpected store path: $store_path"; exit 1 ;;
esac
test -n "$(find "$PNPM_STORE_DIR" -type f -print -quit)"
touch "$PNPM_STORE_DIR/reused-by-second-install"
- id: second
name: Reinstall pnpm with the same destination and store
uses: ./
with:
dest: ${{ runner.temp }}/setup-pnpm
standalone: false
- name: Verify the second installation reused the store
working-directory: ${{ runner.temp }}
env:
BIN_DEST: ${{ steps.second.outputs.bin_dest }}
run: |
test -f "$PNPM_STORE_DIR/reused-by-second-install"
test "$("$BIN_DEST/pnpm" --version)" = "$REQUIRED"
test "$(pnpm --version)" = "$REQUIRED"
standalone_windows_self_update:
# Regression guard for the patchPnpmEnv PATH-shadow bug. When
# standalone: true on Windows AND the requested pnpm differs from the
# bootstrap, the previous patchPnpmEnv prepended node_modules/.bin to
# PATH; that directory contains an npm-created pnpm.cmd shim pointing
# at the BOOTSTRAP pnpm, which shadowed the self-updated pnpm at
# $PNPM_HOME/bin and caused `pnpm install` inside the action to run
# under the bootstrap version. Exercising a newer-pnpm-only flag
# (`--no-runtime`, added in 11.1.0) makes the regression assertable:
# if the bootstrap (11.0.4) handles the install, it errors with
# "Unknown option: 'runtime'".
name: 'Standalone Windows self-update (PATH regression)'
runs-on: windows-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up package.json with a minimal manifest
# run_install needs a manifest to install against. Removing the
# repo's existing pnpm-lock.yaml avoids frozen-lockfile mismatch.
run: |
rm -f pnpm-lock.yaml
echo '{"name":"sw","private":true,"packageManager":"pnpm@11.1.0"}' > package.json
shell: bash
- name: Run the action
uses: ./
with:
version: 11.1.0
standalone: true
run_install: |
args: ['--no-runtime']
- name: 'Test: pnpm install completed under the self-updated pnpm'
# If the bug recurs, the previous step's run_install will have failed
# the job with "Unknown option: 'runtime'", so reaching this step
# implies success. Still verify the version on PATH matches request.
env:
REQUIRED: '11.1.0'
run: |
set -e
actual="$(pnpm --version)"
echo "pnpm --version: ${actual}"
if [ "${actual}" != "${REQUIRED}" ]; then
echo "Expected pnpm ${REQUIRED}, got ${actual}"
exit 1
fi
shell: bash
cache_store_path:
# Regression guard for #233. When package.json pins a pnpm major that
# differs from the bootstrap pnpm's major, the bootstrap reports its
# own STORE_VERSION from `pnpm store path` (the `store` command skips
# pnpm's auto-switch). The user's actual `pnpm install` runs under the
# pinned version and writes to a different STORE_VERSION, so the post
# step's saveCache then fails with "Path Validation Error". The fix is
# to self-update the bootstrap to the pinned version up front.
name: 'Cache store path matches install (#233): ${{ matrix.label }}'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- label: 'packageManager pnpm@10.33.0'
manifest: '{"packageManager":"pnpm@10.33.0","dependencies":{"is-odd":"3.0.1"}}'
- label: 'devEngines exact pnpm@10.33.0'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":"10.33.0"}},"dependencies":{"is-odd":"3.0.1"}}'
- label: 'devEngines range >=10 <11'
manifest: '{"devEngines":{"packageManager":{"name":"pnpm","version":">=10 <11"}},"dependencies":{"is-odd":"3.0.1"}}'
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up package.json
run: echo '${{ matrix.manifest }}' > package.json
shell: bash
- id: pnpm
uses: ./
with:
cache: true
run_install: |
- args: [--no-frozen-lockfile]
- name: 'Test: store path computed by the action exists on disk'
run: |
set -e
actual="$(pnpm store path --silent)"
echo "pnpm store path: ${actual}"
if [ ! -d "${actual}" ]; then
echo "Expected store path to exist on disk; cache save would fail"
exit 1
fi
shell: bash
run_install:
name: 'run_install (${{ matrix.run_install.name }})'
runs-on: ubuntu-latest
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
pnpm:
- 9.15.5
os:
- ubuntu-latest
- macos-latest
- windows-latest
run_install: run_install:
- name: 'null' - name: 'null'
value: 'null' value: 'null'
@@ -324,7 +400,7 @@ jobs:
- yarn - yarn
steps: steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Run the action - name: Run the action
uses: ./ uses: ./
@@ -332,15 +408,14 @@ jobs:
version: 9.15.5 version: 9.15.5
run_install: ${{ matrix.run_install.value }} run_install: ${{ matrix.run_install.value }}
- name: 'Test: which' - name: 'Test: pnpm works'
run: which pnpm; which pnpx
- name: 'Test: version'
run: | run: |
set -e
which pnpm
which pnpx
actual="$(pnpm --version)" actual="$(pnpm --version)"
echo "pnpm version: ${actual}" if [ "${actual}" != "9.15.5" ]; then
if [[ ! "${actual}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-.+)?$ ]]; then echo "Expected 9.15.5, got ${actual}"
echo "ERROR: pnpm --version did not produce valid output"
exit 1 exit 1
fi fi
shell: bash shell: bash
+91 -10
View File
@@ -1,18 +1,70 @@
> ## :warning: Upgrade from v2! > [!IMPORTANT]
> **This action supports pnpm v12 and earlier.**
> >
> The v2 version of this action [has stopped working](https://github.com/pnpm/action-setup/issues/135) with newer Node.js versions. Please, upgrade to the latest version to fix any issues. > For pnpm v11 and newer, [`pnpm/setup`](https://github.com/pnpm/setup) is also available. It downloads pnpm's self-contained release binary (no Node.js or npm required) and can install a JavaScript runtime (Node.js, Bun, or Deno) in the same step, replacing `actions/setup-node` when its feature set fits your workflow.
>
> You can continue using `pnpm/action-setup` with `actions/setup-node`, including for pnpm v11 and v12. See [Using pnpm/setup instead](#using-pnpmsetup-instead) below if you want a single action to install pnpm and a JavaScript runtime.
>
> `pnpm/setup` cannot install pnpm v11 on Intel macOS (`darwin-x64`), where no standalone pnpm v11 binary is published. On that platform, run `actions/setup-node` with Node.js 22.13 or newer before `pnpm/action-setup`, or upgrade to pnpm v12.
# Setup pnpm # Setup pnpm
Install pnpm package manager. Install pnpm package manager.
> ## :warning: Upgrade from v2!
>
> The v2 version of this action [has stopped working](https://github.com/pnpm/action-setup/issues/135) with newer Node.js versions. Please, upgrade to the latest version to fix any issues.
## Using pnpm/setup instead
[`pnpm/setup`](https://github.com/pnpm/setup) installs pnpm v11+ as a native standalone executable and can install Node.js, Bun, or Deno in the same step, so a typical workflow no longer needs `actions/setup-node` or an explicit `pnpm install` step:
```yaml
steps:
- uses: actions/checkout@v6
# Before:
# - uses: pnpm/action-setup@v6
# with:
# version: 10
# cache: true
# - uses: actions/setup-node@v4
# with:
# node-version: 22
# - run: pnpm install
# After:
- uses: pnpm/setup@v1
with:
version: 11
runtime: node@22
cache: true
```
The `version` input can be omitted only when `packageManager` (or `devEngines.packageManager`) in `package.json` declares pnpm v11 or newer; otherwise keep it explicit, since `pnpm/setup` requires pnpm v11+.
Input and output changes:
| `pnpm/action-setup` | `pnpm/setup` | Notes |
| ------------------- | ------------ | ----- |
| `version` | `version` | Must resolve to pnpm v11 or newer. As before, it can be omitted when `packageManager` (or `devEngines.packageManager`) is set in `package.json`. |
| `dest` | `dest` | Unchanged. |
| `run_install` | `install` | `pnpm/setup` runs `pnpm install` automatically when a `package.json` is present (`install: true` by default); set `install: false` to skip it. The object/array form (`recursive`, `cwd`, `args`) is not supported — run those commands in separate steps. |
| `cache` | `cache` | Unchanged. |
| `cache_dependency_path` | `cache-dependency-path` | Renamed to kebab-case. |
| `package_json_file` | `package-json-file` | Renamed to kebab-case. |
| `standalone` | removed | `pnpm/setup` always installs the standalone native executable. |
| n/a | `runtime` | New: installs Node.js, Bun, or Deno (e.g. `node@22`, `bun@latest`, `deno@2`), or reads `devEngines.runtime` from `package.json`. |
| n/a | `token` | New: GitHub token for release lookup; defaults to `${{ github.token }}` and rarely needs to be set. |
| `bin_dest` (output) | `bin-dest` (output) | Renamed to kebab-case. New outputs `runtime-name` and `runtime-version` describe the installed runtime. |
## Inputs ## Inputs
### `version` ### `version`
Version of pnpm to install. Version of pnpm to install.
**Optional** when there is a [`packageManager` field in the `package.json`](https://nodejs.org/api/corepack.html). **Optional** when `package.json` declares pnpm in `packageManager`, or sets `devEngines.packageManager.name` to `"pnpm"` and provides `devEngines.packageManager.version`.
otherwise, this field is **required** It supports npm versioning scheme, it could be an exact version (such as `10.9.8`), or a version range (such as `10`, `10.x.x`, `10.9.x`, `^10.9.8`, `*`, etc.), or `latest`. otherwise, this field is **required** It supports npm versioning scheme, it could be an exact version (such as `10.9.8`), or a version range (such as `10`, `10.x.x`, `10.9.x`, `^10.9.8`, `*`, etc.), or `latest`.
@@ -48,17 +100,17 @@ If `run_install` is a YAML string representation of either an object or an array
### `cache_dependency_path` ### `cache_dependency_path`
**Optional** (_type:_ `string|string[]`, _default:_ `pnpm-lock.yaml`) File path to the pnpm lockfile, which contents hash will be used as a cache key. **Optional** (_type:_ `string`, _default:_ `pnpm-lock.yaml`) File path to the pnpm lockfile, whose contents hash will be used as a cache key. Accepts multiple paths delimited by newlines.
### `package_json_file` ### `package_json_file`
**Optional** (_type:_ `string`, _default:_ `package.json`) File path to the `package.json`/[`package.yaml`](https://github.com/pnpm/pnpm/pull/1799) to read "packageManager" configuration. **Optional** (_type:_ `string`, _default:_ `package.json`) File path to the `package.json`/[`package.yaml`](https://github.com/pnpm/pnpm/pull/1799) to read `packageManager` or `devEngines.packageManager` configuration.
### `standalone` ### `standalone`
**Optional** (_type:_ `boolean`, _default:_ `false`) When set to true, [@pnpm/exe](https://www.npmjs.com/package/@pnpm/exe), which is a Node.js bundled package, will be installed, enabling using `pnpm` without Node.js. **Optional** (_type:_ `boolean`, _default:_ `false`) For pnpm v11 and earlier, install [@pnpm/exe](https://www.npmjs.com/package/@pnpm/exe), enabling pnpm to run without Node.js.
This is useful when you want to use a incompatible pair of Node.js and pnpm. For pnpm v12, this input has no effect because the plain `pnpm` package already installs a standalone native executable.
## Outputs ## Outputs
@@ -74,7 +126,7 @@ Location of `pnpm` and `pnpx` command.
### Install only pnpm without `packageManager` ### Install only pnpm without `packageManager`
This works when the repo either doesn't have a `package.json` or has a `package.json` but it doesn't specify `packageManager`. This works when the repo either doesn't have a `package.json` or has a `package.json` but it doesn't specify `packageManager` or `devEngines.packageManager`.
```yaml ```yaml
on: on:
@@ -93,7 +145,7 @@ jobs:
### Install only pnpm with `packageManager` ### Install only pnpm with `packageManager`
Omit `version` input to use the version in the [`packageManager` field in the `package.json`](https://nodejs.org/api/corepack.html). Omit `version` input to use the version in the [`packageManager` or `devEngines.packageManager` field in the `package.json`](https://nodejs.org/api/corepack.html).
```yaml ```yaml
on: on:
@@ -105,6 +157,8 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v6 - uses: pnpm/action-setup@v6
``` ```
@@ -158,9 +212,36 @@ jobs:
**Note:** You don't need to run `pnpm store prune` at the end; post-action has already taken care of that. **Note:** You don't need to run `pnpm store prune` at the end; post-action has already taken care of that.
### Cache dependencies from multiple lockfiles
```yaml
on:
- push
- pull_request
jobs:
cache-and-install-multiple:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- uses: pnpm/action-setup@v6
with:
version: 10
cache: true
cache_dependency_path: |
one/pnpm-lock.yaml
two/pnpm-lock.yaml
run_install: |
- cwd: one
- cwd: two
```
## Notes ## Notes
This action does not setup Node.js for you, use [actions/setup-node](https://github.com/actions/setup-node) yourself. This action does not set up Node.js. Use [actions/setup-node](https://github.com/actions/setup-node) yourself. As an alternative for pnpm v11 or newer, [`pnpm/setup`](https://github.com/pnpm/setup) can install pnpm and Node.js in a single step.
## License ## License
+2 -2
View File
@@ -20,7 +20,7 @@ inputs:
required: false required: false
default: 'false' default: 'false'
cache_dependency_path: cache_dependency_path:
description: File path to the pnpm lockfile, which contents hash will be used as a cache key description: File path to the pnpm lockfile, whose contents hash will be used as a cache key. Accepts multiple paths delimited by newlines.
required: false required: false
default: 'pnpm-lock.yaml' default: 'pnpm-lock.yaml'
package_json_file: package_json_file:
@@ -28,7 +28,7 @@ inputs:
required: false required: false
default: 'package.json' default: 'package.json'
standalone: standalone:
description: When set to true, @pnpm/exe, which is a Node.js bundled package, will be installed, enabling using pnpm without Node.js. description: When set to true for pnpm v11 and earlier, install @pnpm/exe to use pnpm without Node.js. pnpm v12 uses the plain pnpm package's native executable.
required: false required: false
default: 'false' default: 'false'
outputs: outputs:
+156 -156
View File
@@ -1,198 +1,198 @@
"use strict";var uK=Object.create;var Mg=Object.defineProperty;var dK=Object.getOwnPropertyDescriptor;var fK=Object.getOwnPropertyNames;var hK=Object.getPrototypeOf,gK=Object.prototype.hasOwnProperty;var mK=(t,e)=>()=>(t&&(e=t(t=0)),e);var h=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),pK=(t,e)=>{for(var r in e)Mg(t,r,{get:e[r],enumerable:!0})},T_=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of fK(e))!gK.call(t,i)&&i!==r&&Mg(t,i,{get:()=>e[i],enumerable:!(n=dK(e,i))||n.enumerable});return t};var pt=(t,e,r)=>(r=t!=null?uK(hK(t)):{},T_(e||!t||!t.__esModule?Mg(r,"default",{value:t,enumerable:!0}):r,t)),xi=t=>T_(Mg({},"__esModule",{value:!0}),t);var Lg=h(jA=>{"use strict";Object.defineProperty(jA,"__esModule",{value:!0});jA.toCommandProperties=jA.toCommandValue=void 0;function yK(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}jA.toCommandValue=yK;function EK(t){return Object.keys(t).length?{title:t.title,file:t.file,line:t.startLine,endLine:t.endLine,col:t.startColumn,endColumn:t.endColumn}:{}}jA.toCommandProperties=EK});var F_=h(jn=>{"use strict";var CK=jn&&jn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),IK=jn&&jn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),BK=jn&&jn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&CK(e,t,r);return IK(e,t),e};Object.defineProperty(jn,"__esModule",{value:!0});jn.issue=jn.issueCommand=void 0;var QK=BK(require("os")),M_=Lg();function L_(t,e,r){let n=new gB(t,e,r);process.stdout.write(n.toString()+QK.EOL)}jn.issueCommand=L_;function bK(t,e=""){L_(t,{},e)}jn.issue=bK;var O_="::",gB=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=O_+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let i=this.properties[n];i&&(r?r=!1:e+=",",e+=`${n}=${wK(i)}`)}}return e+=`${O_}${NK(this.message)}`,e}};function NK(t){return(0,M_.toCommandValue)(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function wK(t){return(0,M_.toCommandValue)(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}});var H_=h(Gn=>{"use strict";var xK=Gn&&Gn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),SK=Gn&&Gn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),pB=Gn&&Gn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&xK(e,t,r);return SK(e,t),e};Object.defineProperty(Gn,"__esModule",{value:!0});Gn.prepareKeyValueMessage=Gn.issueFileCommand=void 0;var vK=pB(require("crypto")),U_=pB(require("fs")),mB=pB(require("os")),q_=Lg();function RK(t,e){let r=process.env[`GITHUB_${t}`];if(!r)throw new Error(`Unable to find environment variable for file command ${t}`);if(!U_.existsSync(r))throw new Error(`Missing file at path: ${r}`);U_.appendFileSync(r,`${(0,q_.toCommandValue)(e)}${mB.EOL}`,{encoding:"utf8"})}Gn.issueFileCommand=RK;function DK(t,e){let r=`ghadelimiter_${vK.randomUUID()}`,n=(0,q_.toCommandValue)(e);if(t.includes(r))throw new Error(`Unexpected input: name should not contain the delimiter "${r}"`);if(n.includes(r))throw new Error(`Unexpected input: value should not contain the delimiter "${r}"`);return`${t}<<${r}${mB.EOL}${n}${mB.EOL}${r}`}Gn.prepareKeyValueMessage=DK});var j_=h(GA=>{"use strict";Object.defineProperty(GA,"__esModule",{value:!0});GA.checkBypass=GA.getProxyUrl=void 0;function _K(t){let e=t.protocol==="https:";if(z_(t))return;let r=e?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY;if(r)try{return new Fg(r)}catch{if(!r.startsWith("http://")&&!r.startsWith("https://"))return new Fg(`http://${r}`)}else return}GA.getProxyUrl=_K;function z_(t){if(!t.hostname)return!1;let e=t.hostname;if(kK(e))return!0;let r=process.env.no_proxy||process.env.NO_PROXY||"";if(!r)return!1;let n;t.port?n=Number(t.port):t.protocol==="http:"?n=80:t.protocol==="https:"&&(n=443);let i=[t.hostname.toUpperCase()];typeof n=="number"&&i.push(`${i[0]}:${n}`);for(let s of r.split(",").map(o=>o.trim().toUpperCase()).filter(oLine truncated "use strict";var t5=Object.create;var nm=Object.defineProperty;var r5=Object.getOwnPropertyDescriptor;var n5=Object.getOwnPropertyNames;var i5=Object.getPrototypeOf,s5=Object.prototype.hasOwnProperty;var o5=(t,e)=>()=>(t&&(e=t(t=0)),e);var h=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),a5=(t,e)=>{for(var r in e)nm(t,r,{get:e[r],enumerable:!0})},Pk=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of n5(e))!s5.call(t,i)&&i!==r&&nm(t,i,{get:()=>e[i],enumerable:!(n=r5(e,i))||n.enumerable});return t};var wt=(t,e,r)=>(r=t!=null?t5(i5(t)):{},Pk(e||!t||!t.__esModule?nm(r,"default",{value:t,enumerable:!0}):r,t)),Li=t=>Pk(nm({},"__esModule",{value:!0}),t);var im=h(nc=>{"use strict";Object.defineProperty(nc,"__esModule",{value:!0});nc.toCommandProperties=nc.toCommandValue=void 0;function A5(t){return t==null?"":typeof t=="string"||t instanceof String?t:JSON.stringify(t)}nc.toCommandValue=A5;function c5(t){return Object.keys(t).length?{title:t.title,file:t.file,line:t.startLine,endLine:t.endLine,col:t.startColumn,endColumn:t.endColumn}:{}}nc.toCommandProperties=c5});var Mk=h(Xn=>{"use strict";var l5=Xn&&Xn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),u5=Xn&&Xn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),d5=Xn&&Xn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&l5(e,t,r);return u5(e,t),e};Object.defineProperty(Xn,"__esModule",{value:!0});Xn.issue=Xn.issueCommand=void 0;var f5=d5(require("os")),Ok=im();function Lk(t,e,r){let n=new GB(t,e,r);process.stdout.write(n.toString()+f5.EOL)}Xn.issueCommand=Lk;function h5(t,e=""){Lk(t,{},e)}Xn.issue=h5;var Tk="::",GB=class{constructor(e,r,n){e||(e="missing.command"),this.command=e,this.properties=r,this.message=n}toString(){let e=Tk+this.command;if(this.properties&&Object.keys(this.properties).length>0){e+=" ";let r=!0;for(let n in this.properties)if(this.properties.hasOwnProperty(n)){let i=this.properties[n];i&&(r?r=!1:e+=",",e+=`${n}=${m5(i)}`)}}return e+=`${Tk}${g5(this.message)}`,e}};function g5(t){return(0,Ok.toCommandValue)(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A")}function m5(t){return(0,Ok.toCommandValue)(t).replace(/%/g,"%25").replace(/\r/g,"%0D").replace(/\n/g,"%0A").replace(/:/g,"%3A").replace(/,/g,"%2C")}});var qk=h(Zn=>{"use strict";var p5=Zn&&Zn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),y5=Zn&&Zn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),JB=Zn&&Zn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&p5(e,t,r);return y5(e,t),e};Object.defineProperty(Zn,"__esModule",{value:!0});Zn.prepareKeyValueMessage=Zn.issueFileCommand=void 0;var E5=JB(require("crypto")),Fk=JB(require("fs")),YB=JB(require("os")),Uk=im();function C5(t,e){let r=process.env[`GITHUB_${t}`];if(!r)throw new Error(`Unable to find environment variable for file command ${t}`);if(!Fk.existsSync(r))throw new Error(`Missing file at path: ${r}`);Fk.appendFileSync(r,`${(0,Uk.toCommandValue)(e)}${YB.EOL}`,{encoding:"utf8"})}Zn.issueFileCommand=C5;function I5(t,e){let r=`ghadelimiter_${E5.randomUUID()}`,n=(0,Uk.toCommandValue)(e);if(t.includes(r))throw new Error(`Unexpected input: name should not contain the delimiter "${r}"`);if(n.includes(r))throw new Error(`Unexpected input: value should not contain the delimiter "${r}"`);return`${t}<<${r}${YB.EOL}${n}${YB.EOL}${r}`}Zn.prepareKeyValueMessage=I5});var jk=h(ic=>{"use strict";Object.defineProperty(ic,"__esModule",{value:!0});ic.checkBypass=ic.getProxyUrl=void 0;function B5(t){let e=t.protocol==="https:";if(Hk(t))return;let r=e?process.env.https_proxy||process.env.HTTPS_PROXY:process.env.http_proxy||process.env.HTTP_PROXY;if(r)try{return new sm(r)}catch{if(!r.startsWith("http://")&&!r.startsWith("https://"))return new sm(`http://${r}`)}else return}ic.getProxyUrl=B5;function Hk(t){if(!t.hostname)return!1;let e=t.hostname;if(Q5(e))return!0;let r=process.env.no_proxy||process.env.NO_PROXY||"";if(!r)return!1;let n;t.port?n=Number(t.port):t.protocol==="http:"?n=80:t.protocol==="https:"&&(n=443);let i=[t.hostname.toUpperCase()];typeof n=="number"&&i.push(`${i[0]}:${n}`);for(let s of r.split(",").map(o=>o.trim().toUpperCase()).filter(oLine truncated
`,u.message,u.stack);var d=new Error("tunneling socket could not be established, cause="+u.message);d.code="ECONNRESET",e.request.emit("error",d),n.removeSocket(i)}};bs.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var n=this.requests.shift();n&&this.createSocket(n,function(i){n.request.onSocket(i)})}};function Y_(t,e){var r=this;bs.prototype.createSocket.call(r,t,function(n){var i=t.request.getHeader("host"),s=EB({},r.options,{socket:n,servername:i?i.replace(/:.*$/,""):t.host}),o=PK.connect(0,s);r.sockets[r.sockets.indexOf(n)]=o,e(o)})}function J_(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function EB(t){for(var e=1,r=arguments.length;e<r;++e){var n=arguments[e];if(typeof n=="object")for(var i=Object.keys(n),s=0,o=i.length;s<o;++s){var a=i[s];n[a]!==void 0&&(t[a]=n[a])}}return t}var ho;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?ho=function(){var t=Array.prototype.slice.call(arguments);typeof t[0]=="string"?t[0]="TUNNEL: "+t[0]:t.unshift("TUNNEL:"),console.error.apply(console,t)}:ho=function(){};YA.debug=ho});var $_=h((u_e,W_)=>{W_.exports=V_()});var yt=h((d_e,K_)=>{K_.exports={kClose:Symbol("close"),kDestroy:Symbol("destroy"),kDispatch:Symbol("dispatch"),kUrl:Symbol("url"),kWriting:Symbol("writing"),kResuming:Symbol("resuming"),kQueue:Symbol("queue"),kConnect:Symbol("connect"),kConnecting:Symbol("connecting"),kHeadersList:Symbol("headers list"),kKeepAliveDefaultTimeout:Symbol("default keep alive timeout"),kKeepAliveMaxTimeout:Symbol("max keep alive timeout"),kKeepAliveTimeoutThreshold:Symbol("keep alive timeout threshold"),kKeepAliveTimeoutValue:Symbol("keep alive timeout"),kKeepAlive:Symbol("keep alive"),kHeadersTimeout:Symbol("headers timeout"),kBodyTimeout:Symbol("body timeout"),kServerName:Symbol("server name"),kLocalAddress:Symbol("local address"),kHost:Symbol("host"),kNoRef:Symbol("no ref"),kBodyUsed:Symbol("used"),kRunning:Symbol("running"),kBlocking:Symbol("blocking"),kPending:Symbol("pending"),kSize:Symbol("size"),kBusy:Symbol("busy"),kQueued:Symbol("queued"),kFree:Symbol("free"),kConnected:Symbol("connected"),kClosed:Symbol("closed"),kNeedDrain:Symbol("need drain"),kReset:Symbol("reset"),kDestroyed:Symbol.for("nodejs.stream.destroyed"),kMaxHeadersSize:Symbol("max headers size"),kRunningIdx:Symbol("running index"),kPendingIdx:Symbol("pending index"),kError:Symbol("error"),kClients:Symbol("clients"),kClient:Symbol("client"),kParser:Symbol("parser"),kOnDestroyed:Symbol("destroy callbacks"),kPipelining:Symbol("pipelining"),kSocket:Symbol("socket"),kHostHeader:Symbol("host header"),kConnector:Symbol("connector"),kStrictContentLength:Symbol("strict content length"),kMaxRedirections:Symbol("maxRedirections"),kMaxRequests:Symbol("maxRequestsPerClient"),kProxy:Symbol("proxy agent options"),kCounter:Symbol("socket request counter"),kInterceptors:Symbol("dispatch interceptors"),kMaxResponseSize:Symbol("max response size"),kHTTP2Session:Symbol("http2Session"),kHTTP2SessionState:Symbol("http2Session state"),kHTTP2BuildRequest:Symbol("http2 build request"),kHTTP1BuildRequest:Symbol("http1 build request"),kHTTP2CopyHeaders:Symbol("http2 copy headers"),kHTTPConnVersion:Symbol("http connection version"),kRetryHandlerDefaultRetry:Symbol("retry agent default retry"),kConstruct:Symbol("constructable")}});var at=h((f_e,X_)=>{"use strict";var zt=class extends Error{constructor(e){super(e),this.name="UndiciError",this.code="UND_ERR"}},CB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="ConnectTimeoutError",this.message=e||"Connect Timeout Error",this.code="UND_ERR_CONNECT_TIMEOUT"}},IB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="HeadersTimeoutError",this.message=e||"Headers Timeout Error",this.code="UND_ERR_HEADERS_TIMEOUT"}},BB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="HeadersOverflowError",this.message=e||"Headers Overflow Error",this.code="UND_ERR_HEADERS_OVERFLOW"}},QB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="BodyTimeoutError",this.message=e||"Body Timeout Error",this.code="UND_ERR_BODY_TIMEOUT"}},bB=class t extends zt{constructor(e,r,n,i){super(e),Error.captureStackTrace(this,t),this.name="ResponseStatusCodeError",this.message=e||"Response Status Code Error",this.code="UND_ERR_RESPONSE_STATUS_CODE",this.body=i,this.status=r,this.statusCode=r,this.headers=n}},NB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="InvalidArgumentError",this.message=e||"Invalid Argument Error",this.code="UND_ERR_INVALID_ARG"}},wB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="InvalidReturnValueError",this.message=e||"Invalid Return Value Error",this.code="UND_ERR_INVALID_RETURN_VALUE"}},xB=class t extends zt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="AbortError",this.messag Line truncated `,u.message,u.stack);var d=new Error("tunneling socket could not be established, cause="+u.message);d.code="ECONNRESET",e.request.emit("error",d),n.removeSocket(i)}};Ts.prototype.removeSocket=function(e){var r=this.sockets.indexOf(e);if(r!==-1){this.sockets.splice(r,1);var n=this.requests.shift();n&&this.createSocket(n,function(i){n.request.onSocket(i)})}};function Gk(t,e){var r=this;Ts.prototype.createSocket.call(r,t,function(n){var i=t.request.getHeader("host"),s=WB({},r.options,{socket:n,servername:i?i.replace(/:.*$/,""):t.host}),o=b5.connect(0,s);r.sockets[r.sockets.indexOf(n)]=o,e(o)})}function Yk(t,e,r){return typeof t=="string"?{host:t,port:e,localAddress:r}:t}function WB(t){for(var e=1,r=arguments.length;e<r;++e){var n=arguments[e];if(typeof n=="object")for(var i=Object.keys(n),s=0,o=i.length;s<o;++s){var a=i[s];n[a]!==void 0&&(t[a]=n[a])}}return t}var No;process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?No=function(){var t=Array.prototype.slice.call(arguments);typeof t[0]=="string"?t[0]="TUNNEL: "+t[0]:t.unshift("TUNNEL:"),console.error.apply(console,t)}:No=function(){};sc.debug=No});var Wk=h((uMe,Vk)=>{Vk.exports=Jk()});var Ct=h((dMe,$k)=>{$k.exports={kClose:Symbol("close"),kDestroy:Symbol("destroy"),kDispatch:Symbol("dispatch"),kUrl:Symbol("url"),kWriting:Symbol("writing"),kResuming:Symbol("resuming"),kQueue:Symbol("queue"),kConnect:Symbol("connect"),kConnecting:Symbol("connecting"),kHeadersList:Symbol("headers list"),kKeepAliveDefaultTimeout:Symbol("default keep alive timeout"),kKeepAliveMaxTimeout:Symbol("max keep alive timeout"),kKeepAliveTimeoutThreshold:Symbol("keep alive timeout threshold"),kKeepAliveTimeoutValue:Symbol("keep alive timeout"),kKeepAlive:Symbol("keep alive"),kHeadersTimeout:Symbol("headers timeout"),kBodyTimeout:Symbol("body timeout"),kServerName:Symbol("server name"),kLocalAddress:Symbol("local address"),kHost:Symbol("host"),kNoRef:Symbol("no ref"),kBodyUsed:Symbol("used"),kRunning:Symbol("running"),kBlocking:Symbol("blocking"),kPending:Symbol("pending"),kSize:Symbol("size"),kBusy:Symbol("busy"),kQueued:Symbol("queued"),kFree:Symbol("free"),kConnected:Symbol("connected"),kClosed:Symbol("closed"),kNeedDrain:Symbol("need drain"),kReset:Symbol("reset"),kDestroyed:Symbol.for("nodejs.stream.destroyed"),kMaxHeadersSize:Symbol("max headers size"),kRunningIdx:Symbol("running index"),kPendingIdx:Symbol("pending index"),kError:Symbol("error"),kClients:Symbol("clients"),kClient:Symbol("client"),kParser:Symbol("parser"),kOnDestroyed:Symbol("destroy callbacks"),kPipelining:Symbol("pipelining"),kSocket:Symbol("socket"),kHostHeader:Symbol("host header"),kConnector:Symbol("connector"),kStrictContentLength:Symbol("strict content length"),kMaxRedirections:Symbol("maxRedirections"),kMaxRequests:Symbol("maxRequestsPerClient"),kProxy:Symbol("proxy agent options"),kCounter:Symbol("socket request counter"),kInterceptors:Symbol("dispatch interceptors"),kMaxResponseSize:Symbol("max response size"),kHTTP2Session:Symbol("http2Session"),kHTTP2SessionState:Symbol("http2Session state"),kHTTP2BuildRequest:Symbol("http2 build request"),kHTTP1BuildRequest:Symbol("http1 build request"),kHTTP2CopyHeaders:Symbol("http2 copy headers"),kHTTPConnVersion:Symbol("http connection version"),kRetryHandlerDefaultRetry:Symbol("retry agent default retry"),kConstruct:Symbol("constructable")}});var lt=h((fMe,Kk)=>{"use strict";var Jt=class extends Error{constructor(e){super(e),this.name="UndiciError",this.code="UND_ERR"}},$B=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="ConnectTimeoutError",this.message=e||"Connect Timeout Error",this.code="UND_ERR_CONNECT_TIMEOUT"}},KB=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="HeadersTimeoutError",this.message=e||"Headers Timeout Error",this.code="UND_ERR_HEADERS_TIMEOUT"}},XB=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="HeadersOverflowError",this.message=e||"Headers Overflow Error",this.code="UND_ERR_HEADERS_OVERFLOW"}},ZB=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="BodyTimeoutError",this.message=e||"Body Timeout Error",this.code="UND_ERR_BODY_TIMEOUT"}},eQ=class t extends Jt{constructor(e,r,n,i){super(e),Error.captureStackTrace(this,t),this.name="ResponseStatusCodeError",this.message=e||"Response Status Code Error",this.code="UND_ERR_RESPONSE_STATUS_CODE",this.body=i,this.status=r,this.statusCode=r,this.headers=n}},tQ=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="InvalidArgumentError",this.message=e||"Invalid Argument Error",this.code="UND_ERR_INVALID_ARG"}},rQ=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="InvalidReturnValueError",this.message=e||"Invalid Return Value Error",this.code="UND_ERR_INVALID_RETURN_VALUE"}},nQ=class t extends Jt{constructor(e){super(e),Error.captureStackTrace(this,t),this.name="AbortError",this.messag Line truncated
\r \r
`),w8=/\r\n/g,x8=/^([^:]+):[ \t]?([\x00-\xFF]+)?$/;function VA(t){Ik.call(this),t=t||{};let e=this;this.nread=0,this.maxed=!1,this.npairs=0,this.maxHeaderPairs=Ck(t,"maxHeaderPairs",2e3),this.maxHeaderSize=Ck(t,"maxHeaderSize",80*1024),this.buffer="",this.header={},this.finished=!1,this.ss=new b8(N8),this.ss.on("info",function(r,n,i,s){n&&!e.maxed&&(e.nread+s-i>=e.maxHeaderSize?(s=e.maxHeaderSize-e.nread+i,e.nread=e.maxHeaderSize,e.maxed=!0):e.nread+=s-i,e.buffer+=n.toString("binary",i,s)),r&&e._finish()})}Q8(VA,Ik);VA.prototype.push=function(t){let e=this.ss.push(t);if(this.finished)return e};VA.prototype.reset=function(){this.finished=!1,this.buffer="",this.header={},this.ss.reset()};VA.prototype._finish=function(){this.buffer&&this._parseHeader(),this.ss.matches=this.ss.maxMatches;let t=this.header;this.header={},this.buffer="",this.finished=!0,this.nread=this.npairs=0,this.maxed=!1,this.emit("header",t)};VA.prototype._parseHeader=function(){if(this.npairs===this.maxHeaderPairs)return;let t=this.buffer.split(w8),e=t.length,r,n;for(var i=0;i<e;++i){if(t[i].length===0)continue;if((t[i][0]===" "||t[i][0]===" ")&&n){this.header[n][this.header[n].length-1]+=t[i];continue}let s=t[i].indexOf(":");if(s===-1||s===0)return;if(r=x8.exec(t[i]),n=r[1].toLowerCase(),this.header[n]=this.header[n]||[],this.header[n].push(r[2]||""),++this.npairs===this.maxHeaderPairs)break}};Bk.exports=VA});var YB=h((I_e,Nk)=>{"use strict";var GB=require("node:stream").Writable,S8=require("node:util").inherits,v8=zB(),bk=yk(),R8=Qk(),D8=45,_8=Buffer.from("-"),k8=Buffer.from(`\r `),m6=/\r\n/g,p6=/^([^:]+):[ \t]?([\x00-\xFF]+)?$/;function ac(t){CP.call(this),t=t||{};let e=this;this.nread=0,this.maxed=!1,this.npairs=0,this.maxHeaderPairs=EP(t,"maxHeaderPairs",2e3),this.maxHeaderSize=EP(t,"maxHeaderSize",80*1024),this.buffer="",this.header={},this.finished=!1,this.ss=new h6(g6),this.ss.on("info",function(r,n,i,s){n&&!e.maxed&&(e.nread+s-i>=e.maxHeaderSize?(s=e.maxHeaderSize-e.nread+i,e.nread=e.maxHeaderSize,e.maxed=!0):e.nread+=s-i,e.buffer+=n.toString("binary",i,s)),r&&e._finish()})}f6(ac,CP);ac.prototype.push=function(t){let e=this.ss.push(t);if(this.finished)return e};ac.prototype.reset=function(){this.finished=!1,this.buffer="",this.header={},this.ss.reset()};ac.prototype._finish=function(){this.buffer&&this._parseHeader(),this.ss.matches=this.ss.maxMatches;let t=this.header;this.header={},this.buffer="",this.finished=!0,this.nread=this.npairs=0,this.maxed=!1,this.emit("header",t)};ac.prototype._parseHeader=function(){if(this.npairs===this.maxHeaderPairs)return;let t=this.buffer.split(m6),e=t.length,r,n;for(var i=0;i<e;++i){if(t[i].length===0)continue;if((t[i][0]===" "||t[i][0]===" ")&&n){this.header[n][this.header[n].length-1]+=t[i];continue}let s=t[i].indexOf(":");if(s===-1||s===0)return;if(r=p6.exec(t[i]),n=r[1].toLowerCase(),this.header[n]=this.header[n]||[],this.header[n].push(r[2]||""),++this.npairs===this.maxHeaderPairs)break}};IP.exports=ac});var BQ=h((IMe,bP)=>{"use strict";var IQ=require("node:stream").Writable,y6=require("node:util").inherits,E6=EQ(),QP=pP(),C6=BP(),I6=45,B6=Buffer.from("-"),Q6=Buffer.from(`\r
`),P8=function(){};function Si(t){if(!(this instanceof Si))return new Si(t);if(GB.call(this,t),!t||!t.headerFirst&&typeof t.boundary!="string")throw new TypeError("Boundary required");typeof t.boundary=="string"?this.setBoundary(t.boundary):this._bparser=void 0,this._headerFirst=t.headerFirst,this._dashes=0,this._parts=0,this._finished=!1,this._realFinish=!1,this._isPreamble=!0,this._justMatched=!1,this._firstWrite=!0,this._inHeader=!0,this._part=void 0,this._cb=void 0,this._ignoreData=!1,this._partOpts={highWaterMark:t.partHwm},this._pause=!1;let e=this;this._hparser=new R8(t),this._hparser.on("header",function(r){e._inHeader=!1,e._part.emit("header",r)})}S8(Si,GB);Si.prototype.emit=function(t){if(t==="finish"&&!this._realFinish){if(!this._finished){let e=this;process.nextTick(function(){if(e.emit("error",new Error("Unexpected end of multipart data")),e._part&&!e._ignoreData){let r=e._isPreamble?"Preamble":"Part";e._part.emit("error",new Error(r+" terminated early due to unexpected end of multipart data")),e._part.push(null),process.nextTick(function(){e._realFinish=!0,e.emit("finish"),e._realFinish=!1});return}e._realFinish=!0,e.emit("finish"),e._realFinish=!1})}}else GB.prototype.emit.apply(this,arguments)};Si.prototype._write=function(t,e,r){if(!this._hparser&&!this._bparser)return r();if(this._headerFirst&&this._isPreamble){this._part||(this._part=new bk(this._partOpts),this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._ignore());let n=this._hparser.push(t);if(!this._inHeader&&n!==void 0&&n<t.length)t=t.slice(n);else return r()}this._firstWrite&&(this._bparser.push(k8),this._firstWrite=!1),this._bparser.push(t),this._pause?this._cb=r:r()};Si.prototype.reset=function(){this._part=void 0,this._bparser=void 0,this._hparser=void 0};Si.prototype.setBoundary=function(t){let e=this;this._bparser=new v8(`\r `),b6=function(){};function Mi(t){if(!(this instanceof Mi))return new Mi(t);if(IQ.call(this,t),!t||!t.headerFirst&&typeof t.boundary!="string")throw new TypeError("Boundary required");typeof t.boundary=="string"?this.setBoundary(t.boundary):this._bparser=void 0,this._headerFirst=t.headerFirst,this._dashes=0,this._parts=0,this._finished=!1,this._realFinish=!1,this._isPreamble=!0,this._justMatched=!1,this._firstWrite=!0,this._inHeader=!0,this._part=void 0,this._cb=void 0,this._ignoreData=!1,this._partOpts={highWaterMark:t.partHwm},this._pause=!1;let e=this;this._hparser=new C6(t),this._hparser.on("header",function(r){e._inHeader=!1,e._part.emit("header",r)})}y6(Mi,IQ);Mi.prototype.emit=function(t){if(t==="finish"&&!this._realFinish){if(!this._finished){let e=this;process.nextTick(function(){if(e.emit("error",new Error("Unexpected end of multipart data")),e._part&&!e._ignoreData){let r=e._isPreamble?"Preamble":"Part";e._part.emit("error",new Error(r+" terminated early due to unexpected end of multipart data")),e._part.push(null),process.nextTick(function(){e._realFinish=!0,e.emit("finish"),e._realFinish=!1});return}e._realFinish=!0,e.emit("finish"),e._realFinish=!1})}}else IQ.prototype.emit.apply(this,arguments)};Mi.prototype._write=function(t,e,r){if(!this._hparser&&!this._bparser)return r();if(this._headerFirst&&this._isPreamble){this._part||(this._part=new QP(this._partOpts),this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._ignore());let n=this._hparser.push(t);if(!this._inHeader&&n!==void 0&&n<t.length)t=t.slice(n);else return r()}this._firstWrite&&(this._bparser.push(Q6),this._firstWrite=!1),this._bparser.push(t),this._pause?this._cb=r:r()};Mi.prototype.reset=function(){this._part=void 0,this._bparser=void 0,this._hparser=void 0};Mi.prototype.setBoundary=function(t){let e=this;this._bparser=new E6(`\r
--`+t),this._bparser.on("info",function(r,n,i,s){e._oninfo(r,n,i,s)})};Si.prototype._ignore=function(){this._part&&!this._ignoreData&&(this._ignoreData=!0,this._part.on("error",P8),this._part.resume())};Si.prototype._oninfo=function(t,e,r,n){let i,s=this,o=0,a,A=!0;if(!this._part&&this._justMatched&&e){for(;this._dashes<2&&r+o<n;)if(e[r+o]===D8)++o,++this._dashes;else{this._dashes&&(i=_8),this._dashes=0;break}if(this._dashes===2&&(r+o<n&&this.listenerCount("trailer")!==0&&this.emit("trailer",e.slice(r+o,n)),this.reset(),this._finished=!0,s._parts===0&&(s._realFinish=!0,s.emit("finish"),s._realFinish=!1)),this._dashes)return}this._justMatched&&(this._justMatched=!1),this._part||(this._part=new bk(this._partOpts),this._part._read=function(c){s._unpause()},this._isPreamble&&this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._isPreamble!==!0&&this.listenerCount("part")!==0?this.emit("part",this._part):this._ignore(),this._isPreamble||(this._inHeader=!0)),e&&r<n&&!this._ignoreData&&(this._isPreamble||!this._inHeader?(i&&(A=this._part.push(i)),A=this._part.push(e.slice(r,n)),A||(this._pause=!0)):!this._isPreamble&&this._inHeader&&(i&&this._hparser.push(i),a=this._hparser.push(e.slice(r,n)),!this._inHeader&&a!==void 0&&a<n&&this._oninfo(!1,e,r+a,n))),t&&(this._hparser.reset(),this._isPreamble?this._isPreamble=!1:r!==n&&(++this._parts,this._part.on("end",function(){--s._parts===0&&(s._finished?(s._realFinish=!0,s.emit("finish"),s._realFinish=!1):s._unpause())})),this._part.push(null),this._part=void 0,this._ignoreData=!1,this._justMatched=!0,this._dashes=0)};Si.prototype._unpause=function(){if(this._pause&&(this._pause=!1,this._cb)){let t=this._cb;this._cb=void 0,t()}};Nk.exports=Si});var Gg=h((JB,Sk)=>{"use strict";var wk=new TextDecoder("utf-8"),xk=new Map([["utf-8",wk],["utf8",wk]]);function T8(t){let e;for(;;)switch(t){case"utf-8":case"utf8":return gd.utf8;case"latin1":case"ascii":case"us-ascii":case"iso-8859-1":case"iso8859-1":case"iso88591":case"iso_8859-1":case"windows-1252":case"iso_8859-1:1987":case"cp1252":case"x-cp1252":return gd.latin1;case"utf16le":case"utf-16le":case"ucs2":case"ucs-2":return gd.utf16le;case"base64":return gd.base64;default:if(e===void 0){e=!0,t=t.toLowerCase();continue}return gd.other.bind(t)}}var gd={utf8:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.utf8Slice(0,t.length)),latin1:(t,e)=>t.length===0?"":typeof t=="string"?t:t.latin1Slice(0,t.length),utf16le:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.ucs2Slice(0,t.length)),base64:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.base64Slice(0,t.length)),other:(t,e)=>{if(t.length===0)return"";if(typeof t=="string"&&(t=Buffer.from(t,e)),xk.has(JB.toString()))try{return xk.get(JB).decode(t)}catch{}return typeof t=="string"?t:t.toString()}};function O8(t,e,r){return t&&T8(r)(t,e)}Sk.exports=O8});var WB=h((B_e,kk)=>{"use strict";var Yg=Gg(),vk=/%[a-fA-F0-9][a-fA-F0-9]/g,M8={"%00":"\0","%01":"","%02":"","%03":"","%04":"","%05":"","%06":"","%07":"\x07","%08":"\b","%09":" ","%0a":` --`+t),this._bparser.on("info",function(r,n,i,s){e._oninfo(r,n,i,s)})};Mi.prototype._ignore=function(){this._part&&!this._ignoreData&&(this._ignoreData=!0,this._part.on("error",b6),this._part.resume())};Mi.prototype._oninfo=function(t,e,r,n){let i,s=this,o=0,a,A=!0;if(!this._part&&this._justMatched&&e){for(;this._dashes<2&&r+o<n;)if(e[r+o]===I6)++o,++this._dashes;else{this._dashes&&(i=B6),this._dashes=0;break}if(this._dashes===2&&(r+o<n&&this.listenerCount("trailer")!==0&&this.emit("trailer",e.slice(r+o,n)),this.reset(),this._finished=!0,s._parts===0&&(s._realFinish=!0,s.emit("finish"),s._realFinish=!1)),this._dashes)return}this._justMatched&&(this._justMatched=!1),this._part||(this._part=new QP(this._partOpts),this._part._read=function(c){s._unpause()},this._isPreamble&&this.listenerCount("preamble")!==0?this.emit("preamble",this._part):this._isPreamble!==!0&&this.listenerCount("part")!==0?this.emit("part",this._part):this._ignore(),this._isPreamble||(this._inHeader=!0)),e&&r<n&&!this._ignoreData&&(this._isPreamble||!this._inHeader?(i&&(A=this._part.push(i)),A=this._part.push(e.slice(r,n)),A||(this._pause=!0)):!this._isPreamble&&this._inHeader&&(i&&this._hparser.push(i),a=this._hparser.push(e.slice(r,n)),!this._inHeader&&a!==void 0&&a<n&&this._oninfo(!1,e,r+a,n))),t&&(this._hparser.reset(),this._isPreamble?this._isPreamble=!1:r!==n&&(++this._parts,this._part.on("end",function(){--s._parts===0&&(s._finished?(s._realFinish=!0,s.emit("finish"),s._realFinish=!1):s._unpause())})),this._part.push(null),this._part=void 0,this._ignoreData=!1,this._justMatched=!0,this._dashes=0)};Mi.prototype._unpause=function(){if(this._pause&&(this._pause=!1,this._cb)){let t=this._cb;this._cb=void 0,t()}};bP.exports=Mi});var um=h((QQ,xP)=>{"use strict";var NP=new TextDecoder("utf-8"),wP=new Map([["utf-8",NP],["utf8",NP]]);function N6(t){let e;for(;;)switch(t){case"utf-8":case"utf8":return vd.utf8;case"latin1":case"ascii":case"us-ascii":case"iso-8859-1":case"iso8859-1":case"iso88591":case"iso_8859-1":case"windows-1252":case"iso_8859-1:1987":case"cp1252":case"x-cp1252":return vd.latin1;case"utf16le":case"utf-16le":case"ucs2":case"ucs-2":return vd.utf16le;case"base64":return vd.base64;default:if(e===void 0){e=!0,t=t.toLowerCase();continue}return vd.other.bind(t)}}var vd={utf8:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.utf8Slice(0,t.length)),latin1:(t,e)=>t.length===0?"":typeof t=="string"?t:t.latin1Slice(0,t.length),utf16le:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.ucs2Slice(0,t.length)),base64:(t,e)=>t.length===0?"":(typeof t=="string"&&(t=Buffer.from(t,e)),t.base64Slice(0,t.length)),other:(t,e)=>{if(t.length===0)return"";if(typeof t=="string"&&(t=Buffer.from(t,e)),wP.has(QQ.toString()))try{return wP.get(QQ).decode(t)}catch{}return typeof t=="string"?t:t.toString()}};function w6(t,e,r){return t&&N6(r)(t,e)}xP.exports=w6});var NQ=h((BMe,_P)=>{"use strict";var dm=um(),SP=/%[a-fA-F0-9][a-fA-F0-9]/g,x6={"%00":"\0","%01":"","%02":"","%03":"","%04":"","%05":"","%06":"","%07":"\x07","%08":"\b","%09":" ","%0a":`
`,"%0A":` `,"%0A":`
`,"%0b":"\v","%0B":"\v","%0c":"\f","%0C":"\f","%0d":"\r","%0D":"\r","%0e":"","%0E":"","%0f":"","%0F":"","%10":"","%11":"","%12":"","%13":"","%14":"","%15":"","%16":"","%17":"","%18":"","%19":"","%1a":"","%1A":"","%1b":"\x1B","%1B":"\x1B","%1c":"","%1C":"","%1d":"","%1D":"","%1e":"","%1E":"","%1f":"","%1F":"","%20":" ","%21":"!","%22":'"',"%23":"#","%24":"$","%25":"%","%26":"&","%27":"'","%28":"(","%29":")","%2a":"*","%2A":"*","%2b":"+","%2B":"+","%2c":",","%2C":",","%2d":"-","%2D":"-","%2e":".","%2E":".","%2f":"/","%2F":"/","%30":"0","%31":"1","%32":"2","%33":"3","%34":"4","%35":"5","%36":"6","%37":"7","%38":"8","%39":"9","%3a":":","%3A":":","%3b":";","%3B":";","%3c":"<","%3C":"<","%3d":"=","%3D":"=","%3e":">","%3E":">","%3f":"?","%3F":"?","%40":"@","%41":"A","%42":"B","%43":"C","%44":"D","%45":"E","%46":"F","%47":"G","%48":"H","%49":"I","%4a":"J","%4A":"J","%4b":"K","%4B":"K","%4c":"L","%4C":"L","%4d":"M","%4D":"M","%4e":"N","%4E":"N","%4f":"O","%4F":"O","%50":"P","%51":"Q","%52":"R","%53":"S","%54":"T","%55":"U","%56":"V","%57":"W","%58":"X","%59":"Y","%5a":"Z","%5A":"Z","%5b":"[","%5B":"[","%5c":"\\","%5C":"\\","%5d":"]","%5D":"]","%5e":"^","%5E":"^","%5f":"_","%5F":"_","%60":"`","%61":"a","%62":"b","%63":"c","%64":"d","%65":"e","%66":"f","%67":"g","%68":"h","%69":"i","%6a":"j","%6A":"j","%6b":"k","%6B":"k","%6c":"l","%6C":"l","%6d":"m","%6D":"m","%6e":"n","%6E":"n","%6f":"o","%6F":"o","%70":"p","%71":"q","%72":"r","%73":"s","%74":"t","%75":"u","%76":"v","%77":"w","%78":"x","%79":"y","%7a":"z","%7A":"z","%7b":"{","%7B":"{","%7c":"|","%7C":"|","%7d":"}","%7D":"}","%7e":"~","%7E":"~","%7f":"\x7F","%7F":"\x7F","%80":"\x80","%81":"\x81","%82":"\x82","%83":"\x83","%84":"\x84","%85":"\x85","%86":"\x86","%87":"\x87","%88":"\x88","%89":"\x89","%8a":"\x8A","%8A":"\x8A","%8b":"\x8B","%8B":"\x8B","%8c":"\x8C","%8C":"\x8C","%8d":"\x8D","%8D":"\x8D","%8e":"\x8E","%8E":"\x8E","%8f":"\x8F","%8F":"\x8F","%90":"\x90","%91":"\x91","%92":"\x92","%93":"\x93","%94":"\x94","%95":"\x95","%96":"\x96","%97":"\x97","%98":"\x98","%99":"\x99","%9a":"\x9A","%9A":"\x9A","%9b":"\x9B","%9B":"\x9B","%9c":"\x9C","%9C":"\x9C","%9d":"\x9D","%9D":"\x9D","%9e":"\x9E","%9E":"\x9E","%9f":"\x9F","%9F":"\x9F","%a0":"\xA0","%A0":"\xA0","%a1":"\xA1","%A1":"\xA1","%a2":"\xA2","%A2":"\xA2","%a3":"\xA3","%A3":"\xA3","%a4":"\xA4","%A4":"\xA4","%a5":"\xA5","%A5":"\xA5","%a6":"\xA6","%A6":"\xA6","%a7":"\xA7","%A7":"\xA7","%a8":"\xA8","%A8":"\xA8","%a9":"\xA9","%A9":"\xA9","%aa":"\xAA","%Aa":"\xAA","%aA":"\xAA","%AA":"\xAA","%ab":"\xAB","%Ab":"\xAB","%aB":"\xAB","%AB":"\xAB","%ac":"\xAC","%Ac":"\xAC","%aC":"\xAC","%AC":"\xAC","%ad":"\xAD","%Ad":"\xAD","%aD":"\xAD","%AD":"\xAD","%ae":"\xAE","%Ae":"\xAE","%aE":"\xAE","%AE":"\xAE","%af":"\xAF","%Af":"\xAF","%aF":"\xAF","%AF":"\xAF","%b0":"\xB0","%B0":"\xB0","%b1":"\xB1","%B1":"\xB1","%b2":"\xB2","%B2":"\xB2","%b3":"\xB3","%B3":"\xB3","%b4":"\xB4","%B4":"\xB4","%b5":"\xB5","%B5":"\xB5","%b6":"\xB6","%B6":"\xB6","%b7":"\xB7","%B7":"\xB7","%b8":"\xB8","%B8":"\xB8","%b9":"\xB9","%B9":"\xB9","%ba":"\xBA","%Ba":"\xBA","%bA":"\xBA","%BA":"\xBA","%bb":"\xBB","%Bb":"\xBB","%bB":"\xBB","%BB":"\xBB","%bc":"\xBC","%Bc":"\xBC","%bC":"\xBC","%BC":"\xBC","%bd":"\xBD","%Bd":"\xBD","%bD":"\xBD","%BD":"\xBD","%be":"\xBE","%Be":"\xBE","%bE":"\xBE","%BE":"\xBE","%bf":"\xBF","%Bf":"\xBF","%bF":"\xBF","%BF":"\xBF","%c0":"\xC0","%C0":"\xC0","%c1":"\xC1","%C1":"\xC1","%c2":"\xC2","%C2":"\xC2","%c3":"\xC3","%C3":"\xC3","%c4":"\xC4","%C4":"\xC4","%c5":"\xC5","%C5":"\xC5","%c6":"\xC6","%C6":"\xC6","%c7":"\xC7","%C7":"\xC7","%c8":"\xC8","%C8":"\xC8","%c9":"\xC9","%C9":"\xC9","%ca":"\xCA","%Ca":"\xCA","%cA":"\xCA","%CA":"\xCA","%cb":"\xCB","%Cb":"\xCB","%cB":"\xCB","%CB":"\xCB","%cc":"\xCC","%Cc":"\xCC","%cC":"\xCC","%CC":"\xCC","%cd":"\xCD","%Cd":"\xCD","%cD":"\xCD","%CD":"\xCD","%ce":"\xCE","%Ce":"\xCE","%cE":"\xCE","%CE":"\xCE","%cf":"\xCF","%Cf":"\xCF","%cF":"\xCF","%CF":"\xCF","%d0":"\xD0","%D0":"\xD0","%d1":"\xD1","%D1":"\xD1","%d2":"\xD2","%D2":"\xD2","%d3":"\xD3","%D3":"\xD3","%d4":"\xD4","%D4":"\xD4","%d5":"\xD5","%D5":"\xD5","%d6":"\xD6","%D6":"\xD6","%d7":"\xD7","%D7":"\xD7","%d8":"\xD8","%D8":"\xD8","%d9":"\xD9","%D9":"\xD9","%da":"\xDA","%Da":"\xDA","%dA":"\xDA","%DA":"\xDA","%db":"\xDB","%Db":"\xDB","%dB":"\xDB","%DB":"\xDB","%dc":"\xDC","%Dc":"\xDC","%dC":"\xDC","%DC":"\xDC","%dd":"\xDD","%Dd":"\xDD","%dD":"\xDD","%DD":"\xDD","%de":"\xDE","%De":"\xDE","%dE":"\xDE","%DE":"\xDE","%df":"\xDF","%Df":"\xDF","%dF":"\xDF","%DF":"\xDF","%e0":"\xE0","%E0":"\xE0","%e1":"\xE1","%E1":"\xE1","%e2":"\xE2","%E2":"\xE2","%e3":"\xE3","%E3":"\xE3","%e4":"\xE4","%E4":"\xE4","%e5":"\xE5","%E5":"\xE5","%e6":"\xE6","%E6":"\xE6","%e7":"\xE7","%E7":"\xE7","%e8":"\xE8","%E8":"\xE8","%e9":"\xE9","%E9":"\xE9","%ea":"\xEA","%Ea":"\xEA","%eA":"\xEA","%EA":"\xEA","%eb":"\xEB","%Eb":"\xEB","%eB":"\xEB","%EB":"\xEB","%ec":"\xEC","%Ec":"\xEC","%eC":"\xEC","%EC":"\xEC","%ed":"\xED","%Ed":"\xED","%eD":"\xED","%ED":"\xED","%ee":"\xLine truncated `,"%0b":"\v","%0B":"\v","%0c":"\f","%0C":"\f","%0d":"\r","%0D":"\r","%0e":"","%0E":"","%0f":"","%0F":"","%10":"","%11":"","%12":"","%13":"","%14":"","%15":"","%16":"","%17":"","%18":"","%19":"","%1a":"","%1A":"","%1b":"\x1B","%1B":"\x1B","%1c":"","%1C":"","%1d":"","%1D":"","%1e":"","%1E":"","%1f":"","%1F":"","%20":" ","%21":"!","%22":'"',"%23":"#","%24":"$","%25":"%","%26":"&","%27":"'","%28":"(","%29":")","%2a":"*","%2A":"*","%2b":"+","%2B":"+","%2c":",","%2C":",","%2d":"-","%2D":"-","%2e":".","%2E":".","%2f":"/","%2F":"/","%30":"0","%31":"1","%32":"2","%33":"3","%34":"4","%35":"5","%36":"6","%37":"7","%38":"8","%39":"9","%3a":":","%3A":":","%3b":";","%3B":";","%3c":"<","%3C":"<","%3d":"=","%3D":"=","%3e":">","%3E":">","%3f":"?","%3F":"?","%40":"@","%41":"A","%42":"B","%43":"C","%44":"D","%45":"E","%46":"F","%47":"G","%48":"H","%49":"I","%4a":"J","%4A":"J","%4b":"K","%4B":"K","%4c":"L","%4C":"L","%4d":"M","%4D":"M","%4e":"N","%4E":"N","%4f":"O","%4F":"O","%50":"P","%51":"Q","%52":"R","%53":"S","%54":"T","%55":"U","%56":"V","%57":"W","%58":"X","%59":"Y","%5a":"Z","%5A":"Z","%5b":"[","%5B":"[","%5c":"\\","%5C":"\\","%5d":"]","%5D":"]","%5e":"^","%5E":"^","%5f":"_","%5F":"_","%60":"`","%61":"a","%62":"b","%63":"c","%64":"d","%65":"e","%66":"f","%67":"g","%68":"h","%69":"i","%6a":"j","%6A":"j","%6b":"k","%6B":"k","%6c":"l","%6C":"l","%6d":"m","%6D":"m","%6e":"n","%6E":"n","%6f":"o","%6F":"o","%70":"p","%71":"q","%72":"r","%73":"s","%74":"t","%75":"u","%76":"v","%77":"w","%78":"x","%79":"y","%7a":"z","%7A":"z","%7b":"{","%7B":"{","%7c":"|","%7C":"|","%7d":"}","%7D":"}","%7e":"~","%7E":"~","%7f":"\x7F","%7F":"\x7F","%80":"\x80","%81":"\x81","%82":"\x82","%83":"\x83","%84":"\x84","%85":"\x85","%86":"\x86","%87":"\x87","%88":"\x88","%89":"\x89","%8a":"\x8A","%8A":"\x8A","%8b":"\x8B","%8B":"\x8B","%8c":"\x8C","%8C":"\x8C","%8d":"\x8D","%8D":"\x8D","%8e":"\x8E","%8E":"\x8E","%8f":"\x8F","%8F":"\x8F","%90":"\x90","%91":"\x91","%92":"\x92","%93":"\x93","%94":"\x94","%95":"\x95","%96":"\x96","%97":"\x97","%98":"\x98","%99":"\x99","%9a":"\x9A","%9A":"\x9A","%9b":"\x9B","%9B":"\x9B","%9c":"\x9C","%9C":"\x9C","%9d":"\x9D","%9D":"\x9D","%9e":"\x9E","%9E":"\x9E","%9f":"\x9F","%9F":"\x9F","%a0":"\xA0","%A0":"\xA0","%a1":"\xA1","%A1":"\xA1","%a2":"\xA2","%A2":"\xA2","%a3":"\xA3","%A3":"\xA3","%a4":"\xA4","%A4":"\xA4","%a5":"\xA5","%A5":"\xA5","%a6":"\xA6","%A6":"\xA6","%a7":"\xA7","%A7":"\xA7","%a8":"\xA8","%A8":"\xA8","%a9":"\xA9","%A9":"\xA9","%aa":"\xAA","%Aa":"\xAA","%aA":"\xAA","%AA":"\xAA","%ab":"\xAB","%Ab":"\xAB","%aB":"\xAB","%AB":"\xAB","%ac":"\xAC","%Ac":"\xAC","%aC":"\xAC","%AC":"\xAC","%ad":"\xAD","%Ad":"\xAD","%aD":"\xAD","%AD":"\xAD","%ae":"\xAE","%Ae":"\xAE","%aE":"\xAE","%AE":"\xAE","%af":"\xAF","%Af":"\xAF","%aF":"\xAF","%AF":"\xAF","%b0":"\xB0","%B0":"\xB0","%b1":"\xB1","%B1":"\xB1","%b2":"\xB2","%B2":"\xB2","%b3":"\xB3","%B3":"\xB3","%b4":"\xB4","%B4":"\xB4","%b5":"\xB5","%B5":"\xB5","%b6":"\xB6","%B6":"\xB6","%b7":"\xB7","%B7":"\xB7","%b8":"\xB8","%B8":"\xB8","%b9":"\xB9","%B9":"\xB9","%ba":"\xBA","%Ba":"\xBA","%bA":"\xBA","%BA":"\xBA","%bb":"\xBB","%Bb":"\xBB","%bB":"\xBB","%BB":"\xBB","%bc":"\xBC","%Bc":"\xBC","%bC":"\xBC","%BC":"\xBC","%bd":"\xBD","%Bd":"\xBD","%bD":"\xBD","%BD":"\xBD","%be":"\xBE","%Be":"\xBE","%bE":"\xBE","%BE":"\xBE","%bf":"\xBF","%Bf":"\xBF","%bF":"\xBF","%BF":"\xBF","%c0":"\xC0","%C0":"\xC0","%c1":"\xC1","%C1":"\xC1","%c2":"\xC2","%C2":"\xC2","%c3":"\xC3","%C3":"\xC3","%c4":"\xC4","%C4":"\xC4","%c5":"\xC5","%C5":"\xC5","%c6":"\xC6","%C6":"\xC6","%c7":"\xC7","%C7":"\xC7","%c8":"\xC8","%C8":"\xC8","%c9":"\xC9","%C9":"\xC9","%ca":"\xCA","%Ca":"\xCA","%cA":"\xCA","%CA":"\xCA","%cb":"\xCB","%Cb":"\xCB","%cB":"\xCB","%CB":"\xCB","%cc":"\xCC","%Cc":"\xCC","%cC":"\xCC","%CC":"\xCC","%cd":"\xCD","%Cd":"\xCD","%cD":"\xCD","%CD":"\xCD","%ce":"\xCE","%Ce":"\xCE","%cE":"\xCE","%CE":"\xCE","%cf":"\xCF","%Cf":"\xCF","%cF":"\xCF","%CF":"\xCF","%d0":"\xD0","%D0":"\xD0","%d1":"\xD1","%D1":"\xD1","%d2":"\xD2","%D2":"\xD2","%d3":"\xD3","%D3":"\xD3","%d4":"\xD4","%D4":"\xD4","%d5":"\xD5","%D5":"\xD5","%d6":"\xD6","%D6":"\xD6","%d7":"\xD7","%D7":"\xD7","%d8":"\xD8","%D8":"\xD8","%d9":"\xD9","%D9":"\xD9","%da":"\xDA","%Da":"\xDA","%dA":"\xDA","%DA":"\xDA","%db":"\xDB","%Db":"\xDB","%dB":"\xDB","%DB":"\xDB","%dc":"\xDC","%Dc":"\xDC","%dC":"\xDC","%DC":"\xDC","%dd":"\xDD","%Dd":"\xDD","%dD":"\xDD","%DD":"\xDD","%de":"\xDE","%De":"\xDE","%dE":"\xDE","%DE":"\xDE","%df":"\xDF","%Df":"\xDF","%dF":"\xDF","%DF":"\xDF","%e0":"\xE0","%E0":"\xE0","%e1":"\xE1","%E1":"\xE1","%e2":"\xE2","%E2":"\xE2","%e3":"\xE3","%E3":"\xE3","%e4":"\xE4","%E4":"\xE4","%e5":"\xE5","%E5":"\xE5","%e6":"\xE6","%E6":"\xE6","%e7":"\xE7","%E7":"\xE7","%e8":"\xE8","%E8":"\xE8","%e9":"\xE9","%E9":"\xE9","%ea":"\xEA","%Ea":"\xEA","%eA":"\xEA","%EA":"\xEA","%eb":"\xEB","%Eb":"\xEB","%eB":"\xEB","%EB":"\xEB","%ec":"\xEC","%Ec":"\xEC","%eC":"\xEC","%EC":"\xEC","%ed":"\xED","%Ed":"\xED","%eD":"\xED","%ED":"\xED","%ee":"\xLine truncated
`))}function O5(t,e){let{headersList:r}=e,n=(r.get("referrer-policy")??"").split(","),i="";if(n.length>0)for(let s=n.length;s!==0;s--){let o=n[s-1].trim();if(B5.has(o)){i=o;break}}i!==""&&(t.referrerPolicy=i)}function M5(){return"allowed"}function L5(){return"success"}function F5(){return"success"}function U5(t){let e=null;e=t.mode,t.headersList.set("sec-fetch-mode",e)}function q5(t){let e=t.origin;if(t.responseTainting==="cors"||t.mode==="websocket")e&&t.headersList.append("origin",e);else if(t.method!=="GET"&&t.method!=="HEAD"){switch(t.referrerPolicy){case"no-referrer":e=null;break;case"no-referrer-when-downgrade":case"strict-origin":case"strict-origin-when-cross-origin":t.origin&&nQ(t.origin)&&!nQ(yd(t))&&(e=null);break;case"same-origin":Kg(t,yd(t))||(e=null);break;default:}e&&t.headersList.append("origin",e)}}function H5(t){return N5.now()}function z5(t){return{startTime:t.startTime??0,redirectStartTime:0,redirectEndTime:0,postRedirectStartTime:t.startTime??0,finalServiceWorkerStartTime:0,finalNetworkResponseStartTime:0,finalNetworkRequestStartTime:0,endTime:0,encodedBodySize:0,decodedBodySize:0,finalConnectionTimingInfo:null}}function j5(){return{referrerPolicy:"strict-origin-when-cross-origin"}}function G5(t){return{referrerPolicy:t.referrerPolicy}}function Y5(t){let e=t.referrerPolicy;ZA(e);let r=null;if(t.referrer==="client"){let a=b5();if(!a||a.origin==="null")return"no-referrer";r=new URL(a)}else t.referrer instanceof URL&&(r=t.referrer);let n=tQ(r),i=tQ(r,!0);n.toString().length>4096&&(n=i);let s=Kg(t,n),o=pd(n)&&!pd(t.url);switch(e){case"origin":return i??tQ(r,!0);case"unsafe-url":return n;case"same-origin":return s?i:"no-referrer";case"origin-when-cross-origin":return s?n:i;case"strict-origin-when-cross-origin":{let a=yd(t);return Kg(n,a)?n:pd(n)&&!pd(a)?"no-referrer":i}default:return o?"no-referrer":i}}function tQ(t,e){return ZA(t instanceof URL),t.protocol==="file:"||t.protocol==="about:"||t.protocol==="blank:"?"no-referrer":(t.username="",t.password="",t.hash="",e&&(t.pathname="",t.search=""),t)}function pd(t){if(!(t instanceof URL))return!1;if(t.href==="about:blank"||t.href==="about:srcdoc"||t.protocol==="data:"||t.protocol==="file:")return!0;return e(t.origin);function e(r){if(r==null||r==="null")return!1;let n=new URL(r);return!!(n.protocol==="https:"||n.protocol==="wss:"||/^127(?:\.[0-9]+){0,2}\.[0-9]+$|^\[(?:0*:)*?:?0*1\]$/.test(n.hostname)||n.hostname==="localhost"||n.hostname.includes("localhost.")||n.hostname.endsWith(".localhost"))}}function J5(t,e){if($g===void 0)return!0;let r=oP(e);if(r==="no metadata"||r.length===0)return!0;let n=W5(r),i=$5(r,n);for(let s of i){let o=s.algo,a=s.hash,A=$g.createHash(o).update(t).digest("base64");if(A[A.length-1]==="="&&(A[A.length-2]==="="?A=A.slice(0,-2):A=A.slice(0,-1)),K5(A,a))return!0}return!1}var V5=/(?<algo>sha256|sha384|sha512)-((?<hash>[A-Za-z0-9+/]+|[A-Za-z0-9_-]+)={0,2}(?:\s|$)( +[!-~]*)?)?/i;function oP(t){let e=[],r=!0;for(let n of t.split(" ")){r=!1;let i=V5.exec(n);if(i===null||i.groups===void 0||i.groups.algo===void 0)continue;let s=i.groups.algo.toLowerCase();rP.includes(s)&&e.push(i.groups)}return r===!0?"no metadata":e}function W5(t){let e=t[0].algo;if(e[3]==="5")return e;for(let r=1;r<t.length;++r){let n=t[r];if(n.algo[3]==="5"){e="sha512";break}else{if(e[3]==="3")continue;n.algo[3]==="3"&&(e="sha384")}}return e}function $5(t,e){if(t.length===1)return t;let r=0;for(let n=0;n<t.length;++n)t[n].algo===e&&(t[r++]=t[n]);return t.length=r,t}function K5(t,e){if(t.length!==e.length)return!1;for(let r=0;r<t.length;++r)if(t[r]!==e[r]){if(t[r]==="+"&&e[r]==="-"||t[r]==="/"&&e[r]==="_")continue;return!1}return!0}function X5(t){}function Kg(t,e){return t.origin===e.origin&&t.origin==="null"||t.protocol===e.protocol&&t.hostname===e.hostname&&t.port===e.port}function Z5(){let t,e;return{promise:new Promise((n,i)=>{t=n,e=i}),resolve:t,reject:e}}function eX(t){return t.controller.state==="aborted"}function tX(t){return t.controller.state==="aborted"||t.controller.state==="terminated"}var iQ={delete:"DELETE",DELETE:"DELETE",get:"GET",GET:"GET",head:"HEAD",HEAD:"HEAD",options:"OPTIONS",OPTIONS:"OPTIONS",post:"POST",POST:"POST",put:"PUT",PUT:"PUT"};Object.setPrototypeOf(iQ,null);function rX(t){return iQ[t.toLowerCase()]??t}function nX(t){let e=JSON.stringify(t);if(e===void 0)throw new TypeError("Value is not JSON serializable");return ZA(typeof e=="string"),e}var iX=Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]()));function sX(t,e,r){let n={index:0,kind:r,target:t},i={next(){if(Object.getPrototypeOf(this)!==i)throw new TypeError(`'next' called on an object that does not implement interface ${e} Iterator.`);let{index:s,kind:o,target:a}=n,A=a(),c=A.length;if(s>=c)return{value:void 0,done:!0};let l=A[s];return n.index=s+1,oX(l,o)},[Symbol.toStringTag]:`${e} Iterator`};return Object.setPrototypeOf(i,iX),Object.setPrototypeOf({},i)}function oX(t,e){let r;switch(e){case"key":{r=t[0];break}case"value":{r=t[1];break}case"key+value":{r Line truncated `))}function wZ(t,e){let{headersList:r}=e,n=(r.get("referrer-policy")??"").split(","),i="";if(n.length>0)for(let s=n.length;s!==0;s--){let o=n[s-1].trim();if(dZ.has(o)){i=o;break}}i!==""&&(t.referrerPolicy=i)}function xZ(){return"allowed"}function SZ(){return"success"}function RZ(){return"success"}function vZ(t){let e=null;e=t.mode,t.headersList.set("sec-fetch-mode",e)}function DZ(t){let e=t.origin;if(t.responseTainting==="cors"||t.mode==="websocket")e&&t.headersList.append("origin",e);else if(t.method!=="GET"&&t.method!=="HEAD"){switch(t.referrerPolicy){case"no-referrer":e=null;break;case"no-referrer-when-downgrade":case"strict-origin":case"strict-origin-when-cross-origin":t.origin&&kQ(t.origin)&&!kQ(kd(t))&&(e=null);break;case"same-origin":pm(t,kd(t))||(e=null);break;default:}e&&t.headersList.append("origin",e)}}function _Z(t){return gZ.now()}function kZ(t){return{startTime:t.startTime??0,redirectStartTime:0,redirectEndTime:0,postRedirectStartTime:t.startTime??0,finalServiceWorkerStartTime:0,finalNetworkResponseStartTime:0,finalNetworkRequestStartTime:0,endTime:0,encodedBodySize:0,decodedBodySize:0,finalConnectionTimingInfo:null}}function PZ(){return{referrerPolicy:"strict-origin-when-cross-origin"}}function TZ(t){return{referrerPolicy:t.referrerPolicy}}function OZ(t){let e=t.referrerPolicy;dc(e);let r=null;if(t.referrer==="client"){let a=hZ();if(!a||a.origin==="null")return"no-referrer";r=new URL(a)}else t.referrer instanceof URL&&(r=t.referrer);let n=DQ(r),i=DQ(r,!0);n.toString().length>4096&&(n=i);let s=pm(t,n),o=_d(n)&&!_d(t.url);switch(e){case"origin":return i??DQ(r,!0);case"unsafe-url":return n;case"same-origin":return s?i:"no-referrer";case"origin-when-cross-origin":return s?n:i;case"strict-origin-when-cross-origin":{let a=kd(t);return pm(n,a)?n:_d(n)&&!_d(a)?"no-referrer":i}default:return o?"no-referrer":i}}function DQ(t,e){return dc(t instanceof URL),t.protocol==="file:"||t.protocol==="about:"||t.protocol==="blank:"?"no-referrer":(t.username="",t.password="",t.hash="",e&&(t.pathname="",t.search=""),t)}function _d(t){if(!(t instanceof URL))return!1;if(t.href==="about:blank"||t.href==="about:srcdoc"||t.protocol==="data:"||t.protocol==="file:")return!0;return e(t.origin);function e(r){if(r==null||r==="null")return!1;let n=new URL(r);return!!(n.protocol==="https:"||n.protocol==="wss:"||/^127(?:\.[0-9]+){0,2}\.[0-9]+$|^\[(?:0*:)*?:?0*1\]$/.test(n.hostname)||n.hostname==="localhost"||n.hostname.includes("localhost.")||n.hostname.endsWith(".localhost"))}}function LZ(t,e){if(mm===void 0)return!0;let r=sT(e);if(r==="no metadata"||r.length===0)return!0;let n=FZ(r),i=UZ(r,n);for(let s of i){let o=s.algo,a=s.hash,A=mm.createHash(o).update(t).digest("base64");if(A[A.length-1]==="="&&(A[A.length-2]==="="?A=A.slice(0,-2):A=A.slice(0,-1)),qZ(A,a))return!0}return!1}var MZ=/(?<algo>sha256|sha384|sha512)-((?<hash>[A-Za-z0-9+/]+|[A-Za-z0-9_-]+)={0,2}(?:\s|$)( +[!-~]*)?)?/i;function sT(t){let e=[],r=!0;for(let n of t.split(" ")){r=!1;let i=MZ.exec(n);if(i===null||i.groups===void 0||i.groups.algo===void 0)continue;let s=i.groups.algo.toLowerCase();tT.includes(s)&&e.push(i.groups)}return r===!0?"no metadata":e}function FZ(t){let e=t[0].algo;if(e[3]==="5")return e;for(let r=1;r<t.length;++r){let n=t[r];if(n.algo[3]==="5"){e="sha512";break}else{if(e[3]==="3")continue;n.algo[3]==="3"&&(e="sha384")}}return e}function UZ(t,e){if(t.length===1)return t;let r=0;for(let n=0;n<t.length;++n)t[n].algo===e&&(t[r++]=t[n]);return t.length=r,t}function qZ(t,e){if(t.length!==e.length)return!1;for(let r=0;r<t.length;++r)if(t[r]!==e[r]){if(t[r]==="+"&&e[r]==="-"||t[r]==="/"&&e[r]==="_")continue;return!1}return!0}function HZ(t){}function pm(t,e){return t.origin===e.origin&&t.origin==="null"||t.protocol===e.protocol&&t.hostname===e.hostname&&t.port===e.port}function jZ(){let t,e;return{promise:new Promise((n,i)=>{t=n,e=i}),resolve:t,reject:e}}function zZ(t){return t.controller.state==="aborted"}function GZ(t){return t.controller.state==="aborted"||t.controller.state==="terminated"}var PQ={delete:"DELETE",DELETE:"DELETE",get:"GET",GET:"GET",head:"HEAD",HEAD:"HEAD",options:"OPTIONS",OPTIONS:"OPTIONS",post:"POST",POST:"POST",put:"PUT",PUT:"PUT"};Object.setPrototypeOf(PQ,null);function YZ(t){return PQ[t.toLowerCase()]??t}function JZ(t){let e=JSON.stringify(t);if(e===void 0)throw new TypeError("Value is not JSON serializable");return dc(typeof e=="string"),e}var VZ=Object.getPrototypeOf(Object.getPrototypeOf([][Symbol.iterator]()));function WZ(t,e,r){let n={index:0,kind:r,target:t},i={next(){if(Object.getPrototypeOf(this)!==i)throw new TypeError(`'next' called on an object that does not implement interface ${e} Iterator.`);let{index:s,kind:o,target:a}=n,A=a(),c=A.length;if(s>=c)return{value:void 0,done:!0};let l=A[s];return n.index=s+1,$Z(l,o)},[Symbol.toStringTag]:`${e} Iterator`};return Object.setPrototypeOf(i,VZ),Object.setPrototypeOf({},i)}function $Z(t,e){let r;switch(e){case"key":{r=t[0];break}case"value":{r=t[1];break}case"key+value":{r Line truncated
`||t===" "||t===" "}function sQ(t,e=!0,r=!0){let n=0,i=t.length-1;if(e)for(;n<t.length&&fP(t[n]);n++);if(r)for(;i>0&&fP(t[i]);i--);return t.slice(n,i+1)}function hP(t){return t==="\r"||t===` `||t===" "||t===" "}function TQ(t,e=!0,r=!0){let n=0,i=t.length-1;if(e)for(;n<t.length&&dT(t[n]);n++);if(r)for(;i>0&&dT(t[i]);i--);return t.slice(n,i+1)}function fT(t){return t==="\r"||t===`
`||t===" "||t==="\f"||t===" "}function NX(t,e=!0,r=!0){let n=0,i=t.length-1;if(e)for(;n<t.length&&hP(t[n]);n++);if(r)for(;i>0&&hP(t[i]);i--);return t.slice(n,i+1)}yP.exports={dataURLProcessor:IX,URLSerializer:gP,collectASequenceOfCodePoints:em,collectASequenceOfCodePointsFast:ec,stringPercentDecode:mP,parseMIMEType:oQ,collectAnHTTPQuotedString:pP,serializeAMimeType:bX}});var tm=h((P_e,QP)=>{"use strict";var{Blob:IP,File:EP}=require("buffer"),{types:aQ}=require("util"),{kState:wn}=ws(),{isBlobLike:BP}=Yn(),{webidl:Je}=qr(),{parseMIMEType:wX,serializeAMimeType:xX}=vi(),{kEnumerableProperty:CP}=Fe(),SX=new TextEncoder,Ed=class t extends IP{constructor(e,r,n={}){Je.argumentLengthCheck(arguments,2,{header:"File constructor"}),e=Je.converters["sequence<BlobPart>"](e),r=Je.converters.USVString(r),n=Je.converters.FilePropertyBag(n);let i=r,s=n.type,o;e:{if(s){if(s=wX(s),s==="failure"){s="";break e}s=xX(s).toLowerCase()}o=n.lastModified}super(vX(e,n),{type:s}),this[wn]={name:i,lastModified:o,type:s}}get name(){return Je.brandCheck(this,t),this[wn].name}get lastModified(){return Je.brandCheck(this,t),this[wn].lastModified}get type(){return Je.brandCheck(this,t),this[wn].type}},AQ=class t{constructor(e,r,n={}){let i=r,s=n.type,o=n.lastModified??Date.now();this[wn]={blobLike:e,name:i,type:s,lastModified:o}}stream(...e){return Je.brandCheck(this,t),this[wn].blobLike.stream(...e)}arrayBuffer(...e){return Je.brandCheck(this,t),this[wn].blobLike.arrayBuffer(...e)}slice(...e){return Je.brandCheck(this,t),this[wn].blobLike.slice(...e)}text(...e){return Je.brandCheck(this,t),this[wn].blobLike.text(...e)}get size(){return Je.brandCheck(this,t),this[wn].blobLike.size}get type(){return Je.brandCheck(this,t),this[wn].blobLike.type}get name(){return Je.brandCheck(this,t),this[wn].name}get lastModified(){return Je.brandCheck(this,t),this[wn].lastModified}get[Symbol.toStringTag](){return"File"}};Object.defineProperties(Ed.prototype,{[Symbol.toStringTag]:{value:"File",configurable:!0},name:CP,lastModified:CP});Je.converters.Blob=Je.interfaceConverter(IP);Je.converters.BlobPart=function(t,e){if(Je.util.Type(t)==="Object"){if(BP(t))return Je.converters.Blob(t,{strict:!1});if(ArrayBuffer.isView(t)||aQ.isAnyArrayBuffer(t))return Je.converters.BufferSource(t,e)}return Je.converters.USVString(t,e)};Je.converters["sequence<BlobPart>"]=Je.sequenceConverter(Je.converters.BlobPart);Je.converters.FilePropertyBag=Je.dictionaryConverter([{key:"lastModified",converter:Je.converters["long long"],get defaultValue(){return Date.now()}},{key:"type",converter:Je.converters.DOMString,defaultValue:""},{key:"endings",converter:t=>(t=Je.converters.DOMString(t),t=t.toLowerCase(),t!=="native"&&(t="transparent"),t),defaultValue:"transparent"}]);function vX(t,e){let r=[];for(let n of t)if(typeof n=="string"){let i=n;e.endings==="native"&&(i=RX(i)),r.push(SX.encode(i))}else aQ.isAnyArrayBuffer(n)||aQ.isTypedArray(n)?n.buffer?r.push(new Uint8Array(n.buffer,n.byteOffset,n.byteLength)):r.push(new Uint8Array(n)):BP(n)&&r.push(n);return r}function RX(t){let e=` `||t===" "||t==="\f"||t===" "}function g7(t,e=!0,r=!0){let n=0,i=t.length-1;if(e)for(;n<t.length&&fT(t[n]);n++);if(r)for(;i>0&&fT(t[i]);i--);return t.slice(n,i+1)}pT.exports={dataURLProcessor:u7,URLSerializer:hT,collectASequenceOfCodePoints:Cm,collectASequenceOfCodePointsFast:fc,stringPercentDecode:gT,parseMIMEType:OQ,collectAnHTTPQuotedString:mT,serializeAMimeType:h7}});var Im=h((PMe,BT)=>{"use strict";var{Blob:CT,File:yT}=require("buffer"),{types:LQ}=require("util"),{kState:Pn}=Ls(),{isBlobLike:IT}=ei(),{webidl:$e}=Vr(),{parseMIMEType:m7,serializeAMimeType:p7}=Fi(),{kEnumerableProperty:ET}=He(),y7=new TextEncoder,Pd=class t extends CT{constructor(e,r,n={}){$e.argumentLengthCheck(arguments,2,{header:"File constructor"}),e=$e.converters["sequence<BlobPart>"](e),r=$e.converters.USVString(r),n=$e.converters.FilePropertyBag(n);let i=r,s=n.type,o;e:{if(s){if(s=m7(s),s==="failure"){s="";break e}s=p7(s).toLowerCase()}o=n.lastModified}super(E7(e,n),{type:s}),this[Pn]={name:i,lastModified:o,type:s}}get name(){return $e.brandCheck(this,t),this[Pn].name}get lastModified(){return $e.brandCheck(this,t),this[Pn].lastModified}get type(){return $e.brandCheck(this,t),this[Pn].type}},MQ=class t{constructor(e,r,n={}){let i=r,s=n.type,o=n.lastModified??Date.now();this[Pn]={blobLike:e,name:i,type:s,lastModified:o}}stream(...e){return $e.brandCheck(this,t),this[Pn].blobLike.stream(...e)}arrayBuffer(...e){return $e.brandCheck(this,t),this[Pn].blobLike.arrayBuffer(...e)}slice(...e){return $e.brandCheck(this,t),this[Pn].blobLike.slice(...e)}text(...e){return $e.brandCheck(this,t),this[Pn].blobLike.text(...e)}get size(){return $e.brandCheck(this,t),this[Pn].blobLike.size}get type(){return $e.brandCheck(this,t),this[Pn].blobLike.type}get name(){return $e.brandCheck(this,t),this[Pn].name}get lastModified(){return $e.brandCheck(this,t),this[Pn].lastModified}get[Symbol.toStringTag](){return"File"}};Object.defineProperties(Pd.prototype,{[Symbol.toStringTag]:{value:"File",configurable:!0},name:ET,lastModified:ET});$e.converters.Blob=$e.interfaceConverter(CT);$e.converters.BlobPart=function(t,e){if($e.util.Type(t)==="Object"){if(IT(t))return $e.converters.Blob(t,{strict:!1});if(ArrayBuffer.isView(t)||LQ.isAnyArrayBuffer(t))return $e.converters.BufferSource(t,e)}return $e.converters.USVString(t,e)};$e.converters["sequence<BlobPart>"]=$e.sequenceConverter($e.converters.BlobPart);$e.converters.FilePropertyBag=$e.dictionaryConverter([{key:"lastModified",converter:$e.converters["long long"],get defaultValue(){return Date.now()}},{key:"type",converter:$e.converters.DOMString,defaultValue:""},{key:"endings",converter:t=>(t=$e.converters.DOMString(t),t=t.toLowerCase(),t!=="native"&&(t="transparent"),t),defaultValue:"transparent"}]);function E7(t,e){let r=[];for(let n of t)if(typeof n=="string"){let i=n;e.endings==="native"&&(i=C7(i)),r.push(y7.encode(i))}else LQ.isAnyArrayBuffer(n)||LQ.isTypedArray(n)?n.buffer?r.push(new Uint8Array(n.buffer,n.byteOffset,n.byteLength)):r.push(new Uint8Array(n)):IT(n)&&r.push(n);return r}function C7(t){let e=`
`;return process.platform==="win32"&&(e=`\r `;return process.platform==="win32"&&(e=`\r
`),t.replace(/\r?\n/g,e)}function DX(t){return EP&&t instanceof EP||t instanceof Ed||t&&(typeof t.stream=="function"||typeof t.arrayBuffer=="function")&&t[Symbol.toStringTag]==="File"}QP.exports={File:Ed,FileLike:AQ,isFileLike:DX}});var nm=h((T_e,SP)=>{"use strict";var{isBlobLike:rm,toUSVString:_X,makeIterator:cQ}=Yn(),{kState:Dr}=ws(),{File:xP,FileLike:bP,isFileLike:kX}=tm(),{webidl:nt}=qr(),{Blob:PX,File:lQ}=require("buffer"),NP=lQ??xP,tc=class t{constructor(e){if(e!==void 0)throw nt.errors.conversionFailed({prefix:"FormData constructor",argument:"Argument 1",types:["undefined"]});this[Dr]=[]}append(e,r,n=void 0){if(nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,2,{header:"FormData.append"}),arguments.length===3&&!rm(r))throw new TypeError("Failed to execute 'append' on 'FormData': parameter 2 is not of type 'Blob'");e=nt.converters.USVString(e),r=rm(r)?nt.converters.Blob(r,{strict:!1}):nt.converters.USVString(r),n=arguments.length===3?nt.converters.USVString(n):void 0;let i=wP(e,r,n);this[Dr].push(i)}delete(e){nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,1,{header:"FormData.delete"}),e=nt.converters.USVString(e),this[Dr]=this[Dr].filter(r=>r.name!==e)}get(e){nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,1,{header:"FormData.get"}),e=nt.converters.USVString(e);let r=this[Dr].findIndex(n=>n.name===e);return r===-1?null:this[Dr][r].value}getAll(e){return nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,1,{header:"FormData.getAll"}),e=nt.converters.USVString(e),this[Dr].filter(r=>r.name===e).map(r=>r.value)}has(e){return nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,1,{header:"FormData.has"}),e=nt.converters.USVString(e),this[Dr].findIndex(r=>r.name===e)!==-1}set(e,r,n=void 0){if(nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,2,{header:"FormData.set"}),arguments.length===3&&!rm(r))throw new TypeError("Failed to execute 'set' on 'FormData': parameter 2 is not of type 'Blob'");e=nt.converters.USVString(e),r=rm(r)?nt.converters.Blob(r,{strict:!1}):nt.converters.USVString(r),n=arguments.length===3?_X(n):void 0;let i=wP(e,r,n),s=this[Dr].findIndex(o=>o.name===e);s!==-1?this[Dr]=[...this[Dr].slice(0,s),i,...this[Dr].slice(s+1).filter(o=>o.name!==e)]:this[Dr].push(i)}entries(){return nt.brandCheck(this,t),cQ(()=>this[Dr].map(e=>[e.name,e.value]),"FormData","key+value")}keys(){return nt.brandCheck(this,t),cQ(()=>this[Dr].map(e=>[e.name,e.value]),"FormData","key")}values(){return nt.brandCheck(this,t),cQ(()=>this[Dr].map(e=>[e.name,e.value]),"FormData","value")}forEach(e,r=globalThis){if(nt.brandCheck(this,t),nt.argumentLengthCheck(arguments,1,{header:"FormData.forEach"}),typeof e!="function")throw new TypeError("Failed to execute 'forEach' on 'FormData': parameter 1 is not of type 'Function'.");for(let[n,i]of this)e.apply(r,[i,n,this])}};tc.prototype[Symbol.iterator]=tc.prototype.entries;Object.defineProperties(tc.prototype,{[Symbol.toStringTag]:{value:"FormData",configurable:!0}});function wP(t,e,r){if(t=Buffer.from(t).toString("utf8"),typeof e=="string")e=Buffer.from(e).toString("utf8");else if(kX(e)||(e=e instanceof PX?new NP([e],"blob",{type:e.type}):new bP(e,"blob",{type:e.type})),r!==void 0){let n={type:e.type,lastModified:e.lastModified};e=lQ&&e instanceof lQ||e instanceof xP?new NP([e],r,n):new bP(e,r,n)}return{name:t,value:e}}SP.exports={FormData:tc}});var Cd=h((O_e,MP)=>{"use strict";var TX=Yk(),rc=Fe(),{ReadableStreamFrom:OX,isBlobLike:vP,isReadableStreamLike:MX,readableStreamClose:LX,createDeferredPromise:FX,fullyReadBody:UX}=Yn(),{FormData:RP}=nm(),{kState:Ss}=ws(),{webidl:uQ}=qr(),{DOMException:kP,structuredClone:qX}=po(),{Blob:HX,File:zX}=require("buffer"),{kBodyUsed:jX}=yt(),dQ=require("assert"),{isErrored:GX}=Fe(),{isUint8Array:PP,isArrayBuffer:YX}=require("util/types"),{File:JX}=tm(),{parseMIMEType:VX,serializeAMimeType:WX}=vi(),fQ;try{let t=require("node:crypto");fQ=e=>t.randomInt(0,e)}catch{fQ=t=>Math.floor(Math.random(t))}var xs=globalThis.ReadableStream,DP=zX??JX,im=new TextEncoder,$X=new TextDecoder;function TP(t,e=!1){xs||(xs=require("stream/web").ReadableStream);let r=null;t instanceof xs?r=t:vP(t)?r=t.stream():r=new xs({async pull(A){A.enqueue(typeof i=="string"?im.encode(i):i),queueMicrotask(()=>LX(A))},start(){},type:void 0}),dQ(MX(r));let n=null,i=null,s=null,o=null;if(typeof t=="string")i=t,o="text/plain;charset=UTF-8";else if(t instanceof URLSearchParams)i=t.toString(),o="application/x-www-form-urlencoded;charset=UTF-8";else if(YX(t))i=new Uint8Array(t.slice());else if(ArrayBuffer.isView(t))i=new Uint8Array(t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength));else if(rc.isFormDataLike(t)){let A=`----formdata-undici-0${`${fQ(1e11)}`.padStart(11,"0")}`,c=`--${A}\r `),t.replace(/\r?\n/g,e)}function I7(t){return yT&&t instanceof yT||t instanceof Pd||t&&(typeof t.stream=="function"||typeof t.arrayBuffer=="function")&&t[Symbol.toStringTag]==="File"}BT.exports={File:Pd,FileLike:MQ,isFileLike:I7}});var Qm=h((TMe,xT)=>{"use strict";var{isBlobLike:Bm,toUSVString:B7,makeIterator:FQ}=ei(),{kState:Mr}=Ls(),{File:wT,FileLike:QT,isFileLike:Q7}=Im(),{webidl:ot}=Vr(),{Blob:b7,File:UQ}=require("buffer"),bT=UQ??wT,hc=class t{constructor(e){if(e!==void 0)throw ot.errors.conversionFailed({prefix:"FormData constructor",argument:"Argument 1",types:["undefined"]});this[Mr]=[]}append(e,r,n=void 0){if(ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,2,{header:"FormData.append"}),arguments.length===3&&!Bm(r))throw new TypeError("Failed to execute 'append' on 'FormData': parameter 2 is not of type 'Blob'");e=ot.converters.USVString(e),r=Bm(r)?ot.converters.Blob(r,{strict:!1}):ot.converters.USVString(r),n=arguments.length===3?ot.converters.USVString(n):void 0;let i=NT(e,r,n);this[Mr].push(i)}delete(e){ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,1,{header:"FormData.delete"}),e=ot.converters.USVString(e),this[Mr]=this[Mr].filter(r=>r.name!==e)}get(e){ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,1,{header:"FormData.get"}),e=ot.converters.USVString(e);let r=this[Mr].findIndex(n=>n.name===e);return r===-1?null:this[Mr][r].value}getAll(e){return ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,1,{header:"FormData.getAll"}),e=ot.converters.USVString(e),this[Mr].filter(r=>r.name===e).map(r=>r.value)}has(e){return ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,1,{header:"FormData.has"}),e=ot.converters.USVString(e),this[Mr].findIndex(r=>r.name===e)!==-1}set(e,r,n=void 0){if(ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,2,{header:"FormData.set"}),arguments.length===3&&!Bm(r))throw new TypeError("Failed to execute 'set' on 'FormData': parameter 2 is not of type 'Blob'");e=ot.converters.USVString(e),r=Bm(r)?ot.converters.Blob(r,{strict:!1}):ot.converters.USVString(r),n=arguments.length===3?B7(n):void 0;let i=NT(e,r,n),s=this[Mr].findIndex(o=>o.name===e);s!==-1?this[Mr]=[...this[Mr].slice(0,s),i,...this[Mr].slice(s+1).filter(o=>o.name!==e)]:this[Mr].push(i)}entries(){return ot.brandCheck(this,t),FQ(()=>this[Mr].map(e=>[e.name,e.value]),"FormData","key+value")}keys(){return ot.brandCheck(this,t),FQ(()=>this[Mr].map(e=>[e.name,e.value]),"FormData","key")}values(){return ot.brandCheck(this,t),FQ(()=>this[Mr].map(e=>[e.name,e.value]),"FormData","value")}forEach(e,r=globalThis){if(ot.brandCheck(this,t),ot.argumentLengthCheck(arguments,1,{header:"FormData.forEach"}),typeof e!="function")throw new TypeError("Failed to execute 'forEach' on 'FormData': parameter 1 is not of type 'Function'.");for(let[n,i]of this)e.apply(r,[i,n,this])}};hc.prototype[Symbol.iterator]=hc.prototype.entries;Object.defineProperties(hc.prototype,{[Symbol.toStringTag]:{value:"FormData",configurable:!0}});function NT(t,e,r){if(t=Buffer.from(t).toString("utf8"),typeof e=="string")e=Buffer.from(e).toString("utf8");else if(Q7(e)||(e=e instanceof b7?new bT([e],"blob",{type:e.type}):new QT(e,"blob",{type:e.type})),r!==void 0){let n={type:e.type,lastModified:e.lastModified};e=UQ&&e instanceof UQ||e instanceof wT?new bT([e],r,n):new QT(e,r,n)}return{name:t,value:e}}xT.exports={FormData:hc}});var Td=h((OMe,OT)=>{"use strict";var N7=GP(),gc=He(),{ReadableStreamFrom:w7,isBlobLike:ST,isReadableStreamLike:x7,readableStreamClose:S7,createDeferredPromise:R7,fullyReadBody:v7}=ei(),{FormData:RT}=Qm(),{kState:Fs}=Ls(),{webidl:qQ}=Vr(),{DOMException:_T,structuredClone:D7}=So(),{Blob:_7,File:k7}=require("buffer"),{kBodyUsed:P7}=Ct(),HQ=require("assert"),{isErrored:T7}=He(),{isUint8Array:kT,isArrayBuffer:O7}=require("util/types"),{File:L7}=Im(),{parseMIMEType:M7,serializeAMimeType:F7}=Fi(),jQ;try{let t=require("node:crypto");jQ=e=>t.randomInt(0,e)}catch{jQ=t=>Math.floor(Math.random(t))}var Ms=globalThis.ReadableStream,vT=k7??L7,bm=new TextEncoder,U7=new TextDecoder;function PT(t,e=!1){Ms||(Ms=require("stream/web").ReadableStream);let r=null;t instanceof Ms?r=t:ST(t)?r=t.stream():r=new Ms({async pull(A){A.enqueue(typeof i=="string"?bm.encode(i):i),queueMicrotask(()=>S7(A))},start(){},type:void 0}),HQ(x7(r));let n=null,i=null,s=null,o=null;if(typeof t=="string")i=t,o="text/plain;charset=UTF-8";else if(t instanceof URLSearchParams)i=t.toString(),o="application/x-www-form-urlencoded;charset=UTF-8";else if(O7(t))i=new Uint8Array(t.slice());else if(ArrayBuffer.isView(t))i=new Uint8Array(t.buffer.slice(t.byteOffset,t.byteOffset+t.byteLength));else if(gc.isFormDataLike(t)){let A=`----formdata-undici-0${`${jQ(1e11)}`.padStart(11,"0")}`,c=`--${A}\r
Content-Disposition: form-data`;let l=E=>E.replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),u=E=>E.replace(/\r?\n|\r/g,`\r Content-Disposition: form-data`;let l=E=>E.replace(/\n/g,"%0A").replace(/\r/g,"%0D").replace(/"/g,"%22"),u=E=>E.replace(/\r?\n|\r/g,`\r
`),d=[],f=new Uint8Array([13,10]);s=0;let g=!1;for(let[E,C]of t)if(typeof C=="string"){let I=im.encode(c+`; name="${l(u(E))}"\r `),d=[],f=new Uint8Array([13,10]);s=0;let g=!1;for(let[E,C]of t)if(typeof C=="string"){let I=bm.encode(c+`; name="${l(u(E))}"\r
\r \r
${u(C)}\r ${u(C)}\r
`);d.push(I),s+=I.byteLength}else{let I=im.encode(`${c}; name="${l(u(E))}"`+(C.name?`; filename="${l(C.name)}"`:"")+`\r `);d.push(I),s+=I.byteLength}else{let I=bm.encode(`${c}; name="${l(u(E))}"`+(C.name?`; filename="${l(C.name)}"`:"")+`\r
Content-Type: ${C.type||"application/octet-stream"}\r Content-Type: ${C.type||"application/octet-stream"}\r
\r \r
`);d.push(I,C,f),typeof C.size=="number"?s+=I.byteLength+C.size+f.byteLength:g=!0}let m=im.encode(`--${A}--`);d.push(m),s+=m.byteLength,g&&(s=null),i=t,n=async function*(){for(let E of d)E.stream?yield*E.stream():yield E},o="multipart/form-data; boundary="+A}else if(vP(t))i=t,s=t.size,t.type&&(o=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(rc.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof xs?t:OX(t)}if((typeof i=="string"||rc.isBuffer(i))&&(s=Buffer.byteLength(i)),n!=null){let A;r=new xs({async start(){A=n(t)[Symbol.asyncIterator]()},async pull(c){let{value:l,done:u}=await A.next();return u?queueMicrotask(()=>{c.close()}):GX(r)||c.enqueue(new Uint8Array(l)),c.desiredSize>0},async cancel(c){await A.return()},type:void 0})}return[{stream:r,source:i,length:s},o]}function KX(t,e=!1){return xs||(xs=require("stream/web").ReadableStream),t instanceof xs&&(dQ(!rc.isDisturbed(t),"The body has already been consumed."),dQ(!t.locked,"The stream is locked.")),TP(t,e)}function XX(t){let[e,r]=t.stream.tee(),n=qX(r,{transfer:[r]}),[,i]=n.tee();return t.stream=e,{stream:i,length:t.length,source:t.source}}async function*_P(t){if(t)if(PP(t))yield t;else{let e=t.stream;if(rc.isDisturbed(e))throw new TypeError("The body has already been consumed.");if(e.locked)throw new TypeError("The stream is locked.");e[jX]=!0,yield*e}}function hQ(t){if(t.aborted)throw new kP("The operation was aborted.","AbortError")}function ZX(t){return{blob(){return sm(this,r=>{let n=nZ(this);return n==="failure"?n="":n&&(n=WX(n)),new HX([r],{type:n})},t)},arrayBuffer(){return sm(this,r=>new Uint8Array(r).buffer,t)},text(){return sm(this,OP,t)},json(){return sm(this,rZ,t)},async formData(){uQ.brandCheck(this,t),hQ(this[Ss]);let r=this.headers.get("Content-Type");if(/multipart\/form-data/.test(r)){let n={};for(let[a,A]of this.headers)n[a.toLowerCase()]=A;let i=new RP,s;try{s=new TX({headers:n,preservePath:!0})}catch(a){throw new kP(`${a}`,"AbortError")}s.on("field",(a,A)=>{i.append(a,A)}),s.on("file",(a,A,c,l,u)=>{let d=[];if(l==="base64"||l.toLowerCase()==="base64"){let f="";A.on("data",g=>{f+=g.toString().replace(/[\r\n]/gm,"");let m=f.length-f.length%4;d.push(Buffer.from(f.slice(0,m),"base64")),f=f.slice(m)}),A.on("end",()=>{d.push(Buffer.from(f,"base64")),i.append(a,new DP(d,c,{type:u}))})}else A.on("data",f=>{d.push(f)}),A.on("end",()=>{i.append(a,new DP(d,c,{type:u}))})});let o=new Promise((a,A)=>{s.on("finish",a),s.on("error",c=>A(new TypeError(c)))});if(this.body!==null)for await(let a of _P(this[Ss].body))s.write(a);return s.end(),await o,i}else if(/application\/x-www-form-urlencoded/.test(r)){let n;try{let s="",o=new TextDecoder("utf-8",{ignoreBOM:!0});for await(let a of _P(this[Ss].body)){if(!PP(a))throw new TypeError("Expected Uint8Array chunk");s+=o.decode(a,{stream:!0})}s+=o.decode(),n=new URLSearchParams(s)}catch(s){throw Object.assign(new TypeError,{cause:s})}let i=new RP;for(let[s,o]of n)i.append(s,o);return i}else throw await Promise.resolve(),hQ(this[Ss]),uQ.errors.exception({header:`${t.name}.formData`,message:"Could not parse content as FormData."})}}}function eZ(t){Object.assign(t.prototype,ZX(t))}async function sm(t,e,r){if(uQ.brandCheck(t,r),hQ(t[Ss]),tZ(t[Ss].body))throw new TypeError("Body is unusable");let n=FX(),i=o=>n.reject(o),s=o=>{try{n.resolve(e(o))}catch(a){i(a)}};return t[Ss].body==null?(s(new Uint8Array),n.promise):(await UX(t[Ss].body,s,i),n.promise)}function tZ(t){return t!=null&&(t.stream.locked||rc.isDisturbed(t.stream))}function OP(t){return t.length===0?"":(t[0]===239&&t[1]===187&&t[2]===191&&(t=t.subarray(3)),$X.decode(t))}function rZ(t){return JSON.parse(OP(t))}function nZ(t){let{headersList:e}=t[Ss],r=e.get("content-type");return r===null?"failure":VX(r)}MP.exports={extractBody:TP,safelyExtractBody:KX,cloneBody:XX,mixinBody:eZ}});var qP=h((M_e,UP)=>{"use strict";var{InvalidArgumentError:ft,NotSupportedError:iZ}=at(),vs=require("assert"),{kHTTP2BuildRequest:sZ,kHTTP2CopyHeaders:oZ,kHTTP1BuildRequest:aZ}=yt(),Xr=Fe(),LP=/^[\^_`a-zA-Z\-0-9!#$%&'*+.|~]+$/,FP=/[^\t\x20-\x7e\x80-\xff]/,AZ=/[^\u0021-\u00ff]/,Ri=Symbol("handler"),$t={},gQ;try{let t=require("diagnostics_channel");$t.create=t.channel("undici:request:create"),$t.bodySent=t.channel("undici:request:bodySent"),$t.headers=t.channel("undici:request:headers"),$t.trailers=t.channel("undici:request:trailers"),$t.error=t.channel("undici:request:error")}catch{$t.create={hasSubscribers:!1},$t.bodySent={hasSubscribers:!1},$t.headers={hasSubscribers:!1},$t.trailers={hasSubscribers:!1},$t.error={hasSubscribers:!1}}var mQ=class t{constructor(e,{path:r,method:n,body:i,headers:s,query:o,idempotent:a,blocking:A,upgrade:c,headersTimeout:l,bodyTimeout:u,reset:d,throwOnError:f,expectContinue:g},m){if(typeof r!="string")throw new ft("path must be a string");if(r[0]!=="/"&&!(r.startsWith("http://")||r.startsWith("https://"))&&n!=="CONNECT")throw new ftLine truncated `);d.push(I,C,f),typeof C.size=="number"?s+=I.byteLength+C.size+f.byteLength:g=!0}let m=bm.encode(`--${A}--`);d.push(m),s+=m.byteLength,g&&(s=null),i=t,n=async function*(){for(let E of d)E.stream?yield*E.stream():yield E},o="multipart/form-data; boundary="+A}else if(ST(t))i=t,s=t.size,t.type&&(o=t.type);else if(typeof t[Symbol.asyncIterator]=="function"){if(e)throw new TypeError("keepalive");if(gc.isDisturbed(t)||t.locked)throw new TypeError("Response body object should not be disturbed or locked");r=t instanceof Ms?t:w7(t)}if((typeof i=="string"||gc.isBuffer(i))&&(s=Buffer.byteLength(i)),n!=null){let A;r=new Ms({async start(){A=n(t)[Symbol.asyncIterator]()},async pull(c){let{value:l,done:u}=await A.next();return u?queueMicrotask(()=>{c.close()}):T7(r)||c.enqueue(new Uint8Array(l)),c.desiredSize>0},async cancel(c){await A.return()},type:void 0})}return[{stream:r,source:i,length:s},o]}function q7(t,e=!1){return Ms||(Ms=require("stream/web").ReadableStream),t instanceof Ms&&(HQ(!gc.isDisturbed(t),"The body has already been consumed."),HQ(!t.locked,"The stream is locked.")),PT(t,e)}function H7(t){let[e,r]=t.stream.tee(),n=D7(r,{transfer:[r]}),[,i]=n.tee();return t.stream=e,{stream:i,length:t.length,source:t.source}}async function*DT(t){if(t)if(kT(t))yield t;else{let e=t.stream;if(gc.isDisturbed(e))throw new TypeError("The body has already been consumed.");if(e.locked)throw new TypeError("The stream is locked.");e[P7]=!0,yield*e}}function zQ(t){if(t.aborted)throw new _T("The operation was aborted.","AbortError")}function j7(t){return{blob(){return Nm(this,r=>{let n=J7(this);return n==="failure"?n="":n&&(n=F7(n)),new _7([r],{type:n})},t)},arrayBuffer(){return Nm(this,r=>new Uint8Array(r).buffer,t)},text(){return Nm(this,TT,t)},json(){return Nm(this,Y7,t)},async formData(){qQ.brandCheck(this,t),zQ(this[Fs]);let r=this.headers.get("Content-Type");if(/multipart\/form-data/.test(r)){let n={};for(let[a,A]of this.headers)n[a.toLowerCase()]=A;let i=new RT,s;try{s=new N7({headers:n,preservePath:!0})}catch(a){throw new _T(`${a}`,"AbortError")}s.on("field",(a,A)=>{i.append(a,A)}),s.on("file",(a,A,c,l,u)=>{let d=[];if(l==="base64"||l.toLowerCase()==="base64"){let f="";A.on("data",g=>{f+=g.toString().replace(/[\r\n]/gm,"");let m=f.length-f.length%4;d.push(Buffer.from(f.slice(0,m),"base64")),f=f.slice(m)}),A.on("end",()=>{d.push(Buffer.from(f,"base64")),i.append(a,new vT(d,c,{type:u}))})}else A.on("data",f=>{d.push(f)}),A.on("end",()=>{i.append(a,new vT(d,c,{type:u}))})});let o=new Promise((a,A)=>{s.on("finish",a),s.on("error",c=>A(new TypeError(c)))});if(this.body!==null)for await(let a of DT(this[Fs].body))s.write(a);return s.end(),await o,i}else if(/application\/x-www-form-urlencoded/.test(r)){let n;try{let s="",o=new TextDecoder("utf-8",{ignoreBOM:!0});for await(let a of DT(this[Fs].body)){if(!kT(a))throw new TypeError("Expected Uint8Array chunk");s+=o.decode(a,{stream:!0})}s+=o.decode(),n=new URLSearchParams(s)}catch(s){throw Object.assign(new TypeError,{cause:s})}let i=new RT;for(let[s,o]of n)i.append(s,o);return i}else throw await Promise.resolve(),zQ(this[Fs]),qQ.errors.exception({header:`${t.name}.formData`,message:"Could not parse content as FormData."})}}}function z7(t){Object.assign(t.prototype,j7(t))}async function Nm(t,e,r){if(qQ.brandCheck(t,r),zQ(t[Fs]),G7(t[Fs].body))throw new TypeError("Body is unusable");let n=R7(),i=o=>n.reject(o),s=o=>{try{n.resolve(e(o))}catch(a){i(a)}};return t[Fs].body==null?(s(new Uint8Array),n.promise):(await v7(t[Fs].body,s,i),n.promise)}function G7(t){return t!=null&&(t.stream.locked||gc.isDisturbed(t.stream))}function TT(t){return t.length===0?"":(t[0]===239&&t[1]===187&&t[2]===191&&(t=t.subarray(3)),U7.decode(t))}function Y7(t){return JSON.parse(TT(t))}function J7(t){let{headersList:e}=t[Fs],r=e.get("content-type");return r===null?"failure":M7(r)}OT.exports={extractBody:PT,safelyExtractBody:q7,cloneBody:H7,mixinBody:z7}});var UT=h((LMe,FT)=>{"use strict";var{InvalidArgumentError:mt,NotSupportedError:V7}=lt(),Us=require("assert"),{kHTTP2BuildRequest:W7,kHTTP2CopyHeaders:$7,kHTTP1BuildRequest:K7}=Ct(),an=He(),LT=/^[\^_`a-zA-Z\-0-9!#$%&'*+.|~]+$/,MT=/[^\t\x20-\x7e\x80-\xff]/,X7=/[^\u0021-\u00ff]/,Ui=Symbol("handler"),er={},GQ;try{let t=require("diagnostics_channel");er.create=t.channel("undici:request:create"),er.bodySent=t.channel("undici:request:bodySent"),er.headers=t.channel("undici:request:headers"),er.trailers=t.channel("undici:request:trailers"),er.error=t.channel("undici:request:error")}catch{er.create={hasSubscribers:!1},er.bodySent={hasSubscribers:!1},er.headers={hasSubscribers:!1},er.trailers={hasSubscribers:!1},er.error={hasSubscribers:!1}}var YQ=class t{constructor(e,{path:r,method:n,body:i,headers:s,query:o,idempotent:a,blocking:A,upgrade:c,headersTimeout:l,bodyTimeout:u,reset:d,throwOnError:f,expectContinue:g},m){if(typeof r!="string")throw new mt("path must be a string");if(r[0]!=="/"&&!(r.startsWith("http://")||r.startsWith("https://"))&&n!=="CONNECT")throw new mtLine truncated
`),this.body=E.stream,this.contentLength=E.length}else Xr.isBlobLike(i)&&this.contentType==null&&i.type&&(this.contentType=i.type,this.headers+=`content-type: ${i.type}\r `),this.body=E.stream,this.contentLength=E.length}else an.isBlobLike(i)&&this.contentType==null&&i.type&&(this.contentType=i.type,this.headers+=`content-type: ${i.type}\r
`);Xr.validateHandler(m,n,c),this.servername=Xr.getServerName(this.host),this[Ri]=m,$t.create.hasSubscribers&&$t.create.publish({request:this})}onBodySent(e){if(this[Ri].onBodySent)try{return this[Ri].onBodySent(e)}catch(r){this.abort(r)}}onRequestSent(){if($t.bodySent.hasSubscribers&&$t.bodySent.publish({request:this}),this[Ri].onRequestSent)try{return this[Ri].onRequestSent()}catch(e){this.abort(e)}}onConnect(e){if(vs(!this.aborted),vs(!this.completed),this.error)e(this.error);else return this.abort=e,this[Ri].onConnect(e)}onHeaders(e,r,n,i){vs(!this.aborted),vs(!this.completed),$t.headers.hasSubscribers&&$t.headers.publish({request:this,response:{statusCode:e,headers:r,statusText:i}});try{return this[Ri].onHeaders(e,r,n,i)}catch(s){this.abort(s)}}onData(e){vs(!this.aborted),vs(!this.completed);try{return this[Ri].onData(e)}catch(r){return this.abort(r),!1}}onUpgrade(e,r,n){return vs(!this.aborted),vs(!this.completed),this[Ri].onUpgrade(e,r,n)}onComplete(e){this.onFinally(),vs(!this.aborted),this.completed=!0,$t.trailers.hasSubscribers&&$t.trailers.publish({request:this,trailers:e});try{return this[Ri].onComplete(e)}catch(r){this.onError(r)}}onError(e){if(this.onFinally(),$t.error.hasSubscribers&&$t.error.publish({request:this,error:e}),!this.aborted)return this.aborted=!0,this[Ri].onError(e)}onFinally(){this.errorHandler&&(this.body.off("error",this.errorHandler),this.errorHandler=null),this.endHandler&&(this.body.off("end",this.endHandler),this.endHandler=null)}addHeader(e,r){return Id(this,e,r),this}static[aZ](e,r,n){return new t(e,r,n)}static[sZ](e,r,n){let i=r.headers;r={...r,headers:null};let s=new t(e,r,n);if(s.headers={},Array.isArray(i)){if(i.length%2!==0)throw new ft("headers array must be even");for(let o=0;o<i.length;o+=2)Id(s,i[o],i[o+1],!0)}else if(i&&typeof i=="object"){let o=Object.keys(i);for(let a=0;a<o.length;a++){let A=o[a];Id(s,A,i[A],!0)}}else if(i!=null)throw new ft("headers must be an object or an array");return s}static[oZ](e){let r=e.split(`\r `);an.validateHandler(m,n,c),this.servername=an.getServerName(this.host),this[Ui]=m,er.create.hasSubscribers&&er.create.publish({request:this})}onBodySent(e){if(this[Ui].onBodySent)try{return this[Ui].onBodySent(e)}catch(r){this.abort(r)}}onRequestSent(){if(er.bodySent.hasSubscribers&&er.bodySent.publish({request:this}),this[Ui].onRequestSent)try{return this[Ui].onRequestSent()}catch(e){this.abort(e)}}onConnect(e){if(Us(!this.aborted),Us(!this.completed),this.error)e(this.error);else return this.abort=e,this[Ui].onConnect(e)}onHeaders(e,r,n,i){Us(!this.aborted),Us(!this.completed),er.headers.hasSubscribers&&er.headers.publish({request:this,response:{statusCode:e,headers:r,statusText:i}});try{return this[Ui].onHeaders(e,r,n,i)}catch(s){this.abort(s)}}onData(e){Us(!this.aborted),Us(!this.completed);try{return this[Ui].onData(e)}catch(r){return this.abort(r),!1}}onUpgrade(e,r,n){return Us(!this.aborted),Us(!this.completed),this[Ui].onUpgrade(e,r,n)}onComplete(e){this.onFinally(),Us(!this.aborted),this.completed=!0,er.trailers.hasSubscribers&&er.trailers.publish({request:this,trailers:e});try{return this[Ui].onComplete(e)}catch(r){this.onError(r)}}onError(e){if(this.onFinally(),er.error.hasSubscribers&&er.error.publish({request:this,error:e}),!this.aborted)return this.aborted=!0,this[Ui].onError(e)}onFinally(){this.errorHandler&&(this.body.off("error",this.errorHandler),this.errorHandler=null),this.endHandler&&(this.body.off("end",this.endHandler),this.endHandler=null)}addHeader(e,r){return Od(this,e,r),this}static[K7](e,r,n){return new t(e,r,n)}static[W7](e,r,n){let i=r.headers;r={...r,headers:null};let s=new t(e,r,n);if(s.headers={},Array.isArray(i)){if(i.length%2!==0)throw new mt("headers array must be even");for(let o=0;o<i.length;o+=2)Od(s,i[o],i[o+1],!0)}else if(i&&typeof i=="object"){let o=Object.keys(i);for(let a=0;a<o.length;a++){let A=o[a];Od(s,A,i[A],!0)}}else if(i!=null)throw new mt("headers must be an object or an array");return s}static[$7](e){let r=e.split(`\r
`),n={};for(let i of r){let[s,o]=i.split(": ");o==null||o.length===0||(n[s]?n[s]+=`,${o}`:n[s]=o)}return n}};function Ia(t,e,r){if(e&&typeof e=="object")throw new ft(`invalid ${t} header`);if(e=e!=null?`${e}`:"",FP.exec(e)!==null)throw new ft(`invalid ${t} header`);return r?e:`${t}: ${e}\r `),n={};for(let i of r){let[s,o]=i.split(": ");o==null||o.length===0||(n[s]?n[s]+=`,${o}`:n[s]=o)}return n}};function Ta(t,e,r){if(e&&typeof e=="object")throw new mt(`invalid ${t} header`);if(e=e!=null?`${e}`:"",MT.exec(e)!==null)throw new mt(`invalid ${t} header`);return r?e:`${t}: ${e}\r
`}function Id(t,e,r,n=!1){if(r&&typeof r=="object"&&!Array.isArray(r))throw new ft(`invalid ${e} header`);if(r===void 0)return;if(t.host===null&&e.length===4&&e.toLowerCase()==="host"){if(FP.exec(r)!==null)throw new ft(`invalid ${e} header`);t.host=r}else if(t.contentLength===null&&e.length===14&&e.toLowerCase()==="content-length"){if(t.contentLength=parseInt(r,10),!Number.isFinite(t.contentLength))throw new ft("invalid content-length header")}else if(t.contentType===null&&e.length===12&&e.toLowerCase()==="content-type")t.contentType=r,n?t.headers[e]=Ia(e,r,n):t.headers+=Ia(e,r);else{if(e.length===17&&e.toLowerCase()==="transfer-encoding")throw new ft("invalid transfer-encoding header");if(e.length===10&&e.toLowerCase()==="connection"){let i=typeof r=="string"?r.toLowerCase():null;if(i!=="close"&&i!=="keep-alive")throw new ft("invalid connection header");i==="close"&&(t.reset=!0)}else{if(e.length===10&&e.toLowerCase()==="keep-alive")throw new ft("invalid keep-alive header");if(e.length===7&&e.toLowerCase()==="upgrade")throw new ft("invalid upgrade header");if(e.length===6&&e.toLowerCase()==="expect")throw new iZ("expect header not supported");if(LP.exec(e)===null)throw new ft("invalid header key");if(Array.isArray(r))for(let i=0;i<r.length;i++)n?t.headers[e]?t.headers[e]+=`,${Ia(e,r[i],n)}`:t.headers[e]=Ia(e,r[i],n):t.headers+=Ia(e,r[i]);else n?t.headers[e]=Ia(e,r,n):t.headers+=Ia(e,r)}}}UP.exports=mQ});var om=h((L_e,HP)=>{"use strict";var cZ=require("events"),pQ=class extends cZ{dispatch(){throw new Error("not implemented")}close(){throw new Error("not implemented")}destroy(){throw new Error("not implemented")}};HP.exports=pQ});var Qd=h((F_e,zP)=>{"use strict";var lZ=om(),{ClientDestroyedError:yQ,ClientClosedError:uZ,InvalidArgumentError:nc}=at(),{kDestroy:dZ,kClose:fZ,kDispatch:EQ,kInterceptors:Ba}=yt(),ic=Symbol("destroyed"),Bd=Symbol("closed"),Rs=Symbol("onDestroyed"),sc=Symbol("onClosed"),am=Symbol("Intercepted Dispatch"),CQ=class extends lZ{constructor(){super(),this[ic]=!1,this[Rs]=null,this[Bd]=!1,this[sc]=[]}get destroyed(){return this[ic]}get closed(){return this[Bd]}get interceptors(){return this[Ba]}set interceptors(e){if(e){for(let r=e.length-1;r>=0;r--)if(typeof this[Ba][r]!="function")throw new nc("interceptor must be an function")}this[Ba]=e}close(e){if(e===void 0)return new Promise((n,i)=>{this.close((s,o)=>s?i(s):n(o))});if(typeof e!="function")throw new nc("invalid callback");if(this[ic]){queueMicrotask(()=>e(new yQ,null));return}if(this[Bd]){this[sc]?this[sc].push(e):queueMicrotask(()=>e(null,null));return}this[Bd]=!0,this[sc].push(e);let r=()=>{let n=this[sc];this[sc]=null;for(let i=0;i<n.length;i++)n[i](null,null)};this[fZ]().then(()=>this.destroy()).then(()=>{queueMicrotask(r)})}destroy(e,r){if(typeof e=="function"&&(r=e,e=null),r===void 0)return new Promise((i,s)=>{this.destroy(e,(o,a)=>o?s(o):i(a))});if(typeof r!="function")throw new nc("invalid callback");if(this[ic]){this[Rs]?this[Rs].push(r):queueMicrotask(()=>r(null,null));return}e||(e=new yQ),this[ic]=!0,this[Rs]=this[Rs]||[],this[Rs].push(r);let n=()=>{let i=this[Rs];this[Rs]=null;for(let s=0;s<i.length;s++)i[s](null,null)};this[dZ](e).then(()=>{queueMicrotask(n)})}[am](e,r){if(!this[Ba]||this[Ba].length===0)return this[am]=this[EQ],this[EQ](e,r);let n=this[EQ].bind(this);for(let i=this[Ba].length-1;i>=0;i--)n=this[Ba][i](n);return this[am]=n,n(e,r)}dispatch(e,r){if(!r||typeof r!="object")throw new nc("handler must be an object");try{if(!e||typeof e!="object")throw new nc("opts must be an object.");if(this[ic]||this[Rs])throw new yQ;if(this[Bd])throw new uZ;return this[am](e,r)}catch(n){if(typeof r.onError!="function")throw new nc("invalid onError method");return r.onError(n),!1}}};zP.exports=CQ});var bd=h((H_e,YP)=>{"use strict";var hZ=require("net"),jP=require("assert"),GP=Fe(),{InvalidArgumentError:gZ,ConnectTimeoutError:mZ}=at(),IQ,BQ;global.FinalizationRegistry&&!process.env.NODE_V8_COVERAGE?BQ=class{constructor(e){this._maxCachedSessions=e,this._sessionCache=new Map,this._sessionRegistry=new global.FinalizationRegistry(r=>{if(this._sessionCache.size<this._maxCachedSessions)return;let n=this._sessionCache.get(r);n!==void 0&&n.deref()===void 0&&this._sessionCache.delete(r)})}get(e){let r=this._sessionCache.get(e);return r?r.deref():null}set(e,r){this._maxCachedSessions!==0&&(this._sessionCache.set(e,new WeakRef(r)),this._sessionRegistry.register(r,e))}}:BQ=class{constructor(e){this._maxCachedSessions=e,this._sessionCache=new Map}get(e){return this._sessionCache.get(e)}set(e,r){if(this._maxCachedSessions!==0){if(this._sessionCache.size>=this._maxCachedSessions){let{value:n}=this._sessionCache.keys().next();this._sessionCache.delete(n)}this._sessionCache.set(e,r)}}};function pZ({allowH2:t,maxCachedSessions:e,socketPath:r,timeout:n,...i}){if(e!=null&&(!Number.isInteger(e)||e<0))throw new gZ("maxCachedSessions must be a positive integer or zero");let s={path:r,...i},o=new BQ(e??100);return n=n??1e4,t=t??!1,function({hostname: Line truncated `}function Od(t,e,r,n=!1){if(r&&typeof r=="object"&&!Array.isArray(r))throw new mt(`invalid ${e} header`);if(r===void 0)return;if(t.host===null&&e.length===4&&e.toLowerCase()==="host"){if(MT.exec(r)!==null)throw new mt(`invalid ${e} header`);t.host=r}else if(t.contentLength===null&&e.length===14&&e.toLowerCase()==="content-length"){if(t.contentLength=parseInt(r,10),!Number.isFinite(t.contentLength))throw new mt("invalid content-length header")}else if(t.contentType===null&&e.length===12&&e.toLowerCase()==="content-type")t.contentType=r,n?t.headers[e]=Ta(e,r,n):t.headers+=Ta(e,r);else{if(e.length===17&&e.toLowerCase()==="transfer-encoding")throw new mt("invalid transfer-encoding header");if(e.length===10&&e.toLowerCase()==="connection"){let i=typeof r=="string"?r.toLowerCase():null;if(i!=="close"&&i!=="keep-alive")throw new mt("invalid connection header");i==="close"&&(t.reset=!0)}else{if(e.length===10&&e.toLowerCase()==="keep-alive")throw new mt("invalid keep-alive header");if(e.length===7&&e.toLowerCase()==="upgrade")throw new mt("invalid upgrade header");if(e.length===6&&e.toLowerCase()==="expect")throw new V7("expect header not supported");if(LT.exec(e)===null)throw new mt("invalid header key");if(Array.isArray(r))for(let i=0;i<r.length;i++)n?t.headers[e]?t.headers[e]+=`,${Ta(e,r[i],n)}`:t.headers[e]=Ta(e,r[i],n):t.headers+=Ta(e,r[i]);else n?t.headers[e]=Ta(e,r,n):t.headers+=Ta(e,r)}}}FT.exports=YQ});var wm=h((MMe,qT)=>{"use strict";var Z7=require("events"),JQ=class extends Z7{dispatch(){throw new Error("not implemented")}close(){throw new Error("not implemented")}destroy(){throw new Error("not implemented")}};qT.exports=JQ});var Md=h((FMe,HT)=>{"use strict";var eee=wm(),{ClientDestroyedError:VQ,ClientClosedError:tee,InvalidArgumentError:mc}=lt(),{kDestroy:ree,kClose:nee,kDispatch:WQ,kInterceptors:Oa}=Ct(),pc=Symbol("destroyed"),Ld=Symbol("closed"),qs=Symbol("onDestroyed"),yc=Symbol("onClosed"),xm=Symbol("Intercepted Dispatch"),$Q=class extends eee{constructor(){super(),this[pc]=!1,this[qs]=null,this[Ld]=!1,this[yc]=[]}get destroyed(){return this[pc]}get closed(){return this[Ld]}get interceptors(){return this[Oa]}set interceptors(e){if(e){for(let r=e.length-1;r>=0;r--)if(typeof this[Oa][r]!="function")throw new mc("interceptor must be an function")}this[Oa]=e}close(e){if(e===void 0)return new Promise((n,i)=>{this.close((s,o)=>s?i(s):n(o))});if(typeof e!="function")throw new mc("invalid callback");if(this[pc]){queueMicrotask(()=>e(new VQ,null));return}if(this[Ld]){this[yc]?this[yc].push(e):queueMicrotask(()=>e(null,null));return}this[Ld]=!0,this[yc].push(e);let r=()=>{let n=this[yc];this[yc]=null;for(let i=0;i<n.length;i++)n[i](null,null)};this[nee]().then(()=>this.destroy()).then(()=>{queueMicrotask(r)})}destroy(e,r){if(typeof e=="function"&&(r=e,e=null),r===void 0)return new Promise((i,s)=>{this.destroy(e,(o,a)=>o?s(o):i(a))});if(typeof r!="function")throw new mc("invalid callback");if(this[pc]){this[qs]?this[qs].push(r):queueMicrotask(()=>r(null,null));return}e||(e=new VQ),this[pc]=!0,this[qs]=this[qs]||[],this[qs].push(r);let n=()=>{let i=this[qs];this[qs]=null;for(let s=0;s<i.length;s++)i[s](null,null)};this[ree](e).then(()=>{queueMicrotask(n)})}[xm](e,r){if(!this[Oa]||this[Oa].length===0)return this[xm]=this[WQ],this[WQ](e,r);let n=this[WQ].bind(this);for(let i=this[Oa].length-1;i>=0;i--)n=this[Oa][i](n);return this[xm]=n,n(e,r)}dispatch(e,r){if(!r||typeof r!="object")throw new mc("handler must be an object");try{if(!e||typeof e!="object")throw new mc("opts must be an object.");if(this[pc]||this[qs])throw new VQ;if(this[Ld])throw new tee;return this[xm](e,r)}catch(n){if(typeof r.onError!="function")throw new mc("invalid onError method");return r.onError(n),!1}}};HT.exports=$Q});var Fd=h((HMe,GT)=>{"use strict";var iee=require("net"),jT=require("assert"),zT=He(),{InvalidArgumentError:see,ConnectTimeoutError:oee}=lt(),KQ,XQ;global.FinalizationRegistry&&!process.env.NODE_V8_COVERAGE?XQ=class{constructor(e){this._maxCachedSessions=e,this._sessionCache=new Map,this._sessionRegistry=new global.FinalizationRegistry(r=>{if(this._sessionCache.size<this._maxCachedSessions)return;let n=this._sessionCache.get(r);n!==void 0&&n.deref()===void 0&&this._sessionCache.delete(r)})}get(e){let r=this._sessionCache.get(e);return r?r.deref():null}set(e,r){this._maxCachedSessions!==0&&(this._sessionCache.set(e,new WeakRef(r)),this._sessionRegistry.register(r,e))}}:XQ=class{constructor(e){this._maxCachedSessions=e,this._sessionCache=new Map}get(e){return this._sessionCache.get(e)}set(e,r){if(this._maxCachedSessions!==0){if(this._sessionCache.size>=this._maxCachedSessions){let{value:n}=this._sessionCache.keys().next();this._sessionCache.delete(n)}this._sessionCache.set(e,r)}}};function aee({allowH2:t,maxCachedSessions:e,socketPath:r,timeout:n,...i}){if(e!=null&&(!Number.isInteger(e)||e<0))throw new see("maxCachedSessions must be a positive integer or zero");let s={path:r,...i},o=new XQ(e??100);return n=n??1e4,t=t??!1,functi Line truncated
`,this[cT]=A??3e5,this[AT]=i??3e5,this[Rd]=I??!0,this[JZ]=w,this[Dd]=T,this[Eo]=null,this[uT]=k>-1?k:-1,this[$i]="h1",this[Sn]=null,this[gm]=Se?{openStreams:0,maxConcurrentStreams:H??100}:null,this[dT]=`${this[Br].hostname}${this[Br].port?`:${this[Br].port}`:""}`,this[Et]=[],this[Ct]=0,this[xn]=0}get pipelining(){return this[Io]}set pipelining(e){this[Io]=e,vn(this,!0)}get[Na](){return this[Et].length-this[xn]}get[St](){return this[xn]-this[Ct]}get[ba](){return this[Et].length-this[Ct]}get[YZ](){return!!this[_t]&&!this[ac]&&!this[_t].destroyed}get[RQ](){let e=this[_t];return e&&(e[Hr]||e[ks]||e[cc])||this[ba]>=(this[Io]||1)||this[Na]>0}[GZ](e){mT(this),this.once("connect",e)}[$Z](e,r){let n=e.origin||this[Br].origin,i=this[$i]==="h2"?vQ[XZ](n,e,r):vQ[e6](n,e,r);return this[Et].push(i),this[Qa]||(Ae.bodyLength(i.body)==null&&Ae.isIterable(i.body)?(this[Qa]=1,process.nextTick(vn,this)):vn(this,!0)),this[Qa]&&this[Co]!==2&&this[RQ]&&(this[Co]=2),this[Co]<2}async[VZ](){return new Promise(e=>{this[ba]?this[Eo]=e:e(null)})}async[WZ](e){return new Promise(r=>{let n=this[Et].splice(this[xn]);for(let s=0;s<n.length;s++){let o=n[s];zr(this,o,e)}let i=()=>{this[Eo]&&(this[Eo](),this[Eo]=null),r()};this[Sn]!=null&&(Ae.destroy(this[Sn],e),this[Sn]=null,this[gm]=null),this[_t]?Ae.destroy(this[_t].on("close",i),e):queueMicrotask(i),vn(this)})}};function A6(t){ee(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[_t][Qr]=t,Em(this[Wi],t)}function c6(t,e,r){let n=new Vi(`HTTP/2: "frameError" received - type ${t}, code ${e}`);r===0&&(this[_t][Qr]=n,Em(this[Wi],n))}function l6(){Ae.destroy(this,new Ac("other side closed")),Ae.destroy(this[_t],new Ac("other side closed"))}function u6(t){let e=this[Wi],r=new Vi(`HTTP/2: "GOAWAY" frame received with code ${t}`);if(e[_t]=null,e[Sn]=null,e.destroyed){ee(this[Na]===0);let n=e[Et].splice(e[Ct]);for(let i=0;i<n.length;i++){let s=n[i];zr(this,s,r)}}else if(e[St]>0){let n=e[Et][e[Ct]];e[Et][e[Ct]++]=null,zr(e,n,r)}e[xn]=e[Ct],ee(e[St]===0),e.emit("disconnect",e[Br],[e],r),vn(e)}var Gi=VP(),d6=lm(),f6=Buffer.alloc(0);async function h6(){let t=process.env.JEST_WORKER_ID?wQ():void 0,e;try{e=await WebAssembly.compile(Buffer.from(tT(),"base64"))}catch{e=await WebAssembly.compile(Buffer.from(t||wQ(),"base64"))}return await WebAssembly.instantiate(e,{env:{wasm_on_url:(r,n,i)=>0,wasm_on_status:(r,n,i)=>{ee.strictEqual(tr.ptr,r);let s=n-Ji+Yi.byteOffset;return tr.onStatus(new um(Yi.buffer,s,i))||0},wasm_on_message_begin:r=>(ee.strictEqual(tr.ptr,r),tr.onMessageBegin()||0),wasm_on_header_field:(r,n,i)=>{ee.strictEqual(tr.ptr,r);let s=n-Ji+Yi.byteOffset;return tr.onHeaderField(new um(Yi.buffer,s,i))||0},wasm_on_header_value:(r,n,i)=>{ee.strictEqual(tr.ptr,r);let s=n-Ji+Yi.byteOffset;return tr.onHeaderValue(new um(Yi.buffer,s,i))||0},wasm_on_headers_complete:(r,n,i,s)=>(ee.strictEqual(tr.ptr,r),tr.onHeadersComplete(n,!!i,!!s)||0),wasm_on_body:(r,n,i)=>{ee.strictEqual(tr.ptr,r);let s=n-Ji+Yi.byteOffset;return tr.onBody(new um(Yi.buffer,s,i))||0},wasm_on_message_complete:r=>(ee.strictEqual(tr.ptr,r),tr.onMessageComplete()||0)}})}var SQ=null,kQ=h6();kQ.catch();var tr=null,Yi=null,dm=0,Ji=null,lc=1,hm=2,PQ=3,TQ=class{constructor(e,r,{exports:n}){ee(Number.isFinite(e[fm])&&e[fm]>0),this.llhttp=n,this.ptr=this.llhttp.llhttp_alloc(Gi.TYPE.RESPONSE),this.client=e,this.socket=r,this.timeout=null,this.timeoutValue=null,this.timeoutType=null,this.statusCode=null,this.statusText="",this.upgrade=!1,this.headers=[],this.headersSize=0,this.headersMaxSize=e[fm],this.shouldKeepAlive=!1,this.paused=!1,this.resume=this.resume.bind(this),this.bytesRead=0,this.keepAlive="",this.contentLength="",this.connection="",this.maxResponseSize=e[uT]}setTimeout(e,r){this.timeoutType=r,e!==this.timeoutValue?(xQ.clearTimeout(this.timeout),e?(this.timeout=xQ.setTimeout(g6,e,this),this.timeout.unref&&this.timeout.unref()):this.timeout=null,this.timeoutValue=e):this.timeout&&this.timeout.refresh&&this.timeout.refresh()}resume(){this.socket.destroyed||!this.paused||(ee(this.ptr!=null),ee(tr==null),this.llhttp.llhttp_resume(this.ptr),ee(this.timeoutType===hm),this.timeout&&this.timeout.refresh&&this.timeout.refresh(),this.paused=!1,this.execute(this.socket.read()||f6),this.readMore())}readMore(){for(;!this.paused&&this.ptr;){let e=this.socket.read();if(e===null)break;this.execute(e)}}execute(e){ee(this.ptr!=null),ee(tr==null),ee(!this.paused);let{socket:r,llhttp:n}=this;e.length>dm&&(Ji&&n.free(Ji),dm=Math.ceil(e.length/4096)*4096,Ji=n.malloc(dm)),new Uint8Array(n.memory.buffer,Ji,dm).set(e);try{let i;try{Yi=e,tr=this,i=n.llhttp_execute(this.ptr,Ji,e.length)}catch(o){throw o}finally{tr=null,Yi=null}let s=n.llhttp_get_error_pos(this.ptr)-Ji;if(i===Gi.ERROR.PAUSED_UPGRADE)this.onUpgrade(e.slice(s));else if(i===Gi.ERROR.PAUSED)this.paused=!0,r.unshift(e.slice(s));else if(i!==Gi.ERROR.OK){let o=n.llhttp_get_error_reason(this.ptr),a="";if(o){let A=new Uint8Array(n.memory.buffer,o).indexOf(0);a="Response does not match the HTTP/1.1 protocol ("+B Line truncated `,this[AO]=A??3e5,this[aO]=i??3e5,this[Gd]=I??!0,this[Lee]=w,this[Yd]=T,this[vo]=null,this[lO]=k>-1?k:-1,this[os]="h1",this[On]=null,this[Tm]=De?{openStreams:0,maxConcurrentStreams:H??100}:null,this[uO]=`${this[Sr].hostname}${this[Sr].port?`:${this[Sr].port}`:""}`,this[It]=[],this[Bt]=0,this[Tn]=0}get pipelining(){return this[_o]}set pipelining(e){this[_o]=e,Ln(this,!0)}get[Fa](){return this[It].length-this[Tn]}get[_t](){return this[Tn]-this[Bt]}get[Ma](){return this[It].length-this[Bt]}get[Oee](){return!!this[Ot]&&!this[Cc]&&!this[Ot].destroyed}get[ob](){let e=this[Ot];return e&&(e[Wr]||e[zs]||e[Bc])||this[Ma]>=(this[_o]||1)||this[Fa]>0}[Tee](e){gO(this),this.once("connect",e)}[Uee](e,r){let n=e.origin||this[Sr].origin,i=this[os]==="h2"?sb[Hee](n,e,r):sb[zee](n,e,r);return this[It].push(i),this[La]||(le.bodyLength(i.body)==null&&le.isIterable(i.body)?(this[La]=1,process.nextTick(Ln,this)):Ln(this,!0)),this[La]&&this[Do]!==2&&this[ob]&&(this[Do]=2),this[Do]<2}async[Mee](){return new Promise(e=>{this[Ma]?this[vo]=e:e(null)})}async[Fee](e){return new Promise(r=>{let n=this[It].splice(this[Tn]);for(let s=0;s<n.length;s++){let o=n[s];$r(this,o,e)}let i=()=>{this[vo]&&(this[vo](),this[vo]=null),r()};this[On]!=null&&(le.destroy(this[On],e),this[On]=null,this[Tm]=null),this[Ot]?le.destroy(this[Ot].on("close",i),e):queueMicrotask(i),Ln(this)})}};function Xee(t){re(t.code!=="ERR_TLS_CERT_ALTNAME_INVALID"),this[Ot][Rr]=t,Fm(this[ss],t)}function Zee(t,e,r){let n=new is(`HTTP/2: "frameError" received - type ${t}, code ${e}`);r===0&&(this[Ot][Rr]=n,Fm(this[ss],n))}function ete(){le.destroy(this,new Ic("other side closed")),le.destroy(this[Ot],new Ic("other side closed"))}function tte(t){let e=this[ss],r=new is(`HTTP/2: "GOAWAY" frame received with code ${t}`);if(e[Ot]=null,e[On]=null,e.destroyed){re(this[Fa]===0);let n=e[It].splice(e[Bt]);for(let i=0;i<n.length;i++){let s=n[i];$r(this,s,r)}}else if(e[_t]>0){let n=e[It][e[Bt]];e[It][e[Bt]++]=null,$r(e,n,r)}e[Tn]=e[Bt],re(e[_t]===0),e.emit("disconnect",e[Sr],[e],r),Ln(e)}var ts=JT(),rte=vm(),nte=Buffer.alloc(0);async function ite(){let t=process.env.JEST_WORKER_ID?rb():void 0,e;try{e=await WebAssembly.compile(Buffer.from(eO(),"base64"))}catch{e=await WebAssembly.compile(Buffer.from(t||rb(),"base64"))}return await WebAssembly.instantiate(e,{env:{wasm_on_url:(r,n,i)=>0,wasm_on_status:(r,n,i)=>{re.strictEqual(sr.ptr,r);let s=n-ns+rs.byteOffset;return sr.onStatus(new Dm(rs.buffer,s,i))||0},wasm_on_message_begin:r=>(re.strictEqual(sr.ptr,r),sr.onMessageBegin()||0),wasm_on_header_field:(r,n,i)=>{re.strictEqual(sr.ptr,r);let s=n-ns+rs.byteOffset;return sr.onHeaderField(new Dm(rs.buffer,s,i))||0},wasm_on_header_value:(r,n,i)=>{re.strictEqual(sr.ptr,r);let s=n-ns+rs.byteOffset;return sr.onHeaderValue(new Dm(rs.buffer,s,i))||0},wasm_on_headers_complete:(r,n,i,s)=>(re.strictEqual(sr.ptr,r),sr.onHeadersComplete(n,!!i,!!s)||0),wasm_on_body:(r,n,i)=>{re.strictEqual(sr.ptr,r);let s=n-ns+rs.byteOffset;return sr.onBody(new Dm(rs.buffer,s,i))||0},wasm_on_message_complete:r=>(re.strictEqual(sr.ptr,r),sr.onMessageComplete()||0)}})}var ib=null,cb=ite();cb.catch();var sr=null,rs=null,_m=0,ns=null,Qc=1,Pm=2,lb=3,ub=class{constructor(e,r,{exports:n}){re(Number.isFinite(e[km])&&e[km]>0),this.llhttp=n,this.ptr=this.llhttp.llhttp_alloc(ts.TYPE.RESPONSE),this.client=e,this.socket=r,this.timeout=null,this.timeoutValue=null,this.timeoutType=null,this.statusCode=null,this.statusText="",this.upgrade=!1,this.headers=[],this.headersSize=0,this.headersMaxSize=e[km],this.shouldKeepAlive=!1,this.paused=!1,this.resume=this.resume.bind(this),this.bytesRead=0,this.keepAlive="",this.contentLength="",this.connection="",this.maxResponseSize=e[lO]}setTimeout(e,r){this.timeoutType=r,e!==this.timeoutValue?(nb.clearTimeout(this.timeout),e?(this.timeout=nb.setTimeout(ste,e,this),this.timeout.unref&&this.timeout.unref()):this.timeout=null,this.timeoutValue=e):this.timeout&&this.timeout.refresh&&this.timeout.refresh()}resume(){this.socket.destroyed||!this.paused||(re(this.ptr!=null),re(sr==null),this.llhttp.llhttp_resume(this.ptr),re(this.timeoutType===Pm),this.timeout&&this.timeout.refresh&&this.timeout.refresh(),this.paused=!1,this.execute(this.socket.read()||nte),this.readMore())}readMore(){for(;!this.paused&&this.ptr;){let e=this.socket.read();if(e===null)break;this.execute(e)}}execute(e){re(this.ptr!=null),re(sr==null),re(!this.paused);let{socket:r,llhttp:n}=this;e.length>_m&&(ns&&n.free(ns),_m=Math.ceil(e.length/4096)*4096,ns=n.malloc(_m)),new Uint8Array(n.memory.buffer,ns,_m).set(e);try{let i;try{rs=e,sr=this,i=n.llhttp_execute(this.ptr,ns,e.length)}catch(o){throw o}finally{sr=null,rs=null}let s=n.llhttp_get_error_pos(this.ptr)-ns;if(i===ts.ERROR.PAUSED_UPGRADE)this.onUpgrade(e.slice(s));else if(i===ts.ERROR.PAUSED)this.paused=!0,r.unshift(e.slice(s));else if(i!==ts.ERROR.OK){let o=n.llhttp_get_error_reason(this.ptr),a="";if(o){let A=new Uint8Array(n.memory.buffer,o).indexOf(0);a="Response does not match the HTTP Line truncated
`;return typeof s=="string"?g+=`host: ${s}\r `;return typeof s=="string"?g+=`host: ${s}\r
`:g+=t[sT],o?g+=`connection: upgrade\r `:g+=t[iO],o?g+=`connection: upgrade\r
upgrade: ${o}\r upgrade: ${o}\r
`:t[Io]&&!f[Hr]?g+=`connection: keep-alive\r `:t[_o]&&!f[Wr]?g+=`connection: keep-alive\r
`:g+=`connection: close\r `:g+=`connection: close\r
`,a&&(g+=a),_r.sendHeaders.hasSubscribers&&_r.sendHeaders.publish({request:e,headers:g,socket:f}),!r||u===0?(d===0?f.write(`${g}content-length: 0\r `,a&&(g+=a),Fr.sendHeaders.hasSubscribers&&Fr.sendHeaders.publish({request:e,headers:g,socket:f}),!r||u===0?(d===0?f.write(`${g}content-length: 0\r
\r \r
`,"latin1"):(ee(d===null,"no body must not have content length"),f.write(`${g}\r `,"latin1"):(re(d===null,"no body must not have content length"),f.write(`${g}\r
`,"latin1")),e.onRequestSent()):Ae.isBuffer(r)?(ee(d===r.byteLength,"buffer body must have content length"),f.cork(),f.write(`${g}content-length: ${d}\r `,"latin1")),e.onRequestSent()):le.isBuffer(r)?(re(d===r.byteLength,"buffer body must have content length"),f.cork(),f.write(`${g}content-length: ${d}\r
\r \r
`,"latin1"),f.write(r),f.uncork(),e.onBodySent(r),e.onRequestSent(),l||(f[Hr]=!0)):Ae.isBlobLike(r)?typeof r.stream=="function"?pm({body:r.stream(),client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):ET({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):Ae.isStream(r)?yT({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):Ae.isIterable(r)?pm({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):ee(!1),!0}function y6(t,e,r){let{body:n,method:i,path:s,host:o,upgrade:a,expectContinue:A,signal:c,headers:l}=r,u;if(typeof l=="string"?u=vQ[ZZ](l.trim()):u=l,a)return zr(t,r,new Error("Upgrade not supported for H2")),!1;try{r.onConnect(I=>{r.aborted||r.completed||zr(t,r,I||new MQ)})}catch(I){zr(t,r,I)}if(r.aborted)return!1;let d,f=t[gm];if(u[t6]=o||t[dT],u[r6]=i,i==="CONNECT")return e.ref(),d=e.request(u,{endStream:!1,signal:c}),d.id&&!d.pending?(r.onUpgrade(null,null,d),++f.openStreams):d.once("ready",()=>{r.onUpgrade(null,null,d),++f.openStreams}),d.once("close",()=>{f.openStreams-=1,f.openStreams===0&&e.unref()}),!0;u[n6]=s,u[i6]="https";let g=i==="PUT"||i==="POST"||i==="PATCH";n&&typeof n.read=="function"&&n.read(0);let m=Ae.bodyLength(n);if(m==null&&(m=r.contentLength),(m===0||!g)&&(m=null),pT(i)&&m>0&&r.contentLength!=null&&r.contentLength!==m){if(t[Rd])return zr(t,r,new _s),!1;process.emitWarning(new _s)}m!=null&&(ee(n,"no body must not have content length"),u[s6]=`${m}`),e.ref();let E=i==="GET"||i==="HEAD";return A?(u[o6]="100-continue",d=e.request(u,{endStream:E,signal:c}),d.once("continue",C)):(d=e.request(u,{endStream:E,signal:c}),C()),++f.openStreams,d.once("response",I=>{let{[a6]:N,...w}=I;r.onHeaders(Number(N),w,d.resume.bind(d),"")===!1&&d.pause()}),d.once("end",()=>{r.onComplete([])}),d.on("data",I=>{r.onData(I)===!1&&d.pause()}),d.once("close",()=>{f.openStreams-=1,f.openStreams===0&&e.unref()}),d.once("error",function(I){t[Sn]&&!t[Sn].destroyed&&!this.closed&&!this.destroyed&&(f.streams-=1,Ae.destroy(d,I))}),d.once("frameError",(I,N)=>{let w=new Vi(`HTTP/2: "frameError" received - type ${I}, code ${N}`);zr(t,r,w),t[Sn]&&!t[Sn].destroyed&&!this.closed&&!this.destroyed&&(f.streams-=1,Ae.destroy(d,w))}),!0;function C(){n?Ae.isBuffer(n)?(ee(m===n.byteLength,"buffer body must have content length"),d.cork(),d.write(n),d.uncork(),d.end(),r.onBodySent(n),r.onRequestSent()):Ae.isBlobLike(n)?typeof n.stream=="function"?pm({client:t,request:r,contentLength:m,h2stream:d,expectsPayload:g,body:n.stream(),socket:t[_t],header:""}):ET({body:n,client:t,request:r,contentLength:m,expectsPayload:g,h2stream:d,header:"",socket:t[_t]}):Ae.isStream(n)?yT({body:n,client:t,request:r,contentLength:m,expectsPayload:g,socket:t[_t],h2stream:d,header:""}):Ae.isIterable(n)?pm({body:n,client:t,request:r,contentLength:m,expectsPayload:g,header:"",h2stream:d,socket:t[_t]}):ee(!1):r.onRequestSent()}}function yT({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){if(ee(s!==0||r[St]===0,"stream body cannot be pipelined"),r[$i]==="h2"){let m=function(E){n.onBodySent(E)},g=TZ(e,t,E=>{E?(Ae.destroy(e,E),Ae.destroy(t,E)):n.onRequestSent()});g.on("data",m),g.once("end",()=>{g.removeListener("data",m),Ae.destroy(g)});return}let A=!1,c=new ym({socket:i,request:n,contentLength:s,client:r,expectsPayload:a,header:o}),l=function(g){if(!A)try{!c.write(g)&&this.pause&&this.pause()}catch(m){Ae.destroy(this,m)}},u=function(){A||e.resume&&e.resume()},d=function(){if(A)return;let g=new MQ;queueMicrotask(()=>f(g))},f=function(g){if(!A){if(A=!0,ee(i.destroyed||i[ks]&&r[St]<=1),i.off("drain",u).off("error",f),e.removeListener("data",l).removeListener("end",f).removeListener("error",f).removeListener("close",d),!g)try{c.end()}catch(m){g=m}c.destroy(g),g&&(g.code!=="UND_ERR_INFO"||g.message!=="reset")?Ae.destroy(e,g):Ae.destroy(e)}};e.on("data",l).on("end",f).on("error",f).on("close",d),e.resume&&e.resume(),i.on("drain",u).on("error",f)}async function ET({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){ee(s===e.size,"blob body must have content length");let A=r[$i]==="h2";try{if(s!=null&&s!==e.size)throw new _s;let c=Buffer.from(await e.arrayBuffer());A?(t.cork(),t.write(c),t.uncork()):(i.cork(),i.write(`${o}content-length: ${s}\r `,"latin1"),f.write(r),f.uncork(),e.onBodySent(r),e.onRequestSent(),l||(f[Wr]=!0)):le.isBlobLike(r)?typeof r.stream=="function"?Lm({body:r.stream(),client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):yO({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):le.isStream(r)?pO({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):le.isIterable(r)?Lm({body:r,client:t,request:e,socket:f,contentLength:d,header:g,expectsPayload:l}):re(!1),!0}function Ate(t,e,r){let{body:n,method:i,path:s,host:o,upgrade:a,expectContinue:A,signal:c,headers:l}=r,u;if(typeof l=="string"?u=sb[jee](l.trim()):u=l,a)return $r(t,r,new Error("Upgrade not supported for H2")),!1;try{r.onConnect(I=>{r.aborted||r.completed||$r(t,r,I||new fb)})}catch(I){$r(t,r,I)}if(r.aborted)return!1;let d,f=t[Tm];if(u[Gee]=o||t[uO],u[Yee]=i,i==="CONNECT")return e.ref(),d=e.request(u,{endStream:!1,signal:c}),d.id&&!d.pending?(r.onUpgrade(null,null,d),++f.openStreams):d.once("ready",()=>{r.onUpgrade(null,null,d),++f.openStreams}),d.once("close",()=>{f.openStreams-=1,f.openStreams===0&&e.unref()}),!0;u[Jee]=s,u[Vee]="https";let g=i==="PUT"||i==="POST"||i==="PATCH";n&&typeof n.read=="function"&&n.read(0);let m=le.bodyLength(n);if(m==null&&(m=r.contentLength),(m===0||!g)&&(m=null),mO(i)&&m>0&&r.contentLength!=null&&r.contentLength!==m){if(t[Gd])return $r(t,r,new js),!1;process.emitWarning(new js)}m!=null&&(re(n,"no body must not have content length"),u[Wee]=`${m}`),e.ref();let E=i==="GET"||i==="HEAD";return A?(u[$ee]="100-continue",d=e.request(u,{endStream:E,signal:c}),d.once("continue",C)):(d=e.request(u,{endStream:E,signal:c}),C()),++f.openStreams,d.once("response",I=>{let{[Kee]:b,...w}=I;r.onHeaders(Number(b),w,d.resume.bind(d),"")===!1&&d.pause()}),d.once("end",()=>{r.onComplete([])}),d.on("data",I=>{r.onData(I)===!1&&d.pause()}),d.once("close",()=>{f.openStreams-=1,f.openStreams===0&&e.unref()}),d.once("error",function(I){t[On]&&!t[On].destroyed&&!this.closed&&!this.destroyed&&(f.streams-=1,le.destroy(d,I))}),d.once("frameError",(I,b)=>{let w=new is(`HTTP/2: "frameError" received - type ${I}, code ${b}`);$r(t,r,w),t[On]&&!t[On].destroyed&&!this.closed&&!this.destroyed&&(f.streams-=1,le.destroy(d,w))}),!0;function C(){n?le.isBuffer(n)?(re(m===n.byteLength,"buffer body must have content length"),d.cork(),d.write(n),d.uncork(),d.end(),r.onBodySent(n),r.onRequestSent()):le.isBlobLike(n)?typeof n.stream=="function"?Lm({client:t,request:r,contentLength:m,h2stream:d,expectsPayload:g,body:n.stream(),socket:t[Ot],header:""}):yO({body:n,client:t,request:r,contentLength:m,expectsPayload:g,h2stream:d,header:"",socket:t[Ot]}):le.isStream(n)?pO({body:n,client:t,request:r,contentLength:m,expectsPayload:g,socket:t[Ot],h2stream:d,header:""}):le.isIterable(n)?Lm({body:n,client:t,request:r,contentLength:m,expectsPayload:g,header:"",h2stream:d,socket:t[Ot]}):re(!1):r.onRequestSent()}}function pO({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){if(re(s!==0||r[_t]===0,"stream body cannot be pipelined"),r[os]==="h2"){let m=function(E){n.onBodySent(E)},g=Nee(e,t,E=>{E?(le.destroy(e,E),le.destroy(t,E)):n.onRequestSent()});g.on("data",m),g.once("end",()=>{g.removeListener("data",m),le.destroy(g)});return}let A=!1,c=new Mm({socket:i,request:n,contentLength:s,client:r,expectsPayload:a,header:o}),l=function(g){if(!A)try{!c.write(g)&&this.pause&&this.pause()}catch(m){le.destroy(this,m)}},u=function(){A||e.resume&&e.resume()},d=function(){if(A)return;let g=new fb;queueMicrotask(()=>f(g))},f=function(g){if(!A){if(A=!0,re(i.destroyed||i[zs]&&r[_t]<=1),i.off("drain",u).off("error",f),e.removeListener("data",l).removeListener("end",f).removeListener("error",f).removeListener("close",d),!g)try{c.end()}catch(m){g=m}c.destroy(g),g&&(g.code!=="UND_ERR_INFO"||g.message!=="reset")?le.destroy(e,g):le.destroy(e)}};e.on("data",l).on("end",f).on("error",f).on("close",d),e.resume&&e.resume(),i.on("drain",u).on("error",f)}async function yO({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){re(s===e.size,"blob body must have content length");let A=r[os]==="h2";try{if(s!=null&&s!==e.size)throw new js;let c=Buffer.from(await e.arrayBuffer());A?(t.cork(),t.write(c),t.uncork()):(i.cork(),i.write(`${o}content-length: ${s}\r
\r \r
`,"latin1"),i.write(c),i.uncork()),n.onBodySent(c),n.onRequestSent(),a||(i[Hr]=!0),vn(r)}catch(c){Ae.destroy(A?t:i,c)}}async function pm({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){ee(s!==0||r[St]===0,"iterator body cannot be pipelined");let A=null;function c(){if(A){let d=A;A=null,d()}}let l=()=>new Promise((d,f)=>{ee(A===null),i[Qr]?f(i[Qr]):A=d});if(r[$i]==="h2"){t.on("close",c).on("drain",c);try{for await(let d of e){if(i[Qr])throw i[Qr];let f=t.write(d);n.onBodySent(d),f||await l()}}catch(d){t.destroy(d)}finally{n.onRequestSent(),t.end(),t.off("close",c).off("drain",c)}return}i.on("close",c).on("drain",c);let u=new ym({socket:i,request:n,contentLength:s,client:r,expectsPayload:a,header:o});try{for await(let d of e){if(i[Qr])throw i[Qr];u.write(d)||await l()}u.end()}catch(d){u.destroy(d)}finally{i.off("close",c).off("drain",c)}}var ym=class{constructor({socket:e,request:r,contentLength:n,client:i,expectsPayload:s,header:o}){this.socket=e,this.request=r,this.contentLength=n,this.client=i,this.bytesWritten=0,this.expectsPayload=s,this.header=o,e[ks]=!0}write(e){let{socket:r,request:n,contentLength:i,client:s,bytesWritten:o,expectsPayload:a,header:A}=this;if(r[Qr])throw r[Qr];if(r.destroyed)return!1;let c=Buffer.byteLength(e);if(!c)return!0;if(i!==null&&o+c>i){if(s[Rd])throw new _s;process.emitWarning(new _s)}r.cork(),o===0&&(a||(r[Hr]=!0),i===null?r.write(`${A}transfer-encoding: chunked\r `,"latin1"),i.write(c),i.uncork()),n.onBodySent(c),n.onRequestSent(),a||(i[Wr]=!0),Ln(r)}catch(c){le.destroy(A?t:i,c)}}async function Lm({h2stream:t,body:e,client:r,request:n,socket:i,contentLength:s,header:o,expectsPayload:a}){re(s!==0||r[_t]===0,"iterator body cannot be pipelined");let A=null;function c(){if(A){let d=A;A=null,d()}}let l=()=>new Promise((d,f)=>{re(A===null),i[Rr]?f(i[Rr]):A=d});if(r[os]==="h2"){t.on("close",c).on("drain",c);try{for await(let d of e){if(i[Rr])throw i[Rr];let f=t.write(d);n.onBodySent(d),f||await l()}}catch(d){t.destroy(d)}finally{n.onRequestSent(),t.end(),t.off("close",c).off("drain",c)}return}i.on("close",c).on("drain",c);let u=new Mm({socket:i,request:n,contentLength:s,client:r,expectsPayload:a,header:o});try{for await(let d of e){if(i[Rr])throw i[Rr];u.write(d)||await l()}u.end()}catch(d){u.destroy(d)}finally{i.off("close",c).off("drain",c)}}var Mm=class{constructor({socket:e,request:r,contentLength:n,client:i,expectsPayload:s,header:o}){this.socket=e,this.request=r,this.contentLength=n,this.client=i,this.bytesWritten=0,this.expectsPayload=s,this.header=o,e[zs]=!0}write(e){let{socket:r,request:n,contentLength:i,client:s,bytesWritten:o,expectsPayload:a,header:A}=this;if(r[Rr])throw r[Rr];if(r.destroyed)return!1;let c=Buffer.byteLength(e);if(!c)return!0;if(i!==null&&o+c>i){if(s[Gd])throw new js;process.emitWarning(new js)}r.cork(),o===0&&(a||(r[Wr]=!0),i===null?r.write(`${A}transfer-encoding: chunked\r
`,"latin1"):r.write(`${A}content-length: ${i}\r `,"latin1"):r.write(`${A}content-length: ${i}\r
\r \r
`,"latin1")),i===null&&r.write(`\r `,"latin1")),i===null&&r.write(`\r
${c.toString(16)}\r ${c.toString(16)}\r
`,"latin1"),this.bytesWritten+=c;let l=r.write(e);return r.uncork(),n.onBodySent(e),l||r[Dt].timeout&&r[Dt].timeoutType===lc&&r[Dt].timeout.refresh&&r[Dt].timeout.refresh(),l}end(){let{socket:e,contentLength:r,client:n,bytesWritten:i,expectsPayload:s,header:o,request:a}=this;if(a.onRequestSent(),e[ks]=!1,e[Qr])throw e[Qr];if(!e.destroyed){if(i===0?s?e.write(`${o}content-length: 0\r `,"latin1"),this.bytesWritten+=c;let l=r.write(e);return r.uncork(),n.onBodySent(e),l||r[Tt].timeout&&r[Tt].timeoutType===Qc&&r[Tt].timeout.refresh&&r[Tt].timeout.refresh(),l}end(){let{socket:e,contentLength:r,client:n,bytesWritten:i,expectsPayload:s,header:o,request:a}=this;if(a.onRequestSent(),e[zs]=!1,e[Rr])throw e[Rr];if(!e.destroyed){if(i===0?s?e.write(`${o}content-length: 0\r
\r \r
`,"latin1"):e.write(`${o}\r `,"latin1"):e.write(`${o}\r
`,"latin1"):r===null&&e.write(`\r `,"latin1"):r===null&&e.write(`\r
0\r 0\r
\r \r
`,"latin1"),r!==null&&i!==r){if(n[Rd])throw new _s;process.emitWarning(new _s)}e[Dt].timeout&&e[Dt].timeoutType===lc&&e[Dt].timeout.refresh&&e[Dt].timeout.refresh(),vn(n)}}destroy(e){let{socket:r,client:n}=this;r[ks]=!1,e&&(ee(n[St]<=1,"pipeline should only contain this request"),Ae.destroy(r,e))}};function zr(t,e,r){try{e.onError(r),ee(e.aborted)}catch(n){t.emit("error",n)}}CT.exports=_Q});var BT=h((K_e,IT)=>{"use strict";var Cm=class{constructor(){this.bottom=0,this.top=0,this.list=new Array(2048),this.next=null}isEmpty(){return this.top===this.bottom}isFull(){return(this.top+1&2047)===this.bottom}push(e){this.list[this.top]=e,this.top=this.top+1&2047}shift(){let e=this.list[this.bottom];return e===void 0?null:(this.list[this.bottom]=void 0,this.bottom=this.bottom+1&2047,e)}};IT.exports=class{constructor(){this.head=this.tail=new Cm}isEmpty(){return this.head.isEmpty()}push(e){this.head.isFull()&&(this.head=this.head.next=new Cm),this.head.push(e)}shift(){let e=this.tail,r=e.shift();return e.isEmpty()&&e.next!==null&&(this.tail=e.next),r}}});var bT=h((X_e,QT)=>{var{kFree:E6,kConnected:C6,kPending:I6,kQueued:B6,kRunning:Q6,kSize:b6}=yt(),wa=Symbol("pool"),LQ=class{constructor(e){this[wa]=e}get connected(){return this[wa][C6]}get free(){return this[wa][E6]}get pending(){return this[wa][I6]}get queued(){return this[wa][B6]}get running(){return this[wa][Q6]}get size(){return this[wa][b6]}};QT.exports=LQ});var jQ=h((Z_e,PT)=>{"use strict";var N6=Qd(),w6=BT(),{kConnected:FQ,kSize:NT,kRunning:wT,kPending:xT,kQueued:kd,kBusy:x6,kFree:S6,kUrl:v6,kClose:R6,kDestroy:D6,kDispatch:_6}=yt(),k6=bT(),Zr=Symbol("clients"),jr=Symbol("needDrain"),Pd=Symbol("queue"),UQ=Symbol("closed resolve"),qQ=Symbol("onDrain"),ST=Symbol("onConnect"),vT=Symbol("onDisconnect"),RT=Symbol("onConnectionError"),HQ=Symbol("get dispatcher"),_T=Symbol("add client"),kT=Symbol("remove client"),DT=Symbol("stats"),zQ=class extends N6{constructor(){super(),this[Pd]=new w6,this[Zr]=[],this[kd]=0;let e=this;this[qQ]=function(n,i){let s=e[Pd],o=!1;for(;!o;){let a=s.shift();if(!a)break;e[kd]--,o=!this.dispatch(a.opts,a.handler)}this[jr]=o,!this[jr]&&e[jr]&&(e[jr]=!1,e.emit("drain",n,[e,...i])),e[UQ]&&s.isEmpty()&&Promise.all(e[Zr].map(a=>a.close())).then(e[UQ])},this[ST]=(r,n)=>{e.emit("connect",r,[e,...n])},this[vT]=(r,n,i)=>{e.emit("disconnect",r,[e,...n],i)},this[RT]=(r,n,i)=>{e.emit("connectionError",r,[e,...n],i)},this[DT]=new k6(this)}get[x6](){return this[jr]}get[FQ](){return this[Zr].filter(e=>e[FQ]).length}get[S6](){return this[Zr].filter(e=>e[FQ]&&!e[jr]).length}get[xT](){let e=this[kd];for(let{[xT]:r}of this[Zr])e+=r;return e}get[wT](){let e=0;for(let{[wT]:r}of this[Zr])e+=r;return e}get[NT](){let e=this[kd];for(let{[NT]:r}of this[Zr])e+=r;return e}get stats(){return this[DT]}async[R6](){return this[Pd].isEmpty()?Promise.all(this[Zr].map(e=>e.close())):new Promise(e=>{this[UQ]=e})}async[D6](e){for(;;){let r=this[Pd].shift();if(!r)break;r.handler.onError(e)}return Promise.all(this[Zr].map(r=>r.destroy(e)))}[_6](e,r){let n=this[HQ]();return n?n.dispatch(e,r)||(n[jr]=!0,this[jr]=!this[HQ]()):(this[jr]=!0,this[Pd].push({opts:e,handler:r}),this[kd]++),!this[jr]}[_T](e){return e.on("drain",this[qQ]).on("connect",this[ST]).on("disconnect",this[vT]).on("connectionError",this[RT]),this[Zr].push(e),this[jr]&&process.nextTick(()=>{this[jr]&&this[qQ](e[v6],[this,e])}),this}[kT](e){e.close(()=>{let r=this[Zr].indexOf(e);r!==-1&&this[Zr].splice(r,1)}),this[jr]=this[Zr].some(r=>!r[jr]&&r.closed!==!0&&r.destroyed!==!0)}};PT.exports={PoolBase:zQ,kClients:Zr,kNeedDrain:jr,kAddClient:_T,kRemoveClient:kT,kGetDispatcher:HQ}});var uc=h((eke,MT)=>{"use strict";var{PoolBase:P6,kClients:Im,kNeedDrain:T6,kAddClient:O6,kGetDispatcher:M6}=jQ(),L6=_d(),{InvalidArgumentError:GQ}=at(),YQ=Fe(),{kUrl:TT,kInterceptors:F6}=yt(),U6=bd(),JQ=Symbol("options"),VQ=Symbol("connections"),OT=Symbol("factory");function q6(t,e){return new L6(t,e)}var WQ=class extends P6{constructor(e,{connections:r,factory:n=q6,connect:i,connectTimeout:s,tls:o,maxCachedSessions:a,socketPath:A,autoSelectFamily:c,autoSelectFamilyAttemptTimeout:l,allowH2:u,...d}={}){if(super(),r!=null&&(!Number.isFinite(r)||r<0))throw new GQ("invalid connections");if(typeof n!="function")throw new GQ("factory must be a function.");if(i!=null&&typeof i!="function"&&typeof i!="object")throw new GQ("connect must be a function or an object");typeof i!="function"&&(i=U6({...o,maxCachedSessions:a,allowH2:u,socketPath:A,timeout:s,...YQ.nodeHasAutoSelectFamily&&c?{autoSelectFamily:c,autoSelectFamilyAttemptTimeout:l}:void 0,...i})),this[F6]=d.interceptors&&d.interceptors.Pool&&Array.isArray(d.interceptors.Pool)?d.interceptors.Pool:[],this[VQ]=r||null,this[TT]=YQ.parseOrigin(e),this[JQ]={...YQ.deepClone(d),connect:i,allowH2:u},this[JQ].interceptors=d.interceptors?{...d.interceptors}:void 0,this[OT]=n,this.on("connectionError",(f,g,m)=>{for(let E of g){let C=this[Im].indexOf(E);C!==-1&&this[Im].splice(C,1)}})}[M6](){let e=this[Im].fin Line truncated `,"latin1"),r!==null&&i!==r){if(n[Gd])throw new js;process.emitWarning(new js)}e[Tt].timeout&&e[Tt].timeoutType===Qc&&e[Tt].timeout.refresh&&e[Tt].timeout.refresh(),Ln(n)}}destroy(e){let{socket:r,client:n}=this;r[zs]=!1,e&&(re(n[_t]<=1,"pipeline should only contain this request"),le.destroy(r,e))}};function $r(t,e,r){try{e.onError(r),re(e.aborted)}catch(n){t.emit("error",n)}}EO.exports=Ab});var IO=h((KMe,CO)=>{"use strict";var Um=class{constructor(){this.bottom=0,this.top=0,this.list=new Array(2048),this.next=null}isEmpty(){return this.top===this.bottom}isFull(){return(this.top+1&2047)===this.bottom}push(e){this.list[this.top]=e,this.top=this.top+1&2047}shift(){let e=this.list[this.bottom];return e===void 0?null:(this.list[this.bottom]=void 0,this.bottom=this.bottom+1&2047,e)}};CO.exports=class{constructor(){this.head=this.tail=new Um}isEmpty(){return this.head.isEmpty()}push(e){this.head.isFull()&&(this.head=this.head.next=new Um),this.head.push(e)}shift(){let e=this.tail,r=e.shift();return e.isEmpty()&&e.next!==null&&(this.tail=e.next),r}}});var QO=h((XMe,BO)=>{var{kFree:cte,kConnected:lte,kPending:ute,kQueued:dte,kRunning:fte,kSize:hte}=Ct(),Ua=Symbol("pool"),hb=class{constructor(e){this[Ua]=e}get connected(){return this[Ua][lte]}get free(){return this[Ua][cte]}get pending(){return this[Ua][ute]}get queued(){return this[Ua][dte]}get running(){return this[Ua][fte]}get size(){return this[Ua][hte]}};BO.exports=hb});var Cb=h((ZMe,kO)=>{"use strict";var gte=Md(),mte=IO(),{kConnected:gb,kSize:bO,kRunning:NO,kPending:wO,kQueued:Vd,kBusy:pte,kFree:yte,kUrl:Ete,kClose:Cte,kDestroy:Ite,kDispatch:Bte}=Ct(),Qte=QO(),An=Symbol("clients"),Kr=Symbol("needDrain"),Wd=Symbol("queue"),mb=Symbol("closed resolve"),pb=Symbol("onDrain"),xO=Symbol("onConnect"),SO=Symbol("onDisconnect"),RO=Symbol("onConnectionError"),yb=Symbol("get dispatcher"),DO=Symbol("add client"),_O=Symbol("remove client"),vO=Symbol("stats"),Eb=class extends gte{constructor(){super(),this[Wd]=new mte,this[An]=[],this[Vd]=0;let e=this;this[pb]=function(n,i){let s=e[Wd],o=!1;for(;!o;){let a=s.shift();if(!a)break;e[Vd]--,o=!this.dispatch(a.opts,a.handler)}this[Kr]=o,!this[Kr]&&e[Kr]&&(e[Kr]=!1,e.emit("drain",n,[e,...i])),e[mb]&&s.isEmpty()&&Promise.all(e[An].map(a=>a.close())).then(e[mb])},this[xO]=(r,n)=>{e.emit("connect",r,[e,...n])},this[SO]=(r,n,i)=>{e.emit("disconnect",r,[e,...n],i)},this[RO]=(r,n,i)=>{e.emit("connectionError",r,[e,...n],i)},this[vO]=new Qte(this)}get[pte](){return this[Kr]}get[gb](){return this[An].filter(e=>e[gb]).length}get[yte](){return this[An].filter(e=>e[gb]&&!e[Kr]).length}get[wO](){let e=this[Vd];for(let{[wO]:r}of this[An])e+=r;return e}get[NO](){let e=0;for(let{[NO]:r}of this[An])e+=r;return e}get[bO](){let e=this[Vd];for(let{[bO]:r}of this[An])e+=r;return e}get stats(){return this[vO]}async[Cte](){return this[Wd].isEmpty()?Promise.all(this[An].map(e=>e.close())):new Promise(e=>{this[mb]=e})}async[Ite](e){for(;;){let r=this[Wd].shift();if(!r)break;r.handler.onError(e)}return Promise.all(this[An].map(r=>r.destroy(e)))}[Bte](e,r){let n=this[yb]();return n?n.dispatch(e,r)||(n[Kr]=!0,this[Kr]=!this[yb]()):(this[Kr]=!0,this[Wd].push({opts:e,handler:r}),this[Vd]++),!this[Kr]}[DO](e){return e.on("drain",this[pb]).on("connect",this[xO]).on("disconnect",this[SO]).on("connectionError",this[RO]),this[An].push(e),this[Kr]&&process.nextTick(()=>{this[Kr]&&this[pb](e[Ete],[this,e])}),this}[_O](e){e.close(()=>{let r=this[An].indexOf(e);r!==-1&&this[An].splice(r,1)}),this[Kr]=this[An].some(r=>!r[Kr]&&r.closed!==!0&&r.destroyed!==!0)}};kO.exports={PoolBase:Eb,kClients:An,kNeedDrain:Kr,kAddClient:DO,kRemoveClient:_O,kGetDispatcher:yb}});var bc=h((eFe,OO)=>{"use strict";var{PoolBase:bte,kClients:qm,kNeedDrain:Nte,kAddClient:wte,kGetDispatcher:xte}=Cb(),Ste=Jd(),{InvalidArgumentError:Ib}=lt(),Bb=He(),{kUrl:PO,kInterceptors:Rte}=Ct(),vte=Fd(),Qb=Symbol("options"),bb=Symbol("connections"),TO=Symbol("factory");function Dte(t,e){return new Ste(t,e)}var Nb=class extends bte{constructor(e,{connections:r,factory:n=Dte,connect:i,connectTimeout:s,tls:o,maxCachedSessions:a,socketPath:A,autoSelectFamily:c,autoSelectFamilyAttemptTimeout:l,allowH2:u,...d}={}){if(super(),r!=null&&(!Number.isFinite(r)||r<0))throw new Ib("invalid connections");if(typeof n!="function")throw new Ib("factory must be a function.");if(i!=null&&typeof i!="function"&&typeof i!="object")throw new Ib("connect must be a function or an object");typeof i!="function"&&(i=vte({...o,maxCachedSessions:a,allowH2:u,socketPath:A,timeout:s,...Bb.nodeHasAutoSelectFamily&&c?{autoSelectFamily:c,autoSelectFamilyAttemptTimeout:l}:void 0,...i})),this[Rte]=d.interceptors&&d.interceptors.Pool&&Array.isArray(d.interceptors.Pool)?d.interceptors.Pool:[],this[bb]=r||null,this[PO]=Bb.parseOrigin(e),this[Qb]={...Bb.deepClone(d),connect:i,allowH2:u},this[Qb].interceptors=d.interceptors?{...d.interceptors}:void 0,this[TO]=n,this.on("connectionError",(f,g,m)=>{for(let E of g){let C=this[qm].indexOf(E);C!==-1&&this[q Line truncated
${n.count} ${n.noun} ${n.is} pending: ${n.count} ${n.noun} ${n.is} pending:
${e.format(r)} ${e.format(r)}
`.trim())}};gM.exports=kb});var BM=h((Nke,IM)=>{"use strict";var{kProxy:Hee,kClose:zee,kDestroy:jee,kInterceptors:Gee}=yt(),{URL:pM}=require("url"),yM=Od(),Yee=uc(),Jee=Qd(),{InvalidArgumentError:qd,RequestAbortedError:Vee}=at(),EM=bd(),Fd=Symbol("proxy agent"),Hm=Symbol("proxy client"),Ud=Symbol("proxy headers"),Pb=Symbol("request tls settings"),Wee=Symbol("proxy tls settings"),CM=Symbol("connect endpoint function");function $ee(t){return t==="https:"?443:80}function Kee(t){if(typeof t=="string"&&(t={uri:t}),!t||!t.uri)throw new qd("Proxy opts.uri is mandatory");return{uri:t.uri,protocol:t.protocol||"https"}}function Xee(t,e){return new Yee(t,e)}var Tb=class extends Jee{constructor(e){if(super(e),this[Hee]=Kee(e),this[Fd]=new yM(e),this[Gee]=e.interceptors&&e.interceptors.ProxyAgent&&Array.isArray(e.interceptors.ProxyAgent)?e.interceptors.ProxyAgent:[],typeof e=="string"&&(e={uri:e}),!e||!e.uri)throw new qd("Proxy opts.uri is mandatory");let{clientFactory:r=Xee}=e;if(typeof r!="function")throw new qd("Proxy opts.clientFactory must be a function.");this[Pb]=e.requestTls,this[Wee]=e.proxyTls,this[Ud]=e.headers||{};let n=new pM(e.uri),{origin:i,port:s,host:o,username:a,password:A}=n;if(e.auth&&e.token)throw new qd("opts.auth cannot be used in combination with opts.token");e.auth?this[Ud]["proxy-authorization"]=`Basic ${e.auth}`:e.token?this[Ud]["proxy-authorization"]=e.token:a&&A&&(this[Ud]["proxy-authorization"]=`Basic ${Buffer.from(`${decodeURIComponent(a)}:${decodeURIComponent(A)}`).toString("base64")}`);let c=EM({...e.proxyTls});this[CM]=EM({...e.requestTls}),this[Hm]=r(n,{connect:c}),this[Fd]=new yM({...e,connect:async(l,u)=>{let d=l.host;l.port||(d+=`:${$ee(l.protocol)}`);try{let{socket:f,statusCode:g}=await this[Hm].connect({origin:i,port:s,path:d,signal:l.signal,headers:{...this[Ud],host:o}});if(g!==200&&(f.on("error",()=>{}).destroy(),u(new Vee(`Proxy response (${g}) !== 200 when HTTP Tunneling`))),l.protocol!=="https:"){u(null,f);return}let m;this[Pb]?m=this[Pb].servername:m=l.servername,this[CM]({...l,servername:m,httpSocket:f},u)}catch(f){u(f)}}})}dispatch(e,r){let{host:n}=new pM(e.origin),i=Zee(e.headers);return ete(i),this[Fd].dispatch({...e,headers:{...i,host:n}},r)}async[zee](){await this[Fd].close(),await this[Hm].close()}async[jee](){await this[Fd].destroy(),await this[Hm].destroy()}};function Zee(t){if(Array.isArray(t)){let e={};for(let r=0;r<t.length;r+=2)e[t[r]]=t[r+1];return e}return t}function ete(t){if(t&&Object.keys(t).find(r=>r.toLowerCase()==="proxy-authorization"))throw new qd("Proxy-Authorization should be sent in ProxyAgent constructor")}IM.exports=Tb});var xM=h((wke,wM)=>{var _a=require("assert"),{kRetryHandlerDefaultRetry:QM}=yt(),{RequestRetryError:zm}=at(),{isDisturbed:bM,parseHeaders:tte,parseRangeHeader:NM}=Fe();function rte(t){let e=Date.now();return new Date(t).getTime()-e}var Ob=class t{constructor(e,r){let{retryOptions:n,...i}=e,{retry:s,maxRetries:o,maxTimeout:a,minTimeout:A,timeoutFactor:c,methods:l,errorCodes:u,retryAfter:d,statusCodes:f}=n??{};this.dispatch=r.dispatch,this.handler=r.handler,this.opts=i,this.abort=null,this.aborted=!1,this.retryOpts={retry:s??t[QM],retryAfter:d??!0,maxTimeout:a??30*1e3,timeout:A??500,timeoutFactor:c??2,maxRetries:o??5,methods:l??["GET","HEAD","OPTIONS","PUT","DELETE","TRACE"],statusCodes:f??[500,502,503,504,429],errorCodes:u??["ECONNRESET","ECONNREFUSED","ENOTFOUND","ENETDOWN","ENETUNREACH","EHOSTDOWN","EHOSTUNREACH","EPIPE"]},this.retryCount=0,this.start=0,this.end=null,this.etag=null,this.resume=null,this.handler.onConnect(g=>{this.aborted=!0,this.abort?this.abort(g):this.reason=g})}onRequestSent(){this.handler.onRequestSent&&this.handler.onRequestSent()}onUpgrade(e,r,n){this.handler.onUpgrade&&this.handler.onUpgrade(e,r,n)}onConnect(e){this.aborted?e(this.reason):this.abort=e}onBodySent(e){if(this.handler.onBodySent)return this.handler.onBodySent(e)}static[QM](e,{state:r,opts:n},i){let{statusCode:s,code:o,headers:a}=e,{method:A,retryOptions:c}=n,{maxRetries:l,timeout:u,maxTimeout:d,timeoutFactor:f,statusCodes:g,errorCodes:m,methods:E}=c,{counter:C,currentTimeout:I}=r;if(I=I!=null&&I>0?I:u,o&&o!=="UND_ERR_REQ_RETRY"&&o!=="UND_ERR_SOCKET"&&!m.includes(o)){i(e);return}if(Array.isArray(E)&&!E.includes(A)){i(e);return}if(s!=null&&Array.isArray(g)&&!g.includes(s)){i(e);return}if(C>l){i(e);return}let N=a!=null&&a["retry-after"];N&&(N=Number(N),N=isNaN(N)?rte(N):N*1e3);let w=N>0?Math.min(N,d):Math.min(I*f**C,d);r.currentTimeout=w,setTimeout(()=>i(null),w)}onHeaders(e,r,n,i){let s=tte(r);if(this.retryCount+=1,e>=300)return this.abort(new zm("Request failed",e,{headers:s,count:this.retryCount})),!1;if(this.resume!=null){if(this.resume=null,e!==206)return!0;let a=NM(s["content-range"]);if(!a)return this.abort(new zm("Content-Range mismatch",e,{headers:s,count:this.retryCount})),!1;if(this.etag!=null&&this.etag!==s.etag)return this.abort(new zm("ETag mismatch",e,{headers:s,count:this.retryCount})),!1;let{start:A,size:c,end:l=c}=a;return _a(t Line truncated `.trim())}};hM.exports=c0});var IM=h((NFe,CM)=>{"use strict";var{kProxy:_ne,kClose:kne,kDestroy:Pne,kInterceptors:Tne}=Ct(),{URL:mM}=require("url"),pM=Kd(),One=bc(),Lne=Md(),{InvalidArgumentError:rf,RequestAbortedError:Mne}=lt(),yM=Fd(),ef=Symbol("proxy agent"),Ap=Symbol("proxy client"),tf=Symbol("proxy headers"),l0=Symbol("request tls settings"),Fne=Symbol("proxy tls settings"),EM=Symbol("connect endpoint function");function Une(t){return t==="https:"?443:80}function qne(t){if(typeof t=="string"&&(t={uri:t}),!t||!t.uri)throw new rf("Proxy opts.uri is mandatory");return{uri:t.uri,protocol:t.protocol||"https"}}function Hne(t,e){return new One(t,e)}var u0=class extends Lne{constructor(e){if(super(e),this[_ne]=qne(e),this[ef]=new pM(e),this[Tne]=e.interceptors&&e.interceptors.ProxyAgent&&Array.isArray(e.interceptors.ProxyAgent)?e.interceptors.ProxyAgent:[],typeof e=="string"&&(e={uri:e}),!e||!e.uri)throw new rf("Proxy opts.uri is mandatory");let{clientFactory:r=Hne}=e;if(typeof r!="function")throw new rf("Proxy opts.clientFactory must be a function.");this[l0]=e.requestTls,this[Fne]=e.proxyTls,this[tf]=e.headers||{};let n=new mM(e.uri),{origin:i,port:s,host:o,username:a,password:A}=n;if(e.auth&&e.token)throw new rf("opts.auth cannot be used in combination with opts.token");e.auth?this[tf]["proxy-authorization"]=`Basic ${e.auth}`:e.token?this[tf]["proxy-authorization"]=e.token:a&&A&&(this[tf]["proxy-authorization"]=`Basic ${Buffer.from(`${decodeURIComponent(a)}:${decodeURIComponent(A)}`).toString("base64")}`);let c=yM({...e.proxyTls});this[EM]=yM({...e.requestTls}),this[Ap]=r(n,{connect:c}),this[ef]=new pM({...e,connect:async(l,u)=>{let d=l.host;l.port||(d+=`:${Une(l.protocol)}`);try{let{socket:f,statusCode:g}=await this[Ap].connect({origin:i,port:s,path:d,signal:l.signal,headers:{...this[tf],host:o}});if(g!==200&&(f.on("error",()=>{}).destroy(),u(new Mne(`Proxy response (${g}) !== 200 when HTTP Tunneling`))),l.protocol!=="https:"){u(null,f);return}let m;this[l0]?m=this[l0].servername:m=l.servername,this[EM]({...l,servername:m,httpSocket:f},u)}catch(f){u(f)}}})}dispatch(e,r){let{host:n}=new mM(e.origin),i=jne(e.headers);return zne(i),this[ef].dispatch({...e,headers:{...i,host:n}},r)}async[kne](){await this[ef].close(),await this[Ap].close()}async[Pne](){await this[ef].destroy(),await this[Ap].destroy()}};function jne(t){if(Array.isArray(t)){let e={};for(let r=0;r<t.length;r+=2)e[t[r]]=t[r+1];return e}return t}function zne(t){if(t&&Object.keys(t).find(r=>r.toLowerCase()==="proxy-authorization"))throw new rf("Proxy-Authorization should be sent in ProxyAgent constructor")}CM.exports=u0});var wM=h((wFe,NM)=>{var Ya=require("assert"),{kRetryHandlerDefaultRetry:BM}=Ct(),{RequestRetryError:cp}=lt(),{isDisturbed:QM,parseHeaders:Gne,parseRangeHeader:bM}=He();function Yne(t){let e=Date.now();return new Date(t).getTime()-e}var d0=class t{constructor(e,r){let{retryOptions:n,...i}=e,{retry:s,maxRetries:o,maxTimeout:a,minTimeout:A,timeoutFactor:c,methods:l,errorCodes:u,retryAfter:d,statusCodes:f}=n??{};this.dispatch=r.dispatch,this.handler=r.handler,this.opts=i,this.abort=null,this.aborted=!1,this.retryOpts={retry:s??t[BM],retryAfter:d??!0,maxTimeout:a??30*1e3,timeout:A??500,timeoutFactor:c??2,maxRetries:o??5,methods:l??["GET","HEAD","OPTIONS","PUT","DELETE","TRACE"],statusCodes:f??[500,502,503,504,429],errorCodes:u??["ECONNRESET","ECONNREFUSED","ENOTFOUND","ENETDOWN","ENETUNREACH","EHOSTDOWN","EHOSTUNREACH","EPIPE"]},this.retryCount=0,this.start=0,this.end=null,this.etag=null,this.resume=null,this.handler.onConnect(g=>{this.aborted=!0,this.abort?this.abort(g):this.reason=g})}onRequestSent(){this.handler.onRequestSent&&this.handler.onRequestSent()}onUpgrade(e,r,n){this.handler.onUpgrade&&this.handler.onUpgrade(e,r,n)}onConnect(e){this.aborted?e(this.reason):this.abort=e}onBodySent(e){if(this.handler.onBodySent)return this.handler.onBodySent(e)}static[BM](e,{state:r,opts:n},i){let{statusCode:s,code:o,headers:a}=e,{method:A,retryOptions:c}=n,{maxRetries:l,timeout:u,maxTimeout:d,timeoutFactor:f,statusCodes:g,errorCodes:m,methods:E}=c,{counter:C,currentTimeout:I}=r;if(I=I!=null&&I>0?I:u,o&&o!=="UND_ERR_REQ_RETRY"&&o!=="UND_ERR_SOCKET"&&!m.includes(o)){i(e);return}if(Array.isArray(E)&&!E.includes(A)){i(e);return}if(s!=null&&Array.isArray(g)&&!g.includes(s)){i(e);return}if(C>l){i(e);return}let b=a!=null&&a["retry-after"];b&&(b=Number(b),b=isNaN(b)?Yne(b):b*1e3);let w=b>0?Math.min(b,d):Math.min(I*f**C,d);r.currentTimeout=w,setTimeout(()=>i(null),w)}onHeaders(e,r,n,i){let s=Gne(r);if(this.retryCount+=1,e>=300)return this.abort(new cp("Request failed",e,{headers:s,count:this.retryCount})),!1;if(this.resume!=null){if(this.resume=null,e!==206)return!0;let a=bM(s["content-range"]);if(!a)return this.abort(new cp("Content-Range mismatch",e,{headers:s,count:this.retryCount})),!1;if(this.etag!=null&&this.etag!==s.etag)return this.abort(new cp("ETag mismatch",e,{headers:s,count:this.retryCount})),!1;let{start:A,size:c,end:l=c}=a;return Ya(t Line truncated
Error Code : ${o.statusCode} Error Code : ${o.statusCode}
Error Message: ${o.message}`)})).result)===null||r===void 0?void 0:r.value;if(!s)throw new Error("Response json body do not have ID Token field");return s})}static getIDToken(e){return OF(this,void 0,void 0,function*(){try{let r=t.getIDTokenUrl();if(e){let i=encodeURIComponent(e);r=`${r}&audience=${i}`}(0,MF.debug)(`ID token url is ${r}`);let n=yield t.getCall(r);return(0,MF.setSecret)(n),n}catch(r){throw new Error(`Error message: ${r.message}`)}})}};Oc.OidcClient=N0});var v0=h(sn=>{"use strict";var w0=sn&&sn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(sn,"__esModule",{value:!0});sn.summary=sn.markdownSummary=sn.SUMMARY_DOCS_URL=sn.SUMMARY_ENV_VAR=void 0;var Yie=require("os"),x0=require("fs"),{access:Jie,appendFile:Vie,writeFile:Wie}=x0.promises;sn.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";sn.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";var S0=class{constructor(){this._buffer=""}filePath(){return w0(this,void 0,void 0,function*(){if(this._filePath)return this._filePath;let e=process.env[sn.SUMMARY_ENV_VAR];if(!e)throw new Error(`Unable to find environment variable for $${sn.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`);try{yield Jie(e,x0.constants.R_OK|x0.constants.W_OK)}catch{throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}return this._filePath=e,this._filePath})}wrap(e,r,n={}){let i=Object.entries(n).map(([s,o])=>` ${s}="${o}"`).join("");return r?`<${e}${i}>${r}</${e}>`:`<${e}${i}>`}write(e){return w0(this,void 0,void 0,function*(){let r=!!e?.overwrite,n=yield this.filePath();return yield(r?Wie:Vie)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){return w0(this,void 0,void 0,function*(){return this.emptyBuffer().write({overwrite:!0})})}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){return this._buffer="",this}addRaw(e,r=!1){return this._buffer+=e,r?this.addEOL():this}addEOL(){return this.addRaw(Yie.EOL)}addCodeBlock(e,r){let n=Object.assign({},r&&{lang:r}),i=this.wrap("pre",this.wrap("code",e),n);return this.addRaw(i).addEOL()}addList(e,r=!1){let n=r?"ol":"ul",i=e.map(o=>this.wrap("li",o)).join(""),s=this.wrap(n,i);return this.addRaw(s).addEOL()}addTable(e){let r=e.map(i=>{let s=i.map(o=>{if(typeof o=="string")return this.wrap("td",o);let{header:a,data:A,colspan:c,rowspan:l}=o,u=a?"th":"td",d=Object.assign(Object.assign({},c&&{colspan:c}),l&&{rowspan:l});return this.wrap(u,A,d)}).join("");return this.wrap("tr",s)}).join(""),n=this.wrap("table",r);return this.addRaw(n).addEOL()}addDetails(e,r){let n=this.wrap("details",this.wrap("summary",e)+r);return this.addRaw(n).addEOL()}addImage(e,r,n){let{width:i,height:s}=n||{},o=Object.assign(Object.assign({},i&&{width:i}),s&&{height:s}),a=this.wrap("img",null,Object.assign({src:e,alt:r},o));return this.addRaw(a).addEOL()}addHeading(e,r){let n=`h${r}`,i=["h1","h2","h3","h4","h5","h6"].includes(n)?n:"h1",s=this.wrap(i,e);return this.addRaw(s).addEOL()}addSeparator(){let e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){let e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,r){let n=Object.assign({},r&&{cite:r}),i=this.wrap("blockquote",e,n);return this.addRaw(i).addEOL()}addLink(e,r){let n=this.wrap("a",e,{href:r});return this.addRaw(n).addEOL()}},FF=new S0;sn.markdownSummary=FF;sn.summary=FF});var UF=h(on=>{"use strict";var $ie=on&&on.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Kie=on&&on.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Xie=on&&on.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&$ie(e,t,r);return Kie(e,t),e};Object.defineProperty(on,"__esModule",{value:!0});on.toPlatformPath=on.toWin32Path=on.toPosixPath=void 0;var Zie=Xie(require("path"));function ese(t){return t.replace(/[\\]/g,"/")}on.toPosixPath=ese;function tse(t){return t.replace(/[/]/g,"\\")}on.toWin32Path=tse;function rse(t){return t.replace(/[/\\]/g,Zie.sep)}on.toPlatformPath=rse});var D0=h(re=>{"use strict";var nse=re&&re.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[nLine truncated Error Message: ${o.message}`)})).result)===null||r===void 0?void 0:r.value;if(!s)throw new Error("Response json body do not have ID Token field");return s})}static getIDToken(e){return T1(this,void 0,void 0,function*(){try{let r=t.getIDTokenUrl();if(e){let i=encodeURIComponent(e);r=`${r}&audience=${i}`}(0,O1.debug)(`ID token url is ${r}`);let n=yield t.getCall(r);return(0,O1.setSecret)(n),n}catch(r){throw new Error(`Error message: ${r.message}`)}})}};Wc.OidcClient=tN});var sN=h(fn=>{"use strict";var rN=fn&&fn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(fn,"__esModule",{value:!0});fn.summary=fn.markdownSummary=fn.SUMMARY_DOCS_URL=fn.SUMMARY_ENV_VAR=void 0;var Oae=require("os"),nN=require("fs"),{access:Lae,appendFile:Mae,writeFile:Fae}=nN.promises;fn.SUMMARY_ENV_VAR="GITHUB_STEP_SUMMARY";fn.SUMMARY_DOCS_URL="https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions#adding-a-job-summary";var iN=class{constructor(){this._buffer=""}filePath(){return rN(this,void 0,void 0,function*(){if(this._filePath)return this._filePath;let e=process.env[fn.SUMMARY_ENV_VAR];if(!e)throw new Error(`Unable to find environment variable for $${fn.SUMMARY_ENV_VAR}. Check if your runtime environment supports job summaries.`);try{yield Lae(e,nN.constants.R_OK|nN.constants.W_OK)}catch{throw new Error(`Unable to access summary file: '${e}'. Check if the file has correct read/write permissions.`)}return this._filePath=e,this._filePath})}wrap(e,r,n={}){let i=Object.entries(n).map(([s,o])=>` ${s}="${o}"`).join("");return r?`<${e}${i}>${r}</${e}>`:`<${e}${i}>`}write(e){return rN(this,void 0,void 0,function*(){let r=!!e?.overwrite,n=yield this.filePath();return yield(r?Fae:Mae)(n,this._buffer,{encoding:"utf8"}),this.emptyBuffer()})}clear(){return rN(this,void 0,void 0,function*(){return this.emptyBuffer().write({overwrite:!0})})}stringify(){return this._buffer}isEmptyBuffer(){return this._buffer.length===0}emptyBuffer(){return this._buffer="",this}addRaw(e,r=!1){return this._buffer+=e,r?this.addEOL():this}addEOL(){return this.addRaw(Oae.EOL)}addCodeBlock(e,r){let n=Object.assign({},r&&{lang:r}),i=this.wrap("pre",this.wrap("code",e),n);return this.addRaw(i).addEOL()}addList(e,r=!1){let n=r?"ol":"ul",i=e.map(o=>this.wrap("li",o)).join(""),s=this.wrap(n,i);return this.addRaw(s).addEOL()}addTable(e){let r=e.map(i=>{let s=i.map(o=>{if(typeof o=="string")return this.wrap("td",o);let{header:a,data:A,colspan:c,rowspan:l}=o,u=a?"th":"td",d=Object.assign(Object.assign({},c&&{colspan:c}),l&&{rowspan:l});return this.wrap(u,A,d)}).join("");return this.wrap("tr",s)}).join(""),n=this.wrap("table",r);return this.addRaw(n).addEOL()}addDetails(e,r){let n=this.wrap("details",this.wrap("summary",e)+r);return this.addRaw(n).addEOL()}addImage(e,r,n){let{width:i,height:s}=n||{},o=Object.assign(Object.assign({},i&&{width:i}),s&&{height:s}),a=this.wrap("img",null,Object.assign({src:e,alt:r},o));return this.addRaw(a).addEOL()}addHeading(e,r){let n=`h${r}`,i=["h1","h2","h3","h4","h5","h6"].includes(n)?n:"h1",s=this.wrap(i,e);return this.addRaw(s).addEOL()}addSeparator(){let e=this.wrap("hr",null);return this.addRaw(e).addEOL()}addBreak(){let e=this.wrap("br",null);return this.addRaw(e).addEOL()}addQuote(e,r){let n=Object.assign({},r&&{cite:r}),i=this.wrap("blockquote",e,n);return this.addRaw(i).addEOL()}addLink(e,r){let n=this.wrap("a",e,{href:r});return this.addRaw(n).addEOL()}},M1=new iN;fn.markdownSummary=M1;fn.summary=M1});var F1=h(hn=>{"use strict";var Uae=hn&&hn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),qae=hn&&hn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Hae=hn&&hn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Uae(e,t,r);return qae(e,t),e};Object.defineProperty(hn,"__esModule",{value:!0});hn.toPlatformPath=hn.toWin32Path=hn.toPosixPath=void 0;var jae=Hae(require("path"));function zae(t){return t.replace(/[\\]/g,"/")}hn.toPosixPath=zae;function Gae(t){return t.replace(/[/]/g,"\\")}hn.toWin32Path=Gae;function Yae(t){return t.replace(/[/\\]/g,jae.sep)}hn.toPlatformPath=Yae});var aN=h(ie=>{"use strict";var Jae=ie&&ie.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[nLine truncated
`);return{name:e,version:r}});Ue.platform=iU.default.platform();Ue.arch=iU.default.arch();Ue.isWindows=Ue.platform==="win32";Ue.isMacOS=Ue.platform==="darwin";Ue.isLinux=Ue.platform==="linux";function Tse(){return Lp(this,void 0,void 0,function*(){return Object.assign(Object.assign({},yield Ue.isWindows?_se():Ue.isMacOS?kse():Pse()),{platform:Ue.platform,arch:Ue.arch,isWindows:Ue.isWindows,isMacOS:Ue.isMacOS,isLinux:Ue.isLinux})})}Ue.getDetails=Tse});var ot=h(te=>{"use strict";var Ose=te&&te.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Mse=te&&te.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),O0=te&&te.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Ose(e,t,r);return Mse(e,t),e},oU=te&&te.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(te,"__esModule",{value:!0});te.platform=te.toPlatformPath=te.toWin32Path=te.toPosixPath=te.markdownSummary=te.summary=te.getIDToken=te.getState=te.saveState=te.group=te.endGroup=te.startGroup=te.info=te.notice=te.warning=te.error=te.debug=te.isDebug=te.setFailed=te.setCommandEcho=te.setOutput=te.getBooleanInput=te.getMultilineInput=te.getInput=te.addPath=te.setSecret=te.exportVariable=te.ExitCode=void 0;var Zn=F_(),Ua=H_(),Lc=Lg(),aU=O0(require("os")),Lse=O0(require("path")),Fse=LF(),T0;(function(t){t[t.Success=0]="Success",t[t.Failure=1]="Failure"})(T0||(te.ExitCode=T0={}));function Use(t,e){let r=(0,Lc.toCommandValue)(e);if(process.env[t]=r,process.env.GITHUB_ENV||"")return(0,Ua.issueFileCommand)("ENV",(0,Ua.prepareKeyValueMessage)(t,e));(0,Zn.issueCommand)("set-env",{name:t},r)}te.exportVariable=Use;function qse(t){(0,Zn.issueCommand)("add-mask",{},t)}te.setSecret=qse;function Hse(t){process.env.GITHUB_PATH||""?(0,Ua.issueFileCommand)("PATH",t):(0,Zn.issueCommand)("add-path",{},t),process.env.PATH=`${t}${Lse.delimiter}${process.env.PATH}`}te.addPath=Hse;function M0(t,e){let r=process.env[`INPUT_${t.replace(/ /g,"_").toUpperCase()}`]||"";if(e&&e.required&&!r)throw new Error(`Input required and not supplied: ${t}`);return e&&e.trimWhitespace===!1?r:r.trim()}te.getInput=M0;function zse(t,e){let r=M0(t,e).split(` `);return{name:e,version:r}});je.platform=nU.default.platform();je.arch=nU.default.arch();je.isWindows=je.platform==="win32";je.isMacOS=je.platform==="darwin";je.isLinux=je.platform==="linux";function NAe(){return iy(this,void 0,void 0,function*(){return Object.assign(Object.assign({},yield je.isWindows?BAe():je.isMacOS?QAe():bAe()),{platform:je.platform,arch:je.arch,isWindows:je.isWindows,isMacOS:je.isMacOS,isLinux:je.isLinux})})}je.getDetails=NAe});var ct=h(ne=>{"use strict";var wAe=ne&&ne.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),xAe=ne&&ne.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),dN=ne&&ne.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&wAe(e,t,r);return xAe(e,t),e},sU=ne&&ne.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(ne,"__esModule",{value:!0});ne.platform=ne.toPlatformPath=ne.toWin32Path=ne.toPosixPath=ne.markdownSummary=ne.summary=ne.getIDToken=ne.getState=ne.saveState=ne.group=ne.endGroup=ne.startGroup=ne.info=ne.notice=ne.warning=ne.error=ne.debug=ne.isDebug=ne.setFailed=ne.setCommandEcho=ne.setOutput=ne.getBooleanInput=ne.getMultilineInput=ne.getInput=ne.addPath=ne.setSecret=ne.exportVariable=ne.ExitCode=void 0;var ai=Mk(),eA=qk(),Kc=im(),oU=dN(require("os")),SAe=dN(require("path")),RAe=L1(),uN;(function(t){t[t.Success=0]="Success",t[t.Failure=1]="Failure"})(uN||(ne.ExitCode=uN={}));function vAe(t,e){let r=(0,Kc.toCommandValue)(e);if(process.env[t]=r,process.env.GITHUB_ENV||"")return(0,eA.issueFileCommand)("ENV",(0,eA.prepareKeyValueMessage)(t,e));(0,ai.issueCommand)("set-env",{name:t},r)}ne.exportVariable=vAe;function DAe(t){(0,ai.issueCommand)("add-mask",{},t)}ne.setSecret=DAe;function _Ae(t){process.env.GITHUB_PATH||""?(0,eA.issueFileCommand)("PATH",t):(0,ai.issueCommand)("add-path",{},t),process.env.PATH=`${t}${SAe.delimiter}${process.env.PATH}`}ne.addPath=_Ae;function fN(t,e){let r=process.env[`INPUT_${t.replace(/ /g,"_").toUpperCase()}`]||"";if(e&&e.required&&!r)throw new Error(`Input required and not supplied: ${t}`);return e&&e.trimWhitespace===!1?r:r.trim()}ne.getInput=fN;function kAe(t,e){let r=fN(t,e).split(`
`).filter(n=>n!=="");return e&&e.trimWhitespace===!1?r:r.map(n=>n.trim())}te.getMultilineInput=zse;function jse(t,e){let r=["true","True","TRUE"],n=["false","False","FALSE"],i=M0(t,e);if(r.includes(i))return!0;if(n.includes(i))return!1;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${t} `).filter(n=>n!=="");return e&&e.trimWhitespace===!1?r:r.map(n=>n.trim())}ne.getMultilineInput=kAe;function PAe(t,e){let r=["true","True","TRUE"],n=["false","False","FALSE"],i=fN(t,e);if(r.includes(i))return!0;if(n.includes(i))return!1;throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${t}
Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}te.getBooleanInput=jse;function Gse(t,e){if(process.env.GITHUB_OUTPUT||"")return(0,Ua.issueFileCommand)("OUTPUT",(0,Ua.prepareKeyValueMessage)(t,e));process.stdout.write(aU.EOL),(0,Zn.issueCommand)("set-output",{name:t},(0,Lc.toCommandValue)(e))}te.setOutput=Gse;function Yse(t){(0,Zn.issue)("echo",t?"on":"off")}te.setCommandEcho=Yse;function Jse(t){process.exitCode=T0.Failure,AU(t)}te.setFailed=Jse;function Vse(){return process.env.RUNNER_DEBUG==="1"}te.isDebug=Vse;function Wse(t){(0,Zn.issueCommand)("debug",{},t)}te.debug=Wse;function AU(t,e={}){(0,Zn.issueCommand)("error",(0,Lc.toCommandProperties)(e),t instanceof Error?t.toString():t)}te.error=AU;function $se(t,e={}){(0,Zn.issueCommand)("warning",(0,Lc.toCommandProperties)(e),t instanceof Error?t.toString():t)}te.warning=$se;function Kse(t,e={}){(0,Zn.issueCommand)("notice",(0,Lc.toCommandProperties)(e),t instanceof Error?t.toString():t)}te.notice=Kse;function Xse(t){process.stdout.write(t+aU.EOL)}te.info=Xse;function cU(t){(0,Zn.issue)("group",t)}te.startGroup=cU;function lU(){(0,Zn.issue)("endgroup")}te.endGroup=lU;function Zse(t,e){return oU(this,void 0,void 0,function*(){cU(t);let r;try{r=yield e()}finally{lU()}return r})}te.group=Zse;function eoe(t,e){if(process.env.GITHUB_STATE||"")return(0,Ua.issueFileCommand)("STATE",(0,Ua.prepareKeyValueMessage)(t,e));(0,Zn.issueCommand)("save-state",{name:t},(0,Lc.toCommandValue)(e))}te.saveState=eoe;function toe(t){return process.env[`STATE_${t}`]||""}te.getState=toe;function roe(t){return oU(this,void 0,void 0,function*(){return yield Fse.OidcClient.getIDToken(t)})}te.getIDToken=roe;var noe=v0();Object.defineProperty(te,"summary",{enumerable:!0,get:function(){return noe.summary}});var ioe=v0();Object.defineProperty(te,"markdownSummary",{enumerable:!0,get:function(){return ioe.markdownSummary}});var L0=UF();Object.defineProperty(te,"toPosixPath",{enumerable:!0,get:function(){return L0.toPosixPath}});Object.defineProperty(te,"toWin32Path",{enumerable:!0,get:function(){return L0.toWin32Path}});Object.defineProperty(te,"toPlatformPath",{enumerable:!0,get:function(){return L0.toPlatformPath}});te.platform=O0(sU())});var uU=h(is=>{"use strict";var soe=is&&is.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),ooe=is&&is.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),aoe=is&&is.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&soe(e,t,r);return ooe(e,t),e};Object.defineProperty(is,"__esModule",{value:!0});is.getOptions=void 0;var F0=aoe(ot());function Aoe(t){let e={followSymbolicLinks:!0,implicitDescendants:!0,omitBrokenSymbolicLinks:!0};return t&&(typeof t.followSymbolicLinks=="boolean"&&(e.followSymbolicLinks=t.followSymbolicLinks,F0.debug(`followSymbolicLinks '${e.followSymbolicLinks}'`)),typeof t.implicitDescendants=="boolean"&&(e.implicitDescendants=t.implicitDescendants,F0.debug(`implicitDescendants '${e.implicitDescendants}'`)),typeof t.omitBrokenSymbolicLinks=="boolean"&&(e.omitBrokenSymbolicLinks=t.omitBrokenSymbolicLinks,F0.debug(`omitBrokenSymbolicLinks '${e.omitBrokenSymbolicLinks}'`))),e}is.getOptions=Aoe});var Up=h(Pt=>{"use strict";var coe=Pt&&Pt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),loe=Pt&&Pt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),uoe=Pt&&Pt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&coe(e,t,r);return loe(e,t),e},doe=Pt&&Pt.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Pt,"__esModule",{value:!0});Pt.safeTrimTrailingSeparator=Pt.normalizeSeparators=Pt.hasRoot=Pt.hasAbsoluteRoot=Pt.ensureAbsoluteRoot=Pt.dirname=void 0;var Fp=uoe(require("path")),qa=doe(require("assert")),vo=process.platform==="win32";function foe(t){if(t=q0(t),vo&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(t))return t;let e=Fp.dirname(t);return vo&&/^\\\\[^\\]+\\[^\\]+\\$/.test(e)&&(e=q0(e)),e}Pt.dirname=foe;function hoe(t,e){if(qa.default(t,"ensureAbsoluteRoot parameter 'root' must not be empty"),qa.default(e,"ensureAbsoluteRoot parameter 'itemPath' must not be empty"),U0(e))return e;if(vo){if(e.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let r=process.cwd();return qa.default(r.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${r}'`),e[0].toUpperCase()===r[0].toUpperCase()?e.length===2?`${e[0]}:\\${r.substr(3)}`:(r.endsWith("\\")||(r+="\\Line truncated Support boolean input list: \`true | True | TRUE | false | False | FALSE\``)}ne.getBooleanInput=PAe;function TAe(t,e){if(process.env.GITHUB_OUTPUT||"")return(0,eA.issueFileCommand)("OUTPUT",(0,eA.prepareKeyValueMessage)(t,e));process.stdout.write(oU.EOL),(0,ai.issueCommand)("set-output",{name:t},(0,Kc.toCommandValue)(e))}ne.setOutput=TAe;function OAe(t){(0,ai.issue)("echo",t?"on":"off")}ne.setCommandEcho=OAe;function LAe(t){process.exitCode=uN.Failure,aU(t)}ne.setFailed=LAe;function MAe(){return process.env.RUNNER_DEBUG==="1"}ne.isDebug=MAe;function FAe(t){(0,ai.issueCommand)("debug",{},t)}ne.debug=FAe;function aU(t,e={}){(0,ai.issueCommand)("error",(0,Kc.toCommandProperties)(e),t instanceof Error?t.toString():t)}ne.error=aU;function UAe(t,e={}){(0,ai.issueCommand)("warning",(0,Kc.toCommandProperties)(e),t instanceof Error?t.toString():t)}ne.warning=UAe;function qAe(t,e={}){(0,ai.issueCommand)("notice",(0,Kc.toCommandProperties)(e),t instanceof Error?t.toString():t)}ne.notice=qAe;function HAe(t){process.stdout.write(t+oU.EOL)}ne.info=HAe;function AU(t){(0,ai.issue)("group",t)}ne.startGroup=AU;function cU(){(0,ai.issue)("endgroup")}ne.endGroup=cU;function jAe(t,e){return sU(this,void 0,void 0,function*(){AU(t);let r;try{r=yield e()}finally{cU()}return r})}ne.group=jAe;function zAe(t,e){if(process.env.GITHUB_STATE||"")return(0,eA.issueFileCommand)("STATE",(0,eA.prepareKeyValueMessage)(t,e));(0,ai.issueCommand)("save-state",{name:t},(0,Kc.toCommandValue)(e))}ne.saveState=zAe;function GAe(t){return process.env[`STATE_${t}`]||""}ne.getState=GAe;function YAe(t){return sU(this,void 0,void 0,function*(){return yield RAe.OidcClient.getIDToken(t)})}ne.getIDToken=YAe;var JAe=sN();Object.defineProperty(ne,"summary",{enumerable:!0,get:function(){return JAe.summary}});var VAe=sN();Object.defineProperty(ne,"markdownSummary",{enumerable:!0,get:function(){return VAe.markdownSummary}});var hN=F1();Object.defineProperty(ne,"toPosixPath",{enumerable:!0,get:function(){return hN.toPosixPath}});Object.defineProperty(ne,"toWin32Path",{enumerable:!0,get:function(){return hN.toWin32Path}});Object.defineProperty(ne,"toPlatformPath",{enumerable:!0,get:function(){return hN.toPlatformPath}});ne.platform=dN(iU())});var lU=h(hs=>{"use strict";var WAe=hs&&hs.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),$Ae=hs&&hs.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),KAe=hs&&hs.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&WAe(e,t,r);return $Ae(e,t),e};Object.defineProperty(hs,"__esModule",{value:!0});hs.getOptions=void 0;var gN=KAe(ct());function XAe(t){let e={followSymbolicLinks:!0,implicitDescendants:!0,omitBrokenSymbolicLinks:!0};return t&&(typeof t.followSymbolicLinks=="boolean"&&(e.followSymbolicLinks=t.followSymbolicLinks,gN.debug(`followSymbolicLinks '${e.followSymbolicLinks}'`)),typeof t.implicitDescendants=="boolean"&&(e.implicitDescendants=t.implicitDescendants,gN.debug(`implicitDescendants '${e.implicitDescendants}'`)),typeof t.omitBrokenSymbolicLinks=="boolean"&&(e.omitBrokenSymbolicLinks=t.omitBrokenSymbolicLinks,gN.debug(`omitBrokenSymbolicLinks '${e.omitBrokenSymbolicLinks}'`))),e}hs.getOptions=XAe});var oy=h(Mt=>{"use strict";var ZAe=Mt&&Mt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),ece=Mt&&Mt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),tce=Mt&&Mt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&ZAe(e,t,r);return ece(e,t),e},rce=Mt&&Mt.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Mt,"__esModule",{value:!0});Mt.safeTrimTrailingSeparator=Mt.normalizeSeparators=Mt.hasRoot=Mt.hasAbsoluteRoot=Mt.ensureAbsoluteRoot=Mt.dirname=void 0;var sy=tce(require("path")),tA=rce(require("assert")),Uo=process.platform==="win32";function nce(t){if(t=pN(t),Uo&&/^\\\\[^\\]+(\\[^\\]+)?$/.test(t))return t;let e=sy.dirname(t);return Uo&&/^\\\\[^\\]+\\[^\\]+\\$/.test(e)&&(e=pN(e)),e}Mt.dirname=nce;function ice(t,e){if(tA.default(t,"ensureAbsoluteRoot parameter 'root' must not be empty"),tA.default(e,"ensureAbsoluteRoot parameter 'itemPath' must not be empty"),mN(e))return e;if(Uo){if(e.match(/^[A-Z]:[^\\/]|^[A-Z]:$/i)){let r=process.cwd();return tA.default(r.match(/^[A-Z]:\\/i),`Expected current directory to start with an absolute drive root. Actual '${r}'`),e[0].toUpperCase()===r[0].toUpperCase()?e.length===2?`${e[0]}:\\${r.substr(3)}`:(r.endsWith("\\")||(r+="\\Line truncated
%s`,R,R,I,n);var T=I.type==="*"?G0:I.type==="?"?j0:"\\"+I.type;i=!0,n=n.slice(0,I.reStart)+T+"\\("+R}g(),s&&(n+="\\\\");var U=!1;switch(n.charAt(0)){case"[":case".":case"(":U=!0}for(var k=a.length-1;k>-1;k--){var J=a[k],Qe=n.slice(0,J.reStart),Se=n.slice(J.reStart,J.reEnd-8),H=n.slice(J.reEnd-8,J.reEnd),Re=n.slice(J.reEnd);H+=Re;var tt=Qe.split("(").length-1,Rr=Re;for(m=0;m<tt;m++)Rr=Rr.replace(/\)[+*?]?/,"");Re=Rr;var or="";Re===""&&e!==Hp&&(or="$");var Ao=Qe+Se+Re+or+H;n=Ao}if(n!==""&&i&&(n="(?=.)"+n),U&&(n=d+n),e===Hp)return[n,i];if(!i)return zoe(t);var co=r.nocase?"i":"";try{var bi=new RegExp("^"+n+"$",co)}catch{return new RegExp("$.")}return bi._glob=t,bi._src=n,bi}On.makeRe=function(t,e){return new Nr(t,e||{}).makeRe()};Nr.prototype.makeRe=Hoe;function Hoe(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var e=this.options,r=e.noglobstar?G0:e.dot?Poe:Toe,n=e.nocase?"i":"",i=t.map(function(s){return s.map(function(o){return o===Y0?r:typeof o=="string"?joe(o):o._src}).join("\\/")}).join("|");i="^(?:"+i+")$",this.negate&&(i="^(?!"+i+").*$");try{this.regexp=new RegExp(i,n)}catch{this.regexp=!1}return this.regexp}On.match=function(t,e,r){r=r||{};var n=new Nr(e,r);return t=t.filter(function(i){return n.match(i)}),n.options.nonull&&!t.length&&t.push(e),t};Nr.prototype.match=function(e,r){if(typeof r>"u"&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;var n=this.options;sf.sep!=="/"&&(e=e.split(sf.sep).join("/")),e=e.split(_U),this.debug(this.pattern,"split",e);var i=this.set;this.debug(this.pattern,"set",i);var s,o;for(o=e.length-1;o>=0&&(s=e[o],!s);o--);for(o=0;o<i.length;o++){var a=i[o],A=e;n.matchBase&&a.length===1&&(A=[s]);var c=this.matchOne(A,a,r);if(c)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};Nr.prototype.matchOne=function(t,e,r){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var i=0,s=0,o=t.length,a=e.length;i<o&&s<a;i++,s++){this.debug("matchOne loop");var A=e[s],c=t[i];if(this.debug(e,A,c),A===!1)return!1;if(A===Y0){this.debug("GLOBSTAR",[e,A,c]);var l=i,u=s+1;if(u===a){for(this.debug("** at the end");i<o;i++)if(t[i]==="."||t[i]===".."||!n.dot&&t[i].charAt(0)===".")return!1;return!0}for(;l<o;){var d=t[l];if(this.debug(` %s`,v,v,I,n);var T=I.type==="*"?IN:I.type==="?"?CN:"\\"+I.type;i=!0,n=n.slice(0,I.reStart)+T+"\\("+v}g(),s&&(n+="\\\\");var U=!1;switch(n.charAt(0)){case"[":case".":case"(":U=!0}for(var k=a.length-1;k>-1;k--){var J=a[k],we=n.slice(0,J.reStart),De=n.slice(J.reStart,J.reEnd-8),H=n.slice(J.reEnd-8,J.reEnd),ke=n.slice(J.reEnd);H+=ke;var it=we.split("(").length-1,Lr=ke;for(m=0;m<it;m++)Lr=Lr.replace(/\)[+*?]?/,"");ke=Lr;var dr="";ke===""&&e!==Ay&&(dr="$");var Co=we+De+ke+dr+H;n=Co}if(n!==""&&i&&(n="(?=.)"+n),U&&(n=d+n),e===Ay)return[n,i];if(!i)return kce(t);var Io=r.nocase?"i":"";try{var Pi=new RegExp("^"+n+"$",Io)}catch{return new RegExp("$.")}return Pi._glob=t,Pi._src=n,Pi}zn.makeRe=function(t,e){return new Dr(t,e||{}).makeRe()};Dr.prototype.makeRe=_ce;function _ce(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var e=this.options,r=e.noglobstar?IN:e.dot?bce:Nce,n=e.nocase?"i":"",i=t.map(function(s){return s.map(function(o){return o===BN?r:typeof o=="string"?Pce(o):o._src}).join("\\/")}).join("|");i="^(?:"+i+")$",this.negate&&(i="^(?!"+i+").*$");try{this.regexp=new RegExp(i,n)}catch{this.regexp=!1}return this.regexp}zn.match=function(t,e,r){r=r||{};var n=new Dr(e,r);return t=t.filter(function(i){return n.match(i)}),n.options.nonull&&!t.length&&t.push(e),t};Dr.prototype.match=function(e,r){if(typeof r>"u"&&(r=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&r)return!0;var n=this.options;Cf.sep!=="/"&&(e=e.split(Cf.sep).join("/")),e=e.split(DU),this.debug(this.pattern,"split",e);var i=this.set;this.debug(this.pattern,"set",i);var s,o;for(o=e.length-1;o>=0&&(s=e[o],!s);o--);for(o=0;o<i.length;o++){var a=i[o],A=e;n.matchBase&&a.length===1&&(A=[s]);var c=this.matchOne(A,a,r);if(c)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};Dr.prototype.matchOne=function(t,e,r){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var i=0,s=0,o=t.length,a=e.length;i<o&&s<a;i++,s++){this.debug("matchOne loop");var A=e[s],c=t[i];if(this.debug(e,A,c),A===!1)return!1;if(A===BN){this.debug("GLOBSTAR",[e,A,c]);var l=i,u=s+1;if(u===a){for(this.debug("** at the end");i<o;i++)if(t[i]==="."||t[i]===".."||!n.dot&&t[i].charAt(0)===".")return!1;return!0}for(;l<o;){var d=t[l];if(this.debug(`
globstar while`,t,l,e,u,d),this.matchOne(t.slice(l),e.slice(u),r))return this.debug("globstar found match!",l,o,d),!0;if(d==="."||d===".."||!n.dot&&d.charAt(0)==="."){this.debug("dot detected!",t,l,e,u);break}this.debug("globstar swallow a segment, and continue"),l++}return!!(r&&(this.debug(` globstar while`,t,l,e,u,d),this.matchOne(t.slice(l),e.slice(u),r))return this.debug("globstar found match!",l,o,d),!0;if(d==="."||d===".."||!n.dot&&d.charAt(0)==="."){this.debug("dot detected!",t,l,e,u);break}this.debug("globstar swallow a segment, and continue"),l++}return!!(r&&(this.debug(`
>>> no match, partial?`,t,l,e,u),l===o))}var f;if(typeof A=="string"?(f=c===A,this.debug("string match",A,c,f)):(f=c.match(A),this.debug("pattern match",A,c,f)),!f)return!1}if(i===o&&s===a)return!0;if(i===o)return r;if(s===a)return i===o-1&&t[i]==="";throw new Error("wtf?")};function zoe(t){return t.replace(/\\(.)/g,"$1")}function joe(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var OU=h(ei=>{"use strict";var Goe=ei&&ei.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Yoe=ei&&ei.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),TU=ei&&ei.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Goe(e,t,r);return Yoe(e,t),e},Joe=ei&&ei.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ei,"__esModule",{value:!0});ei.Path=void 0;var of=TU(require("path")),Do=TU(Up()),af=Joe(require("assert")),Voe=process.platform==="win32",V0=class{constructor(e){if(this.segments=[],typeof e=="string")if(af.default(e,"Parameter 'itemPath' must not be empty"),e=Do.safeTrimTrailingSeparator(e),!Do.hasRoot(e))this.segments=e.split(of.sep);else{let r=e,n=Do.dirname(r);for(;n!==r;){let i=of.basename(r);this.segments.unshift(i),r=n,n=Do.dirname(r)}this.segments.unshift(r)}else{af.default(e.length>0,"Parameter 'itemPath' must not be an empty array");for(let r=0;r<e.length;r++){let n=e[r];af.default(n,"Parameter 'itemPath' must not contain any empty segments"),n=Do.normalizeSeparators(e[r]),r===0&&Do.hasRoot(n)?(n=Do.safeTrimTrailingSeparator(n),af.default(n===Do.dirname(n),"Parameter 'itemPath' root segment contains information for multiple segments"),this.segments.push(n)):(af.default(!n.includes(of.sep),"Parameter 'itemPath' contains unexpected path separators"),this.segments.push(n))}}}toString(){let e=this.segments[0],r=e.endsWith(of.sep)||Voe&&/^[A-Z]:$/i.test(e);for(let n=1;n<this.segments.length;n++)r?r=!1:e+=of.sep,e+=this.segments[n];return e}};ei.Path=V0});var MU=h(ti=>{"use strict";var Woe=ti&&ti.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),$oe=ti&&ti.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),K0=ti&&ti.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Woe(e,t,r);return $oe(e,t),e},Koe=ti&&ti.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ti,"__esModule",{value:!0});ti.Pattern=void 0;var Xoe=K0(require("os")),Af=K0(require("path")),un=K0(Up()),Ha=Koe(require("assert")),Zoe=J0(),W0=qp(),jp=OU(),Ls=process.platform==="win32",$0=class t{constructor(e,r=!1,n,i){this.negate=!1;let s;if(typeof e=="string")s=e.trim();else{n=n||[],Ha.default(n.length,"Parameter 'segments' must not empty");let c=t.getLiteral(n[0]);Ha.default(c&&un.hasAbsoluteRoot(c),"Parameter 'segments' first element must be a root path"),s=new jp.Path(n).toString().trim(),e&&(s=`!${s}`)}for(;s.startsWith("!");)this.negate=!this.negate,s=s.substr(1).trim();s=t.fixupPattern(s,i),this.segments=new jp.Path(s).segments,this.trailingSeparator=un.normalizeSeparators(s).endsWith(Af.sep),s=un.safeTrimTrailingSeparator(s);let o=!1,a=this.segments.map(c=>t.getLiteral(c)).filter(c=>!o&&!(o=c===""));this.searchPath=new jp.Path(a).toString(),this.rootRegExp=new RegExp(t.regExpEscape(a[0]),Ls?"i":""),this.isImplicitPattern=r;let A={dot:!0,nobrace:!0,nocase:Ls,nocomment:!0,noext:!0,nonegate:!0};s=Ls?s.replace(/\\/g,"/"):s,this.minimatch=new Zoe.Minimatch(s,A)}match(e){return this.segments[this.segments.length-1]==="**"?(e=un.normalizeSeparators(e),!e.endsWith(Af.sep)&&this.isImplicitPattern===!1&&(e=`${e}${Af.sep}`)):e=un.safeTrimTrailingSeparator(e),this.minimatch.match(e)?this.trailingSeparator?W0.MatchKind.Directory:W0.MatchKind.All:W0.MatchKind.None}partialMatch(e){return e=un.safeTrimTrailingSeparator(e),un.dirname(e)===e?this.rootRegExp.test(e):this.minimatch.matchOne(e.split(Ls?/\\+/:/\/+/),this.minimatch.set[0],!0)}static globEscape(e){return(Ls?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,r){Ha.default(e,"pattern cannot be empty");let n=new jp.Path(e).segments.map(i=>t.getLiteral(i));if(Ha.default(n.every((i,s)=>(i!=="."||s===0)&&i!==".."),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`),Ha.default(!un.hasRoot(e)||n[0],`Invalid pattern '${e}'. Root segment must not contain globs.`),e=un.normalizeSeparators(e),e==="."||e.startsWith(`.${Af.sep}`))e Line truncated >>> no match, partial?`,t,l,e,u),l===o))}var f;if(typeof A=="string"?(f=c===A,this.debug("string match",A,c,f)):(f=c.match(A),this.debug("pattern match",A,c,f)),!f)return!1}if(i===o&&s===a)return!0;if(i===o)return r;if(s===a)return i===o-1&&t[i]==="";throw new Error("wtf?")};function kce(t){return t.replace(/\\(.)/g,"$1")}function Pce(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var TU=h(Ai=>{"use strict";var Tce=Ai&&Ai.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Oce=Ai&&Ai.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),PU=Ai&&Ai.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Tce(e,t,r);return Oce(e,t),e},Lce=Ai&&Ai.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(Ai,"__esModule",{value:!0});Ai.Path=void 0;var If=PU(require("path")),Ho=PU(oy()),Bf=Lce(require("assert")),Mce=process.platform==="win32",bN=class{constructor(e){if(this.segments=[],typeof e=="string")if(Bf.default(e,"Parameter 'itemPath' must not be empty"),e=Ho.safeTrimTrailingSeparator(e),!Ho.hasRoot(e))this.segments=e.split(If.sep);else{let r=e,n=Ho.dirname(r);for(;n!==r;){let i=If.basename(r);this.segments.unshift(i),r=n,n=Ho.dirname(r)}this.segments.unshift(r)}else{Bf.default(e.length>0,"Parameter 'itemPath' must not be an empty array");for(let r=0;r<e.length;r++){let n=e[r];Bf.default(n,"Parameter 'itemPath' must not contain any empty segments"),n=Ho.normalizeSeparators(e[r]),r===0&&Ho.hasRoot(n)?(n=Ho.safeTrimTrailingSeparator(n),Bf.default(n===Ho.dirname(n),"Parameter 'itemPath' root segment contains information for multiple segments"),this.segments.push(n)):(Bf.default(!n.includes(If.sep),"Parameter 'itemPath' contains unexpected path separators"),this.segments.push(n))}}}toString(){let e=this.segments[0],r=e.endsWith(If.sep)||Mce&&/^[A-Z]:$/i.test(e);for(let n=1;n<this.segments.length;n++)r?r=!1:e+=If.sep,e+=this.segments[n];return e}};Ai.Path=bN});var OU=h(ci=>{"use strict";var Fce=ci&&ci.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r),Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[r]}})}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Uce=ci&&ci.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),xN=ci&&ci.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.hasOwnProperty.call(t,r)&&Fce(e,t,r);return Uce(e,t),e},qce=ci&&ci.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ci,"__esModule",{value:!0});ci.Pattern=void 0;var Hce=xN(require("os")),Qf=xN(require("path")),En=xN(oy()),rA=qce(require("assert")),jce=QN(),NN=ay(),ly=TU(),Ws=process.platform==="win32",wN=class t{constructor(e,r=!1,n,i){this.negate=!1;let s;if(typeof e=="string")s=e.trim();else{n=n||[],rA.default(n.length,"Parameter 'segments' must not empty");let c=t.getLiteral(n[0]);rA.default(c&&En.hasAbsoluteRoot(c),"Parameter 'segments' first element must be a root path"),s=new ly.Path(n).toString().trim(),e&&(s=`!${s}`)}for(;s.startsWith("!");)this.negate=!this.negate,s=s.substr(1).trim();s=t.fixupPattern(s,i),this.segments=new ly.Path(s).segments,this.trailingSeparator=En.normalizeSeparators(s).endsWith(Qf.sep),s=En.safeTrimTrailingSeparator(s);let o=!1,a=this.segments.map(c=>t.getLiteral(c)).filter(c=>!o&&!(o=c===""));this.searchPath=new ly.Path(a).toString(),this.rootRegExp=new RegExp(t.regExpEscape(a[0]),Ws?"i":""),this.isImplicitPattern=r;let A={dot:!0,nobrace:!0,nocase:Ws,nocomment:!0,noext:!0,nonegate:!0};s=Ws?s.replace(/\\/g,"/"):s,this.minimatch=new jce.Minimatch(s,A)}match(e){return this.segments[this.segments.length-1]==="**"?(e=En.normalizeSeparators(e),!e.endsWith(Qf.sep)&&this.isImplicitPattern===!1&&(e=`${e}${Qf.sep}`)):e=En.safeTrimTrailingSeparator(e),this.minimatch.match(e)?this.trailingSeparator?NN.MatchKind.Directory:NN.MatchKind.All:NN.MatchKind.None}partialMatch(e){return e=En.safeTrimTrailingSeparator(e),En.dirname(e)===e?this.rootRegExp.test(e):this.minimatch.matchOne(e.split(Ws?/\\+/:/\/+/),this.minimatch.set[0],!0)}static globEscape(e){return(Ws?e:e.replace(/\\/g,"\\\\")).replace(/(\[)(?=[^/]+\])/g,"[[]").replace(/\?/g,"[?]").replace(/\*/g,"[*]")}static fixupPattern(e,r){rA.default(e,"pattern cannot be empty");let n=new ly.Path(e).segments.map(i=>t.getLiteral(i));if(rA.default(n.every((i,s)=>(i!=="."||s===0)&&i!==".."),`Invalid pattern '${e}'. Relative pathing '.' and '..' is not allowed.`),rA.default(!En.hasRoot(e)||n[0],`Invalid pattern '${e}'. Root segment must not contain globs.`),e=En.normalizeSeparators(e),e==="."||e.startsWith(`.${Qf.sep}`))e Line truncated
`),e=e.replace(/\r/g,` `),e=e.replace(/\r/g,`
`));let i=e.split(` `));let i=e.split(`
`).map(s=>s.trim());for(let s of i)!s||s.startsWith("#")||n.patterns.push(new qU.Pattern(s));return n.searchPaths.push(...Yp.getSearchPaths(n.patterns)),n})}static stat(e,r,n){return Z0(this,void 0,void 0,function*(){let i;if(r.followSymbolicLinks)try{i=yield cf.promises.stat(e.path)}catch(s){if(s.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){eN.debug(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw s}else i=yield cf.promises.lstat(e.path);if(i.isDirectory()&&r.followSymbolicLinks){let s=yield cf.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===s)){eN.debug(`Symlink cycle detected for path '${e.path}' and realpath '${s}'`);return}n.push(s)}return i})}};Ar.DefaultGlobber=tN});var jU=h(Uc=>{"use strict";var oae=Uc&&Uc.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Uc,"__esModule",{value:!0});Uc.create=void 0;var aae=zU();function Aae(t,e){return oae(this,void 0,void 0,function*(){return yield aae.DefaultGlobber.create(t,e)})}Uc.create=Aae});var $U=h((pe,WU)=>{pe=WU.exports=xe;var $e;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?$e=function(){var t=Array.prototype.slice.call(arguments,0);t.unshift("SEMVER"),console.log.apply(console,t)}:$e=function(){};pe.SEMVER_SPEC_VERSION="2.0.0";var uf=256,Jp=Number.MAX_SAFE_INTEGER||9007199254740991,rN=16,cae=uf-6,qc=pe.re=[],We=pe.safeRe=[],_=pe.src=[],S=pe.tokens={},JU=0;function De(t){S[t]=JU++}var iN="[a-zA-Z0-9-]",nN=[["\\s",1],["\\d",uf],[iN,cae]];function ff(t){for(var e=0;e<nN.length;e++){var r=nN[e][0],n=nN[e][1];t=t.split(r+"*").join(r+"{0,"+n+"}").split(r+"+").join(r+"{1,"+n+"}")}return t}De("NUMERICIDENTIFIER");_[S.NUMERICIDENTIFIER]="0|[1-9]\\d*";De("NUMERICIDENTIFIERLOOSE");_[S.NUMERICIDENTIFIERLOOSE]="\\d+";De("NONNUMERICIDENTIFIER");_[S.NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+iN+"*";De("MAINVERSION");_[S.MAINVERSION]="("+_[S.NUMERICIDENTIFIER]+")\\.("+_[S.NUMERICIDENTIFIER]+")\\.("+_[S.NUMERICIDENTIFIER]+")";De("MAINVERSIONLOOSE");_[S.MAINVERSIONLOOSE]="("+_[S.NUMERICIDENTIFIERLOOSE]+")\\.("+_[S.NUMERICIDENTIFIERLOOSE]+")\\.("+_[S.NUMERICIDENTIFIERLOOSE]+")";De("PRERELEASEIDENTIFIER");_[S.PRERELEASEIDENTIFIER]="(?:"+_[S.NUMERICIDENTIFIER]+"|"+_[S.NONNUMERICIDENTIFIER]+")";De("PRERELEASEIDENTIFIERLOOSE");_[S.PRERELEASEIDENTIFIERLOOSE]="(?:"+_[S.NUMERICIDENTIFIERLOOSE]+"|"+_[S.NONNUMERICIDENTIFIER]+")";De("PRERELEASE");_[S.PRERELEASE]="(?:-("+_[S.PRERELEASEIDENTIFIER]+"(?:\\."+_[S.PRERELEASEIDENTIFIER]+")*))";De("PRERELEASELOOSE");_[S.PRERELEASELOOSE]="(?:-?("+_[S.PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+_[S.PRERELEASEIDENTIFIERLOOSE]+")*))";De("BUILDIDENTIFIER");_[S.BUILDIDENTIFIER]=iN+"+";De("BUILD");_[S.BUILD]="(?:\\+("+_[S.BUILDIDENTIFIER]+"(?:\\."+_[S.BUILDIDENTIFIER]+")*))";De("FULL");De("FULLPLAIN");_[S.FULLPLAIN]="v?"+_[S.MAINVERSION]+_[S.PRERELEASE]+"?"+_[S.BUILD]+"?";_[S.FULL]="^"+_[S.FULLPLAIN]+"$";De("LOOSEPLAIN");_[S.LOOSEPLAIN]="[v=\\s]*"+_[S.MAINVERSIONLOOSE]+_[S.PRERELEASELOOSE]+"?"+_[S.BUILD]+"?";De("LOOSE");_[S.LOOSE]="^"+_[S.LOOSEPLAIN]+"$";De("GTLT");_[S.GTLT]="((?:<|>)?=?)";De("XRANGEIDENTIFIERLOOSE");_[S.XRANGEIDENTIFIERLOOSE]=_[S.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";De("XRANGEIDENTIFIER");_[S.XRANGEIDENTIFIER]=_[S.NUMERICIDENTIFIER]+"|x|X|\\*";De("XRANGEPLAIN");_[S.XRANGEPLAIN]="[v=\\s]*("+_[S.XRANGEIDENTIFIER]+")(?:\\.("+_[S.XRANGEIDENTIFIER]+")(?:\\.("+_[S.XRANGEIDENTIFIER]+")(?:"+_[S.PRERELEASE]+")?"+_[S.BUILD]+"?)?)?";De("XRANGEPLAINLOOSE");_[S.XRANGEPLAINLOOSE]="[v=\\s]*("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:"+_[S.PRERELEASELOOSE]+")?"+_[S.BUILD]+"?)?)?";De("XRANGE");_[S.XRANGE]="^"+_[S.GTLT]+"\\s*"+_[S.XRANGEPLAIN]+"$";De("XRANGELOOSE");_[S.XRANGELOOSE]="^"+_[S.GTLT]+"\\s*"+_[S.XRANGEPLAINLOOSE]+"$";De("COERCE");_[S.COERCE]="(^|[^\\d])(\\d{1,"+rN+"})(?:\\.(\\d{1,"+rN+"}))?(?:\\.(\\d{1,"+rN+"}))?(?:$|[^\\d])";De("COERCERTL");qc[S.COERCERTL]=new RegExp(_[S.COERCE],"g");We[S.COERCERTL]=new RegExp(ff(_[S.COERCE]),"g");De("LONETILDE");_[S.LONETILDE]="(?:~>?)";De("TILDETRIM");_[S.TILDETRIM]="(\\s*)"+_[S.LONETILDE]+"\\s+";qc[S.TILDETRIM]=new RegExp(_[S.TILDETRIM],"g");We[S.TILDETRIM]=new RegExp(ff(_[S.TILDETRIM]),"g");var lae="$1~";De("TILDE");_[S.TILDE]="^"+_[S.LONETILDE]+_[S.XRANGEPLAIN]+"$";De("TILDELOOSE");_[S.TILDELOOSE]="^"+_[S.LONETILDE]+_[S.XRANGEPLAINLOOSE]+"$";De("LONECARET");_[S.LONECARET]="(?:\\^)";De("CARETTRIM");_[S.CARETTRIM]="(\\s*)"+_[S.LONECARET]+"\\s+";qc[S.CARETTRIM]=new RegExp(_[S.CARETTRIM],"g");We[S.CARETTRIM]=new RegExp(ff(_[S.CARETTRIM]),"g");var uae="$1^";De("CARET");_[S.CARET]="^ Line truncated `).map(s=>s.trim());for(let s of i)!s||s.startsWith("#")||n.patterns.push(new UU.Pattern(s));return n.searchPaths.push(...dy.getSearchPaths(n.patterns)),n})}static stat(e,r,n){return RN(this,void 0,void 0,function*(){let i;if(r.followSymbolicLinks)try{i=yield bf.promises.stat(e.path)}catch(s){if(s.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){vN.debug(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw s}else i=yield bf.promises.lstat(e.path);if(i.isDirectory()&&r.followSymbolicLinks){let s=yield bf.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===s)){vN.debug(`Symlink cycle detected for path '${e.path}' and realpath '${s}'`);return}n.push(s)}return i})}};hr.DefaultGlobber=DN});var jU=h(Zc=>{"use strict";var $ce=Zc&&Zc.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Zc,"__esModule",{value:!0});Zc.create=void 0;var Kce=HU();function Xce(t,e){return $ce(this,void 0,void 0,function*(){return yield Kce.DefaultGlobber.create(t,e)})}Zc.create=Xce});var WU=h((Ee,VU)=>{Ee=VU.exports=ve;var Ze;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?Ze=function(){var t=Array.prototype.slice.call(arguments,0);t.unshift("SEMVER"),console.log.apply(console,t)}:Ze=function(){};Ee.SEMVER_SPEC_VERSION="2.0.0";var wf=256,fy=Number.MAX_SAFE_INTEGER||9007199254740991,_N=16,Zce=wf-6,el=Ee.re=[],Xe=Ee.safeRe=[],_=Ee.src=[],S=Ee.tokens={},YU=0;function Pe(t){S[t]=YU++}var PN="[a-zA-Z0-9-]",kN=[["\\s",1],["\\d",wf],[PN,Zce]];function Sf(t){for(var e=0;e<kN.length;e++){var r=kN[e][0],n=kN[e][1];t=t.split(r+"*").join(r+"{0,"+n+"}").split(r+"+").join(r+"{1,"+n+"}")}return t}Pe("NUMERICIDENTIFIER");_[S.NUMERICIDENTIFIER]="0|[1-9]\\d*";Pe("NUMERICIDENTIFIERLOOSE");_[S.NUMERICIDENTIFIERLOOSE]="\\d+";Pe("NONNUMERICIDENTIFIER");_[S.NONNUMERICIDENTIFIER]="\\d*[a-zA-Z-]"+PN+"*";Pe("MAINVERSION");_[S.MAINVERSION]="("+_[S.NUMERICIDENTIFIER]+")\\.("+_[S.NUMERICIDENTIFIER]+")\\.("+_[S.NUMERICIDENTIFIER]+")";Pe("MAINVERSIONLOOSE");_[S.MAINVERSIONLOOSE]="("+_[S.NUMERICIDENTIFIERLOOSE]+")\\.("+_[S.NUMERICIDENTIFIERLOOSE]+")\\.("+_[S.NUMERICIDENTIFIERLOOSE]+")";Pe("PRERELEASEIDENTIFIER");_[S.PRERELEASEIDENTIFIER]="(?:"+_[S.NUMERICIDENTIFIER]+"|"+_[S.NONNUMERICIDENTIFIER]+")";Pe("PRERELEASEIDENTIFIERLOOSE");_[S.PRERELEASEIDENTIFIERLOOSE]="(?:"+_[S.NUMERICIDENTIFIERLOOSE]+"|"+_[S.NONNUMERICIDENTIFIER]+")";Pe("PRERELEASE");_[S.PRERELEASE]="(?:-("+_[S.PRERELEASEIDENTIFIER]+"(?:\\."+_[S.PRERELEASEIDENTIFIER]+")*))";Pe("PRERELEASELOOSE");_[S.PRERELEASELOOSE]="(?:-?("+_[S.PRERELEASEIDENTIFIERLOOSE]+"(?:\\."+_[S.PRERELEASEIDENTIFIERLOOSE]+")*))";Pe("BUILDIDENTIFIER");_[S.BUILDIDENTIFIER]=PN+"+";Pe("BUILD");_[S.BUILD]="(?:\\+("+_[S.BUILDIDENTIFIER]+"(?:\\."+_[S.BUILDIDENTIFIER]+")*))";Pe("FULL");Pe("FULLPLAIN");_[S.FULLPLAIN]="v?"+_[S.MAINVERSION]+_[S.PRERELEASE]+"?"+_[S.BUILD]+"?";_[S.FULL]="^"+_[S.FULLPLAIN]+"$";Pe("LOOSEPLAIN");_[S.LOOSEPLAIN]="[v=\\s]*"+_[S.MAINVERSIONLOOSE]+_[S.PRERELEASELOOSE]+"?"+_[S.BUILD]+"?";Pe("LOOSE");_[S.LOOSE]="^"+_[S.LOOSEPLAIN]+"$";Pe("GTLT");_[S.GTLT]="((?:<|>)?=?)";Pe("XRANGEIDENTIFIERLOOSE");_[S.XRANGEIDENTIFIERLOOSE]=_[S.NUMERICIDENTIFIERLOOSE]+"|x|X|\\*";Pe("XRANGEIDENTIFIER");_[S.XRANGEIDENTIFIER]=_[S.NUMERICIDENTIFIER]+"|x|X|\\*";Pe("XRANGEPLAIN");_[S.XRANGEPLAIN]="[v=\\s]*("+_[S.XRANGEIDENTIFIER]+")(?:\\.("+_[S.XRANGEIDENTIFIER]+")(?:\\.("+_[S.XRANGEIDENTIFIER]+")(?:"+_[S.PRERELEASE]+")?"+_[S.BUILD]+"?)?)?";Pe("XRANGEPLAINLOOSE");_[S.XRANGEPLAINLOOSE]="[v=\\s]*("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:\\.("+_[S.XRANGEIDENTIFIERLOOSE]+")(?:"+_[S.PRERELEASELOOSE]+")?"+_[S.BUILD]+"?)?)?";Pe("XRANGE");_[S.XRANGE]="^"+_[S.GTLT]+"\\s*"+_[S.XRANGEPLAIN]+"$";Pe("XRANGELOOSE");_[S.XRANGELOOSE]="^"+_[S.GTLT]+"\\s*"+_[S.XRANGEPLAINLOOSE]+"$";Pe("COERCE");_[S.COERCE]="(^|[^\\d])(\\d{1,"+_N+"})(?:\\.(\\d{1,"+_N+"}))?(?:\\.(\\d{1,"+_N+"}))?(?:$|[^\\d])";Pe("COERCERTL");el[S.COERCERTL]=new RegExp(_[S.COERCE],"g");Xe[S.COERCERTL]=new RegExp(Sf(_[S.COERCE]),"g");Pe("LONETILDE");_[S.LONETILDE]="(?:~>?)";Pe("TILDETRIM");_[S.TILDETRIM]="(\\s*)"+_[S.LONETILDE]+"\\s+";el[S.TILDETRIM]=new RegExp(_[S.TILDETRIM],"g");Xe[S.TILDETRIM]=new RegExp(Sf(_[S.TILDETRIM]),"g");var ele="$1~";Pe("TILDE");_[S.TILDE]="^"+_[S.LONETILDE]+_[S.XRANGEPLAIN]+"$";Pe("TILDELOOSE");_[S.TILDELOOSE]="^"+_[S.LONETILDE]+_[S.XRANGEPLAINLOOSE]+"$";Pe("LONECARET");_[S.LONECARET]="(?:\\^)";Pe("CARETTRIM");_[S.CARETTRIM]="(\\s*)"+_[S.LONECARET]+"\\s+";el[S.CARETTRIM]=new RegExp(_[S.CARETTRIM],"g");Xe[S.CARETTRIM]=new RegExp(Sf(_[S.CARETTRIM]),"g");var tle="$1^";Pe("CARET");_[S.CARET]="^ Line truncated
`),{implicitDescendants:!1});try{for(var c=!0,l=Vae(A.globGenerator()),u;u=yield l.next(),e=u.done,!e;c=!0){i=u.value,c=!1;let d=i,f=Kp.relative(a,d).replace(new RegExp(`\\${Kp.sep}`,"g"),"/");gf.debug(`Matched: ${f}`),f===""?o.push("."):o.push(`${f}`)}}catch(d){r={error:d}}finally{try{!c&&!e&&(n=l.return)&&(yield n.call(l))}finally{if(r)throw r.error}}return o})}Ge.resolvePaths=rAe;function nAe(t){return zc(this,void 0,void 0,function*(){return Xae.promisify(cN.unlink)(t)})}Ge.unlinkFile=nAe;function r1(t,e=[]){return zc(this,void 0,void 0,function*(){let r="";e.push("--version"),gf.debug(`Checking ${t} ${e.join(" ")}`);try{yield Wae.exec(`${t}`,e,{ignoreReturnCode:!0,silent:!0,listeners:{stdout:n=>r+=n.toString(),stderr:n=>r+=n.toString()}})}catch(n){gf.debug(n.message)}return r=r.trim(),gf.debug(r),r})}function iAe(){return zc(this,void 0,void 0,function*(){let t=yield r1("zstd",["--quiet"]),e=Kae.clean(t);return gf.debug(`zstd version: ${e}`),t===""?Ga.CompressionMethod.Gzip:Ga.CompressionMethod.ZstdWithoutLong})}Ge.getCompressionMethod=iAe;function sAe(t){return t===Ga.CompressionMethod.Gzip?Ga.CacheFilename.Gzip:Ga.CacheFilename.Zstd}Ge.getCacheFileName=sAe;function oAe(){return zc(this,void 0,void 0,function*(){return cN.existsSync(Ga.GnuTarPathOnWindows)?Ga.GnuTarPathOnWindows:(yield r1("tar")).toLowerCase().includes("gnu tar")?e1.which("tar"):""})}Ge.getGnuTarPathOnWindows=oAe;function aAe(t,e){if(e===void 0)throw Error(`Expected ${t} but value was undefiend`);return e}Ge.assertDefined=aAe;function AAe(t,e,r=!1){let n=t.slice();return e&&n.push(e),process.platform==="win32"&&!r&&n.push("windows-only"),n.push(Zae),t1.createHash("sha256").update(n.join("|")).digest("hex")}Ge.getCacheVersion=AAe;function cAe(){let t=process.env.ACTIONS_RUNTIME_TOKEN;if(!t)throw new Error("Unable to get the ACTIONS_RUNTIME_TOKEN env variable");return t}Ge.getRuntimeToken=cAe});var ni={};pK(ni,{__addDisposableResource:()=>x1,__assign:()=>Xp,__asyncDelegator:()=>E1,__asyncGenerator:()=>y1,__asyncValues:()=>C1,__await:()=>Gc,__awaiter:()=>d1,__classPrivateFieldGet:()=>b1,__classPrivateFieldIn:()=>w1,__classPrivateFieldSet:()=>N1,__createBinding:()=>ey,__decorate:()=>s1,__disposeResources:()=>S1,__esDecorate:()=>a1,__exportStar:()=>h1,__extends:()=>n1,__generator:()=>f1,__importDefault:()=>Q1,__importStar:()=>B1,__makeTemplateObject:()=>I1,__metadata:()=>u1,__param:()=>o1,__propKey:()=>c1,__read:()=>dN,__rest:()=>i1,__rewriteRelativeImportExtension:()=>v1,__runInitializers:()=>A1,__setFunctionName:()=>l1,__spread:()=>g1,__spreadArray:()=>p1,__spreadArrays:()=>m1,__values:()=>Zp,default:()=>dAe});function n1(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");lN(t,e);function r(){this.constructor=t}t.prototype=e===null?Object.create(e):(r.prototype=e.prototype,new r)}function i1(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(t);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i])&&(r[n[i]]=t[n[i]]);return r}function s1(t,e,r,n){var i=arguments.length,s=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(t,e,r,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,r,s):o(e,r))||s);return i>3&&s&&Object.defineProperty(e,r,s),s}function o1(t,e){return function(r,n){e(r,n,t)}}function a1(t,e,r,n,i,s){function o(C){if(C!==void 0&&typeof C!="function")throw new TypeError("Function expected");return C}for(var a=n.kind,A=a==="getter"?"get":a==="setter"?"set":"value",c=!e&&t?n.static?t:t.prototype:null,l=e||(c?Object.getOwnPropertyDescriptor(c,n.name):{}),u,d=!1,f=r.length-1;f>=0;f--){var g={};for(var m in n)g[m]=m==="access"?{}:n[m];for(var m in n.access)g.access[m]=n.access[m];g.addInitializer=function(C){if(d)throw new TypeError("Cannot add initializers after decoration has completed");s.push(o(C||null))};var E=(0,r[f])(a==="accessor"?{get:l.get,set:l.set}:l[A],g);if(a==="accessor"){if(E===void 0)continue;if(E===null||typeof E!="object")throw new TypeError("Object expected");(u=o(E.get))&&(l.get=u),(u=o(E.set))&&(l.set=u),(u=o(E.init))&&i.unshift(u)}else(u=o(E))&&(a==="field"?i.unshift(u):l[A]=u)}c&&Object.defineProperty(c,n.name,l),d=!0}function A1(t,e,r){for(var n=arguments.length>2,i=0;i<e.length;i++)r=n?e[i].call(t,r):e[i].call(t);return n?r:void 0}function c1(t){return typeof t=="symbol"?t:"".concat(t)}function l1(t,e,r){return typeof e=="symbol"&&(e=e.description?"[".concat(e.description,"]"):""),Object.defineProperty(t,"name",{configurable:!0,value:r?"".concat(r," ",e):e})}function u1(t,e){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,e)}function d1(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)}) Line truncated `),{implicitDescendants:!1});try{for(var c=!0,l=Mle(A.globGenerator()),u;u=yield l.next(),e=u.done,!e;c=!0){i=u.value,c=!1;let d=i,f=py.relative(a,d).replace(new RegExp(`\\${py.sep}`,"g"),"/");vf.debug(`Matched: ${f}`),f===""?o.push("."):o.push(`${f}`)}}catch(d){r={error:d}}finally{try{!c&&!e&&(n=l.return)&&(yield n.call(l))}finally{if(r)throw r.error}}return o})}Ve.resolvePaths=Yle;function Jle(t){return rl(this,void 0,void 0,function*(){return Hle.promisify(FN.unlink)(t)})}Ve.unlinkFile=Jle;function tq(t,e=[]){return rl(this,void 0,void 0,function*(){let r="";e.push("--version"),vf.debug(`Checking ${t} ${e.join(" ")}`);try{yield Fle.exec(`${t}`,e,{ignoreReturnCode:!0,silent:!0,listeners:{stdout:n=>r+=n.toString(),stderr:n=>r+=n.toString()}})}catch(n){vf.debug(n.message)}return r=r.trim(),vf.debug(r),r})}function Vle(){return rl(this,void 0,void 0,function*(){let t=yield tq("zstd",["--quiet"]),e=qle.clean(t);return vf.debug(`zstd version: ${e}`),t===""?sA.CompressionMethod.Gzip:sA.CompressionMethod.ZstdWithoutLong})}Ve.getCompressionMethod=Vle;function Wle(t){return t===sA.CompressionMethod.Gzip?sA.CacheFilename.Gzip:sA.CacheFilename.Zstd}Ve.getCacheFileName=Wle;function $le(){return rl(this,void 0,void 0,function*(){return FN.existsSync(sA.GnuTarPathOnWindows)?sA.GnuTarPathOnWindows:(yield tq("tar")).toLowerCase().includes("gnu tar")?ZU.which("tar"):""})}Ve.getGnuTarPathOnWindows=$le;function Kle(t,e){if(e===void 0)throw Error(`Expected ${t} but value was undefiend`);return e}Ve.assertDefined=Kle;function Xle(t,e,r=!1){let n=t.slice();return e&&n.push(e),process.platform==="win32"&&!r&&n.push("windows-only"),n.push(jle),eq.createHash("sha256").update(n.join("|")).digest("hex")}Ve.getCacheVersion=Xle;function Zle(){let t=process.env.ACTIONS_RUNTIME_TOKEN;if(!t)throw new Error("Unable to get the ACTIONS_RUNTIME_TOKEN env variable");return t}Ve.getRuntimeToken=Zle});var ui={};a5(ui,{__addDisposableResource:()=>wq,__assign:()=>yy,__asyncDelegator:()=>yq,__asyncGenerator:()=>pq,__asyncValues:()=>Eq,__await:()=>il,__awaiter:()=>uq,__classPrivateFieldGet:()=>Qq,__classPrivateFieldIn:()=>Nq,__classPrivateFieldSet:()=>bq,__createBinding:()=>Cy,__decorate:()=>iq,__disposeResources:()=>xq,__esDecorate:()=>oq,__exportStar:()=>fq,__extends:()=>rq,__generator:()=>dq,__importDefault:()=>Bq,__importStar:()=>Iq,__makeTemplateObject:()=>Cq,__metadata:()=>lq,__param:()=>sq,__propKey:()=>Aq,__read:()=>HN,__rest:()=>nq,__rewriteRelativeImportExtension:()=>Sq,__runInitializers:()=>aq,__setFunctionName:()=>cq,__spread:()=>hq,__spreadArray:()=>mq,__spreadArrays:()=>gq,__values:()=>Ey,default:()=>rue});function rq(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");UN(t,e);function r(){this.constructor=t}t.prototype=e===null?Object.create(e):(r.prototype=e.prototype,new r)}function nq(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(t);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i])&&(r[n[i]]=t[n[i]]);return r}function iq(t,e,r,n){var i=arguments.length,s=i<3?e:n===null?n=Object.getOwnPropertyDescriptor(e,r):n,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")s=Reflect.decorate(t,e,r,n);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,r,s):o(e,r))||s);return i>3&&s&&Object.defineProperty(e,r,s),s}function sq(t,e){return function(r,n){e(r,n,t)}}function oq(t,e,r,n,i,s){function o(C){if(C!==void 0&&typeof C!="function")throw new TypeError("Function expected");return C}for(var a=n.kind,A=a==="getter"?"get":a==="setter"?"set":"value",c=!e&&t?n.static?t:t.prototype:null,l=e||(c?Object.getOwnPropertyDescriptor(c,n.name):{}),u,d=!1,f=r.length-1;f>=0;f--){var g={};for(var m in n)g[m]=m==="access"?{}:n[m];for(var m in n.access)g.access[m]=n.access[m];g.addInitializer=function(C){if(d)throw new TypeError("Cannot add initializers after decoration has completed");s.push(o(C||null))};var E=(0,r[f])(a==="accessor"?{get:l.get,set:l.set}:l[A],g);if(a==="accessor"){if(E===void 0)continue;if(E===null||typeof E!="object")throw new TypeError("Object expected");(u=o(E.get))&&(l.get=u),(u=o(E.set))&&(l.set=u),(u=o(E.init))&&i.unshift(u)}else(u=o(E))&&(a==="field"?i.unshift(u):l[A]=u)}c&&Object.defineProperty(c,n.name,l),d=!0}function aq(t,e,r){for(var n=arguments.length>2,i=0;i<e.length;i++)r=n?e[i].call(t,r):e[i].call(t);return n?r:void 0}function Aq(t){return typeof t=="symbol"?t:"".concat(t)}function cq(t,e,r){return typeof e=="symbol"&&(e=e.description?"[".concat(e.description,"]"):""),Object.defineProperty(t,"name",{configurable:!0,value:r?"".concat(r," ",e):e})}function lq(t,e){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(t,e)}function uq(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)}) Line truncated
${jAe.sanitize(Object.assign(Object.assign({},this),{request:this.request,response:this.response}))}`,enumerable:!1}),Object.setPrototypeOf(this,t.prototype)}};Cf.RestError=Yc;Yc.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";Yc.PARSE_ERROR="PARSE_ERROR";function GAe(t){return t instanceof Yc?!0:(0,qAe.isError)(t)&&t.name==="RestError"}});var Ya=h(cy=>{"use strict";Object.defineProperty(cy,"__esModule",{value:!0});cy.uint8ArrayToString=YAe;cy.stringToUint8Array=JAe;function YAe(t,e){return Buffer.from(t).toString(e)}function JAe(t,e){return Buffer.from(t,e)}});var If=h(ly=>{"use strict";Object.defineProperty(ly,"__esModule",{value:!0});ly.logger=void 0;var VAe=yf();ly.logger=(0,VAe.createClientLogger)("ts-http-runtime")});var X1=h(dy=>{"use strict";Object.defineProperty(dy,"__esModule",{value:!0});dy.getBodyLength=K1;dy.createNodeHttpClient=rce;var FN=(ii(),xi(ni)),ON=FN.__importStar(require("node:http")),MN=FN.__importStar(require("node:https")),J1=FN.__importStar(require("node:zlib")),WAe=require("node:stream"),V1=mf(),$Ae=Po(),Qf=Jc(),Vc=If(),KAe=Ef(),XAe={};function Bf(t){return t&&typeof t.pipe=="function"}function W1(t){return t.readable===!1?Promise.resolve():new Promise(e=>{let r=()=>{e(),t.removeListener("close",r),t.removeListener("end",r),t.removeListener("error",r)};t.on("close",r),t.on("end",r),t.on("error",r)})}function $1(t){return t&&typeof t.byteLength=="number"}var uy=class extends WAe.Transform{_transform(e,r,n){this.push(e),this.loadedBytes+=e.length;try{this.progressCallback({loadedBytes:this.loadedBytes}),n()}catch(i){n(i)}}constructor(e){super(),this.loadedBytes=0,this.progressCallback=e}},LN=class{constructor(){this.cachedHttpsAgents=new WeakMap}async sendRequest(e){var r,n,i;let s=new AbortController,o;if(e.abortSignal){if(e.abortSignal.aborted)throw new V1.AbortError("The operation was aborted. Request has already been canceled.");o=d=>{d.type==="abort"&&s.abort()},e.abortSignal.addEventListener("abort",o)}let a;e.timeout>0&&(a=setTimeout(()=>{let d=new KAe.Sanitizer;Vc.logger.info(`request to '${d.sanitizeUrl(e.url)}' timed out. canceling...`),s.abort()},e.timeout));let A=e.headers.get("Accept-Encoding"),c=A?.includes("gzip")||A?.includes("deflate"),l=typeof e.body=="function"?e.body():e.body;if(l&&!e.headers.has("Content-Length")){let d=K1(l);d!==null&&e.headers.set("Content-Length",d)}let u;try{if(l&&e.onUploadProgress){let C=e.onUploadProgress,I=new uy(C);I.on("error",N=>{Vc.logger.error("Error in upload progress",N)}),Bf(l)?l.pipe(I):I.end(l),l=I}let d=await this.makeRequest(e,s,l);a!==void 0&&clearTimeout(a);let f=ZAe(d),m={status:(r=d.statusCode)!==null&&r!==void 0?r:0,headers:f,request:e};if(e.method==="HEAD")return d.resume(),m;u=c?ece(d,f):d;let E=e.onDownloadProgress;if(E){let C=new uy(E);C.on("error",I=>{Vc.logger.error("Error in download progress",I)}),u.pipe(C),u=C}return!((n=e.streamResponseStatusCodes)===null||n===void 0)&&n.has(Number.POSITIVE_INFINITY)||!((i=e.streamResponseStatusCodes)===null||i===void 0)&&i.has(m.status)?m.readableStreamBody=u:m.bodyAsText=await tce(u),m}finally{if(e.abortSignal&&o){let d=Promise.resolve();Bf(l)&&(d=W1(l));let f=Promise.resolve();Bf(u)&&(f=W1(u)),Promise.all([d,f]).then(()=>{var g;o&&((g=e.abortSignal)===null||g===void 0||g.removeEventListener("abort",o))}).catch(g=>{Vc.logger.warning("Error when cleaning up abortListener on httpRequest",g)})}}}makeRequest(e,r,n){var i;let s=new URL(e.url),o=s.protocol!=="https:";if(o&&!e.allowInsecureConnection)throw new Error(`Cannot connect to ${e.url} while allowInsecureConnection is false.`);let a=(i=e.agent)!==null&&i!==void 0?i:this.getOrCreateAgent(e,o),A=Object.assign({agent:a,hostname:s.hostname,path:`${s.pathname}${s.search}`,port:s.port,method:e.method,headers:e.headers.toJSON({preserveCase:!0})},e.requestOverrides);return new Promise((c,l)=>{let u=o?ON.request(A,c):MN.request(A,c);u.once("error",d=>{var f;l(new Qf.RestError(d.message,{code:(f=d.code)!==null&&f!==void 0?f:Qf.RestError.REQUEST_SEND_ERROR,request:e}))}),r.signal.addEventListener("abort",()=>{let d=new V1.AbortError("The operation was aborted. Rejecting from abort signal callback while making request.");u.destroy(d),l(d)}),n&&Bf(n)?n.pipe(u):n?typeof n=="string"||Buffer.isBuffer(n)?u.end(n):$1(n)?u.end(ArrayBuffer.isView(n)?Buffer.from(n.buffer):Buffer.from(n)):(Vc.logger.error("Unrecognized body type",n),l(new Qf.RestError("Unrecognized body type"))):u.end()})}getOrCreateAgent(e,r){var n;let i=e.disableKeepAlive;if(r)return i?ON.globalAgent:(this.cachedHttpAgent||(this.cachedHttpAgent=new ON.Agent({keepAlive:!0})),this.cachedHttpAgent);{if(i&&!e.tlsSettings)return MN.globalAgent;let s=(n=e.tlsSettings)!==null&&n!==void 0?n:XAe,o=this.cachedHttpsAgents.get(s);return o&&o.options.keepAlive===!i||(Vc.logger.info("No cached TLS Agent exist, creating a new Agent"),o=new MN.Agent(Object.assign({keepAlive:!i},s)),this.cachedHttpsAgents.set(s,o)),o}}};function ZAe(t){let e=(0,$Ae.createHttpHeaders)();for(let r of Object.keys(t.head Line truncated ${Pue.sanitize(Object.assign(Object.assign({},this),{request:this.request,response:this.response}))}`,enumerable:!1}),Object.setPrototypeOf(this,t.prototype)}};Tf.RestError=sl;sl.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";sl.PARSE_ERROR="PARSE_ERROR";function Tue(t){return t instanceof sl?!0:(0,Due.isError)(t)&&t.name==="RestError"}});var oA=h(Ry=>{"use strict";Object.defineProperty(Ry,"__esModule",{value:!0});Ry.uint8ArrayToString=Oue;Ry.stringToUint8Array=Lue;function Oue(t,e){return Buffer.from(t).toString(e)}function Lue(t,e){return Buffer.from(t,e)}});var Of=h(vy=>{"use strict";Object.defineProperty(vy,"__esModule",{value:!0});vy.logger=void 0;var Mue=kf();vy.logger=(0,Mue.createClientLogger)("ts-http-runtime")});var Kq=h(_y=>{"use strict";Object.defineProperty(_y,"__esModule",{value:!0});_y.getBodyLength=$q;_y.createNodeHttpClient=Yue;var gw=(di(),Li(ui)),dw=gw.__importStar(require("node:http")),fw=gw.__importStar(require("node:https")),Yq=gw.__importStar(require("node:zlib")),Fue=require("node:stream"),Jq=Df(),Uue=Go(),Mf=ol(),al=Of(),que=Pf(),Hue={};function Lf(t){return t&&typeof t.pipe=="function"}function Vq(t){return t.readable===!1?Promise.resolve():new Promise(e=>{let r=()=>{e(),t.removeListener("close",r),t.removeListener("end",r),t.removeListener("error",r)};t.on("close",r),t.on("end",r),t.on("error",r)})}function Wq(t){return t&&typeof t.byteLength=="number"}var Dy=class extends Fue.Transform{_transform(e,r,n){this.push(e),this.loadedBytes+=e.length;try{this.progressCallback({loadedBytes:this.loadedBytes}),n()}catch(i){n(i)}}constructor(e){super(),this.loadedBytes=0,this.progressCallback=e}},hw=class{constructor(){this.cachedHttpsAgents=new WeakMap}async sendRequest(e){var r,n,i;let s=new AbortController,o;if(e.abortSignal){if(e.abortSignal.aborted)throw new Jq.AbortError("The operation was aborted. Request has already been canceled.");o=d=>{d.type==="abort"&&s.abort()},e.abortSignal.addEventListener("abort",o)}let a;e.timeout>0&&(a=setTimeout(()=>{let d=new que.Sanitizer;al.logger.info(`request to '${d.sanitizeUrl(e.url)}' timed out. canceling...`),s.abort()},e.timeout));let A=e.headers.get("Accept-Encoding"),c=A?.includes("gzip")||A?.includes("deflate"),l=typeof e.body=="function"?e.body():e.body;if(l&&!e.headers.has("Content-Length")){let d=$q(l);d!==null&&e.headers.set("Content-Length",d)}let u;try{if(l&&e.onUploadProgress){let C=e.onUploadProgress,I=new Dy(C);I.on("error",b=>{al.logger.error("Error in upload progress",b)}),Lf(l)?l.pipe(I):I.end(l),l=I}let d=await this.makeRequest(e,s,l);a!==void 0&&clearTimeout(a);let f=jue(d),m={status:(r=d.statusCode)!==null&&r!==void 0?r:0,headers:f,request:e};if(e.method==="HEAD")return d.resume(),m;u=c?zue(d,f):d;let E=e.onDownloadProgress;if(E){let C=new Dy(E);C.on("error",I=>{al.logger.error("Error in download progress",I)}),u.pipe(C),u=C}return!((n=e.streamResponseStatusCodes)===null||n===void 0)&&n.has(Number.POSITIVE_INFINITY)||!((i=e.streamResponseStatusCodes)===null||i===void 0)&&i.has(m.status)?m.readableStreamBody=u:m.bodyAsText=await Gue(u),m}finally{if(e.abortSignal&&o){let d=Promise.resolve();Lf(l)&&(d=Vq(l));let f=Promise.resolve();Lf(u)&&(f=Vq(u)),Promise.all([d,f]).then(()=>{var g;o&&((g=e.abortSignal)===null||g===void 0||g.removeEventListener("abort",o))}).catch(g=>{al.logger.warning("Error when cleaning up abortListener on httpRequest",g)})}}}makeRequest(e,r,n){var i;let s=new URL(e.url),o=s.protocol!=="https:";if(o&&!e.allowInsecureConnection)throw new Error(`Cannot connect to ${e.url} while allowInsecureConnection is false.`);let a=(i=e.agent)!==null&&i!==void 0?i:this.getOrCreateAgent(e,o),A=Object.assign({agent:a,hostname:s.hostname,path:`${s.pathname}${s.search}`,port:s.port,method:e.method,headers:e.headers.toJSON({preserveCase:!0})},e.requestOverrides);return new Promise((c,l)=>{let u=o?dw.request(A,c):fw.request(A,c);u.once("error",d=>{var f;l(new Mf.RestError(d.message,{code:(f=d.code)!==null&&f!==void 0?f:Mf.RestError.REQUEST_SEND_ERROR,request:e}))}),r.signal.addEventListener("abort",()=>{let d=new Jq.AbortError("The operation was aborted. Rejecting from abort signal callback while making request.");u.destroy(d),l(d)}),n&&Lf(n)?n.pipe(u):n?typeof n=="string"||Buffer.isBuffer(n)?u.end(n):Wq(n)?u.end(ArrayBuffer.isView(n)?Buffer.from(n.buffer):Buffer.from(n)):(al.logger.error("Unrecognized body type",n),l(new Mf.RestError("Unrecognized body type"))):u.end()})}getOrCreateAgent(e,r){var n;let i=e.disableKeepAlive;if(r)return i?dw.globalAgent:(this.cachedHttpAgent||(this.cachedHttpAgent=new dw.Agent({keepAlive:!0})),this.cachedHttpAgent);{if(i&&!e.tlsSettings)return fw.globalAgent;let s=(n=e.tlsSettings)!==null&&n!==void 0?n:Hue,o=this.cachedHttpsAgents.get(s);return o&&o.options.keepAlive===!i||(al.logger.info("No cached TLS Agent exist, creating a new Agent"),o=new fw.Agent(Object.assign({keepAlive:!i},s)),this.cachedHttpsAgents.set(s,o)),o}}};function jue(t){let e=(0,Uue.createHttpHeaders)();for(let r of Object.keys(t.head Line truncated
`).join(` `).join(`
`+s),t.push(i+"m+"+By.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=ule()+e+" "+t[0]}function ule(){return cr.inspectOpts.hideDate?"":new Date().toISOString()+" "}function dle(...t){return process.stderr.write(Iy.formatWithOptions(cr.inspectOpts,...t)+` `+s),t.push(i+"m+"+Hy.exports.humanize(this.diff)+"\x1B[0m")}else t[0]=tfe()+e+" "+t[0]}function tfe(){return gr.inspectOpts.hideDate?"":new Date().toISOString()+" "}function rfe(...t){return process.stderr.write(qy.formatWithOptions(gr.inspectOpts,...t)+`
`)}function fle(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function hle(){return process.env.DEBUG}function gle(t){t.inspectOpts={};let e=Object.keys(cr.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=cr.inspectOpts[e[r]]}By.exports=aw()(cr);var{formatters:mq}=By.exports;mq.o=function(t){return this.inspectOpts.colors=this.useColors,Iy.inspect(t,this.inspectOpts).split(` `)}function nfe(t){t?process.env.DEBUG=t:delete process.env.DEBUG}function ife(){return process.env.DEBUG}function sfe(t){t.inspectOpts={};let e=Object.keys(gr.inspectOpts);for(let r=0;r<e.length;r++)t.inspectOpts[e[r]]=gr.inspectOpts[e[r]]}Hy.exports=Lw()(gr);var{formatters:g2}=Hy.exports;g2.o=function(t){return this.inspectOpts.colors=this.useColors,qy.inspect(t,this.inspectOpts).split(`
`).map(e=>e.trim()).join(" ")};mq.O=function(t){return this.inspectOpts.colors=this.useColors,Iy.inspect(t,this.inspectOpts)}});var Qy=h((uTe,Aw)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?Aw.exports=gq():Aw.exports=pq()});var Cq=h(fn=>{"use strict";var mle=fn&&fn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),ple=fn&&fn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),yq=fn&&fn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&mle(e,t,r);return ple(e,t),e};Object.defineProperty(fn,"__esModule",{value:!0});fn.req=fn.json=fn.toBuffer=void 0;var yle=yq(require("http")),Ele=yq(require("https"));async function Eq(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}fn.toBuffer=Eq;async function Cle(t){let r=(await Eq(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let i=n;throw i.message+=` (input: ${r})`,i}}fn.json=Cle;function Ile(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?Ele:yle).request(t,e),i=new Promise((s,o)=>{n.once("response",s).once("error",o).end()});return n.then=i.then.bind(i),n}fn.req=Ile});var lw=h(Mn=>{"use strict";var Bq=Mn&&Mn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Ble=Mn&&Mn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Qq=Mn&&Mn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Bq(e,t,r);return Ble(e,t),e},Qle=Mn&&Mn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&Bq(e,t,r)};Object.defineProperty(Mn,"__esModule",{value:!0});Mn.Agent=void 0;var ble=Qq(require("net")),Iq=Qq(require("http")),Nle=require("https");Qle(Cq(),Mn);var os=Symbol("AgentBaseInternalState"),cw=class extends Iq.Agent{constructor(e){super(e),this[os]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(` `).map(e=>e.trim()).join(" ")};g2.O=function(t){return this.inspectOpts.colors=this.useColors,qy.inspect(t,this.inspectOpts)}});var jy=h((uUe,Mw)=>{typeof process>"u"||process.type==="renderer"||process.browser===!0||process.__nwjs?Mw.exports=h2():Mw.exports=m2()});var E2=h(In=>{"use strict";var ofe=In&&In.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),afe=In&&In.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),p2=In&&In.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&ofe(e,t,r);return afe(e,t),e};Object.defineProperty(In,"__esModule",{value:!0});In.req=In.json=In.toBuffer=void 0;var Afe=p2(require("http")),cfe=p2(require("https"));async function y2(t){let e=0,r=[];for await(let n of t)e+=n.length,r.push(n);return Buffer.concat(r,e)}In.toBuffer=y2;async function lfe(t){let r=(await y2(t)).toString("utf8");try{return JSON.parse(r)}catch(n){let i=n;throw i.message+=` (input: ${r})`,i}}In.json=lfe;function ufe(t,e={}){let n=((typeof t=="string"?t:t.href).startsWith("https:")?cfe:Afe).request(t,e),i=new Promise((s,o)=>{n.once("response",s).once("error",o).end()});return n.then=i.then.bind(i),n}In.req=ufe});var Uw=h(Gn=>{"use strict";var I2=Gn&&Gn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),dfe=Gn&&Gn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),B2=Gn&&Gn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&I2(e,t,r);return dfe(e,t),e},ffe=Gn&&Gn.__exportStar||function(t,e){for(var r in t)r!=="default"&&!Object.prototype.hasOwnProperty.call(e,r)&&I2(e,t,r)};Object.defineProperty(Gn,"__esModule",{value:!0});Gn.Agent=void 0;var hfe=B2(require("net")),C2=B2(require("http")),gfe=require("https");ffe(E2(),Gn);var ms=Symbol("AgentBaseInternalState"),Fw=class extends C2.Agent{constructor(e){super(e),this[ms]={}}isSecureEndpoint(e){if(e){if(typeof e.secureEndpoint=="boolean")return e.secureEndpoint;if(typeof e.protocol=="string")return e.protocol==="https:"}let{stack:r}=new Error;return typeof r!="string"?!1:r.split(`
`).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new ble.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],i=n.indexOf(r);i!==-1&&(n.splice(i,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return this.isSecureEndpoint(e)?Nle.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let i={...r,secureEndpoint:this.isSecureEndpoint(r)},s=this.getName(i),o=this.incrementSockets(s);Promise.resolve().then(()=>this.connect(e,i)).then(a=>{if(this.decrementSockets(s,o),a instanceof Iq.Agent)try{return a.addRequest(e,i)}catch(A){return n(A)}this[os].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(s,o),n(a)})}createConnection(){let e=this[os].currentSocket;if(this[os].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[os].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[os]&&(this[os].defaultPort=e)}get protocol(){return this[os].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[os]&&(this[os].protocol=e)}};Mn.Agent=cw});var bq=h(ol=>{"use strict";var wle=ol&&ol.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(ol,"__esModule",{value:!0});ol.parseProxyResponse=void 0;var xle=wle(Qy()),by=(0,xle.default)("https-proxy-agent:parse-proxy-response");function Sle(t){return new Promise((e,r)=>{let n=0,i=[];function s(){let l=t.read();l?c(l):t.once("readable",s)}function o(){t.removeListener("end",a),t.removeListener("error",A),t.removeListener("readable",s)}function a(){o(),by("onend"),r(new Error("Proxy connection ended before receiving CONNECT response"))}function A(l){o(),by("onerror %o",l),r(l)}function c(l){i.push(l),n+=l.length;let u=Buffer.concat(i,n),d=u.indexOf(`\r `).some(n=>n.indexOf("(https.js:")!==-1||n.indexOf("node:https:")!==-1)}incrementSockets(e){if(this.maxSockets===1/0&&this.maxTotalSockets===1/0)return null;this.sockets[e]||(this.sockets[e]=[]);let r=new hfe.Socket({writable:!1});return this.sockets[e].push(r),this.totalSocketCount++,r}decrementSockets(e,r){if(!this.sockets[e]||r===null)return;let n=this.sockets[e],i=n.indexOf(r);i!==-1&&(n.splice(i,1),this.totalSocketCount--,n.length===0&&delete this.sockets[e])}getName(e){return this.isSecureEndpoint(e)?gfe.Agent.prototype.getName.call(this,e):super.getName(e)}createSocket(e,r,n){let i={...r,secureEndpoint:this.isSecureEndpoint(r)},s=this.getName(i),o=this.incrementSockets(s);Promise.resolve().then(()=>this.connect(e,i)).then(a=>{if(this.decrementSockets(s,o),a instanceof C2.Agent)try{return a.addRequest(e,i)}catch(A){return n(A)}this[ms].currentSocket=a,super.createSocket(e,r,n)},a=>{this.decrementSockets(s,o),n(a)})}createConnection(){let e=this[ms].currentSocket;if(this[ms].currentSocket=void 0,!e)throw new Error("No socket was returned in the `connect()` function");return e}get defaultPort(){return this[ms].defaultPort??(this.protocol==="https:"?443:80)}set defaultPort(e){this[ms]&&(this[ms].defaultPort=e)}get protocol(){return this[ms].protocol??(this.isSecureEndpoint()?"https:":"http:")}set protocol(e){this[ms]&&(this[ms].protocol=e)}};Gn.Agent=Fw});var Q2=h(El=>{"use strict";var mfe=El&&El.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(El,"__esModule",{value:!0});El.parseProxyResponse=void 0;var pfe=mfe(jy()),zy=(0,pfe.default)("https-proxy-agent:parse-proxy-response");function yfe(t){return new Promise((e,r)=>{let n=0,i=[];function s(){let l=t.read();l?c(l):t.once("readable",s)}function o(){t.removeListener("end",a),t.removeListener("error",A),t.removeListener("readable",s)}function a(){o(),zy("onend"),r(new Error("Proxy connection ended before receiving CONNECT response"))}function A(l){o(),zy("onerror %o",l),r(l)}function c(l){i.push(l),n+=l.length;let u=Buffer.concat(i,n),d=u.indexOf(`\r
\r \r
`);if(d===-1){by("have not received end of HTTP headers yet..."),s();return}let f=u.slice(0,d).toString("ascii").split(`\r `);if(d===-1){zy("have not received end of HTTP headers yet..."),s();return}let f=u.slice(0,d).toString("ascii").split(`\r
`),g=f.shift();if(!g)return t.destroy(),r(new Error("No header received from proxy CONNECT response"));let m=g.split(" "),E=+m[1],C=m.slice(2).join(" "),I={};for(let N of f){if(!N)continue;let w=N.indexOf(":");if(w===-1)return t.destroy(),r(new Error(`Invalid header from proxy CONNECT response: "${N}"`));let R=N.slice(0,w).toLowerCase(),T=N.slice(w+1).trimStart(),U=I[R];typeof U=="string"?I[R]=[U,T]:Array.isArray(U)?U.push(T):I[R]=T}by("got proxy server response: %o %o",g,I),o(),e({connect:{statusCode:E,statusText:C,headers:I},buffered:u})}t.on("error",A),t.on("end",a),s()})}ol.parseProxyResponse=Sle});var Rq=h(si=>{"use strict";var vle=si&&si.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Rle=si&&si.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Sq=si&&si.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&vle(e,t,r);return Rle(e,t),e},vq=si&&si.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(si,"__esModule",{value:!0});si.HttpsProxyAgent=void 0;var Ny=Sq(require("net")),Nq=Sq(require("tls")),Dle=vq(require("assert")),_le=vq(Qy()),kle=lw(),Ple=require("url"),Tle=bq(),wf=(0,_le.default)("https-proxy-agent"),wq=t=>t.servername===void 0&&t.host&&!Ny.isIP(t.host)?{...t,servername:t.host}:t,wy=class extends kle.Agent{constructor(e,r){super(r),this.options={path:void 0},this.proxy=typeof e=="string"?new Ple.URL(e):e,this.proxyHeaders=r?.headers??{},wf("Creating new HttpsProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),i=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={ALPNProtocols:["http/1.1"],...r?xq(r,"headers"):null,host:n,port:i}}async connect(e,r){let{proxy:n}=this;if(!r.host)throw new TypeError('No "host" provided');let i;n.protocol==="https:"?(wf("Creating `tls.Socket`: %o",this.connectOpts),i=Nq.connect(wq(this.connectOpts))):(wf("Creating `net.Socket`: %o",this.connectOpts),i=Ny.connect(this.connectOpts));let s=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders},o=Ny.isIPv6(r.host)?`[${r.host}]`:r.host,a=`CONNECT ${o}:${r.port} HTTP/1.1\r `),g=f.shift();if(!g)return t.destroy(),r(new Error("No header received from proxy CONNECT response"));let m=g.split(" "),E=+m[1],C=m.slice(2).join(" "),I={};for(let b of f){if(!b)continue;let w=b.indexOf(":");if(w===-1)return t.destroy(),r(new Error(`Invalid header from proxy CONNECT response: "${b}"`));let v=b.slice(0,w).toLowerCase(),T=b.slice(w+1).trimStart(),U=I[v];typeof U=="string"?I[v]=[U,T]:Array.isArray(U)?U.push(T):I[v]=T}zy("got proxy server response: %o %o",g,I),o(),e({connect:{statusCode:E,statusText:C,headers:I},buffered:u})}t.on("error",A),t.on("end",a),s()})}El.parseProxyResponse=yfe});var R2=h(fi=>{"use strict";var Efe=fi&&fi.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Cfe=fi&&fi.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),x2=fi&&fi.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Efe(e,t,r);return Cfe(e,t),e},S2=fi&&fi.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(fi,"__esModule",{value:!0});fi.HttpsProxyAgent=void 0;var Gy=x2(require("net")),b2=x2(require("tls")),Ife=S2(require("assert")),Bfe=S2(jy()),Qfe=Uw(),bfe=require("url"),Nfe=Q2(),qf=(0,Bfe.default)("https-proxy-agent"),N2=t=>t.servername===void 0&&t.host&&!Gy.isIP(t.host)?{...t,servername:t.host}:t,Yy=class extends Qfe.Agent{constructor(e,r){super(r),this.options={path:void 0},this.proxy=typeof e=="string"?new bfe.URL(e):e,this.proxyHeaders=r?.headers??{},qf("Creating new HttpsProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),i=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={ALPNProtocols:["http/1.1"],...r?w2(r,"headers"):null,host:n,port:i}}async connect(e,r){let{proxy:n}=this;if(!r.host)throw new TypeError('No "host" provided');let i;n.protocol==="https:"?(qf("Creating `tls.Socket`: %o",this.connectOpts),i=b2.connect(N2(this.connectOpts))):(qf("Creating `net.Socket`: %o",this.connectOpts),i=Gy.connect(this.connectOpts));let s=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders},o=Gy.isIPv6(r.host)?`[${r.host}]`:r.host,a=`CONNECT ${o}:${r.port} HTTP/1.1\r
`;if(n.username||n.password){let d=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;s["Proxy-Authorization"]=`Basic ${Buffer.from(d).toString("base64")}`}s.Host=`${o}:${r.port}`,s["Proxy-Connection"]||(s["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let d of Object.keys(s))a+=`${d}: ${s[d]}\r `;if(n.username||n.password){let d=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;s["Proxy-Authorization"]=`Basic ${Buffer.from(d).toString("base64")}`}s.Host=`${o}:${r.port}`,s["Proxy-Connection"]||(s["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let d of Object.keys(s))a+=`${d}: ${s[d]}\r
`;let A=(0,Tle.parseProxyResponse)(i);i.write(`${a}\r `;let A=(0,Nfe.parseProxyResponse)(i);i.write(`${a}\r
`);let{connect:c,buffered:l}=await A;if(e.emit("proxyConnect",c),this.emit("proxyConnect",c,e),c.statusCode===200)return e.once("socket",Ole),r.secureEndpoint?(wf("Upgrading socket connection to TLS"),Nq.connect({...xq(wq(r),"host","path","port"),socket:i})):i;i.destroy();let u=new Ny.Socket({writable:!1});return u.readable=!0,e.once("socket",d=>{wf("Replaying proxy buffer for failed request"),(0,Dle.default)(d.listenerCount("data")>0),d.push(l),d.push(null)}),u}};wy.protocols=["http","https"];si.HttpsProxyAgent=wy;function Ole(t){t.resume()}function xq(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var kq=h(oi=>{"use strict";var Mle=oi&&oi.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Lle=oi&&oi.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),_q=oi&&oi.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&Mle(e,t,r);return Lle(e,t),e},Fle=oi&&oi.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(oi,"__esModule",{value:!0});oi.HttpProxyAgent=void 0;var Ule=_q(require("net")),qle=_q(require("tls")),Hle=Fle(Qy()),zle=require("events"),jle=lw(),Dq=require("url"),al=(0,Hle.default)("http-proxy-agent"),xy=class extends jle.Agent{constructor(e,r){super(r),this.proxy=typeof e=="string"?new Dq.URL(e):e,this.proxyHeaders=r?.headers??{},al("Creating new HttpProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),i=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={...r?Gle(r,"headers"):null,host:n,port:i}}addRequest(e,r){e._header=null,this.setRequestProps(e,r),super.addRequest(e,r)}setRequestProps(e,r){let{proxy:n}=this,i=r.secureEndpoint?"https:":"http:",s=e.getHeader("host")||"localhost",o=`${i}//${s}`,a=new Dq.URL(e.path,o);r.port!==80&&(a.port=String(r.port)),e.path=String(a);let A=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders};if(n.username||n.password){let c=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;A["Proxy-Authorization"]=`Basic ${Buffer.from(c).toString("base64")}`}A["Proxy-Connection"]||(A["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let c of Object.keys(A)){let l=A[c];l&&e.setHeader(c,l)}}async connect(e,r){e._header=null,e.path.includes("://")||this.setRequestProps(e,r);let n,i;al("Regenerating stored HTTP header string for request"),e._implicitHeader(),e.outputData&&e.outputData.length>0&&(al("Patching connection write() output buffer with updated header"),n=e.outputData[0].data,i=n.indexOf(`\r `);let{connect:c,buffered:l}=await A;if(e.emit("proxyConnect",c),this.emit("proxyConnect",c,e),c.statusCode===200)return e.once("socket",wfe),r.secureEndpoint?(qf("Upgrading socket connection to TLS"),b2.connect({...w2(N2(r),"host","path","port"),socket:i})):i;i.destroy();let u=new Gy.Socket({writable:!1});return u.readable=!0,e.once("socket",d=>{qf("Replaying proxy buffer for failed request"),(0,Ife.default)(d.listenerCount("data")>0),d.push(l),d.push(null)}),u}};Yy.protocols=["http","https"];fi.HttpsProxyAgent=Yy;function wfe(t){t.resume()}function w2(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var _2=h(hi=>{"use strict";var xfe=hi&&hi.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Sfe=hi&&hi.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),D2=hi&&hi.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&xfe(e,t,r);return Sfe(e,t),e},Rfe=hi&&hi.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(hi,"__esModule",{value:!0});hi.HttpProxyAgent=void 0;var vfe=D2(require("net")),Dfe=D2(require("tls")),_fe=Rfe(jy()),kfe=require("events"),Pfe=Uw(),v2=require("url"),Cl=(0,_fe.default)("http-proxy-agent"),Jy=class extends Pfe.Agent{constructor(e,r){super(r),this.proxy=typeof e=="string"?new v2.URL(e):e,this.proxyHeaders=r?.headers??{},Cl("Creating new HttpProxyAgent instance: %o",this.proxy.href);let n=(this.proxy.hostname||this.proxy.host).replace(/^\[|\]$/g,""),i=this.proxy.port?parseInt(this.proxy.port,10):this.proxy.protocol==="https:"?443:80;this.connectOpts={...r?Tfe(r,"headers"):null,host:n,port:i}}addRequest(e,r){e._header=null,this.setRequestProps(e,r),super.addRequest(e,r)}setRequestProps(e,r){let{proxy:n}=this,i=r.secureEndpoint?"https:":"http:",s=e.getHeader("host")||"localhost",o=`${i}//${s}`,a=new v2.URL(e.path,o);r.port!==80&&(a.port=String(r.port)),e.path=String(a);let A=typeof this.proxyHeaders=="function"?this.proxyHeaders():{...this.proxyHeaders};if(n.username||n.password){let c=`${decodeURIComponent(n.username)}:${decodeURIComponent(n.password)}`;A["Proxy-Authorization"]=`Basic ${Buffer.from(c).toString("base64")}`}A["Proxy-Connection"]||(A["Proxy-Connection"]=this.keepAlive?"Keep-Alive":"close");for(let c of Object.keys(A)){let l=A[c];l&&e.setHeader(c,l)}}async connect(e,r){e._header=null,e.path.includes("://")||this.setRequestProps(e,r);let n,i;Cl("Regenerating stored HTTP header string for request"),e._implicitHeader(),e.outputData&&e.outputData.length>0&&(Cl("Patching connection write() output buffer with updated header"),n=e.outputData[0].data,i=n.indexOf(`\r
\r \r
`)+4,e.outputData[0].data=e._header+n.substring(i),al("Output buffer: %o",e.outputData[0].data));let s;return this.proxy.protocol==="https:"?(al("Creating `tls.Socket`: %o",this.connectOpts),s=qle.connect(this.connectOpts)):(al("Creating `net.Socket`: %o",this.connectOpts),s=Ule.connect(this.connectOpts)),await(0,zle.once)(s,"connect"),s}};xy.protocols=["http","https"];oi.HttpProxyAgent=xy;function Gle(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var uw=h(ai=>{"use strict";Object.defineProperty(ai,"__esModule",{value:!0});ai.globalNoProxyList=ai.proxyPolicyName=void 0;ai.loadNoProxy=Lq;ai.getDefaultProxySettings=tue;ai.proxyPolicy=nue;var Yle=Rq(),Jle=kq(),Vle=If(),Wle="HTTPS_PROXY",$le="HTTP_PROXY",Kle="ALL_PROXY",Xle="NO_PROXY";ai.proxyPolicyName="proxyPolicy";ai.globalNoProxyList=[];var Oq=!1,Zle=new Map;function Sy(t){if(process.env[t])return process.env[t];if(process.env[t.toLowerCase()])return process.env[t.toLowerCase()]}function Mq(){if(!process)return;let t=Sy(Wle),e=Sy(Kle),r=Sy($le);return t||e||r}function eue(t,e,r){if(e.length===0)return!1;let n=new URL(t).hostname;if(r?.has(n))return r.get(n);let i=!1;for(let s of e)s[0]==="."?(n.endsWith(s)||n.length===s.length-1&&n===s.slice(1))&&(i=!0):n===s&&(i=!0);return r?.set(n,i),i}function Lq(){let t=Sy(Xle);return Oq=!0,t?t.split(",").map(e=>e.trim()).filter(e=>e.length):[]}function tue(t){if(!t&&(t=Mq(),!t))return;let e=new URL(t);return{host:(e.protocol?e.protocol+"//":"")+e.hostname,port:Number.parseInt(e.port||"80"),username:e.username,password:e.password}}function rue(){let t=Mq();return t?new URL(t):void 0}function Pq(t){let e;try{e=new URL(t.host)}catch{throw new Error(`Expecting a valid host string in proxy settings, but found "${t.host}".`)}return e.port=String(t.port),t.username&&(e.username=t.username),t.password&&(e.password=t.password),e}function Tq(t,e,r){if(t.agent)return;let i=new URL(t.url).protocol!=="https:";t.tlsSettings&&Vle.logger.warning("TLS settings are not supported in combination with custom Proxy, certificates provided to the client will be ignored.");let s=t.headers.toJSON();i?(e.httpProxyAgent||(e.httpProxyAgent=new Jle.HttpProxyAgent(r,{headers:s})),t.agent=e.httpProxyAgent):(e.httpsProxyAgent||(e.httpsProxyAgent=new Yle.HttpsProxyAgent(r,{headers:s})),t.agent=e.httpsProxyAgent)}function nue(t,e){Oq||ai.globalNoProxyList.push(...Lq());let r=t?Pq(t):rue(),n={};return{name:ai.proxyPolicyName,async sendRequest(i,s){var o;return!i.proxySettings&&r&&!eue(i.url,(o=e?.customNoProxyList)!==null&&o!==void 0?o:ai.globalNoProxyList,e?.customNoProxyList?void 0:Zle)?Tq(i,n,r):i.proxySettings&&Tq(i,n,Pq(i.proxySettings)),s(i)}}}});var dw=h(Al=>{"use strict";Object.defineProperty(Al,"__esModule",{value:!0});Al.agentPolicyName=void 0;Al.agentPolicy=iue;Al.agentPolicyName="agentPolicy";function iue(t){return{name:Al.agentPolicyName,sendRequest:async(e,r)=>(e.agent||(e.agent=t),r(e))}}});var fw=h(cl=>{"use strict";Object.defineProperty(cl,"__esModule",{value:!0});cl.tlsPolicyName=void 0;cl.tlsPolicy=sue;cl.tlsPolicyName="tlsPolicy";function sue(t){return{name:cl.tlsPolicyName,sendRequest:async(e,r)=>(e.tlsSettings||(e.tlsSettings=t),r(e))}}});var xf=h(Wa=>{"use strict";Object.defineProperty(Wa,"__esModule",{value:!0});Wa.isNodeReadableStream=Fq;Wa.isWebReadableStream=Uq;Wa.isBinaryBody=oue;Wa.isReadableStream=qq;Wa.isBlob=aue;function Fq(t){return!!(t&&typeof t.pipe=="function")}function Uq(t){return!!(t&&typeof t.getReader=="function"&&typeof t.tee=="function")}function oue(t){return t!==void 0&&(t instanceof Uint8Array||qq(t)||typeof t=="function"||t instanceof Blob)}function qq(t){return Fq(t)||Uq(t)}function aue(t){return typeof t.stream=="function"}});var jq=h(gw=>{"use strict";Object.defineProperty(gw,"__esModule",{value:!0});gw.concat=uue;var qs=(ii(),xi(ni)),hw=require("stream"),Aue=xf();function Hq(){return qs.__asyncGenerator(this,arguments,function*(){let e=this.getReader();try{for(;;){let{done:r,value:n}=yield qs.__await(e.read());if(r)return yield qs.__await(void 0);yield yield qs.__await(n)}}finally{e.releaseLock()}})}function cue(t){t[Symbol.asyncIterator]||(t[Symbol.asyncIterator]=Hq.bind(t)),t.values||(t.values=Hq.bind(t))}function zq(t){return t instanceof ReadableStream?(cue(t),hw.Readable.fromWeb(t)):t}function lue(t){return t instanceof Uint8Array?hw.Readable.from(Buffer.from(t)):(0,Aue.isBlob)(t)?zq(t.stream()):zq(t)}async function uue(t){return function(){let e=t.map(r=>typeof r=="function"?r():r).map(lue);return hw.Readable.from((function(){return qs.__asyncGenerator(this,arguments,function*(){var r,n,i,s;for(let c of e)try{for(var o=!0,a=(n=void 0,qs.__asyncValues(c)),A;A=yield qs.__await(a.next()),r=A.done,!r;o=!0){s=A.value,o=!1;let l=s;yield yield qs.__await(l)}}catch(l){n={error:l}}finally{try{!o&&!r&&(i=a.return)&&(yield qs.__await(i.call(a)))}finally{if(n)throw n.error}}})})())}}});var mw=h(ul=>{"use strict";Object.defineProperty(ul,"__esModule",{value:!0});ul.multipartPolicyName=vo Line truncated `)+4,e.outputData[0].data=e._header+n.substring(i),Cl("Output buffer: %o",e.outputData[0].data));let s;return this.proxy.protocol==="https:"?(Cl("Creating `tls.Socket`: %o",this.connectOpts),s=Dfe.connect(this.connectOpts)):(Cl("Creating `net.Socket`: %o",this.connectOpts),s=vfe.connect(this.connectOpts)),await(0,kfe.once)(s,"connect"),s}};Jy.protocols=["http","https"];hi.HttpProxyAgent=Jy;function Tfe(t,...e){let r={},n;for(n in t)e.includes(n)||(r[n]=t[n]);return r}});var qw=h(gi=>{"use strict";Object.defineProperty(gi,"__esModule",{value:!0});gi.globalNoProxyList=gi.proxyPolicyName=void 0;gi.loadNoProxy=L2;gi.getDefaultProxySettings=Gfe;gi.proxyPolicy=Jfe;var Ofe=R2(),Lfe=_2(),Mfe=Of(),Ffe="HTTPS_PROXY",Ufe="HTTP_PROXY",qfe="ALL_PROXY",Hfe="NO_PROXY";gi.proxyPolicyName="proxyPolicy";gi.globalNoProxyList=[];var T2=!1,jfe=new Map;function Vy(t){if(process.env[t])return process.env[t];if(process.env[t.toLowerCase()])return process.env[t.toLowerCase()]}function O2(){if(!process)return;let t=Vy(Ffe),e=Vy(qfe),r=Vy(Ufe);return t||e||r}function zfe(t,e,r){if(e.length===0)return!1;let n=new URL(t).hostname;if(r?.has(n))return r.get(n);let i=!1;for(let s of e)s[0]==="."?(n.endsWith(s)||n.length===s.length-1&&n===s.slice(1))&&(i=!0):n===s&&(i=!0);return r?.set(n,i),i}function L2(){let t=Vy(Hfe);return T2=!0,t?t.split(",").map(e=>e.trim()).filter(e=>e.length):[]}function Gfe(t){if(!t&&(t=O2(),!t))return;let e=new URL(t);return{host:(e.protocol?e.protocol+"//":"")+e.hostname,port:Number.parseInt(e.port||"80"),username:e.username,password:e.password}}function Yfe(){let t=O2();return t?new URL(t):void 0}function k2(t){let e;try{e=new URL(t.host)}catch{throw new Error(`Expecting a valid host string in proxy settings, but found "${t.host}".`)}return e.port=String(t.port),t.username&&(e.username=t.username),t.password&&(e.password=t.password),e}function P2(t,e,r){if(t.agent)return;let i=new URL(t.url).protocol!=="https:";t.tlsSettings&&Mfe.logger.warning("TLS settings are not supported in combination with custom Proxy, certificates provided to the client will be ignored.");let s=t.headers.toJSON();i?(e.httpProxyAgent||(e.httpProxyAgent=new Lfe.HttpProxyAgent(r,{headers:s})),t.agent=e.httpProxyAgent):(e.httpsProxyAgent||(e.httpsProxyAgent=new Ofe.HttpsProxyAgent(r,{headers:s})),t.agent=e.httpsProxyAgent)}function Jfe(t,e){T2||gi.globalNoProxyList.push(...L2());let r=t?k2(t):Yfe(),n={};return{name:gi.proxyPolicyName,async sendRequest(i,s){var o;return!i.proxySettings&&r&&!zfe(i.url,(o=e?.customNoProxyList)!==null&&o!==void 0?o:gi.globalNoProxyList,e?.customNoProxyList?void 0:jfe)?P2(i,n,r):i.proxySettings&&P2(i,n,k2(i.proxySettings)),s(i)}}}});var Hw=h(Il=>{"use strict";Object.defineProperty(Il,"__esModule",{value:!0});Il.agentPolicyName=void 0;Il.agentPolicy=Vfe;Il.agentPolicyName="agentPolicy";function Vfe(t){return{name:Il.agentPolicyName,sendRequest:async(e,r)=>(e.agent||(e.agent=t),r(e))}}});var jw=h(Bl=>{"use strict";Object.defineProperty(Bl,"__esModule",{value:!0});Bl.tlsPolicyName=void 0;Bl.tlsPolicy=Wfe;Bl.tlsPolicyName="tlsPolicy";function Wfe(t){return{name:Bl.tlsPolicyName,sendRequest:async(e,r)=>(e.tlsSettings||(e.tlsSettings=t),r(e))}}});var Hf=h(cA=>{"use strict";Object.defineProperty(cA,"__esModule",{value:!0});cA.isNodeReadableStream=M2;cA.isWebReadableStream=F2;cA.isBinaryBody=$fe;cA.isReadableStream=U2;cA.isBlob=Kfe;function M2(t){return!!(t&&typeof t.pipe=="function")}function F2(t){return!!(t&&typeof t.getReader=="function"&&typeof t.tee=="function")}function $fe(t){return t!==void 0&&(t instanceof Uint8Array||U2(t)||typeof t=="function"||t instanceof Blob)}function U2(t){return M2(t)||F2(t)}function Kfe(t){return typeof t.stream=="function"}});var j2=h(Gw=>{"use strict";Object.defineProperty(Gw,"__esModule",{value:!0});Gw.concat=the;var Xs=(di(),Li(ui)),zw=require("stream"),Xfe=Hf();function q2(){return Xs.__asyncGenerator(this,arguments,function*(){let e=this.getReader();try{for(;;){let{done:r,value:n}=yield Xs.__await(e.read());if(r)return yield Xs.__await(void 0);yield yield Xs.__await(n)}}finally{e.releaseLock()}})}function Zfe(t){t[Symbol.asyncIterator]||(t[Symbol.asyncIterator]=q2.bind(t)),t.values||(t.values=q2.bind(t))}function H2(t){return t instanceof ReadableStream?(Zfe(t),zw.Readable.fromWeb(t)):t}function ehe(t){return t instanceof Uint8Array?zw.Readable.from(Buffer.from(t)):(0,Xfe.isBlob)(t)?H2(t.stream()):H2(t)}async function the(t){return function(){let e=t.map(r=>typeof r=="function"?r():r).map(ehe);return zw.Readable.from((function(){return Xs.__asyncGenerator(this,arguments,function*(){var r,n,i,s;for(let c of e)try{for(var o=!0,a=(n=void 0,Xs.__asyncValues(c)),A;A=yield Xs.__await(a.next()),r=A.done,!r;o=!0){s=A.value,o=!1;let l=s;yield yield Xs.__await(l)}}catch(l){n={error:l}}finally{try{!o&&!r&&(i=a.return)&&(yield Xs.__await(i.call(a)))}finally{if(n)throw n.error}}})})())}}});var Yw=h(bl=>{"use strict";Object.defineProperty(bl,"__esModule",{value:!0});bl.multipartPolicyName=vo Line truncated
`;return e}function pue(t){return t instanceof Uint8Array?t.byteLength:(0,due.isBlob)(t)?t.size===-1?void 0:t.size:void 0}function yue(t){let e=0;for(let r of t){let n=pue(r);if(n===void 0)return;e+=n}return e}async function Eue(t,e,r){let n=[(0,ll.stringToUint8Array)(`--${r}`,"utf-8"),...e.flatMap(s=>[(0,ll.stringToUint8Array)(`\r `;return e}function ahe(t){return t instanceof Uint8Array?t.byteLength:(0,rhe.isBlob)(t)?t.size===-1?void 0:t.size:void 0}function Ahe(t){let e=0;for(let r of t){let n=ahe(r);if(n===void 0)return;e+=n}return e}async function che(t,e,r){let n=[(0,Ql.stringToUint8Array)(`--${r}`,"utf-8"),...e.flatMap(s=>[(0,Ql.stringToUint8Array)(`\r
`,"utf-8"),(0,ll.stringToUint8Array)(mue(s.headers),"utf-8"),(0,ll.stringToUint8Array)(`\r `,"utf-8"),(0,Ql.stringToUint8Array)(ohe(s.headers),"utf-8"),(0,Ql.stringToUint8Array)(`\r
`,"utf-8"),s.body,(0,ll.stringToUint8Array)(`\r `,"utf-8"),s.body,(0,Ql.stringToUint8Array)(`\r
--${r}`,"utf-8")]),(0,ll.stringToUint8Array)(`--\r --${r}`,"utf-8")]),(0,Ql.stringToUint8Array)(`--\r
\r \r
`,"utf-8")],i=yue(n);i&&t.headers.set("Content-Length",i),t.body=await(0,hue.concat)(n)}ul.multipartPolicyName="multipartPolicy";var Cue=70,Iue=new Set("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");function Bue(t){if(t.length>Cue)throw new Error(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!Iue.has(e)))throw new Error(`Multipart boundary "${t}" contains invalid characters`)}function Que(){return{name:ul.multipartPolicyName,async sendRequest(t,e){var r;if(!t.multipartBody)return e(t);if(t.body)throw new Error("multipartBody and regular body cannot be set at the same time");let n=t.multipartBody.boundary,i=(r=t.headers.get("Content-Type"))!==null&&r!==void 0?r:"multipart/mixed",s=i.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!s)throw new Error(`Got multipart request body, but content-type header was not multipart: ${i}`);let[,o,a]=s;if(a&&n&&a!==n)throw new Error(`Multipart boundary was specified as ${a} in the header, but got ${n} in the request body`);return n??(n=a),n?Bue(n):n=gue(),t.headers.set("Content-Type",`${o}; boundary=${n}`),await Eue(t,t.multipartBody.parts,n),t.multipartBody=void 0,e(t)}}}});var Jq=h(pw=>{"use strict";Object.defineProperty(pw,"__esModule",{value:!0});pw.createPipelineFromOptions=Pue;var bue=HN(),Nue=RN(),wue=zN(),xue=YN(),Sue=JN(),vue=tw(),Rue=ow(),Gq=Nf(),Due=uw(),_ue=dw(),kue=fw(),Yq=mw();function Pue(t){let e=(0,Nue.createEmptyPipeline)();return Gq.isNodeLike&&(t.agent&&e.addPolicy((0,_ue.agentPolicy)(t.agent)),t.tlsOptions&&e.addPolicy((0,kue.tlsPolicy)(t.tlsOptions)),e.addPolicy((0,Due.proxyPolicy)(t.proxyOptions)),e.addPolicy((0,Sue.decompressResponsePolicy)())),e.addPolicy((0,Rue.formDataPolicy)(),{beforePolicies:[Yq.multipartPolicyName]}),e.addPolicy((0,xue.userAgentPolicy)(t.userAgentOptions)),e.addPolicy((0,Yq.multipartPolicy)(),{afterPhase:"Deserialize"}),e.addPolicy((0,vue.defaultRetryPolicy)(t.retryOptions),{phase:"Retry"}),Gq.isNodeLike&&e.addPolicy((0,wue.redirectPolicy)(t.redirectOptions),{afterPhase:"Retry"}),e.addPolicy((0,bue.logPolicy)(t.loggingOptions),{afterPhase:"Sign"}),e}});var Vq=h(dl=>{"use strict";Object.defineProperty(dl,"__esModule",{value:!0});dl.apiVersionPolicyName=void 0;dl.apiVersionPolicy=Tue;dl.apiVersionPolicyName="ApiVersionPolicy";function Tue(t){return{name:dl.apiVersionPolicyName,sendRequest:(e,r)=>{let n=new URL(e.url);return!n.searchParams.get("api-version")&&t.apiVersion&&(e.url=`${e.url}${Array.from(n.searchParams.keys()).length>0?"&":"?"}api-version=${t.apiVersion}`),r(e)}}}});var Wq=h(fl=>{"use strict";Object.defineProperty(fl,"__esModule",{value:!0});fl.isOAuth2TokenCredential=Oue;fl.isBearerTokenCredential=Mue;fl.isBasicCredential=Lue;fl.isApiKeyCredential=Fue;function Oue(t){return"getOAuth2Token"in t}function Mue(t){return"getBearerToken"in t}function Lue(t){return"username"in t&&"password"in t}function Fue(t){return"key"in t}});var Sf=h(yw=>{"use strict";Object.defineProperty(yw,"__esModule",{value:!0});yw.ensureSecureConnection=zue;var Uue=If(),$q=!1;function que(t,e){if(e.allowInsecureConnection&&t.allowInsecureConnection){let r=new URL(t.url);if(r.hostname==="localhost"||r.hostname==="127.0.0.1")return!0}return!1}function Hue(){let t="Sending token over insecure transport. Assume any token issued is compromised.";Uue.logger.warning(t),typeof(process==null?void 0:process.emitWarning)=="function"&&!$q&&($q=!0,process.emitWarning(t))}function zue(t,e){if(!t.url.toLowerCase().startsWith("https://"))if(que(t,e))Hue();else throw new Error("Authentication is not permitted for non-TLS protected (non-https) URLs when allowInsecureConnection is false.")}});var Kq=h(hl=>{"use strict";Object.defineProperty(hl,"__esModule",{value:!0});hl.apiKeyAuthenticationPolicyName=void 0;hl.apiKeyAuthenticationPolicy=Gue;var jue=Sf();hl.apiKeyAuthenticationPolicyName="apiKeyAuthenticationPolicy";function Gue(t){return{name:hl.apiKeyAuthenticationPolicyName,async sendRequest(e,r){var n,i;(0,jue.ensureSecureConnection)(e,t);let s=(i=(n=e.authSchemes)!==null&&n!==void 0?n:t.authSchemes)===null||i===void 0?void 0:i.find(o=>o.kind==="apiKey");if(!s)return r(e);if(s.apiKeyLocation!=="header")throw new Error(`Unsupported API key location: ${s.apiKeyLocation}`);return e.headers.set(s.name,t.credential.key),r(e)}}}});var Zq=h(gl=>{"use strict";Object.defineProperty(gl,"__esModule",{value:!0});gl.basicAuthenticationPolicyName=void 0;gl.basicAuthenticationPolicy=Jue;var Xq=Ya(),Yue=Sf();gl.basicAuthenticationPolicyName="bearerAuthenticationPolicy";function Jue(t){return{name:gl.basicAuthenticationPolicyName,async sendRequest(e,r){var n,i;if((0,Yue.ensureSecureConnection)(e,t),!((i=(n=e.authSchemes)!==null&&n!==void 0?n:t.authSchemes)===null||i===void 0?void 0:i.find(c=>c.kind==="http"&&c.scheme==="basic")))return r(e);let{username:o,password:a}=t.credential,A=(0,Xq.uint8ArrayToString)((0,Xq.stringToUint8Array)(`${o}:${a}`,"utf-8"),"base64");return e.headers.set("Authori Line truncated `,"utf-8")],i=Ahe(n);i&&t.headers.set("Content-Length",i),t.body=await(0,ihe.concat)(n)}bl.multipartPolicyName="multipartPolicy";var lhe=70,uhe=new Set("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'()+,-./:=?");function dhe(t){if(t.length>lhe)throw new Error(`Multipart boundary "${t}" exceeds maximum length of 70 characters`);if(Array.from(t).some(e=>!uhe.has(e)))throw new Error(`Multipart boundary "${t}" contains invalid characters`)}function fhe(){return{name:bl.multipartPolicyName,async sendRequest(t,e){var r;if(!t.multipartBody)return e(t);if(t.body)throw new Error("multipartBody and regular body cannot be set at the same time");let n=t.multipartBody.boundary,i=(r=t.headers.get("Content-Type"))!==null&&r!==void 0?r:"multipart/mixed",s=i.match(/^(multipart\/[^ ;]+)(?:; *boundary=(.+))?$/);if(!s)throw new Error(`Got multipart request body, but content-type header was not multipart: ${i}`);let[,o,a]=s;if(a&&n&&a!==n)throw new Error(`Multipart boundary was specified as ${a} in the header, but got ${n} in the request body`);return n??(n=a),n?dhe(n):n=she(),t.headers.set("Content-Type",`${o}; boundary=${n}`),await che(t,t.multipartBody.parts,n),t.multipartBody=void 0,e(t)}}}});var Y2=h(Jw=>{"use strict";Object.defineProperty(Jw,"__esModule",{value:!0});Jw.createPipelineFromOptions=bhe;var hhe=yw(),ghe=ow(),mhe=Ew(),phe=Bw(),yhe=Qw(),Ehe=Dw(),Che=Ow(),z2=Uf(),Ihe=qw(),Bhe=Hw(),Qhe=jw(),G2=Yw();function bhe(t){let e=(0,ghe.createEmptyPipeline)();return z2.isNodeLike&&(t.agent&&e.addPolicy((0,Bhe.agentPolicy)(t.agent)),t.tlsOptions&&e.addPolicy((0,Qhe.tlsPolicy)(t.tlsOptions)),e.addPolicy((0,Ihe.proxyPolicy)(t.proxyOptions)),e.addPolicy((0,yhe.decompressResponsePolicy)())),e.addPolicy((0,Che.formDataPolicy)(),{beforePolicies:[G2.multipartPolicyName]}),e.addPolicy((0,phe.userAgentPolicy)(t.userAgentOptions)),e.addPolicy((0,G2.multipartPolicy)(),{afterPhase:"Deserialize"}),e.addPolicy((0,Ehe.defaultRetryPolicy)(t.retryOptions),{phase:"Retry"}),z2.isNodeLike&&e.addPolicy((0,mhe.redirectPolicy)(t.redirectOptions),{afterPhase:"Retry"}),e.addPolicy((0,hhe.logPolicy)(t.loggingOptions),{afterPhase:"Sign"}),e}});var J2=h(Nl=>{"use strict";Object.defineProperty(Nl,"__esModule",{value:!0});Nl.apiVersionPolicyName=void 0;Nl.apiVersionPolicy=Nhe;Nl.apiVersionPolicyName="ApiVersionPolicy";function Nhe(t){return{name:Nl.apiVersionPolicyName,sendRequest:(e,r)=>{let n=new URL(e.url);return!n.searchParams.get("api-version")&&t.apiVersion&&(e.url=`${e.url}${Array.from(n.searchParams.keys()).length>0?"&":"?"}api-version=${t.apiVersion}`),r(e)}}}});var V2=h(wl=>{"use strict";Object.defineProperty(wl,"__esModule",{value:!0});wl.isOAuth2TokenCredential=whe;wl.isBearerTokenCredential=xhe;wl.isBasicCredential=She;wl.isApiKeyCredential=Rhe;function whe(t){return"getOAuth2Token"in t}function xhe(t){return"getBearerToken"in t}function She(t){return"username"in t&&"password"in t}function Rhe(t){return"key"in t}});var jf=h(Vw=>{"use strict";Object.defineProperty(Vw,"__esModule",{value:!0});Vw.ensureSecureConnection=khe;var vhe=Of(),W2=!1;function Dhe(t,e){if(e.allowInsecureConnection&&t.allowInsecureConnection){let r=new URL(t.url);if(r.hostname==="localhost"||r.hostname==="127.0.0.1")return!0}return!1}function _he(){let t="Sending token over insecure transport. Assume any token issued is compromised.";vhe.logger.warning(t),typeof(process==null?void 0:process.emitWarning)=="function"&&!W2&&(W2=!0,process.emitWarning(t))}function khe(t,e){if(!t.url.toLowerCase().startsWith("https://"))if(Dhe(t,e))_he();else throw new Error("Authentication is not permitted for non-TLS protected (non-https) URLs when allowInsecureConnection is false.")}});var $2=h(xl=>{"use strict";Object.defineProperty(xl,"__esModule",{value:!0});xl.apiKeyAuthenticationPolicyName=void 0;xl.apiKeyAuthenticationPolicy=The;var Phe=jf();xl.apiKeyAuthenticationPolicyName="apiKeyAuthenticationPolicy";function The(t){return{name:xl.apiKeyAuthenticationPolicyName,async sendRequest(e,r){var n,i;(0,Phe.ensureSecureConnection)(e,t);let s=(i=(n=e.authSchemes)!==null&&n!==void 0?n:t.authSchemes)===null||i===void 0?void 0:i.find(o=>o.kind==="apiKey");if(!s)return r(e);if(s.apiKeyLocation!=="header")throw new Error(`Unsupported API key location: ${s.apiKeyLocation}`);return e.headers.set(s.name,t.credential.key),r(e)}}}});var X2=h(Sl=>{"use strict";Object.defineProperty(Sl,"__esModule",{value:!0});Sl.basicAuthenticationPolicyName=void 0;Sl.basicAuthenticationPolicy=Lhe;var K2=oA(),Ohe=jf();Sl.basicAuthenticationPolicyName="bearerAuthenticationPolicy";function Lhe(t){return{name:Sl.basicAuthenticationPolicyName,async sendRequest(e,r){var n,i;if((0,Ohe.ensureSecureConnection)(e,t),!((i=(n=e.authSchemes)!==null&&n!==void 0?n:t.authSchemes)===null||i===void 0?void 0:i.find(c=>c.kind==="http"&&c.scheme==="basic")))return r(e);let{username:o,password:a}=t.credential,A=(0,K2.uint8ArrayToString)((0,K2.stringToUint8Array)(`${o}:${a}`,"utf-8"),"base64");return e.headers.set("Authori Line truncated
`).join(""))}return e(t)}}}});var PH=h(Za=>{"use strict";Object.defineProperty(Za,"__esModule",{value:!0});Za.auxiliaryAuthenticationHeaderPolicyName=void 0;Za.auxiliaryAuthenticationHeaderPolicy=bge;var Ige=hx(),Bge=Rf();Za.auxiliaryAuthenticationHeaderPolicyName="auxiliaryAuthenticationHeaderPolicy";var kH="x-ms-authorization-auxiliary";async function Qge(t){var e,r;let{scopes:n,getAccessToken:i,request:s}=t,o={abortSignal:s.abortSignal,tracingOptions:s.tracingOptions};return(r=(e=await i(n,o))===null||e===void 0?void 0:e.token)!==null&&r!==void 0?r:""}function bge(t){let{credentials:e,scopes:r}=t,n=t.logger||Bge.logger,i=new WeakMap;return{name:Za.auxiliaryAuthenticationHeaderPolicyName,async sendRequest(s,o){if(!s.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication for auxiliary header is not permitted for non-TLS protected (non-https) URLs.");if(!e||e.length===0)return n.info(`${Za.auxiliaryAuthenticationHeaderPolicyName} header will not be set due to empty credentials.`),o(s);let a=[];for(let c of e){let l=i.get(c);l||(l=(0,Ige.createTokenCycler)(c),i.set(c,l)),a.push(Qge({scopes:Array.isArray(r)?r:[r],request:s,getAccessToken:l,logger:n}))}let A=(await Promise.all(a)).filter(c=>!!c);return A.length===0?(n.warning(`None of the auxiliary tokens are valid. ${kH} header will not be set.`),o(s)):(s.headers.set(kH,A.map(c=>`Bearer ${c}`).join(", ")),o(s))}}}});var zs=h(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});M.createFileFromStream=M.createFile=M.agentPolicyName=M.agentPolicy=M.auxiliaryAuthenticationHeaderPolicyName=M.auxiliaryAuthenticationHeaderPolicy=M.ndJsonPolicyName=M.ndJsonPolicy=M.bearerTokenAuthenticationPolicyName=M.bearerTokenAuthenticationPolicy=M.formDataPolicyName=M.formDataPolicy=M.tlsPolicyName=M.tlsPolicy=M.userAgentPolicyName=M.userAgentPolicy=M.defaultRetryPolicy=M.tracingPolicyName=M.tracingPolicy=M.retryPolicy=M.throttlingRetryPolicyName=M.throttlingRetryPolicy=M.systemErrorRetryPolicyName=M.systemErrorRetryPolicy=M.redirectPolicyName=M.redirectPolicy=M.getDefaultProxySettings=M.proxyPolicyName=M.proxyPolicy=M.multipartPolicyName=M.multipartPolicy=M.logPolicyName=M.logPolicy=M.setClientRequestIdPolicyName=M.setClientRequestIdPolicy=M.exponentialRetryPolicyName=M.exponentialRetryPolicy=M.decompressResponsePolicyName=M.decompressResponsePolicy=M.isRestError=M.RestError=M.createPipelineRequest=M.createHttpHeaders=M.createDefaultHttpClient=M.createPipelineFromOptions=M.createEmptyPipeline=void 0;var Nge=vw();Object.defineProperty(M,"createEmptyPipeline",{enumerable:!0,get:function(){return Nge.createEmptyPipeline}});var wge=mH();Object.defineProperty(M,"createPipelineFromOptions",{enumerable:!0,get:function(){return wge.createPipelineFromOptions}});var xge=pH();Object.defineProperty(M,"createDefaultHttpClient",{enumerable:!0,get:function(){return xge.createDefaultHttpClient}});var Sge=yH();Object.defineProperty(M,"createHttpHeaders",{enumerable:!0,get:function(){return Sge.createHttpHeaders}});var vge=EH();Object.defineProperty(M,"createPipelineRequest",{enumerable:!0,get:function(){return vge.createPipelineRequest}});var TH=Vy();Object.defineProperty(M,"RestError",{enumerable:!0,get:function(){return TH.RestError}});Object.defineProperty(M,"isRestError",{enumerable:!0,get:function(){return TH.isRestError}});var OH=Jw();Object.defineProperty(M,"decompressResponsePolicy",{enumerable:!0,get:function(){return OH.decompressResponsePolicy}});Object.defineProperty(M,"decompressResponsePolicyName",{enumerable:!0,get:function(){return OH.decompressResponsePolicyName}});var MH=IH();Object.defineProperty(M,"exponentialRetryPolicy",{enumerable:!0,get:function(){return MH.exponentialRetryPolicy}});Object.defineProperty(M,"exponentialRetryPolicyName",{enumerable:!0,get:function(){return MH.exponentialRetryPolicyName}});var LH=Xw();Object.defineProperty(M,"setClientRequestIdPolicy",{enumerable:!0,get:function(){return LH.setClientRequestIdPolicy}});Object.defineProperty(M,"setClientRequestIdPolicyName",{enumerable:!0,get:function(){return LH.setClientRequestIdPolicyName}});var FH=Dw();Object.defineProperty(M,"logPolicy",{enumerable:!0,get:function(){return FH.logPolicy}});Object.defineProperty(M,"logPolicyName",{enumerable:!0,get:function(){return FH.logPolicyName}});var UH=Yw();Object.defineProperty(M,"multipartPolicy",{enumerable:!0,get:function(){return UH.multipartPolicy}});Object.defineProperty(M,"multipartPolicyName",{enumerable:!0,get:function(){return UH.multipartPolicyName}});var gx=Kw();Object.defineProperty(M,"proxyPolicy",{enumerable:!0,get:function(){return gx.proxyPolicy}});Object.defineProperty(M,"proxyPolicyName",{enumerable:!0,get:function(){return gx.proxyPolicyName}});Object.defineProperty(M,"getDefaultProxySettings",{enumerable:!0,get:function(){return gx.getDefaultProxySettings}});var qH=_w();Object.defineProperty(M,"redirectPolicy",{enumerable:!0,get:function(){return qH.redirectPolicy}});Object.defineProperty(M,"redirect Line truncated `).join(""))}return e(t)}}}});var kj=h(fA=>{"use strict";Object.defineProperty(fA,"__esModule",{value:!0});fA.auxiliaryAuthenticationHeaderPolicyName=void 0;fA.auxiliaryAuthenticationHeaderPolicy=hye;var uye=zx(),dye=Gf();fA.auxiliaryAuthenticationHeaderPolicyName="auxiliaryAuthenticationHeaderPolicy";var _j="x-ms-authorization-auxiliary";async function fye(t){var e,r;let{scopes:n,getAccessToken:i,request:s}=t,o={abortSignal:s.abortSignal,tracingOptions:s.tracingOptions};return(r=(e=await i(n,o))===null||e===void 0?void 0:e.token)!==null&&r!==void 0?r:""}function hye(t){let{credentials:e,scopes:r}=t,n=t.logger||dye.logger,i=new WeakMap;return{name:fA.auxiliaryAuthenticationHeaderPolicyName,async sendRequest(s,o){if(!s.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication for auxiliary header is not permitted for non-TLS protected (non-https) URLs.");if(!e||e.length===0)return n.info(`${fA.auxiliaryAuthenticationHeaderPolicyName} header will not be set due to empty credentials.`),o(s);let a=[];for(let c of e){let l=i.get(c);l||(l=(0,uye.createTokenCycler)(c),i.set(c,l)),a.push(fye({scopes:Array.isArray(r)?r:[r],request:s,getAccessToken:l,logger:n}))}let A=(await Promise.all(a)).filter(c=>!!c);return A.length===0?(n.warning(`None of the auxiliary tokens are valid. ${_j} header will not be set.`),o(s)):(s.headers.set(_j,A.map(c=>`Bearer ${c}`).join(", ")),o(s))}}}});var eo=h(L=>{"use strict";Object.defineProperty(L,"__esModule",{value:!0});L.createFileFromStream=L.createFile=L.agentPolicyName=L.agentPolicy=L.auxiliaryAuthenticationHeaderPolicyName=L.auxiliaryAuthenticationHeaderPolicy=L.ndJsonPolicyName=L.ndJsonPolicy=L.bearerTokenAuthenticationPolicyName=L.bearerTokenAuthenticationPolicy=L.formDataPolicyName=L.formDataPolicy=L.tlsPolicyName=L.tlsPolicy=L.userAgentPolicyName=L.userAgentPolicy=L.defaultRetryPolicy=L.tracingPolicyName=L.tracingPolicy=L.retryPolicy=L.throttlingRetryPolicyName=L.throttlingRetryPolicy=L.systemErrorRetryPolicyName=L.systemErrorRetryPolicy=L.redirectPolicyName=L.redirectPolicy=L.getDefaultProxySettings=L.proxyPolicyName=L.proxyPolicy=L.multipartPolicyName=L.multipartPolicy=L.logPolicyName=L.logPolicy=L.setClientRequestIdPolicyName=L.setClientRequestIdPolicy=L.exponentialRetryPolicyName=L.exponentialRetryPolicy=L.decompressResponsePolicyName=L.decompressResponsePolicy=L.isRestError=L.RestError=L.createPipelineRequest=L.createHttpHeaders=L.createDefaultHttpClient=L.createPipelineFromOptions=L.createEmptyPipeline=void 0;var gye=sx();Object.defineProperty(L,"createEmptyPipeline",{enumerable:!0,get:function(){return gye.createEmptyPipeline}});var mye=gj();Object.defineProperty(L,"createPipelineFromOptions",{enumerable:!0,get:function(){return mye.createPipelineFromOptions}});var pye=mj();Object.defineProperty(L,"createDefaultHttpClient",{enumerable:!0,get:function(){return pye.createDefaultHttpClient}});var yye=pj();Object.defineProperty(L,"createHttpHeaders",{enumerable:!0,get:function(){return yye.createHttpHeaders}});var Eye=yj();Object.defineProperty(L,"createPipelineRequest",{enumerable:!0,get:function(){return Eye.createPipelineRequest}});var Pj=hE();Object.defineProperty(L,"RestError",{enumerable:!0,get:function(){return Pj.RestError}});Object.defineProperty(L,"isRestError",{enumerable:!0,get:function(){return Pj.isRestError}});var Tj=Qx();Object.defineProperty(L,"decompressResponsePolicy",{enumerable:!0,get:function(){return Tj.decompressResponsePolicy}});Object.defineProperty(L,"decompressResponsePolicyName",{enumerable:!0,get:function(){return Tj.decompressResponsePolicyName}});var Oj=Cj();Object.defineProperty(L,"exponentialRetryPolicy",{enumerable:!0,get:function(){return Oj.exponentialRetryPolicy}});Object.defineProperty(L,"exponentialRetryPolicyName",{enumerable:!0,get:function(){return Oj.exponentialRetryPolicyName}});var Lj=Sx();Object.defineProperty(L,"setClientRequestIdPolicy",{enumerable:!0,get:function(){return Lj.setClientRequestIdPolicy}});Object.defineProperty(L,"setClientRequestIdPolicyName",{enumerable:!0,get:function(){return Lj.setClientRequestIdPolicyName}});var Mj=ax();Object.defineProperty(L,"logPolicy",{enumerable:!0,get:function(){return Mj.logPolicy}});Object.defineProperty(L,"logPolicyName",{enumerable:!0,get:function(){return Mj.logPolicyName}});var Fj=Bx();Object.defineProperty(L,"multipartPolicy",{enumerable:!0,get:function(){return Fj.multipartPolicy}});Object.defineProperty(L,"multipartPolicyName",{enumerable:!0,get:function(){return Fj.multipartPolicyName}});var Gx=xx();Object.defineProperty(L,"proxyPolicy",{enumerable:!0,get:function(){return Gx.proxyPolicy}});Object.defineProperty(L,"proxyPolicyName",{enumerable:!0,get:function(){return Gx.proxyPolicyName}});Object.defineProperty(L,"getDefaultProxySettings",{enumerable:!0,get:function(){return Gx.getDefaultProxySettings}});var Uj=Ax();Object.defineProperty(L,"redirectPolicy",{enumerable:!0,get:function(){return Uj.redirectPolicy}});Object.defineProperty(L,"redirect Line truncated
`&&p[b]!=="\r";b++)P+=p[b];if(P=P.trim(),P[P.length-1]==="/"&&(P=P.substring(0,P.length-1),b--),!s(P)){let ae;return ae=P.trim().length===0?"Invalid space after '<'.":"Tag '"+P+"' is an invalid name.",C("InvalidTag",ae,N(p,b))}let j=f(p,b);if(j===!1)return C("InvalidAttr","Attributes for '"+P+"' have open quote.",N(p,b));let ye=j.value;if(b=j.index,ye[ye.length-1]==="/"){let ae=b-ye.length;ye=ye.substring(0,ye.length-1);let Le=m(ye,y);if(Le!==!0)return C(Le.err.code,Le.err.msg,N(p,ae+Le.err.line));x=!0}else if(v){if(!j.tagClosed)return C("InvalidTag","Closing tag '"+P+"' doesn't have proper closing.",N(p,b));if(ye.trim().length>0)return C("InvalidTag","Closing tag '"+P+"' can't have attributes or invalid starting.",N(p,D));if(B.length===0)return C("InvalidTag","Closing tag '"+P+"' has not been opened.",N(p,D));{let ae=B.pop();if(P!==ae.tagName){let Le=N(p,ae.tagStartPos);return C("InvalidTag","Expected closing tag '"+ae.tagName+"' (opened in line "+Le.line+", col "+Le.col+") instead of closing tag '"+P+"'.",N(p,D))}B.length==0&&(Q=!0)}}else{let ae=m(ye,y);if(ae!==!0)return C(ae.err.code,ae.err.msg,N(p,b-ye.length+ae.err.line));if(Q===!0)return C("InvalidXml","Multiple possible root nodes found.",N(p,b));y.unpairedTags.indexOf(P)!==-1||B.push({tagName:P,tagStartPos:D}),x=!0}for(b++;b<p.length;b++)if(p[b]==="<"){if(p[b+1]==="!"){b++,b=l(p,b);continue}if(p[b+1]!=="?")break;if(b=c(p,++b),b.err)return b}else if(p[b]==="&"){let ae=E(p,b);if(ae==-1)return C("InvalidChar","char '&' is not expected.",N(p,b));b=ae}else if(Q===!0&&!A(p[b]))return C("InvalidXml","Extra text at the end",N(p,b));p[b]==="<"&&b--}}}return x?B.length==1?C("InvalidTag","Unclosed tag '"+B[0].tagName+"'.",N(p,B[0].tagStartPos)):!(B.length>0)||C("InvalidXml","Invalid '"+JSON.stringify(B.map((b=>b.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):C("InvalidXml","Start tag expected.",1)}function A(p){return p===" "||p===" "||p===` `&&p[N]!=="\r";N++)P+=p[N];if(P=P.trim(),P[P.length-1]==="/"&&(P=P.substring(0,P.length-1),N--),!s(P)){let ce;return ce=P.trim().length===0?"Invalid space after '<'.":"Tag '"+P+"' is an invalid name.",C("InvalidTag",ce,b(p,N))}let z=f(p,N);if(z===!1)return C("InvalidAttr","Attributes for '"+P+"' have open quote.",b(p,N));let Ce=z.value;if(N=z.index,Ce[Ce.length-1]==="/"){let ce=N-Ce.length;Ce=Ce.substring(0,Ce.length-1);let qe=m(Ce,y);if(qe!==!0)return C(qe.err.code,qe.err.msg,b(p,ce+qe.err.line));x=!0}else if(R){if(!z.tagClosed)return C("InvalidTag","Closing tag '"+P+"' doesn't have proper closing.",b(p,N));if(Ce.trim().length>0)return C("InvalidTag","Closing tag '"+P+"' can't have attributes or invalid starting.",b(p,D));if(B.length===0)return C("InvalidTag","Closing tag '"+P+"' has not been opened.",b(p,D));{let ce=B.pop();if(P!==ce.tagName){let qe=b(p,ce.tagStartPos);return C("InvalidTag","Expected closing tag '"+ce.tagName+"' (opened in line "+qe.line+", col "+qe.col+") instead of closing tag '"+P+"'.",b(p,D))}B.length==0&&(Q=!0)}}else{let ce=m(Ce,y);if(ce!==!0)return C(ce.err.code,ce.err.msg,b(p,N-Ce.length+ce.err.line));if(Q===!0)return C("InvalidXml","Multiple possible root nodes found.",b(p,N));y.unpairedTags.indexOf(P)!==-1||B.push({tagName:P,tagStartPos:D}),x=!0}for(N++;N<p.length;N++)if(p[N]==="<"){if(p[N+1]==="!"){N++,N=l(p,N);continue}if(p[N+1]!=="?")break;if(N=c(p,++N),N.err)return N}else if(p[N]==="&"){let ce=E(p,N);if(ce==-1)return C("InvalidChar","char '&' is not expected.",b(p,N));N=ce}else if(Q===!0&&!A(p[N]))return C("InvalidXml","Extra text at the end",b(p,N));p[N]==="<"&&N--}}}return x?B.length==1?C("InvalidTag","Unclosed tag '"+B[0].tagName+"'.",b(p,B[0].tagStartPos)):!(B.length>0)||C("InvalidXml","Invalid '"+JSON.stringify(B.map((N=>N.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):C("InvalidXml","Start tag expected.",1)}function A(p){return p===" "||p===" "||p===`
`||p==="\r"}function c(p,y){let B=y;for(;y<p.length;y++)if(!(p[y]!="?"&&p[y]!=" ")){let x=p.substr(B,y-B);if(y>5&&x==="xml")return C("InvalidXml","XML declaration allowed only at the start of the document.",N(p,y));if(p[y]=="?"&&p[y+1]==">"){y++;break}}return y}function l(p,y){if(p.length>y+5&&p[y+1]==="-"&&p[y+2]==="-"){for(y+=3;y<p.length;y++)if(p[y]==="-"&&p[y+1]==="-"&&p[y+2]===">"){y+=2;break}}else if(p.length>y+8&&p[y+1]==="D"&&p[y+2]==="O"&&p[y+3]==="C"&&p[y+4]==="T"&&p[y+5]==="Y"&&p[y+6]==="P"&&p[y+7]==="E"){let B=1;for(y+=8;y<p.length;y++)if(p[y]==="<")B++;else if(p[y]===">"&&(B--,B===0))break}else if(p.length>y+9&&p[y+1]==="["&&p[y+2]==="C"&&p[y+3]==="D"&&p[y+4]==="A"&&p[y+5]==="T"&&p[y+6]==="A"&&p[y+7]==="["){for(y+=8;y<p.length;y++)if(p[y]==="]"&&p[y+1]==="]"&&p[y+2]===">"){y+=2;break}}return y}let u='"',d="'";function f(p,y){let B="",x="",Q=!1;for(;y<p.length;y++){if(p[y]===u||p[y]===d)x===""?x=p[y]:x!==p[y]||(x="");else if(p[y]===">"&&x===""){Q=!0;break}B+=p[y]}return x===""&&{value:B,index:y,tagClosed:Q}}let g=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function m(p,y){let B=i(p,g),x={};for(let Q=0;Q<B.length;Q++){if(B[Q][1].length===0)return C("InvalidAttr","Attribute '"+B[Q][2]+"' has no space in starting.",w(B[Q]));if(B[Q][3]!==void 0&&B[Q][4]===void 0)return C("InvalidAttr","Attribute '"+B[Q][2]+"' is without value.",w(B[Q]));if(B[Q][3]===void 0&&!y.allowBooleanAttributes)return C("InvalidAttr","boolean attribute '"+B[Q][2]+"' is not allowed.",w(B[Q]));let b=B[Q][2];if(!I(b))return C("InvalidAttr","Attribute '"+b+"' is an invalid name.",w(B[Q]));if(x.hasOwnProperty(b))return C("InvalidAttr","Attribute '"+b+"' is repeated.",w(B[Q]));x[b]=1}return!0}function E(p,y){if(p[++y]===";")return-1;if(p[y]==="#")return(function(x,Q){let b=/\d/;for(x[Q]==="x"&&(Q++,b=/[\da-fA-F]/);Q<x.length;Q++){if(x[Q]===";")return Q;if(!x[Q].match(b))break}return-1})(p,++y);let B=0;for(;y<p.length;y++,B++)if(!(p[y].match(/\w/)&&B<20)){if(p[y]===";")break;return-1}return y}function C(p,y,B){return{err:{code:p,msg:y,line:B.line||B,col:B.col}}}function I(p){return s(p)}function N(p,y){let B=p.substring(0,y).split(/\r?\n/);return{line:B.length,col:B[B.length-1].length+1}}function w(p){return p.startIndex+p[1].length}let R={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(p,y){return y},attributeValueProcessor:function(p,y){return y},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(p,y,B){return p},captureMetaData:!1},T;T=typeof Symbol!="function"?"@@xmlMetadata":Symbol("XML Node Metadata");class U{constructor(y){this.tagname=y,this.child=[],this[":@"]={}}add(y,B){y==="__proto__"&&(y="#__proto__"),this.child.push({[y]:B})}addChild(y,B){y.tagname==="__proto__"&&(y.tagname="#__proto__"),y[":@"]&&Object.keys(y[":@"]).length>0?this.child.push({[y.tagname]:y.child,":@":y[":@"]}):this.child.push({[y.tagname]:y.child}),B!==void 0&&(this.child[this.child.length-1][T]={startIndex:B})}static getMetaDataSymbol(){return T}}function k(p,y){let B={};if(p[y+3]!=="O"||p[y+4]!=="C"||p[y+5]!=="T"||p[y+6]!=="Y"||p[y+7]!=="P"||p[y+8]!=="E")throw new Error("Invalid Tag instead of DOCTYPE");{y+=9;let x=1,Q=!1,b=!1,D="";for(;y<p.length;y++)if(p[y]!=="<"||b)if(p[y]===">"){if(b?p[y-1]==="-"&&p[y-2]==="-"&&(b=!1,x--):x--,x===0)break}else p[y]==="["?Q=!0:D+=p[y];else{if(Q&&tt(p,"!ENTITY",y)){let v,P;y+=7,[v,P,y]=Qe(p,y+1),P.indexOf("&")===-1&&(B[v]={regx:RegExp(`&${v};`,"g"),val:P})}else if(Q&&tt(p,"!ELEMENT",y)){y+=8;let{index:v}=Re(p,y+1);y=v}else if(Q&&tt(p,"!ATTLIST",y))y+=8;else if(Q&&tt(p,"!NOTATION",y)){y+=9;let{index:v}=Se(p,y+1);y=v}else{if(!tt(p,"!--",y))throw new Error("Invalid DOCTYPE");b=!0}x++,D=""}if(x!==0)throw new Error("Unclosed DOCTYPE")}return{entities:B,i:y}}let J=(p,y)=>{for(;y<p.length&&/\s/.test(p[y]);)y++;return y};function Qe(p,y){y=J(p,y);let B="";for(;y<p.length&&!/\s/.test(p[y])&&p[y]!=='"'&&p[y]!=="'";)B+=p[y],y++;if(Rr(B),y=J(p,y),p.substring(y,y+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(p[y]==="%")throw new Error("Parameter entities are not supported");let x="";return[y,x]=H(p,y,"entity"),[B,x,--y]}function Se(p,y){y=J(p,y);let B="";for(;y<p.length&&!/\s/.test(p[y]);)B+=p[y],y++;Rr(B),y=J(p,y);let x=p.substring(y,y+6).toUpperCase();if(x!=="SYSTEM"&&x!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${x}"`);y+=x.length,y=J(p,y);let Q=null,b=null;if(x==="PUBLIC")[y,Q]=H(p,y,"publicIdentifier"),p[y=J(p,y)]!=='"'&&p[y]!=="'"||([y,b]=H(p,y,"systemIdentifier"));else if(x==="SYSTEM"&&([y,b]=H(p,y,"systemIdentifieLine truncated `||p==="\r"}function c(p,y){let B=y;for(;y<p.length;y++)if(!(p[y]!="?"&&p[y]!=" ")){let x=p.substr(B,y-B);if(y>5&&x==="xml")return C("InvalidXml","XML declaration allowed only at the start of the document.",b(p,y));if(p[y]=="?"&&p[y+1]==">"){y++;break}}return y}function l(p,y){if(p.length>y+5&&p[y+1]==="-"&&p[y+2]==="-"){for(y+=3;y<p.length;y++)if(p[y]==="-"&&p[y+1]==="-"&&p[y+2]===">"){y+=2;break}}else if(p.length>y+8&&p[y+1]==="D"&&p[y+2]==="O"&&p[y+3]==="C"&&p[y+4]==="T"&&p[y+5]==="Y"&&p[y+6]==="P"&&p[y+7]==="E"){let B=1;for(y+=8;y<p.length;y++)if(p[y]==="<")B++;else if(p[y]===">"&&(B--,B===0))break}else if(p.length>y+9&&p[y+1]==="["&&p[y+2]==="C"&&p[y+3]==="D"&&p[y+4]==="A"&&p[y+5]==="T"&&p[y+6]==="A"&&p[y+7]==="["){for(y+=8;y<p.length;y++)if(p[y]==="]"&&p[y+1]==="]"&&p[y+2]===">"){y+=2;break}}return y}let u='"',d="'";function f(p,y){let B="",x="",Q=!1;for(;y<p.length;y++){if(p[y]===u||p[y]===d)x===""?x=p[y]:x!==p[y]||(x="");else if(p[y]===">"&&x===""){Q=!0;break}B+=p[y]}return x===""&&{value:B,index:y,tagClosed:Q}}let g=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function m(p,y){let B=i(p,g),x={};for(let Q=0;Q<B.length;Q++){if(B[Q][1].length===0)return C("InvalidAttr","Attribute '"+B[Q][2]+"' has no space in starting.",w(B[Q]));if(B[Q][3]!==void 0&&B[Q][4]===void 0)return C("InvalidAttr","Attribute '"+B[Q][2]+"' is without value.",w(B[Q]));if(B[Q][3]===void 0&&!y.allowBooleanAttributes)return C("InvalidAttr","boolean attribute '"+B[Q][2]+"' is not allowed.",w(B[Q]));let N=B[Q][2];if(!I(N))return C("InvalidAttr","Attribute '"+N+"' is an invalid name.",w(B[Q]));if(x.hasOwnProperty(N))return C("InvalidAttr","Attribute '"+N+"' is repeated.",w(B[Q]));x[N]=1}return!0}function E(p,y){if(p[++y]===";")return-1;if(p[y]==="#")return(function(x,Q){let N=/\d/;for(x[Q]==="x"&&(Q++,N=/[\da-fA-F]/);Q<x.length;Q++){if(x[Q]===";")return Q;if(!x[Q].match(N))break}return-1})(p,++y);let B=0;for(;y<p.length;y++,B++)if(!(p[y].match(/\w/)&&B<20)){if(p[y]===";")break;return-1}return y}function C(p,y,B){return{err:{code:p,msg:y,line:B.line||B,col:B.col}}}function I(p){return s(p)}function b(p,y){let B=p.substring(0,y).split(/\r?\n/);return{line:B.length,col:B[B.length-1].length+1}}function w(p){return p.startIndex+p[1].length}let v={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(p,y){return y},attributeValueProcessor:function(p,y){return y},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(p,y,B){return p},captureMetaData:!1},T;T=typeof Symbol!="function"?"@@xmlMetadata":Symbol("XML Node Metadata");class U{constructor(y){this.tagname=y,this.child=[],this[":@"]={}}add(y,B){y==="__proto__"&&(y="#__proto__"),this.child.push({[y]:B})}addChild(y,B){y.tagname==="__proto__"&&(y.tagname="#__proto__"),y[":@"]&&Object.keys(y[":@"]).length>0?this.child.push({[y.tagname]:y.child,":@":y[":@"]}):this.child.push({[y.tagname]:y.child}),B!==void 0&&(this.child[this.child.length-1][T]={startIndex:B})}static getMetaDataSymbol(){return T}}function k(p,y){let B={};if(p[y+3]!=="O"||p[y+4]!=="C"||p[y+5]!=="T"||p[y+6]!=="Y"||p[y+7]!=="P"||p[y+8]!=="E")throw new Error("Invalid Tag instead of DOCTYPE");{y+=9;let x=1,Q=!1,N=!1,D="";for(;y<p.length;y++)if(p[y]!=="<"||N)if(p[y]===">"){if(N?p[y-1]==="-"&&p[y-2]==="-"&&(N=!1,x--):x--,x===0)break}else p[y]==="["?Q=!0:D+=p[y];else{if(Q&&it(p,"!ENTITY",y)){let R,P;y+=7,[R,P,y]=we(p,y+1),P.indexOf("&")===-1&&(B[R]={regx:RegExp(`&${R};`,"g"),val:P})}else if(Q&&it(p,"!ELEMENT",y)){y+=8;let{index:R}=ke(p,y+1);y=R}else if(Q&&it(p,"!ATTLIST",y))y+=8;else if(Q&&it(p,"!NOTATION",y)){y+=9;let{index:R}=De(p,y+1);y=R}else{if(!it(p,"!--",y))throw new Error("Invalid DOCTYPE");N=!0}x++,D=""}if(x!==0)throw new Error("Unclosed DOCTYPE")}return{entities:B,i:y}}let J=(p,y)=>{for(;y<p.length&&/\s/.test(p[y]);)y++;return y};function we(p,y){y=J(p,y);let B="";for(;y<p.length&&!/\s/.test(p[y])&&p[y]!=='"'&&p[y]!=="'";)B+=p[y],y++;if(Lr(B),y=J(p,y),p.substring(y,y+6).toUpperCase()==="SYSTEM")throw new Error("External entities are not supported");if(p[y]==="%")throw new Error("Parameter entities are not supported");let x="";return[y,x]=H(p,y,"entity"),[B,x,--y]}function De(p,y){y=J(p,y);let B="";for(;y<p.length&&!/\s/.test(p[y]);)B+=p[y],y++;Lr(B),y=J(p,y);let x=p.substring(y,y+6).toUpperCase();if(x!=="SYSTEM"&&x!=="PUBLIC")throw new Error(`Expected SYSTEM or PUBLIC, found "${x}"`);y+=x.length,y=J(p,y);let Q=null,N=null;if(x==="PUBLIC")[y,Q]=H(p,y,"publicIdentifier"),p[y=J(p,y)]!=='"'&&p[y]!=="'"||([y,N]=H(p,y,"systemIdentifier"));else if(x==="SYSTEM"&&([y,N]=H(p,y,"systemIdentifieLine truncated
`);let y=new U("!xml"),B=y,x="",Q="";for(let b=0;b<p.length;b++)if(p[b]==="<")if(p[b+1]==="/"){let D=ya(p,">",b,"Closing Tag is not closed."),v=p.substring(b+2,D).trim();if(this.options.removeNSPrefix){let ye=v.indexOf(":");ye!==-1&&(v=v.substr(ye+1))}this.options.transformTagName&&(v=this.options.transformTagName(v)),B&&(x=this.saveTextToParentTag(x,B,Q));let P=Q.substring(Q.lastIndexOf(".")+1);if(v&&this.options.unpairedTags.indexOf(v)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${v}>`);let j=0;P&&this.options.unpairedTags.indexOf(P)!==-1?(j=Q.lastIndexOf(".",Q.lastIndexOf(".")-1),this.tagsNodeStack.pop()):j=Q.lastIndexOf("."),Q=Q.substring(0,j),B=this.tagsNodeStack.pop(),x="",b=D}else if(p[b+1]==="?"){let D=fB(p,b,!1,"?>");if(!D)throw new Error("Pi Tag is not closed.");if(x=this.saveTextToParentTag(x,B,Q),!(this.options.ignoreDeclaration&&D.tagName==="?xml"||this.options.ignorePiTags)){let v=new U(D.tagName);v.add(this.options.textNodeName,""),D.tagName!==D.tagExp&&D.attrExpPresent&&(v[":@"]=this.buildAttributesMap(D.tagExp,Q,D.tagName)),this.addChild(B,v,Q,b)}b=D.closeIndex+1}else if(p.substr(b+1,3)==="!--"){let D=ya(p,"-->",b+4,"Comment is not closed.");if(this.options.commentPropName){let v=p.substring(b+4,D-2);x=this.saveTextToParentTag(x,B,Q),B.add(this.options.commentPropName,[{[this.options.textNodeName]:v}])}b=D}else if(p.substr(b+1,2)==="!D"){let D=k(p,b);this.docTypeEntities=D.entities,b=D.i}else if(p.substr(b+1,2)==="!["){let D=ya(p,"]]>",b,"CDATA is not closed.")-2,v=p.substring(b+9,D);x=this.saveTextToParentTag(x,B,Q);let P=this.parseTextData(v,B.tagname,Q,!0,!1,!0,!0);P==null&&(P=""),this.options.cdataPropName?B.add(this.options.cdataPropName,[{[this.options.textNodeName]:v}]):B.add(this.options.textNodeName,P),b=D+2}else{let D=fB(p,b,this.options.removeNSPrefix),v=D.tagName,P=D.rawTagName,j=D.tagExp,ye=D.attrExpPresent,ae=D.closeIndex;this.options.transformTagName&&(v=this.options.transformTagName(v)),B&&x&&B.tagname!=="!xml"&&(x=this.saveTextToParentTag(x,B,Q,!1));let Le=B;Le&&this.options.unpairedTags.indexOf(Le.tagname)!==-1&&(B=this.tagsNodeStack.pop(),Q=Q.substring(0,Q.lastIndexOf("."))),v!==y.tagname&&(Q+=Q?"."+v:v);let rt=b;if(this.isItStopNode(this.options.stopNodes,Q,v)){let ze="";if(j.length>0&&j.lastIndexOf("/")===j.length-1)v[v.length-1]==="/"?(v=v.substr(0,v.length-1),Q=Q.substr(0,Q.length-1),j=v):j=j.substr(0,j.length-1),b=D.closeIndex;else if(this.options.unpairedTags.indexOf(v)!==-1)b=D.closeIndex;else{let zi=this.readStopNodeData(p,P,ae+1);if(!zi)throw new Error(`Unexpected end of ${P}`);b=zi.i,ze=zi.tagContent}let Wt=new U(v);v!==j&&ye&&(Wt[":@"]=this.buildAttributesMap(j,Q,v)),ze&&(ze=this.parseTextData(ze,v,Q,!0,ye,!0,!0)),Q=Q.substr(0,Q.lastIndexOf(".")),Wt.add(this.options.textNodeName,ze),this.addChild(B,Wt,Q,rt)}else{if(j.length>0&&j.lastIndexOf("/")===j.length-1){v[v.length-1]==="/"?(v=v.substr(0,v.length-1),Q=Q.substr(0,Q.length-1),j=v):j=j.substr(0,j.length-1),this.options.transformTagName&&(v=this.options.transformTagName(v));let ze=new U(v);v!==j&&ye&&(ze[":@"]=this.buildAttributesMap(j,Q,v)),this.addChild(B,ze,Q,rt),Q=Q.substr(0,Q.lastIndexOf("."))}else{let ze=new U(v);this.tagsNodeStack.push(B),v!==j&&ye&&(ze[":@"]=this.buildAttributesMap(j,Q,v)),this.addChild(B,ze,Q,rt),B=ze}x="",b=ae}}else x+=p[b];return y.child};function J9(p,y,B,x){this.options.captureMetaData||(x=void 0);let Q=this.options.updateTag(y.tagname,B,y[":@"]);Q===!1||(typeof Q=="string"&&(y.tagname=Q),p.addChild(y,x))}let V9=function(p){if(this.options.processEntities){for(let y in this.docTypeEntities){let B=this.docTypeEntities[y];p=p.replace(B.regx,B.val)}for(let y in this.lastEntities){let B=this.lastEntities[y];p=p.replace(B.regex,B.val)}if(this.options.htmlEntities)for(let y in this.htmlEntities){let B=this.htmlEntities[y];p=p.replace(B.regex,B.val)}p=p.replace(this.ampEntity.regex,this.ampEntity.val)}return p};function W9(p,y,B,x){return p&&(x===void 0&&(x=y.child.length===0),(p=this.parseTextData(p,y.tagname,B,!1,!!y[":@"]&&Object.keys(y[":@"]).length!==0,x))!==void 0&&p!==""&&y.add(this.options.textNodeName,p),p=""),p}function $9(p,y,B){let x="*."+B;for(let Q in p){let b=p[Q];if(x===b||y===b)return!0}return!1}function ya(p,y,B,x){let Q=p.indexOf(y,B);if(Q===-1)throw new Error(x);return Q+y.length-1}function fB(p,y,B,x=">"){let Q=(function(ae,Le,rt=">"){let ze,Wt="";for(let zi=Le;zi<ae.length;zi++){let fo=ae[zi];if(ze)fo===ze&&(ze="");else if(fo==='"'||fo==="'")ze=fo;else if(fo===rt[0]){if(!rt[1])return{data:Wt,index:zi};if(ae[zi+1]===rt[1])return{data:Wt,index:zi}}else fo===" "&&(fo=" ");Wt+=fo}})(p,y+1,x);if(!Q)return;let b=Q.data,D=Q.index,v=b.search(/\s/),P=b,j=!0;v!==-1&&(P=b.substring(0,v),b=b.substring(v+1).trimStart());let ye=P;if(B){let ae=P.indexOf(":");ae!==-1&&(P=P.substr(ae+1),j=P!==Q.data.substr(ae+1))}return{tagName:P,tagExp:b,closeIndex:D,attrExpPresent:j,rawTagName:ye}}function K9(p,y,B){let x=B,Q=1;for(;B<p.length;B++)if(p[B]==="<")if(p[B+1]=Line truncated `);let y=new U("!xml"),B=y,x="",Q="";for(let N=0;N<p.length;N++)if(p[N]==="<")if(p[N+1]==="/"){let D=_a(p,">",N,"Closing Tag is not closed."),R=p.substring(N+2,D).trim();if(this.options.removeNSPrefix){let Ce=R.indexOf(":");Ce!==-1&&(R=R.substr(Ce+1))}this.options.transformTagName&&(R=this.options.transformTagName(R)),B&&(x=this.saveTextToParentTag(x,B,Q));let P=Q.substring(Q.lastIndexOf(".")+1);if(R&&this.options.unpairedTags.indexOf(R)!==-1)throw new Error(`Unpaired tag can not be used as closing tag: </${R}>`);let z=0;P&&this.options.unpairedTags.indexOf(P)!==-1?(z=Q.lastIndexOf(".",Q.lastIndexOf(".")-1),this.tagsNodeStack.pop()):z=Q.lastIndexOf("."),Q=Q.substring(0,z),B=this.tagsNodeStack.pop(),x="",N=D}else if(p[N+1]==="?"){let D=jB(p,N,!1,"?>");if(!D)throw new Error("Pi Tag is not closed.");if(x=this.saveTextToParentTag(x,B,Q),!(this.options.ignoreDeclaration&&D.tagName==="?xml"||this.options.ignorePiTags)){let R=new U(D.tagName);R.add(this.options.textNodeName,""),D.tagName!==D.tagExp&&D.attrExpPresent&&(R[":@"]=this.buildAttributesMap(D.tagExp,Q,D.tagName)),this.addChild(B,R,Q,N)}N=D.closeIndex+1}else if(p.substr(N+1,3)==="!--"){let D=_a(p,"-->",N+4,"Comment is not closed.");if(this.options.commentPropName){let R=p.substring(N+4,D-2);x=this.saveTextToParentTag(x,B,Q),B.add(this.options.commentPropName,[{[this.options.textNodeName]:R}])}N=D}else if(p.substr(N+1,2)==="!D"){let D=k(p,N);this.docTypeEntities=D.entities,N=D.i}else if(p.substr(N+1,2)==="!["){let D=_a(p,"]]>",N,"CDATA is not closed.")-2,R=p.substring(N+9,D);x=this.saveTextToParentTag(x,B,Q);let P=this.parseTextData(R,B.tagname,Q,!0,!1,!0,!0);P==null&&(P=""),this.options.cdataPropName?B.add(this.options.cdataPropName,[{[this.options.textNodeName]:R}]):B.add(this.options.textNodeName,P),N=D+2}else{let D=jB(p,N,this.options.removeNSPrefix),R=D.tagName,P=D.rawTagName,z=D.tagExp,Ce=D.attrExpPresent,ce=D.closeIndex;this.options.transformTagName&&(R=this.options.transformTagName(R)),B&&x&&B.tagname!=="!xml"&&(x=this.saveTextToParentTag(x,B,Q,!1));let qe=B;qe&&this.options.unpairedTags.indexOf(qe.tagname)!==-1&&(B=this.tagsNodeStack.pop(),Q=Q.substring(0,Q.lastIndexOf("."))),R!==y.tagname&&(Q+=Q?"."+R:R);let st=N;if(this.isItStopNode(this.options.stopNodes,Q,R)){let Ye="";if(z.length>0&&z.lastIndexOf("/")===z.length-1)R[R.length-1]==="/"?(R=R.substr(0,R.length-1),Q=Q.substr(0,Q.length-1),z=R):z=z.substr(0,z.length-1),N=D.closeIndex;else if(this.options.unpairedTags.indexOf(R)!==-1)N=D.closeIndex;else{let Zi=this.readStopNodeData(p,P,ce+1);if(!Zi)throw new Error(`Unexpected end of ${P}`);N=Zi.i,Ye=Zi.tagContent}let Zt=new U(R);R!==z&&Ce&&(Zt[":@"]=this.buildAttributesMap(z,Q,R)),Ye&&(Ye=this.parseTextData(Ye,R,Q,!0,Ce,!0,!0)),Q=Q.substr(0,Q.lastIndexOf(".")),Zt.add(this.options.textNodeName,Ye),this.addChild(B,Zt,Q,st)}else{if(z.length>0&&z.lastIndexOf("/")===z.length-1){R[R.length-1]==="/"?(R=R.substr(0,R.length-1),Q=Q.substr(0,Q.length-1),z=R):z=z.substr(0,z.length-1),this.options.transformTagName&&(R=this.options.transformTagName(R));let Ye=new U(R);R!==z&&Ce&&(Ye[":@"]=this.buildAttributesMap(z,Q,R)),this.addChild(B,Ye,Q,st),Q=Q.substr(0,Q.lastIndexOf("."))}else{let Ye=new U(R);this.tagsNodeStack.push(B),R!==z&&Ce&&(Ye[":@"]=this.buildAttributesMap(z,Q,R)),this.addChild(B,Ye,Q,st),B=Ye}x="",N=ce}}else x+=p[N];return y.child};function LX(p,y,B,x){this.options.captureMetaData||(x=void 0);let Q=this.options.updateTag(y.tagname,B,y[":@"]);Q===!1||(typeof Q=="string"&&(y.tagname=Q),p.addChild(y,x))}let MX=function(p){if(this.options.processEntities){for(let y in this.docTypeEntities){let B=this.docTypeEntities[y];p=p.replace(B.regx,B.val)}for(let y in this.lastEntities){let B=this.lastEntities[y];p=p.replace(B.regex,B.val)}if(this.options.htmlEntities)for(let y in this.htmlEntities){let B=this.htmlEntities[y];p=p.replace(B.regex,B.val)}p=p.replace(this.ampEntity.regex,this.ampEntity.val)}return p};function FX(p,y,B,x){return p&&(x===void 0&&(x=y.child.length===0),(p=this.parseTextData(p,y.tagname,B,!1,!!y[":@"]&&Object.keys(y[":@"]).length!==0,x))!==void 0&&p!==""&&y.add(this.options.textNodeName,p),p=""),p}function UX(p,y,B){let x="*."+B;for(let Q in p){let N=p[Q];if(x===N||y===N)return!0}return!1}function _a(p,y,B,x){let Q=p.indexOf(y,B);if(Q===-1)throw new Error(x);return Q+y.length-1}function jB(p,y,B,x=">"){let Q=(function(ce,qe,st=">"){let Ye,Zt="";for(let Zi=qe;Zi<ce.length;Zi++){let bo=ce[Zi];if(Ye)bo===Ye&&(Ye="");else if(bo==='"'||bo==="'")Ye=bo;else if(bo===st[0]){if(!st[1])return{data:Zt,index:Zi};if(ce[Zi+1]===st[1])return{data:Zt,index:Zi}}else bo===" "&&(bo=" ");Zt+=bo}})(p,y+1,x);if(!Q)return;let N=Q.data,D=Q.index,R=N.search(/\s/),P=N,z=!0;R!==-1&&(P=N.substring(0,R),N=N.substring(R+1).trimStart());let Ce=P;if(B){let ce=P.indexOf(":");ce!==-1&&(P=P.substr(ce+1),z=P!==Q.data.substr(ce+1))}return{tagName:P,tagExp:N,closeIndex:D,attrExpPresent:z,rawTagName:Ce}}function qX(p,y,B){let x=B,Q=1;for(;B<p.length;B++)if(p[B]==="<")if(p[B+1]=Line truncated
`),__(p,y,"",B)}function __(p,y,B,x){let Q="",b=!1;for(let D=0;D<p.length;D++){let v=p[D],P=iK(v);if(P===void 0)continue;let j="";if(j=B.length===0?P:`${B}.${P}`,P===y.textNodeName){let rt=v[P];sK(j,y)||(rt=y.tagValueProcessor(P,rt),rt=P_(rt,y)),b&&(Q+=x),Q+=rt,b=!1;continue}if(P===y.cdataPropName){b&&(Q+=x),Q+=`<![CDATA[${v[P][0][y.textNodeName]}]]>`,b=!1;continue}if(P===y.commentPropName){Q+=x+`<!--${v[P][0][y.textNodeName]}-->`,b=!0;continue}if(P[0]==="?"){let rt=k_(v[":@"],y),ze=P==="?xml"?"":x,Wt=v[P][0][y.textNodeName];Wt=Wt.length!==0?" "+Wt:"",Q+=ze+`<${P}${Wt}${rt}?>`,b=!0;continue}let ye=x;ye!==""&&(ye+=y.indentBy);let ae=x+`<${P}${k_(v[":@"],y)}`,Le=__(v[P],y,j,ye);y.unpairedTags.indexOf(P)!==-1?y.suppressUnpairedNode?Q+=ae+">":Q+=ae+"/>":Le&&Le.length!==0||!y.suppressEmptyNode?Le&&Le.endsWith(">")?Q+=ae+`>${Le}${x}</${P}>`:(Q+=ae+">",Le&&x!==""&&(Le.includes("/>")||Le.includes("</"))?Q+=x+y.indentBy+Le+x:Q+=Le,Q+=`</${P}>`):Q+=ae+"/>",b=!0}return Q}function iK(p){let y=Object.keys(p);for(let B=0;B<y.length;B++){let x=y[B];if(p.hasOwnProperty(x)&&x!==":@")return x}}function k_(p,y){let B="";if(p&&!y.ignoreAttributes)for(let x in p){if(!p.hasOwnProperty(x))continue;let Q=y.attributeValueProcessor(x,p[x]);Q=P_(Q,y),Q===!0&&y.suppressBooleanAttributes?B+=` ${x.substr(y.attributeNamePrefix.length)}`:B+=` ${x.substr(y.attributeNamePrefix.length)}="${Q}"`}return B}function sK(p,y){let B=(p=p.substr(0,p.length-y.textNodeName.length-1)).substr(p.lastIndexOf(".")+1);for(let x in y.stopNodes)if(y.stopNodes[x]===p||y.stopNodes[x]==="*."+B)return!0;return!1}function P_(p,y){if(p&&p.length>0&&y.processEntities)for(let B=0;B<y.entities.length;B++){let x=y.entities[B];p=p.replace(x.regex,x.val)}return p}let oK={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(p,y){return y},attributeValueProcessor:function(p,y){return y},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function uo(p){this.options=Object.assign({},oK,p),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Ni(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=cK),this.processTextOrObjNode=aK,this.options.format?(this.indentate=AK,this.tagEndChar=`> `),Dk(p,y,"",B)}function Dk(p,y,B,x){let Q="",N=!1;for(let D=0;D<p.length;D++){let R=p[D],P=VX(R);if(P===void 0)continue;let z="";if(z=B.length===0?P:`${B}.${P}`,P===y.textNodeName){let st=R[P];WX(z,y)||(st=y.tagValueProcessor(P,st),st=kk(st,y)),N&&(Q+=x),Q+=st,N=!1;continue}if(P===y.cdataPropName){N&&(Q+=x),Q+=`<![CDATA[${R[P][0][y.textNodeName]}]]>`,N=!1;continue}if(P===y.commentPropName){Q+=x+`<!--${R[P][0][y.textNodeName]}-->`,N=!0;continue}if(P[0]==="?"){let st=_k(R[":@"],y),Ye=P==="?xml"?"":x,Zt=R[P][0][y.textNodeName];Zt=Zt.length!==0?" "+Zt:"",Q+=Ye+`<${P}${Zt}${st}?>`,N=!0;continue}let Ce=x;Ce!==""&&(Ce+=y.indentBy);let ce=x+`<${P}${_k(R[":@"],y)}`,qe=Dk(R[P],y,z,Ce);y.unpairedTags.indexOf(P)!==-1?y.suppressUnpairedNode?Q+=ce+">":Q+=ce+"/>":qe&&qe.length!==0||!y.suppressEmptyNode?qe&&qe.endsWith(">")?Q+=ce+`>${qe}${x}</${P}>`:(Q+=ce+">",qe&&x!==""&&(qe.includes("/>")||qe.includes("</"))?Q+=x+y.indentBy+qe+x:Q+=qe,Q+=`</${P}>`):Q+=ce+"/>",N=!0}return Q}function VX(p){let y=Object.keys(p);for(let B=0;B<y.length;B++){let x=y[B];if(p.hasOwnProperty(x)&&x!==":@")return x}}function _k(p,y){let B="";if(p&&!y.ignoreAttributes)for(let x in p){if(!p.hasOwnProperty(x))continue;let Q=y.attributeValueProcessor(x,p[x]);Q=kk(Q,y),Q===!0&&y.suppressBooleanAttributes?B+=` ${x.substr(y.attributeNamePrefix.length)}`:B+=` ${x.substr(y.attributeNamePrefix.length)}="${Q}"`}return B}function WX(p,y){let B=(p=p.substr(0,p.length-y.textNodeName.length-1)).substr(p.lastIndexOf(".")+1);for(let x in y.stopNodes)if(y.stopNodes[x]===p||y.stopNodes[x]==="*."+B)return!0;return!1}function kk(p,y){if(p&&p.length>0&&y.processEntities)for(let B=0;B<y.entities.length;B++){let x=y.entities[B];p=p.replace(x.regex,x.val)}return p}let $X={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(p,y){return y},attributeValueProcessor:function(p,y){return y},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&amp;"},{regex:new RegExp(">","g"),val:"&gt;"},{regex:new RegExp("<","g"),val:"&lt;"},{regex:new RegExp("'","g"),val:"&apos;"},{regex:new RegExp('"',"g"),val:"&quot;"}],processEntities:!0,stopNodes:[],oneListGroup:!1};function Qo(p){this.options=Object.assign({},$X,p),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=Ti(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=ZX),this.processTextOrObjNode=KX,this.options.format?(this.indentate=XX,this.tagEndChar=`>
`,this.newLine=` `,this.newLine=`
`):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function aK(p,y,B,x){let Q=this.j2x(p,B+1,x.concat(y));return p[this.options.textNodeName]!==void 0&&Object.keys(p).length===1?this.buildTextValNode(p[this.options.textNodeName],y,Q.attrStr,B):this.buildObjectNode(Q.val,y,Q.attrStr,B)}function AK(p){return this.options.indentBy.repeat(p)}function cK(p){return!(!p.startsWith(this.options.attributeNamePrefix)||p===this.options.textNodeName)&&p.substr(this.attrPrefixLen)}uo.prototype.build=function(p){return this.options.preserveOrder?nK(p,this.options):(Array.isArray(p)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(p={[this.options.arrayNodeName]:p}),this.j2x(p,0,[]).val)},uo.prototype.j2x=function(p,y,B){let x="",Q="",b=B.join(".");for(let D in p)if(Object.prototype.hasOwnProperty.call(p,D))if(p[D]===void 0)this.isAttribute(D)&&(Q+="");else if(p[D]===null)this.isAttribute(D)||D===this.options.cdataPropName?Q+="":D[0]==="?"?Q+=this.indentate(y)+"<"+D+"?"+this.tagEndChar:Q+=this.indentate(y)+"<"+D+"/"+this.tagEndChar;else if(p[D]instanceof Date)Q+=this.buildTextValNode(p[D],D,"",y);else if(typeof p[D]!="object"){let v=this.isAttribute(D);if(v&&!this.ignoreAttributesFn(v,b))x+=this.buildAttrPairStr(v,""+p[D]);else if(!v)if(D===this.options.textNodeName){let P=this.options.tagValueProcessor(D,""+p[D]);Q+=this.replaceEntitiesValue(P)}else Q+=this.buildTextValNode(p[D],D,"",y)}else if(Array.isArray(p[D])){let v=p[D].length,P="",j="";for(let ye=0;ye<v;ye++){let ae=p[D][ye];if(ae!==void 0)if(ae===null)D[0]==="?"?Q+=this.indentate(y)+"<"+D+"?"+this.tagEndChar:Q+=this.indentate(y)+"<"+D+"/"+this.tagEndChar;else if(typeof ae=="object")if(this.options.oneListGroup){let Le=this.j2x(ae,y+1,B.concat(D));P+=Le.val,this.options.attributesGroupName&&ae.hasOwnProperty(this.options.attributesGroupName)&&(j+=Le.attrStr)}else P+=this.processTextOrObjNode(ae,D,y,B);else if(this.options.oneListGroup){let Le=this.options.tagValueProcessor(D,ae);Le=this.replaceEntitiesValue(Le),P+=Le}else P+=this.buildTextValNode(ae,D,"",y)}this.options.oneListGroup&&(P=this.buildObjectNode(P,D,j,y)),Q+=P}else if(this.options.attributesGroupName&&D===this.options.attributesGroupName){let v=Object.keys(p[D]),P=v.length;for(let j=0;j<P;j++)x+=this.buildAttrPairStr(v[j],""+p[D][v[j]])}else Q+=this.processTextOrObjNode(p[D],D,y,B);return{attrStr:x,val:Q}},uo.prototype.buildAttrPairStr=function(p,y){return y=this.options.attributeValueProcessor(p,""+y),y=this.replaceEntitiesValue(y),this.options.suppressBooleanAttributes&&y==="true"?" "+p:" "+p+'="'+y+'"'},uo.prototype.buildObjectNode=function(p,y,B,x){if(p==="")return y[0]==="?"?this.indentate(x)+"<"+y+B+"?"+this.tagEndChar:this.indentate(x)+"<"+y+B+this.closeTag(y)+this.tagEndChar;{let Q="</"+y+this.tagEndChar,b="";return y[0]==="?"&&(b="?",Q=""),!B&&B!==""||p.indexOf("<")!==-1?this.options.commentPropName!==!1&&y===this.options.commentPropName&&b.length===0?this.indentate(x)+`<!--${p}-->`+this.newLine:this.indentate(x)+"<"+y+B+b+this.tagEndChar+p+this.indentate(x)+Q:this.indentate(x)+"<"+y+B+b+">"+p+Q}},uo.prototype.closeTag=function(p){let y="";return this.options.unpairedTags.indexOf(p)!==-1?this.options.suppressUnpairedNode||(y="/"):y=this.options.suppressEmptyNode?"/":`></${p}`,y},uo.prototype.buildTextValNode=function(p,y,B,x){if(this.options.cdataPropName!==!1&&y===this.options.cdataPropName)return this.indentate(x)+`<![CDATA[${p}]]>`+this.newLine;if(this.options.commentPropName!==!1&&y===this.options.commentPropName)return this.indentate(x)+`<!--${p}-->`+this.newLine;if(y[0]==="?")return this.indentate(x)+"<"+y+B+"?"+this.tagEndChar;{let Q=this.options.tagValueProcessor(y,p);return Q=this.replaceEntitiesValue(Q),Q===""?this.indentate(x)+"<"+y+B+this.closeTag(y)+this.tagEndChar:this.indentate(x)+"<"+y+B+">"+Q+"</"+y+this.tagEndChar}},uo.prototype.replaceEntitiesValue=function(p){if(p&&p.length>0&&this.options.processEntities)for(let y=0;y<this.options.entities.length;y++){let B=this.options.entities[y];p=p.replace(B.regex,B.val)}return p};let lK={validate:a};Zz.exports=e})()});var Hx=h(Ll=>{"use strict";Object.defineProperty(Ll,"__esModule",{value:!0});Ll.XML_CHARKEY=Ll.XML_ATTRKEY=void 0;Ll.XML_ATTRKEY="$";Ll.XML_CHARKEY="_"});var nj=h(gE=>{"use strict";Object.defineProperty(gE,"__esModule",{value:!0});gE.stringifyXML=Upe;gE.parseXML=qpe;var zx=ej(),tj=Hx();function rj(t){var e;return{attributesGroupName:tj.XML_ATTRKEY,textNodeName:(e=t.xmlCharKey)!==null&&e!==void 0?e:tj.XML_CHARKEY,ignoreAttributes:!1,suppressBooleanAttributes:!1}}function Lpe(t={}){var e,r;return Object.assign(Object.assign({},rj(t)),{attributeNamePrefix:"@_",format:!0,suppressEmptyNode:!0,indentBy:"",rootNodeName:(e=t.rootName)!==null&&e!==void 0?e:"root",cdataPropName:(r=t.cdataPropName)!==null&&r!==void 0?r:"__cdata"})}function Fpe(t={}){return Object.assign(Object.assign({},rj(t)),{parseAttributeValue:!1,parseTagValue:!1,attributeNamePrefix:"",stopNodes:t.stopNodes,processEnLine truncated `):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function KX(p,y,B,x){let Q=this.j2x(p,B+1,x.concat(y));return p[this.options.textNodeName]!==void 0&&Object.keys(p).length===1?this.buildTextValNode(p[this.options.textNodeName],y,Q.attrStr,B):this.buildObjectNode(Q.val,y,Q.attrStr,B)}function XX(p){return this.options.indentBy.repeat(p)}function ZX(p){return!(!p.startsWith(this.options.attributeNamePrefix)||p===this.options.textNodeName)&&p.substr(this.attrPrefixLen)}Qo.prototype.build=function(p){return this.options.preserveOrder?JX(p,this.options):(Array.isArray(p)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(p={[this.options.arrayNodeName]:p}),this.j2x(p,0,[]).val)},Qo.prototype.j2x=function(p,y,B){let x="",Q="",N=B.join(".");for(let D in p)if(Object.prototype.hasOwnProperty.call(p,D))if(p[D]===void 0)this.isAttribute(D)&&(Q+="");else if(p[D]===null)this.isAttribute(D)||D===this.options.cdataPropName?Q+="":D[0]==="?"?Q+=this.indentate(y)+"<"+D+"?"+this.tagEndChar:Q+=this.indentate(y)+"<"+D+"/"+this.tagEndChar;else if(p[D]instanceof Date)Q+=this.buildTextValNode(p[D],D,"",y);else if(typeof p[D]!="object"){let R=this.isAttribute(D);if(R&&!this.ignoreAttributesFn(R,N))x+=this.buildAttrPairStr(R,""+p[D]);else if(!R)if(D===this.options.textNodeName){let P=this.options.tagValueProcessor(D,""+p[D]);Q+=this.replaceEntitiesValue(P)}else Q+=this.buildTextValNode(p[D],D,"",y)}else if(Array.isArray(p[D])){let R=p[D].length,P="",z="";for(let Ce=0;Ce<R;Ce++){let ce=p[D][Ce];if(ce!==void 0)if(ce===null)D[0]==="?"?Q+=this.indentate(y)+"<"+D+"?"+this.tagEndChar:Q+=this.indentate(y)+"<"+D+"/"+this.tagEndChar;else if(typeof ce=="object")if(this.options.oneListGroup){let qe=this.j2x(ce,y+1,B.concat(D));P+=qe.val,this.options.attributesGroupName&&ce.hasOwnProperty(this.options.attributesGroupName)&&(z+=qe.attrStr)}else P+=this.processTextOrObjNode(ce,D,y,B);else if(this.options.oneListGroup){let qe=this.options.tagValueProcessor(D,ce);qe=this.replaceEntitiesValue(qe),P+=qe}else P+=this.buildTextValNode(ce,D,"",y)}this.options.oneListGroup&&(P=this.buildObjectNode(P,D,z,y)),Q+=P}else if(this.options.attributesGroupName&&D===this.options.attributesGroupName){let R=Object.keys(p[D]),P=R.length;for(let z=0;z<P;z++)x+=this.buildAttrPairStr(R[z],""+p[D][R[z]])}else Q+=this.processTextOrObjNode(p[D],D,y,B);return{attrStr:x,val:Q}},Qo.prototype.buildAttrPairStr=function(p,y){return y=this.options.attributeValueProcessor(p,""+y),y=this.replaceEntitiesValue(y),this.options.suppressBooleanAttributes&&y==="true"?" "+p:" "+p+'="'+y+'"'},Qo.prototype.buildObjectNode=function(p,y,B,x){if(p==="")return y[0]==="?"?this.indentate(x)+"<"+y+B+"?"+this.tagEndChar:this.indentate(x)+"<"+y+B+this.closeTag(y)+this.tagEndChar;{let Q="</"+y+this.tagEndChar,N="";return y[0]==="?"&&(N="?",Q=""),!B&&B!==""||p.indexOf("<")!==-1?this.options.commentPropName!==!1&&y===this.options.commentPropName&&N.length===0?this.indentate(x)+`<!--${p}-->`+this.newLine:this.indentate(x)+"<"+y+B+N+this.tagEndChar+p+this.indentate(x)+Q:this.indentate(x)+"<"+y+B+N+">"+p+Q}},Qo.prototype.closeTag=function(p){let y="";return this.options.unpairedTags.indexOf(p)!==-1?this.options.suppressUnpairedNode||(y="/"):y=this.options.suppressEmptyNode?"/":`></${p}`,y},Qo.prototype.buildTextValNode=function(p,y,B,x){if(this.options.cdataPropName!==!1&&y===this.options.cdataPropName)return this.indentate(x)+`<![CDATA[${p}]]>`+this.newLine;if(this.options.commentPropName!==!1&&y===this.options.commentPropName)return this.indentate(x)+`<!--${p}-->`+this.newLine;if(y[0]==="?")return this.indentate(x)+"<"+y+B+"?"+this.tagEndChar;{let Q=this.options.tagValueProcessor(y,p);return Q=this.replaceEntitiesValue(Q),Q===""?this.indentate(x)+"<"+y+B+this.closeTag(y)+this.tagEndChar:this.indentate(x)+"<"+y+B+">"+Q+"</"+y+this.tagEndChar}},Qo.prototype.replaceEntitiesValue=function(p){if(p&&p.length>0&&this.options.processEntities)for(let y=0;y<this.options.entities.length;y++){let B=this.options.entities[y];p=p.replace(B.regex,B.val)}return p};let e5={validate:a};Xz.exports=e})()});var yS=h(Kl=>{"use strict";Object.defineProperty(Kl,"__esModule",{value:!0});Kl.XML_CHARKEY=Kl.XML_ATTRKEY=void 0;Kl.XML_ATTRKEY="$";Kl.XML_CHARKEY="_"});var rG=h(TE=>{"use strict";Object.defineProperty(TE,"__esModule",{value:!0});TE.stringifyXML=vCe;TE.parseXML=DCe;var ES=Zz(),eG=yS();function tG(t){var e;return{attributesGroupName:eG.XML_ATTRKEY,textNodeName:(e=t.xmlCharKey)!==null&&e!==void 0?e:eG.XML_CHARKEY,ignoreAttributes:!1,suppressBooleanAttributes:!1}}function SCe(t={}){var e,r;return Object.assign(Object.assign({},tG(t)),{attributeNamePrefix:"@_",format:!0,suppressEmptyNode:!0,indentBy:"",rootNodeName:(e=t.rootName)!==null&&e!==void 0?e:"root",cdataPropName:(r=t.cdataPropName)!==null&&r!==void 0?r:"__cdata"})}function RCe(t={}){return Object.assign(Object.assign({},tG(t)),{parseAttributeValue:!1,parseTagValue:!1,attributeNamePrefix:"",stopNodes:t.stopNodes,processEnLine truncated
Polling from: ${r.config.operationLocation} Polling from: ${r.config.operationLocation}
Operation status: ${l} Operation status: ${l}
Polling status: ${Aj.terminalStates.includes(l)?"Stopped":"Running"}`),l==="succeeded"){let u=o(c,r);if(u!==void 0)return{response:await e(u).catch(aj({state:r,stateProxy:n,isOperationError:a})),status:l}}return{response:c,status:l}}async function Wpe(t){let{poll:e,state:r,stateProxy:n,options:i,getOperationStatus:s,getResourceLocation:o,getOperationLocation:a,isOperationError:A,withOperationLocation:c,getPollingInterval:l,processResult:u,getError:d,updateState:f,setDelay:g,isDone:m,setErrorAsResult:E}=t,{operationLocation:C}=r.config;if(C!==void 0){let{response:I,status:N}=await Vpe({poll:e,getOperationStatus:s,state:r,stateProxy:n,operationLocation:C,getResourceLocation:o,isOperationError:A,options:i});if(cj({status:N,response:I,state:r,stateProxy:n,isDone:m,processResult:u,getError:d,setErrorAsResult:E}),!Aj.terminalStates.includes(N)){let w=l?.(I);w&&g(w);let R=a?.(I,r);if(R!==void 0){let T=C!==R;r.config.operationLocation=R,c?.(R,T)}else c?.(C,!1)}f?.(r,I)}}Fo.pollOperation=Wpe});var Vx=h(Tt=>{"use strict";Object.defineProperty(Tt,"__esModule",{value:!0});Tt.pollHttpOperation=Tt.isOperationError=Tt.getResourceLocation=Tt.getOperationStatus=Tt.getOperationLocation=Tt.initHttpOperation=Tt.getStatusFromInitialResponse=Tt.getErrorFromResponse=Tt.parseRetryAfter=Tt.inferLroMode=void 0;var lj=EE(),Gx=pE();function uj(t){let{azureAsyncOperation:e,operationLocation:r}=t;return r??e}function dj(t){return t.headers.location}function fj(t){return t.headers["operation-location"]}function hj(t){return t.headers["azure-asyncoperation"]}function $pe(t){var e;let{location:r,requestMethod:n,requestPath:i,resourceLocationConfig:s}=t;switch(n){case"PUT":return i;case"DELETE":return;case"PATCH":return(e=o())!==null&&e!==void 0?e:i;default:return o()}function o(){switch(s){case"azure-async-operation":return;case"original-uri":return i;default:return r}}}function gj(t){let{rawResponse:e,requestMethod:r,requestPath:n,resourceLocationConfig:i}=t,s=fj(e),o=hj(e),a=uj({operationLocation:s,azureAsyncOperation:o}),A=dj(e),c=r?.toLocaleUpperCase();return a!==void 0?{mode:"OperationLocation",operationLocation:a,resourceLocation:$pe({requestMethod:c,location:A,requestPath:n,resourceLocationConfig:i})}:A!==void 0?{mode:"ResourceLocation",operationLocation:A}:c==="PUT"&&n?{mode:"Body",operationLocation:n}:void 0}Tt.inferLroMode=gj;function mj(t){let{status:e,statusCode:r}=t;if(typeof e!="string"&&e!==void 0)throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${e}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`);switch(e?.toLocaleLowerCase()){case void 0:return Yx(r);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:return Gx.logger.verbose(`LRO: unrecognized operation status: ${e}`),e}}function Kpe(t){var e;let{status:r}=(e=t.body)!==null&&e!==void 0?e:{};return mj({status:r,statusCode:t.statusCode})}function Xpe(t){var e,r;let{properties:n,provisioningState:i}=(e=t.body)!==null&&e!==void 0?e:{},s=(r=n?.provisioningState)!==null&&r!==void 0?r:i;return mj({status:s,statusCode:t.statusCode})}function Yx(t){return t===202?"running":t<300?"succeeded":"failed"}function pj({rawResponse:t}){let e=t.headers["retry-after"];if(e!==void 0){let r=parseInt(e);return isNaN(r)?Zpe(new Date(e)):r*1e3}}Tt.parseRetryAfter=pj;function yj(t){let e=Ij(t,"error");if(!e){Gx.logger.warning("The long-running operation failed but there is no error property in the response's body");return}if(!e.code||!e.message){Gx.logger.warning("The long-running operation failed but the error property in the response's body doesn't contain code or message");return}return e}Tt.getErrorFromResponse=yj;function Zpe(t){let e=Math.floor(new Date().getTime()),r=t.getTime();if(e<r)return r-e}function Ej(t){let{response:e,state:r,operationLocation:n}=t;function i(){var o;switch((o=r.config.metadata)===null||o===void 0?void 0:o.mode){case void 0:return Yx(e.rawResponse.statusCode);case"Body":return Jx(e,r);default:return"running"}}let s=i();return s==="running"&&n===void 0?"succeeded":s}Tt.getStatusFromInitialResponse=Ej;async function eye(t){let{stateProxy:e,resourceLocationConfig:r,processResult:n,lro:i,setErrorAsResult:s}=t;return(0,lj.initOperation)({init:async()=>{let o=await i.sendInitialRequest(),a=gj({rawResponse:o.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:r});return Object.assign({response:o,operationLocation:a?.operationLocation,resourceLocation:a?.resourceLocation},a?.mode?{metadata:{mode:a.mode}}:{})},stateProxy:e,processResult:n?({flatResponse:o},a)=>n(o,a):({flatResponse:o})=>o,getOperationStatus:Ej,setErrorAsResult:s})}Tt.initHttpOperation=eye;function Cj({rawResponse:t},e){var r;switch((r=e.config.metadata)===null||r=Line truncated Polling status: ${aG.terminalStates.includes(l)?"Stopped":"Running"}`),l==="succeeded"){let u=o(c,r);if(u!==void 0)return{response:await e(u).catch(oG({state:r,stateProxy:n,isOperationError:a})),status:l}}return{response:c,status:l}}async function FCe(t){let{poll:e,state:r,stateProxy:n,options:i,getOperationStatus:s,getResourceLocation:o,getOperationLocation:a,isOperationError:A,withOperationLocation:c,getPollingInterval:l,processResult:u,getError:d,updateState:f,setDelay:g,isDone:m,setErrorAsResult:E}=t,{operationLocation:C}=r.config;if(C!==void 0){let{response:I,status:b}=await MCe({poll:e,getOperationStatus:s,state:r,stateProxy:n,operationLocation:C,getResourceLocation:o,isOperationError:A,options:i});if(AG({status:b,response:I,state:r,stateProxy:n,isDone:m,processResult:u,getError:d,setErrorAsResult:E}),!aG.terminalStates.includes(b)){let w=l?.(I);w&&g(w);let v=a?.(I,r);if(v!==void 0){let T=C!==v;r.config.operationLocation=v,c?.(v,T)}else c?.(C,!1)}f?.(r,I)}}$o.pollOperation=FCe});var bS=h(Ft=>{"use strict";Object.defineProperty(Ft,"__esModule",{value:!0});Ft.pollHttpOperation=Ft.isOperationError=Ft.getResourceLocation=Ft.getOperationStatus=Ft.getOperationLocation=Ft.initHttpOperation=Ft.getStatusFromInitialResponse=Ft.getErrorFromResponse=Ft.parseRetryAfter=Ft.inferLroMode=void 0;var cG=FE(),IS=LE();function lG(t){let{azureAsyncOperation:e,operationLocation:r}=t;return r??e}function uG(t){return t.headers.location}function dG(t){return t.headers["operation-location"]}function fG(t){return t.headers["azure-asyncoperation"]}function UCe(t){var e;let{location:r,requestMethod:n,requestPath:i,resourceLocationConfig:s}=t;switch(n){case"PUT":return i;case"DELETE":return;case"PATCH":return(e=o())!==null&&e!==void 0?e:i;default:return o()}function o(){switch(s){case"azure-async-operation":return;case"original-uri":return i;default:return r}}}function hG(t){let{rawResponse:e,requestMethod:r,requestPath:n,resourceLocationConfig:i}=t,s=dG(e),o=fG(e),a=lG({operationLocation:s,azureAsyncOperation:o}),A=uG(e),c=r?.toLocaleUpperCase();return a!==void 0?{mode:"OperationLocation",operationLocation:a,resourceLocation:UCe({requestMethod:c,location:A,requestPath:n,resourceLocationConfig:i})}:A!==void 0?{mode:"ResourceLocation",operationLocation:A}:c==="PUT"&&n?{mode:"Body",operationLocation:n}:void 0}Ft.inferLroMode=hG;function gG(t){let{status:e,statusCode:r}=t;if(typeof e!="string"&&e!==void 0)throw new Error(`Polling was unsuccessful. Expected status to have a string value or no value but it has instead: ${e}. This doesn't necessarily indicate the operation has failed. Check your Azure subscription or resource status for more information.`);switch(e?.toLocaleLowerCase()){case void 0:return BS(r);case"succeeded":return"succeeded";case"failed":return"failed";case"running":case"accepted":case"started":case"canceling":case"cancelling":return"running";case"canceled":case"cancelled":return"canceled";default:return IS.logger.verbose(`LRO: unrecognized operation status: ${e}`),e}}function qCe(t){var e;let{status:r}=(e=t.body)!==null&&e!==void 0?e:{};return gG({status:r,statusCode:t.statusCode})}function HCe(t){var e,r;let{properties:n,provisioningState:i}=(e=t.body)!==null&&e!==void 0?e:{},s=(r=n?.provisioningState)!==null&&r!==void 0?r:i;return gG({status:s,statusCode:t.statusCode})}function BS(t){return t===202?"running":t<300?"succeeded":"failed"}function mG({rawResponse:t}){let e=t.headers["retry-after"];if(e!==void 0){let r=parseInt(e);return isNaN(r)?jCe(new Date(e)):r*1e3}}Ft.parseRetryAfter=mG;function pG(t){let e=CG(t,"error");if(!e){IS.logger.warning("The long-running operation failed but there is no error property in the response's body");return}if(!e.code||!e.message){IS.logger.warning("The long-running operation failed but the error property in the response's body doesn't contain code or message");return}return e}Ft.getErrorFromResponse=pG;function jCe(t){let e=Math.floor(new Date().getTime()),r=t.getTime();if(e<r)return r-e}function yG(t){let{response:e,state:r,operationLocation:n}=t;function i(){var o;switch((o=r.config.metadata)===null||o===void 0?void 0:o.mode){case void 0:return BS(e.rawResponse.statusCode);case"Body":return QS(e,r);default:return"running"}}let s=i();return s==="running"&&n===void 0?"succeeded":s}Ft.getStatusFromInitialResponse=yG;async function zCe(t){let{stateProxy:e,resourceLocationConfig:r,processResult:n,lro:i,setErrorAsResult:s}=t;return(0,cG.initOperation)({init:async()=>{let o=await i.sendInitialRequest(),a=hG({rawResponse:o.rawResponse,requestPath:i.requestPath,requestMethod:i.requestMethod,resourceLocationConfig:r});return Object.assign({response:o,operationLocation:a?.operationLocation,resourceLocation:a?.resourceLocation},a?.mode?{metadata:{mode:a.mode}}:{})},stateProxy:e,processResult:n?({flatResponse:o},a)=>n(o,a):({flatResponse:o})=>o,getOperationStatus:yG,setErrorAsResult:s})}Ft.initHttpOperation=zCe;function EG({rawResponse:t},e){var r;switch((r=e.config.metadata)===null||r=Line truncated
`,Jj="HTTP/1.1",Rye="AES256",Dye="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;",_ye=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-copy-source-error-code","x-ms-copy-source-status-code","x-ms-if-tags","x-ms-source-if-tags"],kye=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"],Pye="BlobUsesCustomerSpecifiedEncryption",Tye="BlobDoesNotUseCustomerSpecifiedEncryption",Oye=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function Mye(t){let e=new URL(t),r=e.pathname;return r=r||"/",r=Fye(r),e.pathname=r,e.toString()}function Lye(t){let e="";if(t.search("DevelopmentStorageProxyUri=")!==-1){let r=t.split(";");for(let n of r)n.trim().startsWith("DevelopmentStorageProxyUri=")&&(e=n.trim().match("DevelopmentStorageProxyUri=(.*)")[1])}return e}function rA(t,e){let r=t.split(";");for(let n of r)if(n.trim().startsWith(e))return n.trim().match(e+"=(.*)")[1];return""}function Wl(t){let e="";t.startsWith("UseDevelopmentStorage=true")&&(e=Lye(t),t=Dye);let r=rA(t,"BlobEndpoint");if(r=r.endsWith("/")?r.slice(0,-1):r,t.search("DefaultEndpointsProtocol=")!==-1&&t.search("AccountKey=")!==-1){let n="",i="",s=Buffer.from("accountKey","base64"),o="";if(i=rA(t,"AccountName"),s=Buffer.from(rA(t,"AccountKey"),"base64"),!r){n=rA(t,"DefaultEndpointsProtocol");let a=n.toLowerCase();if(a!=="https"&&a!=="http")throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'");if(o=rA(t,"EndpointSuffix"),!o)throw new Error("Invalid EndpointSuffix in the provided Connection String");r=`${n}://${i}.blob.${o}`}if(i){if(s.length===0)throw new Error("Invalid AccountKey in the provided Connection String")}else throw new Error("Invalid AccountName in the provided Connection String");return{kind:"AccountConnString",url:r,accountName:i,accountKey:s,proxyUri:e}}else{let n=rA(t,"SharedAccessSignature"),i=rA(t,"AccountName");if(i||(i=Xj(r)),r){if(!n)throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}else throw new Error("Invalid BlobEndpoint in the provided SAS Connection String");return n.startsWith("?")&&(n=n.substring(1)),{kind:"SASConnString",url:r,accountName:i,accountSas:n}}}function Fye(t){return encodeURIComponent(t).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function Rt(t,e){let r=new URL(t),n=r.pathname;return n=n?n.endsWith("/")?`${n}${e}`:`${n}/${e}`:e,r.pathname=n,r.toString()}function Gs(t,e,r){let n=new URL(t),i=encodeURIComponent(e),s=r?encodeURIComponent( Line truncated `,YG="HTTP/1.1",CIe="AES256",IIe="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;",BIe=["Access-Control-Allow-Origin","Cache-Control","Content-Length","Content-Type","Date","Request-Id","traceparent","Transfer-Encoding","User-Agent","x-ms-client-request-id","x-ms-date","x-ms-error-code","x-ms-request-id","x-ms-return-client-request-id","x-ms-version","Accept-Ranges","Content-Disposition","Content-Encoding","Content-Language","Content-MD5","Content-Range","ETag","Last-Modified","Server","Vary","x-ms-content-crc64","x-ms-copy-action","x-ms-copy-completion-time","x-ms-copy-id","x-ms-copy-progress","x-ms-copy-status","x-ms-has-immutability-policy","x-ms-has-legal-hold","x-ms-lease-state","x-ms-lease-status","x-ms-range","x-ms-request-server-encrypted","x-ms-server-encrypted","x-ms-snapshot","x-ms-source-range","If-Match","If-Modified-Since","If-None-Match","If-Unmodified-Since","x-ms-access-tier","x-ms-access-tier-change-time","x-ms-access-tier-inferred","x-ms-account-kind","x-ms-archive-status","x-ms-blob-append-offset","x-ms-blob-cache-control","x-ms-blob-committed-block-count","x-ms-blob-condition-appendpos","x-ms-blob-condition-maxsize","x-ms-blob-content-disposition","x-ms-blob-content-encoding","x-ms-blob-content-language","x-ms-blob-content-length","x-ms-blob-content-md5","x-ms-blob-content-type","x-ms-blob-public-access","x-ms-blob-sequence-number","x-ms-blob-type","x-ms-copy-destination-snapshot","x-ms-creation-time","x-ms-default-encryption-scope","x-ms-delete-snapshots","x-ms-delete-type-permanent","x-ms-deny-encryption-scope-override","x-ms-encryption-algorithm","x-ms-if-sequence-number-eq","x-ms-if-sequence-number-le","x-ms-if-sequence-number-lt","x-ms-incremental-copy","x-ms-lease-action","x-ms-lease-break-period","x-ms-lease-duration","x-ms-lease-id","x-ms-lease-time","x-ms-page-write","x-ms-proposed-lease-id","x-ms-range-get-content-md5","x-ms-rehydrate-priority","x-ms-sequence-number-action","x-ms-sku-name","x-ms-source-content-md5","x-ms-source-if-match","x-ms-source-if-modified-since","x-ms-source-if-none-match","x-ms-source-if-unmodified-since","x-ms-tag-count","x-ms-encryption-key-sha256","x-ms-copy-source-error-code","x-ms-copy-source-status-code","x-ms-if-tags","x-ms-source-if-tags"],QIe=["comp","maxresults","rscc","rscd","rsce","rscl","rsct","se","si","sip","sp","spr","sr","srt","ss","st","sv","include","marker","prefix","copyid","restype","blockid","blocklisttype","delimiter","prevsnapshot","ske","skoid","sks","skt","sktid","skv","snapshot"],bIe="BlobUsesCustomerSpecifiedEncryption",NIe="BlobDoesNotUseCustomerSpecifiedEncryption",wIe=["10000","10001","10002","10003","10004","10100","10101","10102","10103","10104","11000","11001","11002","11003","11004","11100","11101","11102","11103","11104"];function xIe(t){let e=new URL(t),r=e.pathname;return r=r||"/",r=RIe(r),e.pathname=r,e.toString()}function SIe(t){let e="";if(t.search("DevelopmentStorageProxyUri=")!==-1){let r=t.split(";");for(let n of r)n.trim().startsWith("DevelopmentStorageProxyUri=")&&(e=n.trim().match("DevelopmentStorageProxyUri=(.*)")[1])}return e}function mA(t,e){let r=t.split(";");for(let n of r)if(n.trim().startsWith(e))return n.trim().match(e+"=(.*)")[1];return""}function Au(t){let e="";t.startsWith("UseDevelopmentStorage=true")&&(e=SIe(t),t=IIe);let r=mA(t,"BlobEndpoint");if(r=r.endsWith("/")?r.slice(0,-1):r,t.search("DefaultEndpointsProtocol=")!==-1&&t.search("AccountKey=")!==-1){let n="",i="",s=Buffer.from("accountKey","base64"),o="";if(i=mA(t,"AccountName"),s=Buffer.from(mA(t,"AccountKey"),"base64"),!r){n=mA(t,"DefaultEndpointsProtocol");let a=n.toLowerCase();if(a!=="https"&&a!=="http")throw new Error("Invalid DefaultEndpointsProtocol in the provided Connection String. Expecting 'https' or 'http'");if(o=mA(t,"EndpointSuffix"),!o)throw new Error("Invalid EndpointSuffix in the provided Connection String");r=`${n}://${i}.blob.${o}`}if(i){if(s.length===0)throw new Error("Invalid AccountKey in the provided Connection String")}else throw new Error("Invalid AccountName in the provided Connection String");return{kind:"AccountConnString",url:r,accountName:i,accountKey:s,proxyUri:e}}else{let n=mA(t,"SharedAccessSignature"),i=mA(t,"AccountName");if(i||(i=KG(r)),r){if(!n)throw new Error("Invalid SharedAccessSignature in the provided SAS Connection String")}else throw new Error("Invalid BlobEndpoint in the provided SAS Connection String");return n.startsWith("?")&&(n=n.substring(1)),{kind:"SASConnString",url:r,accountName:i,accountSas:n}}}function RIe(t){return encodeURIComponent(t).replace(/%2F/g,"/").replace(/'/g,"%27").replace(/\+/g,"%20").replace(/%25/g,"%")}function Pt(t,e){let r=new URL(t),n=r.pathname;return n=n?n.endsWith("/")?`${n}${e}`:`${n}/${e}`:e,r.pathname=n,r.toString()}function ro(t,e,r){let n=new URL(t),i=encodeURIComponent(e),s=r?encodeURIComponent( Line truncated
`)+` `)+`
`+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e),n=this.factory.computeHMACSHA256(r);return e.headers.set(Ce.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${n}`),e}getHeaderValueToSign(e,r){let n=e.headers.get(r);return!n||r===Ce.CONTENT_LENGTH&&n==="0"?"":n}getCanonicalizedHeadersString(e){let r=e.headers.headersArray().filter(i=>i.name.toLowerCase().startsWith(Ce.PREFIX_FOR_STORAGE));r.sort((i,s)=>Zj(i.name.toLowerCase(),s.name.toLowerCase())),r=r.filter((i,s,o)=>!(s>0&&i.name.toLowerCase()===o[s-1].name.toLowerCase()));let n="";return r.forEach(i=>{n+=`${i.name.toLowerCase().trimRight()}:${i.value.trimLeft()} `+this.getCanonicalizedHeadersString(e)+this.getCanonicalizedResourceString(e),n=this.factory.computeHMACSHA256(r);return e.headers.set(Be.AUTHORIZATION,`SharedKey ${this.factory.accountName}:${n}`),e}getHeaderValueToSign(e,r){let n=e.headers.get(r);return!n||r===Be.CONTENT_LENGTH&&n==="0"?"":n}getCanonicalizedHeadersString(e){let r=e.headers.headersArray().filter(i=>i.name.toLowerCase().startsWith(Be.PREFIX_FOR_STORAGE));r.sort((i,s)=>XG(i.name.toLowerCase(),s.name.toLowerCase())),r=r.filter((i,s,o)=>!(s>0&&i.name.toLowerCase()===o[s-1].name.toLowerCase()));let n="";return r.forEach(i=>{n+=`${i.name.toLowerCase().trimRight()}:${i.value.trimLeft()}
`}),n}getCanonicalizedResourceString(e){let r=GE(e.url)||"/",n="";n+=`/${this.factory.accountName}${r}`;let i=Wj(e.url),s={};if(i){let o=[];for(let a in i)if(Object.prototype.hasOwnProperty.call(i,a)){let A=a.toLowerCase();s[A]=i[a],o.push(A)}o.sort();for(let a of o)n+=` `}),n}getCanonicalizedResourceString(e){let r=uC(e.url)||"/",n="";n+=`/${this.factory.accountName}${r}`;let i=VG(e.url),s={};if(i){let o=[];for(let a in i)if(Object.prototype.hasOwnProperty.call(i,a)){let A=a.toLowerCase();s[A]=i[a],o.push(A)}o.sort();for(let a of o)n+=`
${a}:${decodeURIComponent(s[a])}`}return n}},ch=class{create(e,r){throw new Error("Method should be implemented in children classes.")}},ct=class extends ch{constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){return new PE(e,r,this)}computeHMACSHA256(e){return OS.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}},TE=class extends Ah{constructor(e,r){super(e,r)}},ut=class extends ch{create(e,r){return new TE(e,r)}},nS;function Xye(){return nS||(nS=Mr.createDefaultHttpClient()),nS}var Zye="storageBrowserPolicy";function eEe(){return{name:Zye,async sendRequest(t,e){return it.isNode||((t.method==="GET"||t.method==="HEAD")&&(t.url=Gs(t.url,Pi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),t.headers.delete(Ce.COOKIE),t.headers.delete(Ce.CONTENT_LENGTH)),e(t)}}}var tEe="storageRetryPolicy",lh;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(lh||(lh={}));var Ul={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:lh.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},rEe=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"],nEe=new zE.AbortError("The operation was aborted.");function iEe(t={}){var e,r,n,i,s,o;let a=(e=t.retryPolicyType)!==null&&e!==void 0?e:Ul.retryPolicyType,A=(r=t.maxTries)!==null&&r!==void 0?r:Ul.maxTries,c=(n=t.retryDelayInMs)!==null&&n!==void 0?n:Ul.retryDelayInMs,l=(i=t.maxRetryDelayInMs)!==null&&i!==void 0?i:Ul.maxRetryDelayInMs,u=(s=t.secondaryHost)!==null&&s!==void 0?s:Ul.secondaryHost,d=(o=t.tryTimeoutInMs)!==null&&o!==void 0?o:Ul.tryTimeoutInMs;function f({isPrimaryRetry:m,attempt:E,response:C,error:I}){var N,w;if(E>=A)return Xt.info(`RetryPolicy: Attempt(s) ${E} >= maxTries ${A}, no further try.`),!1;if(I){for(let R of rEe)if(I.name.toUpperCase().includes(R)||I.message.toUpperCase().includes(R)||I.code&&I.code.toString().toUpperCase()===R)return Xt.info(`RetryPolicy: Network error ${R} found, will retry.`),!0;if(I?.code==="PARSE_ERROR"&&I?.message.startsWith('Error "Error: Unclosed root tag'))return Xt.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0}if(C||I){let R=(w=(N=C?.status)!==null&&N!==void 0?N:I?.statusCode)!==null&&w!==void 0?w:0;if(!m&&R===404)return Xt.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(R===503||R===500)return Xt.info(`RetryPolicy: Will retry for status code ${R}.`),!0}return!1}function g(m,E){let C=0;if(m)switch(a){case lh.EXPONENTIAL:C=Math.min((Math.pow(2,E-1)-1)*c,l);break;case lh.FIXED:C=c;break}else C=Math.random()*1e3;return Xt.info(`RetryPolicy: Delay for ${C}ms`),C}return{name:tEe,async sendRequest(m,E){d&&(m.url=Gs(m.url,Pi.Parameters.TIMEOUT,String(Math.floor(d/1e3))));let C=m.url,I=u?Vj(m.url,u):void 0,N=!1,w=1,R=!0,T,U;for(;R;){let k=N||!I||!["GET","HEAD","OPTIONS"].includes(m.method)||w%2===1;m.url=k?C:I,T=void 0,U=void 0;try{Xt.info(`RetryPolicy: =====> Try=${w} ${k?"Primary":"Secondary"}`),T=await E(m),N=N||!k&&T.status===404}catch(J){if(Mr.isRestError(J))Xt.error(`RetryPolicy: Caught error, message: ${J.message}, code: ${J.code}`),U=J;else throw Xt.error(`RetryPolicy: Caught error, message: ${it.getErrorMessage(J)}`),J}R=f({isPrimaryRetry:k,attempt:w,response:T,error:U}),R&&await $j(g(k,w),m.abortSignal,nEe),w++}if(T)return T;throw U??new Mr.RestError("RetryPolicy failed without known error.")}}}var sEe="storageSharedKeyCredentialPolicy";function eG(t){function e(s){s.headers.set(Ce.X_MS_DATE,new Date().toUTCString()),s.body&&(typeof s.body=="string"||Buffer.isBuffer(s.body))&&s.body.length>0&&s.headers.set(Ce.CONTENT_LENGTH,Buffer.byteLength(s.body));let o=[s.method.toUpperCase(),r(s,Ce.CONTENT_LANGUAGE),r(s,Ce.CONTENT_ENCODING),r(s,Ce.CONTENT_LENGTH),r(s,Ce.CONTENT_MD5),r(s,Ce.CONTENT_TYPE),r(s,Ce.DATE),r(s,Ce.IF_MODIFIED_SINCE),r(s,Ce.IF_MATCH),r(s,Ce.IF_NONE_MATCH),r(s,Ce.IF_UNMODIFIED_SINCE),r(s,Ce.RANGE)].join(` ${a}:${decodeURIComponent(s[a])}`}return n}},bh=class{create(e,r){throw new Error("Method should be implemented in children classes.")}},dt=class extends bh{constructor(e,r){super(),this.accountName=e,this.accountKey=Buffer.from(r,"base64")}create(e,r){return new eC(e,r,this)}computeHMACSHA256(e){return dR.createHmac("sha256",this.accountKey).update(e,"utf8").digest("base64")}},tC=class extends Qh{constructor(e,r){super(e,r)}},ht=class extends bh{create(e,r){return new tC(e,r)}},kS;function HIe(){return kS||(kS=zr.createDefaultHttpClient()),kS}var jIe="storageBrowserPolicy";function zIe(){return{name:jIe,async sendRequest(t,e){return at.isNode||((t.method==="GET"||t.method==="HEAD")&&(t.url=ro(t.url,zi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),t.headers.delete(Be.COOKIE),t.headers.delete(Be.CONTENT_LENGTH)),e(t)}}}var GIe="storageRetryPolicy",Nh;(function(t){t[t.EXPONENTIAL=0]="EXPONENTIAL",t[t.FIXED=1]="FIXED"})(Nh||(Nh={}));var Zl={maxRetryDelayInMs:120*1e3,maxTries:4,retryDelayInMs:4*1e3,retryPolicyType:Nh.EXPONENTIAL,secondaryHost:"",tryTimeoutInMs:void 0},YIe=["ETIMEDOUT","ESOCKETTIMEDOUT","ECONNREFUSED","ECONNRESET","ENOENT","ENOTFOUND","TIMEOUT","EPIPE","REQUEST_SEND_ERROR"],JIe=new cC.AbortError("The operation was aborted.");function VIe(t={}){var e,r,n,i,s,o;let a=(e=t.retryPolicyType)!==null&&e!==void 0?e:Zl.retryPolicyType,A=(r=t.maxTries)!==null&&r!==void 0?r:Zl.maxTries,c=(n=t.retryDelayInMs)!==null&&n!==void 0?n:Zl.retryDelayInMs,l=(i=t.maxRetryDelayInMs)!==null&&i!==void 0?i:Zl.maxRetryDelayInMs,u=(s=t.secondaryHost)!==null&&s!==void 0?s:Zl.secondaryHost,d=(o=t.tryTimeoutInMs)!==null&&o!==void 0?o:Zl.tryTimeoutInMs;function f({isPrimaryRetry:m,attempt:E,response:C,error:I}){var b,w;if(E>=A)return rr.info(`RetryPolicy: Attempt(s) ${E} >= maxTries ${A}, no further try.`),!1;if(I){for(let v of YIe)if(I.name.toUpperCase().includes(v)||I.message.toUpperCase().includes(v)||I.code&&I.code.toString().toUpperCase()===v)return rr.info(`RetryPolicy: Network error ${v} found, will retry.`),!0;if(I?.code==="PARSE_ERROR"&&I?.message.startsWith('Error "Error: Unclosed root tag'))return rr.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry."),!0}if(C||I){let v=(w=(b=C?.status)!==null&&b!==void 0?b:I?.statusCode)!==null&&w!==void 0?w:0;if(!m&&v===404)return rr.info("RetryPolicy: Secondary access with 404, will retry."),!0;if(v===503||v===500)return rr.info(`RetryPolicy: Will retry for status code ${v}.`),!0}return!1}function g(m,E){let C=0;if(m)switch(a){case Nh.EXPONENTIAL:C=Math.min((Math.pow(2,E-1)-1)*c,l);break;case Nh.FIXED:C=c;break}else C=Math.random()*1e3;return rr.info(`RetryPolicy: Delay for ${C}ms`),C}return{name:GIe,async sendRequest(m,E){d&&(m.url=ro(m.url,zi.Parameters.TIMEOUT,String(Math.floor(d/1e3))));let C=m.url,I=u?JG(m.url,u):void 0,b=!1,w=1,v=!0,T,U;for(;v;){let k=b||!I||!["GET","HEAD","OPTIONS"].includes(m.method)||w%2===1;m.url=k?C:I,T=void 0,U=void 0;try{rr.info(`RetryPolicy: =====> Try=${w} ${k?"Primary":"Secondary"}`),T=await E(m),b=b||!k&&T.status===404}catch(J){if(zr.isRestError(J))rr.error(`RetryPolicy: Caught error, message: ${J.message}, code: ${J.code}`),U=J;else throw rr.error(`RetryPolicy: Caught error, message: ${at.getErrorMessage(J)}`),J}v=f({isPrimaryRetry:k,attempt:w,response:T,error:U}),v&&await WG(g(k,w),m.abortSignal,JIe),w++}if(T)return T;throw U??new zr.RestError("RetryPolicy failed without known error.")}}}var WIe="storageSharedKeyCredentialPolicy";function ZG(t){function e(s){s.headers.set(Be.X_MS_DATE,new Date().toUTCString()),s.body&&(typeof s.body=="string"||Buffer.isBuffer(s.body))&&s.body.length>0&&s.headers.set(Be.CONTENT_LENGTH,Buffer.byteLength(s.body));let o=[s.method.toUpperCase(),r(s,Be.CONTENT_LANGUAGE),r(s,Be.CONTENT_ENCODING),r(s,Be.CONTENT_LENGTH),r(s,Be.CONTENT_MD5),r(s,Be.CONTENT_TYPE),r(s,Be.DATE),r(s,Be.IF_MODIFIED_SINCE),r(s,Be.IF_MATCH),r(s,Be.IF_NONE_MATCH),r(s,Be.IF_UNMODIFIED_SINCE),r(s,Be.RANGE)].join(`
`)+` `)+`
`+n(s)+i(s),a=OS.createHmac("sha256",t.accountKey).update(o,"utf8").digest("base64");s.headers.set(Ce.AUTHORIZATION,`SharedKey ${t.accountName}:${a}`)}function r(s,o){let a=s.headers.get(o);return!a||o===Ce.CONTENT_LENGTH&&a==="0"?"":a}function n(s){let o=[];for(let[A,c]of s.headers)A.toLowerCase().startsWith(Ce.PREFIX_FOR_STORAGE)&&o.push({name:A,value:c});o.sort((A,c)=>Zj(A.name.toLowerCase(),c.name.toLowerCase())),o=o.filter((A,c,l)=>!(c>0&&A.name.toLowerCase()===l[c-1].name.toLowerCase()));let a="";return o.forEach(A=>{a+=`${A.name.toLowerCase().trimRight()}:${A.value.trimLeft()} `+n(s)+i(s),a=dR.createHmac("sha256",t.accountKey).update(o,"utf8").digest("base64");s.headers.set(Be.AUTHORIZATION,`SharedKey ${t.accountName}:${a}`)}function r(s,o){let a=s.headers.get(o);return!a||o===Be.CONTENT_LENGTH&&a==="0"?"":a}function n(s){let o=[];for(let[A,c]of s.headers)A.toLowerCase().startsWith(Be.PREFIX_FOR_STORAGE)&&o.push({name:A,value:c});o.sort((A,c)=>XG(A.name.toLowerCase(),c.name.toLowerCase())),o=o.filter((A,c,l)=>!(c>0&&A.name.toLowerCase()===l[c-1].name.toLowerCase()));let a="";return o.forEach(A=>{a+=`${A.name.toLowerCase().trimRight()}:${A.value.trimLeft()}
`}),a}function i(s){let o=GE(s.url)||"/",a="";a+=`/${t.accountName}${o}`;let A=Wj(s.url),c={};if(A){let l=[];for(let u in A)if(Object.prototype.hasOwnProperty.call(A,u)){let d=u.toLowerCase();c[d]=A[u],l.push(d)}l.sort();for(let u of l)a+=` `}),a}function i(s){let o=uC(s.url)||"/",a="";a+=`/${t.accountName}${o}`;let A=VG(s.url),c={};if(A){let l=[];for(let u in A)if(Object.prototype.hasOwnProperty.call(A,u)){let d=u.toLowerCase();c[d]=A[u],l.push(d)}l.sort();for(let u of l)a+=`
${u}:${decodeURIComponent(c[u])}`}return a}return{name:sEe,async sendRequest(s,o){return e(s),o(s)}}}var OE=class extends jl{constructor(e,r){super(e,r)}async sendRequest(e){return it.isNode?this._nextPolicy.sendRequest(e):((e.method.toUpperCase()==="GET"||e.method.toUpperCase()==="HEAD")&&(e.url=Gs(e.url,Pi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),e.headers.remove(Ce.COOKIE),e.headers.remove(Ce.CONTENT_LENGTH),this._nextPolicy.sendRequest(e))}},ME=class{create(e,r){return new OE(e,r)}},oEe="StorageCorrectContentLengthPolicy";function aEe(){function t(e){e.body&&(typeof e.body=="string"||Buffer.isBuffer(e.body))&&e.body.length>0&&e.headers.set(Ce.CONTENT_LENGTH,Buffer.byteLength(e.body))}return{name:oEe,async sendRequest(e,r){return t(e),r(e)}}}function jo(t){if(!t||typeof t!="object")return!1;let e=t;return Array.isArray(e.factories)&&typeof e.options=="object"&&typeof e.toServiceClientOptions=="function"}var uh=class{constructor(e,r={}){this.factories=e,this.options=r}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}};function lt(t,e={}){t||(t=new ut);let r=new uh([],e);return r._credential=t,r}function AEe(t){let e=[cEe,nG,lEe,uEe,dEe,fEe,gEe];if(t.factories.length){let r=t.factories.filter(n=>!e.some(i=>i(n)));if(r.length){let n=r.some(i=>hEe(i));return{wrappedPolicies:HE.createRequestPolicyFactoryPolicy(r),afterRetry:n}}}}function tG(t){var e;let r=t.options,{httpClient:n}=r,i=q.__rest(r,["httpClient"]),s=t._coreHttpClient;s||(s=n?HE.convertHttpClient(n):Xye(),t._coreHttpClient=s);let o=t._corePipeline;if(!o){let a=`azsdk-js-azure-storage-blob/${Gj}`,A=i.userAgentOptions&&i.userAgentOptions.userAgentPrefix?`${i.userAgentOptions.userAgentPrefix} ${a}`:`${a}`;o=sh.createClientPipeline(Object.assign(Object.assign({},i),{loggingOptions:{additionalAllowedHeaderNames:_ye,additionalAllowedQueryParameters:kye,logger:Xt.info},userAgentOptions:{userAgentPrefix:A},serializationOptions:{stringifyXML:sS.stringifyXML,serializerOptions:{xml:{xmlCharKey:"#"}}},deserializationOptions:{parseXML:sS.parseXML,serializerOptions:{xml:{xmlCharKey:"#"}}}})),o.removePolicy({phase:"Retry"}),o.removePolicy({name:Mr.decompressResponsePolicyName}),o.addPolicy(aEe()),o.addPolicy(iEe(i.retryOptions),{phase:"Retry"}),o.addPolicy(eEe());let c=AEe(t);c&&o.addPolicy(c.wrappedPolicies,c.afterRetry?{afterPhase:"Retry"}:void 0);let l=rG(t);Ai.isTokenCredential(l)?o.addPolicy(Mr.bearerTokenAuthenticationPolicy({credential:l,scopes:(e=i.audience)!==null&&e!==void 0?e:US,challengeCallbacks:{authorizeRequestOnChallenge:sh.authorizeRequestOnTenantChallenge}}),{phase:"Sign"}):l instanceof ct&&o.addPolicy(eG({accountName:l.accountName,accountKey:l.accountKey}),{phase:"Sign"}),t._corePipeline=o}return Object.assign(Object.assign({},i),{allowInsecureConnection:!0,httpClient:s,pipeline:o})}function rG(t){if(t._credential)return t._credential;let e=new ut;for(let r of t.factories)if(Ai.isTokenCredential(r.credential))e=r.credential;else if(nG(r))return r;return e}function nG(t){return t instanceof ct?!0:t.constructor.name==="StorageSharedKeyCredential"}function cEe(t){return t instanceof ut?!0:t.constructor.name==="AnonymousCredential"}function lEe(t){return Ai.isTokenCredential(t.credential)}function uEe(t){return t instanceof ME?!0:t.constructor.name==="StorageBrowserPolicyFactory"}function dEe(t){return t instanceof kE?!0:t.constructor.name==="StorageRetryPolicyFactory"}function fEe(t){return t.constructor.name==="TelemetryPolicyFactory"}function hEe(t){return t.constructor.name==="InjectorPolicyFactory"}function gEe(t){let e=["GenerateClientRequestIdPolicy","TracingPolicy","LogPolicy","ProxyPolicy","DisableResponseDecompressionPolicy","KeepAlivePolicy","DeserializationPolicy"],r={sendRequest:async o=>({request:o,headers:o.headers.clone(),status:500})},n={log(o,a){},shouldLog(o){return!1}},s=t.create(r,n).constructor.name;return e.some(o=>s.startsWith(o))}var HS={serializedName:"BlobServiceProperties",xmlName:"StorageServiceProperties",type:{name:"Composite",className:"BlobServiceProperties",modelProperties:{blobAnalyticsLogging:{serializedName:"Logging",xmlName:"Logging",type:{name:"Composite",className:"Logging"}},hourMetrics:{serializedName:"HourMetrics",xmlName:"HourMetrics",type:{name:"Composite",className:"Metrics"}},minuteMetrics:{serializedName:"MinuteMetrics",xmlName:"MinuteMetrics",type:{name:"Composite",className:"Metrics"}},cors:{serializedName:"Cors",xmlName:"Cors",xmlIsWrapped:!0,xmlElementName:"CorsRule",type:{name:"Sequence",element:{type:{name:"Composite",className:"CorsRule"}}}},defaultServiceVersion:{serializedName:"DefaultServiceVersion",xmlName:"DefaultServiceVersion",type:{name:"String"}},deleteRetentionPolicy:{serializedName:"DeleteRetentionPolicy",xmlName:"DeleteRetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}},staticWebsite:{serializedName:"StaticWebsite",xmlName:"StaticWebsite",type:{name:"Composite",className:"StaticWe Line truncated ${u}:${decodeURIComponent(c[u])}`}return a}return{name:WIe,async sendRequest(s,o){return e(s),o(s)}}}var rC=class extends nu{constructor(e,r){super(e,r)}async sendRequest(e){return at.isNode?this._nextPolicy.sendRequest(e):((e.method.toUpperCase()==="GET"||e.method.toUpperCase()==="HEAD")&&(e.url=ro(e.url,zi.Parameters.FORCE_BROWSER_NO_CACHE,new Date().getTime().toString())),e.headers.remove(Be.COOKIE),e.headers.remove(Be.CONTENT_LENGTH),this._nextPolicy.sendRequest(e))}},nC=class{create(e,r){return new rC(e,r)}},$Ie="StorageCorrectContentLengthPolicy";function KIe(){function t(e){e.body&&(typeof e.body=="string"||Buffer.isBuffer(e.body))&&e.body.length>0&&e.headers.set(Be.CONTENT_LENGTH,Buffer.byteLength(e.body))}return{name:$Ie,async sendRequest(e,r){return t(e),r(e)}}}function ta(t){if(!t||typeof t!="object")return!1;let e=t;return Array.isArray(e.factories)&&typeof e.options=="object"&&typeof e.toServiceClientOptions=="function"}var wh=class{constructor(e,r={}){this.factories=e,this.options=r}toServiceClientOptions(){return{httpClient:this.options.httpClient,requestPolicyFactories:this.factories}}};function ft(t,e={}){t||(t=new ht);let r=new wh([],e);return r._credential=t,r}function XIe(t){let e=[ZIe,rY,eBe,tBe,rBe,nBe,sBe];if(t.factories.length){let r=t.factories.filter(n=>!e.some(i=>i(n)));if(r.length){let n=r.some(i=>iBe(i));return{wrappedPolicies:AC.createRequestPolicyFactoryPolicy(r),afterRetry:n}}}}function eY(t){var e;let r=t.options,{httpClient:n}=r,i=q.__rest(r,["httpClient"]),s=t._coreHttpClient;s||(s=n?AC.convertHttpClient(n):HIe(),t._coreHttpClient=s);let o=t._corePipeline;if(!o){let a=`azsdk-js-azure-storage-blob/${zG}`,A=i.userAgentOptions&&i.userAgentOptions.userAgentPrefix?`${i.userAgentOptions.userAgentPrefix} ${a}`:`${a}`;o=Ch.createClientPipeline(Object.assign(Object.assign({},i),{loggingOptions:{additionalAllowedHeaderNames:BIe,additionalAllowedQueryParameters:QIe,logger:rr.info},userAgentOptions:{userAgentPrefix:A},serializationOptions:{stringifyXML:TS.stringifyXML,serializerOptions:{xml:{xmlCharKey:"#"}}},deserializationOptions:{parseXML:TS.parseXML,serializerOptions:{xml:{xmlCharKey:"#"}}}})),o.removePolicy({phase:"Retry"}),o.removePolicy({name:zr.decompressResponsePolicyName}),o.addPolicy(KIe()),o.addPolicy(VIe(i.retryOptions),{phase:"Retry"}),o.addPolicy(zIe());let c=XIe(t);c&&o.addPolicy(c.wrappedPolicies,c.afterRetry?{afterPhase:"Retry"}:void 0);let l=tY(t);mi.isTokenCredential(l)?o.addPolicy(zr.bearerTokenAuthenticationPolicy({credential:l,scopes:(e=i.audience)!==null&&e!==void 0?e:mR,challengeCallbacks:{authorizeRequestOnChallenge:Ch.authorizeRequestOnTenantChallenge}}),{phase:"Sign"}):l instanceof dt&&o.addPolicy(ZG({accountName:l.accountName,accountKey:l.accountKey}),{phase:"Sign"}),t._corePipeline=o}return Object.assign(Object.assign({},i),{allowInsecureConnection:!0,httpClient:s,pipeline:o})}function tY(t){if(t._credential)return t._credential;let e=new ht;for(let r of t.factories)if(mi.isTokenCredential(r.credential))e=r.credential;else if(rY(r))return r;return e}function rY(t){return t instanceof dt?!0:t.constructor.name==="StorageSharedKeyCredential"}function ZIe(t){return t instanceof ht?!0:t.constructor.name==="AnonymousCredential"}function eBe(t){return mi.isTokenCredential(t.credential)}function tBe(t){return t instanceof nC?!0:t.constructor.name==="StorageBrowserPolicyFactory"}function rBe(t){return t instanceof ZE?!0:t.constructor.name==="StorageRetryPolicyFactory"}function nBe(t){return t.constructor.name==="TelemetryPolicyFactory"}function iBe(t){return t.constructor.name==="InjectorPolicyFactory"}function sBe(t){let e=["GenerateClientRequestIdPolicy","TracingPolicy","LogPolicy","ProxyPolicy","DisableResponseDecompressionPolicy","KeepAlivePolicy","DeserializationPolicy"],r={sendRequest:async o=>({request:o,headers:o.headers.clone(),status:500})},n={log(o,a){},shouldLog(o){return!1}},s=t.create(r,n).constructor.name;return e.some(o=>s.startsWith(o))}var yR={serializedName:"BlobServiceProperties",xmlName:"StorageServiceProperties",type:{name:"Composite",className:"BlobServiceProperties",modelProperties:{blobAnalyticsLogging:{serializedName:"Logging",xmlName:"Logging",type:{name:"Composite",className:"Logging"}},hourMetrics:{serializedName:"HourMetrics",xmlName:"HourMetrics",type:{name:"Composite",className:"Metrics"}},minuteMetrics:{serializedName:"MinuteMetrics",xmlName:"MinuteMetrics",type:{name:"Composite",className:"Metrics"}},cors:{serializedName:"Cors",xmlName:"Cors",xmlIsWrapped:!0,xmlElementName:"CorsRule",type:{name:"Sequence",element:{type:{name:"Composite",className:"CorsRule"}}}},defaultServiceVersion:{serializedName:"DefaultServiceVersion",xmlName:"DefaultServiceVersion",type:{name:"String"}},deleteRetentionPolicy:{serializedName:"DeleteRetentionPolicy",xmlName:"DeleteRetentionPolicy",type:{name:"Composite",className:"RetentionPolicy"}},staticWebsite:{serializedName:"StaticWebsite",xmlName:"StaticWebsite",type:{name:"Composite",className:"StaticWe Line truncated
`),s=e.computeHMACSHA256(i);return{sasQueryParameters:new ls(t.version,s,n,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:i}}function ZIe(t,e){if(t=hu(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=Ys.parse(t.permissions.toString()).toString():i=Js.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?Ke(t.startsOn,!1):"",t.expiresOn?Ke(t.expiresOn,!1):"",fu(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(` `),s=e.computeHMACSHA256(i);return{sasQueryParameters:new Cs(t.version,s,n,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:i}}function jbe(t,e){if(t=xu(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=no.parse(t.permissions.toString()).toString():i=io.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?et(t.startsOn,!1):"",t.expiresOn?et(t.expiresOn,!1):"",wu(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
`),o=e.computeHMACSHA256(s);return{sasQueryParameters:new ls(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}function eBe(t,e){if(t=hu(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=Ys.parse(t.permissions.toString()).toString():i=Js.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?Ke(t.startsOn,!1):"",t.expiresOn?Ke(t.expiresOn,!1):"",fu(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(` `),o=e.computeHMACSHA256(s);return{sasQueryParameters:new Cs(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType),stringToSign:s}}function zbe(t,e){if(t=xu(t),!t.identifier&&!(t.permissions&&t.expiresOn))throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when 'identifier' is not provided.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=no.parse(t.permissions.toString()).toString():i=io.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?et(t.startsOn,!1):"",t.expiresOn?et(t.expiresOn,!1):"",wu(e.accountName,t.containerName,t.blobName),t.identifier,t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl?t.cacheControl:"",t.contentDisposition?t.contentDisposition:"",t.contentEncoding?t.contentEncoding:"",t.contentLanguage?t.contentLanguage:"",t.contentType?t.contentType:""].join(`
`),o=e.computeHMACSHA256(s);return{sasQueryParameters:new ls(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void 0,void 0,void 0,t.encryptionScope),stringToSign:s}}function tBe(t,e){if(t=hu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=Ys.parse(t.permissions.toString()).toString():i=Js.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?Ke(t.startsOn,!1):"",t.expiresOn?Ke(t.expiresOn,!1):"",fu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ke(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ke(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(` `),o=e.computeHMACSHA256(s);return{sasQueryParameters:new Cs(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,void 0,void 0,void 0,t.encryptionScope),stringToSign:s}}function Gbe(t,e){if(t=xu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=no.parse(t.permissions.toString()).toString():i=io.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?et(t.startsOn,!1):"",t.expiresOn?et(t.expiresOn,!1):"",wu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?et(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?et(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),o=e.computeHMACSHA256(s);return{sasQueryParameters:new ls(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey),stringToSign:s}}function rBe(t,e){if(t=hu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=Ys.parse(t.permissions.toString()).toString():i=Js.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?Ke(t.startsOn,!1):"",t.expiresOn?Ke(t.expiresOn,!1):"",fu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ke(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ke(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(` `),o=e.computeHMACSHA256(s);return{sasQueryParameters:new Cs(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey),stringToSign:s}}function Ybe(t,e){if(t=xu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=no.parse(t.permissions.toString()).toString():i=io.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?et(t.startsOn,!1):"",t.expiresOn?et(t.expiresOn,!1):"",wu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?et(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?et(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),o=e.computeHMACSHA256(s);return{sasQueryParameters:new ls(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId),stringToSign:s}}function nBe(t,e){if(t=hu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=Ys.parse(t.permissions.toString()).toString():i=Js.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?Ke(t.startsOn,!1):"",t.expiresOn?Ke(t.expiresOn,!1):"",fu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?Ke(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?Ke(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(` `),o=e.computeHMACSHA256(s);return{sasQueryParameters:new Cs(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId),stringToSign:s}}function Jbe(t,e){if(t=xu(t),!t.permissions||!t.expiresOn)throw new RangeError("Must provide 'permissions' and 'expiresOn' for Blob SAS generation when generating user delegation SAS.");let r="c",n=t.snapshotTime;t.blobName&&(r="b",t.snapshotTime?r="bs":t.versionId&&(r="bv",n=t.versionId));let i;t.permissions&&(t.blobName?i=no.parse(t.permissions.toString()).toString():i=io.parse(t.permissions.toString()).toString());let s=[i||"",t.startsOn?et(t.startsOn,!1):"",t.expiresOn?et(t.expiresOn,!1):"",wu(e.accountName,t.containerName,t.blobName),e.userDelegationKey.signedObjectId,e.userDelegationKey.signedTenantId,e.userDelegationKey.signedStartsOn?et(e.userDelegationKey.signedStartsOn,!1):"",e.userDelegationKey.signedExpiresOn?et(e.userDelegationKey.signedExpiresOn,!1):"",e.userDelegationKey.signedService,e.userDelegationKey.signedVersion,t.preauthorizedAgentObjectId,void 0,t.correlationId,t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",t.version,r,n,t.encryptionScope,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType].join(`
`),o=e.computeHMACSHA256(s);return{sasQueryParameters:new ls(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope),stringToSign:s}}function fu(t,e,r){let n=[`/blob/${t}/${e}`];return r&&n.push(`/${r}`),n.join("")}function hu(t){let e=t.version?t.version:FS;if(t.snapshotTime&&e<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void 0&&t.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void 0&&t.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");return t.version=e,t}var gh=class{get leaseId(){return this._leaseId}get url(){return this._url}constructor(e,r){let n=e.storageClientContext;this._url=e.url,e.name===void 0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=it.randomUUID()),this._leaseId=r}async acquireLease(e,r={}){var n,i,s,o,a;if(this._isContainer&&(!((n=r.conditions)===null||n===void 0)&&n.ifMatch&&((i=r.conditions)===null||i===void 0?void 0:i.ifMatch)!==cs||!((s=r.conditions)===null||s===void 0)&&s.ifNoneMatch&&((o=r.conditions)===null||o===void 0?void 0:o.ifNoneMatch)!==cs||!((a=r.conditions)===null||a===void 0)&&a.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-acquireLease",r,async A=>{var c;return V(await this._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(c=r.conditions)===null||c===void 0?void 0:c.tagConditions}),proposedLeaseId:this._leaseId,tracingOptions:A.tracingOptions}))})}async changeLease(e,r={}){var n,i,s,o,a;if(this._isContainer&&(!((n=r.conditions)===null||n===void 0)&&n.ifMatch&&((i=r.conditions)===null||i===void 0?void 0:i.ifMatch)!==cs||!((s=r.conditions)===null||s===void 0)&&s.ifNoneMatch&&((o=r.conditions)===null||o===void 0?void 0:o.ifNoneMatch)!==cs||!((a=r.conditions)===null||a===void 0)&&a.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-changeLease",r,async A=>{var c;let l=V(await this._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(c=r.conditions)===null||c===void 0?void 0:c.tagConditions}),tracingOptions:A.tracingOptions}));return this._leaseId=e,l})}async releaseLease(e={}){var r,n,i,s,o;if(this._isContainer&&(!((r=e.conditions)===null||r===void 0)&&r.ifMatch&&((n=e.conditions)===null||n===void 0?void 0:n.ifMatch)!==cs||!((i=e.conditions)===null||i===void 0)&&i.ifNoneMatch&&((s=e.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==cs||!((o=e.conditions)===null||o===void 0)&&o.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-releaseLease",e,async a=>{var A;return V(await this._containerOrBlobOperation.releaseLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:Objec Line truncated `),o=e.computeHMACSHA256(s);return{sasQueryParameters:new Cs(t.version,o,i,void 0,void 0,t.protocol,t.startsOn,t.expiresOn,t.ipRange,t.identifier,r,t.cacheControl,t.contentDisposition,t.contentEncoding,t.contentLanguage,t.contentType,e.userDelegationKey,t.preauthorizedAgentObjectId,t.correlationId,t.encryptionScope),stringToSign:s}}function wu(t,e,r){let n=[`/blob/${t}/${e}`];return r&&n.push(`/${r}`),n.join("")}function xu(t){let e=t.version?t.version:gR;if(t.snapshotTime&&e<"2018-11-09")throw RangeError("'version' must be >= '2018-11-09' when providing 'snapshotTime'.");if(t.blobName===void 0&&t.snapshotTime)throw RangeError("Must provide 'blobName' when providing 'snapshotTime'.");if(t.versionId&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'versionId'.");if(t.blobName===void 0&&t.versionId)throw RangeError("Must provide 'blobName' when providing 'versionId'.");if(t.permissions&&t.permissions.setImmutabilityPolicy&&e<"2020-08-04")throw RangeError("'version' must be >= '2020-08-04' when provided 'i' permission.");if(t.permissions&&t.permissions.deleteVersion&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'x' permission.");if(t.permissions&&t.permissions.permanentDelete&&e<"2019-10-10")throw RangeError("'version' must be >= '2019-10-10' when providing 'y' permission.");if(t.permissions&&t.permissions.tag&&e<"2019-12-12")throw RangeError("'version' must be >= '2019-12-12' when providing 't' permission.");if(e<"2020-02-10"&&t.permissions&&(t.permissions.move||t.permissions.execute))throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");if(e<"2021-04-10"&&t.permissions&&t.permissions.filterByTags)throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");if(e<"2020-02-10"&&(t.preauthorizedAgentObjectId||t.correlationId))throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");if(t.encryptionScope&&e<"2020-12-06")throw RangeError("'version' must be >= '2020-12-06' when provided 'encryptionScope' in SAS.");return t.version=e,t}var vh=class{get leaseId(){return this._leaseId}get url(){return this._url}constructor(e,r){let n=e.storageClientContext;this._url=e.url,e.name===void 0?(this._isContainer=!0,this._containerOrBlobOperation=n.container):(this._isContainer=!1,this._containerOrBlobOperation=n.blob),r||(r=at.randomUUID()),this._leaseId=r}async acquireLease(e,r={}){var n,i,s,o,a;if(this._isContainer&&(!((n=r.conditions)===null||n===void 0)&&n.ifMatch&&((i=r.conditions)===null||i===void 0?void 0:i.ifMatch)!==Es||!((s=r.conditions)===null||s===void 0)&&s.ifNoneMatch&&((o=r.conditions)===null||o===void 0?void 0:o.ifNoneMatch)!==Es||!((a=r.conditions)===null||a===void 0)&&a.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-acquireLease",r,async A=>{var c;return V(await this._containerOrBlobOperation.acquireLease({abortSignal:r.abortSignal,duration:e,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(c=r.conditions)===null||c===void 0?void 0:c.tagConditions}),proposedLeaseId:this._leaseId,tracingOptions:A.tracingOptions}))})}async changeLease(e,r={}){var n,i,s,o,a;if(this._isContainer&&(!((n=r.conditions)===null||n===void 0)&&n.ifMatch&&((i=r.conditions)===null||i===void 0?void 0:i.ifMatch)!==Es||!((s=r.conditions)===null||s===void 0)&&s.ifNoneMatch&&((o=r.conditions)===null||o===void 0?void 0:o.ifNoneMatch)!==Es||!((a=r.conditions)===null||a===void 0)&&a.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-changeLease",r,async A=>{var c;let l=V(await this._containerOrBlobOperation.changeLease(this._leaseId,e,{abortSignal:r.abortSignal,modifiedAccessConditions:Object.assign(Object.assign({},r.conditions),{ifTags:(c=r.conditions)===null||c===void 0?void 0:c.tagConditions}),tracingOptions:A.tracingOptions}));return this._leaseId=e,l})}async releaseLease(e={}){var r,n,i,s,o;if(this._isContainer&&(!((r=e.conditions)===null||r===void 0)&&r.ifMatch&&((n=e.conditions)===null||n===void 0?void 0:n.ifMatch)!==Es||!((i=e.conditions)===null||i===void 0)&&i.ifNoneMatch&&((s=e.conditions)===null||s===void 0?void 0:s.ifNoneMatch)!==Es||!((o=e.conditions)===null||o===void 0)&&o.tagConditions))throw new RangeError("The IfMatch, IfNoneMatch and tags access conditions are ignored by the service. Values other than undefined or their default values are not acceptable.");return F.withSpan("BlobLeaseClient-releaseLease",e,async a=>{var A;return V(await this._containerOrBlobOperation.releaseLease(this._leaseId,{abortSignal:e.abortSignal,modifiedAccessConditions:Objec Line truncated
`):o=[e.accountName,n,i,s,t.startsOn?Ke(t.startsOn,!1):"",Ke(t.expiresOn,!1),t.ipRange?Vs(t.ipRange):"",t.protocol?t.protocol:"",r,""].join(` `):o=[e.accountName,n,i,s,t.startsOn?et(t.startsOn,!1):"",et(t.expiresOn,!1),t.ipRange?so(t.ipRange):"",t.protocol?t.protocol:"",r,""].join(`
`);let a=e.computeHMACSHA256(o);return{sasQueryParameters:new ls(r,a,n.toString(),i,s,t.protocol,t.startsOn,t.expiresOn,t.ipRange,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,t.encryptionScope),stringToSign:o}}var TS=class t extends dh{static fromConnectionString(e,r){r=r||{};let n=Wl(e);if(n.kind==="AccountConnString")if(it.isNode){let i=new ct(n.accountName,n.accountKey);r.proxyOptions||(r.proxyOptions=Mr.getDefaultProxySettings(n.proxyUri));let s=lt(i,r);return new t(n.url,s)}else throw new Error("Account connection string is only supported in Node.js environment");else if(n.kind==="SASConnString"){let i=lt(new ut,r);return new t(n.url+"?"+n.accountSas,i)}else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}constructor(e,r,n){let i;jo(r)?i=r:it.isNode&&r instanceof ct||r instanceof ut||Ai.isTokenCredential(r)?i=lt(r,n):i=lt(new ut,n),super(e,i),this.serviceContext=this.storageClientContext.service}getContainerClient(e){return new UE(Rt(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,r={}){return F.withSpan("BlobServiceClient-createContainer",r,async n=>{let i=this.getContainerClient(e),s=await i.create(n);return{containerClient:i,containerCreateResponse:s}})}async deleteContainer(e,r={}){return F.withSpan("BlobServiceClient-deleteContainer",r,async n=>this.getContainerClient(e).delete(n))}async undeleteContainer(e,r,n={}){return F.withSpan("BlobServiceClient-undeleteContainer",n,async i=>{let s=this.getContainerClient(n.destinationContainerName||e),o=s.storageClientContext.container,a=V(await o.restore({deletedContainerName:e,deletedContainerVersion:r,tracingOptions:i.tracingOptions}));return{containerClient:s,containerUndeleteResponse:a}})}async renameContainer(e,r,n={}){return F.withSpan("BlobServiceClient-renameContainer",n,async i=>{var s;let o=this.getContainerClient(r),a=o.storageClientContext.container,A=V(await a.rename(e,Object.assign(Object.assign({},i),{sourceLeaseId:(s=n.sourceCondition)===null||s===void 0?void 0:s.leaseId})));return{containerClient:o,containerRenameResponse:A}})}async getProperties(e={}){return F.withSpan("BlobServiceClient-getProperties",e,async r=>V(await this.serviceContext.getProperties({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async setProperties(e,r={}){return F.withSpan("BlobServiceClient-setProperties",r,async n=>V(await this.serviceContext.setProperties(e,{abortSignal:r.abortSignal,tracingOptions:n.tracingOptions})))}async getStatistics(e={}){return F.withSpan("BlobServiceClient-getStatistics",e,async r=>V(await this.serviceContext.getStatistics({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async getAccountInfo(e={}){return F.withSpan("BlobServiceClient-getAccountInfo",e,async r=>V(await this.serviceContext.getAccountInfo({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async listContainersSegment(e,r={}){return F.withSpan("BlobServiceClient-listContainersSegment",r,async n=>V(await this.serviceContext.listContainersSegment(Object.assign(Object.assign({abortSignal:r.abortSignal,marker:e},r),{include:typeof r.include=="string"?[r.include]:r.include,tracingOptions:n.tracingOptions}))))}async findBlobsByTagsSegment(e,r,n={}){return F.withSpan("BlobServiceClient-findBlobsByTagsSegment",n,async i=>{let s=V(await this.serviceContext.filterBlobs({abortSignal:n.abortSignal,where:e,marker:r,maxPageSize:n.maxPageSize,tracingOptions:i.tracingOptions}));return Object.assign(Object.assign({},s),{_response:s._response,blobs:s.blobs.map(a=>{var A;let c="";return((A=a.tags)===null||A===void 0?void 0:A.blobTagSet.length)===1&&(c=a.tags.blobTagSet[0].value),Object.assign(Object.assign({},a),{tags:rh(a.tags),tagValue:c})})})})}findBlobsByTagsSegments(e,r){return q.__asyncGenerator(this,arguments,function*(i,s,o={}){let a;if(s||s===void 0)do a=yield q.__await(this.findBlobsByTagsSegment(i,s,o)),a.blobs=a.blobs||[],s=a.continuationToken,yield yield q.__await(a);while(s)})}findBlobsByTagsItems(e){return q.__asyncGenerator(this,arguments,function*(n,i={}){var s,o,a,A;let c;try{for(var l=!0,u=q.__asyncValues(this.findBlobsByTagsSegments(n,c,i)),d;d=yield q.__await(u.next()),s=d.done,!s;l=!0){A=d.value,l=!1;let f=A;yield q.__await(yield*q.__asyncDelegator(q.__asyncValues(f.blobs)))}}catch(f){o={error:f}}finally{try{!l&&!s&&(a=u.return)&&(yield q.__await(a.call(u)))}finally{if(o)throw o.error}}})}findBlobsByTags(e,r={}){let n=Object.assign({},r),i=this.findBlobsByTagsItems(e,n);return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(s={})=>this.findBlobsByTagsSegments(e,s.continuationToken,Object.assign({maxPageSize:s.maxPageSize},n))}}listSegments(e){return q.__asyncGenerator(this,arguments,function*(n,i={}){let s;if(n||n===void 0)do s=yield q.__await(this.listContainersSegment(n,i)),s.containerItems=s.containerItems||[],n=s.continuationToken,yield yield q.__await(yield q.__await(s));while(n)})}listItems(){retur Line truncated `);let a=e.computeHMACSHA256(o);return{sasQueryParameters:new Cs(r,a,n.toString(),i,s,t.protocol,t.startsOn,t.expiresOn,t.ipRange,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,t.encryptionScope),stringToSign:o}}var uR=class t extends xh{static fromConnectionString(e,r){r=r||{};let n=Au(e);if(n.kind==="AccountConnString")if(at.isNode){let i=new dt(n.accountName,n.accountKey);r.proxyOptions||(r.proxyOptions=zr.getDefaultProxySettings(n.proxyUri));let s=ft(i,r);return new t(n.url,s)}else throw new Error("Account connection string is only supported in Node.js environment");else if(n.kind==="SASConnString"){let i=ft(new ht,r);return new t(n.url+"?"+n.accountSas,i)}else throw new Error("Connection string must be either an Account connection string or a SAS connection string")}constructor(e,r,n){let i;ta(r)?i=r:at.isNode&&r instanceof dt||r instanceof ht||mi.isTokenCredential(r)?i=ft(r,n):i=ft(new ht,n),super(e,i),this.serviceContext=this.storageClientContext.service}getContainerClient(e){return new oC(Pt(this.url,encodeURIComponent(e)),this.pipeline)}async createContainer(e,r={}){return F.withSpan("BlobServiceClient-createContainer",r,async n=>{let i=this.getContainerClient(e),s=await i.create(n);return{containerClient:i,containerCreateResponse:s}})}async deleteContainer(e,r={}){return F.withSpan("BlobServiceClient-deleteContainer",r,async n=>this.getContainerClient(e).delete(n))}async undeleteContainer(e,r,n={}){return F.withSpan("BlobServiceClient-undeleteContainer",n,async i=>{let s=this.getContainerClient(n.destinationContainerName||e),o=s.storageClientContext.container,a=V(await o.restore({deletedContainerName:e,deletedContainerVersion:r,tracingOptions:i.tracingOptions}));return{containerClient:s,containerUndeleteResponse:a}})}async renameContainer(e,r,n={}){return F.withSpan("BlobServiceClient-renameContainer",n,async i=>{var s;let o=this.getContainerClient(r),a=o.storageClientContext.container,A=V(await a.rename(e,Object.assign(Object.assign({},i),{sourceLeaseId:(s=n.sourceCondition)===null||s===void 0?void 0:s.leaseId})));return{containerClient:o,containerRenameResponse:A}})}async getProperties(e={}){return F.withSpan("BlobServiceClient-getProperties",e,async r=>V(await this.serviceContext.getProperties({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async setProperties(e,r={}){return F.withSpan("BlobServiceClient-setProperties",r,async n=>V(await this.serviceContext.setProperties(e,{abortSignal:r.abortSignal,tracingOptions:n.tracingOptions})))}async getStatistics(e={}){return F.withSpan("BlobServiceClient-getStatistics",e,async r=>V(await this.serviceContext.getStatistics({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async getAccountInfo(e={}){return F.withSpan("BlobServiceClient-getAccountInfo",e,async r=>V(await this.serviceContext.getAccountInfo({abortSignal:e.abortSignal,tracingOptions:r.tracingOptions})))}async listContainersSegment(e,r={}){return F.withSpan("BlobServiceClient-listContainersSegment",r,async n=>V(await this.serviceContext.listContainersSegment(Object.assign(Object.assign({abortSignal:r.abortSignal,marker:e},r),{include:typeof r.include=="string"?[r.include]:r.include,tracingOptions:n.tracingOptions}))))}async findBlobsByTagsSegment(e,r,n={}){return F.withSpan("BlobServiceClient-findBlobsByTagsSegment",n,async i=>{let s=V(await this.serviceContext.filterBlobs({abortSignal:n.abortSignal,where:e,marker:r,maxPageSize:n.maxPageSize,tracingOptions:i.tracingOptions}));return Object.assign(Object.assign({},s),{_response:s._response,blobs:s.blobs.map(a=>{var A;let c="";return((A=a.tags)===null||A===void 0?void 0:A.blobTagSet.length)===1&&(c=a.tags.blobTagSet[0].value),Object.assign(Object.assign({},a),{tags:ph(a.tags),tagValue:c})})})})}findBlobsByTagsSegments(e,r){return q.__asyncGenerator(this,arguments,function*(i,s,o={}){let a;if(s||s===void 0)do a=yield q.__await(this.findBlobsByTagsSegment(i,s,o)),a.blobs=a.blobs||[],s=a.continuationToken,yield yield q.__await(a);while(s)})}findBlobsByTagsItems(e){return q.__asyncGenerator(this,arguments,function*(n,i={}){var s,o,a,A;let c;try{for(var l=!0,u=q.__asyncValues(this.findBlobsByTagsSegments(n,c,i)),d;d=yield q.__await(u.next()),s=d.done,!s;l=!0){A=d.value,l=!1;let f=A;yield q.__await(yield*q.__asyncDelegator(q.__asyncValues(f.blobs)))}}catch(f){o={error:f}}finally{try{!l&&!s&&(a=u.return)&&(yield q.__await(a.call(u)))}finally{if(o)throw o.error}}})}findBlobsByTags(e,r={}){let n=Object.assign({},r),i=this.findBlobsByTagsItems(e,n);return{next(){return i.next()},[Symbol.asyncIterator](){return this},byPage:(s={})=>this.findBlobsByTagsSegments(e,s.continuationToken,Object.assign({maxPageSize:s.maxPageSize},n))}}listSegments(e){return q.__asyncGenerator(this,arguments,function*(n,i={}){let s;if(n||n===void 0)do s=yield q.__await(this.listContainersSegment(n,i)),s.containerItems=s.containerItems||[],n=s.continuationToken,yield yield q.__await(yield q.__await(s));while(n)})}listItems(){retur Line truncated
If you are using self-hosted runners, please make sure your runner has access to all GitHub endpoints: https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/about-self-hosted-runners#communication-between-self-hosted-runners-and-github`;super(r),this.code=e,this.name="NetworkError"}};gn.NetworkError=XE;XE.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var ZE=class extends Error{constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries. Usage is recalculated every 6-12 hours. If you are using self-hosted runners, please make sure your runner has access to all GitHub endpoints: https://docs.github.com/en/actions/hosting-your-own-runners/managing-self-hosted-runners/about-self-hosted-runners#communication-between-self-hosted-runners-and-github`;super(r),this.code=e,this.name="NetworkError"}};Qn.NetworkError=yC;yC.isNetworkErrorCode=t=>t?["ECONNRESET","ENOTFOUND","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH"].includes(t):!1;var EC=class extends Error{constructor(){super(`Cache storage quota has been hit. Unable to upload any new cache entries. Usage is recalculated every 6-12 hours.
More info on storage limits: https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};gn.UsageError=ZE;ZE.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1});var QV=h(mn=>{"use strict";var EBe=mn&&mn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),CBe=mn&&mn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),IBe=mn&&mn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&EBe(e,t,r);return CBe(e,t),e},BBe=mn&&mn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(mn,"__esModule",{value:!0});mn.uploadCacheArchiveSDK=mn.UploadProgress=void 0;var Av=IBe(ot()),QBe=rv(),bBe=av(),eC=class{constructor(e){this.contentLength=e,this.sentBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}setSentBytes(e){this.sentBytes=e}getTransferredBytes(){return this.sentBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.sentBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,i=(e/(1024*1024)/(n/1e3)).toFixed(1);Av.info(`Sent ${e} of ${this.contentLength} (${r}%), ${i} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setSentBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){let r=()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))};this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};mn.UploadProgress=eC;function NBe(t,e,r){var n;return BBe(this,void 0,void 0,function*(){let i=new QBe.BlobClient(t),s=i.getBlockBlobClient(),o=new eC((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),a={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:o.onProgress()};try{o.startDisplayTimer(),Av.debug(`BlobClient: ${i.name}:${i.accountName}:${i.containerName}`);let A=yield s.uploadFile(e,a);if(A._response.status>=400)throw new bBe.InvalidResponseError(`uploadCacheArchiveSDK: upload failed with status code ${A._response.status}`);return A}catch(A){throw Av.warning(`uploadCacheArchiveSDK: internal error uploading cache archive: ${A.message}`),A}finally{o.stopDisplayTimer()}})}mn.uploadCacheArchiveSDK=NBe});var lv=h(Mt=>{"use strict";var wBe=Mt&&Mt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),xBe=Mt&&Mt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),SBe=Mt&&Mt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&wBe(e,t,r);return xBe(e,t),e},rC=Mt&&Mt.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Mt,"__esModule",{value:!0});Mt.retryHttpClientResponse=Mt.retryTypedResponse=Mt.retry=Mt.isRetryableStatusCode=Mt.isServerErrorStatusCode=Mt.isSuccessStatusCode=void 0;var bV=SBe(ot()),tC=Fa(),gu=hf();function vBe(t){return t?t>=200&&t<300:!1}Mt.isSuccessStatusCode=vBe;function NV(t){return t?t>=500:!0}Mt.isServerErrorStatusCode=NV;function wV(t){return t?[tC.HttpCodes.BadGateway,tC.HttpCodes.ServiceUnavailable,tC.HttpCodes.GatewayTimeout].includes(t):!1}Mt.isRetryableStatusCode=wV;function RBe(t){return rC(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}function cv(t,e,r,n=gu.DefaultRetryAttempts,i=gu.DefaultRetryDelay,s=void 0){return rC(this,void 0,void 0,function*(){let o="",a=1;for(;a<=n;){let A,c,l=!1;try{A=yield e()}catch(u){s&&(A=s(u)),l=!0,o=u.message}if(A&&(c=r(A),!NV(c)))return A;if(c&&(l=wV(c),o=`Cache service responded with ${c}`),bV.debug(`${t} - Attempt ${a} of ${n} failed with Line truncated More info on storage limits: https://docs.github.com/en/billing/managing-billing-for-github-actions/about-billing-for-github-actions#calculating-minute-and-storage-spending`),this.name="UsageError"}};Qn.UsageError=EC;EC.isUsageErrorMessage=t=>t?t.includes("insufficient usage"):!1});var BW=h(bn=>{"use strict";var c0e=bn&&bn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),l0e=bn&&bn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),u0e=bn&&bn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&c0e(e,t,r);return l0e(e,t),e},d0e=bn&&bn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(bn,"__esModule",{value:!0});bn.uploadCacheArchiveSDK=bn.UploadProgress=void 0;var MR=u0e(ct()),f0e=_R(),h0e=LR(),CC=class{constructor(e){this.contentLength=e,this.sentBytes=0,this.displayedComplete=!1,this.startTime=Date.now()}setSentBytes(e){this.sentBytes=e}getTransferredBytes(){return this.sentBytes}isDone(){return this.getTransferredBytes()===this.contentLength}display(){if(this.displayedComplete)return;let e=this.sentBytes,r=(100*(e/this.contentLength)).toFixed(1),n=Date.now()-this.startTime,i=(e/(1024*1024)/(n/1e3)).toFixed(1);MR.info(`Sent ${e} of ${this.contentLength} (${r}%), ${i} MBs/sec`),this.isDone()&&(this.displayedComplete=!0)}onProgress(){return e=>{this.setSentBytes(e.loadedBytes)}}startDisplayTimer(e=1e3){let r=()=>{this.display(),this.isDone()||(this.timeoutHandle=setTimeout(r,e))};this.timeoutHandle=setTimeout(r,e)}stopDisplayTimer(){this.timeoutHandle&&(clearTimeout(this.timeoutHandle),this.timeoutHandle=void 0),this.display()}};bn.UploadProgress=CC;function g0e(t,e,r){var n;return d0e(this,void 0,void 0,function*(){let i=new f0e.BlobClient(t),s=i.getBlockBlobClient(),o=new CC((n=r?.archiveSizeBytes)!==null&&n!==void 0?n:0),a={blockSize:r?.uploadChunkSize,concurrency:r?.uploadConcurrency,maxSingleShotSize:128*1024*1024,onProgress:o.onProgress()};try{o.startDisplayTimer(),MR.debug(`BlobClient: ${i.name}:${i.accountName}:${i.containerName}`);let A=yield s.uploadFile(e,a);if(A._response.status>=400)throw new h0e.InvalidResponseError(`uploadCacheArchiveSDK: upload failed with status code ${A._response.status}`);return A}catch(A){throw MR.warning(`uploadCacheArchiveSDK: internal error uploading cache archive: ${A.message}`),A}finally{o.stopDisplayTimer()}})}bn.uploadCacheArchiveSDK=g0e});var UR=h(qt=>{"use strict";var m0e=qt&&qt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),p0e=qt&&qt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),y0e=qt&&qt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&m0e(e,t,r);return p0e(e,t),e},BC=qt&&qt.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(qt,"__esModule",{value:!0});qt.retryHttpClientResponse=qt.retryTypedResponse=qt.retry=qt.isRetryableStatusCode=qt.isServerErrorStatusCode=qt.isSuccessStatusCode=void 0;var QW=y0e(ct()),IC=Za(),Su=Rf();function E0e(t){return t?t>=200&&t<300:!1}qt.isSuccessStatusCode=E0e;function bW(t){return t?t>=500:!0}qt.isServerErrorStatusCode=bW;function NW(t){return t?[IC.HttpCodes.BadGateway,IC.HttpCodes.ServiceUnavailable,IC.HttpCodes.GatewayTimeout].includes(t):!1}qt.isRetryableStatusCode=NW;function C0e(t){return BC(this,void 0,void 0,function*(){return new Promise(e=>setTimeout(e,t))})}function FR(t,e,r,n=Su.DefaultRetryAttempts,i=Su.DefaultRetryDelay,s=void 0){return BC(this,void 0,void 0,function*(){let o="",a=1;for(;a<=n;){let A,c,l=!1;try{A=yield e()}catch(u){s&&(A=s(u)),l=!0,o=u.message}if(A&&(c=r(A),!bW(c)))return A;if(c&&(l=NW(c),o=`Cache service responded with ${c}`),QW.debug(`${t} - Attempt ${a} of ${n} failed with Line truncated
Other caches with similar key:`);for(let a of s?.artifactCaches||[])Un.debug(`Cache Key: ${a?.cacheKey}, Cache Version: ${a?.cacheVersion}, Cache Scope: ${a?.scope}, Cache Created: ${a?.creationTime}`)}}})}function fQe(t,e,r){return pn(this,void 0,void 0,function*(){let n=new sQe.URL(t),i=(0,pv.getDownloadOptions)(r);n.hostname.endsWith(".blob.core.windows.net")?i.useAzureSdk?yield(0,oC.downloadCacheStorageSDK)(t,e,i):i.concurrentBlobDownloads?yield(0,oC.downloadCacheHttpClientConcurrent)(t,e,i):yield(0,oC.downloadCacheHttpClient)(t,e):yield(0,oC.downloadCacheHttpClient)(t,e)})}yr.downloadCache=fQe;function hQe(t,e,r){return pn(this,void 0,void 0,function*(){let n=yv(),i=yu.getCacheVersion(e,r?.compressionMethod,r?.enableCrossOsArchive),s={key:t,version:i,cacheSize:r?.cacheSize};return yield(0,$o.retryTypedResponse)("reserveCache",()=>pn(this,void 0,void 0,function*(){return n.postJson(Sh("caches"),s)}))})}yr.reserveCache=hQe;function LV(t,e){return`bytes ${t}-${e}/*`}function gQe(t,e,r,n,i){return pn(this,void 0,void 0,function*(){Un.debug(`Uploading chunk of size ${i-n+1} bytes at offset ${n} with content range: ${LV(n,i)}`);let s={"Content-Type":"application/octet-stream","Content-Range":LV(n,i)},o=yield(0,$o.retryHttpClientResponse)(`uploadChunk (start: ${n}, end: ${i})`,()=>pn(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),s)}));if(!(0,$o.isSuccessStatusCode)(o.message.statusCode))throw new Error(`Cache service responded with ${o.message.statusCode} during upload chunk.`)})}function mQe(t,e,r,n){return pn(this,void 0,void 0,function*(){let i=yu.getArchiveFileSizeInBytes(r),s=Sh(`caches/${e.toString()}`),o=gv.openSync(r,"r"),a=(0,pv.getUploadOptions)(n),A=yu.assertDefined("uploadConcurrency",a.uploadConcurrency),c=yu.assertDefined("uploadChunkSize",a.uploadChunkSize),l=[...new Array(A).keys()];Un.debug("Awaiting all uploads");let u=0;try{yield Promise.all(l.map(()=>pn(this,void 0,void 0,function*(){for(;u<i;){let d=Math.min(i-u,c),f=u,g=u+d-1;u+=c,yield gQe(t,s,()=>gv.createReadStream(r,{fd:o,start:f,end:g,autoClose:!1}).on("error",m=>{throw new Error(`Cache upload failed because file read failed with ${m.message}`)}),f,g)}})))}finally{gv.closeSync(o)}})}function pQe(t,e,r){return pn(this,void 0,void 0,function*(){let n={size:r};return yield(0,$o.retryTypedResponse)("commitCache",()=>pn(this,void 0,void 0,function*(){return t.postJson(Sh(`caches/${e.toString()}`),n)}))})}function yQe(t,e,r,n){return pn(this,void 0,void 0,function*(){if((0,pv.getUploadOptions)(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield(0,oQe.uploadCacheArchiveSDK)(r,e,n)}else{let s=yv();Un.debug("Upload cache"),yield mQe(s,t,e,n),Un.debug("Commiting cache");let o=yu.getArchiveFileSizeInBytes(e);Un.info(`Cache Size: ~${Math.round(o/(1024*1024))} MB (${o} B)`);let a=yield pQe(s,t,o);if(!(0,$o.isSuccessStatusCode)(a.statusCode))throw new Error(`Cache service responded with ${a.statusCode} during commit cache.`);Un.info("Cache saved successfully")}})}yr.saveCache=yQe});var aC=h(Eu=>{"use strict";Object.defineProperty(Eu,"__esModule",{value:!0});Eu.isJsonObject=Eu.typeofJsonValue=void 0;function EQe(t){let e=typeof t;if(e=="object"){if(Array.isArray(t))return"array";if(t===null)return"null"}return e}Eu.typeofJsonValue=EQe;function CQe(t){return t!==null&&typeof t=="object"&&!Array.isArray(t)}Eu.isJsonObject=CQe});var cC=h(Cu=>{"use strict";Object.defineProperty(Cu,"__esModule",{value:!0});Cu.base64encode=Cu.base64decode=void 0;var Xs="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),AC=[];for(let t=0;t<Xs.length;t++)AC[Xs[t].charCodeAt(0)]=t;AC[45]=Xs.indexOf("+");AC[95]=Xs.indexOf("/");function IQe(t){let e=t.length*3/4;t[t.length-2]=="="?e-=2:t[t.length-1]=="="&&(e-=1);let r=new Uint8Array(e),n=0,i=0,s,o=0;for(let a=0;a<t.length;a++){if(s=AC[t.charCodeAt(a)],s===void 0)switch(t[a]){case"=":i=0;case` Other caches with similar key:`);for(let a of s?.artifactCaches||[])Vn.debug(`Cache Key: ${a?.cacheKey}, Cache Version: ${a?.cacheVersion}, Cache Scope: ${a?.scope}, Cache Created: ${a?.creationTime}`)}}})}function nNe(t,e,r){return Nn(this,void 0,void 0,function*(){let n=new W0e.URL(t),i=(0,JR.getDownloadOptions)(r);n.hostname.endsWith(".blob.core.windows.net")?i.useAzureSdk?yield(0,wC.downloadCacheStorageSDK)(t,e,i):i.concurrentBlobDownloads?yield(0,wC.downloadCacheHttpClientConcurrent)(t,e,i):yield(0,wC.downloadCacheHttpClient)(t,e):yield(0,wC.downloadCacheHttpClient)(t,e)})}br.downloadCache=nNe;function iNe(t,e,r){return Nn(this,void 0,void 0,function*(){let n=VR(),i=Du.getCacheVersion(e,r?.compressionMethod,r?.enableCrossOsArchive),s={key:t,version:i,cacheSize:r?.cacheSize};return yield(0,aa.retryTypedResponse)("reserveCache",()=>Nn(this,void 0,void 0,function*(){return n.postJson(jh("caches"),s)}))})}br.reserveCache=iNe;function LW(t,e){return`bytes ${t}-${e}/*`}function sNe(t,e,r,n,i){return Nn(this,void 0,void 0,function*(){Vn.debug(`Uploading chunk of size ${i-n+1} bytes at offset ${n} with content range: ${LW(n,i)}`);let s={"Content-Type":"application/octet-stream","Content-Range":LW(n,i)},o=yield(0,aa.retryHttpClientResponse)(`uploadChunk (start: ${n}, end: ${i})`,()=>Nn(this,void 0,void 0,function*(){return t.sendStream("PATCH",e,r(),s)}));if(!(0,aa.isSuccessStatusCode)(o.message.statusCode))throw new Error(`Cache service responded with ${o.message.statusCode} during upload chunk.`)})}function oNe(t,e,r,n){return Nn(this,void 0,void 0,function*(){let i=Du.getArchiveFileSizeInBytes(r),s=jh(`caches/${e.toString()}`),o=GR.openSync(r,"r"),a=(0,JR.getUploadOptions)(n),A=Du.assertDefined("uploadConcurrency",a.uploadConcurrency),c=Du.assertDefined("uploadChunkSize",a.uploadChunkSize),l=[...new Array(A).keys()];Vn.debug("Awaiting all uploads");let u=0;try{yield Promise.all(l.map(()=>Nn(this,void 0,void 0,function*(){for(;u<i;){let d=Math.min(i-u,c),f=u,g=u+d-1;u+=c,yield sNe(t,s,()=>GR.createReadStream(r,{fd:o,start:f,end:g,autoClose:!1}).on("error",m=>{throw new Error(`Cache upload failed because file read failed with ${m.message}`)}),f,g)}})))}finally{GR.closeSync(o)}})}function aNe(t,e,r){return Nn(this,void 0,void 0,function*(){let n={size:r};return yield(0,aa.retryTypedResponse)("commitCache",()=>Nn(this,void 0,void 0,function*(){return t.postJson(jh(`caches/${e.toString()}`),n)}))})}function ANe(t,e,r,n){return Nn(this,void 0,void 0,function*(){if((0,JR.getUploadOptions)(n).useAzureSdk){if(!r)throw new Error("Azure Storage SDK can only be used when a signed URL is provided.");yield(0,$0e.uploadCacheArchiveSDK)(r,e,n)}else{let s=VR();Vn.debug("Upload cache"),yield oNe(s,t,e,n),Vn.debug("Commiting cache");let o=Du.getArchiveFileSizeInBytes(e);Vn.info(`Cache Size: ~${Math.round(o/(1024*1024))} MB (${o} B)`);let a=yield aNe(s,t,o);if(!(0,aa.isSuccessStatusCode)(a.statusCode))throw new Error(`Cache service responded with ${a.statusCode} during commit cache.`);Vn.info("Cache saved successfully")}})}br.saveCache=ANe});var xC=h(_u=>{"use strict";Object.defineProperty(_u,"__esModule",{value:!0});_u.isJsonObject=_u.typeofJsonValue=void 0;function cNe(t){let e=typeof t;if(e=="object"){if(Array.isArray(t))return"array";if(t===null)return"null"}return e}_u.typeofJsonValue=cNe;function lNe(t){return t!==null&&typeof t=="object"&&!Array.isArray(t)}_u.isJsonObject=lNe});var RC=h(ku=>{"use strict";Object.defineProperty(ku,"__esModule",{value:!0});ku.base64encode=ku.base64decode=void 0;var co="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),SC=[];for(let t=0;t<co.length;t++)SC[co[t].charCodeAt(0)]=t;SC[45]=co.indexOf("+");SC[95]=co.indexOf("/");function uNe(t){let e=t.length*3/4;t[t.length-2]=="="?e-=2:t[t.length-1]=="="&&(e-=1);let r=new Uint8Array(e),n=0,i=0,s,o=0;for(let a=0;a<t.length;a++){if(s=SC[t.charCodeAt(a)],s===void 0)switch(t[a]){case"=":i=0;case`
`:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string.")}switch(i){case 0:o=s,i=1;break;case 1:r[n++]=o<<2|(s&48)>>4,o=s,i=2;break;case 2:r[n++]=(o&15)<<4|(s&60)>>2,o=s,i=3;break;case 3:r[n++]=(o&3)<<6|s,i=0;break}}if(i==1)throw Error("invalid base64 string.");return r.subarray(0,n)}Cu.base64decode=IQe;function BQe(t){let e="",r=0,n,i=0;for(let s=0;s<t.length;s++)switch(n=t[s],r){case 0:e+=Xs[n>>2],i=(n&3)<<4,r=1;break;case 1:e+=Xs[i|n>>4],i=(n&15)<<2,r=2;break;case 2:e+=Xs[i|n>>6],e+=Xs[n&63],r=0;break}return r&&(e+=Xs[i],e+="=",r==1&&(e+="=")),e}Cu.base64encode=BQe});var UV=h(lC=>{"use strict";Object.defineProperty(lC,"__esModule",{value:!0});lC.utf8read=void 0;var Ev=t=>String.fromCharCode.apply(String,t);function QQe(t){if(t.length<1)return"";let e=0,r=[],n=[],i=0,s,o=t.length;for(;e<o;)s=t[e++],s<128?n[i++]=s:s>191&&s<224?n[i++]=(s&31)<<6|t[e++]&63:s>239&&s<365?(s=((s&7)<<18|(t[e++]&63)<<12|(t[e++]&63)<<6|t[e++]&63)-65536,n[i++]=55296+(s>>10),n[i++]=56320+(s&1023)):n[i++]=(s&15)<<12|(t[e++]&63)<<6|t[e++]&63,i>8191&&(r.push(Ev(n)),i=0);return r.length?(i&&r.push(Ev(n.slice(0,i))),r.join("")):Ev(n.slice(0,i))}lC.utf8read=QQe});var vh=h(ds=>{"use strict";Object.defineProperty(ds,"__esModule",{value:!0});ds.WireType=ds.mergeBinaryOptions=ds.UnknownFieldHandler=void 0;var bQe;(function(t){t.symbol=Symbol.for("protobuf-ts/unknown"),t.onRead=(r,n,i,s,o)=>{(e(n)?n[t.symbol]:n[t.symbol]=[]).push({no:i,wireType:s,data:o})},t.onWrite=(r,n,i)=>{for(let{no:s,wireType:o,data:a}of t.list(n))i.tag(s,o).raw(a)},t.list=(r,n)=>{if(e(r)){let i=r[t.symbol];return n?i.filter(s=>s.no==n):i}return[]},t.last=(r,n)=>t.list(r,n).slice(-1)[0];let e=r=>r&&Array.isArray(r[t.symbol])})(bQe=ds.UnknownFieldHandler||(ds.UnknownFieldHandler={}));function NQe(t,e){return Object.assign(Object.assign({},t),e)}ds.mergeBinaryOptions=NQe;var wQe;(function(t){t[t.Varint=0]="Varint",t[t.Bit64=1]="Bit64",t[t.LengthDelimited=2]="LengthDelimited",t[t.StartGroup=3]="StartGroup",t[t.EndGroup=4]="EndGroup",t[t.Bit32=5]="Bit32"})(wQe=ds.WireType||(ds.WireType={}))});var dC=h(yn=>{"use strict";Object.defineProperty(yn,"__esModule",{value:!0});yn.varint32read=yn.varint32write=yn.int64toString=yn.int64fromString=yn.varint64write=yn.varint64read=void 0;function xQe(){let t=0,e=0;for(let n=0;n<28;n+=7){let i=this.buf[this.pos++];if(t|=(i&127)<<n,(i&128)==0)return this.assertBounds(),[t,e]}let r=this.buf[this.pos++];if(t|=(r&15)<<28,e=(r&112)>>4,(r&128)==0)return this.assertBounds(),[t,e];for(let n=3;n<=31;n+=7){let i=this.buf[this.pos++];if(e|=(i&127)<<n,(i&128)==0)return this.assertBounds(),[t,e]}throw new Error("invalid varint")}yn.varint64read=xQe;function SQe(t,e,r){for(let s=0;s<28;s=s+7){let o=t>>>s,a=!(!(o>>>7)&&e==0),A=(a?o|128:o)&255;if(r.push(A),!a)return}let n=t>>>28&15|(e&7)<<4,i=e>>3!=0;if(r.push((i?n|128:n)&255),!!i){for(let s=3;s<31;s=s+7){let o=e>>>s,a=!!(o>>>7),A=(a?o|128:o)&255;if(r.push(A),!a)return}r.push(e>>>31&1)}}yn.varint64write=SQe;var uC=65536*65536;function vQe(t){let e=t[0]=="-";e&&(t=t.slice(1));let r=1e6,n=0,i=0;function s(o,a){let A=Number(t.slice(o,a));i*=r,n=n*r+A,n>=uC&&(i=i+(n/uC|0),n=n%uC)}return s(-24,-18),s(-18,-12),s(-12,-6),s(-6),[e,n,i]}yn.int64fromString=vQe;function RQe(t,e){if(e>>>0<=2097151)return""+(uC*e+(t>>>0));let r=t&16777215,n=(t>>>24|e<<8)>>>0&16777215,i=e>>16&65535,s=r+n*6777216+i*6710656,o=n+i*8147497,a=i*2,A=1e7;s>=A&&(o+=Math.floor(s/A),s%=A),o>=A&&(a+=Math.floor(o/A),o%=A);function c(l,u){let d=l?String(l):"";return u?"0000000".slice(d.length)+d:d}return c(a,0)+c(o,a)+c(s,1)}yn.int64toString=RQe;function DQe(t,e){if(t>=0){for(;t>127;)e.push(t&127|128),t=t>>>7;e.push(t)}else{for(let r=0;r<9;r++)e.push(t&127|128),t=t>>7;e.push(1)}}yn.varint32write=DQe;function _Qe(){let t=this.buf[this.pos++],e=t&127;if((t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<7,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<14,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<21,(t&128)==0)return this.assertBounds(),e;t=this.buf[this.pos++],e|=(t&15)<<28;for(let r=5;(t&128)!==0&&r<10;r++)t=this.buf[this.pos++];if((t&128)!=0)throw new Error("invalid varint");return this.assertBounds(),e>>>0}yn.varint32read=_Qe});var Xo=h(Ko=>{"use strict";Object.defineProperty(Ko,"__esModule",{value:!0});Ko.PbLong=Ko.PbULong=Ko.detectBi=void 0;var Rh=dC(),dt;function qV(){let t=new DataView(new ArrayBuffer(8));dt=globalThis.BigInt!==void 0&&typeof t.getBigInt64=="function"&&typeof t.getBigUint64=="function"&&typeof t.setBigInt64=="function"&&typeof t.setBigUint64=="function"?{MIN:BigInt("-9223372036854775808"),MAX:BigInt("9223372036854775807"),UMIN:BigInt("0"),UMAX:BigInt("18446744073709551615"),C:BigInt,V:t}:void 0}Ko.detectBi=qV;qV();function HV(t){if(!t)throw new Error("BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support")}var zV=/^-?[0-9]+$/,hC=4294967296,fC=2147483648,gC=class{c Line truncated `:case"\r":case" ":case" ":continue;default:throw Error("invalid base64 string.")}switch(i){case 0:o=s,i=1;break;case 1:r[n++]=o<<2|(s&48)>>4,o=s,i=2;break;case 2:r[n++]=(o&15)<<4|(s&60)>>2,o=s,i=3;break;case 3:r[n++]=(o&3)<<6|s,i=0;break}}if(i==1)throw Error("invalid base64 string.");return r.subarray(0,n)}ku.base64decode=uNe;function dNe(t){let e="",r=0,n,i=0;for(let s=0;s<t.length;s++)switch(n=t[s],r){case 0:e+=co[n>>2],i=(n&3)<<4,r=1;break;case 1:e+=co[i|n>>4],i=(n&15)<<2,r=2;break;case 2:e+=co[i|n>>6],e+=co[n&63],r=0;break}return r&&(e+=co[i],e+="=",r==1&&(e+="=")),e}ku.base64encode=dNe});var FW=h(vC=>{"use strict";Object.defineProperty(vC,"__esModule",{value:!0});vC.utf8read=void 0;var WR=t=>String.fromCharCode.apply(String,t);function fNe(t){if(t.length<1)return"";let e=0,r=[],n=[],i=0,s,o=t.length;for(;e<o;)s=t[e++],s<128?n[i++]=s:s>191&&s<224?n[i++]=(s&31)<<6|t[e++]&63:s>239&&s<365?(s=((s&7)<<18|(t[e++]&63)<<12|(t[e++]&63)<<6|t[e++]&63)-65536,n[i++]=55296+(s>>10),n[i++]=56320+(s&1023)):n[i++]=(s&15)<<12|(t[e++]&63)<<6|t[e++]&63,i>8191&&(r.push(WR(n)),i=0);return r.length?(i&&r.push(WR(n.slice(0,i))),r.join("")):WR(n.slice(0,i))}vC.utf8read=fNe});var zh=h(Bs=>{"use strict";Object.defineProperty(Bs,"__esModule",{value:!0});Bs.WireType=Bs.mergeBinaryOptions=Bs.UnknownFieldHandler=void 0;var hNe;(function(t){t.symbol=Symbol.for("protobuf-ts/unknown"),t.onRead=(r,n,i,s,o)=>{(e(n)?n[t.symbol]:n[t.symbol]=[]).push({no:i,wireType:s,data:o})},t.onWrite=(r,n,i)=>{for(let{no:s,wireType:o,data:a}of t.list(n))i.tag(s,o).raw(a)},t.list=(r,n)=>{if(e(r)){let i=r[t.symbol];return n?i.filter(s=>s.no==n):i}return[]},t.last=(r,n)=>t.list(r,n).slice(-1)[0];let e=r=>r&&Array.isArray(r[t.symbol])})(hNe=Bs.UnknownFieldHandler||(Bs.UnknownFieldHandler={}));function gNe(t,e){return Object.assign(Object.assign({},t),e)}Bs.mergeBinaryOptions=gNe;var mNe;(function(t){t[t.Varint=0]="Varint",t[t.Bit64=1]="Bit64",t[t.LengthDelimited=2]="LengthDelimited",t[t.StartGroup=3]="StartGroup",t[t.EndGroup=4]="EndGroup",t[t.Bit32=5]="Bit32"})(mNe=Bs.WireType||(Bs.WireType={}))});var _C=h(wn=>{"use strict";Object.defineProperty(wn,"__esModule",{value:!0});wn.varint32read=wn.varint32write=wn.int64toString=wn.int64fromString=wn.varint64write=wn.varint64read=void 0;function pNe(){let t=0,e=0;for(let n=0;n<28;n+=7){let i=this.buf[this.pos++];if(t|=(i&127)<<n,(i&128)==0)return this.assertBounds(),[t,e]}let r=this.buf[this.pos++];if(t|=(r&15)<<28,e=(r&112)>>4,(r&128)==0)return this.assertBounds(),[t,e];for(let n=3;n<=31;n+=7){let i=this.buf[this.pos++];if(e|=(i&127)<<n,(i&128)==0)return this.assertBounds(),[t,e]}throw new Error("invalid varint")}wn.varint64read=pNe;function yNe(t,e,r){for(let s=0;s<28;s=s+7){let o=t>>>s,a=!(!(o>>>7)&&e==0),A=(a?o|128:o)&255;if(r.push(A),!a)return}let n=t>>>28&15|(e&7)<<4,i=e>>3!=0;if(r.push((i?n|128:n)&255),!!i){for(let s=3;s<31;s=s+7){let o=e>>>s,a=!!(o>>>7),A=(a?o|128:o)&255;if(r.push(A),!a)return}r.push(e>>>31&1)}}wn.varint64write=yNe;var DC=65536*65536;function ENe(t){let e=t[0]=="-";e&&(t=t.slice(1));let r=1e6,n=0,i=0;function s(o,a){let A=Number(t.slice(o,a));i*=r,n=n*r+A,n>=DC&&(i=i+(n/DC|0),n=n%DC)}return s(-24,-18),s(-18,-12),s(-12,-6),s(-6),[e,n,i]}wn.int64fromString=ENe;function CNe(t,e){if(e>>>0<=2097151)return""+(DC*e+(t>>>0));let r=t&16777215,n=(t>>>24|e<<8)>>>0&16777215,i=e>>16&65535,s=r+n*6777216+i*6710656,o=n+i*8147497,a=i*2,A=1e7;s>=A&&(o+=Math.floor(s/A),s%=A),o>=A&&(a+=Math.floor(o/A),o%=A);function c(l,u){let d=l?String(l):"";return u?"0000000".slice(d.length)+d:d}return c(a,0)+c(o,a)+c(s,1)}wn.int64toString=CNe;function INe(t,e){if(t>=0){for(;t>127;)e.push(t&127|128),t=t>>>7;e.push(t)}else{for(let r=0;r<9;r++)e.push(t&127|128),t=t>>7;e.push(1)}}wn.varint32write=INe;function BNe(){let t=this.buf[this.pos++],e=t&127;if((t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<7,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<14,(t&128)==0)return this.assertBounds(),e;if(t=this.buf[this.pos++],e|=(t&127)<<21,(t&128)==0)return this.assertBounds(),e;t=this.buf[this.pos++],e|=(t&15)<<28;for(let r=5;(t&128)!==0&&r<10;r++)t=this.buf[this.pos++];if((t&128)!=0)throw new Error("invalid varint");return this.assertBounds(),e>>>0}wn.varint32read=BNe});var ca=h(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});Aa.PbLong=Aa.PbULong=Aa.detectBi=void 0;var Gh=_C(),gt;function UW(){let t=new DataView(new ArrayBuffer(8));gt=globalThis.BigInt!==void 0&&typeof t.getBigInt64=="function"&&typeof t.getBigUint64=="function"&&typeof t.setBigInt64=="function"&&typeof t.setBigUint64=="function"?{MIN:BigInt("-9223372036854775808"),MAX:BigInt("9223372036854775807"),UMIN:BigInt("0"),UMAX:BigInt("18446744073709551615"),C:BigInt,V:t}:void 0}Aa.detectBi=UW;UW();function qW(t){if(!t)throw new Error("BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support")}var HW=/^-?[0-9]+$/,PC=4294967296,kC=2147483648,TC=class{c Line truncated
`)}};FC.RpcError=Yv});var Vv=h(qC=>{"use strict";Object.defineProperty(qC,"__esModule",{value:!0});qC.mergeRpcOptions=void 0;var EW=Jt();function e0e(t,e){if(!e)return t;let r={};UC(t,r),UC(e,r);for(let n of Object.keys(e)){let i=e[n];switch(n){case"jsonOptions":r.jsonOptions=EW.mergeJsonOptions(t.jsonOptions,r.jsonOptions);break;case"binaryOptions":r.binaryOptions=EW.mergeBinaryOptions(t.binaryOptions,r.binaryOptions);break;case"meta":r.meta={},UC(t.meta,r.meta),UC(e.meta,r.meta);break;case"interceptors":r.interceptors=t.interceptors?t.interceptors.concat(i):i.concat();break}}return r}qC.mergeRpcOptions=e0e;function UC(t,e){if(!t)return;let r=e;for(let[n,i]of Object.entries(t))i instanceof Date?r[n]=new Date(i.getTime()):Array.isArray(i)?r[n]=i.concat():r[n]=i}});var $v=h(fA=>{"use strict";Object.defineProperty(fA,"__esModule",{value:!0});fA.Deferred=fA.DeferredState=void 0;var gs;(function(t){t[t.PENDING=0]="PENDING",t[t.REJECTED=1]="REJECTED",t[t.RESOLVED=2]="RESOLVED"})(gs=fA.DeferredState||(fA.DeferredState={}));var Wv=class{constructor(e=!0){this._state=gs.PENDING,this._promise=new Promise((r,n)=>{this._resolve=r,this._reject=n}),e&&this._promise.catch(r=>{})}get state(){return this._state}get promise(){return this._promise}resolve(e){if(this.state!==gs.PENDING)throw new Error(`cannot resolve ${gs[this.state].toLowerCase()}`);this._resolve(e),this._state=gs.RESOLVED}reject(e){if(this.state!==gs.PENDING)throw new Error(`cannot reject ${gs[this.state].toLowerCase()}`);this._reject(e),this._state=gs.REJECTED}resolvePending(e){this._state===gs.PENDING&&this.resolve(e)}rejectPending(e){this._state===gs.PENDING&&this.reject(e)}};fA.Deferred=Wv});var Xv=h(HC=>{"use strict";Object.defineProperty(HC,"__esModule",{value:!0});HC.RpcOutputStreamController=void 0;var CW=$v(),hA=Jt(),Kv=class{constructor(){this._lis={nxt:[],msg:[],err:[],cmp:[]},this._closed=!1,this._itState={q:[]}}onNext(e){return this.addLis(e,this._lis.nxt)}onMessage(e){return this.addLis(e,this._lis.msg)}onError(e){return this.addLis(e,this._lis.err)}onComplete(e){return this.addLis(e,this._lis.cmp)}addLis(e,r){return r.push(e),()=>{let n=r.indexOf(e);n>=0&&r.splice(n,1)}}clearLis(){for(let e of Object.values(this._lis))e.splice(0,e.length)}get closed(){return this._closed!==!1}notifyNext(e,r,n){hA.assert((e?1:0)+(r?1:0)+(n?1:0)<=1,"only one emission at a time"),e&&this.notifyMessage(e),r&&this.notifyError(r),n&&this.notifyComplete()}notifyMessage(e){hA.assert(!this.closed,"stream is closed"),this.pushIt({value:e,done:!1}),this._lis.msg.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(e,void 0,!1))}notifyError(e){hA.assert(!this.closed,"stream is closed"),this._closed=e,this.pushIt(e),this._lis.err.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(void 0,e,!1)),this.clearLis()}notifyComplete(){hA.assert(!this.closed,"stream is closed"),this._closed=!0,this.pushIt({value:null,done:!0}),this._lis.cmp.forEach(e=>e()),this._lis.nxt.forEach(e=>e(void 0,void 0,!0)),this.clearLis()}[Symbol.asyncIterator](){return this._closed===!0?this.pushIt({value:null,done:!0}):this._closed!==!1&&this.pushIt(this._closed),{next:()=>{let e=this._itState;hA.assert(e,"bad state"),hA.assert(!e.p,"iterator contract broken");let r=e.q.shift();return r?"value"in r?Promise.resolve(r):Promise.reject(r):(e.p=new CW.Deferred,e.p.promise)}}}pushIt(e){let r=this._itState;if(r.p){let n=r.p;hA.assert(n.state==CW.DeferredState.PENDING,"iterator contract broken"),"value"in e?n.resolve(e):n.reject(e),delete r.p}else r.q.push(e)}};HC.RpcOutputStreamController=Kv});var eR=h(xu=>{"use strict";var t0e=xu&&xu.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(xu,"__esModule",{value:!0});xu.UnaryCall=void 0;var Zv=class{constructor(e,r,n,i,s,o,a){this.method=e,this.requestHeaders=r,this.request=n,this.headers=i,this.response=s,this.status=o,this.trailers=a}then(e,r){return this.promiseFinished().then(n=>e?Promise.resolve(e(n)):n,n=>r?Promise.resolve(r(n)):Promise.reject(n))}promiseFinished(){return t0e(this,void 0,void 0,function*(){let[e,r,n,i]=yield Promise.all([this.headers,this.response,this.status,this.trailers]);return{method:this.method,requestHeaders:this.requestHeaders,request:this.request,headers:e,response:r,status:n,trailers:i}})}};xu.UnaryCall=Zv});var rR=h(Su=>{"use strict";var r0e=Su&&Su.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Su,"__esModule",{value:!0});Su.ServerStreamingCall=void 0;var tR=class{constructor(e,r,n,i Line truncated `)}};sI.RpcError=Bv});var bv=h(aI=>{"use strict";Object.defineProperty(aI,"__esModule",{value:!0});aI.mergeRpcOptions=void 0;var y$=Kt();function zwe(t,e){if(!e)return t;let r={};oI(t,r),oI(e,r);for(let n of Object.keys(e)){let i=e[n];switch(n){case"jsonOptions":r.jsonOptions=y$.mergeJsonOptions(t.jsonOptions,r.jsonOptions);break;case"binaryOptions":r.binaryOptions=y$.mergeBinaryOptions(t.binaryOptions,r.binaryOptions);break;case"meta":r.meta={},oI(t.meta,r.meta),oI(e.meta,r.meta);break;case"interceptors":r.interceptors=t.interceptors?t.interceptors.concat(i):i.concat();break}}return r}aI.mergeRpcOptions=zwe;function oI(t,e){if(!t)return;let r=e;for(let[n,i]of Object.entries(t))i instanceof Date?r[n]=new Date(i.getTime()):Array.isArray(i)?r[n]=i.concat():r[n]=i}});var wv=h(xA=>{"use strict";Object.defineProperty(xA,"__esModule",{value:!0});xA.Deferred=xA.DeferredState=void 0;var Ns;(function(t){t[t.PENDING=0]="PENDING",t[t.REJECTED=1]="REJECTED",t[t.RESOLVED=2]="RESOLVED"})(Ns=xA.DeferredState||(xA.DeferredState={}));var Nv=class{constructor(e=!0){this._state=Ns.PENDING,this._promise=new Promise((r,n)=>{this._resolve=r,this._reject=n}),e&&this._promise.catch(r=>{})}get state(){return this._state}get promise(){return this._promise}resolve(e){if(this.state!==Ns.PENDING)throw new Error(`cannot resolve ${Ns[this.state].toLowerCase()}`);this._resolve(e),this._state=Ns.RESOLVED}reject(e){if(this.state!==Ns.PENDING)throw new Error(`cannot reject ${Ns[this.state].toLowerCase()}`);this._reject(e),this._state=Ns.REJECTED}resolvePending(e){this._state===Ns.PENDING&&this.resolve(e)}rejectPending(e){this._state===Ns.PENDING&&this.reject(e)}};xA.Deferred=Nv});var Sv=h(AI=>{"use strict";Object.defineProperty(AI,"__esModule",{value:!0});AI.RpcOutputStreamController=void 0;var E$=wv(),SA=Kt(),xv=class{constructor(){this._lis={nxt:[],msg:[],err:[],cmp:[]},this._closed=!1,this._itState={q:[]}}onNext(e){return this.addLis(e,this._lis.nxt)}onMessage(e){return this.addLis(e,this._lis.msg)}onError(e){return this.addLis(e,this._lis.err)}onComplete(e){return this.addLis(e,this._lis.cmp)}addLis(e,r){return r.push(e),()=>{let n=r.indexOf(e);n>=0&&r.splice(n,1)}}clearLis(){for(let e of Object.values(this._lis))e.splice(0,e.length)}get closed(){return this._closed!==!1}notifyNext(e,r,n){SA.assert((e?1:0)+(r?1:0)+(n?1:0)<=1,"only one emission at a time"),e&&this.notifyMessage(e),r&&this.notifyError(r),n&&this.notifyComplete()}notifyMessage(e){SA.assert(!this.closed,"stream is closed"),this.pushIt({value:e,done:!1}),this._lis.msg.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(e,void 0,!1))}notifyError(e){SA.assert(!this.closed,"stream is closed"),this._closed=e,this.pushIt(e),this._lis.err.forEach(r=>r(e)),this._lis.nxt.forEach(r=>r(void 0,e,!1)),this.clearLis()}notifyComplete(){SA.assert(!this.closed,"stream is closed"),this._closed=!0,this.pushIt({value:null,done:!0}),this._lis.cmp.forEach(e=>e()),this._lis.nxt.forEach(e=>e(void 0,void 0,!0)),this.clearLis()}[Symbol.asyncIterator](){return this._closed===!0?this.pushIt({value:null,done:!0}):this._closed!==!1&&this.pushIt(this._closed),{next:()=>{let e=this._itState;SA.assert(e,"bad state"),SA.assert(!e.p,"iterator contract broken");let r=e.q.shift();return r?"value"in r?Promise.resolve(r):Promise.reject(r):(e.p=new E$.Deferred,e.p.promise)}}}pushIt(e){let r=this._itState;if(r.p){let n=r.p;SA.assert(n.state==E$.DeferredState.PENDING,"iterator contract broken"),"value"in e?n.resolve(e):n.reject(e),delete r.p}else r.q.push(e)}};AI.RpcOutputStreamController=xv});var vv=h(Uu=>{"use strict";var Gwe=Uu&&Uu.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Uu,"__esModule",{value:!0});Uu.UnaryCall=void 0;var Rv=class{constructor(e,r,n,i,s,o,a){this.method=e,this.requestHeaders=r,this.request=n,this.headers=i,this.response=s,this.status=o,this.trailers=a}then(e,r){return this.promiseFinished().then(n=>e?Promise.resolve(e(n)):n,n=>r?Promise.resolve(r(n)):Promise.reject(n))}promiseFinished(){return Gwe(this,void 0,void 0,function*(){let[e,r,n,i]=yield Promise.all([this.headers,this.response,this.status,this.trailers]);return{method:this.method,requestHeaders:this.requestHeaders,request:this.request,headers:e,response:r,status:n,trailers:i}})}};Uu.UnaryCall=Rv});var _v=h(qu=>{"use strict";var Ywe=qu&&qu.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(qu,"__esModule",{value:!0});qu.ServerStreamingCall=void 0;var Dv=class{constructor(e,r,n,i Line truncated
`));let n=yield bR(r,"create");yield NR(n,t)})}Fr.createTar=$0e});var ZC=h(qt=>{"use strict";var K0e=qt&&qt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),X0e=qt&&qt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),Gh=qt&&qt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&K0e(e,t,r);return X0e(e,t),e},zu=qt&&qt.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(qt,"__esModule",{value:!0});qt.saveCache=qt.restoreCache=qt.isFeatureAvailable=qt.FinalizeCacheError=qt.ReserveCacheError=qt.ValidationError=void 0;var fe=Gh(ot()),$C=Gh(require("path")),xt=Gh(jc()),Hu=Gh(FV()),UW=Gh(OW()),KC=iC(),ta=FW(),XC=Fa(),pi=class t extends Error{constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}};qt.ValidationError=pi;var gA=class t extends Error{constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}};qt.ReserveCacheError=gA;var jh=class t extends Error{constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};qt.FinalizeCacheError=jh;function qW(t){if(!t||t.length===0)throw new pi("Path Validation Error: At least one directory or file path is required")}function wR(t){if(t.length>512)throw new pi(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new pi(`Key Validation Error: ${t} cannot contain commas.`)}function Z0e(){return(0,KC.getCacheServiceVersion)()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}qt.isFeatureAvailable=Z0e;function eNe(t,e,r,n,i=!1){return zu(this,void 0,void 0,function*(){let s=(0,KC.getCacheServiceVersion)();return fe.debug(`Cache service version: ${s}`),qW(t),s==="v2"?yield rNe(t,e,r,n,i):yield tNe(t,e,r,n,i)})}qt.restoreCache=eNe;function tNe(t,e,r,n,i=!1){return zu(this,void 0,void 0,function*(){r=r||[];let s=[e,...r];if(fe.debug("Resolved Keys:"),fe.debug(JSON.stringify(s)),s.length>10)throw new pi("Key Validation Error: Keys are limited to a maximum of 10.");for(let A of s)wR(A);let o=yield xt.getCompressionMethod(),a="";try{let A=yield Hu.getCacheEntry(s,t,{compressionMethod:o,enableCrossOsArchive:i});if(!A?.archiveLocation)return;if(n?.lookupOnly)return fe.info("Lookup only - skipping download"),A.cacheKey;a=$C.join(yield xt.createTempDirectory(),xt.getCacheFileName(o)),fe.debug(`Archive Path: ${a}`),yield Hu.downloadCache(A.archiveLocation,a,n),fe.isDebug()&&(yield(0,ta.listTar)(a,o));let c=xt.getArchiveFileSizeInBytes(a);return fe.info(`Cache Size: ~${Math.round(c/(1024*1024))} MB (${c} B)`),yield(0,ta.extractTar)(a,o),fe.info("Cache restored successfully"),A.cacheKey}catch(A){let c=A;if(c.name===pi.name)throw A;c instanceof XC.HttpClientError&&typeof c.statusCode=="number"&&c.statusCode>=500?fe.error(`Failed to restore: ${A.message}`):fe.warning(`Failed to restore: ${A.message}`)}finally{try{yield xt.unlinkFile(a)}catch(A){fe.debug(`Failed to delete archive: ${A}`)}}})}function rNe(t,e,r,n,i=!1){return zu(this,void 0,void 0,function*(){n=Object.assign(Object.assign({},n),{useAzureSdk:!0}),r=r||[];let s=[e,...r];if(fe.debug("Resolved Keys:"),fe.debug(JSON.stringify(s)),s.length>10)throw new pi("Key Validation Error: Keys are limited to a maximum of 10.");for(let a of s)wR(a);let o="";try{let a=UW.internalCacheTwirpClient(),A=yield xt.getCompressionMethod(),c={key:e,restoreKeys:r,version:xt.getCacheVersion(t,A,i)},l=yield a.GetCacheEntryDownloadURL(c);if(!l.ok){fe.debug(`Cache not found for version ${c.version} of keys: ${s.join(", ")}`);return}if(c.key!==l.matchedKey?fe.info(`Cache hit for restore-key: ${l.matchedKey}`):fe.info(`Cache hit for: ${l.matchedKey}`),n?.lookupOnly)return fe.info("Lookup only - skipping download"),l.matchedKey;o=$C.join(yield xt.createTempDirectory(),xt.getCacheFileName(A)),fe.debug(`Archive path: ${o}`),fe.debug(`Starting download of archive to: ${o}`),yield Hu.downloadCache(l.signedDownloadUrl,o,n);let d=xt.getArchiveFileSizeInBytes(o);return fe.info(`Cache Size: ~${Math.round(d/(1024*1024))} MB (${d} B)`),fe.isDebug()&&(yield(0,ta.listTar)(o,A)),yield(0,ta.extractTar)(o,A),fe.info("Cache restored successfully"),l.matchedKey}catch(a){let A=a;if(A.name===pi.name)throw a;A instanceof XC.HttpClientError&&typeof A.statusCode=="number"&&A.statusCode>=500?fe.error(`Line truncated `));let n=yield eD(r,"create");yield tD(n,t)})}Yr.createTar=Uxe});var EI=h(Gt=>{"use strict";var qxe=Gt&&Gt.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),Hxe=Gt&&Gt.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),og=Gt&&Gt.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&qxe(e,t,r);return Hxe(e,t),e},rd=Gt&&Gt.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(Gt,"__esModule",{value:!0});Gt.saveCache=Gt.restoreCache=Gt.isFeatureAvailable=Gt.FinalizeCacheError=Gt.ReserveCacheError=Gt.ValidationError=void 0;var ge=og(ct()),mI=og(require("path")),Dt=og(nl()),td=og(MW()),F$=og(T$()),pI=bC(),da=M$(),yI=Za(),Ni=class t extends Error{constructor(e){super(e),this.name="ValidationError",Object.setPrototypeOf(this,t.prototype)}};Gt.ValidationError=Ni;var RA=class t extends Error{constructor(e){super(e),this.name="ReserveCacheError",Object.setPrototypeOf(this,t.prototype)}};Gt.ReserveCacheError=RA;var sg=class t extends Error{constructor(e){super(e),this.name="FinalizeCacheError",Object.setPrototypeOf(this,t.prototype)}};Gt.FinalizeCacheError=sg;function U$(t){if(!t||t.length===0)throw new Ni("Path Validation Error: At least one directory or file path is required")}function rD(t){if(t.length>512)throw new Ni(`Key Validation Error: ${t} cannot be larger than 512 characters.`);if(!/^[^,]*$/.test(t))throw new Ni(`Key Validation Error: ${t} cannot contain commas.`)}function jxe(){return(0,pI.getCacheServiceVersion)()==="v2"?!!process.env.ACTIONS_RESULTS_URL:!!process.env.ACTIONS_CACHE_URL}Gt.isFeatureAvailable=jxe;function zxe(t,e,r,n,i=!1){return rd(this,void 0,void 0,function*(){let s=(0,pI.getCacheServiceVersion)();return ge.debug(`Cache service version: ${s}`),U$(t),s==="v2"?yield Yxe(t,e,r,n,i):yield Gxe(t,e,r,n,i)})}Gt.restoreCache=zxe;function Gxe(t,e,r,n,i=!1){return rd(this,void 0,void 0,function*(){r=r||[];let s=[e,...r];if(ge.debug("Resolved Keys:"),ge.debug(JSON.stringify(s)),s.length>10)throw new Ni("Key Validation Error: Keys are limited to a maximum of 10.");for(let A of s)rD(A);let o=yield Dt.getCompressionMethod(),a="";try{let A=yield td.getCacheEntry(s,t,{compressionMethod:o,enableCrossOsArchive:i});if(!A?.archiveLocation)return;if(n?.lookupOnly)return ge.info("Lookup only - skipping download"),A.cacheKey;a=mI.join(yield Dt.createTempDirectory(),Dt.getCacheFileName(o)),ge.debug(`Archive Path: ${a}`),yield td.downloadCache(A.archiveLocation,a,n),ge.isDebug()&&(yield(0,da.listTar)(a,o));let c=Dt.getArchiveFileSizeInBytes(a);return ge.info(`Cache Size: ~${Math.round(c/(1024*1024))} MB (${c} B)`),yield(0,da.extractTar)(a,o),ge.info("Cache restored successfully"),A.cacheKey}catch(A){let c=A;if(c.name===Ni.name)throw A;c instanceof yI.HttpClientError&&typeof c.statusCode=="number"&&c.statusCode>=500?ge.error(`Failed to restore: ${A.message}`):ge.warning(`Failed to restore: ${A.message}`)}finally{try{yield Dt.unlinkFile(a)}catch(A){ge.debug(`Failed to delete archive: ${A}`)}}})}function Yxe(t,e,r,n,i=!1){return rd(this,void 0,void 0,function*(){n=Object.assign(Object.assign({},n),{useAzureSdk:!0}),r=r||[];let s=[e,...r];if(ge.debug("Resolved Keys:"),ge.debug(JSON.stringify(s)),s.length>10)throw new Ni("Key Validation Error: Keys are limited to a maximum of 10.");for(let a of s)rD(a);let o="";try{let a=F$.internalCacheTwirpClient(),A=yield Dt.getCompressionMethod(),c={key:e,restoreKeys:r,version:Dt.getCacheVersion(t,A,i)},l=yield a.GetCacheEntryDownloadURL(c);if(!l.ok){ge.debug(`Cache not found for version ${c.version} of keys: ${s.join(", ")}`);return}if(c.key!==l.matchedKey?ge.info(`Cache hit for restore-key: ${l.matchedKey}`):ge.info(`Cache hit for: ${l.matchedKey}`),n?.lookupOnly)return ge.info("Lookup only - skipping download"),l.matchedKey;o=mI.join(yield Dt.createTempDirectory(),Dt.getCacheFileName(A)),ge.debug(`Archive path: ${o}`),ge.debug(`Starting download of archive to: ${o}`),yield td.downloadCache(l.signedDownloadUrl,o,n);let d=Dt.getArchiveFileSizeInBytes(o);return ge.info(`Cache Size: ~${Math.round(d/(1024*1024))} MB (${d} B)`),ge.isDebug()&&(yield(0,da.listTar)(o,A)),yield(0,da.extractTar)(o,A),ge.info("Cache restored successfully"),l.matchedKey}catch(a){let A=a;if(A.name===Ni.name)throw a;A instanceof yI.HttpClientError&&typeof A.statusCode=="number"&&A.statusCode>=500?ge.error(`Line truncated
`),e=e.replace(/\r/g,` `),e=e.replace(/\r/g,`
`));let i=e.split(` `));let i=e.split(`
`).map(s=>s.trim());for(let s of i)!s||s.startsWith("#")||n.patterns.push(new e4.Pattern(s));return n.searchPaths.push(...oI.getSearchPaths(n.patterns)),n})}static stat(e,r,n){return PR(this,void 0,void 0,function*(){let i;if(r.followSymbolicLinks)try{i=yield Kh.promises.stat(e.path)}catch(s){if(s.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){TR.debug(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw s}else i=yield Kh.promises.lstat(e.path);if(i.isDirectory()&&r.followSymbolicLinks){let s=yield Kh.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===s)){TR.debug(`Symlink cycle detected for path '${e.path}' and realpath '${s}'`);return}n.push(s)}return i})}};Cr.DefaultGlobber=OR});var o4=h(Bn=>{"use strict";var LNe=Bn&&Bn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),FNe=Bn&&Bn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),ju=Bn&&Bn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&LNe(e,t,r);return FNe(e,t),e},UNe=Bn&&Bn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})},qNe=Bn&&Bn.__asyncValues||function(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],r;return e?e.call(t):(t=typeof __values=="function"?__values(t):t[Symbol.iterator](),r={},n("next"),n("throw"),n("return"),r[Symbol.asyncIterator]=function(){return this},r);function n(s){r[s]=t[s]&&function(o){return new Promise(function(a,A){o=t[s](o),i(a,A,o.done,o.value)})}}function i(s,o,a,A){Promise.resolve(A).then(function(c){s({value:c,done:a})},o)}};Object.defineProperty(Bn,"__esModule",{value:!0});Bn.hashFiles=void 0;var n4=ju(require("crypto")),i4=ju(ot()),s4=ju(require("fs")),HNe=ju(require("stream")),zNe=ju(require("util")),jNe=ju(require("path"));function GNe(t,e,r=!1){var n,i,s,o,a;return UNe(this,void 0,void 0,function*(){let A=r?i4.info:i4.debug,c=!1,l=e||((a=process.env.GITHUB_WORKSPACE)!==null&&a!==void 0?a:process.cwd()),u=n4.createHash("sha256"),d=0;try{for(var f=!0,g=qNe(t.globGenerator()),m;m=yield g.next(),n=m.done,!n;f=!0){o=m.value,f=!1;let E=o;if(A(E),!E.startsWith(`${l}${jNe.sep}`)){A(`Ignore '${E}' since it is not under GITHUB_WORKSPACE.`);continue}if(s4.statSync(E).isDirectory()){A(`Skip directory '${E}'.`);continue}let C=n4.createHash("sha256");yield zNe.promisify(HNe.pipeline)(s4.createReadStream(E),C),u.write(C.digest()),d++,c||(c=!0)}}catch(E){i={error:E}}finally{try{!f&&!n&&(s=g.return)&&(yield s.call(g))}finally{if(i)throw i.error}}return u.end(),c?(A(`Found ${d} files to hash.`),u.digest("hex")):(A("No matches found for glob"),"")})}Bn.hashFiles=GNe});var c4=h(sa=>{"use strict";var a4=sa&&sa.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(sa,"__esModule",{value:!0});sa.hashFiles=sa.create=void 0;var YNe=r4(),JNe=o4();function A4(t,e){return a4(this,void 0,void 0,function*(){return yield YNe.DefaultGlobber.create(t,e)})}sa.create=A4;function VNe(t,e="",r,n=!1){return a4(this,void 0,void 0,function*(){let i=!0;r&&typeof r.followSymbolicLinks=="boolean"&&(i=r.followSymbolicLinks);let s=yield A4(t,{followSymbolicLinks:i});return(0,JNe.hashFiles)(s,e,n)})}sa.hashFiles=VNe});var B4=h((rFe,I4)=>{"use strict";I4.exports=function(t){if(typeof t!="string")throw new Error("expected a string");return t.split(` `).map(s=>s.trim());for(let s of i)!s||s.startsWith("#")||n.patterns.push(new Z$.Pattern(s));return n.searchPaths.push(...wI.getSearchPaths(n.patterns)),n})}static stat(e,r,n){return lD(this,void 0,void 0,function*(){let i;if(r.followSymbolicLinks)try{i=yield dg.promises.stat(e.path)}catch(s){if(s.code==="ENOENT"){if(r.omitBrokenSymbolicLinks){uD.debug(`Broken symlink '${e.path}'`);return}throw new Error(`No information found for the path '${e.path}'. This may indicate a broken symbolic link.`)}throw s}else i=yield dg.promises.lstat(e.path);if(i.isDirectory()&&r.followSymbolicLinks){let s=yield dg.promises.realpath(e.path);for(;n.length>=e.level;)n.pop();if(n.some(o=>o===s)){uD.debug(`Symlink cycle detected for path '${e.path}' and realpath '${s}'`);return}n.push(s)}return i})}};wr.DefaultGlobber=dD});var s4=h(vn=>{"use strict";var SSe=vn&&vn.__createBinding||(Object.create?(function(t,e,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(e,r);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[r]}}),Object.defineProperty(t,n,i)}):(function(t,e,r,n){n===void 0&&(n=r),t[n]=e[r]})),RSe=vn&&vn.__setModuleDefault||(Object.create?(function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}):function(t,e){t.default=e}),nd=vn&&vn.__importStar||function(t){if(t&&t.__esModule)return t;var e={};if(t!=null)for(var r in t)r!=="default"&&Object.prototype.hasOwnProperty.call(t,r)&&SSe(e,t,r);return RSe(e,t),e},vSe=vn&&vn.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})},DSe=vn&&vn.__asyncValues||function(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e=t[Symbol.asyncIterator],r;return e?e.call(t):(t=typeof __values=="function"?__values(t):t[Symbol.iterator](),r={},n("next"),n("throw"),n("return"),r[Symbol.asyncIterator]=function(){return this},r);function n(s){r[s]=t[s]&&function(o){return new Promise(function(a,A){o=t[s](o),i(a,A,o.done,o.value)})}}function i(s,o,a,A){Promise.resolve(A).then(function(c){s({value:c,done:a})},o)}};Object.defineProperty(vn,"__esModule",{value:!0});vn.hashFiles=void 0;var r4=nd(require("crypto")),n4=nd(ct()),i4=nd(require("fs")),_Se=nd(require("stream")),kSe=nd(require("util")),PSe=nd(require("path"));function TSe(t,e,r=!1){var n,i,s,o,a;return vSe(this,void 0,void 0,function*(){let A=r?n4.info:n4.debug,c=!1,l=e||((a=process.env.GITHUB_WORKSPACE)!==null&&a!==void 0?a:process.cwd()),u=r4.createHash("sha256"),d=0;try{for(var f=!0,g=DSe(t.globGenerator()),m;m=yield g.next(),n=m.done,!n;f=!0){o=m.value,f=!1;let E=o;if(A(E),!E.startsWith(`${l}${PSe.sep}`)){A(`Ignore '${E}' since it is not under GITHUB_WORKSPACE.`);continue}if(i4.statSync(E).isDirectory()){A(`Skip directory '${E}'.`);continue}let C=r4.createHash("sha256");yield kSe.promisify(_Se.pipeline)(i4.createReadStream(E),C),u.write(C.digest()),d++,c||(c=!0)}}catch(E){i={error:E}}finally{try{!f&&!n&&(s=g.return)&&(yield s.call(g))}finally{if(i)throw i.error}}return u.end(),c?(A(`Found ${d} files to hash.`),u.digest("hex")):(A("No matches found for glob"),"")})}vn.hashFiles=TSe});var A4=h(ma=>{"use strict";var o4=ma&&ma.__awaiter||function(t,e,r,n){function i(s){return s instanceof r?s:new r(function(o){o(s)})}return new(r||(r=Promise))(function(s,o){function a(l){try{c(n.next(l))}catch(u){o(u)}}function A(l){try{c(n.throw(l))}catch(u){o(u)}}function c(l){l.done?s(l.value):i(l.value).then(a,A)}c((n=n.apply(t,e||[])).next())})};Object.defineProperty(ma,"__esModule",{value:!0});ma.hashFiles=ma.create=void 0;var OSe=t4(),LSe=s4();function a4(t,e){return o4(this,void 0,void 0,function*(){return yield OSe.DefaultGlobber.create(t,e)})}ma.create=a4;function MSe(t,e="",r,n=!1){return o4(this,void 0,void 0,function*(){let i=!0;r&&typeof r.followSymbolicLinks=="boolean"&&(i=r.followSymbolicLinks);let s=yield a4(t,{followSymbolicLinks:i});return(0,LSe.hashFiles)(s,e,n)})}ma.hashFiles=MSe});var I4=h((rje,C4)=>{"use strict";C4.exports=function(t){if(typeof t!="string")throw new Error("expected a string");return t.split(`
`).map(XNe).filter(Boolean)};function XNe(t,e){if(!t||!t.length||t.charAt(0)==="#")return null;var r=t.split(":");return{username:r[0],password:r[1],uid:r[2],gid:r[3],gecos:r[4],homedir:r[5],shell:r[6]}}});var b4=h((nFe,Q4)=>{"use strict";var ZNe=require("fs"),ewe=B4();function twe(){if(process.platform==="win32")return process.env.USERPROFILE?process.env.USERPROFILE:process.env.HOMEDRIVE&&process.env.HOMEPATH?process.env.HOMEDRIVE+process.env.HOMEPATH:process.env.HOME?process.env.HOME:null;if(process.env.HOME)return process.env.HOME;var t=iwe("/etc/passwd"),e=rwe(ewe(t),nwe());if(e)return e;var r=process.env.LOGNAME||process.env.USER||process.env.LNAME||process.env.USERNAME;return r?process.platform==="darwin"?"/Users/"+r:"/home/"+r:null}function rwe(t,e){for(var r=t.length,n=0;n<r;n++)if(+t[n].uid===e)return t[n].homedir}function nwe(){return typeof process.geteuid=="function"?process.geteuid():process.getuid()}function iwe(t){try{return ZNe.readFileSync(t,"utf8")}catch{return""}}Q4.exports=twe});var w4=h((iFe,MR)=>{"use strict";var N4=require("os");typeof N4.homedir<"u"?MR.exports=N4.homedir:MR.exports=b4()});var v4=h((sFe,S4)=>{var swe=w4(),x4=require("path");S4.exports=function(e){var r=swe();return e.charCodeAt(0)===126?e.charCodeAt(1)===43?x4.join(process.cwd(),e.slice(2)):r?x4.join(r,e.slice(1)):e:e}});var qe=h(Sr=>{"use strict";var LR=Symbol.for("yaml.alias"),R4=Symbol.for("yaml.document"),aI=Symbol.for("yaml.map"),D4=Symbol.for("yaml.pair"),FR=Symbol.for("yaml.scalar"),AI=Symbol.for("yaml.seq"),ro=Symbol.for("yaml.node.type"),owe=t=>!!t&&typeof t=="object"&&t[ro]===LR,awe=t=>!!t&&typeof t=="object"&&t[ro]===R4,Awe=t=>!!t&&typeof t=="object"&&t[ro]===aI,cwe=t=>!!t&&typeof t=="object"&&t[ro]===D4,_4=t=>!!t&&typeof t=="object"&&t[ro]===FR,lwe=t=>!!t&&typeof t=="object"&&t[ro]===AI;function k4(t){if(t&&typeof t=="object")switch(t[ro]){case aI:case AI:return!0}return!1}function uwe(t){if(t&&typeof t=="object")switch(t[ro]){case LR:case aI:case FR:case AI:return!0}return!1}var dwe=t=>(_4(t)||k4(t))&&!!t.anchor;Sr.ALIAS=LR;Sr.DOC=R4;Sr.MAP=aI;Sr.NODE_TYPE=ro;Sr.PAIR=D4;Sr.SCALAR=FR;Sr.SEQ=AI;Sr.hasAnchor=dwe;Sr.isAlias=owe;Sr.isCollection=k4;Sr.isDocument=awe;Sr.isMap=Awe;Sr.isNode=uwe;Sr.isPair=cwe;Sr.isScalar=_4;Sr.isSeq=lwe});var Zh=h(UR=>{"use strict";var sr=qe(),Qn=Symbol("break visit"),P4=Symbol("skip children"),ps=Symbol("remove node");function cI(t,e){let r=T4(e);sr.isDocument(t)?Yu(null,t.contents,r,Object.freeze([t]))===ps&&(t.contents=null):Yu(null,t,r,Object.freeze([]))}cI.BREAK=Qn;cI.SKIP=P4;cI.REMOVE=ps;function Yu(t,e,r,n){let i=O4(t,e,r,n);if(sr.isNode(i)||sr.isPair(i))return M4(t,n,i),Yu(t,i,r,n);if(typeof i!="symbol"){if(sr.isCollection(e)){n=Object.freeze(n.concat(e));for(let s=0;s<e.items.length;++s){let o=Yu(s,e.items[s],r,n);if(typeof o=="number")s=o-1;else{if(o===Qn)return Qn;o===ps&&(e.items.splice(s,1),s-=1)}}}else if(sr.isPair(e)){n=Object.freeze(n.concat(e));let s=Yu("key",e.key,r,n);if(s===Qn)return Qn;s===ps&&(e.key=null);let o=Yu("value",e.value,r,n);if(o===Qn)return Qn;o===ps&&(e.value=null)}}return i}async function lI(t,e){let r=T4(e);sr.isDocument(t)?await Ju(null,t.contents,r,Object.freeze([t]))===ps&&(t.contents=null):await Ju(null,t,r,Object.freeze([]))}lI.BREAK=Qn;lI.SKIP=P4;lI.REMOVE=ps;async function Ju(t,e,r,n){let i=await O4(t,e,r,n);if(sr.isNode(i)||sr.isPair(i))return M4(t,n,i),Ju(t,i,r,n);if(typeof i!="symbol"){if(sr.isCollection(e)){n=Object.freeze(n.concat(e));for(let s=0;s<e.items.length;++s){let o=await Ju(s,e.items[s],r,n);if(typeof o=="number")s=o-1;else{if(o===Qn)return Qn;o===ps&&(e.items.splice(s,1),s-=1)}}}else if(sr.isPair(e)){n=Object.freeze(n.concat(e));let s=await Ju("key",e.key,r,n);if(s===Qn)return Qn;s===ps&&(e.key=null);let o=await Ju("value",e.value,r,n);if(o===Qn)return Qn;o===ps&&(e.value=null)}}return i}function T4(t){return typeof t=="object"&&(t.Collection||t.Node||t.Value)?Object.assign({Alias:t.Node,Map:t.Node,Scalar:t.Node,Seq:t.Node},t.Value&&{Map:t.Value,Scalar:t.Value,Seq:t.Value},t.Collection&&{Map:t.Collection,Seq:t.Collection},t):t}function O4(t,e,r,n){if(typeof r=="function")return r(t,e,n);if(sr.isMap(e))return r.Map?.(t,e,n);if(sr.isSeq(e))return r.Seq?.(t,e,n);if(sr.isPair(e))return r.Pair?.(t,e,n);if(sr.isScalar(e))return r.Scalar?.(t,e,n);if(sr.isAlias(e))return r.Alias?.(t,e,n)}function M4(t,e,r){let n=e[e.length-1];if(sr.isCollection(n))n.items[t]=r;else if(sr.isPair(n))t==="key"?n.key=r:n.value=r;else if(sr.isDocument(n))n.contents=r;else{let i=sr.isAlias(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${i} parent`)}}UR.visit=cI;UR.visitAsync=lI});var qR=h(F4=>{"use strict";var L4=qe(),fwe=Zh(),hwe={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},gwe=t=>t.replace(/[!,[\]{}]/g,e=>hwe[e]),eg=class t{constructor(e,r){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},t.defaultYaml,e),this.tags=Object.assign({},t.defaultTags,r)}clone(){let e=new t(this.yaml,this.tags);return e.docStart= Line truncated `).map(HSe).filter(Boolean)};function HSe(t,e){if(!t||!t.length||t.charAt(0)==="#")return null;var r=t.split(":");return{username:r[0],password:r[1],uid:r[2],gid:r[3],gecos:r[4],homedir:r[5],shell:r[6]}}});var Q4=h((nje,B4)=>{"use strict";var jSe=require("fs"),zSe=I4();function GSe(){if(process.platform==="win32")return process.env.USERPROFILE?process.env.USERPROFILE:process.env.HOMEDRIVE&&process.env.HOMEPATH?process.env.HOMEDRIVE+process.env.HOMEPATH:process.env.HOME?process.env.HOME:null;if(process.env.HOME)return process.env.HOME;var t=VSe("/etc/passwd"),e=YSe(zSe(t),JSe());if(e)return e;var r=process.env.LOGNAME||process.env.USER||process.env.LNAME||process.env.USERNAME;return r?process.platform==="darwin"?"/Users/"+r:"/home/"+r:null}function YSe(t,e){for(var r=t.length,n=0;n<r;n++)if(+t[n].uid===e)return t[n].homedir}function JSe(){return typeof process.geteuid=="function"?process.geteuid():process.getuid()}function VSe(t){try{return jSe.readFileSync(t,"utf8")}catch{return""}}B4.exports=GSe});var N4=h((ije,hD)=>{"use strict";var b4=require("os");typeof b4.homedir<"u"?hD.exports=b4.homedir:hD.exports=Q4()});var S4=h((sje,x4)=>{var WSe=N4(),w4=require("path");x4.exports=function(e){var r=WSe();return e.charCodeAt(0)===126?e.charCodeAt(1)===43?w4.join(process.cwd(),e.slice(2)):r?w4.join(r,e.slice(1)):e:e}});var ze=h(Pr=>{"use strict";var gD=Symbol.for("yaml.alias"),R4=Symbol.for("yaml.document"),xI=Symbol.for("yaml.map"),v4=Symbol.for("yaml.pair"),mD=Symbol.for("yaml.scalar"),SI=Symbol.for("yaml.seq"),ho=Symbol.for("yaml.node.type"),$Se=t=>!!t&&typeof t=="object"&&t[ho]===gD,KSe=t=>!!t&&typeof t=="object"&&t[ho]===R4,XSe=t=>!!t&&typeof t=="object"&&t[ho]===xI,ZSe=t=>!!t&&typeof t=="object"&&t[ho]===v4,D4=t=>!!t&&typeof t=="object"&&t[ho]===mD,eRe=t=>!!t&&typeof t=="object"&&t[ho]===SI;function _4(t){if(t&&typeof t=="object")switch(t[ho]){case xI:case SI:return!0}return!1}function tRe(t){if(t&&typeof t=="object")switch(t[ho]){case gD:case xI:case mD:case SI:return!0}return!1}var rRe=t=>(D4(t)||_4(t))&&!!t.anchor;Pr.ALIAS=gD;Pr.DOC=R4;Pr.MAP=xI;Pr.NODE_TYPE=ho;Pr.PAIR=v4;Pr.SCALAR=mD;Pr.SEQ=SI;Pr.hasAnchor=rRe;Pr.isAlias=$Se;Pr.isCollection=_4;Pr.isDocument=KSe;Pr.isMap=XSe;Pr.isNode=tRe;Pr.isPair=ZSe;Pr.isScalar=D4;Pr.isSeq=eRe});var hg=h(pD=>{"use strict";var cr=ze(),Dn=Symbol("break visit"),k4=Symbol("skip children"),xs=Symbol("remove node");function RI(t,e){let r=P4(e);cr.isDocument(t)?sd(null,t.contents,r,Object.freeze([t]))===xs&&(t.contents=null):sd(null,t,r,Object.freeze([]))}RI.BREAK=Dn;RI.SKIP=k4;RI.REMOVE=xs;function sd(t,e,r,n){let i=T4(t,e,r,n);if(cr.isNode(i)||cr.isPair(i))return O4(t,n,i),sd(t,i,r,n);if(typeof i!="symbol"){if(cr.isCollection(e)){n=Object.freeze(n.concat(e));for(let s=0;s<e.items.length;++s){let o=sd(s,e.items[s],r,n);if(typeof o=="number")s=o-1;else{if(o===Dn)return Dn;o===xs&&(e.items.splice(s,1),s-=1)}}}else if(cr.isPair(e)){n=Object.freeze(n.concat(e));let s=sd("key",e.key,r,n);if(s===Dn)return Dn;s===xs&&(e.key=null);let o=sd("value",e.value,r,n);if(o===Dn)return Dn;o===xs&&(e.value=null)}}return i}async function vI(t,e){let r=P4(e);cr.isDocument(t)?await od(null,t.contents,r,Object.freeze([t]))===xs&&(t.contents=null):await od(null,t,r,Object.freeze([]))}vI.BREAK=Dn;vI.SKIP=k4;vI.REMOVE=xs;async function od(t,e,r,n){let i=await T4(t,e,r,n);if(cr.isNode(i)||cr.isPair(i))return O4(t,n,i),od(t,i,r,n);if(typeof i!="symbol"){if(cr.isCollection(e)){n=Object.freeze(n.concat(e));for(let s=0;s<e.items.length;++s){let o=await od(s,e.items[s],r,n);if(typeof o=="number")s=o-1;else{if(o===Dn)return Dn;o===xs&&(e.items.splice(s,1),s-=1)}}}else if(cr.isPair(e)){n=Object.freeze(n.concat(e));let s=await od("key",e.key,r,n);if(s===Dn)return Dn;s===xs&&(e.key=null);let o=await od("value",e.value,r,n);if(o===Dn)return Dn;o===xs&&(e.value=null)}}return i}function P4(t){return typeof t=="object"&&(t.Collection||t.Node||t.Value)?Object.assign({Alias:t.Node,Map:t.Node,Scalar:t.Node,Seq:t.Node},t.Value&&{Map:t.Value,Scalar:t.Value,Seq:t.Value},t.Collection&&{Map:t.Collection,Seq:t.Collection},t):t}function T4(t,e,r,n){if(typeof r=="function")return r(t,e,n);if(cr.isMap(e))return r.Map?.(t,e,n);if(cr.isSeq(e))return r.Seq?.(t,e,n);if(cr.isPair(e))return r.Pair?.(t,e,n);if(cr.isScalar(e))return r.Scalar?.(t,e,n);if(cr.isAlias(e))return r.Alias?.(t,e,n)}function O4(t,e,r){let n=e[e.length-1];if(cr.isCollection(n))n.items[t]=r;else if(cr.isPair(n))t==="key"?n.key=r:n.value=r;else if(cr.isDocument(n))n.contents=r;else{let i=cr.isAlias(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${i} parent`)}}pD.visit=RI;pD.visitAsync=vI});var yD=h(M4=>{"use strict";var L4=ze(),nRe=hg(),iRe={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},sRe=t=>t.replace(/[!,[\]{}]/g,e=>iRe[e]),gg=class t{constructor(e,r){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},t.defaultYaml,e),this.tags=Object.assign({},t.defaultTags,r)}clone(){let e=new t(this.yaml,this.tags);return e.docStart= Line truncated
`)}};eg.defaultYaml={explicit:!1,version:"1.2"};eg.defaultTags={"!!":"tag:yaml.org,2002:"};F4.Directives=eg});var uI=h(tg=>{"use strict";var U4=qe(),mwe=Zh();function pwe(t){if(/[\x00-\x19\s,[\]{}]/.test(t)){let r=`Anchor must not contain whitespace or control characters: ${JSON.stringify(t)}`;throw new Error(r)}return!0}function q4(t){let e=new Set;return mwe.visit(t,{Value(r,n){n.anchor&&e.add(n.anchor)}}),e}function H4(t,e){for(let r=1;;++r){let n=`${t}${r}`;if(!e.has(n))return n}}function ywe(t,e){let r=[],n=new Map,i=null;return{onAnchor:s=>{r.push(s),i||(i=q4(t));let o=H4(e,i);return i.add(o),o},setAnchors:()=>{for(let s of r){let o=n.get(s);if(typeof o=="object"&&o.anchor&&(U4.isScalar(o.node)||U4.isCollection(o.node)))o.node.anchor=o.anchor;else{let a=new Error("Failed to resolve repeated object (this should not happen)");throw a.source=s,a}}},sourceObjects:n}}tg.anchorIsValid=pwe;tg.anchorNames=q4;tg.createNodeAnchors=ywe;tg.findNewAnchor=H4});var HR=h(z4=>{"use strict";function rg(t,e,r,n){if(n&&typeof n=="object")if(Array.isArray(n))for(let i=0,s=n.length;i<s;++i){let o=n[i],a=rg(t,n,String(i),o);a===void 0?delete n[i]:a!==o&&(n[i]=a)}else if(n instanceof Map)for(let i of Array.from(n.keys())){let s=n.get(i),o=rg(t,n,i,s);o===void 0?n.delete(i):o!==s&&n.set(i,o)}else if(n instanceof Set)for(let i of Array.from(n)){let s=rg(t,n,i,i);s===void 0?n.delete(i):s!==i&&(n.delete(i),n.add(s))}else for(let[i,s]of Object.entries(n)){let o=rg(t,n,i,s);o===void 0?delete n[i]:o!==s&&(n[i]=o)}return t.call(e,r,n)}z4.applyReviver=rg});var oa=h(G4=>{"use strict";var Ewe=qe();function j4(t,e,r){if(Array.isArray(t))return t.map((n,i)=>j4(n,String(i),r));if(t&&typeof t.toJSON=="function"){if(!r||!Ewe.hasAnchor(t))return t.toJSON(e,r);let n={aliasCount:0,count:1,res:void 0};r.anchors.set(t,n),r.onCreate=s=>{n.res=s,delete r.onCreate};let i=t.toJSON(e,r);return r.onCreate&&r.onCreate(i),i}return typeof t=="bigint"&&!r?.keep?Number(t):t}G4.toJS=j4});var dI=h(J4=>{"use strict";var Cwe=HR(),Y4=qe(),Iwe=oa(),zR=class{constructor(e){Object.defineProperty(this,Y4.NODE_TYPE,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:r,maxAliasCount:n,onAnchor:i,reviver:s}={}){if(!Y4.isDocument(e))throw new TypeError("A document argument is required");let o={anchors:new Map,doc:e,keep:!0,mapAsMap:r===!0,mapKeyWarned:!1,maxAliasCount:typeof n=="number"?n:100},a=Iwe.toJS(this,"",o);if(typeof i=="function")for(let{count:A,res:c}of o.anchors.values())i(c,A);return typeof s=="function"?Cwe.applyReviver(s,{"":a},"",a):a}};J4.NodeBase=zR});var ng=h(W4=>{"use strict";var Bwe=uI(),V4=Zh(),fI=qe(),Qwe=dI(),bwe=oa(),jR=class extends Qwe.NodeBase{constructor(e){super(fI.ALIAS),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e){let r;return V4.visit(e,{Node:(n,i)=>{if(i===this)return V4.visit.BREAK;i.anchor===this.source&&(r=i)}}),r}toJSON(e,r){if(!r)return{source:this.source};let{anchors:n,doc:i,maxAliasCount:s}=r,o=this.resolve(i);if(!o){let A=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(A)}let a=n.get(o);if(a||(bwe.toJS(o,null,r),a=n.get(o)),!a||a.res===void 0){let A="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(A)}if(s>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=hI(i,o,n)),a.count*a.aliasCount>s)){let A="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(A)}return a.res}toString(e,r,n){let i=`*${this.source}`;if(e){if(Bwe.anchorIsValid(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let s=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(s)}if(e.implicitKey)return`${i} `}return i}};function hI(t,e,r){if(fI.isAlias(e)){let n=e.resolve(t),i=r&&n&&r.get(n);return i?i.count*i.aliasCount:0}else if(fI.isCollection(e)){let n=0;for(let i of e.items){let s=hI(t,i,r);s>n&&(n=s)}return n}else if(fI.isPair(e)){let n=hI(t,e.key,r),i=hI(t,e.value,r);return Math.max(n,i)}return 1}W4.Alias=jR});var er=h(GR=>{"use strict";var Nwe=qe(),wwe=dI(),xwe=oa(),Swe=t=>!t||typeof t!="function"&&typeof t!="object",aa=class extends wwe.NodeBase{constructor(e){super(Nwe.SCALAR),this.value=e}toJSON(e,r){return r?.keep?this.value:xwe.toJS(this.value,e,r)}toString(){return String(this.value)}};aa.BLOCK_FOLDED="BLOCK_FOLDED";aa.BLOCK_LITERAL="BLOCK_LITERAL";aa.PLAIN="PLAIN";aa.QUOTE_DOUBLE="QUOTE_DOUBLE";aa.QUOTE_SINGLE="QUOTE_SINGLE";GR.Scalar=aa;GR.isScalarValue=Swe});var ig=h(K4=>{"use strict";var vwe=ng(),EA=qe(),$4=er(),Rwe="tag:yaml.org,2002:";function Dwe(t,e,r){if(e){let n=r.filter(s=>s.tag===e),i=n.find(s=>!s.format)??n[0];if(!i)throw new Error(`Tag ${e} not found`);return i}return r.find(n=>n.identify?.(t)&&!n.format)}function _we(t,e,r){if(EA.isDocument(t)&&(t=t.contents),EA.isNode(t))r Line truncated `)}};gg.defaultYaml={explicit:!1,version:"1.2"};gg.defaultTags={"!!":"tag:yaml.org,2002:"};M4.Directives=gg});var DI=h(mg=>{"use strict";var F4=ze(),oRe=hg();function aRe(t){if(/[\x00-\x19\s,[\]{}]/.test(t)){let r=`Anchor must not contain whitespace or control characters: ${JSON.stringify(t)}`;throw new Error(r)}return!0}function U4(t){let e=new Set;return oRe.visit(t,{Value(r,n){n.anchor&&e.add(n.anchor)}}),e}function q4(t,e){for(let r=1;;++r){let n=`${t}${r}`;if(!e.has(n))return n}}function ARe(t,e){let r=[],n=new Map,i=null;return{onAnchor:s=>{r.push(s),i||(i=U4(t));let o=q4(e,i);return i.add(o),o},setAnchors:()=>{for(let s of r){let o=n.get(s);if(typeof o=="object"&&o.anchor&&(F4.isScalar(o.node)||F4.isCollection(o.node)))o.node.anchor=o.anchor;else{let a=new Error("Failed to resolve repeated object (this should not happen)");throw a.source=s,a}}},sourceObjects:n}}mg.anchorIsValid=aRe;mg.anchorNames=U4;mg.createNodeAnchors=ARe;mg.findNewAnchor=q4});var ED=h(H4=>{"use strict";function pg(t,e,r,n){if(n&&typeof n=="object")if(Array.isArray(n))for(let i=0,s=n.length;i<s;++i){let o=n[i],a=pg(t,n,String(i),o);a===void 0?delete n[i]:a!==o&&(n[i]=a)}else if(n instanceof Map)for(let i of Array.from(n.keys())){let s=n.get(i),o=pg(t,n,i,s);o===void 0?n.delete(i):o!==s&&n.set(i,o)}else if(n instanceof Set)for(let i of Array.from(n)){let s=pg(t,n,i,i);s===void 0?n.delete(i):s!==i&&(n.delete(i),n.add(s))}else for(let[i,s]of Object.entries(n)){let o=pg(t,n,i,s);o===void 0?delete n[i]:o!==s&&(n[i]=o)}return t.call(e,r,n)}H4.applyReviver=pg});var ya=h(z4=>{"use strict";var cRe=ze();function j4(t,e,r){if(Array.isArray(t))return t.map((n,i)=>j4(n,String(i),r));if(t&&typeof t.toJSON=="function"){if(!r||!cRe.hasAnchor(t))return t.toJSON(e,r);let n={aliasCount:0,count:1,res:void 0};r.anchors.set(t,n),r.onCreate=s=>{n.res=s,delete r.onCreate};let i=t.toJSON(e,r);return r.onCreate&&r.onCreate(i),i}return typeof t=="bigint"&&!r?.keep?Number(t):t}z4.toJS=j4});var _I=h(Y4=>{"use strict";var lRe=ED(),G4=ze(),uRe=ya(),CD=class{constructor(e){Object.defineProperty(this,G4.NODE_TYPE,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:r,maxAliasCount:n,onAnchor:i,reviver:s}={}){if(!G4.isDocument(e))throw new TypeError("A document argument is required");let o={anchors:new Map,doc:e,keep:!0,mapAsMap:r===!0,mapKeyWarned:!1,maxAliasCount:typeof n=="number"?n:100},a=uRe.toJS(this,"",o);if(typeof i=="function")for(let{count:A,res:c}of o.anchors.values())i(c,A);return typeof s=="function"?lRe.applyReviver(s,{"":a},"",a):a}};Y4.NodeBase=CD});var yg=h(V4=>{"use strict";var dRe=DI(),J4=hg(),kI=ze(),fRe=_I(),hRe=ya(),ID=class extends fRe.NodeBase{constructor(e){super(kI.ALIAS),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e){let r;return J4.visit(e,{Node:(n,i)=>{if(i===this)return J4.visit.BREAK;i.anchor===this.source&&(r=i)}}),r}toJSON(e,r){if(!r)return{source:this.source};let{anchors:n,doc:i,maxAliasCount:s}=r,o=this.resolve(i);if(!o){let A=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(A)}let a=n.get(o);if(a||(hRe.toJS(o,null,r),a=n.get(o)),!a||a.res===void 0){let A="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(A)}if(s>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=PI(i,o,n)),a.count*a.aliasCount>s)){let A="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(A)}return a.res}toString(e,r,n){let i=`*${this.source}`;if(e){if(dRe.anchorIsValid(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let s=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(s)}if(e.implicitKey)return`${i} `}return i}};function PI(t,e,r){if(kI.isAlias(e)){let n=e.resolve(t),i=r&&n&&r.get(n);return i?i.count*i.aliasCount:0}else if(kI.isCollection(e)){let n=0;for(let i of e.items){let s=PI(t,i,r);s>n&&(n=s)}return n}else if(kI.isPair(e)){let n=PI(t,e.key,r),i=PI(t,e.value,r);return Math.max(n,i)}return 1}V4.Alias=ID});var ir=h(BD=>{"use strict";var gRe=ze(),mRe=_I(),pRe=ya(),yRe=t=>!t||typeof t!="function"&&typeof t!="object",Ea=class extends mRe.NodeBase{constructor(e){super(gRe.SCALAR),this.value=e}toJSON(e,r){return r?.keep?this.value:pRe.toJS(this.value,e,r)}toString(){return String(this.value)}};Ea.BLOCK_FOLDED="BLOCK_FOLDED";Ea.BLOCK_LITERAL="BLOCK_LITERAL";Ea.PLAIN="PLAIN";Ea.QUOTE_DOUBLE="QUOTE_DOUBLE";Ea.QUOTE_SINGLE="QUOTE_SINGLE";BD.Scalar=Ea;BD.isScalarValue=yRe});var Eg=h($4=>{"use strict";var ERe=yg(),_A=ze(),W4=ir(),CRe="tag:yaml.org,2002:";function IRe(t,e,r){if(e){let n=r.filter(s=>s.tag===e),i=n.find(s=>!s.format)??n[0];if(!i)throw new Error(`Tag ${e} not found`);return i}return r.find(n=>n.identify?.(t)&&!n.format)}function BRe(t,e,r){if(_A.isDocument(t)&&(t=t.contents),_A.isNode(t))r Line truncated
`)?VR(r,e):r.includes(` `)?ND(r,e):r.includes(`
`)?` `)?`
`+VR(r,e):(t.endsWith(" ")?"":" ")+r;pI.indentComment=VR;pI.lineComment=Owe;pI.stringifyComment=Twe});var e3=h(og=>{"use strict";var Mwe="flow",WR="block",yI="quoted";function Lwe(t,e,r="flow",{indentAtStart:n,lineWidth:i=80,minContentWidth:s=20,onFold:o,onOverflow:a}={}){if(!i||i<0)return t;i<s&&(s=0);let A=Math.max(1+s,1+i-e.length);if(t.length<=A)return t;let c=[],l={},u=i-e.length;typeof n=="number"&&(n>i-Math.max(2,s)?c.push(0):u=i-n);let d,f,g=!1,m=-1,E=-1,C=-1;r===WR&&(m=Z4(t,m,e.length),m!==-1&&(u=m+A));for(let N;N=t[m+=1];){if(r===yI&&N==="\\"){switch(E=m,t[m+1]){case"x":m+=3;break;case"u":m+=5;break;case"U":m+=9;break;default:m+=1}C=m}if(N===` `+ND(r,e):(t.endsWith(" ")?"":" ")+r;LI.indentComment=ND;LI.lineComment=wRe;LI.stringifyComment=NRe});var Z4=h(Ig=>{"use strict";var xRe="flow",wD="block",MI="quoted";function SRe(t,e,r="flow",{indentAtStart:n,lineWidth:i=80,minContentWidth:s=20,onFold:o,onOverflow:a}={}){if(!i||i<0)return t;i<s&&(s=0);let A=Math.max(1+s,1+i-e.length);if(t.length<=A)return t;let c=[],l={},u=i-e.length;typeof n=="number"&&(n>i-Math.max(2,s)?c.push(0):u=i-n);let d,f,g=!1,m=-1,E=-1,C=-1;r===wD&&(m=X4(t,m,e.length),m!==-1&&(u=m+A));for(let b;b=t[m+=1];){if(r===MI&&b==="\\"){switch(E=m,t[m+1]){case"x":m+=3;break;case"u":m+=5;break;case"U":m+=9;break;default:m+=1}C=m}if(b===`
`)r===WR&&(m=Z4(t,m,e.length)),u=m+e.length+A,d=void 0;else{if(N===" "&&f&&f!==" "&&f!==` `)r===wD&&(m=X4(t,m,e.length)),u=m+e.length+A,d=void 0;else{if(b===" "&&f&&f!==" "&&f!==`
`&&f!==" "){let w=t[m+1];w&&w!==" "&&w!==` `&&f!==" "){let w=t[m+1];w&&w!==" "&&w!==`
`&&w!==" "&&(d=m)}if(m>=u)if(d)c.push(d),u=d+A,d=void 0;else if(r===yI){for(;f===" "||f===" ";)f=N,N=t[m+=1],g=!0;let w=m>C+1?m-2:E-1;if(l[w])return t;c.push(w),l[w]=!0,u=w+A,d=void 0}else g=!0}f=N}if(g&&a&&a(),c.length===0)return t;o&&o();let I=t.slice(0,c[0]);for(let N=0;N<c.length;++N){let w=c[N],R=c[N+1]||t.length;w===0?I=` `&&w!==" "&&(d=m)}if(m>=u)if(d)c.push(d),u=d+A,d=void 0;else if(r===MI){for(;f===" "||f===" ";)f=b,b=t[m+=1],g=!0;let w=m>C+1?m-2:E-1;if(l[w])return t;c.push(w),l[w]=!0,u=w+A,d=void 0}else g=!0}f=b}if(g&&a&&a(),c.length===0)return t;o&&o();let I=t.slice(0,c[0]);for(let b=0;b<c.length;++b){let w=c[b],v=c[b+1]||t.length;w===0?I=`
${e}${t.slice(0,R)}`:(r===yI&&l[w]&&(I+=`${t[w]}\\`),I+=` ${e}${t.slice(0,v)}`:(r===MI&&l[w]&&(I+=`${t[w]}\\`),I+=`
${e}${t.slice(w+1,R)}`)}return I}function Z4(t,e,r){let n=e,i=e+1,s=t[i];for(;s===" "||s===" ";)if(e<i+r)s=t[++e];else{do s=t[++e];while(s&&s!==` ${e}${t.slice(w+1,v)}`)}return I}function X4(t,e,r){let n=e,i=e+1,s=t[i];for(;s===" "||s===" ";)if(e<i+r)s=t[++e];else{do s=t[++e];while(s&&s!==`
`);n=e,i=e+1,s=t[i]}return n}og.FOLD_BLOCK=WR;og.FOLD_FLOW=Mwe;og.FOLD_QUOTED=yI;og.foldFlowLines=Lwe});var Ag=h(t3=>{"use strict";var Ui=er(),Aa=e3(),CI=(t,e)=>({indentAtStart:e?t.indent.length:t.indentAtStart,lineWidth:t.options.lineWidth,minContentWidth:t.options.minContentWidth}),II=t=>/^(%|---|\.\.\.)/m.test(t);function Fwe(t,e,r){if(!e||e<0)return!1;let n=e-r,i=t.length;if(i<=n)return!1;for(let s=0,o=0;s<i;++s)if(t[s]===` `);n=e,i=e+1,s=t[i]}return n}Ig.FOLD_BLOCK=wD;Ig.FOLD_FLOW=xRe;Ig.FOLD_QUOTED=MI;Ig.foldFlowLines=SRe});var Qg=h(e3=>{"use strict";var $i=ir(),Ca=Z4(),UI=(t,e)=>({indentAtStart:e?t.indent.length:t.indentAtStart,lineWidth:t.options.lineWidth,minContentWidth:t.options.minContentWidth}),qI=t=>/^(%|---|\.\.\.)/m.test(t);function RRe(t,e,r){if(!e||e<0)return!1;let n=e-r,i=t.length;if(i<=n)return!1;for(let s=0,o=0;s<i;++s)if(t[s]===`
`){if(s-o>n)return!0;if(o=s+1,i-o<=n)return!1}return!0}function ag(t,e){let r=JSON.stringify(t);if(e.options.doubleQuotedAsJSON)return r;let{implicitKey:n}=e,i=e.options.doubleQuotedMinMultiLineLength,s=e.indent||(II(t)?" ":""),o="",a=0;for(let A=0,c=r[A];c;c=r[++A])if(c===" "&&r[A+1]==="\\"&&r[A+2]==="n"&&(o+=r.slice(a,A)+"\\ ",A+=1,a=A,c="\\"),c==="\\")switch(r[A+1]){case"u":{o+=r.slice(a,A);let l=r.substr(A+2,4);switch(l){case"0000":o+="\\0";break;case"0007":o+="\\a";break;case"000b":o+="\\v";break;case"001b":o+="\\e";break;case"0085":o+="\\N";break;case"00a0":o+="\\_";break;case"2028":o+="\\L";break;case"2029":o+="\\P";break;default:l.substr(0,2)==="00"?o+="\\x"+l.substr(2):o+=r.substr(A,6)}A+=5,a=A+1}break;case"n":if(n||r[A+2]==='"'||r.length<i)A+=1;else{for(o+=r.slice(a,A)+` `){if(s-o>n)return!0;if(o=s+1,i-o<=n)return!1}return!0}function Bg(t,e){let r=JSON.stringify(t);if(e.options.doubleQuotedAsJSON)return r;let{implicitKey:n}=e,i=e.options.doubleQuotedMinMultiLineLength,s=e.indent||(qI(t)?" ":""),o="",a=0;for(let A=0,c=r[A];c;c=r[++A])if(c===" "&&r[A+1]==="\\"&&r[A+2]==="n"&&(o+=r.slice(a,A)+"\\ ",A+=1,a=A,c="\\"),c==="\\")switch(r[A+1]){case"u":{o+=r.slice(a,A);let l=r.substr(A+2,4);switch(l){case"0000":o+="\\0";break;case"0007":o+="\\a";break;case"000b":o+="\\v";break;case"001b":o+="\\e";break;case"0085":o+="\\N";break;case"00a0":o+="\\_";break;case"2028":o+="\\L";break;case"2029":o+="\\P";break;default:l.substr(0,2)==="00"?o+="\\x"+l.substr(2):o+=r.substr(A,6)}A+=5,a=A+1}break;case"n":if(n||r[A+2]==='"'||r.length<i)A+=1;else{for(o+=r.slice(a,A)+`
`;r[A+2]==="\\"&&r[A+3]==="n"&&r[A+4]!=='"';)o+=` `;r[A+2]==="\\"&&r[A+3]==="n"&&r[A+4]!=='"';)o+=`
`,A+=2;o+=s,r[A+2]===" "&&(o+="\\"),A+=1,a=A+1}break;default:A+=1}return o=a?o+r.slice(a):r,n?o:Aa.foldFlowLines(o,s,Aa.FOLD_QUOTED,CI(e,!1))}function $R(t,e){if(e.options.singleQuote===!1||e.implicitKey&&t.includes(` `,A+=2;o+=s,r[A+2]===" "&&(o+="\\"),A+=1,a=A+1}break;default:A+=1}return o=a?o+r.slice(a):r,n?o:Ca.foldFlowLines(o,s,Ca.FOLD_QUOTED,UI(e,!1))}function xD(t,e){if(e.options.singleQuote===!1||e.implicitKey&&t.includes(`
`)||/[ \t]\n|\n[ \t]/.test(t))return ag(t,e);let r=e.indent||(II(t)?" ":""),n="'"+t.replace(/'/g,"''").replace(/\n+/g,`$& `)||/[ \t]\n|\n[ \t]/.test(t))return Bg(t,e);let r=e.indent||(qI(t)?" ":""),n="'"+t.replace(/'/g,"''").replace(/\n+/g,`$&
${r}`)+"'";return e.implicitKey?n:Aa.foldFlowLines(n,r,Aa.FOLD_FLOW,CI(e,!1))}function Vu(t,e){let{singleQuote:r}=e.options,n;if(r===!1)n=ag;else{let i=t.includes('"'),s=t.includes("'");i&&!s?n=$R:s&&!i?n=ag:n=r?$R:ag}return n(t,e)}var KR;try{KR=new RegExp(`(^|(?<! ${r}`)+"'";return e.implicitKey?n:Ca.foldFlowLines(n,r,Ca.FOLD_FLOW,UI(e,!1))}function ad(t,e){let{singleQuote:r}=e.options,n;if(r===!1)n=Bg;else{let i=t.includes('"'),s=t.includes("'");i&&!s?n=xD:s&&!i?n=Bg:n=r?xD:Bg}return n(t,e)}var SD;try{SD=new RegExp(`(^|(?<!
)) ))
+(?! +(?!
|$)`,"g")}catch{KR=/\n+(?!\n|$)/g}function EI({comment:t,type:e,value:r},n,i,s){let{blockQuote:o,commentString:a,lineWidth:A}=n.options;if(!o||/\n[\t ]+$/.test(r)||/^\s*$/.test(r))return Vu(r,n);let c=n.indent||(n.forceBlockIndent||II(r)?" ":""),l=o==="literal"?!0:o==="folded"||e===Ui.Scalar.BLOCK_FOLDED?!1:e===Ui.Scalar.BLOCK_LITERAL?!0:!Fwe(r,A,c.length);if(!r)return l?`| |$)`,"g")}catch{SD=/\n+(?!\n|$)/g}function FI({comment:t,type:e,value:r},n,i,s){let{blockQuote:o,commentString:a,lineWidth:A}=n.options;if(!o||/\n[\t ]+$/.test(r)||/^\s*$/.test(r))return ad(r,n);let c=n.indent||(n.forceBlockIndent||qI(r)?" ":""),l=o==="literal"?!0:o==="folded"||e===$i.Scalar.BLOCK_FOLDED?!1:e===$i.Scalar.BLOCK_LITERAL?!0:!RRe(r,A,c.length);if(!r)return l?`|
`:`> `:`>
`;let u,d;for(d=r.length;d>0;--d){let R=r[d-1];if(R!==` `;let u,d;for(d=r.length;d>0;--d){let v=r[d-1];if(v!==`
`&&R!==" "&&R!==" ")break}let f=r.substring(d),g=f.indexOf(` `&&v!==" "&&v!==" ")break}let f=r.substring(d),g=f.indexOf(`
`);g===-1?u="-":r===f||g!==f.length-1?(u="+",s&&s()):u="",f&&(r=r.slice(0,-f.length),f[f.length-1]===` `);g===-1?u="-":r===f||g!==f.length-1?(u="+",s&&s()):u="",f&&(r=r.slice(0,-f.length),f[f.length-1]===`
`&&(f=f.slice(0,-1)),f=f.replace(KR,`$&${c}`));let m=!1,E,C=-1;for(E=0;E<r.length;++E){let R=r[E];if(R===" ")m=!0;else if(R===` `&&(f=f.slice(0,-1)),f=f.replace(SD,`$&${c}`));let m=!1,E,C=-1;for(E=0;E<r.length;++E){let v=r[E];if(v===" ")m=!0;else if(v===`
`)C=E;else break}let I=r.substring(0,C<E?C+1:E);I&&(r=r.substring(I.length),I=I.replace(/\n+/g,`$&${c}`));let w=(m?c?"2":"1":"")+u;if(t&&(w+=" "+a(t.replace(/ ?[\r\n]+/g," ")),i&&i()),!l){let R=r.replace(/\n+/g,` `)C=E;else break}let I=r.substring(0,C<E?C+1:E);I&&(r=r.substring(I.length),I=I.replace(/\n+/g,`$&${c}`));let w=(m?c?"2":"1":"")+u;if(t&&(w+=" "+a(t.replace(/ ?[\r\n]+/g," ")),i&&i()),!l){let v=r.replace(/\n+/g,`
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`),T=!1,U=CI(n,!0);o!=="folded"&&e!==Ui.Scalar.BLOCK_FOLDED&&(U.onOverflow=()=>{T=!0});let k=Aa.foldFlowLines(`${I}${R}${f}`,c,Aa.FOLD_BLOCK,U);if(!T)return`>${w} $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${c}`),T=!1,U=UI(n,!0);o!=="folded"&&e!==$i.Scalar.BLOCK_FOLDED&&(U.onOverflow=()=>{T=!0});let k=Ca.foldFlowLines(`${I}${v}${f}`,c,Ca.FOLD_BLOCK,U);if(!T)return`>${w}
${c}${k}`}return r=r.replace(/\n+/g,`$&${c}`),`|${w} ${c}${k}`}return r=r.replace(/\n+/g,`$&${c}`),`|${w}
${c}${I}${r}${f}`}function Uwe(t,e,r,n){let{type:i,value:s}=t,{actualString:o,implicitKey:a,indent:A,indentStep:c,inFlow:l}=e;if(a&&s.includes(` ${c}${I}${r}${f}`}function vRe(t,e,r,n){let{type:i,value:s}=t,{actualString:o,implicitKey:a,indent:A,indentStep:c,inFlow:l}=e;if(a&&s.includes(`
`)||l&&/[[\]{},]/.test(s))return Vu(s,e);if(!s||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(s))return a||l||!s.includes(` `)||l&&/[[\]{},]/.test(s))return ad(s,e);if(!s||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(s))return a||l||!s.includes(`
`)?Vu(s,e):EI(t,e,r,n);if(!a&&!l&&i!==Ui.Scalar.PLAIN&&s.includes(` `)?ad(s,e):FI(t,e,r,n);if(!a&&!l&&i!==$i.Scalar.PLAIN&&s.includes(`
`))return EI(t,e,r,n);if(II(s)){if(A==="")return e.forceBlockIndent=!0,EI(t,e,r,n);if(a&&A===c)return Vu(s,e)}let u=s.replace(/\n+/g,`$& `))return FI(t,e,r,n);if(qI(s)){if(A==="")return e.forceBlockIndent=!0,FI(t,e,r,n);if(a&&A===c)return ad(s,e)}let u=s.replace(/\n+/g,`$&
${A}`);if(o){let d=m=>m.default&&m.tag!=="tag:yaml.org,2002:str"&&m.test?.test(u),{compat:f,tags:g}=e.doc.schema;if(g.some(d)||f?.some(d))return Vu(s,e)}return a?u:Aa.foldFlowLines(u,A,Aa.FOLD_FLOW,CI(e,!1))}function qwe(t,e,r,n){let{implicitKey:i,inFlow:s}=e,o=typeof t.value=="string"?t:Object.assign({},t,{value:String(t.value)}),{type:a}=t;a!==Ui.Scalar.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(a=Ui.Scalar.QUOTE_DOUBLE);let A=l=>{switch(l){case Ui.Scalar.BLOCK_FOLDED:case Ui.Scalar.BLOCK_LITERAL:return i||s?Vu(o.value,e):EI(o,e,r,n);case Ui.Scalar.QUOTE_DOUBLE:return ag(o.value,e);case Ui.Scalar.QUOTE_SINGLE:return $R(o.value,e);case Ui.Scalar.PLAIN:return Uwe(o,e,r,n);default:return null}},c=A(a);if(c===null){let{defaultKeyType:l,defaultStringType:u}=e.options,d=i&&l||u;if(c=A(d),c===null)throw new Error(`Unsupported default string type ${d}`)}return c}t3.stringifyString=qwe});var cg=h(XR=>{"use strict";var Hwe=uI(),ca=qe(),zwe=sg(),jwe=Ag();function Gwe(t,e){let r=Object.assign({blockQuote:!0,commentString:zwe.stringifyComment,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},t.schema.toStringOptions,e),n;switch(r.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:t,flowCollectionPadding:r.flowCollectionPadding?" ":"",indent:"",indentStep:typeof r.indent=="number"?" ".repeat(r.indent):" ",inFlow:n,options:r}}function Ywe(t,e){if(e.tag){let i=t.filter(s=>s.tag===e.tag);if(i.length>0)return i.find(s=>s.format===e.format)??i[0]}let r,n;if(ca.isScalar(e)){n=e.value;let i=t.filter(s=>s.identify?.(n));if(i.length>1){let s=i.filter(o=>o.test);s.length>0&&(i=s)}r=i.find(s=>s.format===e.format)??i.find(s=>!s.format)}else n=e,r=t.find(i=>i.nodeClass&&n instanceof i.nodeClass);if(!r){let i=n?.constructor?.name??typeof n;throw new Error(`Tag not resolved for ${i} value`)}return r}function Jwe(t,e,{anchors:r,doc:n}){if(!n.directives)return"";let i=[],s=(ca.isScalar(t)||ca.isCollection(t))&&t.anchor;s&&Hwe.anchorIsValid(s)&&(r.add(s),i.push(`&${s}`));let o=t.tag?t.tag:e.default?null:e.tag;return o&&i.push(n.directives.tagString(o)),i.join(" ")}function Vwe(t,e,r,n){if(ca.isPair(t))return t.toString(e,r,n);if(ca.isAlias(t)){if(e.doc.directives)return t.toString(e);if(e.resolvedAliases?.has(t))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(t):e.resolvedAliases=new Set([t]),t=t.resolve(e.doc)}let i,s=ca.isNode(t)?t:e.doc.createNode(t,{onTagObj:A=>i=A});i||(i=Ywe(e.doc.schema.tags,s));let o=Jwe(s,i,e);o.length>0&&(e.indentAtStart=(e.indentAtStart??0)+o.length+1);let a=typeof i.stringify=="function"?i.stringify(s,e,r,n):ca.isScalar(s)?jwe.stringifyString(s,e,r,n):s.toString(e,r,n);return o?ca.isScalar(s)||a[0]==="{"||a[0]==="["?`${o} ${a}`:`${o} ${A}`);if(o){let d=m=>m.default&&m.tag!=="tag:yaml.org,2002:str"&&m.test?.test(u),{compat:f,tags:g}=e.doc.schema;if(g.some(d)||f?.some(d))return ad(s,e)}return a?u:Ca.foldFlowLines(u,A,Ca.FOLD_FLOW,UI(e,!1))}function DRe(t,e,r,n){let{implicitKey:i,inFlow:s}=e,o=typeof t.value=="string"?t:Object.assign({},t,{value:String(t.value)}),{type:a}=t;a!==$i.Scalar.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(a=$i.Scalar.QUOTE_DOUBLE);let A=l=>{switch(l){case $i.Scalar.BLOCK_FOLDED:case $i.Scalar.BLOCK_LITERAL:return i||s?ad(o.value,e):FI(o,e,r,n);case $i.Scalar.QUOTE_DOUBLE:return Bg(o.value,e);case $i.Scalar.QUOTE_SINGLE:return xD(o.value,e);case $i.Scalar.PLAIN:return vRe(o,e,r,n);default:return null}},c=A(a);if(c===null){let{defaultKeyType:l,defaultStringType:u}=e.options,d=i&&l||u;if(c=A(d),c===null)throw new Error(`Unsupported default string type ${d}`)}return c}e3.stringifyString=DRe});var bg=h(RD=>{"use strict";var _Re=DI(),Ia=ze(),kRe=Cg(),PRe=Qg();function TRe(t,e){let r=Object.assign({blockQuote:!0,commentString:kRe.stringifyComment,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},t.schema.toStringOptions,e),n;switch(r.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:t,flowCollectionPadding:r.flowCollectionPadding?" ":"",indent:"",indentStep:typeof r.indent=="number"?" ".repeat(r.indent):" ",inFlow:n,options:r}}function ORe(t,e){if(e.tag){let i=t.filter(s=>s.tag===e.tag);if(i.length>0)return i.find(s=>s.format===e.format)??i[0]}let r,n;if(Ia.isScalar(e)){n=e.value;let i=t.filter(s=>s.identify?.(n));if(i.length>1){let s=i.filter(o=>o.test);s.length>0&&(i=s)}r=i.find(s=>s.format===e.format)??i.find(s=>!s.format)}else n=e,r=t.find(i=>i.nodeClass&&n instanceof i.nodeClass);if(!r){let i=n?.constructor?.name??typeof n;throw new Error(`Tag not resolved for ${i} value`)}return r}function LRe(t,e,{anchors:r,doc:n}){if(!n.directives)return"";let i=[],s=(Ia.isScalar(t)||Ia.isCollection(t))&&t.anchor;s&&_Re.anchorIsValid(s)&&(r.add(s),i.push(`&${s}`));let o=t.tag?t.tag:e.default?null:e.tag;return o&&i.push(n.directives.tagString(o)),i.join(" ")}function MRe(t,e,r,n){if(Ia.isPair(t))return t.toString(e,r,n);if(Ia.isAlias(t)){if(e.doc.directives)return t.toString(e);if(e.resolvedAliases?.has(t))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(t):e.resolvedAliases=new Set([t]),t=t.resolve(e.doc)}let i,s=Ia.isNode(t)?t:e.doc.createNode(t,{onTagObj:A=>i=A});i||(i=ORe(e.doc.schema.tags,s));let o=LRe(s,i,e);o.length>0&&(e.indentAtStart=(e.indentAtStart??0)+o.length+1);let a=typeof i.stringify=="function"?i.stringify(s,e,r,n):Ia.isScalar(s)?PRe.stringifyString(s,e,r,n):s.toString(e,r,n);return o?Ia.isScalar(s)||a[0]==="{"||a[0]==="["?`${o} ${a}`:`${o}
${e.indent}${a}`:a}XR.createStringifyContext=Gwe;XR.stringify=Vwe});var s3=h(i3=>{"use strict";var no=qe(),r3=er(),n3=cg(),lg=sg();function Wwe({key:t,value:e},r,n,i){let{allNullValues:s,doc:o,indent:a,indentStep:A,options:{commentString:c,indentSeq:l,simpleKeys:u}}=r,d=no.isNode(t)&&t.comment||null;if(u){if(d)throw new Error("With simple keys, key nodes cannot have comments");if(no.isCollection(t)||!no.isNode(t)&&typeof t=="object"){let U="With simple keys, collection cannot be used as a key value";throw new Error(U)}}let f=!u&&(!t||d&&e==null&&!r.inFlow||no.isCollection(t)||(no.isScalar(t)?t.type===r3.Scalar.BLOCK_FOLDED||t.type===r3.Scalar.BLOCK_LITERAL:typeof t=="object"));r=Object.assign({},r,{allNullValues:!1,implicitKey:!f&&(u||!s),indent:a+A});let g=!1,m=!1,E=n3.stringify(t,r,()=>g=!0,()=>m=!0);if(!f&&!r.inFlow&&E.length>1024){if(u)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");f=!0}if(r.inFlow){if(s||e==null)return g&&n&&n(),E===""?"?":f?`? ${E}`:E}else if(s&&!u||e==null&&f)return E=`? ${E}`,d&&!g?E+=lg.lineComment(E,r.indent,c(d)):m&&i&&i(),E;g&&(d=null),f?(d&&(E+=lg.lineComment(E,r.indent,c(d))),E=`? ${E} ${e.indent}${a}`:a}RD.createStringifyContext=TRe;RD.stringify=MRe});var i3=h(n3=>{"use strict";var go=ze(),t3=ir(),r3=bg(),Ng=Cg();function FRe({key:t,value:e},r,n,i){let{allNullValues:s,doc:o,indent:a,indentStep:A,options:{commentString:c,indentSeq:l,simpleKeys:u}}=r,d=go.isNode(t)&&t.comment||null;if(u){if(d)throw new Error("With simple keys, key nodes cannot have comments");if(go.isCollection(t)||!go.isNode(t)&&typeof t=="object"){let U="With simple keys, collection cannot be used as a key value";throw new Error(U)}}let f=!u&&(!t||d&&e==null&&!r.inFlow||go.isCollection(t)||(go.isScalar(t)?t.type===t3.Scalar.BLOCK_FOLDED||t.type===t3.Scalar.BLOCK_LITERAL:typeof t=="object"));r=Object.assign({},r,{allNullValues:!1,implicitKey:!f&&(u||!s),indent:a+A});let g=!1,m=!1,E=r3.stringify(t,r,()=>g=!0,()=>m=!0);if(!f&&!r.inFlow&&E.length>1024){if(u)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");f=!0}if(r.inFlow){if(s||e==null)return g&&n&&n(),E===""?"?":f?`? ${E}`:E}else if(s&&!u||e==null&&f)return E=`? ${E}`,d&&!g?E+=Ng.lineComment(E,r.indent,c(d)):m&&i&&i(),E;g&&(d=null),f?(d&&(E+=Ng.lineComment(E,r.indent,c(d))),E=`? ${E}
${a}:`):(E=`${E}:`,d&&(E+=lg.lineComment(E,r.indent,c(d))));let C,I,N;no.isNode(e)?(C=!!e.spaceBefore,I=e.commentBefore,N=e.comment):(C=!1,I=null,N=null,e&&typeof e=="object"&&(e=o.createNode(e))),r.implicitKey=!1,!f&&!d&&no.isScalar(e)&&(r.indentAtStart=E.length+1),m=!1,!l&&A.length>=2&&!r.inFlow&&!f&&no.isSeq(e)&&!e.flow&&!e.tag&&!e.anchor&&(r.indent=r.indent.substring(2));let w=!1,R=n3.stringify(e,r,()=>w=!0,()=>m=!0),T=" ";if(d||C||I){if(T=C?` ${a}:`):(E=`${E}:`,d&&(E+=Ng.lineComment(E,r.indent,c(d))));let C,I,b;go.isNode(e)?(C=!!e.spaceBefore,I=e.commentBefore,b=e.comment):(C=!1,I=null,b=null,e&&typeof e=="object"&&(e=o.createNode(e))),r.implicitKey=!1,!f&&!d&&go.isScalar(e)&&(r.indentAtStart=E.length+1),m=!1,!l&&A.length>=2&&!r.inFlow&&!f&&go.isSeq(e)&&!e.flow&&!e.tag&&!e.anchor&&(r.indent=r.indent.substring(2));let w=!1,v=r3.stringify(e,r,()=>w=!0,()=>m=!0),T=" ";if(d||C||I){if(T=C?`
`:"",I){let U=c(I);T+=` `:"",I){let U=c(I);T+=`
${lg.indentComment(U,r.indent)}`}R===""&&!r.inFlow?T===` ${Ng.indentComment(U,r.indent)}`}v===""&&!r.inFlow?T===`
`&&(T=` `&&(T=`
`):T+=` `):T+=`
${r.indent}`}else if(!f&&no.isCollection(e)){let U=R[0],k=R.indexOf(` ${r.indent}`}else if(!f&&go.isCollection(e)){let U=v[0],k=v.indexOf(`
`),J=k!==-1,Qe=r.inFlow??e.flow??e.items.length===0;if(J||!Qe){let Se=!1;if(J&&(U==="&"||U==="!")){let H=R.indexOf(" ");U==="&"&&H!==-1&&H<k&&R[H+1]==="!"&&(H=R.indexOf(" ",H+1)),(H===-1||k<H)&&(Se=!0)}Se||(T=` `),J=k!==-1,we=r.inFlow??e.flow??e.items.length===0;if(J||!we){let De=!1;if(J&&(U==="&"||U==="!")){let H=v.indexOf(" ");U==="&"&&H!==-1&&H<k&&v[H+1]==="!"&&(H=v.indexOf(" ",H+1)),(H===-1||k<H)&&(De=!0)}De||(T=`
${r.indent}`)}}else(R===""||R[0]===` ${r.indent}`)}}else(v===""||v[0]===`
`)&&(T="");return E+=T+R,r.inFlow?w&&n&&n():N&&!w?E+=lg.lineComment(E,r.indent,c(N)):m&&i&&i(),E}i3.stringifyPair=Wwe});var eD=h(ZR=>{"use strict";var o3=require("node:process");function $we(t,...e){t==="debug"&&console.log(...e)}function Kwe(t,e){(t==="debug"||t==="warn")&&(typeof o3.emitWarning=="function"?o3.emitWarning(e):console.warn(e))}ZR.debug=$we;ZR.warn=Kwe});var NI=h(bI=>{"use strict";var ug=qe(),a3=er(),BI="<<",QI={identify:t=>t===BI||typeof t=="symbol"&&t.description===BI,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new a3.Scalar(Symbol(BI)),{addToJSMap:A3}),stringify:()=>BI},Xwe=(t,e)=>(QI.identify(e)||ug.isScalar(e)&&(!e.type||e.type===a3.Scalar.PLAIN)&&QI.identify(e.value))&&t?.doc.schema.tags.some(r=>r.tag===QI.tag&&r.default);function A3(t,e,r){if(r=t&&ug.isAlias(r)?r.resolve(t.doc):r,ug.isSeq(r))for(let n of r.items)tD(t,e,n);else if(Array.isArray(r))for(let n of r)tD(t,e,n);else tD(t,e,r)}function tD(t,e,r){let n=t&&ug.isAlias(r)?r.resolve(t.doc):r;if(!ug.isMap(n))throw new Error("Merge sources must be maps or map aliases");let i=n.toJSON(null,t,Map);for(let[s,o]of i)e instanceof Map?e.has(s)||e.set(s,o):e instanceof Set?e.add(s):Object.prototype.hasOwnProperty.call(e,s)||Object.defineProperty(e,s,{value:o,writable:!0,enumerable:!0,configurable:!0});return e}bI.addMergeToJSMap=A3;bI.isMergeKey=Xwe;bI.merge=QI});var nD=h(u3=>{"use strict";var Zwe=eD(),c3=NI(),exe=cg(),l3=qe(),rD=oa();function txe(t,e,{key:r,value:n}){if(l3.isNode(r)&&r.addToJSMap)r.addToJSMap(t,e,n);else if(c3.isMergeKey(t,r))c3.addMergeToJSMap(t,e,n);else{let i=rD.toJS(r,"",t);if(e instanceof Map)e.set(i,rD.toJS(n,i,t));else if(e instanceof Set)e.add(i);else{let s=rxe(r,i,t),o=rD.toJS(n,s,t);s in e?Object.defineProperty(e,s,{value:o,writable:!0,enumerable:!0,configurable:!0}):e[s]=o}}return e}function rxe(t,e,r){if(e===null)return"";if(typeof e!="object")return String(e);if(l3.isNode(t)&&r?.doc){let n=exe.createStringifyContext(r.doc,{});n.anchors=new Set;for(let s of r.anchors.keys())n.anchors.add(s.anchor);n.inFlow=!0,n.inStringifyKey=!0;let i=t.toString(n);if(!r.mapKeyWarned){let s=JSON.stringify(i);s.length>40&&(s=s.substring(0,36)+'..."'),Zwe.warn(r.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${s}. Set mapAsMap: true to use object keys.`),r.mapKeyWarned=!0}return i}return JSON.stringify(e)}u3.addPairToJSMap=txe});var la=h(iD=>{"use strict";var d3=ig(),nxe=s3(),ixe=nD(),wI=qe();function sxe(t,e,r){let n=d3.createNode(t,void 0,r),i=d3.createNode(e,void 0,r);return new xI(n,i)}var xI=class t{constructor(e,r=null){Object.defineProperty(this,wI.NODE_TYPE,{value:wI.PAIR}),this.key=e,this.value=r}clone(e){let{key:r,value:n}=this;return wI.isNode(r)&&(r=r.clone(e)),wI.isNode(n)&&(n=n.clone(e)),new t(r,n)}toJSON(e,r){let n=r?.mapAsMap?new Map:{};return ixe.addPairToJSMap(r,n,this)}toString(e,r,n){return e?.doc?nxe.stringifyPair(this,e,r,n):JSON.stringify(this)}};iD.Pair=xI;iD.createPair=sxe});var sD=h(h3=>{"use strict";var CA=qe(),f3=cg(),SI=sg();function oxe(t,e,r){return(e.inFlow??t.flow?Axe:axe)(t,e,r)}function axe({comment:t,items:e},r,{blockItemPrefix:n,flowChars:i,itemIndent:s,onChompKeep:o,onComment:a}){let{indent:A,options:{commentString:c}}=r,l=Object.assign({},r,{indent:s,type:null}),u=!1,d=[];for(let g=0;g<e.length;++g){let m=e[g],E=null;if(CA.isNode(m))!u&&m.spaceBefore&&d.push(""),vI(r,d,m.commentBefore,u),m.comment&&(E=m.comment);else if(CA.isPair(m)){let I=CA.isNode(m.key)?m.key:null;I&&(!u&&I.spaceBefore&&d.push(""),vI(r,d,I.commentBefore,u))}u=!1;let C=f3.stringify(m,l,()=>E=null,()=>u=!0);E&&(C+=SI.lineComment(C,s,c(E))),u&&E&&(u=!1),d.push(n+C)}let f;if(d.length===0)f=i.start+i.end;else{f=d[0];for(let g=1;g<d.length;++g){let m=d[g];f+=m?` `)&&(T="");return E+=T+v,r.inFlow?w&&n&&n():b&&!w?E+=Ng.lineComment(E,r.indent,c(b)):m&&i&&i(),E}n3.stringifyPair=FRe});var DD=h(vD=>{"use strict";var s3=require("node:process");function URe(t,...e){t==="debug"&&console.log(...e)}function qRe(t,e){(t==="debug"||t==="warn")&&(typeof s3.emitWarning=="function"?s3.emitWarning(e):console.warn(e))}vD.debug=URe;vD.warn=qRe});var GI=h(zI=>{"use strict";var wg=ze(),o3=ir(),HI="<<",jI={identify:t=>t===HI||typeof t=="symbol"&&t.description===HI,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new o3.Scalar(Symbol(HI)),{addToJSMap:a3}),stringify:()=>HI},HRe=(t,e)=>(jI.identify(e)||wg.isScalar(e)&&(!e.type||e.type===o3.Scalar.PLAIN)&&jI.identify(e.value))&&t?.doc.schema.tags.some(r=>r.tag===jI.tag&&r.default);function a3(t,e,r){if(r=t&&wg.isAlias(r)?r.resolve(t.doc):r,wg.isSeq(r))for(let n of r.items)_D(t,e,n);else if(Array.isArray(r))for(let n of r)_D(t,e,n);else _D(t,e,r)}function _D(t,e,r){let n=t&&wg.isAlias(r)?r.resolve(t.doc):r;if(!wg.isMap(n))throw new Error("Merge sources must be maps or map aliases");let i=n.toJSON(null,t,Map);for(let[s,o]of i)e instanceof Map?e.has(s)||e.set(s,o):e instanceof Set?e.add(s):Object.prototype.hasOwnProperty.call(e,s)||Object.defineProperty(e,s,{value:o,writable:!0,enumerable:!0,configurable:!0});return e}zI.addMergeToJSMap=a3;zI.isMergeKey=HRe;zI.merge=jI});var PD=h(l3=>{"use strict";var jRe=DD(),A3=GI(),zRe=bg(),c3=ze(),kD=ya();function GRe(t,e,{key:r,value:n}){if(c3.isNode(r)&&r.addToJSMap)r.addToJSMap(t,e,n);else if(A3.isMergeKey(t,r))A3.addMergeToJSMap(t,e,n);else{let i=kD.toJS(r,"",t);if(e instanceof Map)e.set(i,kD.toJS(n,i,t));else if(e instanceof Set)e.add(i);else{let s=YRe(r,i,t),o=kD.toJS(n,s,t);s in e?Object.defineProperty(e,s,{value:o,writable:!0,enumerable:!0,configurable:!0}):e[s]=o}}return e}function YRe(t,e,r){if(e===null)return"";if(typeof e!="object")return String(e);if(c3.isNode(t)&&r?.doc){let n=zRe.createStringifyContext(r.doc,{});n.anchors=new Set;for(let s of r.anchors.keys())n.anchors.add(s.anchor);n.inFlow=!0,n.inStringifyKey=!0;let i=t.toString(n);if(!r.mapKeyWarned){let s=JSON.stringify(i);s.length>40&&(s=s.substring(0,36)+'..."'),jRe.warn(r.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${s}. Set mapAsMap: true to use object keys.`),r.mapKeyWarned=!0}return i}return JSON.stringify(e)}l3.addPairToJSMap=GRe});var Ba=h(TD=>{"use strict";var u3=Eg(),JRe=i3(),VRe=PD(),YI=ze();function WRe(t,e,r){let n=u3.createNode(t,void 0,r),i=u3.createNode(e,void 0,r);return new JI(n,i)}var JI=class t{constructor(e,r=null){Object.defineProperty(this,YI.NODE_TYPE,{value:YI.PAIR}),this.key=e,this.value=r}clone(e){let{key:r,value:n}=this;return YI.isNode(r)&&(r=r.clone(e)),YI.isNode(n)&&(n=n.clone(e)),new t(r,n)}toJSON(e,r){let n=r?.mapAsMap?new Map:{};return VRe.addPairToJSMap(r,n,this)}toString(e,r,n){return e?.doc?JRe.stringifyPair(this,e,r,n):JSON.stringify(this)}};TD.Pair=JI;TD.createPair=WRe});var OD=h(f3=>{"use strict";var kA=ze(),d3=bg(),VI=Cg();function $Re(t,e,r){return(e.inFlow??t.flow?XRe:KRe)(t,e,r)}function KRe({comment:t,items:e},r,{blockItemPrefix:n,flowChars:i,itemIndent:s,onChompKeep:o,onComment:a}){let{indent:A,options:{commentString:c}}=r,l=Object.assign({},r,{indent:s,type:null}),u=!1,d=[];for(let g=0;g<e.length;++g){let m=e[g],E=null;if(kA.isNode(m))!u&&m.spaceBefore&&d.push(""),WI(r,d,m.commentBefore,u),m.comment&&(E=m.comment);else if(kA.isPair(m)){let I=kA.isNode(m.key)?m.key:null;I&&(!u&&I.spaceBefore&&d.push(""),WI(r,d,I.commentBefore,u))}u=!1;let C=d3.stringify(m,l,()=>E=null,()=>u=!0);E&&(C+=VI.lineComment(C,s,c(E))),u&&E&&(u=!1),d.push(n+C)}let f;if(d.length===0)f=i.start+i.end;else{f=d[0];for(let g=1;g<d.length;++g){let m=d[g];f+=m?`
${A}${m}`:` ${A}${m}`:`
`}}return t?(f+=` `}}return t?(f+=`
`+SI.indentComment(c(t),A),a&&a()):u&&o&&o(),f}function Axe({items:t},e,{flowChars:r,itemIndent:n}){let{indent:i,indentStep:s,flowCollectionPadding:o,options:{commentString:a}}=e;n+=s;let A=Object.assign({},e,{indent:n,inFlow:!0,type:null}),c=!1,l=0,u=[];for(let g=0;g<t.length;++g){let m=t[g],E=null;if(CA.isNode(m))m.spaceBefore&&u.push(""),vI(e,u,m.commentBefore,!1),m.comment&&(E=m.comment);else if(CA.isPair(m)){let I=CA.isNode(m.key)?m.key:null;I&&(I.spaceBefore&&u.push(""),vI(e,u,I.commentBefore,!1),I.comment&&(c=!0));let N=CA.isNode(m.value)?m.value:null;N?(N.comment&&(E=N.comment),N.commentBefore&&(c=!0)):m.value==null&&I?.comment&&(E=I.comment)}E&&(c=!0);let C=f3.stringify(m,A,()=>E=null);g<t.length-1&&(C+=","),E&&(C+=SI.lineComment(C,n,a(E))),!c&&(u.length>l||C.includes(` `+VI.indentComment(c(t),A),a&&a()):u&&o&&o(),f}function XRe({items:t},e,{flowChars:r,itemIndent:n}){let{indent:i,indentStep:s,flowCollectionPadding:o,options:{commentString:a}}=e;n+=s;let A=Object.assign({},e,{indent:n,inFlow:!0,type:null}),c=!1,l=0,u=[];for(let g=0;g<t.length;++g){let m=t[g],E=null;if(kA.isNode(m))m.spaceBefore&&u.push(""),WI(e,u,m.commentBefore,!1),m.comment&&(E=m.comment);else if(kA.isPair(m)){let I=kA.isNode(m.key)?m.key:null;I&&(I.spaceBefore&&u.push(""),WI(e,u,I.commentBefore,!1),I.comment&&(c=!0));let b=kA.isNode(m.value)?m.value:null;b?(b.comment&&(E=b.comment),b.commentBefore&&(c=!0)):m.value==null&&I?.comment&&(E=I.comment)}E&&(c=!0);let C=d3.stringify(m,A,()=>E=null);g<t.length-1&&(C+=","),E&&(C+=VI.lineComment(C,n,a(E))),!c&&(u.length>l||C.includes(`
`))&&(c=!0),u.push(C),l=u.length}let{start:d,end:f}=r;if(u.length===0)return d+f;if(!c){let g=u.reduce((m,E)=>m+E.length+2,2);c=e.options.lineWidth>0&&g>e.options.lineWidth}if(c){let g=d;for(let m of u)g+=m?` `))&&(c=!0),u.push(C),l=u.length}let{start:d,end:f}=r;if(u.length===0)return d+f;if(!c){let g=u.reduce((m,E)=>m+E.length+2,2);c=e.options.lineWidth>0&&g>e.options.lineWidth}if(c){let g=d;for(let m of u)g+=m?`
${s}${i}${m}`:` ${s}${i}${m}`:`
`;return`${g} `;return`${g}
${i}${f}`}else return`${d}${o}${u.join(" ")}${o}${f}`}function vI({indent:t,options:{commentString:e}},r,n,i){if(n&&i&&(n=n.replace(/^\n+/,"")),n){let s=SI.indentComment(e(n),t);r.push(s.trimStart())}}h3.stringifyCollection=oxe});var da=h(aD=>{"use strict";var cxe=sD(),lxe=nD(),uxe=mI(),ua=qe(),RI=la(),dxe=er();function dg(t,e){let r=ua.isScalar(e)?e.value:e;for(let n of t)if(ua.isPair(n)&&(n.key===e||n.key===r||ua.isScalar(n.key)&&n.key.value===r))return n}var oD=class extends uxe.Collection{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(ua.MAP,e),this.items=[]}static from(e,r,n){let{keepUndefined:i,replacer:s}=n,o=new this(e),a=(A,c)=>{if(typeof s=="function")c=s.call(r,A,c);else if(Array.isArray(s)&&!s.includes(A))return;(c!==void 0||i)&&o.items.push(RI.createPair(A,c,n))};if(r instanceof Map)for(let[A,c]of r)a(A,c);else if(r&&typeof r=="object")for(let A of Object.keys(r))a(A,r[A]);return typeof e.sortMapEntries=="function"&&o.items.sort(e.sortMapEntries),o}add(e,r){let n;ua.isPair(e)?n=e:!e||typeof e!="object"||!("key"in e)?n=new RI.Pair(e,e?.value):n=new RI.Pair(e.key,e.value);let i=dg(this.items,n.key),s=this.schema?.sortMapEntries;if(i){if(!r)throw new Error(`Key ${n.key} already set`);ua.isScalar(i.value)&&dxe.isScalarValue(n.value)?i.value.value=n.value:i.value=n.value}else if(s){let o=this.items.findIndex(a=>s(n,a)<0);o===-1?this.items.push(n):this.items.splice(o,0,n)}else this.items.push(n)}delete(e){let r=dg(this.items,e);return r?this.items.splice(this.items.indexOf(r),1).length>0:!1}get(e,r){let i=dg(this.items,e)?.value;return(!r&&ua.isScalar(i)?i.value:i)??void 0}has(e){return!!dg(this.items,e)}set(e,r){this.add(new RI.Pair(e,r),!0)}toJSON(e,r,n){let i=n?new n:r?.mapAsMap?new Map:{};r?.onCreate&&r.onCreate(i);for(let s of this.items)lxe.addPairToJSMap(r,i,s);return i}toString(e,r,n){if(!e)return JSON.stringify(this);for(let i of this.items)if(!ua.isPair(i))throw new Error(`Map items must all be pairs; found ${JSON.stringify(i)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),cxe.stringifyCollection(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:r})}};aD.YAMLMap=oD;aD.findPair=dg});var Wu=h(m3=>{"use strict";var fxe=qe(),g3=da(),hxe={collection:"map",default:!0,nodeClass:g3.YAMLMap,tag:"tag:yaml.org,2002:map",resolve(t,e){return fxe.isMap(t)||e("Expected a mapping for this tag"),t},createNode:(t,e,r)=>g3.YAMLMap.from(t,e,r)};m3.map=hxe});var fa=h(p3=>{"use strict";var gxe=ig(),mxe=sD(),pxe=mI(),_I=qe(),yxe=er(),Exe=oa(),AD=class extends pxe.Collection{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(_I.SEQ,e),this.items=[]}add(e){this.items.push(e)}delete(e){let r=DI(e);return typeof r!="number"?!1:this.items.splice(r,1).length>0}get(e,r){let n=DI(e);if(typeof n!="number")return;let i=this.items[n];return!r&&_I.isScalar(i)?i.value:i}has(e){let r=DI(e);return typeof r=="number"&&r<this.items.length}set(e,r){let n=DI(e);if(typeof n!="number")throw new Error(`Expected a valid index, not ${e}.`);let i=this.items[n];_I.isScalar(i)&&yxe.isScalarValue(r)?i.value=r:this.items[n]=r}toJSON(e,r){let n=[];r?.onCreate&&r.onCreate(n);let i=0;for(let s of this.items)n.push(Exe.toJS(s,String(i++),r));return n}toString(e,r,n){return e?mxe.stringifyCollection(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:n,onComment:r}):JSON.stringify(this)}static from(e,r,n){let{replacer:i}=n,s=new this(e);if(r&&Symbol.iterator in Object(r)){let o=0;for(let a of r){if(typeof i=="function"){let A=r instanceof Set?a:String(o++);a=i.call(r,A,a)}s.items.push(gxe.createNode(a,void 0,n))}}return s}};function DI(t){let e=_I.isScalar(t)?t.value:t;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}p3.YAMLSeq=AD});var $u=h(E3=>{"use strict";var Cxe=qe(),y3=fa(),Ixe={collection:"seq",default:!0,nodeClass:y3.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve(t,e){return Cxe.isSeq(t)||e("Expected a sequence for this tag"),t},createNode:(t,e,r)=>y3.YAMLSeq.from(t,e,r)};E3.seq=Ixe});var fg=h(C3=>{"use strict";var Bxe=Ag(),Qxe={identify:t=>typeof t=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:t=>t,stringify(t,e,r,n){return e=Object.assign({actualString:!0},e),Bxe.stringifyString(t,e,r,n)}};C3.string=Qxe});var kI=h(Q3=>{"use strict";var I3=er(),B3={identify:t=>t==null,createNode:()=>new I3.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new I3.Scalar(null),stringify:({source:t},e)=>typeof t=="string"&&B3.test.test(t)?t:e.options.nullStr};Q3.nullTag=B3});var cD=h(N3=>{"use strict";var bxe=er(),b3={identify:t=>typeof t=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:t=>new bxe.Scalar(t[0]==="t"||t[0]==="T"),stringify({source:t,value:e},r){if(t&&b3.test.test(t)){let n=t[0]==="t"||t[0 Line truncated ${i}${f}`}else return`${d}${o}${u.join(" ")}${o}${f}`}function WI({indent:t,options:{commentString:e}},r,n,i){if(n&&i&&(n=n.replace(/^\n+/,"")),n){let s=VI.indentComment(e(n),t);r.push(s.trimStart())}}f3.stringifyCollection=$Re});var ba=h(MD=>{"use strict";var ZRe=OD(),eve=PD(),tve=OI(),Qa=ze(),$I=Ba(),rve=ir();function xg(t,e){let r=Qa.isScalar(e)?e.value:e;for(let n of t)if(Qa.isPair(n)&&(n.key===e||n.key===r||Qa.isScalar(n.key)&&n.key.value===r))return n}var LD=class extends tve.Collection{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(Qa.MAP,e),this.items=[]}static from(e,r,n){let{keepUndefined:i,replacer:s}=n,o=new this(e),a=(A,c)=>{if(typeof s=="function")c=s.call(r,A,c);else if(Array.isArray(s)&&!s.includes(A))return;(c!==void 0||i)&&o.items.push($I.createPair(A,c,n))};if(r instanceof Map)for(let[A,c]of r)a(A,c);else if(r&&typeof r=="object")for(let A of Object.keys(r))a(A,r[A]);return typeof e.sortMapEntries=="function"&&o.items.sort(e.sortMapEntries),o}add(e,r){let n;Qa.isPair(e)?n=e:!e||typeof e!="object"||!("key"in e)?n=new $I.Pair(e,e?.value):n=new $I.Pair(e.key,e.value);let i=xg(this.items,n.key),s=this.schema?.sortMapEntries;if(i){if(!r)throw new Error(`Key ${n.key} already set`);Qa.isScalar(i.value)&&rve.isScalarValue(n.value)?i.value.value=n.value:i.value=n.value}else if(s){let o=this.items.findIndex(a=>s(n,a)<0);o===-1?this.items.push(n):this.items.splice(o,0,n)}else this.items.push(n)}delete(e){let r=xg(this.items,e);return r?this.items.splice(this.items.indexOf(r),1).length>0:!1}get(e,r){let i=xg(this.items,e)?.value;return(!r&&Qa.isScalar(i)?i.value:i)??void 0}has(e){return!!xg(this.items,e)}set(e,r){this.add(new $I.Pair(e,r),!0)}toJSON(e,r,n){let i=n?new n:r?.mapAsMap?new Map:{};r?.onCreate&&r.onCreate(i);for(let s of this.items)eve.addPairToJSMap(r,i,s);return i}toString(e,r,n){if(!e)return JSON.stringify(this);for(let i of this.items)if(!Qa.isPair(i))throw new Error(`Map items must all be pairs; found ${JSON.stringify(i)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),ZRe.stringifyCollection(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:r})}};MD.YAMLMap=LD;MD.findPair=xg});var Ad=h(g3=>{"use strict";var nve=ze(),h3=ba(),ive={collection:"map",default:!0,nodeClass:h3.YAMLMap,tag:"tag:yaml.org,2002:map",resolve(t,e){return nve.isMap(t)||e("Expected a mapping for this tag"),t},createNode:(t,e,r)=>h3.YAMLMap.from(t,e,r)};g3.map=ive});var Na=h(m3=>{"use strict";var sve=Eg(),ove=OD(),ave=OI(),XI=ze(),Ave=ir(),cve=ya(),FD=class extends ave.Collection{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(XI.SEQ,e),this.items=[]}add(e){this.items.push(e)}delete(e){let r=KI(e);return typeof r!="number"?!1:this.items.splice(r,1).length>0}get(e,r){let n=KI(e);if(typeof n!="number")return;let i=this.items[n];return!r&&XI.isScalar(i)?i.value:i}has(e){let r=KI(e);return typeof r=="number"&&r<this.items.length}set(e,r){let n=KI(e);if(typeof n!="number")throw new Error(`Expected a valid index, not ${e}.`);let i=this.items[n];XI.isScalar(i)&&Ave.isScalarValue(r)?i.value=r:this.items[n]=r}toJSON(e,r){let n=[];r?.onCreate&&r.onCreate(n);let i=0;for(let s of this.items)n.push(cve.toJS(s,String(i++),r));return n}toString(e,r,n){return e?ove.stringifyCollection(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:n,onComment:r}):JSON.stringify(this)}static from(e,r,n){let{replacer:i}=n,s=new this(e);if(r&&Symbol.iterator in Object(r)){let o=0;for(let a of r){if(typeof i=="function"){let A=r instanceof Set?a:String(o++);a=i.call(r,A,a)}s.items.push(sve.createNode(a,void 0,n))}}return s}};function KI(t){let e=XI.isScalar(t)?t.value:t;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}m3.YAMLSeq=FD});var cd=h(y3=>{"use strict";var lve=ze(),p3=Na(),uve={collection:"seq",default:!0,nodeClass:p3.YAMLSeq,tag:"tag:yaml.org,2002:seq",resolve(t,e){return lve.isSeq(t)||e("Expected a sequence for this tag"),t},createNode:(t,e,r)=>p3.YAMLSeq.from(t,e,r)};y3.seq=uve});var Sg=h(E3=>{"use strict";var dve=Qg(),fve={identify:t=>typeof t=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:t=>t,stringify(t,e,r,n){return e=Object.assign({actualString:!0},e),dve.stringifyString(t,e,r,n)}};E3.string=fve});var ZI=h(B3=>{"use strict";var C3=ir(),I3={identify:t=>t==null,createNode:()=>new C3.Scalar(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new C3.Scalar(null),stringify:({source:t},e)=>typeof t=="string"&&I3.test.test(t)?t:e.options.nullStr};B3.nullTag=I3});var UD=h(b3=>{"use strict";var hve=ir(),Q3={identify:t=>typeof t=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:t=>new hve.Scalar(t[0]==="t"||t[0]==="T"),stringify({source:t,value:e},r){if(t&&Q3.test.test(t)){let n=t[0]==="t"||t[0 Line truncated
`:" ")}return Gxe.stringifyString({comment:t,type:e,value:a},n,i,s)}};P3.binary=Yxe});var UI=h(FI=>{"use strict";var LI=qe(),yD=la(),Jxe=er(),Vxe=fa();function T3(t,e){if(LI.isSeq(t))for(let r=0;r<t.items.length;++r){let n=t.items[r];if(!LI.isPair(n)){if(LI.isMap(n)){n.items.length>1&&e("Each pair must have its own sequence indicator");let i=n.items[0]||new yD.Pair(new Jxe.Scalar(null));if(n.commentBefore&&(i.key.commentBefore=i.key.commentBefore?`${n.commentBefore} `:" ")}return Tve.stringifyString({comment:t,type:e,value:a},n,i,s)}};k3.binary=Ove});var oB=h(sB=>{"use strict";var iB=ze(),WD=Ba(),Lve=ir(),Mve=Na();function P3(t,e){if(iB.isSeq(t))for(let r=0;r<t.items.length;++r){let n=t.items[r];if(!iB.isPair(n)){if(iB.isMap(n)){n.items.length>1&&e("Each pair must have its own sequence indicator");let i=n.items[0]||new WD.Pair(new Lve.Scalar(null));if(n.commentBefore&&(i.key.commentBefore=i.key.commentBefore?`${n.commentBefore}
${i.key.commentBefore}`:n.commentBefore),n.comment){let s=i.value??i.key;s.comment=s.comment?`${n.comment} ${i.key.commentBefore}`:n.commentBefore),n.comment){let s=i.value??i.key;s.comment=s.comment?`${n.comment}
${s.comment}`:n.comment}n=i}t.items[r]=LI.isPair(n)?n:new yD.Pair(n)}}else e("Expected a sequence for this tag");return t}function O3(t,e,r){let{replacer:n}=r,i=new Vxe.YAMLSeq(t);i.tag="tag:yaml.org,2002:pairs";let s=0;if(e&&Symbol.iterator in Object(e))for(let o of e){typeof n=="function"&&(o=n.call(e,String(s++),o));let a,A;if(Array.isArray(o))if(o.length===2)a=o[0],A=o[1];else throw new TypeError(`Expected [key, value] tuple: ${o}`);else if(o&&o instanceof Object){let c=Object.keys(o);if(c.length===1)a=c[0],A=o[a];else throw new TypeError(`Expected tuple with one key, not ${c.length} keys`)}else a=o;i.items.push(yD.createPair(a,A,r))}return i}var Wxe={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:T3,createNode:O3};FI.createPairs=O3;FI.pairs=Wxe;FI.resolvePairs=T3});var ID=h(CD=>{"use strict";var M3=qe(),ED=oa(),gg=da(),$xe=fa(),L3=UI(),IA=class t extends $xe.YAMLSeq{constructor(){super(),this.add=gg.YAMLMap.prototype.add.bind(this),this.delete=gg.YAMLMap.prototype.delete.bind(this),this.get=gg.YAMLMap.prototype.get.bind(this),this.has=gg.YAMLMap.prototype.has.bind(this),this.set=gg.YAMLMap.prototype.set.bind(this),this.tag=t.tag}toJSON(e,r){if(!r)return super.toJSON(e);let n=new Map;r?.onCreate&&r.onCreate(n);for(let i of this.items){let s,o;if(M3.isPair(i)?(s=ED.toJS(i.key,"",r),o=ED.toJS(i.value,s,r)):s=ED.toJS(i,"",r),n.has(s))throw new Error("Ordered maps must not include duplicate keys");n.set(s,o)}return n}static from(e,r,n){let i=L3.createPairs(e,r,n),s=new this;return s.items=i.items,s}};IA.tag="tag:yaml.org,2002:omap";var Kxe={collection:"seq",identify:t=>t instanceof Map,nodeClass:IA,default:!1,tag:"tag:yaml.org,2002:omap",resolve(t,e){let r=L3.resolvePairs(t,e),n=[];for(let{key:i}of r.items)M3.isScalar(i)&&(n.includes(i.value)?e(`Ordered maps must not include duplicate keys: ${i.value}`):n.push(i.value));return Object.assign(new IA,r)},createNode:(t,e,r)=>IA.from(t,e,r)};CD.YAMLOMap=IA;CD.omap=Kxe});var z3=h(BD=>{"use strict";var F3=er();function U3({value:t,source:e},r){return e&&(t?q3:H3).test.test(e)?e:t?r.options.trueStr:r.options.falseStr}var q3={identify:t=>t===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new F3.Scalar(!0),stringify:U3},H3={identify:t=>t===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new F3.Scalar(!1),stringify:U3};BD.falseTag=H3;BD.trueTag=q3});var j3=h(qI=>{"use strict";var Xxe=er(),QD=Ku(),Zxe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:t=>t.slice(-3).toLowerCase()==="nan"?NaN:t[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:QD.stringifyNumber},eSe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:t=>parseFloat(t.replace(/_/g,"")),stringify(t){let e=Number(t.value);return isFinite(e)?e.toExponential():QD.stringifyNumber(t)}},tSe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(t){let e=new Xxe.Scalar(parseFloat(t.replace(/_/g,""))),r=t.indexOf(".");if(r!==-1){let n=t.substring(r+1).replace(/_/g,"");n[n.length-1]==="0"&&(e.minFractionDigits=n.length)}return e},stringify:QD.stringifyNumber};qI.float=tSe;qI.floatExp=eSe;qI.floatNaN=Zxe});var Y3=h(pg=>{"use strict";var G3=Ku(),mg=t=>typeof t=="bigint"||Number.isInteger(t);function HI(t,e,r,{intAsBigInt:n}){let i=t[0];if((i==="-"||i==="+")&&(e+=1),t=t.substring(e).replace(/_/g,""),n){switch(r){case 2:t=`0b${t}`;break;case 8:t=`0o${t}`;break;case 16:t=`0x${t}`;break}let o=BigInt(t);return i==="-"?BigInt(-1)*o:o}let s=parseInt(t,r);return i==="-"?-1*s:s}function bD(t,e,r){let{value:n}=t;if(mg(n)){let i=n.toString(e);return n<0?"-"+r+i.substr(1):r+i}return G3.stringifyNumber(t)}var rSe={identify:mg,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(t,e,r)=>HI(t,2,2,r),stringify:t=>bD(t,2,"0b")},nSe={identify:mg,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(t,e,r)=>HI(t,1,8,r),stringify:t=>bD(t,8,"0")},iSe={identify:mg,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(t,e,r)=>HI(t,0,10,r),stringify:G3.stringifyNumber},sSe={identify:mg,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(t,e,r)=>HI(t,2,16,r),stringify:t=>bD(t,16,"0x")};pg.int=iSe;pg.intBin=rSe;pg.intHex=sSe;pg.intOct=nSe});var wD=h(ND=>{"use strict";var GI=qe(),zI=la(),jI=da(),BA=class t extends jI.YAMLMap{constructor(e){super(e),this.tag=t.tag}add(e){let r;GI.isPair(e)?r=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?r=new zI.Pair(e.key,null):r=new zI.Pair(e,null),jI.findPair(this.items,r.key)||this.items.push(r)}get(e,r){let n=jI.findPair(this.items,e);return!r&&GI.isPair(n)?GI.isSca Line truncated ${s.comment}`:n.comment}n=i}t.items[r]=iB.isPair(n)?n:new WD.Pair(n)}}else e("Expected a sequence for this tag");return t}function T3(t,e,r){let{replacer:n}=r,i=new Mve.YAMLSeq(t);i.tag="tag:yaml.org,2002:pairs";let s=0;if(e&&Symbol.iterator in Object(e))for(let o of e){typeof n=="function"&&(o=n.call(e,String(s++),o));let a,A;if(Array.isArray(o))if(o.length===2)a=o[0],A=o[1];else throw new TypeError(`Expected [key, value] tuple: ${o}`);else if(o&&o instanceof Object){let c=Object.keys(o);if(c.length===1)a=c[0],A=o[a];else throw new TypeError(`Expected tuple with one key, not ${c.length} keys`)}else a=o;i.items.push(WD.createPair(a,A,r))}return i}var Fve={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:P3,createNode:T3};sB.createPairs=T3;sB.pairs=Fve;sB.resolvePairs=P3});var XD=h(KD=>{"use strict";var O3=ze(),$D=ya(),vg=ba(),Uve=Na(),L3=oB(),PA=class t extends Uve.YAMLSeq{constructor(){super(),this.add=vg.YAMLMap.prototype.add.bind(this),this.delete=vg.YAMLMap.prototype.delete.bind(this),this.get=vg.YAMLMap.prototype.get.bind(this),this.has=vg.YAMLMap.prototype.has.bind(this),this.set=vg.YAMLMap.prototype.set.bind(this),this.tag=t.tag}toJSON(e,r){if(!r)return super.toJSON(e);let n=new Map;r?.onCreate&&r.onCreate(n);for(let i of this.items){let s,o;if(O3.isPair(i)?(s=$D.toJS(i.key,"",r),o=$D.toJS(i.value,s,r)):s=$D.toJS(i,"",r),n.has(s))throw new Error("Ordered maps must not include duplicate keys");n.set(s,o)}return n}static from(e,r,n){let i=L3.createPairs(e,r,n),s=new this;return s.items=i.items,s}};PA.tag="tag:yaml.org,2002:omap";var qve={collection:"seq",identify:t=>t instanceof Map,nodeClass:PA,default:!1,tag:"tag:yaml.org,2002:omap",resolve(t,e){let r=L3.resolvePairs(t,e),n=[];for(let{key:i}of r.items)O3.isScalar(i)&&(n.includes(i.value)?e(`Ordered maps must not include duplicate keys: ${i.value}`):n.push(i.value));return Object.assign(new PA,r)},createNode:(t,e,r)=>PA.from(t,e,r)};KD.YAMLOMap=PA;KD.omap=qve});var H3=h(ZD=>{"use strict";var M3=ir();function F3({value:t,source:e},r){return e&&(t?U3:q3).test.test(e)?e:t?r.options.trueStr:r.options.falseStr}var U3={identify:t=>t===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new M3.Scalar(!0),stringify:F3},q3={identify:t=>t===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new M3.Scalar(!1),stringify:F3};ZD.falseTag=q3;ZD.trueTag=U3});var j3=h(aB=>{"use strict";var Hve=ir(),e_=ld(),jve={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:t=>t.slice(-3).toLowerCase()==="nan"?NaN:t[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:e_.stringifyNumber},zve={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:t=>parseFloat(t.replace(/_/g,"")),stringify(t){let e=Number(t.value);return isFinite(e)?e.toExponential():e_.stringifyNumber(t)}},Gve={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(t){let e=new Hve.Scalar(parseFloat(t.replace(/_/g,""))),r=t.indexOf(".");if(r!==-1){let n=t.substring(r+1).replace(/_/g,"");n[n.length-1]==="0"&&(e.minFractionDigits=n.length)}return e},stringify:e_.stringifyNumber};aB.float=Gve;aB.floatExp=zve;aB.floatNaN=jve});var G3=h(_g=>{"use strict";var z3=ld(),Dg=t=>typeof t=="bigint"||Number.isInteger(t);function AB(t,e,r,{intAsBigInt:n}){let i=t[0];if((i==="-"||i==="+")&&(e+=1),t=t.substring(e).replace(/_/g,""),n){switch(r){case 2:t=`0b${t}`;break;case 8:t=`0o${t}`;break;case 16:t=`0x${t}`;break}let o=BigInt(t);return i==="-"?BigInt(-1)*o:o}let s=parseInt(t,r);return i==="-"?-1*s:s}function t_(t,e,r){let{value:n}=t;if(Dg(n)){let i=n.toString(e);return n<0?"-"+r+i.substr(1):r+i}return z3.stringifyNumber(t)}var Yve={identify:Dg,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(t,e,r)=>AB(t,2,2,r),stringify:t=>t_(t,2,"0b")},Jve={identify:Dg,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(t,e,r)=>AB(t,1,8,r),stringify:t=>t_(t,8,"0")},Vve={identify:Dg,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(t,e,r)=>AB(t,0,10,r),stringify:z3.stringifyNumber},Wve={identify:Dg,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(t,e,r)=>AB(t,2,16,r),stringify:t=>t_(t,16,"0x")};_g.int=Vve;_g.intBin=Yve;_g.intHex=Wve;_g.intOct=Jve});var n_=h(r_=>{"use strict";var uB=ze(),cB=Ba(),lB=ba(),TA=class t extends lB.YAMLMap{constructor(e){super(e),this.tag=t.tag}add(e){let r;uB.isPair(e)?r=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?r=new cB.Pair(e.key,null):r=new cB.Pair(e,null),lB.findPair(this.items,r.key)||this.items.push(r)}get(e,r){let n=lB.findPair(this.items,e);return!r&&uB.isPair(n)?uB.isSca Line truncated
`)?(r.push("..."),r.push(Eg.indentComment(A,""))):r.push(`... ${A}`)}else r.push("...");else{let A=t.comment;A&&o&&(A=A.replace(/^\n+/,"")),A&&((!o||a)&&r[r.length-1]!==""&&r.push(""),r.push(Eg.indentComment(s(A),"")))}return r.join(` `)?(r.push("..."),r.push(Pg.indentComment(A,""))):r.push(`... ${A}`)}else r.push("...");else{let A=t.comment;A&&o&&(A=A.replace(/^\n+/,"")),A&&((!o||a)&&r[r.length-1]!==""&&r.push(""),r.push(Pg.indentComment(s(A),"")))}return r.join(`
`)+` `)+`
`}c$.stringifyDocument=_Se});var Cg=h(u$=>{"use strict";var kSe=ng(),Xu=mI(),Ii=qe(),PSe=la(),TSe=oa(),OSe=OD(),MSe=l$(),LD=uI(),LSe=HR(),FSe=ig(),FD=qR(),UD=class t{constructor(e,r,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Ii.NODE_TYPE,{value:Ii.DOC});let i=null;typeof r=="function"||Array.isArray(r)?i=r:n===void 0&&r&&(n=r,r=void 0);let s=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},n);this.options=s;let{version:o}=s;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(o=this.directives.yaml.version)):this.directives=new FD.Directives({version:o}),this.setSchema(o,n),this.contents=e===void 0?null:this.createNode(e,i,n)}clone(){let e=Object.create(t.prototype,{[Ii.NODE_TYPE]:{value:Ii.DOC}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=Ii.isNode(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){Zu(this.contents)&&this.contents.add(e)}addIn(e,r){Zu(this.contents)&&this.contents.addIn(e,r)}createAlias(e,r){if(!e.anchor){let n=LD.anchorNames(this);e.anchor=!r||n.has(r)?LD.findNewAnchor(r||"a",n):r}return new kSe.Alias(e.anchor)}createNode(e,r,n){let i;if(typeof r=="function")e=r.call({"":e},"",e),i=r;else if(Array.isArray(r)){let E=I=>typeof I=="number"||I instanceof String||I instanceof Number,C=r.filter(E).map(String);C.length>0&&(r=r.concat(C)),i=r}else n===void 0&&r&&(n=r,r=void 0);let{aliasDuplicateObjects:s,anchorPrefix:o,flow:a,keepUndefined:A,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=LD.createNodeAnchors(this,o||"a"),g={aliasDuplicateObjects:s??!0,keepUndefined:A??!1,onAnchor:u,onTagObj:c,replacer:i,schema:this.schema,sourceObjects:f},m=FSe.createNode(e,l,g);return a&&Ii.isCollection(m)&&(m.flow=!0),d(),m}createPair(e,r,n={}){let i=this.createNode(e,null,n),s=this.createNode(r,null,n);return new PSe.Pair(i,s)}delete(e){return Zu(this.contents)?this.contents.delete(e):!1}deleteIn(e){return Xu.isEmptyPath(e)?this.contents==null?!1:(this.contents=null,!0):Zu(this.contents)?this.contents.deleteIn(e):!1}get(e,r){return Ii.isCollection(this.contents)?this.contents.get(e,r):void 0}getIn(e,r){return Xu.isEmptyPath(e)?!r&&Ii.isScalar(this.contents)?this.contents.value:this.contents:Ii.isCollection(this.contents)?this.contents.getIn(e,r):void 0}has(e){return Ii.isCollection(this.contents)?this.contents.has(e):!1}hasIn(e){return Xu.isEmptyPath(e)?this.contents!==void 0:Ii.isCollection(this.contents)?this.contents.hasIn(e):!1}set(e,r){this.contents==null?this.contents=Xu.collectionFromPath(this.schema,[e],r):Zu(this.contents)&&this.contents.set(e,r)}setIn(e,r){Xu.isEmptyPath(e)?this.contents=r:this.contents==null?this.contents=Xu.collectionFromPath(this.schema,Array.from(e),r):Zu(this.contents)&&this.contents.setIn(e,r)}setSchema(e,r={}){typeof e=="number"&&(e=String(e));let n;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new FD.Directives({version:"1.1"}),n={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new FD.Directives({version:e}),n={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,n=null;break;default:{let i=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${i}`)}}if(r.schema instanceof Object)this.schema=r.schema;else if(n)this.schema=new OSe.Schema(Object.assign(n,r));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:r,mapAsMap:n,maxAliasCount:i,onAnchor:s,reviver:o}={}){let a={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof i=="number"?i:100},A=TSe.toJS(this.contents,r??"",a);if(typeof s=="function")for(let{count:c,res:l}of a.anchors.values())s(l,c);return typeof o=="function"?LSe.applyReviver(o,{"":A},"",A):A}toJSON(e,r){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:r})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let r=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${r}`)}return MSe.stringifyDocument(this,e)}};function Zu(t){if(Ii.isCollection(t))return!0;throw new Error("Expected a YAML collection as document contents")}u$.Document=UD});var Qg=h(Bg=>{"use strict";var Ig=class extends Error{constructor(e,r,n,i){super(),this.name=e,this.code=n,this.message=i,this.pos=r}},qD=class extends Ig{constructor(e,r,n){super("YAMLParseError",e,r,n) Line truncated `}A9.stringifyDocument=BDe});var Tg=h(l9=>{"use strict";var QDe=yg(),ud=OI(),Ri=ze(),bDe=Ba(),NDe=ya(),wDe=f_(),xDe=c9(),g_=DI(),SDe=ED(),RDe=Eg(),m_=yD(),p_=class t{constructor(e,r,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Ri.NODE_TYPE,{value:Ri.DOC});let i=null;typeof r=="function"||Array.isArray(r)?i=r:n===void 0&&r&&(n=r,r=void 0);let s=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},n);this.options=s;let{version:o}=s;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(o=this.directives.yaml.version)):this.directives=new m_.Directives({version:o}),this.setSchema(o,n),this.contents=e===void 0?null:this.createNode(e,i,n)}clone(){let e=Object.create(t.prototype,{[Ri.NODE_TYPE]:{value:Ri.DOC}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=Ri.isNode(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){dd(this.contents)&&this.contents.add(e)}addIn(e,r){dd(this.contents)&&this.contents.addIn(e,r)}createAlias(e,r){if(!e.anchor){let n=g_.anchorNames(this);e.anchor=!r||n.has(r)?g_.findNewAnchor(r||"a",n):r}return new QDe.Alias(e.anchor)}createNode(e,r,n){let i;if(typeof r=="function")e=r.call({"":e},"",e),i=r;else if(Array.isArray(r)){let E=I=>typeof I=="number"||I instanceof String||I instanceof Number,C=r.filter(E).map(String);C.length>0&&(r=r.concat(C)),i=r}else n===void 0&&r&&(n=r,r=void 0);let{aliasDuplicateObjects:s,anchorPrefix:o,flow:a,keepUndefined:A,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=g_.createNodeAnchors(this,o||"a"),g={aliasDuplicateObjects:s??!0,keepUndefined:A??!1,onAnchor:u,onTagObj:c,replacer:i,schema:this.schema,sourceObjects:f},m=RDe.createNode(e,l,g);return a&&Ri.isCollection(m)&&(m.flow=!0),d(),m}createPair(e,r,n={}){let i=this.createNode(e,null,n),s=this.createNode(r,null,n);return new bDe.Pair(i,s)}delete(e){return dd(this.contents)?this.contents.delete(e):!1}deleteIn(e){return ud.isEmptyPath(e)?this.contents==null?!1:(this.contents=null,!0):dd(this.contents)?this.contents.deleteIn(e):!1}get(e,r){return Ri.isCollection(this.contents)?this.contents.get(e,r):void 0}getIn(e,r){return ud.isEmptyPath(e)?!r&&Ri.isScalar(this.contents)?this.contents.value:this.contents:Ri.isCollection(this.contents)?this.contents.getIn(e,r):void 0}has(e){return Ri.isCollection(this.contents)?this.contents.has(e):!1}hasIn(e){return ud.isEmptyPath(e)?this.contents!==void 0:Ri.isCollection(this.contents)?this.contents.hasIn(e):!1}set(e,r){this.contents==null?this.contents=ud.collectionFromPath(this.schema,[e],r):dd(this.contents)&&this.contents.set(e,r)}setIn(e,r){ud.isEmptyPath(e)?this.contents=r:this.contents==null?this.contents=ud.collectionFromPath(this.schema,Array.from(e),r):dd(this.contents)&&this.contents.setIn(e,r)}setSchema(e,r={}){typeof e=="number"&&(e=String(e));let n;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new m_.Directives({version:"1.1"}),n={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new m_.Directives({version:e}),n={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,n=null;break;default:{let i=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${i}`)}}if(r.schema instanceof Object)this.schema=r.schema;else if(n)this.schema=new wDe.Schema(Object.assign(n,r));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:r,mapAsMap:n,maxAliasCount:i,onAnchor:s,reviver:o}={}){let a={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof i=="number"?i:100},A=NDe.toJS(this.contents,r??"",a);if(typeof s=="function")for(let{count:c,res:l}of a.anchors.values())s(l,c);return typeof o=="function"?SDe.applyReviver(o,{"":A},"",A):A}toJSON(e,r){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:r})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let r=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${r}`)}return xDe.stringifyDocument(this,e)}};function dd(t){if(Ri.isCollection(t))return!0;throw new Error("Expected a YAML collection as document contents")}l9.Document=p_});var Mg=h(Lg=>{"use strict";var Og=class extends Error{constructor(e,r,n,i){super(),this.name=e,this.code=n,this.message=i,this.pos=r}},y_=class extends Og{constructor(e,r,n){super("YAMLParseError",e,r,n) Line truncated
`),o=a+o}if(/[^ ]/.test(o)){let a=1,A=r.linePos[1];A&&A.line===n&&A.col>i&&(a=Math.max(1,Math.min(A.col-i,80-s)));let c=" ".repeat(s)+"^".repeat(a);r.message+=`: `),o=a+o}if(/[^ ]/.test(o)){let a=1,A=r.linePos[1];A&&A.line===n&&A.col>i&&(a=Math.max(1,Math.min(A.col-i,80-s)));let c=" ".repeat(s)+"^".repeat(a);r.message+=`:
${o} ${o}
${c} ${c}
`}};Bg.YAMLError=Ig;Bg.YAMLParseError=qD;Bg.YAMLWarning=HD;Bg.prettifyError=USe});var bg=h(d$=>{"use strict";function qSe(t,{flow:e,indicator:r,next:n,offset:i,onError:s,parentIndent:o,startOnNewline:a}){let A=!1,c=a,l=a,u="",d="",f=!1,g=!1,m=null,E=null,C=null,I=null,N=null,w=null,R=null;for(let k of t)switch(g&&(k.type!=="space"&&k.type!=="newline"&&k.type!=="comma"&&s(k.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),g=!1),m&&(c&&k.type!=="comment"&&k.type!=="newline"&&s(m,"TAB_AS_INDENT","Tabs are not allowed as indentation"),m=null),k.type){case"space":!e&&(r!=="doc-start"||n?.type!=="flow-collection")&&k.source.includes(" ")&&(m=k),l=!0;break;case"comment":{l||s(k,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let J=k.source.substring(1)||" ";u?u+=d+J:u=J,d="",c=!1;break}case"newline":c?u?u+=k.source:(!w||r!=="seq-item-ind")&&(A=!0):d+=k.source,c=!0,f=!0,(E||C)&&(I=k),l=!0;break;case"anchor":E&&s(k,"MULTIPLE_ANCHORS","A node can have at most one anchor"),k.source.endsWith(":")&&s(k.offset+k.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),E=k,R===null&&(R=k.offset),c=!1,l=!1,g=!0;break;case"tag":{C&&s(k,"MULTIPLE_TAGS","A node can have at most one tag"),C=k,R===null&&(R=k.offset),c=!1,l=!1,g=!0;break}case r:(E||C)&&s(k,"BAD_PROP_ORDER",`Anchors and tags must be after the ${k.source} indicator`),w&&s(k,"UNEXPECTED_TOKEN",`Unexpected ${k.source} in ${e??"collection"}`),w=k,c=r==="seq-item-ind"||r==="explicit-key-ind",l=!1;break;case"comma":if(e){N&&s(k,"UNEXPECTED_TOKEN",`Unexpected , in ${e}`),N=k,c=!1,l=!1;break}default:s(k,"UNEXPECTED_TOKEN",`Unexpected ${k.type} token`),c=!1,l=!1}let T=t[t.length-1],U=T?T.offset+T.source.length:i;return g&&n&&n.type!=="space"&&n.type!=="newline"&&n.type!=="comma"&&(n.type!=="scalar"||n.source!=="")&&s(n.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),m&&(c&&m.indent<=o||n?.type==="block-map"||n?.type==="block-seq")&&s(m,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:N,found:w,spaceBefore:A,comment:u,hasNewline:f,anchor:E,tag:C,newlineAfterProp:I,end:U,start:R??U}}d$.resolveProps=qSe});var $I=h(f$=>{"use strict";function zD(t){if(!t)return null;switch(t.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(t.source.includes(` `}};Lg.YAMLError=Og;Lg.YAMLParseError=y_;Lg.YAMLWarning=E_;Lg.prettifyError=vDe});var Fg=h(u9=>{"use strict";function DDe(t,{flow:e,indicator:r,next:n,offset:i,onError:s,parentIndent:o,startOnNewline:a}){let A=!1,c=a,l=a,u="",d="",f=!1,g=!1,m=null,E=null,C=null,I=null,b=null,w=null,v=null;for(let k of t)switch(g&&(k.type!=="space"&&k.type!=="newline"&&k.type!=="comma"&&s(k.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),g=!1),m&&(c&&k.type!=="comment"&&k.type!=="newline"&&s(m,"TAB_AS_INDENT","Tabs are not allowed as indentation"),m=null),k.type){case"space":!e&&(r!=="doc-start"||n?.type!=="flow-collection")&&k.source.includes(" ")&&(m=k),l=!0;break;case"comment":{l||s(k,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let J=k.source.substring(1)||" ";u?u+=d+J:u=J,d="",c=!1;break}case"newline":c?u?u+=k.source:(!w||r!=="seq-item-ind")&&(A=!0):d+=k.source,c=!0,f=!0,(E||C)&&(I=k),l=!0;break;case"anchor":E&&s(k,"MULTIPLE_ANCHORS","A node can have at most one anchor"),k.source.endsWith(":")&&s(k.offset+k.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),E=k,v===null&&(v=k.offset),c=!1,l=!1,g=!0;break;case"tag":{C&&s(k,"MULTIPLE_TAGS","A node can have at most one tag"),C=k,v===null&&(v=k.offset),c=!1,l=!1,g=!0;break}case r:(E||C)&&s(k,"BAD_PROP_ORDER",`Anchors and tags must be after the ${k.source} indicator`),w&&s(k,"UNEXPECTED_TOKEN",`Unexpected ${k.source} in ${e??"collection"}`),w=k,c=r==="seq-item-ind"||r==="explicit-key-ind",l=!1;break;case"comma":if(e){b&&s(k,"UNEXPECTED_TOKEN",`Unexpected , in ${e}`),b=k,c=!1,l=!1;break}default:s(k,"UNEXPECTED_TOKEN",`Unexpected ${k.type} token`),c=!1,l=!1}let T=t[t.length-1],U=T?T.offset+T.source.length:i;return g&&n&&n.type!=="space"&&n.type!=="newline"&&n.type!=="comma"&&(n.type!=="scalar"||n.source!=="")&&s(n.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),m&&(c&&m.indent<=o||n?.type==="block-map"||n?.type==="block-seq")&&s(m,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:b,found:w,spaceBefore:A,comment:u,hasNewline:f,anchor:E,tag:C,newlineAfterProp:I,end:U,start:v??U}}u9.resolveProps=DDe});var mB=h(d9=>{"use strict";function C_(t){if(!t)return null;switch(t.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(t.source.includes(`
`))return!0;if(t.end){for(let e of t.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(let e of t.items){for(let r of e.start)if(r.type==="newline")return!0;if(e.sep){for(let r of e.sep)if(r.type==="newline")return!0}if(zD(e.key)||zD(e.value))return!0}return!1;default:return!0}}f$.containsNewline=zD});var jD=h(h$=>{"use strict";var HSe=$I();function zSe(t,e,r){if(e?.type==="flow-collection"){let n=e.end[0];n.indent===t&&(n.source==="]"||n.source==="}")&&HSe.containsNewline(e)&&r(n,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}h$.flowIndentCheck=zSe});var GD=h(m$=>{"use strict";var g$=qe();function jSe(t,e,r){let{uniqueKeys:n}=t.options;if(n===!1)return!1;let i=typeof n=="function"?n:(s,o)=>s===o||g$.isScalar(s)&&g$.isScalar(o)&&s.value===o.value;return e.some(s=>i(s.key,r))}m$.mapIncludes=jSe});var B$=h(I$=>{"use strict";var p$=la(),GSe=da(),y$=bg(),YSe=$I(),E$=jD(),JSe=GD(),C$="All mapping items must start at the same column";function VSe({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=s?.nodeClass??GSe.YAMLMap,a=new o(r.schema);r.atRoot&&(r.atRoot=!1);let A=n.offset,c=null;for(let l of n.items){let{start:u,key:d,sep:f,value:g}=l,m=y$.resolveProps(u,{indicator:"explicit-key-ind",next:d??f?.[0],offset:A,onError:i,parentIndent:n.indent,startOnNewline:!0}),E=!m.found;if(E){if(d&&(d.type==="block-seq"?i(A,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in d&&d.indent!==n.indent&&i(A,"BAD_INDENT",C$)),!m.anchor&&!m.tag&&!f){c=m.end,m.comment&&(a.comment?a.comment+=` `))return!0;if(t.end){for(let e of t.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(let e of t.items){for(let r of e.start)if(r.type==="newline")return!0;if(e.sep){for(let r of e.sep)if(r.type==="newline")return!0}if(C_(e.key)||C_(e.value))return!0}return!1;default:return!0}}d9.containsNewline=C_});var I_=h(f9=>{"use strict";var _De=mB();function kDe(t,e,r){if(e?.type==="flow-collection"){let n=e.end[0];n.indent===t&&(n.source==="]"||n.source==="}")&&_De.containsNewline(e)&&r(n,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}f9.flowIndentCheck=kDe});var B_=h(g9=>{"use strict";var h9=ze();function PDe(t,e,r){let{uniqueKeys:n}=t.options;if(n===!1)return!1;let i=typeof n=="function"?n:(s,o)=>s===o||h9.isScalar(s)&&h9.isScalar(o)&&s.value===o.value;return e.some(s=>i(s.key,r))}g9.mapIncludes=PDe});var I9=h(C9=>{"use strict";var m9=Ba(),TDe=ba(),p9=Fg(),ODe=mB(),y9=I_(),LDe=B_(),E9="All mapping items must start at the same column";function MDe({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=s?.nodeClass??TDe.YAMLMap,a=new o(r.schema);r.atRoot&&(r.atRoot=!1);let A=n.offset,c=null;for(let l of n.items){let{start:u,key:d,sep:f,value:g}=l,m=p9.resolveProps(u,{indicator:"explicit-key-ind",next:d??f?.[0],offset:A,onError:i,parentIndent:n.indent,startOnNewline:!0}),E=!m.found;if(E){if(d&&(d.type==="block-seq"?i(A,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in d&&d.indent!==n.indent&&i(A,"BAD_INDENT",E9)),!m.anchor&&!m.tag&&!f){c=m.end,m.comment&&(a.comment?a.comment+=`
`+m.comment:a.comment=m.comment);continue}(m.newlineAfterProp||YSe.containsNewline(d))&&i(d??u[u.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else m.found?.indent!==n.indent&&i(A,"BAD_INDENT",C$);r.atKey=!0;let C=m.end,I=d?t(r,d,m,i):e(r,C,u,null,m,i);r.schema.compat&&E$.flowIndentCheck(n.indent,d,i),r.atKey=!1,JSe.mapIncludes(r,a.items,I)&&i(C,"DUPLICATE_KEY","Map keys must be unique");let N=y$.resolveProps(f??[],{indicator:"map-value-ind",next:g,offset:I.range[2],onError:i,parentIndent:n.indent,startOnNewline:!d||d.type==="block-scalar"});if(A=N.end,N.found){E&&(g?.type==="block-map"&&!N.hasNewline&&i(A,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),r.options.strict&&m.start<N.found.offset-1024&&i(I.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));let w=g?t(r,g,N,i):e(r,A,f,null,N,i);r.schema.compat&&E$.flowIndentCheck(n.indent,g,i),A=w.range[2];let R=new p$.Pair(I,w);r.options.keepSourceTokens&&(R.srcToken=l),a.items.push(R)}else{E&&i(I.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),N.comment&&(I.comment?I.comment+=` `+m.comment:a.comment=m.comment);continue}(m.newlineAfterProp||ODe.containsNewline(d))&&i(d??u[u.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else m.found?.indent!==n.indent&&i(A,"BAD_INDENT",E9);r.atKey=!0;let C=m.end,I=d?t(r,d,m,i):e(r,C,u,null,m,i);r.schema.compat&&y9.flowIndentCheck(n.indent,d,i),r.atKey=!1,LDe.mapIncludes(r,a.items,I)&&i(C,"DUPLICATE_KEY","Map keys must be unique");let b=p9.resolveProps(f??[],{indicator:"map-value-ind",next:g,offset:I.range[2],onError:i,parentIndent:n.indent,startOnNewline:!d||d.type==="block-scalar"});if(A=b.end,b.found){E&&(g?.type==="block-map"&&!b.hasNewline&&i(A,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),r.options.strict&&m.start<b.found.offset-1024&&i(I.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));let w=g?t(r,g,b,i):e(r,A,f,null,b,i);r.schema.compat&&y9.flowIndentCheck(n.indent,g,i),A=w.range[2];let v=new m9.Pair(I,w);r.options.keepSourceTokens&&(v.srcToken=l),a.items.push(v)}else{E&&i(I.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),b.comment&&(I.comment?I.comment+=`
`+N.comment:I.comment=N.comment);let w=new p$.Pair(I);r.options.keepSourceTokens&&(w.srcToken=l),a.items.push(w)}}return c&&c<A&&i(c,"IMPOSSIBLE","Map comment with trailing content"),a.range=[n.offset,A,c??A],a}I$.resolveBlockMap=VSe});var b$=h(Q$=>{"use strict";var WSe=fa(),$Se=bg(),KSe=jD();function XSe({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=s?.nodeClass??WSe.YAMLSeq,a=new o(r.schema);r.atRoot&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let A=n.offset,c=null;for(let{start:l,value:u}of n.items){let d=$Se.resolveProps(l,{indicator:"seq-item-ind",next:u,offset:A,onError:i,parentIndent:n.indent,startOnNewline:!0});if(!d.found)if(d.anchor||d.tag||u)u&&u.type==="block-seq"?i(d.end,"BAD_INDENT","All sequence items must start at the same column"):i(A,"MISSING_CHAR","Sequence item without - indicator");else{c=d.end,d.comment&&(a.comment=d.comment);continue}let f=u?t(r,u,d,i):e(r,d.end,l,null,d,i);r.schema.compat&&KSe.flowIndentCheck(n.indent,u,i),A=f.range[2],a.items.push(f)}return a.range=[n.offset,A,c??A],a}Q$.resolveBlockSeq=XSe});var ed=h(N$=>{"use strict";function ZSe(t,e,r,n){let i="";if(t){let s=!1,o="";for(let a of t){let{source:A,type:c}=a;switch(c){case"space":s=!0;break;case"comment":{r&&!s&&n(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let l=A.substring(1)||" ";i?i+=o+l:i=l,o="";break}case"newline":i&&(o+=A),s=!0;break;default:n(a,"UNEXPECTED_TOKEN",`Unexpected ${c} at node end`)}e+=A.length}}return{comment:i,offset:e}}N$.resolveEnd=ZSe});var v$=h(S$=>{"use strict";var eve=qe(),tve=la(),w$=da(),rve=fa(),nve=ed(),x$=bg(),ive=$I(),sve=GD(),YD="Block collections are not allowed within flow collections",JD=t=>t&&(t.type==="block-map"||t.type==="block-seq");function ove({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=n.start.source==="{",a=o?"flow map":"flow sequence",A=s?.nodeClass??(o?w$.YAMLMap:rve.YAMLSeq),c=new A(r.schema);c.flow=!0;let l=r.atRoot;l&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let u=n.offset+n.start.source.length;for(let E=0;E<n.items.length;++E){let C=n.items[E],{start:I,key:N,sep:w,value:R}=C,T=x$.resolveProps(I,{flow:a,indicator:"explicit-key-ind",next:N??w?.[0],offset:u,onError:i,parentIndent:n.indent,startOnNewline:!1});if(!T.found){if(!T.anchor&&!T.tag&&!w&&!R){E===0&&T.comma?i(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${a}`):E<n.items.length-1&&i(T.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${a}`),T.comment&&(c.comment?c.comment+=` `+b.comment:I.comment=b.comment);let w=new m9.Pair(I);r.options.keepSourceTokens&&(w.srcToken=l),a.items.push(w)}}return c&&c<A&&i(c,"IMPOSSIBLE","Map comment with trailing content"),a.range=[n.offset,A,c??A],a}C9.resolveBlockMap=MDe});var Q9=h(B9=>{"use strict";var FDe=Na(),UDe=Fg(),qDe=I_();function HDe({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=s?.nodeClass??FDe.YAMLSeq,a=new o(r.schema);r.atRoot&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let A=n.offset,c=null;for(let{start:l,value:u}of n.items){let d=UDe.resolveProps(l,{indicator:"seq-item-ind",next:u,offset:A,onError:i,parentIndent:n.indent,startOnNewline:!0});if(!d.found)if(d.anchor||d.tag||u)u&&u.type==="block-seq"?i(d.end,"BAD_INDENT","All sequence items must start at the same column"):i(A,"MISSING_CHAR","Sequence item without - indicator");else{c=d.end,d.comment&&(a.comment=d.comment);continue}let f=u?t(r,u,d,i):e(r,d.end,l,null,d,i);r.schema.compat&&qDe.flowIndentCheck(n.indent,u,i),A=f.range[2],a.items.push(f)}return a.range=[n.offset,A,c??A],a}B9.resolveBlockSeq=HDe});var fd=h(b9=>{"use strict";function jDe(t,e,r,n){let i="";if(t){let s=!1,o="";for(let a of t){let{source:A,type:c}=a;switch(c){case"space":s=!0;break;case"comment":{r&&!s&&n(a,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");let l=A.substring(1)||" ";i?i+=o+l:i=l,o="";break}case"newline":i&&(o+=A),s=!0;break;default:n(a,"UNEXPECTED_TOKEN",`Unexpected ${c} at node end`)}e+=A.length}}return{comment:i,offset:e}}b9.resolveEnd=jDe});var S9=h(x9=>{"use strict";var zDe=ze(),GDe=Ba(),N9=ba(),YDe=Na(),JDe=fd(),w9=Fg(),VDe=mB(),WDe=B_(),Q_="Block collections are not allowed within flow collections",b_=t=>t&&(t.type==="block-map"||t.type==="block-seq");function $De({composeNode:t,composeEmptyNode:e},r,n,i,s){let o=n.start.source==="{",a=o?"flow map":"flow sequence",A=s?.nodeClass??(o?N9.YAMLMap:YDe.YAMLSeq),c=new A(r.schema);c.flow=!0;let l=r.atRoot;l&&(r.atRoot=!1),r.atKey&&(r.atKey=!1);let u=n.offset+n.start.source.length;for(let E=0;E<n.items.length;++E){let C=n.items[E],{start:I,key:b,sep:w,value:v}=C,T=w9.resolveProps(I,{flow:a,indicator:"explicit-key-ind",next:b??w?.[0],offset:u,onError:i,parentIndent:n.indent,startOnNewline:!1});if(!T.found){if(!T.anchor&&!T.tag&&!w&&!v){E===0&&T.comma?i(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${a}`):E<n.items.length-1&&i(T.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${a}`),T.comment&&(c.comment?c.comment+=`
`+T.comment:c.comment=T.comment),u=T.end;continue}!o&&r.options.strict&&ive.containsNewline(N)&&i(N,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(E===0)T.comma&&i(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${a}`);else if(T.comma||i(T.start,"MISSING_CHAR",`Missing , between ${a} items`),T.comment){let U="";e:for(let k of I)switch(k.type){case"comma":case"space":break;case"comment":U=k.source.substring(1);break e;default:break e}if(U){let k=c.items[c.items.length-1];eve.isPair(k)&&(k=k.value??k.key),k.comment?k.comment+=` `+T.comment:c.comment=T.comment),u=T.end;continue}!o&&r.options.strict&&VDe.containsNewline(b)&&i(b,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(E===0)T.comma&&i(T.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${a}`);else if(T.comma||i(T.start,"MISSING_CHAR",`Missing , between ${a} items`),T.comment){let U="";e:for(let k of I)switch(k.type){case"comma":case"space":break;case"comment":U=k.source.substring(1);break e;default:break e}if(U){let k=c.items[c.items.length-1];zDe.isPair(k)&&(k=k.value??k.key),k.comment?k.comment+=`
`+U:k.comment=U,T.comment=T.comment.substring(U.length+1)}}if(!o&&!w&&!T.found){let U=R?t(r,R,T,i):e(r,T.end,w,null,T,i);c.items.push(U),u=U.range[2],JD(R)&&i(U.range,"BLOCK_IN_FLOW",YD)}else{r.atKey=!0;let U=T.end,k=N?t(r,N,T,i):e(r,U,I,null,T,i);JD(N)&&i(k.range,"BLOCK_IN_FLOW",YD),r.atKey=!1;let J=x$.resolveProps(w??[],{flow:a,indicator:"map-value-ind",next:R,offset:k.range[2],onError:i,parentIndent:n.indent,startOnNewline:!1});if(J.found){if(!o&&!T.found&&r.options.strict){if(w)for(let H of w){if(H===J.found)break;if(H.type==="newline"){i(H,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}T.start<J.found.offset-1024&&i(J.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else R&&("source"in R&&R.source&&R.source[0]===":"?i(R,"MISSING_CHAR",`Missing space after : in ${a}`):i(J.start,"MISSING_CHAR",`Missing , or : between ${a} items`));let Qe=R?t(r,R,J,i):J.found?e(r,J.end,w,null,J,i):null;Qe?JD(R)&&i(Qe.range,"BLOCK_IN_FLOW",YD):J.comment&&(k.comment?k.comment+=` `+U:k.comment=U,T.comment=T.comment.substring(U.length+1)}}if(!o&&!w&&!T.found){let U=v?t(r,v,T,i):e(r,T.end,w,null,T,i);c.items.push(U),u=U.range[2],b_(v)&&i(U.range,"BLOCK_IN_FLOW",Q_)}else{r.atKey=!0;let U=T.end,k=b?t(r,b,T,i):e(r,U,I,null,T,i);b_(b)&&i(k.range,"BLOCK_IN_FLOW",Q_),r.atKey=!1;let J=w9.resolveProps(w??[],{flow:a,indicator:"map-value-ind",next:v,offset:k.range[2],onError:i,parentIndent:n.indent,startOnNewline:!1});if(J.found){if(!o&&!T.found&&r.options.strict){if(w)for(let H of w){if(H===J.found)break;if(H.type==="newline"){i(H,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}T.start<J.found.offset-1024&&i(J.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else v&&("source"in v&&v.source&&v.source[0]===":"?i(v,"MISSING_CHAR",`Missing space after : in ${a}`):i(J.start,"MISSING_CHAR",`Missing , or : between ${a} items`));let we=v?t(r,v,J,i):J.found?e(r,J.end,w,null,J,i):null;we?b_(v)&&i(we.range,"BLOCK_IN_FLOW",Q_):J.comment&&(k.comment?k.comment+=`
`+J.comment:k.comment=J.comment);let Se=new tve.Pair(k,Qe);if(r.options.keepSourceTokens&&(Se.srcToken=C),o){let H=c;sve.mapIncludes(r,H.items,k)&&i(U,"DUPLICATE_KEY","Map keys must be unique"),H.items.push(Se)}else{let H=new w$.YAMLMap(r.schema);H.flow=!0,H.items.push(Se);let Re=(Qe??k).range;H.range=[k.range[0],Re[1],Re[2]],c.items.push(H)}u=Qe?Qe.range[2]:J.end}}let d=o?"}":"]",[f,...g]=n.end,m=u;if(f&&f.source===d)m=f.offset+f.source.length;else{let E=a[0].toUpperCase()+a.substring(1),C=l?`${E} must end with a ${d}`:`${E} in block collection must be sufficiently indented and end with a ${d}`;i(u,l?"MISSING_CHAR":"BAD_INDENT",C),f&&f.source.length!==1&&g.unshift(f)}if(g.length>0){let E=nve.resolveEnd(g,m,r.options.strict,i);E.comment&&(c.comment?c.comment+=` `+J.comment:k.comment=J.comment);let De=new GDe.Pair(k,we);if(r.options.keepSourceTokens&&(De.srcToken=C),o){let H=c;WDe.mapIncludes(r,H.items,k)&&i(U,"DUPLICATE_KEY","Map keys must be unique"),H.items.push(De)}else{let H=new N9.YAMLMap(r.schema);H.flow=!0,H.items.push(De);let ke=(we??k).range;H.range=[k.range[0],ke[1],ke[2]],c.items.push(H)}u=we?we.range[2]:J.end}}let d=o?"}":"]",[f,...g]=n.end,m=u;if(f&&f.source===d)m=f.offset+f.source.length;else{let E=a[0].toUpperCase()+a.substring(1),C=l?`${E} must end with a ${d}`:`${E} in block collection must be sufficiently indented and end with a ${d}`;i(u,l?"MISSING_CHAR":"BAD_INDENT",C),f&&f.source.length!==1&&g.unshift(f)}if(g.length>0){let E=JDe.resolveEnd(g,m,r.options.strict,i);E.comment&&(c.comment?c.comment+=`
`+E.comment:c.comment=E.comment),c.range=[n.offset,m,E.offset]}else c.range=[n.offset,m,m];return c}S$.resolveFlowCollection=ove});var D$=h(R$=>{"use strict";var ave=qe(),Ave=er(),cve=da(),lve=fa(),uve=B$(),dve=b$(),fve=v$();function VD(t,e,r,n,i,s){let o=r.type==="block-map"?uve.resolveBlockMap(t,e,r,n,s):r.type==="block-seq"?dve.resolveBlockSeq(t,e,r,n,s):fve.resolveFlowCollection(t,e,r,n,s),a=o.constructor;return i==="!"||i===a.tagName?(o.tag=a.tagName,o):(i&&(o.tag=i),o)}function hve(t,e,r,n,i){let s=n.tag,o=s?e.directives.tagName(s.source,d=>i(s,"TAG_RESOLVE_FAILED",d)):null;if(r.type==="block-seq"){let{anchor:d,newlineAfterProp:f}=n,g=d&&s?d.offset>s.offset?d:s:d??s;g&&(!f||f.offset<g.offset)&&i(g,"MISSING_CHAR","Missing newline after block sequence props")}let a=r.type==="block-map"?"map":r.type==="block-seq"?"seq":r.start.source==="{"?"map":"seq";if(!s||!o||o==="!"||o===cve.YAMLMap.tagName&&a==="map"||o===lve.YAMLSeq.tagName&&a==="seq")return VD(t,e,r,i,o);let A=e.schema.tags.find(d=>d.tag===o&&d.collection===a);if(!A){let d=e.schema.knownTags[o];if(d&&d.collection===a)e.schema.tags.push(Object.assign({},d,{default:!1})),A=d;else return d?.collection?i(s,"BAD_COLLECTION_TYPE",`${d.tag} used for ${a} collection, but expects ${d.collection}`,!0):i(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${o}`,!0),VD(t,e,r,i,o)}let c=VD(t,e,r,i,o,A),l=A.resolve?.(c,d=>i(s,"TAG_RESOLVE_FAILED",d),e.options)??c,u=ave.isNode(l)?l:new Ave.Scalar(l);return u.range=c.range,u.tag=o,A?.format&&(u.format=A.format),u}R$.composeCollection=hve});var $D=h(_$=>{"use strict";var WD=er();function gve(t,e,r){let n=e.offset,i=mve(e,t.options.strict,r);if(!i)return{value:"",type:null,comment:"",range:[n,n,n]};let s=i.mode===">"?WD.Scalar.BLOCK_FOLDED:WD.Scalar.BLOCK_LITERAL,o=e.source?pve(e.source):[],a=o.length;for(let m=o.length-1;m>=0;--m){let E=o[m][1];if(E===""||E==="\r")a=m;else break}if(a===0){let m=i.chomp==="+"&&o.length>0?` `+E.comment:c.comment=E.comment),c.range=[n.offset,m,E.offset]}else c.range=[n.offset,m,m];return c}x9.resolveFlowCollection=$De});var v9=h(R9=>{"use strict";var KDe=ze(),XDe=ir(),ZDe=ba(),e_e=Na(),t_e=I9(),r_e=Q9(),n_e=S9();function N_(t,e,r,n,i,s){let o=r.type==="block-map"?t_e.resolveBlockMap(t,e,r,n,s):r.type==="block-seq"?r_e.resolveBlockSeq(t,e,r,n,s):n_e.resolveFlowCollection(t,e,r,n,s),a=o.constructor;return i==="!"||i===a.tagName?(o.tag=a.tagName,o):(i&&(o.tag=i),o)}function i_e(t,e,r,n,i){let s=n.tag,o=s?e.directives.tagName(s.source,d=>i(s,"TAG_RESOLVE_FAILED",d)):null;if(r.type==="block-seq"){let{anchor:d,newlineAfterProp:f}=n,g=d&&s?d.offset>s.offset?d:s:d??s;g&&(!f||f.offset<g.offset)&&i(g,"MISSING_CHAR","Missing newline after block sequence props")}let a=r.type==="block-map"?"map":r.type==="block-seq"?"seq":r.start.source==="{"?"map":"seq";if(!s||!o||o==="!"||o===ZDe.YAMLMap.tagName&&a==="map"||o===e_e.YAMLSeq.tagName&&a==="seq")return N_(t,e,r,i,o);let A=e.schema.tags.find(d=>d.tag===o&&d.collection===a);if(!A){let d=e.schema.knownTags[o];if(d&&d.collection===a)e.schema.tags.push(Object.assign({},d,{default:!1})),A=d;else return d?.collection?i(s,"BAD_COLLECTION_TYPE",`${d.tag} used for ${a} collection, but expects ${d.collection}`,!0):i(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${o}`,!0),N_(t,e,r,i,o)}let c=N_(t,e,r,i,o,A),l=A.resolve?.(c,d=>i(s,"TAG_RESOLVE_FAILED",d),e.options)??c,u=KDe.isNode(l)?l:new XDe.Scalar(l);return u.range=c.range,u.tag=o,A?.format&&(u.format=A.format),u}R9.composeCollection=i_e});var x_=h(D9=>{"use strict";var w_=ir();function s_e(t,e,r){let n=e.offset,i=o_e(e,t.options.strict,r);if(!i)return{value:"",type:null,comment:"",range:[n,n,n]};let s=i.mode===">"?w_.Scalar.BLOCK_FOLDED:w_.Scalar.BLOCK_LITERAL,o=e.source?a_e(e.source):[],a=o.length;for(let m=o.length-1;m>=0;--m){let E=o[m][1];if(E===""||E==="\r")a=m;else break}if(a===0){let m=i.chomp==="+"&&o.length>0?`
`.repeat(Math.max(1,o.length-1)):"",E=n+i.length;return e.source&&(E+=e.source.length),{value:m,type:s,comment:i.comment,range:[n,E,E]}}let A=e.indent+i.indent,c=e.offset+i.length,l=0;for(let m=0;m<a;++m){let[E,C]=o[m];if(C===""||C==="\r")i.indent===0&&E.length>A&&(A=E.length);else{E.length<A&&r(c+E.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),i.indent===0&&(A=E.length),l=m,A===0&&!t.atRoot&&r(c,"BAD_INDENT","Block scalar values in collections must be indented");break}c+=E.length+C.length+1}for(let m=o.length-1;m>=a;--m)o[m][0].length>A&&(a=m+1);let u="",d="",f=!1;for(let m=0;m<l;++m)u+=o[m][0].slice(A)+` `.repeat(Math.max(1,o.length-1)):"",E=n+i.length;return e.source&&(E+=e.source.length),{value:m,type:s,comment:i.comment,range:[n,E,E]}}let A=e.indent+i.indent,c=e.offset+i.length,l=0;for(let m=0;m<a;++m){let[E,C]=o[m];if(C===""||C==="\r")i.indent===0&&E.length>A&&(A=E.length);else{E.length<A&&r(c+E.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),i.indent===0&&(A=E.length),l=m,A===0&&!t.atRoot&&r(c,"BAD_INDENT","Block scalar values in collections must be indented");break}c+=E.length+C.length+1}for(let m=o.length-1;m>=a;--m)o[m][0].length>A&&(a=m+1);let u="",d="",f=!1;for(let m=0;m<l;++m)u+=o[m][0].slice(A)+`
`;for(let m=l;m<a;++m){let[E,C]=o[m];c+=E.length+C.length+1;let I=C[C.length-1]==="\r";if(I&&(C=C.slice(0,-1)),C&&E.length<A){let w=`Block scalar lines must not be less indented than their ${i.indent?"explicit indentation indicator":"first line"}`;r(c-C.length-(I?2:1),"BAD_INDENT",w),E=""}s===WD.Scalar.BLOCK_LITERAL?(u+=d+E.slice(A)+C,d=` `;for(let m=l;m<a;++m){let[E,C]=o[m];c+=E.length+C.length+1;let I=C[C.length-1]==="\r";if(I&&(C=C.slice(0,-1)),C&&E.length<A){let w=`Block scalar lines must not be less indented than their ${i.indent?"explicit indentation indicator":"first line"}`;r(c-C.length-(I?2:1),"BAD_INDENT",w),E=""}s===w_.Scalar.BLOCK_LITERAL?(u+=d+E.slice(A)+C,d=`
`):E.length>A||C[0]===" "?(d===" "?d=` `):E.length>A||C[0]===" "?(d===" "?d=`
`:!f&&d===` `:!f&&d===`
`&&(d=` `&&(d=`
@@ -205,72 +205,72 @@ ${c}
`+o[m][0].slice(A);u[u.length-1]!==` `+o[m][0].slice(A);u[u.length-1]!==`
`&&(u+=` `&&(u+=`
`);break;default:u+=` `);break;default:u+=`
`}let g=n+i.length+e.source.length;return{value:u,type:s,comment:i.comment,range:[n,g,g]}}function mve({offset:t,props:e},r,n){if(e[0].type!=="block-scalar-header")return n(e[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:i}=e[0],s=i[0],o=0,a="",A=-1;for(let d=1;d<i.length;++d){let f=i[d];if(!a&&(f==="-"||f==="+"))a=f;else{let g=Number(f);!o&&g?o=g:A===-1&&(A=t+d)}}A!==-1&&n(A,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${i}`);let c=!1,l="",u=i.length;for(let d=1;d<e.length;++d){let f=e[d];switch(f.type){case"space":c=!0;case"newline":u+=f.source.length;break;case"comment":r&&!c&&n(f,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),u+=f.source.length,l=f.source.substring(1);break;case"error":n(f,"UNEXPECTED_TOKEN",f.message),u+=f.source.length;break;default:{let g=`Unexpected token in block scalar header: ${f.type}`;n(f,"UNEXPECTED_TOKEN",g);let m=f.source;m&&typeof m=="string"&&(u+=m.length)}}}return{mode:s,indent:o,chomp:a,comment:l,length:u}}function pve(t){let e=t.split(/\n( *)/),r=e[0],n=r.match(/^( *)/),s=[n?.[1]?[n[1],r.slice(n[1].length)]:["",r]];for(let o=1;o<e.length;o+=2)s.push([e[o],e[o+1]]);return s}_$.resolveBlockScalar=gve});var XD=h(P$=>{"use strict";var KD=er(),yve=ed();function Eve(t,e,r){let{offset:n,type:i,source:s,end:o}=t,a,A,c=(d,f,g)=>r(n+d,f,g);switch(i){case"scalar":a=KD.Scalar.PLAIN,A=Cve(s,c);break;case"single-quoted-scalar":a=KD.Scalar.QUOTE_SINGLE,A=Ive(s,c);break;case"double-quoted-scalar":a=KD.Scalar.QUOTE_DOUBLE,A=Bve(s,c);break;default:return r(t,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${i}`),{value:"",type:null,comment:"",range:[n,n+s.length,n+s.length]}}let l=n+s.length,u=yve.resolveEnd(o,l,e,r);return{value:A,type:a,comment:u.comment,range:[n,l,u.offset]}}function Cve(t,e){let r="";switch(t[0]){case" ":r="a tab character";break;case",":r="flow indicator character ,";break;case"%":r="directive indicator character %";break;case"|":case">":{r=`block scalar indicator ${t[0]}`;break}case"@":case"`":{r=`reserved character ${t[0]}`;break}}return r&&e(0,"BAD_SCALAR_START",`Plain value cannot start with ${r}`),k$(t)}function Ive(t,e){return(t[t.length-1]!=="'"||t.length===1)&&e(t.length,"MISSING_CHAR","Missing closing 'quote"),k$(t.slice(1,-1)).replace(/''/g,"'")}function k$(t){let e,r;try{e=new RegExp(`(.*?)(?<![ ])[ ]*\r? `}let g=n+i.length+e.source.length;return{value:u,type:s,comment:i.comment,range:[n,g,g]}}function o_e({offset:t,props:e},r,n){if(e[0].type!=="block-scalar-header")return n(e[0],"IMPOSSIBLE","Block scalar header not found"),null;let{source:i}=e[0],s=i[0],o=0,a="",A=-1;for(let d=1;d<i.length;++d){let f=i[d];if(!a&&(f==="-"||f==="+"))a=f;else{let g=Number(f);!o&&g?o=g:A===-1&&(A=t+d)}}A!==-1&&n(A,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${i}`);let c=!1,l="",u=i.length;for(let d=1;d<e.length;++d){let f=e[d];switch(f.type){case"space":c=!0;case"newline":u+=f.source.length;break;case"comment":r&&!c&&n(f,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),u+=f.source.length,l=f.source.substring(1);break;case"error":n(f,"UNEXPECTED_TOKEN",f.message),u+=f.source.length;break;default:{let g=`Unexpected token in block scalar header: ${f.type}`;n(f,"UNEXPECTED_TOKEN",g);let m=f.source;m&&typeof m=="string"&&(u+=m.length)}}}return{mode:s,indent:o,chomp:a,comment:l,length:u}}function a_e(t){let e=t.split(/\n( *)/),r=e[0],n=r.match(/^( *)/),s=[n?.[1]?[n[1],r.slice(n[1].length)]:["",r]];for(let o=1;o<e.length;o+=2)s.push([e[o],e[o+1]]);return s}D9.resolveBlockScalar=s_e});var R_=h(k9=>{"use strict";var S_=ir(),A_e=fd();function c_e(t,e,r){let{offset:n,type:i,source:s,end:o}=t,a,A,c=(d,f,g)=>r(n+d,f,g);switch(i){case"scalar":a=S_.Scalar.PLAIN,A=l_e(s,c);break;case"single-quoted-scalar":a=S_.Scalar.QUOTE_SINGLE,A=u_e(s,c);break;case"double-quoted-scalar":a=S_.Scalar.QUOTE_DOUBLE,A=d_e(s,c);break;default:return r(t,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${i}`),{value:"",type:null,comment:"",range:[n,n+s.length,n+s.length]}}let l=n+s.length,u=A_e.resolveEnd(o,l,e,r);return{value:A,type:a,comment:u.comment,range:[n,l,u.offset]}}function l_e(t,e){let r="";switch(t[0]){case" ":r="a tab character";break;case",":r="flow indicator character ,";break;case"%":r="directive indicator character %";break;case"|":case">":{r=`block scalar indicator ${t[0]}`;break}case"@":case"`":{r=`reserved character ${t[0]}`;break}}return r&&e(0,"BAD_SCALAR_START",`Plain value cannot start with ${r}`),_9(t)}function u_e(t,e){return(t[t.length-1]!=="'"||t.length===1)&&e(t.length,"MISSING_CHAR","Missing closing 'quote"),_9(t.slice(1,-1)).replace(/''/g,"'")}function _9(t){let e,r;try{e=new RegExp(`(.*?)(?<![ ])[ ]*\r?
`,"sy"),r=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r? `,"sy"),r=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
`,"sy")}catch{e=/(.*?)[ \t]*\r?\n/sy,r=/[ \t]*(.*?)[ \t]*\r?\n/sy}let n=e.exec(t);if(!n)return t;let i=n[1],s=" ",o=e.lastIndex;for(r.lastIndex=o;n=r.exec(t);)n[1]===""?s===` `,"sy")}catch{e=/(.*?)[ \t]*\r?\n/sy,r=/[ \t]*(.*?)[ \t]*\r?\n/sy}let n=e.exec(t);if(!n)return t;let i=n[1],s=" ",o=e.lastIndex;for(r.lastIndex=o;n=r.exec(t);)n[1]===""?s===`
`?i+=s:s=` `?i+=s:s=`
`:(i+=s+n[1],s=" "),o=r.lastIndex;let a=/[ \t]*(.*)/sy;return a.lastIndex=o,n=a.exec(t),i+s+(n?.[1]??"")}function Bve(t,e){let r="";for(let n=1;n<t.length-1;++n){let i=t[n];if(!(i==="\r"&&t[n+1]===` `:(i+=s+n[1],s=" "),o=r.lastIndex;let a=/[ \t]*(.*)/sy;return a.lastIndex=o,n=a.exec(t),i+s+(n?.[1]??"")}function d_e(t,e){let r="";for(let n=1;n<t.length-1;++n){let i=t[n];if(!(i==="\r"&&t[n+1]===`
`))if(i===` `))if(i===`
`){let{fold:s,offset:o}=Qve(t,n);r+=s,n=o}else if(i==="\\"){let s=t[++n],o=bve[s];if(o)r+=o;else if(s===` `){let{fold:s,offset:o}=f_e(t,n);r+=s,n=o}else if(i==="\\"){let s=t[++n],o=h_e[s];if(o)r+=o;else if(s===`
`)for(s=t[n+1];s===" "||s===" ";)s=t[++n+1];else if(s==="\r"&&t[n+1]===` `)for(s=t[n+1];s===" "||s===" ";)s=t[++n+1];else if(s==="\r"&&t[n+1]===`
`)for(s=t[++n+1];s===" "||s===" ";)s=t[++n+1];else if(s==="x"||s==="u"||s==="U"){let a={x:2,u:4,U:8}[s];r+=Nve(t,n+1,a,e),n+=a}else{let a=t.substr(n-1,2);e(n-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),r+=a}}else if(i===" "||i===" "){let s=n,o=t[n+1];for(;o===" "||o===" ";)o=t[++n+1];o!==` `)for(s=t[++n+1];s===" "||s===" ";)s=t[++n+1];else if(s==="x"||s==="u"||s==="U"){let a={x:2,u:4,U:8}[s];r+=g_e(t,n+1,a,e),n+=a}else{let a=t.substr(n-1,2);e(n-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),r+=a}}else if(i===" "||i===" "){let s=n,o=t[n+1];for(;o===" "||o===" ";)o=t[++n+1];o!==`
`&&!(o==="\r"&&t[n+2]===` `&&!(o==="\r"&&t[n+2]===`
`)&&(r+=n>s?t.slice(s,n+1):i)}else r+=i}return(t[t.length-1]!=='"'||t.length===1)&&e(t.length,"MISSING_CHAR",'Missing closing "quote'),r}function Qve(t,e){let r="",n=t[e+1];for(;(n===" "||n===" "||n===` `)&&(r+=n>s?t.slice(s,n+1):i)}else r+=i}return(t[t.length-1]!=='"'||t.length===1)&&e(t.length,"MISSING_CHAR",'Missing closing "quote'),r}function f_e(t,e){let r="",n=t[e+1];for(;(n===" "||n===" "||n===`
`||n==="\r")&&!(n==="\r"&&t[e+2]!==` `||n==="\r")&&!(n==="\r"&&t[e+2]!==`
`);)n===` `);)n===`
`&&(r+=` `&&(r+=`
`),e+=1,n=t[e+1];return r||(r=" "),{fold:r,offset:e}}var bve={0:"\0",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:` `),e+=1,n=t[e+1];return r||(r=" "),{fold:r,offset:e}}var h_e={0:"\0",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
`,r:"\r",t:" ",v:"\v",N:"\x85",_:"\xA0",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function Nve(t,e,r,n){let i=t.substr(e,r),o=i.length===r&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;if(isNaN(o)){let a=t.substr(e-2,r+2);return n(e-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),a}return String.fromCodePoint(o)}P$.resolveFlowScalar=Eve});var M$=h(O$=>{"use strict";var QA=qe(),T$=er(),wve=$D(),xve=XD();function Sve(t,e,r,n){let{value:i,type:s,comment:o,range:a}=e.type==="block-scalar"?wve.resolveBlockScalar(t,e,n):xve.resolveFlowScalar(e,t.options.strict,n),A=r?t.directives.tagName(r.source,u=>n(r,"TAG_RESOLVE_FAILED",u)):null,c;t.options.stringKeys&&t.atKey?c=t.schema[QA.SCALAR]:A?c=vve(t.schema,i,A,r,n):e.type==="scalar"?c=Rve(t,i,e,n):c=t.schema[QA.SCALAR];let l;try{let u=c.resolve(i,d=>n(r??e,"TAG_RESOLVE_FAILED",d),t.options);l=QA.isScalar(u)?u:new T$.Scalar(u)}catch(u){let d=u instanceof Error?u.message:String(u);n(r??e,"TAG_RESOLVE_FAILED",d),l=new T$.Scalar(i)}return l.range=a,l.source=i,s&&(l.type=s),A&&(l.tag=A),c.format&&(l.format=c.format),o&&(l.comment=o),l}function vve(t,e,r,n,i){if(r==="!")return t[QA.SCALAR];let s=[];for(let a of t.tags)if(!a.collection&&a.tag===r)if(a.default&&a.test)s.push(a);else return a;for(let a of s)if(a.test?.test(e))return a;let o=t.knownTags[r];return o&&!o.collection?(t.tags.push(Object.assign({},o,{default:!1,test:void 0})),o):(i(n,"TAG_RESOLVE_FAILED",`Unresolved tag: ${r}`,r!=="tag:yaml.org,2002:str"),t[QA.SCALAR])}function Rve({atKey:t,directives:e,schema:r},n,i,s){let o=r.tags.find(a=>(a.default===!0||t&&a.default==="key")&&a.test?.test(n))||r[QA.SCALAR];if(r.compat){let a=r.compat.find(A=>A.default&&A.test?.test(n))??r[QA.SCALAR];if(o.tag!==a.tag){let A=e.tagString(o.tag),c=e.tagString(a.tag),l=`Value may be parsed as either ${A} or ${c}`;s(i,"TAG_RESOLVE_FAILED",l,!0)}}return o}O$.composeScalar=Sve});var F$=h(L$=>{"use strict";function Dve(t,e,r){if(e){r===null&&(r=e.length);for(let n=r-1;n>=0;--n){let i=e[n];switch(i.type){case"space":case"comment":case"newline":t-=i.source.length;continue}for(i=e[++n];i?.type==="space";)t+=i.source.length,i=e[++n];break}}return t}L$.emptyScalarPosition=Dve});var H$=h(e_=>{"use strict";var _ve=ng(),kve=qe(),Pve=D$(),U$=M$(),Tve=ed(),Ove=F$(),Mve={composeNode:q$,composeEmptyNode:ZD};function q$(t,e,r,n){let i=t.atKey,{spaceBefore:s,comment:o,anchor:a,tag:A}=r,c,l=!0;switch(e.type){case"alias":c=Lve(t,e,n),(a||A)&&n(e,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":c=U$.composeScalar(t,e,A,n),a&&(c.anchor=a.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":c=Pve.composeCollection(Mve,t,e,r,n),a&&(c.anchor=a.source.substring(1));break;default:{let u=e.type==="error"?e.message:`Unsupported token (type: ${e.type})`;n(e,"UNEXPECTED_TOKEN",u),c=ZD(t,e.offset,void 0,null,r,n),l=!1}}return a&&c.anchor===""&&n(a,"BAD_ALIAS","Anchor cannot be an empty string"),i&&t.options.stringKeys&&(!kve.isScalar(c)||typeof c.value!="string"||c.tag&&c.tag!=="tag:yaml.org,2002:str")&&n(A??e,"NON_STRING_KEY","With stringKeys, all keys must be strings"),s&&(c.spaceBefore=!0),o&&(e.type==="scalar"&&e.source===""?c.comment=o:c.commentBefore=o),t.options.keepSourceTokens&&l&&(c.srcToken=e),c}function ZD(t,e,r,n,{spaceBefore:i,comment:s,anchor:o,tag:a,end:A},c){let l={type:"scalar",offset:Ove.emptyScalarPosition(e,r,n),indent:-1,source:""},u=U$.composeScalar(t,l,a,c);return o&&(u.anchor=o.source.substring(1),u.anchor===""&&c(o,"BAD_ALIAS","Anchor cannot be an empty string")),i&&(u.spaceBefore=!0),s&&(u.comment=s,u.range[2]=A),u}function Lve({options:t},{offset:e,source:r,end:n},i){let s=new _ve.Alias(r.substring(1));s.source===""&&i(e,"BAD_ALIAS","Alias cannot be an empty string"),s.source.endsWith(":")&&i(e+r.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let o=e+r.length,a=Tve.resolveEnd(n,o,t.strict,i);return s.range=[e,o,a.offset],a.comment&&(s.comment=a.comment),s}e_.composeEmptyNode=ZD;e_.composeNode=q$});var G$=h(j$=>{"use strict";var Fve=Cg(),z$=H$(),Uve=ed(),qve=bg();function Hve(t,e,{offset:r,start:n,value:i,end:s},o){let a=Object.assign({_directives:e},t),A=new Fve.Document(void 0,a),c={atKey:!1,atRoot:!0,directives:A.directives,options:A.options,schema:A.schema},l=qve.resolveProps(n,{indicator:"doc-start",next:i??s?.[0],offset:r,onError:o,parentIndent:0,startOnNewline:!0});l.found&&(A.directives.docStart=!0,i&&(i.type==="block-map"||i.type==="block-seq")&&!l.hasNewline&&o(l.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),A.contents=i?z$.composeNode(c,i,l,o):z$.composeEmptyNode(c,l.end,n,null,l,o);let u=A.contents.range[2],d=Uve.resolveEnd(s,u,!1,o);return d.comment&&(A.comment=d.comment),A.range=[r,u,d.offset],A}j$.composeDoc=Hve});var r_=h(V$=>{"use strict";var zve=require("node:process"),jve=qR(),Gve=Cg(),Ng=Qg(),Y$=qe(),Yve= Line truncated `,r:"\r",t:" ",v:"\v",N:"\x85",_:"\xA0",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function g_e(t,e,r,n){let i=t.substr(e,r),o=i.length===r&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;if(isNaN(o)){let a=t.substr(e-2,r+2);return n(e-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${a}`),a}return String.fromCodePoint(o)}k9.resolveFlowScalar=c_e});var O9=h(T9=>{"use strict";var OA=ze(),P9=ir(),m_e=x_(),p_e=R_();function y_e(t,e,r,n){let{value:i,type:s,comment:o,range:a}=e.type==="block-scalar"?m_e.resolveBlockScalar(t,e,n):p_e.resolveFlowScalar(e,t.options.strict,n),A=r?t.directives.tagName(r.source,u=>n(r,"TAG_RESOLVE_FAILED",u)):null,c;t.options.stringKeys&&t.atKey?c=t.schema[OA.SCALAR]:A?c=E_e(t.schema,i,A,r,n):e.type==="scalar"?c=C_e(t,i,e,n):c=t.schema[OA.SCALAR];let l;try{let u=c.resolve(i,d=>n(r??e,"TAG_RESOLVE_FAILED",d),t.options);l=OA.isScalar(u)?u:new P9.Scalar(u)}catch(u){let d=u instanceof Error?u.message:String(u);n(r??e,"TAG_RESOLVE_FAILED",d),l=new P9.Scalar(i)}return l.range=a,l.source=i,s&&(l.type=s),A&&(l.tag=A),c.format&&(l.format=c.format),o&&(l.comment=o),l}function E_e(t,e,r,n,i){if(r==="!")return t[OA.SCALAR];let s=[];for(let a of t.tags)if(!a.collection&&a.tag===r)if(a.default&&a.test)s.push(a);else return a;for(let a of s)if(a.test?.test(e))return a;let o=t.knownTags[r];return o&&!o.collection?(t.tags.push(Object.assign({},o,{default:!1,test:void 0})),o):(i(n,"TAG_RESOLVE_FAILED",`Unresolved tag: ${r}`,r!=="tag:yaml.org,2002:str"),t[OA.SCALAR])}function C_e({atKey:t,directives:e,schema:r},n,i,s){let o=r.tags.find(a=>(a.default===!0||t&&a.default==="key")&&a.test?.test(n))||r[OA.SCALAR];if(r.compat){let a=r.compat.find(A=>A.default&&A.test?.test(n))??r[OA.SCALAR];if(o.tag!==a.tag){let A=e.tagString(o.tag),c=e.tagString(a.tag),l=`Value may be parsed as either ${A} or ${c}`;s(i,"TAG_RESOLVE_FAILED",l,!0)}}return o}T9.composeScalar=y_e});var M9=h(L9=>{"use strict";function I_e(t,e,r){if(e){r===null&&(r=e.length);for(let n=r-1;n>=0;--n){let i=e[n];switch(i.type){case"space":case"comment":case"newline":t-=i.source.length;continue}for(i=e[++n];i?.type==="space";)t+=i.source.length,i=e[++n];break}}return t}L9.emptyScalarPosition=I_e});var q9=h(D_=>{"use strict";var B_e=yg(),Q_e=ze(),b_e=v9(),F9=O9(),N_e=fd(),w_e=M9(),x_e={composeNode:U9,composeEmptyNode:v_};function U9(t,e,r,n){let i=t.atKey,{spaceBefore:s,comment:o,anchor:a,tag:A}=r,c,l=!0;switch(e.type){case"alias":c=S_e(t,e,n),(a||A)&&n(e,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":c=F9.composeScalar(t,e,A,n),a&&(c.anchor=a.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":c=b_e.composeCollection(x_e,t,e,r,n),a&&(c.anchor=a.source.substring(1));break;default:{let u=e.type==="error"?e.message:`Unsupported token (type: ${e.type})`;n(e,"UNEXPECTED_TOKEN",u),c=v_(t,e.offset,void 0,null,r,n),l=!1}}return a&&c.anchor===""&&n(a,"BAD_ALIAS","Anchor cannot be an empty string"),i&&t.options.stringKeys&&(!Q_e.isScalar(c)||typeof c.value!="string"||c.tag&&c.tag!=="tag:yaml.org,2002:str")&&n(A??e,"NON_STRING_KEY","With stringKeys, all keys must be strings"),s&&(c.spaceBefore=!0),o&&(e.type==="scalar"&&e.source===""?c.comment=o:c.commentBefore=o),t.options.keepSourceTokens&&l&&(c.srcToken=e),c}function v_(t,e,r,n,{spaceBefore:i,comment:s,anchor:o,tag:a,end:A},c){let l={type:"scalar",offset:w_e.emptyScalarPosition(e,r,n),indent:-1,source:""},u=F9.composeScalar(t,l,a,c);return o&&(u.anchor=o.source.substring(1),u.anchor===""&&c(o,"BAD_ALIAS","Anchor cannot be an empty string")),i&&(u.spaceBefore=!0),s&&(u.comment=s,u.range[2]=A),u}function S_e({options:t},{offset:e,source:r,end:n},i){let s=new B_e.Alias(r.substring(1));s.source===""&&i(e,"BAD_ALIAS","Alias cannot be an empty string"),s.source.endsWith(":")&&i(e+r.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);let o=e+r.length,a=N_e.resolveEnd(n,o,t.strict,i);return s.range=[e,o,a.offset],a.comment&&(s.comment=a.comment),s}D_.composeEmptyNode=v_;D_.composeNode=U9});var z9=h(j9=>{"use strict";var R_e=Tg(),H9=q9(),v_e=fd(),D_e=Fg();function __e(t,e,{offset:r,start:n,value:i,end:s},o){let a=Object.assign({_directives:e},t),A=new R_e.Document(void 0,a),c={atKey:!1,atRoot:!0,directives:A.directives,options:A.options,schema:A.schema},l=D_e.resolveProps(n,{indicator:"doc-start",next:i??s?.[0],offset:r,onError:o,parentIndent:0,startOnNewline:!0});l.found&&(A.directives.docStart=!0,i&&(i.type==="block-map"||i.type==="block-seq")&&!l.hasNewline&&o(l.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),A.contents=i?H9.composeNode(c,i,l,o):H9.composeEmptyNode(c,l.end,n,null,l,o);let u=A.contents.range[2],d=v_e.resolveEnd(s,u,!1,o);return d.comment&&(A.comment=d.comment),A.range=[r,u,d.offset],A}j9.composeDoc=__e});var k_=h(J9=>{"use strict";var k_e=require("node:process"),P_e=yD(),T_e=Tg(),Ug=Mg(),G9=ze(),O_e= Line truncated
`:` `:`
`)+(s.substring(1)||" "),r=!0,n=!1;break;case"%":t[i+1]?.[0]!=="#"&&(i+=1),r=!1;break;default:r||(n=!0),r=!1}}return{comment:e,afterEmptyLine:n}}var t_=class{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(r,n,i,s)=>{let o=wg(r);s?this.warnings.push(new Ng.YAMLWarning(o,n,i)):this.errors.push(new Ng.YAMLParseError(o,n,i))},this.directives=new jve.Directives({version:e.version||"1.2"}),this.options=e}decorate(e,r){let{comment:n,afterEmptyLine:i}=J$(this.prelude);if(n){let s=e.contents;if(r)e.comment=e.comment?`${e.comment} `)+(s.substring(1)||" "),r=!0,n=!1;break;case"%":t[i+1]?.[0]!=="#"&&(i+=1),r=!1;break;default:r||(n=!0),r=!1}}return{comment:e,afterEmptyLine:n}}var __=class{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(r,n,i,s)=>{let o=qg(r);s?this.warnings.push(new Ug.YAMLWarning(o,n,i)):this.errors.push(new Ug.YAMLParseError(o,n,i))},this.directives=new P_e.Directives({version:e.version||"1.2"}),this.options=e}decorate(e,r){let{comment:n,afterEmptyLine:i}=Y9(this.prelude);if(n){let s=e.contents;if(r)e.comment=e.comment?`${e.comment}
${n}`:n;else if(i||e.directives.docStart||!s)e.commentBefore=n;else if(Y$.isCollection(s)&&!s.flow&&s.items.length>0){let o=s.items[0];Y$.isPair(o)&&(o=o.key);let a=o.commentBefore;o.commentBefore=a?`${n} ${n}`:n;else if(i||e.directives.docStart||!s)e.commentBefore=n;else if(G9.isCollection(s)&&!s.flow&&s.items.length>0){let o=s.items[0];G9.isPair(o)&&(o=o.key);let a=o.commentBefore;o.commentBefore=a?`${n}
${a}`:n}else{let o=s.commentBefore;s.commentBefore=o?`${n} ${a}`:n}else{let o=s.commentBefore;s.commentBefore=o?`${n}
${o}`:n}}r?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:J$(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,r=!1,n=-1){for(let i of e)yield*this.next(i);yield*this.end(r,n)}*next(e){switch(zve.env.LOG_STREAM&&console.dir(e,{depth:null}),e.type){case"directive":this.directives.add(e.source,(r,n,i)=>{let s=wg(e);s[0]+=r,this.onError(s,"BAD_DIRECTIVE",n,i)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{let r=Yve.composeDoc(this.options,this.directives,e,this.onError);this.atDirectives&&!r.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(r,!1),this.doc&&(yield this.doc),this.doc=r,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{let r=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new Ng.YAMLParseError(wg(e),"UNEXPECTED_TOKEN",r);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case"doc-end":{if(!this.doc){let n="Unexpected doc-end without preceding document";this.errors.push(new Ng.YAMLParseError(wg(e),"UNEXPECTED_TOKEN",n));break}this.doc.directives.docEnd=!0;let r=Jve.resolveEnd(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),r.comment){let n=this.doc.comment;this.doc.comment=n?`${n} ${o}`:n}}r?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Y9(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,r=!1,n=-1){for(let i of e)yield*this.next(i);yield*this.end(r,n)}*next(e){switch(k_e.env.LOG_STREAM&&console.dir(e,{depth:null}),e.type){case"directive":this.directives.add(e.source,(r,n,i)=>{let s=qg(e);s[0]+=r,this.onError(s,"BAD_DIRECTIVE",n,i)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{let r=O_e.composeDoc(this.options,this.directives,e,this.onError);this.atDirectives&&!r.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(r,!1),this.doc&&(yield this.doc),this.doc=r,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{let r=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new Ug.YAMLParseError(qg(e),"UNEXPECTED_TOKEN",r);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case"doc-end":{if(!this.doc){let n="Unexpected doc-end without preceding document";this.errors.push(new Ug.YAMLParseError(qg(e),"UNEXPECTED_TOKEN",n));break}this.doc.directives.docEnd=!0;let r=L_e.resolveEnd(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),r.comment){let n=this.doc.comment;this.doc.comment=n?`${n}
${r.comment}`:r.comment}this.doc.range[2]=r.offset;break}default:this.errors.push(new Ng.YAMLParseError(wg(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,r=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let n=Object.assign({_directives:this.directives},this.options),i=new Gve.Document(void 0,n);this.atDirectives&&this.onError(r,"MISSING_CHAR","Missing directives-end indicator line"),i.range=[0,r,r],this.decorate(i,!1),yield i}}};V$.Composer=t_});var K$=h(KI=>{"use strict";var Vve=$D(),Wve=XD(),$ve=Qg(),W$=Ag();function Kve(t,e=!0,r){if(t){let n=(i,s,o)=>{let a=typeof i=="number"?i:Array.isArray(i)?i[0]:i.offset;if(r)r(a,s,o);else throw new $ve.YAMLParseError([a,a+1],s,o)};switch(t.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return Wve.resolveFlowScalar(t,e,n);case"block-scalar":return Vve.resolveBlockScalar({options:{strict:e}},t,n)}}return null}function Xve(t,e){let{implicitKey:r=!1,indent:n,inFlow:i=!1,offset:s=-1,type:o="PLAIN"}=e,a=W$.stringifyString({type:o,value:t},{implicitKey:r,indent:n>0?" ".repeat(n):"",inFlow:i,options:{blockQuote:!0,lineWidth:-1}}),A=e.end??[{type:"newline",offset:-1,indent:n,source:` ${r.comment}`:r.comment}this.doc.range[2]=r.offset;break}default:this.errors.push(new Ug.YAMLParseError(qg(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,r=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let n=Object.assign({_directives:this.directives},this.options),i=new T_e.Document(void 0,n);this.atDirectives&&this.onError(r,"MISSING_CHAR","Missing directives-end indicator line"),i.range=[0,r,r],this.decorate(i,!1),yield i}}};J9.Composer=__});var $9=h(pB=>{"use strict";var M_e=x_(),F_e=R_(),U_e=Mg(),V9=Qg();function q_e(t,e=!0,r){if(t){let n=(i,s,o)=>{let a=typeof i=="number"?i:Array.isArray(i)?i[0]:i.offset;if(r)r(a,s,o);else throw new U_e.YAMLParseError([a,a+1],s,o)};switch(t.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return F_e.resolveFlowScalar(t,e,n);case"block-scalar":return M_e.resolveBlockScalar({options:{strict:e}},t,n)}}return null}function H_e(t,e){let{implicitKey:r=!1,indent:n,inFlow:i=!1,offset:s=-1,type:o="PLAIN"}=e,a=V9.stringifyString({type:o,value:t},{implicitKey:r,indent:n>0?" ".repeat(n):"",inFlow:i,options:{blockQuote:!0,lineWidth:-1}}),A=e.end??[{type:"newline",offset:-1,indent:n,source:`
`}];switch(a[0]){case"|":case">":{let c=a.indexOf(` `}];switch(a[0]){case"|":case">":{let c=a.indexOf(`
`),l=a.substring(0,c),u=a.substring(c+1)+` `),l=a.substring(0,c),u=a.substring(c+1)+`
`,d=[{type:"block-scalar-header",offset:s,indent:n,source:l}];return $$(d,A)||d.push({type:"newline",offset:-1,indent:n,source:` `,d=[{type:"block-scalar-header",offset:s,indent:n,source:l}];return W9(d,A)||d.push({type:"newline",offset:-1,indent:n,source:`
`}),{type:"block-scalar",offset:s,indent:n,props:d,source:u}}case'"':return{type:"double-quoted-scalar",offset:s,indent:n,source:a,end:A};case"'":return{type:"single-quoted-scalar",offset:s,indent:n,source:a,end:A};default:return{type:"scalar",offset:s,indent:n,source:a,end:A}}}function Zve(t,e,r={}){let{afterKey:n=!1,implicitKey:i=!1,inFlow:s=!1,type:o}=r,a="indent"in t?t.indent:null;if(n&&typeof a=="number"&&(a+=2),!o)switch(t.type){case"single-quoted-scalar":o="QUOTE_SINGLE";break;case"double-quoted-scalar":o="QUOTE_DOUBLE";break;case"block-scalar":{let c=t.props[0];if(c.type!=="block-scalar-header")throw new Error("Invalid block scalar header");o=c.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:o="PLAIN"}let A=W$.stringifyString({type:o,value:e},{implicitKey:i||a===null,indent:a!==null&&a>0?" ".repeat(a):"",inFlow:s,options:{blockQuote:!0,lineWidth:-1}});switch(A[0]){case"|":case">":eRe(t,A);break;case'"':n_(t,A,"double-quoted-scalar");break;case"'":n_(t,A,"single-quoted-scalar");break;default:n_(t,A,"scalar")}}function eRe(t,e){let r=e.indexOf(` `}),{type:"block-scalar",offset:s,indent:n,props:d,source:u}}case'"':return{type:"double-quoted-scalar",offset:s,indent:n,source:a,end:A};case"'":return{type:"single-quoted-scalar",offset:s,indent:n,source:a,end:A};default:return{type:"scalar",offset:s,indent:n,source:a,end:A}}}function j_e(t,e,r={}){let{afterKey:n=!1,implicitKey:i=!1,inFlow:s=!1,type:o}=r,a="indent"in t?t.indent:null;if(n&&typeof a=="number"&&(a+=2),!o)switch(t.type){case"single-quoted-scalar":o="QUOTE_SINGLE";break;case"double-quoted-scalar":o="QUOTE_DOUBLE";break;case"block-scalar":{let c=t.props[0];if(c.type!=="block-scalar-header")throw new Error("Invalid block scalar header");o=c.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:o="PLAIN"}let A=V9.stringifyString({type:o,value:e},{implicitKey:i||a===null,indent:a!==null&&a>0?" ".repeat(a):"",inFlow:s,options:{blockQuote:!0,lineWidth:-1}});switch(A[0]){case"|":case">":z_e(t,A);break;case'"':P_(t,A,"double-quoted-scalar");break;case"'":P_(t,A,"single-quoted-scalar");break;default:P_(t,A,"scalar")}}function z_e(t,e){let r=e.indexOf(`
`),n=e.substring(0,r),i=e.substring(r+1)+` `),n=e.substring(0,r),i=e.substring(r+1)+`
`;if(t.type==="block-scalar"){let s=t.props[0];if(s.type!=="block-scalar-header")throw new Error("Invalid block scalar header");s.source=n,t.source=i}else{let{offset:s}=t,o="indent"in t?t.indent:-1,a=[{type:"block-scalar-header",offset:s,indent:o,source:n}];$$(a,"end"in t?t.end:void 0)||a.push({type:"newline",offset:-1,indent:o,source:` `;if(t.type==="block-scalar"){let s=t.props[0];if(s.type!=="block-scalar-header")throw new Error("Invalid block scalar header");s.source=n,t.source=i}else{let{offset:s}=t,o="indent"in t?t.indent:-1,a=[{type:"block-scalar-header",offset:s,indent:o,source:n}];W9(a,"end"in t?t.end:void 0)||a.push({type:"newline",offset:-1,indent:o,source:`
`});for(let A of Object.keys(t))A!=="type"&&A!=="offset"&&delete t[A];Object.assign(t,{type:"block-scalar",indent:o,props:a,source:i})}}function $$(t,e){if(e)for(let r of e)switch(r.type){case"space":case"comment":t.push(r);break;case"newline":return t.push(r),!0}return!1}function n_(t,e,r){switch(t.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":t.type=r,t.source=e;break;case"block-scalar":{let n=t.props.slice(1),i=e.length;t.props[0].type==="block-scalar-header"&&(i-=t.props[0].source.length);for(let s of n)s.offset+=i;delete t.props,Object.assign(t,{type:r,source:e,end:n});break}case"block-map":case"block-seq":{let i={type:"newline",offset:t.offset+e.length,indent:t.indent,source:` `});for(let A of Object.keys(t))A!=="type"&&A!=="offset"&&delete t[A];Object.assign(t,{type:"block-scalar",indent:o,props:a,source:i})}}function W9(t,e){if(e)for(let r of e)switch(r.type){case"space":case"comment":t.push(r);break;case"newline":return t.push(r),!0}return!1}function P_(t,e,r){switch(t.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":t.type=r,t.source=e;break;case"block-scalar":{let n=t.props.slice(1),i=e.length;t.props[0].type==="block-scalar-header"&&(i-=t.props[0].source.length);for(let s of n)s.offset+=i;delete t.props,Object.assign(t,{type:r,source:e,end:n});break}case"block-map":case"block-seq":{let i={type:"newline",offset:t.offset+e.length,indent:t.indent,source:`
`};delete t.items,Object.assign(t,{type:r,source:e,end:[i]});break}default:{let n="indent"in t?t.indent:-1,i="end"in t&&Array.isArray(t.end)?t.end.filter(s=>s.type==="space"||s.type==="comment"||s.type==="newline"):[];for(let s of Object.keys(t))s!=="type"&&s!=="offset"&&delete t[s];Object.assign(t,{type:r,indent:n,source:e,end:i})}}}KI.createScalarToken=Xve;KI.resolveAsScalar=Kve;KI.setScalarValue=Zve});var Z$=h(X$=>{"use strict";var tRe=t=>"type"in t?ZI(t):XI(t);function ZI(t){switch(t.type){case"block-scalar":{let e="";for(let r of t.props)e+=ZI(r);return e+t.source}case"block-map":case"block-seq":{let e="";for(let r of t.items)e+=XI(r);return e}case"flow-collection":{let e=t.start.source;for(let r of t.items)e+=XI(r);for(let r of t.end)e+=r.source;return e}case"document":{let e=XI(t);if(t.end)for(let r of t.end)e+=r.source;return e}default:{let e=t.source;if("end"in t&&t.end)for(let r of t.end)e+=r.source;return e}}}function XI({start:t,key:e,sep:r,value:n}){let i="";for(let s of t)i+=s.source;if(e&&(i+=ZI(e)),r)for(let s of r)i+=s.source;return n&&(i+=ZI(n)),i}X$.stringify=tRe});var n9=h(r9=>{"use strict";var i_=Symbol("break visit"),rRe=Symbol("skip children"),e9=Symbol("remove item");function bA(t,e){"type"in t&&t.type==="document"&&(t={start:t.start,value:t.value}),t9(Object.freeze([]),t,e)}bA.BREAK=i_;bA.SKIP=rRe;bA.REMOVE=e9;bA.itemAtPath=(t,e)=>{let r=t;for(let[n,i]of e){let s=r?.[n];if(s&&"items"in s)r=s.items[i];else return}return r};bA.parentCollection=(t,e)=>{let r=bA.itemAtPath(t,e.slice(0,-1)),n=e[e.length-1][0],i=r?.[n];if(i&&"items"in i)return i;throw new Error("Parent collection not found")};function t9(t,e,r){let n=r(e,t);if(typeof n=="symbol")return n;for(let i of["key","value"]){let s=e[i];if(s&&"items"in s){for(let o=0;o<s.items.length;++o){let a=t9(Object.freeze(t.concat([[i,o]])),s.items[o],r);if(typeof a=="number")o=a-1;else{if(a===i_)return i_;a===e9&&(s.items.splice(o,1),o-=1)}}typeof n=="function"&&i==="key"&&(n=n(e,t))}}return typeof n=="function"?n(e,t):n}r9.visit=bA});var eB=h(bn=>{"use strict";var s_=K$(),nRe=Z$(),iRe=n9(),o_="\uFEFF",a_="",A_="",c_="",sRe=t=>!!t&&"items"in t,oRe=t=>!!t&&(t.type==="scalar"||t.type==="single-quoted-scalar"||t.type==="double-quoted-scalar"||t.type==="block-scalar");function aRe(t){switch(t){case o_:return"<BOM>";case a_:return"<DOC>";case A_:return"<FLOW_END>";case c_:return"<SCALAR>";default:return JSON.stringify(t)}}function ARe(t){switch(t){case o_:return"byte-order-mark";case a_:return"doc-mode";case A_:return"flow-error-end";case c_:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case` `};delete t.items,Object.assign(t,{type:r,source:e,end:[i]});break}default:{let n="indent"in t?t.indent:-1,i="end"in t&&Array.isArray(t.end)?t.end.filter(s=>s.type==="space"||s.type==="comment"||s.type==="newline"):[];for(let s of Object.keys(t))s!=="type"&&s!=="offset"&&delete t[s];Object.assign(t,{type:r,indent:n,source:e,end:i})}}}pB.createScalarToken=H_e;pB.resolveAsScalar=q_e;pB.setScalarValue=j_e});var X9=h(K9=>{"use strict";var G_e=t=>"type"in t?EB(t):yB(t);function EB(t){switch(t.type){case"block-scalar":{let e="";for(let r of t.props)e+=EB(r);return e+t.source}case"block-map":case"block-seq":{let e="";for(let r of t.items)e+=yB(r);return e}case"flow-collection":{let e=t.start.source;for(let r of t.items)e+=yB(r);for(let r of t.end)e+=r.source;return e}case"document":{let e=yB(t);if(t.end)for(let r of t.end)e+=r.source;return e}default:{let e=t.source;if("end"in t&&t.end)for(let r of t.end)e+=r.source;return e}}}function yB({start:t,key:e,sep:r,value:n}){let i="";for(let s of t)i+=s.source;if(e&&(i+=EB(e)),r)for(let s of r)i+=s.source;return n&&(i+=EB(n)),i}K9.stringify=G_e});var rK=h(tK=>{"use strict";var T_=Symbol("break visit"),Y_e=Symbol("skip children"),Z9=Symbol("remove item");function LA(t,e){"type"in t&&t.type==="document"&&(t={start:t.start,value:t.value}),eK(Object.freeze([]),t,e)}LA.BREAK=T_;LA.SKIP=Y_e;LA.REMOVE=Z9;LA.itemAtPath=(t,e)=>{let r=t;for(let[n,i]of e){let s=r?.[n];if(s&&"items"in s)r=s.items[i];else return}return r};LA.parentCollection=(t,e)=>{let r=LA.itemAtPath(t,e.slice(0,-1)),n=e[e.length-1][0],i=r?.[n];if(i&&"items"in i)return i;throw new Error("Parent collection not found")};function eK(t,e,r){let n=r(e,t);if(typeof n=="symbol")return n;for(let i of["key","value"]){let s=e[i];if(s&&"items"in s){for(let o=0;o<s.items.length;++o){let a=eK(Object.freeze(t.concat([[i,o]])),s.items[o],r);if(typeof a=="number")o=a-1;else{if(a===T_)return T_;a===Z9&&(s.items.splice(o,1),o-=1)}}typeof n=="function"&&i==="key"&&(n=n(e,t))}}return typeof n=="function"?n(e,t):n}tK.visit=LA});var CB=h(_n=>{"use strict";var O_=$9(),J_e=X9(),V_e=rK(),L_="\uFEFF",M_="",F_="",U_="",W_e=t=>!!t&&"items"in t,$_e=t=>!!t&&(t.type==="scalar"||t.type==="single-quoted-scalar"||t.type==="double-quoted-scalar"||t.type==="block-scalar");function K_e(t){switch(t){case L_:return"<BOM>";case M_:return"<DOC>";case F_:return"<FLOW_END>";case U_:return"<SCALAR>";default:return JSON.stringify(t)}}function X_e(t){switch(t){case L_:return"byte-order-mark";case M_:return"doc-mode";case F_:return"flow-error-end";case U_:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
`:case`\r `:case`\r
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(t[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}bn.createScalarToken=s_.createScalarToken;bn.resolveAsScalar=s_.resolveAsScalar;bn.setScalarValue=s_.setScalarValue;bn.stringify=nRe.stringify;bn.visit=iRe.visit;bn.BOM=o_;bn.DOCUMENT=a_;bn.FLOW_END=A_;bn.SCALAR=c_;bn.isCollection=sRe;bn.isScalar=oRe;bn.prettyToken=aRe;bn.tokenType=ARe});var d_=h(s9=>{"use strict";var xg=eB();function qi(t){switch(t){case void 0:case" ":case` `:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(t[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}_n.createScalarToken=O_.createScalarToken;_n.resolveAsScalar=O_.resolveAsScalar;_n.setScalarValue=O_.setScalarValue;_n.stringify=J_e.stringify;_n.visit=V_e.visit;_n.BOM=L_;_n.DOCUMENT=M_;_n.FLOW_END=F_;_n.SCALAR=U_;_n.isCollection=W_e;_n.isScalar=$_e;_n.prettyToken=K_e;_n.tokenType=X_e});var j_=h(iK=>{"use strict";var Hg=CB();function Ki(t){switch(t){case void 0:case" ":case`
`:case"\r":case" ":return!0;default:return!1}}var i9=new Set("0123456789ABCDEFabcdef"),cRe=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),tB=new Set(",[]{}"),lRe=new Set(` ,[]{} `:case"\r":case" ":return!0;default:return!1}}var nK=new Set("0123456789ABCDEFabcdef"),Z_e=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),IB=new Set(",[]{}"),eke=new Set(` ,[]{}
\r `),l_=t=>!t||lRe.has(t),u_=class{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,r=!1){if(e){if(typeof e!="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!r;let n=this.next??"stream";for(;n&&(r||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,r=this.buffer[e];for(;r===" "||r===" ";)r=this.buffer[++e];return!r||r==="#"||r===` \r `),q_=t=>!t||eke.has(t),H_=class{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,r=!1){if(e){if(typeof e!="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!r;let n=this.next??"stream";for(;n&&(r||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,r=this.buffer[e];for(;r===" "||r===" ";)r=this.buffer[++e];return!r||r==="#"||r===`
`?!0:r==="\r"?this.buffer[e+1]===` `?!0:r==="\r"?this.buffer[e+1]===`
`:!1}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let r=this.buffer[e];if(this.indentNext>0){let n=0;for(;r===" ";)r=this.buffer[++n+e];if(r==="\r"){let i=this.buffer[n+e+1];if(i===` `:!1}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let r=this.buffer[e];if(this.indentNext>0){let n=0;for(;r===" ";)r=this.buffer[++n+e];if(r==="\r"){let i=this.buffer[n+e+1];if(i===`
`||!i&&!this.atEnd)return e+n+1}return r===` `||!i&&!this.atEnd)return e+n+1}return r===`
`||n>=this.indentNext||!r&&!this.atEnd?e+n:-1}if(r==="-"||r==="."){let n=this.buffer.substr(e,3);if((n==="---"||n==="...")&&qi(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!="number"||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(` `||n>=this.indentNext||!r&&!this.atEnd?e+n:-1}if(r==="-"||r==="."){let n=this.buffer.substr(e,3);if((n==="---"||n==="...")&&Ki(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!="number"||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(`
`,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]==="\r"&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext("stream");if(e[0]===xg.BOM&&(yield*this.pushCount(1),e=e.substring(1)),e[0]==="%"){let r=e.length,n=e.indexOf("#");for(;n!==-1;){let s=e[n-1];if(s===" "||s===" "){r=n-1;break}else n=e.indexOf("#",n+1)}for(;;){let s=e[r-1];if(s===" "||s===" ")r-=1;else break}let i=(yield*this.pushCount(r))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-i),this.pushNewline(),"stream"}if(this.atLineEnd()){let r=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-r),yield*this.pushNewline(),"stream"}return yield xg.DOCUMENT,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if(e==="-"||e==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let r=this.peek(3);if((r==="---"||r==="...")&&qi(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,r==="---"?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!qi(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,r]=this.peek(2);if(!r&&!this.atEnd)return this.setNext("block-start");if((e==="-"||e==="?"||e===":")&&qi(r)){let n=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=n,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(e===null)return this.setNext("doc");let r=yield*this.pushIndicators();switch(e[r]){case"#":yield*this.pushCount(e.length-r);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(l_),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return r+=yield*this.parseBlockScalarHeader(),r+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-r),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,r,n=-1;do e=yield*this.pushNewline(),e>0?(r=yield*this.pushSpaces(!1),this.indentValue=n=r):r=0,r+=yield*this.pushSpaces(!0);while(e+r>0);let i=this.getLine();if(i===null)return this.setNext("flow");if((n!==-1&&n<this.indentNext&&i[0]!=="#"||n===0&&(i.startsWith("---")||i.startsWith("..."))&&qi(i[3]))&&!(n===this.indentNext-1&&this.flowLevel===1&&(i[0]==="]"||i[0]==="}")))return this.flowLevel=0,yield xg.FLOW_END,yield*this.parseLineStart();let s=0;for(;i[s]===",";)s+=yield*this.pushCount(1),s+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(s+=yield*this.pushIndicators(),i[s]){case void 0:return"flow";case"#":return yield*this.pushCount(i.length-s),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(l_),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let o=this.charAt(1);if(this.flowKey||qi(o)||o===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),r=this.buffer.indexOf(e,this.pos+1);if(e==="'")for(;r!==-1&&this.buffer[r+1]==="'";)r=this.buffer.indexOf("'",r+2);else for(;r!==-1;){let s=0;for(;this.buffer[r-1-s]==="\\";)s+=1;if(s%2===0)break;r=this.buffer.indexOf('"',r+1)}let n=this.buffer.substring(0,r),i=n.indexOf(` `,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]==="\r"&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext("stream");if(e[0]===Hg.BOM&&(yield*this.pushCount(1),e=e.substring(1)),e[0]==="%"){let r=e.length,n=e.indexOf("#");for(;n!==-1;){let s=e[n-1];if(s===" "||s===" "){r=n-1;break}else n=e.indexOf("#",n+1)}for(;;){let s=e[r-1];if(s===" "||s===" ")r-=1;else break}let i=(yield*this.pushCount(r))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-i),this.pushNewline(),"stream"}if(this.atLineEnd()){let r=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-r),yield*this.pushNewline(),"stream"}return yield Hg.DOCUMENT,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if(e==="-"||e==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");let r=this.peek(3);if((r==="---"||r==="...")&&Ki(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,r==="---"?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!Ki(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,r]=this.peek(2);if(!r&&!this.atEnd)return this.setNext("block-start");if((e==="-"||e==="?"||e===":")&&Ki(r)){let n=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=n,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(e===null)return this.setNext("doc");let r=yield*this.pushIndicators();switch(e[r]){case"#":yield*this.pushCount(e.length-r);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(q_),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return r+=yield*this.parseBlockScalarHeader(),r+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-r),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,r,n=-1;do e=yield*this.pushNewline(),e>0?(r=yield*this.pushSpaces(!1),this.indentValue=n=r):r=0,r+=yield*this.pushSpaces(!0);while(e+r>0);let i=this.getLine();if(i===null)return this.setNext("flow");if((n!==-1&&n<this.indentNext&&i[0]!=="#"||n===0&&(i.startsWith("---")||i.startsWith("..."))&&Ki(i[3]))&&!(n===this.indentNext-1&&this.flowLevel===1&&(i[0]==="]"||i[0]==="}")))return this.flowLevel=0,yield Hg.FLOW_END,yield*this.parseLineStart();let s=0;for(;i[s]===",";)s+=yield*this.pushCount(1),s+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(s+=yield*this.pushIndicators(),i[s]){case void 0:return"flow";case"#":return yield*this.pushCount(i.length-s),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(q_),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{let o=this.charAt(1);if(this.flowKey||Ki(o)||o===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),r=this.buffer.indexOf(e,this.pos+1);if(e==="'")for(;r!==-1&&this.buffer[r+1]==="'";)r=this.buffer.indexOf("'",r+2);else for(;r!==-1;){let s=0;for(;this.buffer[r-1-s]==="\\";)s+=1;if(s%2===0)break;r=this.buffer.indexOf('"',r+1)}let n=this.buffer.substring(0,r),i=n.indexOf(`
`,this.pos);if(i!==-1){for(;i!==-1;){let s=this.continueScalar(i+1);if(s===-1)break;i=n.indexOf(` `,this.pos);if(i!==-1){for(;i!==-1;){let s=this.continueScalar(i+1);if(s===-1)break;i=n.indexOf(`
`,s)}i!==-1&&(r=i-(n[i-1]==="\r"?2:1))}if(r===-1){if(!this.atEnd)return this.setNext("quoted-scalar");r=this.buffer.length}return yield*this.pushToIndex(r+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){let r=this.buffer[++e];if(r==="+")this.blockScalarKeep=!0;else if(r>"0"&&r<="9")this.blockScalarIndent=Number(r)-1;else if(r!=="-")break}return yield*this.pushUntil(r=>qi(r)||r==="#")}*parseBlockScalar(){let e=this.pos-1,r=0,n;e:for(let s=this.pos;n=this.buffer[s];++s)switch(n){case" ":r+=1;break;case` `,s)}i!==-1&&(r=i-(n[i-1]==="\r"?2:1))}if(r===-1){if(!this.atEnd)return this.setNext("quoted-scalar");r=this.buffer.length}return yield*this.pushToIndex(r+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){let r=this.buffer[++e];if(r==="+")this.blockScalarKeep=!0;else if(r>"0"&&r<="9")this.blockScalarIndent=Number(r)-1;else if(r!=="-")break}return yield*this.pushUntil(r=>Ki(r)||r==="#")}*parseBlockScalar(){let e=this.pos-1,r=0,n;e:for(let s=this.pos;n=this.buffer[s];++s)switch(n){case" ":r+=1;break;case`
`:e=s,r=0;break;case"\r":{let o=this.buffer[s+1];if(!o&&!this.atEnd)return this.setNext("block-scalar");if(o===` `:e=s,r=0;break;case"\r":{let o=this.buffer[s+1];if(!o&&!this.atEnd)return this.setNext("block-scalar");if(o===`
`)break}default:break e}if(!n&&!this.atEnd)return this.setNext("block-scalar");if(r>=this.indentNext){this.blockScalarIndent===-1?this.indentNext=r:this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let s=this.continueScalar(e+1);if(s===-1)break;e=this.buffer.indexOf(` `)break}default:break e}if(!n&&!this.atEnd)return this.setNext("block-scalar");if(r>=this.indentNext){this.blockScalarIndent===-1?this.indentNext=r:this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let s=this.continueScalar(e+1);if(s===-1)break;e=this.buffer.indexOf(`
`,s)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext("block-scalar");e=this.buffer.length}}let i=e+1;for(n=this.buffer[i];n===" ";)n=this.buffer[++i];if(n===" "){for(;n===" "||n===" "||n==="\r"||n===` `,s)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext("block-scalar");e=this.buffer.length}}let i=e+1;for(n=this.buffer[i];n===" ";)n=this.buffer[++i];if(n===" "){for(;n===" "||n===" "||n==="\r"||n===`
`;)n=this.buffer[++i];e=i-1}else if(!this.blockScalarKeep)do{let s=e-1,o=this.buffer[s];o==="\r"&&(o=this.buffer[--s]);let a=s;for(;o===" ";)o=this.buffer[--s];if(o===` `;)n=this.buffer[++i];e=i-1}else if(!this.blockScalarKeep)do{let s=e-1,o=this.buffer[s];o==="\r"&&(o=this.buffer[--s]);let a=s;for(;o===" ";)o=this.buffer[--s];if(o===`
`&&s>=this.pos&&s+1+r>a)e=s;else break}while(!0);return yield xg.SCALAR,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,r=this.pos-1,n=this.pos-1,i;for(;i=this.buffer[++n];)if(i===":"){let s=this.buffer[n+1];if(qi(s)||e&&tB.has(s))break;r=n}else if(qi(i)){let s=this.buffer[n+1];if(i==="\r"&&(s===` `&&s>=this.pos&&s+1+r>a)e=s;else break}while(!0);return yield Hg.SCALAR,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,r=this.pos-1,n=this.pos-1,i;for(;i=this.buffer[++n];)if(i===":"){let s=this.buffer[n+1];if(Ki(s)||e&&IB.has(s))break;r=n}else if(Ki(i)){let s=this.buffer[n+1];if(i==="\r"&&(s===`
`?(n+=1,i=` `?(n+=1,i=`
`,s=this.buffer[n+1]):r=n),s==="#"||e&&tB.has(s))break;if(i===` `,s=this.buffer[n+1]):r=n),s==="#"||e&&IB.has(s))break;if(i===`
`){let o=this.continueScalar(n+1);if(o===-1)break;n=Math.max(n,o-2)}}else{if(e&&tB.has(i))break;r=n}return!i&&!this.atEnd?this.setNext("plain-scalar"):(yield xg.SCALAR,yield*this.pushToIndex(r+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,r){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(r&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(l_))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{let e=this.flowLevel>0,r=this.charAt(1);if(qi(r)||e&&tB.has(r))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,r=this.buffer[e];for(;!qi(r)&&r!==">";)r=this.buffer[++e];return yield*this.pushToIndex(r===">"?e+1:e,!1)}else{let e=this.pos+1,r=this.buffer[e];for(;r;)if(cRe.has(r))r=this.buffer[++e];else if(r==="%"&&i9.has(this.buffer[e+1])&&i9.has(this.buffer[e+2]))r=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return e===` `){let o=this.continueScalar(n+1);if(o===-1)break;n=Math.max(n,o-2)}}else{if(e&&IB.has(i))break;r=n}return!i&&!this.atEnd?this.setNext("plain-scalar"):(yield Hg.SCALAR,yield*this.pushToIndex(r+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,r){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(r&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(q_))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{let e=this.flowLevel>0,r=this.charAt(1);if(Ki(r)||e&&IB.has(r))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,r=this.buffer[e];for(;!Ki(r)&&r!==">";)r=this.buffer[++e];return yield*this.pushToIndex(r===">"?e+1:e,!1)}else{let e=this.pos+1,r=this.buffer[e];for(;r;)if(Z_e.has(r))r=this.buffer[++e];else if(r==="%"&&nK.has(this.buffer[e+1])&&nK.has(this.buffer[e+2]))r=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return e===`
`?yield*this.pushCount(1):e==="\r"&&this.charAt(1)===` `?yield*this.pushCount(1):e==="\r"&&this.charAt(1)===`
`?yield*this.pushCount(2):0}*pushSpaces(e){let r=this.pos-1,n;do n=this.buffer[++r];while(n===" "||e&&n===" ");let i=r-this.pos;return i>0&&(yield this.buffer.substr(this.pos,i),this.pos=r),i}*pushUntil(e){let r=this.pos,n=this.buffer[r];for(;!e(n);)n=this.buffer[++r];return yield*this.pushToIndex(r,!1)}};s9.Lexer=u_});var h_=h(o9=>{"use strict";var f_=class{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let r=0,n=this.lineStarts.length;for(;r<n;){let s=r+n>>1;this.lineStarts[s]<e?r=s+1:n=s}if(this.lineStarts[r]===e)return{line:r+1,col:1};if(r===0)return{line:0,col:e};let i=this.lineStarts[r-1];return{line:r,col:e-i+1}}}};o9.LineCounter=f_});var m_=h(u9=>{"use strict";var uRe=require("node:process"),a9=eB(),dRe=d_();function NA(t,e){for(let r=0;r<t.length;++r)if(t[r].type===e)return!0;return!1}function A9(t){for(let e=0;e<t.length;++e)switch(t[e].type){case"space":case"comment":case"newline":break;default:return e}return-1}function l9(t){switch(t?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function rB(t){switch(t.type){case"document":return t.start;case"block-map":{let e=t.items[t.items.length-1];return e.sep??e.start}case"block-seq":return t.items[t.items.length-1].start;default:return[]}}function td(t){if(t.length===0)return[];let e=t.length;e:for(;--e>=0;)switch(t[e].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;t[++e]?.type==="space";);return t.splice(e,t.length)}function c9(t){if(t.start.type==="flow-seq-start")for(let e of t.items)e.sep&&!e.value&&!NA(e.start,"explicit-key-ind")&&!NA(e.sep,"map-value-ind")&&(e.key&&(e.value=e.key),delete e.key,l9(e.value)?e.value.end?Array.prototype.push.apply(e.value.end,e.sep):e.value.end=e.sep:Array.prototype.push.apply(e.start,e.sep),delete e.sep)}var g_=class{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new dRe.Lexer,this.onNewLine=e}*parse(e,r=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(let n of this.lexer.lex(e,r))yield*this.next(n);r||(yield*this.end())}*next(e){if(this.source=e,uRe.env.LOG_TOKENS&&console.log("|",a9.prettyToken(e)),this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let r=a9.tokenType(e);if(r)if(r==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=r,yield*this.step(),r){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&e[0]===" "&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{let n=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:n,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type==="doc-end"&&(!e||e.type!=="doc-end")){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){let r=e??this.stack.pop();if(!r)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield r;else{let n=this.peek(1);switch(r.type==="block-scalar"?r.indent="indent"in n?n.indent:0:r.type==="flow-collection"&&n.type==="document"&&(r.indent=0),r.type==="flow-collection"&&c9(r),n.type){case"document":n.value=r;break;case"block-scalar":n.props.push(r);break;case"block-map":{let i=n.items[n.items.length-1];if(i.value){n.items.push({start:[],key:r,sep:[]}),this.onKeyLine=!0;return}else if(i.sep)i.value=r;else{Object.assign(i,{key:r,sep:[]}),this.onKeyLine=!i.explicitKey;return}break}case"block-seq":{let i=n.items[n.items.length-1];i.value?n.items.push({start:[],value:r}):i.value=r;break}case"flow-collection":{let i=n.items[n.items.length-1];!i||i.value?n.items.push({start:[],key:r,sep:[]}):i.sep?i.value=r:Object.assign(i,{key:r,sep:[]});return}default:yield*this.pop(),yield*this.pop(r)}if((n.type==="document"||n.type==="block-map"||n.type==="block-seq")&&(r.type==="block-map"||r.type==="bloc Line truncated `?yield*this.pushCount(2):0}*pushSpaces(e){let r=this.pos-1,n;do n=this.buffer[++r];while(n===" "||e&&n===" ");let i=r-this.pos;return i>0&&(yield this.buffer.substr(this.pos,i),this.pos=r),i}*pushUntil(e){let r=this.pos,n=this.buffer[r];for(;!e(n);)n=this.buffer[++r];return yield*this.pushToIndex(r,!1)}};iK.Lexer=H_});var G_=h(sK=>{"use strict";var z_=class{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let r=0,n=this.lineStarts.length;for(;r<n;){let s=r+n>>1;this.lineStarts[s]<e?r=s+1:n=s}if(this.lineStarts[r]===e)return{line:r+1,col:1};if(r===0)return{line:0,col:e};let i=this.lineStarts[r-1];return{line:r,col:e-i+1}}}};sK.LineCounter=z_});var J_=h(lK=>{"use strict";var tke=require("node:process"),oK=CB(),rke=j_();function MA(t,e){for(let r=0;r<t.length;++r)if(t[r].type===e)return!0;return!1}function aK(t){for(let e=0;e<t.length;++e)switch(t[e].type){case"space":case"comment":case"newline":break;default:return e}return-1}function cK(t){switch(t?.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function BB(t){switch(t.type){case"document":return t.start;case"block-map":{let e=t.items[t.items.length-1];return e.sep??e.start}case"block-seq":return t.items[t.items.length-1].start;default:return[]}}function hd(t){if(t.length===0)return[];let e=t.length;e:for(;--e>=0;)switch(t[e].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;t[++e]?.type==="space";);return t.splice(e,t.length)}function AK(t){if(t.start.type==="flow-seq-start")for(let e of t.items)e.sep&&!e.value&&!MA(e.start,"explicit-key-ind")&&!MA(e.sep,"map-value-ind")&&(e.key&&(e.value=e.key),delete e.key,cK(e.value)?e.value.end?Array.prototype.push.apply(e.value.end,e.sep):e.value.end=e.sep:Array.prototype.push.apply(e.start,e.sep),delete e.sep)}var Y_=class{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new rke.Lexer,this.onNewLine=e}*parse(e,r=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(let n of this.lexer.lex(e,r))yield*this.next(n);r||(yield*this.end())}*next(e){if(this.source=e,tke.env.LOG_TOKENS&&console.log("|",oK.prettyToken(e)),this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let r=oK.tokenType(e);if(r)if(r==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=r,yield*this.step(),r){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&e[0]===" "&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{let n=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:n,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type==="doc-end"&&(!e||e.type!=="doc-end")){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){let r=e??this.stack.pop();if(!r)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield r;else{let n=this.peek(1);switch(r.type==="block-scalar"?r.indent="indent"in n?n.indent:0:r.type==="flow-collection"&&n.type==="document"&&(r.indent=0),r.type==="flow-collection"&&AK(r),n.type){case"document":n.value=r;break;case"block-scalar":n.props.push(r);break;case"block-map":{let i=n.items[n.items.length-1];if(i.value){n.items.push({start:[],key:r,sep:[]}),this.onKeyLine=!0;return}else if(i.sep)i.value=r;else{Object.assign(i,{key:r,sep:[]}),this.onKeyLine=!i.explicitKey;return}break}case"block-seq":{let i=n.items[n.items.length-1];i.value?n.items.push({start:[],value:r}):i.value=r;break}case"flow-collection":{let i=n.items[n.items.length-1];!i||i.value?n.items.push({start:[],key:r,sep:[]}):i.sep?i.value=r:Object.assign(i,{key:r,sep:[]});return}default:yield*this.pop(),yield*this.pop(r)}if((n.type==="document"||n.type==="block-map"||n.type==="block-seq")&&(r.type==="block-map"||r.type==="bloc Line truncated
`)+1;for(;r!==0;)this.onNewLine(this.offset+r),r=this.source.indexOf(` `)+1;for(;r!==0;)this.onNewLine(this.offset+r),r=this.source.indexOf(`
`,r)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let r=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,r.value){let n="end"in r.value?r.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"space":case"comment":if(r.value)e.items.push({start:[this.sourceToken]});else if(r.sep)r.sep.push(this.sourceToken);else{if(this.atIndentedComment(r.start,e.indent)){let i=e.items[e.items.length-2]?.value?.end;if(Array.isArray(i)){Array.prototype.push.apply(i,r.start),i.push(this.sourceToken),e.items.pop();return}}r.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,i=n&&(r.sep||r.explicitKey)&&this.type!=="seq-item-ind",s=[];if(i&&r.sep&&!r.value){let o=[];for(let a=0;a<r.sep.length;++a){let A=r.sep[a];switch(A.type){case"newline":o.push(a);break;case"space":break;case"comment":A.indent>e.indent&&(o.length=0);break;default:o.length=0}}o.length>=2&&(s=r.sep.splice(o[1]))}switch(this.type){case"anchor":case"tag":i||r.value?(s.push(this.sourceToken),e.items.push({start:s}),this.onKeyLine=!0):r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"explicit-key-ind":!r.sep&&!r.explicitKey?(r.start.push(this.sourceToken),r.explicitKey=!0):i||r.value?(s.push(this.sourceToken),e.items.push({start:s,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(r.explicitKey)if(r.sep)if(r.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(NA(r.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]});else if(l9(r.key)&&!NA(r.sep,"newline")){let o=td(r.start),a=r.key,A=r.sep;A.push(this.sourceToken),delete r.key,delete r.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:o,key:a,sep:A}]})}else s.length>0?r.sep=r.sep.concat(s,this.sourceToken):r.sep.push(this.sourceToken);else if(NA(r.start,"newline"))Object.assign(r,{key:null,sep:[this.sourceToken]});else{let o=td(r.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:o,key:null,sep:[this.sourceToken]}]})}else r.sep?r.value||i?e.items.push({start:s,key:null,sep:[this.sourceToken]}):NA(r.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):r.sep.push(this.sourceToken):Object.assign(r,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let o=this.flowScalar(this.type);i||r.value?(e.items.push({start:s,key:o,sep:[]}),this.onKeyLine=!0):r.sep?this.stack.push(o):(Object.assign(r,{key:o,sep:[]}),this.onKeyLine=!0);return}default:{let o=this.startBlockValue(e);if(o){n&&o.type!=="block-seq"&&e.items.push({start:s}),this.stack.push(o);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let r=e.items[e.items.length-1];switch(this.type){case"newline":if(r.value){let n="end"in r.value?r.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else r.start.push(this.sourceToken);return;case"space":case"comment":if(r.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(r.start,e.indent)){let i=e.items[e.items.length-2]?.value?.end;if(Array.isArray(i)){Array.prototype.push.apply(i,r.start),i.push(this.sourceToken),e.items.pop();return}}r.start.push(this.sourceToken)}return;case"anchor":case"tag":if(r.value||this.indent<=e.indent)break;r.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;r.value||NA(r.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):r.start.push(this.sourceToken);return}if(this.indent>e.indent){let n=this.startBlockValue(e);if(n){this.stack.push(n);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let r=e.items[e.items.length-1];if(this.type==="flow-error-end"){let n;do yield*this.pop(),n=this.peek(1);while(n&&n.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":!r||r.sep?e.items.push({start:[this.sourceToken]}):r.start.push(this.sourceToken);return;case"map-value-ind":!r||r.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):r.sep?r.sep.push(this.sourceToken):Object.assign(r,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!r||r.value?e.items.push({start:[this.sourceToken]}):r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"alias":case"scalar":case"singl Line truncated `,r)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let r=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,r.value){let n="end"in r.value?r.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"space":case"comment":if(r.value)e.items.push({start:[this.sourceToken]});else if(r.sep)r.sep.push(this.sourceToken);else{if(this.atIndentedComment(r.start,e.indent)){let i=e.items[e.items.length-2]?.value?.end;if(Array.isArray(i)){Array.prototype.push.apply(i,r.start),i.push(this.sourceToken),e.items.pop();return}}r.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,i=n&&(r.sep||r.explicitKey)&&this.type!=="seq-item-ind",s=[];if(i&&r.sep&&!r.value){let o=[];for(let a=0;a<r.sep.length;++a){let A=r.sep[a];switch(A.type){case"newline":o.push(a);break;case"space":break;case"comment":A.indent>e.indent&&(o.length=0);break;default:o.length=0}}o.length>=2&&(s=r.sep.splice(o[1]))}switch(this.type){case"anchor":case"tag":i||r.value?(s.push(this.sourceToken),e.items.push({start:s}),this.onKeyLine=!0):r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"explicit-key-ind":!r.sep&&!r.explicitKey?(r.start.push(this.sourceToken),r.explicitKey=!0):i||r.value?(s.push(this.sourceToken),e.items.push({start:s,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(r.explicitKey)if(r.sep)if(r.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(MA(r.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]});else if(cK(r.key)&&!MA(r.sep,"newline")){let o=hd(r.start),a=r.key,A=r.sep;A.push(this.sourceToken),delete r.key,delete r.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:o,key:a,sep:A}]})}else s.length>0?r.sep=r.sep.concat(s,this.sourceToken):r.sep.push(this.sourceToken);else if(MA(r.start,"newline"))Object.assign(r,{key:null,sep:[this.sourceToken]});else{let o=hd(r.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:o,key:null,sep:[this.sourceToken]}]})}else r.sep?r.value||i?e.items.push({start:s,key:null,sep:[this.sourceToken]}):MA(r.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):r.sep.push(this.sourceToken):Object.assign(r,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{let o=this.flowScalar(this.type);i||r.value?(e.items.push({start:s,key:o,sep:[]}),this.onKeyLine=!0):r.sep?this.stack.push(o):(Object.assign(r,{key:o,sep:[]}),this.onKeyLine=!0);return}default:{let o=this.startBlockValue(e);if(o){n&&o.type!=="block-seq"&&e.items.push({start:s}),this.stack.push(o);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let r=e.items[e.items.length-1];switch(this.type){case"newline":if(r.value){let n="end"in r.value?r.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type==="comment"?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else r.start.push(this.sourceToken);return;case"space":case"comment":if(r.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(r.start,e.indent)){let i=e.items[e.items.length-2]?.value?.end;if(Array.isArray(i)){Array.prototype.push.apply(i,r.start),i.push(this.sourceToken),e.items.pop();return}}r.start.push(this.sourceToken)}return;case"anchor":case"tag":if(r.value||this.indent<=e.indent)break;r.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;r.value||MA(r.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):r.start.push(this.sourceToken);return}if(this.indent>e.indent){let n=this.startBlockValue(e);if(n){this.stack.push(n);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let r=e.items[e.items.length-1];if(this.type==="flow-error-end"){let n;do yield*this.pop(),n=this.peek(1);while(n&&n.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":!r||r.sep?e.items.push({start:[this.sourceToken]}):r.start.push(this.sourceToken);return;case"map-value-ind":!r||r.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):r.sep?r.sep.push(this.sourceToken):Object.assign(r,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!r||r.value?e.items.push({start:[this.sourceToken]}):r.sep?r.sep.push(this.sourceToken):r.start.push(this.sourceToken);return;case"alias":case"scalar":case"singl Line truncated
`)+1;for(;r!==0;)this.onNewLine(this.offset+r),r=this.source.indexOf(` `)+1;for(;r!==0;)this.onNewLine(this.offset+r),r=this.source.indexOf(`
`,r)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let r=rB(e),n=td(r);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let r=rB(e),n=td(r);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,r){return this.type!=="comment"||this.indent<=r?!1:e.every(n=>n.type==="newline"||n.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}};u9.Parser=g_});var m9=h(vg=>{"use strict";var d9=r_(),fRe=Cg(),Sg=Qg(),hRe=eD(),gRe=qe(),mRe=h_(),f9=m_();function h9(t){let e=t.prettyErrors!==!1;return{lineCounter:t.lineCounter||e&&new mRe.LineCounter||null,prettyErrors:e}}function pRe(t,e={}){let{lineCounter:r,prettyErrors:n}=h9(e),i=new f9.Parser(r?.addNewLine),s=new d9.Composer(e),o=Array.from(s.compose(i.parse(t)));if(n&&r)for(let a of o)a.errors.forEach(Sg.prettifyError(t,r)),a.warnings.forEach(Sg.prettifyError(t,r));return o.length>0?o:Object.assign([],{empty:!0},s.streamInfo())}function g9(t,e={}){let{lineCounter:r,prettyErrors:n}=h9(e),i=new f9.Parser(r?.addNewLine),s=new d9.Composer(e),o=null;for(let a of s.compose(i.parse(t),!0,t.length))if(!o)o=a;else if(o.options.logLevel!=="silent"){o.errors.push(new Sg.YAMLParseError(a.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return n&&r&&(o.errors.forEach(Sg.prettifyError(t,r)),o.warnings.forEach(Sg.prettifyError(t,r))),o}function yRe(t,e,r){let n;typeof e=="function"?n=e:r===void 0&&e&&typeof e=="object"&&(r=e);let i=g9(t,r);if(!i)return null;if(i.warnings.forEach(s=>hRe.warn(i.options.logLevel,s)),i.errors.length>0){if(i.options.logLevel!=="silent")throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:n},r))}function ERe(t,e,r){let n=null;if(typeof e=="function"||Array.isArray(e)?n=e:r===void 0&&e&&(r=e),typeof r=="string"&&(r=r.length),typeof r=="number"){let i=Math.round(r);r=i<1?void 0:i>8?{indent:8}:{indent:i}}if(t===void 0){let{keepUndefined:i}=r??e??{};if(!i)return}return gRe.isDocument(t)&&!n?t.toString(r):new fRe.Document(t,n,r).toString(r)}vg.parse=yRe;vg.parseAllDocuments=pRe;vg.parseDocument=g9;vg.stringify=ERe});var y_=h(et=>{"use strict";var CRe=r_(),IRe=Cg(),BRe=OD(),p_=Qg(),QRe=ng(),ha=qe(),bRe=la(),NRe=er(),wRe=da(),xRe=fa(),SRe=eB(),vRe=d_(),RRe=h_(),DRe=m_(),nB=m9(),p9=Zh();et.Composer=CRe.Composer;et.Document=IRe.Document;et.Schema=BRe.Schema;et.YAMLError=p_.YAMLError;et.YAMLParseError=p_.YAMLParseError;et.YAMLWarning=p_.YAMLWarning;et.Alias=QRe.Alias;et.isAlias=ha.isAlias;et.isCollection=ha.isCollection;et.isDocument=ha.isDocument;et.isMap=ha.isMap;et.isNode=ha.isNode;et.isPair=ha.isPair;et.isScalar=ha.isScalar;et.isSeq=ha.isSeq;et.Pair=bRe.Pair;et.Scalar=NRe.Scalar;et.YAMLMap=wRe.YAMLMap;et.YAMLSeq=xRe.YAMLSeq;et.CST=SRe;et.Lexer=vRe.Lexer;et.LineCounter=RRe.LineCounter;et.Parser=DRe.Parser;et.parse=nB.parse;et.parseAllDocuments=nB.parseAllDocuments;et.parseDocument=nB.parseDocument;et.stringify=nB.stringify;et.visit=p9.visit;et.visitAsync=p9.visitAsync});var fd=pt(ot());var g4=pt(ZC()),Gu=pt(ot());var l4=pt(ZC()),Ci=pt(ot()),u4=pt(tf()),d4=pt(c4()),f4=pt(require("os"));async function h4(t){let e=await WNe();(0,Ci.saveState)("cache_path",e);let r=await(0,d4.hashFiles)(t.cacheDependencyPath);if(!r)throw new Error("Some specified paths were not resolved, unable to cache dependencies.");let n=`pnpm-cache-${process.env.RUNNER_OS}-${f4.default.arch()}-${r}`;(0,Ci.debug)(`Primary key is ${n}`),(0,Ci.saveState)("cache_primary_key",n);let i=await(0,l4.restoreCache)([e],n);if((0,Ci.setOutput)("cache-hit",!!i),!i){(0,Ci.info)("Cache is not found");return}(0,Ci.saveState)("cache_restored_key",i),(0,Ci.info)(`Cache restored from key: ${i}`)}async function WNe(){let{stdout:t}=await(0,u4.getExecOutput)("pnpm store path --silent"),e=t.trim();return(0,Ci.debug)(`Cache folLine truncated `,r)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;let r=BB(e),n=hd(r);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;let r=BB(e),n=hd(r);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,r){return this.type!=="comment"||this.indent<=r?!1:e.every(n=>n.type==="newline"||n.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}};lK.Parser=Y_});var gK=h(zg=>{"use strict";var uK=k_(),nke=Tg(),jg=Mg(),ike=DD(),ske=ze(),oke=G_(),dK=J_();function fK(t){let e=t.prettyErrors!==!1;return{lineCounter:t.lineCounter||e&&new oke.LineCounter||null,prettyErrors:e}}function ake(t,e={}){let{lineCounter:r,prettyErrors:n}=fK(e),i=new dK.Parser(r?.addNewLine),s=new uK.Composer(e),o=Array.from(s.compose(i.parse(t)));if(n&&r)for(let a of o)a.errors.forEach(jg.prettifyError(t,r)),a.warnings.forEach(jg.prettifyError(t,r));return o.length>0?o:Object.assign([],{empty:!0},s.streamInfo())}function hK(t,e={}){let{lineCounter:r,prettyErrors:n}=fK(e),i=new dK.Parser(r?.addNewLine),s=new uK.Composer(e),o=null;for(let a of s.compose(i.parse(t),!0,t.length))if(!o)o=a;else if(o.options.logLevel!=="silent"){o.errors.push(new jg.YAMLParseError(a.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return n&&r&&(o.errors.forEach(jg.prettifyError(t,r)),o.warnings.forEach(jg.prettifyError(t,r))),o}function Ake(t,e,r){let n;typeof e=="function"?n=e:r===void 0&&e&&typeof e=="object"&&(r=e);let i=hK(t,r);if(!i)return null;if(i.warnings.forEach(s=>ike.warn(i.options.logLevel,s)),i.errors.length>0){if(i.options.logLevel!=="silent")throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:n},r))}function cke(t,e,r){let n=null;if(typeof e=="function"||Array.isArray(e)?n=e:r===void 0&&e&&(r=e),typeof r=="string"&&(r=r.length),typeof r=="number"){let i=Math.round(r);r=i<1?void 0:i>8?{indent:8}:{indent:i}}if(t===void 0){let{keepUndefined:i}=r??e??{};if(!i)return}return ske.isDocument(t)&&!n?t.toString(r):new nke.Document(t,n,r).toString(r)}zg.parse=Ake;zg.parseAllDocuments=ake;zg.parseDocument=hK;zg.stringify=cke});var W_=h(nt=>{"use strict";var lke=k_(),uke=Tg(),dke=f_(),V_=Mg(),fke=yg(),wa=ze(),hke=Ba(),gke=ir(),mke=ba(),pke=Na(),yke=CB(),Eke=j_(),Cke=G_(),Ike=J_(),QB=gK(),mK=hg();nt.Composer=lke.Composer;nt.Document=uke.Document;nt.Schema=dke.Schema;nt.YAMLError=V_.YAMLError;nt.YAMLParseError=V_.YAMLParseError;nt.YAMLWarning=V_.YAMLWarning;nt.Alias=fke.Alias;nt.isAlias=wa.isAlias;nt.isCollection=wa.isCollection;nt.isDocument=wa.isDocument;nt.isMap=wa.isMap;nt.isNode=wa.isNode;nt.isPair=wa.isPair;nt.isScalar=wa.isScalar;nt.isSeq=wa.isSeq;nt.Pair=hke.Pair;nt.Scalar=gke.Scalar;nt.YAMLMap=mke.YAMLMap;nt.YAMLSeq=pke.YAMLSeq;nt.CST=yke;nt.Lexer=Eke.Lexer;nt.LineCounter=Cke.LineCounter;nt.Parser=Ike.Parser;nt.parse=QB.parse;nt.parseAllDocuments=QB.parseAllDocuments;nt.parseDocument=QB.parseDocument;nt.stringify=QB.stringify;nt.visit=mK.visit;nt.visitAsync=mK.visitAsync});var Nd=h((Dze,PK)=>{"use strict";var kPe="2.0.0",PPe=Number.MAX_SAFE_INTEGER||9007199254740991,TPe=16,OPe=250,LPe=["major","premajor","minor","preminor","patch","prepatch","prerelease"];PK.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:TPe,MAX_SAFE_BUILD_LENGTH:OPe,MAX_SAFE_INTEGER:PPe,RELEASE_TYPES:LPe,SEMVER_SPEC_VERSION:kPe,FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}});var $g=h((_ze,TK)=>{"use strict";var MPe=typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...t)=>console.error("SEMVER",...t):()=>{};TK.exports=MPe});var wd=h((_s,OK)=>{"use strict";var{MAX_SAFE_COMPONENT_LENGTH:rk,MAX_SAFE_BUILD_LENGTH:FPe,MAX_LENGTH:UPe}=Nd(),qPe=$g();_s=OK.exports={};var HPe=_s.re=[],jPe=_s.safeRe=[],ee=_s.src=[],zPe=_s.safeSrc=[],te=_s.t={},GPe=0,nk="[a-zA-Z0-9 Line truncated
- version ${e} in the GitHub Action config with the key "version" - version ${e} in the GitHub Action config with the key "version"
- version ${i} in the package.json with the key "packageManager" - version ${i} in the package.json with the key "packageManager"
Remove one of these versions to avoid version mismatch errors like ERR_PNPM_BAD_PM_VERSION`);return e}if(!(typeof i=="string"&&i.startsWith("pnpm@"))&&!(s?.packageManager?.name==="pnpm"&&s.packageManager.version))throw n?new Error(`No pnpm version is specified. Remove one of these versions to avoid version mismatch errors like ERR_PNPM_BAD_PM_VERSION`);return e}if(s?.packageManager?.name==="pnpm"&&s.packageManager.version)return s.packageManager.version;if(o)return o;throw n?new Error(`No pnpm version is specified.
Please specify it by one of the following ways: Please specify it by one of the following ways:
- in the GitHub Action config with the key "version" - in the GitHub Action config with the key "version"
- in the package.json with the key "packageManager" - in the package.json with the key "packageManager"
- in the package.json with the key "devEngines.packageManager"`):new Error(`No workspace is found. - in the package.json with the key "devEngines.packageManager"`):new Error(`No workspace is found.
If you've intended to let pnpm/action-setup read preferred pnpm version from the "packageManager" field in the package.json file, If you've intended to let pnpm/action-setup read preferred pnpm version from the "packageManager" field in the package.json file,
please run the actions/checkout before pnpm/action-setup. please run the actions/checkout before pnpm/action-setup.
Otherwise, please specify the pnpm version in the action configuration.`)}function WDe(){return new Promise(t=>{let e=(0,x_.spawn)("node",["--version"],{stdio:["pipe","pipe","pipe"],shell:process.platform==="win32"}),r="";e.stdout.on("data",n=>{r+=n.toString()}),e.on("close",()=>{let n=r.match(/^v(\d+)\.(\d+)/);t(n?{major:parseInt(n[1],10),minor:parseInt(n[2],10)}:{major:0,minor:0})}),e.on("error",()=>t({major:0,minor:0}))})}function T9(t,e,r){return new Promise((n,i)=>{let s=(0,x_.spawn)(t,e,{cwd:r.cwd,env:r.env,stdio:["pipe","inherit","inherit"],shell:process.platform==="win32"});s.on("error",i),s.on("close",n)})}var L9=JDe;async function $De(t){(0,dd.startGroup)("Running self-installer...");let{exitCode:e,binDest:r}=await L9(t);if((0,dd.endGroup)(),e){(0,dd.setFailed)(`Something went wrong, self-installer exits with code ${e}`);return}return r}var F9=$De;var S_=pt(ot());function KDe(t,e){(0,S_.setOutput)("dest",t.dest),(0,S_.setOutput)("bin_dest",e)}var U9=KDe;var HA=pt(ot()),H9=require("child_process");var Og=pt(require("path")),v_=pt(require("process")),q9=t=>Og.default.join(t.dest,"node_modules",".bin"),uB=t=>({...v_.default.env,PATH:Og.default.join(q9(t),"bin")+Og.default.delimiter+q9(t)+Og.default.delimiter+v_.default.env.PATH});function XDe(t){let e=uB(t);for(let r of t.runInstall){let n=["install"];r.recursive&&n.unshift("recursive"),r.args&&n.push(...r.args);let i=["pnpm",...n].join(" ");(0,HA.startGroup)(`Running ${i}...`);let{error:s,status:o}=(0,H9.spawnSync)("pnpm",n,{stdio:"inherit",cwd:r.cwd,shell:!0,env:e});if((0,HA.endGroup)(),s){(0,HA.setFailed)(s);continue}if(o){(0,HA.setFailed)(`Command ${i} (cwd: ${r.cwd}) exits with status ${o}`);continue}}}var z9=XDe;var zA=pt(ot()),j9=require("child_process");function ZDe(t){if(t.runInstall.length===0){console.log("Pruning is unnecessary.");return}(0,zA.startGroup)("Running pnpm store prune...");let{error:e,status:r}=(0,j9.spawnSync)("pnpm",["store","prune"],{stdio:"inherit",shell:!0,env:uB(t)});if((0,zA.endGroup)(),e){(0,zA.warning)(e);return}if(r){(0,zA.warning)(`command pnpm store prune exits with code ${r}`);return}}var G9=ZDe;async function e_e(){let t=P9();(0,fd.getState)("is_post")==="true"?await r_e(t):await t_e(t)}async function t_e(t){(0,fd.saveState)("is_post","true");let e=await F9(t);e!==void 0&&(console.log("Installation Completed!"),U9(t,e),await m4(t),z9(t))}async function r_e(t){G9(t),await C4(t)}e_e().catch(t=>{console.error(t),(0,fd.setFailed)(t)}); Otherwise, please specify the pnpm version in the action configuration.`)}function VLe(t){if(t==="latest-12"||t==="next-12")return!0;let e=(0,xd.validRange)(t);return e!==null&&(0,xd.subset)(e,">=12.0.0 <13.0.0")}function WLe(){return new Promise(t=>{let e=(0,xk.spawn)("node",["--version"],{stdio:["pipe","pipe","pipe"],shell:process.platform==="win32"}),r="";e.stdout.on("data",n=>{r+=n.toString()}),e.on("close",()=>{let n=r.match(/^v(\d+)\.(\d+)/);t(n?{major:parseInt(n[1],10),minor:parseInt(n[2],10)}:{major:0,minor:0})}),e.on("error",()=>t({major:0,minor:0}))})}function NX(t,e,r){return new Promise((n,i)=>{let s=(0,xk.spawn)(t,e,{cwd:r.cwd,env:r.env,stdio:["pipe","inherit","inherit"],shell:process.platform==="win32"});s.on("error",i),s.on("close",n)})}var RX=YLe;async function $Le(t){(0,Sd.startGroup)("Running self-installer...");let{exitCode:e,binDest:r}=await RX(t);if((0,Sd.endGroup)(),e){(0,Sd.setFailed)(`Something went wrong, self-installer exits with code ${e}`);return}return r}var vX=$Le;var Sk=wt(ct());function KLe(t,e){(0,Sk.setOutput)("dest",t.dest),(0,Sk.setOutput)("bin_dest",e)}var DX=KLe;var tc=wt(ct()),_X=require("child_process");function XLe(t){for(let e of t.runInstall){let r=["install"];e.recursive&&r.unshift("recursive"),e.args&&r.push(...e.args);let n=["pnpm",...r].join(" ");(0,tc.startGroup)(`Running ${n}...`);let{error:i,status:s}=(0,_X.spawnSync)("pnpm",r,{stdio:"inherit",cwd:e.cwd,shell:!0});if((0,tc.endGroup)(),i){(0,tc.setFailed)(i);continue}if(s){(0,tc.setFailed)(`Command ${n} (cwd: ${e.cwd}) exits with status ${s}`);continue}}}var kX=XLe;var rc=wt(ct()),PX=require("child_process");function ZLe(t){if(t.runInstall.length===0){console.log("Pruning is unnecessary.");return}(0,rc.startGroup)("Running pnpm store prune...");let{error:e,status:r}=(0,PX.spawnSync)("pnpm",["store","prune"],{stdio:"inherit",shell:!0});if((0,rc.endGroup)(),e){(0,rc.warning)(e);return}if(r){(0,rc.warning)(`command pnpm store prune exits with code ${r}`);return}}var TX=ZLe;async function eMe(){(0,Da.getState)("is_post")==="true"?await rMe():await tMe()}async function tMe(){let t=kK();(0,Da.saveState)("inputs",t),(0,Da.saveState)("is_post","true");let e=await vX(t);e!==void 0&&(console.log("Installation Completed!"),DX(t,e),await h4(t),kX(t))}async function rMe(){let t=JSON.parse((0,Da.getState)("inputs"));TX(t),await E4(t)}eMe().catch(t=>{console.error(t),(0,Da.setFailed)(t)});
/*! Bundled license information: /*! Bundled license information:
undici/lib/fetch/body.js: undici/lib/fetch/body.js:
+4 -1
View File
@@ -4,7 +4,8 @@
"build:bundle": "esbuild src/index.ts --bundle --platform=node --target=node24 --format=cjs --minify --outfile=dist/index.js --loader:.json=json", "build:bundle": "esbuild src/index.ts --bundle --platform=node --target=node24 --format=cjs --minify --outfile=dist/index.js --loader:.json=json",
"build": "pnpm run build:bundle", "build": "pnpm run build:bundle",
"start": "pnpm run build && sh ./run.sh", "start": "pnpm run build && sh ./run.sh",
"update-bootstrap": "node scripts/update-bootstrap.mjs" "update-bootstrap": "node scripts/update-bootstrap.mjs",
"test": "node --experimental-test-module-mocks --test test/*.test.mjs"
}, },
"dependencies": { "dependencies": {
"@actions/cache": "^4.1.0", "@actions/cache": "^4.1.0",
@@ -14,10 +15,12 @@
"@types/expand-tilde": "^2.0.2", "@types/expand-tilde": "^2.0.2",
"@types/node": "^22.0.0", "@types/node": "^22.0.0",
"expand-tilde": "^2.0.2", "expand-tilde": "^2.0.2",
"semver": "^7.8.5",
"yaml": "^2.3.4", "yaml": "^2.3.4",
"zod": "^3.22.4" "zod": "^3.22.4"
}, },
"devDependencies": { "devDependencies": {
"@types/semver": "^7.8.0",
"esbuild": "^0.27.4", "esbuild": "^0.27.4",
"typescript": "^5.3.3" "typescript": "^5.3.3"
} }
+18
View File
@@ -29,6 +29,9 @@ importers:
expand-tilde: expand-tilde:
specifier: ^2.0.2 specifier: ^2.0.2
version: 2.0.2 version: 2.0.2
semver:
specifier: ^7.8.5
version: 7.8.5
yaml: yaml:
specifier: ^2.3.4 specifier: ^2.3.4
version: 2.7.0 version: 2.7.0
@@ -36,6 +39,9 @@ importers:
specifier: ^3.22.4 specifier: ^3.22.4
version: 3.24.1 version: 3.24.1
devDependencies: devDependencies:
'@types/semver':
specifier: ^7.8.0
version: 7.8.0
esbuild: esbuild:
specifier: ^0.27.4 specifier: ^0.27.4
version: 0.27.4 version: 0.27.4
@@ -293,6 +299,9 @@ packages:
'@types/node@22.19.11': '@types/node@22.19.11':
resolution: {integrity: sha512-BH7YwL6rA93ReqeQS1c4bsPpcfOmJasG+Fkr6Y59q83f9M1WcBRHR2vM+P9eOisYRcN3ujQoiZY8uk5W+1WL8w==} resolution: {integrity: sha512-BH7YwL6rA93ReqeQS1c4bsPpcfOmJasG+Fkr6Y59q83f9M1WcBRHR2vM+P9eOisYRcN3ujQoiZY8uk5W+1WL8w==}
'@types/semver@7.8.0':
resolution: {integrity: sha512-1mAINjtQCXXeLkJ9ehXkwOcBpqtLxiVtKhpUf83DdRNdQKV0iXZpaHYqRr7nj+wvxuJzoAmAwXI+sCNMv1CzLQ==}
'@typespec/ts-http-runtime@0.3.0': '@typespec/ts-http-runtime@0.3.0':
resolution: {integrity: sha512-sOx1PKSuFwnIl7z4RN0Ls7N9AQawmR9r66eI5rFCzLDIs8HTIYrIpH9QjYWoX0lkgGrkLxXhi4QnK7MizPRrIg==} resolution: {integrity: sha512-sOx1PKSuFwnIl7z4RN0Ls7N9AQawmR9r66eI5rFCzLDIs8HTIYrIpH9QjYWoX0lkgGrkLxXhi4QnK7MizPRrIg==}
engines: {node: '>=20.0.0'} engines: {node: '>=20.0.0'}
@@ -463,6 +472,11 @@ packages:
resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==} resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==}
hasBin: true hasBin: true
semver@7.8.5:
resolution: {integrity: sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA==}
engines: {node: '>=10'}
hasBin: true
strnum@2.1.1: strnum@2.1.1:
resolution: {integrity: sha512-7ZvoFTiCnGxBtDqJ//Cu6fWtZtc7Y3x+QOirG15wztbdngGSkht27o2pyGWrVy0b4WAy3jbKmnoK6g5VlVNUUw==} resolution: {integrity: sha512-7ZvoFTiCnGxBtDqJ//Cu6fWtZtc7Y3x+QOirG15wztbdngGSkht27o2pyGWrVy0b4WAy3jbKmnoK6g5VlVNUUw==}
@@ -770,6 +784,8 @@ snapshots:
dependencies: dependencies:
undici-types: 6.21.0 undici-types: 6.21.0
'@types/semver@7.8.0': {}
'@typespec/ts-http-runtime@0.3.0': '@typespec/ts-http-runtime@0.3.0':
dependencies: dependencies:
http-proxy-agent: 7.0.2 http-proxy-agent: 7.0.2
@@ -957,6 +973,8 @@ snapshots:
semver@6.3.1: {} semver@6.3.1: {}
semver@7.8.5: {}
strnum@2.1.1: {} strnum@2.1.1: {}
tr46@0.0.3: {} tr46@0.0.3: {}
+14 -14
View File
@@ -1,9 +1,5 @@
#!/usr/bin/env node #!/usr/bin/env node
// Usage: node scripts/update-bootstrap.mjs [version]
// If version is omitted, fetches the latest next-11 tag from npm.
// Regenerates the bootstrap lockfiles used by action-setup to install pnpm via npm.
import { execSync } from 'child_process' import { execSync } from 'child_process'
import { mkdtempSync, rmSync, readFileSync, writeFileSync } from 'fs' import { mkdtempSync, rmSync, readFileSync, writeFileSync } from 'fs'
import { join } from 'path' import { join } from 'path'
@@ -11,21 +7,24 @@ import { tmpdir } from 'os'
const BOOTSTRAP_DIR = new URL('../src/install-pnpm/bootstrap/', import.meta.url).pathname const BOOTSTRAP_DIR = new URL('../src/install-pnpm/bootstrap/', import.meta.url).pathname
const version = process.argv[2] || resolveLatestVersion() const legacyVersion = process.argv[2] || resolveLatestVersion(11)
const nativeVersion = process.argv[3] || resolveLatestVersion(12)
console.log(`Updating bootstrap lockfiles to pnpm@${version} ...`) console.log(`Updating bootstrap lockfiles to pnpm@${legacyVersion} and pnpm@${nativeVersion} ...`)
generateLock('pnpm-lock.json', { pnpm: version }, 'bootstrap-pnpm') generateLock('pnpm-lock.json', { pnpm: legacyVersion }, 'bootstrap-pnpm')
generateLock('exe-lock.json', { '@pnpm/exe': version }, 'bootstrap-exe') generateLock('exe-lock.json', { '@pnpm/exe': legacyVersion }, 'bootstrap-exe')
generateLock('native-lock.json', { pnpm: nativeVersion }, 'bootstrap-native-pnpm')
console.log('Done!') console.log('Done!')
function resolveLatestVersion() { function resolveLatestVersion(major) {
const json = execSync('npm view @pnpm/exe dist-tags --json', { encoding: 'utf8' }) const json = execSync('npm view pnpm dist-tags --json', { encoding: 'utf8' })
const tags = JSON.parse(json) const parsed = JSON.parse(json)
const version = tags['next-11'] || tags['latest'] const tags = Array.isArray(parsed) ? parsed[0] : parsed
const version = tags[`next-${major}`] || tags[`latest-${major}`]
if (!version) { if (!version) {
console.error('Could not determine latest pnpm version from npm dist-tags') console.error(`Could not determine latest pnpm v${major} version from npm dist-tags`)
process.exit(1) process.exit(1)
} }
return version return version
@@ -40,7 +39,8 @@ function generateLock(filename, dependencies, name) {
const parsed = JSON.parse(lock) const parsed = JSON.parse(lock)
parsed.name = name parsed.name = name
writeFileSync(join(BOOTSTRAP_DIR, filename), JSON.stringify(parsed, null, 2) + '\n') writeFileSync(join(BOOTSTRAP_DIR, filename), JSON.stringify(parsed, null, 2) + '\n')
console.log(` ${filename} -> ${Object.values(dependencies)[0]}@${version}`) const [packageName, packageVersion] = Object.entries(dependencies)[0]
console.log(` ${filename} -> ${packageName}@${packageVersion}`)
} finally { } finally {
rmSync(tmp, { recursive: true, force: true }) rmSync(tmp, { recursive: true, force: true })
} }
+11 -2
View File
@@ -18,9 +18,18 @@ export async function runRestoreCache(inputs: Inputs) {
debug(`Primary key is ${primaryKey}`) debug(`Primary key is ${primaryKey}`)
saveState('cache_primary_key', primaryKey) saveState('cache_primary_key', primaryKey)
let cacheKey = await restoreCache([cachePath], primaryKey) // We don't need to download everything again if only one dependency changed
// We can still re-use previous store to cache the rest of the unchanged dependencies
const restoreKeys = [
`pnpm-cache-${process.env.RUNNER_OS}-${os.arch()}-`
];
setOutput('cache-hit', Boolean(cacheKey)) let cacheKey = await restoreCache([cachePath], primaryKey, restoreKeys)
// A restore-key (prefix) match still restores an older store, but "cache-hit"
// must only report an exact primary-key match, so dependency installation
// is not skipped when the lockfile has changed.
setOutput('cache-hit', cacheKey === primaryKey)
if (!cacheKey) { if (!cacheKey) {
info(`Cache is not found`) info(`Cache is not found`)
+12
View File
@@ -1,5 +1,6 @@
import { saveCache } from '@actions/cache' import { saveCache } from '@actions/cache'
import { getState, info } from '@actions/core' import { getState, info } from '@actions/core'
import { access } from 'fs/promises'
export async function runSaveCache() { export async function runSaveCache() {
const state = getState('cache_restored_key') const state = getState('cache_restored_key')
@@ -11,6 +12,17 @@ export async function runSaveCache() {
return return
} }
try {
await access(cachePath)
} catch (error) {
if (!(error instanceof Error)) throw error
if (!('code' in error)) throw error
if (error.code !== 'ENOENT') throw error
info(`Cache path ${cachePath} does not exist, not saving cache.`)
return
}
const cacheId = await saveCache([cachePath], primaryKey) const cacheId = await saveCache([cachePath], primaryKey)
if (cacheId == -1) return if (cacheId == -1) return
+7 -6
View File
@@ -8,16 +8,16 @@ import pnpmInstall from './pnpm-install'
import pruneStore from './pnpm-store-prune' import pruneStore from './pnpm-store-prune'
async function main() { async function main() {
const inputs = getInputs()
if (getState('is_post') === 'true') { if (getState('is_post') === 'true') {
await runPost(inputs) await runPost()
} else { } else {
await runMain(inputs) await runMain()
} }
} }
async function runMain(inputs: Inputs) { async function runMain() {
const inputs = getInputs()
saveState('inputs', inputs)
saveState('is_post', 'true') saveState('is_post', 'true')
const binDest = await installPnpm(inputs) const binDest = await installPnpm(inputs)
@@ -30,7 +30,8 @@ async function runMain(inputs: Inputs) {
pnpmInstall(inputs) pnpmInstall(inputs)
} }
async function runPost(inputs: Inputs) { async function runPost() {
const inputs = JSON.parse(getState('inputs')) as Inputs
pruneStore(inputs) pruneStore(inputs)
await saveCache(inputs) await saveCache(inputs)
} }
+29 -66
View File
@@ -5,18 +5,18 @@
"packages": { "packages": {
"": { "": {
"dependencies": { "dependencies": {
"@pnpm/exe": "11.0.4" "@pnpm/exe": "11.28.10"
} }
}, },
"node_modules/@pnpm/exe": { "node_modules/@pnpm/exe": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/exe/-/exe-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/exe/-/exe-11.28.10.tgz",
"integrity": "sha512-3OwYqbbj1KtuUqoMo5OEkY8nU/WutZ7L5ADFl0bbW9oyqU55U37aDqA3NJNSk28CyszNARfrjerAF2DW2TsV7w==", "integrity": "sha512-prIiCu3BBaIlim+JD6x2VnqCAp4Er4CevPhrIhOnXK7TRVjhNeULBEv9F7E5ZmEtseR2G+foubhcMZmM6eEqqg==",
"hasInstallScript": true, "hasInstallScript": true,
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@reflink/reflink": "0.1.19", "@reflink/reflink": "0.1.19",
"detect-libc": "^2.0.3" "detect-libc": "^2.1.2"
}, },
"bin": { "bin": {
"pn": "pn", "pn": "pn",
@@ -28,20 +28,18 @@
"url": "https://opencollective.com/pnpm" "url": "https://opencollective.com/pnpm"
}, },
"optionalDependencies": { "optionalDependencies": {
"@pnpm/linux-arm64": "11.0.4", "@pnpm/linux-arm64": "11.28.10",
"@pnpm/linux-x64": "11.0.4", "@pnpm/linux-x64": "11.28.10",
"@pnpm/linuxstatic-arm64": "11.0.4", "@pnpm/linuxstatic-x64": "11.28.10",
"@pnpm/linuxstatic-x64": "11.0.4", "@pnpm/macos-arm64": "11.28.10",
"@pnpm/macos-arm64": "11.0.4", "@pnpm/win-arm64": "11.28.10",
"@pnpm/macos-x64": "11.0.4", "@pnpm/win-x64": "11.28.10"
"@pnpm/win-arm64": "11.0.4",
"@pnpm/win-x64": "11.0.4"
} }
}, },
"node_modules/@pnpm/linux-arm64": { "node_modules/@pnpm/linux-arm64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/linux-arm64/-/linux-arm64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/linux-arm64/-/linux-arm64-11.28.10.tgz",
"integrity": "sha512-Bz7V2sFypoGHX/t5w/w7jnCw5DCK3C8s5q8whHJJ3iS5kRznX3Q1F4LwSjjy+lsi777fHyNIvD7qtNmdt9IKoA==", "integrity": "sha512-gtNgBYw2s0MLOU980IlqFqvc90iL9y7W6VIRQB8wydgbgeoIU1G0qUOWBRIKB57xDgVuFp7gnTWdwQ2lF2sU1Q==",
"cpu": [ "cpu": [
"arm64" "arm64"
], ],
@@ -55,9 +53,9 @@
} }
}, },
"node_modules/@pnpm/linux-x64": { "node_modules/@pnpm/linux-x64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/linux-x64/-/linux-x64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/linux-x64/-/linux-x64-11.28.10.tgz",
"integrity": "sha512-u0Yn1gytR1vKdPk6fYF500H8ZWQlj0cTuIQPp+5GYVPkMmA5bSw41RNIDPBfjDlE8ERmQWaQcrgmTcmTZ+n22A==", "integrity": "sha512-PCJF+0FwwHBOR7oBp3ySjvk7m1LQUhTN2xfLk3e+v0h036PgY9Z2Ldtu+l4xIYZoI6eEwBSQFXGLxslWrcZ5jg==",
"cpu": [ "cpu": [
"x64" "x64"
], ],
@@ -70,29 +68,10 @@
"url": "https://opencollective.com/pnpm" "url": "https://opencollective.com/pnpm"
} }
}, },
"node_modules/@pnpm/linuxstatic-arm64": {
"version": "11.0.4",
"resolved": "https://registry.npmjs.org/@pnpm/linuxstatic-arm64/-/linuxstatic-arm64-11.0.4.tgz",
"integrity": "sha512-0aitEcfhWNXNZhfJGt/kJaRvfcdtJzXZpV+toJN94kfawSJnhuawfnUSXMi/3m0G97HkJc7BH8rOz3sojUKt0g==",
"cpu": [
"arm64"
],
"libc": [
"musl"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
],
"funding": {
"url": "https://opencollective.com/pnpm"
}
},
"node_modules/@pnpm/linuxstatic-x64": { "node_modules/@pnpm/linuxstatic-x64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/linuxstatic-x64/-/linuxstatic-x64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/linuxstatic-x64/-/linuxstatic-x64-11.28.10.tgz",
"integrity": "sha512-xDJdeJ7D2YvDBy2/IH9lEqMKiSuZiV8190XKWOgQgxUGGeuW4z3j6Ewpl0S5bXsWuNjAgC+uCKp7Qp3P7cXAvw==", "integrity": "sha512-kkcKBNPEx/xyW97inm4pEs6VkuY6Cy7w6gWaCVbv8qVmyqsyF4yFXJwUG7VxqmCnwVhSb2x/122S9UZumQns4A==",
"cpu": [ "cpu": [
"x64" "x64"
], ],
@@ -109,9 +88,9 @@
} }
}, },
"node_modules/@pnpm/macos-arm64": { "node_modules/@pnpm/macos-arm64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/macos-arm64/-/macos-arm64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/macos-arm64/-/macos-arm64-11.28.10.tgz",
"integrity": "sha512-dNR69jUARtGFuyyLE9VuyxhRUKC8MO/7/xIyAdeIMZAD5ej0Y/Ct0DYCa/FLbgFL1nXaXmp4+gRMfJBkkrKfQQ==", "integrity": "sha512-eT/HzSBZHjZk2xb+XmTbLIPPSMeHzK8xov4mD9oQWwfplYBTU5P21yoJp6GNFLql1IXAoSaFeTv6EZ2DwBj/Eg==",
"cpu": [ "cpu": [
"arm64" "arm64"
], ],
@@ -124,26 +103,10 @@
"url": "https://opencollective.com/pnpm" "url": "https://opencollective.com/pnpm"
} }
}, },
"node_modules/@pnpm/macos-x64": {
"version": "11.0.4",
"resolved": "https://registry.npmjs.org/@pnpm/macos-x64/-/macos-x64-11.0.4.tgz",
"integrity": "sha512-RfyrxSBajeEU16dZsgFjbdagDV9F4HNCJfbBgm8IbGjL0+J95naM/VmCDLd6S3+1tISeI2MxtcyCxqjKJsD/BA==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"darwin"
],
"funding": {
"url": "https://opencollective.com/pnpm"
}
},
"node_modules/@pnpm/win-arm64": { "node_modules/@pnpm/win-arm64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/win-arm64/-/win-arm64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/win-arm64/-/win-arm64-11.28.10.tgz",
"integrity": "sha512-fOQEv8b9KxZlUAxPPXSQQUUIrt2nY24Qwd4RzCPpatacBnsE4JIadlr/B4V5z2zFxmV7FdHr7nYUhv2RqTlY/w==", "integrity": "sha512-UFeYraIlLHNUBgMarcAX/jK3PR2iWfI4SJL8fucVWNHivdyXNQYLmUhf+8a6MPdh4Sr0/2W/h6LqzVdjnpPx6g==",
"cpu": [ "cpu": [
"arm64" "arm64"
], ],
@@ -157,9 +120,9 @@
} }
}, },
"node_modules/@pnpm/win-x64": { "node_modules/@pnpm/win-x64": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/@pnpm/win-x64/-/win-x64-11.0.4.tgz", "resolved": "https://registry.npmjs.org/@pnpm/win-x64/-/win-x64-11.28.10.tgz",
"integrity": "sha512-pErHAV8m3NZuPSeCmH3senTSHX0nwkH5lLzQSpiFuyt08hq8sqL3jDymT4ri9N7ixPN9RFZghZIiT3h+Croaew==", "integrity": "sha512-1Do1wLHqiLVQac53DqRtqz0h5UCetoI1oaUZJ62L2wDW4sfe/MBs427rwyaiGZzYLps8glsD1aZXT5uAv1zx8A==",
"cpu": [ "cpu": [
"x64" "x64"
], ],
+247
View File
@@ -0,0 +1,247 @@
{
"name": "bootstrap-native-pnpm",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"dependencies": {
"pnpm": "12.17.0"
}
},
"node_modules/@pnpm/exe.android-arm64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.android-arm64/-/exe.android-arm64-12.17.0.tgz",
"integrity": "sha512-gwu/F5YyoJp1bIbrIBl7B8JO3rkjkGlKikwQg9s0aVa5xWaBYIqPX+ZJqQ7I4D1YfbdI/Omfze0+6vnYiWHG6A==",
"cpu": [
"arm64"
],
"license": "MIT",
"optional": true,
"os": [
"android"
]
},
"node_modules/@pnpm/exe.android-x64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.android-x64/-/exe.android-x64-12.17.0.tgz",
"integrity": "sha512-qUNhCvWyeBrUByNWkqqQ3Koy1gIAQ8UV5HDHXxoo5NUWVTde0Ld2BxweNwWJw8CNKpqEGceCUdjZ506JYpTjJg==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"android"
]
},
"node_modules/@pnpm/exe.darwin-arm64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.darwin-arm64/-/exe.darwin-arm64-12.17.0.tgz",
"integrity": "sha512-0nkEqRLIbrm7dWl+p2EPpmyNKyM0bbdPEovdtMhHYbhkO+Vls38S+6emkx8kSTAr75BNXYXkCl4RtGinGG4Erg==",
"cpu": [
"arm64"
],
"license": "MIT",
"optional": true,
"os": [
"darwin"
]
},
"node_modules/@pnpm/exe.darwin-x64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.darwin-x64/-/exe.darwin-x64-12.17.0.tgz",
"integrity": "sha512-w89cboNi4KCzmt/dSKrE4ijVNKICKiZsE9TcIWf77Tz+VpoDfuhPSmWPZK+iCHBvlI/9dIN+M3HiPPVsFnAx4Q==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"darwin"
]
},
"node_modules/@pnpm/exe.freebsd-x64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.freebsd-x64/-/exe.freebsd-x64-12.17.0.tgz",
"integrity": "sha512-DJ0FOaUDXc71icSgiuBFEvqReqoSiS/rmnC6kltoiC3MzPyw3awcGbT/7FnnYzi/ziuoTC7v6vfBh0Vzv7VKOQ==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"freebsd"
]
},
"node_modules/@pnpm/exe.linux-arm64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-arm64/-/exe.linux-arm64-12.17.0.tgz",
"integrity": "sha512-Cj2nIzWTVm6ZuhQHqL9SiJ11scBnEGxJyNg7tYQPzh9fVF5UVRkv+LbyfwdftnAtJerK/7HDpK/55WeQqp8OkA==",
"cpu": [
"arm64"
],
"libc": [
"glibc"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-arm64-musl": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-arm64-musl/-/exe.linux-arm64-musl-12.17.0.tgz",
"integrity": "sha512-w5ZwZ4j8S804DGhMYlLLpc+G3Kkc+5GlDO++LLvO/nDIXBTHRhdxPfQBQU08q31k0JYfp3wXCQk0Y7DnsuVF6w==",
"cpu": [
"arm64"
],
"libc": [
"musl"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-ppc64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-ppc64/-/exe.linux-ppc64-12.17.0.tgz",
"integrity": "sha512-Gb//Wm15fXl+qWcxjNQmwlYDjGiJOnLU/A9uRZYmtkyZie2Yx8AHI6XkUIJioQz99TwVDKQ87ywD5Jtk8zcgyg==",
"cpu": [
"ppc64"
],
"libc": [
"glibc"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-riscv64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-riscv64/-/exe.linux-riscv64-12.17.0.tgz",
"integrity": "sha512-+kItEcFjdVZEDzODsc7icb8cB+3AouCrEzOCezzxLITRhw86m9t3J/qyPdcFELBjeMnS+IXV8sJaSCQcpSqfgA==",
"cpu": [
"riscv64"
],
"libc": [
"glibc"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-s390x": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-s390x/-/exe.linux-s390x-12.17.0.tgz",
"integrity": "sha512-jf5ghD2uDeknWQgK/EsCFNwlyL7BYLWfXe687g5UMVFclPLt524CREZ8Yl5hf4u7p3evCIPBN/m5I1QXUmJpHw==",
"cpu": [
"s390x"
],
"libc": [
"glibc"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-x64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-x64/-/exe.linux-x64-12.17.0.tgz",
"integrity": "sha512-vQAusDzMofc/Ee4KOUYjE6FWeHOlMGQyvhR7W39QSamVeJWS16co/n+bhjdjwjI3UFh8IWOpamvTS+b4lvQUog==",
"cpu": [
"x64"
],
"libc": [
"glibc"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.linux-x64-musl": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.linux-x64-musl/-/exe.linux-x64-musl-12.17.0.tgz",
"integrity": "sha512-JGxrGSxkDkqRAUD49T9dOnKyJkQ3bWBeHnYH4o4mvj09R9eUzhWFi8oa6WPNyCO0/7/Max2gsSfgXOHj3QW7ug==",
"cpu": [
"x64"
],
"libc": [
"musl"
],
"license": "MIT",
"optional": true,
"os": [
"linux"
]
},
"node_modules/@pnpm/exe.win32-arm64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.win32-arm64/-/exe.win32-arm64-12.17.0.tgz",
"integrity": "sha512-qDQh8rmyK5sxlaCSCADcmPrvytJabMCbxtJ0nCitzRo2j3/8BhzLjlOcWF3C6iPGhR5CbIb+btNy+VCVhd06mQ==",
"cpu": [
"arm64"
],
"license": "MIT",
"optional": true,
"os": [
"win32"
]
},
"node_modules/@pnpm/exe.win32-x64": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/@pnpm/exe.win32-x64/-/exe.win32-x64-12.17.0.tgz",
"integrity": "sha512-qCo1OQlE3WrFZIAUK0O5EoupLaQ1fST7zNX8Qd+Tc4ojWgCvYA/ze0uP9hox8mSFC/JPAGRSG5o8gUBSq2rRxw==",
"cpu": [
"x64"
],
"license": "MIT",
"optional": true,
"os": [
"win32"
]
},
"node_modules/pnpm": {
"version": "12.17.0",
"resolved": "https://registry.npmjs.org/pnpm/-/pnpm-12.17.0.tgz",
"integrity": "sha512-uNIj6+wEtYContIG2qcdG8y2oe4dUu+pXMOw23UnFWHfjw2OLEOt05xewIAYr3qKlRCOcJD5Win4hye3pA/VPQ==",
"hasInstallScript": true,
"license": "MIT",
"bin": {
"pn": "pn",
"pnpm": "pnpm",
"pnpx": "pnpx",
"pnx": "pnx"
},
"engines": {
"node": ">=18"
},
"optionalDependencies": {
"@pnpm/exe.android-arm64": "12.17.0",
"@pnpm/exe.android-x64": "12.17.0",
"@pnpm/exe.darwin-arm64": "12.17.0",
"@pnpm/exe.darwin-x64": "12.17.0",
"@pnpm/exe.freebsd-x64": "12.17.0",
"@pnpm/exe.linux-arm64": "12.17.0",
"@pnpm/exe.linux-arm64-musl": "12.17.0",
"@pnpm/exe.linux-ppc64": "12.17.0",
"@pnpm/exe.linux-riscv64": "12.17.0",
"@pnpm/exe.linux-s390x": "12.17.0",
"@pnpm/exe.linux-x64": "12.17.0",
"@pnpm/exe.linux-x64-musl": "12.17.0",
"@pnpm/exe.win32-arm64": "12.17.0",
"@pnpm/exe.win32-x64": "12.17.0"
}
}
}
}
+4 -4
View File
@@ -5,13 +5,13 @@
"packages": { "packages": {
"": { "": {
"dependencies": { "dependencies": {
"pnpm": "11.0.4" "pnpm": "11.28.10"
} }
}, },
"node_modules/pnpm": { "node_modules/pnpm": {
"version": "11.0.4", "version": "11.28.10",
"resolved": "https://registry.npmjs.org/pnpm/-/pnpm-11.0.4.tgz", "resolved": "https://registry.npmjs.org/pnpm/-/pnpm-11.28.10.tgz",
"integrity": "sha512-CjlxZQB6AU7VKRmmHl9GxIubyohATDA+yuzGP2Le9WOJjTxril1epYEes5jP4DqwXaGlzpY/Em1erUwC+TuDww==", "integrity": "sha512-ZyIW8G4VwQm4VHHUnT++0X5vA+rSWN8Iwr9bSlwzMh6/v1lHa86BMl762has4Kx4VI/Qv816UTaek5GCo91Q5A==",
"license": "MIT", "license": "MIT",
"bin": { "bin": {
"pn": "bin/pnpm.mjs", "pn": "bin/pnpm.mjs",
+86 -47
View File
@@ -6,11 +6,28 @@ import path from 'path'
import util from 'util' import util from 'util'
import { Inputs } from '../inputs' import { Inputs } from '../inputs'
import { parse as parseYaml } from 'yaml' import { parse as parseYaml } from 'yaml'
import { satisfies, subset, validRange } from 'semver'
import pnpmLock from './bootstrap/pnpm-lock.json' import pnpmLock from './bootstrap/pnpm-lock.json'
import exeLock from './bootstrap/exe-lock.json' import exeLock from './bootstrap/exe-lock.json'
import nativeLock from './bootstrap/native-lock.json'
const BOOTSTRAP_PNPM_PACKAGE_JSON = JSON.stringify({ private: true, dependencies: { pnpm: pnpmLock.packages['node_modules/pnpm'].version } }) const bootstrapPnpmVersion = pnpmLock.packages['node_modules/pnpm'].version
const BOOTSTRAP_EXE_PACKAGE_JSON = JSON.stringify({ private: true, dependencies: { '@pnpm/exe': exeLock.packages['node_modules/@pnpm/exe'].version } }) const bootstrapExeVersion = exeLock.packages['node_modules/@pnpm/exe'].version
const bootstrapNativeVersion = nativeLock.packages['node_modules/pnpm'].version
const BOOTSTRAP_PNPM_PACKAGE_JSON = JSON.stringify({
private: true,
dependencies: { pnpm: bootstrapPnpmVersion },
})
const BOOTSTRAP_EXE_PACKAGE_JSON = JSON.stringify({
private: true,
dependencies: { '@pnpm/exe': bootstrapExeVersion },
allowScripts: { [`@pnpm/exe@${bootstrapExeVersion}`]: true },
})
const BOOTSTRAP_NATIVE_PACKAGE_JSON = JSON.stringify({
private: true,
dependencies: { pnpm: bootstrapNativeVersion },
allowScripts: { [`pnpm@${bootstrapNativeVersion}`]: true },
})
export interface SelfInstallerResult { export interface SelfInstallerResult {
exitCode: number exitCode: number
@@ -19,18 +36,20 @@ export interface SelfInstallerResult {
export async function runSelfInstaller(inputs: Inputs): Promise<SelfInstallerResult> { export async function runSelfInstaller(inputs: Inputs): Promise<SelfInstallerResult> {
const { version, dest, packageJsonFile } = inputs const { version, dest, packageJsonFile } = inputs
const targetVersion = readTargetVersion({ version, packageJsonFile })
// pnpm v11 requires Node >= 22.13; use standalone (exe) bootstrap which const native = targetsPnpm12(targetVersion)
// bundles its own Node.js when the system Node is too old let standalone = false
const systemNode = await getSystemNodeVersion() if (!native) {
const standalone = inputs.standalone || systemNode.major < 22 || (systemNode.major === 22 && systemNode.minor < 13) const systemNode = await getSystemNodeVersion()
standalone = inputs.standalone || systemNode.major < 22 || (systemNode.major === 22 && systemNode.minor < 13)
}
// Install bootstrap pnpm via npm (integrity verified by committed lockfile) // Install bootstrap pnpm via npm (integrity verified by committed lockfile)
await rm(dest, { recursive: true, force: true }) await rm(dest, { recursive: true, force: true })
await mkdir(dest, { recursive: true }) await mkdir(dest, { recursive: true })
const lockfile = standalone ? exeLock : pnpmLock const lockfile = native ? nativeLock : standalone ? exeLock : pnpmLock
const packageJson = standalone ? BOOTSTRAP_EXE_PACKAGE_JSON : BOOTSTRAP_PNPM_PACKAGE_JSON const packageJson = native ? BOOTSTRAP_NATIVE_PACKAGE_JSON : standalone ? BOOTSTRAP_EXE_PACKAGE_JSON : BOOTSTRAP_PNPM_PACKAGE_JSON
await writeFile(path.join(dest, 'package.json'), packageJson) await writeFile(path.join(dest, 'package.json'), packageJson)
await writeFile(path.join(dest, 'package-lock.json'), JSON.stringify(lockfile)) await writeFile(path.join(dest, 'package-lock.json'), JSON.stringify(lockfile))
@@ -53,9 +72,6 @@ export async function runSelfInstaller(inputs: Inputs): Promise<SelfInstallerRes
return { exitCode: npmExitCode, binDest: path.join(dest, 'node_modules', '.bin') } return { exitCode: npmExitCode, binDest: path.join(dest, 'node_modules', '.bin') }
} }
// On Windows with standalone mode, npm's .bin shims can't properly
// execute the extensionless @pnpm/exe native binaries. Add the
// @pnpm/exe directory directly to PATH so pnpm.exe is found natively.
const pnpmHome = standalone && process.platform === 'win32' const pnpmHome = standalone && process.platform === 'win32'
? path.join(dest, 'node_modules', '@pnpm', 'exe') ? path.join(dest, 'node_modules', '@pnpm', 'exe')
: path.join(dest, 'node_modules', '.bin') : path.join(dest, 'node_modules', '.bin')
@@ -73,43 +89,48 @@ export async function runSelfInstaller(inputs: Inputs): Promise<SelfInstallerRes
const pnpmBinLink = path.join(dest, 'node_modules', '.bin', 'pnpm') const pnpmBinLink = path.join(dest, 'node_modules', '.bin', 'pnpm')
if (!existsSync(pnpmBinLink)) { if (!existsSync(pnpmBinLink)) {
await mkdir(path.join(dest, 'node_modules', '.bin'), { recursive: true }) await mkdir(path.join(dest, 'node_modules', '.bin'), { recursive: true })
const target = standalone const target = native
? path.join('..', '@pnpm', 'exe', 'pnpm') ? path.join('..', 'pnpm', 'pnpm')
: path.join('..', 'pnpm', 'bin', 'pnpm.mjs') : standalone
? path.join('..', '@pnpm', 'exe', 'pnpm')
: path.join('..', 'pnpm', 'bin', 'pnpm.mjs')
await symlink(target, pnpmBinLink) await symlink(target, pnpmBinLink)
} }
} }
const bootstrapPnpm = standalone const bootstrapPnpm = native
? path.join(dest, 'node_modules', '@pnpm', 'exe', process.platform === 'win32' ? 'pnpm.exe' : 'pnpm') ? path.join(dest, 'node_modules', 'pnpm', process.platform === 'win32' ? 'pnpm.exe' : 'pnpm')
: path.join(dest, 'node_modules', 'pnpm', 'bin', 'pnpm.mjs') : standalone
? path.join(dest, 'node_modules', '@pnpm', 'exe', process.platform === 'win32' ? 'pnpm.exe' : 'pnpm')
: path.join(dest, 'node_modules', 'pnpm', 'bin', 'pnpm.mjs')
const bootstrapVersion = native ? bootstrapNativeVersion : standalone ? bootstrapExeVersion : bootstrapPnpmVersion
// Determine the target version if (targetVersion === bootstrapVersion || (native && satisfies(bootstrapVersion, targetVersion))) {
const targetVersion = readTargetVersion({ version, packageJsonFile }) return { exitCode: 0, binDest: pnpmHome }
if (targetVersion) {
const cmd = standalone ? bootstrapPnpm : process.execPath
const args = standalone ? ['self-update', targetVersion] : [bootstrapPnpm, 'self-update', targetVersion]
const exitCode = await runCommand(cmd, args, { cwd: dest })
if (exitCode !== 0) {
return { exitCode, binDest: pnpmHome }
}
// self-update writes the target pnpm/pnpx into PNPM_HOME/bin, leaving
// the bootstrap symlinks in pnpmHome pointing at the old version. Use
// PNPM_HOME/bin so consumers of the bin_dest output (e.g.
// `${steps.pnpm.outputs.bin_dest}/pnpm`) invoke the requested version.
return { exitCode: 0, binDest: path.join(pnpmHome, 'bin') }
} }
// No explicit target version: rely on the bootstrap pnpm to switch to const cmd = native || standalone ? bootstrapPnpm : process.execPath
// the version declared in packageManager/devEngines at runtime. const args = native || standalone ? ['self-update', targetVersion] : [bootstrapPnpm, 'self-update', targetVersion]
return { exitCode: 0, binDest: pnpmHome } const exitCode = await runCommand(cmd, args, { cwd: dest })
if (exitCode !== 0) {
return { exitCode, binDest: pnpmHome }
}
// self-update writes the target pnpm/pnpx into PNPM_HOME/bin, leaving
// the bootstrap symlinks in pnpmHome pointing at the old version. Use
// PNPM_HOME/bin so consumers of the bin_dest output (e.g.
// `${steps.pnpm.outputs.bin_dest}/pnpm`) invoke the requested version.
//
// When the requested version resolves to the bootstrap version, self-update
// is a no-op and PNPM_HOME/bin is not created — fall back to pnpmHome,
// whose symlinks already point at the right version.
const updatedBinDir = path.join(pnpmHome, 'bin')
return { exitCode: 0, binDest: existsSync(updatedBinDir) ? updatedBinDir : pnpmHome }
} }
function readTargetVersion(opts: { function readTargetVersion(opts: {
readonly version?: string | undefined readonly version?: string | undefined
readonly packageJsonFile: string readonly packageJsonFile: string
}): string | undefined { }): string {
const { version, packageJsonFile } = opts const { version, packageJsonFile } = opts
const { GITHUB_WORKSPACE } = process.env const { GITHUB_WORKSPACE } = process.env
@@ -130,12 +151,15 @@ function readTargetVersion(opts: {
} }
} }
// packageManager is always exact `pnpm@<version>[+<integrity>]` per spec.
// Strip the integrity hash for self-update.
const packageManagerVersion =
typeof packageManager === 'string' && packageManager.startsWith('pnpm@')
? packageManager.slice('pnpm@'.length).split('+')[0]
: undefined
if (version) { if (version) {
if ( if (packageManagerVersion && packageManagerVersion !== version) {
typeof packageManager === 'string' &&
packageManager.startsWith('pnpm@') &&
packageManager.replace('pnpm@', '') !== version
) {
throw new Error(`Multiple versions of pnpm specified: throw new Error(`Multiple versions of pnpm specified:
- version ${version} in the GitHub Action config with the key "version" - version ${version} in the GitHub Action config with the key "version"
- version ${packageManager} in the package.json with the key "packageManager" - version ${packageManager} in the package.json with the key "packageManager"
@@ -145,13 +169,22 @@ Remove one of these versions to avoid version mismatch errors like ERR_PNPM_BAD_
return version return version
} }
// pnpm will automatically download and switch to the right version // Self-update the bootstrap pnpm to the version pinned in package.json so
if (typeof packageManager === 'string' && packageManager.startsWith('pnpm@')) { // PATH-resolved `pnpm` (and the bin_dest output) reflect the target
return undefined // version. Without this, `pnpm store path` runs as the bootstrap and
// reports a different STORE_VERSION than the one the user's actual
// install writes to — breaking cache: true and actions/setup-node's
// `cache: pnpm` on cold caches (issue #233).
//
// devEngines.packageManager takes priority over packageManager, matching
// pnpm's getWantedPackageManager logic. `pnpm self-update` accepts both
// exact versions and semver ranges, so we pass either through directly.
if (devEngines?.packageManager?.name === 'pnpm' && devEngines.packageManager.version) {
return devEngines.packageManager.version
} }
if (devEngines?.packageManager?.name === 'pnpm' && devEngines.packageManager.version) { if (packageManagerVersion) {
return undefined return packageManagerVersion
} }
if (!GITHUB_WORKSPACE) { if (!GITHUB_WORKSPACE) {
@@ -168,6 +201,12 @@ Please specify it by one of the following ways:
- in the package.json with the key "devEngines.packageManager"`) - in the package.json with the key "devEngines.packageManager"`)
} }
function targetsPnpm12(version: string): boolean {
if (version === 'latest-12' || version === 'next-12') return true
const range = validRange(version)
return range !== null && subset(range, '>=12.0.0 <13.0.0')
}
function getSystemNodeVersion(): Promise<{ major: number; minor: number }> { function getSystemNodeVersion(): Promise<{ major: number; minor: number }> {
return new Promise((resolve) => { return new Promise((resolve) => {
const cp = spawn('node', ['--version'], { stdio: ['pipe', 'pipe', 'pipe'], shell: process.platform === 'win32' }) const cp = spawn('node', ['--version'], { stdio: ['pipe', 'pipe', 'pipe'], shell: process.platform === 'win32' })
+6 -4
View File
@@ -1,11 +1,8 @@
import { setFailed, startGroup, endGroup } from '@actions/core' import { setFailed, startGroup, endGroup } from '@actions/core'
import { spawnSync } from 'child_process' import { spawnSync } from 'child_process'
import { Inputs } from '../inputs' import { Inputs } from '../inputs'
import { patchPnpmEnv } from '../utils'
export function runPnpmInstall(inputs: Inputs) { export function runPnpmInstall(inputs: Inputs) {
const env = patchPnpmEnv(inputs)
for (const options of inputs.runInstall) { for (const options of inputs.runInstall) {
const args = ['install'] const args = ['install']
if (options.recursive) args.unshift('recursive') if (options.recursive) args.unshift('recursive')
@@ -14,11 +11,16 @@ export function runPnpmInstall(inputs: Inputs) {
const cmdStr = ['pnpm', ...args].join(' ') const cmdStr = ['pnpm', ...args].join(' ')
startGroup(`Running ${cmdStr}...`) startGroup(`Running ${cmdStr}...`)
// spawnSync inherits process.env, which already has $PNPM_HOME/bin and
// $PNPM_HOME prepended via addPath() in install-pnpm. Do NOT pass a
// hand-patched env that adds node_modules/.bin to the front — on
// Windows standalone, .bin/pnpm.cmd is an npm shim pointing at the
// BOOTSTRAP pnpm, which would shadow the self-updated one and break
// newer-pnpm-only behavior.
const { error, status } = spawnSync('pnpm', args, { const { error, status } = spawnSync('pnpm', args, {
stdio: 'inherit', stdio: 'inherit',
cwd: options.cwd, cwd: options.cwd,
shell: true, shell: true,
env,
}) })
endGroup() endGroup()
+2 -2
View File
@@ -1,7 +1,6 @@
import { warning, startGroup, endGroup } from '@actions/core' import { warning, startGroup, endGroup } from '@actions/core'
import { spawnSync } from 'child_process' import { spawnSync } from 'child_process'
import { Inputs } from '../inputs' import { Inputs } from '../inputs'
import { patchPnpmEnv } from '../utils'
export function pruneStore(inputs: Inputs) { export function pruneStore(inputs: Inputs) {
if (inputs.runInstall.length === 0) { if (inputs.runInstall.length === 0) {
@@ -10,10 +9,11 @@ export function pruneStore(inputs: Inputs) {
} }
startGroup('Running pnpm store prune...') startGroup('Running pnpm store prune...')
// spawnSync inherits process.env (which has the right PATH from addPath
// in install-pnpm). See pnpm-install/index.ts for the rationale.
const { error, status } = spawnSync('pnpm', ['store', 'prune'], { const { error, status } = spawnSync('pnpm', ['store', 'prune'], {
stdio: 'inherit', stdio: 'inherit',
shell: true, shell: true,
env: patchPnpmEnv(inputs),
}) })
endGroup() endGroup()
-10
View File
@@ -1,10 +0,0 @@
import path from 'path'
import process from 'process'
import { Inputs } from '../inputs'
export const getBinDest = (inputs: Inputs): string => path.join(inputs.dest, 'node_modules', '.bin')
export const patchPnpmEnv = (inputs: Inputs): NodeJS.ProcessEnv => ({
...process.env,
PATH: path.join(getBinDest(inputs), 'bin') + path.delimiter + getBinDest(inputs) + path.delimiter + process.env.PATH,
})
+47
View File
@@ -0,0 +1,47 @@
import assert from 'node:assert/strict'
import { mkdtemp, rm, access } from 'node:fs/promises'
import { tmpdir } from 'node:os'
import { join } from 'node:path'
import { after, beforeEach, mock, test } from 'node:test'
const directory = await mkdtemp(join(tmpdir(), 'pnpm-cache-save-'))
after(() => rm(directory, { recursive: true, force: true }))
let state
let checkAccess
const saveCache = mock.fn(async () => 1)
mock.module('@actions/cache', { namedExports: { saveCache } })
mock.module('@actions/core', {
namedExports: { getState: name => state[name], info: () => {} },
})
mock.module('fs/promises', { namedExports: { access: path => checkAccess(path) } })
const { runSaveCache } = await import('../src/cache-save/run.ts')
beforeEach(() => {
state = { cache_restored_key: 'old', cache_primary_key: 'new', cache_path: directory }
checkAccess = access
saveCache.mock.resetCalls()
})
test('skips saving a missing directory', async () => {
state.cache_path = join(directory, 'missing')
await runSaveCache()
assert.equal(saveCache.mock.callCount(), 0)
})
test('saves an existing directory with the primary key', async () => {
await runSaveCache()
assert.deepEqual(saveCache.mock.calls[0].arguments, [[directory], 'new'])
})
test('skips saving a primary-key cache hit', async () => {
state.cache_restored_key = 'new'
await runSaveCache()
assert.equal(saveCache.mock.callCount(), 0)
})
test('propagates unexpected filesystem errors', async () => {
const error = Object.assign(new Error('access denied'), { code: 'EACCES' })
checkAccess = async () => { throw error }
await assert.rejects(runSaveCache(), error)
assert.equal(saveCache.mock.callCount(), 0)
})