@xyo-network/xl1-cli 4.0.5 → 4.1.0
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/cli-min.mjs +1288 -687
- package/dist/cli-min.mjs.map +1 -1
- package/package.json +20 -31
package/dist/cli-min.mjs
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import "node:url";
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import { ROOT_CONTEXT, SpanStatusCode, context, metrics, propagation, trace } from "@opentelemetry/api";
|
|
4
|
-
import { AlwaysOnSampler, BasicTracerProvider, BatchSpanProcessor, ConsoleSpanExporter } from "@opentelemetry/sdk-trace-base";
|
|
5
4
|
import http from "http";
|
|
6
5
|
import https from "https";
|
|
7
6
|
import { gunzipSync } from "zlib";
|
|
@@ -17,6 +16,7 @@ import os$1 from "os";
|
|
|
17
16
|
import { channel, tracingChannel } from "node:diagnostics_channel";
|
|
18
17
|
import fs, { readFileSync, readdirSync, statSync, writeFile } from "fs";
|
|
19
18
|
import path$1, { basename, dirname, extname, join, normalize, relative, resolve } from "path";
|
|
19
|
+
import { AlwaysOnSampler, BasicTracerProvider, BatchSpanProcessor, ConsoleSpanExporter } from "@opentelemetry/sdk-trace-base";
|
|
20
20
|
import tty from "node:tty";
|
|
21
21
|
import { AsyncLocalStorageContextManager } from "@opentelemetry/context-async-hooks";
|
|
22
22
|
import { CompositePropagator, W3CBaggagePropagator, W3CTraceContextPropagator } from "@opentelemetry/core";
|
|
@@ -11956,7 +11956,7 @@ var Mutex = class {
|
|
|
11956
11956
|
}
|
|
11957
11957
|
};
|
|
11958
11958
|
//#endregion
|
|
11959
|
-
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.
|
|
11959
|
+
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3/node_modules/@ariestools/sdk/dist/node/index.mjs
|
|
11960
11960
|
var __defProp$31 = Object.defineProperty;
|
|
11961
11961
|
var __getOwnPropDesc$30 = Object.getOwnPropertyDescriptor;
|
|
11962
11962
|
var __decorateClass$30 = (decorators, target, key, kind) => {
|
|
@@ -12480,23 +12480,6 @@ var isEthAddress = (value, config = {}) => {
|
|
|
12480
12480
|
});
|
|
12481
12481
|
};
|
|
12482
12482
|
var EthAddressZod = (/* @__PURE__ */ string$3()).check(/* @__PURE__ */ _regex(EthAddressRegEx, { error: "Invalid address format" }), /* @__PURE__ */ refine$2(isEthAddress));
|
|
12483
|
-
function asEthAddress(value, assert) {
|
|
12484
|
-
try {
|
|
12485
|
-
let stringValue;
|
|
12486
|
-
switch (typeof value) {
|
|
12487
|
-
case "string":
|
|
12488
|
-
stringValue = hexFromHexString(value, {
|
|
12489
|
-
prefix: true,
|
|
12490
|
-
byteSize: 4
|
|
12491
|
-
});
|
|
12492
|
-
break;
|
|
12493
|
-
default: if (value !== void 0) return assertError(value, assert, `Unsupported type [${typeof value}]`);
|
|
12494
|
-
}
|
|
12495
|
-
return isEthAddress(stringValue) ? stringValue : assertError(value, assert, `Value is not an EthAddress [${value}]`);
|
|
12496
|
-
} catch (ex) {
|
|
12497
|
-
return assertError(void 0, assert, ex.message);
|
|
12498
|
-
}
|
|
12499
|
-
}
|
|
12500
12483
|
var isHash = (value, bitLength = 256) => {
|
|
12501
12484
|
return isHex(value, { bitLength });
|
|
12502
12485
|
};
|
|
@@ -13379,7 +13362,7 @@ function getFunctionName(depth = 2) {
|
|
|
13379
13362
|
let newIndex;
|
|
13380
13363
|
const stackParts = error.stack?.split("\n")[depth]?.split(" ");
|
|
13381
13364
|
const funcName = stackParts?.find((item, index) => {
|
|
13382
|
-
if (
|
|
13365
|
+
if (item.length === 0 || item === "at") return;
|
|
13383
13366
|
if (item === "new") newIndex = index;
|
|
13384
13367
|
return true;
|
|
13385
13368
|
}) ?? "<unknown>";
|
|
@@ -14031,7 +14014,7 @@ var logColors = {
|
|
|
14031
14014
|
function spanDurationInMillis$1(span2) {
|
|
14032
14015
|
return span2.duration[0] * 1e3 + span2.duration[1] / 1e6;
|
|
14033
14016
|
}
|
|
14034
|
-
(class
|
|
14017
|
+
(class _XyConsoleSpanExporterImplementation {
|
|
14035
14018
|
/** Duration thresholds (in ms) that map to increasing log levels. */
|
|
14036
14019
|
static durationToLogLevel = [
|
|
14037
14020
|
0,
|
|
@@ -14051,7 +14034,6 @@ function spanDurationInMillis$1(span2) {
|
|
|
14051
14034
|
logger;
|
|
14052
14035
|
_logLevel;
|
|
14053
14036
|
constructor(logLevel = 0, logger = console) {
|
|
14054
|
-
super();
|
|
14055
14037
|
this._logLevel = logLevel;
|
|
14056
14038
|
this.logger = logger;
|
|
14057
14039
|
}
|
|
@@ -14059,7 +14041,7 @@ function spanDurationInMillis$1(span2) {
|
|
|
14059
14041
|
get logLevel() {
|
|
14060
14042
|
return this._logLevel;
|
|
14061
14043
|
}
|
|
14062
|
-
export(spans) {
|
|
14044
|
+
export(spans, resultCallback) {
|
|
14063
14045
|
for (const span2 of spans) {
|
|
14064
14046
|
const spanLevel = this.spanLevel(span2);
|
|
14065
14047
|
if (spanLevel < this.logLevel) continue;
|
|
@@ -14070,6 +14052,10 @@ function spanDurationInMillis$1(span2) {
|
|
|
14070
14052
|
`TraceId: ${span2.spanContext().traceId}`
|
|
14071
14053
|
].join(", ")));
|
|
14072
14054
|
}
|
|
14055
|
+
resultCallback?.({ code: 0 });
|
|
14056
|
+
}
|
|
14057
|
+
forceFlush() {
|
|
14058
|
+
return Promise.resolve();
|
|
14073
14059
|
}
|
|
14074
14060
|
/**
|
|
14075
14061
|
* Returns the chalk color function for the given log level.
|
|
@@ -14077,7 +14063,10 @@ function spanDurationInMillis$1(span2) {
|
|
|
14077
14063
|
* @returns A chalk color function.
|
|
14078
14064
|
*/
|
|
14079
14065
|
logColor(level) {
|
|
14080
|
-
return
|
|
14066
|
+
return _XyConsoleSpanExporterImplementation.logLevelToChalkColor[level] ?? logColors.magenta;
|
|
14067
|
+
}
|
|
14068
|
+
shutdown() {
|
|
14069
|
+
return Promise.resolve();
|
|
14081
14070
|
}
|
|
14082
14071
|
/**
|
|
14083
14072
|
* Determines the log level of a span based on its duration.
|
|
@@ -14087,7 +14076,7 @@ function spanDurationInMillis$1(span2) {
|
|
|
14087
14076
|
spanLevel(span2) {
|
|
14088
14077
|
let logLevel = 0;
|
|
14089
14078
|
const duration = spanDurationInMillis$1(span2);
|
|
14090
|
-
for (let x =
|
|
14079
|
+
for (let x = _XyConsoleSpanExporterImplementation.durationToLogLevel.length - 1; x >= 0; x--) if (duration > _XyConsoleSpanExporterImplementation.durationToLogLevel[x]) {
|
|
14091
14080
|
logLevel = x;
|
|
14092
14081
|
break;
|
|
14093
14082
|
}
|
|
@@ -14536,7 +14525,7 @@ const bech32m = /* @__PURE__ */ Object.freeze(genBech32("bech32m"));
|
|
|
14536
14525
|
return s.toLowerCase();
|
|
14537
14526
|
}));
|
|
14538
14527
|
//#endregion
|
|
14539
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
14528
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/address.mjs
|
|
14540
14529
|
var XyoLegacyAddressZod = AddressZod;
|
|
14541
14530
|
zodToFactory(XyoLegacyAddressZod, "toXyoLegacyAddress");
|
|
14542
14531
|
function tryDecodeQuantAddress(address) {
|
|
@@ -14558,7 +14547,7 @@ var XyoAddressZod = /* @__PURE__ */ union$2([XyoLegacyAddressZod, XyoQuantAddres
|
|
|
14558
14547
|
var asXyoAddress = zodAsFactory(XyoAddressZod, "asXyoAddress");
|
|
14559
14548
|
var toXyoAddress = zodToFactory(XyoAddressZod, "toXyoAddress");
|
|
14560
14549
|
//#endregion
|
|
14561
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
14550
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/account-model.mjs
|
|
14562
14551
|
var isPhraseInitializationConfig = (value) => {
|
|
14563
14552
|
if (typeof value === "object" && value !== null) return typeof value.phrase === "string";
|
|
14564
14553
|
return false;
|
|
@@ -17543,7 +17532,7 @@ const [SHA3_PI, SHA3_ROTL, _SHA3_IOTA] = [
|
|
|
17543
17532
|
];
|
|
17544
17533
|
const _0n$4 = /* @__PURE__ */ BigInt(0);
|
|
17545
17534
|
const _1n$5 = /* @__PURE__ */ BigInt(1);
|
|
17546
|
-
const _2n$
|
|
17535
|
+
const _2n$3 = /* @__PURE__ */ BigInt(2);
|
|
17547
17536
|
const _7n = /* @__PURE__ */ BigInt(7);
|
|
17548
17537
|
const _256n = /* @__PURE__ */ BigInt(256);
|
|
17549
17538
|
const _0x71n = /* @__PURE__ */ BigInt(113);
|
|
@@ -17554,7 +17543,7 @@ for (let round = 0, R = _1n$5, x = 1, y = 0; round < 24; round++) {
|
|
|
17554
17543
|
let t = _0n$4;
|
|
17555
17544
|
for (let j = 0; j < 7; j++) {
|
|
17556
17545
|
R = (R << _1n$5 ^ (R >> _7n) * _0x71n) % _256n;
|
|
17557
|
-
if (R & _2n$
|
|
17546
|
+
if (R & _2n$3) t ^= _1n$5 << (_1n$5 << /* @__PURE__ */ BigInt(j)) - _1n$5;
|
|
17558
17547
|
}
|
|
17559
17548
|
_SHA3_IOTA.push(t);
|
|
17560
17549
|
}
|
|
@@ -18641,7 +18630,8 @@ async function scryptAsync(password, salt, opts) {
|
|
|
18641
18630
|
}
|
|
18642
18631
|
//#endregion
|
|
18643
18632
|
//#region ../../node_modules/.pnpm/ethers@6.17.0/node_modules/ethers/lib.esm/crypto/scrypt.js
|
|
18644
|
-
let lockedSync = false
|
|
18633
|
+
let lockedSync = false;
|
|
18634
|
+
let lockedAsync = false;
|
|
18645
18635
|
const _scryptAsync = async function(passwd, salt, N, r, p, dkLen, onProgress) {
|
|
18646
18636
|
return await scryptAsync(passwd, salt, {
|
|
18647
18637
|
N,
|
|
@@ -18758,7 +18748,8 @@ const _sha512 = function(data) {
|
|
|
18758
18748
|
};
|
|
18759
18749
|
let __sha256 = _sha256;
|
|
18760
18750
|
let __sha512 = _sha512;
|
|
18761
|
-
let locked256 = false
|
|
18751
|
+
let locked256 = false;
|
|
18752
|
+
let locked512 = false;
|
|
18762
18753
|
/**
|
|
18763
18754
|
* Compute the cryptographic SHA2-256 hash of %%data%%.
|
|
18764
18755
|
*
|
|
@@ -18844,7 +18835,7 @@ var utils_exports = /* @__PURE__ */ __exportAll({
|
|
|
18844
18835
|
/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */
|
|
18845
18836
|
const _0n$3 = BigInt(0);
|
|
18846
18837
|
const _1n$4 = BigInt(1);
|
|
18847
|
-
const _2n$
|
|
18838
|
+
const _2n$2 = BigInt(2);
|
|
18848
18839
|
const u8a = (a) => a instanceof Uint8Array;
|
|
18849
18840
|
const hexes = /* @__PURE__ */ Array.from({ length: 256 }, (_, i) => i.toString(16).padStart(2, "0"));
|
|
18850
18841
|
/**
|
|
@@ -18971,7 +18962,7 @@ const bitSet = (n, pos, value) => {
|
|
|
18971
18962
|
* Calculate mask for N bits. Not using ** operator with bigints because of old engines.
|
|
18972
18963
|
* Same as BigInt(`0b${Array(i).fill('1').join('')}`)
|
|
18973
18964
|
*/
|
|
18974
|
-
const bitMask = (n) => (_2n$
|
|
18965
|
+
const bitMask = (n) => (_2n$2 << BigInt(n - 1)) - _1n$4;
|
|
18975
18966
|
const u8n = (data) => new Uint8Array(data);
|
|
18976
18967
|
const u8fr = (arr) => Uint8Array.from(arr);
|
|
18977
18968
|
/**
|
|
@@ -19049,9 +19040,15 @@ function validateObject(object, validators, optValidators = {}) {
|
|
|
19049
19040
|
//#endregion
|
|
19050
19041
|
//#region ../../node_modules/.pnpm/@noble+curves@1.2.0/node_modules/@noble/curves/esm/abstract/modular.js
|
|
19051
19042
|
/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */
|
|
19052
|
-
const _0n$2 = BigInt(0)
|
|
19053
|
-
const
|
|
19054
|
-
const
|
|
19043
|
+
const _0n$2 = BigInt(0);
|
|
19044
|
+
const _1n$3 = BigInt(1);
|
|
19045
|
+
const _2n$1 = BigInt(2);
|
|
19046
|
+
const _3n$1 = BigInt(3);
|
|
19047
|
+
const _4n = BigInt(4);
|
|
19048
|
+
const _5n = BigInt(5);
|
|
19049
|
+
const _8n = BigInt(8);
|
|
19050
|
+
const _9n = BigInt(9);
|
|
19051
|
+
const _16n = BigInt(16);
|
|
19055
19052
|
function mod(a, b) {
|
|
19056
19053
|
const result = a % b;
|
|
19057
19054
|
return result >= _0n$2 ? result : b + result;
|
|
@@ -19105,19 +19102,19 @@ function invert(number, modulo) {
|
|
|
19105
19102
|
* @returns function that takes field Fp (created from P) and number n
|
|
19106
19103
|
*/
|
|
19107
19104
|
function tonelliShanks(P) {
|
|
19108
|
-
const legendreC = (P - _1n$3) / _2n$
|
|
19105
|
+
const legendreC = (P - _1n$3) / _2n$1;
|
|
19109
19106
|
let Q, S, Z;
|
|
19110
|
-
for (Q = P - _1n$3, S = 0; Q % _2n$
|
|
19111
|
-
for (Z = _2n$
|
|
19107
|
+
for (Q = P - _1n$3, S = 0; Q % _2n$1 === _0n$2; Q /= _2n$1, S++);
|
|
19108
|
+
for (Z = _2n$1; Z < P && pow(Z, legendreC, P) !== P - _1n$3; Z++);
|
|
19112
19109
|
if (S === 1) {
|
|
19113
|
-
const p1div4 = (P + _1n$3) / _4n
|
|
19110
|
+
const p1div4 = (P + _1n$3) / _4n;
|
|
19114
19111
|
return function tonelliFast(Fp, n) {
|
|
19115
19112
|
const root = Fp.pow(n, p1div4);
|
|
19116
19113
|
if (!Fp.eql(Fp.sqr(root), n)) throw new Error("Cannot find square root");
|
|
19117
19114
|
return root;
|
|
19118
19115
|
};
|
|
19119
19116
|
}
|
|
19120
|
-
const Q1div2 = (Q + _1n$3) / _2n$
|
|
19117
|
+
const Q1div2 = (Q + _1n$3) / _2n$1;
|
|
19121
19118
|
return function tonelliSlow(Fp, n) {
|
|
19122
19119
|
if (Fp.pow(n, legendreC) === Fp.neg(Fp.ONE)) throw new Error("Cannot find square root");
|
|
19123
19120
|
let r = S;
|
|
@@ -19141,8 +19138,8 @@ function tonelliShanks(P) {
|
|
|
19141
19138
|
};
|
|
19142
19139
|
}
|
|
19143
19140
|
function FpSqrt(P) {
|
|
19144
|
-
if (P % _4n
|
|
19145
|
-
const p1div4 = (P + _1n$3) / _4n
|
|
19141
|
+
if (P % _4n === _3n$1) {
|
|
19142
|
+
const p1div4 = (P + _1n$3) / _4n;
|
|
19146
19143
|
return function sqrt3mod4(Fp, n) {
|
|
19147
19144
|
const root = Fp.pow(n, p1div4);
|
|
19148
19145
|
if (!Fp.eql(Fp.sqr(root), n)) throw new Error("Cannot find square root");
|
|
@@ -19152,10 +19149,10 @@ function FpSqrt(P) {
|
|
|
19152
19149
|
if (P % _8n === _5n) {
|
|
19153
19150
|
const c1 = (P - _5n) / _8n;
|
|
19154
19151
|
return function sqrt5mod8(Fp, n) {
|
|
19155
|
-
const n2 = Fp.mul(n, _2n$
|
|
19152
|
+
const n2 = Fp.mul(n, _2n$1);
|
|
19156
19153
|
const v = Fp.pow(n2, c1);
|
|
19157
19154
|
const nv = Fp.mul(n, v);
|
|
19158
|
-
const i = Fp.mul(Fp.mul(nv, _2n$
|
|
19155
|
+
const i = Fp.mul(Fp.mul(nv, _2n$1), v);
|
|
19159
19156
|
const root = Fp.mul(nv, Fp.sub(i, Fp.ONE));
|
|
19160
19157
|
if (!Fp.eql(Fp.sqr(root), n)) throw new Error("Cannot find square root");
|
|
19161
19158
|
return root;
|
|
@@ -19524,7 +19521,10 @@ const DER = {
|
|
|
19524
19521
|
const rl = h(rhl);
|
|
19525
19522
|
return `30${h(rhl + shl + 4)}02${rl}${r}02${sl}${s}`;
|
|
19526
19523
|
}
|
|
19527
|
-
}
|
|
19524
|
+
};
|
|
19525
|
+
const _0n = BigInt(0);
|
|
19526
|
+
const _1n$1 = BigInt(1);
|
|
19527
|
+
const _3n = BigInt(3);
|
|
19528
19528
|
function weierstrassPoints(opts) {
|
|
19529
19529
|
const CURVE = validatePointOpts(opts);
|
|
19530
19530
|
const { Fp } = CURVE;
|
|
@@ -23570,7 +23570,10 @@ function unpack_cc(packed) {
|
|
|
23570
23570
|
function unpack_cp(packed) {
|
|
23571
23571
|
return packed & 16777215;
|
|
23572
23572
|
}
|
|
23573
|
-
let SHIFTED_RANK
|
|
23573
|
+
let SHIFTED_RANK;
|
|
23574
|
+
let EXCLUSIONS;
|
|
23575
|
+
let DECOMP;
|
|
23576
|
+
let RECOMP;
|
|
23574
23577
|
function init$1() {
|
|
23575
23578
|
let r = read_compressed_payload(COMPRESSED);
|
|
23576
23579
|
SHIFTED_RANK = new Map(read_sorted_arrays(r).flatMap((v, i) => v.map((x) => [x, i + 1 << 24])));
|
|
@@ -23709,7 +23712,17 @@ var Emoji = class extends Array {
|
|
|
23709
23712
|
return true;
|
|
23710
23713
|
}
|
|
23711
23714
|
};
|
|
23712
|
-
let MAPPED
|
|
23715
|
+
let MAPPED;
|
|
23716
|
+
let IGNORED;
|
|
23717
|
+
let CM;
|
|
23718
|
+
let NSM;
|
|
23719
|
+
let ESCAPE;
|
|
23720
|
+
let GROUPS;
|
|
23721
|
+
let WHOLE_VALID;
|
|
23722
|
+
let WHOLE_MAP;
|
|
23723
|
+
let VALID;
|
|
23724
|
+
let EMOJI_LIST;
|
|
23725
|
+
let EMOJI_ROOT;
|
|
23713
23726
|
function init() {
|
|
23714
23727
|
if (MAPPED) return;
|
|
23715
23728
|
let r = read_compressed_payload(COMPRESSED$1);
|
|
@@ -33117,7 +33130,9 @@ var __classPrivateFieldSet$6 = function(receiver, state, value, kind, f) {
|
|
|
33117
33130
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
33118
33131
|
return kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value), value;
|
|
33119
33132
|
};
|
|
33120
|
-
var _AES_key
|
|
33133
|
+
var _AES_key;
|
|
33134
|
+
var _AES_Kd;
|
|
33135
|
+
var _AES_Ke;
|
|
33121
33136
|
const numberOfRounds = {
|
|
33122
33137
|
16: 10,
|
|
33123
33138
|
24: 12,
|
|
@@ -36920,7 +36935,8 @@ var __classPrivateFieldGet$5 = function(receiver, state, kind, f) {
|
|
|
36920
36935
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
36921
36936
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
36922
36937
|
};
|
|
36923
|
-
var _CBC_iv
|
|
36938
|
+
var _CBC_iv;
|
|
36939
|
+
var _CBC_lastBlock;
|
|
36924
36940
|
var CBC = class CBC extends ModeOfOperation {
|
|
36925
36941
|
constructor(key, iv) {
|
|
36926
36942
|
super("ECC", key, CBC);
|
|
@@ -36972,7 +36988,9 @@ var __classPrivateFieldGet$4 = function(receiver, state, kind, f) {
|
|
|
36972
36988
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
36973
36989
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
36974
36990
|
};
|
|
36975
|
-
var _CTR_remaining
|
|
36991
|
+
var _CTR_remaining;
|
|
36992
|
+
var _CTR_remainingIndex;
|
|
36993
|
+
var _CTR_counter;
|
|
36976
36994
|
var CTR = class CTR extends ModeOfOperation {
|
|
36977
36995
|
constructor(key, initialValue) {
|
|
36978
36996
|
super("CTR", key, CTR);
|
|
@@ -37950,7 +37968,7 @@ var Wallet = class Wallet extends BaseWallet {
|
|
|
37950
37968
|
}
|
|
37951
37969
|
};
|
|
37952
37970
|
//#endregion
|
|
37953
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
37971
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/data.mjs
|
|
37954
37972
|
var AbstractData = class {
|
|
37955
37973
|
static is(value) {
|
|
37956
37974
|
return value instanceof this;
|
|
@@ -37990,7 +38008,7 @@ var Data = class _Data extends AbstractData {
|
|
|
37990
38008
|
}
|
|
37991
38009
|
};
|
|
37992
38010
|
//#endregion
|
|
37993
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
38011
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/wasm.mjs
|
|
37994
38012
|
var validate$2 = (bytes) => Promise.resolve(WebAssembly.validate(new Uint8Array(bytes)));
|
|
37995
38013
|
var bigInt = async () => {
|
|
37996
38014
|
try {
|
|
@@ -38576,7 +38594,7 @@ var WasmSupport = class _WasmSupport {
|
|
|
38576
38594
|
}
|
|
38577
38595
|
};
|
|
38578
38596
|
//#endregion
|
|
38579
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
38597
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/elliptic.mjs
|
|
38580
38598
|
var wasmSupportStatic$1 = new WasmSupport([
|
|
38581
38599
|
"bigInt",
|
|
38582
38600
|
"mutableGlobals",
|
|
@@ -38651,7 +38669,7 @@ var Elliptic = class {
|
|
|
38651
38669
|
}
|
|
38652
38670
|
};
|
|
38653
38671
|
//#endregion
|
|
38654
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
38672
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/account.mjs
|
|
38655
38673
|
var __defProp$30 = Object.defineProperty;
|
|
38656
38674
|
var __getOwnPropDesc$29 = Object.getOwnPropertyDescriptor;
|
|
38657
38675
|
var __defNormalProp$28 = (obj, key, value) => key in obj ? __defProp$30(obj, key, {
|
|
@@ -39004,7 +39022,7 @@ __publicField$28(Account, "_addressMap", {});
|
|
|
39004
39022
|
__publicField$28(Account, "_protectedConstructorKey", /* @__PURE__ */ Symbol());
|
|
39005
39023
|
Account = __decorateClass$29([staticImplements()], Account);
|
|
39006
39024
|
//#endregion
|
|
39007
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
39025
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/payload-model.mjs
|
|
39008
39026
|
var SchemaRegEx = /^(?:[a-z0-9]+\.)*[a-z0-9]+$/;
|
|
39009
39027
|
var SchemaZod = /* @__PURE__ */ pipe$1((/* @__PURE__ */ string$3()).check(/* @__PURE__ */ _regex(SchemaRegEx)), /* @__PURE__ */ transform$1((v) => v));
|
|
39010
39028
|
var isSchema = zodIsFactory(SchemaZod);
|
|
@@ -39261,7 +39279,7 @@ var QueryFieldsZod = /* @__PURE__ */ object$4({
|
|
|
39261
39279
|
minBid: /* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())
|
|
39262
39280
|
});
|
|
39263
39281
|
//#endregion
|
|
39264
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
39282
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/boundwitness-model.mjs
|
|
39265
39283
|
var BoundWitnessSchema = asSchema("network.xyo.boundwitness", true);
|
|
39266
39284
|
var SignaturesMetaZod = /* @__PURE__ */ object$4({ $signatures: /* @__PURE__ */ array$2(/* @__PURE__ */ union$2([HexZod, /* @__PURE__ */ _null$1()])) });
|
|
39267
39285
|
var UnsignedSignaturesMetaZod = /* @__PURE__ */ object$4({ $signatures: /* @__PURE__ */ array$2(/* @__PURE__ */ _null$1()) });
|
|
@@ -40613,7 +40631,7 @@ function multicast(coldObservable) {
|
|
|
40613
40631
|
});
|
|
40614
40632
|
}
|
|
40615
40633
|
//#endregion
|
|
40616
|
-
//#region ../../node_modules/.pnpm/@ariestools+threads@8.0.
|
|
40634
|
+
//#region ../../node_modules/.pnpm/@ariestools+threads@8.0.8_@opentelemetry+api@1.9.1_observable-fns@0.6.1_supports-color@5.5.0_zod@4.4.3/node_modules/@ariestools/threads/dist/node/master/index-node.mjs
|
|
40617
40635
|
var import_src = /* @__PURE__ */ __toESM(require_src$1(), 1);
|
|
40618
40636
|
cpus().length;
|
|
40619
40637
|
function resolveScriptPath(scriptPath, baseURL) {
|
|
@@ -41311,7 +41329,7 @@ var Worker2$1 = getWorkerImplementation().default;
|
|
|
41311
41329
|
* @license MIT
|
|
41312
41330
|
*/
|
|
41313
41331
|
//#endregion
|
|
41314
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
41332
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/node/hash.mjs
|
|
41315
41333
|
var import_index_umd = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
41316
41334
|
(function(global, factory) {
|
|
41317
41335
|
typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define(["exports"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.hashwasm = {}));
|
|
@@ -43726,7 +43744,7 @@ var NodeObjectHasher = class extends ObjectHasher {
|
|
|
43726
43744
|
static createNodeWorker = createNodeWorker;
|
|
43727
43745
|
};
|
|
43728
43746
|
//#endregion
|
|
43729
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
43747
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/payload-builder.mjs
|
|
43730
43748
|
var omitSchema = (payload) => {
|
|
43731
43749
|
const result = structuredClone(payload);
|
|
43732
43750
|
delete result.schema;
|
|
@@ -43894,7 +43912,7 @@ var PayloadBuilder = class _PayloadBuilder {
|
|
|
43894
43912
|
}
|
|
43895
43913
|
};
|
|
43896
43914
|
//#endregion
|
|
43897
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
43915
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/schema-name-validator.mjs
|
|
43898
43916
|
var SchemaNameValidator = class {
|
|
43899
43917
|
_parts;
|
|
43900
43918
|
_rootDomain;
|
|
@@ -43960,7 +43978,7 @@ function domainLevel(validator, level) {
|
|
|
43960
43978
|
return validator.parts?.slice(0, level + 1).toReversed().join(".");
|
|
43961
43979
|
}
|
|
43962
43980
|
//#endregion
|
|
43963
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
43981
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/payload-validator.mjs
|
|
43964
43982
|
var defaultSchemaNameValidatorFactory = (schema) => new SchemaNameValidator(schema);
|
|
43965
43983
|
var PayloadValidator = class _PayloadValidator extends ValidatorBase {
|
|
43966
43984
|
static schemaNameValidatorFactory = defaultSchemaNameValidatorFactory;
|
|
@@ -43989,7 +44007,7 @@ var PayloadValidator = class _PayloadValidator extends ValidatorBase {
|
|
|
43989
44007
|
}
|
|
43990
44008
|
};
|
|
43991
44009
|
//#endregion
|
|
43992
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44010
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/payload-wrapper.mjs
|
|
43993
44011
|
var isPayloadWrapperBase = (value) => {
|
|
43994
44012
|
return value instanceof PayloadWrapperBase;
|
|
43995
44013
|
};
|
|
@@ -44106,7 +44124,7 @@ var payloadJsonSchema = {
|
|
|
44106
44124
|
type: "object"
|
|
44107
44125
|
};
|
|
44108
44126
|
//#endregion
|
|
44109
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44127
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/boundwitness-builder.mjs
|
|
44110
44128
|
var GeneratedBoundWitnessFields = [
|
|
44111
44129
|
"addresses",
|
|
44112
44130
|
"payload_hashes",
|
|
@@ -44308,7 +44326,7 @@ var QueryBoundWitnessBuilder = class extends BoundWitnessBuilder {
|
|
|
44308
44326
|
}
|
|
44309
44327
|
};
|
|
44310
44328
|
//#endregion
|
|
44311
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44329
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/boundwitness-validator.mjs
|
|
44312
44330
|
var boundWitnessArrayPropertyContains = (bw, prop, value) => {
|
|
44313
44331
|
return bw[prop]?.includes(value);
|
|
44314
44332
|
};
|
|
@@ -44399,7 +44417,7 @@ var BoundWitnessValidator = class _BoundWitnessValidator extends PayloadValidato
|
|
|
44399
44417
|
}
|
|
44400
44418
|
};
|
|
44401
44419
|
//#endregion
|
|
44402
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44420
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/boundwitness-wrapper.mjs
|
|
44403
44421
|
var isBoundWitnessWrapper = (value) => {
|
|
44404
44422
|
if (isPayloadWrapperBase(value)) return typeof value.payloadsDataHashMap === "function";
|
|
44405
44423
|
return false;
|
|
@@ -44651,11 +44669,11 @@ var boundWitnessJsonSchema = {
|
|
|
44651
44669
|
type: "object"
|
|
44652
44670
|
};
|
|
44653
44671
|
//#endregion
|
|
44654
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44672
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/config-payload-plugin.mjs
|
|
44655
44673
|
var ConfigSchema = asSchema("network.xyo.config", true);
|
|
44656
44674
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(ConfigSchema), { config: /* @__PURE__ */ string$3() }), "toConfigPayload");
|
|
44657
44675
|
//#endregion
|
|
44658
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44676
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/schema-payload-plugin.mjs
|
|
44659
44677
|
var SchemaSchema = asSchema("network.xyo.schema", true);
|
|
44660
44678
|
var schemaDefinitionZod = /* @__PURE__ */ looseObject$1({ $id: /* @__PURE__ */ optional$2(/* @__PURE__ */ string$3()) });
|
|
44661
44679
|
var SchemaPayloadZod = /* @__PURE__ */ extend(PayloadZodOfSchema(SchemaSchema), {
|
|
@@ -44671,7 +44689,7 @@ var SchemaPayloadZod = /* @__PURE__ */ extend(PayloadZodOfSchema(SchemaSchema),
|
|
|
44671
44689
|
var isSchemaPayload = zodIsFactory(SchemaPayloadZod);
|
|
44672
44690
|
zodToFactory(SchemaPayloadZod, "toSchemaPayload");
|
|
44673
44691
|
//#endregion
|
|
44674
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
44692
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/query-payload-plugin.mjs
|
|
44675
44693
|
var QuerySchema = asSchema("network.xyo.query", true);
|
|
44676
44694
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(QuerySchema), { query: SchemaZod }), "toQueryPayload");
|
|
44677
44695
|
//#endregion
|
|
@@ -47359,7 +47377,7 @@ zero
|
|
|
47359
47377
|
zone
|
|
47360
47378
|
zoo`.split("\n"));
|
|
47361
47379
|
//#endregion
|
|
47362
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
47380
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/wallet.mjs
|
|
47363
47381
|
var __defProp$29 = Object.defineProperty;
|
|
47364
47382
|
var __getOwnPropDesc$28 = Object.getOwnPropertyDescriptor;
|
|
47365
47383
|
var __defNormalProp$27 = (obj, key, value) => key in obj ? __defProp$29(obj, key, {
|
|
@@ -47483,7 +47501,7 @@ __publicField$27(HDWallet, "uniqueName", globallyUnique("HDWallet", HDWallet, "x
|
|
|
47483
47501
|
__publicField$27(HDWallet, "_addressMap", {});
|
|
47484
47502
|
HDWallet = __decorateClass$28([staticImplements()], HDWallet);
|
|
47485
47503
|
//#endregion
|
|
47486
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol@7.
|
|
47504
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk-protocol-core@7.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_a1a8fc0ded2d0638a9d8cf37742f5b82/node_modules/@xyo-network/sdk-protocol-core/dist/neutral/manifest-model.mjs
|
|
47487
47505
|
var isString$1 = (value) => typeof value === "string";
|
|
47488
47506
|
var stringZod = /* @__PURE__ */ string$3();
|
|
47489
47507
|
var optionalStringZod = /* @__PURE__ */ optional$2(stringZod);
|
|
@@ -53381,8 +53399,8 @@ var require_json_schema_draft_07 = /* @__PURE__ */ __commonJSMin(((exports, modu
|
|
|
53381
53399
|
};
|
|
53382
53400
|
}));
|
|
53383
53401
|
//#endregion
|
|
53384
|
-
//#region ../../node_modules/.pnpm/
|
|
53385
|
-
var
|
|
53402
|
+
//#region ../../node_modules/.pnpm/ajv@8.20.0/node_modules/ajv/dist/ajv.js
|
|
53403
|
+
var require_ajv = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
53386
53404
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
53387
53405
|
exports.MissingRefError = exports.ValidationError = exports.CodeGen = exports.Name = exports.nil = exports.stringify = exports.str = exports._ = exports.KeywordCxt = exports.Ajv = void 0;
|
|
53388
53406
|
const core_1 = require_core$2();
|
|
@@ -53471,29 +53489,39 @@ var import_ajv = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
53471
53489
|
return ref_error_1.default;
|
|
53472
53490
|
}
|
|
53473
53491
|
});
|
|
53474
|
-
}))
|
|
53475
|
-
|
|
53492
|
+
}));
|
|
53493
|
+
//#endregion
|
|
53494
|
+
//#region ../../node_modules/.pnpm/lru-cache@11.5.2/node_modules/lru-cache/dist/esm/node/index.min.js
|
|
53495
|
+
var S = channel("lru-cache:metrics");
|
|
53496
|
+
var W = tracingChannel("lru-cache");
|
|
53476
53497
|
var L = typeof performance == "object" && performance && typeof performance.now == "function" ? performance : Date;
|
|
53477
|
-
var
|
|
53478
|
-
|
|
53479
|
-
|
|
53480
|
-
var
|
|
53498
|
+
var R = () => S.hasSubscribers || W.hasSubscribers;
|
|
53499
|
+
var U = /* @__PURE__ */ new Set();
|
|
53500
|
+
var M = typeof process == "object" && process ? process : {};
|
|
53501
|
+
var k = (d, e, t, i) => {
|
|
53502
|
+
typeof M.emitWarning == "function" ? M.emitWarning(d, e, t, i) : console.error(`[${t}] ${e}: ${d}`);
|
|
53503
|
+
};
|
|
53504
|
+
var H = (d) => !U.has(d);
|
|
53505
|
+
var T = (d) => !!d && d === Math.floor(d) && d > 0 && isFinite(d);
|
|
53506
|
+
var j = (d) => T(d) ? d <= Math.pow(2, 8) ? Uint8Array : d <= Math.pow(2, 16) ? Uint16Array : d <= Math.pow(2, 32) ? Uint32Array : d <= Number.MAX_SAFE_INTEGER ? O : null : null;
|
|
53507
|
+
var O = class extends Array {
|
|
53481
53508
|
constructor(e) {
|
|
53482
53509
|
super(e), this.fill(0);
|
|
53483
53510
|
}
|
|
53484
|
-
}
|
|
53511
|
+
};
|
|
53512
|
+
var x = class d {
|
|
53485
53513
|
heap;
|
|
53486
53514
|
length;
|
|
53487
53515
|
static #o = !1;
|
|
53488
53516
|
static create(e) {
|
|
53489
53517
|
let t = j(e);
|
|
53490
53518
|
if (!t) return [];
|
|
53491
|
-
|
|
53492
|
-
let i = new
|
|
53493
|
-
return
|
|
53519
|
+
d.#o = !0;
|
|
53520
|
+
let i = new d(e, t);
|
|
53521
|
+
return d.#o = !1, i;
|
|
53494
53522
|
}
|
|
53495
53523
|
constructor(e, t) {
|
|
53496
|
-
if (!
|
|
53524
|
+
if (!d.#o) throw new TypeError("instantiate Stack using Stack.create(n)");
|
|
53497
53525
|
this.heap = new t(e), this.length = 0;
|
|
53498
53526
|
}
|
|
53499
53527
|
push(e) {
|
|
@@ -53502,7 +53530,8 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53502
53530
|
pop() {
|
|
53503
53531
|
return this.heap[--this.length];
|
|
53504
53532
|
}
|
|
53505
|
-
}
|
|
53533
|
+
};
|
|
53534
|
+
var I = class d {
|
|
53506
53535
|
#o;
|
|
53507
53536
|
#c;
|
|
53508
53537
|
#S;
|
|
@@ -53548,7 +53577,7 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53548
53577
|
#T;
|
|
53549
53578
|
#U;
|
|
53550
53579
|
#f;
|
|
53551
|
-
#
|
|
53580
|
+
#D;
|
|
53552
53581
|
static unsafeExposeInternals(e) {
|
|
53553
53582
|
return {
|
|
53554
53583
|
starts: e.#F,
|
|
@@ -53603,30 +53632,30 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53603
53632
|
return this.#w;
|
|
53604
53633
|
}
|
|
53605
53634
|
constructor(e) {
|
|
53606
|
-
let { max: t = 0, ttl: i, ttlResolution: s = 1, ttlAutopurge: n, updateAgeOnGet:
|
|
53635
|
+
let { max: t = 0, ttl: i, ttlResolution: s = 1, ttlAutopurge: n, updateAgeOnGet: o, updateAgeOnHas: l, allowStale: h, dispose: r, onInsert: c, disposeAfter: m, noDisposeOnSet: _, noUpdateTTL: u, maxSize: g = 0, maxEntrySize: f = 0, sizeCalculation: y, fetchMethod: a, memoMethod: w, noDeleteOnFetchRejection: F, noDeleteOnStaleGet: b, allowStaleOnFetchRejection: p, allowStaleOnFetchAbort: A, ignoreFetchAbort: z, backgroundFetchSize: C = 1, perf: E } = e;
|
|
53607
53636
|
if (this.backgroundFetchSize = C, E !== void 0 && typeof E?.now != "function") throw new TypeError("perf option must have a now() method if specified");
|
|
53608
53637
|
if (this.#m = E ?? L, t !== 0 && !T(t)) throw new TypeError("max option must be a nonnegative integer");
|
|
53609
53638
|
let v = t ? j(t) : Array;
|
|
53610
53639
|
if (!v) throw new Error("invalid max value: " + t);
|
|
53611
|
-
if (this.#o = t, this.#c = g, this.maxEntrySize = f || this.#c, this.sizeCalculation =
|
|
53640
|
+
if (this.#o = t, this.#c = g, this.maxEntrySize = f || this.#c, this.sizeCalculation = y, this.sizeCalculation) {
|
|
53612
53641
|
if (!this.#c && !this.maxEntrySize) throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");
|
|
53613
53642
|
if (typeof this.sizeCalculation != "function") throw new TypeError("sizeCalculation set to non-function");
|
|
53614
53643
|
}
|
|
53615
53644
|
if (w !== void 0 && typeof w != "function") throw new TypeError("memoMethod must be a function if defined");
|
|
53616
|
-
if (this.#I = w,
|
|
53617
|
-
if (this.#M =
|
|
53645
|
+
if (this.#I = w, a !== void 0 && typeof a != "function") throw new TypeError("fetchMethod must be a function if specified");
|
|
53646
|
+
if (this.#M = a, this.#U = !!a, this.#s = /* @__PURE__ */ new Map(), this.#i = Array.from({ length: t }).fill(void 0), this.#t = Array.from({ length: t }).fill(void 0), this.#l = new v(t), this.#u = new v(t), this.#a = 0, this.#h = 0, this.#y = x.create(t), this.#n = 0, this.#b = 0, typeof r == "function" && (this.#S = r), typeof c == "function" && (this.#O = c), typeof m == "function" ? (this.#w = m, this.#r = []) : (this.#w = void 0, this.#r = void 0), this.#T = !!this.#S, this.#D = !!this.#O, this.#f = !!this.#w, this.noDisposeOnSet = !!_, this.noUpdateTTL = !!u, this.noDeleteOnFetchRejection = !!F, this.allowStaleOnFetchRejection = !!p, this.allowStaleOnFetchAbort = !!A, this.ignoreFetchAbort = !!z, this.maxEntrySize !== 0) {
|
|
53618
53647
|
if (this.#c !== 0 && !T(this.#c)) throw new TypeError("maxSize must be a positive integer if specified");
|
|
53619
53648
|
if (!T(this.maxEntrySize)) throw new TypeError("maxEntrySize must be a positive integer if specified");
|
|
53620
53649
|
this.#X();
|
|
53621
53650
|
}
|
|
53622
|
-
if (this.allowStale = !!
|
|
53651
|
+
if (this.allowStale = !!h, this.noDeleteOnStaleGet = !!b, this.updateAgeOnGet = !!o, this.updateAgeOnHas = !!l, this.ttlResolution = T(s) || s === 0 ? s : 1, this.ttlAutopurge = !!n, this.ttl = i || 0, this.ttl) {
|
|
53623
53652
|
if (!T(this.ttl)) throw new TypeError("ttl must be a positive integer if specified");
|
|
53624
53653
|
this.#k();
|
|
53625
53654
|
}
|
|
53626
53655
|
if (this.#o === 0 && this.ttl === 0 && this.#c === 0) throw new TypeError("At least one of max, maxSize, or ttl is required");
|
|
53627
53656
|
if (!this.ttlAutopurge && !this.#o && !this.#c) {
|
|
53628
|
-
let
|
|
53629
|
-
H(
|
|
53657
|
+
let D = "LRU_CACHE_UNBOUNDED";
|
|
53658
|
+
H(D) && (U.add(D), k("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.", "UnboundedCacheWarning", D, d));
|
|
53630
53659
|
}
|
|
53631
53660
|
}
|
|
53632
53661
|
getRemainingTTL(e) {
|
|
@@ -53636,54 +53665,57 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53636
53665
|
let e = new O(this.#o), t = new O(this.#o);
|
|
53637
53666
|
this.#d = e, this.#F = t;
|
|
53638
53667
|
let i = this.ttlAutopurge ? Array.from({ length: this.#o }) : void 0;
|
|
53639
|
-
this.#g = i, this.#H = (h,
|
|
53640
|
-
t[h] =
|
|
53641
|
-
}, this.#
|
|
53668
|
+
this.#g = i, this.#H = (h, r, c = this.#m.now()) => {
|
|
53669
|
+
t[h] = r !== 0 ? c : 0, e[h] = r, s(h, r);
|
|
53670
|
+
}, this.#R = (h) => {
|
|
53642
53671
|
t[h] = e[h] !== 0 ? this.#m.now() : 0, s(h, e[h]);
|
|
53643
53672
|
};
|
|
53644
|
-
let s = this.ttlAutopurge ? (h,
|
|
53645
|
-
if (i?.[h] && (clearTimeout(i[h]), i[h] = void 0),
|
|
53646
|
-
let
|
|
53647
|
-
this.#p(h)
|
|
53648
|
-
},
|
|
53649
|
-
|
|
53673
|
+
let s = this.ttlAutopurge ? (h, r) => {
|
|
53674
|
+
if (i?.[h] && (clearTimeout(i[h]), i[h] = void 0), r && r !== 0 && i) {
|
|
53675
|
+
let c = setTimeout(() => {
|
|
53676
|
+
this.#p(h) ? (this.#E(this.#i[h], "expire"), i[h] = void 0) : s(h, l(h));
|
|
53677
|
+
}, r + 1);
|
|
53678
|
+
c.unref && c.unref(), i[h] = c;
|
|
53650
53679
|
}
|
|
53651
53680
|
} : () => {};
|
|
53652
|
-
this.#v = (h,
|
|
53653
|
-
if (e[
|
|
53654
|
-
let
|
|
53655
|
-
if (!
|
|
53656
|
-
h.ttl =
|
|
53657
|
-
h.remainingTTL =
|
|
53681
|
+
this.#v = (h, r) => {
|
|
53682
|
+
if (e[r]) {
|
|
53683
|
+
let c = e[r], m = t[r];
|
|
53684
|
+
if (!c || !m) return;
|
|
53685
|
+
h.ttl = c, h.start = m, h.now = n || o();
|
|
53686
|
+
h.remainingTTL = c - (h.now - m);
|
|
53658
53687
|
}
|
|
53659
53688
|
};
|
|
53660
|
-
let n = 0,
|
|
53689
|
+
let n = 0, o = () => {
|
|
53661
53690
|
let h = this.#m.now();
|
|
53662
53691
|
if (this.ttlResolution > 0) {
|
|
53663
53692
|
n = h;
|
|
53664
|
-
let
|
|
53665
|
-
|
|
53693
|
+
let r = setTimeout(() => n = 0, this.ttlResolution);
|
|
53694
|
+
r.unref && r.unref();
|
|
53666
53695
|
}
|
|
53667
53696
|
return h;
|
|
53668
53697
|
};
|
|
53669
53698
|
this.getRemainingTTL = (h) => {
|
|
53670
|
-
let
|
|
53671
|
-
|
|
53672
|
-
|
|
53673
|
-
|
|
53674
|
-
|
|
53675
|
-
|
|
53676
|
-
|
|
53677
|
-
|
|
53699
|
+
let r = this.#s.get(h);
|
|
53700
|
+
return r === void 0 ? 0 : l(r);
|
|
53701
|
+
};
|
|
53702
|
+
let l = (h) => {
|
|
53703
|
+
let r = e[h], c = t[h];
|
|
53704
|
+
if (!r || !c) return Infinity;
|
|
53705
|
+
return r - ((n || o()) - c);
|
|
53706
|
+
};
|
|
53707
|
+
this.#p = (h) => {
|
|
53708
|
+
let r = t[h], c = e[h];
|
|
53709
|
+
return !!c && !!r && (n || o()) - r > c;
|
|
53678
53710
|
};
|
|
53679
53711
|
}
|
|
53680
|
-
#
|
|
53712
|
+
#R = () => {};
|
|
53681
53713
|
#v = () => {};
|
|
53682
53714
|
#H = () => {};
|
|
53683
53715
|
#p = () => !1;
|
|
53684
53716
|
#X() {
|
|
53685
53717
|
let e = new O(this.#o);
|
|
53686
|
-
this.#b = 0, this.#_ = e, this.#
|
|
53718
|
+
this.#b = 0, this.#_ = e, this.#x = (t) => {
|
|
53687
53719
|
this.#b -= e[t], e[t] = 0;
|
|
53688
53720
|
}, this.#N = (t, i, s, n) => {
|
|
53689
53721
|
if (!T(s)) {
|
|
@@ -53702,7 +53734,7 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53702
53734
|
this.#b += e[t], s && (s.entrySize = i, s.totalCalculatedSize = this.#b);
|
|
53703
53735
|
};
|
|
53704
53736
|
}
|
|
53705
|
-
#
|
|
53737
|
+
#x = (e) => {};
|
|
53706
53738
|
#j = (e, t, i) => {};
|
|
53707
53739
|
#N = (e, t, i, s) => {
|
|
53708
53740
|
if (i || s) throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");
|
|
@@ -53775,8 +53807,8 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53775
53807
|
if (s === void 0) return;
|
|
53776
53808
|
let n = { value: s };
|
|
53777
53809
|
if (this.#d && this.#F) {
|
|
53778
|
-
let
|
|
53779
|
-
if (
|
|
53810
|
+
let o = this.#d[t], l = this.#F[t];
|
|
53811
|
+
if (o && l) n.ttl = o - (this.#m.now() - l), n.start = Date.now();
|
|
53780
53812
|
}
|
|
53781
53813
|
return this.#_ && (n.size = this.#_[t]), n;
|
|
53782
53814
|
}
|
|
@@ -53785,13 +53817,13 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53785
53817
|
for (let t of this.#A({ allowStale: !0 })) {
|
|
53786
53818
|
let i = this.#i[t], s = this.#t[t], n = this.#e(s) ? s.__staleWhileFetching : s;
|
|
53787
53819
|
if (n === void 0 || i === void 0) continue;
|
|
53788
|
-
let
|
|
53820
|
+
let o = { value: n };
|
|
53789
53821
|
if (this.#d && this.#F) {
|
|
53790
|
-
|
|
53791
|
-
let
|
|
53792
|
-
|
|
53822
|
+
o.ttl = this.#d[t];
|
|
53823
|
+
let l = this.#m.now() - this.#F[t];
|
|
53824
|
+
o.start = Math.floor(Date.now() - l);
|
|
53793
53825
|
}
|
|
53794
|
-
this.#_ && (
|
|
53826
|
+
this.#_ && (o.size = this.#_[t]), e.unshift([i, o]);
|
|
53795
53827
|
}
|
|
53796
53828
|
return e;
|
|
53797
53829
|
}
|
|
@@ -53812,19 +53844,19 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53812
53844
|
return s && S.hasSubscribers && S.publish(s), n;
|
|
53813
53845
|
}
|
|
53814
53846
|
#W(e, t, i, s) {
|
|
53815
|
-
let { ttl: n = this.ttl, start:
|
|
53816
|
-
if (t === void 0) return
|
|
53817
|
-
let { noUpdateTTL:
|
|
53818
|
-
|
|
53819
|
-
let _ = this.#N(e, t, i.size || 0,
|
|
53820
|
-
if (this.maxEntrySize && _ > this.maxEntrySize) return this.#E(e, "set"),
|
|
53821
|
-
let
|
|
53822
|
-
if (
|
|
53847
|
+
let { ttl: n = this.ttl, start: o, noDisposeOnSet: l = this.noDisposeOnSet, sizeCalculation: h = this.sizeCalculation, status: r } = i, c = this.#e(t);
|
|
53848
|
+
if (t === void 0) return r && (r.set = "deleted"), this.delete(e), this;
|
|
53849
|
+
let { noUpdateTTL: m = this.noUpdateTTL } = i;
|
|
53850
|
+
r && !c && (r.value = t);
|
|
53851
|
+
let _ = this.#N(e, t, i.size || 0, h, r);
|
|
53852
|
+
if (this.maxEntrySize && _ > this.maxEntrySize) return this.#E(e, "set"), r && (r.set = "miss", r.maxEntrySizeExceeded = !0), this;
|
|
53853
|
+
let u = this.#n === 0 ? void 0 : this.#s.get(e);
|
|
53854
|
+
if (u === void 0) u = this.#n === 0 ? this.#h : this.#y.length !== 0 ? this.#y.pop() : this.#n === this.#o ? this.#G(!1) : this.#n, this.#i[u] = e, this.#t[u] = t, this.#s.set(e, u), this.#l[this.#h] = u, this.#u[u] = this.#h, this.#h = u, this.#n++, this.#j(u, _, r), r && (r.set = "add"), m = !1, this.#D && !c && this.#O?.(t, e, "add");
|
|
53823
53855
|
else {
|
|
53824
|
-
this.#L(
|
|
53825
|
-
let g = this.#t[
|
|
53856
|
+
this.#L(u);
|
|
53857
|
+
let g = this.#t[u];
|
|
53826
53858
|
if (t !== g) {
|
|
53827
|
-
if (!
|
|
53859
|
+
if (!l) if (this.#e(g)) {
|
|
53828
53860
|
g !== s && g.__abortController.abort(/* @__PURE__ */ new Error("replaced"));
|
|
53829
53861
|
let { __staleWhileFetching: f } = g;
|
|
53830
53862
|
f !== void 0 && f !== t && (this.#T && this.#S?.(f, e, "set"), this.#f && this.#r?.push([
|
|
@@ -53837,13 +53869,13 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53837
53869
|
e,
|
|
53838
53870
|
"set"
|
|
53839
53871
|
]);
|
|
53840
|
-
if (this.#
|
|
53841
|
-
let f = g && this.#e(g) ? g.__staleWhileFetching : g,
|
|
53842
|
-
|
|
53872
|
+
if (this.#x(u), this.#j(u, _, r), this.#t[u] = t, !c) {
|
|
53873
|
+
let f = g && this.#e(g) ? g.__staleWhileFetching : g, y = f === void 0 ? "add" : t !== f ? "replace" : "update";
|
|
53874
|
+
r && (r.set = y, f !== void 0 && (r.oldValue = f)), this.#D && this.onInsert?.(t, e, y);
|
|
53843
53875
|
}
|
|
53844
|
-
} else
|
|
53876
|
+
} else c || (r && (r.set = "update"), this.#D && this.onInsert?.(t, e, "update"));
|
|
53845
53877
|
}
|
|
53846
|
-
if (n !== 0 && !this.#d && this.#k(), this.#d && (
|
|
53878
|
+
if (n !== 0 && !this.#d && this.#k(), this.#d && (m || this.#H(u, n, o), r && this.#v(r, u)), !l && this.#f && this.#r) {
|
|
53847
53879
|
let g = this.#r, f;
|
|
53848
53880
|
for (; f = g?.shift();) this.#w?.(...f);
|
|
53849
53881
|
}
|
|
@@ -53867,12 +53899,12 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53867
53899
|
#G(e) {
|
|
53868
53900
|
let t = this.#a, i = this.#i[t], s = this.#t[t], n = this.#e(s);
|
|
53869
53901
|
n && s.__abortController.abort(/* @__PURE__ */ new Error("evicted"));
|
|
53870
|
-
let
|
|
53871
|
-
return (this.#T || this.#f) &&
|
|
53872
|
-
|
|
53902
|
+
let o = n ? s.__staleWhileFetching : s;
|
|
53903
|
+
return (this.#T || this.#f) && o !== void 0 && (this.#T && this.#S?.(o, i, "evict"), this.#f && this.#r?.push([
|
|
53904
|
+
o,
|
|
53873
53905
|
i,
|
|
53874
53906
|
"evict"
|
|
53875
|
-
])), this.#
|
|
53907
|
+
])), this.#x(t), this.#g?.[t] && (clearTimeout(this.#g[t]), this.#g[t] = void 0), e && (this.#i[t] = void 0, this.#t[t] = void 0, this.#y.push(t)), this.#n === 1 ? (this.#a = this.#h = 0, this.#y.length = 0) : this.#a = this.#l[t], this.#s.delete(i), this.#n--, t;
|
|
53876
53908
|
}
|
|
53877
53909
|
has(e, t = {}) {
|
|
53878
53910
|
let { status: i = S.hasSubscribers ? {} : void 0 } = t;
|
|
@@ -53883,15 +53915,15 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53883
53915
|
#Y(e, t = {}) {
|
|
53884
53916
|
let { updateAgeOnHas: i = this.updateAgeOnHas, status: s } = t, n = this.#s.get(e);
|
|
53885
53917
|
if (n !== void 0) {
|
|
53886
|
-
let
|
|
53887
|
-
if (this.#e(
|
|
53918
|
+
let o = this.#t[n];
|
|
53919
|
+
if (this.#e(o) && o.__staleWhileFetching === void 0) return !1;
|
|
53888
53920
|
if (this.#p(n)) s && (s.has = "stale", this.#v(s, n));
|
|
53889
|
-
else return i && this.#
|
|
53921
|
+
else return i && this.#R(n), s && (s.has = "hit", this.#v(s, n)), !0;
|
|
53890
53922
|
} else s && (s.has = "miss");
|
|
53891
53923
|
return !1;
|
|
53892
53924
|
}
|
|
53893
53925
|
peek(e, t = {}) {
|
|
53894
|
-
let { status: i =
|
|
53926
|
+
let { status: i = R() ? {} : void 0 } = t;
|
|
53895
53927
|
i && (i.op = "peek", i.key = e, i.cache = this), t.status = i;
|
|
53896
53928
|
let s = this.#J(e, t);
|
|
53897
53929
|
return S.hasSubscribers && S.publish(i), s;
|
|
@@ -53902,41 +53934,41 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53902
53934
|
i && (i.peek = n === void 0 ? "miss" : "stale");
|
|
53903
53935
|
return;
|
|
53904
53936
|
}
|
|
53905
|
-
let
|
|
53906
|
-
return i && (
|
|
53937
|
+
let o = this.#t[n], l = this.#e(o) ? o.__staleWhileFetching : o;
|
|
53938
|
+
return i && (l !== void 0 ? (i.peek = "hit", i.value = l) : i.peek = "miss"), l;
|
|
53907
53939
|
}
|
|
53908
53940
|
#P(e, t, i, s) {
|
|
53909
53941
|
let n = t === void 0 ? void 0 : this.#t[t];
|
|
53910
53942
|
if (this.#e(n)) return n;
|
|
53911
|
-
let
|
|
53912
|
-
|
|
53913
|
-
let
|
|
53914
|
-
signal:
|
|
53943
|
+
let o = new AbortController(), { signal: l } = i;
|
|
53944
|
+
l?.addEventListener("abort", () => o.abort(l.reason), { signal: o.signal });
|
|
53945
|
+
let h = {
|
|
53946
|
+
signal: o.signal,
|
|
53915
53947
|
options: i,
|
|
53916
53948
|
context: s
|
|
53917
|
-
},
|
|
53918
|
-
let { aborted:
|
|
53919
|
-
if (i.status && (
|
|
53920
|
-
let
|
|
53921
|
-
return (p ===
|
|
53922
|
-
},
|
|
53923
|
-
let { aborted:
|
|
53924
|
-
if (this.#t[t] ===
|
|
53949
|
+
}, r = (f, y = !1) => {
|
|
53950
|
+
let { aborted: a } = o.signal, w = i.ignoreFetchAbort && f !== void 0, F = i.ignoreFetchAbort || !!(i.allowStaleOnFetchAbort && f !== void 0);
|
|
53951
|
+
if (i.status && (a && !y ? (i.status.fetchAborted = !0, i.status.fetchError = o.signal.reason, w && (i.status.fetchAbortIgnored = !0)) : i.status.fetchResolved = !0), a && !w && !y) return m(o.signal.reason, F);
|
|
53952
|
+
let b = u, p = this.#t[t];
|
|
53953
|
+
return (p === u || p === void 0 && w && y) && (f === void 0 ? b.__staleWhileFetching !== void 0 ? this.#t[t] = b.__staleWhileFetching : this.#E(e, "fetch") : (i.status && (i.status.fetchUpdated = !0), this.#W(e, f, h.options, b))), f;
|
|
53954
|
+
}, c = (f) => (i.status && (i.status.fetchRejected = !0, i.status.fetchError = f), m(f, !1)), m = (f, y) => {
|
|
53955
|
+
let { aborted: a } = o.signal, w = a && i.allowStaleOnFetchAbort, F = w || i.allowStaleOnFetchRejection, b = F || i.noDeleteOnFetchRejection, p = u;
|
|
53956
|
+
if (this.#t[t] === u && (!b || !y && p.__staleWhileFetching === void 0 ? this.#E(e, "fetch") : w || (this.#t[t] = p.__staleWhileFetching)), F) return i.status && p.__staleWhileFetching !== void 0 && (i.status.returnedStale = !0), p.__staleWhileFetching;
|
|
53925
53957
|
if (p.__returned === p) throw f;
|
|
53926
|
-
}, _ = (f,
|
|
53927
|
-
let
|
|
53928
|
-
|
|
53929
|
-
(!i.ignoreFetchAbort || i.allowStaleOnFetchAbort) && (f(void 0), i.allowStaleOnFetchAbort && (f = (w) =>
|
|
53930
|
-
}),
|
|
53958
|
+
}, _ = (f, y) => {
|
|
53959
|
+
let a = this.#M?.(e, n, h);
|
|
53960
|
+
o.signal.addEventListener("abort", () => {
|
|
53961
|
+
(!i.ignoreFetchAbort || i.allowStaleOnFetchAbort) && (f(void 0), i.allowStaleOnFetchAbort && (f = (w) => r(w, !0)));
|
|
53962
|
+
}), a && a instanceof Promise ? a.then((w) => f(w === void 0 ? void 0 : w), y) : a !== void 0 && f(a);
|
|
53931
53963
|
};
|
|
53932
53964
|
i.status && (i.status.fetchDispatched = !0);
|
|
53933
|
-
let
|
|
53934
|
-
__abortController:
|
|
53965
|
+
let u = new Promise(_).then(r, c), g = Object.assign(u, {
|
|
53966
|
+
__abortController: o,
|
|
53935
53967
|
__staleWhileFetching: n,
|
|
53936
53968
|
__returned: void 0
|
|
53937
53969
|
});
|
|
53938
53970
|
return t === void 0 ? (this.#W(e, g, {
|
|
53939
|
-
...
|
|
53971
|
+
...h.options,
|
|
53940
53972
|
status: void 0
|
|
53941
53973
|
}), t = this.#s.get(e)) : this.#t[t] = g, g;
|
|
53942
53974
|
}
|
|
@@ -53946,53 +53978,53 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
53946
53978
|
return !!t && t instanceof Promise && t.hasOwnProperty("__staleWhileFetching") && t.__abortController instanceof AbortController;
|
|
53947
53979
|
}
|
|
53948
53980
|
fetch(e, t = {}) {
|
|
53949
|
-
let i = W.hasSubscribers, { status: s =
|
|
53981
|
+
let i = W.hasSubscribers, { status: s = R() ? {} : void 0 } = t;
|
|
53950
53982
|
t.status = s, s && t.context && (s.context = t.context);
|
|
53951
53983
|
let n = this.#B(e, t);
|
|
53952
53984
|
return s && i && (s.trace = !0, W.tracePromise(() => n, s).catch(() => {})), n;
|
|
53953
53985
|
}
|
|
53954
53986
|
async #B(e, t = {}) {
|
|
53955
|
-
let { allowStale: i = this.allowStale, updateAgeOnGet: s = this.updateAgeOnGet, noDeleteOnStaleGet: n = this.noDeleteOnStaleGet, ttl:
|
|
53956
|
-
if (
|
|
53987
|
+
let { allowStale: i = this.allowStale, updateAgeOnGet: s = this.updateAgeOnGet, noDeleteOnStaleGet: n = this.noDeleteOnStaleGet, ttl: o = this.ttl, noDisposeOnSet: l = this.noDisposeOnSet, size: h = 0, sizeCalculation: r = this.sizeCalculation, noUpdateTTL: c = this.noUpdateTTL, noDeleteOnFetchRejection: m = this.noDeleteOnFetchRejection, allowStaleOnFetchRejection: _ = this.allowStaleOnFetchRejection, ignoreFetchAbort: u = this.ignoreFetchAbort, allowStaleOnFetchAbort: g = this.allowStaleOnFetchAbort, context: f, forceRefresh: y = !1, status: a, signal: w } = t;
|
|
53988
|
+
if (a && (a.op = "fetch", a.key = e, y && (a.forceRefresh = !0), a.cache = this), !this.#U) return a && (a.fetch = "get"), this.#C(e, {
|
|
53957
53989
|
allowStale: i,
|
|
53958
53990
|
updateAgeOnGet: s,
|
|
53959
53991
|
noDeleteOnStaleGet: n,
|
|
53960
|
-
status:
|
|
53992
|
+
status: a
|
|
53961
53993
|
});
|
|
53962
53994
|
let F = {
|
|
53963
53995
|
allowStale: i,
|
|
53964
53996
|
updateAgeOnGet: s,
|
|
53965
53997
|
noDeleteOnStaleGet: n,
|
|
53966
|
-
ttl:
|
|
53967
|
-
noDisposeOnSet:
|
|
53968
|
-
size:
|
|
53969
|
-
sizeCalculation:
|
|
53970
|
-
noUpdateTTL:
|
|
53971
|
-
noDeleteOnFetchRejection:
|
|
53998
|
+
ttl: o,
|
|
53999
|
+
noDisposeOnSet: l,
|
|
54000
|
+
size: h,
|
|
54001
|
+
sizeCalculation: r,
|
|
54002
|
+
noUpdateTTL: c,
|
|
54003
|
+
noDeleteOnFetchRejection: m,
|
|
53972
54004
|
allowStaleOnFetchRejection: _,
|
|
53973
54005
|
allowStaleOnFetchAbort: g,
|
|
53974
|
-
ignoreFetchAbort:
|
|
53975
|
-
status:
|
|
54006
|
+
ignoreFetchAbort: u,
|
|
54007
|
+
status: a,
|
|
53976
54008
|
signal: w
|
|
53977
|
-
},
|
|
53978
|
-
if (
|
|
53979
|
-
|
|
53980
|
-
let p = this.#P(e,
|
|
54009
|
+
}, b = this.#s.get(e);
|
|
54010
|
+
if (b === void 0) {
|
|
54011
|
+
a && (a.fetch = "miss");
|
|
54012
|
+
let p = this.#P(e, b, F, f);
|
|
53981
54013
|
return p.__returned = p;
|
|
53982
54014
|
} else {
|
|
53983
|
-
let p = this.#t[
|
|
54015
|
+
let p = this.#t[b];
|
|
53984
54016
|
if (this.#e(p)) {
|
|
53985
54017
|
let v = i && p.__staleWhileFetching !== void 0;
|
|
53986
|
-
return
|
|
54018
|
+
return a && (a.fetch = "inflight", v && (a.returnedStale = !0)), v ? p.__staleWhileFetching : p.__returned = p;
|
|
53987
54019
|
}
|
|
53988
|
-
let A = this.#p(
|
|
53989
|
-
if (!
|
|
53990
|
-
let z = this.#P(e,
|
|
53991
|
-
return
|
|
54020
|
+
let A = this.#p(b);
|
|
54021
|
+
if (!y && !A) return a && (a.fetch = "hit"), this.#L(b), s && this.#R(b), a && this.#v(a, b), p;
|
|
54022
|
+
let z = this.#P(e, b, F, f), E = z.__staleWhileFetching !== void 0 && i;
|
|
54023
|
+
return a && (a.fetch = A ? "stale" : "refresh", E && A && (a.returnedStale = !0)), E ? z.__staleWhileFetching : z.__returned = z;
|
|
53992
54024
|
}
|
|
53993
54025
|
}
|
|
53994
54026
|
forceFetch(e, t = {}) {
|
|
53995
|
-
let i = W.hasSubscribers, { status: s =
|
|
54027
|
+
let i = W.hasSubscribers, { status: s = R() ? {} : void 0 } = t;
|
|
53996
54028
|
t.status = s, s && t.context && (s.context = t.context);
|
|
53997
54029
|
let n = this.#K(e, t);
|
|
53998
54030
|
return s && i && (s.trace = !0, W.tracePromise(() => n, s).catch(() => {})), n;
|
|
@@ -54011,15 +54043,15 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
54011
54043
|
#Q(e, t = {}) {
|
|
54012
54044
|
let i = this.#I;
|
|
54013
54045
|
if (!i) throw new Error("no memoMethod provided to constructor");
|
|
54014
|
-
let { context: s, status: n, forceRefresh:
|
|
54015
|
-
n &&
|
|
54016
|
-
let
|
|
54017
|
-
if (n && (n.memo =
|
|
54018
|
-
let
|
|
54019
|
-
options:
|
|
54046
|
+
let { context: s, status: n, forceRefresh: o, ...l } = t;
|
|
54047
|
+
n && o && (n.forceRefresh = !0);
|
|
54048
|
+
let h = this.#C(e, l), r = o || h === void 0;
|
|
54049
|
+
if (n && (n.memo = r ? "miss" : "hit", r || (n.value = h)), !r) return h;
|
|
54050
|
+
let c = i(e, h, {
|
|
54051
|
+
options: l,
|
|
54020
54052
|
context: s
|
|
54021
54053
|
});
|
|
54022
|
-
return n && (n.value =
|
|
54054
|
+
return n && (n.value = c), this.#W(e, c, l), c;
|
|
54023
54055
|
}
|
|
54024
54056
|
get(e, t = {}) {
|
|
54025
54057
|
let { status: i = S.hasSubscribers ? {} : void 0 } = t;
|
|
@@ -54028,13 +54060,13 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
54028
54060
|
return i && (s !== void 0 && (i.value = s), S.hasSubscribers && S.publish(i)), s;
|
|
54029
54061
|
}
|
|
54030
54062
|
#C(e, t = {}) {
|
|
54031
|
-
let { allowStale: i = this.allowStale, updateAgeOnGet: s = this.updateAgeOnGet, noDeleteOnStaleGet: n = this.noDeleteOnStaleGet, status:
|
|
54032
|
-
if (
|
|
54033
|
-
|
|
54063
|
+
let { allowStale: i = this.allowStale, updateAgeOnGet: s = this.updateAgeOnGet, noDeleteOnStaleGet: n = this.noDeleteOnStaleGet, status: o } = t, l = this.#s.get(e);
|
|
54064
|
+
if (l === void 0) {
|
|
54065
|
+
o && (o.get = "miss");
|
|
54034
54066
|
return;
|
|
54035
54067
|
}
|
|
54036
|
-
let
|
|
54037
|
-
return
|
|
54068
|
+
let h = this.#t[l], r = this.#e(h);
|
|
54069
|
+
return o && this.#v(o, l), this.#p(l) ? r ? (o && (o.get = "stale-fetching"), i && h.__staleWhileFetching !== void 0 ? (o && (o.returnedStale = !0), h.__staleWhileFetching) : void 0) : (n || this.#E(e, "expire"), o && (o.get = "stale"), i ? (o && (o.returnedStale = !0), h) : void 0) : (o && (o.get = r ? "fetching" : "hit"), this.#L(l), s && this.#R(l), r ? h.__staleWhileFetching : h);
|
|
54038
54070
|
}
|
|
54039
54071
|
#$(e, t) {
|
|
54040
54072
|
this.#u[t] = e, this.#l[e] = t;
|
|
@@ -54055,9 +54087,9 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
54055
54087
|
let i = !1;
|
|
54056
54088
|
if (this.#n !== 0) {
|
|
54057
54089
|
let s = this.#s.get(e);
|
|
54058
|
-
if (s !== void 0) if (this.#g?.[s] && (clearTimeout(this.#g
|
|
54090
|
+
if (s !== void 0) if (this.#g?.[s] && (clearTimeout(this.#g[s]), this.#g[s] = void 0), i = !0, this.#n === 1) this.#q(t);
|
|
54059
54091
|
else {
|
|
54060
|
-
this.#
|
|
54092
|
+
this.#x(s);
|
|
54061
54093
|
let n = this.#t[s];
|
|
54062
54094
|
if (this.#e(n) ? n.__abortController.abort(/* @__PURE__ */ new Error("deleted")) : (this.#T || this.#f) && (this.#T && this.#S?.(n, e, t), this.#f && this.#r?.push([
|
|
54063
54095
|
n,
|
|
@@ -54066,10 +54098,10 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
54066
54098
|
])), this.#s.delete(e), this.#i[s] = void 0, this.#t[s] = void 0, s === this.#h) this.#h = this.#u[s];
|
|
54067
54099
|
else if (s === this.#a) this.#a = this.#l[s];
|
|
54068
54100
|
else {
|
|
54069
|
-
let
|
|
54070
|
-
this.#l[
|
|
54071
|
-
let
|
|
54072
|
-
this.#u[
|
|
54101
|
+
let o = this.#u[s];
|
|
54102
|
+
this.#l[o] = this.#l[s];
|
|
54103
|
+
let l = this.#l[s];
|
|
54104
|
+
this.#u[l] = this.#u[s];
|
|
54073
54105
|
}
|
|
54074
54106
|
this.#n--, this.#y.push(s);
|
|
54075
54107
|
}
|
|
@@ -54108,7 +54140,8 @@ var T = (u) => !!u && u === Math.floor(u) && u > 0 && isFinite(u), j = (u) => T(
|
|
|
54108
54140
|
}
|
|
54109
54141
|
};
|
|
54110
54142
|
//#endregion
|
|
54111
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54143
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/module-model.mjs
|
|
54144
|
+
var import_ajv = require_ajv();
|
|
54112
54145
|
var ArchivingModuleConfigZod = /* @__PURE__ */ object$4({ archiving: /* @__PURE__ */ optional$2(/* @__PURE__ */ object$4({
|
|
54113
54146
|
archivists: /* @__PURE__ */ optional$2(/* @__PURE__ */ array$2(/* @__PURE__ */ custom$1())),
|
|
54114
54147
|
queries: /* @__PURE__ */ optional$2(/* @__PURE__ */ array$2(/* @__PURE__ */ custom$1()))
|
|
@@ -54407,7 +54440,7 @@ var ArchivistConfigZod = /* @__PURE__ */ extend(ModuleConfigZod, {
|
|
|
54407
54440
|
});
|
|
54408
54441
|
zodToFactory(ArchivistConfigZod, "toArchivistConfig");
|
|
54409
54442
|
//#endregion
|
|
54410
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54443
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-model.mjs
|
|
54411
54444
|
var DivinerDivineQuerySchema = asSchema("network.xyo.query.diviner.divine", true);
|
|
54412
54445
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(DivinerDivineQuerySchema), { ...QueryFieldsZod.shape }), "toDivinerDivineQuery");
|
|
54413
54446
|
var isDivinerInstance = new IsInstanceFactory().create({ divine: "function" }, [isModuleInstance]);
|
|
@@ -54425,7 +54458,7 @@ var DivinerConfigZod = /* @__PURE__ */ extend(ModuleConfigZod, {
|
|
|
54425
54458
|
});
|
|
54426
54459
|
zodToFactory(DivinerConfigZod, "toDivinerConfig");
|
|
54427
54460
|
//#endregion
|
|
54428
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54461
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-payload-model.mjs
|
|
54429
54462
|
var PayloadDivinerSchema = asSchema("network.xyo.diviner.payload", true);
|
|
54430
54463
|
var PayloadDivinerConfigSchema = asSchema(`${PayloadDivinerSchema}.config`, true);
|
|
54431
54464
|
var PayloadDivinerConfigZod = /* @__PURE__ */ extend(DivinerConfigZod, {
|
|
@@ -54444,7 +54477,7 @@ var PayloadDivinerQueryPayloadZod = /* @__PURE__ */ extend(PayloadZodOfSchema(as
|
|
|
54444
54477
|
var asPayloadDivinerQueryPayload = zodAsFactory(PayloadDivinerQueryPayloadZod, "asPayloadDivinerQueryPayload");
|
|
54445
54478
|
zodToFactory(PayloadDivinerQueryPayloadZod, "toPayloadDivinerQueryPayload");
|
|
54446
54479
|
//#endregion
|
|
54447
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54480
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/module-resolver.mjs
|
|
54448
54481
|
var AbstractModuleResolver = class extends Base {
|
|
54449
54482
|
get priority() {
|
|
54450
54483
|
return this.params.priority ?? ObjectResolverPriority.Normal;
|
|
@@ -54889,7 +54922,7 @@ var CompositeModuleResolver = class _CompositeModuleResolver extends AbstractMod
|
|
|
54889
54922
|
}
|
|
54890
54923
|
};
|
|
54891
54924
|
//#endregion
|
|
54892
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54925
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/node-model.mjs
|
|
54893
54926
|
var NodeAttachQuerySchema = asSchema("network.xyo.query.node.attach", true);
|
|
54894
54927
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(NodeAttachQuerySchema), {
|
|
54895
54928
|
...QueryFieldsZod.shape,
|
|
@@ -54930,7 +54963,7 @@ var NodeConfigSchema = asSchema("network.xyo.node.config", true);
|
|
|
54930
54963
|
var NodeConfigZod = /* @__PURE__ */ extend(ModuleConfigZod, { schema: /* @__PURE__ */ literal$2(NodeConfigSchema) });
|
|
54931
54964
|
zodToFactory(NodeConfigZod, "toNodeConfig");
|
|
54932
54965
|
//#endregion
|
|
54933
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
54966
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/module-abstract.mjs
|
|
54934
54967
|
var isDetermineAccountFromAccountParams = (params) => {
|
|
54935
54968
|
assertEx$1(isUndefined$1(params.accountPath), () => "accountPath may not be provided when account is provided");
|
|
54936
54969
|
return isDefined$1(params.account);
|
|
@@ -55684,7 +55717,7 @@ var LoggerModuleStatusReporter = class {
|
|
|
55684
55717
|
}
|
|
55685
55718
|
};
|
|
55686
55719
|
//#endregion
|
|
55687
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
55720
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/archivist-abstract.mjs
|
|
55688
55721
|
var StorageClassLabel = "network.xyo.storage.class";
|
|
55689
55722
|
var NOT_IMPLEMENTED = "Not implemented";
|
|
55690
55723
|
var AbstractArchivist = class _AbstractArchivist extends AbstractModuleInstance {
|
|
@@ -56158,7 +56191,7 @@ var AbstractArchivist = class _AbstractArchivist extends AbstractModuleInstance
|
|
|
56158
56191
|
}
|
|
56159
56192
|
};
|
|
56160
56193
|
//#endregion
|
|
56161
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56194
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/archivist-generic.mjs
|
|
56162
56195
|
var __defProp$28 = Object.defineProperty;
|
|
56163
56196
|
var __getOwnPropDesc$27 = Object.getOwnPropertyDescriptor;
|
|
56164
56197
|
var __getProtoOf$7 = Object.getPrototypeOf;
|
|
@@ -56245,7 +56278,7 @@ __publicField$26(GenericArchivist, "labels", {
|
|
|
56245
56278
|
});
|
|
56246
56279
|
GenericArchivist = __decorateClass$27([creatableModule()], GenericArchivist);
|
|
56247
56280
|
//#endregion
|
|
56248
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56281
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/archivist-view.mjs
|
|
56249
56282
|
var __defProp$27 = Object.defineProperty;
|
|
56250
56283
|
var __getOwnPropDesc$26 = Object.getOwnPropertyDescriptor;
|
|
56251
56284
|
var __getProtoOf$6 = Object.getPrototypeOf;
|
|
@@ -56308,7 +56341,7 @@ __publicField$25(ViewArchivist, "labels", {
|
|
|
56308
56341
|
});
|
|
56309
56342
|
ViewArchivist = __decorateClass$26([labeledCreatableModule()], ViewArchivist);
|
|
56310
56343
|
//#endregion
|
|
56311
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56344
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/bridge-model.mjs
|
|
56312
56345
|
var BridgeConnectQuerySchema = asSchema("network.xyo.query.bridge.connect", true);
|
|
56313
56346
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(BridgeConnectQuerySchema), {
|
|
56314
56347
|
...QueryFieldsZod.shape,
|
|
@@ -56347,7 +56380,7 @@ var BridgeConfigZod$1 = /* @__PURE__ */ extend(ModuleConfigZod, {
|
|
|
56347
56380
|
});
|
|
56348
56381
|
zodToFactory(BridgeConfigZod$1, "toBridgeConfig");
|
|
56349
56382
|
//#endregion
|
|
56350
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56383
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/module-wrapper.mjs
|
|
56351
56384
|
var __defProp$26 = Object.defineProperty;
|
|
56352
56385
|
var __getOwnPropDesc$25 = Object.getOwnPropertyDescriptor;
|
|
56353
56386
|
var __defNormalProp$24 = (obj, key, value) => key in obj ? __defProp$26(obj, key, {
|
|
@@ -56799,7 +56832,7 @@ var NodeWrapper = class extends ModuleWrapper {
|
|
|
56799
56832
|
}
|
|
56800
56833
|
};
|
|
56801
56834
|
//#endregion
|
|
56802
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56835
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/sentinel-model.mjs
|
|
56803
56836
|
var SentinelReportQuerySchema = asSchema("network.xyo.query.sentinel.report", true);
|
|
56804
56837
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(SentinelReportQuerySchema), { ...QueryFieldsZod.shape }), "toSentinelReportQuery");
|
|
56805
56838
|
var isSentinelInstance = new IsInstanceFactory().create({ report: "function" }, [isModuleInstance]);
|
|
@@ -56868,7 +56901,7 @@ var SentinelWrapper = class extends ModuleWrapper {
|
|
|
56868
56901
|
}
|
|
56869
56902
|
};
|
|
56870
56903
|
//#endregion
|
|
56871
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56904
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/witness-model.mjs
|
|
56872
56905
|
var WitnessObserveQuerySchema = asSchema("network.xyo.query.witness.observe", true);
|
|
56873
56906
|
zodToFactory(/* @__PURE__ */ extend(PayloadZodOfSchema(WitnessObserveQuerySchema), {
|
|
56874
56907
|
...QueryFieldsZod.shape,
|
|
@@ -56899,7 +56932,7 @@ var WitnessWrapper = class extends ModuleWrapper {
|
|
|
56899
56932
|
}
|
|
56900
56933
|
};
|
|
56901
56934
|
//#endregion
|
|
56902
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
56935
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/bridge-abstract.mjs
|
|
56903
56936
|
var AbstractBridge = class _AbstractBridge extends AbstractModuleInstance {
|
|
56904
56937
|
static configSchemas = [...super.configSchemas, BridgeConfigSchema];
|
|
56905
56938
|
static defaultConfigSchema = BridgeConfigSchema;
|
|
@@ -57310,7 +57343,7 @@ var AbstractModuleProxy = class extends AbstractModuleInstance {
|
|
|
57310
57343
|
}
|
|
57311
57344
|
};
|
|
57312
57345
|
//#endregion
|
|
57313
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57346
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/bridge-http.mjs
|
|
57314
57347
|
var __defProp$25 = Object.defineProperty;
|
|
57315
57348
|
var __getOwnPropDesc$24 = Object.getOwnPropertyDescriptor;
|
|
57316
57349
|
var __getProtoOf$5 = Object.getPrototypeOf;
|
|
@@ -57592,7 +57625,7 @@ __publicField$23(HttpBridge, "fetchClient", new FetchJsonClient());
|
|
|
57592
57625
|
__publicField$23(HttpBridge, "maxFailureCacheSize", 1e3);
|
|
57593
57626
|
HttpBridge = __decorateClass$24([creatableModule()], HttpBridge);
|
|
57594
57627
|
//#endregion
|
|
57595
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57628
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-abstract.mjs
|
|
57596
57629
|
var delayedResolve = async (parent, id, closure, as = asModuleInstance, timeout = 3e4, logger) => {
|
|
57597
57630
|
const start = Date.now();
|
|
57598
57631
|
let result;
|
|
@@ -57704,7 +57737,7 @@ var AbstractDiviner = class _AbstractDiviner extends AbstractModuleInstance {
|
|
|
57704
57737
|
}
|
|
57705
57738
|
};
|
|
57706
57739
|
//#endregion
|
|
57707
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57740
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-identity.mjs
|
|
57708
57741
|
var __defProp$24 = Object.defineProperty;
|
|
57709
57742
|
var __getOwnPropDesc$23 = Object.getOwnPropertyDescriptor;
|
|
57710
57743
|
var __defNormalProp$22 = (obj, key, value) => key in obj ? __defProp$24(obj, key, {
|
|
@@ -57728,13 +57761,13 @@ var IdentityDiviner = class extends AbstractDiviner {
|
|
|
57728
57761
|
__publicField$22(IdentityDiviner, "targetSchema", asSchema("network.xyo.test", true));
|
|
57729
57762
|
IdentityDiviner = __decorateClass$23([creatableModule()], IdentityDiviner);
|
|
57730
57763
|
//#endregion
|
|
57731
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57764
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-payload-abstract.mjs
|
|
57732
57765
|
var PayloadDiviner = class extends AbstractDiviner {
|
|
57733
57766
|
static configSchemas = [...super.configSchemas, PayloadDivinerConfigSchema];
|
|
57734
57767
|
static defaultConfigSchema = PayloadDivinerConfigSchema;
|
|
57735
57768
|
};
|
|
57736
57769
|
//#endregion
|
|
57737
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57770
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-payload-generic.mjs
|
|
57738
57771
|
var __defProp$23 = Object.defineProperty;
|
|
57739
57772
|
var __getOwnPropDesc$22 = Object.getOwnPropertyDescriptor;
|
|
57740
57773
|
var __getProtoOf$4 = Object.getPrototypeOf;
|
|
@@ -57874,7 +57907,7 @@ __publicField$21(GenericPayloadDiviner, "configSchemas", [...__superGet$4(Generi
|
|
|
57874
57907
|
__publicField$21(GenericPayloadDiviner, "defaultConfigSchema", GenericPayloadDivinerConfigSchema);
|
|
57875
57908
|
GenericPayloadDiviner = __decorateClass$22([creatableModule()], GenericPayloadDiviner);
|
|
57876
57909
|
//#endregion
|
|
57877
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
57910
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/archivist-memory.mjs
|
|
57878
57911
|
var __defProp$22 = Object.defineProperty;
|
|
57879
57912
|
var __getOwnPropDesc$21 = Object.getOwnPropertyDescriptor;
|
|
57880
57913
|
var __getProtoOf$3 = Object.getPrototypeOf;
|
|
@@ -58017,7 +58050,7 @@ __publicField$20(MemoryArchivist, "labels", {
|
|
|
58017
58050
|
});
|
|
58018
58051
|
MemoryArchivist = __decorateClass$21([creatableModule()], MemoryArchivist);
|
|
58019
58052
|
//#endregion
|
|
58020
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58053
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/node-abstract.mjs
|
|
58021
58054
|
var AbstractNode = class _AbstractNode extends AbstractModuleInstance {
|
|
58022
58055
|
static configSchemas = [...super.configSchemas, NodeConfigSchema];
|
|
58023
58056
|
static defaultConfigSchema = NodeConfigSchema;
|
|
@@ -58220,7 +58253,7 @@ var NodeHelper = {
|
|
|
58220
58253
|
attachedPublicModules
|
|
58221
58254
|
};
|
|
58222
58255
|
//#endregion
|
|
58223
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58256
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/node-memory.mjs
|
|
58224
58257
|
var __defProp$21 = Object.defineProperty;
|
|
58225
58258
|
var __getOwnPropDesc$20 = Object.getOwnPropertyDescriptor;
|
|
58226
58259
|
var __decorateClass$20 = (decorators, target, key, kind) => {
|
|
@@ -58441,7 +58474,7 @@ var MemoryNodeHelper = {
|
|
|
58441
58474
|
flatAttachToNewNode
|
|
58442
58475
|
};
|
|
58443
58476
|
//#endregion
|
|
58444
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58477
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/manifest-wrapper.mjs
|
|
58445
58478
|
var ManifestWrapper = class extends PayloadWrapper {
|
|
58446
58479
|
locator;
|
|
58447
58480
|
logger;
|
|
@@ -58531,7 +58564,7 @@ var ManifestWrapper = class extends PayloadWrapper {
|
|
|
58531
58564
|
}
|
|
58532
58565
|
};
|
|
58533
58566
|
//#endregion
|
|
58534
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58567
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/diviner-boundwitness.memory.mjs
|
|
58535
58568
|
var applyBoundWitnessDivinerQueryPayload = (filter, payloads = []) => {
|
|
58536
58569
|
if (!filter) return [];
|
|
58537
58570
|
const { addresses, cursor, destination, limit, order = "desc", payload_hashes, payload_schemas, sourceQuery } = filter;
|
|
@@ -58573,7 +58606,7 @@ var MemoryBoundWitnessDiviner = class extends BoundWitnessDiviner {
|
|
|
58573
58606
|
}
|
|
58574
58607
|
};
|
|
58575
58608
|
//#endregion
|
|
58576
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58609
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/node-view.mjs
|
|
58577
58610
|
var __defProp$20 = Object.defineProperty;
|
|
58578
58611
|
var __getOwnPropDesc$19 = Object.getOwnPropertyDescriptor;
|
|
58579
58612
|
var __getProtoOf$2 = Object.getPrototypeOf;
|
|
@@ -58676,7 +58709,7 @@ __publicField$19(ViewNode, "defaultConfigSchema", ViewNodeConfigSchema);
|
|
|
58676
58709
|
__publicField$19(ViewNode, "labels", { ...ModuleLimitationViewLabel });
|
|
58677
58710
|
ViewNode = __decorateClass$19([creatableModule()], ViewNode);
|
|
58678
58711
|
//#endregion
|
|
58679
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58712
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/sentinel-abstract.mjs
|
|
58680
58713
|
var AbstractSentinel = class _AbstractSentinel extends AbstractModuleInstance {
|
|
58681
58714
|
static configSchemas = [...super.configSchemas, SentinelConfigSchema];
|
|
58682
58715
|
static defaultConfigSchema = SentinelConfigSchema;
|
|
@@ -58782,7 +58815,7 @@ var AbstractSentinel = class _AbstractSentinel extends AbstractModuleInstance {
|
|
|
58782
58815
|
}
|
|
58783
58816
|
};
|
|
58784
58817
|
//#endregion
|
|
58785
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
58818
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/sentinel-memory.mjs
|
|
58786
58819
|
var SentinelIntervalAutomationWrapper = class extends PayloadWrapper {
|
|
58787
58820
|
constructor(payload) {
|
|
58788
58821
|
super(payload);
|
|
@@ -58815,6 +58848,7 @@ var SentinelIntervalAutomationWrapper = class extends PayloadWrapper {
|
|
|
58815
58848
|
if ((this.payload.start ?? 0) > (this.payload.end ?? Number.POSITIVE_INFINITY)) this.setStart(Number.POSITIVE_INFINITY);
|
|
58816
58849
|
}
|
|
58817
58850
|
consumeRemaining(count = 1) {
|
|
58851
|
+
if (this.payload.remaining === void 0) return;
|
|
58818
58852
|
const remaining = Math.max(this.remaining - count, 0);
|
|
58819
58853
|
this.setRemaining(remaining);
|
|
58820
58854
|
if (remaining <= 0) this.setStart(Number.POSITIVE_INFINITY);
|
|
@@ -58899,7 +58933,7 @@ var SentinelRunner = class extends Base {
|
|
|
58899
58933
|
}
|
|
58900
58934
|
}, { tracer: this.tracer });
|
|
58901
58935
|
}, delay);
|
|
58902
|
-
}
|
|
58936
|
+
} else if (isDefined$1(automation) && automation.type === "interval" && automation.start !== Number.POSITIVE_INFINITY) this.logger?.warn(`Unschedulable interval automation; runner stopped [${JSON.stringify(automation)}]`);
|
|
58903
58937
|
}
|
|
58904
58938
|
stop() {
|
|
58905
58939
|
if (isDefined$1(this.timeoutId)) {
|
|
@@ -59052,7 +59086,7 @@ var MemorySentinel = class extends AbstractSentinel {
|
|
|
59052
59086
|
}
|
|
59053
59087
|
};
|
|
59054
59088
|
//#endregion
|
|
59055
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
59089
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/witness-abstract.mjs
|
|
59056
59090
|
var AbstractWitness = class _AbstractWitness extends AbstractModuleInstance {
|
|
59057
59091
|
static configSchemas = [...super.configSchemas, WitnessConfigSchema];
|
|
59058
59092
|
static defaultConfigSchema = WitnessConfigSchema;
|
|
@@ -59120,7 +59154,7 @@ var AbstractWitness = class _AbstractWitness extends AbstractModuleInstance {
|
|
|
59120
59154
|
}
|
|
59121
59155
|
};
|
|
59122
59156
|
//#endregion
|
|
59123
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
59157
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/witness-adhoc.mjs
|
|
59124
59158
|
var AdhocWitnessConfigSchema = asSchema("network.xyo.witness.adhoc.config", true);
|
|
59125
59159
|
zodToFactory(/* @__PURE__ */ extend(WitnessConfigZod, {
|
|
59126
59160
|
payload: /* @__PURE__ */ optional$2(/* @__PURE__ */ custom$1()),
|
|
@@ -59137,7 +59171,7 @@ var AdhocWitness = class extends AbstractWitness {
|
|
|
59137
59171
|
}
|
|
59138
59172
|
};
|
|
59139
59173
|
//#endregion
|
|
59140
|
-
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.0.
|
|
59174
|
+
//#region ../../node_modules/.pnpm/@xyo-network+sdk@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@opent_d9f9b81a4b47d0ff9ceba921adbe7d80/node_modules/@xyo-network/sdk/dist/neutral/module-factory-locator.mjs
|
|
59141
59175
|
var standardCreatableModulesList = [
|
|
59142
59176
|
HttpBridge.factory(),
|
|
59143
59177
|
ViewArchivist.factory(),
|
|
@@ -61429,7 +61463,7 @@ config$1(en_default());
|
|
|
61429
61463
|
//#region ../../node_modules/.pnpm/zod@4.4.3/node_modules/zod/index.js
|
|
61430
61464
|
var zod_default = external_exports;
|
|
61431
61465
|
//#endregion
|
|
61432
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.0.
|
|
61466
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4._fff58e29df95b1237131e9a13841dfd7/node_modules/@xyo-network/xl1-protocol/dist/neutral/protocol-model.mjs
|
|
61433
61467
|
var ExchangeOutcomeSchema = asSchema("network.xyo.exchange.outcome", true);
|
|
61434
61468
|
var isExchangeOutcome = isPayloadOfZodType(/* @__PURE__ */ object$4({
|
|
61435
61469
|
/** Hash of the ExchangeTerms payload this outcome settles */
|
|
@@ -62156,7 +62190,7 @@ var TransactionRejectionSchema = asSchema("network.xyo.transaction.rejection", t
|
|
|
62156
62190
|
var isTransactionRejection = isPayloadOfSchemaType(TransactionRejectionSchema);
|
|
62157
62191
|
AsObjectFactory.create(isTransactionRejection);
|
|
62158
62192
|
//#endregion
|
|
62159
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.0.
|
|
62193
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4._fff58e29df95b1237131e9a13841dfd7/node_modules/@xyo-network/xl1-protocol/dist/neutral/protocol-lib.mjs
|
|
62160
62194
|
function derivedReceiveAddress(address, scope) {
|
|
62161
62195
|
return toAddress(keccak256(new TextEncoder().encode(isDefined$1(scope) ? `${scope}|${address}` : address)).slice(-40), { prefix: false });
|
|
62162
62196
|
}
|
|
@@ -62165,6 +62199,11 @@ function rewardAddressFromStepIdentity({ block, step }) {
|
|
|
62165
62199
|
return toAddress(keccak256(new TextEncoder().encode(`${block}|${resolvedStepSize}`)).slice(-40), { prefix: false });
|
|
62166
62200
|
}
|
|
62167
62201
|
asSchema("network.xyo.chain.status", true);
|
|
62202
|
+
function isSchemaAllowed(schema, allowedSchemas, disallowedSchemas) {
|
|
62203
|
+
if (allowedSchemas && !allowedSchemas.includes(schema)) return false;
|
|
62204
|
+
if (disallowedSchemas?.includes(schema) === true) return false;
|
|
62205
|
+
return true;
|
|
62206
|
+
}
|
|
62168
62207
|
var DataLakeRunnerMoniker = "DataLakeRunner";
|
|
62169
62208
|
var DataLakeViewerMoniker = "DataLakeViewer";
|
|
62170
62209
|
var XyoSignerMoniker = "XyoSigner";
|
|
@@ -62175,6 +62214,7 @@ var XyoRunnerMoniker = "XyoRunner";
|
|
|
62175
62214
|
var BlockRunnerMoniker = "BlockRunner";
|
|
62176
62215
|
var BlockPublishRunnerMoniker = "BlockPublishRunner";
|
|
62177
62216
|
var ChainStatePublishRunnerMoniker = "ChainStatePublishRunner";
|
|
62217
|
+
var DataLakePublishRunnerMoniker = "DataLakePublishRunner";
|
|
62178
62218
|
var DeadLetterQueueRunnerMoniker = "DeadLetterQueueRunner";
|
|
62179
62219
|
var FinalizationRunnerMoniker = "FinalizationRunner";
|
|
62180
62220
|
var IndexPublishRunnerMoniker = "IndexPublishRunner";
|
|
@@ -62316,6 +62356,7 @@ var ChainStateViewerMoniker = "ChainStateViewer";
|
|
|
62316
62356
|
(/* @__PURE__ */ int$1()).check(/* @__PURE__ */ _positive());
|
|
62317
62357
|
(/* @__PURE__ */ int$1()).check(/* @__PURE__ */ _positive());
|
|
62318
62358
|
var DeadLetterQueueViewerMoniker = "DeadLetterQueueViewer";
|
|
62359
|
+
var EvmChainViewerMoniker = "EvmChainViewer";
|
|
62319
62360
|
var FinalizationViewerMoniker = "FinalizationViewer";
|
|
62320
62361
|
var IndexViewerMoniker = "IndexViewer";
|
|
62321
62362
|
var PendingTransactionsOptionsZod = /* @__PURE__ */ object$4({
|
|
@@ -62368,7 +62409,7 @@ var TransactionValidationViewerMoniker = "TransactionValidationViewer";
|
|
|
62368
62409
|
var WindowedBlockViewerMoniker = "WindowedBlockViewer";
|
|
62369
62410
|
var XyoViewerMoniker = "XyoViewer";
|
|
62370
62411
|
//#endregion
|
|
62371
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.0.
|
|
62412
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4._fff58e29df95b1237131e9a13841dfd7/node_modules/@xyo-network/xl1-protocol/dist/neutral/network-model.mjs
|
|
62372
62413
|
var local_default = "<svg id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 256 256\"><g style=\"opacity:.5;\"><path d=\"M154.71,97c.46,2.59,2.5,4.62,5.1,5.05l14.05,2.34,31.71-46.17c4.57-6.65-3.62-14.62-10.14-9.87l-43.68,31.83,2.97,16.82Z\" style=\"fill:#f47f00;\"/><path d=\"M173.86,151.62l-14.05,2.34c-2.6.43-4.64,2.45-5.1,5.05l-2.97,16.82,43.68,31.83c6.52,4.75,14.71-3.21,10.14-9.87l-31.71-46.17Z\" style=\"fill:#f47f00;\"/><path d=\"M82.14,104.38l14.05-2.34c2.6-.43,4.64-2.45,5.1-5.05l2.97-16.82-43.68-31.83c-6.52-4.75-14.71,3.21-10.14,9.87l31.71,46.17Z\" style=\"fill:#f47f00;\"/><path d=\"M101.29,159c-.46-2.59-2.5-4.62-5.1-5.05l-14.05-2.34-31.71,46.17c-4.57,6.65,3.62,14.62,10.14,9.87l43.68-31.83-2.97-16.82Z\" style=\"fill:#f47f00;\"/></g><path d=\"M107.33,104l15.94-90.32c.93-5.3,8.53-5.3,9.47,0l15.94,90.32c.35,2.01,1.94,3.57,3.95,3.91l92.24,15.35c5.36.89,5.36,8.59,0,9.49l-92.24,15.35c-2.01.33-3.59,1.9-3.95,3.91l-15.94,90.32c-.93,5.3-8.53,5.3-9.47,0l-15.94-90.32c-.35-2.01-1.94-3.57-3.95-3.91l-92.24-15.35c-5.36-.89-5.36-8.59,0-9.49l92.24-15.35c2.01-.33,3.59-1.9,3.95-3.91Z\" style=\"fill:#f47f00;\"/></svg>";
|
|
62373
62414
|
var mainnet_default = "<svg id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 256 256\"><path d=\"M154.71,97c.46,2.59,2.5,4.62,5.1,5.05l14.05,2.34,31.71-46.17c4.57-6.65-3.62-14.62-10.14-9.87l-43.68,31.83,2.97,16.82Z\" style=\"fill:#8d8fc6;\"/><path d=\"M173.86,151.62l-14.05,2.34c-2.6.43-4.64,2.45-5.1,5.05l-2.97,16.82,43.68,31.83c6.52,4.75,14.71-3.21,10.14-9.87l-31.71-46.17Z\" style=\"fill:#eb407a;\"/><path d=\"M82.14,104.38l14.05-2.34c2.6-.43,4.64-2.45,5.1-5.05l2.97-16.82-43.68-31.83c-6.52-4.75-14.71,3.21-10.14,9.87l31.71,46.17Z\" style=\"fill:#579fd6;\"/><path d=\"M101.29,159c-.46-2.59-2.5-4.62-5.1-5.05l-14.05-2.34-31.71,46.17c-4.57,6.65,3.62,14.62,10.14,9.87l43.68-31.83-2.97-16.82Z\" style=\"fill:#f27046;\"/><path d=\"M107.33,104l15.94-90.32c.93-5.3,8.53-5.3,9.47,0l15.94,90.32c.35,2.01,1.94,3.57,3.95,3.91l92.24,15.35c5.36.89,5.36,8.59,0,9.49l-92.24,15.35c-2.01.33-3.59,1.9-3.95,3.91l-15.94,90.32c-.93,5.3-8.53,5.3-9.47,0l-15.94-90.32c-.35-2.01-1.94-3.57-3.95-3.91l-92.24-15.35c-5.36-.89-5.36-8.59,0-9.49l92.24-15.35c2.01-.33,3.59-1.9,3.95-3.91Z\" style=\"fill:#572aff;\"/></svg>";
|
|
62374
62415
|
var testnet_default = "<svg id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 256 256\"><g style=\"opacity:.5;\"><path d=\"M154.71,97c.46,2.59,2.5,4.62,5.1,5.05l14.05,2.34,31.71-46.17c4.57-6.65-3.62-14.62-10.14-9.87l-43.68,31.83,2.97,16.82Z\" style=\"fill:#579fd6;\"/><path d=\"M173.86,151.62l-14.05,2.34c-2.6.43-4.64,2.45-5.1,5.05l-2.97,16.82,43.68,31.83c6.52,4.75,14.71-3.21,10.14-9.87l-31.71-46.17Z\" style=\"fill:#579fd6;\"/><path d=\"M82.14,104.38l14.05-2.34c2.6-.43,4.64-2.45,5.1-5.05l2.97-16.82-43.68-31.83c-6.52-4.75-14.71,3.21-10.14,9.87l31.71,46.17Z\" style=\"fill:#579fd6;\"/><path d=\"M101.29,159c-.46-2.59-2.5-4.62-5.1-5.05l-14.05-2.34-31.71,46.17c-4.57,6.65,3.62,14.62,10.14,9.87l43.68-31.83-2.97-16.82Z\" style=\"fill:#579fd6;\"/></g><path d=\"M107.33,104l15.94-90.32c.93-5.3,8.53-5.3,9.47,0l15.94,90.32c.35,2.01,1.94,3.57,3.95,3.91l92.24,15.35c5.36.89,5.36,8.59,0,9.49l-92.24,15.35c-2.01.33-3.59,1.9-3.95,3.91l-15.94,90.32c-.93,5.3-8.53,5.3-9.47,0l-15.94-90.32c-.35-2.01-1.94-3.57-3.95-3.91l-92.24-15.35c-5.36-.89-5.36-8.59,0-9.49l92.24-15.35c2.01-.33,3.59-1.9,3.95-3.91Z\" style=\"fill:#579fd6;\"/></svg>";
|
|
@@ -62586,7 +62627,7 @@ function createIndexHead(watermark, updatedAt) {
|
|
|
62586
62627
|
}, true);
|
|
62587
62628
|
}
|
|
62588
62629
|
//#endregion
|
|
62589
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.0.
|
|
62630
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4._fff58e29df95b1237131e9a13841dfd7/node_modules/@xyo-network/xl1-protocol/dist/neutral/schema.mjs
|
|
62590
62631
|
var asRequiredStrings = (required) => {
|
|
62591
62632
|
if (typeof required === "string") return [required];
|
|
62592
62633
|
if (!Array.isArray(required)) return [];
|
|
@@ -62822,7 +62863,7 @@ var TransferPayloadJsonSchema = {
|
|
|
62822
62863
|
};
|
|
62823
62864
|
var TransferPayloadJsonSchemaPayload = new PayloadBuilder({ schema: SchemaSchema }).fields({ definition: TransferPayloadJsonSchema }).build();
|
|
62824
62865
|
//#endregion
|
|
62825
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.0.
|
|
62866
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-protocol@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4._fff58e29df95b1237131e9a13841dfd7/node_modules/@xyo-network/xl1-protocol/dist/neutral/validation.mjs
|
|
62826
62867
|
function maxTransactionFeeCost(tx) {
|
|
62827
62868
|
const { base, gasLimit, priority } = tx.fees;
|
|
62828
62869
|
return hexToBigInt(base) + hexToBigInt(priority) + hexToBigInt(gasLimit);
|
|
@@ -63059,7 +63100,7 @@ var validateTransaction = async (context, tx, additionalValidators) => {
|
|
|
63059
63100
|
}
|
|
63060
63101
|
};
|
|
63061
63102
|
//#endregion
|
|
63062
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
63103
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/neutral/driver-memory.mjs
|
|
63063
63104
|
var LruCacheMap = class {
|
|
63064
63105
|
lruCache;
|
|
63065
63106
|
constructor(options) {
|
|
@@ -63443,7 +63484,9 @@ var require_build = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
63443
63484
|
//#endregion
|
|
63444
63485
|
//#region ../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
|
|
63445
63486
|
var require_picocolors = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
63446
|
-
let p = process || {}
|
|
63487
|
+
let p = process || {};
|
|
63488
|
+
let argv = p.argv || [];
|
|
63489
|
+
let env = p.env || {};
|
|
63447
63490
|
let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
|
|
63448
63491
|
let formatter = (open, close, replace = open) => (input) => {
|
|
63449
63492
|
let string = "" + input, index = string.indexOf(close, open.length);
|
|
@@ -68038,7 +68081,7 @@ var require_ExplorerSync = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
68038
68081
|
exports.ExplorerSync = ExplorerSync;
|
|
68039
68082
|
}));
|
|
68040
68083
|
//#endregion
|
|
68041
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
68084
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/node/protocol-sdk.mjs
|
|
68042
68085
|
var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
68043
68086
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
68044
68087
|
exports.defaultLoadersSync = exports.defaultLoaders = exports.globalConfigSearchPlacesSync = exports.globalConfigSearchPlaces = exports.getDefaultSearchPlacesSync = exports.getDefaultSearchPlaces = void 0;
|
|
@@ -68664,12 +68707,175 @@ async function stepRewardTotal(context, blockViewer, { block, step }, multiplier
|
|
|
68664
68707
|
}
|
|
68665
68708
|
var XL1_NETWORK_STAKING_GENESIS_PERIOD_END_XL1_BLOCK = 107496;
|
|
68666
68709
|
var functionName = "externalBlockNumberFromXL1BlockNumber";
|
|
68667
|
-
|
|
68668
|
-
|
|
68669
|
-
|
|
68670
|
-
|
|
68671
|
-
|
|
68672
|
-
|
|
68710
|
+
var SCAN_CHUNK = 50;
|
|
68711
|
+
var MIN_SCAN_CHUNK = 10;
|
|
68712
|
+
function externalTimeOfBlock(block, externalTimeName) {
|
|
68713
|
+
const [, payloads = []] = block;
|
|
68714
|
+
return (isArray(payloads) ? asTimePayload(payloads.find(isTimePayload)) : void 0)?.[externalTimeName];
|
|
68715
|
+
}
|
|
68716
|
+
async function externalTimeAtBlock(context, blockViewer, xl1Block, externalTimeName) {
|
|
68717
|
+
const cache = contextCache(context, "externalTimeAtBlock");
|
|
68718
|
+
const cacheKey = `${xl1Block}-${externalTimeName}`;
|
|
68719
|
+
const cached = await cache.get(cacheKey);
|
|
68720
|
+
if (isDefined$1(cached)) return cached;
|
|
68721
|
+
const block = await blockViewer.blockByNumber(asXL1BlockNumber(xl1Block, true));
|
|
68722
|
+
if (isUndefined$1(block) || block === null) return { exists: false };
|
|
68723
|
+
const result = {
|
|
68724
|
+
exists: true,
|
|
68725
|
+
time: externalTimeOfBlock(block, externalTimeName)
|
|
68726
|
+
};
|
|
68727
|
+
await cache.set(cacheKey, result);
|
|
68728
|
+
return result;
|
|
68729
|
+
}
|
|
68730
|
+
async function scanForAnchor(context, blockViewer, from, direction, maxScanBlocks, externalTimeName) {
|
|
68731
|
+
if (maxScanBlocks < 1) return { final: true };
|
|
68732
|
+
const chunker = new AdaptiveChunkFetcher(context, blockViewer, direction);
|
|
68733
|
+
return direction === "backward" ? await scanBackward(chunker, from, maxScanBlocks, externalTimeName) : await scanForward(chunker, blockViewer, from, maxScanBlocks, externalTimeName);
|
|
68734
|
+
}
|
|
68735
|
+
var AdaptiveChunkFetcher = class {
|
|
68736
|
+
blockViewer;
|
|
68737
|
+
chunk = SCAN_CHUNK;
|
|
68738
|
+
context;
|
|
68739
|
+
direction;
|
|
68740
|
+
failedAtFloor = false;
|
|
68741
|
+
constructor(context, blockViewer, direction) {
|
|
68742
|
+
this.context = context;
|
|
68743
|
+
this.blockViewer = blockViewer;
|
|
68744
|
+
this.direction = direction;
|
|
68745
|
+
}
|
|
68746
|
+
/** True once a fetch failed at the minimum chunk size — the scan should give up */
|
|
68747
|
+
get exhausted() {
|
|
68748
|
+
return this.failedAtFloor;
|
|
68749
|
+
}
|
|
68750
|
+
get size() {
|
|
68751
|
+
return this.chunk;
|
|
68752
|
+
}
|
|
68753
|
+
/**
|
|
68754
|
+
* Returns the chunk ending at endBlock (descending), or undefined on a
|
|
68755
|
+
* transport error. On failure the chunk size is halved so the caller can
|
|
68756
|
+
* recompute its window and retry; once a failure happens at the floor size,
|
|
68757
|
+
* `exhausted` is set and the caller should bail non-final.
|
|
68758
|
+
*/
|
|
68759
|
+
async fetch(endBlock, count) {
|
|
68760
|
+
try {
|
|
68761
|
+
return await this.blockViewer.blocksByNumber(asXL1BlockNumber(endBlock, true), count);
|
|
68762
|
+
} catch (ex) {
|
|
68763
|
+
this.context.logger?.warn(`[${functionName}] blocksByNumber(${endBlock}, ${count}) failed during ${this.direction} scan: ${ex.message}`);
|
|
68764
|
+
if (count <= MIN_SCAN_CHUNK) this.failedAtFloor = true;
|
|
68765
|
+
else this.chunk = Math.max(MIN_SCAN_CHUNK, this.chunk >> 1);
|
|
68766
|
+
return;
|
|
68767
|
+
}
|
|
68768
|
+
}
|
|
68769
|
+
};
|
|
68770
|
+
async function scanBackward(chunker, from, maxScanBlocks, externalTimeName) {
|
|
68771
|
+
const floor = Math.max(0, from - maxScanBlocks);
|
|
68772
|
+
let cursor = from - 1;
|
|
68773
|
+
while (cursor >= floor) {
|
|
68774
|
+
const count = Math.min(chunker.size, cursor - floor + 1);
|
|
68775
|
+
const blocks = await chunker.fetch(cursor, count);
|
|
68776
|
+
if (blocks === void 0) {
|
|
68777
|
+
if (chunker.exhausted) return { final: false };
|
|
68778
|
+
continue;
|
|
68779
|
+
}
|
|
68780
|
+
for (const block of blocks) {
|
|
68781
|
+
const time = externalTimeOfBlock(block, externalTimeName);
|
|
68782
|
+
if (isDefined$1(time)) return {
|
|
68783
|
+
anchor: time,
|
|
68784
|
+
final: true
|
|
68785
|
+
};
|
|
68786
|
+
}
|
|
68787
|
+
if (blocks.length < count) return { final: false };
|
|
68788
|
+
cursor -= count;
|
|
68789
|
+
}
|
|
68790
|
+
return { final: true };
|
|
68791
|
+
}
|
|
68792
|
+
async function scanForward(chunker, blockViewer, from, maxScanBlocks, externalTimeName) {
|
|
68793
|
+
const head = await blockViewer.currentBlockNumber();
|
|
68794
|
+
const ceiling = Math.min(from + maxScanBlocks, head);
|
|
68795
|
+
let windowStart = from + 1;
|
|
68796
|
+
while (windowStart <= ceiling) {
|
|
68797
|
+
const windowEnd = Math.min(windowStart + chunker.size - 1, ceiling);
|
|
68798
|
+
const count = windowEnd - windowStart + 1;
|
|
68799
|
+
const blocks = await chunker.fetch(windowEnd, count);
|
|
68800
|
+
if (blocks === void 0) {
|
|
68801
|
+
if (chunker.exhausted) return { final: false };
|
|
68802
|
+
continue;
|
|
68803
|
+
}
|
|
68804
|
+
for (const block of blocks.toReversed()) {
|
|
68805
|
+
const time = externalTimeOfBlock(block, externalTimeName);
|
|
68806
|
+
if (isDefined$1(time)) return {
|
|
68807
|
+
anchor: time,
|
|
68808
|
+
final: true
|
|
68809
|
+
};
|
|
68810
|
+
}
|
|
68811
|
+
if (blocks.length < count) return { final: false };
|
|
68812
|
+
windowStart = windowEnd + 1;
|
|
68813
|
+
}
|
|
68814
|
+
return { final: from + maxScanBlocks <= head };
|
|
68815
|
+
}
|
|
68816
|
+
async function externalBlockNumberFromXL1BlockNumber(context, blockViewer, xl1BlockNumber, externalTimeName, direction = "backward", options) {
|
|
68817
|
+
const externalGenesisTime = options?.externalGenesisTime ?? 23372716;
|
|
68818
|
+
const maxScanBlocks = options?.maxScanBlocks ?? 1e4;
|
|
68819
|
+
const cache = contextCache(context, functionName);
|
|
68820
|
+
const cacheKey = `${xl1BlockNumber}-${externalTimeName}-${direction}-${externalGenesisTime}-${maxScanBlocks}`;
|
|
68821
|
+
const cached = await cache.get(cacheKey);
|
|
68822
|
+
if (isDefined$1(cached)) return cached;
|
|
68823
|
+
let result;
|
|
68824
|
+
let final = true;
|
|
68825
|
+
const own = await externalTimeAtBlock(context, blockViewer, xl1BlockNumber, externalTimeName);
|
|
68826
|
+
if (isDefined$1(own.time)) result = own.time;
|
|
68827
|
+
else {
|
|
68828
|
+
final = own.exists;
|
|
68829
|
+
const directions = direction === "backward" ? ["backward", "forward"] : ["forward", "backward"];
|
|
68830
|
+
for (const scanDirection of directions) {
|
|
68831
|
+
const scan = await scanForAnchor(context, blockViewer, xl1BlockNumber, scanDirection, maxScanBlocks, externalTimeName);
|
|
68832
|
+
final = final && scan.final;
|
|
68833
|
+
if (isDefined$1(scan.anchor)) {
|
|
68834
|
+
result = scan.anchor;
|
|
68835
|
+
break;
|
|
68836
|
+
}
|
|
68837
|
+
}
|
|
68838
|
+
if (isUndefined$1(result)) {
|
|
68839
|
+
context.logger?.warn(`[${functionName}] No ${externalTimeName} time anchor within ${maxScanBlocks} blocks of XL1 block ${xl1BlockNumber}; falling back to genesis time ${externalGenesisTime}`);
|
|
68840
|
+
result = externalGenesisTime;
|
|
68841
|
+
}
|
|
68842
|
+
}
|
|
68843
|
+
const blockNumber = asBlockNumber(result, { name: functionName });
|
|
68844
|
+
if (final) await cache.set(cacheKey, blockNumber);
|
|
68845
|
+
return blockNumber;
|
|
68846
|
+
}
|
|
68847
|
+
async function externalBlockRangeFromXL1BlockRange(context, blockViewer, xl1BlockRange, externalTimeName = "ethereum", options) {
|
|
68848
|
+
const start = await externalBlockNumberFromXL1BlockNumber(context, blockViewer, xl1BlockRange[0], externalTimeName, "backward", options);
|
|
68849
|
+
const end = await externalBlockNumberFromXL1BlockNumber(context, blockViewer, xl1BlockRange[1], externalTimeName, "forward", options);
|
|
68850
|
+
return end < start ? [start, start] : [start, end];
|
|
68851
|
+
}
|
|
68852
|
+
async function externalBlockRangeFromStep(context, blockViewer, stepIdentity, options) {
|
|
68853
|
+
return await externalBlockRangeFromXL1BlockRange(context, blockViewer, stepBlockRange(stepIdentity), "ethereum", options);
|
|
68854
|
+
}
|
|
68855
|
+
function mapToMapType(map) {
|
|
68856
|
+
return {
|
|
68857
|
+
get: (key) => map.get(key),
|
|
68858
|
+
has: (key) => map.has(key),
|
|
68859
|
+
set: (key, value) => {
|
|
68860
|
+
map.set(key, value);
|
|
68861
|
+
},
|
|
68862
|
+
setMany: (entries) => {
|
|
68863
|
+
for (const [key, value] of entries) map.set(key, value);
|
|
68864
|
+
},
|
|
68865
|
+
delete: (key) => map.delete(key),
|
|
68866
|
+
clear: () => map.clear(),
|
|
68867
|
+
getMany: (keys) => {
|
|
68868
|
+
const result = [];
|
|
68869
|
+
for (const key of keys) {
|
|
68870
|
+
const value = map.get(key);
|
|
68871
|
+
if (isDefined$1(value)) result.push(value);
|
|
68872
|
+
}
|
|
68873
|
+
return result;
|
|
68874
|
+
},
|
|
68875
|
+
[Symbol.iterator]: function* () {
|
|
68876
|
+
for (const entry of map) yield entry;
|
|
68877
|
+
}
|
|
68878
|
+
};
|
|
68673
68879
|
}
|
|
68674
68880
|
function allHashesPresent(hashes, payloads) {
|
|
68675
68881
|
const payloadHashes = new Set(payloads.map((p) => p._hash));
|
|
@@ -68797,39 +69003,6 @@ async function validateTransactionsOpcodes(txs) {
|
|
|
68797
69003
|
}
|
|
68798
69004
|
return txElevatedPayloads;
|
|
68799
69005
|
}
|
|
68800
|
-
async function externalBlockRangeFromXL1BlockRange(context, blockViewer, xl1BlockRange, externalTimeName = "ethereum") {
|
|
68801
|
-
return [await externalBlockNumberFromXL1BlockNumber(context, blockViewer, xl1BlockRange[0], externalTimeName), await externalBlockNumberFromXL1BlockNumber(context, blockViewer, xl1BlockRange[1], externalTimeName)];
|
|
68802
|
-
}
|
|
68803
|
-
async function externalBlockRangeFromStep(context, blockViewer, stepIdentity) {
|
|
68804
|
-
return await withContextCacheResponse(context, "externalBlockRangeFromStep", toStepIdentityString(stepIdentity), async () => {
|
|
68805
|
-
return await externalBlockRangeFromXL1BlockRange(context, blockViewer, stepBlockRange(stepIdentity));
|
|
68806
|
-
});
|
|
68807
|
-
}
|
|
68808
|
-
function mapToMapType(map) {
|
|
68809
|
-
return {
|
|
68810
|
-
get: (key) => map.get(key),
|
|
68811
|
-
has: (key) => map.has(key),
|
|
68812
|
-
set: (key, value) => {
|
|
68813
|
-
map.set(key, value);
|
|
68814
|
-
},
|
|
68815
|
-
setMany: (entries) => {
|
|
68816
|
-
for (const [key, value] of entries) map.set(key, value);
|
|
68817
|
-
},
|
|
68818
|
-
delete: (key) => map.delete(key),
|
|
68819
|
-
clear: () => map.clear(),
|
|
68820
|
-
getMany: (keys) => {
|
|
68821
|
-
const result = [];
|
|
68822
|
-
for (const key of keys) {
|
|
68823
|
-
const value = map.get(key);
|
|
68824
|
-
if (isDefined$1(value)) result.push(value);
|
|
68825
|
-
}
|
|
68826
|
-
return result;
|
|
68827
|
-
},
|
|
68828
|
-
[Symbol.iterator]: function* () {
|
|
68829
|
-
for (const entry of map) yield entry;
|
|
68830
|
-
}
|
|
68831
|
-
};
|
|
68832
|
-
}
|
|
68833
69006
|
function rewardFromBlockNumber(blockNumber) {
|
|
68834
69007
|
if (blockNumber === 0) return XL1_REWARDS_CREATOR_REWARD;
|
|
68835
69008
|
const step = Math.floor((blockNumber + XL1_REWARDS_BLOCKS_PER_STEP) / XL1_REWARDS_BLOCKS_PER_STEP);
|
|
@@ -68879,8 +69052,8 @@ async function allStakersForRange(chain, externalRange, staked) {
|
|
|
68879
69052
|
for (const address of nonZero) result[toXyoAddress(address, true)] = resultWithZeros[toXyoAddress(address, true)];
|
|
68880
69053
|
return result;
|
|
68881
69054
|
}
|
|
68882
|
-
async function allStakersForStep(context, blockViewer, stakeEventsViewer, stepContext, staked) {
|
|
68883
|
-
return await allStakersForRange(stakeEventsViewer, await externalBlockRangeFromXL1BlockRange(context, blockViewer, stepBlockRange(stepContext)), staked);
|
|
69055
|
+
async function allStakersForStep(context, blockViewer, stakeEventsViewer, stepContext, staked, timeAnchor) {
|
|
69056
|
+
return await allStakersForRange(stakeEventsViewer, await externalBlockRangeFromXL1BlockRange(context, blockViewer, stepBlockRange(stepContext), "ethereum", timeAnchor), staked);
|
|
68884
69057
|
}
|
|
68885
69058
|
async function weightedStakeForRangeByPosition(context, blockViewer, stakeEventsViewer, externalRange, staked, positionId) {
|
|
68886
69059
|
return await withContextCacheResponse(context, "weightedStakeForRangeByPosition", isDefined$1(positionId) ? `${externalRange[0]}-${externalRange[1]}-${positionId}` : `${externalRange[0]}-${externalRange[1]}-all`, async () => {
|
|
@@ -68891,11 +69064,12 @@ async function weightedStakeForRangeByPosition(context, blockViewer, stakeEvents
|
|
|
68891
69064
|
let currentTime = externalRange[0];
|
|
68892
69065
|
let currentStake = 0n;
|
|
68893
69066
|
for (const event of mergedEvents) {
|
|
68894
|
-
|
|
69067
|
+
const eventTime = asBlockNumber(Math.max(event.time, externalRange[0]), { name: "weightedStakeForRangeByPosition" });
|
|
69068
|
+
if (eventTime > currentTime) weightedStakeSum += currentStake * BigInt(eventTime - currentTime);
|
|
68895
69069
|
if (event.name === "StakeAdded") currentStake += event.args.amount;
|
|
68896
69070
|
else if (event.name === "StakeRemoved") currentStake -= event.args.amount;
|
|
68897
69071
|
currentStake = currentStake < 0n ? 0n : currentStake;
|
|
68898
|
-
currentTime =
|
|
69072
|
+
currentTime = eventTime;
|
|
68899
69073
|
if (currentTime > externalRange[1]) break;
|
|
68900
69074
|
}
|
|
68901
69075
|
if (externalRange[1] > currentTime) weightedStakeSum += currentStake * BigInt(externalRange[1] - currentTime);
|
|
@@ -68906,8 +69080,8 @@ async function weightedStakeForRangeByPosition(context, blockViewer, stakeEvents
|
|
|
68906
69080
|
return weightedStakeSum;
|
|
68907
69081
|
});
|
|
68908
69082
|
}
|
|
68909
|
-
async function networkStakeStepRewardPositionWeight(context, blockViewer, stakeEventsViewer, stepContext, position) {
|
|
68910
|
-
return await weightedStakeForRangeByPosition(context, blockViewer, stakeEventsViewer, await externalBlockRangeFromStep(context, blockViewer, stepContext), XYO_NETWORK_STAKING_ADDRESS, position);
|
|
69083
|
+
async function networkStakeStepRewardPositionWeight(context, blockViewer, stakeEventsViewer, stepContext, position, timeAnchor) {
|
|
69084
|
+
return await weightedStakeForRangeByPosition(context, blockViewer, stakeEventsViewer, await externalBlockRangeFromStep(context, blockViewer, stepContext, timeAnchor), XYO_NETWORK_STAKING_ADDRESS, position);
|
|
68911
69085
|
}
|
|
68912
69086
|
var DEFAULT_NEXT_OPTIONS = { limit: 50 };
|
|
68913
69087
|
var findMostRecentBlock = async (chainArchivist, nextOptions = DEFAULT_NEXT_OPTIONS, maxIterations = Infinity) => {
|
|
@@ -69108,6 +69282,15 @@ LocatorConfigFieldsZod.check((ctx) => {
|
|
|
69108
69282
|
});
|
|
69109
69283
|
}
|
|
69110
69284
|
});
|
|
69285
|
+
function asEvmRpcConnectionConfig(connection) {
|
|
69286
|
+
if (connection?.type !== "evm-rpc") return void 0;
|
|
69287
|
+
return connection;
|
|
69288
|
+
}
|
|
69289
|
+
function resolveEvmRpcConnection$1(config, moniker) {
|
|
69290
|
+
const normalized = normalizeConnectionsConfig$1(config);
|
|
69291
|
+
const boundName = normalized.providerBindings[moniker]?.connection;
|
|
69292
|
+
return (isDefined$1(boundName) ? asEvmRpcConnectionConfig(normalized.connections[boundName]) : void 0) ?? asEvmRpcConnectionConfig(normalized.connections["default-evm-rpc"]);
|
|
69293
|
+
}
|
|
69111
69294
|
function asMongoConnectionConfig(connection) {
|
|
69112
69295
|
if (connection?.type !== "mongo") return void 0;
|
|
69113
69296
|
return connection;
|
|
@@ -69162,19 +69345,6 @@ var UsageMetaSchema = GlobalMetaSchema.extend({
|
|
|
69162
69345
|
function isUsageMeta(v) {
|
|
69163
69346
|
return UsageMetaSchema.safeParse(v).success;
|
|
69164
69347
|
}
|
|
69165
|
-
var configName$1 = "xyo";
|
|
69166
|
-
var configSection$1 = "xl1";
|
|
69167
|
-
async function getFileConfig(searchPlaces) {
|
|
69168
|
-
const result = (await (0, import_dist.cosmiconfig)(configName$1, {
|
|
69169
|
-
cache: true,
|
|
69170
|
-
searchPlaces
|
|
69171
|
-
}).search())?.config;
|
|
69172
|
-
if (!isNull(result)) {
|
|
69173
|
-
const section = result[configSection$1];
|
|
69174
|
-
if (isDefined$1(section) && typeof section === "object") return (/* @__PURE__ */ looseObject$1(ConfigZod.shape)).parse(section);
|
|
69175
|
-
}
|
|
69176
|
-
return ConfigZod.parse({});
|
|
69177
|
-
}
|
|
69178
69348
|
Object.values(XL1Places);
|
|
69179
69349
|
var KEY_SEPARATOR = "::";
|
|
69180
69350
|
function archivistCacheKey(connectionName, archivistName) {
|
|
@@ -69275,6 +69445,7 @@ var BRANCH_SURFACE = {
|
|
|
69275
69445
|
"viewer.finalization": "node",
|
|
69276
69446
|
"viewer.time": "node",
|
|
69277
69447
|
"viewer.account.balance": "node",
|
|
69448
|
+
"viewer.stakeTotals": "node",
|
|
69278
69449
|
"viewer.networkStake": "indexed",
|
|
69279
69450
|
"viewer.stake": "indexed",
|
|
69280
69451
|
"viewer.step": "indexed"
|
|
@@ -69289,6 +69460,7 @@ var VIEWER_BRANCH_KEYS = [
|
|
|
69289
69460
|
["finalization", "viewer.finalization"],
|
|
69290
69461
|
["time", "viewer.time"],
|
|
69291
69462
|
["account", "viewer.account.balance"],
|
|
69463
|
+
["stakeTotals", "viewer.stakeTotals"],
|
|
69292
69464
|
["networkStake", "viewer.networkStake"],
|
|
69293
69465
|
["stake", "viewer.stake"],
|
|
69294
69466
|
["step", "viewer.step"]
|
|
@@ -70958,9 +71130,7 @@ var AbstractRestDataLake = class extends AbstractCreatableProvider {
|
|
|
70958
71130
|
return false;
|
|
70959
71131
|
}
|
|
70960
71132
|
isAllowedSchema(schema) {
|
|
70961
|
-
|
|
70962
|
-
if (this.disallowedSchemas?.includes(schema) === true) return false;
|
|
70963
|
-
return true;
|
|
71133
|
+
return isSchemaAllowed(schema, this.allowedSchemas, this.disallowedSchemas);
|
|
70964
71134
|
}
|
|
70965
71135
|
};
|
|
70966
71136
|
var RestDataLakeRunner = class extends AbstractRestDataLake {
|
|
@@ -71060,6 +71230,36 @@ __publicField$18(SimpleDataLakeViewer, "dependencies", []);
|
|
|
71060
71230
|
__publicField$18(SimpleDataLakeViewer, "monikers", [DataLakeViewerMoniker]);
|
|
71061
71231
|
__publicField$18(SimpleDataLakeViewer, "surface", "node");
|
|
71062
71232
|
SimpleDataLakeViewer = __decorateClass$18([creatableProvider()], SimpleDataLakeViewer);
|
|
71233
|
+
function ethProviderFromEvmRpcConnection(connection) {
|
|
71234
|
+
return isDefined$1(connection.chainId) ? new JsonRpcProvider(connection.url, Number(connection.chainId), { staticNetwork: true }) : new JsonRpcProvider(connection.url);
|
|
71235
|
+
}
|
|
71236
|
+
var SimpleEvmChainViewer = class extends AbstractCreatableProvider {
|
|
71237
|
+
moniker = SimpleEvmChainViewer.defaultMoniker;
|
|
71238
|
+
_provider;
|
|
71239
|
+
static async paramsHandler(params) {
|
|
71240
|
+
const config = params.context?.config;
|
|
71241
|
+
const connection = params.connection ?? (config === void 0 ? void 0 : resolveEvmRpcConnection$1(config, "EvmChainViewer"));
|
|
71242
|
+
return {
|
|
71243
|
+
...await super.paramsHandler(params),
|
|
71244
|
+
connection
|
|
71245
|
+
};
|
|
71246
|
+
}
|
|
71247
|
+
async createHandler() {
|
|
71248
|
+
await super.createHandler();
|
|
71249
|
+
const { connection, provider } = this.params;
|
|
71250
|
+
this._provider = provider ?? (connection === void 0 ? void 0 : ethProviderFromEvmRpcConnection(connection));
|
|
71251
|
+
assertEx$1(this._provider, () => "EvmChainViewer requires an evm-rpc connection binding or an explicit provider");
|
|
71252
|
+
}
|
|
71253
|
+
provider() {
|
|
71254
|
+
return assertEx$1(this._provider, () => "EvmChainViewer provider not initialized");
|
|
71255
|
+
}
|
|
71256
|
+
};
|
|
71257
|
+
__publicField$18(SimpleEvmChainViewer, "connectionTypes", ["evm-rpc"]);
|
|
71258
|
+
__publicField$18(SimpleEvmChainViewer, "defaultMoniker", EvmChainViewerMoniker);
|
|
71259
|
+
__publicField$18(SimpleEvmChainViewer, "dependencies", []);
|
|
71260
|
+
__publicField$18(SimpleEvmChainViewer, "monikers", [EvmChainViewerMoniker]);
|
|
71261
|
+
__publicField$18(SimpleEvmChainViewer, "surface", "node");
|
|
71262
|
+
SimpleEvmChainViewer = __decorateClass$18([creatableProvider()], SimpleEvmChainViewer);
|
|
71063
71263
|
var SimpleFinalizationRunner = class extends AbstractCreatableProvider {
|
|
71064
71264
|
moniker = SimpleFinalizationRunner.defaultMoniker;
|
|
71065
71265
|
_store;
|
|
@@ -71321,6 +71521,41 @@ __publicField$18(SimpleIndexViewer, "defaultMoniker", IndexViewerMoniker);
|
|
|
71321
71521
|
__publicField$18(SimpleIndexViewer, "dependencies", [BlockViewerMoniker]);
|
|
71322
71522
|
__publicField$18(SimpleIndexViewer, "monikers", [IndexViewerMoniker]);
|
|
71323
71523
|
SimpleIndexViewer = __decorateClass$18([creatableProvider()], SimpleIndexViewer);
|
|
71524
|
+
var applyValidationResults = async ({ bundles, isValidated, onInvalid, remaining, results, valid }) => {
|
|
71525
|
+
for (const [resultIndex, result] of results.entries()) {
|
|
71526
|
+
const itemIndex = remaining.indexes.at(resultIndex);
|
|
71527
|
+
if (itemIndex === void 0) throw new Error(`Missing remaining index [${resultIndex}]`);
|
|
71528
|
+
const validated = isValidated(result);
|
|
71529
|
+
if (!validated) await onInvalid?.({
|
|
71530
|
+
bundle: assertEx$1(bundles.at(itemIndex), () => `Missing bundle [${itemIndex}]`),
|
|
71531
|
+
item: assertEx$1(remaining.items.at(resultIndex), () => `Missing remaining item [${resultIndex}]`),
|
|
71532
|
+
result
|
|
71533
|
+
});
|
|
71534
|
+
valid[itemIndex] = validated;
|
|
71535
|
+
}
|
|
71536
|
+
};
|
|
71537
|
+
var collectExistingItems = (items) => {
|
|
71538
|
+
const indexes = [];
|
|
71539
|
+
const existingItems = items.map((item, index) => {
|
|
71540
|
+
if (item === void 0) return;
|
|
71541
|
+
indexes.push(index);
|
|
71542
|
+
return item;
|
|
71543
|
+
}).filter(exists$1);
|
|
71544
|
+
assertEx$1(indexes.length === existingItems.length, () => `remaining indexes length should match remaining items length [${indexes.length}/${existingItems.length}]`);
|
|
71545
|
+
return {
|
|
71546
|
+
indexes,
|
|
71547
|
+
items: existingItems
|
|
71548
|
+
};
|
|
71549
|
+
};
|
|
71550
|
+
var invalidBundleHashes = (bundles, valid) => {
|
|
71551
|
+
return bundles.map((bundle3, index) => {
|
|
71552
|
+
if (valid.at(index) !== true) return bundle3._hash;
|
|
71553
|
+
}).filter(exists$1);
|
|
71554
|
+
};
|
|
71555
|
+
var nextPruneCursor = (batch, pruneHashes, cursor) => {
|
|
71556
|
+
const pruneSet = new Set(pruneHashes);
|
|
71557
|
+
return batch.findLast((bundle3) => !pruneSet.has(bundle3._hash))?._sequence ?? cursor;
|
|
71558
|
+
};
|
|
71324
71559
|
var DEFAULT_SYNC_INTERVAL = 3e4;
|
|
71325
71560
|
var DEFAULT_SYNC_LIMIT = 100;
|
|
71326
71561
|
var ENFORCE_CAP_BATCH_SIZE = 1e3;
|
|
@@ -71395,106 +71630,115 @@ var SimpleMempoolRunner = class extends AbstractCreatableProvider {
|
|
|
71395
71630
|
this._mempoolViewer = await this.locator.tryGetInstance(MempoolViewerMoniker);
|
|
71396
71631
|
}
|
|
71397
71632
|
async prunePendingBlocks({ batchSize = 10, maxPrune = 1e3, maxCheck = 1e3 } = {}) {
|
|
71633
|
+
const startedAt = Date.now();
|
|
71398
71634
|
let total = 0;
|
|
71399
71635
|
let pruned = 0;
|
|
71636
|
+
let batches = 0;
|
|
71400
71637
|
let cursor;
|
|
71401
71638
|
let batch = await this.pendingBlocksArchivist.next({
|
|
71402
71639
|
limit: batchSize,
|
|
71403
71640
|
cursor,
|
|
71404
71641
|
order: "desc"
|
|
71405
71642
|
});
|
|
71406
|
-
this.logger?.
|
|
71643
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingBlocks start batchSize=${batchSize} maxPrune=${maxPrune} maxCheck=${maxCheck} firstBatch=${batch.length}`);
|
|
71644
|
+
if (batch.length === 0) {
|
|
71645
|
+
this.logger?.info("[SimpleMempoolRunner] prunePendingBlocks: pending_block_bundles empty (nothing to check)");
|
|
71646
|
+
return [0, 0];
|
|
71647
|
+
}
|
|
71407
71648
|
while (batch.length > 0 && pruned < maxPrune && total < maxCheck) {
|
|
71649
|
+
batches += 1;
|
|
71408
71650
|
const blocksAndBundles = await this.simpleBlockValidationCheck(batch);
|
|
71409
71651
|
const blocks = blocksAndBundles.map(([b]) => b);
|
|
71410
71652
|
const bundles = blocksAndBundles.map(([_, p]) => p);
|
|
71411
71653
|
const valid = blocks.map((b) => !!b);
|
|
71412
|
-
const
|
|
71413
|
-
|
|
71414
|
-
|
|
71415
|
-
|
|
71416
|
-
|
|
71417
|
-
|
|
71418
|
-
|
|
71419
|
-
|
|
71420
|
-
|
|
71421
|
-
|
|
71422
|
-
|
|
71423
|
-
|
|
71424
|
-
|
|
71425
|
-
|
|
71426
|
-
|
|
71427
|
-
|
|
71428
|
-
}
|
|
71429
|
-
valid[remainingBlockMap[i]] = validated;
|
|
71430
|
-
}
|
|
71431
|
-
const pruneHashes = bundles.map((p, i) => {
|
|
71432
|
-
if (valid.at(i) !== true) return p._hash;
|
|
71433
|
-
}).filter(exists$1);
|
|
71654
|
+
const remaining = collectExistingItems(blocks);
|
|
71655
|
+
await applyValidationResults({
|
|
71656
|
+
bundles,
|
|
71657
|
+
valid,
|
|
71658
|
+
remaining,
|
|
71659
|
+
results: await Promise.all(remaining.items.map(async (remainingBlock) => this.blockValidationViewer.validateBlock(remainingBlock, {
|
|
71660
|
+
value: true,
|
|
71661
|
+
state: true
|
|
71662
|
+
}))),
|
|
71663
|
+
isValidated: isSignedHydratedBlockWithHashMeta,
|
|
71664
|
+
onInvalid: ({ bundle: bundle3, result }) => {
|
|
71665
|
+
const errors = result;
|
|
71666
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingBlocks deleting block ${bundle3._hash} (validation: ${errors.at(0)?.message ?? "failed simple/full check"})`);
|
|
71667
|
+
}
|
|
71668
|
+
});
|
|
71669
|
+
const pruneHashes = invalidBundleHashes(bundles, valid);
|
|
71434
71670
|
pruned += pruneHashes.length;
|
|
71435
71671
|
total += batch.length;
|
|
71436
|
-
|
|
71437
|
-
|
|
71438
|
-
|
|
71672
|
+
if (pruneHashes.length > 0) {
|
|
71673
|
+
await this.pendingBlocksArchivist.delete(pruneHashes);
|
|
71674
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingBlocks batch deleted ${pruneHashes.length} (batchSize=${batch.length} runningPruned=${pruned} checked=${total})`);
|
|
71675
|
+
}
|
|
71676
|
+
cursor = nextPruneCursor(batch, pruneHashes, cursor);
|
|
71439
71677
|
batch = await this.pendingBlocksArchivist.next({
|
|
71440
71678
|
limit: batchSize,
|
|
71441
71679
|
cursor,
|
|
71442
71680
|
order: "desc"
|
|
71443
71681
|
});
|
|
71444
71682
|
}
|
|
71445
|
-
|
|
71683
|
+
const durationMs = Date.now() - startedAt;
|
|
71684
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingBlocks done pruned=${pruned} checked=${total} batches=${batches} durationMs=${durationMs} hitMaxPrune=${pruned >= maxPrune} hitMaxCheck=${total >= maxCheck} poolExhausted=${batch.length === 0}`);
|
|
71446
71685
|
return [pruned, total];
|
|
71447
71686
|
}
|
|
71448
71687
|
async prunePendingTransactions({ batchSize = 10, maxPrune = 1e3, maxCheck = 1e3 } = {}) {
|
|
71688
|
+
const startedAt = Date.now();
|
|
71449
71689
|
let total = 0;
|
|
71450
71690
|
let pruned = 0;
|
|
71691
|
+
let batches = 0;
|
|
71451
71692
|
let cursor;
|
|
71452
71693
|
let batch = await this.pendingTransactionsArchivist.next({
|
|
71453
71694
|
limit: batchSize,
|
|
71454
71695
|
cursor,
|
|
71455
71696
|
order: "desc"
|
|
71456
71697
|
});
|
|
71457
|
-
this.logger?.
|
|
71698
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingTransactions start batchSize=${batchSize} maxPrune=${maxPrune} maxCheck=${maxCheck} firstBatch=${batch.length}`);
|
|
71699
|
+
if (batch.length === 0) {
|
|
71700
|
+
this.logger?.info("[SimpleMempoolRunner] prunePendingTransactions: pending_transaction_bundles empty (nothing to check)");
|
|
71701
|
+
return this.finalizePruneTransactionsResult(0, 0);
|
|
71702
|
+
}
|
|
71458
71703
|
while (batch.length > 0 && pruned < maxPrune && total < maxCheck) {
|
|
71704
|
+
batches += 1;
|
|
71459
71705
|
const transactionsAndBundles = await this.simpleTransactionValidationCheck(batch);
|
|
71460
71706
|
const transactions = transactionsAndBundles.map(([t]) => t);
|
|
71461
71707
|
const bundles = transactionsAndBundles.map(([_, p]) => p);
|
|
71462
71708
|
const valid = transactions.map((t) => !!t);
|
|
71463
|
-
const
|
|
71464
|
-
|
|
71465
|
-
|
|
71466
|
-
|
|
71467
|
-
|
|
71468
|
-
|
|
71469
|
-
|
|
71470
|
-
|
|
71471
|
-
|
|
71472
|
-
|
|
71473
|
-
|
|
71474
|
-
|
|
71475
|
-
|
|
71476
|
-
|
|
71477
|
-
this.
|
|
71478
|
-
|
|
71479
|
-
|
|
71480
|
-
|
|
71481
|
-
valid[remainingTransactionMap[i]] = validated;
|
|
71482
|
-
}
|
|
71483
|
-
const pruneHashes = bundles.map((p, i) => {
|
|
71484
|
-
if (valid.at(i) !== true) return p._hash;
|
|
71485
|
-
}).filter(exists$1);
|
|
71709
|
+
const remaining = collectExistingItems(transactions);
|
|
71710
|
+
await applyValidationResults({
|
|
71711
|
+
bundles,
|
|
71712
|
+
valid,
|
|
71713
|
+
remaining,
|
|
71714
|
+
results: await Promise.all(remaining.items.map(async (remainingTransaction) => this.transactionValidationViewer.validateTransaction(remainingTransaction, {
|
|
71715
|
+
value: true,
|
|
71716
|
+
state: true
|
|
71717
|
+
}))),
|
|
71718
|
+
isValidated: isSignedHydratedTransactionWithHashMeta,
|
|
71719
|
+
onInvalid: async ({ bundle: bundle3, item, result }) => {
|
|
71720
|
+
const errors = result;
|
|
71721
|
+
this.logger?.debug(`Pruning transaction ${bundle3._hash} during transaction validation`);
|
|
71722
|
+
this.logger?.debug(` - validation result: ${errors.at(0)?.message}`);
|
|
71723
|
+
await this.routeRejectedTransaction(item, errors);
|
|
71724
|
+
}
|
|
71725
|
+
});
|
|
71726
|
+
const pruneHashes = invalidBundleHashes(bundles, valid);
|
|
71486
71727
|
pruned += pruneHashes.length;
|
|
71487
71728
|
total += batch.length;
|
|
71488
|
-
|
|
71489
|
-
|
|
71490
|
-
|
|
71491
|
-
|
|
71729
|
+
if (pruneHashes.length > 0) {
|
|
71730
|
+
await this.pendingTransactionsArchivist.delete(pruneHashes);
|
|
71731
|
+
this.forgetBundleHashes(pruneHashes);
|
|
71732
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingTransactions batch deleted ${pruneHashes.length} (batchSize=${batch.length} runningPruned=${pruned} checked=${total})`);
|
|
71733
|
+
}
|
|
71734
|
+
cursor = nextPruneCursor(batch, pruneHashes, cursor);
|
|
71492
71735
|
batch = await this.pendingTransactionsArchivist.next({
|
|
71493
71736
|
limit: batchSize,
|
|
71494
71737
|
cursor,
|
|
71495
71738
|
order: "desc"
|
|
71496
71739
|
});
|
|
71497
71740
|
}
|
|
71741
|
+
this.logger?.info(`[SimpleMempoolRunner] prunePendingTransactions done pruned=${pruned} checked=${total} batches=${batches} durationMs=${Date.now() - startedAt} hitMaxPrune=${pruned >= maxPrune} hitMaxCheck=${total >= maxCheck} poolExhausted=${batch.length === 0}`);
|
|
71498
71742
|
return this.finalizePruneTransactionsResult(pruned, total);
|
|
71499
71743
|
}
|
|
71500
71744
|
async submitBlocks(blocks) {
|
|
@@ -71579,7 +71823,6 @@ var SimpleMempoolRunner = class extends AbstractCreatableProvider {
|
|
|
71579
71823
|
this.logger?.debug(`enforceCap evicted ${toEvict.length} bundles (pool=${all.length}, cap=${cap})`);
|
|
71580
71824
|
}
|
|
71581
71825
|
async finalizePruneTransactionsResult(pruned, total) {
|
|
71582
|
-
this.logger?.debug(`prunePendingTransactions completed: pruned=${pruned}, totalChecked=${total}`);
|
|
71583
71826
|
await this.enforceCap();
|
|
71584
71827
|
return [pruned, total];
|
|
71585
71828
|
}
|
|
@@ -72266,11 +72509,12 @@ SimpleSystemStatusViewer = __decorateClass$18([creatableProvider()], SimpleSyste
|
|
|
72266
72509
|
var SimpleTimeSyncViewer = class extends AbstractCreatableProvider {
|
|
72267
72510
|
moniker = SimpleTimeSyncViewer.defaultMoniker;
|
|
72268
72511
|
_blockViewer;
|
|
72512
|
+
_ethProvider;
|
|
72269
72513
|
get blockViewer() {
|
|
72270
72514
|
return this._blockViewer;
|
|
72271
72515
|
}
|
|
72272
72516
|
get ethProvider() {
|
|
72273
|
-
return this.
|
|
72517
|
+
return this._ethProvider;
|
|
72274
72518
|
}
|
|
72275
72519
|
async convertTime(fromDomain, toDomain, from) {
|
|
72276
72520
|
switch (fromDomain) {
|
|
@@ -72293,6 +72537,9 @@ var SimpleTimeSyncViewer = class extends AbstractCreatableProvider {
|
|
|
72293
72537
|
async createHandler() {
|
|
72294
72538
|
await super.createHandler();
|
|
72295
72539
|
this._blockViewer = await this.locator.getInstance(BlockViewerMoniker);
|
|
72540
|
+
const evmChainViewer = await this.tryLocateAndCreate(EvmChainViewerMoniker);
|
|
72541
|
+
this._ethProvider = await evmChainViewer?.provider();
|
|
72542
|
+
if (this.ethProvider === void 0) this.logger?.warn("No EvmChainViewer available — TimePayloads will omit ethereum block number/hash");
|
|
72296
72543
|
}
|
|
72297
72544
|
async currentTime(domain) {
|
|
72298
72545
|
switch (domain) {
|
|
@@ -72335,6 +72582,7 @@ var SimpleTimeSyncViewer = class extends AbstractCreatableProvider {
|
|
|
72335
72582
|
}
|
|
72336
72583
|
};
|
|
72337
72584
|
__publicField$18(SimpleTimeSyncViewer, "connectionTypes", [
|
|
72585
|
+
"evm-rpc",
|
|
72338
72586
|
"lmdb",
|
|
72339
72587
|
"mongo",
|
|
72340
72588
|
"memory"
|
|
@@ -75949,7 +76197,15 @@ var __classPrivateFieldGet$3 = function(receiver, state, kind, f) {
|
|
|
75949
76197
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
75950
76198
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
75951
76199
|
};
|
|
75952
|
-
var _JsonRpcEngineV2_instances
|
|
76200
|
+
var _JsonRpcEngineV2_instances;
|
|
76201
|
+
var _JsonRpcEngineV2_middleware;
|
|
76202
|
+
var _JsonRpcEngineV2_isDestroyed;
|
|
76203
|
+
var _JsonRpcEngineV2_handle;
|
|
76204
|
+
var _JsonRpcEngineV2_makeNextFactory;
|
|
76205
|
+
var _JsonRpcEngineV2_makeMiddlewareIterator;
|
|
76206
|
+
var _JsonRpcEngineV2_updateResult;
|
|
76207
|
+
var _JsonRpcEngineV2_assertValidNextRequest;
|
|
76208
|
+
var _JsonRpcEngineV2_assertIsNotDestroyed;
|
|
75953
76209
|
function $importDefault(module) {
|
|
75954
76210
|
if (module?.__esModule) return module.default;
|
|
75955
76211
|
return module;
|
|
@@ -76130,7 +76386,10 @@ var __classPrivateFieldGet$2 = function(receiver, state, kind, f) {
|
|
|
76130
76386
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
76131
76387
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
76132
76388
|
};
|
|
76133
|
-
var _a$1
|
|
76389
|
+
var _a$1;
|
|
76390
|
+
var _JsonRpcServer_engine;
|
|
76391
|
+
var _JsonRpcServer_onError;
|
|
76392
|
+
var _JsonRpcServer_coerceRequest;
|
|
76134
76393
|
const jsonrpc$1 = "2.0";
|
|
76135
76394
|
/**
|
|
76136
76395
|
* A JSON-RPC server that handles requests and notifications.
|
|
@@ -76246,7 +76505,7 @@ function getOriginalId(rawRequest) {
|
|
|
76246
76505
|
return [void 0, false];
|
|
76247
76506
|
}
|
|
76248
76507
|
//#endregion
|
|
76249
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
76508
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/neutral/rpc.mjs
|
|
76250
76509
|
var __defProp$18 = Object.defineProperty;
|
|
76251
76510
|
var __getOwnPropDesc$17 = Object.getOwnPropertyDescriptor;
|
|
76252
76511
|
var __defNormalProp$17 = (obj, key, value) => key in obj ? __defProp$18(obj, key, {
|
|
@@ -76305,6 +76564,17 @@ var rpcMethodHandlersFromNetworkStakingStepRewardsByPositionViewer = (viewer) =>
|
|
|
76305
76564
|
var rpcMethodHandlersFromRunner = (runner) => {
|
|
76306
76565
|
return { xyoRunner_broadcastTransaction: (params) => runner.broadcastTransaction(...params ?? []) };
|
|
76307
76566
|
};
|
|
76567
|
+
var rpcMethodHandlersFromStakeTotalsViewer = (viewer) => {
|
|
76568
|
+
return {
|
|
76569
|
+
stakeTotalsViewer_active: (params) => viewer.active(...params ?? []),
|
|
76570
|
+
stakeTotalsViewer_activeByStaked: (params) => viewer.activeByStaked(...params ?? []),
|
|
76571
|
+
stakeTotalsViewer_activeByStaker: (params) => viewer.activeByStaker(...params ?? []),
|
|
76572
|
+
stakeTotalsViewer_pending: (params) => viewer.pending(...params ?? []),
|
|
76573
|
+
stakeTotalsViewer_pendingByStaker: (params) => viewer.pendingByStaker(...params ?? []),
|
|
76574
|
+
stakeTotalsViewer_withdrawn: (params) => viewer.withdrawn(...params ?? []),
|
|
76575
|
+
stakeTotalsViewer_withdrawnByStaker: (params) => viewer.withdrawnByStaker(...params ?? [])
|
|
76576
|
+
};
|
|
76577
|
+
};
|
|
76308
76578
|
var rpcMethodHandlersFromTimeSyncViewer = (viewer) => {
|
|
76309
76579
|
return {
|
|
76310
76580
|
timeSyncViewer_convertTime: (params) => viewer.convertTime(...params ?? []),
|
|
@@ -76748,8 +77018,8 @@ var NetworkStakingStepRewardsTotalViewerRpcSchemas = {
|
|
|
76748
77018
|
var StakeTotalsViewerRpcSchemas = {
|
|
76749
77019
|
stakeTotalsViewer_active: {
|
|
76750
77020
|
params: {
|
|
76751
|
-
to: /* @__PURE__ */
|
|
76752
|
-
from: /* @__PURE__ */
|
|
77021
|
+
to: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())]),
|
|
77022
|
+
from: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())])
|
|
76753
77023
|
},
|
|
76754
77024
|
result: {
|
|
76755
77025
|
to: BigIntToJsonZod,
|
|
@@ -76778,8 +77048,8 @@ var StakeTotalsViewerRpcSchemas = {
|
|
|
76778
77048
|
},
|
|
76779
77049
|
stakeTotalsViewer_pending: {
|
|
76780
77050
|
params: {
|
|
76781
|
-
to: /* @__PURE__ */
|
|
76782
|
-
from: /* @__PURE__ */
|
|
77051
|
+
to: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())]),
|
|
77052
|
+
from: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())])
|
|
76783
77053
|
},
|
|
76784
77054
|
result: {
|
|
76785
77055
|
to: BigIntToJsonZod,
|
|
@@ -76798,8 +77068,8 @@ var StakeTotalsViewerRpcSchemas = {
|
|
|
76798
77068
|
},
|
|
76799
77069
|
stakeTotalsViewer_withdrawn: {
|
|
76800
77070
|
params: {
|
|
76801
|
-
to: /* @__PURE__ */
|
|
76802
|
-
from: /* @__PURE__ */
|
|
77071
|
+
to: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())]),
|
|
77072
|
+
from: /* @__PURE__ */ tuple$1([/* @__PURE__ */ optional$2(/* @__PURE__ */ number$5())])
|
|
76803
77073
|
},
|
|
76804
77074
|
result: {
|
|
76805
77075
|
to: BigIntToJsonZod,
|
|
@@ -78380,6 +78650,8 @@ var composedRpcEngineFromConnection = (connection, logger) => {
|
|
|
78380
78650
|
if (timeSyncViewer) subEngines.push(buildTypedSubEngine(TimeSyncViewerRpcSchemas, rpcMethodHandlersFromTimeSyncViewer(timeSyncViewer)));
|
|
78381
78651
|
const transactionViewer = viewer?.transaction;
|
|
78382
78652
|
if (transactionViewer) subEngines.push(buildTypedSubEngine(TransactionViewerRpcSchemas, rpcMethodHandlersFromTransactionViewer(transactionViewer)));
|
|
78653
|
+
const stakeTotalsViewer = viewer?.stakeTotals;
|
|
78654
|
+
if (stakeTotalsViewer) subEngines.push(buildTypedSubEngine(StakeTotalsViewerRpcSchemas, rpcMethodHandlersFromStakeTotalsViewer(stakeTotalsViewer)));
|
|
78383
78655
|
const mempoolRunner = runner?.mempool;
|
|
78384
78656
|
if (mempoolRunner) subEngines.push(buildTypedSubEngine(MempoolRunnerRpcSchemas, rpcMethodHandlersFromMempoolRunner(mempoolRunner)));
|
|
78385
78657
|
const networkStakeViewer = viewer?.networkStake;
|
|
@@ -78395,7 +78667,7 @@ var composedRpcServerFromConnection = (connection, logger) => {
|
|
|
78395
78667
|
return new JsonRpcServer({ engine: composedRpcEngineFromConnection(connection, logger) });
|
|
78396
78668
|
};
|
|
78397
78669
|
//#endregion
|
|
78398
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
78670
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/neutral/rest-block-viewer.mjs
|
|
78399
78671
|
var __defProp$17 = Object.defineProperty;
|
|
78400
78672
|
var __getOwnPropDesc$16 = Object.getOwnPropertyDescriptor;
|
|
78401
78673
|
var __defNormalProp$16 = (obj, key, value) => key in obj ? __defProp$17(obj, key, {
|
|
@@ -78924,7 +79196,7 @@ __publicField$16(RestIndexViewer, "dependencies", []);
|
|
|
78924
79196
|
__publicField$16(RestIndexViewer, "monikers", [IndexViewerMoniker]);
|
|
78925
79197
|
RestIndexViewer = __decorateClass$16([creatableProvider()], RestIndexViewer);
|
|
78926
79198
|
//#endregion
|
|
78927
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
79199
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/neutral/providers.mjs
|
|
78928
79200
|
var __defProp$16 = Object.defineProperty;
|
|
78929
79201
|
var __getOwnPropDesc$15 = Object.getOwnPropertyDescriptor;
|
|
78930
79202
|
var __defNormalProp$15 = (obj, key, value) => key in obj ? __defProp$16(obj, key, {
|
|
@@ -79177,30 +79449,33 @@ __publicField$15(SimpleNetworkStakeViewer, "dependencies", [
|
|
|
79177
79449
|
__publicField$15(SimpleNetworkStakeViewer, "monikers", [NetworkStakeViewerMoniker]);
|
|
79178
79450
|
__publicField$15(SimpleNetworkStakeViewer, "surface", "node");
|
|
79179
79451
|
SimpleNetworkStakeViewer = __decorateClass$15([creatableProvider()], SimpleNetworkStakeViewer);
|
|
79180
|
-
async function networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeEventsViewer, stepIdentity, position, rewardMultipliers = {}) {
|
|
79181
|
-
|
|
79182
|
-
|
|
79452
|
+
async function networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeEventsViewer, stepIdentity, position, rewardMultipliers = {}, timeAnchor) {
|
|
79453
|
+
const range = await externalBlockRangeFromStep(context, blockViewer, stepIdentity, timeAnchor);
|
|
79454
|
+
return await withContextCacheResponse(context, "networkStakeStepRewardEarnedForPosition", `${stepIdentity.block}|${stepIdentity.step}|${position.id}|${range[0]}-${range[1]}`, async () => {
|
|
79183
79455
|
const numerator = position.staked === "1969196919691969196919691969196919691969" ? await weightedStakeForRangeByPosition(context, blockViewer, stakeEventsViewer, range, XYO_NETWORK_STAKING_ADDRESS, position.id) : 0n;
|
|
79184
79456
|
const denominator = await weightedStakeForRangeByPosition(context, blockViewer, stakeEventsViewer, range);
|
|
79185
79457
|
const totalReward = await stepRewardTotal(context, blockViewer, stepIdentity, rewardMultipliers);
|
|
79186
79458
|
return [denominator > 0n ? totalReward * numerator / denominator : 0n, totalReward];
|
|
79187
79459
|
});
|
|
79188
79460
|
}
|
|
79189
|
-
async function networkStakeStepRewardEarned(context, blockViewer, stakeViewer, stepIdentity, rewardMultipliers = {}) {
|
|
79190
|
-
|
|
79461
|
+
async function networkStakeStepRewardEarned(context, blockViewer, stakeViewer, stepIdentity, rewardMultipliers = {}, timeAnchor) {
|
|
79462
|
+
const range = await externalBlockRangeFromStep(context, blockViewer, stepIdentity, timeAnchor);
|
|
79463
|
+
return await withContextCacheResponse(context, "networkStakeStepRewardEarned", `${stepIdentity.block}|${stepIdentity.step}|${range[0]}-${range[1]}`, async () => {
|
|
79191
79464
|
const positions = await stakeViewer.stakesByStaked(XYO_NETWORK_STAKING_ADDRESS);
|
|
79192
79465
|
const results = await Promise.all(positions.map((pos) => {
|
|
79193
|
-
return networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeViewer.stakeEvents, stepIdentity, pos, rewardMultipliers);
|
|
79466
|
+
return networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeViewer.stakeEvents, stepIdentity, pos, rewardMultipliers, timeAnchor);
|
|
79194
79467
|
}));
|
|
79195
79468
|
const numerator = results.reduce((acc, [positionReward]) => acc + positionReward, 0n);
|
|
79196
79469
|
return results.length > 0 ? [numerator, results[0][1]] : [0n, 0n];
|
|
79197
79470
|
});
|
|
79198
79471
|
}
|
|
79199
|
-
async function networkStakeStepRewardEarnedForStaker(context, blockViewer, stakeViewer, stepIdentity, staker, rewardMultipliers = {}) {
|
|
79200
|
-
|
|
79472
|
+
async function networkStakeStepRewardEarnedForStaker(context, blockViewer, stakeViewer, stepIdentity, staker, rewardMultipliers = {}, timeAnchor) {
|
|
79473
|
+
const stepId = toStepIdentityString(stepIdentity);
|
|
79474
|
+
const range = await externalBlockRangeFromStep(context, blockViewer, stepIdentity, timeAnchor);
|
|
79475
|
+
return await withContextCacheResponse(context, "networkStakeStepRewardEarnedForStaker", `${stepId}-${staker}-${range[0]}-${range[1]}`, async () => {
|
|
79201
79476
|
const positions = (await stakeViewer.stakesByStaker(staker)).filter((pos) => pos.staked === XYO_NETWORK_STAKING_ADDRESS);
|
|
79202
79477
|
const results = await Promise.all(positions.map((pos) => {
|
|
79203
|
-
return networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeViewer.stakeEvents, stepIdentity, pos, rewardMultipliers);
|
|
79478
|
+
return networkStakeStepRewardEarnedForPosition(context, blockViewer, stakeViewer.stakeEvents, stepIdentity, pos, rewardMultipliers, timeAnchor);
|
|
79204
79479
|
}));
|
|
79205
79480
|
const numerator = results.reduce((acc, [positionReward]) => acc + positionReward, 0n);
|
|
79206
79481
|
return results.length > 0 ? [numerator, results[0][1]] : [0n, 0n];
|
|
@@ -79214,6 +79489,9 @@ var SimpleStepRewardsByPositionViewer = class extends AbstractCreatableProvider
|
|
|
79214
79489
|
get rewardMultipliers() {
|
|
79215
79490
|
return this.params.rewardMultipliers ?? {};
|
|
79216
79491
|
}
|
|
79492
|
+
get timeAnchor() {
|
|
79493
|
+
return this.params.timeAnchor;
|
|
79494
|
+
}
|
|
79217
79495
|
get blockViewer() {
|
|
79218
79496
|
return this._blockViewer;
|
|
79219
79497
|
}
|
|
@@ -79275,7 +79553,7 @@ var SimpleStepRewardsByPositionViewer = class extends AbstractCreatableProvider
|
|
|
79275
79553
|
]);
|
|
79276
79554
|
for (const step of steps) if (isArray(positions)) for (const positionId of positions) {
|
|
79277
79555
|
const position = await this.stakeViewer.stakeById(positionId);
|
|
79278
|
-
const reward = await networkStakeStepRewardEarnedForPosition(this.context, this.blockViewer, this.stakeViewer.stakeEvents, step, position, rewardMultipliers);
|
|
79556
|
+
const reward = await networkStakeStepRewardEarnedForPosition(this.context, this.blockViewer, this.stakeViewer.stakeEvents, step, position, rewardMultipliers, this.timeAnchor);
|
|
79279
79557
|
result[positionId] = asAttoXL1((result[positionId] ?? 0n) + reward[0]);
|
|
79280
79558
|
}
|
|
79281
79559
|
return result;
|
|
@@ -79304,6 +79582,9 @@ var SimpleStepRewardsByStakerViewer = class extends AbstractCreatableProvider {
|
|
|
79304
79582
|
get rewardMultipliers() {
|
|
79305
79583
|
return this.params.rewardMultipliers ?? {};
|
|
79306
79584
|
}
|
|
79585
|
+
get timeAnchor() {
|
|
79586
|
+
return this.params.timeAnchor;
|
|
79587
|
+
}
|
|
79307
79588
|
get blockViewer() {
|
|
79308
79589
|
return this._blockViewer;
|
|
79309
79590
|
}
|
|
@@ -79354,7 +79635,7 @@ var SimpleStepRewardsByStakerViewer = class extends AbstractCreatableProvider {
|
|
|
79354
79635
|
7
|
|
79355
79636
|
]);
|
|
79356
79637
|
for (const step of steps) if (isArray(stakers)) for (const staker of stakers) {
|
|
79357
|
-
const reward = await networkStakeStepRewardEarnedForStaker(this.context, this.blockViewer, this.stakeViewer, step, staker, rewardMultipliers);
|
|
79638
|
+
const reward = await networkStakeStepRewardEarnedForStaker(this.context, this.blockViewer, this.stakeViewer, step, staker, rewardMultipliers, this.timeAnchor);
|
|
79358
79639
|
result[staker] = asAttoXL1((result[staker] ?? 0n) + reward[0]);
|
|
79359
79640
|
}
|
|
79360
79641
|
return result;
|
|
@@ -79383,6 +79664,9 @@ var SimpleStepRewardsByStepViewer = class extends AbstractCreatableProvider {
|
|
|
79383
79664
|
get rewardMultipliers() {
|
|
79384
79665
|
return this.params.rewardMultipliers ?? {};
|
|
79385
79666
|
}
|
|
79667
|
+
get timeAnchor() {
|
|
79668
|
+
return this.params.timeAnchor;
|
|
79669
|
+
}
|
|
79386
79670
|
get blockViewer() {
|
|
79387
79671
|
return this._blockViewer;
|
|
79388
79672
|
}
|
|
@@ -79425,7 +79709,7 @@ var SimpleStepRewardsByStepViewer = class extends AbstractCreatableProvider {
|
|
|
79425
79709
|
]);
|
|
79426
79710
|
for (const step of resolvedSteps) {
|
|
79427
79711
|
const stepIdentityString = toStepIdentityString(step);
|
|
79428
|
-
const reward = await networkStakeStepRewardEarned(this.context, this.blockViewer, this.stakeViewer, step);
|
|
79712
|
+
const reward = await networkStakeStepRewardEarned(this.context, this.blockViewer, this.stakeViewer, step, void 0, this.timeAnchor);
|
|
79429
79713
|
result[stepIdentityString] = asAttoXL1((result[stepIdentityString] ?? 0n) + reward[0]);
|
|
79430
79714
|
}
|
|
79431
79715
|
return result;
|
|
@@ -79442,7 +79726,7 @@ var SimpleStepRewardsByStepViewer = class extends AbstractCreatableProvider {
|
|
|
79442
79726
|
]);
|
|
79443
79727
|
for (const step of resolvedSteps) {
|
|
79444
79728
|
const stepIdentityString = toStepIdentityString(step);
|
|
79445
|
-
const reward = await networkStakeStepRewardEarned(this.context, this.blockViewer, this.stakeViewer, step, this.rewardMultipliers);
|
|
79729
|
+
const reward = await networkStakeStepRewardEarned(this.context, this.blockViewer, this.stakeViewer, step, this.rewardMultipliers, this.timeAnchor);
|
|
79446
79730
|
result[stepIdentityString] = asAttoXL1((result[stepIdentityString] ?? 0n) + reward[0]);
|
|
79447
79731
|
}
|
|
79448
79732
|
return result;
|
|
@@ -79561,6 +79845,9 @@ var SimpleStepViewer = class extends AbstractCreatableProvider {
|
|
|
79561
79845
|
get rewards() {
|
|
79562
79846
|
return this._networkStakeStepRewardsViewer;
|
|
79563
79847
|
}
|
|
79848
|
+
get timeAnchor() {
|
|
79849
|
+
return this.params.timeAnchor;
|
|
79850
|
+
}
|
|
79564
79851
|
get blockViewer() {
|
|
79565
79852
|
return this._blockViewer;
|
|
79566
79853
|
}
|
|
@@ -79578,12 +79865,12 @@ var SimpleStepViewer = class extends AbstractCreatableProvider {
|
|
|
79578
79865
|
this._stakeEventsViewer = await this.locator.getInstance(StakeEventsViewerMoniker);
|
|
79579
79866
|
}
|
|
79580
79867
|
async positionCount(step) {
|
|
79581
|
-
const externalRange = await externalBlockRangeFromStep(this.context, this.blockViewer, step);
|
|
79868
|
+
const externalRange = await externalBlockRangeFromStep(this.context, this.blockViewer, step, this.timeAnchor);
|
|
79582
79869
|
return await this.stakeEventsViewer.positionCount(externalRange);
|
|
79583
79870
|
}
|
|
79584
79871
|
async positions(step, _options) {
|
|
79585
79872
|
const count = await this.positionCount(step);
|
|
79586
|
-
const externalRange = await externalBlockRangeFromStep(this.context, this.blockViewer, step);
|
|
79873
|
+
const externalRange = await externalBlockRangeFromStep(this.context, this.blockViewer, step, this.timeAnchor);
|
|
79587
79874
|
return (await Promise.all(Array.from({ length: count + 1 }, (_, i) => i).map(async (id) => this.stakeViewer.stakeById(id)))).filter((pos) => pos.addBlock <= externalRange[1] && (pos.removeBlock === 0 || pos.removeBlock > externalRange[0]));
|
|
79588
79875
|
}
|
|
79589
79876
|
randomizer(_step) {
|
|
@@ -79630,6 +79917,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79630
79917
|
_networkStakeViewer;
|
|
79631
79918
|
_networkStepRewardsByPositionViewer;
|
|
79632
79919
|
_rewardMultipliers;
|
|
79920
|
+
_stakeTotalsViewer;
|
|
79633
79921
|
_stakeViewer;
|
|
79634
79922
|
_stepViewer;
|
|
79635
79923
|
_timeSyncViewer;
|
|
@@ -79655,6 +79943,9 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79655
79943
|
get stake() {
|
|
79656
79944
|
return this._stakeViewer;
|
|
79657
79945
|
}
|
|
79946
|
+
get stakeTotals() {
|
|
79947
|
+
return this._stakeTotalsViewer;
|
|
79948
|
+
}
|
|
79658
79949
|
get step() {
|
|
79659
79950
|
return this._stepViewer;
|
|
79660
79951
|
}
|
|
@@ -79677,6 +79968,9 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79677
79968
|
this._rewardMultipliers = this._rewardMultipliers ?? this.params.rewardMultipliers ?? {};
|
|
79678
79969
|
return this._rewardMultipliers;
|
|
79679
79970
|
}
|
|
79971
|
+
get timeAnchor() {
|
|
79972
|
+
return this.params.timeAnchor;
|
|
79973
|
+
}
|
|
79680
79974
|
async accountBalance(address, config = {}) {
|
|
79681
79975
|
return await this.account.balance.accountBalance(address, config);
|
|
79682
79976
|
}
|
|
@@ -79713,6 +80007,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79713
80007
|
this._networkStakeViewer = await this.locator.getInstance(NetworkStakeViewerMoniker);
|
|
79714
80008
|
this._networkStepRewardsByPositionViewer = await this.locator.getInstance(NetworkStakeStepRewardsByPositionViewerMoniker);
|
|
79715
80009
|
this._stakeViewer = await this.locator.getInstance(StakeViewerMoniker);
|
|
80010
|
+
this._stakeTotalsViewer = await this.locator.tryGetInstance(StakeTotalsViewerMoniker);
|
|
79716
80011
|
this._stepViewer = await this.locator.getInstance(StepViewerMoniker);
|
|
79717
80012
|
this._timeSyncViewer = await this.locator.getInstance(TimeSyncViewerMoniker);
|
|
79718
80013
|
this._transaction = await this.locator.getInstance(TransactionViewerMoniker);
|
|
@@ -79745,7 +80040,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79745
80040
|
async networkStakeStepRewardForPosition(position, range) {
|
|
79746
80041
|
const cacheKey = `${position}|${range[0]}-${range[1]}`;
|
|
79747
80042
|
return await withContextCacheResponse(this.context, "SimpleXyoViewer:networkStakeStepRewardForPosition", cacheKey, async () => {
|
|
79748
|
-
const externalRange = await externalBlockRangeFromXL1BlockRange(this.context, this.block, range);
|
|
80043
|
+
const externalRange = await externalBlockRangeFromXL1BlockRange(this.context, this.block, range, "ethereum", this.timeAnchor);
|
|
79749
80044
|
if (await this.stake.stakeEvents.positionCount(externalRange) === 0) return [asAttoXL1(0n), asAttoXL1(0n)];
|
|
79750
80045
|
const steps = blockRangeSteps(range, [
|
|
79751
80046
|
3,
|
|
@@ -79762,9 +80057,10 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79762
80057
|
return await stepRewardTotal(this.context, this.block, stepContext, this.rewardMultipliers);
|
|
79763
80058
|
}
|
|
79764
80059
|
async networkStakeStepRewardForStepForPosition(stepIdentity, position) {
|
|
79765
|
-
const
|
|
80060
|
+
const stepIdentityString = toStepIdentityString(stepIdentity);
|
|
80061
|
+
const range = await externalBlockRangeFromStep(this.context, this.block, stepIdentity, this.timeAnchor);
|
|
80062
|
+
const cacheKey = `${stepIdentityString}|${position}|${range[0]}-${range[1]}`;
|
|
79766
80063
|
return await withContextCacheResponse(this.context, "SimpleXyoViewer:networkStakeStepRewardForStepForPosition", cacheKey, async () => {
|
|
79767
|
-
const range = await externalBlockRangeFromStep(this.context, this.block, stepIdentity);
|
|
79768
80064
|
const numerator = (await this.stakeById(position)).staked === "1969196919691969196919691969196919691969" ? await weightedStakeForRangeByPosition(this.context, this.block, this.stake.stakeEvents, range, XYO_NETWORK_STAKING_ADDRESS, position) : 0n;
|
|
79769
80065
|
const denominator = await this.stepWeightedDenominator(stepIdentity);
|
|
79770
80066
|
const totalReward = await this.networkStakeStepRewardForStep(stepIdentity);
|
|
@@ -79783,7 +80079,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79783
80079
|
throw new Error("Method [networkStakeStepRewardPoolShares] not implemented.");
|
|
79784
80080
|
}
|
|
79785
80081
|
async networkStakeStepRewardPositionWeight(stepContext, position) {
|
|
79786
|
-
return await networkStakeStepRewardPositionWeight(this.context, this.block, this.stake.stakeEvents, stepContext, position);
|
|
80082
|
+
return await networkStakeStepRewardPositionWeight(this.context, this.block, this.stake.stakeEvents, stepContext, position, this.timeAnchor);
|
|
79787
80083
|
}
|
|
79788
80084
|
networkStakeStepRewardPotentialPositionLoss(_context, _position) {
|
|
79789
80085
|
throw new Error("Method [networkStakeStepRewardPotentialPositionLoss] not implemented.");
|
|
@@ -79792,7 +80088,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79792
80088
|
throw new Error("Method [networkStakeStepRewardRandomizer] not implemented.");
|
|
79793
80089
|
}
|
|
79794
80090
|
async networkStakeStepRewardStakerCount(stepContext) {
|
|
79795
|
-
return Object.keys(await allStakersForStep(this.context, this.block, this.stake.stakeEvents, stepContext, XYO_NETWORK_STAKING_ADDRESS)).length;
|
|
80091
|
+
return Object.keys(await allStakersForStep(this.context, this.block, this.stake.stakeEvents, stepContext, XYO_NETWORK_STAKING_ADDRESS, this.timeAnchor)).length;
|
|
79796
80092
|
}
|
|
79797
80093
|
networkStakeStepRewardUnclaimedByAddress(_address) {
|
|
79798
80094
|
throw new Error("Method [networkStakeStepRewardUnclaimedByAddress] not implemented.");
|
|
@@ -79889,7 +80185,7 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79889
80185
|
const currentBlockNumber = await this.currentBlockNumber();
|
|
79890
80186
|
await this.account.balance.accountBalance(XYO_ZERO_ADDRESS);
|
|
79891
80187
|
if (this.initRewardsCache) {
|
|
79892
|
-
const externalRange = await externalBlockRangeFromXL1BlockRange(this.context, this.block, asXL1BlockRange([0, currentBlockNumber], { name: "startHandler" }));
|
|
80188
|
+
const externalRange = await externalBlockRangeFromXL1BlockRange(this.context, this.block, asXL1BlockRange([0, currentBlockNumber], { name: "startHandler" }), "ethereum", this.timeAnchor);
|
|
79893
80189
|
const positionCount = await this.stake.stakeEvents.positionCount(externalRange);
|
|
79894
80190
|
this.logger?.debug(`SimpleXyoViewer: Precomputing networkStakeStepRewardForPosition up to position ${positionCount - 1}`);
|
|
79895
80191
|
const positions = Array.from({ length: positionCount }, (_, i) => i);
|
|
@@ -79907,9 +80203,9 @@ var SimpleXyoViewer = class extends AbstractCreatableProvider {
|
|
|
79907
80203
|
}
|
|
79908
80204
|
}
|
|
79909
80205
|
async stepWeightedDenominator(stepIdentity, staked) {
|
|
79910
|
-
const
|
|
80206
|
+
const range = await externalBlockRangeFromStep(this.context, this.block, stepIdentity, this.timeAnchor);
|
|
80207
|
+
const cacheKey = `${toStepIdentityString(stepIdentity)}|${staked ?? "all"}|${range[0]}-${range[1]}`;
|
|
79911
80208
|
return await withContextCacheResponse(this.context, "NodeXyoViewer-networkStakeStepRewardForStepForPosition-denominator", cacheKey, async () => {
|
|
79912
|
-
const range = await externalBlockRangeFromStep(this.context, this.block, stepIdentity);
|
|
79913
80209
|
return await weightedStakeForRangeByPosition(this.context, this.block, this.stake.stakeEvents, range, staked);
|
|
79914
80210
|
});
|
|
79915
80211
|
}
|
|
@@ -79936,7 +80232,7 @@ __publicField$15(SimpleXyoViewer, "monikers", [XyoViewerMoniker]);
|
|
|
79936
80232
|
__publicField$15(SimpleXyoViewer, "surface", "node");
|
|
79937
80233
|
SimpleXyoViewer = __decorateClass$15([creatableProvider()], SimpleXyoViewer);
|
|
79938
80234
|
//#endregion
|
|
79939
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.0.
|
|
80235
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-sdk@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@m_aad5bbdc21fd24569e1a5d6955015da4/node_modules/@xyo-network/xl1-sdk/dist/neutral/wrappers.mjs
|
|
79940
80236
|
function parseHexOrBigInt(value) {
|
|
79941
80237
|
return AttoXL1(typeof value === "bigint" ? value : hexToBigInt(value));
|
|
79942
80238
|
}
|
|
@@ -99843,17 +100139,56 @@ var __decorateClass$14 = (decorators, target, key, kind) => {
|
|
|
99843
100139
|
return result;
|
|
99844
100140
|
};
|
|
99845
100141
|
var __publicField$14 = (obj, key, value) => __defNormalProp$14(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
100142
|
+
function blockRangeChunks(fromBlock, toBlock, chunkSize) {
|
|
100143
|
+
if (!Number.isInteger(chunkSize) || chunkSize < 1) throw new TypeError(`chunkSize must be an integer >= 1, got ${chunkSize}`);
|
|
100144
|
+
if (!Number.isFinite(fromBlock) || !Number.isFinite(toBlock)) throw new TypeError(`fromBlock and toBlock must be finite numbers, got [${fromBlock}, ${toBlock}]`);
|
|
100145
|
+
if (fromBlock > toBlock) return [];
|
|
100146
|
+
const chunks = [];
|
|
100147
|
+
for (let start = fromBlock; start <= toBlock; start += chunkSize) {
|
|
100148
|
+
const end = Math.min(start + chunkSize - 1, toBlock);
|
|
100149
|
+
chunks.push([start, end]);
|
|
100150
|
+
}
|
|
100151
|
+
return chunks;
|
|
100152
|
+
}
|
|
100153
|
+
var DEFAULT_ESTIMATE_BLOCK_DATE = new Date(Date.UTC(2025, 5, 1));
|
|
100154
|
+
function estimateBlockNumberFromHead(headNumber, headTimestampSec, targetDate = DEFAULT_ESTIMATE_BLOCK_DATE, avgBlockTimeSec = 12) {
|
|
100155
|
+
const targetTimestampSec = Math.floor(targetDate.getTime() / 1e3);
|
|
100156
|
+
if (targetTimestampSec >= headTimestampSec) return headNumber;
|
|
100157
|
+
const blocksBack = Math.ceil((headTimestampSec - targetTimestampSec) / avgBlockTimeSec);
|
|
100158
|
+
return Math.max(0, headNumber - blocksBack);
|
|
100159
|
+
}
|
|
100160
|
+
async function estimateBlockNumberAt(provider, targetDate = DEFAULT_ESTIMATE_BLOCK_DATE, avgBlockTimeSec = 12) {
|
|
100161
|
+
const head = assertEx$1(await provider.getBlock("latest"), () => /* @__PURE__ */ new Error("Failed to get latest eth block"));
|
|
100162
|
+
return estimateBlockNumberFromHead(head.number, head.timestamp, targetDate, avgBlockTimeSec);
|
|
100163
|
+
}
|
|
99846
100164
|
var AbstractEvmProvider = class extends AbstractCreatableProvider {
|
|
99847
100165
|
_contract;
|
|
100166
|
+
_address;
|
|
100167
|
+
get address() {
|
|
100168
|
+
return assertEx$1(this._address, () => "EVM contract address not initialized");
|
|
100169
|
+
}
|
|
99848
100170
|
get contract() {
|
|
99849
100171
|
return this._contract;
|
|
99850
100172
|
}
|
|
99851
100173
|
async createHandler() {
|
|
99852
100174
|
await super.createHandler();
|
|
99853
|
-
this.
|
|
100175
|
+
this._address = this.params.address ?? toEthAddress(assertEx$1(this.config?.chain?.id, () => "EVM provider requires an address param or config.chain.id"));
|
|
100176
|
+
this._contract = this.connectContract(this._address);
|
|
100177
|
+
}
|
|
100178
|
+
};
|
|
100179
|
+
var AbstractEvmViewer = class extends AbstractEvmProvider {
|
|
100180
|
+
_provider;
|
|
100181
|
+
get provider() {
|
|
100182
|
+
return assertEx$1(this.params.provider ?? this._provider, () => "EVM provider not initialized");
|
|
100183
|
+
}
|
|
100184
|
+
async createHandler() {
|
|
100185
|
+
if (this.params.provider === void 0) {
|
|
100186
|
+
const evmChainViewer = await this.locateAndCreate(EvmChainViewerMoniker);
|
|
100187
|
+
this._provider = await evmChainViewer.provider();
|
|
100188
|
+
}
|
|
100189
|
+
await super.createHandler();
|
|
99854
100190
|
}
|
|
99855
100191
|
};
|
|
99856
|
-
var AbstractEvmViewer = class extends AbstractEvmProvider {};
|
|
99857
100192
|
var AbstractEvmRunner = class extends AbstractEvmViewer {
|
|
99858
100193
|
static async paramsHandler(params) {
|
|
99859
100194
|
const runner = assertEx$1(params?.runner, () => /* @__PURE__ */ new Error("No runner defined"));
|
|
@@ -99876,11 +100211,8 @@ var EvmChainContractViewer = class extends AbstractEvmViewer {
|
|
|
99876
100211
|
_minWithdrawalBlocks;
|
|
99877
100212
|
_rewardsContract;
|
|
99878
100213
|
_stakingTokenAddress;
|
|
99879
|
-
get address() {
|
|
99880
|
-
return this.params.address;
|
|
99881
|
-
}
|
|
99882
100214
|
chainId() {
|
|
99883
|
-
return toHex(this.
|
|
100215
|
+
return toHex(this.address, { prefix: false });
|
|
99884
100216
|
}
|
|
99885
100217
|
async chainIdAtBlockNumber(blockNumber) {
|
|
99886
100218
|
return await withContextCacheResponse(this.context, "chainIdAtBlockNumber", String(blockNumber), async () => {
|
|
@@ -99915,7 +100247,8 @@ var EvmChainContractViewer = class extends AbstractEvmViewer {
|
|
|
99915
100247
|
const address = await this.forkedChainId();
|
|
99916
100248
|
return EvmChainContractViewer.create({
|
|
99917
100249
|
...this.params,
|
|
99918
|
-
address: toEthAddress(address)
|
|
100250
|
+
address: toEthAddress(address),
|
|
100251
|
+
provider: this.provider
|
|
99919
100252
|
});
|
|
99920
100253
|
})();
|
|
99921
100254
|
return await this._forkedChainContractViewer;
|
|
@@ -99943,12 +100276,12 @@ var EvmChainContractViewer = class extends AbstractEvmViewer {
|
|
|
99943
100276
|
return await this._stakingTokenAddress;
|
|
99944
100277
|
}
|
|
99945
100278
|
connectContract(address) {
|
|
99946
|
-
return IStakedXyoChain__factory.connect(address, this.
|
|
100279
|
+
return IStakedXyoChain__factory.connect(address, this.provider);
|
|
99947
100280
|
}
|
|
99948
100281
|
};
|
|
99949
100282
|
__publicField$14(EvmChainContractViewer, "connectionTypes", ["evm-rpc"]);
|
|
99950
100283
|
__publicField$14(EvmChainContractViewer, "defaultMoniker", ChainContractViewerMoniker);
|
|
99951
|
-
__publicField$14(EvmChainContractViewer, "dependencies", []);
|
|
100284
|
+
__publicField$14(EvmChainContractViewer, "dependencies", [EvmChainViewerMoniker]);
|
|
99952
100285
|
__publicField$14(EvmChainContractViewer, "monikers", [ChainContractViewerMoniker]);
|
|
99953
100286
|
__publicField$14(EvmChainContractViewer, "surface", "node");
|
|
99954
100287
|
EvmChainContractViewer = __decorateClass$14([creatableProvider()], EvmChainContractViewer);
|
|
@@ -100000,15 +100333,81 @@ var EvmStakeTotalsViewer = class extends AbstractEvmViewer {
|
|
|
100000
100333
|
return await this.contract.withdrawnByStaker(getAddress(staker));
|
|
100001
100334
|
}
|
|
100002
100335
|
connectContract(address) {
|
|
100003
|
-
return IStakedXyoChain__factory.connect(address, this.
|
|
100336
|
+
return IStakedXyoChain__factory.connect(address, this.provider);
|
|
100004
100337
|
}
|
|
100005
100338
|
};
|
|
100006
100339
|
__publicField$14(EvmStakeTotalsViewer, "connectionTypes", ["evm-rpc"]);
|
|
100007
100340
|
__publicField$14(EvmStakeTotalsViewer, "defaultMoniker", StakeTotalsViewerMoniker);
|
|
100008
|
-
__publicField$14(EvmStakeTotalsViewer, "dependencies", []);
|
|
100341
|
+
__publicField$14(EvmStakeTotalsViewer, "dependencies", [EvmChainViewerMoniker]);
|
|
100009
100342
|
__publicField$14(EvmStakeTotalsViewer, "monikers", [StakeTotalsViewerMoniker]);
|
|
100010
100343
|
__publicField$14(EvmStakeTotalsViewer, "surface", "node");
|
|
100011
100344
|
EvmStakeTotalsViewer = __decorateClass$14([creatableProvider()], EvmStakeTotalsViewer);
|
|
100345
|
+
function isRpcRateLimitError(error) {
|
|
100346
|
+
const seen = /* @__PURE__ */ new Set();
|
|
100347
|
+
const queue = [error];
|
|
100348
|
+
while (queue.length > 0) {
|
|
100349
|
+
const current = queue.pop();
|
|
100350
|
+
if (current === void 0 || current === null || seen.has(current)) continue;
|
|
100351
|
+
seen.add(current);
|
|
100352
|
+
if (typeof current === "string") {
|
|
100353
|
+
if (matchesRateLimitText(current)) return true;
|
|
100354
|
+
continue;
|
|
100355
|
+
}
|
|
100356
|
+
if (typeof current === "number") {
|
|
100357
|
+
if (isRateLimitCode(current)) return true;
|
|
100358
|
+
continue;
|
|
100359
|
+
}
|
|
100360
|
+
if (typeof current !== "object") continue;
|
|
100361
|
+
if (Array.isArray(current)) {
|
|
100362
|
+
const items = current;
|
|
100363
|
+
queue.push(...items);
|
|
100364
|
+
continue;
|
|
100365
|
+
}
|
|
100366
|
+
const record = current;
|
|
100367
|
+
for (const key of [
|
|
100368
|
+
"code",
|
|
100369
|
+
"message",
|
|
100370
|
+
"shortMessage",
|
|
100371
|
+
"reason",
|
|
100372
|
+
"status",
|
|
100373
|
+
"statusCode"
|
|
100374
|
+
]) if (key in record) queue.push(record[key]);
|
|
100375
|
+
for (const key of [
|
|
100376
|
+
"error",
|
|
100377
|
+
"info",
|
|
100378
|
+
"data",
|
|
100379
|
+
"value",
|
|
100380
|
+
"body",
|
|
100381
|
+
"payload"
|
|
100382
|
+
]) if (key in record) queue.push(record[key]);
|
|
100383
|
+
}
|
|
100384
|
+
return false;
|
|
100385
|
+
}
|
|
100386
|
+
function isRateLimitCode(code) {
|
|
100387
|
+
return code === 429 || code === -32005 || code === -32007 || code === -32016;
|
|
100388
|
+
}
|
|
100389
|
+
function matchesRateLimitText(text) {
|
|
100390
|
+
const normalized = text.toLowerCase();
|
|
100391
|
+
return normalized.includes("too many requests") || normalized.includes("rate limit") || normalized.includes("rate exceeded") || normalized.includes("call rate limit") || normalized.includes("request limit") || normalized.includes("exceeded the quota");
|
|
100392
|
+
}
|
|
100393
|
+
async function withRpcRateLimitBackoff(fn, options = {}) {
|
|
100394
|
+
const { backoff = 2, initialDelayMs = 1e3, maxAttempts = 8, maxDelayMs = 3e4, onRetry } = options;
|
|
100395
|
+
if (!Number.isInteger(maxAttempts) || maxAttempts < 1) throw new TypeError(`maxAttempts must be an integer >= 1, got ${maxAttempts}`);
|
|
100396
|
+
let delayMs = initialDelayMs;
|
|
100397
|
+
let lastError;
|
|
100398
|
+
for (let attempt = 1; attempt <= maxAttempts; attempt++) try {
|
|
100399
|
+
return await fn();
|
|
100400
|
+
} catch (error) {
|
|
100401
|
+
lastError = error;
|
|
100402
|
+
const isLastAttempt = attempt >= maxAttempts;
|
|
100403
|
+
if (!isRpcRateLimitError(error) || isLastAttempt) throw error;
|
|
100404
|
+
const waitMs = Math.min(delayMs, maxDelayMs);
|
|
100405
|
+
onRetry?.(error, attempt, waitMs);
|
|
100406
|
+
await delay$1(waitMs);
|
|
100407
|
+
delayMs = Math.min(delayMs * backoff, maxDelayMs);
|
|
100408
|
+
}
|
|
100409
|
+
throw lastError;
|
|
100410
|
+
}
|
|
100012
100411
|
var EthHashRegEx = HexRegExMinMaxMixedCaseWithPrefix(32, 32);
|
|
100013
100412
|
var EthHashZod = (/* @__PURE__ */ string$3()).check(/* @__PURE__ */ _regex(EthHashRegEx, { error: "Invalid address format" }));
|
|
100014
100413
|
var EvmStakeAddedEventNameZod = /* @__PURE__ */ literal$2("StakeAdded");
|
|
@@ -100038,9 +100437,20 @@ zodToFactory(/* @__PURE__ */ extend(EvmStakeEventZod, { eventName: EvmStakeRemov
|
|
|
100038
100437
|
zodToFactory(/* @__PURE__ */ extend(EvmStakeEventZod, { eventName: EvmStakeWithdrawnEventNameZod }), "toEvmStakeWithdrawnEvent");
|
|
100039
100438
|
var EvmStakeEventsViewer = class extends AbstractEvmViewer {
|
|
100040
100439
|
moniker = EvmStakeEventsViewer.defaultMoniker;
|
|
100440
|
+
/** Set at start when `params.deploymentBlock` is omitted (estimated 2025-06-01). */
|
|
100441
|
+
defaultDeploymentBlock = 0;
|
|
100041
100442
|
eventCache = /* @__PURE__ */ new Map();
|
|
100042
100443
|
get deploymentBlock() {
|
|
100043
|
-
return this.params.deploymentBlock ??
|
|
100444
|
+
return this.params.deploymentBlock ?? this.defaultDeploymentBlock;
|
|
100445
|
+
}
|
|
100446
|
+
get eventQueryBlockChunkSize() {
|
|
100447
|
+
return this.params.eventQueryBlockChunkSize ?? 2e3;
|
|
100448
|
+
}
|
|
100449
|
+
get eventQueryInitialDelayMs() {
|
|
100450
|
+
return this.params.eventQueryInitialDelayMs ?? 1e3;
|
|
100451
|
+
}
|
|
100452
|
+
get eventQueryMaxAttempts() {
|
|
100453
|
+
return this.params.eventQueryMaxAttempts ?? 8;
|
|
100044
100454
|
}
|
|
100045
100455
|
async positionCount(range) {
|
|
100046
100456
|
const positionIds = (await this.stakeEvents(range)).map((e) => e.args.id);
|
|
@@ -100058,7 +100468,7 @@ var EvmStakeEventsViewer = class extends AbstractEvmViewer {
|
|
|
100058
100468
|
});
|
|
100059
100469
|
}
|
|
100060
100470
|
connectContract(address) {
|
|
100061
|
-
return IAddressStakingEvents__factory2.connect(address, this.
|
|
100471
|
+
return IAddressStakingEvents__factory2.connect(address, this.provider);
|
|
100062
100472
|
}
|
|
100063
100473
|
onEventHandler(staked, staker, id, amount, event, throwOnInvalid = false) {
|
|
100064
100474
|
const validatedEventResult = EvmStakeEventZod.safeParse(event);
|
|
@@ -100069,9 +100479,7 @@ var EvmStakeEventsViewer = class extends AbstractEvmViewer {
|
|
|
100069
100479
|
return;
|
|
100070
100480
|
}
|
|
100071
100481
|
const { eventName, blockNumber } = validatedEventResult.data;
|
|
100072
|
-
this.logger?.log(`Processing ${eventName} event for stake ID ${id} at block ${blockNumber}`);
|
|
100073
100482
|
const cacheKey = `${Number(id)}|${eventName}|${staker}`;
|
|
100074
|
-
const existingStakeEvent = this.eventCache.get(cacheKey);
|
|
100075
100483
|
const stakeEvent = {
|
|
100076
100484
|
name: eventName,
|
|
100077
100485
|
args: {
|
|
@@ -100082,63 +100490,80 @@ var EvmStakeEventsViewer = class extends AbstractEvmViewer {
|
|
|
100082
100490
|
},
|
|
100083
100491
|
time: blockNumber
|
|
100084
100492
|
};
|
|
100085
|
-
if (isDefined$1(existingStakeEvent)) {
|
|
100086
|
-
this.logger?.warn(`Received ${eventName} event for stake ID ${id} that is already cached, updating cache...`);
|
|
100087
|
-
this.logger?.warn("1");
|
|
100088
|
-
this.logger?.warn("Previous event", existingStakeEvent);
|
|
100089
|
-
this.logger?.warn("2");
|
|
100090
|
-
this.logger?.warn("New event", stakeEvent);
|
|
100091
|
-
this.logger?.warn("3");
|
|
100092
|
-
}
|
|
100093
100493
|
this.eventCache.set(cacheKey, stakeEvent);
|
|
100094
100494
|
return stakeEvent;
|
|
100095
100495
|
}
|
|
100096
100496
|
async startHandler() {
|
|
100097
100497
|
try {
|
|
100098
|
-
const
|
|
100099
|
-
await
|
|
100100
|
-
|
|
100101
|
-
|
|
100102
|
-
await this.
|
|
100103
|
-
|
|
100104
|
-
|
|
100105
|
-
await this.contract.on(this.contract.getEvent("StakeWithdrawn"), (staked, staker, id, amount, event) => {
|
|
100106
|
-
this.onEventHandler(staked, staker, id, amount, event);
|
|
100107
|
-
});
|
|
100108
|
-
await this.loadHistoricalEvents(currentEthBlock);
|
|
100498
|
+
const provider = assertEx$1(this.contract.runner?.provider, () => /* @__PURE__ */ new Error("Failed to get provider"));
|
|
100499
|
+
const historyEndBlock = assertEx$1(await provider.getBlockNumber(), () => /* @__PURE__ */ new Error("Failed to get currentEthBlock"));
|
|
100500
|
+
if (!isDefined$1(this.params.deploymentBlock)) this.defaultDeploymentBlock = await estimateBlockNumberAt(provider);
|
|
100501
|
+
await this.loadHistoricalEvents(this.deploymentBlock, historyEndBlock);
|
|
100502
|
+
await this.attachLiveListeners();
|
|
100503
|
+
const latestBlock = assertEx$1(await provider.getBlockNumber(), () => /* @__PURE__ */ new Error("Failed to get latestEthBlock"));
|
|
100504
|
+
if (latestBlock > historyEndBlock) await this.loadHistoricalEvents(historyEndBlock + 1, latestBlock);
|
|
100109
100505
|
} catch (error) {
|
|
100110
100506
|
this.logger?.error("EthereumChainStakeEvents failed to start:", error);
|
|
100111
100507
|
throw error;
|
|
100112
100508
|
}
|
|
100113
100509
|
}
|
|
100114
|
-
async
|
|
100510
|
+
async attachLiveListeners() {
|
|
100511
|
+
await this.contract.on(this.contract.getEvent("StakeAdded"), (staked, staker, id, amount, event) => {
|
|
100512
|
+
this.onEventHandler(staked, staker, id, amount, event);
|
|
100513
|
+
});
|
|
100514
|
+
await this.contract.on(this.contract.getEvent("StakeRemoved"), (staked, staker, id, amount, event) => {
|
|
100515
|
+
this.onEventHandler(staked, staker, id, amount, event);
|
|
100516
|
+
});
|
|
100517
|
+
await this.contract.on(this.contract.getEvent("StakeWithdrawn"), (staked, staker, id, amount, event) => {
|
|
100518
|
+
this.onEventHandler(staked, staker, id, amount, event);
|
|
100519
|
+
});
|
|
100520
|
+
}
|
|
100521
|
+
async loadHistoricalEvents(fromBlock, toBlock) {
|
|
100522
|
+
if (fromBlock > toBlock) return;
|
|
100115
100523
|
const allStakeEvents = (await Promise.all([
|
|
100116
|
-
this.stakeEventsNative([
|
|
100117
|
-
this.stakeEventsNative([
|
|
100118
|
-
this.stakeEventsNative([
|
|
100524
|
+
this.stakeEventsNative([fromBlock, toBlock], { name: "StakeAdded" }),
|
|
100525
|
+
this.stakeEventsNative([fromBlock, toBlock], { name: "StakeRemoved" }),
|
|
100526
|
+
this.stakeEventsNative([fromBlock, toBlock], { name: "StakeWithdrawn" })
|
|
100119
100527
|
])).flat().toSorted((a, b) => a.time - b.time);
|
|
100120
|
-
|
|
100528
|
+
const chunks = blockRangeChunks(fromBlock, toBlock, this.eventQueryBlockChunkSize);
|
|
100529
|
+
this.logger?.log(`Cached ${allStakeEvents.length} stake events from blocks ${fromBlock}-${toBlock} (${chunks.length} chunk(s) of up to ${this.eventQueryBlockChunkSize} blocks)`);
|
|
100121
100530
|
for (const event of allStakeEvents) this.eventCache.set(`${Number(event.args.id)}|${event.name}|${event.args.staker}`, event);
|
|
100122
100531
|
}
|
|
100123
100532
|
async stakeEventsNative(range = [0, "latest"], filter) {
|
|
100124
100533
|
const name = filter?.name;
|
|
100125
|
-
if (isDefined$1(name))
|
|
100126
|
-
|
|
100127
|
-
|
|
100128
|
-
|
|
100129
|
-
|
|
100130
|
-
|
|
100131
|
-
|
|
100132
|
-
|
|
100133
|
-
|
|
100134
|
-
|
|
100534
|
+
if (!isDefined$1(name)) throw new Error("Only filtered stake events (by name) are supported");
|
|
100535
|
+
const stakedFilter = filter?.args?.staked;
|
|
100536
|
+
const stakerFilter = filter?.args?.staker;
|
|
100537
|
+
const stakedFilterEth = isDefined$1(stakedFilter) ? toEthAddress(stakedFilter) : void 0;
|
|
100538
|
+
const stakerFilterEth = isDefined$1(stakerFilter) ? toEthAddress(stakerFilter) : void 0;
|
|
100539
|
+
const ethFilter = this.contract.filters[name](stakedFilterEth, stakerFilterEth);
|
|
100540
|
+
const fromBlock = range[0];
|
|
100541
|
+
const toBlock = range[1] === "latest" ? assertEx$1(await this.contract.runner?.provider?.getBlockNumber(), () => /* @__PURE__ */ new Error("Failed to resolve latest block")) : range[1];
|
|
100542
|
+
if (fromBlock > toBlock) return [];
|
|
100543
|
+
const chunkSize = this.eventQueryBlockChunkSize;
|
|
100544
|
+
const chunks = blockRangeChunks(fromBlock, toBlock, chunkSize);
|
|
100545
|
+
const ethEventGroups = [];
|
|
100546
|
+
for (const [chunkFrom, chunkTo] of chunks) try {
|
|
100547
|
+
ethEventGroups.push(await withRpcRateLimitBackoff(() => this.contract.queryFilter(ethFilter, chunkFrom, chunkTo), {
|
|
100548
|
+
initialDelayMs: this.eventQueryInitialDelayMs,
|
|
100549
|
+
maxAttempts: this.eventQueryMaxAttempts,
|
|
100550
|
+
onRetry: (_error, attempt, delayMs) => {
|
|
100551
|
+
this.logger?.warn(`Rate limited fetching ${name} logs for blocks ${chunkFrom}-${chunkTo} (attempt ${attempt}/${this.eventQueryMaxAttempts}); backing off ${delayMs}ms`);
|
|
100552
|
+
}
|
|
100553
|
+
}));
|
|
100554
|
+
} catch (error) {
|
|
100555
|
+
this.logger?.error(`eth_getLogs failed for ${name} blocks ${chunkFrom}-${chunkTo} after rate-limit retries (from=${fromBlock} to=${toBlock}):`, error);
|
|
100556
|
+
throw error;
|
|
100135
100557
|
}
|
|
100136
|
-
|
|
100558
|
+
return ethEventGroups.flat().map((e) => {
|
|
100559
|
+
assertEx$1(e.eventName === name, () => `Event name mismatch expected '${name}' but got '${e.eventName}'`);
|
|
100560
|
+
return this.onEventHandler(e.args.staked, e.args.by, e.args.id, e.args.amount, e, true);
|
|
100561
|
+
}).filter(exists$1);
|
|
100137
100562
|
}
|
|
100138
100563
|
};
|
|
100139
100564
|
__publicField$14(EvmStakeEventsViewer, "connectionTypes", ["evm-rpc"]);
|
|
100140
100565
|
__publicField$14(EvmStakeEventsViewer, "defaultMoniker", StakeEventsViewerMoniker);
|
|
100141
|
-
__publicField$14(EvmStakeEventsViewer, "dependencies", []);
|
|
100566
|
+
__publicField$14(EvmStakeEventsViewer, "dependencies", [EvmChainViewerMoniker]);
|
|
100142
100567
|
__publicField$14(EvmStakeEventsViewer, "monikers", [StakeEventsViewerMoniker]);
|
|
100143
100568
|
__publicField$14(EvmStakeEventsViewer, "surface", "node");
|
|
100144
100569
|
EvmStakeEventsViewer = __decorateClass$14([creatableProvider()], EvmStakeEventsViewer);
|
|
@@ -100183,6 +100608,7 @@ var EvmStakeViewer = class extends AbstractEvmViewer {
|
|
|
100183
100608
|
async createHandler() {
|
|
100184
100609
|
await super.createHandler();
|
|
100185
100610
|
this._stakeEventsViewer = await this.locator.getInstance(StakeEventsViewerMoniker);
|
|
100611
|
+
this._deploymentBlock = isDefined$1(this.params.deploymentBlock) ? this.params.deploymentBlock : await estimateBlockNumberAt(this.provider);
|
|
100186
100612
|
}
|
|
100187
100613
|
minWithdrawalBlocks() {
|
|
100188
100614
|
return 0;
|
|
@@ -100256,7 +100682,7 @@ var EvmStakeViewer = class extends AbstractEvmViewer {
|
|
|
100256
100682
|
return this._stakeCache.values().filter((stake) => stake.removeBlock !== 0 && stake.withdrawBlock !== 0).toArray();
|
|
100257
100683
|
}
|
|
100258
100684
|
connectContract(address) {
|
|
100259
|
-
return IAddressStaking__factory2.connect(address, this.
|
|
100685
|
+
return IAddressStaking__factory2.connect(address, this.provider);
|
|
100260
100686
|
}
|
|
100261
100687
|
async startHandler() {
|
|
100262
100688
|
await this.contract.on(this.contract.getEvent("StakeAdded"), (staked, staker, id, amount, event) => {
|
|
@@ -100324,7 +100750,7 @@ var EvmStakeViewer = class extends AbstractEvmViewer {
|
|
|
100324
100750
|
};
|
|
100325
100751
|
__publicField$14(EvmStakeViewer, "connectionTypes", ["evm-rpc"]);
|
|
100326
100752
|
__publicField$14(EvmStakeViewer, "defaultMoniker", StakeViewerMoniker);
|
|
100327
|
-
__publicField$14(EvmStakeViewer, "dependencies", []);
|
|
100753
|
+
__publicField$14(EvmStakeViewer, "dependencies", [EvmChainViewerMoniker]);
|
|
100328
100754
|
__publicField$14(EvmStakeViewer, "monikers", [StakeViewerMoniker]);
|
|
100329
100755
|
__publicField$14(EvmStakeViewer, "surface", "node");
|
|
100330
100756
|
EvmStakeViewer = __decorateClass$14([creatableProvider()], EvmStakeViewer);
|
|
@@ -102173,7 +102599,7 @@ function initTelemetry(params) {
|
|
|
102173
102599
|
};
|
|
102174
102600
|
}
|
|
102175
102601
|
//#endregion
|
|
102176
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-
|
|
102602
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-s3-publishers@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_0fdd8c9bdedd28ec1152d8828c4ec1b5/node_modules/@xyo-network/xl1-s3-publishers/dist/node/index.mjs
|
|
102177
102603
|
var __defProp$11 = Object.defineProperty;
|
|
102178
102604
|
var __getOwnPropDesc$11 = Object.getOwnPropertyDescriptor;
|
|
102179
102605
|
var __defNormalProp$11 = (obj, key, value) => key in obj ? __defProp$11(obj, key, {
|
|
@@ -102471,6 +102897,34 @@ __publicField$11(S3ChainStateViewer, "defaultMoniker", ChainStateViewerMoniker);
|
|
|
102471
102897
|
__publicField$11(S3ChainStateViewer, "dependencies", []);
|
|
102472
102898
|
__publicField$11(S3ChainStateViewer, "monikers", [ChainStateViewerMoniker]);
|
|
102473
102899
|
S3ChainStateViewer = __decorateClass$11([creatableProvider()], S3ChainStateViewer);
|
|
102900
|
+
var S3DataLakePublishRunner = class extends AbstractS3Provider {
|
|
102901
|
+
moniker = S3DataLakePublishRunner.defaultMoniker;
|
|
102902
|
+
get allowedSchemas() {
|
|
102903
|
+
return this.params.allowedSchemas;
|
|
102904
|
+
}
|
|
102905
|
+
get concurrency() {
|
|
102906
|
+
return this.params.concurrency ?? 8;
|
|
102907
|
+
}
|
|
102908
|
+
get disallowedSchemas() {
|
|
102909
|
+
return this.params.disallowedSchemas;
|
|
102910
|
+
}
|
|
102911
|
+
async insert(items) {
|
|
102912
|
+
const allowedItems = items.filter((item) => isAnyPayload(item) && isSchemaAllowed(item.schema, this.allowedSchemas, this.disallowedSchemas));
|
|
102913
|
+
if (allowedItems.length === 0) return [];
|
|
102914
|
+
const payloads = await PayloadBuilder.addHashMeta(allowedItems);
|
|
102915
|
+
const semaphore = new Semaphore(this.concurrency);
|
|
102916
|
+
await Promise.all(payloads.map((payload) => semaphore.runExclusive(async () => {
|
|
102917
|
+
await this.putJson(payloadPath(payload._hash), JSON.stringify(payload), IMMUTABLE_CACHE_CONTROL);
|
|
102918
|
+
})));
|
|
102919
|
+
return payloads;
|
|
102920
|
+
}
|
|
102921
|
+
};
|
|
102922
|
+
__publicField$11(S3DataLakePublishRunner, "connectionTypes", ["s3"]);
|
|
102923
|
+
__publicField$11(S3DataLakePublishRunner, "defaultMoniker", DataLakePublishRunnerMoniker);
|
|
102924
|
+
__publicField$11(S3DataLakePublishRunner, "dependencies", []);
|
|
102925
|
+
__publicField$11(S3DataLakePublishRunner, "monikers", [DataLakePublishRunnerMoniker]);
|
|
102926
|
+
__publicField$11(S3DataLakePublishRunner, "surface", "node");
|
|
102927
|
+
S3DataLakePublishRunner = __decorateClass$11([creatableProvider()], S3DataLakePublishRunner);
|
|
102474
102928
|
var S3IndexSummaryMap = class {
|
|
102475
102929
|
family;
|
|
102476
102930
|
numberCache = /* @__PURE__ */ new Map();
|
|
@@ -102651,7 +103105,7 @@ __publicField$11(S3IndexPublishRunner, "dependencies", [BlockViewerMoniker]);
|
|
|
102651
103105
|
__publicField$11(S3IndexPublishRunner, "monikers", [IndexPublishRunnerMoniker]);
|
|
102652
103106
|
S3IndexPublishRunner = __decorateClass$11([creatableProvider()], S3IndexPublishRunner);
|
|
102653
103107
|
//#endregion
|
|
102654
|
-
//#region ../../node_modules/.pnpm/@xyo-network+archivist-lmdb@7.0.
|
|
103108
|
+
//#region ../../node_modules/.pnpm/@xyo-network+archivist-lmdb@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4._1302c86471ef8910822e1c573a811a1c/node_modules/@xyo-network/archivist-lmdb/dist/browser/index.mjs
|
|
102655
103109
|
var __defProp$10 = Object.defineProperty;
|
|
102656
103110
|
var __getOwnPropDesc$10 = Object.getOwnPropertyDescriptor;
|
|
102657
103111
|
var __getProtoOf = Object.getPrototypeOf;
|
|
@@ -102796,10 +103250,10 @@ __publicField$10(LmdbArchivist, "sequenceIndex", {
|
|
|
102796
103250
|
});
|
|
102797
103251
|
LmdbArchivist = __decorateClass$10([creatableModule()], LmdbArchivist);
|
|
102798
103252
|
//#endregion
|
|
102799
|
-
//#region ../../node_modules/.pnpm/@xyo-network+archivist-model-mongodb@7.0.
|
|
103253
|
+
//#region ../../node_modules/.pnpm/@xyo-network+archivist-model-mongodb@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9_f200200000a1a91f407eeb675f0d871c/node_modules/@xyo-network/archivist-model-mongodb/dist/node/index.mjs
|
|
102800
103254
|
var MongoDBArchivistConfigSchema = asSchema("network.xyo.archivist.mongodb.config", true);
|
|
102801
103255
|
//#endregion
|
|
102802
|
-
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.
|
|
103256
|
+
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3/node_modules/@ariestools/sdk/dist/neutral/assert.mjs
|
|
102803
103257
|
function assertEx(expr, func) {
|
|
102804
103258
|
if (expr !== void 0 && expr !== null && expr !== false && expr !== 0 && expr !== "" && expr !== 0n) return expr;
|
|
102805
103259
|
if (typeof func === "function") {
|
|
@@ -102810,7 +103264,7 @@ function assertEx(expr, func) {
|
|
|
102810
103264
|
throw new Error("Assertion failed");
|
|
102811
103265
|
}
|
|
102812
103266
|
//#endregion
|
|
102813
|
-
//#region ../../node_modules/.pnpm/@ariestools+mongo@8.0.3_@opentelemetry+api@1.9.1_@opentelemetry+sdk-trace-base@2.9.0_@
|
|
103267
|
+
//#region ../../node_modules/.pnpm/@ariestools+mongo@8.0.3_@opentelemetry+api@1.9.1_@opentelemetry+sdk-trace-base@2.9.0_@o_c82cb5c38cc6c6567596fa4cd8222cd9/node_modules/@ariestools/mongo/dist/node/index.mjs
|
|
102814
103268
|
var DEFAULT_CLOSE_DELAY_MS = 1e4;
|
|
102815
103269
|
var MongoClientWrapper = class _MongoClientWrapper {
|
|
102816
103270
|
/** Global cache of wrapper instances keyed by URI and pool options. */
|
|
@@ -103067,7 +103521,7 @@ var BaseMongoSdk = class {
|
|
|
103067
103521
|
}
|
|
103068
103522
|
};
|
|
103069
103523
|
//#endregion
|
|
103070
|
-
//#region ../../node_modules/.pnpm/@xyo-network+module-model-mongodb@7.0.
|
|
103524
|
+
//#region ../../node_modules/.pnpm/@xyo-network+module-model-mongodb@7.1.1_@ariestools+mongo@8.0.3_@opentelemetry+api@1.9._b8385d7bd70f374a936a515a0ac721a5/node_modules/@xyo-network/module-model-mongodb/dist/node/index.mjs
|
|
103071
103525
|
var MongoDBModuleConfigSchema = asSchema("network.xyo.module.mongodb.config", true);
|
|
103072
103526
|
zodToFactory(/* @__PURE__ */ extend(ModuleConfigZod, {
|
|
103073
103527
|
boundWitnessSdkConfig: /* @__PURE__ */ optional$2(/* @__PURE__ */ custom$1()),
|
|
@@ -103087,7 +103541,7 @@ zodToFactory(/* @__PURE__ */ extend(ModuleConfigZod, {
|
|
|
103087
103541
|
}), "toMongoDBModuleConfigV2");
|
|
103088
103542
|
var MongoDBStorageClassLabels = { "network.xyo.storage.class": "mongodb" };
|
|
103089
103543
|
//#endregion
|
|
103090
|
-
//#region ../../node_modules/.pnpm/@xyo-network+module-abstract-mongodb@7.0.
|
|
103544
|
+
//#region ../../node_modules/.pnpm/@xyo-network+module-abstract-mongodb@7.1.1_@ariestools+mongo@8.0.3_@opentelemetry+api@1_45cf0e6537de5d69d796d45fc57df364/node_modules/@xyo-network/module-abstract-mongodb/dist/node/index.mjs
|
|
103091
103545
|
var __defProp$9 = Object.defineProperty;
|
|
103092
103546
|
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
103093
103547
|
var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, {
|
|
@@ -103349,7 +103803,7 @@ var ensureExistingCollectionIsCapped = async (sdk, max, docSize = 1024) => {
|
|
|
103349
103803
|
});
|
|
103350
103804
|
};
|
|
103351
103805
|
//#endregion
|
|
103352
|
-
//#region ../../node_modules/.pnpm/@xyo-network+payload-mongodb@7.0.
|
|
103806
|
+
//#region ../../node_modules/.pnpm/@xyo-network+payload-mongodb@7.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4_209fc12f8041d6fbdbe40f85dee8e022/node_modules/@xyo-network/payload-mongodb/dist/node/index.mjs
|
|
103353
103807
|
function payloadFromDbRepresentation(value) {
|
|
103354
103808
|
const clone = structuredClone(value);
|
|
103355
103809
|
const metaNormalized = {};
|
|
@@ -103377,7 +103831,7 @@ var toDbRepresentation = (value) => {
|
|
|
103377
103831
|
return isBoundWitness(value) ? boundWitnessToDbRepresentation(value) : payloadToDbRepresentation(value);
|
|
103378
103832
|
};
|
|
103379
103833
|
//#endregion
|
|
103380
|
-
//#region ../../node_modules/.pnpm/@xyo-network+archivist-mongodb@7.0.
|
|
103834
|
+
//#region ../../node_modules/.pnpm/@xyo-network+archivist-mongodb@7.1.1_@ariestools+mongo@8.0.3_@opentelemetry+api@1.9.1_@_db6f4bc8a44d8b8baba44007b47f6920/node_modules/@xyo-network/archivist-mongodb/dist/node/index.mjs
|
|
103381
103835
|
var validByType = async (payloads = []) => {
|
|
103382
103836
|
const results = [[], []];
|
|
103383
103837
|
await Promise.all(payloads.map(async (payload) => {
|
|
@@ -103703,20 +104157,18 @@ var canUseJsonRpcProvider = (context) => {
|
|
|
103703
104157
|
};
|
|
103704
104158
|
var initJsonRpcProvider = (context) => {
|
|
103705
104159
|
const connection = assertEx$1(resolveEvmRpcConnection(context.config), () => "Missing connections.default-evm-rpc (type \"evm-rpc\")");
|
|
103706
|
-
const
|
|
103707
|
-
return Promise.resolve(
|
|
104160
|
+
const provider = connection.chainId === void 0 ? new JsonRpcProvider(connection.url) : new JsonRpcProvider(connection.url, parseChainId(connection.chainId));
|
|
104161
|
+
return Promise.resolve(provider);
|
|
103708
104162
|
};
|
|
103709
|
-
var provider;
|
|
103710
104163
|
var initEvmProvider = async (context) => {
|
|
103711
|
-
|
|
103712
|
-
|
|
103713
|
-
return assertEx$1(await provider, () => "No EVM provider available — declare connections.default-evm-rpc with type \"evm-rpc\"");
|
|
104164
|
+
assertEx$1(canUseJsonRpcProvider(context), () => "No EVM provider available — declare connections.default-evm-rpc with type \"evm-rpc\"");
|
|
104165
|
+
return await initJsonRpcProvider(context);
|
|
103714
104166
|
};
|
|
103715
104167
|
var canUseEvmProvider = (context) => {
|
|
103716
104168
|
return canUseJsonRpcProvider(context);
|
|
103717
104169
|
};
|
|
103718
104170
|
//#endregion
|
|
103719
|
-
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.
|
|
104171
|
+
//#region ../../node_modules/.pnpm/@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3/node_modules/@ariestools/sdk/dist/neutral/typeof.mjs
|
|
103720
104172
|
function isUndefined(value) {
|
|
103721
104173
|
return value === void 0;
|
|
103722
104174
|
}
|
|
@@ -107158,7 +107610,11 @@ var require__stream_readable = /* @__PURE__ */ __commonJSMin(((exports, module)
|
|
|
107158
107610
|
var BufferList = require_buffer_list();
|
|
107159
107611
|
var destroyImpl = require_destroy();
|
|
107160
107612
|
var getHighWaterMark = require_state().getHighWaterMark;
|
|
107161
|
-
var _require$codes = require_errors$2().codes
|
|
107613
|
+
var _require$codes = require_errors$2().codes;
|
|
107614
|
+
var ERR_INVALID_ARG_TYPE = _require$codes.ERR_INVALID_ARG_TYPE;
|
|
107615
|
+
var ERR_STREAM_PUSH_AFTER_EOF = _require$codes.ERR_STREAM_PUSH_AFTER_EOF;
|
|
107616
|
+
var ERR_METHOD_NOT_IMPLEMENTED = _require$codes.ERR_METHOD_NOT_IMPLEMENTED;
|
|
107617
|
+
var ERR_STREAM_UNSHIFT_AFTER_END_EVENT = _require$codes.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;
|
|
107162
107618
|
var StringDecoder;
|
|
107163
107619
|
var createReadableStreamAsyncIterator;
|
|
107164
107620
|
var from;
|
|
@@ -107881,7 +108337,15 @@ var require__stream_writable = /* @__PURE__ */ __commonJSMin(((exports, module)
|
|
|
107881
108337
|
}
|
|
107882
108338
|
var destroyImpl = require_destroy();
|
|
107883
108339
|
var getHighWaterMark = require_state().getHighWaterMark;
|
|
107884
|
-
var _require$codes = require_errors$2().codes
|
|
108340
|
+
var _require$codes = require_errors$2().codes;
|
|
108341
|
+
var ERR_INVALID_ARG_TYPE = _require$codes.ERR_INVALID_ARG_TYPE;
|
|
108342
|
+
var ERR_METHOD_NOT_IMPLEMENTED = _require$codes.ERR_METHOD_NOT_IMPLEMENTED;
|
|
108343
|
+
var ERR_MULTIPLE_CALLBACK = _require$codes.ERR_MULTIPLE_CALLBACK;
|
|
108344
|
+
var ERR_STREAM_CANNOT_PIPE = _require$codes.ERR_STREAM_CANNOT_PIPE;
|
|
108345
|
+
var ERR_STREAM_DESTROYED = _require$codes.ERR_STREAM_DESTROYED;
|
|
108346
|
+
var ERR_STREAM_NULL_VALUES = _require$codes.ERR_STREAM_NULL_VALUES;
|
|
108347
|
+
var ERR_STREAM_WRITE_AFTER_END = _require$codes.ERR_STREAM_WRITE_AFTER_END;
|
|
108348
|
+
var ERR_UNKNOWN_ENCODING = _require$codes.ERR_UNKNOWN_ENCODING;
|
|
107885
108349
|
var errorOrDestroy = destroyImpl.errorOrDestroy;
|
|
107886
108350
|
require_inherits()(Writable, Stream);
|
|
107887
108351
|
function nop() {}
|
|
@@ -109244,7 +109708,11 @@ var require_series = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
109244
109708
|
//#region ../../node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_transform.js
|
|
109245
109709
|
var require__stream_transform = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
109246
109710
|
module.exports = Transform;
|
|
109247
|
-
var _require$codes = require_errors$2().codes
|
|
109711
|
+
var _require$codes = require_errors$2().codes;
|
|
109712
|
+
var ERR_METHOD_NOT_IMPLEMENTED = _require$codes.ERR_METHOD_NOT_IMPLEMENTED;
|
|
109713
|
+
var ERR_MULTIPLE_CALLBACK = _require$codes.ERR_MULTIPLE_CALLBACK;
|
|
109714
|
+
var ERR_TRANSFORM_ALREADY_TRANSFORMING = _require$codes.ERR_TRANSFORM_ALREADY_TRANSFORMING;
|
|
109715
|
+
var ERR_TRANSFORM_WITH_LENGTH_0 = _require$codes.ERR_TRANSFORM_WITH_LENGTH_0;
|
|
109248
109716
|
var Duplex = require__stream_duplex();
|
|
109249
109717
|
require_inherits()(Transform, Duplex);
|
|
109250
109718
|
function afterTransform(er, data) {
|
|
@@ -109349,7 +109817,9 @@ var require_pipeline = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
109349
109817
|
callback.apply(void 0, arguments);
|
|
109350
109818
|
};
|
|
109351
109819
|
}
|
|
109352
|
-
var _require$codes = require_errors$2().codes
|
|
109820
|
+
var _require$codes = require_errors$2().codes;
|
|
109821
|
+
var ERR_MISSING_ARGS = _require$codes.ERR_MISSING_ARGS;
|
|
109822
|
+
var ERR_STREAM_DESTROYED = _require$codes.ERR_STREAM_DESTROYED;
|
|
109353
109823
|
function noop(err) {
|
|
109354
109824
|
if (err) throw err;
|
|
109355
109825
|
}
|
|
@@ -146782,7 +147252,7 @@ var require_body_parser = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
146782
147252
|
}
|
|
146783
147253
|
}));
|
|
146784
147254
|
//#endregion
|
|
146785
|
-
//#region ../../node_modules/.pnpm/@ariestools+express@8.0.
|
|
147255
|
+
//#region ../../node_modules/.pnpm/@ariestools+express@8.0.8_@opentelemetry+api@1.9.1_supports-color@5.5.0_winston-transport@4.9.0_zod@4.4.3/node_modules/@ariestools/express/dist/node/index.mjs
|
|
146786
147256
|
var import_winston_transport = /* @__PURE__ */ __toESM(require_winston_transport(), 1);
|
|
146787
147257
|
var import_body_parser = /* @__PURE__ */ __toESM(require_body_parser(), 1);
|
|
146788
147258
|
var { colorize, combine, timestamp, printf } = import_winston.format;
|
|
@@ -149796,7 +150266,11 @@ var ACTOR_DEPENDENCIES = {
|
|
|
149796
150266
|
"XyoConnection",
|
|
149797
150267
|
"XyoViewer"
|
|
149798
150268
|
],
|
|
149799
|
-
optionalDependencies: [
|
|
150269
|
+
optionalDependencies: [
|
|
150270
|
+
"DeadLetterQueueViewer",
|
|
150271
|
+
"EvmChainViewer",
|
|
150272
|
+
"IndexViewer"
|
|
150273
|
+
]
|
|
149800
150274
|
},
|
|
149801
150275
|
bridge: { dependencies: [
|
|
149802
150276
|
"DataLakeRunner",
|
|
@@ -149832,7 +150306,7 @@ var ACTOR_DEPENDENCIES = {
|
|
|
149832
150306
|
"MempoolViewer",
|
|
149833
150307
|
"StakeTotalsViewer"
|
|
149834
150308
|
],
|
|
149835
|
-
optionalDependencies: ["DeadLetterQueueRunner"]
|
|
150309
|
+
optionalDependencies: ["DeadLetterQueueRunner", "EvmChainViewer"]
|
|
149836
150310
|
},
|
|
149837
150311
|
rewardRedemption: { dependencies: ["XyoGatewayRunner", "XyoViewer"] }
|
|
149838
150312
|
};
|
|
@@ -150184,6 +150658,8 @@ function buildDefaultInstalledCandidates() {
|
|
|
150184
150658
|
...xyoOwnedProviders.map((cls) => providerCandidateFromClass(cls)),
|
|
150185
150659
|
providerCandidateFromClass(SimpleXyoGatewayRunner, "SimpleXyoGatewayRunner"),
|
|
150186
150660
|
providerCandidateFromClass(SimpleXyoConnectionRunner, "SimpleXyoConnectionRunner"),
|
|
150661
|
+
providerCandidateFromClass(SimpleEvmChainViewer),
|
|
150662
|
+
providerCandidateWithConnectionTypes(SimpleTimeSyncViewer, ["evm-rpc"], "SimpleTimeSyncViewerEvmRpc"),
|
|
150187
150663
|
providerCandidateWithConnectionTypes(S3BlockPublishRunner, ["s3"]),
|
|
150188
150664
|
providerCandidateWithConnectionTypes(S3ChainStatePublishRunner, ["s3"]),
|
|
150189
150665
|
providerCandidateWithConnectionTypes(S3IndexPublishRunner, ["s3"]),
|
|
@@ -150217,6 +150693,16 @@ function hasMemoryOnlyImplementation(moniker, candidates) {
|
|
|
150217
150693
|
function memoryProviderBinding() {
|
|
150218
150694
|
return { connection: DEFAULT_MEMORY_CONNECTION };
|
|
150219
150695
|
}
|
|
150696
|
+
function augmentEvmRpcBinding(moniker, providerBindings, candidates, connections) {
|
|
150697
|
+
if (declaredConnectionName(providerBindings, moniker) !== void 0) return false;
|
|
150698
|
+
if (hasMemoryOnlyImplementation(moniker, candidates)) return false;
|
|
150699
|
+
const satisfying = candidates.filter((descriptor) => descriptor.satisfies.includes(moniker));
|
|
150700
|
+
if (satisfying.length === 0 || !satisfying.some((descriptor) => descriptor.connectionTypes?.includes("evm-rpc"))) return false;
|
|
150701
|
+
const evmConnectionName = Object.entries(connections).find(([, connection]) => connection?.type === "evm-rpc")?.[0];
|
|
150702
|
+
if (evmConnectionName === void 0) return false;
|
|
150703
|
+
providerBindings[moniker] = { connection: evmConnectionName };
|
|
150704
|
+
return true;
|
|
150705
|
+
}
|
|
150220
150706
|
function augmentMemoryBinding(moniker, providerBindings, candidates) {
|
|
150221
150707
|
if (declaredConnectionName(providerBindings, moniker) !== void 0) return false;
|
|
150222
150708
|
if (!hasMemoryOnlyImplementation(moniker, candidates)) return false;
|
|
@@ -150255,6 +150741,7 @@ function prepareBindingsForResolve(needs, candidates, options = {}) {
|
|
|
150255
150741
|
const effectiveBindings = { ...options.providerBindings };
|
|
150256
150742
|
const effectiveConnections = { ...options.connections };
|
|
150257
150743
|
ensureMemoryConnection(effectiveConnections);
|
|
150744
|
+
for (const moniker of wanted) augmentEvmRpcBinding(moniker, effectiveBindings, uniqueCandidates, effectiveConnections);
|
|
150258
150745
|
stripUnboundOptionals(wanted, planNeeds.optional, effectiveBindings, uniqueCandidates);
|
|
150259
150746
|
for (const moniker of planNeeds.required) augmentMemoryBinding(moniker, effectiveBindings, uniqueCandidates);
|
|
150260
150747
|
if (planNeeds.optional !== void 0) {
|
|
@@ -150280,6 +150767,7 @@ function resolveProviders(needs, candidates, _ctx, options = {}) {
|
|
|
150280
150767
|
if (!(error instanceof UnboundProviderError)) throw error;
|
|
150281
150768
|
const moniker = error.moniker;
|
|
150282
150769
|
if (augmentMemoryBinding(moniker, prepared.providerBindings, uniqueCandidates)) continue;
|
|
150770
|
+
if (augmentEvmRpcBinding(moniker, prepared.providerBindings, uniqueCandidates, prepared.connections)) continue;
|
|
150283
150771
|
if (prepared.planNeeds.optional?.has(moniker) === true) {
|
|
150284
150772
|
prepared.wanted.delete(moniker);
|
|
150285
150773
|
continue;
|
|
@@ -150515,6 +151003,8 @@ function isPoolManagedConnection(connections, name) {
|
|
|
150515
151003
|
}
|
|
150516
151004
|
function connectionNamesForPlan(plan, providerBindings, connections) {
|
|
150517
151005
|
const names = /* @__PURE__ */ new Set();
|
|
151006
|
+
const declaredEvmName = findConnectionName(connections, "evm-rpc");
|
|
151007
|
+
if (declaredEvmName !== void 0) names.add(declaredEvmName);
|
|
150518
151008
|
for (const moniker of Object.keys(plan.bindings)) {
|
|
150519
151009
|
const binding = providerBindings?.[moniker];
|
|
150520
151010
|
const name = connectionNameForBinding(binding);
|
|
@@ -150894,15 +151384,13 @@ function s3ClientFor(bucket) {
|
|
|
150894
151384
|
}
|
|
150895
151385
|
});
|
|
150896
151386
|
}
|
|
150897
|
-
function
|
|
150898
|
-
const
|
|
150899
|
-
const name
|
|
150900
|
-
|
|
150901
|
-
|
|
150902
|
-
|
|
150903
|
-
|
|
150904
|
-
const id = ctx.actorContext.config?.chain?.id;
|
|
150905
|
-
return id ? asEthAddress(id, true) : void 0;
|
|
151387
|
+
function pooledEvmProvider(ctx) {
|
|
151388
|
+
const connections = ctx.actorContext.config?.connections ?? {};
|
|
151389
|
+
for (const [name, connection] of Object.entries(connections)) {
|
|
151390
|
+
if (connection?.type !== "evm-rpc") continue;
|
|
151391
|
+
const handle = ctx.connections.get(name);
|
|
151392
|
+
if (handle !== void 0 && isEvmRpcHandle(handle)) return handle.provider;
|
|
151393
|
+
}
|
|
150906
151394
|
}
|
|
150907
151395
|
function rpcUrlForMoniker(ctx, moniker) {
|
|
150908
151396
|
const config = ctx.actorContext.config;
|
|
@@ -150964,6 +151452,11 @@ function createFactoryForDescriptor(d, ctx) {
|
|
|
150964
151452
|
if (rpcUrl === void 0) return void 0;
|
|
150965
151453
|
return Cls.factory(deps, { rpcUrl });
|
|
150966
151454
|
}
|
|
151455
|
+
if (id === "SimpleTimeSyncViewer" || id === "SimpleTimeSyncViewerEvmRpc") return Cls.factory(deps, {});
|
|
151456
|
+
if (id === "SimpleEvmChainViewer") {
|
|
151457
|
+
const provider = pooledEvmProvider(ctx);
|
|
151458
|
+
return Cls.factory(deps, provider === void 0 ? {} : { provider });
|
|
151459
|
+
}
|
|
150967
151460
|
if (id.startsWith("Simple") && (id.includes("Mempool") || id.includes("Finalization") || id.includes("BlockViewer") || id.includes("AccountBalance") || id.includes("DeadLetter") || id.includes("Validation") || id.includes("Rejected"))) {
|
|
150968
151461
|
const moniker = d.satisfies[0];
|
|
150969
151462
|
if (id === "SimpleMempoolViewer") {
|
|
@@ -151017,15 +151510,6 @@ function createFactoryForDescriptor(d, ctx) {
|
|
|
151017
151510
|
});
|
|
151018
151511
|
}
|
|
151019
151512
|
if (id.includes("Rest")) return Cls.factory(deps, {});
|
|
151020
|
-
if (id.includes("Evm")) {
|
|
151021
|
-
const p = evmProviderFromContext(ctx);
|
|
151022
|
-
const a = evmContractAddress(ctx);
|
|
151023
|
-
if (!p || !a) return void 0;
|
|
151024
|
-
return Cls.factory(deps, {
|
|
151025
|
-
address: a,
|
|
151026
|
-
provider: p
|
|
151027
|
-
});
|
|
151028
|
-
}
|
|
151029
151513
|
if (id === "SimpleChainContractViewer" && isMemoryBoundMoniker(ctx, "ChainContractViewer")) return Cls.factory(deps, {
|
|
151030
151514
|
minWithdrawalBlocks: 10,
|
|
151031
151515
|
rewardsContract: XYO_ZERO_ADDRESS,
|
|
@@ -151298,9 +151782,15 @@ async function loadConfigSectionFromPath(configPath) {
|
|
|
151298
151782
|
}
|
|
151299
151783
|
async function loadConfigSectionFromSearch(searchPlaces) {
|
|
151300
151784
|
try {
|
|
151301
|
-
const
|
|
151302
|
-
|
|
151303
|
-
|
|
151785
|
+
const result = (await (0, import_dist.cosmiconfig)(configName, {
|
|
151786
|
+
cache: true,
|
|
151787
|
+
searchPlaces
|
|
151788
|
+
}).search())?.config;
|
|
151789
|
+
if (isRecord$1(result)) {
|
|
151790
|
+
const section = result[configSection];
|
|
151791
|
+
if (isRecord$1(section) && !isUnsetXl1Config(section)) return section;
|
|
151792
|
+
}
|
|
151793
|
+
return defaultDevConfig();
|
|
151304
151794
|
} catch {
|
|
151305
151795
|
return defaultDevConfig();
|
|
151306
151796
|
}
|
|
@@ -160141,7 +160631,11 @@ var MempoolActor = class extends ActorV3 {
|
|
|
160141
160631
|
async prunePendingBlocks() {
|
|
160142
160632
|
await this.spanAsync("mempool:prunePendingBlocks", async () => {
|
|
160143
160633
|
try {
|
|
160144
|
-
await this.mempoolRunner.prunePendingBlocks({
|
|
160634
|
+
await this.mempoolRunner.prunePendingBlocks({
|
|
160635
|
+
batchSize: 100,
|
|
160636
|
+
maxCheck: 1e4,
|
|
160637
|
+
maxPrune: 5e3
|
|
160638
|
+
});
|
|
160145
160639
|
} catch (error) {
|
|
160146
160640
|
this.logger?.error(`[MempoolActor] Error pruning pending blocks: ${error.message}`);
|
|
160147
160641
|
throw error;
|
|
@@ -160154,7 +160648,11 @@ var MempoolActor = class extends ActorV3 {
|
|
|
160154
160648
|
async prunePendingTransactions() {
|
|
160155
160649
|
await this.spanAsync("mempool:prunePendingTransactions", async () => {
|
|
160156
160650
|
try {
|
|
160157
|
-
await this.mempoolRunner.prunePendingTransactions({
|
|
160651
|
+
await this.mempoolRunner.prunePendingTransactions({
|
|
160652
|
+
batchSize: 100,
|
|
160653
|
+
maxCheck: 1e4,
|
|
160654
|
+
maxPrune: 5e3
|
|
160655
|
+
});
|
|
160158
160656
|
} catch (error) {
|
|
160159
160657
|
this.logger?.error(`[MempoolActor] Error pruning pending transactions: ${error.message}`);
|
|
160160
160658
|
throw error;
|
|
@@ -163249,7 +163747,9 @@ var require_lodash_defaults = /* @__PURE__ */ __commonJSMin(((exports, module) =
|
|
|
163249
163747
|
/** Used as references for various `Number` constants. */
|
|
163250
163748
|
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
163251
163749
|
/** `Object#toString` result references. */
|
|
163252
|
-
var argsTag = "[object Arguments]"
|
|
163750
|
+
var argsTag = "[object Arguments]";
|
|
163751
|
+
var funcTag = "[object Function]";
|
|
163752
|
+
var genTag = "[object GeneratorFunction]";
|
|
163253
163753
|
/** Used to detect unsigned integer values. */
|
|
163254
163754
|
var reIsUint = /^(?:0|[1-9]\d*)$/;
|
|
163255
163755
|
/**
|
|
@@ -163810,7 +164310,9 @@ var require_lodash_isarguments = /* @__PURE__ */ __commonJSMin(((exports, module
|
|
|
163810
164310
|
/** Used as references for various `Number` constants. */
|
|
163811
164311
|
var MAX_SAFE_INTEGER = 9007199254740991;
|
|
163812
164312
|
/** `Object#toString` result references. */
|
|
163813
|
-
var argsTag = "[object Arguments]"
|
|
164313
|
+
var argsTag = "[object Arguments]";
|
|
164314
|
+
var funcTag = "[object Function]";
|
|
164315
|
+
var genTag = "[object GeneratorFunction]";
|
|
163814
164316
|
/** Used for built-in method references. */
|
|
163815
164317
|
var objectProto = Object.prototype;
|
|
163816
164318
|
/** Used to check objects for own properties. */
|
|
@@ -170145,7 +170647,7 @@ var init_tslib_es6 = __esmMin((() => {
|
|
|
170145
170647
|
};
|
|
170146
170648
|
}));
|
|
170147
170649
|
//#endregion
|
|
170148
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170650
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/async-fifo-queue.js
|
|
170149
170651
|
var require_async_fifo_queue = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170150
170652
|
/**
|
|
170151
170653
|
* (c) 2017-2025 BullForce Labs AB, MIT Licensed.
|
|
@@ -170298,7 +170800,7 @@ var require_async_fifo_queue = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170298
170800
|
exports.AsyncFifoQueue = AsyncFifoQueue;
|
|
170299
170801
|
}));
|
|
170300
170802
|
//#endregion
|
|
170301
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170803
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/backoffs.js
|
|
170302
170804
|
var require_backoffs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170303
170805
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170304
170806
|
exports.Backoffs = void 0;
|
|
@@ -170342,7 +170844,7 @@ var require_backoffs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170342
170844
|
}
|
|
170343
170845
|
}));
|
|
170344
170846
|
//#endregion
|
|
170345
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170847
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/child-command.js
|
|
170346
170848
|
var require_child_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170347
170849
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170348
170850
|
exports.ChildCommand = void 0;
|
|
@@ -170360,7 +170862,7 @@ var require_child_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170360
170862
|
})(ChildCommand || (exports.ChildCommand = ChildCommand = {}));
|
|
170361
170863
|
}));
|
|
170362
170864
|
//#endregion
|
|
170363
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170865
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/error-code.js
|
|
170364
170866
|
var require_error_code = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170365
170867
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170366
170868
|
exports.ErrorCode = void 0;
|
|
@@ -170380,7 +170882,7 @@ var require_error_code = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170380
170882
|
})(ErrorCode || (exports.ErrorCode = ErrorCode = {}));
|
|
170381
170883
|
}));
|
|
170382
170884
|
//#endregion
|
|
170383
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170885
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/parent-command.js
|
|
170384
170886
|
var require_parent_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170385
170887
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170386
170888
|
exports.ParentCommand = void 0;
|
|
@@ -170404,7 +170906,7 @@ var require_parent_command = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170404
170906
|
})(ParentCommand || (exports.ParentCommand = ParentCommand = {}));
|
|
170405
170907
|
}));
|
|
170406
170908
|
//#endregion
|
|
170407
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170909
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/metrics-time.js
|
|
170408
170910
|
var require_metrics_time = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170409
170911
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170410
170912
|
exports.MetricsTime = void 0;
|
|
@@ -170421,7 +170923,7 @@ var require_metrics_time = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170421
170923
|
})(MetricsTime || (exports.MetricsTime = MetricsTime = {}));
|
|
170422
170924
|
}));
|
|
170423
170925
|
//#endregion
|
|
170424
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170926
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/telemetry-attributes.js
|
|
170425
170927
|
var require_telemetry_attributes = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170426
170928
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170427
170929
|
exports.SpanKind = exports.MetricNames = exports.TelemetryAttributes = void 0;
|
|
@@ -170492,7 +170994,7 @@ var require_telemetry_attributes = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170492
170994
|
})(SpanKind || (exports.SpanKind = SpanKind = {}));
|
|
170493
170995
|
}));
|
|
170494
170996
|
//#endregion
|
|
170495
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
170997
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/enums/index.js
|
|
170496
170998
|
var require_enums = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170497
170999
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170498
171000
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -170503,7 +171005,7 @@ var require_enums = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170503
171005
|
tslib_1.__exportStar(require_telemetry_attributes(), exports);
|
|
170504
171006
|
}));
|
|
170505
171007
|
//#endregion
|
|
170506
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171008
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/child.js
|
|
170507
171009
|
var require_child = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170508
171010
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170509
171011
|
exports.Child = void 0;
|
|
@@ -170682,7 +171184,7 @@ var require_child = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170682
171184
|
};
|
|
170683
171185
|
}));
|
|
170684
171186
|
//#endregion
|
|
170685
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171187
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/child-pool.js
|
|
170686
171188
|
var require_child_pool = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
170687
171189
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170688
171190
|
exports.ChildPool = void 0;
|
|
@@ -170825,7 +171327,7 @@ var require_node_abort_controller = /* @__PURE__ */ __commonJSMin(((exports, mod
|
|
|
170825
171327
|
};
|
|
170826
171328
|
}));
|
|
170827
171329
|
//#endregion
|
|
170828
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171330
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/abort-controller.js
|
|
170829
171331
|
var require_abort_controller = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170830
171332
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170831
171333
|
exports.AbortController = void 0;
|
|
@@ -170837,7 +171339,7 @@ var require_abort_controller = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
170837
171339
|
exports.AbortController = AbortController;
|
|
170838
171340
|
}));
|
|
170839
171341
|
//#endregion
|
|
170840
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171342
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/connection-closed-error.js
|
|
170841
171343
|
var require_connection_closed_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170842
171344
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170843
171345
|
exports.ConnectionClosedError = void 0;
|
|
@@ -170860,7 +171362,7 @@ var require_connection_closed_error = /* @__PURE__ */ __commonJSMin(((exports) =
|
|
|
170860
171362
|
exports.ConnectionClosedError = ConnectionClosedError;
|
|
170861
171363
|
}));
|
|
170862
171364
|
//#endregion
|
|
170863
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171365
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/utils/index.js
|
|
170864
171366
|
var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
170865
171367
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
170866
171368
|
exports.QUEUE_EVENT_SUFFIX = exports.toString = exports.errorToJSON = exports.parseObjectValues = exports.isRedisVersionLowerThan = exports.childSend = exports.asyncSend = exports.DELAY_TIME_1 = exports.DELAY_TIME_5 = exports.clientCommandMessageReg = exports.optsEncodeMap = exports.optsDecodeMap = exports.errorObject = void 0;
|
|
@@ -171125,7 +171627,7 @@ var require_utils = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171125
171627
|
}
|
|
171126
171628
|
}));
|
|
171127
171629
|
//#endregion
|
|
171128
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171630
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/child-processor.js
|
|
171129
171631
|
var require_child_processor = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171130
171632
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171131
171633
|
exports.ChildProcessor = void 0;
|
|
@@ -171357,7 +171859,7 @@ var require_child_processor = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171357
171859
|
};
|
|
171358
171860
|
}));
|
|
171359
171861
|
//#endregion
|
|
171360
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171862
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/delayed-error.js
|
|
171361
171863
|
var require_delayed_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171362
171864
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171363
171865
|
exports.DelayedError = exports.DELAYED_ERROR = void 0;
|
|
@@ -171379,7 +171881,7 @@ var require_delayed_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171379
171881
|
exports.DelayedError = DelayedError;
|
|
171380
171882
|
}));
|
|
171381
171883
|
//#endregion
|
|
171382
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171884
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/rate-limit-error.js
|
|
171383
171885
|
var require_rate_limit_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171384
171886
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171385
171887
|
exports.RateLimitError = exports.RATE_LIMIT_ERROR = void 0;
|
|
@@ -171400,7 +171902,7 @@ var require_rate_limit_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171400
171902
|
exports.RateLimitError = RateLimitError;
|
|
171401
171903
|
}));
|
|
171402
171904
|
//#endregion
|
|
171403
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171905
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/unrecoverable-error.js
|
|
171404
171906
|
var require_unrecoverable_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171405
171907
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171406
171908
|
exports.UnrecoverableError = exports.UNRECOVERABLE_ERROR = void 0;
|
|
@@ -171422,7 +171924,7 @@ var require_unrecoverable_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171422
171924
|
exports.UnrecoverableError = UnrecoverableError;
|
|
171423
171925
|
}));
|
|
171424
171926
|
//#endregion
|
|
171425
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171927
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/waiting-children-error.js
|
|
171426
171928
|
var require_waiting_children_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171427
171929
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171428
171930
|
exports.WaitingChildrenError = exports.WAITING_CHILDREN_ERROR = void 0;
|
|
@@ -171444,7 +171946,7 @@ var require_waiting_children_error = /* @__PURE__ */ __commonJSMin(((exports) =>
|
|
|
171444
171946
|
exports.WaitingChildrenError = WaitingChildrenError;
|
|
171445
171947
|
}));
|
|
171446
171948
|
//#endregion
|
|
171447
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171949
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/waiting-error.js
|
|
171448
171950
|
var require_waiting_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171449
171951
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171450
171952
|
exports.WaitingError = exports.WAITING_ERROR = void 0;
|
|
@@ -171465,7 +171967,7 @@ var require_waiting_error = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
171465
171967
|
exports.WaitingError = WaitingError;
|
|
171466
171968
|
}));
|
|
171467
171969
|
//#endregion
|
|
171468
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
171970
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/errors/index.js
|
|
171469
171971
|
var require_errors = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
171470
171972
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
171471
171973
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -172975,14 +173477,16 @@ var require_node = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
172975
173477
|
try {
|
|
172976
173478
|
textEncoder = new TextEncoder();
|
|
172977
173479
|
} catch (error) {}
|
|
172978
|
-
let extensions
|
|
173480
|
+
let extensions;
|
|
173481
|
+
let extensionClasses;
|
|
172979
173482
|
const hasNodeBuffer = typeof Buffer !== "undefined";
|
|
172980
173483
|
const ByteArrayAllocate = hasNodeBuffer ? function(length) {
|
|
172981
173484
|
return Buffer.allocUnsafeSlow(length);
|
|
172982
173485
|
} : Uint8Array;
|
|
172983
173486
|
const ByteArray = hasNodeBuffer ? Buffer : Uint8Array;
|
|
172984
173487
|
const MAX_BUFFER_SIZE = hasNodeBuffer ? 4294967296 : 2144337920;
|
|
172985
|
-
let target
|
|
173488
|
+
let target;
|
|
173489
|
+
let keysTarget;
|
|
172986
173490
|
let targetView;
|
|
172987
173491
|
let position = 0;
|
|
172988
173492
|
let safeEnd;
|
|
@@ -174027,14 +174531,14 @@ var require_node = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
174027
174531
|
exports.useRecords = useRecords;
|
|
174028
174532
|
}));
|
|
174029
174533
|
//#endregion
|
|
174030
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
174534
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/version.js
|
|
174031
174535
|
var require_version = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
174032
174536
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
174033
174537
|
exports.version = void 0;
|
|
174034
|
-
exports.version = "5.79.
|
|
174538
|
+
exports.version = "5.79.4";
|
|
174035
174539
|
}));
|
|
174036
174540
|
//#endregion
|
|
174037
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
174541
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/scripts.js
|
|
174038
174542
|
/**
|
|
174039
174543
|
* Includes all the scripts needed by the queue and jobs.
|
|
174040
174544
|
*/
|
|
@@ -175262,7 +175766,7 @@ var require_scripts$1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
175262
175766
|
}
|
|
175263
175767
|
}));
|
|
175264
175768
|
//#endregion
|
|
175265
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
175769
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/utils/create-scripts.js
|
|
175266
175770
|
var require_create_scripts = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
175267
175771
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175268
175772
|
exports.createScripts = void 0;
|
|
@@ -175283,7 +175787,7 @@ var require_create_scripts = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
175283
175787
|
exports.createScripts = createScripts;
|
|
175284
175788
|
}));
|
|
175285
175789
|
//#endregion
|
|
175286
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
175790
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/job.js
|
|
175287
175791
|
var require_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
175288
175792
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
175289
175793
|
exports.Job = exports.PRIORITY_LIMIT = void 0;
|
|
@@ -176188,7 +176692,7 @@ var require_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
176188
176692
|
}
|
|
176189
176693
|
}));
|
|
176190
176694
|
//#endregion
|
|
176191
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
176695
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue-keys.js
|
|
176192
176696
|
var require_queue_keys = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
176193
176697
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
176194
176698
|
exports.QueueKeys = void 0;
|
|
@@ -176233,7 +176737,7 @@ var require_queue_keys = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
176233
176737
|
exports.QueueKeys = QueueKeys;
|
|
176234
176738
|
}));
|
|
176235
176739
|
//#endregion
|
|
176236
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
176740
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addDelayedJob-6.js
|
|
176237
176741
|
var require_addDelayedJob_6 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
176238
176742
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
176239
176743
|
exports.addDelayedJob = void 0;
|
|
@@ -176814,7 +177318,7 @@ return jobId .. "" -- convert to string
|
|
|
176814
177318
|
};
|
|
176815
177319
|
}));
|
|
176816
177320
|
//#endregion
|
|
176817
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
177321
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addJobScheduler-11.js
|
|
176818
177322
|
var require_addJobScheduler_11 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
176819
177323
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
176820
177324
|
exports.addJobScheduler = void 0;
|
|
@@ -177254,6 +177758,7 @@ local function storeJobScheduler(schedulerId, schedulerKey, repeatKey, nextMilli
|
|
|
177254
177758
|
rcall("HMSET", schedulerKey, "name", opts['name'], unpack(optionalValues))
|
|
177255
177759
|
end
|
|
177256
177760
|
local function getJobSchedulerEveryNextMillis(prevMillis, every, now, offset, startDate)
|
|
177761
|
+
offset = tonumber(offset)
|
|
177257
177762
|
local nextMillis
|
|
177258
177763
|
if not prevMillis then
|
|
177259
177764
|
if startDate then
|
|
@@ -177411,7 +177916,7 @@ return {jobId .. "", delay}
|
|
|
177411
177916
|
};
|
|
177412
177917
|
}));
|
|
177413
177918
|
//#endregion
|
|
177414
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
177919
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addLog-2.js
|
|
177415
177920
|
var require_addLog_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
177416
177921
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
177417
177922
|
exports.addLog = void 0;
|
|
@@ -177445,7 +177950,7 @@ end
|
|
|
177445
177950
|
};
|
|
177446
177951
|
}));
|
|
177447
177952
|
//#endregion
|
|
177448
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
177953
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addParentJob-6.js
|
|
177449
177954
|
var require_addParentJob_6 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
177450
177955
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
177451
177956
|
exports.addParentJob = void 0;
|
|
@@ -177923,7 +178428,7 @@ return jobId .. "" -- convert to string
|
|
|
177923
178428
|
};
|
|
177924
178429
|
}));
|
|
177925
178430
|
//#endregion
|
|
177926
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
178431
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addPrioritizedJob-9.js
|
|
177927
178432
|
var require_addPrioritizedJob_9 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
177928
178433
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
177929
178434
|
exports.addPrioritizedJob = void 0;
|
|
@@ -178474,7 +178979,7 @@ return jobId .. "" -- convert to string
|
|
|
178474
178979
|
};
|
|
178475
178980
|
}));
|
|
178476
178981
|
//#endregion
|
|
178477
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
178982
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addRepeatableJob-2.js
|
|
178478
178983
|
var require_addRepeatableJob_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
178479
178984
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178480
178985
|
exports.addRepeatableJob = void 0;
|
|
@@ -178713,7 +179218,7 @@ return storeRepeatableJob(repeatKey, customKey, nextMillis, ARGV[2])
|
|
|
178713
179218
|
};
|
|
178714
179219
|
}));
|
|
178715
179220
|
//#endregion
|
|
178716
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
179221
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/addStandardJob-9.js
|
|
178717
179222
|
var require_addStandardJob_9 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
178718
179223
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
178719
179224
|
exports.addStandardJob = void 0;
|
|
@@ -179268,7 +179773,7 @@ return jobId .. "" -- convert to string
|
|
|
179268
179773
|
};
|
|
179269
179774
|
}));
|
|
179270
179775
|
//#endregion
|
|
179271
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
179776
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/changeDelay-4.js
|
|
179272
179777
|
var require_changeDelay_4 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
179273
179778
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179274
179779
|
exports.changeDelay = void 0;
|
|
@@ -179376,7 +179881,7 @@ end`,
|
|
|
179376
179881
|
};
|
|
179377
179882
|
}));
|
|
179378
179883
|
//#endregion
|
|
179379
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
179884
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/changePriority-7.js
|
|
179380
179885
|
var require_changePriority_7 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
179381
179886
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179382
179887
|
exports.changePriority = void 0;
|
|
@@ -179505,7 +180010,7 @@ end
|
|
|
179505
180010
|
};
|
|
179506
180011
|
}));
|
|
179507
180012
|
//#endregion
|
|
179508
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180013
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/cleanJobsInSet-3.js
|
|
179509
180014
|
var require_cleanJobsInSet_3 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
179510
180015
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179511
180016
|
exports.cleanJobsInSet = void 0;
|
|
@@ -179875,7 +180380,7 @@ return result[1]
|
|
|
179875
180380
|
};
|
|
179876
180381
|
}));
|
|
179877
180382
|
//#endregion
|
|
179878
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180383
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/drain-5.js
|
|
179879
180384
|
var require_drain_5 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
179880
180385
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
179881
180386
|
exports.drain = void 0;
|
|
@@ -180151,7 +180656,7 @@ removeZSetJobs(KEYS[4], true, queueBaseKey, 0, scheduledJobs) -- prioritized
|
|
|
180151
180656
|
};
|
|
180152
180657
|
}));
|
|
180153
180658
|
//#endregion
|
|
180154
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180659
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/extendLock-2.js
|
|
180155
180660
|
var require_extendLock_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180156
180661
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180157
180662
|
exports.extendLock = void 0;
|
|
@@ -180182,7 +180687,7 @@ return 0
|
|
|
180182
180687
|
};
|
|
180183
180688
|
}));
|
|
180184
180689
|
//#endregion
|
|
180185
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180690
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/extendLocks-1.js
|
|
180186
180691
|
var require_extendLocks_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180187
180692
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180188
180693
|
exports.extendLocks = void 0;
|
|
@@ -180233,7 +180738,7 @@ return failedJobs
|
|
|
180233
180738
|
};
|
|
180234
180739
|
}));
|
|
180235
180740
|
//#endregion
|
|
180236
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180741
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getCounts-1.js
|
|
180237
180742
|
var require_getCounts_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180238
180743
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180239
180744
|
exports.getCounts = void 0;
|
|
@@ -180276,7 +180781,7 @@ return results
|
|
|
180276
180781
|
};
|
|
180277
180782
|
}));
|
|
180278
180783
|
//#endregion
|
|
180279
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180784
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getCountsPerPriority-4.js
|
|
180280
180785
|
var require_getCountsPerPriority_4 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180281
180786
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180282
180787
|
exports.getCountsPerPriority = void 0;
|
|
@@ -180323,7 +180828,7 @@ return results
|
|
|
180323
180828
|
};
|
|
180324
180829
|
}));
|
|
180325
180830
|
//#endregion
|
|
180326
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180831
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getDependencyCounts-4.js
|
|
180327
180832
|
var require_getDependencyCounts_4 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180328
180833
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180329
180834
|
exports.getDependencyCounts = void 0;
|
|
@@ -180361,7 +180866,7 @@ return results
|
|
|
180361
180866
|
};
|
|
180362
180867
|
}));
|
|
180363
180868
|
//#endregion
|
|
180364
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180869
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getJobScheduler-1.js
|
|
180365
180870
|
var require_getJobScheduler_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180366
180871
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180367
180872
|
exports.getJobScheduler = void 0;
|
|
@@ -180385,7 +180890,7 @@ return {nil, nil}
|
|
|
180385
180890
|
};
|
|
180386
180891
|
}));
|
|
180387
180892
|
//#endregion
|
|
180388
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180893
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getMetrics-2.js
|
|
180389
180894
|
var require_getMetrics_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180390
180895
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180391
180896
|
exports.getMetrics = void 0;
|
|
@@ -180411,7 +180916,7 @@ return {metrics, data, numPoints}
|
|
|
180411
180916
|
};
|
|
180412
180917
|
}));
|
|
180413
180918
|
//#endregion
|
|
180414
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180919
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getRanges-1.js
|
|
180415
180920
|
var require_getRanges_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180416
180921
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180417
180922
|
exports.getRanges = void 0;
|
|
@@ -180485,7 +180990,7 @@ return results
|
|
|
180485
180990
|
};
|
|
180486
180991
|
}));
|
|
180487
180992
|
//#endregion
|
|
180488
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
180993
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getRateLimitTtl-2.js
|
|
180489
180994
|
var require_getRateLimitTtl_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180490
180995
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180491
180996
|
exports.getRateLimitTtl = void 0;
|
|
@@ -180530,7 +181035,7 @@ end
|
|
|
180530
181035
|
};
|
|
180531
181036
|
}));
|
|
180532
181037
|
//#endregion
|
|
180533
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181038
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getState-8.js
|
|
180534
181039
|
var require_getState_8 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180535
181040
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180536
181041
|
exports.getState = void 0;
|
|
@@ -180604,7 +181109,7 @@ return "unknown"
|
|
|
180604
181109
|
};
|
|
180605
181110
|
}));
|
|
180606
181111
|
//#endregion
|
|
180607
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181112
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/getStateV2-8.js
|
|
180608
181113
|
var require_getStateV2_8 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180609
181114
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180610
181115
|
exports.getStateV2 = void 0;
|
|
@@ -180662,7 +181167,7 @@ return "unknown"
|
|
|
180662
181167
|
};
|
|
180663
181168
|
}));
|
|
180664
181169
|
//#endregion
|
|
180665
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181170
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/isFinished-3.js
|
|
180666
181171
|
var require_isFinished_3 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180667
181172
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180668
181173
|
exports.isFinished = void 0;
|
|
@@ -180712,7 +181217,7 @@ return 0
|
|
|
180712
181217
|
};
|
|
180713
181218
|
}));
|
|
180714
181219
|
//#endregion
|
|
180715
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181220
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/isJobInList-1.js
|
|
180716
181221
|
var require_isJobInList_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180717
181222
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180718
181223
|
exports.isJobInList = void 0;
|
|
@@ -180745,7 +181250,7 @@ return checkItemInList(items, ARGV[1])
|
|
|
180745
181250
|
};
|
|
180746
181251
|
}));
|
|
180747
181252
|
//#endregion
|
|
180748
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181253
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/isMaxed-2.js
|
|
180749
181254
|
var require_isMaxed_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180750
181255
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180751
181256
|
exports.isMaxed = void 0;
|
|
@@ -180780,7 +181285,7 @@ return isQueueMaxed(KEYS[1], KEYS[2])
|
|
|
180780
181285
|
};
|
|
180781
181286
|
}));
|
|
180782
181287
|
//#endregion
|
|
180783
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181288
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveJobFromActiveToWait-9.js
|
|
180784
181289
|
var require_moveJobFromActiveToWait_9 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180785
181290
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180786
181291
|
exports.moveJobFromActiveToWait = void 0;
|
|
@@ -180915,7 +181420,7 @@ end
|
|
|
180915
181420
|
};
|
|
180916
181421
|
}));
|
|
180917
181422
|
//#endregion
|
|
180918
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181423
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveJobsToWait-8.js
|
|
180919
181424
|
var require_moveJobsToWait_8 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
180920
181425
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
180921
181426
|
exports.moveJobsToWait = void 0;
|
|
@@ -181034,7 +181539,7 @@ return 0
|
|
|
181034
181539
|
};
|
|
181035
181540
|
}));
|
|
181036
181541
|
//#endregion
|
|
181037
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181542
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveStalledJobsToWait-9.js
|
|
181038
181543
|
var require_moveStalledJobsToWait_9 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
181039
181544
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
181040
181545
|
exports.moveStalledJobsToWait = void 0;
|
|
@@ -181229,7 +181734,7 @@ return stalled
|
|
|
181229
181734
|
};
|
|
181230
181735
|
}));
|
|
181231
181736
|
//#endregion
|
|
181232
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181737
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveToActive-11.js
|
|
181233
181738
|
var require_moveToActive_11 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
181234
181739
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
181235
181740
|
exports.moveToActive = void 0;
|
|
@@ -181474,7 +181979,7 @@ return {0, 0, 0, 0}
|
|
|
181474
181979
|
};
|
|
181475
181980
|
}));
|
|
181476
181981
|
//#endregion
|
|
181477
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
181982
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveToDelayed-12.js
|
|
181478
181983
|
var require_moveToDelayed_12 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
181479
181984
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
181480
181985
|
exports.moveToDelayed = void 0;
|
|
@@ -181874,7 +182379,7 @@ end
|
|
|
181874
182379
|
};
|
|
181875
182380
|
}));
|
|
181876
182381
|
//#endregion
|
|
181877
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
182382
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveToFinished-14.js
|
|
181878
182383
|
var require_moveToFinished_14 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
181879
182384
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
181880
182385
|
exports.moveToFinished = void 0;
|
|
@@ -182920,7 +183425,7 @@ end
|
|
|
182920
183425
|
};
|
|
182921
183426
|
}));
|
|
182922
183427
|
//#endregion
|
|
182923
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
183428
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/moveToWaitingChildren-7.js
|
|
182924
183429
|
var require_moveToWaitingChildren_7 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
182925
183430
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
182926
183431
|
exports.moveToWaitingChildren = void 0;
|
|
@@ -183028,7 +183533,7 @@ return -1
|
|
|
183028
183533
|
};
|
|
183029
183534
|
}));
|
|
183030
183535
|
//#endregion
|
|
183031
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
183536
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/obliterate-2.js
|
|
183032
183537
|
var require_obliterate_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183033
183538
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183034
183539
|
exports.obliterate = void 0;
|
|
@@ -183373,7 +183878,7 @@ end
|
|
|
183373
183878
|
};
|
|
183374
183879
|
}));
|
|
183375
183880
|
//#endregion
|
|
183376
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
183881
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/paginate-1.js
|
|
183377
183882
|
var require_paginate_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183378
183883
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183379
183884
|
exports.paginate = void 0;
|
|
@@ -183484,7 +183989,7 @@ return {cursor, offset, items, numItems, jobs}
|
|
|
183484
183989
|
};
|
|
183485
183990
|
}));
|
|
183486
183991
|
//#endregion
|
|
183487
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
183992
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/pause-7.js
|
|
183488
183993
|
var require_pause_7 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183489
183994
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183490
183995
|
exports.pause = void 0;
|
|
@@ -183552,7 +184057,7 @@ rcall("XADD", KEYS[5], "*", "event", ARGV[1]);
|
|
|
183552
184057
|
};
|
|
183553
184058
|
}));
|
|
183554
184059
|
//#endregion
|
|
183555
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184060
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/promote-9.js
|
|
183556
184061
|
var require_promote_9 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183557
184062
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183558
184063
|
exports.promote = void 0;
|
|
@@ -183663,7 +184168,7 @@ end
|
|
|
183663
184168
|
};
|
|
183664
184169
|
}));
|
|
183665
184170
|
//#endregion
|
|
183666
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184171
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/releaseLock-1.js
|
|
183667
184172
|
var require_releaseLock_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183668
184173
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183669
184174
|
exports.releaseLock = void 0;
|
|
@@ -183689,7 +184194,7 @@ end
|
|
|
183689
184194
|
};
|
|
183690
184195
|
}));
|
|
183691
184196
|
//#endregion
|
|
183692
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184197
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeChildDependency-1.js
|
|
183693
184198
|
var require_removeChildDependency_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183694
184199
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183695
184200
|
exports.removeChildDependency = void 0;
|
|
@@ -183855,7 +184360,7 @@ end`,
|
|
|
183855
184360
|
};
|
|
183856
184361
|
}));
|
|
183857
184362
|
//#endregion
|
|
183858
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184363
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeDeduplicationKey-1.js
|
|
183859
184364
|
var require_removeDeduplicationKey_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183860
184365
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183861
184366
|
exports.removeDeduplicationKey = void 0;
|
|
@@ -183883,7 +184388,7 @@ return 0
|
|
|
183883
184388
|
};
|
|
183884
184389
|
}));
|
|
183885
184390
|
//#endregion
|
|
183886
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184391
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeJob-2.js
|
|
183887
184392
|
var require_removeJob_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
183888
184393
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
183889
184394
|
exports.removeJob = void 0;
|
|
@@ -184236,7 +184741,7 @@ return 0
|
|
|
184236
184741
|
};
|
|
184237
184742
|
}));
|
|
184238
184743
|
//#endregion
|
|
184239
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184744
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeJobScheduler-3.js
|
|
184240
184745
|
var require_removeJobScheduler_3 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184241
184746
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184242
184747
|
exports.removeJobScheduler = void 0;
|
|
@@ -184286,7 +184791,7 @@ return 1
|
|
|
184286
184791
|
};
|
|
184287
184792
|
}));
|
|
184288
184793
|
//#endregion
|
|
184289
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184794
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeOrphanedJobs-1.js
|
|
184290
184795
|
var require_removeOrphanedJobs_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184291
184796
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184292
184797
|
exports.removeOrphanedJobs = void 0;
|
|
@@ -184364,7 +184869,7 @@ return removedCount
|
|
|
184364
184869
|
};
|
|
184365
184870
|
}));
|
|
184366
184871
|
//#endregion
|
|
184367
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184872
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeRepeatable-3.js
|
|
184368
184873
|
var require_removeRepeatable_3 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184369
184874
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184370
184875
|
exports.removeRepeatable = void 0;
|
|
@@ -184428,7 +184933,7 @@ return 1
|
|
|
184428
184933
|
};
|
|
184429
184934
|
}));
|
|
184430
184935
|
//#endregion
|
|
184431
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
184936
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/removeUnprocessedChildren-2.js
|
|
184432
184937
|
var require_removeUnprocessedChildren_2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184433
184938
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184434
184939
|
exports.removeUnprocessedChildren = void 0;
|
|
@@ -184771,7 +185276,7 @@ removeJobChildren(prefix, jobKey, options)
|
|
|
184771
185276
|
};
|
|
184772
185277
|
}));
|
|
184773
185278
|
//#endregion
|
|
184774
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
185279
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/reprocessJob-8.js
|
|
184775
185280
|
var require_reprocessJob_8 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184776
185281
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184777
185282
|
exports.reprocessJob = void 0;
|
|
@@ -184891,7 +185396,7 @@ end
|
|
|
184891
185396
|
};
|
|
184892
185397
|
}));
|
|
184893
185398
|
//#endregion
|
|
184894
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
185399
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/retryJob-11.js
|
|
184895
185400
|
var require_retryJob_11 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
184896
185401
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
184897
185402
|
exports.retryJob = void 0;
|
|
@@ -185106,7 +185611,7 @@ end
|
|
|
185106
185611
|
};
|
|
185107
185612
|
}));
|
|
185108
185613
|
//#endregion
|
|
185109
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
185614
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/saveStacktrace-1.js
|
|
185110
185615
|
var require_saveStacktrace_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185111
185616
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185112
185617
|
exports.saveStacktrace = void 0;
|
|
@@ -185134,7 +185639,7 @@ end
|
|
|
185134
185639
|
};
|
|
185135
185640
|
}));
|
|
185136
185641
|
//#endregion
|
|
185137
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
185642
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/updateData-1.js
|
|
185138
185643
|
var require_updateData_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185139
185644
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185140
185645
|
exports.updateData = void 0;
|
|
@@ -185161,7 +185666,7 @@ end
|
|
|
185161
185666
|
};
|
|
185162
185667
|
}));
|
|
185163
185668
|
//#endregion
|
|
185164
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
185669
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/updateJobScheduler-12.js
|
|
185165
185670
|
var require_updateJobScheduler_12 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185166
185671
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185167
185672
|
exports.updateJobScheduler = void 0;
|
|
@@ -185407,6 +185912,7 @@ local function getOrSetMaxEvents(metaKey)
|
|
|
185407
185912
|
return maxEvents
|
|
185408
185913
|
end
|
|
185409
185914
|
local function getJobSchedulerEveryNextMillis(prevMillis, every, now, offset, startDate)
|
|
185915
|
+
offset = tonumber(offset)
|
|
185410
185916
|
local nextMillis
|
|
185411
185917
|
if not prevMillis then
|
|
185412
185918
|
if startDate then
|
|
@@ -185506,7 +186012,7 @@ end
|
|
|
185506
186012
|
};
|
|
185507
186013
|
}));
|
|
185508
186014
|
//#endregion
|
|
185509
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186015
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/updateProgress-3.js
|
|
185510
186016
|
var require_updateProgress_3 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185511
186017
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185512
186018
|
exports.updateProgress = void 0;
|
|
@@ -185553,7 +186059,7 @@ end
|
|
|
185553
186059
|
};
|
|
185554
186060
|
}));
|
|
185555
186061
|
//#endregion
|
|
185556
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186062
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/updateRepeatableJobMillis-1.js
|
|
185557
186063
|
var require_updateRepeatableJobMillis_1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185558
186064
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185559
186065
|
exports.updateRepeatableJobMillis = void 0;
|
|
@@ -185587,7 +186093,7 @@ return ''
|
|
|
185587
186093
|
};
|
|
185588
186094
|
}));
|
|
185589
186095
|
//#endregion
|
|
185590
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186096
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/scripts/index.js
|
|
185591
186097
|
var require_scripts = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185592
186098
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185593
186099
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -185644,7 +186150,7 @@ var require_scripts = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
185644
186150
|
tslib_1.__exportStar(require_updateRepeatableJobMillis_1(), exports);
|
|
185645
186151
|
}));
|
|
185646
186152
|
//#endregion
|
|
185647
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186153
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/ioredis-client.js
|
|
185648
186154
|
var require_ioredis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185649
186155
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185650
186156
|
exports.createIORedisClient = createIORedisClient;
|
|
@@ -185840,7 +186346,7 @@ var require_ioredis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
185840
186346
|
}
|
|
185841
186347
|
}));
|
|
185842
186348
|
//#endregion
|
|
185843
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186349
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/redis-connection.js
|
|
185844
186350
|
var require_redis_connection = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
185845
186351
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
185846
186352
|
exports.RedisConnection = void 0;
|
|
@@ -186204,7 +186710,7 @@ var require_redis_connection = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
186204
186710
|
RedisConnection.recommendedMinimumVersion = "6.2.0";
|
|
186205
186711
|
}));
|
|
186206
186712
|
//#endregion
|
|
186207
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
186713
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/flow-producer.js
|
|
186208
186714
|
var require_flow_producer = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
186209
186715
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
186210
186716
|
exports.FlowProducer = void 0;
|
|
@@ -186570,7 +187076,7 @@ var require_flow_producer = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
186570
187076
|
exports.FlowProducer = FlowProducer;
|
|
186571
187077
|
}));
|
|
186572
187078
|
//#endregion
|
|
186573
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
187079
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/node-redis-client.js
|
|
186574
187080
|
var require_node_redis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
186575
187081
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
186576
187082
|
exports.createNodeRedisClient = createNodeRedisClient;
|
|
@@ -187104,7 +187610,7 @@ var require_node_redis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
187104
187610
|
};
|
|
187105
187611
|
}));
|
|
187106
187612
|
//#endregion
|
|
187107
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
187613
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/bun-redis-client.js
|
|
187108
187614
|
var require_bun_redis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
187109
187615
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
187110
187616
|
exports.createBunRedisClient = createBunRedisClient;
|
|
@@ -187878,7 +188384,9 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
187878
188384
|
/**
|
|
187879
188385
|
* @private
|
|
187880
188386
|
*/
|
|
187881
|
-
const n = "numeric"
|
|
188387
|
+
const n = "numeric";
|
|
188388
|
+
const s = "short";
|
|
188389
|
+
const l = "long";
|
|
187882
188390
|
const DATE_SHORT = {
|
|
187883
188391
|
year: n,
|
|
187884
188392
|
month: n,
|
|
@@ -189019,7 +189527,14 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
189019
189527
|
}
|
|
189020
189528
|
return regex;
|
|
189021
189529
|
}
|
|
189022
|
-
let now = () => Date.now()
|
|
189530
|
+
let now = () => Date.now();
|
|
189531
|
+
let defaultZone = "system";
|
|
189532
|
+
let defaultLocale = null;
|
|
189533
|
+
let defaultNumberingSystem = null;
|
|
189534
|
+
let defaultOutputCalendar = null;
|
|
189535
|
+
let twoDigitCutoffYear = 60;
|
|
189536
|
+
let throwOnInvalid;
|
|
189537
|
+
let defaultWeekSettings = null;
|
|
189023
189538
|
/**
|
|
189024
189539
|
* Settings contains static getters and setters that control Luxon's overall behavior. Luxon is a simple library with few options, but the ones it does have live here.
|
|
189025
189540
|
*/
|
|
@@ -189188,7 +189703,8 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
189188
189703
|
273,
|
|
189189
189704
|
304,
|
|
189190
189705
|
334
|
|
189191
|
-
]
|
|
189706
|
+
];
|
|
189707
|
+
const leapLadder = [
|
|
189192
189708
|
0,
|
|
189193
189709
|
31,
|
|
189194
189710
|
60,
|
|
@@ -190115,7 +190631,9 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
190115
190631
|
function preprocessRFC2822(s) {
|
|
190116
190632
|
return s.replace(/\([^()]*\)|[\n\t]/g, " ").replace(/(\s\s+)/g, " ").trim();
|
|
190117
190633
|
}
|
|
190118
|
-
const rfc1123 = /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT
|
|
190634
|
+
const rfc1123 = /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/;
|
|
190635
|
+
const rfc850 = /^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/;
|
|
190636
|
+
const ascii = /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;
|
|
190119
190637
|
function extractRFC1123Or850(match) {
|
|
190120
190638
|
const [, weekdayStr, dayStr, monthStr, yearStr, hourStr, minuteStr, secondStr] = match;
|
|
190121
190639
|
return [fromStrings(weekdayStr, yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr), FixedOffsetZone.utcInstance];
|
|
@@ -190179,7 +190697,8 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
190179
190697
|
milliseconds: 60 * 1e3
|
|
190180
190698
|
},
|
|
190181
190699
|
seconds: { milliseconds: 1e3 }
|
|
190182
|
-
}
|
|
190700
|
+
};
|
|
190701
|
+
const casualMatrix = {
|
|
190183
190702
|
years: {
|
|
190184
190703
|
quarters: 4,
|
|
190185
190704
|
months: 12,
|
|
@@ -190208,7 +190727,10 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
190208
190727
|
milliseconds: 720 * 60 * 60 * 1e3
|
|
190209
190728
|
},
|
|
190210
190729
|
...lowOrderMatrix
|
|
190211
|
-
}
|
|
190730
|
+
};
|
|
190731
|
+
const daysInYearAccurate = 146097 / 400;
|
|
190732
|
+
const daysInMonthAccurate = 146097 / 4800;
|
|
190733
|
+
const accurateMatrix = {
|
|
190212
190734
|
years: {
|
|
190213
190735
|
quarters: 4,
|
|
190214
190736
|
months: 12,
|
|
@@ -192192,14 +192714,16 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
192192
192714
|
minute: 0,
|
|
192193
192715
|
second: 0,
|
|
192194
192716
|
millisecond: 0
|
|
192195
|
-
}
|
|
192717
|
+
};
|
|
192718
|
+
const defaultWeekUnitValues = {
|
|
192196
192719
|
weekNumber: 1,
|
|
192197
192720
|
weekday: 1,
|
|
192198
192721
|
hour: 0,
|
|
192199
192722
|
minute: 0,
|
|
192200
192723
|
second: 0,
|
|
192201
192724
|
millisecond: 0
|
|
192202
|
-
}
|
|
192725
|
+
};
|
|
192726
|
+
const defaultOrdinalUnitValues = {
|
|
192203
192727
|
ordinal: 1,
|
|
192204
192728
|
hour: 0,
|
|
192205
192729
|
minute: 0,
|
|
@@ -192214,7 +192738,8 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
192214
192738
|
"minute",
|
|
192215
192739
|
"second",
|
|
192216
192740
|
"millisecond"
|
|
192217
|
-
]
|
|
192741
|
+
];
|
|
192742
|
+
const orderedWeekUnits = [
|
|
192218
192743
|
"weekYear",
|
|
192219
192744
|
"weekNumber",
|
|
192220
192745
|
"weekday",
|
|
@@ -192222,7 +192747,8 @@ var require_luxon = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
192222
192747
|
"minute",
|
|
192223
192748
|
"second",
|
|
192224
192749
|
"millisecond"
|
|
192225
|
-
]
|
|
192750
|
+
];
|
|
192751
|
+
const orderedOrdinalUnits = [
|
|
192226
192752
|
"year",
|
|
192227
192753
|
"ordinal",
|
|
192228
192754
|
"hour",
|
|
@@ -195047,7 +195573,7 @@ var require_parser = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
195047
195573
|
module.exports = CronParser;
|
|
195048
195574
|
}));
|
|
195049
195575
|
//#endregion
|
|
195050
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
195576
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue-base.js
|
|
195051
195577
|
var require_queue_base = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195052
195578
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195053
195579
|
exports.QueueBase = void 0;
|
|
@@ -195194,7 +195720,7 @@ var require_queue_base = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
195194
195720
|
exports.QueueBase = QueueBase;
|
|
195195
195721
|
}));
|
|
195196
195722
|
//#endregion
|
|
195197
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
195723
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/job-scheduler.js
|
|
195198
195724
|
var require_job_scheduler = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195199
195725
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195200
195726
|
exports.defaultRepeatStrategy = exports.JobScheduler = void 0;
|
|
@@ -195402,7 +195928,7 @@ var require_job_scheduler = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
195402
195928
|
exports.defaultRepeatStrategy = defaultRepeatStrategy;
|
|
195403
195929
|
}));
|
|
195404
195930
|
//#endregion
|
|
195405
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
195931
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/lock-manager.js
|
|
195406
195932
|
var require_lock_manager = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195407
195933
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195408
195934
|
exports.LockManager = void 0;
|
|
@@ -195557,7 +196083,7 @@ var require_lock_manager = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
195557
196083
|
exports.LockManager = LockManager;
|
|
195558
196084
|
}));
|
|
195559
196085
|
//#endregion
|
|
195560
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
196086
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue-events.js
|
|
195561
196087
|
var require_queue_events = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195562
196088
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195563
196089
|
exports.QueueEvents = void 0;
|
|
@@ -195639,6 +196165,9 @@ var require_queue_events = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
195639
196165
|
case "completed":
|
|
195640
196166
|
args.returnvalue = JSON.parse(args.returnvalue);
|
|
195641
196167
|
break;
|
|
196168
|
+
case "delayed":
|
|
196169
|
+
args.delay = Number(args.delay);
|
|
196170
|
+
break;
|
|
195642
196171
|
}
|
|
195643
196172
|
const { event } = args, restArgs = tslib_1.__rest(args, ["event"]);
|
|
195644
196173
|
if (event === "drained") this.emit(event, id);
|
|
@@ -195670,7 +196199,7 @@ var require_queue_events = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
195670
196199
|
exports.QueueEvents = QueueEvents;
|
|
195671
196200
|
}));
|
|
195672
196201
|
//#endregion
|
|
195673
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
196202
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue-events-producer.js
|
|
195674
196203
|
var require_queue_events_producer = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195675
196204
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195676
196205
|
exports.QueueEventsProducer = void 0;
|
|
@@ -195710,7 +196239,7 @@ var require_queue_events_producer = /* @__PURE__ */ __commonJSMin(((exports) =>
|
|
|
195710
196239
|
exports.QueueEventsProducer = QueueEventsProducer;
|
|
195711
196240
|
}));
|
|
195712
196241
|
//#endregion
|
|
195713
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
196242
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue-getters.js
|
|
195714
196243
|
var require_queue_getters = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
195715
196244
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
195716
196245
|
exports.QueueGetters = void 0;
|
|
@@ -196232,7 +196761,7 @@ var require_queue_getters = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
196232
196761
|
exports.QueueGetters = QueueGetters;
|
|
196233
196762
|
}));
|
|
196234
196763
|
//#endregion
|
|
196235
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
196764
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/repeat.js
|
|
196236
196765
|
var require_repeat = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
196237
196766
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
196238
196767
|
exports.getNextMillis = exports.Repeat = void 0;
|
|
@@ -196400,7 +196929,7 @@ var require_repeat = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
196400
196929
|
exports.getNextMillis = getNextMillis;
|
|
196401
196930
|
}));
|
|
196402
196931
|
//#endregion
|
|
196403
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
196932
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/queue.js
|
|
196404
196933
|
var require_queue = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
196405
196934
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
196406
196935
|
exports.Queue = void 0;
|
|
@@ -197070,7 +197599,7 @@ var require_queue = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
197070
197599
|
exports.Queue = Queue;
|
|
197071
197600
|
}));
|
|
197072
197601
|
//#endregion
|
|
197073
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
197602
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/sandbox.js
|
|
197074
197603
|
var require_sandbox = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197075
197604
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197076
197605
|
const enums_1 = require_enums();
|
|
@@ -197212,7 +197741,7 @@ var require_sandbox = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
197212
197741
|
exports.default = sandbox;
|
|
197213
197742
|
}));
|
|
197214
197743
|
//#endregion
|
|
197215
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
197744
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/worker.js
|
|
197216
197745
|
var require_worker = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
197217
197746
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197218
197747
|
exports.Worker = void 0;
|
|
@@ -197927,7 +198456,7 @@ var require_worker = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
197927
198456
|
exports.Worker = Worker;
|
|
197928
198457
|
}));
|
|
197929
198458
|
//#endregion
|
|
197930
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198459
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/classes/index.js
|
|
197931
198460
|
var require_classes = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197932
198461
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197933
198462
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -197957,97 +198486,97 @@ var require_classes = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
197957
198486
|
tslib_1.__exportStar(require_worker(), exports);
|
|
197958
198487
|
}));
|
|
197959
198488
|
//#endregion
|
|
197960
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198489
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/advanced-options.js
|
|
197961
198490
|
var require_advanced_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197962
198491
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197963
198492
|
}));
|
|
197964
198493
|
//#endregion
|
|
197965
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198494
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/backoff-options.js
|
|
197966
198495
|
var require_backoff_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197967
198496
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197968
198497
|
}));
|
|
197969
198498
|
//#endregion
|
|
197970
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198499
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/base-job-options.js
|
|
197971
198500
|
var require_base_job_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197972
198501
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197973
198502
|
}));
|
|
197974
198503
|
//#endregion
|
|
197975
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198504
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/child-message.js
|
|
197976
198505
|
var require_child_message = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197977
198506
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197978
198507
|
}));
|
|
197979
198508
|
//#endregion
|
|
197980
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198509
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/connection.js
|
|
197981
198510
|
var require_connection = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197982
198511
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197983
198512
|
}));
|
|
197984
198513
|
//#endregion
|
|
197985
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198514
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/flow-job.js
|
|
197986
198515
|
var require_flow_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197987
198516
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197988
198517
|
}));
|
|
197989
198518
|
//#endregion
|
|
197990
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198519
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/ioredis-events.js
|
|
197991
198520
|
var require_ioredis_events = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197992
198521
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197993
198522
|
}));
|
|
197994
198523
|
//#endregion
|
|
197995
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198524
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/job-json.js
|
|
197996
198525
|
var require_job_json = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
197997
198526
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
197998
198527
|
}));
|
|
197999
198528
|
//#endregion
|
|
198000
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198529
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/job-scheduler-json.js
|
|
198001
198530
|
var require_job_scheduler_json = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198002
198531
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198003
198532
|
}));
|
|
198004
198533
|
//#endregion
|
|
198005
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198534
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/lock-manager-worker-context.js
|
|
198006
198535
|
var require_lock_manager_worker_context = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198007
198536
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198008
198537
|
}));
|
|
198009
198538
|
//#endregion
|
|
198010
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198539
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/metrics-options.js
|
|
198011
198540
|
var require_metrics_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198012
198541
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198013
198542
|
}));
|
|
198014
198543
|
//#endregion
|
|
198015
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198544
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/metrics.js
|
|
198016
198545
|
var require_metrics = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198017
198546
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198018
198547
|
}));
|
|
198019
198548
|
//#endregion
|
|
198020
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198549
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/minimal-job.js
|
|
198021
198550
|
var require_minimal_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198022
198551
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198023
198552
|
}));
|
|
198024
198553
|
//#endregion
|
|
198025
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198554
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/minimal-queue.js
|
|
198026
198555
|
var require_minimal_queue = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198027
198556
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198028
198557
|
}));
|
|
198029
198558
|
//#endregion
|
|
198030
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198559
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/parent-message.js
|
|
198031
198560
|
var require_parent_message = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198032
198561
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198033
198562
|
}));
|
|
198034
198563
|
//#endregion
|
|
198035
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198564
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/parent.js
|
|
198036
198565
|
var require_parent = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198037
198566
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198038
198567
|
}));
|
|
198039
198568
|
//#endregion
|
|
198040
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198569
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/parent-options.js
|
|
198041
198570
|
var require_parent_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198042
198571
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198043
198572
|
}));
|
|
198044
198573
|
//#endregion
|
|
198045
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198574
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/queue-meta.js
|
|
198046
198575
|
var require_queue_meta = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198047
198576
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198048
198577
|
}));
|
|
198049
198578
|
//#endregion
|
|
198050
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198579
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/queue-options.js
|
|
198051
198580
|
var require_queue_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198052
198581
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198053
198582
|
exports.ClientType = void 0;
|
|
@@ -198058,82 +198587,82 @@ var require_queue_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
198058
198587
|
})(ClientType || (exports.ClientType = ClientType = {}));
|
|
198059
198588
|
}));
|
|
198060
198589
|
//#endregion
|
|
198061
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198590
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/rate-limiter-options.js
|
|
198062
198591
|
var require_rate_limiter_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198063
198592
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198064
198593
|
}));
|
|
198065
198594
|
//#endregion
|
|
198066
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198595
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/redis-client.js
|
|
198067
198596
|
var require_redis_client = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198068
198597
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198069
198598
|
}));
|
|
198070
198599
|
//#endregion
|
|
198071
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198600
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/redis-options.js
|
|
198072
198601
|
var require_redis_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198073
198602
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198074
198603
|
}));
|
|
198075
198604
|
//#endregion
|
|
198076
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198605
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/redis-streams.js
|
|
198077
198606
|
var require_redis_streams = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198078
198607
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198079
198608
|
}));
|
|
198080
198609
|
//#endregion
|
|
198081
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198610
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/repeatable-job.js
|
|
198082
198611
|
var require_repeatable_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198083
198612
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198084
198613
|
}));
|
|
198085
198614
|
//#endregion
|
|
198086
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198615
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/repeatable-options.js
|
|
198087
198616
|
var require_repeatable_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198088
198617
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198089
198618
|
}));
|
|
198090
198619
|
//#endregion
|
|
198091
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198620
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/repeat-options.js
|
|
198092
198621
|
var require_repeat_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198093
198622
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198094
198623
|
}));
|
|
198095
198624
|
//#endregion
|
|
198096
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198625
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/retry-options.js
|
|
198097
198626
|
var require_retry_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198098
198627
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198099
198628
|
}));
|
|
198100
198629
|
//#endregion
|
|
198101
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198630
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/script-queue-context.js
|
|
198102
198631
|
var require_script_queue_context = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198103
198632
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198104
198633
|
}));
|
|
198105
198634
|
//#endregion
|
|
198106
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198635
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/sandboxed-job-processor.js
|
|
198107
198636
|
var require_sandboxed_job_processor = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198108
198637
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198109
198638
|
}));
|
|
198110
198639
|
//#endregion
|
|
198111
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198640
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/sandboxed-job.js
|
|
198112
198641
|
var require_sandboxed_job = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198113
198642
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198114
198643
|
}));
|
|
198115
198644
|
//#endregion
|
|
198116
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198645
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/sandboxed-options.js
|
|
198117
198646
|
var require_sandboxed_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198118
198647
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198119
198648
|
}));
|
|
198120
198649
|
//#endregion
|
|
198121
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198650
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/worker-options.js
|
|
198122
198651
|
var require_worker_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198123
198652
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198124
198653
|
}));
|
|
198125
198654
|
//#endregion
|
|
198126
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198655
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/telemetry.js
|
|
198127
198656
|
var require_telemetry = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198128
198657
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198129
198658
|
}));
|
|
198130
198659
|
//#endregion
|
|
198131
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198660
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/receiver.js
|
|
198132
198661
|
var require_receiver = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198133
198662
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198134
198663
|
}));
|
|
198135
198664
|
//#endregion
|
|
198136
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198665
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/interfaces/index.js
|
|
198137
198666
|
var require_interfaces = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198138
198667
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198139
198668
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -198173,62 +198702,62 @@ var require_interfaces = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
198173
198702
|
tslib_1.__exportStar(require_receiver(), exports);
|
|
198174
198703
|
}));
|
|
198175
198704
|
//#endregion
|
|
198176
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198705
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/backoff-strategy.js
|
|
198177
198706
|
var require_backoff_strategy = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198178
198707
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198179
198708
|
}));
|
|
198180
198709
|
//#endregion
|
|
198181
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198710
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/database-type.js
|
|
198182
198711
|
var require_database_type = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198183
198712
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198184
198713
|
}));
|
|
198185
198714
|
//#endregion
|
|
198186
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198715
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/deduplication-options.js
|
|
198187
198716
|
var require_deduplication_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198188
198717
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198189
198718
|
}));
|
|
198190
198719
|
//#endregion
|
|
198191
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198720
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/finished-status.js
|
|
198192
198721
|
var require_finished_status = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198193
198722
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198194
198723
|
}));
|
|
198195
198724
|
//#endregion
|
|
198196
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198725
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/job-json-sandbox.js
|
|
198197
198726
|
var require_job_json_sandbox = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198198
198727
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198199
198728
|
}));
|
|
198200
198729
|
//#endregion
|
|
198201
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198730
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/job-options.js
|
|
198202
198731
|
var require_job_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198203
198732
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198204
198733
|
}));
|
|
198205
198734
|
//#endregion
|
|
198206
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198735
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/job-scheduler-template-options.js
|
|
198207
198736
|
var require_job_scheduler_template_options = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198208
198737
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198209
198738
|
}));
|
|
198210
198739
|
//#endregion
|
|
198211
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198740
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/job-type.js
|
|
198212
198741
|
var require_job_type = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198213
198742
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198214
198743
|
}));
|
|
198215
198744
|
//#endregion
|
|
198216
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198745
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/job-progress.js
|
|
198217
198746
|
var require_job_progress = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198218
198747
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198219
198748
|
}));
|
|
198220
198749
|
//#endregion
|
|
198221
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198750
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/repeat-strategy.js
|
|
198222
198751
|
var require_repeat_strategy = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198223
198752
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198224
198753
|
}));
|
|
198225
198754
|
//#endregion
|
|
198226
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198755
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/keep-jobs.js
|
|
198227
198756
|
var require_keep_jobs = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198228
198757
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198229
198758
|
}));
|
|
198230
198759
|
//#endregion
|
|
198231
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198760
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/index.js
|
|
198232
198761
|
var require_types = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198233
198762
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198234
198763
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -198245,12 +198774,12 @@ var require_types = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
198245
198774
|
tslib_1.__exportStar(require_keep_jobs(), exports);
|
|
198246
198775
|
}));
|
|
198247
198776
|
//#endregion
|
|
198248
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198777
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/types/processor.js
|
|
198249
198778
|
var require_processor = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198250
198779
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198251
198780
|
}));
|
|
198252
198781
|
//#endregion
|
|
198253
|
-
//#region ../../node_modules/.pnpm/bullmq@5.79.
|
|
198782
|
+
//#region ../../node_modules/.pnpm/bullmq@5.79.4/node_modules/bullmq/dist/cjs/index.js
|
|
198254
198783
|
var require_cjs$1 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198255
198784
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198256
198785
|
const tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports));
|
|
@@ -198624,7 +199153,7 @@ var require_bullMQOtel = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
198624
199153
|
exports.BullMQOtel = BullMQOtel;
|
|
198625
199154
|
}));
|
|
198626
199155
|
//#endregion
|
|
198627
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-driver-mongodb@4.0.
|
|
199156
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-driver-mongodb@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zo_5e217f52165fa4737a3f539512f3dd75/node_modules/@xyo-network/xl1-driver-mongodb/dist/neutral/index.mjs
|
|
198628
199157
|
var import_cjs$1 = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
198629
199158
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
198630
199159
|
(init_tslib_es6(), __toCommonJS(tslib_es6_exports)).__exportStar(require_bullMQOtel(), exports);
|
|
@@ -199445,7 +199974,7 @@ async function verifyEthBridgeEvent(id, bridge, provider, confirmationDepth, dep
|
|
|
199445
199974
|
const event = (await bridge.queryFilter(filter, deployBlock, blockTag))[0];
|
|
199446
199975
|
if (event === void 0) return null;
|
|
199447
199976
|
return {
|
|
199448
|
-
amount: data.amount,
|
|
199977
|
+
amount: toHex(data.amount),
|
|
199449
199978
|
destAddress: toAddress(data.destAddress),
|
|
199450
199979
|
destToken: toAddress(data.destToken),
|
|
199451
199980
|
evmTxHash: asHex(event.transactionHash, true),
|
|
@@ -199480,7 +200009,7 @@ var createWorker = (connection2, telemetry2, services) => {
|
|
|
199480
200009
|
const { feeFixed, feeRateBasisPoints } = getFeeStructure(config);
|
|
199481
200010
|
const { feesAddress } = await getTransferAddresses(config);
|
|
199482
200011
|
const snapshot = buildAcceptedSnapshot({
|
|
199483
|
-
amount: data.amount,
|
|
200012
|
+
amount: hexToBigInt(data.amount),
|
|
199484
200013
|
bridgeAccountAddress: toAddress(account.address),
|
|
199485
200014
|
bridgeId: id,
|
|
199486
200015
|
destAddress: data.destAddress,
|
|
@@ -199499,7 +200028,7 @@ var createWorker = (connection2, telemetry2, services) => {
|
|
|
199499
200028
|
state.acceptedFees = snapshot.acceptedFees;
|
|
199500
200029
|
state.acceptedSourceObservation = snapshot.acceptedSourceObservation;
|
|
199501
200030
|
await bridgeFulfillmentMap.set(identity, state);
|
|
199502
|
-
await job.log(`[${identity}] verified: src=${data.srcAddress} dest=${data.destAddress} amount=${data.amount} evmTxHash=${data.evmTxHash} snapshot: feeFixed=${snapshot.acceptedFees.feeFixed} feeVariable=${snapshot.acceptedFees.feeVariable}`);
|
|
200031
|
+
await job.log(`[${identity}] verified: src=${data.srcAddress} dest=${data.destAddress} amount=${hexToBigInt(data.amount)} evmTxHash=${data.evmTxHash} snapshot: feeFixed=${snapshot.acceptedFees.feeFixed} feeVariable=${snapshot.acceptedFees.feeVariable}`);
|
|
199503
200032
|
}, {
|
|
199504
200033
|
logger,
|
|
199505
200034
|
timeBudgetLimit: 5e3
|
|
@@ -199891,14 +200420,15 @@ async function buildAndSubmitFreshAttempt(ctx) {
|
|
|
199891
200420
|
const { account, bridgeId, config, contractAddress, evmChainId, fulfillmentMap, gateway, identity, job, state, viewer, xl1ChainId, xl1TokenAddress } = ctx;
|
|
199892
200421
|
const canonical = assertEx$1(state.canonical, () => `[${identity}] buildAndSubmitFreshAttempt requires canonical`);
|
|
199893
200422
|
const acceptedFees = assertEx$1(state.acceptedFees, () => `[${identity}] acceptedFees missing \u2014 Stage 1 did not snapshot`);
|
|
200423
|
+
const amount = hexToBigInt(canonical.amount);
|
|
199894
200424
|
const feesAmount = hexToBigInt(acceptedFees.feeFixed) + hexToBigInt(acceptedFees.feeVariable);
|
|
199895
200425
|
const { feesAddress } = await getTransferAddresses(config);
|
|
199896
200426
|
if (!await validateSufficientXl1ReserveBalance({
|
|
199897
|
-
amount
|
|
200427
|
+
amount,
|
|
199898
200428
|
bridgeAccount: account,
|
|
199899
200429
|
gateway
|
|
199900
200430
|
})) {
|
|
199901
|
-
const msg = `[${identity}] XL1 reserve below required ${
|
|
200431
|
+
const msg = `[${identity}] XL1 reserve below required ${amount.toString()}; terminal \u2014 refill and retry`;
|
|
199902
200432
|
await job.log(msg);
|
|
199903
200433
|
throw new import_cjs.UnrecoverableError(msg);
|
|
199904
200434
|
}
|
|
@@ -199906,7 +200436,7 @@ async function buildAndSubmitFreshAttempt(ctx) {
|
|
|
199906
200436
|
const nbf = asXL1BlockNumber(head, true);
|
|
199907
200437
|
const exp = asXL1BlockNumber(head + EXP_BLOCKS_AHEAD, true);
|
|
199908
200438
|
const tx = await buildEthToXl1ReserveTx({
|
|
199909
|
-
amount
|
|
200439
|
+
amount,
|
|
199910
200440
|
bridgeAccount: account,
|
|
199911
200441
|
bridgeId,
|
|
199912
200442
|
destAddress: canonical.destAddress,
|
|
@@ -199969,12 +200499,13 @@ var createWorker7 = (connection2, telemetry2, services) => {
|
|
|
199969
200499
|
const state = assertEx$1(initialState, () => `[${identity}] no fulfillment state \u2014 Stage 1 did not run`);
|
|
199970
200500
|
const canonical = assertEx$1(state.canonical, () => `[${identity}] canonical missing \u2014 Stage 1 did not write canonical`);
|
|
199971
200501
|
const minBridgeAmount = getMinBridgeAmount(config);
|
|
200502
|
+
const grossAmount = hexToBigInt(canonical.amount);
|
|
199972
200503
|
if (!validateAmountMeetsMinBridgeAmount({
|
|
199973
|
-
amount:
|
|
200504
|
+
amount: grossAmount,
|
|
199974
200505
|
minBridgeAmount
|
|
199975
200506
|
})) {
|
|
199976
|
-
await job.log(`[${identity}] amount ${
|
|
199977
|
-
throw new import_cjs.UnrecoverableError(`[${identity}] below_min_bridge_amount: amount=${
|
|
200507
|
+
await job.log(`[${identity}] amount ${grossAmount} below minBridgeAmount ${minBridgeAmount}; terminal`);
|
|
200508
|
+
throw new import_cjs.UnrecoverableError(`[${identity}] below_min_bridge_amount: amount=${grossAmount} minBridgeAmount=${minBridgeAmount}`);
|
|
199978
200509
|
}
|
|
199979
200510
|
const viewer = assertEx$1(gateway.connection.viewer, () => `[${identity}] gateway viewer not available`);
|
|
199980
200511
|
const ctx = {
|
|
@@ -200669,7 +201200,9 @@ function createEvmBridgeScannerRunner(options2) {
|
|
|
200669
201200
|
});
|
|
200670
201201
|
await queue.add(REPEATABLE_JOB_NAME, {}, {
|
|
200671
201202
|
jobId: REPEATABLE_JOB_ID,
|
|
200672
|
-
repeat: { every: intervalMs }
|
|
201203
|
+
repeat: { every: intervalMs },
|
|
201204
|
+
removeOnComplete: { count: 25 },
|
|
201205
|
+
removeOnFail: { count: 100 }
|
|
200673
201206
|
});
|
|
200674
201207
|
},
|
|
200675
201208
|
async stop() {
|
|
@@ -201745,7 +202278,7 @@ function producerCommand(getConfiguration, getLocatorFromConfig) {
|
|
|
201745
202278
|
};
|
|
201746
202279
|
}
|
|
201747
202280
|
//#endregion
|
|
201748
|
-
//#region ../../node_modules/.pnpm/@xyo-network+storage-model@9.0.
|
|
202281
|
+
//#region ../../node_modules/.pnpm/@xyo-network+storage-model@9.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4_d8689fb2b31c5dbea53e88072c30c7e3/node_modules/@xyo-network/storage-model/dist/neutral/index.mjs
|
|
201749
202282
|
var WalletKindMap = {
|
|
201750
202283
|
os: "os",
|
|
201751
202284
|
user: "user"
|
|
@@ -201754,7 +202287,7 @@ Object.keys(WalletKindMap);
|
|
|
201754
202287
|
/*! store2 - v2.14.4 - 2024-12-26
|
|
201755
202288
|
* Copyright (c) 2024 Nathan Bubna; Licensed MIT */
|
|
201756
202289
|
//#endregion
|
|
201757
|
-
//#region ../../node_modules/.pnpm/@xyo-network+bios@9.0.
|
|
202290
|
+
//#region ../../node_modules/.pnpm/@xyo-network+bios@9.1.0_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod@4.4.3__@open_30e9f57a4d1efaae2d12625e80867ccc/node_modules/@xyo-network/bios/dist/neutral/index.mjs
|
|
201758
202291
|
var import_store2 = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
201759
202292
|
(function(window, define) {
|
|
201760
202293
|
var _ = {
|
|
@@ -202724,7 +203257,7 @@ function rewardRedemptionCommand(getConfiguration, getLocatorFromConfig) {
|
|
|
202724
203257
|
};
|
|
202725
203258
|
}
|
|
202726
203259
|
//#endregion
|
|
202727
|
-
//#region ../../node_modules/.pnpm/@xyo-network+xl1-system-status@4.0.
|
|
203260
|
+
//#region ../../node_modules/.pnpm/@xyo-network+xl1-system-status@4.1.1_@ariestools+sdk@8.0.8_@opentelemetry+api@1.9.1_zod_c0a6465efa67f8400f196b40e03a1964/node_modules/@xyo-network/xl1-system-status/dist/node/index.mjs
|
|
202728
203261
|
function resolveStatusProbe(status, url) {
|
|
202729
203262
|
switch (url) {
|
|
202730
203263
|
case "/healthz": {
|
|
@@ -204816,7 +205349,9 @@ function stripQuotes(val) {
|
|
|
204816
205349
|
* Copyright (c) 2016, Contributors
|
|
204817
205350
|
* SPDX-License-Identifier: ISC
|
|
204818
205351
|
*/
|
|
204819
|
-
var _a
|
|
205352
|
+
var _a;
|
|
205353
|
+
var _b;
|
|
205354
|
+
var _c;
|
|
204820
205355
|
const minNodeVersion = process && process.env && process.env.YARGS_MIN_NODE_VERSION ? Number(process.env.YARGS_MIN_NODE_VERSION) : 20;
|
|
204821
205356
|
const nodeVersion = (_b = (_a = process === null || process === void 0 ? void 0 : process.versions) === null || _a === void 0 ? void 0 : _a.node) !== null && _b !== void 0 ? _b : (_c = process === null || process === void 0 ? void 0 : process.version) === null || _c === void 0 ? void 0 : _c.slice(1);
|
|
204822
205357
|
if (nodeVersion) {
|
|
@@ -206632,7 +207167,41 @@ var __classPrivateFieldGet = function(receiver, state, kind, f) {
|
|
|
206632
207167
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
206633
207168
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
206634
207169
|
};
|
|
206635
|
-
var _YargsInstance_command
|
|
207170
|
+
var _YargsInstance_command;
|
|
207171
|
+
var _YargsInstance_cwd;
|
|
207172
|
+
var _YargsInstance_context;
|
|
207173
|
+
var _YargsInstance_completion;
|
|
207174
|
+
var _YargsInstance_completionCommand;
|
|
207175
|
+
var _YargsInstance_defaultShowHiddenOpt;
|
|
207176
|
+
var _YargsInstance_exitError;
|
|
207177
|
+
var _YargsInstance_detectLocale;
|
|
207178
|
+
var _YargsInstance_emittedWarnings;
|
|
207179
|
+
var _YargsInstance_exitProcess;
|
|
207180
|
+
var _YargsInstance_frozens;
|
|
207181
|
+
var _YargsInstance_globalMiddleware;
|
|
207182
|
+
var _YargsInstance_groups;
|
|
207183
|
+
var _YargsInstance_hasOutput;
|
|
207184
|
+
var _YargsInstance_helpOpt;
|
|
207185
|
+
var _YargsInstance_isGlobalContext;
|
|
207186
|
+
var _YargsInstance_logger;
|
|
207187
|
+
var _YargsInstance_output;
|
|
207188
|
+
var _YargsInstance_options;
|
|
207189
|
+
var _YargsInstance_parentRequire;
|
|
207190
|
+
var _YargsInstance_parserConfig;
|
|
207191
|
+
var _YargsInstance_parseFn;
|
|
207192
|
+
var _YargsInstance_parseContext;
|
|
207193
|
+
var _YargsInstance_pkgs;
|
|
207194
|
+
var _YargsInstance_preservedGroups;
|
|
207195
|
+
var _YargsInstance_processArgs;
|
|
207196
|
+
var _YargsInstance_recommendCommands;
|
|
207197
|
+
var _YargsInstance_shim;
|
|
207198
|
+
var _YargsInstance_strict;
|
|
207199
|
+
var _YargsInstance_strictCommands;
|
|
207200
|
+
var _YargsInstance_strictOptions;
|
|
207201
|
+
var _YargsInstance_usage;
|
|
207202
|
+
var _YargsInstance_usageConfig;
|
|
207203
|
+
var _YargsInstance_versionOpt;
|
|
207204
|
+
var _YargsInstance_validation;
|
|
206636
207205
|
function YargsFactory(_shim) {
|
|
206637
207206
|
return (processArgs = [], cwd = _shim.process.cwd(), parentRequire) => {
|
|
206638
207207
|
const yargs = new YargsInstance(processArgs, cwd, parentRequire, _shim);
|
|
@@ -208279,6 +208848,12 @@ function stripCliOnlyArgs(argv) {
|
|
|
208279
208848
|
for (const [key, value] of Object.entries(argv)) if (!CLI_ONLY_ARG_KEYS.has(key)) stripped[key] = value;
|
|
208280
208849
|
return stripped;
|
|
208281
208850
|
}
|
|
208851
|
+
function selectActorSlices(fileActors, names) {
|
|
208852
|
+
const slices = Array.isArray(fileActors) ? fileActors.filter(isRecord) : [];
|
|
208853
|
+
return [...new Set(names)].map((name) => {
|
|
208854
|
+
return slices.find((slice) => slice.name === name) ?? { name };
|
|
208855
|
+
});
|
|
208856
|
+
}
|
|
208282
208857
|
async function buildFinalConfig(argv) {
|
|
208283
208858
|
const configPath = argv.config;
|
|
208284
208859
|
const parsedConfigFileRaw = normalizeConnectionNames(await tryParseConfig({
|
|
@@ -208289,14 +208864,19 @@ async function buildFinalConfig(argv) {
|
|
|
208289
208864
|
const normalizedArgv = normalizeConnectionNames(coerceActorsArray(argv));
|
|
208290
208865
|
const configArgs = stripCliOnlyArgs(normalizedArgv);
|
|
208291
208866
|
const argsForSdk = stripOrchestrationOnlyConnections(configArgs);
|
|
208292
|
-
|
|
208867
|
+
let parsedConfigArgs = argsForSdk.actors !== void 0 || argsForSdk.connections !== void 0 || argsForSdk.providerBindings !== void 0 ? argsForSdk : {};
|
|
208293
208868
|
const rootMnemonicFromArgs = typeof normalizedArgv.mnemonic === "string" ? normalizedArgv.mnemonic : void 0;
|
|
208294
208869
|
const parsedFileRecord = parsedConfigFileRaw;
|
|
208295
208870
|
let fileForMerge = parsedFileRecord;
|
|
208296
208871
|
const argvActors = configArgs.actors;
|
|
208297
208872
|
if (Array.isArray(argvActors) && argvActors.length > 0) {
|
|
208298
|
-
const { actors:
|
|
208873
|
+
const { actors: fileActors, ...rest } = parsedFileRecord;
|
|
208299
208874
|
fileForMerge = rest;
|
|
208875
|
+
const names = argvActors.filter((entry) => typeof entry === "string");
|
|
208876
|
+
if (names.length === argvActors.length) parsedConfigArgs = {
|
|
208877
|
+
...parsedConfigArgs,
|
|
208878
|
+
actors: selectActorSlices(fileActors, names)
|
|
208879
|
+
};
|
|
208300
208880
|
}
|
|
208301
208881
|
const mergedForSdk = stripOrchestrationOnlyConnections(deepMerge(fileForMerge, parsedConfigArgs));
|
|
208302
208882
|
const rootMnemonic = rootMnemonicFromArgs ?? rootMnemonicFromFile;
|
|
@@ -208567,6 +209147,15 @@ var optionsFromGlobalZodRegistry = () => {
|
|
|
208567
209147
|
}
|
|
208568
209148
|
return opts;
|
|
208569
209149
|
};
|
|
209150
|
+
function formatStartupBanner(version2, actors) {
|
|
209151
|
+
return [
|
|
209152
|
+
"",
|
|
209153
|
+
"🚀 XL1 Node CLI",
|
|
209154
|
+
` Version: ${version2}`,
|
|
209155
|
+
` Actors: ${actors.join(", ")}`,
|
|
209156
|
+
""
|
|
209157
|
+
].join("\n");
|
|
209158
|
+
}
|
|
208570
209159
|
var DEFAULT_HEALTH_CHECK_PORT = 9099;
|
|
208571
209160
|
function defaultScrapePortForActors(actors) {
|
|
208572
209161
|
const primary = actors[0];
|
|
@@ -208575,10 +209164,15 @@ function defaultScrapePortForActors(actors) {
|
|
|
208575
209164
|
var configuration;
|
|
208576
209165
|
var skipInsecureConfirm = false;
|
|
208577
209166
|
var dumpProviders = false;
|
|
208578
|
-
var version = isDefined$1("4.0
|
|
209167
|
+
var version = isDefined$1("4.1.0") ? "4.1.0" : "unknown";
|
|
209168
|
+
var gitHash = isDefined$1("1f1484078") ? "1f1484078" : "";
|
|
209169
|
+
var fullVersion = gitHash.length > 0 ? `${version} (${gitHash})` : version;
|
|
208579
209170
|
function getConfiguration() {
|
|
208580
209171
|
return configuration;
|
|
208581
209172
|
}
|
|
209173
|
+
function isAbortError(error) {
|
|
209174
|
+
return error instanceof Error && "code" in error && error.code === "ABORT_ERR";
|
|
209175
|
+
}
|
|
208582
209176
|
async function promptForInsecureGenesisConfirmation(logger) {
|
|
208583
209177
|
if (!stdin.isTTY || !stdout.isTTY) {
|
|
208584
209178
|
logger.warn("Insecure genesis reward wallet is active. Interactive confirmation skipped because this session is not a TTY.");
|
|
@@ -208590,6 +209184,12 @@ async function promptForInsecureGenesisConfirmation(logger) {
|
|
|
208590
209184
|
});
|
|
208591
209185
|
try {
|
|
208592
209186
|
await rl.question("Insecure genesis reward wallet is active. Hit RETURN to continue.");
|
|
209187
|
+
} catch (error) {
|
|
209188
|
+
if (isAbortError(error)) {
|
|
209189
|
+
logger.info("\nShutdown requested. Exiting.");
|
|
209190
|
+
process.exit(0);
|
|
209191
|
+
}
|
|
209192
|
+
throw error;
|
|
208593
209193
|
} finally {
|
|
208594
209194
|
rl.close();
|
|
208595
209195
|
}
|
|
@@ -208601,6 +209201,7 @@ async function getLocatorFromConfig(actors, configuration2) {
|
|
|
208601
209201
|
const { process: processConfig } = splitRunConfig(configuration2);
|
|
208602
209202
|
const fullConfig = assembleRunConfig(processConfig, actorConfigs, configuration2.mnemonic);
|
|
208603
209203
|
const logger = initLogger(configuration2);
|
|
209204
|
+
logger.info(formatStartupBanner(fullVersion, actors));
|
|
208604
209205
|
const orchestrator = await Orchestrator.create({ logger });
|
|
208605
209206
|
const collision = detectDerivationPathCollisions(actors, fullConfig);
|
|
208606
209207
|
if (collision) throw collision;
|
|
@@ -208623,11 +209224,11 @@ async function getLocatorFromConfig(actors, configuration2) {
|
|
|
208623
209224
|
process.on("SIGINT", () => {
|
|
208624
209225
|
(async () => {
|
|
208625
209226
|
try {
|
|
208626
|
-
logger.
|
|
209227
|
+
logger.info("\nShutdown requested. Attempting graceful shutdown...");
|
|
208627
209228
|
statusReporter?.setShuttingDown(true);
|
|
208628
209229
|
await statusHttpPublisher?.stop();
|
|
208629
209230
|
await orchestrator?.stop();
|
|
208630
|
-
logger.
|
|
209231
|
+
logger.info("Orchestrator stopped, exiting now.");
|
|
208631
209232
|
process.exit(0);
|
|
208632
209233
|
} catch (err) {
|
|
208633
209234
|
logger.error("Error stopping orchestrator:", err);
|
|
@@ -208643,7 +209244,7 @@ async function getLocatorFromConfig(actors, configuration2) {
|
|
|
208643
209244
|
async function runCLI() {
|
|
208644
209245
|
const y = Yargs(hideBin(process.argv));
|
|
208645
209246
|
await y.usage(`
|
|
208646
|
-
\u{1F680} XL1 Node CLI (${
|
|
209247
|
+
\u{1F680} XL1 Node CLI (${fullVersion})
|
|
208647
209248
|
${XL1LogoColorizedAscii}
|
|
208648
209249
|
Run various components of the XL1 ecosystem.
|
|
208649
209250
|
|
|
@@ -208689,7 +209290,7 @@ $0 <command> [options]`).parserConfiguration({
|
|
|
208689
209290
|
description: "Skip the interactive RETURN confirmation when the built-in dev mnemonic / insecure genesis reward wallet is active.",
|
|
208690
209291
|
default: false
|
|
208691
209292
|
}
|
|
208692
|
-
}).help().alias("help", "h").version(
|
|
209293
|
+
}).help().alias("help", "h").version(fullVersion).argv;
|
|
208693
209294
|
}
|
|
208694
209295
|
var start = async () => {
|
|
208695
209296
|
(0, import_main.config)({ quiet: true });
|