@stablyai/playwright-test 2.0.13 → 2.0.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{index-DVywK-2d.cjs → index-Covr1y-4.cjs} +1564 -1401
- package/dist/index-Covr1y-4.cjs.map +1 -0
- package/dist/{index-q6hgdCVS.mjs → index-Tn_eFdjz.mjs} +1565 -1402
- package/dist/index-Tn_eFdjz.mjs.map +1 -0
- package/dist/index.cjs +2 -2
- package/dist/{index.d-DaMmBaG3.d.cts → index.d-BjGuH5NO.d.cts} +9 -1
- package/dist/{index.d-DaMmBaG3.d.cts.map → index.d-BjGuH5NO.d.cts.map} +1 -1
- package/dist/{index.d-DaMmBaG3.d.ts → index.d-BjGuH5NO.d.mts} +9 -1
- package/dist/{index.d-DaMmBaG3.d.mts.map → index.d-BjGuH5NO.d.mts.map} +1 -1
- package/dist/{index.d-DaMmBaG3.d.mts → index.d-BjGuH5NO.d.ts} +9 -1
- package/dist/{index.d-DaMmBaG3.d.ts.map → index.d-BjGuH5NO.d.ts.map} +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.mjs +1 -1
- package/dist/reporter.cjs +2 -2
- package/dist/reporter.d.cts +1 -1
- package/dist/reporter.d.mts +1 -1
- package/dist/reporter.mjs +2 -2
- package/package.json +4 -4
- package/dist/index-DVywK-2d.cjs.map +0 -1
- package/dist/index-q6hgdCVS.mjs.map +0 -1
|
@@ -4,16 +4,16 @@ import childProcess from 'node:child_process';
|
|
|
4
4
|
import y, { stdout, stdin } from 'node:process';
|
|
5
5
|
import require$$0$2, { execSync } from 'child_process';
|
|
6
6
|
import require$$0$1 from 'path';
|
|
7
|
-
import ze, { readFileSync as readFileSync$1 } from 'fs';
|
|
7
|
+
import ze, { openSync, closeSync, readFileSync as readFileSync$1 } from 'fs';
|
|
8
8
|
import { fileURLToPath } from 'node:url';
|
|
9
9
|
import { constants as constants$1 } from 'node:os';
|
|
10
|
-
import { readFileSync } from 'node:fs';
|
|
10
|
+
import { readFileSync, createReadStream } from 'node:fs';
|
|
11
11
|
import 'node:timers/promises';
|
|
12
12
|
import require$$0 from 'stream';
|
|
13
13
|
import { debuglog, promisify, TextDecoder as TextDecoder$1, TextEncoder as TextEncoder$1 } from 'node:util';
|
|
14
14
|
import * as g from 'node:readline';
|
|
15
15
|
import 'node:stream';
|
|
16
|
-
import
|
|
16
|
+
import ei from 'util';
|
|
17
17
|
import require$$0$5 from 'events';
|
|
18
18
|
import require$$1$1 from 'https';
|
|
19
19
|
import require$$2 from 'http';
|
|
@@ -23,7 +23,7 @@ import require$$1 from 'crypto';
|
|
|
23
23
|
import require$$7 from 'url';
|
|
24
24
|
import require$$0$3 from 'zlib';
|
|
25
25
|
import require$$0$4 from 'buffer';
|
|
26
|
-
import
|
|
26
|
+
import wr from 'os';
|
|
27
27
|
|
|
28
28
|
var appveyor = {
|
|
29
29
|
detect({ env }) {
|
|
@@ -6386,309 +6386,436 @@ function requireWebsocketServer () {
|
|
|
6386
6386
|
|
|
6387
6387
|
requireWebsocketServer();
|
|
6388
6388
|
|
|
6389
|
-
|
|
6390
|
-
const isError = (value) => objectToString.call(value) === "[object Error]";
|
|
6391
|
-
const errorMessages = /* @__PURE__ */ new Set([
|
|
6392
|
-
"network error",
|
|
6393
|
-
// Chrome
|
|
6394
|
-
"Failed to fetch",
|
|
6395
|
-
// Chrome
|
|
6396
|
-
"NetworkError when attempting to fetch resource.",
|
|
6397
|
-
// Firefox
|
|
6398
|
-
"The Internet connection appears to be offline.",
|
|
6399
|
-
// Safari 16
|
|
6400
|
-
"Network request failed",
|
|
6401
|
-
// `cross-fetch`
|
|
6402
|
-
"fetch failed",
|
|
6403
|
-
// Undici (Node.js)
|
|
6404
|
-
"terminated",
|
|
6405
|
-
// Undici (Node.js)
|
|
6406
|
-
" A network error occurred.",
|
|
6407
|
-
// Bun (WebKit)
|
|
6408
|
-
"Network connection lost"
|
|
6409
|
-
// Cloudflare Workers (fetch)
|
|
6410
|
-
]);
|
|
6411
|
-
function isNetworkError(error) {
|
|
6412
|
-
const isValid = error && isError(error) && error.name === "TypeError" && typeof error.message === "string";
|
|
6413
|
-
if (!isValid) {
|
|
6414
|
-
return false;
|
|
6415
|
-
}
|
|
6416
|
-
const { message, stack } = error;
|
|
6417
|
-
if (message === "Load failed") {
|
|
6418
|
-
return stack === void 0 || "__sentry_captured__" in error;
|
|
6419
|
-
}
|
|
6420
|
-
if (message.startsWith("error sending request for url")) {
|
|
6421
|
-
return true;
|
|
6422
|
-
}
|
|
6423
|
-
return errorMessages.has(message);
|
|
6424
|
-
}
|
|
6389
|
+
var pRetry = {exports: {}};
|
|
6425
6390
|
|
|
6426
|
-
|
|
6427
|
-
|
|
6428
|
-
|
|
6429
|
-
|
|
6430
|
-
|
|
6431
|
-
|
|
6432
|
-
|
|
6433
|
-
|
|
6434
|
-
|
|
6435
|
-
|
|
6436
|
-
|
|
6391
|
+
var retry$1 = {};
|
|
6392
|
+
|
|
6393
|
+
var retry_operation;
|
|
6394
|
+
var hasRequiredRetry_operation;
|
|
6395
|
+
|
|
6396
|
+
function requireRetry_operation () {
|
|
6397
|
+
if (hasRequiredRetry_operation) return retry_operation;
|
|
6398
|
+
hasRequiredRetry_operation = 1;
|
|
6399
|
+
function RetryOperation(timeouts, options) {
|
|
6400
|
+
if (typeof options === "boolean") {
|
|
6401
|
+
options = { forever: options };
|
|
6402
|
+
}
|
|
6403
|
+
this._originalTimeouts = JSON.parse(JSON.stringify(timeouts));
|
|
6404
|
+
this._timeouts = timeouts;
|
|
6405
|
+
this._options = options || {};
|
|
6406
|
+
this._maxRetryTime = options && options.maxRetryTime || Infinity;
|
|
6407
|
+
this._fn = null;
|
|
6408
|
+
this._errors = [];
|
|
6409
|
+
this._attempts = 1;
|
|
6410
|
+
this._operationTimeout = null;
|
|
6411
|
+
this._operationTimeoutCb = null;
|
|
6412
|
+
this._timeout = null;
|
|
6413
|
+
this._operationStart = null;
|
|
6414
|
+
this._timer = null;
|
|
6415
|
+
if (this._options.forever) {
|
|
6416
|
+
this._cachedTimeouts = this._timeouts.slice(0);
|
|
6417
|
+
}
|
|
6418
|
+
}
|
|
6419
|
+
retry_operation = RetryOperation;
|
|
6420
|
+
RetryOperation.prototype.reset = function() {
|
|
6421
|
+
this._attempts = 1;
|
|
6422
|
+
this._timeouts = this._originalTimeouts.slice(0);
|
|
6423
|
+
};
|
|
6424
|
+
RetryOperation.prototype.stop = function() {
|
|
6425
|
+
if (this._timeout) {
|
|
6426
|
+
clearTimeout(this._timeout);
|
|
6427
|
+
}
|
|
6428
|
+
if (this._timer) {
|
|
6429
|
+
clearTimeout(this._timer);
|
|
6430
|
+
}
|
|
6431
|
+
this._timeouts = [];
|
|
6432
|
+
this._cachedTimeouts = null;
|
|
6433
|
+
};
|
|
6434
|
+
RetryOperation.prototype.retry = function(err) {
|
|
6435
|
+
if (this._timeout) {
|
|
6436
|
+
clearTimeout(this._timeout);
|
|
6437
|
+
}
|
|
6438
|
+
if (!err) {
|
|
6439
|
+
return false;
|
|
6440
|
+
}
|
|
6441
|
+
var currentTime = (/* @__PURE__ */ new Date()).getTime();
|
|
6442
|
+
if (err && currentTime - this._operationStart >= this._maxRetryTime) {
|
|
6443
|
+
this._errors.push(err);
|
|
6444
|
+
this._errors.unshift(new Error("RetryOperation timeout occurred"));
|
|
6445
|
+
return false;
|
|
6446
|
+
}
|
|
6447
|
+
this._errors.push(err);
|
|
6448
|
+
var timeout = this._timeouts.shift();
|
|
6449
|
+
if (timeout === void 0) {
|
|
6450
|
+
if (this._cachedTimeouts) {
|
|
6451
|
+
this._errors.splice(0, this._errors.length - 1);
|
|
6452
|
+
timeout = this._cachedTimeouts.slice(-1);
|
|
6453
|
+
} else {
|
|
6454
|
+
return false;
|
|
6455
|
+
}
|
|
6456
|
+
}
|
|
6457
|
+
var self = this;
|
|
6458
|
+
this._timer = setTimeout(function() {
|
|
6459
|
+
self._attempts++;
|
|
6460
|
+
if (self._operationTimeoutCb) {
|
|
6461
|
+
self._timeout = setTimeout(function() {
|
|
6462
|
+
self._operationTimeoutCb(self._attempts);
|
|
6463
|
+
}, self._operationTimeout);
|
|
6464
|
+
if (self._options.unref) {
|
|
6465
|
+
self._timeout.unref();
|
|
6466
|
+
}
|
|
6467
|
+
}
|
|
6468
|
+
self._fn(self._attempts);
|
|
6469
|
+
}, timeout);
|
|
6470
|
+
if (this._options.unref) {
|
|
6471
|
+
this._timer.unref();
|
|
6472
|
+
}
|
|
6473
|
+
return true;
|
|
6474
|
+
};
|
|
6475
|
+
RetryOperation.prototype.attempt = function(fn, timeoutOps) {
|
|
6476
|
+
this._fn = fn;
|
|
6477
|
+
if (timeoutOps) {
|
|
6478
|
+
if (timeoutOps.timeout) {
|
|
6479
|
+
this._operationTimeout = timeoutOps.timeout;
|
|
6480
|
+
}
|
|
6481
|
+
if (timeoutOps.cb) {
|
|
6482
|
+
this._operationTimeoutCb = timeoutOps.cb;
|
|
6483
|
+
}
|
|
6484
|
+
}
|
|
6485
|
+
var self = this;
|
|
6486
|
+
if (this._operationTimeoutCb) {
|
|
6487
|
+
this._timeout = setTimeout(function() {
|
|
6488
|
+
self._operationTimeoutCb();
|
|
6489
|
+
}, self._operationTimeout);
|
|
6490
|
+
}
|
|
6491
|
+
this._operationStart = (/* @__PURE__ */ new Date()).getTime();
|
|
6492
|
+
this._fn(this._attempts);
|
|
6493
|
+
};
|
|
6494
|
+
RetryOperation.prototype.try = function(fn) {
|
|
6495
|
+
console.log("Using RetryOperation.try() is deprecated");
|
|
6496
|
+
this.attempt(fn);
|
|
6497
|
+
};
|
|
6498
|
+
RetryOperation.prototype.start = function(fn) {
|
|
6499
|
+
console.log("Using RetryOperation.start() is deprecated");
|
|
6500
|
+
this.attempt(fn);
|
|
6501
|
+
};
|
|
6502
|
+
RetryOperation.prototype.start = RetryOperation.prototype.try;
|
|
6503
|
+
RetryOperation.prototype.errors = function() {
|
|
6504
|
+
return this._errors;
|
|
6505
|
+
};
|
|
6506
|
+
RetryOperation.prototype.attempts = function() {
|
|
6507
|
+
return this._attempts;
|
|
6508
|
+
};
|
|
6509
|
+
RetryOperation.prototype.mainError = function() {
|
|
6510
|
+
if (this._errors.length === 0) {
|
|
6511
|
+
return null;
|
|
6512
|
+
}
|
|
6513
|
+
var counts = {};
|
|
6514
|
+
var mainError = null;
|
|
6515
|
+
var mainErrorCount = 0;
|
|
6516
|
+
for (var i = 0; i < this._errors.length; i++) {
|
|
6517
|
+
var error = this._errors[i];
|
|
6518
|
+
var message = error.message;
|
|
6519
|
+
var count = (counts[message] || 0) + 1;
|
|
6520
|
+
counts[message] = count;
|
|
6521
|
+
if (count >= mainErrorCount) {
|
|
6522
|
+
mainError = error;
|
|
6523
|
+
mainErrorCount = count;
|
|
6524
|
+
}
|
|
6525
|
+
}
|
|
6526
|
+
return mainError;
|
|
6527
|
+
};
|
|
6528
|
+
return retry_operation;
|
|
6437
6529
|
}
|
|
6438
|
-
|
|
6439
|
-
|
|
6440
|
-
|
|
6441
|
-
|
|
6442
|
-
|
|
6443
|
-
|
|
6444
|
-
|
|
6445
|
-
|
|
6446
|
-
|
|
6447
|
-
|
|
6448
|
-
|
|
6449
|
-
|
|
6450
|
-
|
|
6530
|
+
|
|
6531
|
+
var hasRequiredRetry$1;
|
|
6532
|
+
|
|
6533
|
+
function requireRetry$1 () {
|
|
6534
|
+
if (hasRequiredRetry$1) return retry$1;
|
|
6535
|
+
hasRequiredRetry$1 = 1;
|
|
6536
|
+
(function (exports$1) {
|
|
6537
|
+
var RetryOperation = requireRetry_operation();
|
|
6538
|
+
exports$1.operation = function(options) {
|
|
6539
|
+
var timeouts = exports$1.timeouts(options);
|
|
6540
|
+
return new RetryOperation(timeouts, {
|
|
6541
|
+
forever: options && (options.forever || options.retries === Infinity),
|
|
6542
|
+
unref: options && options.unref,
|
|
6543
|
+
maxRetryTime: options && options.maxRetryTime
|
|
6544
|
+
});
|
|
6545
|
+
};
|
|
6546
|
+
exports$1.timeouts = function(options) {
|
|
6547
|
+
if (options instanceof Array) {
|
|
6548
|
+
return [].concat(options);
|
|
6549
|
+
}
|
|
6550
|
+
var opts = {
|
|
6551
|
+
retries: 10,
|
|
6552
|
+
factor: 2,
|
|
6553
|
+
minTimeout: 1 * 1e3,
|
|
6554
|
+
maxTimeout: Infinity,
|
|
6555
|
+
randomize: false
|
|
6556
|
+
};
|
|
6557
|
+
for (var key in options) {
|
|
6558
|
+
opts[key] = options[key];
|
|
6559
|
+
}
|
|
6560
|
+
if (opts.minTimeout > opts.maxTimeout) {
|
|
6561
|
+
throw new Error("minTimeout is greater than maxTimeout");
|
|
6562
|
+
}
|
|
6563
|
+
var timeouts = [];
|
|
6564
|
+
for (var i = 0; i < opts.retries; i++) {
|
|
6565
|
+
timeouts.push(this.createTimeout(i, opts));
|
|
6566
|
+
}
|
|
6567
|
+
if (options && options.forever && !timeouts.length) {
|
|
6568
|
+
timeouts.push(this.createTimeout(i, opts));
|
|
6569
|
+
}
|
|
6570
|
+
timeouts.sort(function(a, b) {
|
|
6571
|
+
return a - b;
|
|
6572
|
+
});
|
|
6573
|
+
return timeouts;
|
|
6574
|
+
};
|
|
6575
|
+
exports$1.createTimeout = function(attempt, opts) {
|
|
6576
|
+
var random = opts.randomize ? Math.random() + 1 : 1;
|
|
6577
|
+
var timeout = Math.round(random * Math.max(opts.minTimeout, 1) * Math.pow(opts.factor, attempt));
|
|
6578
|
+
timeout = Math.min(timeout, opts.maxTimeout);
|
|
6579
|
+
return timeout;
|
|
6580
|
+
};
|
|
6581
|
+
exports$1.wrap = function(obj, options, methods) {
|
|
6582
|
+
if (options instanceof Array) {
|
|
6583
|
+
methods = options;
|
|
6584
|
+
options = null;
|
|
6585
|
+
}
|
|
6586
|
+
if (!methods) {
|
|
6587
|
+
methods = [];
|
|
6588
|
+
for (var key in obj) {
|
|
6589
|
+
if (typeof obj[key] === "function") {
|
|
6590
|
+
methods.push(key);
|
|
6591
|
+
}
|
|
6592
|
+
}
|
|
6593
|
+
}
|
|
6594
|
+
for (var i = 0; i < methods.length; i++) {
|
|
6595
|
+
var method = methods[i];
|
|
6596
|
+
var original = obj[method];
|
|
6597
|
+
obj[method] = function retryWrapper(original2) {
|
|
6598
|
+
var op = exports$1.operation(options);
|
|
6599
|
+
var args = Array.prototype.slice.call(arguments, 1);
|
|
6600
|
+
var callback = args.pop();
|
|
6601
|
+
args.push(function(err) {
|
|
6602
|
+
if (op.retry(err)) {
|
|
6603
|
+
return;
|
|
6604
|
+
}
|
|
6605
|
+
if (err) {
|
|
6606
|
+
arguments[0] = op.mainError();
|
|
6607
|
+
}
|
|
6608
|
+
callback.apply(this, arguments);
|
|
6609
|
+
});
|
|
6610
|
+
op.attempt(function() {
|
|
6611
|
+
original2.apply(obj, args);
|
|
6612
|
+
});
|
|
6613
|
+
}.bind(obj, original);
|
|
6614
|
+
obj[method].options = options;
|
|
6615
|
+
}
|
|
6616
|
+
};
|
|
6617
|
+
} (retry$1));
|
|
6618
|
+
return retry$1;
|
|
6451
6619
|
}
|
|
6452
|
-
|
|
6453
|
-
|
|
6454
|
-
|
|
6455
|
-
|
|
6456
|
-
|
|
6457
|
-
|
|
6458
|
-
|
|
6459
|
-
|
|
6460
|
-
|
|
6461
|
-
}
|
|
6462
|
-
this.name = "AbortError";
|
|
6463
|
-
this.message = message;
|
|
6464
|
-
}
|
|
6465
|
-
}
|
|
6466
|
-
function calculateDelay(retriesConsumed, options) {
|
|
6467
|
-
const attempt = Math.max(1, retriesConsumed + 1);
|
|
6468
|
-
const random = options.randomize ? Math.random() + 1 : 1;
|
|
6469
|
-
let timeout = Math.round(random * options.minTimeout * options.factor ** (attempt - 1));
|
|
6470
|
-
timeout = Math.min(timeout, options.maxTimeout);
|
|
6471
|
-
return timeout;
|
|
6472
|
-
}
|
|
6473
|
-
function calculateRemainingTime(start, max) {
|
|
6474
|
-
if (!Number.isFinite(max)) {
|
|
6475
|
-
return max;
|
|
6476
|
-
}
|
|
6477
|
-
return max - (performance.now() - start);
|
|
6478
|
-
}
|
|
6479
|
-
async function onAttemptFailure({ error, attemptNumber, retriesConsumed, startTime, options }) {
|
|
6480
|
-
const normalizedError = error instanceof Error ? error : new TypeError(`Non-error was thrown: "${error}". You should only throw errors.`);
|
|
6481
|
-
if (normalizedError instanceof AbortError) {
|
|
6482
|
-
throw normalizedError.originalError;
|
|
6483
|
-
}
|
|
6484
|
-
const retriesLeft = Number.isFinite(options.retries) ? Math.max(0, options.retries - retriesConsumed) : options.retries;
|
|
6485
|
-
const maxRetryTime = options.maxRetryTime ?? Number.POSITIVE_INFINITY;
|
|
6486
|
-
const context = Object.freeze({
|
|
6487
|
-
error: normalizedError,
|
|
6488
|
-
attemptNumber,
|
|
6489
|
-
retriesLeft,
|
|
6490
|
-
retriesConsumed
|
|
6491
|
-
});
|
|
6492
|
-
await options.onFailedAttempt(context);
|
|
6493
|
-
if (calculateRemainingTime(startTime, maxRetryTime) <= 0) {
|
|
6494
|
-
throw normalizedError;
|
|
6495
|
-
}
|
|
6496
|
-
const consumeRetry = await options.shouldConsumeRetry(context);
|
|
6497
|
-
const remainingTime = calculateRemainingTime(startTime, maxRetryTime);
|
|
6498
|
-
if (remainingTime <= 0 || retriesLeft <= 0) {
|
|
6499
|
-
throw normalizedError;
|
|
6500
|
-
}
|
|
6501
|
-
if (normalizedError instanceof TypeError && !isNetworkError(normalizedError)) {
|
|
6502
|
-
if (consumeRetry) {
|
|
6503
|
-
throw normalizedError;
|
|
6504
|
-
}
|
|
6505
|
-
options.signal?.throwIfAborted();
|
|
6506
|
-
return false;
|
|
6507
|
-
}
|
|
6508
|
-
if (!await options.shouldRetry(context)) {
|
|
6509
|
-
throw normalizedError;
|
|
6510
|
-
}
|
|
6511
|
-
if (!consumeRetry) {
|
|
6512
|
-
options.signal?.throwIfAborted();
|
|
6513
|
-
return false;
|
|
6514
|
-
}
|
|
6515
|
-
const delayTime = calculateDelay(retriesConsumed, options);
|
|
6516
|
-
const finalDelay = Math.min(delayTime, remainingTime);
|
|
6517
|
-
options.signal?.throwIfAborted();
|
|
6518
|
-
if (finalDelay > 0) {
|
|
6519
|
-
await new Promise((resolve, reject) => {
|
|
6520
|
-
const onAbort = () => {
|
|
6521
|
-
clearTimeout(timeoutToken);
|
|
6522
|
-
options.signal?.removeEventListener("abort", onAbort);
|
|
6523
|
-
reject(options.signal.reason);
|
|
6524
|
-
};
|
|
6525
|
-
const timeoutToken = setTimeout(() => {
|
|
6526
|
-
options.signal?.removeEventListener("abort", onAbort);
|
|
6527
|
-
resolve();
|
|
6528
|
-
}, finalDelay);
|
|
6529
|
-
if (options.unref) {
|
|
6530
|
-
timeoutToken.unref?.();
|
|
6531
|
-
}
|
|
6532
|
-
options.signal?.addEventListener("abort", onAbort, { once: true });
|
|
6533
|
-
});
|
|
6534
|
-
}
|
|
6535
|
-
options.signal?.throwIfAborted();
|
|
6536
|
-
return true;
|
|
6620
|
+
|
|
6621
|
+
var retry;
|
|
6622
|
+
var hasRequiredRetry;
|
|
6623
|
+
|
|
6624
|
+
function requireRetry () {
|
|
6625
|
+
if (hasRequiredRetry) return retry;
|
|
6626
|
+
hasRequiredRetry = 1;
|
|
6627
|
+
retry = requireRetry$1();
|
|
6628
|
+
return retry;
|
|
6537
6629
|
}
|
|
6538
|
-
|
|
6539
|
-
|
|
6540
|
-
|
|
6541
|
-
|
|
6542
|
-
|
|
6543
|
-
|
|
6544
|
-
|
|
6545
|
-
|
|
6546
|
-
|
|
6547
|
-
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
|
|
6551
|
-
|
|
6552
|
-
|
|
6553
|
-
|
|
6554
|
-
|
|
6555
|
-
|
|
6556
|
-
|
|
6557
|
-
|
|
6558
|
-
|
|
6559
|
-
|
|
6560
|
-
|
|
6561
|
-
|
|
6562
|
-
|
|
6563
|
-
|
|
6564
|
-
|
|
6565
|
-
|
|
6566
|
-
|
|
6567
|
-
|
|
6568
|
-
|
|
6569
|
-
|
|
6570
|
-
|
|
6571
|
-
|
|
6572
|
-
|
|
6573
|
-
|
|
6574
|
-
|
|
6575
|
-
|
|
6576
|
-
|
|
6577
|
-
|
|
6578
|
-
|
|
6579
|
-
|
|
6580
|
-
|
|
6581
|
-
|
|
6582
|
-
|
|
6583
|
-
|
|
6584
|
-
|
|
6630
|
+
|
|
6631
|
+
var hasRequiredPRetry;
|
|
6632
|
+
|
|
6633
|
+
function requirePRetry () {
|
|
6634
|
+
if (hasRequiredPRetry) return pRetry.exports;
|
|
6635
|
+
hasRequiredPRetry = 1;
|
|
6636
|
+
const retry = requireRetry();
|
|
6637
|
+
const networkErrorMsgs = [
|
|
6638
|
+
"Failed to fetch",
|
|
6639
|
+
// Chrome
|
|
6640
|
+
"NetworkError when attempting to fetch resource.",
|
|
6641
|
+
// Firefox
|
|
6642
|
+
"The Internet connection appears to be offline.",
|
|
6643
|
+
// Safari
|
|
6644
|
+
"Network request failed"
|
|
6645
|
+
// `cross-fetch`
|
|
6646
|
+
];
|
|
6647
|
+
class AbortError extends Error {
|
|
6648
|
+
constructor(message) {
|
|
6649
|
+
super();
|
|
6650
|
+
if (message instanceof Error) {
|
|
6651
|
+
this.originalError = message;
|
|
6652
|
+
({ message } = message);
|
|
6653
|
+
} else {
|
|
6654
|
+
this.originalError = new Error(message);
|
|
6655
|
+
this.originalError.stack = this.stack;
|
|
6656
|
+
}
|
|
6657
|
+
this.name = "AbortError";
|
|
6658
|
+
this.message = message;
|
|
6659
|
+
}
|
|
6660
|
+
}
|
|
6661
|
+
const decorateErrorWithCounts = (error, attemptNumber, options) => {
|
|
6662
|
+
const retriesLeft = options.retries - (attemptNumber - 1);
|
|
6663
|
+
error.attemptNumber = attemptNumber;
|
|
6664
|
+
error.retriesLeft = retriesLeft;
|
|
6665
|
+
return error;
|
|
6666
|
+
};
|
|
6667
|
+
const isNetworkError = (errorMessage) => networkErrorMsgs.includes(errorMessage);
|
|
6668
|
+
const pRetry$1 = (input, options) => new Promise((resolve, reject) => {
|
|
6669
|
+
options = {
|
|
6670
|
+
onFailedAttempt: () => {
|
|
6671
|
+
},
|
|
6672
|
+
retries: 10,
|
|
6673
|
+
...options
|
|
6674
|
+
};
|
|
6675
|
+
const operation = retry.operation(options);
|
|
6676
|
+
operation.attempt(async (attemptNumber) => {
|
|
6677
|
+
try {
|
|
6678
|
+
resolve(await input(attemptNumber));
|
|
6679
|
+
} catch (error) {
|
|
6680
|
+
if (!(error instanceof Error)) {
|
|
6681
|
+
reject(new TypeError(`Non-error was thrown: "${error}". You should only throw errors.`));
|
|
6682
|
+
return;
|
|
6683
|
+
}
|
|
6684
|
+
if (error instanceof AbortError) {
|
|
6685
|
+
operation.stop();
|
|
6686
|
+
reject(error.originalError);
|
|
6687
|
+
} else if (error instanceof TypeError && !isNetworkError(error.message)) {
|
|
6688
|
+
operation.stop();
|
|
6689
|
+
reject(error);
|
|
6690
|
+
} else {
|
|
6691
|
+
decorateErrorWithCounts(error, attemptNumber, options);
|
|
6692
|
+
try {
|
|
6693
|
+
await options.onFailedAttempt(error);
|
|
6694
|
+
} catch (error2) {
|
|
6695
|
+
reject(error2);
|
|
6696
|
+
return;
|
|
6697
|
+
}
|
|
6698
|
+
if (!operation.retry(error)) {
|
|
6699
|
+
reject(operation.mainError());
|
|
6700
|
+
}
|
|
6701
|
+
}
|
|
6702
|
+
}
|
|
6703
|
+
});
|
|
6704
|
+
});
|
|
6705
|
+
pRetry.exports = pRetry$1;
|
|
6706
|
+
pRetry.exports.default = pRetry$1;
|
|
6707
|
+
pRetry.exports.AbortError = AbortError;
|
|
6708
|
+
return pRetry.exports;
|
|
6585
6709
|
}
|
|
6586
6710
|
|
|
6587
|
-
var
|
|
6588
|
-
var
|
|
6589
|
-
|
|
6590
|
-
|
|
6591
|
-
|
|
6592
|
-
|
|
6593
|
-
|
|
6594
|
-
|
|
6711
|
+
var pRetryExports = requirePRetry();
|
|
6712
|
+
var ai = /*@__PURE__*/getDefaultExportFromCjs(pRetryExports);
|
|
6713
|
+
|
|
6714
|
+
var Yn = Object.defineProperty;
|
|
6715
|
+
var s = (e, t) => Yn(e, "name", { value: t, configurable: true });
|
|
6716
|
+
const st = BigInt(2 ** 32 - 1), Ar = BigInt(32);
|
|
6717
|
+
function ui(e, t = false) {
|
|
6718
|
+
return t ? { h: Number(e & st), l: Number(e >> Ar & st) } : { h: Number(e >> Ar & st) | 0, l: Number(e & st) | 0 };
|
|
6719
|
+
}
|
|
6720
|
+
s(ui, "fromBig");
|
|
6721
|
+
function li(e, t = false) {
|
|
6595
6722
|
const r = e.length;
|
|
6596
|
-
let n = new Uint32Array(r),
|
|
6597
|
-
for (let
|
|
6598
|
-
const { h: c, l } =
|
|
6599
|
-
[n[
|
|
6723
|
+
let n = new Uint32Array(r), i = new Uint32Array(r);
|
|
6724
|
+
for (let o = 0; o < r; o++) {
|
|
6725
|
+
const { h: c, l } = ui(e[o], t);
|
|
6726
|
+
[n[o], i[o]] = [c, l];
|
|
6600
6727
|
}
|
|
6601
|
-
return [n,
|
|
6728
|
+
return [n, i];
|
|
6602
6729
|
}
|
|
6603
|
-
s(
|
|
6604
|
-
const
|
|
6730
|
+
s(li, "split");
|
|
6731
|
+
const fi = s((e, t, r) => e << r | t >>> 32 - r, "rotlSH"), hi = s((e, t, r) => t << r | e >>> 32 - r, "rotlSL"), di = s((e, t, r) => t << r - 32 | e >>> 64 - r, "rotlBH"), pi = s((e, t, r) => e << r - 32 | t >>> 64 - r, "rotlBL");
|
|
6605
6732
|
/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */
|
|
6606
|
-
function
|
|
6733
|
+
function mi(e) {
|
|
6607
6734
|
return e instanceof Uint8Array || ArrayBuffer.isView(e) && e.constructor.name === "Uint8Array";
|
|
6608
6735
|
}
|
|
6609
|
-
s(
|
|
6610
|
-
function
|
|
6736
|
+
s(mi, "isBytes");
|
|
6737
|
+
function vr(e, t = "") {
|
|
6611
6738
|
if (!Number.isSafeInteger(e) || e < 0) {
|
|
6612
6739
|
const r = t && `"${t}" `;
|
|
6613
6740
|
throw new Error(`${r}expected integer >= 0, got ${e}`);
|
|
6614
6741
|
}
|
|
6615
6742
|
}
|
|
6616
|
-
s(
|
|
6743
|
+
s(vr, "anumber");
|
|
6617
6744
|
function Ut(e, t, r = "") {
|
|
6618
|
-
const n =
|
|
6745
|
+
const n = mi(e), i = e?.length;
|
|
6619
6746
|
if (!n || t !== void 0) {
|
|
6620
|
-
const c = r && `"${r}" `, l = "", h = n ? `length=${
|
|
6747
|
+
const c = r && `"${r}" `, l = "", h = n ? `length=${i}` : `type=${typeof e}`;
|
|
6621
6748
|
throw new Error(c + "expected Uint8Array" + l + ", got " + h);
|
|
6622
6749
|
}
|
|
6623
6750
|
return e;
|
|
6624
6751
|
}
|
|
6625
6752
|
s(Ut, "abytes");
|
|
6626
|
-
function
|
|
6753
|
+
function br(e, t = true) {
|
|
6627
6754
|
if (e.destroyed) throw new Error("Hash instance has been destroyed");
|
|
6628
6755
|
if (t && e.finished) throw new Error("Hash#digest() has already been called");
|
|
6629
6756
|
}
|
|
6630
|
-
s(
|
|
6631
|
-
function
|
|
6757
|
+
s(br, "aexists");
|
|
6758
|
+
function Ei(e, t) {
|
|
6632
6759
|
Ut(e, void 0, "digestInto() output");
|
|
6633
6760
|
const r = t.outputLen;
|
|
6634
6761
|
if (e.length < r) throw new Error('"digestInto() output" expected to be of length >=' + r);
|
|
6635
6762
|
}
|
|
6636
|
-
s(
|
|
6637
|
-
function
|
|
6763
|
+
s(Ei, "aoutput");
|
|
6764
|
+
function _i(e) {
|
|
6638
6765
|
return new Uint32Array(e.buffer, e.byteOffset, Math.floor(e.byteLength / 4));
|
|
6639
6766
|
}
|
|
6640
|
-
s(
|
|
6641
|
-
function
|
|
6767
|
+
s(_i, "u32");
|
|
6768
|
+
function Cr(...e) {
|
|
6642
6769
|
for (let t = 0; t < e.length; t++) e[t].fill(0);
|
|
6643
6770
|
}
|
|
6644
|
-
s(
|
|
6645
|
-
const
|
|
6646
|
-
function
|
|
6771
|
+
s(Cr, "clean");
|
|
6772
|
+
const gi = new Uint8Array(new Uint32Array([287454020]).buffer)[0] === 68;
|
|
6773
|
+
function Ii(e) {
|
|
6647
6774
|
return e << 24 & 4278190080 | e << 8 & 16711680 | e >>> 8 & 65280 | e >>> 24 & 255;
|
|
6648
6775
|
}
|
|
6649
|
-
s(
|
|
6650
|
-
function
|
|
6651
|
-
for (let t = 0; t < e.length; t++) e[t] =
|
|
6776
|
+
s(Ii, "byteSwap");
|
|
6777
|
+
function Si(e) {
|
|
6778
|
+
for (let t = 0; t < e.length; t++) e[t] = Ii(e[t]);
|
|
6652
6779
|
return e;
|
|
6653
6780
|
}
|
|
6654
|
-
s(
|
|
6655
|
-
const
|
|
6656
|
-
function
|
|
6657
|
-
const r = s((
|
|
6658
|
-
return r.outputLen = n.outputLen, r.blockLen = n.blockLen, r.create = (
|
|
6781
|
+
s(Si, "byteSwap32");
|
|
6782
|
+
const Ur = gi ? (e) => e : Si;
|
|
6783
|
+
function Ri(e, t = {}) {
|
|
6784
|
+
const r = s((i, o) => e(o).update(i).digest(), "hashC"), n = e(void 0);
|
|
6785
|
+
return r.outputLen = n.outputLen, r.blockLen = n.blockLen, r.create = (i) => e(i), Object.assign(r, t), Object.freeze(r);
|
|
6659
6786
|
}
|
|
6660
|
-
s(
|
|
6661
|
-
const
|
|
6787
|
+
s(Ri, "createHasher");
|
|
6788
|
+
const Ti = s((e) => ({ oid: Uint8Array.from([6, 9, 96, 134, 72, 1, 101, 3, 4, 2, e]) }), "oidNist"), yi = BigInt(0), Qe = BigInt(1), wi = BigInt(2), Ai = BigInt(7), vi = BigInt(256), bi = BigInt(113), Br = [], Or = [], Lr = [];
|
|
6662
6789
|
for (let e = 0, t = Qe, r = 1, n = 0; e < 24; e++) {
|
|
6663
|
-
[r, n] = [n, (2 * r + 3 * n) % 5],
|
|
6664
|
-
let
|
|
6665
|
-
for (let
|
|
6666
|
-
|
|
6790
|
+
[r, n] = [n, (2 * r + 3 * n) % 5], Br.push(2 * (5 * n + r)), Or.push((e + 1) * (e + 2) / 2 % 64);
|
|
6791
|
+
let i = yi;
|
|
6792
|
+
for (let o = 0; o < 7; o++) t = (t << Qe ^ (t >> Ai) * bi) % vi, t & wi && (i ^= Qe << (Qe << BigInt(o)) - Qe);
|
|
6793
|
+
Lr.push(i);
|
|
6667
6794
|
}
|
|
6668
|
-
const
|
|
6669
|
-
function
|
|
6795
|
+
const Pr = li(Lr, true), Ci = Pr[0], Ui = Pr[1], Nr = s((e, t, r) => r > 32 ? di(e, t, r) : fi(e, t, r), "rotlH"), Dr = s((e, t, r) => r > 32 ? pi(e, t, r) : hi(e, t, r), "rotlL");
|
|
6796
|
+
function Bi(e, t = 24) {
|
|
6670
6797
|
const r = new Uint32Array(10);
|
|
6671
6798
|
for (let n = 24 - t; n < 24; n++) {
|
|
6672
6799
|
for (let c = 0; c < 10; c++) r[c] = e[c] ^ e[c + 10] ^ e[c + 20] ^ e[c + 30] ^ e[c + 40];
|
|
6673
6800
|
for (let c = 0; c < 10; c += 2) {
|
|
6674
|
-
const l = (c + 8) % 10, h = (c + 2) % 10,
|
|
6801
|
+
const l = (c + 8) % 10, h = (c + 2) % 10, g = r[h], m = r[h + 1], A = Nr(g, m, 1) ^ r[l], b = Dr(g, m, 1) ^ r[l + 1];
|
|
6675
6802
|
for (let O = 0; O < 50; O += 10) e[c + O] ^= A, e[c + O + 1] ^= b;
|
|
6676
6803
|
}
|
|
6677
|
-
let
|
|
6804
|
+
let i = e[2], o = e[3];
|
|
6678
6805
|
for (let c = 0; c < 24; c++) {
|
|
6679
|
-
const l =
|
|
6680
|
-
|
|
6806
|
+
const l = Or[c], h = Nr(i, o, l), g = Dr(i, o, l), m = Br[c];
|
|
6807
|
+
i = e[m], o = e[m + 1], e[m] = h, e[m + 1] = g;
|
|
6681
6808
|
}
|
|
6682
6809
|
for (let c = 0; c < 50; c += 10) {
|
|
6683
6810
|
for (let l = 0; l < 10; l++) r[l] = e[c + l];
|
|
6684
6811
|
for (let l = 0; l < 10; l++) e[c + l] ^= ~r[(l + 2) % 10] & r[(l + 4) % 10];
|
|
6685
6812
|
}
|
|
6686
|
-
e[0] ^=
|
|
6813
|
+
e[0] ^= Ci[n], e[1] ^= Ui[n];
|
|
6687
6814
|
}
|
|
6688
|
-
|
|
6815
|
+
Cr(r);
|
|
6689
6816
|
}
|
|
6690
|
-
s(
|
|
6691
|
-
class
|
|
6817
|
+
s(Bi, "keccakP");
|
|
6818
|
+
class mr {
|
|
6692
6819
|
static {
|
|
6693
6820
|
s(this, "Keccak");
|
|
6694
6821
|
}
|
|
@@ -6703,22 +6830,22 @@ class dr {
|
|
|
6703
6830
|
outputLen;
|
|
6704
6831
|
enableXOF = false;
|
|
6705
6832
|
rounds;
|
|
6706
|
-
constructor(t, r, n,
|
|
6707
|
-
if (this.blockLen = t, this.suffix = r, this.outputLen = n, this.enableXOF =
|
|
6708
|
-
this.state = new Uint8Array(200), this.state32 =
|
|
6833
|
+
constructor(t, r, n, i = false, o = 24) {
|
|
6834
|
+
if (this.blockLen = t, this.suffix = r, this.outputLen = n, this.enableXOF = i, this.rounds = o, vr(n, "outputLen"), !(0 < t && t < 200)) throw new Error("only keccak-f1600 function is supported");
|
|
6835
|
+
this.state = new Uint8Array(200), this.state32 = _i(this.state);
|
|
6709
6836
|
}
|
|
6710
6837
|
clone() {
|
|
6711
6838
|
return this._cloneInto();
|
|
6712
6839
|
}
|
|
6713
6840
|
keccak() {
|
|
6714
|
-
|
|
6841
|
+
Ur(this.state32), Bi(this.state32, this.rounds), Ur(this.state32), this.posOut = 0, this.pos = 0;
|
|
6715
6842
|
}
|
|
6716
6843
|
update(t) {
|
|
6717
|
-
|
|
6718
|
-
const { blockLen: r, state: n } = this,
|
|
6719
|
-
for (let
|
|
6720
|
-
const c = Math.min(r - this.pos,
|
|
6721
|
-
for (let l = 0; l < c; l++) n[this.pos++] ^= t[
|
|
6844
|
+
br(this), Ut(t);
|
|
6845
|
+
const { blockLen: r, state: n } = this, i = t.length;
|
|
6846
|
+
for (let o = 0; o < i; ) {
|
|
6847
|
+
const c = Math.min(r - this.pos, i - o);
|
|
6848
|
+
for (let l = 0; l < c; l++) n[this.pos++] ^= t[o++];
|
|
6722
6849
|
this.pos === r && this.keccak();
|
|
6723
6850
|
}
|
|
6724
6851
|
return this;
|
|
@@ -6726,16 +6853,16 @@ class dr {
|
|
|
6726
6853
|
finish() {
|
|
6727
6854
|
if (this.finished) return;
|
|
6728
6855
|
this.finished = true;
|
|
6729
|
-
const { state: t, suffix: r, pos: n, blockLen:
|
|
6730
|
-
t[n] ^= r, (r & 128) !== 0 && n ===
|
|
6856
|
+
const { state: t, suffix: r, pos: n, blockLen: i } = this;
|
|
6857
|
+
t[n] ^= r, (r & 128) !== 0 && n === i - 1 && this.keccak(), t[i - 1] ^= 128, this.keccak();
|
|
6731
6858
|
}
|
|
6732
6859
|
writeInto(t) {
|
|
6733
|
-
|
|
6860
|
+
br(this, false), Ut(t), this.finish();
|
|
6734
6861
|
const r = this.state, { blockLen: n } = this;
|
|
6735
|
-
for (let
|
|
6862
|
+
for (let i = 0, o = t.length; i < o; ) {
|
|
6736
6863
|
this.posOut >= n && this.keccak();
|
|
6737
|
-
const c = Math.min(n - this.posOut,
|
|
6738
|
-
t.set(r.subarray(this.posOut, this.posOut + c),
|
|
6864
|
+
const c = Math.min(n - this.posOut, o - i);
|
|
6865
|
+
t.set(r.subarray(this.posOut, this.posOut + c), i), this.posOut += c, i += c;
|
|
6739
6866
|
}
|
|
6740
6867
|
return t;
|
|
6741
6868
|
}
|
|
@@ -6744,30 +6871,30 @@ class dr {
|
|
|
6744
6871
|
return this.writeInto(t);
|
|
6745
6872
|
}
|
|
6746
6873
|
xof(t) {
|
|
6747
|
-
return
|
|
6874
|
+
return vr(t), this.xofInto(new Uint8Array(t));
|
|
6748
6875
|
}
|
|
6749
6876
|
digestInto(t) {
|
|
6750
|
-
if (
|
|
6877
|
+
if (Ei(t, this), this.finished) throw new Error("digest() was already called");
|
|
6751
6878
|
return this.writeInto(t), this.destroy(), t;
|
|
6752
6879
|
}
|
|
6753
6880
|
digest() {
|
|
6754
6881
|
return this.digestInto(new Uint8Array(this.outputLen));
|
|
6755
6882
|
}
|
|
6756
6883
|
destroy() {
|
|
6757
|
-
this.destroyed = true,
|
|
6884
|
+
this.destroyed = true, Cr(this.state);
|
|
6758
6885
|
}
|
|
6759
6886
|
_cloneInto(t) {
|
|
6760
|
-
const { blockLen: r, suffix: n, outputLen:
|
|
6761
|
-
return t ||= new
|
|
6887
|
+
const { blockLen: r, suffix: n, outputLen: i, rounds: o, enableXOF: c } = this;
|
|
6888
|
+
return t ||= new mr(r, n, i, c, o), t.state32.set(this.state32), t.pos = this.pos, t.posOut = this.posOut, t.finished = this.finished, t.rounds = o, t.suffix = n, t.outputLen = i, t.enableXOF = c, t.destroyed = this.destroyed, t;
|
|
6762
6889
|
}
|
|
6763
6890
|
}
|
|
6764
|
-
const
|
|
6765
|
-
var
|
|
6766
|
-
function
|
|
6767
|
-
var t, r, n,
|
|
6768
|
-
function
|
|
6769
|
-
var f,
|
|
6770
|
-
if (!(R instanceof
|
|
6891
|
+
const Oi = s((e, t, r, n = {}) => Ri(() => new mr(t, e, r), n), "genKeccak"), Li = Oi(6, 72, 64, Ti(10));
|
|
6892
|
+
var Pi = /^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i, Bt = Math.ceil, ce = Math.floor, oe = "[BigNumber Error] ", Mr = oe + "Number primitive has more than 15 significant digits: ", me = 1e14, $ = 14, Ot = 9007199254740991, Lt = [1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 1e12, 1e13], Ue = 1e7, te = 1e9;
|
|
6893
|
+
function xr(e) {
|
|
6894
|
+
var t, r, n, i = y.prototype = { constructor: y, toString: null, valueOf: null }, o = new y(1), c = 20, l = 4, h = -7, g = 21, m = -1e7, A = 1e7, b = false, O = 1, x = 0, M = { prefix: "", groupSize: 3, secondaryGroupSize: 0, groupSeparator: ",", decimalSeparator: ".", fractionGroupSize: 0, fractionGroupSeparator: "\xA0", suffix: "" }, w = "0123456789abcdefghijklmnopqrstuvwxyz", C = true;
|
|
6895
|
+
function y(a, u) {
|
|
6896
|
+
var f, _, p, I, T, d, E, S, R = this;
|
|
6897
|
+
if (!(R instanceof y)) return new y(a, u);
|
|
6771
6898
|
if (u == null) {
|
|
6772
6899
|
if (a && a._isBigNumber === true) {
|
|
6773
6900
|
R.s = a.s, !a.c || a.e > A ? R.c = R.e = null : a.e < m ? R.c = [R.e = 0] : (R.e = a.e, R.c = a.c.slice());
|
|
@@ -6781,18 +6908,18 @@ function Nr(e) {
|
|
|
6781
6908
|
}
|
|
6782
6909
|
S = String(a);
|
|
6783
6910
|
} else {
|
|
6784
|
-
if (!
|
|
6911
|
+
if (!Pi.test(S = String(a))) return n(R, S, d);
|
|
6785
6912
|
R.s = S.charCodeAt(0) == 45 ? (S = S.slice(1), -1) : 1;
|
|
6786
6913
|
}
|
|
6787
6914
|
(I = S.indexOf(".")) > -1 && (S = S.replace(".", "")), (T = S.search(/e/i)) > 0 ? (I < 0 && (I = T), I += +S.slice(T + 1), S = S.substring(0, T)) : I < 0 && (I = S.length);
|
|
6788
6915
|
} else {
|
|
6789
|
-
if (J(u, 2,
|
|
6916
|
+
if (J(u, 2, w.length, "Base"), u == 10 && C) return R = new y(a), G(R, c + R.e + 1, l);
|
|
6790
6917
|
if (S = String(a), d = typeof a == "number") {
|
|
6791
6918
|
if (a * 0 != 0) return n(R, S, d, u);
|
|
6792
|
-
if (R.s = 1 / a < 0 ? (S = S.slice(1), -1) : 1,
|
|
6919
|
+
if (R.s = 1 / a < 0 ? (S = S.slice(1), -1) : 1, y.DEBUG && S.replace(/^0\.0*|\./, "").length > 15) throw Error(Mr + a);
|
|
6793
6920
|
} else R.s = S.charCodeAt(0) === 45 ? (S = S.slice(1), -1) : 1;
|
|
6794
|
-
for (f =
|
|
6795
|
-
if (
|
|
6921
|
+
for (f = w.slice(0, u), I = T = 0, E = S.length; T < E; T++) if (f.indexOf(_ = S.charAt(T)) < 0) {
|
|
6922
|
+
if (_ == ".") {
|
|
6796
6923
|
if (T > I) {
|
|
6797
6924
|
I = E;
|
|
6798
6925
|
continue;
|
|
@@ -6808,7 +6935,7 @@ function Nr(e) {
|
|
|
6808
6935
|
for (T = 0; S.charCodeAt(T) === 48; T++) ;
|
|
6809
6936
|
for (E = S.length; S.charCodeAt(--E) === 48; ) ;
|
|
6810
6937
|
if (S = S.slice(T, ++E)) {
|
|
6811
|
-
if (E -= T, d &&
|
|
6938
|
+
if (E -= T, d && y.DEBUG && E > 15 && (a > Ot || a !== ce(a))) throw Error(Mr + R.s * a);
|
|
6812
6939
|
if ((I = I - T - 1) > A) R.c = R.e = null;
|
|
6813
6940
|
else if (I < m) R.c = [R.e = 0];
|
|
6814
6941
|
else {
|
|
@@ -6821,58 +6948,58 @@ function Nr(e) {
|
|
|
6821
6948
|
}
|
|
6822
6949
|
} else R.c = [R.e = 0];
|
|
6823
6950
|
}
|
|
6824
|
-
s(
|
|
6951
|
+
s(y, "BigNumber2"), y.clone = xr, y.ROUND_UP = 0, y.ROUND_DOWN = 1, y.ROUND_CEIL = 2, y.ROUND_FLOOR = 3, y.ROUND_HALF_UP = 4, y.ROUND_HALF_DOWN = 5, y.ROUND_HALF_EVEN = 6, y.ROUND_HALF_CEIL = 7, y.ROUND_HALF_FLOOR = 8, y.EUCLID = 9, y.config = y.set = function(a) {
|
|
6825
6952
|
var u, f;
|
|
6826
6953
|
if (a != null) if (typeof a == "object") {
|
|
6827
|
-
if (a.hasOwnProperty(u = "DECIMAL_PLACES") && (f = a[u], J(f, 0, te, u), c = f), a.hasOwnProperty(u = "ROUNDING_MODE") && (f = a[u], J(f, 0, 8, u), l = f), a.hasOwnProperty(u = "EXPONENTIAL_AT") && (f = a[u], f && f.pop ? (J(f[0], -te, 0, u), J(f[1], 0, te, u), h = f[0],
|
|
6954
|
+
if (a.hasOwnProperty(u = "DECIMAL_PLACES") && (f = a[u], J(f, 0, te, u), c = f), a.hasOwnProperty(u = "ROUNDING_MODE") && (f = a[u], J(f, 0, 8, u), l = f), a.hasOwnProperty(u = "EXPONENTIAL_AT") && (f = a[u], f && f.pop ? (J(f[0], -te, 0, u), J(f[1], 0, te, u), h = f[0], g = f[1]) : (J(f, -te, te, u), h = -(g = f < 0 ? -f : f))), a.hasOwnProperty(u = "RANGE")) if (f = a[u], f && f.pop) J(f[0], -te, -1, u), J(f[1], 1, te, u), m = f[0], A = f[1];
|
|
6828
6955
|
else if (J(f, -te, te, u), f) m = -(A = f < 0 ? -f : f);
|
|
6829
|
-
else throw Error(
|
|
6956
|
+
else throw Error(oe + u + " cannot be zero: " + f);
|
|
6830
6957
|
if (a.hasOwnProperty(u = "CRYPTO")) if (f = a[u], f === !!f) if (f) if (typeof crypto < "u" && crypto && (crypto.getRandomValues || crypto.randomBytes)) b = f;
|
|
6831
|
-
else throw b = !f, Error(
|
|
6958
|
+
else throw b = !f, Error(oe + "crypto unavailable");
|
|
6832
6959
|
else b = f;
|
|
6833
|
-
else throw Error(
|
|
6960
|
+
else throw Error(oe + u + " not true or false: " + f);
|
|
6834
6961
|
if (a.hasOwnProperty(u = "MODULO_MODE") && (f = a[u], J(f, 0, 9, u), O = f), a.hasOwnProperty(u = "POW_PRECISION") && (f = a[u], J(f, 0, te, u), x = f), a.hasOwnProperty(u = "FORMAT")) if (f = a[u], typeof f == "object") M = f;
|
|
6835
|
-
else throw Error(
|
|
6836
|
-
if (a.hasOwnProperty(u = "ALPHABET")) if (f = a[u], typeof f == "string" && !/^.?$|[+\-.\s]|(.).*\1/.test(f)) C = f.slice(0, 10) == "0123456789",
|
|
6837
|
-
else throw Error(
|
|
6838
|
-
} else throw Error(
|
|
6839
|
-
return { DECIMAL_PLACES: c, ROUNDING_MODE: l, EXPONENTIAL_AT: [h,
|
|
6840
|
-
},
|
|
6962
|
+
else throw Error(oe + u + " not an object: " + f);
|
|
6963
|
+
if (a.hasOwnProperty(u = "ALPHABET")) if (f = a[u], typeof f == "string" && !/^.?$|[+\-.\s]|(.).*\1/.test(f)) C = f.slice(0, 10) == "0123456789", w = f;
|
|
6964
|
+
else throw Error(oe + u + " invalid: " + f);
|
|
6965
|
+
} else throw Error(oe + "Object expected: " + a);
|
|
6966
|
+
return { DECIMAL_PLACES: c, ROUNDING_MODE: l, EXPONENTIAL_AT: [h, g], RANGE: [m, A], CRYPTO: b, MODULO_MODE: O, POW_PRECISION: x, FORMAT: M, ALPHABET: w };
|
|
6967
|
+
}, y.isBigNumber = function(a) {
|
|
6841
6968
|
if (!a || a._isBigNumber !== true) return false;
|
|
6842
|
-
if (!
|
|
6843
|
-
var u, f,
|
|
6844
|
-
e: if ({}.toString.call(
|
|
6969
|
+
if (!y.DEBUG) return true;
|
|
6970
|
+
var u, f, _ = a.c, p = a.e, I = a.s;
|
|
6971
|
+
e: if ({}.toString.call(_) == "[object Array]") {
|
|
6845
6972
|
if ((I === 1 || I === -1) && p >= -te && p <= te && p === ce(p)) {
|
|
6846
|
-
if (
|
|
6847
|
-
if (p === 0 &&
|
|
6973
|
+
if (_[0] === 0) {
|
|
6974
|
+
if (p === 0 && _.length === 1) return true;
|
|
6848
6975
|
break e;
|
|
6849
6976
|
}
|
|
6850
|
-
if (u = (p + 1) % $, u < 1 && (u += $), String(
|
|
6851
|
-
for (u = 0; u <
|
|
6977
|
+
if (u = (p + 1) % $, u < 1 && (u += $), String(_[0]).length == u) {
|
|
6978
|
+
for (u = 0; u < _.length; u++) if (f = _[u], f < 0 || f >= me || f !== ce(f)) break e;
|
|
6852
6979
|
if (f !== 0) return true;
|
|
6853
6980
|
}
|
|
6854
6981
|
}
|
|
6855
|
-
} else if (
|
|
6856
|
-
throw Error(
|
|
6857
|
-
},
|
|
6982
|
+
} else if (_ === null && p === null && (I === null || I === 1 || I === -1)) return true;
|
|
6983
|
+
throw Error(oe + "Invalid BigNumber: " + a);
|
|
6984
|
+
}, y.maximum = y.max = function() {
|
|
6858
6985
|
return L(arguments, -1);
|
|
6859
|
-
},
|
|
6986
|
+
}, y.minimum = y.min = function() {
|
|
6860
6987
|
return L(arguments, 1);
|
|
6861
|
-
},
|
|
6988
|
+
}, y.random = (function() {
|
|
6862
6989
|
var a = 9007199254740992, u = Math.random() * a & 2097151 ? function() {
|
|
6863
6990
|
return ce(Math.random() * a);
|
|
6864
6991
|
} : function() {
|
|
6865
6992
|
return (Math.random() * 1073741824 | 0) * 8388608 + (Math.random() * 8388608 | 0);
|
|
6866
6993
|
};
|
|
6867
6994
|
return function(f) {
|
|
6868
|
-
var
|
|
6995
|
+
var _, p, I, T, d, E = 0, S = [], R = new y(o);
|
|
6869
6996
|
if (f == null ? f = c : J(f, 0, te), T = Bt(f / $), b) if (crypto.getRandomValues) {
|
|
6870
|
-
for (
|
|
6997
|
+
for (_ = crypto.getRandomValues(new Uint32Array(T *= 2)); E < T; ) d = _[E] * 131072 + (_[E + 1] >>> 11), d >= 9e15 ? (p = crypto.getRandomValues(new Uint32Array(2)), _[E] = p[0], _[E + 1] = p[1]) : (S.push(d % 1e14), E += 2);
|
|
6871
6998
|
E = T / 2;
|
|
6872
6999
|
} else if (crypto.randomBytes) {
|
|
6873
|
-
for (
|
|
7000
|
+
for (_ = crypto.randomBytes(T *= 7); E < T; ) d = (_[E] & 31) * 281474976710656 + _[E + 1] * 1099511627776 + _[E + 2] * 4294967296 + _[E + 3] * 16777216 + (_[E + 4] << 16) + (_[E + 5] << 8) + _[E + 6], d >= 9e15 ? crypto.randomBytes(7).copy(_, E) : (S.push(d % 1e14), E += 7);
|
|
6874
7001
|
E = T / 7;
|
|
6875
|
-
} else throw b = false, Error(
|
|
7002
|
+
} else throw b = false, Error(oe + "crypto unavailable");
|
|
6876
7003
|
if (!b) for (; E < T; ) d = u(), d < 9e15 && (S[E++] = d % 1e14);
|
|
6877
7004
|
for (T = S[--E], f %= $, T && f && (d = Lt[$ - f], S[E] = ce(T / d) * d); S[E] === 0; S.pop(), E--) ;
|
|
6878
7005
|
if (E < 0) S = [I = 0];
|
|
@@ -6883,56 +7010,56 @@ function Nr(e) {
|
|
|
6883
7010
|
}
|
|
6884
7011
|
return R.e = I, R.c = S, R;
|
|
6885
7012
|
};
|
|
6886
|
-
})(),
|
|
6887
|
-
for (var a = 1, u = arguments, f = new
|
|
7013
|
+
})(), y.sum = function() {
|
|
7014
|
+
for (var a = 1, u = arguments, f = new y(u[0]); a < u.length; ) f = f.plus(u[a++]);
|
|
6888
7015
|
return f;
|
|
6889
7016
|
}, r = (function() {
|
|
6890
7017
|
var a = "0123456789";
|
|
6891
|
-
function u(f,
|
|
7018
|
+
function u(f, _, p, I) {
|
|
6892
7019
|
for (var T, d = [0], E, S = 0, R = f.length; S < R; ) {
|
|
6893
|
-
for (E = d.length; E--; d[E] *=
|
|
7020
|
+
for (E = d.length; E--; d[E] *= _) ;
|
|
6894
7021
|
for (d[0] += I.indexOf(f.charAt(S++)), T = 0; T < d.length; T++) d[T] > p - 1 && (d[T + 1] == null && (d[T + 1] = 0), d[T + 1] += d[T] / p | 0, d[T] %= p);
|
|
6895
7022
|
}
|
|
6896
7023
|
return d.reverse();
|
|
6897
7024
|
}
|
|
6898
|
-
return s(u, "toBaseOut"), function(f,
|
|
7025
|
+
return s(u, "toBaseOut"), function(f, _, p, I, T) {
|
|
6899
7026
|
var d, E, S, R, v, N, P, H, j = f.indexOf("."), q = c, D = l;
|
|
6900
|
-
for (j >= 0 && (R = x, x = 0, f = f.replace(".", ""), H = new
|
|
7027
|
+
for (j >= 0 && (R = x, x = 0, f = f.replace(".", ""), H = new y(_), N = H.pow(f.length - j), x = R, H.c = u(ye(le(N.c), N.e, "0"), 10, p, a), H.e = H.c.length), P = u(f, _, p, T ? (d = w, a) : (d = a, w)), S = R = P.length; P[--R] == 0; P.pop()) ;
|
|
6901
7028
|
if (!P[0]) return d.charAt(0);
|
|
6902
|
-
if (j < 0 ? --S : (N.c = P, N.e = S, N.s = I, N = t(N, H, q, D, p), P = N.c, v = N.r, S = N.e), E = S + q + 1, j = P[E], R = p / 2, v = v || E < 0 || P[E + 1] != null, v = D < 4 ? (j != null || v) && (D == 0 || D == (N.s < 0 ? 3 : 2)) : j > R || j == R && (D == 4 || v || D == 6 && P[E - 1] & 1 || D == (N.s < 0 ? 8 : 7)), E < 1 || !P[0]) f = v ?
|
|
7029
|
+
if (j < 0 ? --S : (N.c = P, N.e = S, N.s = I, N = t(N, H, q, D, p), P = N.c, v = N.r, S = N.e), E = S + q + 1, j = P[E], R = p / 2, v = v || E < 0 || P[E + 1] != null, v = D < 4 ? (j != null || v) && (D == 0 || D == (N.s < 0 ? 3 : 2)) : j > R || j == R && (D == 4 || v || D == 6 && P[E - 1] & 1 || D == (N.s < 0 ? 8 : 7)), E < 1 || !P[0]) f = v ? ye(d.charAt(1), -q, d.charAt(0)) : d.charAt(0);
|
|
6903
7030
|
else {
|
|
6904
7031
|
if (P.length = E, v) for (--p; ++P[--E] > p; ) P[E] = 0, E || (++S, P = [1].concat(P));
|
|
6905
7032
|
for (R = P.length; !P[--R]; ) ;
|
|
6906
7033
|
for (j = 0, f = ""; j <= R; f += d.charAt(P[j++])) ;
|
|
6907
|
-
f =
|
|
7034
|
+
f = ye(f, S, d.charAt(0));
|
|
6908
7035
|
}
|
|
6909
7036
|
return f;
|
|
6910
7037
|
};
|
|
6911
7038
|
})(), t = (function() {
|
|
6912
|
-
function a(
|
|
6913
|
-
var T, d, E, S, R = 0, v =
|
|
6914
|
-
for (
|
|
6915
|
-
return R && (
|
|
7039
|
+
function a(_, p, I) {
|
|
7040
|
+
var T, d, E, S, R = 0, v = _.length, N = p % Ue, P = p / Ue | 0;
|
|
7041
|
+
for (_ = _.slice(); v--; ) E = _[v] % Ue, S = _[v] / Ue | 0, T = P * E + S * N, d = N * E + T % Ue * Ue + R, R = (d / I | 0) + (T / Ue | 0) + P * S, _[v] = d % I;
|
|
7042
|
+
return R && (_ = [R].concat(_)), _;
|
|
6916
7043
|
}
|
|
6917
7044
|
s(a, "multiply");
|
|
6918
|
-
function u(
|
|
7045
|
+
function u(_, p, I, T) {
|
|
6919
7046
|
var d, E;
|
|
6920
7047
|
if (I != T) E = I > T ? 1 : -1;
|
|
6921
|
-
else for (d = E = 0; d < I; d++) if (
|
|
6922
|
-
E =
|
|
7048
|
+
else for (d = E = 0; d < I; d++) if (_[d] != p[d]) {
|
|
7049
|
+
E = _[d] > p[d] ? 1 : -1;
|
|
6923
7050
|
break;
|
|
6924
7051
|
}
|
|
6925
7052
|
return E;
|
|
6926
7053
|
}
|
|
6927
7054
|
s(u, "compare2");
|
|
6928
|
-
function f(
|
|
6929
|
-
for (var d = 0; I--; )
|
|
6930
|
-
for (; !
|
|
6931
|
-
}
|
|
6932
|
-
return s(f, "subtract"), function(
|
|
6933
|
-
var E, S, R, v, N, P, H, j, q, D, F, z, de, ve, be, ne, pe, Z =
|
|
6934
|
-
if (!ee || !ee[0] || !Q || !Q[0]) return new
|
|
6935
|
-
for (j = new
|
|
7055
|
+
function f(_, p, I, T) {
|
|
7056
|
+
for (var d = 0; I--; ) _[I] -= d, d = _[I] < p[I] ? 1 : 0, _[I] = d * T + _[I] - p[I];
|
|
7057
|
+
for (; !_[0] && _.length > 1; _.splice(0, 1)) ;
|
|
7058
|
+
}
|
|
7059
|
+
return s(f, "subtract"), function(_, p, I, T, d) {
|
|
7060
|
+
var E, S, R, v, N, P, H, j, q, D, F, z, de, ve, be, ne, pe, Z = _.s == p.s ? 1 : -1, ee = _.c, Q = p.c;
|
|
7061
|
+
if (!ee || !ee[0] || !Q || !Q[0]) return new y(!_.s || !p.s || (ee ? Q && ee[0] == Q[0] : !Q) ? NaN : ee && ee[0] == 0 || !Q ? Z * 0 : Z / 0);
|
|
7062
|
+
for (j = new y(Z), q = j.c = [], S = _.e - p.e, Z = I + S + 1, d || (d = me, S = ue(_.e / $) - ue(p.e / $), Z = Z / $ | 0), R = 0; Q[R] == (ee[R] || 0); R++) ;
|
|
6936
7063
|
if (Q[R] > (ee[R] || 0) && S--, Z < 0) q.push(1), v = true;
|
|
6937
7064
|
else {
|
|
6938
7065
|
for (ve = ee.length, ne = Q.length, R = 0, Z += 2, N = ce(d / (Q[0] + 1)), N > 1 && (Q = a(Q, N, d), ee = a(ee, N, d), ne = Q.length, ve = ee.length), de = ne, D = ee.slice(0, ne), F = D.length; F < ne; D[F++] = 0) ;
|
|
@@ -6954,51 +7081,51 @@ function Nr(e) {
|
|
|
6954
7081
|
return j;
|
|
6955
7082
|
};
|
|
6956
7083
|
})();
|
|
6957
|
-
function B(a, u, f,
|
|
7084
|
+
function B(a, u, f, _) {
|
|
6958
7085
|
var p, I, T, d, E;
|
|
6959
7086
|
if (f == null ? f = l : J(f, 0, 8), !a.c) return a.toString();
|
|
6960
|
-
if (p = a.c[0], T = a.e, u == null) E = le(a.c), E =
|
|
6961
|
-
else if (a = G(new
|
|
7087
|
+
if (p = a.c[0], T = a.e, u == null) E = le(a.c), E = _ == 1 || _ == 2 && (T <= h || T >= g) ? ct(E, T) : ye(E, T, "0");
|
|
7088
|
+
else if (a = G(new y(a), u, f), I = a.e, E = le(a.c), d = E.length, _ == 1 || _ == 2 && (u <= I || I <= h)) {
|
|
6962
7089
|
for (; d < u; E += "0", d++) ;
|
|
6963
7090
|
E = ct(E, I);
|
|
6964
|
-
} else if (u -= T + (
|
|
7091
|
+
} else if (u -= T + (_ === 2 && I > T), E = ye(E, I, "0"), I + 1 > d) {
|
|
6965
7092
|
if (--u > 0) for (E += "."; u--; E += "0") ;
|
|
6966
7093
|
} else if (u += I - d, u > 0) for (I + 1 == d && (E += "."); u--; E += "0") ;
|
|
6967
7094
|
return a.s < 0 && p ? "-" + E : E;
|
|
6968
7095
|
}
|
|
6969
7096
|
s(B, "format");
|
|
6970
7097
|
function L(a, u) {
|
|
6971
|
-
for (var f,
|
|
7098
|
+
for (var f, _, p = 1, I = new y(a[0]); p < a.length; p++) _ = new y(a[p]), (!_.s || (f = Me(I, _)) === u || f === 0 && I.s === u) && (I = _);
|
|
6972
7099
|
return I;
|
|
6973
7100
|
}
|
|
6974
7101
|
s(L, "maxOrMin");
|
|
6975
7102
|
function U(a, u, f) {
|
|
6976
|
-
for (var
|
|
6977
|
-
for (p = u[0]; p >= 10; p /= 10,
|
|
6978
|
-
return (f =
|
|
7103
|
+
for (var _ = 1, p = u.length; !u[--p]; u.pop()) ;
|
|
7104
|
+
for (p = u[0]; p >= 10; p /= 10, _++) ;
|
|
7105
|
+
return (f = _ + f * $ - 1) > A ? a.c = a.e = null : f < m ? a.c = [a.e = 0] : (a.e = f, a.c = u), a;
|
|
6979
7106
|
}
|
|
6980
7107
|
s(U, "normalise"), n = /* @__PURE__ */ (function() {
|
|
6981
|
-
var a = /^(-?)0([xbo])(?=\w[\w.]*$)/i, u = /^([^.]+)\.$/, f = /^\.([^.]+)$/,
|
|
7108
|
+
var a = /^(-?)0([xbo])(?=\w[\w.]*$)/i, u = /^([^.]+)\.$/, f = /^\.([^.]+)$/, _ = /^-?(Infinity|NaN)$/, p = /^\s*\+(?=[\w.])|^\s+|\s+$/g;
|
|
6982
7109
|
return function(I, T, d, E) {
|
|
6983
7110
|
var S, R = d ? T : T.replace(p, "");
|
|
6984
|
-
if (
|
|
7111
|
+
if (_.test(R)) I.s = isNaN(R) ? null : R < 0 ? -1 : 1;
|
|
6985
7112
|
else {
|
|
6986
7113
|
if (!d && (R = R.replace(a, function(v, N, P) {
|
|
6987
7114
|
return S = (P = P.toLowerCase()) == "x" ? 16 : P == "b" ? 2 : 8, !E || E == S ? N : v;
|
|
6988
|
-
}), E && (S = E, R = R.replace(u, "$1").replace(f, "0.$1")), T != R)) return new
|
|
6989
|
-
if (
|
|
7115
|
+
}), E && (S = E, R = R.replace(u, "$1").replace(f, "0.$1")), T != R)) return new y(R, S);
|
|
7116
|
+
if (y.DEBUG) throw Error(oe + "Not a" + (E ? " base " + E : "") + " number: " + T);
|
|
6990
7117
|
I.s = null;
|
|
6991
7118
|
}
|
|
6992
7119
|
I.c = I.e = null;
|
|
6993
7120
|
};
|
|
6994
7121
|
})();
|
|
6995
|
-
function G(a, u, f,
|
|
7122
|
+
function G(a, u, f, _) {
|
|
6996
7123
|
var p, I, T, d, E, S, R, v = a.c, N = Lt;
|
|
6997
7124
|
if (v) {
|
|
6998
7125
|
e: {
|
|
6999
7126
|
for (p = 1, d = v[0]; d >= 10; d /= 10, p++) ;
|
|
7000
7127
|
if (I = u - p, I < 0) I += $, T = u, E = v[S = 0], R = ce(E / N[p - T - 1] % 10);
|
|
7001
|
-
else if (S = Bt((I + 1) / $), S >= v.length) if (
|
|
7128
|
+
else if (S = Bt((I + 1) / $), S >= v.length) if (_) {
|
|
7002
7129
|
for (; v.length <= S; v.push(0)) ;
|
|
7003
7130
|
E = R = 0, p = 1, I %= $, T = I - $ + 1;
|
|
7004
7131
|
} else break e;
|
|
@@ -7006,8 +7133,8 @@ function Nr(e) {
|
|
|
7006
7133
|
for (E = d = v[S], p = 1; d >= 10; d /= 10, p++) ;
|
|
7007
7134
|
I %= $, T = I - $ + p, R = T < 0 ? 0 : ce(E / N[p - T - 1] % 10);
|
|
7008
7135
|
}
|
|
7009
|
-
if (
|
|
7010
|
-
if (I == 0 ? (v.length = S, d = 1, S--) : (v.length = S + 1, d = N[$ - I], v[S] = T > 0 ? ce(E / N[p - T] % N[T]) * d : 0),
|
|
7136
|
+
if (_ = _ || u < 0 || v[S + 1] != null || (T < 0 ? E : E % N[p - T - 1]), _ = f < 4 ? (R || _) && (f == 0 || f == (a.s < 0 ? 3 : 2)) : R > 5 || R == 5 && (f == 4 || _ || f == 6 && (I > 0 ? T > 0 ? E / N[p - T] : 0 : v[S - 1]) % 10 & 1 || f == (a.s < 0 ? 8 : 7)), u < 1 || !v[0]) return v.length = 0, _ ? (u -= a.e + 1, v[0] = N[($ - u % $) % $], a.e = -u || 0) : v[0] = a.e = 0, a;
|
|
7137
|
+
if (I == 0 ? (v.length = S, d = 1, S--) : (v.length = S + 1, d = N[$ - I], v[S] = T > 0 ? ce(E / N[p - T] % N[T]) * d : 0), _) for (; ; ) if (S == 0) {
|
|
7011
7138
|
for (I = 1, T = v[0]; T >= 10; T /= 10, I++) ;
|
|
7012
7139
|
for (T = v[0] += d, d = 1; T >= 10; T /= 10, d++) ;
|
|
7013
7140
|
I != d && (a.e++, v[0] == me && (v[0] = 1));
|
|
@@ -7025,38 +7152,38 @@ function Nr(e) {
|
|
|
7025
7152
|
s(G, "round");
|
|
7026
7153
|
function k(a) {
|
|
7027
7154
|
var u, f = a.e;
|
|
7028
|
-
return f === null ? a.toString() : (u = le(a.c), u = f <= h || f >=
|
|
7155
|
+
return f === null ? a.toString() : (u = le(a.c), u = f <= h || f >= g ? ct(u, f) : ye(u, f, "0"), a.s < 0 ? "-" + u : u);
|
|
7029
7156
|
}
|
|
7030
|
-
return s(k, "valueOf"),
|
|
7031
|
-
var a = new
|
|
7157
|
+
return s(k, "valueOf"), i.absoluteValue = i.abs = function() {
|
|
7158
|
+
var a = new y(this);
|
|
7032
7159
|
return a.s < 0 && (a.s = 1), a;
|
|
7033
|
-
},
|
|
7034
|
-
return Me(this, new
|
|
7035
|
-
},
|
|
7036
|
-
var f,
|
|
7037
|
-
if (a != null) return J(a, 0, te), u == null ? u = l : J(u, 0, 8), G(new
|
|
7160
|
+
}, i.comparedTo = function(a, u) {
|
|
7161
|
+
return Me(this, new y(a, u));
|
|
7162
|
+
}, i.decimalPlaces = i.dp = function(a, u) {
|
|
7163
|
+
var f, _, p, I = this;
|
|
7164
|
+
if (a != null) return J(a, 0, te), u == null ? u = l : J(u, 0, 8), G(new y(I), a + I.e + 1, u);
|
|
7038
7165
|
if (!(f = I.c)) return null;
|
|
7039
|
-
if (
|
|
7040
|
-
return
|
|
7041
|
-
},
|
|
7042
|
-
return t(this, new
|
|
7043
|
-
},
|
|
7044
|
-
return t(this, new
|
|
7045
|
-
},
|
|
7046
|
-
var f,
|
|
7047
|
-
if (a = new
|
|
7048
|
-
if (u != null && (u = new
|
|
7166
|
+
if (_ = ((p = f.length - 1) - ue(this.e / $)) * $, p = f[p]) for (; p % 10 == 0; p /= 10, _--) ;
|
|
7167
|
+
return _ < 0 && (_ = 0), _;
|
|
7168
|
+
}, i.dividedBy = i.div = function(a, u) {
|
|
7169
|
+
return t(this, new y(a, u), c, l);
|
|
7170
|
+
}, i.dividedToIntegerBy = i.idiv = function(a, u) {
|
|
7171
|
+
return t(this, new y(a, u), 0, 1);
|
|
7172
|
+
}, i.exponentiatedBy = i.pow = function(a, u) {
|
|
7173
|
+
var f, _, p, I, T, d, E, S, R, v = this;
|
|
7174
|
+
if (a = new y(a), a.c && !a.isInteger()) throw Error(oe + "Exponent not an integer: " + k(a));
|
|
7175
|
+
if (u != null && (u = new y(u)), d = a.e > 14, !v.c || !v.c[0] || v.c[0] == 1 && !v.e && v.c.length == 1 || !a.c || !a.c[0]) return R = new y(Math.pow(+k(v), d ? a.s * (2 - at(a)) : +k(a))), u ? R.mod(u) : R;
|
|
7049
7176
|
if (E = a.s < 0, u) {
|
|
7050
|
-
if (u.c ? !u.c[0] : !u.s) return new
|
|
7051
|
-
|
|
7177
|
+
if (u.c ? !u.c[0] : !u.s) return new y(NaN);
|
|
7178
|
+
_ = !E && v.isInteger() && u.isInteger(), _ && (v = v.mod(u));
|
|
7052
7179
|
} else {
|
|
7053
|
-
if (a.e > 9 && (v.e > 0 || v.e < -1 || (v.e == 0 ? v.c[0] > 1 || d && v.c[1] >= 24e7 : v.c[0] < 8e13 || d && v.c[0] <= 9999975e7))) return I = v.s < 0 && at(a) ? -0 : 0, v.e > -1 && (I = 1 / I), new
|
|
7180
|
+
if (a.e > 9 && (v.e > 0 || v.e < -1 || (v.e == 0 ? v.c[0] > 1 || d && v.c[1] >= 24e7 : v.c[0] < 8e13 || d && v.c[0] <= 9999975e7))) return I = v.s < 0 && at(a) ? -0 : 0, v.e > -1 && (I = 1 / I), new y(E ? 1 / I : I);
|
|
7054
7181
|
x && (I = Bt(x / $ + 2));
|
|
7055
7182
|
}
|
|
7056
|
-
for (d ? (f = new
|
|
7183
|
+
for (d ? (f = new y(0.5), E && (a.s = 1), S = at(a)) : (p = Math.abs(+k(a)), S = p % 2), R = new y(o); ; ) {
|
|
7057
7184
|
if (S) {
|
|
7058
7185
|
if (R = R.times(v), !R.c) break;
|
|
7059
|
-
I ? R.c.length > I && (R.c.length = I) :
|
|
7186
|
+
I ? R.c.length > I && (R.c.length = I) : _ && (R = R.mod(u));
|
|
7060
7187
|
}
|
|
7061
7188
|
if (p) {
|
|
7062
7189
|
if (p = ce(p / 2), p === 0) break;
|
|
@@ -7066,83 +7193,83 @@ function Nr(e) {
|
|
|
7066
7193
|
if (p = +k(a), p === 0) break;
|
|
7067
7194
|
S = p % 2;
|
|
7068
7195
|
}
|
|
7069
|
-
v = v.times(v), I ? v.c && v.c.length > I && (v.c.length = I) :
|
|
7196
|
+
v = v.times(v), I ? v.c && v.c.length > I && (v.c.length = I) : _ && (v = v.mod(u));
|
|
7070
7197
|
}
|
|
7071
|
-
return
|
|
7072
|
-
},
|
|
7073
|
-
var u = new
|
|
7198
|
+
return _ ? R : (E && (R = o.div(R)), u ? R.mod(u) : I ? G(R, x, l, T) : R);
|
|
7199
|
+
}, i.integerValue = function(a) {
|
|
7200
|
+
var u = new y(this);
|
|
7074
7201
|
return a == null ? a = l : J(a, 0, 8), G(u, u.e + 1, a);
|
|
7075
|
-
},
|
|
7076
|
-
return Me(this, new
|
|
7077
|
-
},
|
|
7202
|
+
}, i.isEqualTo = i.eq = function(a, u) {
|
|
7203
|
+
return Me(this, new y(a, u)) === 0;
|
|
7204
|
+
}, i.isFinite = function() {
|
|
7078
7205
|
return !!this.c;
|
|
7079
|
-
},
|
|
7080
|
-
return Me(this, new
|
|
7081
|
-
},
|
|
7082
|
-
return (u = Me(this, new
|
|
7083
|
-
},
|
|
7206
|
+
}, i.isGreaterThan = i.gt = function(a, u) {
|
|
7207
|
+
return Me(this, new y(a, u)) > 0;
|
|
7208
|
+
}, i.isGreaterThanOrEqualTo = i.gte = function(a, u) {
|
|
7209
|
+
return (u = Me(this, new y(a, u))) === 1 || u === 0;
|
|
7210
|
+
}, i.isInteger = function() {
|
|
7084
7211
|
return !!this.c && ue(this.e / $) > this.c.length - 2;
|
|
7085
|
-
},
|
|
7086
|
-
return Me(this, new
|
|
7087
|
-
},
|
|
7088
|
-
return (u = Me(this, new
|
|
7089
|
-
},
|
|
7212
|
+
}, i.isLessThan = i.lt = function(a, u) {
|
|
7213
|
+
return Me(this, new y(a, u)) < 0;
|
|
7214
|
+
}, i.isLessThanOrEqualTo = i.lte = function(a, u) {
|
|
7215
|
+
return (u = Me(this, new y(a, u))) === -1 || u === 0;
|
|
7216
|
+
}, i.isNaN = function() {
|
|
7090
7217
|
return !this.s;
|
|
7091
|
-
},
|
|
7218
|
+
}, i.isNegative = function() {
|
|
7092
7219
|
return this.s < 0;
|
|
7093
|
-
},
|
|
7220
|
+
}, i.isPositive = function() {
|
|
7094
7221
|
return this.s > 0;
|
|
7095
|
-
},
|
|
7222
|
+
}, i.isZero = function() {
|
|
7096
7223
|
return !!this.c && this.c[0] == 0;
|
|
7097
|
-
},
|
|
7098
|
-
var f,
|
|
7099
|
-
if (a = new
|
|
7224
|
+
}, i.minus = function(a, u) {
|
|
7225
|
+
var f, _, p, I, T = this, d = T.s;
|
|
7226
|
+
if (a = new y(a, u), u = a.s, !d || !u) return new y(NaN);
|
|
7100
7227
|
if (d != u) return a.s = -u, T.plus(a);
|
|
7101
7228
|
var E = T.e / $, S = a.e / $, R = T.c, v = a.c;
|
|
7102
7229
|
if (!E || !S) {
|
|
7103
|
-
if (!R || !v) return R ? (a.s = -u, a) : new
|
|
7104
|
-
if (!R[0] || !v[0]) return v[0] ? (a.s = -u, a) : new
|
|
7230
|
+
if (!R || !v) return R ? (a.s = -u, a) : new y(v ? T : NaN);
|
|
7231
|
+
if (!R[0] || !v[0]) return v[0] ? (a.s = -u, a) : new y(R[0] ? T : l == 3 ? -0 : 0);
|
|
7105
7232
|
}
|
|
7106
7233
|
if (E = ue(E), S = ue(S), R = R.slice(), d = E - S) {
|
|
7107
7234
|
for ((I = d < 0) ? (d = -d, p = R) : (S = E, p = v), p.reverse(), u = d; u--; p.push(0)) ;
|
|
7108
7235
|
p.reverse();
|
|
7109
|
-
} else for (
|
|
7236
|
+
} else for (_ = (I = (d = R.length) < (u = v.length)) ? d : u, d = u = 0; u < _; u++) if (R[u] != v[u]) {
|
|
7110
7237
|
I = R[u] < v[u];
|
|
7111
7238
|
break;
|
|
7112
7239
|
}
|
|
7113
|
-
if (I && (p = R, R = v, v = p, a.s = -a.s), u = (
|
|
7114
|
-
for (u = me - 1;
|
|
7115
|
-
if (R[--
|
|
7116
|
-
for (f =
|
|
7117
|
-
--R[f], R[
|
|
7240
|
+
if (I && (p = R, R = v, v = p, a.s = -a.s), u = (_ = v.length) - (f = R.length), u > 0) for (; u--; R[f++] = 0) ;
|
|
7241
|
+
for (u = me - 1; _ > d; ) {
|
|
7242
|
+
if (R[--_] < v[_]) {
|
|
7243
|
+
for (f = _; f && !R[--f]; R[f] = u) ;
|
|
7244
|
+
--R[f], R[_] += me;
|
|
7118
7245
|
}
|
|
7119
|
-
R[
|
|
7246
|
+
R[_] -= v[_];
|
|
7120
7247
|
}
|
|
7121
7248
|
for (; R[0] == 0; R.splice(0, 1), --S) ;
|
|
7122
7249
|
return R[0] ? U(a, R, S) : (a.s = l == 3 ? -1 : 1, a.c = [a.e = 0], a);
|
|
7123
|
-
},
|
|
7124
|
-
var f,
|
|
7125
|
-
return a = new
|
|
7126
|
-
},
|
|
7127
|
-
var f,
|
|
7250
|
+
}, i.modulo = i.mod = function(a, u) {
|
|
7251
|
+
var f, _, p = this;
|
|
7252
|
+
return a = new y(a, u), !p.c || !a.s || a.c && !a.c[0] ? new y(NaN) : !a.c || p.c && !p.c[0] ? new y(p) : (O == 9 ? (_ = a.s, a.s = 1, f = t(p, a, 0, 3), a.s = _, f.s *= _) : f = t(p, a, 0, O), a = p.minus(f.times(a)), !a.c[0] && O == 1 && (a.s = p.s), a);
|
|
7253
|
+
}, i.multipliedBy = i.times = function(a, u) {
|
|
7254
|
+
var f, _, p, I, T, d, E, S, R, v, N, P, H, j, q, D = this, F = D.c, z = (a = new y(a, u)).c;
|
|
7128
7255
|
if (!F || !z || !F[0] || !z[0]) return !D.s || !a.s || F && !F[0] && !z || z && !z[0] && !F ? a.c = a.e = a.s = null : (a.s *= D.s, !F || !z ? a.c = a.e = null : (a.c = [0], a.e = 0)), a;
|
|
7129
|
-
for (
|
|
7256
|
+
for (_ = ue(D.e / $) + ue(a.e / $), a.s *= D.s, E = F.length, v = z.length, E < v && (H = F, F = z, z = H, p = E, E = v, v = p), p = E + v, H = []; p--; H.push(0)) ;
|
|
7130
7257
|
for (j = me, q = Ue, p = v; --p >= 0; ) {
|
|
7131
7258
|
for (f = 0, N = z[p] % q, P = z[p] / q | 0, T = E, I = p + T; I > p; ) S = F[--T] % q, R = F[T] / q | 0, d = P * S + R * N, S = N * S + d % q * q + H[I] + f, f = (S / j | 0) + (d / q | 0) + P * R, H[I--] = S % j;
|
|
7132
7259
|
H[I] = f;
|
|
7133
7260
|
}
|
|
7134
|
-
return f ? ++
|
|
7135
|
-
},
|
|
7136
|
-
var a = new
|
|
7261
|
+
return f ? ++_ : H.splice(0, 1), U(a, H, _);
|
|
7262
|
+
}, i.negated = function() {
|
|
7263
|
+
var a = new y(this);
|
|
7137
7264
|
return a.s = -a.s || null, a;
|
|
7138
|
-
},
|
|
7139
|
-
var f,
|
|
7140
|
-
if (a = new
|
|
7141
|
-
if (p != u) return a.s = -u,
|
|
7142
|
-
var I =
|
|
7265
|
+
}, i.plus = function(a, u) {
|
|
7266
|
+
var f, _ = this, p = _.s;
|
|
7267
|
+
if (a = new y(a, u), u = a.s, !p || !u) return new y(NaN);
|
|
7268
|
+
if (p != u) return a.s = -u, _.minus(a);
|
|
7269
|
+
var I = _.e / $, T = a.e / $, d = _.c, E = a.c;
|
|
7143
7270
|
if (!I || !T) {
|
|
7144
|
-
if (!d || !E) return new
|
|
7145
|
-
if (!d[0] || !E[0]) return E[0] ? a : new
|
|
7271
|
+
if (!d || !E) return new y(p / 0);
|
|
7272
|
+
if (!d[0] || !E[0]) return E[0] ? a : new y(d[0] ? _ : p * 0);
|
|
7146
7273
|
}
|
|
7147
7274
|
if (I = ue(I), T = ue(T), d = d.slice(), p = I - T) {
|
|
7148
7275
|
for (p > 0 ? (T = I, f = E) : (p = -p, f = d), f.reverse(); p--; f.push(0)) ;
|
|
@@ -7150,95 +7277,95 @@ function Nr(e) {
|
|
|
7150
7277
|
}
|
|
7151
7278
|
for (p = d.length, u = E.length, p - u < 0 && (f = E, E = d, d = f, u = p), p = 0; u; ) p = (d[--u] = d[u] + E[u] + p) / me | 0, d[u] = me === d[u] ? 0 : d[u] % me;
|
|
7152
7279
|
return p && (d = [p].concat(d), ++T), U(a, d, T);
|
|
7153
|
-
},
|
|
7154
|
-
var f,
|
|
7155
|
-
if (a != null && a !== !!a) return J(a, 1, te), u == null ? u = l : J(u, 0, 8), G(new
|
|
7280
|
+
}, i.precision = i.sd = function(a, u) {
|
|
7281
|
+
var f, _, p, I = this;
|
|
7282
|
+
if (a != null && a !== !!a) return J(a, 1, te), u == null ? u = l : J(u, 0, 8), G(new y(I), a, u);
|
|
7156
7283
|
if (!(f = I.c)) return null;
|
|
7157
|
-
if (p = f.length - 1,
|
|
7158
|
-
for (; p % 10 == 0; p /= 10,
|
|
7159
|
-
for (p = f[0]; p >= 10; p /= 10,
|
|
7284
|
+
if (p = f.length - 1, _ = p * $ + 1, p = f[p]) {
|
|
7285
|
+
for (; p % 10 == 0; p /= 10, _--) ;
|
|
7286
|
+
for (p = f[0]; p >= 10; p /= 10, _++) ;
|
|
7160
7287
|
}
|
|
7161
|
-
return a && I.e + 1 >
|
|
7162
|
-
},
|
|
7288
|
+
return a && I.e + 1 > _ && (_ = I.e + 1), _;
|
|
7289
|
+
}, i.shiftedBy = function(a) {
|
|
7163
7290
|
return J(a, -Ot, Ot), this.times("1e" + a);
|
|
7164
|
-
},
|
|
7165
|
-
var a, u, f,
|
|
7166
|
-
if (d !== 1 || !T || !T[0]) return new
|
|
7167
|
-
if (d = Math.sqrt(+k(I)), d == 0 || d == 1 / 0 ? (u = le(T), (u.length + E) % 2 == 0 && (u += "0"), d = Math.sqrt(+u), E = ue((E + 1) / 2) - (E < 0 || E % 2), d == 1 / 0 ? u = "5e" + E : (u = d.toExponential(), u = u.slice(0, u.indexOf("e") + 1) + E), f = new
|
|
7168
|
-
for (E = f.e, d = E + S, d < 3 && (d = 0); ; ) if (p = f, f = R.times(p.plus(t(I, p, S, 1))), le(p.c).slice(0, d) === (u = le(f.c)).slice(0, d)) if (f.e < E && --d, u = u.slice(d - 3, d + 1), u == "9999" || !
|
|
7169
|
-
if (!
|
|
7291
|
+
}, i.squareRoot = i.sqrt = function() {
|
|
7292
|
+
var a, u, f, _, p, I = this, T = I.c, d = I.s, E = I.e, S = c + 4, R = new y("0.5");
|
|
7293
|
+
if (d !== 1 || !T || !T[0]) return new y(!d || d < 0 && (!T || T[0]) ? NaN : T ? I : 1 / 0);
|
|
7294
|
+
if (d = Math.sqrt(+k(I)), d == 0 || d == 1 / 0 ? (u = le(T), (u.length + E) % 2 == 0 && (u += "0"), d = Math.sqrt(+u), E = ue((E + 1) / 2) - (E < 0 || E % 2), d == 1 / 0 ? u = "5e" + E : (u = d.toExponential(), u = u.slice(0, u.indexOf("e") + 1) + E), f = new y(u)) : f = new y(d + ""), f.c[0]) {
|
|
7295
|
+
for (E = f.e, d = E + S, d < 3 && (d = 0); ; ) if (p = f, f = R.times(p.plus(t(I, p, S, 1))), le(p.c).slice(0, d) === (u = le(f.c)).slice(0, d)) if (f.e < E && --d, u = u.slice(d - 3, d + 1), u == "9999" || !_ && u == "4999") {
|
|
7296
|
+
if (!_ && (G(p, p.e + c + 2, 0), p.times(p).eq(I))) {
|
|
7170
7297
|
f = p;
|
|
7171
7298
|
break;
|
|
7172
7299
|
}
|
|
7173
|
-
S += 4, d += 4,
|
|
7300
|
+
S += 4, d += 4, _ = 1;
|
|
7174
7301
|
} else {
|
|
7175
7302
|
(!+u || !+u.slice(1) && u.charAt(0) == "5") && (G(f, f.e + c + 2, 1), a = !f.times(f).eq(I));
|
|
7176
7303
|
break;
|
|
7177
7304
|
}
|
|
7178
7305
|
}
|
|
7179
7306
|
return G(f, f.e + c + 1, l, a);
|
|
7180
|
-
},
|
|
7307
|
+
}, i.toExponential = function(a, u) {
|
|
7181
7308
|
return a != null && (J(a, 0, te), a++), B(this, a, u, 1);
|
|
7182
|
-
},
|
|
7309
|
+
}, i.toFixed = function(a, u) {
|
|
7183
7310
|
return a != null && (J(a, 0, te), a = a + this.e + 1), B(this, a, u);
|
|
7184
|
-
},
|
|
7185
|
-
var
|
|
7311
|
+
}, i.toFormat = function(a, u, f) {
|
|
7312
|
+
var _, p = this;
|
|
7186
7313
|
if (f == null) a != null && u && typeof u == "object" ? (f = u, u = null) : a && typeof a == "object" ? (f = a, a = u = null) : f = M;
|
|
7187
|
-
else if (typeof f != "object") throw Error(
|
|
7188
|
-
if (
|
|
7189
|
-
var I, T =
|
|
7314
|
+
else if (typeof f != "object") throw Error(oe + "Argument not an object: " + f);
|
|
7315
|
+
if (_ = p.toFixed(a, u), p.c) {
|
|
7316
|
+
var I, T = _.split("."), d = +f.groupSize, E = +f.secondaryGroupSize, S = f.groupSeparator || "", R = T[0], v = T[1], N = p.s < 0, P = N ? R.slice(1) : R, H = P.length;
|
|
7190
7317
|
if (E && (I = d, d = E, E = I, H -= I), d > 0 && H > 0) {
|
|
7191
7318
|
for (I = H % d || d, R = P.substr(0, I); I < H; I += d) R += S + P.substr(I, d);
|
|
7192
7319
|
E > 0 && (R += S + P.slice(I)), N && (R = "-" + R);
|
|
7193
7320
|
}
|
|
7194
|
-
|
|
7195
|
-
}
|
|
7196
|
-
return (f.prefix || "") +
|
|
7197
|
-
},
|
|
7198
|
-
var u, f,
|
|
7199
|
-
if (a != null && (d = new
|
|
7200
|
-
if (!H) return new
|
|
7201
|
-
for (u = new
|
|
7202
|
-
return p = t(a.minus(f),
|
|
7203
|
-
},
|
|
7321
|
+
_ = v ? R + (f.decimalSeparator || "") + ((E = +f.fractionGroupSize) ? v.replace(new RegExp("\\d{" + E + "}\\B", "g"), "$&" + (f.fractionGroupSeparator || "")) : v) : R;
|
|
7322
|
+
}
|
|
7323
|
+
return (f.prefix || "") + _ + (f.suffix || "");
|
|
7324
|
+
}, i.toFraction = function(a) {
|
|
7325
|
+
var u, f, _, p, I, T, d, E, S, R, v, N, P = this, H = P.c;
|
|
7326
|
+
if (a != null && (d = new y(a), !d.isInteger() && (d.c || d.s !== 1) || d.lt(o))) throw Error(oe + "Argument " + (d.isInteger() ? "out of range: " : "not an integer: ") + k(d));
|
|
7327
|
+
if (!H) return new y(P);
|
|
7328
|
+
for (u = new y(o), S = f = new y(o), _ = E = new y(o), N = le(H), I = u.e = N.length - P.e - 1, u.c[0] = Lt[(T = I % $) < 0 ? $ + T : T], a = !a || d.comparedTo(u) > 0 ? I > 0 ? u : S : d, T = A, A = 1 / 0, d = new y(N), E.c[0] = 0; R = t(d, u, 0, 1), p = f.plus(R.times(_)), p.comparedTo(a) != 1; ) f = _, _ = p, S = E.plus(R.times(p = S)), E = p, u = d.minus(R.times(p = u)), d = p;
|
|
7329
|
+
return p = t(a.minus(f), _, 0, 1), E = E.plus(p.times(S)), f = f.plus(p.times(_)), E.s = S.s = P.s, I = I * 2, v = t(S, _, I, l).minus(P).abs().comparedTo(t(E, f, I, l).minus(P).abs()) < 1 ? [S, _] : [E, f], A = T, v;
|
|
7330
|
+
}, i.toNumber = function() {
|
|
7204
7331
|
return +k(this);
|
|
7205
|
-
},
|
|
7332
|
+
}, i.toPrecision = function(a, u) {
|
|
7206
7333
|
return a != null && J(a, 1, te), B(this, a, u, 2);
|
|
7207
|
-
},
|
|
7208
|
-
var u, f = this,
|
|
7209
|
-
return p === null ?
|
|
7210
|
-
},
|
|
7334
|
+
}, i.toString = function(a) {
|
|
7335
|
+
var u, f = this, _ = f.s, p = f.e;
|
|
7336
|
+
return p === null ? _ ? (u = "Infinity", _ < 0 && (u = "-" + u)) : u = "NaN" : (a == null ? u = p <= h || p >= g ? ct(le(f.c), p) : ye(le(f.c), p, "0") : a === 10 && C ? (f = G(new y(f), c + p + 1, l), u = ye(le(f.c), f.e, "0")) : (J(a, 2, w.length, "Base"), u = r(ye(le(f.c), p, "0"), 10, a, _, true)), _ < 0 && f.c[0] && (u = "-" + u)), u;
|
|
7337
|
+
}, i.valueOf = i.toJSON = function() {
|
|
7211
7338
|
return k(this);
|
|
7212
|
-
},
|
|
7339
|
+
}, i._isBigNumber = true, i[Symbol.toStringTag] = "BigNumber", i[Symbol.for("nodejs.util.inspect.custom")] = i.valueOf, e != null && y.set(e), y;
|
|
7213
7340
|
}
|
|
7214
|
-
s(
|
|
7341
|
+
s(xr, "clone");
|
|
7215
7342
|
function ue(e) {
|
|
7216
7343
|
var t = e | 0;
|
|
7217
7344
|
return e > 0 || e === t ? t : t - 1;
|
|
7218
7345
|
}
|
|
7219
7346
|
s(ue, "bitFloor");
|
|
7220
7347
|
function le(e) {
|
|
7221
|
-
for (var t, r, n = 1,
|
|
7348
|
+
for (var t, r, n = 1, i = e.length, o = e[0] + ""; n < i; ) {
|
|
7222
7349
|
for (t = e[n++] + "", r = $ - t.length; r--; t = "0" + t) ;
|
|
7223
|
-
|
|
7350
|
+
o += t;
|
|
7224
7351
|
}
|
|
7225
|
-
for (
|
|
7226
|
-
return
|
|
7352
|
+
for (i = o.length; o.charCodeAt(--i) === 48; ) ;
|
|
7353
|
+
return o.slice(0, i + 1 || 1);
|
|
7227
7354
|
}
|
|
7228
7355
|
s(le, "coeffToString");
|
|
7229
7356
|
function Me(e, t) {
|
|
7230
|
-
var r, n,
|
|
7357
|
+
var r, n, i = e.c, o = t.c, c = e.s, l = t.s, h = e.e, g = t.e;
|
|
7231
7358
|
if (!c || !l) return null;
|
|
7232
|
-
if (r =
|
|
7359
|
+
if (r = i && !i[0], n = o && !o[0], r || n) return r ? n ? 0 : -l : c;
|
|
7233
7360
|
if (c != l) return c;
|
|
7234
|
-
if (r = c < 0, n = h ==
|
|
7235
|
-
if (!n) return h >
|
|
7236
|
-
for (l = (h =
|
|
7237
|
-
return h ==
|
|
7361
|
+
if (r = c < 0, n = h == g, !i || !o) return n ? 0 : !i ^ r ? 1 : -1;
|
|
7362
|
+
if (!n) return h > g ^ r ? 1 : -1;
|
|
7363
|
+
for (l = (h = i.length) < (g = o.length) ? h : g, c = 0; c < l; c++) if (i[c] != o[c]) return i[c] > o[c] ^ r ? 1 : -1;
|
|
7364
|
+
return h == g ? 0 : h > g ^ r ? 1 : -1;
|
|
7238
7365
|
}
|
|
7239
7366
|
s(Me, "compare");
|
|
7240
7367
|
function J(e, t, r, n) {
|
|
7241
|
-
if (e < t || e > r || e !== ce(e)) throw Error(
|
|
7368
|
+
if (e < t || e > r || e !== ce(e)) throw Error(oe + (n || "Argument") + (typeof e == "number" ? e < t || e > r ? " out of range: " : " not an integer: " : " not a primitive number: ") + String(e));
|
|
7242
7369
|
}
|
|
7243
7370
|
s(J, "intCheck");
|
|
7244
7371
|
function at(e) {
|
|
@@ -7250,61 +7377,61 @@ function ct(e, t) {
|
|
|
7250
7377
|
return (e.length > 1 ? e.charAt(0) + "." + e.slice(1) : e) + (t < 0 ? "e" : "e+") + t;
|
|
7251
7378
|
}
|
|
7252
7379
|
s(ct, "toExponential");
|
|
7253
|
-
function
|
|
7254
|
-
var n,
|
|
7380
|
+
function ye(e, t, r) {
|
|
7381
|
+
var n, i;
|
|
7255
7382
|
if (t < 0) {
|
|
7256
|
-
for (
|
|
7257
|
-
e =
|
|
7383
|
+
for (i = r + "."; ++t; i += r) ;
|
|
7384
|
+
e = i + e;
|
|
7258
7385
|
} else if (n = e.length, ++t > n) {
|
|
7259
|
-
for (
|
|
7260
|
-
e +=
|
|
7386
|
+
for (i = r, t -= n; --t; i += r) ;
|
|
7387
|
+
e += i;
|
|
7261
7388
|
} else t < n && (e = e.slice(0, t) + "." + e.slice(t));
|
|
7262
7389
|
return e;
|
|
7263
7390
|
}
|
|
7264
|
-
s(
|
|
7265
|
-
var
|
|
7266
|
-
const
|
|
7391
|
+
s(ye, "toFixedPoint");
|
|
7392
|
+
var Ni = xr();
|
|
7393
|
+
const Di = 24, Xe = 32, Mi = s(() => typeof globalThis < "u" && globalThis.crypto && typeof globalThis.crypto.getRandomValues == "function" ? () => {
|
|
7267
7394
|
const e = new Uint32Array(1);
|
|
7268
7395
|
return globalThis.crypto.getRandomValues(e), e[0] / 4294967296;
|
|
7269
|
-
} : Math.random, "createRandom"), Pt =
|
|
7396
|
+
} : Math.random, "createRandom"), Pt = Mi(), Nt = s((e = 4, t = Pt) => {
|
|
7270
7397
|
let r = "";
|
|
7271
7398
|
for (; r.length < e; ) r = r + Math.floor(t() * 36).toString(36);
|
|
7272
7399
|
return r;
|
|
7273
7400
|
}, "createEntropy");
|
|
7274
|
-
function
|
|
7275
|
-
let t = new
|
|
7401
|
+
function xi(e) {
|
|
7402
|
+
let t = new Ni(0);
|
|
7276
7403
|
for (const r of e.values()) t = t.multipliedBy(256).plus(r);
|
|
7277
7404
|
return t;
|
|
7278
7405
|
}
|
|
7279
|
-
s(
|
|
7280
|
-
const
|
|
7406
|
+
s(xi, "bufToBigInt");
|
|
7407
|
+
const Gr = s((e = "") => {
|
|
7281
7408
|
const t = new TextEncoder();
|
|
7282
|
-
return
|
|
7283
|
-
}, "hash"),
|
|
7409
|
+
return xi(Li(t.encode(e))).toString(36).slice(1);
|
|
7410
|
+
}, "hash"), $r = Array.from({ length: 26 }, (e, t) => String.fromCharCode(t + 97)), Gi = s((e) => $r[Math.floor(e() * $r.length)], "randomLetter"), $i = s(({ globalObj: e = typeof global < "u" ? global : typeof window < "u" ? window : {}, random: t = Pt } = {}) => {
|
|
7284
7411
|
const r = Object.keys(e).toString(), n = r.length ? r + Nt(Xe, t) : Nt(Xe, t);
|
|
7285
|
-
return
|
|
7286
|
-
}, "createFingerprint"),
|
|
7412
|
+
return Gr(n).substring(0, Xe);
|
|
7413
|
+
}, "createFingerprint"), ki = s((e) => () => e++, "createCounter"), Hi = 476782367, Fi = s(({ random: e = Pt, counter: t = ki(Math.floor(e() * Hi)), length: r = Di, fingerprint: n = $i({ random: e }) } = {}) => {
|
|
7287
7414
|
if (r > Xe) throw new Error(`Length must be between 2 and ${Xe}. Received: ${r}`);
|
|
7288
7415
|
return s(function() {
|
|
7289
|
-
const
|
|
7290
|
-
return `${
|
|
7416
|
+
const o = Gi(e), c = Date.now().toString(36), l = t().toString(36), h = Nt(r, e), g = `${c + h + l + n}`;
|
|
7417
|
+
return `${o + Gr(g).substring(1, r)}`;
|
|
7291
7418
|
}, "cuid2");
|
|
7292
|
-
}, "init"), ut =
|
|
7293
|
-
function
|
|
7419
|
+
}, "init"), ut = ji(Fi);
|
|
7420
|
+
function ji(e) {
|
|
7294
7421
|
let t;
|
|
7295
7422
|
return () => (t || (t = e()), t());
|
|
7296
7423
|
}
|
|
7297
|
-
s(
|
|
7298
|
-
var
|
|
7299
|
-
function
|
|
7424
|
+
s(ji, "lazy");
|
|
7425
|
+
var qi = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
7426
|
+
function kr(e) {
|
|
7300
7427
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
7301
7428
|
}
|
|
7302
|
-
s(
|
|
7303
|
-
var xe = {},
|
|
7304
|
-
function
|
|
7305
|
-
if (
|
|
7306
|
-
|
|
7307
|
-
const e = ze, t =
|
|
7429
|
+
s(kr, "getDefaultExportFromCjs");
|
|
7430
|
+
var xe = {}, Hr;
|
|
7431
|
+
function Wi() {
|
|
7432
|
+
if (Hr) return xe;
|
|
7433
|
+
Hr = 1, Object.defineProperty(xe, "__esModule", { value: true }), xe.isBinaryFileSync = xe.isBinaryFile = void 0;
|
|
7434
|
+
const e = ze, t = ei, r = (0, t.promisify)(e.stat), n = (0, t.promisify)(e.open), i = (0, t.promisify)(e.close), o = 512, c = 3;
|
|
7308
7435
|
class l {
|
|
7309
7436
|
static {
|
|
7310
7437
|
s(this, "Reader");
|
|
@@ -7313,8 +7440,8 @@ function $i() {
|
|
|
7313
7440
|
size;
|
|
7314
7441
|
offset;
|
|
7315
7442
|
error;
|
|
7316
|
-
constructor(C,
|
|
7317
|
-
this.fileBuffer = C, this.size =
|
|
7443
|
+
constructor(C, y) {
|
|
7444
|
+
this.fileBuffer = C, this.size = y, this.offset = 0, this.error = false;
|
|
7318
7445
|
}
|
|
7319
7446
|
hasError() {
|
|
7320
7447
|
return this.error;
|
|
@@ -7323,62 +7450,62 @@ function $i() {
|
|
|
7323
7450
|
return this.offset === this.size || this.hasError() ? (this.error = true, 255) : this.fileBuffer[this.offset++];
|
|
7324
7451
|
}
|
|
7325
7452
|
next(C) {
|
|
7326
|
-
const
|
|
7453
|
+
const y = new Array();
|
|
7327
7454
|
for (let B = 0; B < C; B++) {
|
|
7328
|
-
if (this.error) return
|
|
7329
|
-
|
|
7455
|
+
if (this.error) return y;
|
|
7456
|
+
y[B] = this.nextByte();
|
|
7330
7457
|
}
|
|
7331
|
-
return
|
|
7458
|
+
return y;
|
|
7332
7459
|
}
|
|
7333
7460
|
}
|
|
7334
|
-
function h(
|
|
7335
|
-
let C = 0,
|
|
7336
|
-
for (; !
|
|
7337
|
-
const B =
|
|
7338
|
-
if (
|
|
7461
|
+
function h(w) {
|
|
7462
|
+
let C = 0, y = 0;
|
|
7463
|
+
for (; !w.hasError(); ) {
|
|
7464
|
+
const B = w.nextByte();
|
|
7465
|
+
if (y = y | (B & 127) << 7 * C, (B & 128) === 0) break;
|
|
7339
7466
|
if (C >= 10) {
|
|
7340
|
-
|
|
7467
|
+
w.error = true;
|
|
7341
7468
|
break;
|
|
7342
7469
|
}
|
|
7343
7470
|
C++;
|
|
7344
7471
|
}
|
|
7345
|
-
return
|
|
7472
|
+
return y;
|
|
7346
7473
|
}
|
|
7347
7474
|
s(h, "readProtoVarInt");
|
|
7348
|
-
function
|
|
7349
|
-
switch (h(
|
|
7475
|
+
function g(w) {
|
|
7476
|
+
switch (h(w) & 7) {
|
|
7350
7477
|
case 0:
|
|
7351
|
-
return h(
|
|
7478
|
+
return h(w), true;
|
|
7352
7479
|
case 1:
|
|
7353
|
-
return
|
|
7480
|
+
return w.next(8), true;
|
|
7354
7481
|
case 2:
|
|
7355
|
-
const B = h(
|
|
7356
|
-
return
|
|
7482
|
+
const B = h(w);
|
|
7483
|
+
return w.next(B), true;
|
|
7357
7484
|
case 5:
|
|
7358
|
-
return
|
|
7485
|
+
return w.next(4), true;
|
|
7359
7486
|
}
|
|
7360
7487
|
return false;
|
|
7361
7488
|
}
|
|
7362
|
-
s(
|
|
7363
|
-
function m(
|
|
7364
|
-
const
|
|
7489
|
+
s(g, "readProtoMessage");
|
|
7490
|
+
function m(w, C) {
|
|
7491
|
+
const y = new l(w, C);
|
|
7365
7492
|
let B = 0;
|
|
7366
7493
|
for (; ; ) {
|
|
7367
|
-
if (!
|
|
7368
|
-
if (
|
|
7494
|
+
if (!g(y) && !y.hasError()) return false;
|
|
7495
|
+
if (y.hasError()) break;
|
|
7369
7496
|
B++;
|
|
7370
7497
|
}
|
|
7371
7498
|
return B > 0;
|
|
7372
7499
|
}
|
|
7373
7500
|
s(m, "isBinaryProto");
|
|
7374
|
-
async function A(
|
|
7375
|
-
if (x(
|
|
7376
|
-
const
|
|
7377
|
-
M(
|
|
7378
|
-
const B = await n(
|
|
7501
|
+
async function A(w, C) {
|
|
7502
|
+
if (x(w)) {
|
|
7503
|
+
const y = await r(w);
|
|
7504
|
+
M(y);
|
|
7505
|
+
const B = await n(w, "r"), L = Buffer.alloc(o + c);
|
|
7379
7506
|
return new Promise((U, G) => {
|
|
7380
|
-
e.read(B, L, 0,
|
|
7381
|
-
if (
|
|
7507
|
+
e.read(B, L, 0, o + c, 0, (k, a, u) => {
|
|
7508
|
+
if (i(B), k) G(k);
|
|
7382
7509
|
else try {
|
|
7383
7510
|
U(O(L, a));
|
|
7384
7511
|
} catch (f) {
|
|
@@ -7386,91 +7513,91 @@ function $i() {
|
|
|
7386
7513
|
}
|
|
7387
7514
|
});
|
|
7388
7515
|
});
|
|
7389
|
-
} else return C === void 0 && (C =
|
|
7516
|
+
} else return C === void 0 && (C = w.length), O(w, C);
|
|
7390
7517
|
}
|
|
7391
7518
|
s(A, "isBinaryFile"), xe.isBinaryFile = A;
|
|
7392
|
-
function b(
|
|
7393
|
-
if (x(
|
|
7394
|
-
const
|
|
7395
|
-
M(
|
|
7396
|
-
const B = e.openSync(
|
|
7519
|
+
function b(w, C) {
|
|
7520
|
+
if (x(w)) {
|
|
7521
|
+
const y = e.statSync(w);
|
|
7522
|
+
M(y);
|
|
7523
|
+
const B = e.openSync(w, "r"), L = Buffer.alloc(o + c), U = e.readSync(B, L, 0, o + c, 0);
|
|
7397
7524
|
return e.closeSync(B), O(L, U);
|
|
7398
|
-
} else return C === void 0 && (C =
|
|
7525
|
+
} else return C === void 0 && (C = w.length), O(w, C);
|
|
7399
7526
|
}
|
|
7400
7527
|
s(b, "isBinaryFileSync"), xe.isBinaryFileSync = b;
|
|
7401
|
-
function O(
|
|
7528
|
+
function O(w, C) {
|
|
7402
7529
|
if (C === 0) return false;
|
|
7403
|
-
let
|
|
7404
|
-
const B = Math.min(C,
|
|
7405
|
-
if (C >= 3 &&
|
|
7406
|
-
if (B >= 5 &&
|
|
7407
|
-
if (C >= 2 &&
|
|
7530
|
+
let y = 0;
|
|
7531
|
+
const B = Math.min(C, o + c), L = Math.min(B, o);
|
|
7532
|
+
if (C >= 3 && w[0] === 239 && w[1] === 187 && w[2] === 191 || C >= 4 && w[0] === 0 && w[1] === 0 && w[2] === 254 && w[3] === 255 || C >= 4 && w[0] === 255 && w[1] === 254 && w[2] === 0 && w[3] === 0 || C >= 4 && w[0] === 132 && w[1] === 49 && w[2] === 149 && w[3] === 51) return false;
|
|
7533
|
+
if (B >= 5 && w.slice(0, 5).toString() === "%PDF-") return true;
|
|
7534
|
+
if (C >= 2 && w[0] === 254 && w[1] === 255 || C >= 2 && w[0] === 255 && w[1] === 254) return false;
|
|
7408
7535
|
for (let U = 0; U < L; U++) {
|
|
7409
|
-
if (
|
|
7410
|
-
if ((
|
|
7411
|
-
if (
|
|
7412
|
-
if (U++,
|
|
7413
|
-
} else if (
|
|
7414
|
-
if (U++,
|
|
7536
|
+
if (w[U] === 0) return true;
|
|
7537
|
+
if ((w[U] < 7 || w[U] > 14) && (w[U] < 32 || w[U] > 127)) {
|
|
7538
|
+
if (w[U] >= 192 && w[U] <= 223 && U + 1 < B) {
|
|
7539
|
+
if (U++, w[U] >= 128 && w[U] <= 191) continue;
|
|
7540
|
+
} else if (w[U] >= 224 && w[U] <= 239 && U + 2 < B) {
|
|
7541
|
+
if (U++, w[U] >= 128 && w[U] <= 191 && w[U + 1] >= 128 && w[U + 1] <= 191) {
|
|
7415
7542
|
U++;
|
|
7416
7543
|
continue;
|
|
7417
7544
|
}
|
|
7418
|
-
} else if (
|
|
7545
|
+
} else if (w[U] >= 240 && w[U] <= 247 && U + 3 < B && (U++, w[U] >= 128 && w[U] <= 191 && w[U + 1] >= 128 && w[U + 1] <= 191 && w[U + 2] >= 128 && w[U + 2] <= 191)) {
|
|
7419
7546
|
U += 2;
|
|
7420
7547
|
continue;
|
|
7421
7548
|
}
|
|
7422
|
-
if (
|
|
7549
|
+
if (y++, U >= 32 && y * 100 / L > 10) return true;
|
|
7423
7550
|
}
|
|
7424
7551
|
}
|
|
7425
|
-
return !!(
|
|
7552
|
+
return !!(y * 100 / L > 10 || y > 1 && m(w, L));
|
|
7426
7553
|
}
|
|
7427
7554
|
s(O, "isBinaryCheck");
|
|
7428
|
-
function x(
|
|
7429
|
-
return typeof
|
|
7555
|
+
function x(w) {
|
|
7556
|
+
return typeof w == "string";
|
|
7430
7557
|
}
|
|
7431
7558
|
s(x, "isString");
|
|
7432
|
-
function M(
|
|
7433
|
-
if (!
|
|
7559
|
+
function M(w) {
|
|
7560
|
+
if (!w.isFile()) throw new Error("Path provided was not a file!");
|
|
7434
7561
|
}
|
|
7435
7562
|
return s(M, "isStatFile"), xe;
|
|
7436
7563
|
}
|
|
7437
|
-
s(
|
|
7438
|
-
var
|
|
7439
|
-
var
|
|
7440
|
-
return
|
|
7564
|
+
s(Wi, "requireLib");
|
|
7565
|
+
var Ki = Wi(), Fr = {}, Vi = s((function(e, t, r, n, i) {
|
|
7566
|
+
var o = new Worker(Fr[t] || (Fr[t] = URL.createObjectURL(new Blob([e + ';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'], { type: "text/javascript" }))));
|
|
7567
|
+
return o.onmessage = function(c) {
|
|
7441
7568
|
var l = c.data, h = l.$e$;
|
|
7442
7569
|
if (h) {
|
|
7443
|
-
var
|
|
7444
|
-
|
|
7445
|
-
} else
|
|
7446
|
-
},
|
|
7447
|
-
}), "wk"), K = Uint8Array, ie = Uint16Array, Ze = Int32Array, je = new K([0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0, 0, 0, 0]), qe = new K([0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 0, 0]), et = new K([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]),
|
|
7570
|
+
var g = new Error(h[0]);
|
|
7571
|
+
g.code = h[1], g.stack = h[2], i(g, null);
|
|
7572
|
+
} else i(null, l);
|
|
7573
|
+
}, o.postMessage(r, n), o;
|
|
7574
|
+
}), "wk"), K = Uint8Array, ie = Uint16Array, Ze = Int32Array, je = new K([0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0, 0, 0, 0]), qe = new K([0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 0, 0]), et = new K([16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15]), jr = s(function(e, t) {
|
|
7448
7575
|
for (var r = new ie(31), n = 0; n < 31; ++n) r[n] = t += 1 << e[n - 1];
|
|
7449
|
-
for (var
|
|
7450
|
-
return { b: r, r:
|
|
7451
|
-
}, "freb"),
|
|
7576
|
+
for (var i = new Ze(r[30]), n = 1; n < 30; ++n) for (var o = r[n]; o < r[n + 1]; ++o) i[o] = o - r[n] << 5 | n;
|
|
7577
|
+
return { b: r, r: i };
|
|
7578
|
+
}, "freb"), qr = jr(je, 2), Dt = qr.b, lt = qr.r;
|
|
7452
7579
|
Dt[28] = 258, lt[258] = 28;
|
|
7453
|
-
for (var
|
|
7580
|
+
for (var Wr = jr(qe, 0), Kr = Wr.b, Mt = Wr.r, tt = new ie(32768), V = 0; V < 32768; ++V) {
|
|
7454
7581
|
var Be = (V & 43690) >> 1 | (V & 21845) << 1;
|
|
7455
7582
|
Be = (Be & 52428) >> 2 | (Be & 13107) << 2, Be = (Be & 61680) >> 4 | (Be & 3855) << 4, tt[V] = ((Be & 65280) >> 8 | (Be & 255) << 8) >> 1;
|
|
7456
7583
|
}
|
|
7457
7584
|
for (var fe = s((function(e, t, r) {
|
|
7458
|
-
for (var n = e.length,
|
|
7585
|
+
for (var n = e.length, i = 0, o = new ie(t); i < n; ++i) e[i] && ++o[e[i] - 1];
|
|
7459
7586
|
var c = new ie(t);
|
|
7460
|
-
for (
|
|
7587
|
+
for (i = 1; i < t; ++i) c[i] = c[i - 1] + o[i - 1] << 1;
|
|
7461
7588
|
var l;
|
|
7462
7589
|
if (r) {
|
|
7463
7590
|
l = new ie(1 << t);
|
|
7464
7591
|
var h = 15 - t;
|
|
7465
|
-
for (
|
|
7466
|
-
} else for (l = new ie(n),
|
|
7592
|
+
for (i = 0; i < n; ++i) if (e[i]) for (var g = i << 4 | e[i], m = t - e[i], A = c[e[i] - 1]++ << m, b = A | (1 << m) - 1; A <= b; ++A) l[tt[A] >> h] = g;
|
|
7593
|
+
} else for (l = new ie(n), i = 0; i < n; ++i) e[i] && (l[i] = tt[c[e[i] - 1]++] >> 15 - e[i]);
|
|
7467
7594
|
return l;
|
|
7468
|
-
}), "hMap"),
|
|
7469
|
-
for (var V = 144; V < 256; ++V)
|
|
7470
|
-
for (var V = 256; V < 280; ++V)
|
|
7471
|
-
for (var V = 280; V < 288; ++V)
|
|
7595
|
+
}), "hMap"), we = new K(288), V = 0; V < 144; ++V) we[V] = 8;
|
|
7596
|
+
for (var V = 144; V < 256; ++V) we[V] = 9;
|
|
7597
|
+
for (var V = 256; V < 280; ++V) we[V] = 7;
|
|
7598
|
+
for (var V = 280; V < 288; ++V) we[V] = 8;
|
|
7472
7599
|
for (var We = new K(32), V = 0; V < 32; ++V) We[V] = 5;
|
|
7473
|
-
var
|
|
7600
|
+
var Vr = fe(we, 9, 0), Yr = fe(we, 9, 1), zr = fe(We, 5, 0), Jr = fe(We, 5, 1), ft = s(function(e) {
|
|
7474
7601
|
for (var t = e[0], r = 1; r < e.length; ++r) e[r] > t && (t = e[r]);
|
|
7475
7602
|
return t;
|
|
7476
7603
|
}, "max"), he = s(function(e, t, r) {
|
|
@@ -7483,52 +7610,52 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7483
7610
|
return (e + 7) / 8 | 0;
|
|
7484
7611
|
}, "shft"), Ge = s(function(e, t, r) {
|
|
7485
7612
|
return (t == null || t < 0) && (t = 0), (r == null || r > e.length) && (r = e.length), new K(e.subarray(t, r));
|
|
7486
|
-
}, "slc"),
|
|
7487
|
-
var n = new Error(t ||
|
|
7613
|
+
}, "slc"), Qr = ["unexpected EOF", "invalid block type", "invalid length/literal", "invalid distance", "stream finished", "no stream handler", , "no callback", "invalid UTF-8 data", "extra field too long", "date not in range 1980-2099", "filename too long", "stream finishing", "invalid zip data"], X = s(function(e, t, r) {
|
|
7614
|
+
var n = new Error(t || Qr[e]);
|
|
7488
7615
|
if (n.code = e, Error.captureStackTrace && Error.captureStackTrace(n, X), !r) throw n;
|
|
7489
7616
|
return n;
|
|
7490
|
-
}, "err"),
|
|
7491
|
-
var
|
|
7492
|
-
if (!
|
|
7617
|
+
}, "err"), Xr = s(function(e, t, r, n) {
|
|
7618
|
+
var i = e.length, o = n ? n.length : 0;
|
|
7619
|
+
if (!i || t.f && !t.l) return r || new K(0);
|
|
7493
7620
|
var c = !r, l = c || t.i != 2, h = t.i;
|
|
7494
|
-
c && (r = new K(
|
|
7495
|
-
var
|
|
7621
|
+
c && (r = new K(i * 3));
|
|
7622
|
+
var g = s(function(ne) {
|
|
7496
7623
|
var pe = r.length;
|
|
7497
7624
|
if (ne > pe) {
|
|
7498
7625
|
var Z = new K(Math.max(pe * 2, ne));
|
|
7499
7626
|
Z.set(r), r = Z;
|
|
7500
7627
|
}
|
|
7501
|
-
}, "cbuf"), m = t.f || 0, A = t.p || 0, b = t.b || 0, O = t.l, x = t.d, M = t.m,
|
|
7628
|
+
}, "cbuf"), m = t.f || 0, A = t.p || 0, b = t.b || 0, O = t.l, x = t.d, M = t.m, w = t.n, C = i * 8;
|
|
7502
7629
|
do {
|
|
7503
7630
|
if (!O) {
|
|
7504
7631
|
m = he(e, A, 1);
|
|
7505
|
-
var
|
|
7506
|
-
if (A += 3,
|
|
7507
|
-
else if (
|
|
7632
|
+
var y = he(e, A + 1, 3);
|
|
7633
|
+
if (A += 3, y) if (y == 1) O = Yr, x = Jr, M = 9, w = 5;
|
|
7634
|
+
else if (y == 2) {
|
|
7508
7635
|
var G = he(e, A, 31) + 257, k = he(e, A + 10, 15) + 4, a = G + he(e, A + 5, 31) + 1;
|
|
7509
7636
|
A += 14;
|
|
7510
|
-
for (var u = new K(a), f = new K(19),
|
|
7637
|
+
for (var u = new K(a), f = new K(19), _ = 0; _ < k; ++_) f[et[_]] = he(e, A + _ * 3, 7);
|
|
7511
7638
|
A += k * 3;
|
|
7512
|
-
for (var p = ft(f), I = (1 << p) - 1, T = fe(f, p, 1),
|
|
7639
|
+
for (var p = ft(f), I = (1 << p) - 1, T = fe(f, p, 1), _ = 0; _ < a; ) {
|
|
7513
7640
|
var d = T[he(e, A, I)];
|
|
7514
7641
|
A += d & 15;
|
|
7515
7642
|
var B = d >> 4;
|
|
7516
|
-
if (B < 16) u[
|
|
7643
|
+
if (B < 16) u[_++] = B;
|
|
7517
7644
|
else {
|
|
7518
7645
|
var E = 0, S = 0;
|
|
7519
|
-
for (B == 16 ? (S = 3 + he(e, A, 3), A += 2, E = u[
|
|
7646
|
+
for (B == 16 ? (S = 3 + he(e, A, 3), A += 2, E = u[_ - 1]) : B == 17 ? (S = 3 + he(e, A, 7), A += 3) : B == 18 && (S = 11 + he(e, A, 127), A += 7); S--; ) u[_++] = E;
|
|
7520
7647
|
}
|
|
7521
7648
|
}
|
|
7522
7649
|
var R = u.subarray(0, G), v = u.subarray(G);
|
|
7523
|
-
M = ft(R),
|
|
7650
|
+
M = ft(R), w = ft(v), O = fe(R, M, 1), x = fe(v, w, 1);
|
|
7524
7651
|
} else X(1);
|
|
7525
7652
|
else {
|
|
7526
7653
|
var B = rt(A) + 4, L = e[B - 4] | e[B - 3] << 8, U = B + L;
|
|
7527
|
-
if (U >
|
|
7654
|
+
if (U > i) {
|
|
7528
7655
|
h && X(0);
|
|
7529
7656
|
break;
|
|
7530
7657
|
}
|
|
7531
|
-
l &&
|
|
7658
|
+
l && g(b + L), r.set(e.subarray(B, U), b), t.b = b += L, t.p = A = U * 8, t.f = m;
|
|
7532
7659
|
continue;
|
|
7533
7660
|
}
|
|
7534
7661
|
if (A > C) {
|
|
@@ -7536,8 +7663,8 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7536
7663
|
break;
|
|
7537
7664
|
}
|
|
7538
7665
|
}
|
|
7539
|
-
l &&
|
|
7540
|
-
for (var N = (1 << M) - 1, P = (1 <<
|
|
7666
|
+
l && g(b + 131072);
|
|
7667
|
+
for (var N = (1 << M) - 1, P = (1 << w) - 1, H = A; ; H = A) {
|
|
7541
7668
|
var E = O[ht(e, A) & N], j = E >> 4;
|
|
7542
7669
|
if (A += E & 15, A > C) {
|
|
7543
7670
|
h && X(0);
|
|
@@ -7550,12 +7677,12 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7550
7677
|
} else {
|
|
7551
7678
|
var q = j - 254;
|
|
7552
7679
|
if (j > 264) {
|
|
7553
|
-
var
|
|
7554
|
-
q = he(e, A, (1 << D) - 1) + Dt[
|
|
7680
|
+
var _ = j - 257, D = je[_];
|
|
7681
|
+
q = he(e, A, (1 << D) - 1) + Dt[_], A += D;
|
|
7555
7682
|
}
|
|
7556
7683
|
var F = x[ht(e, A) & P], z = F >> 4;
|
|
7557
7684
|
F || X(3), A += F & 15;
|
|
7558
|
-
var v =
|
|
7685
|
+
var v = Kr[z];
|
|
7559
7686
|
if (z > 3) {
|
|
7560
7687
|
var D = qe[z];
|
|
7561
7688
|
v += ht(e, A) & (1 << D) - 1, A += D;
|
|
@@ -7564,16 +7691,16 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7564
7691
|
h && X(0);
|
|
7565
7692
|
break;
|
|
7566
7693
|
}
|
|
7567
|
-
l &&
|
|
7694
|
+
l && g(b + 131072);
|
|
7568
7695
|
var de = b + q;
|
|
7569
7696
|
if (b < v) {
|
|
7570
|
-
var ve =
|
|
7697
|
+
var ve = o - v, be = Math.min(v, de);
|
|
7571
7698
|
for (ve + b < 0 && X(3); b < be; ++b) r[b] = n[ve + b];
|
|
7572
7699
|
}
|
|
7573
7700
|
for (; b < de; ++b) r[b] = r[b - v];
|
|
7574
7701
|
}
|
|
7575
7702
|
}
|
|
7576
|
-
t.l = O, t.p = H, t.b = b, t.f = m, O && (m = 1, t.m = M, t.d = x, t.n =
|
|
7703
|
+
t.l = O, t.p = H, t.b = b, t.f = m, O && (m = 1, t.m = M, t.d = x, t.n = w);
|
|
7577
7704
|
} while (!m);
|
|
7578
7705
|
return b != r.length && c ? Ge(r, 0, b) : r.subarray(0, b);
|
|
7579
7706
|
}, "inflt"), ge = s(function(e, t, r) {
|
|
@@ -7586,34 +7713,34 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7586
7713
|
e[n] |= r, e[n + 1] |= r >> 8, e[n + 2] |= r >> 16;
|
|
7587
7714
|
}, "wbits16"), dt = s(function(e, t) {
|
|
7588
7715
|
for (var r = [], n = 0; n < e.length; ++n) e[n] && r.push({ s: n, f: e[n] });
|
|
7589
|
-
var
|
|
7590
|
-
if (!
|
|
7591
|
-
if (
|
|
7716
|
+
var i = r.length, o = r.slice();
|
|
7717
|
+
if (!i) return { t: kt, l: 0 };
|
|
7718
|
+
if (i == 1) {
|
|
7592
7719
|
var c = new K(r[0].s + 1);
|
|
7593
7720
|
return c[r[0].s] = 1, { t: c, l: 1 };
|
|
7594
7721
|
}
|
|
7595
7722
|
r.sort(function(U, G) {
|
|
7596
7723
|
return U.f - G.f;
|
|
7597
7724
|
}), r.push({ s: -1, f: 25001 });
|
|
7598
|
-
var l = r[0], h = r[1],
|
|
7599
|
-
for (r[0] = { s: -1, f: l.f + h.f, l, r: h }; m !=
|
|
7600
|
-
for (var b =
|
|
7725
|
+
var l = r[0], h = r[1], g = 0, m = 1, A = 2;
|
|
7726
|
+
for (r[0] = { s: -1, f: l.f + h.f, l, r: h }; m != i - 1; ) l = r[r[g].f < r[A].f ? g++ : A++], h = r[g != m && r[g].f < r[A].f ? g++ : A++], r[m++] = { s: -1, f: l.f + h.f, l, r: h };
|
|
7727
|
+
for (var b = o[0].s, n = 1; n < i; ++n) o[n].s > b && (b = o[n].s);
|
|
7601
7728
|
var O = new ie(b + 1), x = pt(r[m - 1], O, 0);
|
|
7602
7729
|
if (x > t) {
|
|
7603
|
-
var n = 0, M = 0,
|
|
7604
|
-
for (
|
|
7730
|
+
var n = 0, M = 0, w = x - t, C = 1 << w;
|
|
7731
|
+
for (o.sort(function(G, k) {
|
|
7605
7732
|
return O[k.s] - O[G.s] || G.f - k.f;
|
|
7606
|
-
}); n <
|
|
7607
|
-
var
|
|
7608
|
-
if (O[
|
|
7733
|
+
}); n < i; ++n) {
|
|
7734
|
+
var y = o[n].s;
|
|
7735
|
+
if (O[y] > t) M += C - (1 << x - O[y]), O[y] = t;
|
|
7609
7736
|
else break;
|
|
7610
7737
|
}
|
|
7611
|
-
for (M >>=
|
|
7612
|
-
var B =
|
|
7738
|
+
for (M >>= w; M > 0; ) {
|
|
7739
|
+
var B = o[n].s;
|
|
7613
7740
|
O[B] < t ? M -= 1 << t - O[B]++ - 1 : ++n;
|
|
7614
7741
|
}
|
|
7615
7742
|
for (; n >= 0 && M; --n) {
|
|
7616
|
-
var L =
|
|
7743
|
+
var L = o[n].s;
|
|
7617
7744
|
O[L] == t && (--O[L], ++M);
|
|
7618
7745
|
}
|
|
7619
7746
|
x = t;
|
|
@@ -7623,48 +7750,48 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7623
7750
|
return e.s == -1 ? Math.max(pt(e.l, t, r + 1), pt(e.r, t, r + 1)) : t[e.s] = r;
|
|
7624
7751
|
}, "ln"), xt = s(function(e) {
|
|
7625
7752
|
for (var t = e.length; t && !e[--t]; ) ;
|
|
7626
|
-
for (var r = new ie(++t), n = 0,
|
|
7753
|
+
for (var r = new ie(++t), n = 0, i = e[0], o = 1, c = s(function(h) {
|
|
7627
7754
|
r[n++] = h;
|
|
7628
|
-
}, "w"), l = 1; l <= t; ++l) if (e[l] ==
|
|
7755
|
+
}, "w"), l = 1; l <= t; ++l) if (e[l] == i && l != t) ++o;
|
|
7629
7756
|
else {
|
|
7630
|
-
if (!
|
|
7631
|
-
for (;
|
|
7632
|
-
|
|
7633
|
-
} else if (
|
|
7634
|
-
for (c(
|
|
7635
|
-
|
|
7757
|
+
if (!i && o > 2) {
|
|
7758
|
+
for (; o > 138; o -= 138) c(32754);
|
|
7759
|
+
o > 2 && (c(o > 10 ? o - 11 << 5 | 28690 : o - 3 << 5 | 12305), o = 0);
|
|
7760
|
+
} else if (o > 3) {
|
|
7761
|
+
for (c(i), --o; o > 6; o -= 6) c(8304);
|
|
7762
|
+
o > 2 && (c(o - 3 << 5 | 8208), o = 0);
|
|
7636
7763
|
}
|
|
7637
|
-
for (;
|
|
7638
|
-
|
|
7764
|
+
for (; o--; ) c(i);
|
|
7765
|
+
o = 1, i = e[l];
|
|
7639
7766
|
}
|
|
7640
7767
|
return { c: r.subarray(0, n), n: t };
|
|
7641
7768
|
}, "lc"), Ve = s(function(e, t) {
|
|
7642
7769
|
for (var r = 0, n = 0; n < t.length; ++n) r += e[n] * t[n];
|
|
7643
7770
|
return r;
|
|
7644
7771
|
}, "clen"), Gt = s(function(e, t, r) {
|
|
7645
|
-
var n = r.length,
|
|
7646
|
-
e[
|
|
7647
|
-
for (var
|
|
7648
|
-
return (
|
|
7649
|
-
}, "wfblk"), $t = s(function(e, t, r, n,
|
|
7650
|
-
ge(t, m++, r), ++
|
|
7651
|
-
for (var A = dt(
|
|
7772
|
+
var n = r.length, i = rt(t + 2);
|
|
7773
|
+
e[i] = n & 255, e[i + 1] = n >> 8, e[i + 2] = e[i] ^ 255, e[i + 3] = e[i + 1] ^ 255;
|
|
7774
|
+
for (var o = 0; o < n; ++o) e[i + o + 4] = r[o];
|
|
7775
|
+
return (i + 4 + n) * 8;
|
|
7776
|
+
}, "wfblk"), $t = s(function(e, t, r, n, i, o, c, l, h, g, m) {
|
|
7777
|
+
ge(t, m++, r), ++i[256];
|
|
7778
|
+
for (var A = dt(i, 15), b = A.t, O = A.l, x = dt(o, 15), M = x.t, w = x.l, C = xt(b), y = C.c, B = C.n, L = xt(M), U = L.c, G = L.n, k = new ie(19), a = 0; a < y.length; ++a) ++k[y[a] & 31];
|
|
7652
7779
|
for (var a = 0; a < U.length; ++a) ++k[U[a] & 31];
|
|
7653
|
-
for (var u = dt(k, 7), f = u.t,
|
|
7654
|
-
var I =
|
|
7655
|
-
if (h >= 0 && I <= T && I <= d) return Gt(t, m, e.subarray(h, h +
|
|
7780
|
+
for (var u = dt(k, 7), f = u.t, _ = u.l, p = 19; p > 4 && !f[et[p - 1]]; --p) ;
|
|
7781
|
+
var I = g + 5 << 3, T = Ve(i, we) + Ve(o, We) + c, d = Ve(i, b) + Ve(o, M) + c + 14 + 3 * p + Ve(k, f) + 2 * k[16] + 3 * k[17] + 7 * k[18];
|
|
7782
|
+
if (h >= 0 && I <= T && I <= d) return Gt(t, m, e.subarray(h, h + g));
|
|
7656
7783
|
var E, S, R, v;
|
|
7657
7784
|
if (ge(t, m, 1 + (d < T)), m += 2, d < T) {
|
|
7658
|
-
E = fe(b, O, 0), S = b, R = fe(M,
|
|
7659
|
-
var N = fe(f,
|
|
7785
|
+
E = fe(b, O, 0), S = b, R = fe(M, w, 0), v = M;
|
|
7786
|
+
var N = fe(f, _, 0);
|
|
7660
7787
|
ge(t, m, B - 257), ge(t, m + 5, G - 1), ge(t, m + 10, p - 4), m += 14;
|
|
7661
7788
|
for (var a = 0; a < p; ++a) ge(t, m + 3 * a, f[et[a]]);
|
|
7662
7789
|
m += 3 * p;
|
|
7663
|
-
for (var P = [
|
|
7790
|
+
for (var P = [y, U], H = 0; H < 2; ++H) for (var j = P[H], a = 0; a < j.length; ++a) {
|
|
7664
7791
|
var q = j[a] & 31;
|
|
7665
7792
|
ge(t, m, N[q]), m += f[q], q > 15 && (ge(t, m, j[a] >> 5 & 127), m += j[a] >> 12);
|
|
7666
7793
|
}
|
|
7667
|
-
} else E =
|
|
7794
|
+
} else E = Vr, S = we, R = zr, v = We;
|
|
7668
7795
|
for (var a = 0; a < l; ++a) {
|
|
7669
7796
|
var D = n[a];
|
|
7670
7797
|
if (D > 255) {
|
|
@@ -7675,17 +7802,17 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7675
7802
|
} else Ke(t, m, E[D]), m += S[D];
|
|
7676
7803
|
}
|
|
7677
7804
|
return Ke(t, m, E[256]), m + S[256];
|
|
7678
|
-
}, "wblk"),
|
|
7679
|
-
var c =
|
|
7805
|
+
}, "wblk"), Zr = new Ze([65540, 131080, 131088, 131104, 262176, 1048704, 1048832, 2114560, 2117632]), kt = new K(0), en = s(function(e, t, r, n, i, o) {
|
|
7806
|
+
var c = o.z || e.length, l = new K(n + c + 5 * (1 + Math.ceil(c / 7e3)) + i), h = l.subarray(n, l.length - i), g = o.l, m = (o.r || 0) & 7;
|
|
7680
7807
|
if (t) {
|
|
7681
|
-
m && (h[0] =
|
|
7682
|
-
for (var A =
|
|
7683
|
-
return (e[ee] ^ e[ee + 1] << C ^ e[ee + 2] <<
|
|
7684
|
-
}, "hsh"), L = new Ze(25e3), U = new ie(288), G = new ie(32), k = 0, a = 0, u =
|
|
7685
|
-
var I = B(u), T = u & 32767, d =
|
|
7686
|
-
if (M[T] = d,
|
|
7808
|
+
m && (h[0] = o.r >> 3);
|
|
7809
|
+
for (var A = Zr[t - 1], b = A >> 13, O = A & 8191, x = (1 << r) - 1, M = o.p || new ie(32768), w = o.h || new ie(x + 1), C = Math.ceil(r / 3), y = 2 * C, B = s(function(ee) {
|
|
7810
|
+
return (e[ee] ^ e[ee + 1] << C ^ e[ee + 2] << y) & x;
|
|
7811
|
+
}, "hsh"), L = new Ze(25e3), U = new ie(288), G = new ie(32), k = 0, a = 0, u = o.i || 0, f = 0, _ = o.w || 0, p = 0; u + 2 < c; ++u) {
|
|
7812
|
+
var I = B(u), T = u & 32767, d = w[I];
|
|
7813
|
+
if (M[T] = d, w[I] = T, _ <= u) {
|
|
7687
7814
|
var E = c - u;
|
|
7688
|
-
if ((k > 7e3 || f > 24576) && (E > 423 || !
|
|
7815
|
+
if ((k > 7e3 || f > 24576) && (E > 423 || !g)) {
|
|
7689
7816
|
m = $t(e, h, 0, L, U, G, a, f, p, u - p, m), f = k = a = 0, p = u;
|
|
7690
7817
|
for (var S = 0; S < 286; ++S) U[S] = 0;
|
|
7691
7818
|
for (var S = 0; S < 30; ++S) G[S] = 0;
|
|
@@ -7707,84 +7834,84 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7707
7834
|
if (v) {
|
|
7708
7835
|
L[f++] = 268435456 | lt[R] << 18 | Mt[v];
|
|
7709
7836
|
var ne = lt[R] & 31, pe = Mt[v] & 31;
|
|
7710
|
-
a += je[ne] + qe[pe], ++U[257 + ne], ++G[pe],
|
|
7837
|
+
a += je[ne] + qe[pe], ++U[257 + ne], ++G[pe], _ = u + R, ++k;
|
|
7711
7838
|
} else L[f++] = e[u], ++U[e[u]];
|
|
7712
7839
|
}
|
|
7713
7840
|
}
|
|
7714
|
-
for (u = Math.max(u,
|
|
7715
|
-
m = $t(e, h,
|
|
7841
|
+
for (u = Math.max(u, _); u < c; ++u) L[f++] = e[u], ++U[e[u]];
|
|
7842
|
+
m = $t(e, h, g, L, U, G, a, f, p, u - p, m), g || (o.r = m & 7 | h[m / 8 | 0] << 3, m -= 7, o.h = w, o.p = M, o.i = u, o.w = _);
|
|
7716
7843
|
} else {
|
|
7717
|
-
for (var u =
|
|
7844
|
+
for (var u = o.w || 0; u < c + g; u += 65535) {
|
|
7718
7845
|
var Z = u + 65535;
|
|
7719
|
-
Z >= c && (h[m / 8 | 0] =
|
|
7846
|
+
Z >= c && (h[m / 8 | 0] = g, Z = c), m = Gt(h, m + 1, e.subarray(u, Z));
|
|
7720
7847
|
}
|
|
7721
|
-
|
|
7848
|
+
o.i = c;
|
|
7722
7849
|
}
|
|
7723
|
-
return Ge(l, 0, n + rt(m) +
|
|
7724
|
-
}, "dflt"),
|
|
7850
|
+
return Ge(l, 0, n + rt(m) + i);
|
|
7851
|
+
}, "dflt"), Yi = (function() {
|
|
7725
7852
|
for (var e = new Int32Array(256), t = 0; t < 256; ++t) {
|
|
7726
7853
|
for (var r = t, n = 9; --n; ) r = (r & 1 && -306674912) ^ r >>> 1;
|
|
7727
7854
|
e[t] = r;
|
|
7728
7855
|
}
|
|
7729
7856
|
return e;
|
|
7730
|
-
})(),
|
|
7857
|
+
})(), zi = s(function() {
|
|
7731
7858
|
var e = -1;
|
|
7732
7859
|
return { p: s(function(t) {
|
|
7733
|
-
for (var r = e, n = 0; n < t.length; ++n) r =
|
|
7860
|
+
for (var r = e, n = 0; n < t.length; ++n) r = Yi[r & 255 ^ t[n]] ^ r >>> 8;
|
|
7734
7861
|
e = r;
|
|
7735
7862
|
}, "p"), d: s(function() {
|
|
7736
7863
|
return ~e;
|
|
7737
7864
|
}, "d") };
|
|
7738
|
-
}, "crc"),
|
|
7739
|
-
if (!
|
|
7740
|
-
var
|
|
7741
|
-
c.set(
|
|
7865
|
+
}, "crc"), tn = s(function(e, t, r, n, i) {
|
|
7866
|
+
if (!i && (i = { l: 1 }, t.dictionary)) {
|
|
7867
|
+
var o = t.dictionary.subarray(-32768), c = new K(o.length + e.length);
|
|
7868
|
+
c.set(o), c.set(e, o.length), e = c, i.w = o.length;
|
|
7742
7869
|
}
|
|
7743
|
-
return
|
|
7870
|
+
return en(e, t.level == null ? 6 : t.level, t.mem == null ? i.l ? Math.ceil(Math.max(8, Math.min(13, Math.log(e.length))) * 1.5) : 20 : 12 + t.mem, r, n, i);
|
|
7744
7871
|
}, "dopt"), Ht = s(function(e, t) {
|
|
7745
7872
|
var r = {};
|
|
7746
7873
|
for (var n in e) r[n] = e[n];
|
|
7747
7874
|
for (var n in t) r[n] = t[n];
|
|
7748
7875
|
return r;
|
|
7749
|
-
}, "mrg"),
|
|
7750
|
-
for (var n = e(),
|
|
7751
|
-
var l = n[c], h =
|
|
7876
|
+
}, "mrg"), rn = s(function(e, t, r) {
|
|
7877
|
+
for (var n = e(), i = e.toString(), o = i.slice(i.indexOf("[") + 1, i.lastIndexOf("]")).replace(/\s+/g, "").split(","), c = 0; c < n.length; ++c) {
|
|
7878
|
+
var l = n[c], h = o[c];
|
|
7752
7879
|
if (typeof l == "function") {
|
|
7753
7880
|
t += ";" + h + "=";
|
|
7754
|
-
var
|
|
7755
|
-
if (l.prototype) if (
|
|
7756
|
-
var m =
|
|
7757
|
-
t +=
|
|
7881
|
+
var g = l.toString();
|
|
7882
|
+
if (l.prototype) if (g.indexOf("[native code]") != -1) {
|
|
7883
|
+
var m = g.indexOf(" ", 8) + 1;
|
|
7884
|
+
t += g.slice(m, g.indexOf("(", m));
|
|
7758
7885
|
} else {
|
|
7759
|
-
t +=
|
|
7886
|
+
t += g;
|
|
7760
7887
|
for (var A in l.prototype) t += ";" + h + ".prototype." + A + "=" + l.prototype[A].toString();
|
|
7761
7888
|
}
|
|
7762
|
-
else t +=
|
|
7889
|
+
else t += g;
|
|
7763
7890
|
} else r[h] = l;
|
|
7764
7891
|
}
|
|
7765
7892
|
return t;
|
|
7766
|
-
}, "wcln"), mt = [],
|
|
7893
|
+
}, "wcln"), mt = [], Ji = s(function(e) {
|
|
7767
7894
|
var t = [];
|
|
7768
7895
|
for (var r in e) e[r].buffer && t.push((e[r] = new e[r].constructor(e[r])).buffer);
|
|
7769
7896
|
return t;
|
|
7770
|
-
}, "cbfs"),
|
|
7897
|
+
}, "cbfs"), Qi = s(function(e, t, r, n) {
|
|
7771
7898
|
if (!mt[r]) {
|
|
7772
|
-
for (var
|
|
7773
|
-
mt[r] = { c:
|
|
7899
|
+
for (var i = "", o = {}, c = e.length - 1, l = 0; l < c; ++l) i = rn(e[l], i, o);
|
|
7900
|
+
mt[r] = { c: rn(e[c], i, o), e: o };
|
|
7774
7901
|
}
|
|
7775
7902
|
var h = Ht({}, mt[r].e);
|
|
7776
|
-
return
|
|
7777
|
-
}, "wrkr"),
|
|
7778
|
-
return [K, ie, Ze, je, qe, et, Dt,
|
|
7779
|
-
}, "bInflt"),
|
|
7780
|
-
return [K, ie, Ze, je, qe, et, lt, Mt,
|
|
7903
|
+
return Vi(mt[r].c + ";onmessage=function(e){for(var k in e.data)self[k]=e.data[k];onmessage=" + t.toString() + "}", r, h, Ji(h), n);
|
|
7904
|
+
}, "wrkr"), Xi = s(function() {
|
|
7905
|
+
return [K, ie, Ze, je, qe, et, Dt, Kr, Yr, Jr, tt, Qr, fe, ft, he, ht, rt, Ge, X, Xr, qt, Et, nn];
|
|
7906
|
+
}, "bInflt"), Zi = s(function() {
|
|
7907
|
+
return [K, ie, Ze, je, qe, et, lt, Mt, Vr, we, zr, We, tt, Zr, kt, fe, ge, Ke, dt, pt, xt, Ve, Gt, $t, rt, Ge, en, tn, jt, Et];
|
|
7781
7908
|
}, "bDflt"), Et = s(function(e) {
|
|
7782
7909
|
return postMessage(e, [e.buffer]);
|
|
7783
|
-
}, "pbf"),
|
|
7910
|
+
}, "pbf"), nn = s(function(e) {
|
|
7784
7911
|
return e && { out: e.size && new K(e.size), dictionary: e.dictionary };
|
|
7785
|
-
}, "gopt"),
|
|
7786
|
-
var c =
|
|
7787
|
-
c.terminate(),
|
|
7912
|
+
}, "gopt"), on = s(function(e, t, r, n, i, o) {
|
|
7913
|
+
var c = Qi(r, n, i, function(l, h) {
|
|
7914
|
+
c.terminate(), o(l, h);
|
|
7788
7915
|
});
|
|
7789
7916
|
return c.postMessage([e, t], t.consume ? [e.buffer] : []), function() {
|
|
7790
7917
|
c.terminate();
|
|
@@ -7798,76 +7925,76 @@ var qr = fe(ye, 9, 0), Wr = fe(ye, 9, 1), Kr = fe(We, 5, 0), Vr = fe(We, 5, 1),
|
|
|
7798
7925
|
}, "b8"), re = s(function(e, t, r) {
|
|
7799
7926
|
for (; r; ++t) e[t] = r, r >>>= 8;
|
|
7800
7927
|
}, "wbytes");
|
|
7801
|
-
function
|
|
7802
|
-
return r || (r = t, t = {}), typeof r != "function" && X(7),
|
|
7928
|
+
function eo(e, t, r) {
|
|
7929
|
+
return r || (r = t, t = {}), typeof r != "function" && X(7), on(e, t, [Zi], function(n) {
|
|
7803
7930
|
return Et(jt(n.data[0], n.data[1]));
|
|
7804
7931
|
}, 0, r);
|
|
7805
7932
|
}
|
|
7806
|
-
s(
|
|
7933
|
+
s(eo, "deflate");
|
|
7807
7934
|
function jt(e, t) {
|
|
7808
|
-
return
|
|
7935
|
+
return tn(e, t || {}, 0, 0);
|
|
7809
7936
|
}
|
|
7810
7937
|
s(jt, "deflateSync");
|
|
7811
|
-
function
|
|
7812
|
-
return r || (r = t, t = {}), typeof r != "function" && X(7),
|
|
7813
|
-
return Et(qt(n.data[0],
|
|
7938
|
+
function to(e, t, r) {
|
|
7939
|
+
return r || (r = t, t = {}), typeof r != "function" && X(7), on(e, t, [Xi], function(n) {
|
|
7940
|
+
return Et(qt(n.data[0], nn(n.data[1])));
|
|
7814
7941
|
}, 1, r);
|
|
7815
7942
|
}
|
|
7816
|
-
s(
|
|
7943
|
+
s(to, "inflate");
|
|
7817
7944
|
function qt(e, t) {
|
|
7818
|
-
return
|
|
7945
|
+
return Xr(e, { i: 2 }, t && t.out, t && t.dictionary);
|
|
7819
7946
|
}
|
|
7820
7947
|
s(qt, "inflateSync");
|
|
7821
|
-
var
|
|
7822
|
-
for (var
|
|
7823
|
-
var
|
|
7824
|
-
Array.isArray(
|
|
7948
|
+
var sn = s(function(e, t, r, n) {
|
|
7949
|
+
for (var i in e) {
|
|
7950
|
+
var o = e[i], c = t + i, l = n;
|
|
7951
|
+
Array.isArray(o) && (l = Ht(n, o[1]), o = o[0]), o instanceof K ? r[c] = [o, l] : (r[c += "/"] = [new K(0), l], sn(o, c, r, n));
|
|
7825
7952
|
}
|
|
7826
|
-
}, "fltn"),
|
|
7953
|
+
}, "fltn"), an = typeof TextEncoder < "u" && new TextEncoder(), Wt = typeof TextDecoder < "u" && new TextDecoder(), ro = 0;
|
|
7827
7954
|
try {
|
|
7828
|
-
Wt.decode(kt, { stream: true }),
|
|
7955
|
+
Wt.decode(kt, { stream: true }), ro = 1;
|
|
7829
7956
|
} catch {
|
|
7830
7957
|
}
|
|
7831
|
-
var
|
|
7958
|
+
var no = s(function(e) {
|
|
7832
7959
|
for (var t = "", r = 0; ; ) {
|
|
7833
|
-
var n = e[r++],
|
|
7834
|
-
if (r +
|
|
7835
|
-
|
|
7960
|
+
var n = e[r++], i = (n > 127) + (n > 223) + (n > 239);
|
|
7961
|
+
if (r + i > e.length) return { s: t, r: Ge(e, r - 1) };
|
|
7962
|
+
i ? i == 3 ? (n = ((n & 15) << 18 | (e[r++] & 63) << 12 | (e[r++] & 63) << 6 | e[r++] & 63) - 65536, t += String.fromCharCode(55296 | n >> 10, 56320 | n & 1023)) : i & 1 ? t += String.fromCharCode((n & 31) << 6 | e[r++] & 63) : t += String.fromCharCode((n & 15) << 12 | (e[r++] & 63) << 6 | e[r++] & 63) : t += String.fromCharCode(n);
|
|
7836
7963
|
}
|
|
7837
7964
|
}, "dutf8");
|
|
7838
|
-
function
|
|
7965
|
+
function cn(e, t) {
|
|
7839
7966
|
var r;
|
|
7840
|
-
if (
|
|
7841
|
-
for (var n = e.length,
|
|
7842
|
-
o
|
|
7967
|
+
if (an) return an.encode(e);
|
|
7968
|
+
for (var n = e.length, i = new K(e.length + (e.length >> 1)), o = 0, c = s(function(g) {
|
|
7969
|
+
i[o++] = g;
|
|
7843
7970
|
}, "w"), r = 0; r < n; ++r) {
|
|
7844
|
-
if (
|
|
7845
|
-
var l = new K(
|
|
7846
|
-
l.set(
|
|
7971
|
+
if (o + 5 > i.length) {
|
|
7972
|
+
var l = new K(o + 8 + (n - r << 1));
|
|
7973
|
+
l.set(i), i = l;
|
|
7847
7974
|
}
|
|
7848
7975
|
var h = e.charCodeAt(r);
|
|
7849
7976
|
h < 128 || t ? c(h) : h < 2048 ? (c(192 | h >> 6), c(128 | h & 63)) : h > 55295 && h < 57344 ? (h = 65536 + (h & 1047552) | e.charCodeAt(++r) & 1023, c(240 | h >> 18), c(128 | h >> 12 & 63), c(128 | h >> 6 & 63), c(128 | h & 63)) : (c(224 | h >> 12), c(128 | h >> 6 & 63), c(128 | h & 63));
|
|
7850
7977
|
}
|
|
7851
|
-
return Ge(
|
|
7978
|
+
return Ge(i, 0, o);
|
|
7852
7979
|
}
|
|
7853
|
-
s(
|
|
7854
|
-
function
|
|
7980
|
+
s(cn, "strToU8");
|
|
7981
|
+
function io(e, t) {
|
|
7855
7982
|
if (t) {
|
|
7856
7983
|
for (var r = "", n = 0; n < e.length; n += 16384) r += String.fromCharCode.apply(null, e.subarray(n, n + 16384));
|
|
7857
7984
|
return r;
|
|
7858
7985
|
} else {
|
|
7859
7986
|
if (Wt) return Wt.decode(e);
|
|
7860
|
-
var
|
|
7861
|
-
return r.length && X(8),
|
|
7987
|
+
var i = no(e), o = i.s, r = i.r;
|
|
7988
|
+
return r.length && X(8), o;
|
|
7862
7989
|
}
|
|
7863
7990
|
}
|
|
7864
|
-
s(
|
|
7865
|
-
var
|
|
7991
|
+
s(io, "strFromU8");
|
|
7992
|
+
var oo = s(function(e, t) {
|
|
7866
7993
|
return t + 30 + Ie(e, t + 26) + Ie(e, t + 28);
|
|
7867
|
-
}, "slzh"),
|
|
7868
|
-
var n = Ie(e, t + 28),
|
|
7869
|
-
return [Ie(e, t + 10), h,
|
|
7870
|
-
}, "zh"),
|
|
7994
|
+
}, "slzh"), so = s(function(e, t, r) {
|
|
7995
|
+
var n = Ie(e, t + 28), i = io(e.subarray(t + 46, t + 46 + n), !(Ie(e, t + 8) & 2048)), o = t + 46 + n, c = Ee(e, t + 20), l = r && c == 4294967295 ? ao(e, o) : [c, Ee(e, t + 24), Ee(e, t + 42)], h = l[0], g = l[1], m = l[2];
|
|
7996
|
+
return [Ie(e, t + 10), h, g, i, o + Ie(e, t + 30) + Ie(e, t + 32), m];
|
|
7997
|
+
}, "zh"), ao = s(function(e, t) {
|
|
7871
7998
|
for (; Ie(e, t) != 1; t += 4 + Ie(e, t + 2)) ;
|
|
7872
7999
|
return [Ft(e, t + 12), Ft(e, t + 4), Ft(e, t + 20)];
|
|
7873
8000
|
}, "z64e"), Kt = s(function(e) {
|
|
@@ -7877,57 +8004,57 @@ var Zi = s(function(e, t) {
|
|
|
7877
8004
|
n > 65535 && X(9), t += n + 4;
|
|
7878
8005
|
}
|
|
7879
8006
|
return t;
|
|
7880
|
-
}, "exfl"),
|
|
7881
|
-
var h = n.length,
|
|
7882
|
-
re(e, t, c != null ? 33639248 : 67324752), t += 4, c != null && (e[t++] = 20, e[t++] = r.os), e[t] = 20, t += 2, e[t++] = r.flag << 1 | (
|
|
8007
|
+
}, "exfl"), un = s(function(e, t, r, n, i, o, c, l) {
|
|
8008
|
+
var h = n.length, g = r.extra, m = l && l.length, A = Kt(g);
|
|
8009
|
+
re(e, t, c != null ? 33639248 : 67324752), t += 4, c != null && (e[t++] = 20, e[t++] = r.os), e[t] = 20, t += 2, e[t++] = r.flag << 1 | (o < 0 && 8), e[t++] = i && 8, e[t++] = r.compression & 255, e[t++] = r.compression >> 8;
|
|
7883
8010
|
var b = new Date(r.mtime == null ? Date.now() : r.mtime), O = b.getFullYear() - 1980;
|
|
7884
|
-
if ((O < 0 || O > 119) && X(10), re(e, t, O << 25 | b.getMonth() + 1 << 21 | b.getDate() << 16 | b.getHours() << 11 | b.getMinutes() << 5 | b.getSeconds() >> 1), t += 4,
|
|
7885
|
-
var M =
|
|
7886
|
-
re(e, t, +x), re(e, t + 2,
|
|
8011
|
+
if ((O < 0 || O > 119) && X(10), re(e, t, O << 25 | b.getMonth() + 1 << 21 | b.getDate() << 16 | b.getHours() << 11 | b.getMinutes() << 5 | b.getSeconds() >> 1), t += 4, o != -1 && (re(e, t, r.crc), re(e, t + 4, o < 0 ? -o - 2 : o), re(e, t + 8, r.size)), re(e, t + 12, h), re(e, t + 14, A), t += 16, c != null && (re(e, t, m), re(e, t + 6, r.attrs), re(e, t + 10, c), t += 14), e.set(n, t), t += h, A) for (var x in g) {
|
|
8012
|
+
var M = g[x], w = M.length;
|
|
8013
|
+
re(e, t, +x), re(e, t + 2, w), e.set(M, t + 4), t += 4 + w;
|
|
7887
8014
|
}
|
|
7888
8015
|
return m && (e.set(l, t), t += m), t;
|
|
7889
|
-
}, "wzh"),
|
|
7890
|
-
re(e, t, 101010256), re(e, t + 8, r), re(e, t + 10, r), re(e, t + 12, n), re(e, t + 16,
|
|
8016
|
+
}, "wzh"), co = s(function(e, t, r, n, i) {
|
|
8017
|
+
re(e, t, 101010256), re(e, t + 8, r), re(e, t + 10, r), re(e, t + 12, n), re(e, t + 16, i);
|
|
7891
8018
|
}, "wzf");
|
|
7892
|
-
function
|
|
8019
|
+
function uo(e, t, r) {
|
|
7893
8020
|
r || (r = t, t = {}), typeof r != "function" && X(7);
|
|
7894
8021
|
var n = {};
|
|
7895
|
-
|
|
7896
|
-
var
|
|
7897
|
-
for (var
|
|
7898
|
-
}, "tAll"), b = s(function(
|
|
8022
|
+
sn(e, "", n, t);
|
|
8023
|
+
var i = Object.keys(n), o = i.length, c = 0, l = 0, h = o, g = new Array(o), m = [], A = s(function() {
|
|
8024
|
+
for (var w = 0; w < m.length; ++w) m[w]();
|
|
8025
|
+
}, "tAll"), b = s(function(w, C) {
|
|
7899
8026
|
_t(function() {
|
|
7900
|
-
r(
|
|
8027
|
+
r(w, C);
|
|
7901
8028
|
});
|
|
7902
8029
|
}, "cbd");
|
|
7903
8030
|
_t(function() {
|
|
7904
8031
|
b = r;
|
|
7905
8032
|
});
|
|
7906
8033
|
var O = s(function() {
|
|
7907
|
-
var
|
|
8034
|
+
var w = new K(l + 22), C = c, y = l - c;
|
|
7908
8035
|
l = 0;
|
|
7909
8036
|
for (var B = 0; B < h; ++B) {
|
|
7910
|
-
var L =
|
|
8037
|
+
var L = g[B];
|
|
7911
8038
|
try {
|
|
7912
8039
|
var U = L.c.length;
|
|
7913
|
-
|
|
8040
|
+
un(w, l, L, L.f, L.u, U);
|
|
7914
8041
|
var G = 30 + L.f.length + Kt(L.extra), k = l + G;
|
|
7915
|
-
|
|
8042
|
+
w.set(L.c, k), un(w, c, L, L.f, L.u, U, l, L.m), c += 16 + G + (L.m ? L.m.length : 0), l = k + U;
|
|
7916
8043
|
} catch (a) {
|
|
7917
8044
|
return b(a, null);
|
|
7918
8045
|
}
|
|
7919
8046
|
}
|
|
7920
|
-
|
|
8047
|
+
co(w, c, g.length, y, C), b(null, w);
|
|
7921
8048
|
}, "cbf");
|
|
7922
|
-
|
|
7923
|
-
for (var x = s(function(
|
|
7924
|
-
var C =
|
|
8049
|
+
o || O();
|
|
8050
|
+
for (var x = s(function(w) {
|
|
8051
|
+
var C = i[w], y = n[C], B = y[0], L = y[1], U = zi(), G = B.length;
|
|
7925
8052
|
U.p(B);
|
|
7926
|
-
var k =
|
|
8053
|
+
var k = cn(C), a = k.length, u = L.comment, f = u && cn(u), _ = f && f.length, p = Kt(L.extra), I = L.level == 0 ? 0 : 8, T = s(function(d, E) {
|
|
7927
8054
|
if (d) A(), b(d, null);
|
|
7928
8055
|
else {
|
|
7929
8056
|
var S = E.length;
|
|
7930
|
-
|
|
8057
|
+
g[w] = Ht(L, { size: G, crc: U.d(), c: E, f: k, m: f, u: a != C.length || f && u.length != _, compression: I }), c += 30 + a + p + S, l += 76 + 2 * (a + p) + (_ || 0) + S, --o || O();
|
|
7931
8058
|
}
|
|
7932
8059
|
}, "cbl");
|
|
7933
8060
|
if (a > 65535 && T(X(11, 0, 1), null), !I) T(null, B);
|
|
@@ -7936,87 +8063,87 @@ function no(e, t, r) {
|
|
|
7936
8063
|
} catch (d) {
|
|
7937
8064
|
T(d, null);
|
|
7938
8065
|
}
|
|
7939
|
-
else m.push(
|
|
8066
|
+
else m.push(eo(B, L, T));
|
|
7940
8067
|
}, "_loop_1"), M = 0; M < h; ++M) x(M);
|
|
7941
8068
|
return A;
|
|
7942
8069
|
}
|
|
7943
|
-
s(
|
|
8070
|
+
s(uo, "zip");
|
|
7944
8071
|
var _t = typeof queueMicrotask == "function" ? queueMicrotask : typeof setTimeout == "function" ? setTimeout : function(e) {
|
|
7945
8072
|
e();
|
|
7946
8073
|
};
|
|
7947
|
-
function
|
|
8074
|
+
function lo(e, t, r) {
|
|
7948
8075
|
r || (r = t, t = {}), typeof r != "function" && X(7);
|
|
7949
|
-
var n = [],
|
|
7950
|
-
for (var
|
|
7951
|
-
}, "tAll"),
|
|
8076
|
+
var n = [], i = s(function() {
|
|
8077
|
+
for (var w = 0; w < n.length; ++w) n[w]();
|
|
8078
|
+
}, "tAll"), o = {}, c = s(function(w, C) {
|
|
7952
8079
|
_t(function() {
|
|
7953
|
-
r(
|
|
8080
|
+
r(w, C);
|
|
7954
8081
|
});
|
|
7955
8082
|
}, "cbd");
|
|
7956
8083
|
_t(function() {
|
|
7957
8084
|
c = r;
|
|
7958
8085
|
});
|
|
7959
|
-
for (var l = e.length - 22; Ee(e, l) != 101010256; --l) if (!l || e.length - l > 65558) return c(X(13, 0, 1), null),
|
|
8086
|
+
for (var l = e.length - 22; Ee(e, l) != 101010256; --l) if (!l || e.length - l > 65558) return c(X(13, 0, 1), null), i;
|
|
7960
8087
|
var h = Ie(e, l + 8);
|
|
7961
8088
|
if (h) {
|
|
7962
|
-
var
|
|
8089
|
+
var g = h, m = Ee(e, l + 16), A = m == 4294967295 || g == 65535;
|
|
7963
8090
|
if (A) {
|
|
7964
8091
|
var b = Ee(e, l - 12);
|
|
7965
|
-
A = Ee(e, b) == 101075792, A && (
|
|
8092
|
+
A = Ee(e, b) == 101075792, A && (g = h = Ee(e, b + 32), m = Ee(e, b + 48));
|
|
7966
8093
|
}
|
|
7967
|
-
for (var O = t && t.filter, x = s(function(
|
|
7968
|
-
var C =
|
|
8094
|
+
for (var O = t && t.filter, x = s(function(w) {
|
|
8095
|
+
var C = so(e, m, A), y = C[0], B = C[1], L = C[2], U = C[3], G = C[4], k = C[5], a = oo(e, k);
|
|
7969
8096
|
m = G;
|
|
7970
|
-
var u = s(function(
|
|
7971
|
-
|
|
8097
|
+
var u = s(function(_, p) {
|
|
8098
|
+
_ ? (i(), c(_, null)) : (p && (o[U] = p), --h || c(null, o));
|
|
7972
8099
|
}, "cbl");
|
|
7973
|
-
if (!O || O({ name: U, size: B, originalSize: L, compression:
|
|
7974
|
-
else if (
|
|
8100
|
+
if (!O || O({ name: U, size: B, originalSize: L, compression: y })) if (!y) u(null, Ge(e, a, a + B));
|
|
8101
|
+
else if (y == 8) {
|
|
7975
8102
|
var f = e.subarray(a, a + B);
|
|
7976
8103
|
if (L < 524288 || B > 0.8 * L) try {
|
|
7977
8104
|
u(null, qt(f, { out: new K(L) }));
|
|
7978
|
-
} catch (
|
|
7979
|
-
u(
|
|
8105
|
+
} catch (_) {
|
|
8106
|
+
u(_, null);
|
|
7980
8107
|
}
|
|
7981
|
-
else n.push(
|
|
7982
|
-
} else u(X(14, "unknown compression type " +
|
|
8108
|
+
else n.push(to(f, { size: L }, u));
|
|
8109
|
+
} else u(X(14, "unknown compression type " + y, 1), null);
|
|
7983
8110
|
else u(null, null);
|
|
7984
|
-
}, "_loop_3"), M = 0; M <
|
|
8111
|
+
}, "_loop_3"), M = 0; M < g; ++M) x(M);
|
|
7985
8112
|
} else c(null, {});
|
|
7986
|
-
return
|
|
8113
|
+
return i;
|
|
7987
8114
|
}
|
|
7988
|
-
s(
|
|
7989
|
-
const
|
|
7990
|
-
function
|
|
7991
|
-
return e.filter((t) => !(t.length <
|
|
8115
|
+
s(lo, "unzip");
|
|
8116
|
+
const fo = [/^\/$/, /^\*+$/, /^[0-9]+$/], ho = ["/artifact/", "https://", "http://", "*********"], po = 3;
|
|
8117
|
+
function ln(e) {
|
|
8118
|
+
return e.filter((t) => !(t.length < po || fo.some((r) => r.test(t)) || ho.some((r) => t.includes(r))));
|
|
7992
8119
|
}
|
|
7993
|
-
s(
|
|
7994
|
-
const Ae = Symbol.for("@ts-pattern/matcher"),
|
|
8120
|
+
s(ln, "filterSensitiveValues");
|
|
8121
|
+
const Ae = Symbol.for("@ts-pattern/matcher"), mo = Symbol.for("@ts-pattern/isVariadic"), gt = "@ts-pattern/anonymous-select-key", Vt = s((e) => !!(e && typeof e == "object"), "r"), It = s((e) => e && !!e[Ae], "i"), Se = s((e, t, r) => {
|
|
7995
8122
|
if (It(e)) {
|
|
7996
|
-
const n = e[Ae](), { matched:
|
|
7997
|
-
return
|
|
8123
|
+
const n = e[Ae](), { matched: i, selections: o } = n.match(t);
|
|
8124
|
+
return i && o && Object.keys(o).forEach((c) => r(c, o[c])), i;
|
|
7998
8125
|
}
|
|
7999
8126
|
if (Vt(e)) {
|
|
8000
8127
|
if (!Vt(t)) return false;
|
|
8001
8128
|
if (Array.isArray(e)) {
|
|
8002
8129
|
if (!Array.isArray(t)) return false;
|
|
8003
|
-
let n = [],
|
|
8130
|
+
let n = [], i = [], o = [];
|
|
8004
8131
|
for (const c of e.keys()) {
|
|
8005
8132
|
const l = e[c];
|
|
8006
|
-
It(l) && l[
|
|
8133
|
+
It(l) && l[mo] ? o.push(l) : o.length ? i.push(l) : n.push(l);
|
|
8007
8134
|
}
|
|
8008
|
-
if (
|
|
8009
|
-
if (
|
|
8010
|
-
if (t.length < n.length +
|
|
8011
|
-
const c = t.slice(0, n.length), l =
|
|
8012
|
-
return n.every((
|
|
8135
|
+
if (o.length) {
|
|
8136
|
+
if (o.length > 1) throw new Error("Pattern error: Using `...P.array(...)` several times in a single pattern is not allowed.");
|
|
8137
|
+
if (t.length < n.length + i.length) return false;
|
|
8138
|
+
const c = t.slice(0, n.length), l = i.length === 0 ? [] : t.slice(-i.length), h = t.slice(n.length, i.length === 0 ? 1 / 0 : -i.length);
|
|
8139
|
+
return n.every((g, m) => Se(g, c[m], r)) && i.every((g, m) => Se(g, l[m], r)) && (o.length === 0 || Se(o[0], h, r));
|
|
8013
8140
|
}
|
|
8014
8141
|
return e.length === t.length && e.every((c, l) => Se(c, t[l], r));
|
|
8015
8142
|
}
|
|
8016
8143
|
return Reflect.ownKeys(e).every((n) => {
|
|
8017
|
-
const
|
|
8018
|
-
return (n in t || It(
|
|
8019
|
-
var
|
|
8144
|
+
const i = e[n];
|
|
8145
|
+
return (n in t || It(o = i) && o[Ae]().matcherType === "optional") && Se(i, t[n], r);
|
|
8146
|
+
var o;
|
|
8020
8147
|
});
|
|
8021
8148
|
}
|
|
8022
8149
|
return Object.is(t, e);
|
|
@@ -8025,57 +8152,57 @@ const Ae = Symbol.for("@ts-pattern/matcher"), co = Symbol.for("@ts-pattern/isVar
|
|
|
8025
8152
|
return Vt(e) ? It(e) ? (t = (r = (n = e[Ae]()).getSelectionKeys) == null ? void 0 : r.call(n)) != null ? t : [] : Array.isArray(e) ? nt(e, Oe) : nt(Object.values(e), Oe) : [];
|
|
8026
8153
|
}, "s"), nt = s((e, t) => e.reduce((r, n) => r.concat(t(n)), []), "c");
|
|
8027
8154
|
function ae(e) {
|
|
8028
|
-
return Object.assign(e, { optional: s(() =>
|
|
8155
|
+
return Object.assign(e, { optional: s(() => Eo(e), "optional"), and: s((t) => Y(e, t), "and"), or: s((t) => _o(e, t), "or"), select: s((t) => t === void 0 ? fn(e) : fn(t, e), "select") });
|
|
8029
8156
|
}
|
|
8030
8157
|
s(ae, "a");
|
|
8031
|
-
function
|
|
8158
|
+
function Eo(e) {
|
|
8032
8159
|
return ae({ [Ae]: () => ({ match: s((t) => {
|
|
8033
8160
|
let r = {};
|
|
8034
|
-
const n = s((
|
|
8035
|
-
r[
|
|
8161
|
+
const n = s((i, o) => {
|
|
8162
|
+
r[i] = o;
|
|
8036
8163
|
}, "r2");
|
|
8037
|
-
return t === void 0 ? (Oe(e).forEach((
|
|
8164
|
+
return t === void 0 ? (Oe(e).forEach((i) => n(i, void 0)), { matched: true, selections: r }) : { matched: Se(e, t, n), selections: r };
|
|
8038
8165
|
}, "match"), getSelectionKeys: s(() => Oe(e), "getSelectionKeys"), matcherType: "optional" }) });
|
|
8039
8166
|
}
|
|
8040
|
-
s(
|
|
8167
|
+
s(Eo, "h");
|
|
8041
8168
|
function Y(...e) {
|
|
8042
8169
|
return ae({ [Ae]: () => ({ match: s((t) => {
|
|
8043
8170
|
let r = {};
|
|
8044
|
-
const n = s((
|
|
8045
|
-
r[
|
|
8171
|
+
const n = s((i, o) => {
|
|
8172
|
+
r[i] = o;
|
|
8046
8173
|
}, "r2");
|
|
8047
|
-
return { matched: e.every((
|
|
8174
|
+
return { matched: e.every((i) => Se(i, t, n)), selections: r };
|
|
8048
8175
|
}, "match"), getSelectionKeys: s(() => nt(e, Oe), "getSelectionKeys"), matcherType: "and" }) });
|
|
8049
8176
|
}
|
|
8050
8177
|
s(Y, "d");
|
|
8051
|
-
function
|
|
8178
|
+
function _o(...e) {
|
|
8052
8179
|
return ae({ [Ae]: () => ({ match: s((t) => {
|
|
8053
8180
|
let r = {};
|
|
8054
|
-
const n = s((
|
|
8055
|
-
r[
|
|
8181
|
+
const n = s((i, o) => {
|
|
8182
|
+
r[i] = o;
|
|
8056
8183
|
}, "r2");
|
|
8057
|
-
return nt(e, Oe).forEach((
|
|
8184
|
+
return nt(e, Oe).forEach((i) => n(i, void 0)), { matched: e.some((i) => Se(i, t, n)), selections: r };
|
|
8058
8185
|
}, "match"), getSelectionKeys: s(() => nt(e, Oe), "getSelectionKeys"), matcherType: "or" }) });
|
|
8059
8186
|
}
|
|
8060
|
-
s(
|
|
8187
|
+
s(_o, "y");
|
|
8061
8188
|
function W(e) {
|
|
8062
8189
|
return { [Ae]: () => ({ match: s((t) => ({ matched: !!e(t) }), "match") }) };
|
|
8063
8190
|
}
|
|
8064
8191
|
s(W, "p");
|
|
8065
|
-
function
|
|
8192
|
+
function fn(...e) {
|
|
8066
8193
|
const t = typeof e[0] == "string" ? e[0] : void 0, r = e.length === 2 ? e[1] : typeof e[0] == "string" ? void 0 : e[0];
|
|
8067
8194
|
return ae({ [Ae]: () => ({ match: s((n) => {
|
|
8068
|
-
let
|
|
8069
|
-
return { matched: r === void 0 || Se(r, n, (
|
|
8070
|
-
o
|
|
8071
|
-
}), selections:
|
|
8195
|
+
let i = { [t ?? gt]: n };
|
|
8196
|
+
return { matched: r === void 0 || Se(r, n, (o, c) => {
|
|
8197
|
+
i[o] = c;
|
|
8198
|
+
}), selections: i };
|
|
8072
8199
|
}, "match"), getSelectionKeys: s(() => [t ?? gt].concat(r === void 0 ? [] : Oe(r)), "getSelectionKeys") }) });
|
|
8073
8200
|
}
|
|
8074
|
-
s(
|
|
8075
|
-
function
|
|
8201
|
+
s(fn, "v");
|
|
8202
|
+
function hn(e) {
|
|
8076
8203
|
return true;
|
|
8077
8204
|
}
|
|
8078
|
-
s(
|
|
8205
|
+
s(hn, "b");
|
|
8079
8206
|
function Re(e) {
|
|
8080
8207
|
return typeof e == "number";
|
|
8081
8208
|
}
|
|
@@ -8087,7 +8214,7 @@ s(Le, "S");
|
|
|
8087
8214
|
function Pe(e) {
|
|
8088
8215
|
return typeof e == "bigint";
|
|
8089
8216
|
}
|
|
8090
|
-
s(Pe, "j"), ae(W(
|
|
8217
|
+
s(Pe, "j"), ae(W(hn)), ae(W(hn));
|
|
8091
8218
|
const Ne = s((e) => Object.assign(ae(e), { startsWith: s((t) => {
|
|
8092
8219
|
return Ne(Y(e, (r = t, W((n) => Le(n) && n.startsWith(r)))));
|
|
8093
8220
|
var r;
|
|
@@ -8102,9 +8229,9 @@ const Ne = s((e) => Object.assign(ae(e), { startsWith: s((t) => {
|
|
|
8102
8229
|
var r;
|
|
8103
8230
|
}, "regex") }), "x");
|
|
8104
8231
|
Ne(W(Le));
|
|
8105
|
-
const Te = s((e) => Object.assign(ae(e), { between: s((t, r) => Te(Y(e, ((n,
|
|
8232
|
+
const Te = s((e) => Object.assign(ae(e), { between: s((t, r) => Te(Y(e, ((n, i) => W((o) => Re(o) && n <= o && i >= o))(t, r))), "between"), lt: s((t) => Te(Y(e, ((r) => W((n) => Re(n) && n < r))(t))), "lt"), gt: s((t) => Te(Y(e, ((r) => W((n) => Re(n) && n > r))(t))), "gt"), lte: s((t) => Te(Y(e, ((r) => W((n) => Re(n) && n <= r))(t))), "lte"), gte: s((t) => Te(Y(e, ((r) => W((n) => Re(n) && n >= r))(t))), "gte"), int: s(() => Te(Y(e, W((t) => Re(t) && Number.isInteger(t)))), "int"), finite: s(() => Te(Y(e, W((t) => Re(t) && Number.isFinite(t)))), "finite"), positive: s(() => Te(Y(e, W((t) => Re(t) && t > 0))), "positive"), negative: s(() => Te(Y(e, W((t) => Re(t) && t < 0))), "negative") }), "N");
|
|
8106
8233
|
Te(W(Re));
|
|
8107
|
-
const De = s((e) => Object.assign(ae(e), { between: s((t, r) => De(Y(e, ((n,
|
|
8234
|
+
const De = s((e) => Object.assign(ae(e), { between: s((t, r) => De(Y(e, ((n, i) => W((o) => Pe(o) && n <= o && i >= o))(t, r))), "between"), lt: s((t) => De(Y(e, ((r) => W((n) => Pe(n) && n < r))(t))), "lt"), gt: s((t) => De(Y(e, ((r) => W((n) => Pe(n) && n > r))(t))), "gt"), lte: s((t) => De(Y(e, ((r) => W((n) => Pe(n) && n <= r))(t))), "lte"), gte: s((t) => De(Y(e, ((r) => W((n) => Pe(n) && n >= r))(t))), "gte"), positive: s(() => De(Y(e, W((t) => Pe(t) && t > 0))), "positive"), negative: s(() => De(Y(e, W((t) => Pe(t) && t < 0))), "negative") }), "k");
|
|
8108
8235
|
De(W(Pe)), ae(W(function(e) {
|
|
8109
8236
|
return typeof e == "boolean";
|
|
8110
8237
|
})), ae(W(function(e) {
|
|
@@ -8114,7 +8241,7 @@ De(W(Pe)), ae(W(function(e) {
|
|
|
8114
8241
|
})), ae(W(function(e) {
|
|
8115
8242
|
return e != null;
|
|
8116
8243
|
}));
|
|
8117
|
-
class
|
|
8244
|
+
class go extends Error {
|
|
8118
8245
|
static {
|
|
8119
8246
|
s(this, "I");
|
|
8120
8247
|
}
|
|
@@ -8129,10 +8256,10 @@ class fo extends Error {
|
|
|
8129
8256
|
}
|
|
8130
8257
|
}
|
|
8131
8258
|
const Yt = { matched: false, value: void 0 };
|
|
8132
|
-
function
|
|
8259
|
+
function Io(e) {
|
|
8133
8260
|
return new vt(e, Yt);
|
|
8134
8261
|
}
|
|
8135
|
-
s(
|
|
8262
|
+
s(Io, "M");
|
|
8136
8263
|
class vt {
|
|
8137
8264
|
static {
|
|
8138
8265
|
s(this, "R");
|
|
@@ -8143,12 +8270,12 @@ class vt {
|
|
|
8143
8270
|
with(...t) {
|
|
8144
8271
|
if (this.state.matched) return this;
|
|
8145
8272
|
const r = t[t.length - 1], n = [t[0]];
|
|
8146
|
-
let
|
|
8147
|
-
t.length === 3 && typeof t[1] == "function" ?
|
|
8148
|
-
let
|
|
8149
|
-
const l = s((
|
|
8150
|
-
|
|
8151
|
-
}, "u2"), h = !n.some((
|
|
8273
|
+
let i;
|
|
8274
|
+
t.length === 3 && typeof t[1] == "function" ? i = t[1] : t.length > 2 && n.push(...t.slice(1, t.length - 1));
|
|
8275
|
+
let o = false, c = {};
|
|
8276
|
+
const l = s((g, m) => {
|
|
8277
|
+
o = true, c[g] = m;
|
|
8278
|
+
}, "u2"), h = !n.some((g) => Se(g, this.input, l)) || i && !i(this.input) ? Yt : { matched: true, value: r(o ? gt in c ? c[gt] : c : this.input, this.input) };
|
|
8152
8279
|
return new vt(this.input, h);
|
|
8153
8280
|
}
|
|
8154
8281
|
when(t, r) {
|
|
@@ -8159,7 +8286,7 @@ class vt {
|
|
|
8159
8286
|
otherwise(t) {
|
|
8160
8287
|
return this.state.matched ? this.state.value : t(this.input);
|
|
8161
8288
|
}
|
|
8162
|
-
exhaustive(t =
|
|
8289
|
+
exhaustive(t = So) {
|
|
8163
8290
|
return this.state.matched ? this.state.value : t(this.input);
|
|
8164
8291
|
}
|
|
8165
8292
|
run() {
|
|
@@ -8172,74 +8299,92 @@ class vt {
|
|
|
8172
8299
|
return this;
|
|
8173
8300
|
}
|
|
8174
8301
|
}
|
|
8175
|
-
function
|
|
8176
|
-
throw new
|
|
8302
|
+
function So(e) {
|
|
8303
|
+
throw new go(e);
|
|
8177
8304
|
}
|
|
8178
|
-
s(
|
|
8179
|
-
const
|
|
8180
|
-
function
|
|
8181
|
-
return e.reduce((r, n) => r.replaceAll(n,
|
|
8305
|
+
s(So, "F");
|
|
8306
|
+
const Ro = "[REDACTED]", To = /* @__PURE__ */ new Set(["sha1", "_sha1", "pageref", "downloadsPath", "tracesDir", "pageId"]);
|
|
8307
|
+
function se({ sensitiveValues: e, str: t }) {
|
|
8308
|
+
return e.reduce((r, n) => r.replaceAll(n, Ro), t);
|
|
8182
8309
|
}
|
|
8183
|
-
s(
|
|
8184
|
-
function
|
|
8310
|
+
s(se, "scrubString");
|
|
8311
|
+
function yo(e) {
|
|
8185
8312
|
return typeof e == "object" && e !== null && !Array.isArray(e);
|
|
8186
8313
|
}
|
|
8187
|
-
s(
|
|
8314
|
+
s(yo, "isRecord");
|
|
8188
8315
|
function it({ sensitiveValues: e, value: t }) {
|
|
8189
|
-
return typeof t == "string" ?
|
|
8316
|
+
return typeof t == "string" ? se({ sensitiveValues: e, str: t }) : Array.isArray(t) ? t.map((r) => it({ sensitiveValues: e, value: r })) : yo(t) ? $e({ obj: t, sensitiveValues: e }) : t;
|
|
8190
8317
|
}
|
|
8191
8318
|
s(it, "scrubValue");
|
|
8192
|
-
function
|
|
8193
|
-
return
|
|
8319
|
+
function wo(e) {
|
|
8320
|
+
return To.has(e) ? true : e.toLowerCase().endsWith("sha1");
|
|
8194
8321
|
}
|
|
8195
|
-
s(
|
|
8322
|
+
s(wo, "shouldPreserveKey");
|
|
8196
8323
|
function $e({ obj: e, sensitiveValues: t }) {
|
|
8197
|
-
return Object.fromEntries(Object.entries(e).map(([r, n]) => [r,
|
|
8324
|
+
return Object.fromEntries(Object.entries(e).map(([r, n]) => [r, wo(r) ? n : it({ sensitiveValues: t, value: n })]));
|
|
8198
8325
|
}
|
|
8199
8326
|
s($e, "scrubObject");
|
|
8200
|
-
function
|
|
8201
|
-
return
|
|
8327
|
+
function dn({ error: e, sensitiveValues: t }) {
|
|
8328
|
+
return e ? { ...e, message: se({ sensitiveValues: t, str: e.message }) } : void 0;
|
|
8329
|
+
}
|
|
8330
|
+
s(dn, "scrubError");
|
|
8331
|
+
function Ao({ event: e, sensitiveValues: t }) {
|
|
8332
|
+
return Io(e).with({ type: "console" }, (r) => ({ ...r, args: r.args?.map((n) => ({ ...n, preview: se({ sensitiveValues: t, str: n.preview }), value: it({ sensitiveValues: t, value: n.value }) })), text: se({ sensitiveValues: t, str: r.text }) })).with({ type: "before" }, (r) => ({ ...r, params: $e({ obj: r.params, sensitiveValues: t }), title: r.title ? se({ sensitiveValues: t, str: r.title }) : void 0 })).with({ type: "after" }, (r) => ({ ...r, error: dn({ error: r.error, sensitiveValues: t }), result: r.result !== void 0 ? it({ sensitiveValues: t, value: r.result }) : void 0 })).with({ type: "action" }, (r) => ({ ...r, error: dn({ error: r.error, sensitiveValues: t }), params: $e({ obj: r.params, sensitiveValues: t }), result: r.result !== void 0 ? it({ sensitiveValues: t, value: r.result }) : void 0, title: r.title ? se({ sensitiveValues: t, str: r.title }) : void 0 })).with({ type: "event" }, (r) => ({ ...r, params: $e({ obj: r.params, sensitiveValues: t }) })).with({ type: "stdout" }, { type: "stderr" }, (r) => ({ ...r, text: r.text !== void 0 ? se({ sensitiveValues: t, str: r.text }) : void 0 })).with({ type: "error" }, (r) => ({ ...r, message: se({ sensitiveValues: t, str: r.message }) })).with({ type: "log" }, (r) => ({ ...r, message: se({ sensitiveValues: t, str: r.message }) })).with({ type: "context-options" }, (r) => ({ ...r, options: $e({ obj: r.options, sensitiveValues: t }), title: r.title ? se({ sensitiveValues: t, str: r.title }) : void 0 })).with({ type: "frame-snapshot" }, (r) => ({ ...r, snapshot: $e({ obj: r.snapshot, sensitiveValues: t }) })).with({ type: "resource-snapshot" }, (r) => ({ ...r, snapshot: $e({ obj: r.snapshot, sensitiveValues: t }) })).with({ type: "screencast-frame" }, { type: "input" }, (r) => r).exhaustive();
|
|
8202
8333
|
}
|
|
8203
|
-
s(
|
|
8204
|
-
function
|
|
8334
|
+
s(Ao, "scrubTraceEvent");
|
|
8335
|
+
function vo({ content: e, sensitiveValues: t }) {
|
|
8205
8336
|
const r = new TextDecoder$1(), n = new TextEncoder$1(), c = r.decode(e).split(`
|
|
8206
8337
|
`).map((l) => {
|
|
8207
8338
|
if (!l.trim()) return l;
|
|
8208
8339
|
try {
|
|
8209
|
-
const h = JSON.parse(l),
|
|
8210
|
-
return JSON.stringify(
|
|
8340
|
+
const h = JSON.parse(l), g = Ao({ event: h, sensitiveValues: t });
|
|
8341
|
+
return JSON.stringify(g);
|
|
8211
8342
|
} catch {
|
|
8212
|
-
return
|
|
8343
|
+
return se({ sensitiveValues: t, str: l });
|
|
8213
8344
|
}
|
|
8214
8345
|
});
|
|
8215
8346
|
return n.encode(c.join(`
|
|
8216
8347
|
`));
|
|
8217
8348
|
}
|
|
8218
|
-
s(
|
|
8219
|
-
function
|
|
8220
|
-
const r = new TextDecoder$1(), n = new TextEncoder$1(),
|
|
8221
|
-
return n.encode(
|
|
8349
|
+
s(vo, "scrubJsonLinesFile");
|
|
8350
|
+
function pn({ content: e, sensitiveValues: t }) {
|
|
8351
|
+
const r = new TextDecoder$1(), n = new TextEncoder$1(), i = se({ sensitiveValues: t, str: r.decode(e) });
|
|
8352
|
+
return n.encode(i);
|
|
8222
8353
|
}
|
|
8223
|
-
s(
|
|
8224
|
-
const
|
|
8225
|
-
async function
|
|
8226
|
-
const r =
|
|
8354
|
+
s(pn, "scrubTextFile");
|
|
8355
|
+
const bo = promisify(lo), Co = promisify(uo);
|
|
8356
|
+
async function zt({ sensitiveValues: e, traceBuffer: t }) {
|
|
8357
|
+
const r = ln(e);
|
|
8227
8358
|
if (r.length === 0) return new Uint8Array(t);
|
|
8228
|
-
const n = r.sort((h,
|
|
8229
|
-
return
|
|
8359
|
+
const n = [...r].sort((h, g) => g.length - h.length), i = await bo(new Uint8Array(t)), o = Object.entries(i), c = await Promise.all(o.map(async ([h, g]) => [h, await Uo({ content: g, filename: h, sensitiveValues: n })])), l = Object.fromEntries(c);
|
|
8360
|
+
return Co(l);
|
|
8230
8361
|
}
|
|
8231
|
-
s(
|
|
8232
|
-
async function
|
|
8362
|
+
s(zt, "scrubTrace");
|
|
8363
|
+
async function Uo({ content: e, filename: t, sensitiveValues: r }) {
|
|
8233
8364
|
const n = t.toLowerCase();
|
|
8234
|
-
return n.endsWith(".trace") || n.endsWith(".network") ?
|
|
8235
|
-
}
|
|
8236
|
-
s(
|
|
8237
|
-
async function
|
|
8238
|
-
return await
|
|
8239
|
-
}
|
|
8240
|
-
s(
|
|
8241
|
-
|
|
8242
|
-
|
|
8365
|
+
return n.endsWith(".trace") || n.endsWith(".network") ? vo({ content: e, sensitiveValues: r }) : n.endsWith(".html") || n.endsWith(".dat") || n.endsWith(".json") ? pn({ content: e, sensitiveValues: r }) : n.startsWith("resources/") ? Bo({ content: e, sensitiveValues: r }) : e;
|
|
8366
|
+
}
|
|
8367
|
+
s(Uo, "scrubFile");
|
|
8368
|
+
async function Bo({ content: e, sensitiveValues: t }) {
|
|
8369
|
+
return await Ki.isBinaryFile(Buffer.from(e)) ? e : pn({ content: e, sensitiveValues: t });
|
|
8370
|
+
}
|
|
8371
|
+
s(Bo, "scrubResourceFile");
|
|
8372
|
+
async function Oo({ sensitiveValues: e, tracePath: t }) {
|
|
8373
|
+
const r = [], n = createReadStream(t);
|
|
8374
|
+
for await (const o of n) r.push(Uint8Array.from(o));
|
|
8375
|
+
const i = new Uint8Array(Buffer.concat(r));
|
|
8376
|
+
return zt({ sensitiveValues: e, traceBuffer: i });
|
|
8377
|
+
}
|
|
8378
|
+
s(Oo, "scrubTraceFromPath");
|
|
8379
|
+
async function Lo({ sensitiveValues: e, traceFd: t, tracePath: r }) {
|
|
8380
|
+
const n = [], i = createReadStream(r, { autoClose: true, fd: t });
|
|
8381
|
+
for await (const c of i) n.push(Uint8Array.from(c));
|
|
8382
|
+
const o = new Uint8Array(Buffer.concat(n));
|
|
8383
|
+
return zt({ sensitiveValues: e, traceBuffer: o });
|
|
8384
|
+
}
|
|
8385
|
+
s(Lo, "scrubTraceFromFd");
|
|
8386
|
+
const mn = { AUTHENTICATION_FAILED: 1008 };
|
|
8387
|
+
class Po {
|
|
8243
8388
|
static {
|
|
8244
8389
|
s(this, "WebSocketClient");
|
|
8245
8390
|
}
|
|
@@ -8258,8 +8403,8 @@ class vo {
|
|
|
8258
8403
|
isManualClose = false;
|
|
8259
8404
|
isAuthenticated = false;
|
|
8260
8405
|
authenticationFailed = false;
|
|
8261
|
-
constructor({ apiKey: t, maxBufferSize: r = 1e3, maxReconnectAttempts: n = 3, onError:
|
|
8262
|
-
this.url = h, this.apiKey = t, this.projectId = c, this.maxBufferSize = r, this.reconnectDelay = l, this.maxReconnectAttempts = n, this.onMessage =
|
|
8406
|
+
constructor({ apiKey: t, maxBufferSize: r = 1e3, maxReconnectAttempts: n = 3, onError: i, onMessage: o, projectId: c, reconnectDelay: l = 2e3, url: h }) {
|
|
8407
|
+
this.url = h, this.apiKey = t, this.projectId = c, this.maxBufferSize = r, this.reconnectDelay = l, this.maxReconnectAttempts = n, this.onMessage = o, this.onError = i, this.connect();
|
|
8263
8408
|
}
|
|
8264
8409
|
connect() {
|
|
8265
8410
|
try {
|
|
@@ -8268,12 +8413,12 @@ class vo {
|
|
|
8268
8413
|
this.reconnectAttempts = 0;
|
|
8269
8414
|
}), this.socket.on("message", (r) => {
|
|
8270
8415
|
try {
|
|
8271
|
-
const n = typeof r == "string" ? r : r.toString(),
|
|
8272
|
-
|
|
8416
|
+
const n = typeof r == "string" ? r : r.toString(), i = JSON.parse(n);
|
|
8417
|
+
i.type === "connected" ? (this.isAuthenticated = true, this.authenticationFailed = false, this.flushBuffer()) : this.onMessage && this.onMessage(i);
|
|
8273
8418
|
} catch {
|
|
8274
8419
|
}
|
|
8275
8420
|
}), this.socket.on("close", (r, n) => {
|
|
8276
|
-
this.isAuthenticated = false, r ===
|
|
8421
|
+
this.isAuthenticated = false, r === mn.AUTHENTICATION_FAILED && (this.authenticationFailed = true, this.onError && this.onError({ code: r, message: n.toString() || "Authentication failed", reason: n.toString() })), !this.isManualClose && !this.authenticationFailed && this.reconnectAttempts < this.maxReconnectAttempts && this.scheduleReconnect();
|
|
8277
8422
|
}), this.socket.on("error", () => {
|
|
8278
8423
|
});
|
|
8279
8424
|
} catch {
|
|
@@ -8291,8 +8436,8 @@ class vo {
|
|
|
8291
8436
|
this.buffer = [];
|
|
8292
8437
|
for (const r of t) try {
|
|
8293
8438
|
const n = JSON.stringify(r);
|
|
8294
|
-
this.socket.send(n, (
|
|
8295
|
-
|
|
8439
|
+
this.socket.send(n, (i) => {
|
|
8440
|
+
i && this.bufferEvent(r);
|
|
8296
8441
|
});
|
|
8297
8442
|
} catch {
|
|
8298
8443
|
this.bufferEvent(r);
|
|
@@ -8328,268 +8473,268 @@ class vo {
|
|
|
8328
8473
|
return [...this.buffer];
|
|
8329
8474
|
}
|
|
8330
8475
|
}
|
|
8331
|
-
var
|
|
8476
|
+
var No = { detect({ env: e }) {
|
|
8332
8477
|
return !!e.APPVEYOR;
|
|
8333
8478
|
}, configuration({ env: e }) {
|
|
8334
8479
|
const t = e.APPVEYOR_PULL_REQUEST_NUMBER, r = !!t;
|
|
8335
8480
|
return { name: "Appveyor", service: "appveyor", commit: e.APPVEYOR_REPO_COMMIT, tag: e.APPVEYOR_REPO_TAG_NAME, build: e.APPVEYOR_BUILD_NUMBER, buildUrl: `https://ci.appveyor.com/project/${e.APPVEYOR_PROJECT_SLUG}/build/${e.APPVEYOR_BUILD_VERSION}`, branch: e.APPVEYOR_REPO_BRANCH, job: e.APPVEYOR_JOB_NUMBER, jobUrl: `https://ci.appveyor.com/project/${e.APPVEYOR_PROJECT_SLUG}/build/job/${e.APPVEYOR_JOB_ID}`, pr: t, isPr: r, prBranch: e.APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH, slug: e.APPVEYOR_REPO_NAME, root: e.APPVEYOR_BUILD_FOLDER };
|
|
8336
8481
|
} };
|
|
8337
|
-
function
|
|
8482
|
+
function En(e) {
|
|
8338
8483
|
return (/\d+(?!.*\d+)/.exec(e) || [])[0];
|
|
8339
8484
|
}
|
|
8340
|
-
s(
|
|
8485
|
+
s(En, "prNumber");
|
|
8341
8486
|
function ot(e) {
|
|
8342
8487
|
return e ? /^(?:refs\/heads\/)?(?<branch>.+)$/i.exec(e)[1] : void 0;
|
|
8343
8488
|
}
|
|
8344
8489
|
s(ot, "parseBranch");
|
|
8345
|
-
var
|
|
8490
|
+
var Do = { detect({ env: e }) {
|
|
8346
8491
|
return !!e.BUILD_BUILDURI;
|
|
8347
8492
|
}, configuration({ env: e }) {
|
|
8348
8493
|
const t = e.SYSTEM_PULLREQUEST_PULLREQUESTID, r = !!t;
|
|
8349
8494
|
return { name: "Azure Pipelines", service: "azurePipelines", commit: e.BUILD_SOURCEVERSION, build: e.BUILD_BUILDNUMBER, branch: ot(r ? e.SYSTEM_PULLREQUEST_TARGETBRANCH : e.BUILD_SOURCEBRANCH), pr: t, isPr: r, prBranch: ot(r ? e.SYSTEM_PULLREQUEST_SOURCEBRANCH : void 0), root: e.BUILD_REPOSITORY_LOCALPATH };
|
|
8350
|
-
} },
|
|
8495
|
+
} }, Mo = { detect({ env: e }) {
|
|
8351
8496
|
return !!e.bamboo_agentId;
|
|
8352
8497
|
}, configuration({ env: e }) {
|
|
8353
8498
|
return { name: "Bamboo", service: "bamboo", commit: e.bamboo_planRepository_1_revision, build: e.bamboo_buildNumber, buildUrl: e.bamboo_buildResultsUrl, branch: e.bamboo_planRepository_1_branchName, job: e.bamboo_buildKey, root: e.bamboo_build_working_directory };
|
|
8354
|
-
} },
|
|
8499
|
+
} }, xo = { detect({ env: e }) {
|
|
8355
8500
|
return !!e.BITBUCKET_BUILD_NUMBER;
|
|
8356
8501
|
}, configuration({ env: e }) {
|
|
8357
8502
|
return { name: "Bitbucket Pipelines", service: "bitbucket", commit: e.BITBUCKET_COMMIT, tag: e.BITBUCKET_TAG, build: e.BITBUCKET_BUILD_NUMBER, buildUrl: `https://bitbucket.org/${e.BITBUCKET_REPO_FULL_NAME}/addon/pipelines/home#!/results/${e.BITBUCKET_BUILD_NUMBER}`, branch: e.BITBUCKET_BRANCH, slug: e.BITBUCKET_REPO_FULL_NAME, root: e.BITBUCKET_CLONE_DIR };
|
|
8358
|
-
} },
|
|
8503
|
+
} }, Go = { detect({ env: e }) {
|
|
8359
8504
|
return !!e.BITRISE_IO;
|
|
8360
8505
|
}, configuration({ env: e }) {
|
|
8361
8506
|
const t = e.BITRISE_PULL_REQUEST === "false" ? void 0 : e.BITRISE_PULL_REQUEST, r = !!t;
|
|
8362
8507
|
return { name: "Bitrise", service: "bitrise", commit: e.BITRISE_GIT_COMMIT, tag: e.BITRISE_GIT_TAG, build: e.BITRISE_BUILD_NUMBER, buildUrl: e.BITRISE_BUILD_URL, branch: r ? e.BITRISEIO_GIT_BRANCH_DEST : e.BITRISE_GIT_BRANCH, pr: t, isPr: r, prBranch: r ? e.BITRISE_GIT_BRANCH : void 0, slug: e.BITRISE_APP_SLUG };
|
|
8363
|
-
} },
|
|
8508
|
+
} }, $o = { detect({ env: e }) {
|
|
8364
8509
|
return !!e.BUDDY_WORKSPACE_ID;
|
|
8365
8510
|
}, configuration({ env: e }) {
|
|
8366
|
-
const t =
|
|
8511
|
+
const t = En(e.BUDDY_EXECUTION_PULL_REQUEST_ID), r = !!t;
|
|
8367
8512
|
return { name: "Buddy", service: "buddy", commit: e.BUDDY_EXECUTION_REVISION, tag: e.BUDDY_EXECUTION_TAG, build: e.BUDDY_EXECUTION_ID, buildUrl: e.BUDDY_EXECUTION_URL, branch: r ? e.BUDDY_EXECUTION_PULL_REQUEST_HEAD_BRANCH : e.BUDDY_EXECUTION_BRANCH, pr: t, isPr: r, slug: e.BUDDY_REPO_SLUG };
|
|
8368
|
-
} }, ke = { exports: {} },
|
|
8369
|
-
function
|
|
8370
|
-
if (
|
|
8371
|
-
|
|
8513
|
+
} }, ke = { exports: {} }, Jt, _n;
|
|
8514
|
+
function ko() {
|
|
8515
|
+
if (_n) return Jt;
|
|
8516
|
+
_n = 1, Jt = n, n.sync = i;
|
|
8372
8517
|
var e = ze;
|
|
8373
|
-
function t(
|
|
8518
|
+
function t(o, c) {
|
|
8374
8519
|
var l = c.pathExt !== void 0 ? c.pathExt : process.env.PATHEXT;
|
|
8375
8520
|
if (!l || (l = l.split(";"), l.indexOf("") !== -1)) return true;
|
|
8376
8521
|
for (var h = 0; h < l.length; h++) {
|
|
8377
|
-
var
|
|
8378
|
-
if (
|
|
8522
|
+
var g = l[h].toLowerCase();
|
|
8523
|
+
if (g && o.substr(-g.length).toLowerCase() === g) return true;
|
|
8379
8524
|
}
|
|
8380
8525
|
return false;
|
|
8381
8526
|
}
|
|
8382
8527
|
s(t, "checkPathExt");
|
|
8383
|
-
function r(
|
|
8384
|
-
return !
|
|
8528
|
+
function r(o, c, l) {
|
|
8529
|
+
return !o.isSymbolicLink() && !o.isFile() ? false : t(c, l);
|
|
8385
8530
|
}
|
|
8386
8531
|
s(r, "checkStat");
|
|
8387
|
-
function n(
|
|
8388
|
-
e.stat(
|
|
8389
|
-
l(h, h ? false : r(
|
|
8532
|
+
function n(o, c, l) {
|
|
8533
|
+
e.stat(o, function(h, g) {
|
|
8534
|
+
l(h, h ? false : r(g, o, c));
|
|
8390
8535
|
});
|
|
8391
8536
|
}
|
|
8392
8537
|
s(n, "isexe");
|
|
8393
|
-
function o
|
|
8394
|
-
return r(e.statSync(
|
|
8538
|
+
function i(o, c) {
|
|
8539
|
+
return r(e.statSync(o), o, c);
|
|
8395
8540
|
}
|
|
8396
|
-
return s(
|
|
8541
|
+
return s(i, "sync"), Jt;
|
|
8397
8542
|
}
|
|
8398
|
-
s(
|
|
8399
|
-
var
|
|
8400
|
-
function
|
|
8401
|
-
if (
|
|
8402
|
-
|
|
8543
|
+
s(ko, "requireWindows");
|
|
8544
|
+
var Qt, gn;
|
|
8545
|
+
function Ho() {
|
|
8546
|
+
if (gn) return Qt;
|
|
8547
|
+
gn = 1, Qt = t, t.sync = r;
|
|
8403
8548
|
var e = ze;
|
|
8404
|
-
function t(
|
|
8405
|
-
e.stat(
|
|
8406
|
-
l(h, h ? false : n(
|
|
8549
|
+
function t(o, c, l) {
|
|
8550
|
+
e.stat(o, function(h, g) {
|
|
8551
|
+
l(h, h ? false : n(g, c));
|
|
8407
8552
|
});
|
|
8408
8553
|
}
|
|
8409
8554
|
s(t, "isexe");
|
|
8410
|
-
function r(
|
|
8411
|
-
return n(e.statSync(
|
|
8555
|
+
function r(o, c) {
|
|
8556
|
+
return n(e.statSync(o), c);
|
|
8412
8557
|
}
|
|
8413
8558
|
s(r, "sync");
|
|
8414
|
-
function n(
|
|
8415
|
-
return
|
|
8559
|
+
function n(o, c) {
|
|
8560
|
+
return o.isFile() && i(o, c);
|
|
8416
8561
|
}
|
|
8417
8562
|
s(n, "checkStat");
|
|
8418
|
-
function o
|
|
8419
|
-
var l =
|
|
8420
|
-
return
|
|
8563
|
+
function i(o, c) {
|
|
8564
|
+
var l = o.mode, h = o.uid, g = o.gid, m = c.uid !== void 0 ? c.uid : process.getuid && process.getuid(), A = c.gid !== void 0 ? c.gid : process.getgid && process.getgid(), b = parseInt("100", 8), O = parseInt("010", 8), x = parseInt("001", 8), M = b | O, w = l & x || l & O && g === A || l & b && h === m || l & M && m === 0;
|
|
8565
|
+
return w;
|
|
8421
8566
|
}
|
|
8422
|
-
return s(
|
|
8567
|
+
return s(i, "checkMode"), Qt;
|
|
8423
8568
|
}
|
|
8424
|
-
s(
|
|
8425
|
-
var
|
|
8426
|
-
function
|
|
8427
|
-
if (
|
|
8428
|
-
|
|
8569
|
+
s(Ho, "requireMode");
|
|
8570
|
+
var Xt, In;
|
|
8571
|
+
function Fo() {
|
|
8572
|
+
if (In) return Xt;
|
|
8573
|
+
In = 1;
|
|
8429
8574
|
var e;
|
|
8430
|
-
process.platform === "win32" ||
|
|
8431
|
-
function t(n,
|
|
8432
|
-
if (typeof
|
|
8575
|
+
process.platform === "win32" || qi.TESTING_WINDOWS ? e = ko() : e = Ho(), Xt = t, t.sync = r;
|
|
8576
|
+
function t(n, i, o) {
|
|
8577
|
+
if (typeof i == "function" && (o = i, i = {}), !o) {
|
|
8433
8578
|
if (typeof Promise != "function") throw new TypeError("callback not provided");
|
|
8434
8579
|
return new Promise(function(c, l) {
|
|
8435
|
-
t(n,
|
|
8436
|
-
h ? l(h) : c(
|
|
8580
|
+
t(n, i || {}, function(h, g) {
|
|
8581
|
+
h ? l(h) : c(g);
|
|
8437
8582
|
});
|
|
8438
8583
|
});
|
|
8439
8584
|
}
|
|
8440
|
-
e(n,
|
|
8441
|
-
c && (c.code === "EACCES" ||
|
|
8585
|
+
e(n, i || {}, function(c, l) {
|
|
8586
|
+
c && (c.code === "EACCES" || i && i.ignoreErrors) && (c = null, l = false), o(c, l);
|
|
8442
8587
|
});
|
|
8443
8588
|
}
|
|
8444
8589
|
s(t, "isexe");
|
|
8445
|
-
function r(n,
|
|
8590
|
+
function r(n, i) {
|
|
8446
8591
|
try {
|
|
8447
|
-
return e.sync(n,
|
|
8448
|
-
} catch (
|
|
8449
|
-
if (
|
|
8450
|
-
throw
|
|
8592
|
+
return e.sync(n, i || {});
|
|
8593
|
+
} catch (o) {
|
|
8594
|
+
if (i && i.ignoreErrors || o.code === "EACCES") return false;
|
|
8595
|
+
throw o;
|
|
8451
8596
|
}
|
|
8452
8597
|
}
|
|
8453
|
-
return s(r, "sync"),
|
|
8598
|
+
return s(r, "sync"), Xt;
|
|
8454
8599
|
}
|
|
8455
|
-
s(
|
|
8456
|
-
var
|
|
8457
|
-
function
|
|
8458
|
-
if (
|
|
8459
|
-
|
|
8460
|
-
const e = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", t = require$$0$1, r = e ? ";" : ":", n =
|
|
8461
|
-
const m =
|
|
8600
|
+
s(Fo, "requireIsexe");
|
|
8601
|
+
var Zt, Sn;
|
|
8602
|
+
function jo() {
|
|
8603
|
+
if (Sn) return Zt;
|
|
8604
|
+
Sn = 1;
|
|
8605
|
+
const e = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", t = require$$0$1, r = e ? ";" : ":", n = Fo(), i = s((h) => Object.assign(new Error(`not found: ${h}`), { code: "ENOENT" }), "getNotFoundError"), o = s((h, g) => {
|
|
8606
|
+
const m = g.colon || r, A = h.match(/\//) || e && h.match(/\\/) ? [""] : [...e ? [process.cwd()] : [], ...(g.path || process.env.PATH || "").split(m)], b = e ? g.pathExt || process.env.PATHEXT || ".EXE;.CMD;.BAT;.COM" : "", O = e ? b.split(m) : [""];
|
|
8462
8607
|
return e && h.indexOf(".") !== -1 && O[0] !== "" && O.unshift(""), { pathEnv: A, pathExt: O, pathExtExe: b };
|
|
8463
|
-
}, "getPathInfo"), c = s((h,
|
|
8464
|
-
typeof
|
|
8465
|
-
const { pathEnv: A, pathExt: b, pathExtExe: O } =
|
|
8466
|
-
if (C === A.length) return
|
|
8608
|
+
}, "getPathInfo"), c = s((h, g, m) => {
|
|
8609
|
+
typeof g == "function" && (m = g, g = {}), g || (g = {});
|
|
8610
|
+
const { pathEnv: A, pathExt: b, pathExtExe: O } = o(h, g), x = [], M = s((C) => new Promise((y, B) => {
|
|
8611
|
+
if (C === A.length) return g.all && x.length ? y(x) : B(i(h));
|
|
8467
8612
|
const L = A[C], U = /^".*"$/.test(L) ? L.slice(1, -1) : L, G = t.join(U, h), k = !U && /^\.[\\\/]/.test(h) ? h.slice(0, 2) + G : G;
|
|
8468
|
-
w(
|
|
8469
|
-
}), "step"),
|
|
8470
|
-
if (B === b.length) return L(M(
|
|
8613
|
+
y(w(k, C, 0));
|
|
8614
|
+
}), "step"), w = s((C, y, B) => new Promise((L, U) => {
|
|
8615
|
+
if (B === b.length) return L(M(y + 1));
|
|
8471
8616
|
const G = b[B];
|
|
8472
8617
|
n(C + G, { pathExt: O }, (k, a) => {
|
|
8473
|
-
if (!k && a) if (
|
|
8618
|
+
if (!k && a) if (g.all) x.push(C + G);
|
|
8474
8619
|
else return L(C + G);
|
|
8475
|
-
return L(
|
|
8620
|
+
return L(w(C, y, B + 1));
|
|
8476
8621
|
});
|
|
8477
8622
|
}), "subStep");
|
|
8478
8623
|
return m ? M(0).then((C) => m(null, C), m) : M(0);
|
|
8479
|
-
}, "which"), l = s((h,
|
|
8480
|
-
|
|
8481
|
-
const { pathEnv: m, pathExt: A, pathExtExe: b } =
|
|
8624
|
+
}, "which"), l = s((h, g) => {
|
|
8625
|
+
g = g || {};
|
|
8626
|
+
const { pathEnv: m, pathExt: A, pathExtExe: b } = o(h, g), O = [];
|
|
8482
8627
|
for (let x = 0; x < m.length; x++) {
|
|
8483
|
-
const M = m[x],
|
|
8628
|
+
const M = m[x], w = /^".*"$/.test(M) ? M.slice(1, -1) : M, C = t.join(w, h), y = !w && /^\.[\\\/]/.test(h) ? h.slice(0, 2) + C : C;
|
|
8484
8629
|
for (let B = 0; B < A.length; B++) {
|
|
8485
|
-
const L =
|
|
8630
|
+
const L = y + A[B];
|
|
8486
8631
|
try {
|
|
8487
|
-
if (n.sync(L, { pathExt: b })) if (
|
|
8632
|
+
if (n.sync(L, { pathExt: b })) if (g.all) O.push(L);
|
|
8488
8633
|
else return L;
|
|
8489
8634
|
} catch {
|
|
8490
8635
|
}
|
|
8491
8636
|
}
|
|
8492
8637
|
}
|
|
8493
|
-
if (
|
|
8494
|
-
if (
|
|
8495
|
-
throw
|
|
8638
|
+
if (g.all && O.length) return O;
|
|
8639
|
+
if (g.nothrow) return null;
|
|
8640
|
+
throw i(h);
|
|
8496
8641
|
}, "whichSync");
|
|
8497
|
-
return
|
|
8642
|
+
return Zt = c, c.sync = l, Zt;
|
|
8498
8643
|
}
|
|
8499
|
-
s(
|
|
8500
|
-
var St = { exports: {} },
|
|
8501
|
-
function
|
|
8502
|
-
if (
|
|
8503
|
-
|
|
8644
|
+
s(jo, "requireWhich");
|
|
8645
|
+
var St = { exports: {} }, Rn;
|
|
8646
|
+
function qo() {
|
|
8647
|
+
if (Rn) return St.exports;
|
|
8648
|
+
Rn = 1;
|
|
8504
8649
|
const e = s((t = {}) => {
|
|
8505
8650
|
const r = t.env || process.env;
|
|
8506
|
-
return (t.platform || process.platform) !== "win32" ? "PATH" : Object.keys(r).reverse().find((
|
|
8651
|
+
return (t.platform || process.platform) !== "win32" ? "PATH" : Object.keys(r).reverse().find((i) => i.toUpperCase() === "PATH") || "Path";
|
|
8507
8652
|
}, "pathKey");
|
|
8508
8653
|
return St.exports = e, St.exports.default = e, St.exports;
|
|
8509
8654
|
}
|
|
8510
|
-
s(
|
|
8511
|
-
var
|
|
8512
|
-
function
|
|
8513
|
-
if (
|
|
8514
|
-
|
|
8515
|
-
const e = require$$0$1, t =
|
|
8516
|
-
function n(
|
|
8517
|
-
const l =
|
|
8655
|
+
s(qo, "requirePathKey");
|
|
8656
|
+
var er, Tn;
|
|
8657
|
+
function Wo() {
|
|
8658
|
+
if (Tn) return er;
|
|
8659
|
+
Tn = 1;
|
|
8660
|
+
const e = require$$0$1, t = jo(), r = qo();
|
|
8661
|
+
function n(o, c) {
|
|
8662
|
+
const l = o.options.env || process.env, h = process.cwd(), g = o.options.cwd != null, m = g && process.chdir !== void 0 && !process.chdir.disabled;
|
|
8518
8663
|
if (m) try {
|
|
8519
|
-
process.chdir(
|
|
8664
|
+
process.chdir(o.options.cwd);
|
|
8520
8665
|
} catch {
|
|
8521
8666
|
}
|
|
8522
8667
|
let A;
|
|
8523
8668
|
try {
|
|
8524
|
-
A = t.sync(
|
|
8669
|
+
A = t.sync(o.command, { path: l[r({ env: l })], pathExt: c ? e.delimiter : void 0 });
|
|
8525
8670
|
} catch {
|
|
8526
8671
|
} finally {
|
|
8527
8672
|
m && process.chdir(h);
|
|
8528
8673
|
}
|
|
8529
|
-
return A && (A = e.resolve(
|
|
8674
|
+
return A && (A = e.resolve(g ? o.options.cwd : "", A)), A;
|
|
8530
8675
|
}
|
|
8531
8676
|
s(n, "resolveCommandAttempt");
|
|
8532
|
-
function o
|
|
8533
|
-
return n(
|
|
8677
|
+
function i(o) {
|
|
8678
|
+
return n(o) || n(o, true);
|
|
8534
8679
|
}
|
|
8535
|
-
return s(
|
|
8680
|
+
return s(i, "resolveCommand"), er = i, er;
|
|
8536
8681
|
}
|
|
8537
|
-
s(
|
|
8538
|
-
var Rt = {},
|
|
8539
|
-
function
|
|
8540
|
-
if (
|
|
8541
|
-
|
|
8682
|
+
s(Wo, "requireResolveCommand");
|
|
8683
|
+
var Rt = {}, yn;
|
|
8684
|
+
function Ko() {
|
|
8685
|
+
if (yn) return Rt;
|
|
8686
|
+
yn = 1;
|
|
8542
8687
|
const e = /([()\][%!^"`<>&|;, *?])/g;
|
|
8543
8688
|
function t(n) {
|
|
8544
8689
|
return n = n.replace(e, "^$1"), n;
|
|
8545
8690
|
}
|
|
8546
8691
|
s(t, "escapeCommand");
|
|
8547
|
-
function r(n,
|
|
8548
|
-
return n = `${n}`, n = n.replace(/(?=(\\+?)?)\1"/g, '$1$1\\"'), n = n.replace(/(?=(\\+?)?)\1$/, "$1$1"), n = `"${n}"`, n = n.replace(e, "^$1"),
|
|
8692
|
+
function r(n, i) {
|
|
8693
|
+
return n = `${n}`, n = n.replace(/(?=(\\+?)?)\1"/g, '$1$1\\"'), n = n.replace(/(?=(\\+?)?)\1$/, "$1$1"), n = `"${n}"`, n = n.replace(e, "^$1"), i && (n = n.replace(e, "^$1")), n;
|
|
8549
8694
|
}
|
|
8550
8695
|
return s(r, "escapeArgument"), Rt.command = t, Rt.argument = r, Rt;
|
|
8551
8696
|
}
|
|
8552
|
-
s(
|
|
8553
|
-
var
|
|
8554
|
-
function
|
|
8555
|
-
return
|
|
8697
|
+
s(Ko, "require_escape");
|
|
8698
|
+
var tr, wn;
|
|
8699
|
+
function Vo() {
|
|
8700
|
+
return wn || (wn = 1, tr = /^#!(.*)/), tr;
|
|
8556
8701
|
}
|
|
8557
|
-
s(
|
|
8558
|
-
var
|
|
8559
|
-
function
|
|
8560
|
-
if (
|
|
8561
|
-
|
|
8562
|
-
const e =
|
|
8563
|
-
return
|
|
8702
|
+
s(Vo, "requireShebangRegex");
|
|
8703
|
+
var rr, An;
|
|
8704
|
+
function Yo() {
|
|
8705
|
+
if (An) return rr;
|
|
8706
|
+
An = 1;
|
|
8707
|
+
const e = Vo();
|
|
8708
|
+
return rr = s((t = "") => {
|
|
8564
8709
|
const r = t.match(e);
|
|
8565
8710
|
if (!r) return null;
|
|
8566
|
-
const [n,
|
|
8567
|
-
return
|
|
8568
|
-
}, "shebangCommand"),
|
|
8569
|
-
}
|
|
8570
|
-
s(
|
|
8571
|
-
var
|
|
8572
|
-
function
|
|
8573
|
-
if (
|
|
8574
|
-
|
|
8575
|
-
const e = ze, t =
|
|
8711
|
+
const [n, i] = r[0].replace(/#! ?/, "").split(" "), o = n.split("/").pop();
|
|
8712
|
+
return o === "env" ? i : i ? `${o} ${i}` : o;
|
|
8713
|
+
}, "shebangCommand"), rr;
|
|
8714
|
+
}
|
|
8715
|
+
s(Yo, "requireShebangCommand");
|
|
8716
|
+
var nr, vn;
|
|
8717
|
+
function zo() {
|
|
8718
|
+
if (vn) return nr;
|
|
8719
|
+
vn = 1;
|
|
8720
|
+
const e = ze, t = Yo();
|
|
8576
8721
|
function r(n) {
|
|
8577
|
-
const
|
|
8722
|
+
const o = Buffer.alloc(150);
|
|
8578
8723
|
let c;
|
|
8579
8724
|
try {
|
|
8580
|
-
c = e.openSync(n, "r"), e.readSync(c,
|
|
8725
|
+
c = e.openSync(n, "r"), e.readSync(c, o, 0, 150, 0), e.closeSync(c);
|
|
8581
8726
|
} catch {
|
|
8582
8727
|
}
|
|
8583
|
-
return t(
|
|
8728
|
+
return t(o.toString());
|
|
8584
8729
|
}
|
|
8585
|
-
return s(r, "readShebang"),
|
|
8730
|
+
return s(r, "readShebang"), nr = r, nr;
|
|
8586
8731
|
}
|
|
8587
|
-
s(
|
|
8588
|
-
var
|
|
8589
|
-
function
|
|
8590
|
-
if (
|
|
8591
|
-
|
|
8592
|
-
const e = require$$0$1, t =
|
|
8732
|
+
s(zo, "requireReadShebang");
|
|
8733
|
+
var ir, bn;
|
|
8734
|
+
function Jo() {
|
|
8735
|
+
if (bn) return ir;
|
|
8736
|
+
bn = 1;
|
|
8737
|
+
const e = require$$0$1, t = Wo(), r = Ko(), n = zo(), i = process.platform === "win32", o = /\.(?:com|exe)$/i, c = /node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;
|
|
8593
8738
|
function l(m) {
|
|
8594
8739
|
m.file = t(m);
|
|
8595
8740
|
const A = m.file && n(m.file);
|
|
@@ -8597,8 +8742,8 @@ function jo() {
|
|
|
8597
8742
|
}
|
|
8598
8743
|
s(l, "detectShebang");
|
|
8599
8744
|
function h(m) {
|
|
8600
|
-
if (!
|
|
8601
|
-
const A = l(m), b = !
|
|
8745
|
+
if (!i) return m;
|
|
8746
|
+
const A = l(m), b = !o.test(A);
|
|
8602
8747
|
if (m.options.forceShell || b) {
|
|
8603
8748
|
const O = c.test(A);
|
|
8604
8749
|
m.command = e.normalize(m.command), m.command = r.command(m.command), m.args = m.args.map((M) => r.argument(M, O));
|
|
@@ -8608,131 +8753,131 @@ function jo() {
|
|
|
8608
8753
|
return m;
|
|
8609
8754
|
}
|
|
8610
8755
|
s(h, "parseNonShell");
|
|
8611
|
-
function
|
|
8756
|
+
function g(m, A, b) {
|
|
8612
8757
|
A && !Array.isArray(A) && (b = A, A = null), A = A ? A.slice(0) : [], b = Object.assign({}, b);
|
|
8613
8758
|
const O = { command: m, args: A, options: b, file: void 0, original: { command: m, args: A } };
|
|
8614
8759
|
return b.shell ? O : h(O);
|
|
8615
8760
|
}
|
|
8616
|
-
return s(
|
|
8761
|
+
return s(g, "parse"), ir = g, ir;
|
|
8617
8762
|
}
|
|
8618
|
-
s(
|
|
8619
|
-
var
|
|
8620
|
-
function
|
|
8621
|
-
if (
|
|
8622
|
-
|
|
8763
|
+
s(Jo, "requireParse");
|
|
8764
|
+
var or, Cn;
|
|
8765
|
+
function Qo() {
|
|
8766
|
+
if (Cn) return or;
|
|
8767
|
+
Cn = 1;
|
|
8623
8768
|
const e = process.platform === "win32";
|
|
8624
|
-
function t(
|
|
8625
|
-
return Object.assign(new Error(`${c} ${
|
|
8769
|
+
function t(o, c) {
|
|
8770
|
+
return Object.assign(new Error(`${c} ${o.command} ENOENT`), { code: "ENOENT", errno: "ENOENT", syscall: `${c} ${o.command}`, path: o.command, spawnargs: o.args });
|
|
8626
8771
|
}
|
|
8627
8772
|
s(t, "notFoundError");
|
|
8628
|
-
function r(
|
|
8773
|
+
function r(o, c) {
|
|
8629
8774
|
if (!e) return;
|
|
8630
|
-
const l =
|
|
8631
|
-
|
|
8775
|
+
const l = o.emit;
|
|
8776
|
+
o.emit = function(h, g) {
|
|
8632
8777
|
if (h === "exit") {
|
|
8633
|
-
const m = n(
|
|
8634
|
-
if (m) return l.call(
|
|
8778
|
+
const m = n(g, c);
|
|
8779
|
+
if (m) return l.call(o, "error", m);
|
|
8635
8780
|
}
|
|
8636
|
-
return l.apply(
|
|
8781
|
+
return l.apply(o, arguments);
|
|
8637
8782
|
};
|
|
8638
8783
|
}
|
|
8639
8784
|
s(r, "hookChildProcess");
|
|
8640
|
-
function n(
|
|
8641
|
-
return e &&
|
|
8785
|
+
function n(o, c) {
|
|
8786
|
+
return e && o === 1 && !c.file ? t(c.original, "spawn") : null;
|
|
8642
8787
|
}
|
|
8643
8788
|
s(n, "verifyENOENT");
|
|
8644
|
-
function o
|
|
8645
|
-
return e &&
|
|
8789
|
+
function i(o, c) {
|
|
8790
|
+
return e && o === 1 && !c.file ? t(c.original, "spawnSync") : null;
|
|
8646
8791
|
}
|
|
8647
|
-
return s(
|
|
8792
|
+
return s(i, "verifyENOENTSync"), or = { hookChildProcess: r, verifyENOENT: n, verifyENOENTSync: i, notFoundError: t }, or;
|
|
8648
8793
|
}
|
|
8649
|
-
s(
|
|
8650
|
-
var
|
|
8651
|
-
function
|
|
8652
|
-
if (
|
|
8653
|
-
|
|
8654
|
-
const e = require$$0$2, t =
|
|
8655
|
-
function n(
|
|
8656
|
-
const h = t(
|
|
8657
|
-
return r.hookChildProcess(
|
|
8794
|
+
s(Qo, "requireEnoent");
|
|
8795
|
+
var Un;
|
|
8796
|
+
function Xo() {
|
|
8797
|
+
if (Un) return ke.exports;
|
|
8798
|
+
Un = 1;
|
|
8799
|
+
const e = require$$0$2, t = Jo(), r = Qo();
|
|
8800
|
+
function n(o, c, l) {
|
|
8801
|
+
const h = t(o, c, l), g = e.spawn(h.command, h.args, h.options);
|
|
8802
|
+
return r.hookChildProcess(g, h), g;
|
|
8658
8803
|
}
|
|
8659
8804
|
s(n, "spawn");
|
|
8660
|
-
function o
|
|
8661
|
-
const h = t(
|
|
8662
|
-
return
|
|
8805
|
+
function i(o, c, l) {
|
|
8806
|
+
const h = t(o, c, l), g = e.spawnSync(h.command, h.args, h.options);
|
|
8807
|
+
return g.error = g.error || r.verifyENOENTSync(g.status, h), g;
|
|
8663
8808
|
}
|
|
8664
|
-
return s(
|
|
8809
|
+
return s(i, "spawnSync"), ke.exports = n, ke.exports.spawn = n, ke.exports.sync = i, ke.exports._parse = t, ke.exports._enoent = r, ke.exports;
|
|
8665
8810
|
}
|
|
8666
|
-
s(
|
|
8667
|
-
var
|
|
8668
|
-
function
|
|
8811
|
+
s(Xo, "requireCrossSpawn");
|
|
8812
|
+
var Zo = Xo(), es = kr(Zo);
|
|
8813
|
+
function ts(e) {
|
|
8669
8814
|
const t = typeof e == "string" ? `
|
|
8670
8815
|
` : 10, r = typeof e == "string" ? "\r" : 13;
|
|
8671
8816
|
return e[e.length - 1] === t && (e = e.slice(0, -1)), e[e.length - 1] === r && (e = e.slice(0, -1)), e;
|
|
8672
8817
|
}
|
|
8673
|
-
s(
|
|
8674
|
-
function
|
|
8818
|
+
s(ts, "stripFinalNewline");
|
|
8819
|
+
function Bn(e = {}) {
|
|
8675
8820
|
const { env: t = process.env, platform: r = process.platform } = e;
|
|
8676
8821
|
return r !== "win32" ? "PATH" : Object.keys(t).reverse().find((n) => n.toUpperCase() === "PATH") || "Path";
|
|
8677
8822
|
}
|
|
8678
|
-
s(
|
|
8679
|
-
const
|
|
8680
|
-
const
|
|
8681
|
-
return r &&
|
|
8682
|
-
}, "npmRunPath"),
|
|
8823
|
+
s(Bn, "pathKey");
|
|
8824
|
+
const rs = s(({ cwd: e = y.cwd(), path: t = y.env[Bn()], preferLocal: r = true, execPath: n = y.execPath, addExecPath: i = true } = {}) => {
|
|
8825
|
+
const o = e instanceof URL ? fileURLToPath(e) : e, c = path.resolve(o), l = [];
|
|
8826
|
+
return r && ns(l, c), i && is(l, n, c), [...l, t].join(path.delimiter);
|
|
8827
|
+
}, "npmRunPath"), ns = s((e, t) => {
|
|
8683
8828
|
let r;
|
|
8684
8829
|
for (; r !== t; ) e.push(path.join(t, "node_modules/.bin")), r = t, t = path.resolve(t, "..");
|
|
8685
|
-
}, "applyPreferLocal"),
|
|
8830
|
+
}, "applyPreferLocal"), is = s((e, t, r) => {
|
|
8686
8831
|
const n = t instanceof URL ? fileURLToPath(t) : t;
|
|
8687
8832
|
e.push(path.resolve(r, n, ".."));
|
|
8688
|
-
}, "applyExecPath"),
|
|
8833
|
+
}, "applyExecPath"), os = s(({ env: e = y.env, ...t } = {}) => {
|
|
8689
8834
|
e = { ...e };
|
|
8690
|
-
const r =
|
|
8691
|
-
return t.path = e[r], e[r] =
|
|
8692
|
-
}, "npmRunPathEnv"),
|
|
8693
|
-
const e =
|
|
8694
|
-
return Array.from({ length: e },
|
|
8695
|
-
}, "getRealtimeSignals"),
|
|
8696
|
-
const e =
|
|
8697
|
-
return [...
|
|
8698
|
-
}, "getSignals"),
|
|
8835
|
+
const r = Bn({ env: e });
|
|
8836
|
+
return t.path = e[r], e[r] = rs(t), e;
|
|
8837
|
+
}, "npmRunPathEnv"), ss = s(() => {
|
|
8838
|
+
const e = Ln - On + 1;
|
|
8839
|
+
return Array.from({ length: e }, as);
|
|
8840
|
+
}, "getRealtimeSignals"), as = s((e, t) => ({ name: `SIGRT${t + 1}`, number: On + t, action: "terminate", description: "Application-specific signal (realtime)", standard: "posix" }), "getRealtimeSignal"), On = 34, Ln = 64, cs = [{ name: "SIGHUP", number: 1, action: "terminate", description: "Terminal closed", standard: "posix" }, { name: "SIGINT", number: 2, action: "terminate", description: "User interruption with CTRL-C", standard: "ansi" }, { name: "SIGQUIT", number: 3, action: "core", description: "User interruption with CTRL-\\", standard: "posix" }, { name: "SIGILL", number: 4, action: "core", description: "Invalid machine instruction", standard: "ansi" }, { name: "SIGTRAP", number: 5, action: "core", description: "Debugger breakpoint", standard: "posix" }, { name: "SIGABRT", number: 6, action: "core", description: "Aborted", standard: "ansi" }, { name: "SIGIOT", number: 6, action: "core", description: "Aborted", standard: "bsd" }, { name: "SIGBUS", number: 7, action: "core", description: "Bus error due to misaligned, non-existing address or paging error", standard: "bsd" }, { name: "SIGEMT", number: 7, action: "terminate", description: "Command should be emulated but is not implemented", standard: "other" }, { name: "SIGFPE", number: 8, action: "core", description: "Floating point arithmetic error", standard: "ansi" }, { name: "SIGKILL", number: 9, action: "terminate", description: "Forced termination", standard: "posix", forced: true }, { name: "SIGUSR1", number: 10, action: "terminate", description: "Application-specific signal", standard: "posix" }, { name: "SIGSEGV", number: 11, action: "core", description: "Segmentation fault", standard: "ansi" }, { name: "SIGUSR2", number: 12, action: "terminate", description: "Application-specific signal", standard: "posix" }, { name: "SIGPIPE", number: 13, action: "terminate", description: "Broken pipe or socket", standard: "posix" }, { name: "SIGALRM", number: 14, action: "terminate", description: "Timeout or timer", standard: "posix" }, { name: "SIGTERM", number: 15, action: "terminate", description: "Termination", standard: "ansi" }, { name: "SIGSTKFLT", number: 16, action: "terminate", description: "Stack is empty or overflowed", standard: "other" }, { name: "SIGCHLD", number: 17, action: "ignore", description: "Child process terminated, paused or unpaused", standard: "posix" }, { name: "SIGCLD", number: 17, action: "ignore", description: "Child process terminated, paused or unpaused", standard: "other" }, { name: "SIGCONT", number: 18, action: "unpause", description: "Unpaused", standard: "posix", forced: true }, { name: "SIGSTOP", number: 19, action: "pause", description: "Paused", standard: "posix", forced: true }, { name: "SIGTSTP", number: 20, action: "pause", description: 'Paused using CTRL-Z or "suspend"', standard: "posix" }, { name: "SIGTTIN", number: 21, action: "pause", description: "Background process cannot read terminal input", standard: "posix" }, { name: "SIGBREAK", number: 21, action: "terminate", description: "User interruption with CTRL-BREAK", standard: "other" }, { name: "SIGTTOU", number: 22, action: "pause", description: "Background process cannot write to terminal output", standard: "posix" }, { name: "SIGURG", number: 23, action: "ignore", description: "Socket received out-of-band data", standard: "bsd" }, { name: "SIGXCPU", number: 24, action: "core", description: "Process timed out", standard: "bsd" }, { name: "SIGXFSZ", number: 25, action: "core", description: "File too big", standard: "bsd" }, { name: "SIGVTALRM", number: 26, action: "terminate", description: "Timeout or timer", standard: "bsd" }, { name: "SIGPROF", number: 27, action: "terminate", description: "Timeout or timer", standard: "bsd" }, { name: "SIGWINCH", number: 28, action: "ignore", description: "Terminal window size changed", standard: "bsd" }, { name: "SIGIO", number: 29, action: "terminate", description: "I/O is available", standard: "other" }, { name: "SIGPOLL", number: 29, action: "terminate", description: "Watched event", standard: "other" }, { name: "SIGINFO", number: 29, action: "ignore", description: "Request for process information", standard: "other" }, { name: "SIGPWR", number: 30, action: "terminate", description: "Device running out of power", standard: "systemv" }, { name: "SIGSYS", number: 31, action: "core", description: "Invalid system call", standard: "other" }, { name: "SIGUNUSED", number: 31, action: "terminate", description: "Invalid system call", standard: "other" }], Pn = s(() => {
|
|
8841
|
+
const e = ss();
|
|
8842
|
+
return [...cs, ...e].map(us);
|
|
8843
|
+
}, "getSignals"), us = s(({ name: e, number: t, description: r, action: n, forced: i = false, standard: o }) => {
|
|
8699
8844
|
const { signals: { [e]: c } } = constants$1, l = c !== void 0;
|
|
8700
|
-
return { name: e, number: l ? c : t, description: r, supported: l, action: n, forced:
|
|
8701
|
-
}, "normalizeSignal"),
|
|
8702
|
-
const e =
|
|
8703
|
-
return Object.fromEntries(e.map(
|
|
8704
|
-
}, "getSignalsByName"),
|
|
8705
|
-
const e =
|
|
8845
|
+
return { name: e, number: l ? c : t, description: r, supported: l, action: n, forced: i, standard: o };
|
|
8846
|
+
}, "normalizeSignal"), ls = s(() => {
|
|
8847
|
+
const e = Pn();
|
|
8848
|
+
return Object.fromEntries(e.map(fs));
|
|
8849
|
+
}, "getSignalsByName"), fs = s(({ name: e, number: t, description: r, supported: n, action: i, forced: o, standard: c }) => [e, { name: e, number: t, description: r, supported: n, action: i, forced: o, standard: c }], "getSignalByName"), hs = ls(), ds = s(() => {
|
|
8850
|
+
const e = Pn(), t = Ln + 1, r = Array.from({ length: t }, (n, i) => ps(i, e));
|
|
8706
8851
|
return Object.assign({}, ...r);
|
|
8707
|
-
}, "getSignalsByNumber"),
|
|
8708
|
-
const r =
|
|
8852
|
+
}, "getSignalsByNumber"), ps = s((e, t) => {
|
|
8853
|
+
const r = ms(e, t);
|
|
8709
8854
|
if (r === void 0) return {};
|
|
8710
|
-
const { name: n, description:
|
|
8711
|
-
return { [e]: { name: n, number: e, description:
|
|
8712
|
-
}, "getSignalByNumber"),
|
|
8855
|
+
const { name: n, description: i, supported: o, action: c, forced: l, standard: h } = r;
|
|
8856
|
+
return { [e]: { name: n, number: e, description: i, supported: o, action: c, forced: l, standard: h } };
|
|
8857
|
+
}, "getSignalByNumber"), ms = s((e, t) => {
|
|
8713
8858
|
const r = t.find(({ name: n }) => constants$1.signals[n] === e);
|
|
8714
8859
|
return r !== void 0 ? r : t.find((n) => n.number === e);
|
|
8715
8860
|
}, "findSignalByNumber");
|
|
8716
|
-
|
|
8717
|
-
const
|
|
8718
|
-
|
|
8719
|
-
const O =
|
|
8720
|
-
${n.message}` :
|
|
8861
|
+
ds();
|
|
8862
|
+
const Es = s(({ timedOut: e, timeout: t, errorCode: r, signal: n, signalDescription: i, exitCode: o, isCanceled: c }) => e ? `timed out after ${t} milliseconds` : r !== void 0 ? `failed with ${r}` : n !== void 0 ? `was killed with ${n} (${i})` : o !== void 0 ? `failed with exit code ${o}` : "failed", "getErrorPrefix"), Nn = s(({ stdout: e, stderr: t, all: r, error: n, signal: i, exitCode: o, command: c, escapedCommand: l, timedOut: h, isCanceled: g, killed: m, parsed: { options: { timeout: A, cwd: b = y.cwd() } } }) => {
|
|
8863
|
+
o = o === null ? void 0 : o, i = i === null ? void 0 : i;
|
|
8864
|
+
const O = i === void 0 ? void 0 : hs[i].description, x = n && n.code, w = `Command ${Es({ timedOut: h, timeout: A, errorCode: x, signal: i, signalDescription: O, exitCode: o, isCanceled: g })}: ${c}`, C = Object.prototype.toString.call(n) === "[object Error]", y = C ? `${w}
|
|
8865
|
+
${n.message}` : w, B = [y, t, e].filter(Boolean).join(`
|
|
8721
8866
|
`);
|
|
8722
|
-
return C ? (n.originalMessage = n.message, n.message = B) : n = new Error(B), n.shortMessage =
|
|
8723
|
-
}, "makeError"), Tt = ["stdin", "stdout", "stderr"],
|
|
8867
|
+
return C ? (n.originalMessage = n.message, n.message = B) : n = new Error(B), n.shortMessage = y, n.command = c, n.escapedCommand = l, n.exitCode = o, n.signal = i, n.signalDescription = O, n.stdout = e, n.stderr = t, n.cwd = b, r !== void 0 && (n.all = r), "bufferedData" in n && delete n.bufferedData, n.failed = true, n.timedOut = !!h, n.isCanceled = g, n.killed = m && !h, n;
|
|
8868
|
+
}, "makeError"), Tt = ["stdin", "stdout", "stderr"], _s = s((e) => Tt.some((t) => e[t] !== void 0), "hasAlias"), gs = s((e) => {
|
|
8724
8869
|
if (!e) return;
|
|
8725
8870
|
const { stdio: t } = e;
|
|
8726
8871
|
if (t === void 0) return Tt.map((n) => e[n]);
|
|
8727
|
-
if (
|
|
8872
|
+
if (_s(e)) throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${Tt.map((n) => `\`${n}\``).join(", ")}`);
|
|
8728
8873
|
if (typeof t == "string") return t;
|
|
8729
8874
|
if (!Array.isArray(t)) throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof t}\``);
|
|
8730
8875
|
const r = Math.max(t.length, Tt.length);
|
|
8731
|
-
return Array.from({ length: r }, (n,
|
|
8876
|
+
return Array.from({ length: r }, (n, i) => t[i]);
|
|
8732
8877
|
}, "normalizeStdio"), Ye = [];
|
|
8733
8878
|
Ye.push("SIGHUP", "SIGINT", "SIGTERM"), process.platform !== "win32" && Ye.push("SIGALRM", "SIGABRT", "SIGVTALRM", "SIGXCPU", "SIGXFSZ", "SIGUSR2", "SIGTRAP", "SIGSYS", "SIGQUIT", "SIGIOT"), process.platform === "linux" && Ye.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");
|
|
8734
|
-
const
|
|
8735
|
-
class
|
|
8879
|
+
const yt = s((e) => !!e && typeof e == "object" && typeof e.removeListener == "function" && typeof e.emit == "function" && typeof e.reallyExit == "function" && typeof e.listeners == "function" && typeof e.kill == "function" && typeof e.pid == "number" && typeof e.on == "function", "processOk"), sr = Symbol.for("signal-exit emitter"), ar = globalThis, Is = Object.defineProperty.bind(Object);
|
|
8880
|
+
class Ss {
|
|
8736
8881
|
static {
|
|
8737
8882
|
s(this, "Emitter");
|
|
8738
8883
|
}
|
|
@@ -8741,37 +8886,37 @@ class ds {
|
|
|
8741
8886
|
count = 0;
|
|
8742
8887
|
id = Math.random();
|
|
8743
8888
|
constructor() {
|
|
8744
|
-
if (sr
|
|
8745
|
-
|
|
8889
|
+
if (ar[sr]) return ar[sr];
|
|
8890
|
+
Is(ar, sr, { value: this, writable: false, enumerable: false, configurable: false });
|
|
8746
8891
|
}
|
|
8747
8892
|
on(t, r) {
|
|
8748
8893
|
this.listeners[t].push(r);
|
|
8749
8894
|
}
|
|
8750
8895
|
removeListener(t, r) {
|
|
8751
|
-
const n = this.listeners[t],
|
|
8752
|
-
|
|
8896
|
+
const n = this.listeners[t], i = n.indexOf(r);
|
|
8897
|
+
i !== -1 && (i === 0 && n.length === 1 ? n.length = 0 : n.splice(i, 1));
|
|
8753
8898
|
}
|
|
8754
8899
|
emit(t, r, n) {
|
|
8755
8900
|
if (this.emitted[t]) return false;
|
|
8756
8901
|
this.emitted[t] = true;
|
|
8757
|
-
let
|
|
8758
|
-
for (const
|
|
8759
|
-
return t === "exit" && (
|
|
8902
|
+
let i = false;
|
|
8903
|
+
for (const o of this.listeners[t]) i = o(r, n) === true || i;
|
|
8904
|
+
return t === "exit" && (i = this.emit("afterExit", r, n) || i), i;
|
|
8760
8905
|
}
|
|
8761
8906
|
}
|
|
8762
|
-
class
|
|
8907
|
+
class Dn {
|
|
8763
8908
|
static {
|
|
8764
8909
|
s(this, "SignalExitBase");
|
|
8765
8910
|
}
|
|
8766
8911
|
}
|
|
8767
|
-
const
|
|
8912
|
+
const Rs = s((e) => ({ onExit(t, r) {
|
|
8768
8913
|
return e.onExit(t, r);
|
|
8769
8914
|
}, load() {
|
|
8770
8915
|
return e.load();
|
|
8771
8916
|
}, unload() {
|
|
8772
8917
|
return e.unload();
|
|
8773
8918
|
} }), "signalExitWrap");
|
|
8774
|
-
class
|
|
8919
|
+
class Ts extends Dn {
|
|
8775
8920
|
static {
|
|
8776
8921
|
s(this, "SignalExitFallback");
|
|
8777
8922
|
}
|
|
@@ -8784,12 +8929,12 @@ class ms extends On {
|
|
|
8784
8929
|
unload() {
|
|
8785
8930
|
}
|
|
8786
8931
|
}
|
|
8787
|
-
class
|
|
8932
|
+
class ys extends Dn {
|
|
8788
8933
|
static {
|
|
8789
8934
|
s(this, "SignalExit");
|
|
8790
8935
|
}
|
|
8791
|
-
#s =
|
|
8792
|
-
#t = new
|
|
8936
|
+
#s = cr.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
8937
|
+
#t = new Ss();
|
|
8793
8938
|
#e;
|
|
8794
8939
|
#i;
|
|
8795
8940
|
#o;
|
|
@@ -8799,9 +8944,9 @@ class Es extends On {
|
|
|
8799
8944
|
super(), this.#e = t, this.#n = {};
|
|
8800
8945
|
for (const r of Ye) this.#n[r] = () => {
|
|
8801
8946
|
const n = this.#e.listeners(r);
|
|
8802
|
-
let { count:
|
|
8803
|
-
const
|
|
8804
|
-
if (typeof
|
|
8947
|
+
let { count: i } = this.#t;
|
|
8948
|
+
const o = t;
|
|
8949
|
+
if (typeof o.__signal_exit_emitter__ == "object" && typeof o.__signal_exit_emitter__.count == "number" && (i += o.__signal_exit_emitter__.count), n.length === i) {
|
|
8805
8950
|
this.unload();
|
|
8806
8951
|
const c = this.#t.emit("exit", null, r), l = r === "SIGHUP" ? this.#s : r;
|
|
8807
8952
|
c || t.kill(t.pid, l);
|
|
@@ -8810,7 +8955,7 @@ class Es extends On {
|
|
|
8810
8955
|
this.#o = t.reallyExit, this.#i = t.emit;
|
|
8811
8956
|
}
|
|
8812
8957
|
onExit(t, r) {
|
|
8813
|
-
if (!
|
|
8958
|
+
if (!yt(this.#e)) return () => {
|
|
8814
8959
|
};
|
|
8815
8960
|
this.#r === false && this.load();
|
|
8816
8961
|
const n = r?.alwaysLast ? "afterExit" : "exit";
|
|
@@ -8840,99 +8985,99 @@ class Es extends On {
|
|
|
8840
8985
|
}), this.#e.emit = this.#i, this.#e.reallyExit = this.#o, this.#t.count -= 1);
|
|
8841
8986
|
}
|
|
8842
8987
|
#a(t) {
|
|
8843
|
-
return
|
|
8988
|
+
return yt(this.#e) ? (this.#e.exitCode = t || 0, this.#t.emit("exit", this.#e.exitCode, null), this.#o.call(this.#e, this.#e.exitCode)) : 0;
|
|
8844
8989
|
}
|
|
8845
8990
|
#c(t, ...r) {
|
|
8846
8991
|
const n = this.#i;
|
|
8847
|
-
if (t === "exit" &&
|
|
8992
|
+
if (t === "exit" && yt(this.#e)) {
|
|
8848
8993
|
typeof r[0] == "number" && (this.#e.exitCode = r[0]);
|
|
8849
|
-
const
|
|
8850
|
-
return this.#t.emit("exit", this.#e.exitCode, null),
|
|
8994
|
+
const i = n.call(this.#e, t, ...r);
|
|
8995
|
+
return this.#t.emit("exit", this.#e.exitCode, null), i;
|
|
8851
8996
|
} else return n.call(this.#e, t, ...r);
|
|
8852
8997
|
}
|
|
8853
8998
|
}
|
|
8854
|
-
const
|
|
8855
|
-
|
|
8856
|
-
function
|
|
8999
|
+
const cr = globalThis.process;
|
|
9000
|
+
Rs(yt(cr) ? new ys(cr) : new Ts());
|
|
9001
|
+
function ws(e) {
|
|
8857
9002
|
return e !== null && typeof e == "object" && typeof e.pipe == "function";
|
|
8858
9003
|
}
|
|
8859
|
-
s(
|
|
8860
|
-
var
|
|
8861
|
-
function
|
|
8862
|
-
if (
|
|
8863
|
-
|
|
9004
|
+
s(ws, "isStream"), new TextEncoder();
|
|
9005
|
+
var ur, Mn;
|
|
9006
|
+
function As() {
|
|
9007
|
+
if (Mn) return ur;
|
|
9008
|
+
Mn = 1;
|
|
8864
9009
|
const { PassThrough: e } = require$$0;
|
|
8865
|
-
return
|
|
9010
|
+
return ur = s(function() {
|
|
8866
9011
|
var t = [], r = new e({ objectMode: true });
|
|
8867
|
-
return r.setMaxListeners(0), r.add = n, r.isEmpty =
|
|
9012
|
+
return r.setMaxListeners(0), r.add = n, r.isEmpty = i, r.on("unpipe", o), Array.prototype.slice.call(arguments).forEach(n), r;
|
|
8868
9013
|
function n(c) {
|
|
8869
|
-
return Array.isArray(c) ? (c.forEach(n), this) : (t.push(c), c.once("end",
|
|
9014
|
+
return Array.isArray(c) ? (c.forEach(n), this) : (t.push(c), c.once("end", o.bind(null, c)), c.once("error", r.emit.bind(r, "error")), c.pipe(r, { end: false }), this);
|
|
8870
9015
|
}
|
|
8871
|
-
function
|
|
9016
|
+
function i() {
|
|
8872
9017
|
return t.length == 0;
|
|
8873
9018
|
}
|
|
8874
|
-
function
|
|
9019
|
+
function o(c) {
|
|
8875
9020
|
t = t.filter(function(l) {
|
|
8876
9021
|
return l !== c;
|
|
8877
9022
|
}), !t.length && r.readable && r.end();
|
|
8878
9023
|
}
|
|
8879
|
-
}, "mergeStream"),
|
|
9024
|
+
}, "mergeStream"), ur;
|
|
8880
9025
|
}
|
|
8881
|
-
s(
|
|
8882
|
-
const
|
|
9026
|
+
s(As, "requireMergeStream"), As();
|
|
9027
|
+
const vs = s((e) => {
|
|
8883
9028
|
if (e !== void 0) throw new TypeError("The `input` and `inputFile` options cannot be both set.");
|
|
8884
|
-
}, "validateInputOptions"),
|
|
8885
|
-
const t =
|
|
8886
|
-
if (
|
|
9029
|
+
}, "validateInputOptions"), bs = s(({ input: e, inputFile: t }) => typeof t != "string" ? e : (vs(e), readFileSync(t)), "getInputSync"), Cs = s((e) => {
|
|
9030
|
+
const t = bs(e);
|
|
9031
|
+
if (ws(t)) throw new TypeError("The `input` option cannot be a stream in sync mode");
|
|
8887
9032
|
return t;
|
|
8888
|
-
}, "handleInputSync"),
|
|
9033
|
+
}, "handleInputSync"), Us = (async () => {
|
|
8889
9034
|
})().constructor.prototype;
|
|
8890
|
-
["then", "catch", "finally"].map((e) => [e, Reflect.getOwnPropertyDescriptor(
|
|
8891
|
-
const
|
|
9035
|
+
["then", "catch", "finally"].map((e) => [e, Reflect.getOwnPropertyDescriptor(Us, e)]);
|
|
9036
|
+
const xn = s((e, t = []) => Array.isArray(t) ? [e, ...t] : [e], "normalizeArgs"), Bs = /^[\w.-]+$/, Os = s((e) => typeof e != "string" || Bs.test(e) ? e : `"${e.replaceAll('"', '\\"')}"`, "escapeArg"), Ls = s((e, t) => xn(e, t).join(" "), "joinCommand"), Ps = s((e, t) => xn(e, t).map((r) => Os(r)).join(" "), "getEscapedCommand"), Ns = debuglog("execa").enabled, wt = s((e, t) => String(e).padStart(t, "0"), "padField"), Ds = s(() => {
|
|
8892
9037
|
const e = /* @__PURE__ */ new Date();
|
|
8893
|
-
return `${
|
|
8894
|
-
}, "getTimestamp"),
|
|
8895
|
-
t && y.stderr.write(`[${
|
|
9038
|
+
return `${wt(e.getHours(), 2)}:${wt(e.getMinutes(), 2)}:${wt(e.getSeconds(), 2)}.${wt(e.getMilliseconds(), 3)}`;
|
|
9039
|
+
}, "getTimestamp"), Ms = s((e, { verbose: t }) => {
|
|
9040
|
+
t && y.stderr.write(`[${Ds()}] ${e}
|
|
8896
9041
|
`);
|
|
8897
|
-
}, "logCommand"),
|
|
8898
|
-
const
|
|
8899
|
-
return r ?
|
|
8900
|
-
}, "getEnv"),
|
|
8901
|
-
const n =
|
|
8902
|
-
return e = n.command, t = n.args, r = n.options, r = { maxBuffer:
|
|
8903
|
-
}, "handleArguments"),
|
|
8904
|
-
function
|
|
8905
|
-
const n =
|
|
8906
|
-
|
|
8907
|
-
const c =
|
|
9042
|
+
}, "logCommand"), xs = 1e3 * 1e3 * 100, Gs = s(({ env: e, extendEnv: t, preferLocal: r, localDir: n, execPath: i }) => {
|
|
9043
|
+
const o = t ? { ...y.env, ...e } : e;
|
|
9044
|
+
return r ? os({ env: o, cwd: n, execPath: i }) : o;
|
|
9045
|
+
}, "getEnv"), $s = s((e, t, r = {}) => {
|
|
9046
|
+
const n = es._parse(e, t, r);
|
|
9047
|
+
return e = n.command, t = n.args, r = n.options, r = { maxBuffer: xs, buffer: true, stripFinalNewline: true, extendEnv: true, preferLocal: false, localDir: r.cwd || y.cwd(), execPath: y.execPath, encoding: "utf8", reject: true, cleanup: true, all: false, windowsHide: true, verbose: Ns, ...r }, r.env = Gs(r), r.stdio = gs(r), y.platform === "win32" && path.basename(e, ".exe") === "cmd" && t.unshift("/q"), { file: e, args: t, options: r, parsed: n };
|
|
9048
|
+
}, "handleArguments"), Gn = s((e, t, r) => typeof t != "string" && !Buffer$1.isBuffer(t) ? r === void 0 ? void 0 : "" : e.stripFinalNewline ? ts(t) : t, "handleOutput");
|
|
9049
|
+
function lr(e, t, r) {
|
|
9050
|
+
const n = $s(e, t, r), i = Ls(e, t), o = Ps(e, t);
|
|
9051
|
+
Ms(o, n.options);
|
|
9052
|
+
const c = Cs(n.options);
|
|
8908
9053
|
let l;
|
|
8909
9054
|
try {
|
|
8910
9055
|
l = childProcess.spawnSync(n.file, n.args, { ...n.options, input: c });
|
|
8911
9056
|
} catch (m) {
|
|
8912
|
-
throw
|
|
9057
|
+
throw Nn({ error: m, stdout: "", stderr: "", all: "", command: i, escapedCommand: o, parsed: n, timedOut: false, isCanceled: false, killed: false });
|
|
8913
9058
|
}
|
|
8914
|
-
const h =
|
|
9059
|
+
const h = Gn(n.options, l.stdout, l.error), g = Gn(n.options, l.stderr, l.error);
|
|
8915
9060
|
if (l.error || l.status !== 0 || l.signal !== null) {
|
|
8916
|
-
const m =
|
|
9061
|
+
const m = Nn({ stdout: h, stderr: g, error: l.error, signal: l.signal, exitCode: l.status, command: i, escapedCommand: o, parsed: n, timedOut: l.error && l.error.code === "ETIMEDOUT", isCanceled: false, killed: l.signal !== null });
|
|
8917
9062
|
if (!n.options.reject) return m;
|
|
8918
9063
|
throw m;
|
|
8919
9064
|
}
|
|
8920
|
-
return { command:
|
|
9065
|
+
return { command: i, escapedCommand: o, exitCode: 0, stdout: h, stderr: g, failed: false, timedOut: false, isCanceled: false, killed: false };
|
|
8921
9066
|
}
|
|
8922
|
-
s(
|
|
9067
|
+
s(lr, "execaSync");
|
|
8923
9068
|
function At(e) {
|
|
8924
9069
|
try {
|
|
8925
|
-
return
|
|
9070
|
+
return lr("git", ["rev-parse", "HEAD"], e).stdout;
|
|
8926
9071
|
} catch {
|
|
8927
9072
|
return;
|
|
8928
9073
|
}
|
|
8929
9074
|
}
|
|
8930
9075
|
s(At, "head");
|
|
8931
|
-
function
|
|
9076
|
+
function fr(e) {
|
|
8932
9077
|
try {
|
|
8933
|
-
const t =
|
|
9078
|
+
const t = lr("git", ["rev-parse", "--abbrev-ref", "HEAD"], e).stdout;
|
|
8934
9079
|
if (t === "HEAD") {
|
|
8935
|
-
const r =
|
|
9080
|
+
const r = lr("git", ["show", "-s", "--pretty=%d", "HEAD"], e).stdout.replace(/^\(|\)$/g, "").split(", ").find((n) => n.startsWith("origin/"));
|
|
8936
9081
|
return r ? r.match(/^origin\/(?<branch>.+)/)[1] : void 0;
|
|
8937
9082
|
}
|
|
8938
9083
|
return t;
|
|
@@ -8940,217 +9085,217 @@ function lr(e) {
|
|
|
8940
9085
|
return;
|
|
8941
9086
|
}
|
|
8942
9087
|
}
|
|
8943
|
-
s(
|
|
8944
|
-
const
|
|
8945
|
-
function
|
|
9088
|
+
s(fr, "branch");
|
|
9089
|
+
const $n = /^(?:.*)@(?:.*):(?:\d+\/)?(.*)\.git$/, ks = /^\/(.*)\.git$/;
|
|
9090
|
+
function Hs(e) {
|
|
8946
9091
|
if (e) {
|
|
8947
|
-
if (e.match(
|
|
9092
|
+
if (e.match($n)) return e.replace($n, "$1");
|
|
8948
9093
|
try {
|
|
8949
|
-
return new URL(e).pathname.replace(
|
|
9094
|
+
return new URL(e).pathname.replace(ks, "$1");
|
|
8950
9095
|
} catch {
|
|
8951
9096
|
return;
|
|
8952
9097
|
}
|
|
8953
9098
|
}
|
|
8954
9099
|
}
|
|
8955
|
-
s(
|
|
8956
|
-
var
|
|
9100
|
+
s(Hs, "getSlugFromGitURL");
|
|
9101
|
+
var Fs = { detect({ env: e }) {
|
|
8957
9102
|
return !!e.BUILDKITE;
|
|
8958
9103
|
}, configuration({ env: e }) {
|
|
8959
9104
|
const t = e.BUILDKITE_PULL_REQUEST === "false" ? void 0 : e.BUILDKITE_PULL_REQUEST, r = !!t;
|
|
8960
|
-
return { name: "Buildkite", service: "buildkite", build: e.BUILDKITE_BUILD_NUMBER, buildUrl: e.BUILDKITE_BUILD_URL, commit: e.BUILDKITE_COMMIT, tag: e.BUILDKITE_TAG, branch: r ? e.BUILDKITE_PULL_REQUEST_BASE_BRANCH : e.BUILDKITE_BRANCH, slug:
|
|
8961
|
-
} },
|
|
9105
|
+
return { name: "Buildkite", service: "buildkite", build: e.BUILDKITE_BUILD_NUMBER, buildUrl: e.BUILDKITE_BUILD_URL, commit: e.BUILDKITE_COMMIT, tag: e.BUILDKITE_TAG, branch: r ? e.BUILDKITE_PULL_REQUEST_BASE_BRANCH : e.BUILDKITE_BRANCH, slug: Hs(e.BUILDKITE_REPO), pr: t, isPr: r, prBranch: r ? e.BUILDKITE_BRANCH : void 0, root: e.BUILDKITE_BUILD_CHECKOUT_PATH };
|
|
9106
|
+
} }, js = { detect({ env: e }) {
|
|
8962
9107
|
return !!e.CIRCLECI;
|
|
8963
9108
|
}, configuration({ env: e }) {
|
|
8964
|
-
const t = e.CIRCLE_PR_NUMBER ||
|
|
9109
|
+
const t = e.CIRCLE_PR_NUMBER || En(e.CIRCLE_PULL_REQUEST || e.CI_PULL_REQUEST), r = !!t;
|
|
8965
9110
|
return { name: "CircleCI", service: "circleci", build: e.CIRCLE_BUILD_NUM, buildUrl: e.CIRCLE_BUILD_URL, job: `${e.CIRCLE_BUILD_NUM}.${e.CIRCLE_NODE_INDEX}`, commit: e.CIRCLE_SHA1, tag: e.CIRCLE_TAG, branch: r ? void 0 : e.CIRCLE_BRANCH, pr: t, isPr: r, prBranch: r ? e.CIRCLE_BRANCH : void 0, slug: `${e.CIRCLE_PROJECT_USERNAME}/${e.CIRCLE_PROJECT_REPONAME}` };
|
|
8966
9111
|
} };
|
|
8967
|
-
const
|
|
8968
|
-
var
|
|
9112
|
+
const kn = "https://cirrus-ci.com";
|
|
9113
|
+
var qs = { detect({ env: e }) {
|
|
8969
9114
|
return !!e.CIRRUS_CI;
|
|
8970
9115
|
}, configuration({ env: e }) {
|
|
8971
9116
|
const t = e.CIRRUS_PR, r = !!t;
|
|
8972
|
-
return { name: "Cirrus CI", service: "cirrus", commit: e.CIRRUS_CHANGE_IN_REPO, tag: e.CIRRUS_TAG, build: e.CIRRUS_BUILD_ID, buildUrl: `${
|
|
8973
|
-
} },
|
|
9117
|
+
return { name: "Cirrus CI", service: "cirrus", commit: e.CIRRUS_CHANGE_IN_REPO, tag: e.CIRRUS_TAG, build: e.CIRRUS_BUILD_ID, buildUrl: `${kn}/build/${e.CIRRUS_BUILD_ID}`, job: e.CIRRUS_TASK_ID, jobUrl: `${kn}/task/${e.CIRRUS_TASK_ID}`, branch: r ? e.CIRRUS_BASE_BRANCH : e.CIRRUS_BRANCH, pr: t, isPr: r, prBranch: r ? e.CIRRUS_BRANCH : void 0, slug: e.CIRRUS_REPO_FULL_NAME, root: e.CIRRUS_WORKING_DIR };
|
|
9118
|
+
} }, Ws = { detect({ env: e }) {
|
|
8974
9119
|
return e.CF_PAGES === "1";
|
|
8975
9120
|
}, configuration({ env: e }) {
|
|
8976
9121
|
return { name: "Cloudflare Pages", service: "cloudflarePages", commit: e.CF_PAGES_COMMIT_SHA, branch: e.CF_PAGES_BRANCH, root: e.PWD };
|
|
8977
|
-
} },
|
|
9122
|
+
} }, Ks = { detect({ env: e }) {
|
|
8978
9123
|
return !!e.CODEBUILD_BUILD_ID;
|
|
8979
9124
|
}, configuration({ env: e, cwd: t }) {
|
|
8980
|
-
return { name: "AWS CodeBuild", service: "codebuild", commit: At({ env: e, cwd: t }), build: e.CODEBUILD_BUILD_ID, branch:
|
|
8981
|
-
} },
|
|
9125
|
+
return { name: "AWS CodeBuild", service: "codebuild", commit: At({ env: e, cwd: t }), build: e.CODEBUILD_BUILD_ID, branch: fr({ env: e, cwd: t }), buildUrl: `https://console.aws.amazon.com/codebuild/home?region=${e.AWS_REGION}#/builds/${e.CODEBUILD_BUILD_ID}/view/new`, root: e.PWD };
|
|
9126
|
+
} }, Vs = { detect({ env: e }) {
|
|
8982
9127
|
return !!e.CF_BUILD_ID;
|
|
8983
9128
|
}, configuration({ env: e }) {
|
|
8984
9129
|
const t = e.CF_PULL_REQUEST_NUMBER, r = !!t;
|
|
8985
9130
|
return { name: "Codefresh", service: "codefresh", commit: e.CF_REVISION, build: e.CF_BUILD_ID, buildUrl: e.CF_BUILD_URL, branch: r ? e.CF_PULL_REQUEST_TARGET : e.CF_BRANCH, pr: t, isPr: r, prBranch: r ? e.CF_BRANCH : void 0, slug: `${e.CF_REPO_OWNER}/${e.CF_REPO_NAME}`, root: e.CF_VOLUME_PATH };
|
|
8986
|
-
} },
|
|
9131
|
+
} }, Ys = { detect({ env: e }) {
|
|
8987
9132
|
return e.CI_NAME && e.CI_NAME === "codeship";
|
|
8988
9133
|
}, configuration({ env: e }) {
|
|
8989
9134
|
return { name: "Codeship", service: "codeship", build: e.CI_BUILD_NUMBER, buildUrl: e.CI_BUILD_URL, commit: e.CI_COMMIT_ID, branch: e.CI_BRANCH, slug: e.CI_REPO_NAME };
|
|
8990
|
-
} },
|
|
9135
|
+
} }, zs = { detect({ env: e }) {
|
|
8991
9136
|
return !!e.DRONE;
|
|
8992
9137
|
}, configuration({ env: e }) {
|
|
8993
9138
|
const t = e.DRONE_BUILD_EVENT === "pull_request";
|
|
8994
9139
|
return { name: "Drone", service: "drone", commit: e.DRONE_COMMIT_SHA, tag: e.DRONE_TAG, build: e.DRONE_BUILD_NUMBER, buildUrl: e.DRONE_BUILD_LINK, branch: t ? e.DRONE_TARGET_BRANCH : e.DRONE_BRANCH, job: e.DRONE_JOB_NUMBER, jobUrl: e.DRONE_BUILD_LINK, pr: e.DRONE_PULL_REQUEST, isPr: t, prBranch: t ? e.DRONE_SOURCE_BRANCH : void 0, slug: `${e.DRONE_REPO_OWNER}/${e.DRONE_REPO_NAME}`, root: e.DRONE_WORKSPACE };
|
|
8995
|
-
} },
|
|
8996
|
-
return { commit: At(e), branch:
|
|
9140
|
+
} }, Js = { configuration(e) {
|
|
9141
|
+
return { commit: At(e), branch: fr(e) };
|
|
8997
9142
|
} };
|
|
8998
|
-
const
|
|
9143
|
+
const Qs = s(({ env: e }) => {
|
|
8999
9144
|
try {
|
|
9000
9145
|
const t = e.GITHUB_EVENT_PATH ? JSON.parse(readFileSync(e.GITHUB_EVENT_PATH, "utf-8")) : void 0;
|
|
9001
9146
|
if (t && t.pull_request) return { branch: t.pull_request.base ? ot(t.pull_request.base.ref) : void 0, pr: t.pull_request.number };
|
|
9002
9147
|
} catch {
|
|
9003
9148
|
}
|
|
9004
9149
|
return { pr: void 0, branch: void 0 };
|
|
9005
|
-
}, "getPrEvent"),
|
|
9150
|
+
}, "getPrEvent"), Xs = s((e) => {
|
|
9006
9151
|
const t = e.GITHUB_EVENT_PATH ? JSON.parse(readFileSync(e.GITHUB_EVENT_PATH, "utf-8")) : void 0;
|
|
9007
9152
|
return t && t.pull_request ? t.pull_request.number : void 0;
|
|
9008
9153
|
}, "getPrNumber");
|
|
9009
|
-
var
|
|
9154
|
+
var Zs = { detect({ env: e }) {
|
|
9010
9155
|
return !!e.GITHUB_ACTIONS;
|
|
9011
9156
|
}, configuration({ env: e, cwd: t }) {
|
|
9012
|
-
const r = e.GITHUB_EVENT_NAME === "pull_request" || e.GITHUB_EVENT_NAME === "pull_request_target", n = ot(e.GITHUB_EVENT_NAME === "pull_request_target" ? `refs/pull/${
|
|
9013
|
-
return { name: "GitHub Actions", service: "github", commit: e.GITHUB_SHA, build: e.GITHUB_RUN_ID, buildUrl: `${e.GITHUB_SERVER_URL}/${e.GITHUB_REPOSITORY}/actions/runs/${e.GITHUB_RUN_ID}`, isPr: r, branch: n, prBranch: r ? n : void 0, slug: e.GITHUB_REPOSITORY, root: e.GITHUB_WORKSPACE, ...r ?
|
|
9014
|
-
} },
|
|
9157
|
+
const r = e.GITHUB_EVENT_NAME === "pull_request" || e.GITHUB_EVENT_NAME === "pull_request_target", n = ot(e.GITHUB_EVENT_NAME === "pull_request_target" ? `refs/pull/${Xs(e)}/merge` : e.GITHUB_REF);
|
|
9158
|
+
return { name: "GitHub Actions", service: "github", commit: e.GITHUB_SHA, build: e.GITHUB_RUN_ID, buildUrl: `${e.GITHUB_SERVER_URL}/${e.GITHUB_REPOSITORY}/actions/runs/${e.GITHUB_RUN_ID}`, isPr: r, branch: n, prBranch: r ? n : void 0, slug: e.GITHUB_REPOSITORY, root: e.GITHUB_WORKSPACE, ...r ? Qs({ env: e }) : void 0 };
|
|
9159
|
+
} }, ea = { detect({ env: e }) {
|
|
9015
9160
|
return !!e.GITLAB_CI;
|
|
9016
9161
|
}, configuration({ env: e }) {
|
|
9017
9162
|
const t = e.CI_MERGE_REQUEST_ID, r = !!t;
|
|
9018
9163
|
return { name: "GitLab CI/CD", service: "gitlab", commit: e.CI_COMMIT_SHA, tag: e.CI_COMMIT_TAG, build: e.CI_PIPELINE_ID, buildUrl: `${e.CI_PROJECT_URL}/pipelines/${e.CI_PIPELINE_ID}`, job: e.CI_JOB_ID, jobUrl: `${e.CI_PROJECT_URL}/-/jobs/${e.CI_JOB_ID}`, branch: r ? e.CI_MERGE_REQUEST_TARGET_BRANCH_NAME : e.CI_COMMIT_REF_NAME, pr: t, isPr: r, prBranch: e.CI_MERGE_REQUEST_SOURCE_BRANCH_NAME, slug: e.CI_PROJECT_PATH, root: e.CI_PROJECT_DIR };
|
|
9019
|
-
} },
|
|
9164
|
+
} }, ta = { detect({ env: e }) {
|
|
9020
9165
|
return !!e.JENKINS_URL;
|
|
9021
9166
|
}, configuration({ env: e, cwd: t }) {
|
|
9022
|
-
const r = e.ghprbPullId || e.gitlabMergeRequestId || e.CHANGE_ID, n = !!r,
|
|
9023
|
-
return { name: "Jenkins", service: "jenkins", commit: e.ghprbActualCommit || e.GIT_COMMIT || At({ env: e, cwd: t }), branch: n ? e.ghprbTargetBranch || e.gitlabTargetBranch :
|
|
9024
|
-
} },
|
|
9167
|
+
const r = e.ghprbPullId || e.gitlabMergeRequestId || e.CHANGE_ID, n = !!r, i = e.GIT_LOCAL_BRANCH || e.GIT_BRANCH || e.gitlabBranch || e.BRANCH_NAME;
|
|
9168
|
+
return { name: "Jenkins", service: "jenkins", commit: e.ghprbActualCommit || e.GIT_COMMIT || At({ env: e, cwd: t }), branch: n ? e.ghprbTargetBranch || e.gitlabTargetBranch : i, build: e.BUILD_NUMBER, buildUrl: e.BUILD_URL, root: e.WORKSPACE, pr: r, isPr: n, prBranch: n ? e.ghprbSourceBranch || e.gitlabSourceBranch || i : void 0 };
|
|
9169
|
+
} }, ra = { detect({ env: e }) {
|
|
9025
9170
|
return e.NETLIFY === "true";
|
|
9026
9171
|
}, configuration({ env: e }) {
|
|
9027
9172
|
const t = e.PULL_REQUEST === "true";
|
|
9028
9173
|
return { name: "Netlify", service: "netlify", commit: e.COMMIT_REF, build: e.DEPLOY_ID, buildUrl: `https://app.netlify.com/sites/${e.SITE_NAME}/deploys/${e.DEPLOY_ID}`, branch: t ? void 0 : e.HEAD, pr: e.REVIEW_ID, isPr: t, prBranch: t ? e.HEAD : void 0, slug: e.REPOSITORY_URL.match(/[^/:]+\/[^/]+?$/)[0], root: e.PWD };
|
|
9029
|
-
} },
|
|
9174
|
+
} }, na = { detect({ env: e }) {
|
|
9030
9175
|
return !!e.DISTELLI_APPNAME;
|
|
9031
9176
|
}, configuration({ env: e }) {
|
|
9032
9177
|
return { name: "Puppet", service: "puppet", build: e.DISTELLI_BUILDNUM, buildUrl: e.DISTELLI_RELEASE, commit: e.DISTELLI_RELREVISION, branch: e.DISTELLI_RELBRANCH, root: e.DISTELLI_INSTALLHOME };
|
|
9033
|
-
} },
|
|
9178
|
+
} }, ia = { detect({ env: e }) {
|
|
9034
9179
|
return !!e.SAILCI;
|
|
9035
9180
|
}, configuration({ env: e }) {
|
|
9036
9181
|
const t = e.SAIL_PULL_REQUEST_NUMBER, r = !!t;
|
|
9037
9182
|
return { name: "Sail CI", service: "sail", commit: e.SAIL_COMMIT_SHA, branch: r ? void 0 : e.SAIL_COMMIT_BRANCH, pr: t, isPr: r, slug: `${e.SAIL_REPO_OWNER}/${e.SAIL_REPO_NAME}`, root: e.SAIL_CLONE_DIR };
|
|
9038
|
-
} },
|
|
9183
|
+
} }, oa = { detect({ env: e }) {
|
|
9039
9184
|
return !!e.SCREWDRIVER;
|
|
9040
9185
|
}, configuration({ env: e }) {
|
|
9041
9186
|
const t = e.SD_PULL_REQUEST, r = !!t;
|
|
9042
9187
|
return { name: "Screwdriver.cd", service: "screwdriver", branch: r ? e.PR_BASE_BRANCH_NAME : e.GIT_BRANCH, prBranch: r ? e.PR_BRANCH_NAME : void 0, commit: e.SD_BUILD_SHA, build: e.SD_BUILD_ID, buildUrl: e.SD_UI_BUILD_URL, job: e.SD_JOB_ID, pr: t, isPr: r, slug: e.SD_PIPELINE_NAME, root: e.SD_ROOT_DIR };
|
|
9043
|
-
} },
|
|
9188
|
+
} }, sa = { detect({ env: e }) {
|
|
9044
9189
|
return !!e.SCRUTINIZER;
|
|
9045
9190
|
}, configuration({ env: e }) {
|
|
9046
9191
|
const t = e.SCRUTINIZER_PR_NUMBER, r = !!t;
|
|
9047
9192
|
return { name: "Scrutinizer", service: "scrutinizer", commit: e.SCRUTINIZER_SHA1, build: e.SCRUTINIZER_INSPECTION_UUID, branch: e.SCRUTINIZER_BRANCH, pr: t, isPr: r, prBranch: e.SCRUTINIZER_PR_SOURCE_BRANCH };
|
|
9048
|
-
} },
|
|
9193
|
+
} }, aa = { detect({ env: e }) {
|
|
9049
9194
|
return !!e.SEMAPHORE;
|
|
9050
9195
|
}, configuration({ env: e, cwd: t }) {
|
|
9051
9196
|
const r = e.SEMAPHORE_GIT_PR_NUMBER || e.PULL_REQUEST_NUMBER, n = !!r;
|
|
9052
9197
|
return { name: "Semaphore", service: "semaphore", commit: e.SEMAPHORE_GIT_SHA || At({ env: e, cwd: t }), tag: e.SEMAPHORE_GIT_TAG_NAME, build: e.SEMAPHORE_JOB_ID || e.SEMAPHORE_BUILD_NUMBER, branch: e.SEMAPHORE_GIT_BRANCH || (n ? void 0 : e.BRANCH_NAME), pr: r, isPr: n, prBranch: e.SEMAPHORE_GIT_PR_BRANCH || (n ? e.BRANCH_NAME : void 0), slug: e.SEMAPHORE_GIT_REPO_SLUG || e.SEMAPHORE_REPO_SLUG, root: e.SEMAPHORE_GIT_DIR || e.SEMAPHORE_PROJECT_DIR };
|
|
9053
|
-
} },
|
|
9198
|
+
} }, ca = { detect({ env: e }) {
|
|
9054
9199
|
return !!e.SHIPPABLE;
|
|
9055
9200
|
}, configuration({ env: e }) {
|
|
9056
9201
|
const t = e.IS_PULL_REQUEST === "true" ? e.PULL_REQUEST : void 0, r = !!t;
|
|
9057
9202
|
return { name: "Shippable", service: "shippable", commit: e.COMMIT, tag: e.GIT_TAG_NAME, build: e.BUILD_NUMBER, buildUrl: e.BUILD_URL, branch: r ? e.BASE_BRANCH : e.BRANCH, job: e.JOB_NUMBER, pr: t, isPr: r, prBranch: r ? e.HEAD_BRANCH : void 0, slug: e.SHIPPABLE_REPO_SLUG, root: e.SHIPPABLE_BUILD_DIR };
|
|
9058
|
-
} }, He = {},
|
|
9059
|
-
function
|
|
9060
|
-
if (
|
|
9061
|
-
|
|
9203
|
+
} }, He = {}, Hn;
|
|
9204
|
+
function ua() {
|
|
9205
|
+
if (Hn) return He;
|
|
9206
|
+
Hn = 1, Object.defineProperty(He, "__esModule", { value: true }), He.of = He.PropertiesFile = void 0;
|
|
9062
9207
|
var e = t(ze);
|
|
9063
|
-
function t(
|
|
9064
|
-
return
|
|
9208
|
+
function t(i) {
|
|
9209
|
+
return i && i.__esModule ? i : { default: i };
|
|
9065
9210
|
}
|
|
9066
9211
|
s(t, "_interopRequireDefault");
|
|
9067
9212
|
class r {
|
|
9068
9213
|
static {
|
|
9069
9214
|
s(this, "PropertiesFile");
|
|
9070
9215
|
}
|
|
9071
|
-
constructor(...
|
|
9072
|
-
this.objs = {},
|
|
9216
|
+
constructor(...o) {
|
|
9217
|
+
this.objs = {}, o.length && this.of.apply(this, o);
|
|
9073
9218
|
}
|
|
9074
|
-
makeKeys(
|
|
9075
|
-
if (
|
|
9076
|
-
let c = ["=", ":"].map((m) =>
|
|
9077
|
-
if (this.objs.hasOwnProperty(h)) if (Array.isArray(this.objs[h])) this.objs[h].push(
|
|
9219
|
+
makeKeys(o) {
|
|
9220
|
+
if (o && o.indexOf("#") !== 0) {
|
|
9221
|
+
let c = ["=", ":"].map((m) => o.indexOf(m)).filter((m) => m > -1), l = Math.min(...c), h = o.substring(0, l).trim(), g = o.substring(l + 1).trim();
|
|
9222
|
+
if (this.objs.hasOwnProperty(h)) if (Array.isArray(this.objs[h])) this.objs[h].push(g);
|
|
9078
9223
|
else {
|
|
9079
9224
|
let m = this.objs[h];
|
|
9080
|
-
this.objs[h] = [m,
|
|
9225
|
+
this.objs[h] = [m, g];
|
|
9081
9226
|
}
|
|
9082
9227
|
else {
|
|
9083
|
-
const m =
|
|
9228
|
+
const m = g.replace(/"/g, '\\"').replace(/\\:/g, ":").replace(/\\=/g, "=");
|
|
9084
9229
|
this.objs[h] = unescape(JSON.parse('"' + m + '"'));
|
|
9085
9230
|
}
|
|
9086
9231
|
}
|
|
9087
9232
|
}
|
|
9088
|
-
addFile(
|
|
9089
|
-
let l = e.default.readFileSync(
|
|
9090
|
-
for (let
|
|
9091
|
-
let m = l[
|
|
9233
|
+
addFile(o) {
|
|
9234
|
+
let l = e.default.readFileSync(o, "utf-8").split(/\r?\n/), h = this;
|
|
9235
|
+
for (let g = 0; g < l.length; g++) {
|
|
9236
|
+
let m = l[g];
|
|
9092
9237
|
for (; m.substring(m.length - 1) === "\\"; ) {
|
|
9093
9238
|
m = m.slice(0, -1);
|
|
9094
|
-
let A = l[
|
|
9095
|
-
m = m + A.trim(),
|
|
9239
|
+
let A = l[g + 1];
|
|
9240
|
+
m = m + A.trim(), g++;
|
|
9096
9241
|
}
|
|
9097
9242
|
h.makeKeys(m);
|
|
9098
9243
|
}
|
|
9099
9244
|
}
|
|
9100
|
-
of(...
|
|
9101
|
-
for (let c = 0; c <
|
|
9245
|
+
of(...o) {
|
|
9246
|
+
for (let c = 0; c < o.length; c++) this.addFile(o[c]);
|
|
9102
9247
|
}
|
|
9103
|
-
get(
|
|
9104
|
-
if (this.objs.hasOwnProperty(
|
|
9248
|
+
get(o, c) {
|
|
9249
|
+
if (this.objs.hasOwnProperty(o)) if (Array.isArray(this.objs[o])) {
|
|
9105
9250
|
let l = [];
|
|
9106
|
-
for (let h = 0; h < this.objs[
|
|
9251
|
+
for (let h = 0; h < this.objs[o].length; h++) l[h] = this.interpolate(this.objs[o][h]);
|
|
9107
9252
|
return l;
|
|
9108
|
-
} else return typeof this.objs[
|
|
9253
|
+
} else return typeof this.objs[o] > "u" ? "" : this.interpolate(this.objs[o]);
|
|
9109
9254
|
return c;
|
|
9110
9255
|
}
|
|
9111
|
-
getLast(
|
|
9112
|
-
if (this.objs.hasOwnProperty(
|
|
9113
|
-
var l = this.objs[
|
|
9114
|
-
return this.interpolate(this.objs[
|
|
9115
|
-
} else return typeof this.objs[
|
|
9256
|
+
getLast(o, c) {
|
|
9257
|
+
if (this.objs.hasOwnProperty(o)) if (Array.isArray(this.objs[o])) {
|
|
9258
|
+
var l = this.objs[o].length;
|
|
9259
|
+
return this.interpolate(this.objs[o][l - 1]);
|
|
9260
|
+
} else return typeof this.objs[o] > "u" ? "" : this.interpolate(this.objs[o]);
|
|
9116
9261
|
return c;
|
|
9117
9262
|
}
|
|
9118
|
-
getFirst(
|
|
9119
|
-
return this.objs.hasOwnProperty(
|
|
9263
|
+
getFirst(o, c) {
|
|
9264
|
+
return this.objs.hasOwnProperty(o) ? Array.isArray(this.objs[o]) ? this.interpolate(this.objs[o][0]) : typeof this.objs[o] > "u" ? "" : this.interpolate(this.objs[o]) : c;
|
|
9120
9265
|
}
|
|
9121
|
-
getInt(
|
|
9122
|
-
let l = this.getLast(
|
|
9266
|
+
getInt(o, c) {
|
|
9267
|
+
let l = this.getLast(o);
|
|
9123
9268
|
return l ? parseInt(l, 10) : c;
|
|
9124
9269
|
}
|
|
9125
|
-
getFloat(
|
|
9126
|
-
let l = this.getLast(
|
|
9270
|
+
getFloat(o, c) {
|
|
9271
|
+
let l = this.getLast(o);
|
|
9127
9272
|
return l ? parseFloat(l) : c;
|
|
9128
9273
|
}
|
|
9129
|
-
getBoolean(
|
|
9130
|
-
function l(
|
|
9131
|
-
return !/^(false|0)$/i.test(
|
|
9274
|
+
getBoolean(o, c) {
|
|
9275
|
+
function l(g) {
|
|
9276
|
+
return !/^(false|0)$/i.test(g) && !!g;
|
|
9132
9277
|
}
|
|
9133
9278
|
s(l, "parseBool");
|
|
9134
|
-
let h = this.getLast(
|
|
9279
|
+
let h = this.getLast(o);
|
|
9135
9280
|
return h ? l(h) : c || false;
|
|
9136
9281
|
}
|
|
9137
|
-
set(
|
|
9138
|
-
this.objs[
|
|
9282
|
+
set(o, c) {
|
|
9283
|
+
this.objs[o] = c;
|
|
9139
9284
|
}
|
|
9140
|
-
interpolate(
|
|
9285
|
+
interpolate(o) {
|
|
9141
9286
|
let c = this;
|
|
9142
|
-
return
|
|
9287
|
+
return o.replace(/\\\\/g, "\\").replace(/\$\{([A-Za-z0-9\.\-\_]*)\}/g, function(l) {
|
|
9143
9288
|
return c.getLast(l.substring(2, l.length - 1));
|
|
9144
9289
|
});
|
|
9145
9290
|
}
|
|
9146
9291
|
getKeys() {
|
|
9147
|
-
let
|
|
9148
|
-
for (let c in this.objs)
|
|
9149
|
-
return
|
|
9292
|
+
let o = [];
|
|
9293
|
+
for (let c in this.objs) o.push(c);
|
|
9294
|
+
return o;
|
|
9150
9295
|
}
|
|
9151
|
-
getMatchingKeys(
|
|
9296
|
+
getMatchingKeys(o) {
|
|
9152
9297
|
let c = [];
|
|
9153
|
-
for (let l in this.objs) l.search(
|
|
9298
|
+
for (let l in this.objs) l.search(o) !== -1 && c.push(l);
|
|
9154
9299
|
return c;
|
|
9155
9300
|
}
|
|
9156
9301
|
reset() {
|
|
@@ -9158,69 +9303,70 @@ function ra() {
|
|
|
9158
9303
|
}
|
|
9159
9304
|
}
|
|
9160
9305
|
He.PropertiesFile = r;
|
|
9161
|
-
let n = s(function(...
|
|
9306
|
+
let n = s(function(...o) {
|
|
9162
9307
|
let c = new r();
|
|
9163
|
-
return c.of.apply(c,
|
|
9308
|
+
return c.of.apply(c, o), c;
|
|
9164
9309
|
}, "of2");
|
|
9165
9310
|
return He.of = n, He;
|
|
9166
9311
|
}
|
|
9167
|
-
s(
|
|
9168
|
-
var
|
|
9169
|
-
const
|
|
9312
|
+
s(ua, "requireDistNode");
|
|
9313
|
+
var la = ua(), fa = kr(la);
|
|
9314
|
+
const hr = { root: "teamcity.build.workingDir", branch: "teamcity.build.branch" }, Fn = s((e) => {
|
|
9170
9315
|
try {
|
|
9171
|
-
return
|
|
9316
|
+
return fa.of(e);
|
|
9172
9317
|
} catch {
|
|
9173
9318
|
return;
|
|
9174
9319
|
}
|
|
9175
|
-
}, "safeReadProperties"),
|
|
9176
|
-
const r = e.TEAMCITY_BUILD_PROPERTIES_FILE ?
|
|
9177
|
-
return Object.fromEntries(Object.keys(
|
|
9320
|
+
}, "safeReadProperties"), ha = s(({ env: e, cwd: t }) => {
|
|
9321
|
+
const r = e.TEAMCITY_BUILD_PROPERTIES_FILE ? Fn(e.TEAMCITY_BUILD_PROPERTIES_FILE) : void 0, n = r ? r.get("teamcity.configuration.properties.file") : void 0, i = n && Fn(n);
|
|
9322
|
+
return Object.fromEntries(Object.keys(hr).map((o) => [o, (r ? r.get(hr[o]) : void 0) || (i ? i.get(hr[o]) : void 0) || (o === "branch" ? fr({ env: e, cwd: t }) : void 0)]));
|
|
9178
9323
|
}, "getProperties");
|
|
9179
|
-
var
|
|
9324
|
+
var da = { detect({ env: e }) {
|
|
9180
9325
|
return !!e.TEAMCITY_VERSION;
|
|
9181
9326
|
}, configuration({ env: e, cwd: t }) {
|
|
9182
|
-
return { name: "TeamCity", service: "teamcity", commit: e.BUILD_VCS_NUMBER, build: e.BUILD_NUMBER, slug: e.TEAMCITY_BUILDCONF_NAME, ...
|
|
9183
|
-
} },
|
|
9327
|
+
return { name: "TeamCity", service: "teamcity", commit: e.BUILD_VCS_NUMBER, build: e.BUILD_NUMBER, slug: e.TEAMCITY_BUILDCONF_NAME, ...ha({ env: e, cwd: t }) };
|
|
9328
|
+
} }, pa = { detect({ env: e }) {
|
|
9184
9329
|
return !!e.TRAVIS;
|
|
9185
9330
|
}, configuration({ env: e }) {
|
|
9186
9331
|
const t = e.TRAVIS_PULL_REQUEST === "false" ? void 0 : e.TRAVIS_PULL_REQUEST, r = !!t;
|
|
9187
9332
|
return { name: "Travis CI", service: "travis", commit: e.TRAVIS_COMMIT, tag: e.TRAVIS_TAG, build: e.TRAVIS_BUILD_NUMBER, buildUrl: e.TRAVIS_BUILD_WEB_URL, branch: e.TRAVIS_BRANCH, job: e.TRAVIS_JOB_NUMBER, jobUrl: e.TRAVIS_JOB_WEB_URL, pr: t, isPr: r, prBranch: e.TRAVIS_PULL_REQUEST_BRANCH, slug: e.TRAVIS_REPO_SLUG, root: e.TRAVIS_BUILD_DIR };
|
|
9188
|
-
} },
|
|
9333
|
+
} }, ma = { detect({ env: e }) {
|
|
9189
9334
|
return !!e.VELA;
|
|
9190
9335
|
}, configuration({ env: e }) {
|
|
9191
9336
|
const t = e.VELA_BUILD_EVENT === "pull_request";
|
|
9192
9337
|
return { name: "Vela", service: "vela", branch: t ? e.VELA_PULL_REQUEST_TARGET : e.VELA_BUILD_BRANCH, commit: e.VELA_BUILD_COMMIT, tag: e.VELA_BUILD_TAG, build: e.VELA_BUILD_NUMBER, buildUrl: e.VELA_BUILD_LINK, job: void 0, jobUrl: void 0, isPr: t, pr: e.VELA_BUILD_PULL_REQUEST, prBranch: e.VELA_PULL_REQUEST_SOURCE, slug: e.VELA_REPO_FULL_NAME, root: e.VELA_BUILD_WORKSPACE };
|
|
9193
|
-
} },
|
|
9338
|
+
} }, Ea = { detect({ env: e }) {
|
|
9194
9339
|
return !!e.VERCEL || !!e.NOW_GITHUB_DEPLOYMENT;
|
|
9195
9340
|
}, configuration({ env: e }) {
|
|
9196
9341
|
const t = "Vercel", r = "vercel";
|
|
9197
9342
|
return e.VERCEL ? { name: t, service: r, commit: e.VERCEL_GIT_COMMIT_SHA, branch: e.VERCEL_GIT_COMMIT_REF, slug: `${e.VERCEL_GIT_REPO_OWNER}/${e.VERCEL_GIT_REPO_SLUG}` } : { name: t, service: r, commit: e.NOW_GITHUB_COMMIT_SHA, branch: e.NOW_GITHUB_COMMIT_REF, slug: `${e.NOW_GITHUB_ORG}/${e.NOW_GITHUB_REPO}` };
|
|
9198
|
-
} },
|
|
9343
|
+
} }, _a = { detect({ env: e }) {
|
|
9199
9344
|
return !!e.WERCKER_MAIN_PIPELINE_STARTED;
|
|
9200
9345
|
}, configuration({ env: e }) {
|
|
9201
9346
|
return { name: "Wercker", service: "wercker", commit: e.WERCKER_GIT_COMMIT, build: e.WERCKER_MAIN_PIPELINE_STARTED, buildUrl: e.WERCKER_RUN_URL, branch: e.WERCKER_GIT_BRANCH, slug: `${e.WERCKER_GIT_OWNER}/${e.WERCKER_GIT_REPOSITORY}`, root: e.WERCKER_ROOT };
|
|
9202
|
-
} },
|
|
9347
|
+
} }, ga = { detect({ env: e }) {
|
|
9203
9348
|
return e.CI && e.CI === "woodpecker";
|
|
9204
9349
|
}, configuration({ env: e }) {
|
|
9205
9350
|
const t = e.CI_PIPELINE_EVENT === "pull_request";
|
|
9206
9351
|
return { name: "Woodpecker CI", service: "woodpecker", commit: e.CI_COMMIT_SHA, tag: e.CI_COMMIT_TAG, build: e.CI_PIPELINE_NUMBER, buildUrl: e.CI_PIPELINE_URL, branch: t ? e.CI_COMMIT_TARGET_BRANCH : e.CI_COMMIT_BRANCH, job: e.CI_STEP_NUMBER, jobUrl: e.CI_STEP_URL, pr: e.CI_COMMIT_PULL_REQUEST, isPr: t, prBranch: t ? e.CI_COMMIT_SOURCE_BRANCH : void 0, slug: `${e.CI_REPO_OWNER}/${e.CI_REPO_NAME}`, root: e.CI_WORKSPACE };
|
|
9207
|
-
} },
|
|
9352
|
+
} }, Ia = { detect({ env: e }) {
|
|
9208
9353
|
return !!e.JB_SPACE_EXECUTION_NUMBER;
|
|
9209
9354
|
}, configuration({ env: e }) {
|
|
9210
9355
|
const t = e.JB_SPACE_PROJECT_KEY, r = e.JB_SPACE_GIT_REPOSITORY_NAME;
|
|
9211
9356
|
return { name: "JetBrains Space", service: "jetbrainsSpace", commit: e.JB_SPACE_GIT_REVISION, build: e.JB_SPACE_EXECUTION_NUMBER, branch: ot(e.JB_SPACE_GIT_BRANCH), slug: t && r ? `${t.toLowerCase()}/${r}` : void 0 };
|
|
9212
9357
|
} };
|
|
9213
|
-
const
|
|
9214
|
-
var
|
|
9215
|
-
for (const r of Object.keys(
|
|
9216
|
-
return { isCi: !!e.CI, ...
|
|
9217
|
-
}, "
|
|
9218
|
-
function
|
|
9219
|
-
|
|
9220
|
-
|
|
9221
|
-
}
|
|
9222
|
-
|
|
9223
|
-
|
|
9358
|
+
const dr = { appveyor: No, azurePipelines: Do, bamboo: Mo, bitbucket: xo, bitrise: Go, buddy: $o, buildkite: Fs, circleci: js, cirrus: qs, cloudflarePages: Ws, codebuild: Ks, codefresh: Vs, codeship: Ys, drone: zs, github: Zs, gitlab: ea, jenkins: ta, netlify: ra, puppet: na, sail: ia, screwdriver: oa, scrutinizer: sa, semaphore: aa, shippable: ca, teamcity: da, travis: pa, vela: ma, vercel: Ea, wercker: _a, woodpecker: ga, jetbrainsSpace: Ia };
|
|
9359
|
+
var pr = s(({ env: e = process.env, cwd: t = process.cwd() } = {}) => {
|
|
9360
|
+
for (const r of Object.keys(dr)) if (dr[r].detect({ env: e, cwd: t })) return { isCi: true, ...dr[r].configuration({ env: e, cwd: t }) };
|
|
9361
|
+
return { isCi: !!e.CI, ...Js.configuration({ env: e, cwd: t }) };
|
|
9362
|
+
}, "envCiModule");
|
|
9363
|
+
const Sa = typeof pr == "function" ? pr : pr.default;
|
|
9364
|
+
function Ra() {
|
|
9365
|
+
const e = Sa();
|
|
9366
|
+
return { branch: e.branch, commit: { message: ya(), sha: e.commit }, isCI: e.isCi, pr: Ta() };
|
|
9367
|
+
}
|
|
9368
|
+
s(Ra, "getGitInfo");
|
|
9369
|
+
function Ta() {
|
|
9224
9370
|
try {
|
|
9225
9371
|
const e = process.env.GITHUB_EVENT_PATH;
|
|
9226
9372
|
if (e) {
|
|
@@ -9232,30 +9378,30 @@ function ma() {
|
|
|
9232
9378
|
return;
|
|
9233
9379
|
}
|
|
9234
9380
|
}
|
|
9235
|
-
s(
|
|
9236
|
-
function
|
|
9381
|
+
s(Ta, "getPRInfo");
|
|
9382
|
+
function ya() {
|
|
9237
9383
|
try {
|
|
9238
9384
|
return execSync("git log -1 --pretty=%B", { encoding: "utf-8", stdio: ["pipe", "pipe", "ignore"] }).trim();
|
|
9239
9385
|
} catch {
|
|
9240
9386
|
return;
|
|
9241
9387
|
}
|
|
9242
9388
|
}
|
|
9243
|
-
s(
|
|
9244
|
-
function
|
|
9245
|
-
return { hostname:
|
|
9389
|
+
s(ya, "getLastCommitMessage");
|
|
9390
|
+
function wa() {
|
|
9391
|
+
return { hostname: wr.hostname(), platform: wr.platform() };
|
|
9246
9392
|
}
|
|
9247
|
-
s(
|
|
9248
|
-
const
|
|
9249
|
-
var
|
|
9250
|
-
function o
|
|
9251
|
-
return
|
|
9252
|
-
c(
|
|
9393
|
+
s(wa, "getMachineInfo");
|
|
9394
|
+
const Aa = new Error("request for lock canceled");
|
|
9395
|
+
var va = s(function(e, t, r, n) {
|
|
9396
|
+
function i(o) {
|
|
9397
|
+
return o instanceof r ? o : new r(function(c) {
|
|
9398
|
+
c(o);
|
|
9253
9399
|
});
|
|
9254
9400
|
}
|
|
9255
|
-
return s(
|
|
9401
|
+
return s(i, "adopt"), new (r || (r = Promise))(function(o, c) {
|
|
9256
9402
|
function l(m) {
|
|
9257
9403
|
try {
|
|
9258
|
-
|
|
9404
|
+
g(n.next(m));
|
|
9259
9405
|
} catch (A) {
|
|
9260
9406
|
c(A);
|
|
9261
9407
|
}
|
|
@@ -9263,37 +9409,37 @@ var Ia = s(function(e, t, r, n) {
|
|
|
9263
9409
|
s(l, "fulfilled");
|
|
9264
9410
|
function h(m) {
|
|
9265
9411
|
try {
|
|
9266
|
-
|
|
9412
|
+
g(n.throw(m));
|
|
9267
9413
|
} catch (A) {
|
|
9268
9414
|
c(A);
|
|
9269
9415
|
}
|
|
9270
9416
|
}
|
|
9271
9417
|
s(h, "rejected");
|
|
9272
|
-
function
|
|
9273
|
-
m.done ?
|
|
9418
|
+
function g(m) {
|
|
9419
|
+
m.done ? o(m.value) : i(m.value).then(l, h);
|
|
9274
9420
|
}
|
|
9275
|
-
s(
|
|
9421
|
+
s(g, "step"), g((n = n.apply(e, t || [])).next());
|
|
9276
9422
|
});
|
|
9277
9423
|
}, "__awaiter$2");
|
|
9278
|
-
class
|
|
9424
|
+
class ba {
|
|
9279
9425
|
static {
|
|
9280
9426
|
s(this, "Semaphore");
|
|
9281
9427
|
}
|
|
9282
|
-
constructor(t, r =
|
|
9428
|
+
constructor(t, r = Aa) {
|
|
9283
9429
|
this._value = t, this._cancelError = r, this._queue = [], this._weightedWaiters = [];
|
|
9284
9430
|
}
|
|
9285
9431
|
acquire(t = 1, r = 0) {
|
|
9286
9432
|
if (t <= 0) throw new Error(`invalid weight ${t}: must be positive`);
|
|
9287
|
-
return new Promise((n,
|
|
9288
|
-
const
|
|
9289
|
-
c === -1 && t <= this._value ? this._dispatchItem(
|
|
9433
|
+
return new Promise((n, i) => {
|
|
9434
|
+
const o = { resolve: n, reject: i, weight: t, priority: r }, c = jn(this._queue, (l) => r <= l.priority);
|
|
9435
|
+
c === -1 && t <= this._value ? this._dispatchItem(o) : this._queue.splice(c + 1, 0, o);
|
|
9290
9436
|
});
|
|
9291
9437
|
}
|
|
9292
9438
|
runExclusive(t) {
|
|
9293
|
-
return
|
|
9294
|
-
const [
|
|
9439
|
+
return va(this, arguments, void 0, function* (r, n = 1, i = 0) {
|
|
9440
|
+
const [o, c] = yield this.acquire(n, i);
|
|
9295
9441
|
try {
|
|
9296
|
-
return yield r(
|
|
9442
|
+
return yield r(o);
|
|
9297
9443
|
} finally {
|
|
9298
9444
|
c();
|
|
9299
9445
|
}
|
|
@@ -9302,7 +9448,7 @@ class Sa {
|
|
|
9302
9448
|
waitForUnlock(t = 1, r = 0) {
|
|
9303
9449
|
if (t <= 0) throw new Error(`invalid weight ${t}: must be positive`);
|
|
9304
9450
|
return this._couldLockImmediately(t, r) ? Promise.resolve() : new Promise((n) => {
|
|
9305
|
-
this._weightedWaiters[t - 1] || (this._weightedWaiters[t - 1] = []),
|
|
9451
|
+
this._weightedWaiters[t - 1] || (this._weightedWaiters[t - 1] = []), Ca(this._weightedWaiters[t - 1], { resolve: n, priority: r });
|
|
9306
9452
|
});
|
|
9307
9453
|
}
|
|
9308
9454
|
isLocked() {
|
|
@@ -9344,8 +9490,8 @@ class Sa {
|
|
|
9344
9490
|
for (let r = this._value; r > 0; r--) {
|
|
9345
9491
|
const n = this._weightedWaiters[r - 1];
|
|
9346
9492
|
if (!n) continue;
|
|
9347
|
-
const
|
|
9348
|
-
(
|
|
9493
|
+
const i = n.findIndex((o) => o.priority <= t);
|
|
9494
|
+
(i === -1 ? n : n.splice(0, i)).forEach(((o) => o.resolve()));
|
|
9349
9495
|
}
|
|
9350
9496
|
}
|
|
9351
9497
|
}
|
|
@@ -9353,26 +9499,26 @@ class Sa {
|
|
|
9353
9499
|
return (this._queue.length === 0 || this._queue[0].priority < r) && t <= this._value;
|
|
9354
9500
|
}
|
|
9355
9501
|
}
|
|
9356
|
-
function
|
|
9357
|
-
const r =
|
|
9502
|
+
function Ca(e, t) {
|
|
9503
|
+
const r = jn(e, (n) => t.priority <= n.priority);
|
|
9358
9504
|
e.splice(r + 1, 0, t);
|
|
9359
9505
|
}
|
|
9360
|
-
s(
|
|
9361
|
-
function
|
|
9506
|
+
s(Ca, "insertSorted");
|
|
9507
|
+
function jn(e, t) {
|
|
9362
9508
|
for (let r = e.length - 1; r >= 0; r--) if (t(e[r])) return r;
|
|
9363
9509
|
return -1;
|
|
9364
9510
|
}
|
|
9365
|
-
s(
|
|
9366
|
-
var
|
|
9367
|
-
function o
|
|
9368
|
-
return
|
|
9369
|
-
c(
|
|
9511
|
+
s(jn, "findIndexFromEnd");
|
|
9512
|
+
var Ua = s(function(e, t, r, n) {
|
|
9513
|
+
function i(o) {
|
|
9514
|
+
return o instanceof r ? o : new r(function(c) {
|
|
9515
|
+
c(o);
|
|
9370
9516
|
});
|
|
9371
9517
|
}
|
|
9372
|
-
return s(
|
|
9518
|
+
return s(i, "adopt"), new (r || (r = Promise))(function(o, c) {
|
|
9373
9519
|
function l(m) {
|
|
9374
9520
|
try {
|
|
9375
|
-
|
|
9521
|
+
g(n.next(m));
|
|
9376
9522
|
} catch (A) {
|
|
9377
9523
|
c(A);
|
|
9378
9524
|
}
|
|
@@ -9380,27 +9526,27 @@ var Ta = s(function(e, t, r, n) {
|
|
|
9380
9526
|
s(l, "fulfilled");
|
|
9381
9527
|
function h(m) {
|
|
9382
9528
|
try {
|
|
9383
|
-
|
|
9529
|
+
g(n.throw(m));
|
|
9384
9530
|
} catch (A) {
|
|
9385
9531
|
c(A);
|
|
9386
9532
|
}
|
|
9387
9533
|
}
|
|
9388
9534
|
s(h, "rejected");
|
|
9389
|
-
function
|
|
9390
|
-
m.done ?
|
|
9535
|
+
function g(m) {
|
|
9536
|
+
m.done ? o(m.value) : i(m.value).then(l, h);
|
|
9391
9537
|
}
|
|
9392
|
-
s(
|
|
9538
|
+
s(g, "step"), g((n = n.apply(e, t || [])).next());
|
|
9393
9539
|
});
|
|
9394
9540
|
}, "__awaiter$1");
|
|
9395
|
-
class
|
|
9541
|
+
class Ba {
|
|
9396
9542
|
static {
|
|
9397
9543
|
s(this, "Mutex");
|
|
9398
9544
|
}
|
|
9399
9545
|
constructor(t) {
|
|
9400
|
-
this._semaphore = new
|
|
9546
|
+
this._semaphore = new ba(1, t);
|
|
9401
9547
|
}
|
|
9402
9548
|
acquire() {
|
|
9403
|
-
return
|
|
9549
|
+
return Ua(this, arguments, void 0, function* (t = 0) {
|
|
9404
9550
|
const [, r] = yield this._semaphore.acquire(1, t);
|
|
9405
9551
|
return r;
|
|
9406
9552
|
});
|
|
@@ -9421,47 +9567,47 @@ class wa {
|
|
|
9421
9567
|
return this._semaphore.cancel();
|
|
9422
9568
|
}
|
|
9423
9569
|
}
|
|
9424
|
-
function
|
|
9570
|
+
function qn(e, t) {
|
|
9425
9571
|
const r = e.length;
|
|
9426
|
-
let n = 0,
|
|
9427
|
-
const
|
|
9428
|
-
return t({ completed: n, errors:
|
|
9429
|
-
n++, t({ completed: n, errors:
|
|
9572
|
+
let n = 0, i = 0;
|
|
9573
|
+
const o = new Ba();
|
|
9574
|
+
return t({ completed: n, errors: i, total: r }), e.map((c) => c.then(async (l) => (await o.runExclusive(() => {
|
|
9575
|
+
n++, t({ completed: n, errors: i, total: r });
|
|
9430
9576
|
}), l)).catch(async (l) => {
|
|
9431
|
-
throw await
|
|
9432
|
-
n++,
|
|
9577
|
+
throw await o.runExclusive(() => {
|
|
9578
|
+
n++, i++, t({ completed: n, errors: i, total: r });
|
|
9433
9579
|
}), l;
|
|
9434
9580
|
}));
|
|
9435
9581
|
}
|
|
9436
|
-
s(
|
|
9437
|
-
function
|
|
9438
|
-
return e.steps.map((r) =>
|
|
9582
|
+
s(qn, "trackPromiseProgress");
|
|
9583
|
+
function Oa({ result: e, sensitiveValues: t }) {
|
|
9584
|
+
return e.steps.map((r) => Wn({ sensitiveValues: t, step: r }));
|
|
9439
9585
|
}
|
|
9440
|
-
s(
|
|
9441
|
-
function
|
|
9442
|
-
const r = s((n) => n && e?.length ?
|
|
9443
|
-
return { category: t.category, duration: t.duration, error: t.error ? { message: r(t.error.message) || "Unknown error", stack: r(t.error.stack) } : void 0, location: t.location ? { column: t.location.column, file: t.location.file, line: t.location.line } : void 0, startedAt: new Date(t.startTime), steps: t.steps && t.steps.length > 0 ? t.steps.map((n) =>
|
|
9586
|
+
s(Oa, "extractSteps");
|
|
9587
|
+
function Wn({ sensitiveValues: e, step: t }) {
|
|
9588
|
+
const r = s((n) => n && e?.length ? se({ sensitiveValues: e, str: n }) : n, "scrub");
|
|
9589
|
+
return { category: t.category, duration: t.duration, error: t.error ? { message: r(t.error.message) || "Unknown error", stack: r(t.error.stack) } : void 0, location: t.location ? { column: t.location.column, file: t.location.file, line: t.location.line } : void 0, startedAt: new Date(t.startTime), steps: t.steps && t.steps.length > 0 ? t.steps.map((n) => Wn({ sensitiveValues: e, step: n })) : void 0, title: r(t.title) ?? t.title };
|
|
9444
9590
|
}
|
|
9445
|
-
s(
|
|
9446
|
-
async function
|
|
9447
|
-
await
|
|
9591
|
+
s(Wn, "extractStep");
|
|
9592
|
+
async function La({ fileData: e, maxRetries: t = 3, uploadUrl: r }) {
|
|
9593
|
+
await ai(async () => {
|
|
9448
9594
|
const n = await fetch(r, { body: e, method: "PUT" });
|
|
9449
|
-
if (!n.ok) throw n.status >= 400 && n.status < 500 ? new AbortError(`Upload failed with status ${n.status}: ${n.statusText}`) : new Error(`Upload failed with status ${n.status}: ${n.statusText}`);
|
|
9595
|
+
if (!n.ok) throw n.status >= 400 && n.status < 500 ? new pRetryExports.AbortError(`Upload failed with status ${n.status}: ${n.statusText}`) : new Error(`Upload failed with status ${n.status}: ${n.statusText}`);
|
|
9450
9596
|
}, { minTimeout: 2e3, randomize: true, retries: t });
|
|
9451
9597
|
}
|
|
9452
|
-
s(
|
|
9453
|
-
const
|
|
9598
|
+
s(La, "uploadWithRetry");
|
|
9599
|
+
const Pa = process.env.STABLY_WS_URL || "wss://api.stably.ai/reporter", Kn = 120 * 1e3, Na = s(({ notificationConfigs: e, suite: t }) => {
|
|
9454
9600
|
if (!e || e.length === 0) return;
|
|
9455
|
-
const r = new Set(t.allTests().map((
|
|
9601
|
+
const r = new Set(t.allTests().map((i) => i.parent.project()?.name).filter(Boolean)), n = e.filter((i) => r.has(i.projectName));
|
|
9456
9602
|
return n.length > 0 ? n : void 0;
|
|
9457
|
-
}, "filterNotificationConfigsByRunningProjects"),
|
|
9603
|
+
}, "filterNotificationConfigsByRunningProjects"), Da = s((e) => e ? { configFile: e.configFile, forbidOnly: e.forbidOnly, fullyParallel: e.fullyParallel, globalSetup: e.globalSetup, globalTeardown: e.globalTeardown, globalTimeout: e.globalTimeout, grep: e.grep?.toString(), grepInvert: e.grepInvert?.toString(), maxFailures: e.maxFailures, metadata: e.metadata, preserveOutput: e.preserveOutput, quiet: e.quiet, reporter: e.reporter, reportSlowTests: e.reportSlowTests, rootDir: e.rootDir, shard: e.shard, updateSnapshots: e.updateSnapshots, version: e.version, webServer: e.webServer, workers: e.workers } : void 0, "extractConfigInfo"), Ma = s(({ absolutePath: e, rootDir: t }) => {
|
|
9458
9604
|
if (t && e.startsWith(t)) {
|
|
9459
9605
|
const r = e.slice(t.length);
|
|
9460
9606
|
return r.startsWith("/") ? r.slice(1) : r;
|
|
9461
9607
|
}
|
|
9462
9608
|
return e;
|
|
9463
9609
|
}, "makePathRelative");
|
|
9464
|
-
class
|
|
9610
|
+
class Vn {
|
|
9465
9611
|
static {
|
|
9466
9612
|
s(this, "StablyReporter");
|
|
9467
9613
|
}
|
|
@@ -9486,16 +9632,16 @@ class jn {
|
|
|
9486
9632
|
if (!r) throw new Error("STABLY_API_KEY is required. Provide it via options or environment variable.");
|
|
9487
9633
|
if (!n) throw new Error("STABLY_PROJECT_ID is required. Provide it via options or environment variable.");
|
|
9488
9634
|
if (this.notificationConfigs = t?.notificationConfigs, t?.sensitiveValues?.length) {
|
|
9489
|
-
const
|
|
9490
|
-
this.sensitiveValues = [...
|
|
9635
|
+
const i = ln(t.sensitiveValues);
|
|
9636
|
+
this.sensitiveValues = [...i].sort((o, c) => c.length - o.length);
|
|
9491
9637
|
}
|
|
9492
|
-
this.wsClient = new
|
|
9638
|
+
this.wsClient = new Po({ apiKey: r, maxBufferSize: 1e3, maxReconnectAttempts: 3, onError: s((i) => this.handleWebSocketError(i), "onError"), onMessage: s((i) => this.handleWebSocketMessage(i), "onMessage"), projectId: n, reconnectDelay: 2e3, url: Pa });
|
|
9493
9639
|
}
|
|
9494
9640
|
onBegin(t, r) {
|
|
9495
9641
|
if (this.isListMode = process.argv.includes("--list"), this.isListMode) return;
|
|
9496
9642
|
r.allTests().length === 0 && process.exit(1), this.config = t, this.testSuiteRunId = this.getSuiteRunId(t), this.rootDir = t.rootDir, this.suiteData = this.extractSuiteInfo(t, r);
|
|
9497
|
-
const
|
|
9498
|
-
this.filteredNotificationConfigs =
|
|
9643
|
+
const i = Na({ notificationConfigs: this.notificationConfigs, suite: r });
|
|
9644
|
+
this.filteredNotificationConfigs = i, this.pendingOperations.push(this.wsClient.sendEvent({ payload: { ...this.suiteData, notificationRequest: i ? { notificationConfigs: i, totalShards: this.config?.shard?.total } : void 0, status: "running" }, type: "suite_start" }));
|
|
9499
9645
|
}
|
|
9500
9646
|
getSuiteRunId(t) {
|
|
9501
9647
|
return getCiRunKey() ?? t.metadata?.testSuiteRunId ?? ut();
|
|
@@ -9509,16 +9655,16 @@ class jn {
|
|
|
9509
9655
|
if (this.isListMode) return;
|
|
9510
9656
|
const n = this.extractTestCaseInfo(t, r);
|
|
9511
9657
|
this.testCases.push(n), this.testStepsMap.set(n.id, r);
|
|
9512
|
-
const
|
|
9513
|
-
const l = await this.extractAttachmentMetadata({ attachments:
|
|
9514
|
-
let h,
|
|
9515
|
-
l.length > 0 && (h = `${n.id}-${n.attemptNumber}`,
|
|
9658
|
+
const i = Oa({ result: r, sensitiveValues: this.sensitiveValues }), o = [...r.attachments, { contentType: "text/plain", name: "source-code", path: t.location.file }], c = (async () => {
|
|
9659
|
+
const l = await this.extractAttachmentMetadata({ attachments: o, attemptNumber: n.attemptNumber, testId: n.id });
|
|
9660
|
+
let h, g;
|
|
9661
|
+
l.length > 0 && (h = `${n.id}-${n.attemptNumber}`, g = new Promise((m) => {
|
|
9516
9662
|
this.pendingUploadUrlRequests.set(h, m);
|
|
9517
|
-
}), this.pendingOperations.push(
|
|
9663
|
+
}), this.pendingOperations.push(g));
|
|
9518
9664
|
try {
|
|
9519
|
-
await this.wsClient.sendEvent({ payload: { ...n, attachments: l, steps:
|
|
9665
|
+
await this.wsClient.sendEvent({ payload: { ...n, attachments: l, steps: i }, type: "test_end" });
|
|
9520
9666
|
} catch (m) {
|
|
9521
|
-
if (h &&
|
|
9667
|
+
if (h && g) {
|
|
9522
9668
|
const A = this.pendingUploadUrlRequests.get(h);
|
|
9523
9669
|
A && (A(), this.pendingUploadUrlRequests.delete(h));
|
|
9524
9670
|
}
|
|
@@ -9532,24 +9678,24 @@ class jn {
|
|
|
9532
9678
|
this.pendingOperations.push(this.wsClient.sendEvent({ payload: { duration: t.duration, notificationRequest: this.filteredNotificationConfigs ? { notificationConfigs: this.filteredNotificationConfigs, totalShards: this.config?.shard?.total } : void 0, status: t.status === "timedout" ? "timedOut" : t.status, suiteId: this.testSuiteRunId }, type: "suite_end" })), Ie$1("[Stably reporter] Waiting for pending tasks to finish...");
|
|
9533
9679
|
const r = Y$1();
|
|
9534
9680
|
r.start("Waiting for tasks to finish...");
|
|
9535
|
-
const n = Promise.allSettled(
|
|
9536
|
-
r.message(`${h}/${m} tasks finished${
|
|
9537
|
-
})),
|
|
9681
|
+
const n = Promise.allSettled(qn(this.pendingOperations, ({ completed: h, errors: g, total: m }) => {
|
|
9682
|
+
r.message(`${h}/${m} tasks finished${g > 0 ? `, ${g} errors` : ""}`);
|
|
9683
|
+
})), i = new Promise((h, g) => {
|
|
9538
9684
|
setTimeout(() => {
|
|
9539
|
-
|
|
9540
|
-
},
|
|
9685
|
+
g(new Error(`Tasks timeout: Some operations did not complete within ${Kn / 1e3}s`));
|
|
9686
|
+
}, Kn);
|
|
9541
9687
|
});
|
|
9542
9688
|
try {
|
|
9543
|
-
await Promise.race([n,
|
|
9689
|
+
await Promise.race([n, i]);
|
|
9544
9690
|
} catch (h) {
|
|
9545
|
-
const
|
|
9546
|
-
console.warn(`[StablyAI reporter] Tasks timeout reached. Some operations may still be pending: ${
|
|
9691
|
+
const g = h instanceof Error ? h.message : String(h);
|
|
9692
|
+
console.warn(`[StablyAI reporter] Tasks timeout reached. Some operations may still be pending: ${g}`);
|
|
9547
9693
|
}
|
|
9548
9694
|
this.wsClient.flushBuffer(), r.stop("All tasks finished");
|
|
9549
|
-
const
|
|
9550
|
-
|
|
9551
|
-
|
|
9552
|
-
})),
|
|
9695
|
+
const o = Y$1();
|
|
9696
|
+
o.start("Waiting for file uploads to finish..."), await Promise.allSettled(qn(this.pendingUploads, ({ completed: h, errors: g, total: m }) => {
|
|
9697
|
+
o.message(`${h}/${m} uploads finished${g > 0 ? `, ${g} errors` : ""}`);
|
|
9698
|
+
})), o.stop("All file uploads finished"), this.wsClient.close();
|
|
9553
9699
|
const c = this.createdSuiteRun?.name || this.suiteData?.title || "Test Suite", l = t.status === "failed" || t.status === "timedout";
|
|
9554
9700
|
Se$1(Ce.cyan(`\u2728 Suite "${Ce.bold(c)}" run complete!${this.createdSuiteRun ? `
|
|
9555
9701
|
\u{1F4CA} View results: ${Ce.bold(Ce.underline(this.createdSuiteRun.url))}` : ""}${l ? `
|
|
@@ -9558,34 +9704,51 @@ class jn {
|
|
|
9558
9704
|
${Ce.bold(Ce.underline(`stably fix ${this.testSuiteRunId}`))}` : ""}`));
|
|
9559
9705
|
}
|
|
9560
9706
|
scrubSensitiveString(t) {
|
|
9561
|
-
return !t || !this.sensitiveValues?.length ? t :
|
|
9707
|
+
return !t || !this.sensitiveValues?.length ? t : se({ sensitiveValues: this.sensitiveValues, str: t });
|
|
9562
9708
|
}
|
|
9563
9709
|
extractSuiteInfo(t, r) {
|
|
9564
|
-
const n =
|
|
9565
|
-
return { id: ut(), projectSettings:
|
|
9710
|
+
const n = Ra(), i = wa(), o = /* @__PURE__ */ new Date();
|
|
9711
|
+
return { id: ut(), projectSettings: Da(t), startedAt: o, suiteId: this.testSuiteRunId, title: r.title || "Playwright Test Suite", createdAt: o, git: { branch: n.branch, commit: { message: n.commit.message, sha: n.commit.sha }, pr: n.pr }, isCI: n.isCI, shards: t.shard?.total ?? 1, workers: t.workers, machineInfo: i, updatedAt: o };
|
|
9566
9712
|
}
|
|
9567
9713
|
extractTestCaseInfo(t, r) {
|
|
9568
|
-
const n =
|
|
9569
|
-
return { fullTitle: this.scrubSensitiveString(t.titlePath().join(" \u203A ")) ?? "", id: ut(), location: `${n}:${t.location.line}:${t.location.column}`, suiteId: this.testSuiteRunId, testIdentifier: t.id, title: this.scrubSensitiveString(t.title) ?? t.title, browserName: c, duration: r.duration, expectedStatus: t.expectedStatus, finishedAt: r.startTime && r.duration ? new Date(r.startTime.getTime() + r.duration) : void 0, outcome: t.outcome(), projectName:
|
|
9714
|
+
const n = Ma({ absolutePath: t.location.file, rootDir: this.rootDir }), i = t.parent.project(), o = i?.name, c = i?.use?.defaultBrowserType;
|
|
9715
|
+
return { fullTitle: this.scrubSensitiveString(t.titlePath().join(" \u203A ")) ?? "", id: ut(), location: `${n}:${t.location.line}:${t.location.column}`, suiteId: this.testSuiteRunId, testIdentifier: t.id, title: this.scrubSensitiveString(t.title) ?? t.title, browserName: c, duration: r.duration, expectedStatus: t.expectedStatus, finishedAt: r.startTime && r.duration ? new Date(r.startTime.getTime() + r.duration) : void 0, outcome: t.outcome(), projectName: o, startedAt: new Date(r.startTime), status: r.status, attemptNumber: r.retry + 1, maxRetries: t.retries, retryCount: r.retry, errorMessage: this.scrubSensitiveString(r.error?.message), errorStack: this.scrubSensitiveString(r.error?.stack), errorType: r.error?.value, annotations: t.annotations.length > 0 ? t.annotations : void 0, tags: t.tags.length > 0 ? t.tags : void 0 };
|
|
9570
9716
|
}
|
|
9571
9717
|
async extractAttachmentMetadata({ attachments: t, attemptNumber: r, testId: n }) {
|
|
9572
|
-
|
|
9573
|
-
|
|
9574
|
-
|
|
9575
|
-
|
|
9576
|
-
|
|
9577
|
-
|
|
9578
|
-
|
|
9579
|
-
|
|
9580
|
-
|
|
9581
|
-
|
|
9582
|
-
|
|
9583
|
-
|
|
9584
|
-
|
|
9585
|
-
|
|
9718
|
+
return (await Promise.all(t.map((o) => this.processAttachment({ attachment: o, attemptNumber: r, testId: n })))).filter((o) => o !== void 0);
|
|
9719
|
+
}
|
|
9720
|
+
async processAttachment({ attachment: t, attemptNumber: r, testId: n }) {
|
|
9721
|
+
let i;
|
|
9722
|
+
try {
|
|
9723
|
+
i = t.name === "trace" && t.path && this.sensitiveValues && this.sensitiveValues.length > 0 ? openSync(t.path, "r") : void 0;
|
|
9724
|
+
const o = await this.getAttachmentFileData({ attachment: t, traceFd: i });
|
|
9725
|
+
if (!o) return;
|
|
9726
|
+
const c = ut(), l = `${n}-${r}-${c}`;
|
|
9727
|
+
return this.attachmentFiles.set(l, o), { artifactId: c, attemptNumber: r, contentType: t.contentType, name: t.name, sizeBytes: o.length, testId: n };
|
|
9728
|
+
} catch (o) {
|
|
9729
|
+
const c = o instanceof Error ? o.message : String(o);
|
|
9730
|
+
console.error(`[StablyAI reporter] Failed to read attachment ${t.name}: ${c}`);
|
|
9731
|
+
return;
|
|
9732
|
+
} finally {
|
|
9733
|
+
if (i !== void 0) try {
|
|
9734
|
+
closeSync(i);
|
|
9735
|
+
} catch {
|
|
9736
|
+
}
|
|
9737
|
+
}
|
|
9738
|
+
}
|
|
9739
|
+
async getAttachmentFileData({ attachment: t, traceFd: r }) {
|
|
9740
|
+
if (!t.path && !t.body) return;
|
|
9741
|
+
if (t.name === "trace" && this.sensitiveValues && this.sensitiveValues.length > 0) {
|
|
9742
|
+
const i = t.path ? await this.scrubTraceFromFile({ attachmentPath: t.path, sensitiveValues: this.sensitiveValues, traceFd: r }) : t.body ? await zt({ sensitiveValues: this.sensitiveValues, traceBuffer: Buffer.from(t.body) }) : void 0;
|
|
9743
|
+
return i ? Buffer.from(i) : void 0;
|
|
9744
|
+
}
|
|
9745
|
+
return t.body ? Buffer.from(t.body) : t.path ? readFileSync$1(t.path) : void 0;
|
|
9746
|
+
}
|
|
9747
|
+
async scrubTraceFromFile({ attachmentPath: t, sensitiveValues: r, traceFd: n }) {
|
|
9748
|
+
return n !== void 0 ? Lo({ sensitiveValues: r, traceFd: n, tracePath: t }) : Oo({ sensitiveValues: r, tracePath: t });
|
|
9586
9749
|
}
|
|
9587
9750
|
handleWebSocketError(t) {
|
|
9588
|
-
t.code ===
|
|
9751
|
+
t.code === mn.AUTHENTICATION_FAILED && (console.error(Ce.bold(Ce.red("[StablyAI reporter] Could not authenticate with the server. Either the API Key or Project ID is invalid. These can be provided via stablyReporter({ apiKey, projectId }) in playwright.config.ts or environment variables (STABLY_API_KEY, STABLY_PROJECT_ID). You can find your API key and Project ID at https://app.stably.ai/settings?tab=api-key"))), process.exit(1)), console.error("[StablyAI reporter] Could not connect to the server. Please check your internet connection and try again."), process.exit(1);
|
|
9589
9752
|
}
|
|
9590
9753
|
handleWebSocketMessage(t) {
|
|
9591
9754
|
if (t.type === "suite_created") this.createdSuiteRun = { id: t.id, name: t.name, url: t.url };
|
|
@@ -9593,27 +9756,27 @@ class jn {
|
|
|
9593
9756
|
const r = `${t.testId}-${t.attemptNumber}`, n = this.pendingUploadUrlRequests.get(r);
|
|
9594
9757
|
if (!n) return;
|
|
9595
9758
|
n(), this.pendingUploadUrlRequests.delete(r);
|
|
9596
|
-
const
|
|
9597
|
-
this.pendingUploads.push(
|
|
9759
|
+
const i = this.uploadAttachments(t.testId, t.attemptNumber, t.uploadUrls);
|
|
9760
|
+
this.pendingUploads.push(i);
|
|
9598
9761
|
}
|
|
9599
9762
|
}
|
|
9600
9763
|
async uploadAttachments(t, r, n) {
|
|
9601
|
-
const
|
|
9602
|
-
const h = `${t}-${r}-${
|
|
9603
|
-
if (
|
|
9604
|
-
await
|
|
9764
|
+
const i = n.map(async ({ artifactId: o, name: c, uploadUrl: l }) => {
|
|
9765
|
+
const h = `${t}-${r}-${o}`, g = this.attachmentFiles.get(h);
|
|
9766
|
+
if (g) try {
|
|
9767
|
+
await La({ fileData: g, maxRetries: 3, uploadUrl: l }), this.attachmentFiles.delete(h);
|
|
9605
9768
|
} catch (m) {
|
|
9606
9769
|
const A = m instanceof Error ? m.message : String(m);
|
|
9607
9770
|
console.error(`[StablyAI reporter] Failed to upload ${c} after retries: ${A}`);
|
|
9608
9771
|
}
|
|
9609
9772
|
});
|
|
9610
|
-
await Promise.allSettled(
|
|
9773
|
+
await Promise.allSettled(i);
|
|
9611
9774
|
}
|
|
9612
9775
|
}
|
|
9613
|
-
function
|
|
9776
|
+
function xa(e) {
|
|
9614
9777
|
return ["@stablyai/playwright-test/reporter", e];
|
|
9615
9778
|
}
|
|
9616
|
-
s(
|
|
9779
|
+
s(xa, "stablyReporter");
|
|
9617
9780
|
|
|
9618
|
-
export {
|
|
9619
|
-
//# sourceMappingURL=index-
|
|
9781
|
+
export { Vn as V, xa as x };
|
|
9782
|
+
//# sourceMappingURL=index-Tn_eFdjz.mjs.map
|