@dev.sail.money/sailor 0.0.2-27 → 0.0.2-28
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/AGENTS.md +2 -1
- package/README.md +11 -62
- package/package.json +3 -9
- package/packages/cli/dist/index.cjs +97 -174
- package/packages/cli/dist/server.cjs +1399 -584
- package/packages/sdk/dist/index.d.ts +0 -1
- package/packages/sdk/dist/index.d.ts.map +1 -1
- package/packages/sdk/dist/index.js +0 -1
- package/packages/sdk/dist/index.js.map +1 -1
- package/packages/sdk/dist/intelligence.d.ts +1 -1
- package/packages/sdk/dist/intelligence.js +1 -1
- package/packages/sdk/package.json +0 -28
- package/packages/ui/dist/assets/{add-qTuQMFTK.js → add-Cj0EIUcG.js} +1 -1
- package/packages/ui/dist/assets/{all-wallets-C-2_6Yfv.js → all-wallets-DlyRsWoN.js} +1 -1
- package/packages/ui/dist/assets/{app-store-DIz363Ij.js → app-store-CXP08sks.js} +1 -1
- package/packages/ui/dist/assets/{apple-Bm2XNMO1.js → apple-B62K6dJr.js} +1 -1
- package/packages/ui/dist/assets/{arrow-bottom-D7B-UpVg.js → arrow-bottom-BTuC5-tQ.js} +1 -1
- package/packages/ui/dist/assets/{arrow-bottom-circle-XB0ks3C3.js → arrow-bottom-circle-dlgFXE0q.js} +1 -1
- package/packages/ui/dist/assets/{arrow-left-_d9tAksG.js → arrow-left-Uohbz9c6.js} +1 -1
- package/packages/ui/dist/assets/{arrow-right-By10t6nk.js → arrow-right-CH0vSHgl.js} +1 -1
- package/packages/ui/dist/assets/{arrow-top-CrLIWHvo.js → arrow-top-CxY6BKDT.js} +1 -1
- package/packages/ui/dist/assets/{bank-DZC26LyI.js → bank-Dz6PlF79.js} +1 -1
- package/packages/ui/dist/assets/{basic-C2XYdmOJ.js → basic-CTV3Ph_S.js} +1 -1
- package/packages/ui/dist/assets/{browser-URMwBp02.js → browser-DBRTpG2H.js} +1 -1
- package/packages/ui/dist/assets/{card-DI1X7fa2.js → card-DWA4Ne8q.js} +1 -1
- package/packages/ui/dist/assets/{ccip-CkI0EKXG.js → ccip-CJCerfkJ.js} +1 -1
- package/packages/ui/dist/assets/{checkmark-DRPP3O33.js → checkmark-Cx-ePFrg.js} +1 -1
- package/packages/ui/dist/assets/{checkmark-bold-BXlTXuID.js → checkmark-bold-BhDIlGHD.js} +1 -1
- package/packages/ui/dist/assets/{chevron-bottom-BtIA5-Zw.js → chevron-bottom-2uFzesS3.js} +1 -1
- package/packages/ui/dist/assets/{chevron-left-CR6HwOU6.js → chevron-left-BoKXXZ4E.js} +1 -1
- package/packages/ui/dist/assets/{chevron-right-DubfEKW-.js → chevron-right-EUp-RhYw.js} +1 -1
- package/packages/ui/dist/assets/{chevron-top-BrZ5ZZx1.js → chevron-top-D51M78MN.js} +1 -1
- package/packages/ui/dist/assets/{chrome-store-DdtEbnZQ.js → chrome-store-DrRbU0Rc.js} +1 -1
- package/packages/ui/dist/assets/{clock-CbGzJbXx.js → clock-9mIuX-1G.js} +1 -1
- package/packages/ui/dist/assets/{close-BdZW5KIv.js → close-BvuXlx8s.js} +1 -1
- package/packages/ui/dist/assets/{coinPlaceholder-BXu1Nsdu.js → coinPlaceholder-Bi7hJj5a.js} +1 -1
- package/packages/ui/dist/assets/{compass-CZQzEYcb.js → compass-C623d6DE.js} +1 -1
- package/packages/ui/dist/assets/{copy-fCcrYd5O.js → copy-CFhZQkfE.js} +1 -1
- package/packages/ui/dist/assets/{core-B_rlQlCa.js → core-BGl4d2YS.js} +3 -3
- package/packages/ui/dist/assets/cursor-CUSm3LCL.js +3 -0
- package/packages/ui/dist/assets/{cursor-transparent-BvuhytdN.js → cursor-transparent-FBFMyBY2.js} +1 -1
- package/packages/ui/dist/assets/{desktop-AwX0UzWw.js → desktop-Cco6Py8z.js} +1 -1
- package/packages/ui/dist/assets/{disconnect-B2DnHNge.js → disconnect-GkX8GhOW.js} +1 -1
- package/packages/ui/dist/assets/{discord-CcFyxhBQ.js → discord-BNJe-HNX.js} +1 -1
- package/packages/ui/dist/assets/{etherscan-D5kNPWk4.js → etherscan-CoY2RMWw.js} +1 -1
- package/packages/ui/dist/assets/{events-C8ePWdzE.js → events-DlxPGhin.js} +1 -1
- package/packages/ui/dist/assets/{exclamation-triangle-DyQ_1Efw.js → exclamation-triangle-9thkvaBf.js} +1 -1
- package/packages/ui/dist/assets/{extension-jz2s06tW.js → extension-BshOJ_bn.js} +1 -1
- package/packages/ui/dist/assets/{external-link-2ybQxumz.js → external-link-97rok_V_.js} +1 -1
- package/packages/ui/dist/assets/{facebook-DS8jxA10.js → facebook-BsiLEVlU.js} +1 -1
- package/packages/ui/dist/assets/{fallback-B9fs84IX.js → fallback-DlWsoHyh.js} +1 -1
- package/packages/ui/dist/assets/{farcaster-BBJafyOu.js → farcaster-CmRL47La.js} +1 -1
- package/packages/ui/dist/assets/{filters-CNeaqp_S.js → filters-DXAWgNLO.js} +1 -1
- package/packages/ui/dist/assets/{github-Bc07zhCy.js → github-bCBJUbbe.js} +1 -1
- package/packages/ui/dist/assets/{google-v8uzPHNZ.js → google-CYTI0KrI.js} +1 -1
- package/packages/ui/dist/assets/{help-circle-DxtX1OZF.js → help-circle-LNgEbcGY.js} +1 -1
- package/packages/ui/dist/assets/{id-Br98ANoH.js → id-ChJn0Ugg.js} +1 -1
- package/packages/ui/dist/assets/{image-Bmk8NyWu.js → image--Y7maC5b.js} +1 -1
- package/packages/ui/dist/assets/{index-DK4KEqZ6.js → index-5MkegeeB.js} +3 -3
- package/packages/ui/dist/assets/{index-tz2OP5vg.js → index-BN0O-ZFZ.js} +39 -39
- package/packages/ui/dist/assets/{index-C8u3uWA-.js → index-BONuaN6W.js} +1 -1
- package/packages/ui/dist/assets/{index-D8e304bv.js → index-BlU0aZ21.js} +1 -1
- package/packages/ui/dist/assets/{index-C3xXe8Pu.js → index-CZMzzRJU.js} +1 -1
- package/packages/ui/dist/assets/{index-noDAXths.js → index-O4l6CrZ0.js} +1 -1
- package/packages/ui/dist/assets/index-n8bp1ZEc.css +1 -0
- package/packages/ui/dist/assets/{index.es-DO70eR0a.js → index.es-CXlLR_xG.js} +4 -4
- package/packages/ui/dist/assets/{info-Dm75IcvR.js → info-DUq1c6sJ.js} +1 -1
- package/packages/ui/dist/assets/{info-circle-COqN3U18.js → info-circle-UobJ0GGG.js} +1 -1
- package/packages/ui/dist/assets/{lightbulb-oXBKSpqT.js → lightbulb-BI4WR-IB.js} +1 -1
- package/packages/ui/dist/assets/{mail-CzH77S-9.js → mail-BSN2fVMe.js} +1 -1
- package/packages/ui/dist/assets/{metamask-sdk-kTTPRXnX.js → metamask-sdk-B7CK8pn-.js} +1 -1
- package/packages/ui/dist/assets/{mobile-DC8p7uWG.js → mobile-BfuUs9p7.js} +1 -1
- package/packages/ui/dist/assets/{more-CW76Ufwh.js → more-C1zkGuE3.js} +1 -1
- package/packages/ui/dist/assets/{network-placeholder-C-jgFto6.js → network-placeholder-CtiEl1UM.js} +1 -1
- package/packages/ui/dist/assets/{nftPlaceholder-CMNOse1o.js → nftPlaceholder-C_B9PGkr.js} +1 -1
- package/packages/ui/dist/assets/{off-BXAtst7s.js → off-B93fIkKw.js} +1 -1
- package/packages/ui/dist/assets/{parseSignature-huIOIOFv.js → parseSignature-BKzLunwo.js} +1 -1
- package/packages/ui/dist/assets/{play-store-CAA_V4_P.js → play-store-DfDTySLA.js} +1 -1
- package/packages/ui/dist/assets/{plus-o-2XxIRf.js → plus-_EYE7Soi.js} +1 -1
- package/packages/ui/dist/assets/{qr-code-BucbLbnn.js → qr-code-CSklhafe.js} +1 -1
- package/packages/ui/dist/assets/{recycle-horizontal-CzM8G600.js → recycle-horizontal-CoH2EBIZ.js} +1 -1
- package/packages/ui/dist/assets/{refresh-UBxc9Ujg.js → refresh-COGV5RR9.js} +1 -1
- package/packages/ui/dist/assets/{reown-logo-DouNSg_O.js → reown-logo-YYxIj6hm.js} +1 -1
- package/packages/ui/dist/assets/{search-B9_0X948.js → search-CpoWhaNF.js} +1 -1
- package/packages/ui/dist/assets/{secp256k1-CnLx1wuv.js → secp256k1-ZWo-L7nJ.js} +1 -1
- package/packages/ui/dist/assets/{send-D2ETNZ0F.js → send-CjEG2p8N.js} +1 -1
- package/packages/ui/dist/assets/{swapHorizontal-6R0tJDBj.js → swapHorizontal-3V6lypqD.js} +1 -1
- package/packages/ui/dist/assets/{swapHorizontalBold-YzWWnx8n.js → swapHorizontalBold-7swnGG5R.js} +1 -1
- package/packages/ui/dist/assets/{swapHorizontalMedium-DD4yeAY1.js → swapHorizontalMedium-zPdpOjAy.js} +1 -1
- package/packages/ui/dist/assets/{swapHorizontalRoundedBold-DmL4h2Mk.js → swapHorizontalRoundedBold-2Mxr5XPm.js} +1 -1
- package/packages/ui/dist/assets/{swapVertical-DWUQf-aB.js → swapVertical-D9KAlnz7.js} +1 -1
- package/packages/ui/dist/assets/{telegram-BWYqex9D.js → telegram-DztV38YW.js} +1 -1
- package/packages/ui/dist/assets/{three-dots-kuxAOnjJ.js → three-dots-DWOvYMr0.js} +1 -1
- package/packages/ui/dist/assets/{twitch-Cqjm9Lmi.js → twitch-B3UH6j0S.js} +1 -1
- package/packages/ui/dist/assets/{twitterIcon-qeJ4RH6T.js → twitterIcon-C2lA-xQv.js} +1 -1
- package/packages/ui/dist/assets/{verify-C2pfbtI7.js → verify-BP_uBvwh.js} +1 -1
- package/packages/ui/dist/assets/{verify-filled-DxEdt6vx.js → verify-filled-DLByZnlA.js} +1 -1
- package/packages/ui/dist/assets/{w3m-modal-Dm1gaw9i.js → w3m-modal-C2-cKwor.js} +1 -1
- package/packages/ui/dist/assets/{wallet-B7p1_8EB.js → wallet-Bc7LMFHM.js} +1 -1
- package/packages/ui/dist/assets/{wallet-placeholder-BY8k3n1-.js → wallet-placeholder-DsjujZQW.js} +1 -1
- package/packages/ui/dist/assets/{walletconnect-Bg6lRwqy.js → walletconnect-i_fC7jz3.js} +1 -1
- package/packages/ui/dist/assets/{warning-circle-DqLCpUJ0.js → warning-circle-DIxNhxFp.js} +1 -1
- package/packages/ui/dist/assets/{x-WtAqjAcW.js → x-BamJJInV.js} +1 -1
- package/packages/ui/dist/index.html +2 -2
- package/templates/default/examples/dca/agent.ts +1 -1
- package/templates/default/examples/dca/mandate.ts +1 -1
- package/templates/default/src/agent.ts +1 -1
- package/templates/default/tsconfig.json +2 -5
- package/templates/lifi-permissions/README.md +1 -1
- package/packages/sdk/dist/chains.d.ts +0 -12
- package/packages/sdk/dist/chains.d.ts.map +0 -1
- package/packages/sdk/dist/chains.js +0 -88
- package/packages/sdk/dist/chains.js.map +0 -1
- package/packages/ui/dist/assets/cursor-CNWux1oe.js +0 -3
- package/packages/ui/dist/assets/index-DCnJ64lX.css +0 -1
|
@@ -21541,7 +21541,7 @@ var require_mediaType = __commonJS({
|
|
|
21541
21541
|
var subtype = match[2];
|
|
21542
21542
|
var type = match[1];
|
|
21543
21543
|
if (match[3]) {
|
|
21544
|
-
var kvps =
|
|
21544
|
+
var kvps = splitParameters3(match[3]).map(splitKeyValuePair);
|
|
21545
21545
|
for (var j = 0; j < kvps.length; j++) {
|
|
21546
21546
|
var pair = kvps[j];
|
|
21547
21547
|
var key = pair[0].toLowerCase();
|
|
@@ -21659,7 +21659,7 @@ var require_mediaType = __commonJS({
|
|
|
21659
21659
|
accepts.length = j + 1;
|
|
21660
21660
|
return accepts;
|
|
21661
21661
|
}
|
|
21662
|
-
function
|
|
21662
|
+
function splitParameters3(str) {
|
|
21663
21663
|
var parameters = str.split(";");
|
|
21664
21664
|
for (var i = 1, j = 0; i < parameters.length; i++) {
|
|
21665
21665
|
if (quoteCount(parameters[j]) % 2 == 0) {
|
|
@@ -26374,7 +26374,7 @@ var require_websocket_server = __commonJS({
|
|
|
26374
26374
|
socket.on("error", socketOnError);
|
|
26375
26375
|
const key = req.headers["sec-websocket-key"];
|
|
26376
26376
|
const upgrade = req.headers.upgrade;
|
|
26377
|
-
const
|
|
26377
|
+
const version6 = +req.headers["sec-websocket-version"];
|
|
26378
26378
|
if (req.method !== "GET") {
|
|
26379
26379
|
const message = "Invalid HTTP method";
|
|
26380
26380
|
abortHandshakeOrEmitwsClientError(this, req, socket, 405, message);
|
|
@@ -26390,7 +26390,7 @@ var require_websocket_server = __commonJS({
|
|
|
26390
26390
|
abortHandshakeOrEmitwsClientError(this, req, socket, 400, message);
|
|
26391
26391
|
return;
|
|
26392
26392
|
}
|
|
26393
|
-
if (
|
|
26393
|
+
if (version6 !== 13 && version6 !== 8) {
|
|
26394
26394
|
const message = "Missing or invalid Sec-WebSocket-Version header";
|
|
26395
26395
|
abortHandshakeOrEmitwsClientError(this, req, socket, 400, message, {
|
|
26396
26396
|
"Sec-WebSocket-Version": "13, 8"
|
|
@@ -26434,7 +26434,7 @@ var require_websocket_server = __commonJS({
|
|
|
26434
26434
|
}
|
|
26435
26435
|
if (this.options.verifyClient) {
|
|
26436
26436
|
const info = {
|
|
26437
|
-
origin: req.headers[`${
|
|
26437
|
+
origin: req.headers[`${version6 === 8 ? "sec-websocket-origin" : "origin"}`],
|
|
26438
26438
|
secure: !!(req.socket.authorized || req.socket.encrypted),
|
|
26439
26439
|
req
|
|
26440
26440
|
};
|
|
@@ -26567,84 +26567,819 @@ var require_websocket_server = __commonJS({
|
|
|
26567
26567
|
}
|
|
26568
26568
|
});
|
|
26569
26569
|
|
|
26570
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/version.js
|
|
26571
|
+
var version;
|
|
26572
|
+
var init_version = __esm({
|
|
26573
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/version.js"() {
|
|
26574
|
+
version = "1.2.3";
|
|
26575
|
+
}
|
|
26576
|
+
});
|
|
26577
|
+
|
|
26578
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/errors.js
|
|
26579
|
+
var BaseError;
|
|
26580
|
+
var init_errors = __esm({
|
|
26581
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/errors.js"() {
|
|
26582
|
+
init_version();
|
|
26583
|
+
BaseError = class _BaseError extends Error {
|
|
26584
|
+
constructor(shortMessage, args = {}) {
|
|
26585
|
+
const details = args.cause instanceof _BaseError ? args.cause.details : args.cause?.message ? args.cause.message : args.details;
|
|
26586
|
+
const docsPath9 = args.cause instanceof _BaseError ? args.cause.docsPath || args.docsPath : args.docsPath;
|
|
26587
|
+
const message = [
|
|
26588
|
+
shortMessage || "An error occurred.",
|
|
26589
|
+
"",
|
|
26590
|
+
...args.metaMessages ? [...args.metaMessages, ""] : [],
|
|
26591
|
+
...docsPath9 ? [`Docs: https://abitype.dev${docsPath9}`] : [],
|
|
26592
|
+
...details ? [`Details: ${details}`] : [],
|
|
26593
|
+
`Version: abitype@${version}`
|
|
26594
|
+
].join("\n");
|
|
26595
|
+
super(message);
|
|
26596
|
+
Object.defineProperty(this, "details", {
|
|
26597
|
+
enumerable: true,
|
|
26598
|
+
configurable: true,
|
|
26599
|
+
writable: true,
|
|
26600
|
+
value: void 0
|
|
26601
|
+
});
|
|
26602
|
+
Object.defineProperty(this, "docsPath", {
|
|
26603
|
+
enumerable: true,
|
|
26604
|
+
configurable: true,
|
|
26605
|
+
writable: true,
|
|
26606
|
+
value: void 0
|
|
26607
|
+
});
|
|
26608
|
+
Object.defineProperty(this, "metaMessages", {
|
|
26609
|
+
enumerable: true,
|
|
26610
|
+
configurable: true,
|
|
26611
|
+
writable: true,
|
|
26612
|
+
value: void 0
|
|
26613
|
+
});
|
|
26614
|
+
Object.defineProperty(this, "shortMessage", {
|
|
26615
|
+
enumerable: true,
|
|
26616
|
+
configurable: true,
|
|
26617
|
+
writable: true,
|
|
26618
|
+
value: void 0
|
|
26619
|
+
});
|
|
26620
|
+
Object.defineProperty(this, "name", {
|
|
26621
|
+
enumerable: true,
|
|
26622
|
+
configurable: true,
|
|
26623
|
+
writable: true,
|
|
26624
|
+
value: "AbiTypeError"
|
|
26625
|
+
});
|
|
26626
|
+
if (args.cause)
|
|
26627
|
+
this.cause = args.cause;
|
|
26628
|
+
this.details = details;
|
|
26629
|
+
this.docsPath = docsPath9;
|
|
26630
|
+
this.metaMessages = args.metaMessages;
|
|
26631
|
+
this.shortMessage = shortMessage;
|
|
26632
|
+
}
|
|
26633
|
+
};
|
|
26634
|
+
}
|
|
26635
|
+
});
|
|
26636
|
+
|
|
26570
26637
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/regex.js
|
|
26571
26638
|
function execTyped(regex, string) {
|
|
26572
26639
|
const match = regex.exec(string);
|
|
26573
26640
|
return match?.groups;
|
|
26574
26641
|
}
|
|
26575
|
-
var
|
|
26576
|
-
|
|
26577
|
-
|
|
26578
|
-
|
|
26579
|
-
|
|
26580
|
-
|
|
26581
|
-
|
|
26582
|
-
|
|
26583
|
-
|
|
26584
|
-
|
|
26585
|
-
|
|
26642
|
+
var bytesRegex, integerRegex, isTupleRegex;
|
|
26643
|
+
var init_regex = __esm({
|
|
26644
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/regex.js"() {
|
|
26645
|
+
bytesRegex = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;
|
|
26646
|
+
integerRegex = /^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;
|
|
26647
|
+
isTupleRegex = /^\(.+?\).*?$/;
|
|
26648
|
+
}
|
|
26649
|
+
});
|
|
26650
|
+
|
|
26651
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiParameter.js
|
|
26652
|
+
function formatAbiParameter(abiParameter) {
|
|
26653
|
+
let type = abiParameter.type;
|
|
26654
|
+
if (tupleRegex.test(abiParameter.type) && "components" in abiParameter) {
|
|
26655
|
+
type = "(";
|
|
26656
|
+
const length = abiParameter.components.length;
|
|
26657
|
+
for (let i = 0; i < length; i++) {
|
|
26658
|
+
const component = abiParameter.components[i];
|
|
26659
|
+
type += formatAbiParameter(component);
|
|
26660
|
+
if (i < length - 1)
|
|
26661
|
+
type += ", ";
|
|
26662
|
+
}
|
|
26663
|
+
const result = execTyped(tupleRegex, abiParameter.type);
|
|
26664
|
+
type += `)${result?.array || ""}`;
|
|
26665
|
+
return formatAbiParameter({
|
|
26666
|
+
...abiParameter,
|
|
26667
|
+
type
|
|
26668
|
+
});
|
|
26669
|
+
}
|
|
26670
|
+
if ("indexed" in abiParameter && abiParameter.indexed)
|
|
26671
|
+
type = `${type} indexed`;
|
|
26672
|
+
if (abiParameter.name)
|
|
26673
|
+
return `${type} ${abiParameter.name}`;
|
|
26674
|
+
return type;
|
|
26675
|
+
}
|
|
26676
|
+
var tupleRegex;
|
|
26677
|
+
var init_formatAbiParameter = __esm({
|
|
26678
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiParameter.js"() {
|
|
26679
|
+
init_regex();
|
|
26680
|
+
tupleRegex = /^tuple(?<array>(\[(\d*)\])*)$/;
|
|
26681
|
+
}
|
|
26682
|
+
});
|
|
26683
|
+
|
|
26684
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiParameters.js
|
|
26685
|
+
function formatAbiParameters(abiParameters) {
|
|
26686
|
+
let params = "";
|
|
26687
|
+
const length = abiParameters.length;
|
|
26688
|
+
for (let i = 0; i < length; i++) {
|
|
26689
|
+
const abiParameter = abiParameters[i];
|
|
26690
|
+
params += formatAbiParameter(abiParameter);
|
|
26691
|
+
if (i !== length - 1)
|
|
26692
|
+
params += ", ";
|
|
26693
|
+
}
|
|
26694
|
+
return params;
|
|
26695
|
+
}
|
|
26696
|
+
var init_formatAbiParameters = __esm({
|
|
26697
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiParameters.js"() {
|
|
26698
|
+
init_formatAbiParameter();
|
|
26699
|
+
}
|
|
26700
|
+
});
|
|
26701
|
+
|
|
26702
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiItem.js
|
|
26703
|
+
function formatAbiItem(abiItem) {
|
|
26704
|
+
if (abiItem.type === "function")
|
|
26705
|
+
return `function ${abiItem.name}(${formatAbiParameters(abiItem.inputs)})${abiItem.stateMutability && abiItem.stateMutability !== "nonpayable" ? ` ${abiItem.stateMutability}` : ""}${abiItem.outputs?.length ? ` returns (${formatAbiParameters(abiItem.outputs)})` : ""}`;
|
|
26706
|
+
if (abiItem.type === "event")
|
|
26707
|
+
return `event ${abiItem.name}(${formatAbiParameters(abiItem.inputs)})`;
|
|
26708
|
+
if (abiItem.type === "error")
|
|
26709
|
+
return `error ${abiItem.name}(${formatAbiParameters(abiItem.inputs)})`;
|
|
26710
|
+
if (abiItem.type === "constructor")
|
|
26711
|
+
return `constructor(${formatAbiParameters(abiItem.inputs)})${abiItem.stateMutability === "payable" ? " payable" : ""}`;
|
|
26712
|
+
if (abiItem.type === "fallback")
|
|
26713
|
+
return `fallback() external${abiItem.stateMutability === "payable" ? " payable" : ""}`;
|
|
26714
|
+
return "receive() external payable";
|
|
26715
|
+
}
|
|
26716
|
+
var init_formatAbiItem = __esm({
|
|
26717
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/formatAbiItem.js"() {
|
|
26718
|
+
init_formatAbiParameters();
|
|
26719
|
+
}
|
|
26720
|
+
});
|
|
26721
|
+
|
|
26722
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/signatures.js
|
|
26723
|
+
function isErrorSignature(signature) {
|
|
26724
|
+
return errorSignatureRegex.test(signature);
|
|
26725
|
+
}
|
|
26726
|
+
function execErrorSignature(signature) {
|
|
26727
|
+
return execTyped(errorSignatureRegex, signature);
|
|
26728
|
+
}
|
|
26729
|
+
function isEventSignature(signature) {
|
|
26730
|
+
return eventSignatureRegex.test(signature);
|
|
26731
|
+
}
|
|
26732
|
+
function execEventSignature(signature) {
|
|
26733
|
+
return execTyped(eventSignatureRegex, signature);
|
|
26734
|
+
}
|
|
26735
|
+
function isFunctionSignature(signature) {
|
|
26736
|
+
return functionSignatureRegex.test(signature);
|
|
26737
|
+
}
|
|
26738
|
+
function execFunctionSignature(signature) {
|
|
26739
|
+
return execTyped(functionSignatureRegex, signature);
|
|
26740
|
+
}
|
|
26741
|
+
function isStructSignature(signature) {
|
|
26742
|
+
return structSignatureRegex.test(signature);
|
|
26743
|
+
}
|
|
26744
|
+
function execStructSignature(signature) {
|
|
26745
|
+
return execTyped(structSignatureRegex, signature);
|
|
26746
|
+
}
|
|
26747
|
+
function isConstructorSignature(signature) {
|
|
26748
|
+
return constructorSignatureRegex.test(signature);
|
|
26749
|
+
}
|
|
26750
|
+
function execConstructorSignature(signature) {
|
|
26751
|
+
return execTyped(constructorSignatureRegex, signature);
|
|
26752
|
+
}
|
|
26753
|
+
function isFallbackSignature(signature) {
|
|
26754
|
+
return fallbackSignatureRegex.test(signature);
|
|
26755
|
+
}
|
|
26756
|
+
function execFallbackSignature(signature) {
|
|
26757
|
+
return execTyped(fallbackSignatureRegex, signature);
|
|
26758
|
+
}
|
|
26759
|
+
function isReceiveSignature(signature) {
|
|
26760
|
+
return receiveSignatureRegex.test(signature);
|
|
26761
|
+
}
|
|
26762
|
+
var errorSignatureRegex, eventSignatureRegex, functionSignatureRegex, structSignatureRegex, constructorSignatureRegex, fallbackSignatureRegex, receiveSignatureRegex, eventModifiers, functionModifiers;
|
|
26763
|
+
var init_signatures = __esm({
|
|
26764
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/signatures.js"() {
|
|
26765
|
+
init_regex();
|
|
26766
|
+
errorSignatureRegex = /^error (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;
|
|
26767
|
+
eventSignatureRegex = /^event (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;
|
|
26768
|
+
functionSignatureRegex = /^function (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)(?: (?<scope>external|public{1}))?(?: (?<stateMutability>pure|view|nonpayable|payable{1}))?(?: returns\s?\((?<returns>.*?)\))?$/;
|
|
26769
|
+
structSignatureRegex = /^struct (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?<properties>.*?)\}$/;
|
|
26770
|
+
constructorSignatureRegex = /^constructor\((?<parameters>.*?)\)(?:\s(?<stateMutability>payable{1}))?$/;
|
|
26771
|
+
fallbackSignatureRegex = /^fallback\(\) external(?:\s(?<stateMutability>payable{1}))?$/;
|
|
26772
|
+
receiveSignatureRegex = /^receive\(\) external payable$/;
|
|
26773
|
+
eventModifiers = /* @__PURE__ */ new Set(["indexed"]);
|
|
26774
|
+
functionModifiers = /* @__PURE__ */ new Set([
|
|
26775
|
+
"calldata",
|
|
26776
|
+
"memory",
|
|
26777
|
+
"storage"
|
|
26778
|
+
]);
|
|
26779
|
+
}
|
|
26780
|
+
});
|
|
26781
|
+
|
|
26782
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/abiItem.js
|
|
26783
|
+
var UnknownTypeError, UnknownSolidityTypeError;
|
|
26784
|
+
var init_abiItem = __esm({
|
|
26785
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/abiItem.js"() {
|
|
26786
|
+
init_errors();
|
|
26787
|
+
UnknownTypeError = class extends BaseError {
|
|
26788
|
+
constructor({ type }) {
|
|
26789
|
+
super("Unknown type.", {
|
|
26790
|
+
metaMessages: [
|
|
26791
|
+
`Type "${type}" is not a valid ABI type. Perhaps you forgot to include a struct signature?`
|
|
26792
|
+
]
|
|
26793
|
+
});
|
|
26794
|
+
Object.defineProperty(this, "name", {
|
|
26795
|
+
enumerable: true,
|
|
26796
|
+
configurable: true,
|
|
26797
|
+
writable: true,
|
|
26798
|
+
value: "UnknownTypeError"
|
|
26799
|
+
});
|
|
26800
|
+
}
|
|
26801
|
+
};
|
|
26802
|
+
UnknownSolidityTypeError = class extends BaseError {
|
|
26803
|
+
constructor({ type }) {
|
|
26804
|
+
super("Unknown type.", {
|
|
26805
|
+
metaMessages: [`Type "${type}" is not a valid ABI type.`]
|
|
26806
|
+
});
|
|
26807
|
+
Object.defineProperty(this, "name", {
|
|
26808
|
+
enumerable: true,
|
|
26809
|
+
configurable: true,
|
|
26810
|
+
writable: true,
|
|
26811
|
+
value: "UnknownSolidityTypeError"
|
|
26812
|
+
});
|
|
26813
|
+
}
|
|
26814
|
+
};
|
|
26815
|
+
}
|
|
26816
|
+
});
|
|
26817
|
+
|
|
26818
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/abiParameter.js
|
|
26819
|
+
var InvalidParameterError, SolidityProtectedKeywordError, InvalidModifierError, InvalidFunctionModifierError, InvalidAbiTypeParameterError;
|
|
26820
|
+
var init_abiParameter = __esm({
|
|
26821
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/abiParameter.js"() {
|
|
26822
|
+
init_errors();
|
|
26823
|
+
InvalidParameterError = class extends BaseError {
|
|
26824
|
+
constructor({ param }) {
|
|
26825
|
+
super("Invalid ABI parameter.", {
|
|
26826
|
+
details: param
|
|
26827
|
+
});
|
|
26828
|
+
Object.defineProperty(this, "name", {
|
|
26829
|
+
enumerable: true,
|
|
26830
|
+
configurable: true,
|
|
26831
|
+
writable: true,
|
|
26832
|
+
value: "InvalidParameterError"
|
|
26833
|
+
});
|
|
26834
|
+
}
|
|
26835
|
+
};
|
|
26836
|
+
SolidityProtectedKeywordError = class extends BaseError {
|
|
26837
|
+
constructor({ param, name }) {
|
|
26838
|
+
super("Invalid ABI parameter.", {
|
|
26839
|
+
details: param,
|
|
26840
|
+
metaMessages: [
|
|
26841
|
+
`"${name}" is a protected Solidity keyword. More info: https://docs.soliditylang.org/en/latest/cheatsheet.html`
|
|
26842
|
+
]
|
|
26843
|
+
});
|
|
26844
|
+
Object.defineProperty(this, "name", {
|
|
26845
|
+
enumerable: true,
|
|
26846
|
+
configurable: true,
|
|
26847
|
+
writable: true,
|
|
26848
|
+
value: "SolidityProtectedKeywordError"
|
|
26849
|
+
});
|
|
26850
|
+
}
|
|
26851
|
+
};
|
|
26852
|
+
InvalidModifierError = class extends BaseError {
|
|
26853
|
+
constructor({ param, type, modifier }) {
|
|
26854
|
+
super("Invalid ABI parameter.", {
|
|
26855
|
+
details: param,
|
|
26856
|
+
metaMessages: [
|
|
26857
|
+
`Modifier "${modifier}" not allowed${type ? ` in "${type}" type` : ""}.`
|
|
26858
|
+
]
|
|
26859
|
+
});
|
|
26860
|
+
Object.defineProperty(this, "name", {
|
|
26861
|
+
enumerable: true,
|
|
26862
|
+
configurable: true,
|
|
26863
|
+
writable: true,
|
|
26864
|
+
value: "InvalidModifierError"
|
|
26865
|
+
});
|
|
26866
|
+
}
|
|
26867
|
+
};
|
|
26868
|
+
InvalidFunctionModifierError = class extends BaseError {
|
|
26869
|
+
constructor({ param, type, modifier }) {
|
|
26870
|
+
super("Invalid ABI parameter.", {
|
|
26871
|
+
details: param,
|
|
26872
|
+
metaMessages: [
|
|
26873
|
+
`Modifier "${modifier}" not allowed${type ? ` in "${type}" type` : ""}.`,
|
|
26874
|
+
`Data location can only be specified for array, struct, or mapping types, but "${modifier}" was given.`
|
|
26875
|
+
]
|
|
26876
|
+
});
|
|
26877
|
+
Object.defineProperty(this, "name", {
|
|
26878
|
+
enumerable: true,
|
|
26879
|
+
configurable: true,
|
|
26880
|
+
writable: true,
|
|
26881
|
+
value: "InvalidFunctionModifierError"
|
|
26882
|
+
});
|
|
26883
|
+
}
|
|
26884
|
+
};
|
|
26885
|
+
InvalidAbiTypeParameterError = class extends BaseError {
|
|
26886
|
+
constructor({ abiParameter }) {
|
|
26887
|
+
super("Invalid ABI parameter.", {
|
|
26888
|
+
details: JSON.stringify(abiParameter, null, 2),
|
|
26889
|
+
metaMessages: ["ABI parameter type is invalid."]
|
|
26890
|
+
});
|
|
26891
|
+
Object.defineProperty(this, "name", {
|
|
26892
|
+
enumerable: true,
|
|
26893
|
+
configurable: true,
|
|
26894
|
+
writable: true,
|
|
26895
|
+
value: "InvalidAbiTypeParameterError"
|
|
26896
|
+
});
|
|
26897
|
+
}
|
|
26898
|
+
};
|
|
26899
|
+
}
|
|
26900
|
+
});
|
|
26901
|
+
|
|
26902
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/signature.js
|
|
26903
|
+
var InvalidSignatureError, UnknownSignatureError, InvalidStructSignatureError;
|
|
26904
|
+
var init_signature = __esm({
|
|
26905
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/signature.js"() {
|
|
26906
|
+
init_errors();
|
|
26907
|
+
InvalidSignatureError = class extends BaseError {
|
|
26908
|
+
constructor({ signature, type }) {
|
|
26909
|
+
super(`Invalid ${type} signature.`, {
|
|
26910
|
+
details: signature
|
|
26911
|
+
});
|
|
26912
|
+
Object.defineProperty(this, "name", {
|
|
26913
|
+
enumerable: true,
|
|
26914
|
+
configurable: true,
|
|
26915
|
+
writable: true,
|
|
26916
|
+
value: "InvalidSignatureError"
|
|
26917
|
+
});
|
|
26918
|
+
}
|
|
26919
|
+
};
|
|
26920
|
+
UnknownSignatureError = class extends BaseError {
|
|
26921
|
+
constructor({ signature }) {
|
|
26922
|
+
super("Unknown signature.", {
|
|
26923
|
+
details: signature
|
|
26924
|
+
});
|
|
26925
|
+
Object.defineProperty(this, "name", {
|
|
26926
|
+
enumerable: true,
|
|
26927
|
+
configurable: true,
|
|
26928
|
+
writable: true,
|
|
26929
|
+
value: "UnknownSignatureError"
|
|
26930
|
+
});
|
|
26931
|
+
}
|
|
26932
|
+
};
|
|
26933
|
+
InvalidStructSignatureError = class extends BaseError {
|
|
26934
|
+
constructor({ signature }) {
|
|
26935
|
+
super("Invalid struct signature.", {
|
|
26936
|
+
details: signature,
|
|
26937
|
+
metaMessages: ["No properties exist."]
|
|
26938
|
+
});
|
|
26939
|
+
Object.defineProperty(this, "name", {
|
|
26940
|
+
enumerable: true,
|
|
26941
|
+
configurable: true,
|
|
26942
|
+
writable: true,
|
|
26943
|
+
value: "InvalidStructSignatureError"
|
|
26944
|
+
});
|
|
26945
|
+
}
|
|
26946
|
+
};
|
|
26947
|
+
}
|
|
26948
|
+
});
|
|
26949
|
+
|
|
26950
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/struct.js
|
|
26951
|
+
var CircularReferenceError;
|
|
26952
|
+
var init_struct = __esm({
|
|
26953
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/struct.js"() {
|
|
26954
|
+
init_errors();
|
|
26955
|
+
CircularReferenceError = class extends BaseError {
|
|
26956
|
+
constructor({ type }) {
|
|
26957
|
+
super("Circular reference detected.", {
|
|
26958
|
+
metaMessages: [`Struct "${type}" is a circular reference.`]
|
|
26959
|
+
});
|
|
26960
|
+
Object.defineProperty(this, "name", {
|
|
26961
|
+
enumerable: true,
|
|
26962
|
+
configurable: true,
|
|
26963
|
+
writable: true,
|
|
26964
|
+
value: "CircularReferenceError"
|
|
26965
|
+
});
|
|
26966
|
+
}
|
|
26967
|
+
};
|
|
26968
|
+
}
|
|
26969
|
+
});
|
|
26970
|
+
|
|
26971
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/splitParameters.js
|
|
26972
|
+
var InvalidParenthesisError;
|
|
26973
|
+
var init_splitParameters = __esm({
|
|
26974
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/errors/splitParameters.js"() {
|
|
26975
|
+
init_errors();
|
|
26976
|
+
InvalidParenthesisError = class extends BaseError {
|
|
26977
|
+
constructor({ current, depth }) {
|
|
26978
|
+
super("Unbalanced parentheses.", {
|
|
26979
|
+
metaMessages: [
|
|
26980
|
+
`"${current.trim()}" has too many ${depth > 0 ? "opening" : "closing"} parentheses.`
|
|
26981
|
+
],
|
|
26982
|
+
details: `Depth "${depth}"`
|
|
26983
|
+
});
|
|
26984
|
+
Object.defineProperty(this, "name", {
|
|
26985
|
+
enumerable: true,
|
|
26986
|
+
configurable: true,
|
|
26987
|
+
writable: true,
|
|
26988
|
+
value: "InvalidParenthesisError"
|
|
26989
|
+
});
|
|
26990
|
+
}
|
|
26991
|
+
};
|
|
26992
|
+
}
|
|
26993
|
+
});
|
|
26994
|
+
|
|
26995
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/cache.js
|
|
26996
|
+
function getParameterCacheKey(param, type, structs) {
|
|
26997
|
+
let structKey = "";
|
|
26998
|
+
if (structs)
|
|
26999
|
+
for (const struct of Object.entries(structs)) {
|
|
27000
|
+
if (!struct)
|
|
27001
|
+
continue;
|
|
27002
|
+
let propertyKey = "";
|
|
27003
|
+
for (const property of struct[1]) {
|
|
27004
|
+
propertyKey += `[${property.type}${property.name ? `:${property.name}` : ""}]`;
|
|
27005
|
+
}
|
|
27006
|
+
structKey += `(${struct[0]}{${propertyKey}})`;
|
|
27007
|
+
}
|
|
27008
|
+
if (type)
|
|
27009
|
+
return `${type}:${param}${structKey}`;
|
|
27010
|
+
return `${param}${structKey}`;
|
|
27011
|
+
}
|
|
27012
|
+
var parameterCache;
|
|
27013
|
+
var init_cache = __esm({
|
|
27014
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/cache.js"() {
|
|
27015
|
+
parameterCache = /* @__PURE__ */ new Map([
|
|
27016
|
+
// Unnamed
|
|
27017
|
+
["address", { type: "address" }],
|
|
27018
|
+
["bool", { type: "bool" }],
|
|
27019
|
+
["bytes", { type: "bytes" }],
|
|
27020
|
+
["bytes32", { type: "bytes32" }],
|
|
27021
|
+
["int", { type: "int256" }],
|
|
27022
|
+
["int256", { type: "int256" }],
|
|
27023
|
+
["string", { type: "string" }],
|
|
27024
|
+
["uint", { type: "uint256" }],
|
|
27025
|
+
["uint8", { type: "uint8" }],
|
|
27026
|
+
["uint16", { type: "uint16" }],
|
|
27027
|
+
["uint24", { type: "uint24" }],
|
|
27028
|
+
["uint32", { type: "uint32" }],
|
|
27029
|
+
["uint64", { type: "uint64" }],
|
|
27030
|
+
["uint96", { type: "uint96" }],
|
|
27031
|
+
["uint112", { type: "uint112" }],
|
|
27032
|
+
["uint160", { type: "uint160" }],
|
|
27033
|
+
["uint192", { type: "uint192" }],
|
|
27034
|
+
["uint256", { type: "uint256" }],
|
|
27035
|
+
// Named
|
|
27036
|
+
["address owner", { type: "address", name: "owner" }],
|
|
27037
|
+
["address to", { type: "address", name: "to" }],
|
|
27038
|
+
["bool approved", { type: "bool", name: "approved" }],
|
|
27039
|
+
["bytes _data", { type: "bytes", name: "_data" }],
|
|
27040
|
+
["bytes data", { type: "bytes", name: "data" }],
|
|
27041
|
+
["bytes signature", { type: "bytes", name: "signature" }],
|
|
27042
|
+
["bytes32 hash", { type: "bytes32", name: "hash" }],
|
|
27043
|
+
["bytes32 r", { type: "bytes32", name: "r" }],
|
|
27044
|
+
["bytes32 root", { type: "bytes32", name: "root" }],
|
|
27045
|
+
["bytes32 s", { type: "bytes32", name: "s" }],
|
|
27046
|
+
["string name", { type: "string", name: "name" }],
|
|
27047
|
+
["string symbol", { type: "string", name: "symbol" }],
|
|
27048
|
+
["string tokenURI", { type: "string", name: "tokenURI" }],
|
|
27049
|
+
["uint tokenId", { type: "uint256", name: "tokenId" }],
|
|
27050
|
+
["uint8 v", { type: "uint8", name: "v" }],
|
|
27051
|
+
["uint256 balance", { type: "uint256", name: "balance" }],
|
|
27052
|
+
["uint256 tokenId", { type: "uint256", name: "tokenId" }],
|
|
27053
|
+
["uint256 value", { type: "uint256", name: "value" }],
|
|
27054
|
+
// Indexed
|
|
27055
|
+
[
|
|
27056
|
+
"event:address indexed from",
|
|
27057
|
+
{ type: "address", name: "from", indexed: true }
|
|
27058
|
+
],
|
|
27059
|
+
["event:address indexed to", { type: "address", name: "to", indexed: true }],
|
|
27060
|
+
[
|
|
27061
|
+
"event:uint indexed tokenId",
|
|
27062
|
+
{ type: "uint256", name: "tokenId", indexed: true }
|
|
27063
|
+
],
|
|
27064
|
+
[
|
|
27065
|
+
"event:uint256 indexed tokenId",
|
|
27066
|
+
{ type: "uint256", name: "tokenId", indexed: true }
|
|
27067
|
+
]
|
|
27068
|
+
]);
|
|
27069
|
+
}
|
|
27070
|
+
});
|
|
27071
|
+
|
|
27072
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/utils.js
|
|
27073
|
+
function parseSignature(signature, structs = {}) {
|
|
27074
|
+
if (isFunctionSignature(signature))
|
|
27075
|
+
return parseFunctionSignature(signature, structs);
|
|
27076
|
+
if (isEventSignature(signature))
|
|
27077
|
+
return parseEventSignature(signature, structs);
|
|
27078
|
+
if (isErrorSignature(signature))
|
|
27079
|
+
return parseErrorSignature(signature, structs);
|
|
27080
|
+
if (isConstructorSignature(signature))
|
|
27081
|
+
return parseConstructorSignature(signature, structs);
|
|
27082
|
+
if (isFallbackSignature(signature))
|
|
27083
|
+
return parseFallbackSignature(signature);
|
|
27084
|
+
if (isReceiveSignature(signature))
|
|
27085
|
+
return {
|
|
27086
|
+
type: "receive",
|
|
27087
|
+
stateMutability: "payable"
|
|
27088
|
+
};
|
|
27089
|
+
throw new UnknownSignatureError({ signature });
|
|
27090
|
+
}
|
|
27091
|
+
function parseFunctionSignature(signature, structs = {}) {
|
|
27092
|
+
const match = execFunctionSignature(signature);
|
|
27093
|
+
if (!match)
|
|
27094
|
+
throw new InvalidSignatureError({ signature, type: "function" });
|
|
27095
|
+
const inputParams = splitParameters(match.parameters);
|
|
27096
|
+
const inputs = [];
|
|
27097
|
+
const inputLength = inputParams.length;
|
|
27098
|
+
for (let i = 0; i < inputLength; i++) {
|
|
27099
|
+
inputs.push(parseAbiParameter(inputParams[i], {
|
|
27100
|
+
modifiers: functionModifiers,
|
|
27101
|
+
structs,
|
|
27102
|
+
type: "function"
|
|
27103
|
+
}));
|
|
27104
|
+
}
|
|
27105
|
+
const outputs = [];
|
|
27106
|
+
if (match.returns) {
|
|
27107
|
+
const outputParams = splitParameters(match.returns);
|
|
27108
|
+
const outputLength = outputParams.length;
|
|
27109
|
+
for (let i = 0; i < outputLength; i++) {
|
|
27110
|
+
outputs.push(parseAbiParameter(outputParams[i], {
|
|
27111
|
+
modifiers: functionModifiers,
|
|
27112
|
+
structs,
|
|
27113
|
+
type: "function"
|
|
27114
|
+
}));
|
|
27115
|
+
}
|
|
27116
|
+
}
|
|
27117
|
+
return {
|
|
27118
|
+
name: match.name,
|
|
27119
|
+
type: "function",
|
|
27120
|
+
stateMutability: match.stateMutability ?? "nonpayable",
|
|
27121
|
+
inputs,
|
|
27122
|
+
outputs
|
|
27123
|
+
};
|
|
27124
|
+
}
|
|
27125
|
+
function parseEventSignature(signature, structs = {}) {
|
|
27126
|
+
const match = execEventSignature(signature);
|
|
27127
|
+
if (!match)
|
|
27128
|
+
throw new InvalidSignatureError({ signature, type: "event" });
|
|
27129
|
+
const params = splitParameters(match.parameters);
|
|
27130
|
+
const abiParameters = [];
|
|
27131
|
+
const length = params.length;
|
|
27132
|
+
for (let i = 0; i < length; i++)
|
|
27133
|
+
abiParameters.push(parseAbiParameter(params[i], {
|
|
27134
|
+
modifiers: eventModifiers,
|
|
27135
|
+
structs,
|
|
27136
|
+
type: "event"
|
|
27137
|
+
}));
|
|
27138
|
+
return { name: match.name, type: "event", inputs: abiParameters };
|
|
27139
|
+
}
|
|
27140
|
+
function parseErrorSignature(signature, structs = {}) {
|
|
27141
|
+
const match = execErrorSignature(signature);
|
|
27142
|
+
if (!match)
|
|
27143
|
+
throw new InvalidSignatureError({ signature, type: "error" });
|
|
27144
|
+
const params = splitParameters(match.parameters);
|
|
27145
|
+
const abiParameters = [];
|
|
27146
|
+
const length = params.length;
|
|
27147
|
+
for (let i = 0; i < length; i++)
|
|
27148
|
+
abiParameters.push(parseAbiParameter(params[i], { structs, type: "error" }));
|
|
27149
|
+
return { name: match.name, type: "error", inputs: abiParameters };
|
|
27150
|
+
}
|
|
27151
|
+
function parseConstructorSignature(signature, structs = {}) {
|
|
27152
|
+
const match = execConstructorSignature(signature);
|
|
27153
|
+
if (!match)
|
|
27154
|
+
throw new InvalidSignatureError({ signature, type: "constructor" });
|
|
27155
|
+
const params = splitParameters(match.parameters);
|
|
27156
|
+
const abiParameters = [];
|
|
27157
|
+
const length = params.length;
|
|
27158
|
+
for (let i = 0; i < length; i++)
|
|
27159
|
+
abiParameters.push(parseAbiParameter(params[i], { structs, type: "constructor" }));
|
|
27160
|
+
return {
|
|
27161
|
+
type: "constructor",
|
|
27162
|
+
stateMutability: match.stateMutability ?? "nonpayable",
|
|
27163
|
+
inputs: abiParameters
|
|
27164
|
+
};
|
|
27165
|
+
}
|
|
27166
|
+
function parseFallbackSignature(signature) {
|
|
27167
|
+
const match = execFallbackSignature(signature);
|
|
27168
|
+
if (!match)
|
|
27169
|
+
throw new InvalidSignatureError({ signature, type: "fallback" });
|
|
27170
|
+
return {
|
|
27171
|
+
type: "fallback",
|
|
27172
|
+
stateMutability: match.stateMutability ?? "nonpayable"
|
|
27173
|
+
};
|
|
27174
|
+
}
|
|
27175
|
+
function parseAbiParameter(param, options) {
|
|
27176
|
+
const parameterCacheKey = getParameterCacheKey(param, options?.type, options?.structs);
|
|
27177
|
+
if (parameterCache.has(parameterCacheKey))
|
|
27178
|
+
return parameterCache.get(parameterCacheKey);
|
|
27179
|
+
const isTuple = isTupleRegex.test(param);
|
|
27180
|
+
const match = execTyped(isTuple ? abiParameterWithTupleRegex : abiParameterWithoutTupleRegex, param);
|
|
27181
|
+
if (!match)
|
|
27182
|
+
throw new InvalidParameterError({ param });
|
|
27183
|
+
if (match.name && isSolidityKeyword(match.name))
|
|
27184
|
+
throw new SolidityProtectedKeywordError({ param, name: match.name });
|
|
27185
|
+
const name = match.name ? { name: match.name } : {};
|
|
27186
|
+
const indexed = match.modifier === "indexed" ? { indexed: true } : {};
|
|
27187
|
+
const structs = options?.structs ?? {};
|
|
27188
|
+
let type;
|
|
27189
|
+
let components = {};
|
|
27190
|
+
if (isTuple) {
|
|
27191
|
+
type = "tuple";
|
|
27192
|
+
const params = splitParameters(match.type);
|
|
27193
|
+
const components_ = [];
|
|
27194
|
+
const length = params.length;
|
|
26586
27195
|
for (let i = 0; i < length; i++) {
|
|
26587
|
-
|
|
26588
|
-
type += formatAbiParameter(component);
|
|
26589
|
-
if (i < length - 1)
|
|
26590
|
-
type += ", ";
|
|
27196
|
+
components_.push(parseAbiParameter(params[i], { structs }));
|
|
26591
27197
|
}
|
|
26592
|
-
|
|
26593
|
-
|
|
26594
|
-
|
|
26595
|
-
|
|
26596
|
-
|
|
26597
|
-
}
|
|
27198
|
+
components = { components: components_ };
|
|
27199
|
+
} else if (match.type in structs) {
|
|
27200
|
+
type = "tuple";
|
|
27201
|
+
components = { components: structs[match.type] };
|
|
27202
|
+
} else if (dynamicIntegerRegex.test(match.type)) {
|
|
27203
|
+
type = `${match.type}256`;
|
|
27204
|
+
} else if (match.type === "address payable") {
|
|
27205
|
+
type = "address";
|
|
27206
|
+
} else {
|
|
27207
|
+
type = match.type;
|
|
27208
|
+
if (!(options?.type === "struct") && !isSolidityType(type))
|
|
27209
|
+
throw new UnknownSolidityTypeError({ type });
|
|
26598
27210
|
}
|
|
26599
|
-
if (
|
|
26600
|
-
|
|
26601
|
-
|
|
26602
|
-
|
|
26603
|
-
|
|
27211
|
+
if (match.modifier) {
|
|
27212
|
+
if (!options?.modifiers?.has?.(match.modifier))
|
|
27213
|
+
throw new InvalidModifierError({
|
|
27214
|
+
param,
|
|
27215
|
+
type: options?.type,
|
|
27216
|
+
modifier: match.modifier
|
|
27217
|
+
});
|
|
27218
|
+
if (functionModifiers.has(match.modifier) && !isValidDataLocation(type, !!match.array))
|
|
27219
|
+
throw new InvalidFunctionModifierError({
|
|
27220
|
+
param,
|
|
27221
|
+
type: options?.type,
|
|
27222
|
+
modifier: match.modifier
|
|
27223
|
+
});
|
|
27224
|
+
}
|
|
27225
|
+
const abiParameter = {
|
|
27226
|
+
type: `${type}${match.array ?? ""}`,
|
|
27227
|
+
...name,
|
|
27228
|
+
...indexed,
|
|
27229
|
+
...components
|
|
27230
|
+
};
|
|
27231
|
+
parameterCache.set(parameterCacheKey, abiParameter);
|
|
27232
|
+
return abiParameter;
|
|
26604
27233
|
}
|
|
26605
|
-
|
|
26606
|
-
|
|
26607
|
-
|
|
27234
|
+
function splitParameters(params, result = [], current = "", depth = 0) {
|
|
27235
|
+
const length = params.trim().length;
|
|
27236
|
+
for (let i = 0; i < length; i++) {
|
|
27237
|
+
const char = params[i];
|
|
27238
|
+
const tail = params.slice(i + 1);
|
|
27239
|
+
switch (char) {
|
|
27240
|
+
case ",":
|
|
27241
|
+
return depth === 0 ? splitParameters(tail, [...result, current.trim()]) : splitParameters(tail, result, `${current}${char}`, depth);
|
|
27242
|
+
case "(":
|
|
27243
|
+
return splitParameters(tail, result, `${current}${char}`, depth + 1);
|
|
27244
|
+
case ")":
|
|
27245
|
+
return splitParameters(tail, result, `${current}${char}`, depth - 1);
|
|
27246
|
+
default:
|
|
27247
|
+
return splitParameters(tail, result, `${current}${char}`, depth);
|
|
27248
|
+
}
|
|
27249
|
+
}
|
|
27250
|
+
if (current === "")
|
|
27251
|
+
return result;
|
|
27252
|
+
if (depth !== 0)
|
|
27253
|
+
throw new InvalidParenthesisError({ current, depth });
|
|
27254
|
+
result.push(current.trim());
|
|
27255
|
+
return result;
|
|
27256
|
+
}
|
|
27257
|
+
function isSolidityType(type) {
|
|
27258
|
+
return type === "address" || type === "bool" || type === "function" || type === "string" || bytesRegex.test(type) || integerRegex.test(type);
|
|
27259
|
+
}
|
|
27260
|
+
function isSolidityKeyword(name) {
|
|
27261
|
+
return name === "address" || name === "bool" || name === "function" || name === "string" || name === "tuple" || bytesRegex.test(name) || integerRegex.test(name) || protectedKeywordsRegex.test(name);
|
|
27262
|
+
}
|
|
27263
|
+
function isValidDataLocation(type, isArray) {
|
|
27264
|
+
return isArray || type === "bytes" || type === "string" || type === "tuple";
|
|
27265
|
+
}
|
|
27266
|
+
var abiParameterWithoutTupleRegex, abiParameterWithTupleRegex, dynamicIntegerRegex, protectedKeywordsRegex;
|
|
27267
|
+
var init_utils = __esm({
|
|
27268
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/utils.js"() {
|
|
26608
27269
|
init_regex();
|
|
26609
|
-
|
|
27270
|
+
init_abiItem();
|
|
27271
|
+
init_abiParameter();
|
|
27272
|
+
init_signature();
|
|
27273
|
+
init_splitParameters();
|
|
27274
|
+
init_cache();
|
|
27275
|
+
init_signatures();
|
|
27276
|
+
abiParameterWithoutTupleRegex = /^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*(?:\spayable)?)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/;
|
|
27277
|
+
abiParameterWithTupleRegex = /^\((?<type>.+?)\)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/;
|
|
27278
|
+
dynamicIntegerRegex = /^u?int$/;
|
|
27279
|
+
protectedKeywordsRegex = /^(?:after|alias|anonymous|apply|auto|byte|calldata|case|catch|constant|copyof|default|defined|error|event|external|false|final|function|immutable|implements|in|indexed|inline|internal|let|mapping|match|memory|mutable|null|of|override|partial|private|promise|public|pure|reference|relocatable|return|returns|sizeof|static|storage|struct|super|supports|switch|this|true|try|typedef|typeof|var|view|virtual)$/;
|
|
26610
27280
|
}
|
|
26611
27281
|
});
|
|
26612
27282
|
|
|
26613
|
-
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/
|
|
26614
|
-
function
|
|
26615
|
-
|
|
27283
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/structs.js
|
|
27284
|
+
function parseStructs(signatures) {
|
|
27285
|
+
const shallowStructs = {};
|
|
27286
|
+
const signaturesLength = signatures.length;
|
|
27287
|
+
for (let i = 0; i < signaturesLength; i++) {
|
|
27288
|
+
const signature = signatures[i];
|
|
27289
|
+
if (!isStructSignature(signature))
|
|
27290
|
+
continue;
|
|
27291
|
+
const match = execStructSignature(signature);
|
|
27292
|
+
if (!match)
|
|
27293
|
+
throw new InvalidSignatureError({ signature, type: "struct" });
|
|
27294
|
+
const properties = match.properties.split(";");
|
|
27295
|
+
const components = [];
|
|
27296
|
+
const propertiesLength = properties.length;
|
|
27297
|
+
for (let k = 0; k < propertiesLength; k++) {
|
|
27298
|
+
const property = properties[k];
|
|
27299
|
+
const trimmed = property.trim();
|
|
27300
|
+
if (!trimmed)
|
|
27301
|
+
continue;
|
|
27302
|
+
const abiParameter = parseAbiParameter(trimmed, {
|
|
27303
|
+
type: "struct"
|
|
27304
|
+
});
|
|
27305
|
+
components.push(abiParameter);
|
|
27306
|
+
}
|
|
27307
|
+
if (!components.length)
|
|
27308
|
+
throw new InvalidStructSignatureError({ signature });
|
|
27309
|
+
shallowStructs[match.name] = components;
|
|
27310
|
+
}
|
|
27311
|
+
const resolvedStructs = {};
|
|
27312
|
+
const entries = Object.entries(shallowStructs);
|
|
27313
|
+
const entriesLength = entries.length;
|
|
27314
|
+
for (let i = 0; i < entriesLength; i++) {
|
|
27315
|
+
const [name, parameters] = entries[i];
|
|
27316
|
+
resolvedStructs[name] = resolveStructs(parameters, shallowStructs);
|
|
27317
|
+
}
|
|
27318
|
+
return resolvedStructs;
|
|
27319
|
+
}
|
|
27320
|
+
function resolveStructs(abiParameters = [], structs = {}, ancestors = /* @__PURE__ */ new Set()) {
|
|
27321
|
+
const components = [];
|
|
26616
27322
|
const length = abiParameters.length;
|
|
26617
27323
|
for (let i = 0; i < length; i++) {
|
|
26618
27324
|
const abiParameter = abiParameters[i];
|
|
26619
|
-
|
|
26620
|
-
if (
|
|
26621
|
-
|
|
27325
|
+
const isTuple = isTupleRegex.test(abiParameter.type);
|
|
27326
|
+
if (isTuple)
|
|
27327
|
+
components.push(abiParameter);
|
|
27328
|
+
else {
|
|
27329
|
+
const match = execTyped(typeWithoutTupleRegex, abiParameter.type);
|
|
27330
|
+
if (!match?.type)
|
|
27331
|
+
throw new InvalidAbiTypeParameterError({ abiParameter });
|
|
27332
|
+
const { array, type } = match;
|
|
27333
|
+
if (type in structs) {
|
|
27334
|
+
if (ancestors.has(type))
|
|
27335
|
+
throw new CircularReferenceError({ type });
|
|
27336
|
+
components.push({
|
|
27337
|
+
...abiParameter,
|
|
27338
|
+
type: `tuple${array ?? ""}`,
|
|
27339
|
+
components: resolveStructs(structs[type], structs, /* @__PURE__ */ new Set([...ancestors, type]))
|
|
27340
|
+
});
|
|
27341
|
+
} else {
|
|
27342
|
+
if (isSolidityType(type))
|
|
27343
|
+
components.push(abiParameter);
|
|
27344
|
+
else
|
|
27345
|
+
throw new UnknownTypeError({ type });
|
|
27346
|
+
}
|
|
27347
|
+
}
|
|
26622
27348
|
}
|
|
26623
|
-
return
|
|
27349
|
+
return components;
|
|
26624
27350
|
}
|
|
26625
|
-
var
|
|
26626
|
-
|
|
26627
|
-
|
|
27351
|
+
var typeWithoutTupleRegex;
|
|
27352
|
+
var init_structs = __esm({
|
|
27353
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/runtime/structs.js"() {
|
|
27354
|
+
init_regex();
|
|
27355
|
+
init_abiItem();
|
|
27356
|
+
init_abiParameter();
|
|
27357
|
+
init_signature();
|
|
27358
|
+
init_struct();
|
|
27359
|
+
init_signatures();
|
|
27360
|
+
init_utils();
|
|
27361
|
+
typeWithoutTupleRegex = /^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?$/;
|
|
26628
27362
|
}
|
|
26629
27363
|
});
|
|
26630
27364
|
|
|
26631
|
-
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/
|
|
26632
|
-
function
|
|
26633
|
-
|
|
26634
|
-
|
|
26635
|
-
|
|
26636
|
-
|
|
26637
|
-
|
|
26638
|
-
|
|
26639
|
-
|
|
26640
|
-
|
|
26641
|
-
|
|
26642
|
-
|
|
26643
|
-
return "receive() external payable";
|
|
27365
|
+
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/parseAbi.js
|
|
27366
|
+
function parseAbi(signatures) {
|
|
27367
|
+
const structs = parseStructs(signatures);
|
|
27368
|
+
const abi2 = [];
|
|
27369
|
+
const length = signatures.length;
|
|
27370
|
+
for (let i = 0; i < length; i++) {
|
|
27371
|
+
const signature = signatures[i];
|
|
27372
|
+
if (isStructSignature(signature))
|
|
27373
|
+
continue;
|
|
27374
|
+
abi2.push(parseSignature(signature, structs));
|
|
27375
|
+
}
|
|
27376
|
+
return abi2;
|
|
26644
27377
|
}
|
|
26645
|
-
var
|
|
26646
|
-
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/
|
|
26647
|
-
|
|
27378
|
+
var init_parseAbi = __esm({
|
|
27379
|
+
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/human-readable/parseAbi.js"() {
|
|
27380
|
+
init_signatures();
|
|
27381
|
+
init_structs();
|
|
27382
|
+
init_utils();
|
|
26648
27383
|
}
|
|
26649
27384
|
});
|
|
26650
27385
|
|
|
@@ -26652,6 +27387,7 @@ var init_formatAbiItem = __esm({
|
|
|
26652
27387
|
var init_exports = __esm({
|
|
26653
27388
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@4.4.3/node_modules/abitype/dist/esm/exports/index.js"() {
|
|
26654
27389
|
init_formatAbiItem();
|
|
27390
|
+
init_parseAbi();
|
|
26655
27391
|
}
|
|
26656
27392
|
});
|
|
26657
27393
|
|
|
@@ -26704,10 +27440,10 @@ var init_size = __esm({
|
|
|
26704
27440
|
});
|
|
26705
27441
|
|
|
26706
27442
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/version.js
|
|
26707
|
-
var
|
|
26708
|
-
var
|
|
27443
|
+
var version2;
|
|
27444
|
+
var init_version2 = __esm({
|
|
26709
27445
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/version.js"() {
|
|
26710
|
-
|
|
27446
|
+
version2 = "2.51.3";
|
|
26711
27447
|
}
|
|
26712
27448
|
});
|
|
26713
27449
|
|
|
@@ -26719,15 +27455,15 @@ function walk(err, fn) {
|
|
|
26719
27455
|
return walk(err.cause, fn);
|
|
26720
27456
|
return fn ? null : err;
|
|
26721
27457
|
}
|
|
26722
|
-
var errorConfig,
|
|
27458
|
+
var errorConfig, BaseError2;
|
|
26723
27459
|
var init_base = __esm({
|
|
26724
27460
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/base.js"() {
|
|
26725
|
-
|
|
27461
|
+
init_version2();
|
|
26726
27462
|
errorConfig = {
|
|
26727
27463
|
getDocsUrl: ({ docsBaseUrl, docsPath: docsPath9 = "", docsSlug }) => docsPath9 ? `${docsBaseUrl ?? "https://viem.sh"}${docsPath9}${docsSlug ? `#${docsSlug}` : ""}` : void 0,
|
|
26728
|
-
version: `viem@${
|
|
27464
|
+
version: `viem@${version2}`
|
|
26729
27465
|
};
|
|
26730
|
-
|
|
27466
|
+
BaseError2 = class _BaseError extends Error {
|
|
26731
27467
|
constructor(shortMessage, args = {}) {
|
|
26732
27468
|
const details = (() => {
|
|
26733
27469
|
if (args.cause instanceof _BaseError)
|
|
@@ -26792,7 +27528,7 @@ var init_base = __esm({
|
|
|
26792
27528
|
this.metaMessages = args.metaMessages;
|
|
26793
27529
|
this.name = args.name ?? this.name;
|
|
26794
27530
|
this.shortMessage = shortMessage;
|
|
26795
|
-
this.version =
|
|
27531
|
+
this.version = version2;
|
|
26796
27532
|
}
|
|
26797
27533
|
walk(fn) {
|
|
26798
27534
|
return walk(this, fn);
|
|
@@ -26808,7 +27544,7 @@ var init_abi = __esm({
|
|
|
26808
27544
|
init_formatAbiItem2();
|
|
26809
27545
|
init_size();
|
|
26810
27546
|
init_base();
|
|
26811
|
-
AbiEncodingArrayLengthMismatchError = class extends
|
|
27547
|
+
AbiEncodingArrayLengthMismatchError = class extends BaseError2 {
|
|
26812
27548
|
constructor({ expectedLength, givenLength, type }) {
|
|
26813
27549
|
super([
|
|
26814
27550
|
`ABI encoding array length mismatch for type ${type}.`,
|
|
@@ -26817,12 +27553,12 @@ var init_abi = __esm({
|
|
|
26817
27553
|
].join("\n"), { name: "AbiEncodingArrayLengthMismatchError" });
|
|
26818
27554
|
}
|
|
26819
27555
|
};
|
|
26820
|
-
AbiEncodingBytesSizeMismatchError = class extends
|
|
27556
|
+
AbiEncodingBytesSizeMismatchError = class extends BaseError2 {
|
|
26821
27557
|
constructor({ expectedSize, value }) {
|
|
26822
27558
|
super(`Size of bytes "${value}" (bytes${size(value)}) does not match expected size (bytes${expectedSize}).`, { name: "AbiEncodingBytesSizeMismatchError" });
|
|
26823
27559
|
}
|
|
26824
27560
|
};
|
|
26825
|
-
AbiEncodingLengthMismatchError = class extends
|
|
27561
|
+
AbiEncodingLengthMismatchError = class extends BaseError2 {
|
|
26826
27562
|
constructor({ expectedLength, givenLength }) {
|
|
26827
27563
|
super([
|
|
26828
27564
|
"ABI encoding params/values length mismatch.",
|
|
@@ -26831,7 +27567,7 @@ var init_abi = __esm({
|
|
|
26831
27567
|
].join("\n"), { name: "AbiEncodingLengthMismatchError" });
|
|
26832
27568
|
}
|
|
26833
27569
|
};
|
|
26834
|
-
AbiFunctionNotFoundError = class extends
|
|
27570
|
+
AbiFunctionNotFoundError = class extends BaseError2 {
|
|
26835
27571
|
constructor(functionName, { docsPath: docsPath9 } = {}) {
|
|
26836
27572
|
super([
|
|
26837
27573
|
`Function ${functionName ? `"${functionName}" ` : ""}not found on ABI.`,
|
|
@@ -26842,7 +27578,7 @@ var init_abi = __esm({
|
|
|
26842
27578
|
});
|
|
26843
27579
|
}
|
|
26844
27580
|
};
|
|
26845
|
-
AbiItemAmbiguityError = class extends
|
|
27581
|
+
AbiItemAmbiguityError = class extends BaseError2 {
|
|
26846
27582
|
constructor(x, y) {
|
|
26847
27583
|
super("Found ambiguous types in overloaded ABI items.", {
|
|
26848
27584
|
metaMessages: [
|
|
@@ -26856,14 +27592,14 @@ var init_abi = __esm({
|
|
|
26856
27592
|
});
|
|
26857
27593
|
}
|
|
26858
27594
|
};
|
|
26859
|
-
BytesSizeMismatchError = class extends
|
|
27595
|
+
BytesSizeMismatchError = class extends BaseError2 {
|
|
26860
27596
|
constructor({ expectedSize, givenSize }) {
|
|
26861
27597
|
super(`Expected bytes${expectedSize}, got bytes${givenSize}.`, {
|
|
26862
27598
|
name: "BytesSizeMismatchError"
|
|
26863
27599
|
});
|
|
26864
27600
|
}
|
|
26865
27601
|
};
|
|
26866
|
-
InvalidAbiEncodingTypeError = class extends
|
|
27602
|
+
InvalidAbiEncodingTypeError = class extends BaseError2 {
|
|
26867
27603
|
constructor(type, { docsPath: docsPath9 }) {
|
|
26868
27604
|
super([
|
|
26869
27605
|
`Type "${type}" is not a valid encoding type.`,
|
|
@@ -26871,14 +27607,14 @@ var init_abi = __esm({
|
|
|
26871
27607
|
].join("\n"), { docsPath: docsPath9, name: "InvalidAbiEncodingType" });
|
|
26872
27608
|
}
|
|
26873
27609
|
};
|
|
26874
|
-
InvalidArrayError = class extends
|
|
27610
|
+
InvalidArrayError = class extends BaseError2 {
|
|
26875
27611
|
constructor(value) {
|
|
26876
27612
|
super([`Value "${value}" is not a valid array.`].join("\n"), {
|
|
26877
27613
|
name: "InvalidArrayError"
|
|
26878
27614
|
});
|
|
26879
27615
|
}
|
|
26880
27616
|
};
|
|
26881
|
-
InvalidDefinitionTypeError = class extends
|
|
27617
|
+
InvalidDefinitionTypeError = class extends BaseError2 {
|
|
26882
27618
|
constructor(type) {
|
|
26883
27619
|
super([
|
|
26884
27620
|
`"${type}" is not a valid definition type.`,
|
|
@@ -26894,12 +27630,12 @@ var SliceOffsetOutOfBoundsError, SizeExceedsPaddingSizeError;
|
|
|
26894
27630
|
var init_data = __esm({
|
|
26895
27631
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/data.js"() {
|
|
26896
27632
|
init_base();
|
|
26897
|
-
SliceOffsetOutOfBoundsError = class extends
|
|
27633
|
+
SliceOffsetOutOfBoundsError = class extends BaseError2 {
|
|
26898
27634
|
constructor({ offset, position, size: size6 }) {
|
|
26899
27635
|
super(`Slice ${position === "start" ? "starting" : "ending"} at offset "${offset}" is out-of-bounds (size: ${size6}).`, { name: "SliceOffsetOutOfBoundsError" });
|
|
26900
27636
|
}
|
|
26901
27637
|
};
|
|
26902
|
-
SizeExceedsPaddingSizeError = class extends
|
|
27638
|
+
SizeExceedsPaddingSizeError = class extends BaseError2 {
|
|
26903
27639
|
constructor({ size: size6, targetSize, type }) {
|
|
26904
27640
|
super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (${size6}) exceeds padding size (${targetSize}).`, { name: "SizeExceedsPaddingSizeError" });
|
|
26905
27641
|
}
|
|
@@ -26952,12 +27688,12 @@ var IntegerOutOfRangeError, SizeOverflowError;
|
|
|
26952
27688
|
var init_encoding = __esm({
|
|
26953
27689
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/encoding.js"() {
|
|
26954
27690
|
init_base();
|
|
26955
|
-
IntegerOutOfRangeError = class extends
|
|
27691
|
+
IntegerOutOfRangeError = class extends BaseError2 {
|
|
26956
27692
|
constructor({ max, min, signed, size: size6, value }) {
|
|
26957
27693
|
super(`Number "${value}" is not in safe ${size6 ? `${size6 * 8}-bit ${signed ? "signed" : "unsigned"} ` : ""}integer range ${max ? `(${min} to ${max})` : `(above ${min})`}`, { name: "IntegerOutOfRangeError" });
|
|
26958
27694
|
}
|
|
26959
27695
|
};
|
|
26960
|
-
SizeOverflowError = class extends
|
|
27696
|
+
SizeOverflowError = class extends BaseError2 {
|
|
26961
27697
|
constructor({ givenSize, maxSize }) {
|
|
26962
27698
|
super(`Size cannot exceed ${maxSize} bytes. Given size: ${givenSize} bytes.`, { name: "SizeOverflowError" });
|
|
26963
27699
|
}
|
|
@@ -27146,7 +27882,7 @@ function hexToBytes(hex_, opts = {}) {
|
|
|
27146
27882
|
const nibbleLeft = charCodeToBase16(hexString.charCodeAt(j++));
|
|
27147
27883
|
const nibbleRight = charCodeToBase16(hexString.charCodeAt(j++));
|
|
27148
27884
|
if (nibbleLeft === void 0 || nibbleRight === void 0) {
|
|
27149
|
-
throw new
|
|
27885
|
+
throw new BaseError2(`Invalid byte sequence ("${hexString[j - 2]}${hexString[j - 1]}" in "${hexString}").`);
|
|
27150
27886
|
}
|
|
27151
27887
|
bytes[index2] = nibbleLeft * 16 + nibbleRight;
|
|
27152
27888
|
}
|
|
@@ -27392,7 +28128,7 @@ function randomBytes(bytesLength = 32) {
|
|
|
27392
28128
|
throw new Error("crypto.getRandomValues must be defined");
|
|
27393
28129
|
}
|
|
27394
28130
|
var isLE, swap32IfBE, hasHexBuiltin, hexes2, asciis, Hash;
|
|
27395
|
-
var
|
|
28131
|
+
var init_utils2 = __esm({
|
|
27396
28132
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/utils.js"() {
|
|
27397
28133
|
init_cryptoNode();
|
|
27398
28134
|
isLE = /* @__PURE__ */ (() => new Uint8Array(new Uint32Array([287454020]).buffer)[0] === 68)();
|
|
@@ -27453,7 +28189,7 @@ var _0n, _1n, _2n, _7n, _256n, _0x71n, SHA3_PI, SHA3_ROTL, _SHA3_IOTA, IOTAS, SH
|
|
|
27453
28189
|
var init_sha3 = __esm({
|
|
27454
28190
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/sha3.js"() {
|
|
27455
28191
|
init_u64();
|
|
27456
|
-
|
|
28192
|
+
init_utils2();
|
|
27457
28193
|
_0n = BigInt(0);
|
|
27458
28194
|
_1n = BigInt(1);
|
|
27459
28195
|
_2n = BigInt(2);
|
|
@@ -27666,7 +28402,7 @@ function normalizeSignature(signature) {
|
|
|
27666
28402
|
current += char;
|
|
27667
28403
|
}
|
|
27668
28404
|
if (!valid)
|
|
27669
|
-
throw new
|
|
28405
|
+
throw new BaseError2("Unable to normalize signature.");
|
|
27670
28406
|
return result;
|
|
27671
28407
|
}
|
|
27672
28408
|
var init_normalizeSignature = __esm({
|
|
@@ -27717,7 +28453,7 @@ var InvalidAddressError;
|
|
|
27717
28453
|
var init_address = __esm({
|
|
27718
28454
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/address.js"() {
|
|
27719
28455
|
init_base();
|
|
27720
|
-
InvalidAddressError = class extends
|
|
28456
|
+
InvalidAddressError = class extends BaseError2 {
|
|
27721
28457
|
constructor({ address }) {
|
|
27722
28458
|
super(`Address "${address}" is invalid.`, {
|
|
27723
28459
|
metaMessages: [
|
|
@@ -27903,11 +28639,11 @@ var init_slice = __esm({
|
|
|
27903
28639
|
});
|
|
27904
28640
|
|
|
27905
28641
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/utils/regex.js
|
|
27906
|
-
var
|
|
28642
|
+
var bytesRegex2, integerRegex2;
|
|
27907
28643
|
var init_regex2 = __esm({
|
|
27908
28644
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/utils/regex.js"() {
|
|
27909
|
-
|
|
27910
|
-
|
|
28645
|
+
bytesRegex2 = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;
|
|
28646
|
+
integerRegex2 = /^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;
|
|
27911
28647
|
}
|
|
27912
28648
|
});
|
|
27913
28649
|
|
|
@@ -27953,7 +28689,7 @@ function prepareParam({ param, value }) {
|
|
|
27953
28689
|
}
|
|
27954
28690
|
if (param.type.startsWith("uint") || param.type.startsWith("int")) {
|
|
27955
28691
|
const signed = param.type.startsWith("int");
|
|
27956
|
-
const [, , size6 = "256"] =
|
|
28692
|
+
const [, , size6 = "256"] = integerRegex2.exec(param.type) ?? [];
|
|
27957
28693
|
return encodeNumber(value, {
|
|
27958
28694
|
signed,
|
|
27959
28695
|
size: Number(size6)
|
|
@@ -28057,7 +28793,7 @@ function encodeBytes(value, { param }) {
|
|
|
28057
28793
|
}
|
|
28058
28794
|
function encodeBool(value) {
|
|
28059
28795
|
if (typeof value !== "boolean")
|
|
28060
|
-
throw new
|
|
28796
|
+
throw new BaseError2(`Invalid boolean value: "${value}" (type: ${typeof value}). Expected: \`true\` or \`false\`.`);
|
|
28061
28797
|
return { dynamic: false, encoded: padHex(boolToHex(value)) };
|
|
28062
28798
|
}
|
|
28063
28799
|
function encodeNumber(value, { signed, size: size6 = 256 }) {
|
|
@@ -28329,19 +29065,19 @@ var NegativeOffsetError, PositionOutOfBoundsError, RecursiveReadLimitExceededErr
|
|
|
28329
29065
|
var init_cursor = __esm({
|
|
28330
29066
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/cursor.js"() {
|
|
28331
29067
|
init_base();
|
|
28332
|
-
NegativeOffsetError = class extends
|
|
29068
|
+
NegativeOffsetError = class extends BaseError2 {
|
|
28333
29069
|
constructor({ offset }) {
|
|
28334
29070
|
super(`Offset \`${offset}\` cannot be negative.`, {
|
|
28335
29071
|
name: "NegativeOffsetError"
|
|
28336
29072
|
});
|
|
28337
29073
|
}
|
|
28338
29074
|
};
|
|
28339
|
-
PositionOutOfBoundsError = class extends
|
|
29075
|
+
PositionOutOfBoundsError = class extends BaseError2 {
|
|
28340
29076
|
constructor({ length, position }) {
|
|
28341
29077
|
super(`Position \`${position}\` is out of bounds (\`0 < position < ${length}\`).`, { name: "PositionOutOfBoundsError" });
|
|
28342
29078
|
}
|
|
28343
29079
|
};
|
|
28344
|
-
RecursiveReadLimitExceededError = class extends
|
|
29080
|
+
RecursiveReadLimitExceededError = class extends BaseError2 {
|
|
28345
29081
|
constructor({ count, limit }) {
|
|
28346
29082
|
super(`Recursive read limit of \`${limit}\` exceeded (recursive read count: \`${count}\`).`, { name: "RecursiveReadLimitExceededError" });
|
|
28347
29083
|
}
|
|
@@ -28590,14 +29326,14 @@ var InvalidLegacyVError, InvalidSerializableTransactionError, InvalidStorageKeyS
|
|
|
28590
29326
|
var init_transaction = __esm({
|
|
28591
29327
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/transaction.js"() {
|
|
28592
29328
|
init_base();
|
|
28593
|
-
InvalidLegacyVError = class extends
|
|
29329
|
+
InvalidLegacyVError = class extends BaseError2 {
|
|
28594
29330
|
constructor({ v }) {
|
|
28595
29331
|
super(`Invalid \`v\` value "${v}". Expected 27 or 28.`, {
|
|
28596
29332
|
name: "InvalidLegacyVError"
|
|
28597
29333
|
});
|
|
28598
29334
|
}
|
|
28599
29335
|
};
|
|
28600
|
-
InvalidSerializableTransactionError = class extends
|
|
29336
|
+
InvalidSerializableTransactionError = class extends BaseError2 {
|
|
28601
29337
|
constructor({ transaction }) {
|
|
28602
29338
|
super("Cannot infer a transaction type from provided transaction.", {
|
|
28603
29339
|
metaMessages: [
|
|
@@ -28618,7 +29354,7 @@ var init_transaction = __esm({
|
|
|
28618
29354
|
});
|
|
28619
29355
|
}
|
|
28620
29356
|
};
|
|
28621
|
-
InvalidStorageKeySizeError = class extends
|
|
29357
|
+
InvalidStorageKeySizeError = class extends BaseError2 {
|
|
28622
29358
|
constructor({ storageKey }) {
|
|
28623
29359
|
super(`Size for storage key "${storageKey}" is invalid. Expected 32 bytes. Got ${Math.floor((storageKey.length - 2) / 2)} bytes.`, { name: "InvalidStorageKeySizeError" });
|
|
28624
29360
|
}
|
|
@@ -28724,7 +29460,7 @@ function getSizeOfLength(length) {
|
|
|
28724
29460
|
return 3;
|
|
28725
29461
|
if (length < 2 ** 32)
|
|
28726
29462
|
return 4;
|
|
28727
|
-
throw new
|
|
29463
|
+
throw new BaseError2("Length is too large.");
|
|
28728
29464
|
}
|
|
28729
29465
|
var init_toRlp = __esm({
|
|
28730
29466
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/utils/encoding/toRlp.js"() {
|
|
@@ -28767,7 +29503,7 @@ var init_node = __esm({
|
|
|
28767
29503
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/node.js"() {
|
|
28768
29504
|
init_formatGwei();
|
|
28769
29505
|
init_base();
|
|
28770
|
-
ExecutionRevertedError = class extends
|
|
29506
|
+
ExecutionRevertedError = class extends BaseError2 {
|
|
28771
29507
|
constructor({ cause, message } = {}) {
|
|
28772
29508
|
const reason = message?.replace("execution reverted: ", "")?.replace("execution reverted", "");
|
|
28773
29509
|
super(`Execution reverted ${reason ? `with reason: ${reason}` : "for an unknown reason"}.`, {
|
|
@@ -28788,7 +29524,7 @@ var init_node = __esm({
|
|
|
28788
29524
|
writable: true,
|
|
28789
29525
|
value: /execution reverted|gas required exceeds allowance/
|
|
28790
29526
|
});
|
|
28791
|
-
FeeCapTooHighError = class extends
|
|
29527
|
+
FeeCapTooHighError = class extends BaseError2 {
|
|
28792
29528
|
constructor({ cause, maxFeePerGas } = {}) {
|
|
28793
29529
|
super(`The fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei(maxFeePerGas)} gwei` : ""}) cannot be higher than the maximum allowed value (2^256-1).`, {
|
|
28794
29530
|
cause,
|
|
@@ -28802,7 +29538,7 @@ var init_node = __esm({
|
|
|
28802
29538
|
writable: true,
|
|
28803
29539
|
value: /max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/
|
|
28804
29540
|
});
|
|
28805
|
-
FeeCapTooLowError = class extends
|
|
29541
|
+
FeeCapTooLowError = class extends BaseError2 {
|
|
28806
29542
|
constructor({ cause, maxFeePerGas } = {}) {
|
|
28807
29543
|
super(`The fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei(maxFeePerGas)}` : ""} gwei) cannot be lower than the block base fee.`, {
|
|
28808
29544
|
cause,
|
|
@@ -28816,7 +29552,7 @@ var init_node = __esm({
|
|
|
28816
29552
|
writable: true,
|
|
28817
29553
|
value: /max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/
|
|
28818
29554
|
});
|
|
28819
|
-
NonceTooHighError = class extends
|
|
29555
|
+
NonceTooHighError = class extends BaseError2 {
|
|
28820
29556
|
constructor({ cause, nonce } = {}) {
|
|
28821
29557
|
super(`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}is higher than the next one expected.`, { cause, name: "NonceTooHighError" });
|
|
28822
29558
|
}
|
|
@@ -28827,7 +29563,7 @@ var init_node = __esm({
|
|
|
28827
29563
|
writable: true,
|
|
28828
29564
|
value: /nonce too high/
|
|
28829
29565
|
});
|
|
28830
|
-
NonceTooLowError = class extends
|
|
29566
|
+
NonceTooLowError = class extends BaseError2 {
|
|
28831
29567
|
constructor({ cause, nonce } = {}) {
|
|
28832
29568
|
super([
|
|
28833
29569
|
`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}is lower than the current nonce of the account.`,
|
|
@@ -28841,7 +29577,7 @@ var init_node = __esm({
|
|
|
28841
29577
|
writable: true,
|
|
28842
29578
|
value: /nonce too low|transaction already imported|already known/
|
|
28843
29579
|
});
|
|
28844
|
-
NonceMaxValueError = class extends
|
|
29580
|
+
NonceMaxValueError = class extends BaseError2 {
|
|
28845
29581
|
constructor({ cause, nonce } = {}) {
|
|
28846
29582
|
super(`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}exceeds the maximum allowed nonce.`, { cause, name: "NonceMaxValueError" });
|
|
28847
29583
|
}
|
|
@@ -28852,7 +29588,7 @@ var init_node = __esm({
|
|
|
28852
29588
|
writable: true,
|
|
28853
29589
|
value: /nonce has max value/
|
|
28854
29590
|
});
|
|
28855
|
-
InsufficientFundsError = class extends
|
|
29591
|
+
InsufficientFundsError = class extends BaseError2 {
|
|
28856
29592
|
constructor({ cause } = {}) {
|
|
28857
29593
|
super([
|
|
28858
29594
|
"The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."
|
|
@@ -28878,7 +29614,7 @@ var init_node = __esm({
|
|
|
28878
29614
|
writable: true,
|
|
28879
29615
|
value: /insufficient funds|exceeds transaction sender account balance/
|
|
28880
29616
|
});
|
|
28881
|
-
IntrinsicGasTooHighError = class extends
|
|
29617
|
+
IntrinsicGasTooHighError = class extends BaseError2 {
|
|
28882
29618
|
constructor({ cause, gas } = {}) {
|
|
28883
29619
|
super(`The amount of gas ${gas ? `(${gas}) ` : ""}provided for the transaction exceeds the limit allowed for the block.`, {
|
|
28884
29620
|
cause,
|
|
@@ -28892,7 +29628,7 @@ var init_node = __esm({
|
|
|
28892
29628
|
writable: true,
|
|
28893
29629
|
value: /intrinsic gas too high|gas limit reached/
|
|
28894
29630
|
});
|
|
28895
|
-
IntrinsicGasTooLowError = class extends
|
|
29631
|
+
IntrinsicGasTooLowError = class extends BaseError2 {
|
|
28896
29632
|
constructor({ cause, gas } = {}) {
|
|
28897
29633
|
super(`The amount of gas ${gas ? `(${gas}) ` : ""}provided for the transaction is too low.`, {
|
|
28898
29634
|
cause,
|
|
@@ -28906,7 +29642,7 @@ var init_node = __esm({
|
|
|
28906
29642
|
writable: true,
|
|
28907
29643
|
value: /intrinsic gas too low/
|
|
28908
29644
|
});
|
|
28909
|
-
TransactionTypeNotSupportedError = class extends
|
|
29645
|
+
TransactionTypeNotSupportedError = class extends BaseError2 {
|
|
28910
29646
|
constructor({ cause }) {
|
|
28911
29647
|
super("The transaction type is not supported for this chain.", {
|
|
28912
29648
|
cause,
|
|
@@ -28920,7 +29656,7 @@ var init_node = __esm({
|
|
|
28920
29656
|
writable: true,
|
|
28921
29657
|
value: /transaction type not valid/
|
|
28922
29658
|
});
|
|
28923
|
-
TipAboveFeeCapError = class extends
|
|
29659
|
+
TipAboveFeeCapError = class extends BaseError2 {
|
|
28924
29660
|
constructor({ cause, maxPriorityFeePerGas, maxFeePerGas } = {}) {
|
|
28925
29661
|
super([
|
|
28926
29662
|
`The provided tip (\`maxPriorityFeePerGas\`${maxPriorityFeePerGas ? ` = ${formatGwei(maxPriorityFeePerGas)} gwei` : ""}) cannot be higher than the fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei(maxFeePerGas)} gwei` : ""}).`
|
|
@@ -29102,7 +29838,7 @@ function Maj(a, b, c) {
|
|
|
29102
29838
|
var HashMD, SHA256_IV, SHA512_IV;
|
|
29103
29839
|
var init_md = __esm({
|
|
29104
29840
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/_md.js"() {
|
|
29105
|
-
|
|
29841
|
+
init_utils2();
|
|
29106
29842
|
HashMD = class extends Hash {
|
|
29107
29843
|
constructor(blockLen, outputLen, padOffset, isLE2) {
|
|
29108
29844
|
super();
|
|
@@ -29230,7 +29966,7 @@ var init_sha2 = __esm({
|
|
|
29230
29966
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/sha2.js"() {
|
|
29231
29967
|
init_md();
|
|
29232
29968
|
init_u64();
|
|
29233
|
-
|
|
29969
|
+
init_utils2();
|
|
29234
29970
|
SHA256_K = /* @__PURE__ */ Uint32Array.from([
|
|
29235
29971
|
1116352408,
|
|
29236
29972
|
1899447441,
|
|
@@ -29598,10 +30334,10 @@ var init_sha2562 = __esm({
|
|
|
29598
30334
|
|
|
29599
30335
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/utils/blob/commitmentToVersionedHash.js
|
|
29600
30336
|
function commitmentToVersionedHash(parameters) {
|
|
29601
|
-
const { commitment, version:
|
|
30337
|
+
const { commitment, version: version6 = 1 } = parameters;
|
|
29602
30338
|
const to = parameters.to ?? (typeof commitment === "string" ? "hex" : "bytes");
|
|
29603
30339
|
const versionedHash = sha2563(commitment, "bytes");
|
|
29604
|
-
versionedHash.set([
|
|
30340
|
+
versionedHash.set([version6], 0);
|
|
29605
30341
|
return to === "bytes" ? versionedHash : bytesToHex(versionedHash);
|
|
29606
30342
|
}
|
|
29607
30343
|
var init_commitmentToVersionedHash = __esm({
|
|
@@ -29613,14 +30349,14 @@ var init_commitmentToVersionedHash = __esm({
|
|
|
29613
30349
|
|
|
29614
30350
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/utils/blob/commitmentsToVersionedHashes.js
|
|
29615
30351
|
function commitmentsToVersionedHashes(parameters) {
|
|
29616
|
-
const { commitments, version:
|
|
30352
|
+
const { commitments, version: version6 } = parameters;
|
|
29617
30353
|
const to = parameters.to ?? (typeof commitments[0] === "string" ? "hex" : "bytes");
|
|
29618
30354
|
const hashes = [];
|
|
29619
30355
|
for (const commitment of commitments) {
|
|
29620
30356
|
hashes.push(commitmentToVersionedHash({
|
|
29621
30357
|
commitment,
|
|
29622
30358
|
to,
|
|
29623
|
-
version:
|
|
30359
|
+
version: version6
|
|
29624
30360
|
}));
|
|
29625
30361
|
}
|
|
29626
30362
|
return hashes;
|
|
@@ -29659,7 +30395,7 @@ var init_blob2 = __esm({
|
|
|
29659
30395
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/blob.js"() {
|
|
29660
30396
|
init_kzg();
|
|
29661
30397
|
init_base();
|
|
29662
|
-
BlobSizeTooLargeError = class extends
|
|
30398
|
+
BlobSizeTooLargeError = class extends BaseError2 {
|
|
29663
30399
|
constructor({ maxSize, size: size6 }) {
|
|
29664
30400
|
super("Blob size is too large.", {
|
|
29665
30401
|
metaMessages: [`Max: ${maxSize} bytes`, `Given: ${size6} bytes`],
|
|
@@ -29667,12 +30403,12 @@ var init_blob2 = __esm({
|
|
|
29667
30403
|
});
|
|
29668
30404
|
}
|
|
29669
30405
|
};
|
|
29670
|
-
EmptyBlobError = class extends
|
|
30406
|
+
EmptyBlobError = class extends BaseError2 {
|
|
29671
30407
|
constructor() {
|
|
29672
30408
|
super("Blob data must not be empty.", { name: "EmptyBlobError" });
|
|
29673
30409
|
}
|
|
29674
30410
|
};
|
|
29675
|
-
InvalidVersionedHashSizeError = class extends
|
|
30411
|
+
InvalidVersionedHashSizeError = class extends BaseError2 {
|
|
29676
30412
|
constructor({ hash: hash4, size: size6 }) {
|
|
29677
30413
|
super(`Versioned hash "${hash4}" size is invalid.`, {
|
|
29678
30414
|
metaMessages: ["Expected: 32", `Received: ${size6}`],
|
|
@@ -29680,12 +30416,12 @@ var init_blob2 = __esm({
|
|
|
29680
30416
|
});
|
|
29681
30417
|
}
|
|
29682
30418
|
};
|
|
29683
|
-
InvalidVersionedHashVersionError = class extends
|
|
29684
|
-
constructor({ hash: hash4, version:
|
|
30419
|
+
InvalidVersionedHashVersionError = class extends BaseError2 {
|
|
30420
|
+
constructor({ hash: hash4, version: version6 }) {
|
|
29685
30421
|
super(`Versioned hash "${hash4}" version is invalid.`, {
|
|
29686
30422
|
metaMessages: [
|
|
29687
30423
|
`Expected: ${versionedHashVersionKzg}`,
|
|
29688
|
-
`Received: ${
|
|
30424
|
+
`Received: ${version6}`
|
|
29689
30425
|
],
|
|
29690
30426
|
name: "InvalidVersionedHashVersionError"
|
|
29691
30427
|
});
|
|
@@ -29989,7 +30725,7 @@ function memoized(fn) {
|
|
|
29989
30725
|
};
|
|
29990
30726
|
}
|
|
29991
30727
|
var _0n2, _1n2, hasHexBuiltin2, hexes3, asciis2, isPosBig, bitMask, u8n, u8fr, validatorFns;
|
|
29992
|
-
var
|
|
30728
|
+
var init_utils3 = __esm({
|
|
29993
30729
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/abstract/utils.js"() {
|
|
29994
30730
|
_0n2 = /* @__PURE__ */ BigInt(0);
|
|
29995
30731
|
_1n2 = /* @__PURE__ */ BigInt(1);
|
|
@@ -30020,7 +30756,7 @@ var InvalidChainIdError;
|
|
|
30020
30756
|
var init_chain = __esm({
|
|
30021
30757
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/chain.js"() {
|
|
30022
30758
|
init_base();
|
|
30023
|
-
InvalidChainIdError = class extends
|
|
30759
|
+
InvalidChainIdError = class extends BaseError2 {
|
|
30024
30760
|
constructor({ chainId }) {
|
|
30025
30761
|
super(typeof chainId === "number" ? `Chain ID "${chainId}" is invalid.` : "Chain ID is invalid.", { name: "InvalidChainIdError" });
|
|
30026
30762
|
}
|
|
@@ -30050,13 +30786,13 @@ function assertTransactionEIP4844(transaction) {
|
|
|
30050
30786
|
throw new EmptyBlobError();
|
|
30051
30787
|
for (const hash4 of blobVersionedHashes) {
|
|
30052
30788
|
const size_ = size(hash4);
|
|
30053
|
-
const
|
|
30789
|
+
const version6 = hexToNumber(slice(hash4, 0, 1));
|
|
30054
30790
|
if (size_ !== 32)
|
|
30055
30791
|
throw new InvalidVersionedHashSizeError({ hash: hash4, size: size_ });
|
|
30056
|
-
if (
|
|
30792
|
+
if (version6 !== versionedHashVersionKzg)
|
|
30057
30793
|
throw new InvalidVersionedHashVersionError({
|
|
30058
30794
|
hash: hash4,
|
|
30059
|
-
version:
|
|
30795
|
+
version: version6
|
|
30060
30796
|
});
|
|
30061
30797
|
}
|
|
30062
30798
|
}
|
|
@@ -30080,7 +30816,7 @@ function assertTransactionEIP2930(transaction) {
|
|
|
30080
30816
|
if (to && !isAddress(to))
|
|
30081
30817
|
throw new InvalidAddressError({ address: to });
|
|
30082
30818
|
if (maxPriorityFeePerGas || maxFeePerGas)
|
|
30083
|
-
throw new
|
|
30819
|
+
throw new BaseError2("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");
|
|
30084
30820
|
if (gasPrice && gasPrice > maxUint256)
|
|
30085
30821
|
throw new FeeCapTooHighError({ maxFeePerGas: gasPrice });
|
|
30086
30822
|
}
|
|
@@ -30091,7 +30827,7 @@ function assertTransactionLegacy(transaction) {
|
|
|
30091
30827
|
if (typeof chainId !== "undefined" && chainId <= 0)
|
|
30092
30828
|
throw new InvalidChainIdError({ chainId });
|
|
30093
30829
|
if (maxPriorityFeePerGas || maxFeePerGas)
|
|
30094
|
-
throw new
|
|
30830
|
+
throw new BaseError2("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");
|
|
30095
30831
|
if (gasPrice && gasPrice > maxUint256)
|
|
30096
30832
|
throw new FeeCapTooHighError({ maxFeePerGas: gasPrice });
|
|
30097
30833
|
}
|
|
@@ -30395,7 +31131,7 @@ var Rho160, Id160, Pi160, idxLR, idxL, idxR, shifts160, shiftsL160, shiftsR160,
|
|
|
30395
31131
|
var init_legacy = __esm({
|
|
30396
31132
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/legacy.js"() {
|
|
30397
31133
|
init_md();
|
|
30398
|
-
|
|
31134
|
+
init_utils2();
|
|
30399
31135
|
Rho160 = /* @__PURE__ */ Uint8Array.from([
|
|
30400
31136
|
7,
|
|
30401
31137
|
4,
|
|
@@ -30550,14 +31286,14 @@ var init_typedData = __esm({
|
|
|
30550
31286
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/errors/typedData.js"() {
|
|
30551
31287
|
init_stringify();
|
|
30552
31288
|
init_base();
|
|
30553
|
-
InvalidDomainError = class extends
|
|
31289
|
+
InvalidDomainError = class extends BaseError2 {
|
|
30554
31290
|
constructor({ domain }) {
|
|
30555
31291
|
super(`Invalid domain "${stringify(domain)}".`, {
|
|
30556
31292
|
metaMessages: ["Must be a valid EIP-712 domain."]
|
|
30557
31293
|
});
|
|
30558
31294
|
}
|
|
30559
31295
|
};
|
|
30560
|
-
InvalidPrimaryTypeError = class extends
|
|
31296
|
+
InvalidPrimaryTypeError = class extends BaseError2 {
|
|
30561
31297
|
constructor({ primaryType, types }) {
|
|
30562
31298
|
super(`Invalid primary type \`${primaryType}\` must be one of \`${JSON.stringify(Object.keys(types))}\`.`, {
|
|
30563
31299
|
docsPath: "/api/glossary/Errors#typeddatainvalidprimarytypeerror",
|
|
@@ -30565,7 +31301,7 @@ var init_typedData = __esm({
|
|
|
30565
31301
|
});
|
|
30566
31302
|
}
|
|
30567
31303
|
};
|
|
30568
|
-
InvalidStructTypeError = class extends
|
|
31304
|
+
InvalidStructTypeError = class extends BaseError2 {
|
|
30569
31305
|
constructor({ type }) {
|
|
30570
31306
|
super(`Struct type "${type}" is invalid.`, {
|
|
30571
31307
|
metaMessages: ["Struct type must not be a Solidity type."],
|
|
@@ -30583,7 +31319,7 @@ function validateTypedData(parameters) {
|
|
|
30583
31319
|
for (const param of struct) {
|
|
30584
31320
|
const { name, type } = param;
|
|
30585
31321
|
const value = data[name];
|
|
30586
|
-
const integerMatch = type.match(
|
|
31322
|
+
const integerMatch = type.match(integerRegex2);
|
|
30587
31323
|
if (integerMatch && (typeof value === "number" || typeof value === "bigint")) {
|
|
30588
31324
|
const [_type, base, size_] = integerMatch;
|
|
30589
31325
|
numberToHex(value, {
|
|
@@ -30593,7 +31329,7 @@ function validateTypedData(parameters) {
|
|
|
30593
31329
|
}
|
|
30594
31330
|
if (type === "address" && typeof value === "string" && !isAddress(value))
|
|
30595
31331
|
throw new InvalidAddressError({ address: value });
|
|
30596
|
-
const bytesMatch = type.match(
|
|
31332
|
+
const bytesMatch = type.match(bytesRegex2);
|
|
30597
31333
|
if (bytesMatch) {
|
|
30598
31334
|
const [_type, size_] = bytesMatch;
|
|
30599
31335
|
if (size_ && size(value) !== Number.parseInt(size_, 10))
|
|
@@ -30775,7 +31511,7 @@ var init_hashTypedData = __esm({
|
|
|
30775
31511
|
var HMAC, hmac;
|
|
30776
31512
|
var init_hmac = __esm({
|
|
30777
31513
|
"../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/hmac.js"() {
|
|
30778
|
-
|
|
31514
|
+
init_utils2();
|
|
30779
31515
|
HMAC = class extends Hash {
|
|
30780
31516
|
constructor(hash4, _key) {
|
|
30781
31517
|
super();
|
|
@@ -31095,8 +31831,8 @@ function mapHashToField(key, fieldOrder, isLE2 = false) {
|
|
|
31095
31831
|
var _0n3, _1n3, _2n2, _3n, _4n, _5n, _8n, FIELD_FIELDS;
|
|
31096
31832
|
var init_modular = __esm({
|
|
31097
31833
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/abstract/modular.js"() {
|
|
31098
|
-
init_utils();
|
|
31099
31834
|
init_utils2();
|
|
31835
|
+
init_utils3();
|
|
31100
31836
|
_0n3 = BigInt(0);
|
|
31101
31837
|
_1n3 = BigInt(1);
|
|
31102
31838
|
_2n2 = /* @__PURE__ */ BigInt(2);
|
|
@@ -31359,7 +32095,7 @@ var _0n4, _1n4, pointPrecomputes, pointWindowSizes;
|
|
|
31359
32095
|
var init_curve = __esm({
|
|
31360
32096
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/abstract/curve.js"() {
|
|
31361
32097
|
init_modular();
|
|
31362
|
-
|
|
32098
|
+
init_utils3();
|
|
31363
32099
|
_0n4 = BigInt(0);
|
|
31364
32100
|
_1n4 = BigInt(1);
|
|
31365
32101
|
pointPrecomputes = /* @__PURE__ */ new WeakMap();
|
|
@@ -32247,7 +32983,7 @@ var init_weierstrass = __esm({
|
|
|
32247
32983
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/abstract/weierstrass.js"() {
|
|
32248
32984
|
init_curve();
|
|
32249
32985
|
init_modular();
|
|
32250
|
-
|
|
32986
|
+
init_utils3();
|
|
32251
32987
|
DERErr = class extends Error {
|
|
32252
32988
|
constructor(m = "") {
|
|
32253
32989
|
super(m);
|
|
@@ -32376,7 +33112,7 @@ function createCurve(curveDef, defHash) {
|
|
|
32376
33112
|
var init_shortw_utils = __esm({
|
|
32377
33113
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/_shortw_utils.js"() {
|
|
32378
33114
|
init_hmac();
|
|
32379
|
-
|
|
33115
|
+
init_utils2();
|
|
32380
33116
|
init_weierstrass();
|
|
32381
33117
|
}
|
|
32382
33118
|
});
|
|
@@ -32531,7 +33267,7 @@ var os2ip;
|
|
|
32531
33267
|
var init_hash_to_curve = __esm({
|
|
32532
33268
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/abstract/hash-to-curve.js"() {
|
|
32533
33269
|
init_modular();
|
|
32534
|
-
|
|
33270
|
+
init_utils3();
|
|
32535
33271
|
os2ip = bytesToNumberBE;
|
|
32536
33272
|
}
|
|
32537
33273
|
});
|
|
@@ -32642,11 +33378,11 @@ var secp256k1P, secp256k1N, _0n6, _1n6, _2n4, divNearest, Fpk1, secp256k1, TAGGE
|
|
|
32642
33378
|
var init_secp256k1 = __esm({
|
|
32643
33379
|
"../../node_modules/.pnpm/@noble+curves@1.9.1/node_modules/@noble/curves/esm/secp256k1.js"() {
|
|
32644
33380
|
init_sha2();
|
|
32645
|
-
|
|
33381
|
+
init_utils2();
|
|
32646
33382
|
init_shortw_utils();
|
|
32647
33383
|
init_hash_to_curve();
|
|
32648
33384
|
init_modular();
|
|
32649
|
-
|
|
33385
|
+
init_utils3();
|
|
32650
33386
|
init_weierstrass();
|
|
32651
33387
|
secp256k1P = BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f");
|
|
32652
33388
|
secp256k1N = BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141");
|
|
@@ -32800,27 +33536,29 @@ var init_serializeSignature = __esm({
|
|
|
32800
33536
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/index.js
|
|
32801
33537
|
var init_esm = __esm({
|
|
32802
33538
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@4.4.3/node_modules/viem/_esm/index.js"() {
|
|
33539
|
+
init_exports();
|
|
32803
33540
|
init_address2();
|
|
32804
33541
|
init_encodeFunctionData();
|
|
33542
|
+
init_toBytes();
|
|
32805
33543
|
init_keccak256();
|
|
32806
33544
|
init_hashTypedData();
|
|
32807
33545
|
}
|
|
32808
33546
|
});
|
|
32809
33547
|
|
|
32810
33548
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/version.js
|
|
32811
|
-
var
|
|
32812
|
-
var
|
|
33549
|
+
var version3;
|
|
33550
|
+
var init_version3 = __esm({
|
|
32813
33551
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/version.js"() {
|
|
32814
|
-
|
|
33552
|
+
version3 = "1.2.3";
|
|
32815
33553
|
}
|
|
32816
33554
|
});
|
|
32817
33555
|
|
|
32818
33556
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/errors.js
|
|
32819
|
-
var
|
|
32820
|
-
var
|
|
33557
|
+
var BaseError3;
|
|
33558
|
+
var init_errors2 = __esm({
|
|
32821
33559
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/errors.js"() {
|
|
32822
|
-
|
|
32823
|
-
|
|
33560
|
+
init_version3();
|
|
33561
|
+
BaseError3 = class _BaseError extends Error {
|
|
32824
33562
|
constructor(shortMessage, args = {}) {
|
|
32825
33563
|
const details = args.cause instanceof _BaseError ? args.cause.details : args.cause?.message ? args.cause.message : args.details;
|
|
32826
33564
|
const docsPath9 = args.cause instanceof _BaseError ? args.cause.docsPath || args.docsPath : args.docsPath;
|
|
@@ -32830,7 +33568,7 @@ var init_errors = __esm({
|
|
|
32830
33568
|
...args.metaMessages ? [...args.metaMessages, ""] : [],
|
|
32831
33569
|
...docsPath9 ? [`Docs: https://abitype.dev${docsPath9}`] : [],
|
|
32832
33570
|
...details ? [`Details: ${details}`] : [],
|
|
32833
|
-
`Version: abitype@${
|
|
33571
|
+
`Version: abitype@${version3}`
|
|
32834
33572
|
].join("\n");
|
|
32835
33573
|
super(message);
|
|
32836
33574
|
Object.defineProperty(this, "details", {
|
|
@@ -32879,12 +33617,12 @@ function execTyped2(regex, string) {
|
|
|
32879
33617
|
const match = regex.exec(string);
|
|
32880
33618
|
return match?.groups;
|
|
32881
33619
|
}
|
|
32882
|
-
var
|
|
33620
|
+
var bytesRegex3, integerRegex3, isTupleRegex2;
|
|
32883
33621
|
var init_regex3 = __esm({
|
|
32884
33622
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/regex.js"() {
|
|
32885
|
-
|
|
32886
|
-
|
|
32887
|
-
|
|
33623
|
+
bytesRegex3 = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;
|
|
33624
|
+
integerRegex3 = /^u?int(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;
|
|
33625
|
+
isTupleRegex2 = /^\(.+?\).*?$/;
|
|
32888
33626
|
}
|
|
32889
33627
|
});
|
|
32890
33628
|
|
|
@@ -32960,64 +33698,64 @@ var init_formatAbiItem3 = __esm({
|
|
|
32960
33698
|
});
|
|
32961
33699
|
|
|
32962
33700
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/signatures.js
|
|
32963
|
-
function
|
|
32964
|
-
return
|
|
33701
|
+
function isErrorSignature2(signature) {
|
|
33702
|
+
return errorSignatureRegex2.test(signature);
|
|
32965
33703
|
}
|
|
32966
|
-
function
|
|
32967
|
-
return execTyped2(
|
|
33704
|
+
function execErrorSignature2(signature) {
|
|
33705
|
+
return execTyped2(errorSignatureRegex2, signature);
|
|
32968
33706
|
}
|
|
32969
|
-
function
|
|
32970
|
-
return
|
|
33707
|
+
function isEventSignature2(signature) {
|
|
33708
|
+
return eventSignatureRegex2.test(signature);
|
|
32971
33709
|
}
|
|
32972
|
-
function
|
|
32973
|
-
return execTyped2(
|
|
33710
|
+
function execEventSignature2(signature) {
|
|
33711
|
+
return execTyped2(eventSignatureRegex2, signature);
|
|
32974
33712
|
}
|
|
32975
|
-
function
|
|
32976
|
-
return
|
|
33713
|
+
function isFunctionSignature2(signature) {
|
|
33714
|
+
return functionSignatureRegex2.test(signature);
|
|
32977
33715
|
}
|
|
32978
|
-
function
|
|
32979
|
-
return execTyped2(
|
|
33716
|
+
function execFunctionSignature2(signature) {
|
|
33717
|
+
return execTyped2(functionSignatureRegex2, signature);
|
|
32980
33718
|
}
|
|
32981
|
-
function
|
|
32982
|
-
return
|
|
33719
|
+
function isStructSignature2(signature) {
|
|
33720
|
+
return structSignatureRegex2.test(signature);
|
|
32983
33721
|
}
|
|
32984
|
-
function
|
|
32985
|
-
return execTyped2(
|
|
33722
|
+
function execStructSignature2(signature) {
|
|
33723
|
+
return execTyped2(structSignatureRegex2, signature);
|
|
32986
33724
|
}
|
|
32987
|
-
function
|
|
32988
|
-
return
|
|
33725
|
+
function isConstructorSignature2(signature) {
|
|
33726
|
+
return constructorSignatureRegex2.test(signature);
|
|
32989
33727
|
}
|
|
32990
|
-
function
|
|
32991
|
-
return execTyped2(
|
|
33728
|
+
function execConstructorSignature2(signature) {
|
|
33729
|
+
return execTyped2(constructorSignatureRegex2, signature);
|
|
32992
33730
|
}
|
|
32993
|
-
function
|
|
32994
|
-
return
|
|
33731
|
+
function isFallbackSignature2(signature) {
|
|
33732
|
+
return fallbackSignatureRegex2.test(signature);
|
|
32995
33733
|
}
|
|
32996
|
-
function
|
|
32997
|
-
return execTyped2(
|
|
33734
|
+
function execFallbackSignature2(signature) {
|
|
33735
|
+
return execTyped2(fallbackSignatureRegex2, signature);
|
|
32998
33736
|
}
|
|
32999
|
-
function
|
|
33000
|
-
return
|
|
33737
|
+
function isReceiveSignature2(signature) {
|
|
33738
|
+
return receiveSignatureRegex2.test(signature);
|
|
33001
33739
|
}
|
|
33002
|
-
var
|
|
33003
|
-
var
|
|
33740
|
+
var errorSignatureRegex2, eventSignatureRegex2, functionSignatureRegex2, structSignatureRegex2, constructorSignatureRegex2, fallbackSignatureRegex2, receiveSignatureRegex2, modifiers, eventModifiers2, functionModifiers2;
|
|
33741
|
+
var init_signatures2 = __esm({
|
|
33004
33742
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/signatures.js"() {
|
|
33005
33743
|
init_regex3();
|
|
33006
|
-
|
|
33007
|
-
|
|
33008
|
-
|
|
33009
|
-
|
|
33010
|
-
|
|
33011
|
-
|
|
33012
|
-
|
|
33744
|
+
errorSignatureRegex2 = /^error (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;
|
|
33745
|
+
eventSignatureRegex2 = /^event (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)$/;
|
|
33746
|
+
functionSignatureRegex2 = /^function (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*)\((?<parameters>.*?)\)(?: (?<scope>external|public{1}))?(?: (?<stateMutability>pure|view|nonpayable|payable{1}))?(?: returns\s?\((?<returns>.*?)\))?$/;
|
|
33747
|
+
structSignatureRegex2 = /^struct (?<name>[a-zA-Z$_][a-zA-Z0-9$_]*) \{(?<properties>.*?)\}$/;
|
|
33748
|
+
constructorSignatureRegex2 = /^constructor\((?<parameters>.*?)\)(?:\s(?<stateMutability>payable{1}))?$/;
|
|
33749
|
+
fallbackSignatureRegex2 = /^fallback\(\) external(?:\s(?<stateMutability>payable{1}))?$/;
|
|
33750
|
+
receiveSignatureRegex2 = /^receive\(\) external payable$/;
|
|
33013
33751
|
modifiers = /* @__PURE__ */ new Set([
|
|
33014
33752
|
"memory",
|
|
33015
33753
|
"indexed",
|
|
33016
33754
|
"storage",
|
|
33017
33755
|
"calldata"
|
|
33018
33756
|
]);
|
|
33019
|
-
|
|
33020
|
-
|
|
33757
|
+
eventModifiers2 = /* @__PURE__ */ new Set(["indexed"]);
|
|
33758
|
+
functionModifiers2 = /* @__PURE__ */ new Set([
|
|
33021
33759
|
"calldata",
|
|
33022
33760
|
"memory",
|
|
33023
33761
|
"storage"
|
|
@@ -33026,11 +33764,11 @@ var init_signatures = __esm({
|
|
|
33026
33764
|
});
|
|
33027
33765
|
|
|
33028
33766
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/abiItem.js
|
|
33029
|
-
var
|
|
33030
|
-
var
|
|
33767
|
+
var InvalidAbiItemError2, UnknownTypeError2, UnknownSolidityTypeError2;
|
|
33768
|
+
var init_abiItem2 = __esm({
|
|
33031
33769
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/abiItem.js"() {
|
|
33032
|
-
|
|
33033
|
-
|
|
33770
|
+
init_errors2();
|
|
33771
|
+
InvalidAbiItemError2 = class extends BaseError3 {
|
|
33034
33772
|
constructor({ signature }) {
|
|
33035
33773
|
super("Failed to parse ABI item.", {
|
|
33036
33774
|
details: `parseAbiItem(${JSON.stringify(signature, null, 2)})`,
|
|
@@ -33044,7 +33782,7 @@ var init_abiItem = __esm({
|
|
|
33044
33782
|
});
|
|
33045
33783
|
}
|
|
33046
33784
|
};
|
|
33047
|
-
|
|
33785
|
+
UnknownTypeError2 = class extends BaseError3 {
|
|
33048
33786
|
constructor({ type }) {
|
|
33049
33787
|
super("Unknown type.", {
|
|
33050
33788
|
metaMessages: [
|
|
@@ -33059,7 +33797,7 @@ var init_abiItem = __esm({
|
|
|
33059
33797
|
});
|
|
33060
33798
|
}
|
|
33061
33799
|
};
|
|
33062
|
-
|
|
33800
|
+
UnknownSolidityTypeError2 = class extends BaseError3 {
|
|
33063
33801
|
constructor({ type }) {
|
|
33064
33802
|
super("Unknown type.", {
|
|
33065
33803
|
metaMessages: [`Type "${type}" is not a valid ABI type.`]
|
|
@@ -33076,11 +33814,11 @@ var init_abiItem = __esm({
|
|
|
33076
33814
|
});
|
|
33077
33815
|
|
|
33078
33816
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/abiParameter.js
|
|
33079
|
-
var
|
|
33080
|
-
var
|
|
33817
|
+
var InvalidAbiParametersError2, InvalidParameterError2, SolidityProtectedKeywordError2, InvalidModifierError2, InvalidFunctionModifierError2, InvalidAbiTypeParameterError2;
|
|
33818
|
+
var init_abiParameter2 = __esm({
|
|
33081
33819
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/abiParameter.js"() {
|
|
33082
|
-
|
|
33083
|
-
|
|
33820
|
+
init_errors2();
|
|
33821
|
+
InvalidAbiParametersError2 = class extends BaseError3 {
|
|
33084
33822
|
constructor({ params }) {
|
|
33085
33823
|
super("Failed to parse ABI parameters.", {
|
|
33086
33824
|
details: `parseAbiParameters(${JSON.stringify(params, null, 2)})`,
|
|
@@ -33094,7 +33832,7 @@ var init_abiParameter = __esm({
|
|
|
33094
33832
|
});
|
|
33095
33833
|
}
|
|
33096
33834
|
};
|
|
33097
|
-
|
|
33835
|
+
InvalidParameterError2 = class extends BaseError3 {
|
|
33098
33836
|
constructor({ param }) {
|
|
33099
33837
|
super("Invalid ABI parameter.", {
|
|
33100
33838
|
details: param
|
|
@@ -33107,7 +33845,7 @@ var init_abiParameter = __esm({
|
|
|
33107
33845
|
});
|
|
33108
33846
|
}
|
|
33109
33847
|
};
|
|
33110
|
-
|
|
33848
|
+
SolidityProtectedKeywordError2 = class extends BaseError3 {
|
|
33111
33849
|
constructor({ param, name }) {
|
|
33112
33850
|
super("Invalid ABI parameter.", {
|
|
33113
33851
|
details: param,
|
|
@@ -33123,7 +33861,7 @@ var init_abiParameter = __esm({
|
|
|
33123
33861
|
});
|
|
33124
33862
|
}
|
|
33125
33863
|
};
|
|
33126
|
-
|
|
33864
|
+
InvalidModifierError2 = class extends BaseError3 {
|
|
33127
33865
|
constructor({ param, type, modifier }) {
|
|
33128
33866
|
super("Invalid ABI parameter.", {
|
|
33129
33867
|
details: param,
|
|
@@ -33139,7 +33877,7 @@ var init_abiParameter = __esm({
|
|
|
33139
33877
|
});
|
|
33140
33878
|
}
|
|
33141
33879
|
};
|
|
33142
|
-
|
|
33880
|
+
InvalidFunctionModifierError2 = class extends BaseError3 {
|
|
33143
33881
|
constructor({ param, type, modifier }) {
|
|
33144
33882
|
super("Invalid ABI parameter.", {
|
|
33145
33883
|
details: param,
|
|
@@ -33156,7 +33894,7 @@ var init_abiParameter = __esm({
|
|
|
33156
33894
|
});
|
|
33157
33895
|
}
|
|
33158
33896
|
};
|
|
33159
|
-
|
|
33897
|
+
InvalidAbiTypeParameterError2 = class extends BaseError3 {
|
|
33160
33898
|
constructor({ abiParameter }) {
|
|
33161
33899
|
super("Invalid ABI parameter.", {
|
|
33162
33900
|
details: JSON.stringify(abiParameter, null, 2),
|
|
@@ -33174,11 +33912,11 @@ var init_abiParameter = __esm({
|
|
|
33174
33912
|
});
|
|
33175
33913
|
|
|
33176
33914
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/signature.js
|
|
33177
|
-
var
|
|
33178
|
-
var
|
|
33915
|
+
var InvalidSignatureError2, UnknownSignatureError2, InvalidStructSignatureError2;
|
|
33916
|
+
var init_signature2 = __esm({
|
|
33179
33917
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/signature.js"() {
|
|
33180
|
-
|
|
33181
|
-
|
|
33918
|
+
init_errors2();
|
|
33919
|
+
InvalidSignatureError2 = class extends BaseError3 {
|
|
33182
33920
|
constructor({ signature, type }) {
|
|
33183
33921
|
super(`Invalid ${type} signature.`, {
|
|
33184
33922
|
details: signature
|
|
@@ -33191,7 +33929,7 @@ var init_signature = __esm({
|
|
|
33191
33929
|
});
|
|
33192
33930
|
}
|
|
33193
33931
|
};
|
|
33194
|
-
|
|
33932
|
+
UnknownSignatureError2 = class extends BaseError3 {
|
|
33195
33933
|
constructor({ signature }) {
|
|
33196
33934
|
super("Unknown signature.", {
|
|
33197
33935
|
details: signature
|
|
@@ -33204,7 +33942,7 @@ var init_signature = __esm({
|
|
|
33204
33942
|
});
|
|
33205
33943
|
}
|
|
33206
33944
|
};
|
|
33207
|
-
|
|
33945
|
+
InvalidStructSignatureError2 = class extends BaseError3 {
|
|
33208
33946
|
constructor({ signature }) {
|
|
33209
33947
|
super("Invalid struct signature.", {
|
|
33210
33948
|
details: signature,
|
|
@@ -33222,11 +33960,11 @@ var init_signature = __esm({
|
|
|
33222
33960
|
});
|
|
33223
33961
|
|
|
33224
33962
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/struct.js
|
|
33225
|
-
var
|
|
33226
|
-
var
|
|
33963
|
+
var CircularReferenceError2;
|
|
33964
|
+
var init_struct2 = __esm({
|
|
33227
33965
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/struct.js"() {
|
|
33228
|
-
|
|
33229
|
-
|
|
33966
|
+
init_errors2();
|
|
33967
|
+
CircularReferenceError2 = class extends BaseError3 {
|
|
33230
33968
|
constructor({ type }) {
|
|
33231
33969
|
super("Circular reference detected.", {
|
|
33232
33970
|
metaMessages: [`Struct "${type}" is a circular reference.`]
|
|
@@ -33243,11 +33981,11 @@ var init_struct = __esm({
|
|
|
33243
33981
|
});
|
|
33244
33982
|
|
|
33245
33983
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/splitParameters.js
|
|
33246
|
-
var
|
|
33247
|
-
var
|
|
33984
|
+
var InvalidParenthesisError2;
|
|
33985
|
+
var init_splitParameters2 = __esm({
|
|
33248
33986
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/errors/splitParameters.js"() {
|
|
33249
|
-
|
|
33250
|
-
|
|
33987
|
+
init_errors2();
|
|
33988
|
+
InvalidParenthesisError2 = class extends BaseError3 {
|
|
33251
33989
|
constructor({ current, depth }) {
|
|
33252
33990
|
super("Unbalanced parentheses.", {
|
|
33253
33991
|
metaMessages: [
|
|
@@ -33267,7 +34005,7 @@ var init_splitParameters = __esm({
|
|
|
33267
34005
|
});
|
|
33268
34006
|
|
|
33269
34007
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/cache.js
|
|
33270
|
-
function
|
|
34008
|
+
function getParameterCacheKey2(param, type, structs) {
|
|
33271
34009
|
let structKey = "";
|
|
33272
34010
|
if (structs)
|
|
33273
34011
|
for (const struct of Object.entries(structs)) {
|
|
@@ -33283,10 +34021,10 @@ function getParameterCacheKey(param, type, structs) {
|
|
|
33283
34021
|
return `${type}:${param}${structKey}`;
|
|
33284
34022
|
return `${param}${structKey}`;
|
|
33285
34023
|
}
|
|
33286
|
-
var
|
|
33287
|
-
var
|
|
34024
|
+
var parameterCache2;
|
|
34025
|
+
var init_cache2 = __esm({
|
|
33288
34026
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/cache.js"() {
|
|
33289
|
-
|
|
34027
|
+
parameterCache2 = /* @__PURE__ */ new Map([
|
|
33290
34028
|
// Unnamed
|
|
33291
34029
|
["address", { type: "address" }],
|
|
33292
34030
|
["bool", { type: "bool" }],
|
|
@@ -33344,45 +34082,45 @@ var init_cache = __esm({
|
|
|
33344
34082
|
});
|
|
33345
34083
|
|
|
33346
34084
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/utils.js
|
|
33347
|
-
function
|
|
33348
|
-
if (
|
|
33349
|
-
return
|
|
33350
|
-
if (
|
|
33351
|
-
return
|
|
33352
|
-
if (
|
|
33353
|
-
return
|
|
33354
|
-
if (
|
|
33355
|
-
return
|
|
33356
|
-
if (
|
|
33357
|
-
return
|
|
33358
|
-
if (
|
|
34085
|
+
function parseSignature2(signature, structs = {}) {
|
|
34086
|
+
if (isFunctionSignature2(signature))
|
|
34087
|
+
return parseFunctionSignature2(signature, structs);
|
|
34088
|
+
if (isEventSignature2(signature))
|
|
34089
|
+
return parseEventSignature2(signature, structs);
|
|
34090
|
+
if (isErrorSignature2(signature))
|
|
34091
|
+
return parseErrorSignature2(signature, structs);
|
|
34092
|
+
if (isConstructorSignature2(signature))
|
|
34093
|
+
return parseConstructorSignature2(signature, structs);
|
|
34094
|
+
if (isFallbackSignature2(signature))
|
|
34095
|
+
return parseFallbackSignature2(signature);
|
|
34096
|
+
if (isReceiveSignature2(signature))
|
|
33359
34097
|
return {
|
|
33360
34098
|
type: "receive",
|
|
33361
34099
|
stateMutability: "payable"
|
|
33362
34100
|
};
|
|
33363
|
-
throw new
|
|
34101
|
+
throw new UnknownSignatureError2({ signature });
|
|
33364
34102
|
}
|
|
33365
|
-
function
|
|
33366
|
-
const match =
|
|
34103
|
+
function parseFunctionSignature2(signature, structs = {}) {
|
|
34104
|
+
const match = execFunctionSignature2(signature);
|
|
33367
34105
|
if (!match)
|
|
33368
|
-
throw new
|
|
33369
|
-
const inputParams =
|
|
34106
|
+
throw new InvalidSignatureError2({ signature, type: "function" });
|
|
34107
|
+
const inputParams = splitParameters2(match.parameters);
|
|
33370
34108
|
const inputs = [];
|
|
33371
34109
|
const inputLength = inputParams.length;
|
|
33372
34110
|
for (let i = 0; i < inputLength; i++) {
|
|
33373
|
-
inputs.push(
|
|
33374
|
-
modifiers:
|
|
34111
|
+
inputs.push(parseAbiParameter3(inputParams[i], {
|
|
34112
|
+
modifiers: functionModifiers2,
|
|
33375
34113
|
structs,
|
|
33376
34114
|
type: "function"
|
|
33377
34115
|
}));
|
|
33378
34116
|
}
|
|
33379
34117
|
const outputs = [];
|
|
33380
34118
|
if (match.returns) {
|
|
33381
|
-
const outputParams =
|
|
34119
|
+
const outputParams = splitParameters2(match.returns);
|
|
33382
34120
|
const outputLength = outputParams.length;
|
|
33383
34121
|
for (let i = 0; i < outputLength; i++) {
|
|
33384
|
-
outputs.push(
|
|
33385
|
-
modifiers:
|
|
34122
|
+
outputs.push(parseAbiParameter3(outputParams[i], {
|
|
34123
|
+
modifiers: functionModifiers2,
|
|
33386
34124
|
structs,
|
|
33387
34125
|
type: "function"
|
|
33388
34126
|
}));
|
|
@@ -33396,66 +34134,66 @@ function parseFunctionSignature(signature, structs = {}) {
|
|
|
33396
34134
|
outputs
|
|
33397
34135
|
};
|
|
33398
34136
|
}
|
|
33399
|
-
function
|
|
33400
|
-
const match =
|
|
34137
|
+
function parseEventSignature2(signature, structs = {}) {
|
|
34138
|
+
const match = execEventSignature2(signature);
|
|
33401
34139
|
if (!match)
|
|
33402
|
-
throw new
|
|
33403
|
-
const params =
|
|
34140
|
+
throw new InvalidSignatureError2({ signature, type: "event" });
|
|
34141
|
+
const params = splitParameters2(match.parameters);
|
|
33404
34142
|
const abiParameters = [];
|
|
33405
34143
|
const length = params.length;
|
|
33406
34144
|
for (let i = 0; i < length; i++)
|
|
33407
|
-
abiParameters.push(
|
|
33408
|
-
modifiers:
|
|
34145
|
+
abiParameters.push(parseAbiParameter3(params[i], {
|
|
34146
|
+
modifiers: eventModifiers2,
|
|
33409
34147
|
structs,
|
|
33410
34148
|
type: "event"
|
|
33411
34149
|
}));
|
|
33412
34150
|
return { name: match.name, type: "event", inputs: abiParameters };
|
|
33413
34151
|
}
|
|
33414
|
-
function
|
|
33415
|
-
const match =
|
|
34152
|
+
function parseErrorSignature2(signature, structs = {}) {
|
|
34153
|
+
const match = execErrorSignature2(signature);
|
|
33416
34154
|
if (!match)
|
|
33417
|
-
throw new
|
|
33418
|
-
const params =
|
|
34155
|
+
throw new InvalidSignatureError2({ signature, type: "error" });
|
|
34156
|
+
const params = splitParameters2(match.parameters);
|
|
33419
34157
|
const abiParameters = [];
|
|
33420
34158
|
const length = params.length;
|
|
33421
34159
|
for (let i = 0; i < length; i++)
|
|
33422
|
-
abiParameters.push(
|
|
34160
|
+
abiParameters.push(parseAbiParameter3(params[i], { structs, type: "error" }));
|
|
33423
34161
|
return { name: match.name, type: "error", inputs: abiParameters };
|
|
33424
34162
|
}
|
|
33425
|
-
function
|
|
33426
|
-
const match =
|
|
34163
|
+
function parseConstructorSignature2(signature, structs = {}) {
|
|
34164
|
+
const match = execConstructorSignature2(signature);
|
|
33427
34165
|
if (!match)
|
|
33428
|
-
throw new
|
|
33429
|
-
const params =
|
|
34166
|
+
throw new InvalidSignatureError2({ signature, type: "constructor" });
|
|
34167
|
+
const params = splitParameters2(match.parameters);
|
|
33430
34168
|
const abiParameters = [];
|
|
33431
34169
|
const length = params.length;
|
|
33432
34170
|
for (let i = 0; i < length; i++)
|
|
33433
|
-
abiParameters.push(
|
|
34171
|
+
abiParameters.push(parseAbiParameter3(params[i], { structs, type: "constructor" }));
|
|
33434
34172
|
return {
|
|
33435
34173
|
type: "constructor",
|
|
33436
34174
|
stateMutability: match.stateMutability ?? "nonpayable",
|
|
33437
34175
|
inputs: abiParameters
|
|
33438
34176
|
};
|
|
33439
34177
|
}
|
|
33440
|
-
function
|
|
33441
|
-
const match =
|
|
34178
|
+
function parseFallbackSignature2(signature) {
|
|
34179
|
+
const match = execFallbackSignature2(signature);
|
|
33442
34180
|
if (!match)
|
|
33443
|
-
throw new
|
|
34181
|
+
throw new InvalidSignatureError2({ signature, type: "fallback" });
|
|
33444
34182
|
return {
|
|
33445
34183
|
type: "fallback",
|
|
33446
34184
|
stateMutability: match.stateMutability ?? "nonpayable"
|
|
33447
34185
|
};
|
|
33448
34186
|
}
|
|
33449
|
-
function
|
|
33450
|
-
const parameterCacheKey =
|
|
33451
|
-
if (
|
|
33452
|
-
return
|
|
33453
|
-
const isTuple =
|
|
33454
|
-
const match = execTyped2(isTuple ?
|
|
34187
|
+
function parseAbiParameter3(param, options) {
|
|
34188
|
+
const parameterCacheKey = getParameterCacheKey2(param, options?.type, options?.structs);
|
|
34189
|
+
if (parameterCache2.has(parameterCacheKey))
|
|
34190
|
+
return parameterCache2.get(parameterCacheKey);
|
|
34191
|
+
const isTuple = isTupleRegex2.test(param);
|
|
34192
|
+
const match = execTyped2(isTuple ? abiParameterWithTupleRegex2 : abiParameterWithoutTupleRegex2, param);
|
|
33455
34193
|
if (!match)
|
|
33456
|
-
throw new
|
|
33457
|
-
if (match.name &&
|
|
33458
|
-
throw new
|
|
34194
|
+
throw new InvalidParameterError2({ param });
|
|
34195
|
+
if (match.name && isSolidityKeyword2(match.name))
|
|
34196
|
+
throw new SolidityProtectedKeywordError2({ param, name: match.name });
|
|
33459
34197
|
const name = match.name ? { name: match.name } : {};
|
|
33460
34198
|
const indexed = match.modifier === "indexed" ? { indexed: true } : {};
|
|
33461
34199
|
const structs = options?.structs ?? {};
|
|
@@ -33463,34 +34201,34 @@ function parseAbiParameter(param, options) {
|
|
|
33463
34201
|
let components = {};
|
|
33464
34202
|
if (isTuple) {
|
|
33465
34203
|
type = "tuple";
|
|
33466
|
-
const params =
|
|
34204
|
+
const params = splitParameters2(match.type);
|
|
33467
34205
|
const components_ = [];
|
|
33468
34206
|
const length = params.length;
|
|
33469
34207
|
for (let i = 0; i < length; i++) {
|
|
33470
|
-
components_.push(
|
|
34208
|
+
components_.push(parseAbiParameter3(params[i], { structs }));
|
|
33471
34209
|
}
|
|
33472
34210
|
components = { components: components_ };
|
|
33473
34211
|
} else if (match.type in structs) {
|
|
33474
34212
|
type = "tuple";
|
|
33475
34213
|
components = { components: structs[match.type] };
|
|
33476
|
-
} else if (
|
|
34214
|
+
} else if (dynamicIntegerRegex2.test(match.type)) {
|
|
33477
34215
|
type = `${match.type}256`;
|
|
33478
34216
|
} else if (match.type === "address payable") {
|
|
33479
34217
|
type = "address";
|
|
33480
34218
|
} else {
|
|
33481
34219
|
type = match.type;
|
|
33482
|
-
if (!(options?.type === "struct") && !
|
|
33483
|
-
throw new
|
|
34220
|
+
if (!(options?.type === "struct") && !isSolidityType2(type))
|
|
34221
|
+
throw new UnknownSolidityTypeError2({ type });
|
|
33484
34222
|
}
|
|
33485
34223
|
if (match.modifier) {
|
|
33486
34224
|
if (!options?.modifiers?.has?.(match.modifier))
|
|
33487
|
-
throw new
|
|
34225
|
+
throw new InvalidModifierError2({
|
|
33488
34226
|
param,
|
|
33489
34227
|
type: options?.type,
|
|
33490
34228
|
modifier: match.modifier
|
|
33491
34229
|
});
|
|
33492
|
-
if (
|
|
33493
|
-
throw new
|
|
34230
|
+
if (functionModifiers2.has(match.modifier) && !isValidDataLocation2(type, !!match.array))
|
|
34231
|
+
throw new InvalidFunctionModifierError2({
|
|
33494
34232
|
param,
|
|
33495
34233
|
type: options?.type,
|
|
33496
34234
|
modifier: match.modifier
|
|
@@ -33502,69 +34240,69 @@ function parseAbiParameter(param, options) {
|
|
|
33502
34240
|
...indexed,
|
|
33503
34241
|
...components
|
|
33504
34242
|
};
|
|
33505
|
-
|
|
34243
|
+
parameterCache2.set(parameterCacheKey, abiParameter);
|
|
33506
34244
|
return abiParameter;
|
|
33507
34245
|
}
|
|
33508
|
-
function
|
|
34246
|
+
function splitParameters2(params, result = [], current = "", depth = 0) {
|
|
33509
34247
|
const length = params.trim().length;
|
|
33510
34248
|
for (let i = 0; i < length; i++) {
|
|
33511
34249
|
const char = params[i];
|
|
33512
34250
|
const tail = params.slice(i + 1);
|
|
33513
34251
|
switch (char) {
|
|
33514
34252
|
case ",":
|
|
33515
|
-
return depth === 0 ?
|
|
34253
|
+
return depth === 0 ? splitParameters2(tail, [...result, current.trim()]) : splitParameters2(tail, result, `${current}${char}`, depth);
|
|
33516
34254
|
case "(":
|
|
33517
|
-
return
|
|
34255
|
+
return splitParameters2(tail, result, `${current}${char}`, depth + 1);
|
|
33518
34256
|
case ")":
|
|
33519
|
-
return
|
|
34257
|
+
return splitParameters2(tail, result, `${current}${char}`, depth - 1);
|
|
33520
34258
|
default:
|
|
33521
|
-
return
|
|
34259
|
+
return splitParameters2(tail, result, `${current}${char}`, depth);
|
|
33522
34260
|
}
|
|
33523
34261
|
}
|
|
33524
34262
|
if (current === "")
|
|
33525
34263
|
return result;
|
|
33526
34264
|
if (depth !== 0)
|
|
33527
|
-
throw new
|
|
34265
|
+
throw new InvalidParenthesisError2({ current, depth });
|
|
33528
34266
|
result.push(current.trim());
|
|
33529
34267
|
return result;
|
|
33530
34268
|
}
|
|
33531
|
-
function
|
|
33532
|
-
return type === "address" || type === "bool" || type === "function" || type === "string" ||
|
|
34269
|
+
function isSolidityType2(type) {
|
|
34270
|
+
return type === "address" || type === "bool" || type === "function" || type === "string" || bytesRegex3.test(type) || integerRegex3.test(type);
|
|
33533
34271
|
}
|
|
33534
|
-
function
|
|
33535
|
-
return name === "address" || name === "bool" || name === "function" || name === "string" || name === "tuple" ||
|
|
34272
|
+
function isSolidityKeyword2(name) {
|
|
34273
|
+
return name === "address" || name === "bool" || name === "function" || name === "string" || name === "tuple" || bytesRegex3.test(name) || integerRegex3.test(name) || protectedKeywordsRegex2.test(name);
|
|
33536
34274
|
}
|
|
33537
|
-
function
|
|
34275
|
+
function isValidDataLocation2(type, isArray) {
|
|
33538
34276
|
return isArray || type === "bytes" || type === "string" || type === "tuple";
|
|
33539
34277
|
}
|
|
33540
|
-
var
|
|
33541
|
-
var
|
|
34278
|
+
var abiParameterWithoutTupleRegex2, abiParameterWithTupleRegex2, dynamicIntegerRegex2, protectedKeywordsRegex2;
|
|
34279
|
+
var init_utils4 = __esm({
|
|
33542
34280
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/utils.js"() {
|
|
33543
34281
|
init_regex3();
|
|
33544
|
-
|
|
33545
|
-
|
|
33546
|
-
|
|
33547
|
-
|
|
33548
|
-
|
|
33549
|
-
|
|
33550
|
-
|
|
33551
|
-
|
|
33552
|
-
|
|
33553
|
-
|
|
34282
|
+
init_abiItem2();
|
|
34283
|
+
init_abiParameter2();
|
|
34284
|
+
init_signature2();
|
|
34285
|
+
init_splitParameters2();
|
|
34286
|
+
init_cache2();
|
|
34287
|
+
init_signatures2();
|
|
34288
|
+
abiParameterWithoutTupleRegex2 = /^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*(?:\spayable)?)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/;
|
|
34289
|
+
abiParameterWithTupleRegex2 = /^\((?<type>.+?)\)(?<array>(?:\[\d*?\])+?)?(?:\s(?<modifier>calldata|indexed|memory|storage{1}))?(?:\s(?<name>[a-zA-Z$_][a-zA-Z0-9$_]*))?$/;
|
|
34290
|
+
dynamicIntegerRegex2 = /^u?int$/;
|
|
34291
|
+
protectedKeywordsRegex2 = /^(?:after|alias|anonymous|apply|auto|byte|calldata|case|catch|constant|copyof|default|defined|error|event|external|false|final|function|immutable|implements|in|indexed|inline|internal|let|mapping|match|memory|mutable|null|of|override|partial|private|promise|public|pure|reference|relocatable|return|returns|sizeof|static|storage|struct|super|supports|switch|this|true|try|typedef|typeof|var|view|virtual)$/;
|
|
33554
34292
|
}
|
|
33555
34293
|
});
|
|
33556
34294
|
|
|
33557
34295
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/structs.js
|
|
33558
|
-
function
|
|
34296
|
+
function parseStructs2(signatures) {
|
|
33559
34297
|
const shallowStructs = {};
|
|
33560
34298
|
const signaturesLength = signatures.length;
|
|
33561
34299
|
for (let i = 0; i < signaturesLength; i++) {
|
|
33562
34300
|
const signature = signatures[i];
|
|
33563
|
-
if (!
|
|
34301
|
+
if (!isStructSignature2(signature))
|
|
33564
34302
|
continue;
|
|
33565
|
-
const match =
|
|
34303
|
+
const match = execStructSignature2(signature);
|
|
33566
34304
|
if (!match)
|
|
33567
|
-
throw new
|
|
34305
|
+
throw new InvalidSignatureError2({ signature, type: "struct" });
|
|
33568
34306
|
const properties = match.properties.split(";");
|
|
33569
34307
|
const components = [];
|
|
33570
34308
|
const propertiesLength = properties.length;
|
|
@@ -33573,13 +34311,13 @@ function parseStructs(signatures) {
|
|
|
33573
34311
|
const trimmed = property.trim();
|
|
33574
34312
|
if (!trimmed)
|
|
33575
34313
|
continue;
|
|
33576
|
-
const abiParameter =
|
|
34314
|
+
const abiParameter = parseAbiParameter3(trimmed, {
|
|
33577
34315
|
type: "struct"
|
|
33578
34316
|
});
|
|
33579
34317
|
components.push(abiParameter);
|
|
33580
34318
|
}
|
|
33581
34319
|
if (!components.length)
|
|
33582
|
-
throw new
|
|
34320
|
+
throw new InvalidStructSignatureError2({ signature });
|
|
33583
34321
|
shallowStructs[match.name] = components;
|
|
33584
34322
|
}
|
|
33585
34323
|
const resolvedStructs = {};
|
|
@@ -33587,139 +34325,139 @@ function parseStructs(signatures) {
|
|
|
33587
34325
|
const entriesLength = entries.length;
|
|
33588
34326
|
for (let i = 0; i < entriesLength; i++) {
|
|
33589
34327
|
const [name, parameters] = entries[i];
|
|
33590
|
-
resolvedStructs[name] =
|
|
34328
|
+
resolvedStructs[name] = resolveStructs2(parameters, shallowStructs);
|
|
33591
34329
|
}
|
|
33592
34330
|
return resolvedStructs;
|
|
33593
34331
|
}
|
|
33594
|
-
function
|
|
34332
|
+
function resolveStructs2(abiParameters = [], structs = {}, ancestors = /* @__PURE__ */ new Set()) {
|
|
33595
34333
|
const components = [];
|
|
33596
34334
|
const length = abiParameters.length;
|
|
33597
34335
|
for (let i = 0; i < length; i++) {
|
|
33598
34336
|
const abiParameter = abiParameters[i];
|
|
33599
|
-
const isTuple =
|
|
34337
|
+
const isTuple = isTupleRegex2.test(abiParameter.type);
|
|
33600
34338
|
if (isTuple)
|
|
33601
34339
|
components.push(abiParameter);
|
|
33602
34340
|
else {
|
|
33603
|
-
const match = execTyped2(
|
|
34341
|
+
const match = execTyped2(typeWithoutTupleRegex2, abiParameter.type);
|
|
33604
34342
|
if (!match?.type)
|
|
33605
|
-
throw new
|
|
34343
|
+
throw new InvalidAbiTypeParameterError2({ abiParameter });
|
|
33606
34344
|
const { array, type } = match;
|
|
33607
34345
|
if (type in structs) {
|
|
33608
34346
|
if (ancestors.has(type))
|
|
33609
|
-
throw new
|
|
34347
|
+
throw new CircularReferenceError2({ type });
|
|
33610
34348
|
components.push({
|
|
33611
34349
|
...abiParameter,
|
|
33612
34350
|
type: `tuple${array ?? ""}`,
|
|
33613
|
-
components:
|
|
34351
|
+
components: resolveStructs2(structs[type], structs, /* @__PURE__ */ new Set([...ancestors, type]))
|
|
33614
34352
|
});
|
|
33615
34353
|
} else {
|
|
33616
|
-
if (
|
|
34354
|
+
if (isSolidityType2(type))
|
|
33617
34355
|
components.push(abiParameter);
|
|
33618
34356
|
else
|
|
33619
|
-
throw new
|
|
34357
|
+
throw new UnknownTypeError2({ type });
|
|
33620
34358
|
}
|
|
33621
34359
|
}
|
|
33622
34360
|
}
|
|
33623
34361
|
return components;
|
|
33624
34362
|
}
|
|
33625
|
-
var
|
|
33626
|
-
var
|
|
34363
|
+
var typeWithoutTupleRegex2;
|
|
34364
|
+
var init_structs2 = __esm({
|
|
33627
34365
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/runtime/structs.js"() {
|
|
33628
34366
|
init_regex3();
|
|
33629
|
-
|
|
33630
|
-
|
|
33631
|
-
|
|
33632
|
-
|
|
33633
|
-
|
|
33634
|
-
|
|
33635
|
-
|
|
34367
|
+
init_abiItem2();
|
|
34368
|
+
init_abiParameter2();
|
|
34369
|
+
init_signature2();
|
|
34370
|
+
init_struct2();
|
|
34371
|
+
init_signatures2();
|
|
34372
|
+
init_utils4();
|
|
34373
|
+
typeWithoutTupleRegex2 = /^(?<type>[a-zA-Z$_][a-zA-Z0-9$_]*)(?<array>(?:\[\d*?\])+?)?$/;
|
|
33636
34374
|
}
|
|
33637
34375
|
});
|
|
33638
34376
|
|
|
33639
34377
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbi.js
|
|
33640
|
-
function
|
|
33641
|
-
const structs =
|
|
34378
|
+
function parseAbi2(signatures) {
|
|
34379
|
+
const structs = parseStructs2(signatures);
|
|
33642
34380
|
const abi2 = [];
|
|
33643
34381
|
const length = signatures.length;
|
|
33644
34382
|
for (let i = 0; i < length; i++) {
|
|
33645
34383
|
const signature = signatures[i];
|
|
33646
|
-
if (
|
|
34384
|
+
if (isStructSignature2(signature))
|
|
33647
34385
|
continue;
|
|
33648
|
-
abi2.push(
|
|
34386
|
+
abi2.push(parseSignature2(signature, structs));
|
|
33649
34387
|
}
|
|
33650
34388
|
return abi2;
|
|
33651
34389
|
}
|
|
33652
|
-
var
|
|
34390
|
+
var init_parseAbi2 = __esm({
|
|
33653
34391
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbi.js"() {
|
|
33654
|
-
|
|
33655
|
-
|
|
33656
|
-
|
|
34392
|
+
init_signatures2();
|
|
34393
|
+
init_structs2();
|
|
34394
|
+
init_utils4();
|
|
33657
34395
|
}
|
|
33658
34396
|
});
|
|
33659
34397
|
|
|
33660
34398
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbiItem.js
|
|
33661
|
-
function
|
|
34399
|
+
function parseAbiItem2(signature) {
|
|
33662
34400
|
let abiItem;
|
|
33663
34401
|
if (typeof signature === "string")
|
|
33664
|
-
abiItem =
|
|
34402
|
+
abiItem = parseSignature2(signature);
|
|
33665
34403
|
else {
|
|
33666
|
-
const structs =
|
|
34404
|
+
const structs = parseStructs2(signature);
|
|
33667
34405
|
const length = signature.length;
|
|
33668
34406
|
for (let i = 0; i < length; i++) {
|
|
33669
34407
|
const signature_ = signature[i];
|
|
33670
|
-
if (
|
|
34408
|
+
if (isStructSignature2(signature_))
|
|
33671
34409
|
continue;
|
|
33672
|
-
abiItem =
|
|
34410
|
+
abiItem = parseSignature2(signature_, structs);
|
|
33673
34411
|
break;
|
|
33674
34412
|
}
|
|
33675
34413
|
}
|
|
33676
34414
|
if (!abiItem)
|
|
33677
|
-
throw new
|
|
34415
|
+
throw new InvalidAbiItemError2({ signature });
|
|
33678
34416
|
return abiItem;
|
|
33679
34417
|
}
|
|
33680
34418
|
var init_parseAbiItem = __esm({
|
|
33681
34419
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbiItem.js"() {
|
|
33682
|
-
|
|
33683
|
-
|
|
33684
|
-
|
|
33685
|
-
|
|
34420
|
+
init_abiItem2();
|
|
34421
|
+
init_signatures2();
|
|
34422
|
+
init_structs2();
|
|
34423
|
+
init_utils4();
|
|
33686
34424
|
}
|
|
33687
34425
|
});
|
|
33688
34426
|
|
|
33689
34427
|
// ../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbiParameters.js
|
|
33690
|
-
function
|
|
34428
|
+
function parseAbiParameters2(params) {
|
|
33691
34429
|
const abiParameters = [];
|
|
33692
34430
|
if (typeof params === "string") {
|
|
33693
|
-
const parameters =
|
|
34431
|
+
const parameters = splitParameters2(params);
|
|
33694
34432
|
const length = parameters.length;
|
|
33695
34433
|
for (let i = 0; i < length; i++) {
|
|
33696
|
-
abiParameters.push(
|
|
34434
|
+
abiParameters.push(parseAbiParameter3(parameters[i], { modifiers }));
|
|
33697
34435
|
}
|
|
33698
34436
|
} else {
|
|
33699
|
-
const structs =
|
|
34437
|
+
const structs = parseStructs2(params);
|
|
33700
34438
|
const length = params.length;
|
|
33701
34439
|
for (let i = 0; i < length; i++) {
|
|
33702
34440
|
const signature = params[i];
|
|
33703
|
-
if (
|
|
34441
|
+
if (isStructSignature2(signature))
|
|
33704
34442
|
continue;
|
|
33705
|
-
const parameters =
|
|
34443
|
+
const parameters = splitParameters2(signature);
|
|
33706
34444
|
const length2 = parameters.length;
|
|
33707
34445
|
for (let k = 0; k < length2; k++) {
|
|
33708
|
-
abiParameters.push(
|
|
34446
|
+
abiParameters.push(parseAbiParameter3(parameters[k], { modifiers, structs }));
|
|
33709
34447
|
}
|
|
33710
34448
|
}
|
|
33711
34449
|
}
|
|
33712
34450
|
if (abiParameters.length === 0)
|
|
33713
|
-
throw new
|
|
34451
|
+
throw new InvalidAbiParametersError2({ params });
|
|
33714
34452
|
return abiParameters;
|
|
33715
34453
|
}
|
|
33716
34454
|
var init_parseAbiParameters = __esm({
|
|
33717
34455
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/human-readable/parseAbiParameters.js"() {
|
|
33718
|
-
|
|
33719
|
-
|
|
33720
|
-
|
|
33721
|
-
|
|
33722
|
-
|
|
34456
|
+
init_abiParameter2();
|
|
34457
|
+
init_signatures2();
|
|
34458
|
+
init_structs2();
|
|
34459
|
+
init_utils4();
|
|
34460
|
+
init_utils4();
|
|
33723
34461
|
}
|
|
33724
34462
|
});
|
|
33725
34463
|
|
|
@@ -33728,7 +34466,7 @@ var init_exports2 = __esm({
|
|
|
33728
34466
|
"../../node_modules/.pnpm/abitype@1.2.3_typescript@5.9.3_zod@3.25.76/node_modules/abitype/dist/esm/exports/index.js"() {
|
|
33729
34467
|
init_formatAbiItem3();
|
|
33730
34468
|
init_formatAbiParameters2();
|
|
33731
|
-
|
|
34469
|
+
init_parseAbi2();
|
|
33732
34470
|
init_parseAbiItem();
|
|
33733
34471
|
init_parseAbiParameters();
|
|
33734
34472
|
}
|
|
@@ -33783,10 +34521,10 @@ var init_size2 = __esm({
|
|
|
33783
34521
|
});
|
|
33784
34522
|
|
|
33785
34523
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/version.js
|
|
33786
|
-
var
|
|
33787
|
-
var
|
|
34524
|
+
var version4;
|
|
34525
|
+
var init_version4 = __esm({
|
|
33788
34526
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/version.js"() {
|
|
33789
|
-
|
|
34527
|
+
version4 = "2.51.3";
|
|
33790
34528
|
}
|
|
33791
34529
|
});
|
|
33792
34530
|
|
|
@@ -33798,15 +34536,15 @@ function walk2(err, fn) {
|
|
|
33798
34536
|
return walk2(err.cause, fn);
|
|
33799
34537
|
return fn ? null : err;
|
|
33800
34538
|
}
|
|
33801
|
-
var errorConfig2,
|
|
34539
|
+
var errorConfig2, BaseError4;
|
|
33802
34540
|
var init_base2 = __esm({
|
|
33803
34541
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/base.js"() {
|
|
33804
|
-
|
|
34542
|
+
init_version4();
|
|
33805
34543
|
errorConfig2 = {
|
|
33806
34544
|
getDocsUrl: ({ docsBaseUrl, docsPath: docsPath9 = "", docsSlug }) => docsPath9 ? `${docsBaseUrl ?? "https://viem.sh"}${docsPath9}${docsSlug ? `#${docsSlug}` : ""}` : void 0,
|
|
33807
|
-
version: `viem@${
|
|
34545
|
+
version: `viem@${version4}`
|
|
33808
34546
|
};
|
|
33809
|
-
|
|
34547
|
+
BaseError4 = class _BaseError extends Error {
|
|
33810
34548
|
constructor(shortMessage, args = {}) {
|
|
33811
34549
|
const details = (() => {
|
|
33812
34550
|
if (args.cause instanceof _BaseError)
|
|
@@ -33871,7 +34609,7 @@ var init_base2 = __esm({
|
|
|
33871
34609
|
this.metaMessages = args.metaMessages;
|
|
33872
34610
|
this.name = args.name ?? this.name;
|
|
33873
34611
|
this.shortMessage = shortMessage;
|
|
33874
|
-
this.version =
|
|
34612
|
+
this.version = version4;
|
|
33875
34613
|
}
|
|
33876
34614
|
walk(fn) {
|
|
33877
34615
|
return walk2(this, fn);
|
|
@@ -33887,7 +34625,7 @@ var init_abi2 = __esm({
|
|
|
33887
34625
|
init_formatAbiItem4();
|
|
33888
34626
|
init_size2();
|
|
33889
34627
|
init_base2();
|
|
33890
|
-
AbiConstructorNotFoundError = class extends
|
|
34628
|
+
AbiConstructorNotFoundError = class extends BaseError4 {
|
|
33891
34629
|
constructor({ docsPath: docsPath9 }) {
|
|
33892
34630
|
super([
|
|
33893
34631
|
"A constructor was not found on the ABI.",
|
|
@@ -33898,7 +34636,7 @@ var init_abi2 = __esm({
|
|
|
33898
34636
|
});
|
|
33899
34637
|
}
|
|
33900
34638
|
};
|
|
33901
|
-
AbiConstructorParamsNotFoundError = class extends
|
|
34639
|
+
AbiConstructorParamsNotFoundError = class extends BaseError4 {
|
|
33902
34640
|
constructor({ docsPath: docsPath9 }) {
|
|
33903
34641
|
super([
|
|
33904
34642
|
"Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.",
|
|
@@ -33909,7 +34647,7 @@ var init_abi2 = __esm({
|
|
|
33909
34647
|
});
|
|
33910
34648
|
}
|
|
33911
34649
|
};
|
|
33912
|
-
AbiDecodingDataSizeTooSmallError = class extends
|
|
34650
|
+
AbiDecodingDataSizeTooSmallError = class extends BaseError4 {
|
|
33913
34651
|
constructor({ data, params, size: size6 }) {
|
|
33914
34652
|
super([`Data size of ${size6} bytes is too small for given parameters.`].join("\n"), {
|
|
33915
34653
|
metaMessages: [
|
|
@@ -33941,7 +34679,7 @@ var init_abi2 = __esm({
|
|
|
33941
34679
|
this.size = size6;
|
|
33942
34680
|
}
|
|
33943
34681
|
};
|
|
33944
|
-
AbiDecodingZeroDataError = class extends
|
|
34682
|
+
AbiDecodingZeroDataError = class extends BaseError4 {
|
|
33945
34683
|
constructor({ cause } = {}) {
|
|
33946
34684
|
super('Cannot decode zero data ("0x") with ABI parameters.', {
|
|
33947
34685
|
name: "AbiDecodingZeroDataError",
|
|
@@ -33949,7 +34687,7 @@ var init_abi2 = __esm({
|
|
|
33949
34687
|
});
|
|
33950
34688
|
}
|
|
33951
34689
|
};
|
|
33952
|
-
AbiEncodingArrayLengthMismatchError2 = class extends
|
|
34690
|
+
AbiEncodingArrayLengthMismatchError2 = class extends BaseError4 {
|
|
33953
34691
|
constructor({ expectedLength, givenLength, type }) {
|
|
33954
34692
|
super([
|
|
33955
34693
|
`ABI encoding array length mismatch for type ${type}.`,
|
|
@@ -33958,12 +34696,12 @@ var init_abi2 = __esm({
|
|
|
33958
34696
|
].join("\n"), { name: "AbiEncodingArrayLengthMismatchError" });
|
|
33959
34697
|
}
|
|
33960
34698
|
};
|
|
33961
|
-
AbiEncodingBytesSizeMismatchError2 = class extends
|
|
34699
|
+
AbiEncodingBytesSizeMismatchError2 = class extends BaseError4 {
|
|
33962
34700
|
constructor({ expectedSize, value }) {
|
|
33963
34701
|
super(`Size of bytes "${value}" (bytes${size2(value)}) does not match expected size (bytes${expectedSize}).`, { name: "AbiEncodingBytesSizeMismatchError" });
|
|
33964
34702
|
}
|
|
33965
34703
|
};
|
|
33966
|
-
AbiEncodingLengthMismatchError2 = class extends
|
|
34704
|
+
AbiEncodingLengthMismatchError2 = class extends BaseError4 {
|
|
33967
34705
|
constructor({ expectedLength, givenLength }) {
|
|
33968
34706
|
super([
|
|
33969
34707
|
"ABI encoding params/values length mismatch.",
|
|
@@ -33972,7 +34710,7 @@ var init_abi2 = __esm({
|
|
|
33972
34710
|
].join("\n"), { name: "AbiEncodingLengthMismatchError" });
|
|
33973
34711
|
}
|
|
33974
34712
|
};
|
|
33975
|
-
AbiErrorInputsNotFoundError = class extends
|
|
34713
|
+
AbiErrorInputsNotFoundError = class extends BaseError4 {
|
|
33976
34714
|
constructor(errorName, { docsPath: docsPath9 }) {
|
|
33977
34715
|
super([
|
|
33978
34716
|
`Arguments (\`args\`) were provided to "${errorName}", but "${errorName}" on the ABI does not contain any parameters (\`inputs\`).`,
|
|
@@ -33984,7 +34722,7 @@ var init_abi2 = __esm({
|
|
|
33984
34722
|
});
|
|
33985
34723
|
}
|
|
33986
34724
|
};
|
|
33987
|
-
AbiErrorNotFoundError = class extends
|
|
34725
|
+
AbiErrorNotFoundError = class extends BaseError4 {
|
|
33988
34726
|
constructor(errorName, { docsPath: docsPath9 } = {}) {
|
|
33989
34727
|
super([
|
|
33990
34728
|
`Error ${errorName ? `"${errorName}" ` : ""}not found on ABI.`,
|
|
@@ -33995,7 +34733,7 @@ var init_abi2 = __esm({
|
|
|
33995
34733
|
});
|
|
33996
34734
|
}
|
|
33997
34735
|
};
|
|
33998
|
-
AbiErrorSignatureNotFoundError = class extends
|
|
34736
|
+
AbiErrorSignatureNotFoundError = class extends BaseError4 {
|
|
33999
34737
|
constructor(signature, { docsPath: docsPath9, cause }) {
|
|
34000
34738
|
super([
|
|
34001
34739
|
`Encoded error signature "${signature}" not found on ABI.`,
|
|
@@ -34015,7 +34753,7 @@ var init_abi2 = __esm({
|
|
|
34015
34753
|
this.signature = signature;
|
|
34016
34754
|
}
|
|
34017
34755
|
};
|
|
34018
|
-
AbiEventSignatureEmptyTopicsError = class extends
|
|
34756
|
+
AbiEventSignatureEmptyTopicsError = class extends BaseError4 {
|
|
34019
34757
|
constructor({ docsPath: docsPath9 }) {
|
|
34020
34758
|
super("Cannot extract event signature from empty topics.", {
|
|
34021
34759
|
docsPath: docsPath9,
|
|
@@ -34023,7 +34761,7 @@ var init_abi2 = __esm({
|
|
|
34023
34761
|
});
|
|
34024
34762
|
}
|
|
34025
34763
|
};
|
|
34026
|
-
AbiEventSignatureNotFoundError = class extends
|
|
34764
|
+
AbiEventSignatureNotFoundError = class extends BaseError4 {
|
|
34027
34765
|
constructor(signature, { docsPath: docsPath9 }) {
|
|
34028
34766
|
super([
|
|
34029
34767
|
`Encoded event signature "${signature}" not found on ABI.`,
|
|
@@ -34035,7 +34773,7 @@ var init_abi2 = __esm({
|
|
|
34035
34773
|
});
|
|
34036
34774
|
}
|
|
34037
34775
|
};
|
|
34038
|
-
AbiEventNotFoundError = class extends
|
|
34776
|
+
AbiEventNotFoundError = class extends BaseError4 {
|
|
34039
34777
|
constructor(eventName, { docsPath: docsPath9 } = {}) {
|
|
34040
34778
|
super([
|
|
34041
34779
|
`Event ${eventName ? `"${eventName}" ` : ""}not found on ABI.`,
|
|
@@ -34046,7 +34784,7 @@ var init_abi2 = __esm({
|
|
|
34046
34784
|
});
|
|
34047
34785
|
}
|
|
34048
34786
|
};
|
|
34049
|
-
AbiFunctionNotFoundError2 = class extends
|
|
34787
|
+
AbiFunctionNotFoundError2 = class extends BaseError4 {
|
|
34050
34788
|
constructor(functionName, { docsPath: docsPath9 } = {}) {
|
|
34051
34789
|
super([
|
|
34052
34790
|
`Function ${functionName ? `"${functionName}" ` : ""}not found on ABI.`,
|
|
@@ -34057,7 +34795,7 @@ var init_abi2 = __esm({
|
|
|
34057
34795
|
});
|
|
34058
34796
|
}
|
|
34059
34797
|
};
|
|
34060
|
-
AbiFunctionOutputsNotFoundError = class extends
|
|
34798
|
+
AbiFunctionOutputsNotFoundError = class extends BaseError4 {
|
|
34061
34799
|
constructor(functionName, { docsPath: docsPath9 }) {
|
|
34062
34800
|
super([
|
|
34063
34801
|
`Function "${functionName}" does not contain any \`outputs\` on ABI.`,
|
|
@@ -34069,7 +34807,7 @@ var init_abi2 = __esm({
|
|
|
34069
34807
|
});
|
|
34070
34808
|
}
|
|
34071
34809
|
};
|
|
34072
|
-
AbiFunctionSignatureNotFoundError = class extends
|
|
34810
|
+
AbiFunctionSignatureNotFoundError = class extends BaseError4 {
|
|
34073
34811
|
constructor(signature, { docsPath: docsPath9 }) {
|
|
34074
34812
|
super([
|
|
34075
34813
|
`Encoded function signature "${signature}" not found on ABI.`,
|
|
@@ -34081,7 +34819,7 @@ var init_abi2 = __esm({
|
|
|
34081
34819
|
});
|
|
34082
34820
|
}
|
|
34083
34821
|
};
|
|
34084
|
-
AbiItemAmbiguityError2 = class extends
|
|
34822
|
+
AbiItemAmbiguityError2 = class extends BaseError4 {
|
|
34085
34823
|
constructor(x, y) {
|
|
34086
34824
|
super("Found ambiguous types in overloaded ABI items.", {
|
|
34087
34825
|
metaMessages: [
|
|
@@ -34095,14 +34833,14 @@ var init_abi2 = __esm({
|
|
|
34095
34833
|
});
|
|
34096
34834
|
}
|
|
34097
34835
|
};
|
|
34098
|
-
BytesSizeMismatchError2 = class extends
|
|
34836
|
+
BytesSizeMismatchError2 = class extends BaseError4 {
|
|
34099
34837
|
constructor({ expectedSize, givenSize }) {
|
|
34100
34838
|
super(`Expected bytes${expectedSize}, got bytes${givenSize}.`, {
|
|
34101
34839
|
name: "BytesSizeMismatchError"
|
|
34102
34840
|
});
|
|
34103
34841
|
}
|
|
34104
34842
|
};
|
|
34105
|
-
DecodeLogDataMismatch = class extends
|
|
34843
|
+
DecodeLogDataMismatch = class extends BaseError4 {
|
|
34106
34844
|
constructor({ abiItem, data, params, size: size6 }) {
|
|
34107
34845
|
super([
|
|
34108
34846
|
`Data size of ${size6} bytes is too small for non-indexed event parameters.`
|
|
@@ -34143,7 +34881,7 @@ var init_abi2 = __esm({
|
|
|
34143
34881
|
this.size = size6;
|
|
34144
34882
|
}
|
|
34145
34883
|
};
|
|
34146
|
-
DecodeLogTopicsMismatch = class extends
|
|
34884
|
+
DecodeLogTopicsMismatch = class extends BaseError4 {
|
|
34147
34885
|
constructor({ abiItem, param }) {
|
|
34148
34886
|
super([
|
|
34149
34887
|
`Expected a topic for indexed event parameter${param.name ? ` "${param.name}"` : ""} on event "${formatAbiItem4(abiItem, { includeName: true })}".`
|
|
@@ -34157,7 +34895,7 @@ var init_abi2 = __esm({
|
|
|
34157
34895
|
this.abiItem = abiItem;
|
|
34158
34896
|
}
|
|
34159
34897
|
};
|
|
34160
|
-
InvalidAbiEncodingTypeError2 = class extends
|
|
34898
|
+
InvalidAbiEncodingTypeError2 = class extends BaseError4 {
|
|
34161
34899
|
constructor(type, { docsPath: docsPath9 }) {
|
|
34162
34900
|
super([
|
|
34163
34901
|
`Type "${type}" is not a valid encoding type.`,
|
|
@@ -34165,7 +34903,7 @@ var init_abi2 = __esm({
|
|
|
34165
34903
|
].join("\n"), { docsPath: docsPath9, name: "InvalidAbiEncodingType" });
|
|
34166
34904
|
}
|
|
34167
34905
|
};
|
|
34168
|
-
InvalidAbiDecodingTypeError = class extends
|
|
34906
|
+
InvalidAbiDecodingTypeError = class extends BaseError4 {
|
|
34169
34907
|
constructor(type, { docsPath: docsPath9 }) {
|
|
34170
34908
|
super([
|
|
34171
34909
|
`Type "${type}" is not a valid decoding type.`,
|
|
@@ -34173,14 +34911,14 @@ var init_abi2 = __esm({
|
|
|
34173
34911
|
].join("\n"), { docsPath: docsPath9, name: "InvalidAbiDecodingType" });
|
|
34174
34912
|
}
|
|
34175
34913
|
};
|
|
34176
|
-
InvalidArrayError2 = class extends
|
|
34914
|
+
InvalidArrayError2 = class extends BaseError4 {
|
|
34177
34915
|
constructor(value) {
|
|
34178
34916
|
super([`Value "${value}" is not a valid array.`].join("\n"), {
|
|
34179
34917
|
name: "InvalidArrayError"
|
|
34180
34918
|
});
|
|
34181
34919
|
}
|
|
34182
34920
|
};
|
|
34183
|
-
InvalidDefinitionTypeError2 = class extends
|
|
34921
|
+
InvalidDefinitionTypeError2 = class extends BaseError4 {
|
|
34184
34922
|
constructor(type) {
|
|
34185
34923
|
super([
|
|
34186
34924
|
`"${type}" is not a valid definition type.`,
|
|
@@ -34196,17 +34934,17 @@ var SliceOffsetOutOfBoundsError2, SizeExceedsPaddingSizeError2, InvalidBytesLeng
|
|
|
34196
34934
|
var init_data2 = __esm({
|
|
34197
34935
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/data.js"() {
|
|
34198
34936
|
init_base2();
|
|
34199
|
-
SliceOffsetOutOfBoundsError2 = class extends
|
|
34937
|
+
SliceOffsetOutOfBoundsError2 = class extends BaseError4 {
|
|
34200
34938
|
constructor({ offset, position, size: size6 }) {
|
|
34201
34939
|
super(`Slice ${position === "start" ? "starting" : "ending"} at offset "${offset}" is out-of-bounds (size: ${size6}).`, { name: "SliceOffsetOutOfBoundsError" });
|
|
34202
34940
|
}
|
|
34203
34941
|
};
|
|
34204
|
-
SizeExceedsPaddingSizeError2 = class extends
|
|
34942
|
+
SizeExceedsPaddingSizeError2 = class extends BaseError4 {
|
|
34205
34943
|
constructor({ size: size6, targetSize, type }) {
|
|
34206
34944
|
super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (${size6}) exceeds padding size (${targetSize}).`, { name: "SizeExceedsPaddingSizeError" });
|
|
34207
34945
|
}
|
|
34208
34946
|
};
|
|
34209
|
-
InvalidBytesLengthError = class extends
|
|
34947
|
+
InvalidBytesLengthError = class extends BaseError4 {
|
|
34210
34948
|
constructor({ size: size6, targetSize, type }) {
|
|
34211
34949
|
super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} is expected to be ${targetSize} ${type} long, but is ${size6} ${type} long.`, { name: "InvalidBytesLengthError" });
|
|
34212
34950
|
}
|
|
@@ -34259,24 +34997,24 @@ var IntegerOutOfRangeError2, InvalidBytesBooleanError, InvalidHexBooleanError2,
|
|
|
34259
34997
|
var init_encoding2 = __esm({
|
|
34260
34998
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/encoding.js"() {
|
|
34261
34999
|
init_base2();
|
|
34262
|
-
IntegerOutOfRangeError2 = class extends
|
|
35000
|
+
IntegerOutOfRangeError2 = class extends BaseError4 {
|
|
34263
35001
|
constructor({ max, min, signed, size: size6, value }) {
|
|
34264
35002
|
super(`Number "${value}" is not in safe ${size6 ? `${size6 * 8}-bit ${signed ? "signed" : "unsigned"} ` : ""}integer range ${max ? `(${min} to ${max})` : `(above ${min})`}`, { name: "IntegerOutOfRangeError" });
|
|
34265
35003
|
}
|
|
34266
35004
|
};
|
|
34267
|
-
InvalidBytesBooleanError = class extends
|
|
35005
|
+
InvalidBytesBooleanError = class extends BaseError4 {
|
|
34268
35006
|
constructor(bytes) {
|
|
34269
35007
|
super(`Bytes value "${bytes}" is not a valid boolean. The bytes array must contain a single byte of either a 0 or 1 value.`, {
|
|
34270
35008
|
name: "InvalidBytesBooleanError"
|
|
34271
35009
|
});
|
|
34272
35010
|
}
|
|
34273
35011
|
};
|
|
34274
|
-
InvalidHexBooleanError2 = class extends
|
|
35012
|
+
InvalidHexBooleanError2 = class extends BaseError4 {
|
|
34275
35013
|
constructor(hex) {
|
|
34276
35014
|
super(`Hex value "${hex}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`, { name: "InvalidHexBooleanError" });
|
|
34277
35015
|
}
|
|
34278
35016
|
};
|
|
34279
|
-
SizeOverflowError2 = class extends
|
|
35017
|
+
SizeOverflowError2 = class extends BaseError4 {
|
|
34280
35018
|
constructor({ givenSize, maxSize }) {
|
|
34281
35019
|
super(`Size cannot exceed ${maxSize} bytes. Given size: ${givenSize} bytes.`, { name: "SizeOverflowError" });
|
|
34282
35020
|
}
|
|
@@ -34478,7 +35216,7 @@ function hexToBytes4(hex_, opts = {}) {
|
|
|
34478
35216
|
const nibbleLeft = charCodeToBase162(hexString.charCodeAt(j++));
|
|
34479
35217
|
const nibbleRight = charCodeToBase162(hexString.charCodeAt(j++));
|
|
34480
35218
|
if (nibbleLeft === void 0 || nibbleRight === void 0) {
|
|
34481
|
-
throw new
|
|
35219
|
+
throw new BaseError4(`Invalid byte sequence ("${hexString[j - 2]}${hexString[j - 1]}" in "${hexString}").`);
|
|
34482
35220
|
}
|
|
34483
35221
|
bytes[index2] = nibbleLeft * 16 + nibbleRight;
|
|
34484
35222
|
}
|
|
@@ -34586,7 +35324,7 @@ function normalizeSignature2(signature) {
|
|
|
34586
35324
|
current += char;
|
|
34587
35325
|
}
|
|
34588
35326
|
if (!valid)
|
|
34589
|
-
throw new
|
|
35327
|
+
throw new BaseError4("Unable to normalize signature.");
|
|
34590
35328
|
return result;
|
|
34591
35329
|
}
|
|
34592
35330
|
var init_normalizeSignature2 = __esm({
|
|
@@ -34637,7 +35375,7 @@ var InvalidAddressError2;
|
|
|
34637
35375
|
var init_address3 = __esm({
|
|
34638
35376
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/address.js"() {
|
|
34639
35377
|
init_base2();
|
|
34640
|
-
InvalidAddressError2 = class extends
|
|
35378
|
+
InvalidAddressError2 = class extends BaseError4 {
|
|
34641
35379
|
constructor({ address }) {
|
|
34642
35380
|
super(`Address "${address}" is invalid.`, {
|
|
34643
35381
|
metaMessages: [
|
|
@@ -34830,11 +35568,11 @@ var init_slice2 = __esm({
|
|
|
34830
35568
|
});
|
|
34831
35569
|
|
|
34832
35570
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/regex.js
|
|
34833
|
-
var
|
|
35571
|
+
var bytesRegex4, integerRegex4;
|
|
34834
35572
|
var init_regex4 = __esm({
|
|
34835
35573
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/regex.js"() {
|
|
34836
|
-
|
|
34837
|
-
|
|
35574
|
+
bytesRegex4 = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;
|
|
35575
|
+
integerRegex4 = /^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;
|
|
34838
35576
|
}
|
|
34839
35577
|
});
|
|
34840
35578
|
|
|
@@ -34880,7 +35618,7 @@ function prepareParam2({ param, value }) {
|
|
|
34880
35618
|
}
|
|
34881
35619
|
if (param.type.startsWith("uint") || param.type.startsWith("int")) {
|
|
34882
35620
|
const signed = param.type.startsWith("int");
|
|
34883
|
-
const [, , size6 = "256"] =
|
|
35621
|
+
const [, , size6 = "256"] = integerRegex4.exec(param.type) ?? [];
|
|
34884
35622
|
return encodeNumber2(value, {
|
|
34885
35623
|
signed,
|
|
34886
35624
|
size: Number(size6)
|
|
@@ -34984,7 +35722,7 @@ function encodeBytes2(value, { param }) {
|
|
|
34984
35722
|
}
|
|
34985
35723
|
function encodeBool2(value) {
|
|
34986
35724
|
if (typeof value !== "boolean")
|
|
34987
|
-
throw new
|
|
35725
|
+
throw new BaseError4(`Invalid boolean value: "${value}" (type: ${typeof value}). Expected: \`true\` or \`false\`.`);
|
|
34988
35726
|
return { dynamic: false, encoded: padHex2(boolToHex2(value)) };
|
|
34989
35727
|
}
|
|
34990
35728
|
function encodeNumber2(value, { signed, size: size6 = 256 }) {
|
|
@@ -35305,19 +36043,19 @@ var NegativeOffsetError2, PositionOutOfBoundsError2, RecursiveReadLimitExceededE
|
|
|
35305
36043
|
var init_cursor3 = __esm({
|
|
35306
36044
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/cursor.js"() {
|
|
35307
36045
|
init_base2();
|
|
35308
|
-
NegativeOffsetError2 = class extends
|
|
36046
|
+
NegativeOffsetError2 = class extends BaseError4 {
|
|
35309
36047
|
constructor({ offset }) {
|
|
35310
36048
|
super(`Offset \`${offset}\` cannot be negative.`, {
|
|
35311
36049
|
name: "NegativeOffsetError"
|
|
35312
36050
|
});
|
|
35313
36051
|
}
|
|
35314
36052
|
};
|
|
35315
|
-
PositionOutOfBoundsError2 = class extends
|
|
36053
|
+
PositionOutOfBoundsError2 = class extends BaseError4 {
|
|
35316
36054
|
constructor({ length, position }) {
|
|
35317
36055
|
super(`Position \`${position}\` is out of bounds (\`0 < position < ${length}\`).`, { name: "PositionOutOfBoundsError" });
|
|
35318
36056
|
}
|
|
35319
36057
|
};
|
|
35320
|
-
RecursiveReadLimitExceededError2 = class extends
|
|
36058
|
+
RecursiveReadLimitExceededError2 = class extends BaseError4 {
|
|
35321
36059
|
constructor({ count, limit }) {
|
|
35322
36060
|
super(`Recursive read limit of \`${limit}\` exceeded (recursive read count: \`${count}\`).`, { name: "RecursiveReadLimitExceededError" });
|
|
35323
36061
|
}
|
|
@@ -35890,14 +36628,14 @@ var AccountStateConflictError, StateAssignmentConflictError;
|
|
|
35890
36628
|
var init_stateOverride = __esm({
|
|
35891
36629
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/stateOverride.js"() {
|
|
35892
36630
|
init_base2();
|
|
35893
|
-
AccountStateConflictError = class extends
|
|
36631
|
+
AccountStateConflictError = class extends BaseError4 {
|
|
35894
36632
|
constructor({ address }) {
|
|
35895
36633
|
super(`State for account "${address}" is set multiple times.`, {
|
|
35896
36634
|
name: "AccountStateConflictError"
|
|
35897
36635
|
});
|
|
35898
36636
|
}
|
|
35899
36637
|
};
|
|
35900
|
-
StateAssignmentConflictError = class extends
|
|
36638
|
+
StateAssignmentConflictError = class extends BaseError4 {
|
|
35901
36639
|
constructor() {
|
|
35902
36640
|
super("state and stateDiff are set on the same account.", {
|
|
35903
36641
|
name: "StateAssignmentConflictError"
|
|
@@ -35923,14 +36661,14 @@ var init_transaction2 = __esm({
|
|
|
35923
36661
|
init_formatEther();
|
|
35924
36662
|
init_formatGwei2();
|
|
35925
36663
|
init_base2();
|
|
35926
|
-
InvalidLegacyVError2 = class extends
|
|
36664
|
+
InvalidLegacyVError2 = class extends BaseError4 {
|
|
35927
36665
|
constructor({ v }) {
|
|
35928
36666
|
super(`Invalid \`v\` value "${v}". Expected 27 or 28.`, {
|
|
35929
36667
|
name: "InvalidLegacyVError"
|
|
35930
36668
|
});
|
|
35931
36669
|
}
|
|
35932
36670
|
};
|
|
35933
|
-
InvalidSerializableTransactionError2 = class extends
|
|
36671
|
+
InvalidSerializableTransactionError2 = class extends BaseError4 {
|
|
35934
36672
|
constructor({ transaction }) {
|
|
35935
36673
|
super("Cannot infer a transaction type from provided transaction.", {
|
|
35936
36674
|
metaMessages: [
|
|
@@ -35951,12 +36689,12 @@ var init_transaction2 = __esm({
|
|
|
35951
36689
|
});
|
|
35952
36690
|
}
|
|
35953
36691
|
};
|
|
35954
|
-
InvalidStorageKeySizeError2 = class extends
|
|
36692
|
+
InvalidStorageKeySizeError2 = class extends BaseError4 {
|
|
35955
36693
|
constructor({ storageKey }) {
|
|
35956
36694
|
super(`Size for storage key "${storageKey}" is invalid. Expected 32 bytes. Got ${Math.floor((storageKey.length - 2) / 2)} bytes.`, { name: "InvalidStorageKeySizeError" });
|
|
35957
36695
|
}
|
|
35958
36696
|
};
|
|
35959
|
-
TransactionExecutionError = class extends
|
|
36697
|
+
TransactionExecutionError = class extends BaseError4 {
|
|
35960
36698
|
constructor(cause, { account, docsPath: docsPath9, chain: chain2, data, gas, gasPrice, maxFeePerGas, maxPriorityFeePerGas, nonce, to, value }) {
|
|
35961
36699
|
const prettyArgs = prettyPrint2({
|
|
35962
36700
|
chain: chain2 && `${chain2?.name} (id: ${chain2?.id})`,
|
|
@@ -35989,7 +36727,7 @@ var init_transaction2 = __esm({
|
|
|
35989
36727
|
this.cause = cause;
|
|
35990
36728
|
}
|
|
35991
36729
|
};
|
|
35992
|
-
TransactionNotFoundError = class extends
|
|
36730
|
+
TransactionNotFoundError = class extends BaseError4 {
|
|
35993
36731
|
constructor({ blockHash, blockNumber, blockTag, hash: hash4, index: index2 }) {
|
|
35994
36732
|
let identifier = "Transaction";
|
|
35995
36733
|
if (blockTag && index2 !== void 0)
|
|
@@ -36005,14 +36743,14 @@ var init_transaction2 = __esm({
|
|
|
36005
36743
|
});
|
|
36006
36744
|
}
|
|
36007
36745
|
};
|
|
36008
|
-
TransactionReceiptNotFoundError = class extends
|
|
36746
|
+
TransactionReceiptNotFoundError = class extends BaseError4 {
|
|
36009
36747
|
constructor({ hash: hash4 }) {
|
|
36010
36748
|
super(`Transaction receipt with hash "${hash4}" could not be found. The Transaction may not be processed on a block yet.`, {
|
|
36011
36749
|
name: "TransactionReceiptNotFoundError"
|
|
36012
36750
|
});
|
|
36013
36751
|
}
|
|
36014
36752
|
};
|
|
36015
|
-
TransactionReceiptRevertedError = class extends
|
|
36753
|
+
TransactionReceiptRevertedError = class extends BaseError4 {
|
|
36016
36754
|
constructor({ receipt }) {
|
|
36017
36755
|
super(`Transaction with hash "${receipt.transactionHash}" reverted.`, {
|
|
36018
36756
|
metaMessages: [
|
|
@@ -36033,7 +36771,7 @@ var init_transaction2 = __esm({
|
|
|
36033
36771
|
this.receipt = receipt;
|
|
36034
36772
|
}
|
|
36035
36773
|
};
|
|
36036
|
-
WaitForTransactionReceiptTimeoutError = class extends
|
|
36774
|
+
WaitForTransactionReceiptTimeoutError = class extends BaseError4 {
|
|
36037
36775
|
constructor({ hash: hash4 }) {
|
|
36038
36776
|
super(`Timed out while waiting for transaction with hash "${hash4}" to be confirmed.`, { name: "WaitForTransactionReceiptTimeoutError" });
|
|
36039
36777
|
}
|
|
@@ -36055,7 +36793,7 @@ function isAbortError(error) {
|
|
|
36055
36793
|
return typeof error === "object" && error !== null && "name" in error && error.name === "AbortError";
|
|
36056
36794
|
}
|
|
36057
36795
|
var getContractAddress, getUrl;
|
|
36058
|
-
var
|
|
36796
|
+
var init_utils5 = __esm({
|
|
36059
36797
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/utils.js"() {
|
|
36060
36798
|
getContractAddress = (address) => address;
|
|
36061
36799
|
getUrl = (url) => {
|
|
@@ -36089,8 +36827,8 @@ var init_contract = __esm({
|
|
|
36089
36827
|
init_base2();
|
|
36090
36828
|
init_stateOverride();
|
|
36091
36829
|
init_transaction2();
|
|
36092
|
-
|
|
36093
|
-
CallExecutionError = class extends
|
|
36830
|
+
init_utils5();
|
|
36831
|
+
CallExecutionError = class extends BaseError4 {
|
|
36094
36832
|
constructor(cause, { account: account_, docsPath: docsPath9, chain: chain2, data, gas, gasPrice, maxFeePerGas, maxPriorityFeePerGas, nonce, to, value, stateOverride }) {
|
|
36095
36833
|
const account = account_ ? parseAccount(account_) : void 0;
|
|
36096
36834
|
let prettyArgs = prettyPrint2({
|
|
@@ -36127,7 +36865,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36127
36865
|
this.cause = cause;
|
|
36128
36866
|
}
|
|
36129
36867
|
};
|
|
36130
|
-
ContractFunctionExecutionError = class extends
|
|
36868
|
+
ContractFunctionExecutionError = class extends BaseError4 {
|
|
36131
36869
|
constructor(cause, { abi: abi2, args, contractAddress, docsPath: docsPath9, functionName, sender }) {
|
|
36132
36870
|
const abiItem = getAbiItem2({ abi: abi2, args, name: functionName });
|
|
36133
36871
|
const formattedArgs = abiItem ? formatAbiItemWithArgs({
|
|
@@ -36203,7 +36941,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36203
36941
|
this.sender = sender;
|
|
36204
36942
|
}
|
|
36205
36943
|
};
|
|
36206
|
-
ContractFunctionRevertedError = class extends
|
|
36944
|
+
ContractFunctionRevertedError = class extends BaseError4 {
|
|
36207
36945
|
constructor({ abi: abi2, data, functionName, message, cause: error }) {
|
|
36208
36946
|
let cause;
|
|
36209
36947
|
let decodedData;
|
|
@@ -36283,7 +37021,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36283
37021
|
this.signature = signature;
|
|
36284
37022
|
}
|
|
36285
37023
|
};
|
|
36286
|
-
ContractFunctionZeroDataError = class extends
|
|
37024
|
+
ContractFunctionZeroDataError = class extends BaseError4 {
|
|
36287
37025
|
constructor({ functionName, cause }) {
|
|
36288
37026
|
super(`The contract function "${functionName}" returned no data ("0x").`, {
|
|
36289
37027
|
metaMessages: [
|
|
@@ -36297,7 +37035,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36297
37035
|
});
|
|
36298
37036
|
}
|
|
36299
37037
|
};
|
|
36300
|
-
CounterfactualDeploymentFailedError = class extends
|
|
37038
|
+
CounterfactualDeploymentFailedError = class extends BaseError4 {
|
|
36301
37039
|
constructor({ factory }) {
|
|
36302
37040
|
super(`Deployment for counterfactual contract call failed${factory ? ` for factory "${factory}".` : ""}`, {
|
|
36303
37041
|
metaMessages: [
|
|
@@ -36309,7 +37047,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
36309
37047
|
});
|
|
36310
37048
|
}
|
|
36311
37049
|
};
|
|
36312
|
-
RawContractError = class extends
|
|
37050
|
+
RawContractError = class extends BaseError4 {
|
|
36313
37051
|
constructor({ data, message }) {
|
|
36314
37052
|
super(message || "", { name: "RawContractError" });
|
|
36315
37053
|
Object.defineProperty(this, "code", {
|
|
@@ -36336,8 +37074,8 @@ var init_request = __esm({
|
|
|
36336
37074
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/request.js"() {
|
|
36337
37075
|
init_stringify2();
|
|
36338
37076
|
init_base2();
|
|
36339
|
-
|
|
36340
|
-
HttpRequestError = class extends
|
|
37077
|
+
init_utils5();
|
|
37078
|
+
HttpRequestError = class extends BaseError4 {
|
|
36341
37079
|
constructor({ body, cause, details, headers, status, url }) {
|
|
36342
37080
|
super("HTTP request failed.", {
|
|
36343
37081
|
cause,
|
|
@@ -36379,7 +37117,7 @@ var init_request = __esm({
|
|
|
36379
37117
|
this.url = url;
|
|
36380
37118
|
}
|
|
36381
37119
|
};
|
|
36382
|
-
RpcRequestError = class extends
|
|
37120
|
+
RpcRequestError = class extends BaseError4 {
|
|
36383
37121
|
constructor({ body, error, url }) {
|
|
36384
37122
|
super("RPC Request failed.", {
|
|
36385
37123
|
cause: error,
|
|
@@ -36410,7 +37148,7 @@ var init_request = __esm({
|
|
|
36410
37148
|
this.url = url;
|
|
36411
37149
|
}
|
|
36412
37150
|
};
|
|
36413
|
-
TimeoutError = class extends
|
|
37151
|
+
TimeoutError = class extends BaseError4 {
|
|
36414
37152
|
constructor({ body, url }) {
|
|
36415
37153
|
super("The request took too long to respond.", {
|
|
36416
37154
|
details: "The request timed out.",
|
|
@@ -36436,7 +37174,7 @@ var init_rpc = __esm({
|
|
|
36436
37174
|
init_base2();
|
|
36437
37175
|
init_request();
|
|
36438
37176
|
unknownErrorCode = -1;
|
|
36439
|
-
RpcError = class extends
|
|
37177
|
+
RpcError = class extends BaseError4 {
|
|
36440
37178
|
constructor(cause, { code, docsPath: docsPath9, metaMessages, name, shortMessage }) {
|
|
36441
37179
|
super(shortMessage, {
|
|
36442
37180
|
cause,
|
|
@@ -36885,7 +37623,7 @@ var init_node2 = __esm({
|
|
|
36885
37623
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/node.js"() {
|
|
36886
37624
|
init_formatGwei2();
|
|
36887
37625
|
init_base2();
|
|
36888
|
-
ExecutionRevertedError2 = class extends
|
|
37626
|
+
ExecutionRevertedError2 = class extends BaseError4 {
|
|
36889
37627
|
constructor({ cause, message } = {}) {
|
|
36890
37628
|
const reason = message?.replace("execution reverted: ", "")?.replace("execution reverted", "");
|
|
36891
37629
|
super(`Execution reverted ${reason ? `with reason: ${reason}` : "for an unknown reason"}.`, {
|
|
@@ -36906,7 +37644,7 @@ var init_node2 = __esm({
|
|
|
36906
37644
|
writable: true,
|
|
36907
37645
|
value: /execution reverted|gas required exceeds allowance/
|
|
36908
37646
|
});
|
|
36909
|
-
FeeCapTooHighError2 = class extends
|
|
37647
|
+
FeeCapTooHighError2 = class extends BaseError4 {
|
|
36910
37648
|
constructor({ cause, maxFeePerGas } = {}) {
|
|
36911
37649
|
super(`The fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei2(maxFeePerGas)} gwei` : ""}) cannot be higher than the maximum allowed value (2^256-1).`, {
|
|
36912
37650
|
cause,
|
|
@@ -36920,7 +37658,7 @@ var init_node2 = __esm({
|
|
|
36920
37658
|
writable: true,
|
|
36921
37659
|
value: /max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/
|
|
36922
37660
|
});
|
|
36923
|
-
FeeCapTooLowError2 = class extends
|
|
37661
|
+
FeeCapTooLowError2 = class extends BaseError4 {
|
|
36924
37662
|
constructor({ cause, maxFeePerGas } = {}) {
|
|
36925
37663
|
super(`The fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei2(maxFeePerGas)}` : ""} gwei) cannot be lower than the block base fee.`, {
|
|
36926
37664
|
cause,
|
|
@@ -36934,7 +37672,7 @@ var init_node2 = __esm({
|
|
|
36934
37672
|
writable: true,
|
|
36935
37673
|
value: /max fee per gas less than block base fee|fee cap less than block base fee|transaction is outdated/
|
|
36936
37674
|
});
|
|
36937
|
-
NonceTooHighError2 = class extends
|
|
37675
|
+
NonceTooHighError2 = class extends BaseError4 {
|
|
36938
37676
|
constructor({ cause, nonce } = {}) {
|
|
36939
37677
|
super(`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}is higher than the next one expected.`, { cause, name: "NonceTooHighError" });
|
|
36940
37678
|
}
|
|
@@ -36945,7 +37683,7 @@ var init_node2 = __esm({
|
|
|
36945
37683
|
writable: true,
|
|
36946
37684
|
value: /nonce too high/
|
|
36947
37685
|
});
|
|
36948
|
-
NonceTooLowError2 = class extends
|
|
37686
|
+
NonceTooLowError2 = class extends BaseError4 {
|
|
36949
37687
|
constructor({ cause, nonce } = {}) {
|
|
36950
37688
|
super([
|
|
36951
37689
|
`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}is lower than the current nonce of the account.`,
|
|
@@ -36959,7 +37697,7 @@ var init_node2 = __esm({
|
|
|
36959
37697
|
writable: true,
|
|
36960
37698
|
value: /nonce too low|transaction already imported|already known/
|
|
36961
37699
|
});
|
|
36962
|
-
NonceMaxValueError2 = class extends
|
|
37700
|
+
NonceMaxValueError2 = class extends BaseError4 {
|
|
36963
37701
|
constructor({ cause, nonce } = {}) {
|
|
36964
37702
|
super(`Nonce provided for the transaction ${nonce ? `(${nonce}) ` : ""}exceeds the maximum allowed nonce.`, { cause, name: "NonceMaxValueError" });
|
|
36965
37703
|
}
|
|
@@ -36970,7 +37708,7 @@ var init_node2 = __esm({
|
|
|
36970
37708
|
writable: true,
|
|
36971
37709
|
value: /nonce has max value/
|
|
36972
37710
|
});
|
|
36973
|
-
InsufficientFundsError2 = class extends
|
|
37711
|
+
InsufficientFundsError2 = class extends BaseError4 {
|
|
36974
37712
|
constructor({ cause } = {}) {
|
|
36975
37713
|
super([
|
|
36976
37714
|
"The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account."
|
|
@@ -36996,7 +37734,7 @@ var init_node2 = __esm({
|
|
|
36996
37734
|
writable: true,
|
|
36997
37735
|
value: /insufficient funds|exceeds transaction sender account balance/
|
|
36998
37736
|
});
|
|
36999
|
-
IntrinsicGasTooHighError2 = class extends
|
|
37737
|
+
IntrinsicGasTooHighError2 = class extends BaseError4 {
|
|
37000
37738
|
constructor({ cause, gas } = {}) {
|
|
37001
37739
|
super(`The amount of gas ${gas ? `(${gas}) ` : ""}provided for the transaction exceeds the limit allowed for the block.`, {
|
|
37002
37740
|
cause,
|
|
@@ -37010,7 +37748,7 @@ var init_node2 = __esm({
|
|
|
37010
37748
|
writable: true,
|
|
37011
37749
|
value: /intrinsic gas too high|gas limit reached/
|
|
37012
37750
|
});
|
|
37013
|
-
IntrinsicGasTooLowError2 = class extends
|
|
37751
|
+
IntrinsicGasTooLowError2 = class extends BaseError4 {
|
|
37014
37752
|
constructor({ cause, gas } = {}) {
|
|
37015
37753
|
super(`The amount of gas ${gas ? `(${gas}) ` : ""}provided for the transaction is too low.`, {
|
|
37016
37754
|
cause,
|
|
@@ -37024,7 +37762,7 @@ var init_node2 = __esm({
|
|
|
37024
37762
|
writable: true,
|
|
37025
37763
|
value: /intrinsic gas too low/
|
|
37026
37764
|
});
|
|
37027
|
-
TransactionTypeNotSupportedError2 = class extends
|
|
37765
|
+
TransactionTypeNotSupportedError2 = class extends BaseError4 {
|
|
37028
37766
|
constructor({ cause }) {
|
|
37029
37767
|
super("The transaction type is not supported for this chain.", {
|
|
37030
37768
|
cause,
|
|
@@ -37038,7 +37776,7 @@ var init_node2 = __esm({
|
|
|
37038
37776
|
writable: true,
|
|
37039
37777
|
value: /transaction type not valid/
|
|
37040
37778
|
});
|
|
37041
|
-
TipAboveFeeCapError2 = class extends
|
|
37779
|
+
TipAboveFeeCapError2 = class extends BaseError4 {
|
|
37042
37780
|
constructor({ cause, maxPriorityFeePerGas, maxFeePerGas } = {}) {
|
|
37043
37781
|
super([
|
|
37044
37782
|
`The provided tip (\`maxPriorityFeePerGas\`${maxPriorityFeePerGas ? ` = ${formatGwei2(maxPriorityFeePerGas)} gwei` : ""}) cannot be higher than the fee cap (\`maxFeePerGas\`${maxFeePerGas ? ` = ${formatGwei2(maxFeePerGas)} gwei` : ""}).`
|
|
@@ -37054,7 +37792,7 @@ var init_node2 = __esm({
|
|
|
37054
37792
|
writable: true,
|
|
37055
37793
|
value: /max priority fee per gas higher than max fee per gas|tip higher than fee cap/
|
|
37056
37794
|
});
|
|
37057
|
-
UnknownNodeError = class extends
|
|
37795
|
+
UnknownNodeError = class extends BaseError4 {
|
|
37058
37796
|
constructor({ cause }) {
|
|
37059
37797
|
super(`An error occurred while executing: ${cause?.shortMessage}`, {
|
|
37060
37798
|
cause,
|
|
@@ -37068,8 +37806,8 @@ var init_node2 = __esm({
|
|
|
37068
37806
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/errors/getNodeError.js
|
|
37069
37807
|
function getNodeError(err, args) {
|
|
37070
37808
|
const message = (err.details || "").toLowerCase();
|
|
37071
|
-
const executionRevertedError = err instanceof
|
|
37072
|
-
if (executionRevertedError instanceof
|
|
37809
|
+
const executionRevertedError = err instanceof BaseError4 ? err.walk((e) => e?.code === ExecutionRevertedError2.code) : err;
|
|
37810
|
+
if (executionRevertedError instanceof BaseError4)
|
|
37073
37811
|
return new ExecutionRevertedError2({
|
|
37074
37812
|
cause: err,
|
|
37075
37813
|
message: executionRevertedError.details
|
|
@@ -37401,7 +38139,7 @@ var init_assertRequest = __esm({
|
|
|
37401
38139
|
function formatBlockParameter(parameters) {
|
|
37402
38140
|
const { blockHash, blockNumber, blockTag, requireCanonical } = parameters;
|
|
37403
38141
|
if (requireCanonical !== void 0 && !blockHash)
|
|
37404
|
-
throw new
|
|
38142
|
+
throw new BaseError4("`requireCanonical` can only be provided when `blockHash` is set.");
|
|
37405
38143
|
if (blockHash)
|
|
37406
38144
|
return requireCanonical ? { blockHash, requireCanonical } : { blockHash };
|
|
37407
38145
|
if (typeof blockNumber === "bigint")
|
|
@@ -37462,20 +38200,20 @@ var init_decodeFunctionResult = __esm({
|
|
|
37462
38200
|
});
|
|
37463
38201
|
|
|
37464
38202
|
// ../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/version.js
|
|
37465
|
-
var
|
|
37466
|
-
var
|
|
38203
|
+
var version5;
|
|
38204
|
+
var init_version5 = __esm({
|
|
37467
38205
|
"../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/version.js"() {
|
|
37468
|
-
|
|
38206
|
+
version5 = "0.1.1";
|
|
37469
38207
|
}
|
|
37470
38208
|
});
|
|
37471
38209
|
|
|
37472
38210
|
// ../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/internal/errors.js
|
|
37473
38211
|
function getVersion() {
|
|
37474
|
-
return
|
|
38212
|
+
return version5;
|
|
37475
38213
|
}
|
|
37476
|
-
var
|
|
38214
|
+
var init_errors3 = __esm({
|
|
37477
38215
|
"../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/internal/errors.js"() {
|
|
37478
|
-
|
|
38216
|
+
init_version5();
|
|
37479
38217
|
}
|
|
37480
38218
|
});
|
|
37481
38219
|
|
|
@@ -37487,11 +38225,11 @@ function walk3(err, fn) {
|
|
|
37487
38225
|
return walk3(err.cause, fn);
|
|
37488
38226
|
return fn ? null : err;
|
|
37489
38227
|
}
|
|
37490
|
-
var
|
|
38228
|
+
var BaseError5;
|
|
37491
38229
|
var init_Errors = __esm({
|
|
37492
38230
|
"../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/Errors.js"() {
|
|
37493
|
-
|
|
37494
|
-
|
|
38231
|
+
init_errors3();
|
|
38232
|
+
BaseError5 = class _BaseError extends Error {
|
|
37495
38233
|
static setStaticOptions(options) {
|
|
37496
38234
|
_BaseError.prototype.docsOrigin = options.docsOrigin;
|
|
37497
38235
|
_BaseError.prototype.showVersion = options.showVersion;
|
|
@@ -37519,7 +38257,7 @@ var init_Errors = __esm({
|
|
|
37519
38257
|
const docsBaseUrl = options.docsOrigin ?? _BaseError.prototype.docsOrigin;
|
|
37520
38258
|
const docs = `${docsBaseUrl}${docsPath9 ?? ""}`;
|
|
37521
38259
|
const showVersion = Boolean(options.version ?? _BaseError.prototype.showVersion);
|
|
37522
|
-
const
|
|
38260
|
+
const version6 = options.version ?? _BaseError.prototype.version;
|
|
37523
38261
|
const message = [
|
|
37524
38262
|
shortMessage || "An error occurred.",
|
|
37525
38263
|
...options.metaMessages ? ["", ...options.metaMessages] : [],
|
|
@@ -37527,7 +38265,7 @@ var init_Errors = __esm({
|
|
|
37527
38265
|
"",
|
|
37528
38266
|
details ? `Details: ${details}` : void 0,
|
|
37529
38267
|
docsPath9 ? `See: ${docs}` : void 0,
|
|
37530
|
-
showVersion ? `Version: ${
|
|
38268
|
+
showVersion ? `Version: ${version6}` : void 0
|
|
37531
38269
|
] : []
|
|
37532
38270
|
].filter((x) => typeof x === "string").join("\n");
|
|
37533
38271
|
super(message, options.cause ? { cause: options.cause } : void 0);
|
|
@@ -37592,13 +38330,13 @@ var init_Errors = __esm({
|
|
|
37592
38330
|
this.docsPath = docsPath9;
|
|
37593
38331
|
this.shortMessage = shortMessage;
|
|
37594
38332
|
this.showVersion = showVersion;
|
|
37595
|
-
this.version =
|
|
38333
|
+
this.version = version6;
|
|
37596
38334
|
}
|
|
37597
38335
|
walk(fn) {
|
|
37598
38336
|
return walk3(this, fn);
|
|
37599
38337
|
}
|
|
37600
38338
|
};
|
|
37601
|
-
Object.defineProperty(
|
|
38339
|
+
Object.defineProperty(BaseError5, "defaultStaticOptions", {
|
|
37602
38340
|
enumerable: true,
|
|
37603
38341
|
configurable: true,
|
|
37604
38342
|
writable: true,
|
|
@@ -37609,7 +38347,7 @@ var init_Errors = __esm({
|
|
|
37609
38347
|
}
|
|
37610
38348
|
});
|
|
37611
38349
|
(() => {
|
|
37612
|
-
|
|
38350
|
+
BaseError5.setStaticOptions(BaseError5.defaultStaticOptions);
|
|
37613
38351
|
})();
|
|
37614
38352
|
}
|
|
37615
38353
|
});
|
|
@@ -37810,7 +38548,7 @@ function fromHex(value, options = {}) {
|
|
|
37810
38548
|
const nibbleLeft = charCodeToBase163(hexString.charCodeAt(j++));
|
|
37811
38549
|
const nibbleRight = charCodeToBase163(hexString.charCodeAt(j++));
|
|
37812
38550
|
if (nibbleLeft === void 0 || nibbleRight === void 0) {
|
|
37813
|
-
throw new
|
|
38551
|
+
throw new BaseError5(`Invalid byte sequence ("${hexString[j - 2]}${hexString[j - 1]}" in "${hexString}").`);
|
|
37814
38552
|
}
|
|
37815
38553
|
bytes[index2] = nibbleLeft << 4 | nibbleRight;
|
|
37816
38554
|
}
|
|
@@ -37897,7 +38635,7 @@ var init_Bytes = __esm({
|
|
|
37897
38635
|
init_Json();
|
|
37898
38636
|
decoder = /* @__PURE__ */ new TextDecoder();
|
|
37899
38637
|
encoder5 = /* @__PURE__ */ new TextEncoder();
|
|
37900
|
-
InvalidBytesBooleanError2 = class extends
|
|
38638
|
+
InvalidBytesBooleanError2 = class extends BaseError5 {
|
|
37901
38639
|
constructor(bytes) {
|
|
37902
38640
|
super(`Bytes value \`${bytes}\` is not a valid boolean.`, {
|
|
37903
38641
|
metaMessages: [
|
|
@@ -37912,7 +38650,7 @@ var init_Bytes = __esm({
|
|
|
37912
38650
|
});
|
|
37913
38651
|
}
|
|
37914
38652
|
};
|
|
37915
|
-
InvalidBytesTypeError = class extends
|
|
38653
|
+
InvalidBytesTypeError = class extends BaseError5 {
|
|
37916
38654
|
constructor(value) {
|
|
37917
38655
|
super(`Value \`${typeof value === "object" ? stringify3(value) : value}\` of type \`${typeof value}\` is an invalid Bytes value.`, {
|
|
37918
38656
|
metaMessages: ["Bytes values must be of type `Bytes`."]
|
|
@@ -37925,7 +38663,7 @@ var init_Bytes = __esm({
|
|
|
37925
38663
|
});
|
|
37926
38664
|
}
|
|
37927
38665
|
};
|
|
37928
|
-
SizeOverflowError3 = class extends
|
|
38666
|
+
SizeOverflowError3 = class extends BaseError5 {
|
|
37929
38667
|
constructor({ givenSize, maxSize }) {
|
|
37930
38668
|
super(`Size cannot exceed \`${maxSize}\` bytes. Given size: \`${givenSize}\` bytes.`);
|
|
37931
38669
|
Object.defineProperty(this, "name", {
|
|
@@ -37936,7 +38674,7 @@ var init_Bytes = __esm({
|
|
|
37936
38674
|
});
|
|
37937
38675
|
}
|
|
37938
38676
|
};
|
|
37939
|
-
SliceOffsetOutOfBoundsError3 = class extends
|
|
38677
|
+
SliceOffsetOutOfBoundsError3 = class extends BaseError5 {
|
|
37940
38678
|
constructor({ offset, position, size: size6 }) {
|
|
37941
38679
|
super(`Slice ${position === "start" ? "starting" : "ending"} at offset \`${offset}\` is out-of-bounds (size: \`${size6}\`).`);
|
|
37942
38680
|
Object.defineProperty(this, "name", {
|
|
@@ -37947,7 +38685,7 @@ var init_Bytes = __esm({
|
|
|
37947
38685
|
});
|
|
37948
38686
|
}
|
|
37949
38687
|
};
|
|
37950
|
-
SizeExceedsPaddingSizeError3 = class extends
|
|
38688
|
+
SizeExceedsPaddingSizeError3 = class extends BaseError5 {
|
|
37951
38689
|
constructor({ size: size6, targetSize, type }) {
|
|
37952
38690
|
super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (\`${size6}\`) exceeds padding size (\`${targetSize}\`).`);
|
|
37953
38691
|
Object.defineProperty(this, "name", {
|
|
@@ -38093,7 +38831,7 @@ var init_Hex = __esm({
|
|
|
38093
38831
|
init_Json();
|
|
38094
38832
|
encoder6 = /* @__PURE__ */ new TextEncoder();
|
|
38095
38833
|
hexes5 = /* @__PURE__ */ Array.from({ length: 256 }, (_v, i) => i.toString(16).padStart(2, "0"));
|
|
38096
|
-
IntegerOutOfRangeError3 = class extends
|
|
38834
|
+
IntegerOutOfRangeError3 = class extends BaseError5 {
|
|
38097
38835
|
constructor({ max, min, signed, size: size6, value }) {
|
|
38098
38836
|
super(`Number \`${value}\` is not in safe${size6 ? ` ${size6 * 8}-bit` : ""}${signed ? " signed" : " unsigned"} integer range ${max ? `(\`${min}\` to \`${max}\`)` : `(above \`${min}\`)`}`);
|
|
38099
38837
|
Object.defineProperty(this, "name", {
|
|
@@ -38104,7 +38842,7 @@ var init_Hex = __esm({
|
|
|
38104
38842
|
});
|
|
38105
38843
|
}
|
|
38106
38844
|
};
|
|
38107
|
-
InvalidHexTypeError = class extends
|
|
38845
|
+
InvalidHexTypeError = class extends BaseError5 {
|
|
38108
38846
|
constructor(value) {
|
|
38109
38847
|
super(`Value \`${typeof value === "object" ? stringify3(value) : value}\` of type \`${typeof value}\` is an invalid hex type.`, {
|
|
38110
38848
|
metaMessages: ['Hex types must be represented as `"0x${string}"`.']
|
|
@@ -38117,7 +38855,7 @@ var init_Hex = __esm({
|
|
|
38117
38855
|
});
|
|
38118
38856
|
}
|
|
38119
38857
|
};
|
|
38120
|
-
InvalidHexValueError = class extends
|
|
38858
|
+
InvalidHexValueError = class extends BaseError5 {
|
|
38121
38859
|
constructor(value) {
|
|
38122
38860
|
super(`Value \`${value}\` is an invalid hex value.`, {
|
|
38123
38861
|
metaMessages: [
|
|
@@ -38132,7 +38870,7 @@ var init_Hex = __esm({
|
|
|
38132
38870
|
});
|
|
38133
38871
|
}
|
|
38134
38872
|
};
|
|
38135
|
-
SizeOverflowError4 = class extends
|
|
38873
|
+
SizeOverflowError4 = class extends BaseError5 {
|
|
38136
38874
|
constructor({ givenSize, maxSize }) {
|
|
38137
38875
|
super(`Size cannot exceed \`${maxSize}\` bytes. Given size: \`${givenSize}\` bytes.`);
|
|
38138
38876
|
Object.defineProperty(this, "name", {
|
|
@@ -38143,7 +38881,7 @@ var init_Hex = __esm({
|
|
|
38143
38881
|
});
|
|
38144
38882
|
}
|
|
38145
38883
|
};
|
|
38146
|
-
SliceOffsetOutOfBoundsError4 = class extends
|
|
38884
|
+
SliceOffsetOutOfBoundsError4 = class extends BaseError5 {
|
|
38147
38885
|
constructor({ offset, position, size: size6 }) {
|
|
38148
38886
|
super(`Slice ${position === "start" ? "starting" : "ending"} at offset \`${offset}\` is out-of-bounds (size: \`${size6}\`).`);
|
|
38149
38887
|
Object.defineProperty(this, "name", {
|
|
@@ -38154,7 +38892,7 @@ var init_Hex = __esm({
|
|
|
38154
38892
|
});
|
|
38155
38893
|
}
|
|
38156
38894
|
};
|
|
38157
|
-
SizeExceedsPaddingSizeError4 = class extends
|
|
38895
|
+
SizeExceedsPaddingSizeError4 = class extends BaseError5 {
|
|
38158
38896
|
constructor({ size: size6, targetSize, type }) {
|
|
38159
38897
|
super(`${type.charAt(0).toUpperCase()}${type.slice(1).toLowerCase()} size (\`${size6}\`) exceeds padding size (\`${targetSize}\`).`);
|
|
38160
38898
|
Object.defineProperty(this, "name", {
|
|
@@ -38601,7 +39339,7 @@ var ChainDoesNotSupportContract, ClientChainNotConfiguredError, InvalidChainIdEr
|
|
|
38601
39339
|
var init_chain2 = __esm({
|
|
38602
39340
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/chain.js"() {
|
|
38603
39341
|
init_base2();
|
|
38604
|
-
ChainDoesNotSupportContract = class extends
|
|
39342
|
+
ChainDoesNotSupportContract = class extends BaseError4 {
|
|
38605
39343
|
constructor({ blockNumber, chain: chain2, contract }) {
|
|
38606
39344
|
super(`Chain "${chain2.name}" does not support contract "${contract.name}".`, {
|
|
38607
39345
|
metaMessages: [
|
|
@@ -38616,14 +39354,14 @@ var init_chain2 = __esm({
|
|
|
38616
39354
|
});
|
|
38617
39355
|
}
|
|
38618
39356
|
};
|
|
38619
|
-
ClientChainNotConfiguredError = class extends
|
|
39357
|
+
ClientChainNotConfiguredError = class extends BaseError4 {
|
|
38620
39358
|
constructor() {
|
|
38621
39359
|
super("No chain was provided to the Client.", {
|
|
38622
39360
|
name: "ClientChainNotConfiguredError"
|
|
38623
39361
|
});
|
|
38624
39362
|
}
|
|
38625
39363
|
};
|
|
38626
|
-
InvalidChainIdError2 = class extends
|
|
39364
|
+
InvalidChainIdError2 = class extends BaseError4 {
|
|
38627
39365
|
constructor({ chainId }) {
|
|
38628
39366
|
super(typeof chainId === "number" ? `Chain ID "${chainId}" is invalid.` : "Chain ID is invalid.", { name: "InvalidChainIdError" });
|
|
38629
39367
|
}
|
|
@@ -38775,8 +39513,8 @@ var init_ccip = __esm({
|
|
|
38775
39513
|
"../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/ccip.js"() {
|
|
38776
39514
|
init_stringify2();
|
|
38777
39515
|
init_base2();
|
|
38778
|
-
|
|
38779
|
-
OffchainLookupError = class extends
|
|
39516
|
+
init_utils5();
|
|
39517
|
+
OffchainLookupError = class extends BaseError4 {
|
|
38780
39518
|
constructor({ callbackSelector, cause, data, extraData, sender, urls }) {
|
|
38781
39519
|
super(cause.shortMessage || "An error occurred while fetching for an offchain result.", {
|
|
38782
39520
|
cause,
|
|
@@ -38797,7 +39535,7 @@ var init_ccip = __esm({
|
|
|
38797
39535
|
});
|
|
38798
39536
|
}
|
|
38799
39537
|
};
|
|
38800
|
-
OffchainLookupResponseMalformedError = class extends
|
|
39538
|
+
OffchainLookupResponseMalformedError = class extends BaseError4 {
|
|
38801
39539
|
constructor({ result, url }) {
|
|
38802
39540
|
super("Offchain gateway response is malformed. Response data must be a hex value.", {
|
|
38803
39541
|
metaMessages: [
|
|
@@ -38808,7 +39546,7 @@ var init_ccip = __esm({
|
|
|
38808
39546
|
});
|
|
38809
39547
|
}
|
|
38810
39548
|
};
|
|
38811
|
-
OffchainLookupSenderMismatchError = class extends
|
|
39549
|
+
OffchainLookupSenderMismatchError = class extends BaseError4 {
|
|
38812
39550
|
constructor({ sender, to }) {
|
|
38813
39551
|
super("Reverted sender address does not match target contract address (`to`).", {
|
|
38814
39552
|
metaMessages: [
|
|
@@ -39071,7 +39809,7 @@ var init_ccip2 = __esm({
|
|
|
39071
39809
|
init_call();
|
|
39072
39810
|
init_ccip();
|
|
39073
39811
|
init_request();
|
|
39074
|
-
|
|
39812
|
+
init_utils5();
|
|
39075
39813
|
init_decodeErrorResult();
|
|
39076
39814
|
init_encodeAbiParameters2();
|
|
39077
39815
|
init_isAddressEqual();
|
|
@@ -39114,9 +39852,9 @@ async function call(client, args) {
|
|
|
39114
39852
|
const { account: account_ = client.account, authorizationList, batch = Boolean(client.batch?.multicall), blockHash, blockNumber, blockTag = client.experimental_blockTag ?? "latest", requireCanonical, accessList, blobs, blockOverrides, code, data: data_, factory, factoryData, gas, gasPrice, maxFeePerBlobGas, maxFeePerGas, maxPriorityFeePerGas, nonce, requestOptions, to, value, stateOverride, ...rest } = args;
|
|
39115
39853
|
const account = account_ ? parseAccount(account_) : void 0;
|
|
39116
39854
|
if (code && (factory || factoryData))
|
|
39117
|
-
throw new
|
|
39855
|
+
throw new BaseError4("Cannot provide both `code` & `factory`/`factoryData` as parameters.");
|
|
39118
39856
|
if (code && to)
|
|
39119
|
-
throw new
|
|
39857
|
+
throw new BaseError4("Cannot provide both `code` & `to` as parameters.");
|
|
39120
39858
|
const deploylessCallViaBytecode = code && data_;
|
|
39121
39859
|
const deploylessCallViaFactory = factory && factoryData && to && data_;
|
|
39122
39860
|
const deploylessCall = deploylessCallViaBytecode || deploylessCallViaFactory;
|
|
@@ -39329,7 +40067,7 @@ function hasStateOverrideForAddress(rpcStateOverride, address) {
|
|
|
39329
40067
|
function toDeploylessCallViaBytecodeData(parameters) {
|
|
39330
40068
|
const { code, data } = parameters;
|
|
39331
40069
|
return encodeDeployData({
|
|
39332
|
-
abi:
|
|
40070
|
+
abi: parseAbi2(["constructor(bytes, bytes)"]),
|
|
39333
40071
|
bytecode: deploylessCallViaBytecodeBytecode,
|
|
39334
40072
|
args: [code, data]
|
|
39335
40073
|
});
|
|
@@ -39337,13 +40075,13 @@ function toDeploylessCallViaBytecodeData(parameters) {
|
|
|
39337
40075
|
function toDeploylessCallViaFactoryData(parameters) {
|
|
39338
40076
|
const { data, factory, factoryData, to } = parameters;
|
|
39339
40077
|
return encodeDeployData({
|
|
39340
|
-
abi:
|
|
40078
|
+
abi: parseAbi2(["constructor(address, bytes, address, bytes)"]),
|
|
39341
40079
|
bytecode: deploylessCallViaFactoryBytecode,
|
|
39342
40080
|
args: [to, data, factory, factoryData]
|
|
39343
40081
|
});
|
|
39344
40082
|
}
|
|
39345
40083
|
function getRevertErrorData(err) {
|
|
39346
|
-
if (!(err instanceof
|
|
40084
|
+
if (!(err instanceof BaseError4))
|
|
39347
40085
|
return void 0;
|
|
39348
40086
|
const error = err.walk();
|
|
39349
40087
|
return typeof error?.data === "object" ? error.data?.data : error.data;
|
|
@@ -39360,7 +40098,7 @@ var init_call = __esm({
|
|
|
39360
40098
|
init_base2();
|
|
39361
40099
|
init_chain2();
|
|
39362
40100
|
init_contract();
|
|
39363
|
-
|
|
40101
|
+
init_utils5();
|
|
39364
40102
|
init_decodeFunctionResult();
|
|
39365
40103
|
init_encodeDeployData();
|
|
39366
40104
|
init_encodeFunctionData2();
|
|
@@ -39705,6 +40443,25 @@ var SailKernelAbi = [
|
|
|
39705
40443
|
}
|
|
39706
40444
|
];
|
|
39707
40445
|
|
|
40446
|
+
// ../sdk/dist/capabilities.js
|
|
40447
|
+
init_esm();
|
|
40448
|
+
var DISPATCH_TYPE_STRINGS = {
|
|
40449
|
+
conjunctive: "Dispatch(address account,address target,uint256 value,bytes32 dataHash,uint256 nonce,uint256 deadline)",
|
|
40450
|
+
selective: "Dispatch(address account,address permission,address target,uint256 value,bytes32 dataHash,uint256 nonce,uint256 deadline)"
|
|
40451
|
+
};
|
|
40452
|
+
var REGISTER_PERMISSION_TYPE_STRINGS = {
|
|
40453
|
+
noDeadline: "RegisterPermission(address account,address permission,uint256 nonce)",
|
|
40454
|
+
withDeadline: "RegisterPermission(address account,address permission,uint256 nonce,uint256 deadline)"
|
|
40455
|
+
};
|
|
40456
|
+
var DISPATCH_TYPEHASHES = {
|
|
40457
|
+
conjunctive: keccak256(toBytes(DISPATCH_TYPE_STRINGS.conjunctive)),
|
|
40458
|
+
selective: keccak256(toBytes(DISPATCH_TYPE_STRINGS.selective))
|
|
40459
|
+
};
|
|
40460
|
+
var REGISTER_PERMISSION_TYPEHASHES = {
|
|
40461
|
+
noDeadline: keccak256(toBytes(REGISTER_PERMISSION_TYPE_STRINGS.noDeadline)),
|
|
40462
|
+
withDeadline: keccak256(toBytes(REGISTER_PERMISSION_TYPE_STRINGS.withDeadline))
|
|
40463
|
+
};
|
|
40464
|
+
|
|
39708
40465
|
// ../sdk/dist/deployments.js
|
|
39709
40466
|
var CREATE2_KERNEL = "0x02ABC18B65A328de2e749F56ba79ACF2718a6659";
|
|
39710
40467
|
var CREATE2_GOVERNANCE = "0x7A478118715791728BDE3bc7A4D7ECfdEB89C6EC";
|
|
@@ -39858,6 +40615,64 @@ function getSailDeployment(chainId) {
|
|
|
39858
40615
|
return deployment;
|
|
39859
40616
|
}
|
|
39860
40617
|
|
|
40618
|
+
// ../sdk/dist/errors.js
|
|
40619
|
+
init_esm();
|
|
40620
|
+
var KERNEL_ERROR_SIGNATURES = [
|
|
40621
|
+
"error AccountAlreadyRegistered(address account)",
|
|
40622
|
+
"error AccountNotRegistered(address account)",
|
|
40623
|
+
"error AccountSelfTarget()",
|
|
40624
|
+
"error ArrayLengthMismatch()",
|
|
40625
|
+
"error BatchPermissionDenied()",
|
|
40626
|
+
"error BatchSubcallFailed(uint256 index, address target)",
|
|
40627
|
+
"error BatchTooLong(uint256 length)",
|
|
40628
|
+
"error BatchZeroTarget(uint256 index)",
|
|
40629
|
+
"error DeadlineExpired(uint256 deadline, uint256 current)",
|
|
40630
|
+
"error DistributorBpsTooLarge(uint256 bps)",
|
|
40631
|
+
"error EmptyBatch()",
|
|
40632
|
+
"error FeePolicyNotSet()",
|
|
40633
|
+
"error FeeTokenMismatch(address provided, address expected)",
|
|
40634
|
+
"error FeeTooLarge(uint256 requested, uint256 maxAllowed)",
|
|
40635
|
+
"error FeeTransferFailed()",
|
|
40636
|
+
"error InsufficientFee(uint256 required, uint256 provided)",
|
|
40637
|
+
"error InvalidInitializer()",
|
|
40638
|
+
"error InvalidManagerSignature()",
|
|
40639
|
+
"error InvalidSignerSignature()",
|
|
40640
|
+
"error KernelSelfTarget(uint256 index)",
|
|
40641
|
+
// SAIL-405: setManager rejects a no-op rotation (newManager == current).
|
|
40642
|
+
"error ManagerUnchanged()",
|
|
40643
|
+
"error ModuleNotEnabled()",
|
|
40644
|
+
// Present in the deployed conjunctive kernel; dropped in the latest source.
|
|
40645
|
+
"error NoPermissionsRegistered(address account)",
|
|
40646
|
+
"error NotAContract(address addr)",
|
|
40647
|
+
"error NotGovernance()",
|
|
40648
|
+
"error NotManager(address caller, address expected)",
|
|
40649
|
+
"error NotPermissionSigner()",
|
|
40650
|
+
"error NotTimelock()",
|
|
40651
|
+
"error PermissionAlreadyRegistered(address permission)",
|
|
40652
|
+
"error PermissionDenied(address permission)",
|
|
40653
|
+
"error PermissionNotBatchAware(address permission)",
|
|
40654
|
+
"error PermissionNotRegistered(address permission)",
|
|
40655
|
+
"error ProtocolPaused()",
|
|
40656
|
+
"error SafeExecutionFailed()",
|
|
40657
|
+
"error SessionInactive(address account)",
|
|
40658
|
+
"error TooManyPermissions(address account, uint256 limit)",
|
|
40659
|
+
"error UntrustedFactory(address factory)",
|
|
40660
|
+
"error UntrustedFeePolicy(address policy)",
|
|
40661
|
+
"error UntrustedModuleSetup(address setup)",
|
|
40662
|
+
"error UntrustedProxyCodehash(bytes32 codehash)",
|
|
40663
|
+
"error UntrustedSingleton(address singleton)",
|
|
40664
|
+
"error ZeroAddress()",
|
|
40665
|
+
"error ZeroFee()"
|
|
40666
|
+
];
|
|
40667
|
+
var KERNEL_ERROR_ABI = parseAbi(KERNEL_ERROR_SIGNATURES);
|
|
40668
|
+
|
|
40669
|
+
// ../sdk/dist/lifi.js
|
|
40670
|
+
init_esm();
|
|
40671
|
+
var ERC20_ABI = parseAbi([
|
|
40672
|
+
"function approve(address spender, uint256 amount)",
|
|
40673
|
+
"function allowance(address owner, address spender) view returns (uint256)"
|
|
40674
|
+
]);
|
|
40675
|
+
|
|
39861
40676
|
// ../sdk/dist/keyring.js
|
|
39862
40677
|
var import_node_crypto = require("node:crypto");
|
|
39863
40678
|
var import_node_fs = require("node:fs");
|
|
@@ -39869,7 +40684,7 @@ init_secp256k1();
|
|
|
39869
40684
|
init_hmac();
|
|
39870
40685
|
init_legacy();
|
|
39871
40686
|
init_sha2();
|
|
39872
|
-
|
|
40687
|
+
init_utils2();
|
|
39873
40688
|
|
|
39874
40689
|
// ../../node_modules/.pnpm/@scure+base@1.2.6/node_modules/@scure/base/lib/esm/index.js
|
|
39875
40690
|
function isBytes3(a) {
|
|
@@ -40128,7 +40943,7 @@ var HDKey = class _HDKey {
|
|
|
40128
40943
|
static fromExtendedKey(base58key, versions = BITCOIN_VERSIONS) {
|
|
40129
40944
|
const keyBuffer = base58check.decode(base58key);
|
|
40130
40945
|
const keyView = createView(keyBuffer);
|
|
40131
|
-
const
|
|
40946
|
+
const version6 = keyView.getUint32(0, false);
|
|
40132
40947
|
const opt = {
|
|
40133
40948
|
versions,
|
|
40134
40949
|
depth: keyBuffer[4],
|
|
@@ -40138,7 +40953,7 @@ var HDKey = class _HDKey {
|
|
|
40138
40953
|
};
|
|
40139
40954
|
const key = keyBuffer.slice(45);
|
|
40140
40955
|
const isPriv = key[0] === 0;
|
|
40141
|
-
if (
|
|
40956
|
+
if (version6 !== versions[isPriv ? "private" : "public"]) {
|
|
40142
40957
|
throw new Error("Version mismatch");
|
|
40143
40958
|
}
|
|
40144
40959
|
if (isPriv) {
|
|
@@ -40291,18 +41106,18 @@ var HDKey = class _HDKey {
|
|
|
40291
41106
|
xpub: this.publicExtendedKey
|
|
40292
41107
|
};
|
|
40293
41108
|
}
|
|
40294
|
-
serialize(
|
|
41109
|
+
serialize(version6, key) {
|
|
40295
41110
|
if (!this.chainCode) {
|
|
40296
41111
|
throw new Error("No chainCode set");
|
|
40297
41112
|
}
|
|
40298
41113
|
abytes(key, 33);
|
|
40299
|
-
return concatBytes(toU32(
|
|
41114
|
+
return concatBytes(toU32(version6), new Uint8Array([this.depth]), toU32(this.parentFingerprint), toU32(this.index), this.chainCode, key);
|
|
40300
41115
|
}
|
|
40301
41116
|
};
|
|
40302
41117
|
|
|
40303
41118
|
// ../../node_modules/.pnpm/@noble+hashes@1.8.0/node_modules/@noble/hashes/esm/pbkdf2.js
|
|
40304
41119
|
init_hmac();
|
|
40305
|
-
|
|
41120
|
+
init_utils2();
|
|
40306
41121
|
function pbkdf2Init(hash4, _password, _salt, _opts) {
|
|
40307
41122
|
ahash(hash4);
|
|
40308
41123
|
const opts = checkOpts({ dkLen: 32, asyncTick: 10 }, _opts);
|
|
@@ -40762,7 +41577,7 @@ init_abi2();
|
|
|
40762
41577
|
|
|
40763
41578
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/log.js
|
|
40764
41579
|
init_base2();
|
|
40765
|
-
var FilterTypeNotSupportedError = class extends
|
|
41580
|
+
var FilterTypeNotSupportedError = class extends BaseError4 {
|
|
40766
41581
|
constructor(type) {
|
|
40767
41582
|
super(`Filter type "${type}" is not supported.`, {
|
|
40768
41583
|
name: "FilterTypeNotSupportedError"
|
|
@@ -40874,7 +41689,7 @@ init_request();
|
|
|
40874
41689
|
init_rpc();
|
|
40875
41690
|
var EXECUTION_REVERTED_ERROR_CODE = 3;
|
|
40876
41691
|
function getContractError(err, { abi: abi2, address, args, docsPath: docsPath9, functionName, sender }) {
|
|
40877
|
-
const error = err instanceof RawContractError ? err : err instanceof
|
|
41692
|
+
const error = err instanceof RawContractError ? err : err instanceof BaseError4 ? err.walk((err2) => "data" in err2) || err.walk() : {};
|
|
40878
41693
|
const { code, data, details, message, shortMessage } = error;
|
|
40879
41694
|
const cause = (() => {
|
|
40880
41695
|
if (err instanceof AbiDecodingZeroDataError)
|
|
@@ -41047,7 +41862,7 @@ function getSizeOfLength2(length) {
|
|
|
41047
41862
|
return 3;
|
|
41048
41863
|
if (length < 2 ** 32)
|
|
41049
41864
|
return 4;
|
|
41050
|
-
throw new
|
|
41865
|
+
throw new BaseError4("Length is too large.");
|
|
41051
41866
|
}
|
|
41052
41867
|
|
|
41053
41868
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/authorization/hashAuthorization.js
|
|
@@ -41085,7 +41900,7 @@ init_formatEther();
|
|
|
41085
41900
|
init_formatGwei2();
|
|
41086
41901
|
init_base2();
|
|
41087
41902
|
init_transaction2();
|
|
41088
|
-
var EstimateGasExecutionError = class extends
|
|
41903
|
+
var EstimateGasExecutionError = class extends BaseError4 {
|
|
41089
41904
|
constructor(cause, { account, docsPath: docsPath9, chain: chain2, data, gas, gasPrice, maxFeePerGas, maxPriorityFeePerGas, nonce, to, value }) {
|
|
41090
41905
|
const prettyArgs = prettyPrint2({
|
|
41091
41906
|
from: account?.address,
|
|
@@ -41146,21 +41961,21 @@ init_parseAccount();
|
|
|
41146
41961
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/fee.js
|
|
41147
41962
|
init_formatGwei2();
|
|
41148
41963
|
init_base2();
|
|
41149
|
-
var BaseFeeScalarError = class extends
|
|
41964
|
+
var BaseFeeScalarError = class extends BaseError4 {
|
|
41150
41965
|
constructor() {
|
|
41151
41966
|
super("`baseFeeMultiplier` must be greater than 1.", {
|
|
41152
41967
|
name: "BaseFeeScalarError"
|
|
41153
41968
|
});
|
|
41154
41969
|
}
|
|
41155
41970
|
};
|
|
41156
|
-
var Eip1559FeesNotSupportedError = class extends
|
|
41971
|
+
var Eip1559FeesNotSupportedError = class extends BaseError4 {
|
|
41157
41972
|
constructor() {
|
|
41158
41973
|
super("Chain does not support EIP-1559 fees.", {
|
|
41159
41974
|
name: "Eip1559FeesNotSupportedError"
|
|
41160
41975
|
});
|
|
41161
41976
|
}
|
|
41162
41977
|
};
|
|
41163
|
-
var MaxFeePerGasTooLowError = class extends
|
|
41978
|
+
var MaxFeePerGasTooLowError = class extends BaseError4 {
|
|
41164
41979
|
constructor({ maxPriorityFeePerGas }) {
|
|
41165
41980
|
super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${formatGwei2(maxPriorityFeePerGas)} gwei).`, { name: "MaxFeePerGasTooLowError" });
|
|
41166
41981
|
}
|
|
@@ -41171,7 +41986,7 @@ init_fromHex2();
|
|
|
41171
41986
|
|
|
41172
41987
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/block.js
|
|
41173
41988
|
init_base2();
|
|
41174
|
-
var BlockNotFoundError = class extends
|
|
41989
|
+
var BlockNotFoundError = class extends BaseError4 {
|
|
41175
41990
|
constructor({ blockHash, blockNumber }) {
|
|
41176
41991
|
let identifier = "Block";
|
|
41177
41992
|
if (blockHash)
|
|
@@ -41473,23 +42288,23 @@ function sha2564(value, to_) {
|
|
|
41473
42288
|
|
|
41474
42289
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/blob/commitmentToVersionedHash.js
|
|
41475
42290
|
function commitmentToVersionedHash2(parameters) {
|
|
41476
|
-
const { commitment, version:
|
|
42291
|
+
const { commitment, version: version6 = 1 } = parameters;
|
|
41477
42292
|
const to = parameters.to ?? (typeof commitment === "string" ? "hex" : "bytes");
|
|
41478
42293
|
const versionedHash = sha2564(commitment, "bytes");
|
|
41479
|
-
versionedHash.set([
|
|
42294
|
+
versionedHash.set([version6], 0);
|
|
41480
42295
|
return to === "bytes" ? versionedHash : bytesToHex4(versionedHash);
|
|
41481
42296
|
}
|
|
41482
42297
|
|
|
41483
42298
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/blob/commitmentsToVersionedHashes.js
|
|
41484
42299
|
function commitmentsToVersionedHashes2(parameters) {
|
|
41485
|
-
const { commitments, version:
|
|
42300
|
+
const { commitments, version: version6 } = parameters;
|
|
41486
42301
|
const to = parameters.to ?? (typeof commitments[0] === "string" ? "hex" : "bytes");
|
|
41487
42302
|
const hashes = [];
|
|
41488
42303
|
for (const commitment of commitments) {
|
|
41489
42304
|
hashes.push(commitmentToVersionedHash2({
|
|
41490
42305
|
commitment,
|
|
41491
42306
|
to,
|
|
41492
|
-
version:
|
|
42307
|
+
version: version6
|
|
41493
42308
|
}));
|
|
41494
42309
|
}
|
|
41495
42310
|
return hashes;
|
|
@@ -41509,7 +42324,7 @@ var versionedHashVersionKzg2 = 1;
|
|
|
41509
42324
|
|
|
41510
42325
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/blob.js
|
|
41511
42326
|
init_base2();
|
|
41512
|
-
var BlobSizeTooLargeError2 = class extends
|
|
42327
|
+
var BlobSizeTooLargeError2 = class extends BaseError4 {
|
|
41513
42328
|
constructor({ maxSize, size: size6 }) {
|
|
41514
42329
|
super("Blob size is too large.", {
|
|
41515
42330
|
metaMessages: [`Max: ${maxSize} bytes`, `Given: ${size6} bytes`],
|
|
@@ -41517,12 +42332,12 @@ var BlobSizeTooLargeError2 = class extends BaseError3 {
|
|
|
41517
42332
|
});
|
|
41518
42333
|
}
|
|
41519
42334
|
};
|
|
41520
|
-
var EmptyBlobError2 = class extends
|
|
42335
|
+
var EmptyBlobError2 = class extends BaseError4 {
|
|
41521
42336
|
constructor() {
|
|
41522
42337
|
super("Blob data must not be empty.", { name: "EmptyBlobError" });
|
|
41523
42338
|
}
|
|
41524
42339
|
};
|
|
41525
|
-
var InvalidVersionedHashSizeError2 = class extends
|
|
42340
|
+
var InvalidVersionedHashSizeError2 = class extends BaseError4 {
|
|
41526
42341
|
constructor({ hash: hash4, size: size6 }) {
|
|
41527
42342
|
super(`Versioned hash "${hash4}" size is invalid.`, {
|
|
41528
42343
|
metaMessages: ["Expected: 32", `Received: ${size6}`],
|
|
@@ -41530,12 +42345,12 @@ var InvalidVersionedHashSizeError2 = class extends BaseError3 {
|
|
|
41530
42345
|
});
|
|
41531
42346
|
}
|
|
41532
42347
|
};
|
|
41533
|
-
var InvalidVersionedHashVersionError2 = class extends
|
|
41534
|
-
constructor({ hash: hash4, version:
|
|
42348
|
+
var InvalidVersionedHashVersionError2 = class extends BaseError4 {
|
|
42349
|
+
constructor({ hash: hash4, version: version6 }) {
|
|
41535
42350
|
super(`Versioned hash "${hash4}" version is invalid.`, {
|
|
41536
42351
|
metaMessages: [
|
|
41537
42352
|
`Expected: ${versionedHashVersionKzg2}`,
|
|
41538
|
-
`Received: ${
|
|
42353
|
+
`Received: ${version6}`
|
|
41539
42354
|
],
|
|
41540
42355
|
name: "InvalidVersionedHashVersionError"
|
|
41541
42356
|
});
|
|
@@ -42000,7 +42815,7 @@ async function estimateGas(client, args) {
|
|
|
42000
42815
|
return await recoverAuthorizationAddress({
|
|
42001
42816
|
authorization: args.authorizationList[0]
|
|
42002
42817
|
}).catch(() => {
|
|
42003
|
-
throw new
|
|
42818
|
+
throw new BaseError4("`to` is required. Could not infer from `authorizationList`");
|
|
42004
42819
|
});
|
|
42005
42820
|
return void 0;
|
|
42006
42821
|
})();
|
|
@@ -42505,7 +43320,7 @@ function observe(observerId, callbacks, fn) {
|
|
|
42505
43320
|
}
|
|
42506
43321
|
|
|
42507
43322
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/wait.js
|
|
42508
|
-
|
|
43323
|
+
init_utils5();
|
|
42509
43324
|
async function wait(time, { signal } = {}) {
|
|
42510
43325
|
return new Promise((resolve, reject) => {
|
|
42511
43326
|
if (signal?.aborted) {
|
|
@@ -42815,7 +43630,7 @@ async function sendRawTransaction(client, { serializedTransaction }) {
|
|
|
42815
43630
|
}
|
|
42816
43631
|
|
|
42817
43632
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/promise/withRetry.js
|
|
42818
|
-
|
|
43633
|
+
init_utils5();
|
|
42819
43634
|
function withRetry(fn, { delay: delay_ = 100, retryCount = 2, shouldRetry: shouldRetry2 = () => true, signal } = {}) {
|
|
42820
43635
|
return new Promise((resolve, reject) => {
|
|
42821
43636
|
const attemptRetry = async ({ count = 0 } = {}) => {
|
|
@@ -42958,7 +43773,7 @@ init_toHex2();
|
|
|
42958
43773
|
init_base2();
|
|
42959
43774
|
init_contract();
|
|
42960
43775
|
function isNullUniversalResolverError(err) {
|
|
42961
|
-
if (!(err instanceof
|
|
43776
|
+
if (!(err instanceof BaseError4))
|
|
42962
43777
|
return false;
|
|
42963
43778
|
const cause = err.walk((e) => e instanceof ContractFunctionRevertedError);
|
|
42964
43779
|
if (!(cause instanceof ContractFunctionRevertedError))
|
|
@@ -43135,7 +43950,7 @@ function decodeAddress2({ coinType, data, args }) {
|
|
|
43135
43950
|
|
|
43136
43951
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/ens.js
|
|
43137
43952
|
init_base2();
|
|
43138
|
-
var EnsAvatarInvalidMetadataError = class extends
|
|
43953
|
+
var EnsAvatarInvalidMetadataError = class extends BaseError4 {
|
|
43139
43954
|
constructor({ data }) {
|
|
43140
43955
|
super("Unable to extract image from metadata. The metadata may be malformed or invalid.", {
|
|
43141
43956
|
metaMessages: [
|
|
@@ -43147,19 +43962,19 @@ var EnsAvatarInvalidMetadataError = class extends BaseError3 {
|
|
|
43147
43962
|
});
|
|
43148
43963
|
}
|
|
43149
43964
|
};
|
|
43150
|
-
var EnsAvatarInvalidNftUriError = class extends
|
|
43965
|
+
var EnsAvatarInvalidNftUriError = class extends BaseError4 {
|
|
43151
43966
|
constructor({ reason }) {
|
|
43152
43967
|
super(`ENS NFT avatar URI is invalid. ${reason}`, {
|
|
43153
43968
|
name: "EnsAvatarInvalidNftUriError"
|
|
43154
43969
|
});
|
|
43155
43970
|
}
|
|
43156
43971
|
};
|
|
43157
|
-
var EnsAvatarUriResolutionError = class extends
|
|
43972
|
+
var EnsAvatarUriResolutionError = class extends BaseError4 {
|
|
43158
43973
|
constructor({ uri }) {
|
|
43159
43974
|
super(`Unable to resolve ENS avatar URI "${uri}". The URI may be malformed, invalid, or does not respond with a valid image.`, { name: "EnsAvatarUriResolutionError" });
|
|
43160
43975
|
}
|
|
43161
43976
|
};
|
|
43162
|
-
var EnsAvatarUnsupportedNamespaceError = class extends
|
|
43977
|
+
var EnsAvatarUnsupportedNamespaceError = class extends BaseError4 {
|
|
43163
43978
|
constructor({ namespace }) {
|
|
43164
43979
|
super(`ENS NFT avatar namespace "${namespace}" is not supported. Must be "erc721" or "erc1155".`, { name: "EnsAvatarUnsupportedNamespaceError" });
|
|
43165
43980
|
}
|
|
@@ -43570,7 +44385,7 @@ async function createAccessList(client, args) {
|
|
|
43570
44385
|
params: [request, block]
|
|
43571
44386
|
});
|
|
43572
44387
|
if (response.error)
|
|
43573
|
-
throw new
|
|
44388
|
+
throw new BaseError4(response.error, { details: response.error });
|
|
43574
44389
|
return {
|
|
43575
44390
|
accessList: response.accessList,
|
|
43576
44391
|
gasUsed: BigInt(response.gasUsed)
|
|
@@ -43772,7 +44587,7 @@ async function getDelegation(client, { address, blockNumber, blockTag = "latest"
|
|
|
43772
44587
|
|
|
43773
44588
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/eip712.js
|
|
43774
44589
|
init_base2();
|
|
43775
|
-
var Eip712DomainNotFoundError = class extends
|
|
44590
|
+
var Eip712DomainNotFoundError = class extends BaseError4 {
|
|
43776
44591
|
constructor({ address }) {
|
|
43777
44592
|
super(`No EIP-712 domain found on contract "${address}".`, {
|
|
43778
44593
|
metaMessages: [
|
|
@@ -43790,7 +44605,7 @@ var Eip712DomainNotFoundError = class extends BaseError3 {
|
|
|
43790
44605
|
async function getEip712Domain(client, parameters) {
|
|
43791
44606
|
const { address, factory, factoryData } = parameters;
|
|
43792
44607
|
try {
|
|
43793
|
-
const [fields, name,
|
|
44608
|
+
const [fields, name, version6, chainId, verifyingContract, salt, extensions] = await getAction(client, readContract, "readContract")({
|
|
43794
44609
|
abi,
|
|
43795
44610
|
address,
|
|
43796
44611
|
functionName: "eip712Domain",
|
|
@@ -43800,7 +44615,7 @@ async function getEip712Domain(client, parameters) {
|
|
|
43800
44615
|
return {
|
|
43801
44616
|
domain: {
|
|
43802
44617
|
name,
|
|
43803
|
-
version:
|
|
44618
|
+
version: version6,
|
|
43804
44619
|
chainId: Number(chainId),
|
|
43805
44620
|
verifyingContract,
|
|
43806
44621
|
salt
|
|
@@ -43921,13 +44736,13 @@ function assertTransactionEIP48442(transaction) {
|
|
|
43921
44736
|
throw new EmptyBlobError2();
|
|
43922
44737
|
for (const hash4 of blobVersionedHashes) {
|
|
43923
44738
|
const size_ = size2(hash4);
|
|
43924
|
-
const
|
|
44739
|
+
const version6 = hexToNumber3(slice2(hash4, 0, 1));
|
|
43925
44740
|
if (size_ !== 32)
|
|
43926
44741
|
throw new InvalidVersionedHashSizeError2({ hash: hash4, size: size_ });
|
|
43927
|
-
if (
|
|
44742
|
+
if (version6 !== versionedHashVersionKzg2)
|
|
43928
44743
|
throw new InvalidVersionedHashVersionError2({
|
|
43929
44744
|
hash: hash4,
|
|
43930
|
-
version:
|
|
44745
|
+
version: version6
|
|
43931
44746
|
});
|
|
43932
44747
|
}
|
|
43933
44748
|
}
|
|
@@ -43951,7 +44766,7 @@ function assertTransactionEIP29302(transaction) {
|
|
|
43951
44766
|
if (to && !isAddress2(to))
|
|
43952
44767
|
throw new InvalidAddressError2({ address: to });
|
|
43953
44768
|
if (maxPriorityFeePerGas || maxFeePerGas)
|
|
43954
|
-
throw new
|
|
44769
|
+
throw new BaseError4("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid EIP-2930 Transaction attribute.");
|
|
43955
44770
|
if (gasPrice && gasPrice > maxUint2562)
|
|
43956
44771
|
throw new FeeCapTooHighError2({ maxFeePerGas: gasPrice });
|
|
43957
44772
|
}
|
|
@@ -43962,7 +44777,7 @@ function assertTransactionLegacy2(transaction) {
|
|
|
43962
44777
|
if (typeof chainId !== "undefined" && chainId <= 0)
|
|
43963
44778
|
throw new InvalidChainIdError2({ chainId });
|
|
43964
44779
|
if (maxPriorityFeePerGas || maxFeePerGas)
|
|
43965
|
-
throw new
|
|
44780
|
+
throw new BaseError4("`maxFeePerGas`/`maxPriorityFeePerGas` is not a valid Legacy Transaction attribute.");
|
|
43966
44781
|
if (gasPrice && gasPrice > maxUint2562)
|
|
43967
44782
|
throw new FeeCapTooHighError2({ maxFeePerGas: gasPrice });
|
|
43968
44783
|
}
|
|
@@ -44222,7 +45037,7 @@ async function verifyAuthorization({ address, authorization, signature }) {
|
|
|
44222
45037
|
init_base2();
|
|
44223
45038
|
init_request();
|
|
44224
45039
|
init_rpc();
|
|
44225
|
-
|
|
45040
|
+
init_utils5();
|
|
44226
45041
|
|
|
44227
45042
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/promise/withDedupe.js
|
|
44228
45043
|
init_lru2();
|
|
@@ -44353,7 +45168,7 @@ function buildRequest(request, options = {}) {
|
|
|
44353
45168
|
case WalletConnectSessionSettlementError.code:
|
|
44354
45169
|
throw new WalletConnectSessionSettlementError(err);
|
|
44355
45170
|
default:
|
|
44356
|
-
if (err_ instanceof
|
|
45171
|
+
if (err_ instanceof BaseError4)
|
|
44357
45172
|
throw err_;
|
|
44358
45173
|
throw new UnknownRpcError(err);
|
|
44359
45174
|
}
|
|
@@ -44428,10 +45243,10 @@ init_fromHex2();
|
|
|
44428
45243
|
|
|
44429
45244
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/rpc/http.js
|
|
44430
45245
|
init_request();
|
|
44431
|
-
|
|
45246
|
+
init_utils5();
|
|
44432
45247
|
|
|
44433
45248
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/utils/promise/withTimeout.js
|
|
44434
|
-
|
|
45249
|
+
init_utils5();
|
|
44435
45250
|
function withTimeout(fn, { errorInstance = new Error("timed out"), timeout, signal }) {
|
|
44436
45251
|
return new Promise((resolve, reject) => {
|
|
44437
45252
|
;
|
|
@@ -44626,14 +45441,14 @@ init_address3();
|
|
|
44626
45441
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/typedData.js
|
|
44627
45442
|
init_stringify2();
|
|
44628
45443
|
init_base2();
|
|
44629
|
-
var InvalidDomainError2 = class extends
|
|
45444
|
+
var InvalidDomainError2 = class extends BaseError4 {
|
|
44630
45445
|
constructor({ domain }) {
|
|
44631
45446
|
super(`Invalid domain "${stringify2(domain)}".`, {
|
|
44632
45447
|
metaMessages: ["Must be a valid EIP-712 domain."]
|
|
44633
45448
|
});
|
|
44634
45449
|
}
|
|
44635
45450
|
};
|
|
44636
|
-
var InvalidPrimaryTypeError2 = class extends
|
|
45451
|
+
var InvalidPrimaryTypeError2 = class extends BaseError4 {
|
|
44637
45452
|
constructor({ primaryType, types }) {
|
|
44638
45453
|
super(`Invalid primary type \`${primaryType}\` must be one of \`${JSON.stringify(Object.keys(types))}\`.`, {
|
|
44639
45454
|
docsPath: "/api/glossary/Errors#typeddatainvalidprimarytypeerror",
|
|
@@ -44641,7 +45456,7 @@ var InvalidPrimaryTypeError2 = class extends BaseError3 {
|
|
|
44641
45456
|
});
|
|
44642
45457
|
}
|
|
44643
45458
|
};
|
|
44644
|
-
var InvalidStructTypeError2 = class extends
|
|
45459
|
+
var InvalidStructTypeError2 = class extends BaseError4 {
|
|
44645
45460
|
constructor({ type }) {
|
|
44646
45461
|
super(`Struct type "${type}" is invalid.`, {
|
|
44647
45462
|
metaMessages: ["Struct type must not be a Solidity type."],
|
|
@@ -44661,7 +45476,7 @@ function validateTypedData2(parameters) {
|
|
|
44661
45476
|
for (const param of struct) {
|
|
44662
45477
|
const { name, type } = param;
|
|
44663
45478
|
const value = data[name];
|
|
44664
|
-
const integerMatch = type.match(
|
|
45479
|
+
const integerMatch = type.match(integerRegex4);
|
|
44665
45480
|
if (integerMatch && (typeof value === "number" || typeof value === "bigint")) {
|
|
44666
45481
|
const [_type, base, size_] = integerMatch;
|
|
44667
45482
|
numberToHex2(value, {
|
|
@@ -44671,7 +45486,7 @@ function validateTypedData2(parameters) {
|
|
|
44671
45486
|
}
|
|
44672
45487
|
if (type === "address" && typeof value === "string" && !isAddress2(value))
|
|
44673
45488
|
throw new InvalidAddressError2({ address: value });
|
|
44674
|
-
const bytesMatch = type.match(
|
|
45489
|
+
const bytesMatch = type.match(bytesRegex4);
|
|
44675
45490
|
if (bytesMatch) {
|
|
44676
45491
|
const [_type, size_] = bytesMatch;
|
|
44677
45492
|
if (size_ && size2(value) !== Number.parseInt(size_, 10))
|
|
@@ -44984,7 +45799,7 @@ function toHex3(publicKey, options = {}) {
|
|
|
44984
45799
|
);
|
|
44985
45800
|
return publicKey_;
|
|
44986
45801
|
}
|
|
44987
|
-
var InvalidError = class extends
|
|
45802
|
+
var InvalidError = class extends BaseError5 {
|
|
44988
45803
|
constructor({ publicKey }) {
|
|
44989
45804
|
super(`Value \`${stringify3(publicKey)}\` is not a valid public key.`, {
|
|
44990
45805
|
metaMessages: [
|
|
@@ -45001,7 +45816,7 @@ var InvalidError = class extends BaseError4 {
|
|
|
45001
45816
|
});
|
|
45002
45817
|
}
|
|
45003
45818
|
};
|
|
45004
|
-
var InvalidPrefixError = class extends
|
|
45819
|
+
var InvalidPrefixError = class extends BaseError5 {
|
|
45005
45820
|
constructor({ prefix, cause }) {
|
|
45006
45821
|
super(`Prefix "${prefix}" is invalid.`, {
|
|
45007
45822
|
cause
|
|
@@ -45014,7 +45829,7 @@ var InvalidPrefixError = class extends BaseError4 {
|
|
|
45014
45829
|
});
|
|
45015
45830
|
}
|
|
45016
45831
|
};
|
|
45017
|
-
var InvalidCompressedPrefixError = class extends
|
|
45832
|
+
var InvalidCompressedPrefixError = class extends BaseError5 {
|
|
45018
45833
|
constructor() {
|
|
45019
45834
|
super("Prefix must be 2 or 3 for compressed public keys.");
|
|
45020
45835
|
Object.defineProperty(this, "name", {
|
|
@@ -45025,7 +45840,7 @@ var InvalidCompressedPrefixError = class extends BaseError4 {
|
|
|
45025
45840
|
});
|
|
45026
45841
|
}
|
|
45027
45842
|
};
|
|
45028
|
-
var InvalidUncompressedPrefixError = class extends
|
|
45843
|
+
var InvalidUncompressedPrefixError = class extends BaseError5 {
|
|
45029
45844
|
constructor() {
|
|
45030
45845
|
super("Prefix must be 4 for uncompressed public keys.");
|
|
45031
45846
|
Object.defineProperty(this, "name", {
|
|
@@ -45036,7 +45851,7 @@ var InvalidUncompressedPrefixError = class extends BaseError4 {
|
|
|
45036
45851
|
});
|
|
45037
45852
|
}
|
|
45038
45853
|
};
|
|
45039
|
-
var InvalidSerializedSizeError = class extends
|
|
45854
|
+
var InvalidSerializedSizeError = class extends BaseError5 {
|
|
45040
45855
|
constructor({ publicKey }) {
|
|
45041
45856
|
super(`Value \`${publicKey}\` is an invalid public key size.`, {
|
|
45042
45857
|
metaMessages: [
|
|
@@ -45111,7 +45926,7 @@ function validate3(address, options = {}) {
|
|
|
45111
45926
|
return false;
|
|
45112
45927
|
}
|
|
45113
45928
|
}
|
|
45114
|
-
var InvalidAddressError3 = class extends
|
|
45929
|
+
var InvalidAddressError3 = class extends BaseError5 {
|
|
45115
45930
|
constructor({ address, cause }) {
|
|
45116
45931
|
super(`Address "${address}" is invalid.`, {
|
|
45117
45932
|
cause
|
|
@@ -45124,7 +45939,7 @@ var InvalidAddressError3 = class extends BaseError4 {
|
|
|
45124
45939
|
});
|
|
45125
45940
|
}
|
|
45126
45941
|
};
|
|
45127
|
-
var InvalidInputError = class extends
|
|
45942
|
+
var InvalidInputError = class extends BaseError5 {
|
|
45128
45943
|
constructor() {
|
|
45129
45944
|
super("Address is not a 20 byte (40 hexadecimal character) value.");
|
|
45130
45945
|
Object.defineProperty(this, "name", {
|
|
@@ -45135,7 +45950,7 @@ var InvalidInputError = class extends BaseError4 {
|
|
|
45135
45950
|
});
|
|
45136
45951
|
}
|
|
45137
45952
|
};
|
|
45138
|
-
var InvalidChecksumError = class extends
|
|
45953
|
+
var InvalidChecksumError = class extends BaseError5 {
|
|
45139
45954
|
constructor() {
|
|
45140
45955
|
super("Address does not match its checksum counterpart.");
|
|
45141
45956
|
Object.defineProperty(this, "name", {
|
|
@@ -45159,8 +45974,8 @@ init_Hex();
|
|
|
45159
45974
|
|
|
45160
45975
|
// ../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/Solidity.js
|
|
45161
45976
|
var arrayRegex = /^(.*)\[([0-9]*)\]$/;
|
|
45162
|
-
var
|
|
45163
|
-
var
|
|
45977
|
+
var bytesRegex5 = /^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/;
|
|
45978
|
+
var integerRegex5 = /^(u?int)(8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?$/;
|
|
45164
45979
|
var maxInt83 = 2n ** (8n - 1n) - 1n;
|
|
45165
45980
|
var maxInt163 = 2n ** (16n - 1n) - 1n;
|
|
45166
45981
|
var maxInt243 = 2n ** (24n - 1n) - 1n;
|
|
@@ -45457,7 +46272,7 @@ function prepareParameter({ checksumAddress: checksumAddress3 = false, parameter
|
|
|
45457
46272
|
}
|
|
45458
46273
|
if (parameter.type.startsWith("uint") || parameter.type.startsWith("int")) {
|
|
45459
46274
|
const signed = parameter.type.startsWith("int");
|
|
45460
|
-
const [, , size6 = "256"] =
|
|
46275
|
+
const [, , size6 = "256"] = integerRegex5.exec(parameter.type) ?? [];
|
|
45461
46276
|
return encodeNumber3(value, {
|
|
45462
46277
|
signed,
|
|
45463
46278
|
size: Number(size6)
|
|
@@ -45564,7 +46379,7 @@ function encodeBytes3(value, { type }) {
|
|
|
45564
46379
|
}
|
|
45565
46380
|
function encodeBoolean(value) {
|
|
45566
46381
|
if (typeof value !== "boolean")
|
|
45567
|
-
throw new
|
|
46382
|
+
throw new BaseError5(`Invalid boolean value: "${value}" (type: ${typeof value}). Expected: \`true\` or \`false\`.`);
|
|
45568
46383
|
return { dynamic: false, encoded: padLeft(fromBoolean(value)) };
|
|
45569
46384
|
}
|
|
45570
46385
|
function encodeNumber3(value, { signed, size: size6 }) {
|
|
@@ -45816,7 +46631,7 @@ function create(bytes, { recursiveReadLimit = 8192 } = {}) {
|
|
|
45816
46631
|
cursor.recursiveReadLimit = recursiveReadLimit;
|
|
45817
46632
|
return cursor;
|
|
45818
46633
|
}
|
|
45819
|
-
var NegativeOffsetError3 = class extends
|
|
46634
|
+
var NegativeOffsetError3 = class extends BaseError5 {
|
|
45820
46635
|
constructor({ offset }) {
|
|
45821
46636
|
super(`Offset \`${offset}\` cannot be negative.`);
|
|
45822
46637
|
Object.defineProperty(this, "name", {
|
|
@@ -45827,7 +46642,7 @@ var NegativeOffsetError3 = class extends BaseError4 {
|
|
|
45827
46642
|
});
|
|
45828
46643
|
}
|
|
45829
46644
|
};
|
|
45830
|
-
var PositionOutOfBoundsError3 = class extends
|
|
46645
|
+
var PositionOutOfBoundsError3 = class extends BaseError5 {
|
|
45831
46646
|
constructor({ length, position }) {
|
|
45832
46647
|
super(`Position \`${position}\` is out of bounds (\`0 < position < ${length}\`).`);
|
|
45833
46648
|
Object.defineProperty(this, "name", {
|
|
@@ -45838,7 +46653,7 @@ var PositionOutOfBoundsError3 = class extends BaseError4 {
|
|
|
45838
46653
|
});
|
|
45839
46654
|
}
|
|
45840
46655
|
};
|
|
45841
|
-
var RecursiveReadLimitExceededError3 = class extends
|
|
46656
|
+
var RecursiveReadLimitExceededError3 = class extends BaseError5 {
|
|
45842
46657
|
constructor({ count, limit }) {
|
|
45843
46658
|
super(`Recursive read limit of \`${limit}\` exceeded (recursive read count: \`${count}\`).`);
|
|
45844
46659
|
Object.defineProperty(this, "name", {
|
|
@@ -45924,7 +46739,7 @@ function encodePacked2(types, values) {
|
|
|
45924
46739
|
return value;
|
|
45925
46740
|
if (type === "bool")
|
|
45926
46741
|
return padLeft(fromBoolean(value), isArray ? 32 : 1);
|
|
45927
|
-
const intMatch = type.match(
|
|
46742
|
+
const intMatch = type.match(integerRegex5);
|
|
45928
46743
|
if (intMatch) {
|
|
45929
46744
|
const [_type, baseType, bits = "256"] = intMatch;
|
|
45930
46745
|
const size6 = Number.parseInt(bits, 10) / 8;
|
|
@@ -45933,7 +46748,7 @@ function encodePacked2(types, values) {
|
|
|
45933
46748
|
signed: baseType === "int"
|
|
45934
46749
|
});
|
|
45935
46750
|
}
|
|
45936
|
-
const bytesMatch = type.match(
|
|
46751
|
+
const bytesMatch = type.match(bytesRegex5);
|
|
45937
46752
|
if (bytesMatch) {
|
|
45938
46753
|
const [_type, size6] = bytesMatch;
|
|
45939
46754
|
if (Number.parseInt(size6, 10) !== (value.length - 2) / 2)
|
|
@@ -45960,12 +46775,12 @@ function encodePacked2(types, values) {
|
|
|
45960
46775
|
})(encodePacked2 || (encodePacked2 = {}));
|
|
45961
46776
|
function from5(parameters) {
|
|
45962
46777
|
if (Array.isArray(parameters) && typeof parameters[0] === "string")
|
|
45963
|
-
return
|
|
46778
|
+
return parseAbiParameters2(parameters);
|
|
45964
46779
|
if (typeof parameters === "string")
|
|
45965
|
-
return
|
|
46780
|
+
return parseAbiParameters2(parameters);
|
|
45966
46781
|
return parameters;
|
|
45967
46782
|
}
|
|
45968
|
-
var DataSizeTooSmallError = class extends
|
|
46783
|
+
var DataSizeTooSmallError = class extends BaseError5 {
|
|
45969
46784
|
constructor({ data, parameters, size: size6 }) {
|
|
45970
46785
|
super(`Data size of ${size6} bytes is too small for given parameters.`, {
|
|
45971
46786
|
metaMessages: [
|
|
@@ -45981,7 +46796,7 @@ var DataSizeTooSmallError = class extends BaseError4 {
|
|
|
45981
46796
|
});
|
|
45982
46797
|
}
|
|
45983
46798
|
};
|
|
45984
|
-
var ZeroDataError = class extends
|
|
46799
|
+
var ZeroDataError = class extends BaseError5 {
|
|
45985
46800
|
constructor() {
|
|
45986
46801
|
super('Cannot decode zero data ("0x") with ABI parameters.');
|
|
45987
46802
|
Object.defineProperty(this, "name", {
|
|
@@ -45992,7 +46807,7 @@ var ZeroDataError = class extends BaseError4 {
|
|
|
45992
46807
|
});
|
|
45993
46808
|
}
|
|
45994
46809
|
};
|
|
45995
|
-
var ArrayLengthMismatchError = class extends
|
|
46810
|
+
var ArrayLengthMismatchError = class extends BaseError5 {
|
|
45996
46811
|
constructor({ expectedLength, givenLength, type }) {
|
|
45997
46812
|
super(`Array length mismatch for type \`${type}\`. Expected: \`${expectedLength}\`. Given: \`${givenLength}\`.`);
|
|
45998
46813
|
Object.defineProperty(this, "name", {
|
|
@@ -46003,7 +46818,7 @@ var ArrayLengthMismatchError = class extends BaseError4 {
|
|
|
46003
46818
|
});
|
|
46004
46819
|
}
|
|
46005
46820
|
};
|
|
46006
|
-
var BytesSizeMismatchError3 = class extends
|
|
46821
|
+
var BytesSizeMismatchError3 = class extends BaseError5 {
|
|
46007
46822
|
constructor({ expectedSize, value }) {
|
|
46008
46823
|
super(`Size of bytes "${value}" (bytes${size4(value)}) does not match expected size (bytes${expectedSize}).`);
|
|
46009
46824
|
Object.defineProperty(this, "name", {
|
|
@@ -46014,7 +46829,7 @@ var BytesSizeMismatchError3 = class extends BaseError4 {
|
|
|
46014
46829
|
});
|
|
46015
46830
|
}
|
|
46016
46831
|
};
|
|
46017
|
-
var LengthMismatchError = class extends
|
|
46832
|
+
var LengthMismatchError = class extends BaseError5 {
|
|
46018
46833
|
constructor({ expectedLength, givenLength }) {
|
|
46019
46834
|
super([
|
|
46020
46835
|
"ABI encoding parameters/values length mismatch.",
|
|
@@ -46029,7 +46844,7 @@ var LengthMismatchError = class extends BaseError4 {
|
|
|
46029
46844
|
});
|
|
46030
46845
|
}
|
|
46031
46846
|
};
|
|
46032
|
-
var InvalidArrayError3 = class extends
|
|
46847
|
+
var InvalidArrayError3 = class extends BaseError5 {
|
|
46033
46848
|
constructor(value) {
|
|
46034
46849
|
super(`Value \`${value}\` is not a valid array.`);
|
|
46035
46850
|
Object.defineProperty(this, "name", {
|
|
@@ -46040,7 +46855,7 @@ var InvalidArrayError3 = class extends BaseError4 {
|
|
|
46040
46855
|
});
|
|
46041
46856
|
}
|
|
46042
46857
|
};
|
|
46043
|
-
var InvalidTypeError = class extends
|
|
46858
|
+
var InvalidTypeError = class extends BaseError5 {
|
|
46044
46859
|
constructor(type) {
|
|
46045
46860
|
super(`Type \`${type}\` is not a valid ABI Type.`);
|
|
46046
46861
|
Object.defineProperty(this, "name", {
|
|
@@ -46149,7 +46964,7 @@ function getSizeOfLength3(length) {
|
|
|
46149
46964
|
return 3;
|
|
46150
46965
|
if (length <= 4294967295)
|
|
46151
46966
|
return 4;
|
|
46152
|
-
throw new
|
|
46967
|
+
throw new BaseError5("Length is too large.");
|
|
46153
46968
|
}
|
|
46154
46969
|
|
|
46155
46970
|
// ../../node_modules/.pnpm/ox@0.14.25_typescript@5.9.3_zod@3.25.76/node_modules/ox/_esm/core/Signature.js
|
|
@@ -46266,7 +47081,7 @@ function vToYParity(v) {
|
|
|
46266
47081
|
return v % 2 === 0 ? 1 : 0;
|
|
46267
47082
|
throw new InvalidVError({ value: v });
|
|
46268
47083
|
}
|
|
46269
|
-
var InvalidSerializedSizeError2 = class extends
|
|
47084
|
+
var InvalidSerializedSizeError2 = class extends BaseError5 {
|
|
46270
47085
|
constructor({ signature }) {
|
|
46271
47086
|
super(`Value \`${signature}\` is an invalid signature size.`, {
|
|
46272
47087
|
metaMessages: [
|
|
@@ -46282,7 +47097,7 @@ var InvalidSerializedSizeError2 = class extends BaseError4 {
|
|
|
46282
47097
|
});
|
|
46283
47098
|
}
|
|
46284
47099
|
};
|
|
46285
|
-
var MissingPropertiesError = class extends
|
|
47100
|
+
var MissingPropertiesError = class extends BaseError5 {
|
|
46286
47101
|
constructor({ signature }) {
|
|
46287
47102
|
super(`Signature \`${stringify3(signature)}\` is missing either an \`r\`, \`s\`, or \`yParity\` property.`);
|
|
46288
47103
|
Object.defineProperty(this, "name", {
|
|
@@ -46293,7 +47108,7 @@ var MissingPropertiesError = class extends BaseError4 {
|
|
|
46293
47108
|
});
|
|
46294
47109
|
}
|
|
46295
47110
|
};
|
|
46296
|
-
var InvalidRError = class extends
|
|
47111
|
+
var InvalidRError = class extends BaseError5 {
|
|
46297
47112
|
constructor({ value }) {
|
|
46298
47113
|
super(`Value \`${value}\` is an invalid r value. r must be a positive integer less than 2^256.`);
|
|
46299
47114
|
Object.defineProperty(this, "name", {
|
|
@@ -46304,7 +47119,7 @@ var InvalidRError = class extends BaseError4 {
|
|
|
46304
47119
|
});
|
|
46305
47120
|
}
|
|
46306
47121
|
};
|
|
46307
|
-
var InvalidSError = class extends
|
|
47122
|
+
var InvalidSError = class extends BaseError5 {
|
|
46308
47123
|
constructor({ value }) {
|
|
46309
47124
|
super(`Value \`${value}\` is an invalid s value. s must be a positive integer less than 2^256.`);
|
|
46310
47125
|
Object.defineProperty(this, "name", {
|
|
@@ -46315,7 +47130,7 @@ var InvalidSError = class extends BaseError4 {
|
|
|
46315
47130
|
});
|
|
46316
47131
|
}
|
|
46317
47132
|
};
|
|
46318
|
-
var InvalidYParityError = class extends
|
|
47133
|
+
var InvalidYParityError = class extends BaseError5 {
|
|
46319
47134
|
constructor({ value }) {
|
|
46320
47135
|
super(`Value \`${value}\` is an invalid y-parity value. Y-parity must be 0 or 1.`);
|
|
46321
47136
|
Object.defineProperty(this, "name", {
|
|
@@ -46326,7 +47141,7 @@ var InvalidYParityError = class extends BaseError4 {
|
|
|
46326
47141
|
});
|
|
46327
47142
|
}
|
|
46328
47143
|
};
|
|
46329
|
-
var InvalidVError = class extends
|
|
47144
|
+
var InvalidVError = class extends BaseError5 {
|
|
46330
47145
|
constructor({ value }) {
|
|
46331
47146
|
super(`Value \`${value}\` is an invalid v value. v must be 27, 28 or >=35.`);
|
|
46332
47147
|
Object.defineProperty(this, "name", {
|
|
@@ -46456,7 +47271,7 @@ function validate4(value) {
|
|
|
46456
47271
|
return false;
|
|
46457
47272
|
}
|
|
46458
47273
|
}
|
|
46459
|
-
var InvalidWrappedSignatureError = class extends
|
|
47274
|
+
var InvalidWrappedSignatureError = class extends BaseError5 {
|
|
46460
47275
|
constructor(wrapped) {
|
|
46461
47276
|
super(`Value \`${wrapped}\` is an invalid ERC-8010 wrapped signature.`);
|
|
46462
47277
|
Object.defineProperty(this, "name", {
|
|
@@ -46715,7 +47530,7 @@ async function multicall(client, parameters) {
|
|
|
46715
47530
|
}
|
|
46716
47531
|
}
|
|
46717
47532
|
if (results.length !== contracts.length)
|
|
46718
|
-
throw new
|
|
47533
|
+
throw new BaseError4("multicall results mismatch");
|
|
46719
47534
|
return results;
|
|
46720
47535
|
}
|
|
46721
47536
|
|
|
@@ -46866,7 +47681,7 @@ function normalizeSignature3(signature) {
|
|
|
46866
47681
|
current += char;
|
|
46867
47682
|
}
|
|
46868
47683
|
if (!valid)
|
|
46869
|
-
throw new
|
|
47684
|
+
throw new BaseError5("Unable to normalize signature.");
|
|
46870
47685
|
return result;
|
|
46871
47686
|
}
|
|
46872
47687
|
function isArgOfType3(arg, abiParameter) {
|
|
@@ -46932,9 +47747,9 @@ function from10(abiItem, options = {}) {
|
|
|
46932
47747
|
const { prepare = true } = options;
|
|
46933
47748
|
const item = (() => {
|
|
46934
47749
|
if (Array.isArray(abiItem))
|
|
46935
|
-
return
|
|
47750
|
+
return parseAbiItem2(abiItem);
|
|
46936
47751
|
if (typeof abiItem === "string")
|
|
46937
|
-
return
|
|
47752
|
+
return parseAbiItem2(abiItem);
|
|
46938
47753
|
return abiItem;
|
|
46939
47754
|
})();
|
|
46940
47755
|
return {
|
|
@@ -47051,7 +47866,7 @@ function getSignatureHash(...parameters) {
|
|
|
47051
47866
|
return abiItem.hash;
|
|
47052
47867
|
return keccak2563(fromString2(getSignature(abiItem)));
|
|
47053
47868
|
}
|
|
47054
|
-
var AmbiguityError = class extends
|
|
47869
|
+
var AmbiguityError = class extends BaseError5 {
|
|
47055
47870
|
constructor(x, y) {
|
|
47056
47871
|
super("Found ambiguous types in overloaded ABI Items.", {
|
|
47057
47872
|
metaMessages: [
|
|
@@ -47071,7 +47886,7 @@ var AmbiguityError = class extends BaseError4 {
|
|
|
47071
47886
|
});
|
|
47072
47887
|
}
|
|
47073
47888
|
};
|
|
47074
|
-
var NotFoundError = class extends
|
|
47889
|
+
var NotFoundError = class extends BaseError5 {
|
|
47075
47890
|
constructor({ name, data, type = "item" }) {
|
|
47076
47891
|
const selector = (() => {
|
|
47077
47892
|
if (name)
|
|
@@ -47161,7 +47976,7 @@ async function simulateCalls(client, parameters) {
|
|
|
47161
47976
|
const { blockNumber, blockTag, calls, stateOverrides, traceAssetChanges, traceTransfers, validation } = parameters;
|
|
47162
47977
|
const account = parameters.account ? parseAccount(parameters.account) : void 0;
|
|
47163
47978
|
if (traceAssetChanges && !account)
|
|
47164
|
-
throw new
|
|
47979
|
+
throw new BaseError4("`account` is required when `traceAssetChanges` is true");
|
|
47165
47980
|
const getBalanceData = account ? encode3(from11("constructor(bytes, bytes)"), {
|
|
47166
47981
|
bytecode: deploylessCallViaBytecodeBytecode,
|
|
47167
47982
|
args: [
|
|
@@ -47443,7 +48258,7 @@ function validate5(wrapped) {
|
|
|
47443
48258
|
return false;
|
|
47444
48259
|
}
|
|
47445
48260
|
}
|
|
47446
|
-
var InvalidWrappedSignatureError2 = class extends
|
|
48261
|
+
var InvalidWrappedSignatureError2 = class extends BaseError5 {
|
|
47447
48262
|
constructor(wrapped) {
|
|
47448
48263
|
super(`Value \`${wrapped}\` is an invalid ERC-6492 wrapped signature.`);
|
|
47449
48264
|
Object.defineProperty(this, "name", {
|
|
@@ -48467,7 +49282,7 @@ init_request();
|
|
|
48467
49282
|
|
|
48468
49283
|
// ../../node_modules/.pnpm/viem@2.51.3_bufferutil@4.1.0_typescript@5.9.3_utf-8-validate@5.0.10_zod@3.25.76/node_modules/viem/_esm/errors/transport.js
|
|
48469
49284
|
init_base2();
|
|
48470
|
-
var UrlRequiredError = class extends
|
|
49285
|
+
var UrlRequiredError = class extends BaseError4 {
|
|
48471
49286
|
constructor() {
|
|
48472
49287
|
super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.", {
|
|
48473
49288
|
docsPath: "/docs/clients/intro",
|