@gearbox-protocol/deploy-tools 5.45.17 → 5.45.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.mjs +1178 -298
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -4323,15 +4323,15 @@ var init_structs = __esm({
|
|
|
4323
4323
|
// ../../node_modules/abitype/dist/esm/human-readable/parseAbi.js
|
|
4324
4324
|
function parseAbi(signatures) {
|
|
4325
4325
|
const structs = parseStructs(signatures);
|
|
4326
|
-
const
|
|
4326
|
+
const abi29 = [];
|
|
4327
4327
|
const length = signatures.length;
|
|
4328
4328
|
for (let i = 0; i < length; i++) {
|
|
4329
4329
|
const signature = signatures[i];
|
|
4330
4330
|
if (isStructSignature(signature))
|
|
4331
4331
|
continue;
|
|
4332
|
-
|
|
4332
|
+
abi29.push(parseSignature(signature, structs));
|
|
4333
4333
|
}
|
|
4334
|
-
return
|
|
4334
|
+
return abi29;
|
|
4335
4335
|
}
|
|
4336
4336
|
var init_parseAbi = __esm({
|
|
4337
4337
|
"../../node_modules/abitype/dist/esm/human-readable/parseAbi.js"() {
|
|
@@ -6093,9 +6093,9 @@ var init_toFunctionSelector = __esm({
|
|
|
6093
6093
|
|
|
6094
6094
|
// ../../node_modules/viem/_esm/utils/abi/getAbiItem.js
|
|
6095
6095
|
function getAbiItem(parameters) {
|
|
6096
|
-
const { abi:
|
|
6096
|
+
const { abi: abi29, args = [], name } = parameters;
|
|
6097
6097
|
const isSelector = isHex(name, { strict: false });
|
|
6098
|
-
const abiItems =
|
|
6098
|
+
const abiItems = abi29.filter((abiItem) => {
|
|
6099
6099
|
if (isSelector) {
|
|
6100
6100
|
if (abiItem.type === "function")
|
|
6101
6101
|
return toFunctionSelector(abiItem) === name;
|
|
@@ -6225,11 +6225,11 @@ var init_parseAccount = __esm({
|
|
|
6225
6225
|
|
|
6226
6226
|
// ../../node_modules/viem/_esm/utils/abi/prepareEncodeFunctionData.js
|
|
6227
6227
|
function prepareEncodeFunctionData(parameters) {
|
|
6228
|
-
const { abi:
|
|
6229
|
-
let abiItem =
|
|
6228
|
+
const { abi: abi29, args, functionName } = parameters;
|
|
6229
|
+
let abiItem = abi29[0];
|
|
6230
6230
|
if (functionName) {
|
|
6231
6231
|
const item = getAbiItem({
|
|
6232
|
-
abi:
|
|
6232
|
+
abi: abi29,
|
|
6233
6233
|
args,
|
|
6234
6234
|
name: functionName
|
|
6235
6235
|
});
|
|
@@ -6258,12 +6258,12 @@ var init_prepareEncodeFunctionData = __esm({
|
|
|
6258
6258
|
// ../../node_modules/viem/_esm/utils/abi/encodeFunctionData.js
|
|
6259
6259
|
function encodeFunctionData(parameters) {
|
|
6260
6260
|
const { args } = parameters;
|
|
6261
|
-
const { abi:
|
|
6261
|
+
const { abi: abi29, functionName } = (() => {
|
|
6262
6262
|
if (parameters.abi.length === 1 && parameters.functionName?.startsWith("0x"))
|
|
6263
6263
|
return parameters;
|
|
6264
6264
|
return prepareEncodeFunctionData(parameters);
|
|
6265
6265
|
})();
|
|
6266
|
-
const abiItem =
|
|
6266
|
+
const abiItem = abi29[0];
|
|
6267
6267
|
const signature = functionName;
|
|
6268
6268
|
const data = "inputs" in abiItem && abiItem.inputs ? encodeAbiParameters(abiItem.inputs, args ?? []) : void 0;
|
|
6269
6269
|
return concatHex([signature, data ?? "0x"]);
|
|
@@ -6758,11 +6758,11 @@ var init_decodeAbiParameters = __esm({
|
|
|
6758
6758
|
|
|
6759
6759
|
// ../../node_modules/viem/_esm/utils/abi/decodeErrorResult.js
|
|
6760
6760
|
function decodeErrorResult(parameters) {
|
|
6761
|
-
const { abi:
|
|
6761
|
+
const { abi: abi29, data } = parameters;
|
|
6762
6762
|
const signature = slice(data, 0, 4);
|
|
6763
6763
|
if (signature === "0x")
|
|
6764
6764
|
throw new AbiDecodingZeroDataError();
|
|
6765
|
-
const abi_ = [...
|
|
6765
|
+
const abi_ = [...abi29 || [], solidityError, solidityPanic];
|
|
6766
6766
|
const abiItem = abi_.find((x) => x.type === "error" && signature === toFunctionSelector(formatAbiItem2(x)));
|
|
6767
6767
|
if (!abiItem)
|
|
6768
6768
|
throw new AbiErrorSignatureNotFoundError(signature, {
|
|
@@ -7105,8 +7105,8 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
7105
7105
|
}
|
|
7106
7106
|
};
|
|
7107
7107
|
ContractFunctionExecutionError = class extends BaseError2 {
|
|
7108
|
-
constructor(cause, { abi:
|
|
7109
|
-
const abiItem = getAbiItem({ abi:
|
|
7108
|
+
constructor(cause, { abi: abi29, args, contractAddress, docsPath: docsPath8, functionName, sender }) {
|
|
7109
|
+
const abiItem = getAbiItem({ abi: abi29, args, name: functionName });
|
|
7110
7110
|
const formattedArgs = abiItem ? formatAbiItemWithArgs({
|
|
7111
7111
|
abiItem,
|
|
7112
7112
|
args,
|
|
@@ -7172,7 +7172,7 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
7172
7172
|
writable: true,
|
|
7173
7173
|
value: void 0
|
|
7174
7174
|
});
|
|
7175
|
-
this.abi =
|
|
7175
|
+
this.abi = abi29;
|
|
7176
7176
|
this.args = args;
|
|
7177
7177
|
this.cause = cause;
|
|
7178
7178
|
this.contractAddress = contractAddress;
|
|
@@ -7181,14 +7181,14 @@ ${prettyStateOverride(stateOverride)}`;
|
|
|
7181
7181
|
}
|
|
7182
7182
|
};
|
|
7183
7183
|
ContractFunctionRevertedError = class extends BaseError2 {
|
|
7184
|
-
constructor({ abi:
|
|
7184
|
+
constructor({ abi: abi29, data, functionName, message: message2 }) {
|
|
7185
7185
|
let cause;
|
|
7186
7186
|
let decodedData;
|
|
7187
7187
|
let metaMessages;
|
|
7188
7188
|
let reason;
|
|
7189
7189
|
if (data && data !== "0x") {
|
|
7190
7190
|
try {
|
|
7191
|
-
decodedData = decodeErrorResult({ abi:
|
|
7191
|
+
decodedData = decodeErrorResult({ abi: abi29, data });
|
|
7192
7192
|
const { abiItem, errorName, args: errorArgs } = decodedData;
|
|
7193
7193
|
if (errorName === "Error") {
|
|
7194
7194
|
reason = errorArgs[0];
|
|
@@ -10886,10 +10886,10 @@ var init_isAddressEqual = __esm({
|
|
|
10886
10886
|
|
|
10887
10887
|
// ../../node_modules/viem/_esm/utils/abi/decodeFunctionResult.js
|
|
10888
10888
|
function decodeFunctionResult(parameters) {
|
|
10889
|
-
const { abi:
|
|
10890
|
-
let abiItem =
|
|
10889
|
+
const { abi: abi29, args, functionName, data } = parameters;
|
|
10890
|
+
let abiItem = abi29[0];
|
|
10891
10891
|
if (functionName) {
|
|
10892
|
-
const item = getAbiItem({ abi:
|
|
10892
|
+
const item = getAbiItem({ abi: abi29, args, name: functionName });
|
|
10893
10893
|
if (!item)
|
|
10894
10894
|
throw new AbiFunctionNotFoundError(functionName, { docsPath: docsPath4 });
|
|
10895
10895
|
abiItem = item;
|
|
@@ -12745,10 +12745,10 @@ var init_chain = __esm({
|
|
|
12745
12745
|
|
|
12746
12746
|
// ../../node_modules/viem/_esm/utils/abi/encodeDeployData.js
|
|
12747
12747
|
function encodeDeployData(parameters) {
|
|
12748
|
-
const { abi:
|
|
12748
|
+
const { abi: abi29, args, bytecode } = parameters;
|
|
12749
12749
|
if (!args || args.length === 0)
|
|
12750
12750
|
return bytecode;
|
|
12751
|
-
const description =
|
|
12751
|
+
const description = abi29.find((x) => "type" in x && x.type === "constructor");
|
|
12752
12752
|
if (!description)
|
|
12753
12753
|
throw new AbiConstructorNotFoundError({ docsPath: docsPath5 });
|
|
12754
12754
|
if (!("inputs" in description))
|
|
@@ -12936,9 +12936,9 @@ var init_ccip = __esm({
|
|
|
12936
12936
|
|
|
12937
12937
|
// ../../node_modules/viem/_esm/utils/abi/decodeFunctionData.js
|
|
12938
12938
|
function decodeFunctionData(parameters) {
|
|
12939
|
-
const { abi:
|
|
12939
|
+
const { abi: abi29, data } = parameters;
|
|
12940
12940
|
const signature = slice(data, 0, 4);
|
|
12941
|
-
const description =
|
|
12941
|
+
const description = abi29.find((x) => x.type === "function" && signature === toFunctionSelector(formatAbiItem2(x)));
|
|
12942
12942
|
if (!description)
|
|
12943
12943
|
throw new AbiFunctionSignatureNotFoundError(signature, {
|
|
12944
12944
|
docsPath: "/docs/contract/decodeFunctionData"
|
|
@@ -12960,10 +12960,10 @@ var init_decodeFunctionData = __esm({
|
|
|
12960
12960
|
|
|
12961
12961
|
// ../../node_modules/viem/_esm/utils/abi/encodeErrorResult.js
|
|
12962
12962
|
function encodeErrorResult(parameters) {
|
|
12963
|
-
const { abi:
|
|
12964
|
-
let abiItem =
|
|
12963
|
+
const { abi: abi29, errorName, args } = parameters;
|
|
12964
|
+
let abiItem = abi29[0];
|
|
12965
12965
|
if (errorName) {
|
|
12966
|
-
const item = getAbiItem({ abi:
|
|
12966
|
+
const item = getAbiItem({ abi: abi29, args, name: errorName });
|
|
12967
12967
|
if (!item)
|
|
12968
12968
|
throw new AbiErrorNotFoundError(errorName, { docsPath: docsPath6 });
|
|
12969
12969
|
abiItem = item;
|
|
@@ -12995,10 +12995,10 @@ var init_encodeErrorResult = __esm({
|
|
|
12995
12995
|
|
|
12996
12996
|
// ../../node_modules/viem/_esm/utils/abi/encodeFunctionResult.js
|
|
12997
12997
|
function encodeFunctionResult(parameters) {
|
|
12998
|
-
const { abi:
|
|
12999
|
-
let abiItem =
|
|
12998
|
+
const { abi: abi29, functionName, result } = parameters;
|
|
12999
|
+
let abiItem = abi29[0];
|
|
13000
13000
|
if (functionName) {
|
|
13001
|
-
const item = getAbiItem({ abi:
|
|
13001
|
+
const item = getAbiItem({ abi: abi29, name: functionName });
|
|
13002
13002
|
if (!item)
|
|
13003
13003
|
throw new AbiFunctionNotFoundError(functionName, { docsPath: docsPath7 });
|
|
13004
13004
|
abiItem = item;
|
|
@@ -35374,13 +35374,13 @@ var require_interface = __commonJS({
|
|
|
35374
35374
|
function Interface2(fragments) {
|
|
35375
35375
|
var _newTarget = this.constructor;
|
|
35376
35376
|
var _this = this;
|
|
35377
|
-
var
|
|
35377
|
+
var abi29 = [];
|
|
35378
35378
|
if (typeof fragments === "string") {
|
|
35379
|
-
|
|
35379
|
+
abi29 = JSON.parse(fragments);
|
|
35380
35380
|
} else {
|
|
35381
|
-
|
|
35381
|
+
abi29 = fragments;
|
|
35382
35382
|
}
|
|
35383
|
-
(0, properties_1.defineReadOnly)(this, "fragments",
|
|
35383
|
+
(0, properties_1.defineReadOnly)(this, "fragments", abi29.map(function(fragment) {
|
|
35384
35384
|
return fragments_1.Fragment.from(fragment);
|
|
35385
35385
|
}).filter(function(fragment) {
|
|
35386
35386
|
return fragment != null;
|
|
@@ -35434,15 +35434,15 @@ var require_interface = __commonJS({
|
|
|
35434
35434
|
if (format2 === fragments_1.FormatTypes.sighash) {
|
|
35435
35435
|
logger2.throwArgumentError("interface does not support formatting sighash", "format", format2);
|
|
35436
35436
|
}
|
|
35437
|
-
var
|
|
35437
|
+
var abi29 = this.fragments.map(function(fragment) {
|
|
35438
35438
|
return fragment.format(format2);
|
|
35439
35439
|
});
|
|
35440
35440
|
if (format2 === fragments_1.FormatTypes.json) {
|
|
35441
|
-
return JSON.stringify(
|
|
35441
|
+
return JSON.stringify(abi29.map(function(j) {
|
|
35442
35442
|
return JSON.parse(j);
|
|
35443
35443
|
}));
|
|
35444
35444
|
}
|
|
35445
|
-
return
|
|
35445
|
+
return abi29;
|
|
35446
35446
|
};
|
|
35447
35447
|
Interface2.getAbiCoder = function() {
|
|
35448
35448
|
return abi_coder_1.defaultAbiCoder;
|
|
@@ -51185,14 +51185,14 @@ var require_lib29 = __commonJS({
|
|
|
51185
51185
|
if (typeof compilerOutput === "string") {
|
|
51186
51186
|
compilerOutput = JSON.parse(compilerOutput);
|
|
51187
51187
|
}
|
|
51188
|
-
var
|
|
51188
|
+
var abi29 = compilerOutput.abi;
|
|
51189
51189
|
var bytecode = null;
|
|
51190
51190
|
if (compilerOutput.bytecode) {
|
|
51191
51191
|
bytecode = compilerOutput.bytecode;
|
|
51192
51192
|
} else if (compilerOutput.evm && compilerOutput.evm.bytecode) {
|
|
51193
51193
|
bytecode = compilerOutput.evm.bytecode;
|
|
51194
51194
|
}
|
|
51195
|
-
return new this(
|
|
51195
|
+
return new this(abi29, bytecode, signer);
|
|
51196
51196
|
};
|
|
51197
51197
|
ContractFactory2.getInterface = function(contractInterface) {
|
|
51198
51198
|
return Contract.getInterface(contractInterface);
|
|
@@ -55707,7 +55707,7 @@ var require_node_gyp_build = __commonJS({
|
|
|
55707
55707
|
var runtimeRequire = typeof __webpack_require__ === "function" ? __non_webpack_require__ : __require;
|
|
55708
55708
|
var vars = process.config && process.config.variables || {};
|
|
55709
55709
|
var prebuildsOnly = !!process.env.PREBUILDS_ONLY;
|
|
55710
|
-
var
|
|
55710
|
+
var abi29 = process.versions.modules;
|
|
55711
55711
|
var runtime = isElectron() ? "electron" : isNwjs() ? "node-webkit" : "node";
|
|
55712
55712
|
var arch = process.env.npm_config_arch || os2.arch();
|
|
55713
55713
|
var platform = process.env.npm_config_platform || os2.platform();
|
|
@@ -55739,7 +55739,7 @@ var require_node_gyp_build = __commonJS({
|
|
|
55739
55739
|
"platform=" + platform,
|
|
55740
55740
|
"arch=" + arch,
|
|
55741
55741
|
"runtime=" + runtime,
|
|
55742
|
-
"abi=" +
|
|
55742
|
+
"abi=" + abi29,
|
|
55743
55743
|
"uv=" + uv,
|
|
55744
55744
|
armv ? "armv=" + armv : "",
|
|
55745
55745
|
"libc=" + libc,
|
|
@@ -55755,7 +55755,7 @@ var require_node_gyp_build = __commonJS({
|
|
|
55755
55755
|
if (!tuple2) return;
|
|
55756
55756
|
var prebuilds = path12.join(dir2, "prebuilds", tuple2.name);
|
|
55757
55757
|
var parsed = readdirSync(prebuilds).map(parseTags);
|
|
55758
|
-
var candidates = parsed.filter(matchTags(runtime,
|
|
55758
|
+
var candidates = parsed.filter(matchTags(runtime, abi29));
|
|
55759
55759
|
var winner = candidates.sort(compareTags(runtime))[0];
|
|
55760
55760
|
if (winner) return path12.join(prebuilds, winner.file);
|
|
55761
55761
|
}
|
|
@@ -55820,11 +55820,11 @@ var require_node_gyp_build = __commonJS({
|
|
|
55820
55820
|
}
|
|
55821
55821
|
return tags;
|
|
55822
55822
|
}
|
|
55823
|
-
function matchTags(runtime2,
|
|
55823
|
+
function matchTags(runtime2, abi30) {
|
|
55824
55824
|
return function(tags) {
|
|
55825
55825
|
if (tags == null) return false;
|
|
55826
55826
|
if (tags.runtime && tags.runtime !== runtime2 && !runtimeAgnostic(tags)) return false;
|
|
55827
|
-
if (tags.abi && tags.abi !==
|
|
55827
|
+
if (tags.abi && tags.abi !== abi30 && !tags.napi) return false;
|
|
55828
55828
|
if (tags.uv && tags.uv !== uv) return false;
|
|
55829
55829
|
if (tags.armv && tags.armv !== armv) return false;
|
|
55830
55830
|
if (tags.libc && tags.libc !== libc) return false;
|
|
@@ -118127,17 +118127,17 @@ var require_interface2 = __commonJS({
|
|
|
118127
118127
|
* Create a new Interface for the %%fragments%%.
|
|
118128
118128
|
*/
|
|
118129
118129
|
constructor(fragments) {
|
|
118130
|
-
let
|
|
118130
|
+
let abi29 = [];
|
|
118131
118131
|
if (typeof fragments === "string") {
|
|
118132
|
-
|
|
118132
|
+
abi29 = JSON.parse(fragments);
|
|
118133
118133
|
} else {
|
|
118134
|
-
|
|
118134
|
+
abi29 = fragments;
|
|
118135
118135
|
}
|
|
118136
118136
|
this.#functions = /* @__PURE__ */ new Map();
|
|
118137
118137
|
this.#errors = /* @__PURE__ */ new Map();
|
|
118138
118138
|
this.#events = /* @__PURE__ */ new Map();
|
|
118139
118139
|
const frags = [];
|
|
118140
|
-
for (const a of
|
|
118140
|
+
for (const a of abi29) {
|
|
118141
118141
|
try {
|
|
118142
118142
|
frags.push(fragments_js_1.Fragment.from(a));
|
|
118143
118143
|
} catch (error45) {
|
|
@@ -118201,16 +118201,16 @@ var require_interface2 = __commonJS({
|
|
|
118201
118201
|
*/
|
|
118202
118202
|
format(minimal) {
|
|
118203
118203
|
const format2 = minimal ? "minimal" : "full";
|
|
118204
|
-
const
|
|
118205
|
-
return
|
|
118204
|
+
const abi29 = this.fragments.map((f) => f.format(format2));
|
|
118205
|
+
return abi29;
|
|
118206
118206
|
}
|
|
118207
118207
|
/**
|
|
118208
118208
|
* Return the JSON-encoded ABI. This is the format Solidiy
|
|
118209
118209
|
* returns.
|
|
118210
118210
|
*/
|
|
118211
118211
|
formatJson() {
|
|
118212
|
-
const
|
|
118213
|
-
return JSON.stringify(
|
|
118212
|
+
const abi29 = this.fragments.map((f) => f.format("json"));
|
|
118213
|
+
return JSON.stringify(abi29.map((j) => JSON.parse(j)));
|
|
118214
118214
|
}
|
|
118215
118215
|
/**
|
|
118216
118216
|
* The ABI coder that will be used to encode and decode binary
|
|
@@ -120978,12 +120978,12 @@ var require_contract = __commonJS({
|
|
|
120978
120978
|
* optionally connected to a %%runner%% to perform operations on behalf
|
|
120979
120979
|
* of.
|
|
120980
120980
|
*/
|
|
120981
|
-
constructor(target,
|
|
120981
|
+
constructor(target, abi29, runner, _deployTx) {
|
|
120982
120982
|
(0, index_js_3.assertArgument)(typeof target === "string" || (0, index_js_2.isAddressable)(target), "invalid value for Contract target", "target", target);
|
|
120983
120983
|
if (runner == null) {
|
|
120984
120984
|
runner = null;
|
|
120985
120985
|
}
|
|
120986
|
-
const iface = index_js_1.Interface.from(
|
|
120986
|
+
const iface = index_js_1.Interface.from(abi29);
|
|
120987
120987
|
(0, index_js_3.defineProperties)(this, { target, runner, interface: iface });
|
|
120988
120988
|
Object.defineProperty(this, internal, { value: {} });
|
|
120989
120989
|
let addrPromise;
|
|
@@ -121346,10 +121346,10 @@ var require_contract = __commonJS({
|
|
|
121346
121346
|
/**
|
|
121347
121347
|
* Create a new Class for the %%abi%%.
|
|
121348
121348
|
*/
|
|
121349
|
-
static buildClass(
|
|
121349
|
+
static buildClass(abi29) {
|
|
121350
121350
|
class CustomContract extends _BaseContract {
|
|
121351
121351
|
constructor(address, runner = null) {
|
|
121352
|
-
super(address,
|
|
121352
|
+
super(address, abi29, runner);
|
|
121353
121353
|
}
|
|
121354
121354
|
}
|
|
121355
121355
|
return CustomContract;
|
|
@@ -121357,11 +121357,11 @@ var require_contract = __commonJS({
|
|
|
121357
121357
|
/**
|
|
121358
121358
|
* Create a new BaseContract with a specified Interface.
|
|
121359
121359
|
*/
|
|
121360
|
-
static from(target,
|
|
121360
|
+
static from(target, abi29, runner) {
|
|
121361
121361
|
if (runner == null) {
|
|
121362
121362
|
runner = null;
|
|
121363
121363
|
}
|
|
121364
|
-
const contract = new this(target,
|
|
121364
|
+
const contract = new this(target, abi29, runner);
|
|
121365
121365
|
return contract;
|
|
121366
121366
|
}
|
|
121367
121367
|
};
|
|
@@ -121405,8 +121405,8 @@ var require_factory = __commonJS({
|
|
|
121405
121405
|
* The %%bytecode%% may be the ``bytecode`` property within the
|
|
121406
121406
|
* standard Solidity JSON output.
|
|
121407
121407
|
*/
|
|
121408
|
-
constructor(
|
|
121409
|
-
const iface = index_js_1.Interface.from(
|
|
121408
|
+
constructor(abi29, bytecode, runner) {
|
|
121409
|
+
const iface = index_js_1.Interface.from(abi29);
|
|
121410
121410
|
if (bytecode instanceof Uint8Array) {
|
|
121411
121411
|
bytecode = (0, index_js_3.hexlify)((0, index_js_3.getBytes)(bytecode));
|
|
121412
121412
|
} else {
|
|
@@ -121476,14 +121476,14 @@ var require_factory = __commonJS({
|
|
|
121476
121476
|
if (typeof output === "string") {
|
|
121477
121477
|
output = JSON.parse(output);
|
|
121478
121478
|
}
|
|
121479
|
-
const
|
|
121479
|
+
const abi29 = output.abi;
|
|
121480
121480
|
let bytecode = "";
|
|
121481
121481
|
if (output.bytecode) {
|
|
121482
121482
|
bytecode = output.bytecode;
|
|
121483
121483
|
} else if (output.evm && output.evm.bytecode) {
|
|
121484
121484
|
bytecode = output.evm.bytecode;
|
|
121485
121485
|
}
|
|
121486
|
-
return new this(
|
|
121486
|
+
return new this(abi29, bytecode, runner);
|
|
121487
121487
|
}
|
|
121488
121488
|
};
|
|
121489
121489
|
exports2.ContractFactory = ContractFactory;
|
|
@@ -126411,8 +126411,8 @@ var require_provider_etherscan = __commonJS({
|
|
|
126411
126411
|
action: "getabi",
|
|
126412
126412
|
address
|
|
126413
126413
|
});
|
|
126414
|
-
const
|
|
126415
|
-
return new index_js_2.Contract(address,
|
|
126414
|
+
const abi29 = JSON.parse(resp);
|
|
126415
|
+
return new index_js_2.Contract(address, abi29, this);
|
|
126416
126416
|
} catch (error45) {
|
|
126417
126417
|
return null;
|
|
126418
126418
|
}
|
|
@@ -152176,9 +152176,9 @@ var require_node_gyp_build_optional_packages = __commonJS({
|
|
|
152176
152176
|
var vars = process.config && process.config.variables || {};
|
|
152177
152177
|
var prebuildsOnly = !!process.env.PREBUILDS_ONLY;
|
|
152178
152178
|
var versions = process.versions;
|
|
152179
|
-
var
|
|
152179
|
+
var abi29 = versions.modules;
|
|
152180
152180
|
if (versions.deno || process.isBun) {
|
|
152181
|
-
|
|
152181
|
+
abi29 = "unsupported";
|
|
152182
152182
|
}
|
|
152183
152183
|
var runtime = isElectron() ? "electron" : "node";
|
|
152184
152184
|
var arch = process.arch;
|
|
@@ -152225,7 +152225,7 @@ var require_node_gyp_build_optional_packages = __commonJS({
|
|
|
152225
152225
|
"platform=" + platform,
|
|
152226
152226
|
"arch=" + arch,
|
|
152227
152227
|
"runtime=" + runtime,
|
|
152228
|
-
"abi=" +
|
|
152228
|
+
"abi=" + abi29,
|
|
152229
152229
|
"uv=" + uv,
|
|
152230
152230
|
armv ? "armv=" + armv : "",
|
|
152231
152231
|
"libc=" + libc,
|
|
@@ -152243,7 +152243,7 @@ var require_node_gyp_build_optional_packages = __commonJS({
|
|
|
152243
152243
|
}
|
|
152244
152244
|
function resolveFile(prebuilds) {
|
|
152245
152245
|
var parsed = readdirSync(prebuilds).map(parseTags);
|
|
152246
|
-
var candidates = parsed.filter(matchTags(runtime,
|
|
152246
|
+
var candidates = parsed.filter(matchTags(runtime, abi29));
|
|
152247
152247
|
var winner = candidates.sort(compareTags(runtime))[0];
|
|
152248
152248
|
if (winner) return path12.join(prebuilds, winner.file);
|
|
152249
152249
|
}
|
|
@@ -152308,11 +152308,11 @@ var require_node_gyp_build_optional_packages = __commonJS({
|
|
|
152308
152308
|
}
|
|
152309
152309
|
return tags;
|
|
152310
152310
|
}
|
|
152311
|
-
function matchTags(runtime2,
|
|
152311
|
+
function matchTags(runtime2, abi30) {
|
|
152312
152312
|
return function(tags) {
|
|
152313
152313
|
if (tags == null) return false;
|
|
152314
152314
|
if (tags.runtime !== runtime2 && !runtimeAgnostic(tags)) return false;
|
|
152315
|
-
if (tags.abi !==
|
|
152315
|
+
if (tags.abi !== abi30 && !tags.napi) return false;
|
|
152316
152316
|
if (tags.uv && tags.uv !== uv) return false;
|
|
152317
152317
|
if (tags.armv && tags.armv !== armv) return false;
|
|
152318
152318
|
if (tags.libc && tags.libc !== libc) return false;
|
|
@@ -158337,11 +158337,11 @@ var require_formatAbi = __commonJS({
|
|
|
158337
158337
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
158338
158338
|
exports2.formatAbi = formatAbi;
|
|
158339
158339
|
var formatAbiItem_js_1 = require_formatAbiItem();
|
|
158340
|
-
function formatAbi(
|
|
158340
|
+
function formatAbi(abi29) {
|
|
158341
158341
|
const signatures = [];
|
|
158342
|
-
const length =
|
|
158342
|
+
const length = abi29.length;
|
|
158343
158343
|
for (let i = 0; i < length; i++) {
|
|
158344
|
-
const abiItem =
|
|
158344
|
+
const abiItem = abi29[i];
|
|
158345
158345
|
const signature = (0, formatAbiItem_js_1.formatAbiItem)(abiItem);
|
|
158346
158346
|
signatures.push(signature);
|
|
158347
158347
|
}
|
|
@@ -159106,15 +159106,15 @@ var require_parseAbi = __commonJS({
|
|
|
159106
159106
|
var utils_js_1 = require_utils13();
|
|
159107
159107
|
function parseAbi2(signatures) {
|
|
159108
159108
|
const structs = (0, structs_js_1.parseStructs)(signatures);
|
|
159109
|
-
const
|
|
159109
|
+
const abi29 = [];
|
|
159110
159110
|
const length = signatures.length;
|
|
159111
159111
|
for (let i = 0; i < length; i++) {
|
|
159112
159112
|
const signature = signatures[i];
|
|
159113
159113
|
if ((0, signatures_js_1.isStructSignature)(signature))
|
|
159114
159114
|
continue;
|
|
159115
|
-
|
|
159115
|
+
abi29.push((0, utils_js_1.parseSignature)(signature, structs));
|
|
159116
159116
|
}
|
|
159117
|
-
return
|
|
159117
|
+
return abi29;
|
|
159118
159118
|
}
|
|
159119
159119
|
}
|
|
159120
159120
|
});
|
|
@@ -168926,9 +168926,9 @@ var require_getAbiItem = __commonJS({
|
|
|
168926
168926
|
var toEventSelector_js_1 = require_toEventSelector();
|
|
168927
168927
|
var toFunctionSelector_js_1 = require_toFunctionSelector();
|
|
168928
168928
|
function getAbiItem2(parameters) {
|
|
168929
|
-
const { abi:
|
|
168929
|
+
const { abi: abi29, args = [], name } = parameters;
|
|
168930
168930
|
const isSelector = (0, isHex_js_1.isHex)(name, { strict: false });
|
|
168931
|
-
const abiItems =
|
|
168931
|
+
const abiItems = abi29.filter((abiItem) => {
|
|
168932
168932
|
if (isSelector) {
|
|
168933
168933
|
if (abiItem.type === "function")
|
|
168934
168934
|
return (0, toFunctionSelector_js_1.toFunctionSelector)(abiItem) === name;
|
|
@@ -169053,10 +169053,10 @@ var require_encodeEventTopics = __commonJS({
|
|
|
169053
169053
|
var getAbiItem_js_1 = require_getAbiItem();
|
|
169054
169054
|
var docsPath8 = "/docs/contract/encodeEventTopics";
|
|
169055
169055
|
function encodeEventTopics2(parameters) {
|
|
169056
|
-
const { abi:
|
|
169057
|
-
let abiItem =
|
|
169056
|
+
const { abi: abi29, eventName, args } = parameters;
|
|
169057
|
+
let abiItem = abi29[0];
|
|
169058
169058
|
if (eventName) {
|
|
169059
|
-
const item = (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
169059
|
+
const item = (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, name: eventName });
|
|
169060
169060
|
if (!item)
|
|
169061
169061
|
throw new abi_js_1.AbiEventNotFoundError(eventName, { docsPath: docsPath8 });
|
|
169062
169062
|
abiItem = item;
|
|
@@ -169117,12 +169117,12 @@ var require_createContractEventFilter = __commonJS({
|
|
|
169117
169117
|
var toHex_js_1 = require_toHex();
|
|
169118
169118
|
var createFilterRequestScope_js_1 = require_createFilterRequestScope();
|
|
169119
169119
|
async function createContractEventFilter2(client, parameters) {
|
|
169120
|
-
const { address, abi:
|
|
169120
|
+
const { address, abi: abi29, args, eventName, fromBlock, strict, toBlock } = parameters;
|
|
169121
169121
|
const getRequest = (0, createFilterRequestScope_js_1.createFilterRequestScope)(client, {
|
|
169122
169122
|
method: "eth_newFilter"
|
|
169123
169123
|
});
|
|
169124
169124
|
const topics = eventName ? (0, encodeEventTopics_js_1.encodeEventTopics)({
|
|
169125
|
-
abi:
|
|
169125
|
+
abi: abi29,
|
|
169126
169126
|
args,
|
|
169127
169127
|
eventName
|
|
169128
169128
|
}) : void 0;
|
|
@@ -169138,7 +169138,7 @@ var require_createContractEventFilter = __commonJS({
|
|
|
169138
169138
|
]
|
|
169139
169139
|
});
|
|
169140
169140
|
return {
|
|
169141
|
-
abi:
|
|
169141
|
+
abi: abi29,
|
|
169142
169142
|
args,
|
|
169143
169143
|
eventName,
|
|
169144
169144
|
id,
|
|
@@ -169176,11 +169176,11 @@ var require_prepareEncodeFunctionData = __commonJS({
|
|
|
169176
169176
|
var getAbiItem_js_1 = require_getAbiItem();
|
|
169177
169177
|
var docsPath8 = "/docs/contract/encodeFunctionData";
|
|
169178
169178
|
function prepareEncodeFunctionData2(parameters) {
|
|
169179
|
-
const { abi:
|
|
169180
|
-
let abiItem =
|
|
169179
|
+
const { abi: abi29, args, functionName } = parameters;
|
|
169180
|
+
let abiItem = abi29[0];
|
|
169181
169181
|
if (functionName) {
|
|
169182
169182
|
const item = (0, getAbiItem_js_1.getAbiItem)({
|
|
169183
|
-
abi:
|
|
169183
|
+
abi: abi29,
|
|
169184
169184
|
args,
|
|
169185
169185
|
name: functionName
|
|
169186
169186
|
});
|
|
@@ -169209,12 +169209,12 @@ var require_encodeFunctionData = __commonJS({
|
|
|
169209
169209
|
var prepareEncodeFunctionData_js_1 = require_prepareEncodeFunctionData();
|
|
169210
169210
|
function encodeFunctionData2(parameters) {
|
|
169211
169211
|
const { args } = parameters;
|
|
169212
|
-
const { abi:
|
|
169212
|
+
const { abi: abi29, functionName } = (() => {
|
|
169213
169213
|
if (parameters.abi.length === 1 && parameters.functionName?.startsWith("0x"))
|
|
169214
169214
|
return parameters;
|
|
169215
169215
|
return (0, prepareEncodeFunctionData_js_1.prepareEncodeFunctionData)(parameters);
|
|
169216
169216
|
})();
|
|
169217
|
-
const abiItem =
|
|
169217
|
+
const abiItem = abi29[0];
|
|
169218
169218
|
const signature = functionName;
|
|
169219
169219
|
const data = "inputs" in abiItem && abiItem.inputs ? (0, encodeAbiParameters_js_1.encodeAbiParameters)(abiItem.inputs, args ?? []) : void 0;
|
|
169220
169220
|
return (0, concat_js_1.concatHex)([signature, data ?? "0x"]);
|
|
@@ -169746,11 +169746,11 @@ var require_decodeErrorResult = __commonJS({
|
|
|
169746
169746
|
var decodeAbiParameters_js_1 = require_decodeAbiParameters();
|
|
169747
169747
|
var formatAbiItem_js_1 = require_formatAbiItem2();
|
|
169748
169748
|
function decodeErrorResult2(parameters) {
|
|
169749
|
-
const { abi:
|
|
169749
|
+
const { abi: abi29, data } = parameters;
|
|
169750
169750
|
const signature = (0, slice_js_1.slice)(data, 0, 4);
|
|
169751
169751
|
if (signature === "0x")
|
|
169752
169752
|
throw new abi_js_1.AbiDecodingZeroDataError();
|
|
169753
|
-
const abi_ = [...
|
|
169753
|
+
const abi_ = [...abi29 || [], solidity_js_1.solidityError, solidity_js_1.solidityPanic];
|
|
169754
169754
|
const abiItem = abi_.find((x) => x.type === "error" && signature === (0, toFunctionSelector_js_1.toFunctionSelector)((0, formatAbiItem_js_1.formatAbiItem)(x)));
|
|
169755
169755
|
if (!abiItem)
|
|
169756
169756
|
throw new abi_js_1.AbiErrorSignatureNotFoundError(signature, {
|
|
@@ -170172,8 +170172,8 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
170172
170172
|
};
|
|
170173
170173
|
exports2.CallExecutionError = CallExecutionError2;
|
|
170174
170174
|
var ContractFunctionExecutionError2 = class extends base_js_1.BaseError {
|
|
170175
|
-
constructor(cause, { abi:
|
|
170176
|
-
const abiItem = (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
170175
|
+
constructor(cause, { abi: abi29, args, contractAddress, docsPath: docsPath8, functionName, sender }) {
|
|
170176
|
+
const abiItem = (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, args, name: functionName });
|
|
170177
170177
|
const formattedArgs = abiItem ? (0, formatAbiItemWithArgs_js_1.formatAbiItemWithArgs)({
|
|
170178
170178
|
abiItem,
|
|
170179
170179
|
args,
|
|
@@ -170239,7 +170239,7 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
170239
170239
|
writable: true,
|
|
170240
170240
|
value: void 0
|
|
170241
170241
|
});
|
|
170242
|
-
this.abi =
|
|
170242
|
+
this.abi = abi29;
|
|
170243
170243
|
this.args = args;
|
|
170244
170244
|
this.cause = cause;
|
|
170245
170245
|
this.contractAddress = contractAddress;
|
|
@@ -170249,14 +170249,14 @@ ${(0, stateOverride_js_1.prettyStateOverride)(stateOverride)}`;
|
|
|
170249
170249
|
};
|
|
170250
170250
|
exports2.ContractFunctionExecutionError = ContractFunctionExecutionError2;
|
|
170251
170251
|
var ContractFunctionRevertedError2 = class extends base_js_1.BaseError {
|
|
170252
|
-
constructor({ abi:
|
|
170252
|
+
constructor({ abi: abi29, data, functionName, message: message2 }) {
|
|
170253
170253
|
let cause;
|
|
170254
170254
|
let decodedData;
|
|
170255
170255
|
let metaMessages;
|
|
170256
170256
|
let reason;
|
|
170257
170257
|
if (data && data !== "0x") {
|
|
170258
170258
|
try {
|
|
170259
|
-
decodedData = (0, decodeErrorResult_js_1.decodeErrorResult)({ abi:
|
|
170259
|
+
decodedData = (0, decodeErrorResult_js_1.decodeErrorResult)({ abi: abi29, data });
|
|
170260
170260
|
const { abiItem, errorName, args: errorArgs } = decodedData;
|
|
170261
170261
|
if (errorName === "Error") {
|
|
170262
170262
|
reason = errorArgs[0];
|
|
@@ -170968,7 +170968,7 @@ var require_getContractError = __commonJS({
|
|
|
170968
170968
|
var request_js_1 = require_request();
|
|
170969
170969
|
var rpc_js_1 = require_rpc();
|
|
170970
170970
|
var EXECUTION_REVERTED_ERROR_CODE2 = 3;
|
|
170971
|
-
function getContractError2(err, { abi:
|
|
170971
|
+
function getContractError2(err, { abi: abi29, address, args, docsPath: docsPath8, functionName, sender }) {
|
|
170972
170972
|
const error45 = err instanceof contract_js_1.RawContractError ? err : err instanceof base_js_1.BaseError ? err.walk((err2) => "data" in err2) || err.walk() : {};
|
|
170973
170973
|
const { code, data, details, message: message2, shortMessage } = error45;
|
|
170974
170974
|
const cause = (() => {
|
|
@@ -170976,7 +170976,7 @@ var require_getContractError = __commonJS({
|
|
|
170976
170976
|
return new contract_js_1.ContractFunctionZeroDataError({ functionName });
|
|
170977
170977
|
if ([EXECUTION_REVERTED_ERROR_CODE2, rpc_js_1.InternalRpcError.code].includes(code) && (data || details || message2 || shortMessage)) {
|
|
170978
170978
|
return new contract_js_1.ContractFunctionRevertedError({
|
|
170979
|
-
abi:
|
|
170979
|
+
abi: abi29,
|
|
170980
170980
|
data: typeof data === "object" ? data.data : data,
|
|
170981
170981
|
functionName,
|
|
170982
170982
|
message: error45 instanceof request_js_1.RpcRequestError ? details : shortMessage ?? message2
|
|
@@ -170985,7 +170985,7 @@ var require_getContractError = __commonJS({
|
|
|
170985
170985
|
return err;
|
|
170986
170986
|
})();
|
|
170987
170987
|
return new contract_js_1.ContractFunctionExecutionError(cause, {
|
|
170988
|
-
abi:
|
|
170988
|
+
abi: abi29,
|
|
170989
170989
|
args,
|
|
170990
170990
|
contractAddress: address,
|
|
170991
170991
|
docsPath: docsPath8,
|
|
@@ -175861,9 +175861,9 @@ var require_estimateContractGas = __commonJS({
|
|
|
175861
175861
|
var getAction_js_1 = require_getAction();
|
|
175862
175862
|
var estimateGas_js_1 = require_estimateGas2();
|
|
175863
175863
|
async function estimateContractGas2(client, parameters) {
|
|
175864
|
-
const { abi:
|
|
175864
|
+
const { abi: abi29, address, args, functionName, dataSuffix, ...request } = parameters;
|
|
175865
175865
|
const data = (0, encodeFunctionData_js_1.encodeFunctionData)({
|
|
175866
|
-
abi:
|
|
175866
|
+
abi: abi29,
|
|
175867
175867
|
args,
|
|
175868
175868
|
functionName
|
|
175869
175869
|
});
|
|
@@ -175877,7 +175877,7 @@ var require_estimateContractGas = __commonJS({
|
|
|
175877
175877
|
} catch (error45) {
|
|
175878
175878
|
const account = request.account ? (0, parseAccount_js_1.parseAccount)(request.account) : void 0;
|
|
175879
175879
|
throw (0, getContractError_js_1.getContractError)(error45, {
|
|
175880
|
-
abi:
|
|
175880
|
+
abi: abi29,
|
|
175881
175881
|
address,
|
|
175882
175882
|
args,
|
|
175883
175883
|
docsPath: "/docs/contract/estimateContractGas",
|
|
@@ -175921,12 +175921,12 @@ var require_decodeEventLog = __commonJS({
|
|
|
175921
175921
|
var formatAbiItem_js_1 = require_formatAbiItem2();
|
|
175922
175922
|
var docsPath8 = "/docs/contract/decodeEventLog";
|
|
175923
175923
|
function decodeEventLog2(parameters) {
|
|
175924
|
-
const { abi:
|
|
175924
|
+
const { abi: abi29, data, strict: strict_, topics } = parameters;
|
|
175925
175925
|
const strict = strict_ ?? true;
|
|
175926
175926
|
const [signature, ...argTopics] = topics;
|
|
175927
175927
|
if (!signature)
|
|
175928
175928
|
throw new abi_js_1.AbiEventSignatureEmptyTopicsError({ docsPath: docsPath8 });
|
|
175929
|
-
const abiItem =
|
|
175929
|
+
const abiItem = abi29.find((x) => x.type === "event" && signature === (0, toEventSelector_js_1.toEventSelector)((0, formatAbiItem_js_1.formatAbiItem)(x)));
|
|
175930
175930
|
if (!(abiItem && "name" in abiItem) || abiItem.type !== "event")
|
|
175931
175931
|
throw new abi_js_1.AbiEventSignatureNotFoundError(signature, { docsPath: docsPath8 });
|
|
175932
175932
|
const { name, inputs } = abiItem;
|
|
@@ -176007,7 +176007,7 @@ var require_parseEventLogs = __commonJS({
|
|
|
176007
176007
|
var toEventSelector_js_1 = require_toEventSelector();
|
|
176008
176008
|
var decodeEventLog_js_1 = require_decodeEventLog();
|
|
176009
176009
|
function parseEventLogs2(parameters) {
|
|
176010
|
-
const { abi:
|
|
176010
|
+
const { abi: abi29, args, logs, strict = true } = parameters;
|
|
176011
176011
|
const eventName = (() => {
|
|
176012
176012
|
if (!parameters.eventName)
|
|
176013
176013
|
return void 0;
|
|
@@ -176017,7 +176017,7 @@ var require_parseEventLogs = __commonJS({
|
|
|
176017
176017
|
})();
|
|
176018
176018
|
return logs.map((log2) => {
|
|
176019
176019
|
try {
|
|
176020
|
-
const abiItem =
|
|
176020
|
+
const abiItem = abi29.find((abiItem2) => abiItem2.type === "event" && log2.topics[0] === (0, toEventSelector_js_1.toEventSelector)(abiItem2));
|
|
176021
176021
|
if (!abiItem)
|
|
176022
176022
|
return null;
|
|
176023
176023
|
const event = (0, decodeEventLog_js_1.decodeEventLog)({
|
|
@@ -176178,9 +176178,9 @@ var require_getContractEvents = __commonJS({
|
|
|
176178
176178
|
var getAction_js_1 = require_getAction();
|
|
176179
176179
|
var getLogs_js_1 = require_getLogs();
|
|
176180
176180
|
async function getContractEvents2(client, parameters) {
|
|
176181
|
-
const { abi:
|
|
176182
|
-
const event = eventName ? (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
176183
|
-
const events = !event ?
|
|
176181
|
+
const { abi: abi29, address, args, blockHash, eventName, fromBlock, toBlock, strict } = parameters;
|
|
176182
|
+
const event = eventName ? (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, name: eventName }) : void 0;
|
|
176183
|
+
const events = !event ? abi29.filter((x) => x.type === "event") : void 0;
|
|
176184
176184
|
return (0, getAction_js_1.getAction)(client, getLogs_js_1.getLogs, "getLogs")({
|
|
176185
176185
|
address,
|
|
176186
176186
|
args,
|
|
@@ -176206,10 +176206,10 @@ var require_decodeFunctionResult = __commonJS({
|
|
|
176206
176206
|
var getAbiItem_js_1 = require_getAbiItem();
|
|
176207
176207
|
var docsPath8 = "/docs/contract/decodeFunctionResult";
|
|
176208
176208
|
function decodeFunctionResult2(parameters) {
|
|
176209
|
-
const { abi:
|
|
176210
|
-
let abiItem =
|
|
176209
|
+
const { abi: abi29, args, functionName, data } = parameters;
|
|
176210
|
+
let abiItem = abi29[0];
|
|
176211
176211
|
if (functionName) {
|
|
176212
|
-
const item = (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
176212
|
+
const item = (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, args, name: functionName });
|
|
176213
176213
|
if (!item)
|
|
176214
176214
|
throw new abi_js_1.AbiFunctionNotFoundError(functionName, { docsPath: docsPath8 });
|
|
176215
176215
|
abiItem = item;
|
|
@@ -179256,10 +179256,10 @@ var require_encodeDeployData = __commonJS({
|
|
|
179256
179256
|
var encodeAbiParameters_js_1 = require_encodeAbiParameters();
|
|
179257
179257
|
var docsPath8 = "/docs/contract/encodeDeployData";
|
|
179258
179258
|
function encodeDeployData2(parameters) {
|
|
179259
|
-
const { abi:
|
|
179259
|
+
const { abi: abi29, args, bytecode } = parameters;
|
|
179260
179260
|
if (!args || args.length === 0)
|
|
179261
179261
|
return bytecode;
|
|
179262
|
-
const description =
|
|
179262
|
+
const description = abi29.find((x) => "type" in x && x.type === "constructor");
|
|
179263
179263
|
if (!description)
|
|
179264
179264
|
throw new abi_js_1.AbiConstructorNotFoundError({ docsPath: docsPath8 });
|
|
179265
179265
|
if (!("inputs" in description))
|
|
@@ -179466,9 +179466,9 @@ var require_decodeFunctionData = __commonJS({
|
|
|
179466
179466
|
var decodeAbiParameters_js_1 = require_decodeAbiParameters();
|
|
179467
179467
|
var formatAbiItem_js_1 = require_formatAbiItem2();
|
|
179468
179468
|
function decodeFunctionData2(parameters) {
|
|
179469
|
-
const { abi:
|
|
179469
|
+
const { abi: abi29, data } = parameters;
|
|
179470
179470
|
const signature = (0, slice_js_1.slice)(data, 0, 4);
|
|
179471
|
-
const description =
|
|
179471
|
+
const description = abi29.find((x) => x.type === "function" && signature === (0, toFunctionSelector_js_1.toFunctionSelector)((0, formatAbiItem_js_1.formatAbiItem)(x)));
|
|
179472
179472
|
if (!description)
|
|
179473
179473
|
throw new abi_js_1.AbiFunctionSignatureNotFoundError(signature, {
|
|
179474
179474
|
docsPath: "/docs/contract/decodeFunctionData"
|
|
@@ -179495,10 +179495,10 @@ var require_encodeErrorResult = __commonJS({
|
|
|
179495
179495
|
var getAbiItem_js_1 = require_getAbiItem();
|
|
179496
179496
|
var docsPath8 = "/docs/contract/encodeErrorResult";
|
|
179497
179497
|
function encodeErrorResult2(parameters) {
|
|
179498
|
-
const { abi:
|
|
179499
|
-
let abiItem =
|
|
179498
|
+
const { abi: abi29, errorName, args } = parameters;
|
|
179499
|
+
let abiItem = abi29[0];
|
|
179500
179500
|
if (errorName) {
|
|
179501
|
-
const item = (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
179501
|
+
const item = (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, args, name: errorName });
|
|
179502
179502
|
if (!item)
|
|
179503
179503
|
throw new abi_js_1.AbiErrorNotFoundError(errorName, { docsPath: docsPath8 });
|
|
179504
179504
|
abiItem = item;
|
|
@@ -179529,10 +179529,10 @@ var require_encodeFunctionResult = __commonJS({
|
|
|
179529
179529
|
var getAbiItem_js_1 = require_getAbiItem();
|
|
179530
179530
|
var docsPath8 = "/docs/contract/encodeFunctionResult";
|
|
179531
179531
|
function encodeFunctionResult2(parameters) {
|
|
179532
|
-
const { abi:
|
|
179533
|
-
let abiItem =
|
|
179532
|
+
const { abi: abi29, functionName, result } = parameters;
|
|
179533
|
+
let abiItem = abi29[0];
|
|
179534
179534
|
if (functionName) {
|
|
179535
|
-
const item = (0, getAbiItem_js_1.getAbiItem)({ abi:
|
|
179535
|
+
const item = (0, getAbiItem_js_1.getAbiItem)({ abi: abi29, name: functionName });
|
|
179536
179536
|
if (!item)
|
|
179537
179537
|
throw new abi_js_1.AbiFunctionNotFoundError(functionName, { docsPath: docsPath8 });
|
|
179538
179538
|
abiItem = item;
|
|
@@ -179972,9 +179972,9 @@ var require_readContract = __commonJS({
|
|
|
179972
179972
|
var getAction_js_1 = require_getAction();
|
|
179973
179973
|
var call_js_1 = require_call();
|
|
179974
179974
|
async function readContract2(client, parameters) {
|
|
179975
|
-
const { abi:
|
|
179975
|
+
const { abi: abi29, address, args, functionName, ...rest } = parameters;
|
|
179976
179976
|
const calldata = (0, encodeFunctionData_js_1.encodeFunctionData)({
|
|
179977
|
-
abi:
|
|
179977
|
+
abi: abi29,
|
|
179978
179978
|
args,
|
|
179979
179979
|
functionName
|
|
179980
179980
|
});
|
|
@@ -179985,14 +179985,14 @@ var require_readContract = __commonJS({
|
|
|
179985
179985
|
to: address
|
|
179986
179986
|
});
|
|
179987
179987
|
return (0, decodeFunctionResult_js_1.decodeFunctionResult)({
|
|
179988
|
-
abi:
|
|
179988
|
+
abi: abi29,
|
|
179989
179989
|
args,
|
|
179990
179990
|
functionName,
|
|
179991
179991
|
data: data || "0x"
|
|
179992
179992
|
});
|
|
179993
179993
|
} catch (error45) {
|
|
179994
179994
|
throw (0, getContractError_js_1.getContractError)(error45, {
|
|
179995
|
-
abi:
|
|
179995
|
+
abi: abi29,
|
|
179996
179996
|
address,
|
|
179997
179997
|
args,
|
|
179998
179998
|
docsPath: "/docs/contract/readContract",
|
|
@@ -180016,9 +180016,9 @@ var require_simulateContract = __commonJS({
|
|
|
180016
180016
|
var getAction_js_1 = require_getAction();
|
|
180017
180017
|
var call_js_1 = require_call();
|
|
180018
180018
|
async function simulateContract2(client, parameters) {
|
|
180019
|
-
const { abi:
|
|
180019
|
+
const { abi: abi29, address, args, dataSuffix, functionName, ...callRequest } = parameters;
|
|
180020
180020
|
const account = callRequest.account ? (0, parseAccount_js_1.parseAccount)(callRequest.account) : client.account;
|
|
180021
|
-
const calldata = (0, encodeFunctionData_js_1.encodeFunctionData)({ abi:
|
|
180021
|
+
const calldata = (0, encodeFunctionData_js_1.encodeFunctionData)({ abi: abi29, args, functionName });
|
|
180022
180022
|
try {
|
|
180023
180023
|
const { data } = await (0, getAction_js_1.getAction)(client, call_js_1.call, "call")({
|
|
180024
180024
|
batch: false,
|
|
@@ -180028,12 +180028,12 @@ var require_simulateContract = __commonJS({
|
|
|
180028
180028
|
account
|
|
180029
180029
|
});
|
|
180030
180030
|
const result = (0, decodeFunctionResult_js_1.decodeFunctionResult)({
|
|
180031
|
-
abi:
|
|
180031
|
+
abi: abi29,
|
|
180032
180032
|
args,
|
|
180033
180033
|
functionName,
|
|
180034
180034
|
data: data || "0x"
|
|
180035
180035
|
});
|
|
180036
|
-
const minimizedAbi =
|
|
180036
|
+
const minimizedAbi = abi29.filter((abiItem) => "name" in abiItem && abiItem.name === parameters.functionName);
|
|
180037
180037
|
return {
|
|
180038
180038
|
result,
|
|
180039
180039
|
request: {
|
|
@@ -180048,7 +180048,7 @@ var require_simulateContract = __commonJS({
|
|
|
180048
180048
|
};
|
|
180049
180049
|
} catch (error45) {
|
|
180050
180050
|
throw (0, getContractError_js_1.getContractError)(error45, {
|
|
180051
|
-
abi:
|
|
180051
|
+
abi: abi29,
|
|
180052
180052
|
address,
|
|
180053
180053
|
args,
|
|
180054
180054
|
docsPath: "/docs/contract/simulateContract",
|
|
@@ -180294,7 +180294,7 @@ var require_watchContractEvent = __commonJS({
|
|
|
180294
180294
|
var getFilterChanges_js_1 = require_getFilterChanges();
|
|
180295
180295
|
var uninstallFilter_js_1 = require_uninstallFilter();
|
|
180296
180296
|
function watchContractEvent2(client, parameters) {
|
|
180297
|
-
const { abi:
|
|
180297
|
+
const { abi: abi29, address, args, batch = true, eventName, fromBlock, onError, onLogs, poll: poll_, pollingInterval = client.pollingInterval, strict: strict_ } = parameters;
|
|
180298
180298
|
const enablePolling = (() => {
|
|
180299
180299
|
if (typeof poll_ !== "undefined")
|
|
180300
180300
|
return poll_;
|
|
@@ -180329,7 +180329,7 @@ var require_watchContractEvent = __commonJS({
|
|
|
180329
180329
|
if (!initialized) {
|
|
180330
180330
|
try {
|
|
180331
180331
|
filter = await (0, getAction_js_1.getAction)(client, createContractEventFilter_js_1.createContractEventFilter, "createContractEventFilter")({
|
|
180332
|
-
abi:
|
|
180332
|
+
abi: abi29,
|
|
180333
180333
|
address,
|
|
180334
180334
|
args,
|
|
180335
180335
|
eventName,
|
|
@@ -180349,7 +180349,7 @@ var require_watchContractEvent = __commonJS({
|
|
|
180349
180349
|
const blockNumber = await (0, getAction_js_1.getAction)(client, getBlockNumber_js_1.getBlockNumber, "getBlockNumber")({});
|
|
180350
180350
|
if (previousBlockNumber && previousBlockNumber < blockNumber) {
|
|
180351
180351
|
logs = await (0, getAction_js_1.getAction)(client, getContractEvents_js_1.getContractEvents, "getContractEvents")({
|
|
180352
|
-
abi:
|
|
180352
|
+
abi: abi29,
|
|
180353
180353
|
address,
|
|
180354
180354
|
args,
|
|
180355
180355
|
eventName,
|
|
@@ -180413,7 +180413,7 @@ var require_watchContractEvent = __commonJS({
|
|
|
180413
180413
|
return client.transport;
|
|
180414
180414
|
})();
|
|
180415
180415
|
const topics = eventName ? (0, encodeEventTopics_js_1.encodeEventTopics)({
|
|
180416
|
-
abi:
|
|
180416
|
+
abi: abi29,
|
|
180417
180417
|
eventName,
|
|
180418
180418
|
args
|
|
180419
180419
|
}) : [];
|
|
@@ -180425,7 +180425,7 @@ var require_watchContractEvent = __commonJS({
|
|
|
180425
180425
|
const log2 = data.result;
|
|
180426
180426
|
try {
|
|
180427
180427
|
const { eventName: eventName2, args: args2 } = (0, decodeEventLog_js_1.decodeEventLog)({
|
|
180428
|
-
abi:
|
|
180428
|
+
abi: abi29,
|
|
180429
180429
|
data: log2.data,
|
|
180430
180430
|
topics: log2.topics,
|
|
180431
180431
|
strict: strict_
|
|
@@ -180727,14 +180727,14 @@ var require_writeContract = __commonJS({
|
|
|
180727
180727
|
var getAction_js_1 = require_getAction();
|
|
180728
180728
|
var sendTransaction_js_1 = require_sendTransaction();
|
|
180729
180729
|
async function writeContract2(client, parameters) {
|
|
180730
|
-
const { abi:
|
|
180730
|
+
const { abi: abi29, account: account_ = client.account, address, args, dataSuffix, functionName, ...request } = parameters;
|
|
180731
180731
|
if (typeof account_ === "undefined")
|
|
180732
180732
|
throw new account_js_1.AccountNotFoundError({
|
|
180733
180733
|
docsPath: "/docs/contract/writeContract"
|
|
180734
180734
|
});
|
|
180735
180735
|
const account = account_ ? (0, parseAccount_js_1.parseAccount)(account_) : null;
|
|
180736
180736
|
const data = (0, encodeFunctionData_js_1.encodeFunctionData)({
|
|
180737
|
-
abi:
|
|
180737
|
+
abi: abi29,
|
|
180738
180738
|
args,
|
|
180739
180739
|
functionName
|
|
180740
180740
|
});
|
|
@@ -180747,7 +180747,7 @@ var require_writeContract = __commonJS({
|
|
|
180747
180747
|
});
|
|
180748
180748
|
} catch (error45) {
|
|
180749
180749
|
throw (0, getContractError_js_1.getContractError)(error45, {
|
|
180750
|
-
abi:
|
|
180750
|
+
abi: abi29,
|
|
180751
180751
|
address,
|
|
180752
180752
|
args,
|
|
180753
180753
|
docsPath: "/docs/contract/writeContract",
|
|
@@ -180775,7 +180775,7 @@ var require_getContract = __commonJS({
|
|
|
180775
180775
|
var simulateContract_js_1 = require_simulateContract();
|
|
180776
180776
|
var watchContractEvent_js_1 = require_watchContractEvent();
|
|
180777
180777
|
var writeContract_js_1 = require_writeContract();
|
|
180778
|
-
function getContract2({ abi:
|
|
180778
|
+
function getContract2({ abi: abi29, address, client: client_ }) {
|
|
180779
180779
|
const client = client_;
|
|
180780
180780
|
const [publicClient, walletClient] = (() => {
|
|
180781
180781
|
if (!client)
|
|
@@ -180794,7 +180794,7 @@ var require_getContract = __commonJS({
|
|
|
180794
180794
|
let hasReadFunction = false;
|
|
180795
180795
|
let hasWriteFunction = false;
|
|
180796
180796
|
let hasEvent = false;
|
|
180797
|
-
for (const item of
|
|
180797
|
+
for (const item of abi29) {
|
|
180798
180798
|
if (item.type === "function")
|
|
180799
180799
|
if (item.stateMutability === "view" || item.stateMutability === "pure")
|
|
180800
180800
|
hasReadFunction = true;
|
|
@@ -180812,7 +180812,7 @@ var require_getContract = __commonJS({
|
|
|
180812
180812
|
return (...parameters) => {
|
|
180813
180813
|
const { args, options } = getFunctionParameters2(parameters);
|
|
180814
180814
|
return (0, getAction_js_1.getAction)(publicClient, readContract_js_1.readContract, "readContract")({
|
|
180815
|
-
abi:
|
|
180815
|
+
abi: abi29,
|
|
180816
180816
|
address,
|
|
180817
180817
|
functionName,
|
|
180818
180818
|
args,
|
|
@@ -180827,7 +180827,7 @@ var require_getContract = __commonJS({
|
|
|
180827
180827
|
return (...parameters) => {
|
|
180828
180828
|
const { args, options } = getFunctionParameters2(parameters);
|
|
180829
180829
|
return (0, getAction_js_1.getAction)(publicClient, simulateContract_js_1.simulateContract, "simulateContract")({
|
|
180830
|
-
abi:
|
|
180830
|
+
abi: abi29,
|
|
180831
180831
|
address,
|
|
180832
180832
|
functionName,
|
|
180833
180833
|
args,
|
|
@@ -180840,10 +180840,10 @@ var require_getContract = __commonJS({
|
|
|
180840
180840
|
contract.createEventFilter = new Proxy({}, {
|
|
180841
180841
|
get(_, eventName) {
|
|
180842
180842
|
return (...parameters) => {
|
|
180843
|
-
const abiEvent =
|
|
180843
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
180844
180844
|
const { args, options } = getEventParameters2(parameters, abiEvent);
|
|
180845
180845
|
return (0, getAction_js_1.getAction)(publicClient, createContractEventFilter_js_1.createContractEventFilter, "createContractEventFilter")({
|
|
180846
|
-
abi:
|
|
180846
|
+
abi: abi29,
|
|
180847
180847
|
address,
|
|
180848
180848
|
eventName,
|
|
180849
180849
|
args,
|
|
@@ -180855,10 +180855,10 @@ var require_getContract = __commonJS({
|
|
|
180855
180855
|
contract.getEvents = new Proxy({}, {
|
|
180856
180856
|
get(_, eventName) {
|
|
180857
180857
|
return (...parameters) => {
|
|
180858
|
-
const abiEvent =
|
|
180858
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
180859
180859
|
const { args, options } = getEventParameters2(parameters, abiEvent);
|
|
180860
180860
|
return (0, getAction_js_1.getAction)(publicClient, getContractEvents_js_1.getContractEvents, "getContractEvents")({
|
|
180861
|
-
abi:
|
|
180861
|
+
abi: abi29,
|
|
180862
180862
|
address,
|
|
180863
180863
|
eventName,
|
|
180864
180864
|
args,
|
|
@@ -180870,10 +180870,10 @@ var require_getContract = __commonJS({
|
|
|
180870
180870
|
contract.watchEvent = new Proxy({}, {
|
|
180871
180871
|
get(_, eventName) {
|
|
180872
180872
|
return (...parameters) => {
|
|
180873
|
-
const abiEvent =
|
|
180873
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
180874
180874
|
const { args, options } = getEventParameters2(parameters, abiEvent);
|
|
180875
180875
|
return (0, getAction_js_1.getAction)(publicClient, watchContractEvent_js_1.watchContractEvent, "watchContractEvent")({
|
|
180876
|
-
abi:
|
|
180876
|
+
abi: abi29,
|
|
180877
180877
|
address,
|
|
180878
180878
|
eventName,
|
|
180879
180879
|
args,
|
|
@@ -180891,7 +180891,7 @@ var require_getContract = __commonJS({
|
|
|
180891
180891
|
return (...parameters) => {
|
|
180892
180892
|
const { args, options } = getFunctionParameters2(parameters);
|
|
180893
180893
|
return (0, getAction_js_1.getAction)(walletClient, writeContract_js_1.writeContract, "writeContract")({
|
|
180894
|
-
abi:
|
|
180894
|
+
abi: abi29,
|
|
180895
180895
|
address,
|
|
180896
180896
|
functionName,
|
|
180897
180897
|
args,
|
|
@@ -180909,7 +180909,7 @@ var require_getContract = __commonJS({
|
|
|
180909
180909
|
const { args, options } = getFunctionParameters2(parameters);
|
|
180910
180910
|
const client2 = publicClient ?? walletClient;
|
|
180911
180911
|
return (0, getAction_js_1.getAction)(client2, estimateContractGas_js_1.estimateContractGas, "estimateContractGas")({
|
|
180912
|
-
abi:
|
|
180912
|
+
abi: abi29,
|
|
180913
180913
|
address,
|
|
180914
180914
|
functionName,
|
|
180915
180915
|
args,
|
|
@@ -180921,7 +180921,7 @@ var require_getContract = __commonJS({
|
|
|
180921
180921
|
});
|
|
180922
180922
|
}
|
|
180923
180923
|
contract.address = address;
|
|
180924
|
-
contract.abi =
|
|
180924
|
+
contract.abi = abi29;
|
|
180925
180925
|
return contract;
|
|
180926
180926
|
}
|
|
180927
180927
|
function getFunctionParameters2(values) {
|
|
@@ -182314,7 +182314,7 @@ var require_getEip712Domain = __commonJS({
|
|
|
182314
182314
|
const { address, factory, factoryData } = parameters;
|
|
182315
182315
|
try {
|
|
182316
182316
|
const [fields, name, version5, chainId, verifyingContract, salt, extensions] = await (0, getAction_js_1.getAction)(client, readContract_js_1.readContract, "readContract")({
|
|
182317
|
-
abi:
|
|
182317
|
+
abi: abi29,
|
|
182318
182318
|
address,
|
|
182319
182319
|
functionName: "eip712Domain",
|
|
182320
182320
|
factory,
|
|
@@ -182339,7 +182339,7 @@ var require_getEip712Domain = __commonJS({
|
|
|
182339
182339
|
throw error45;
|
|
182340
182340
|
}
|
|
182341
182341
|
}
|
|
182342
|
-
var
|
|
182342
|
+
var abi29 = [
|
|
182343
182343
|
{
|
|
182344
182344
|
inputs: [],
|
|
182345
182345
|
name: "eip712Domain",
|
|
@@ -191659,9 +191659,9 @@ var require_multicall2 = __commonJS({
|
|
|
191659
191659
|
let currentChunk = 0;
|
|
191660
191660
|
let currentChunkSize = 0;
|
|
191661
191661
|
for (let i = 0; i < contracts2.length; i++) {
|
|
191662
|
-
const { abi:
|
|
191662
|
+
const { abi: abi29, address, args, functionName } = contracts2[i];
|
|
191663
191663
|
try {
|
|
191664
|
-
const callData = (0, encodeFunctionData_js_1.encodeFunctionData)({ abi:
|
|
191664
|
+
const callData = (0, encodeFunctionData_js_1.encodeFunctionData)({ abi: abi29, args, functionName });
|
|
191665
191665
|
currentChunkSize += (callData.length - 2) / 2;
|
|
191666
191666
|
if (batchSize > 0 && currentChunkSize > batchSize && chunkedCalls[currentChunk].length > 0) {
|
|
191667
191667
|
currentChunk++;
|
|
@@ -191678,7 +191678,7 @@ var require_multicall2 = __commonJS({
|
|
|
191678
191678
|
];
|
|
191679
191679
|
} catch (err) {
|
|
191680
191680
|
const error45 = (0, getContractError_js_1.getContractError)(err, {
|
|
191681
|
-
abi:
|
|
191681
|
+
abi: abi29,
|
|
191682
191682
|
address,
|
|
191683
191683
|
args,
|
|
191684
191684
|
docsPath: "/docs/contract/multicall",
|
|
@@ -191728,14 +191728,14 @@ var require_multicall2 = __commonJS({
|
|
|
191728
191728
|
for (let j = 0; j < aggregate3Result.length; j++) {
|
|
191729
191729
|
const { returnData, success: success2 } = aggregate3Result[j];
|
|
191730
191730
|
const { callData } = chunkedCalls[i][j];
|
|
191731
|
-
const { abi:
|
|
191731
|
+
const { abi: abi29, address, functionName, args } = contracts2[results.length];
|
|
191732
191732
|
try {
|
|
191733
191733
|
if (callData === "0x")
|
|
191734
191734
|
throw new abi_js_1.AbiDecodingZeroDataError();
|
|
191735
191735
|
if (!success2)
|
|
191736
191736
|
throw new contract_js_1.RawContractError({ data: returnData });
|
|
191737
191737
|
const result2 = (0, decodeFunctionResult_js_1.decodeFunctionResult)({
|
|
191738
|
-
abi:
|
|
191738
|
+
abi: abi29,
|
|
191739
191739
|
args,
|
|
191740
191740
|
data: returnData,
|
|
191741
191741
|
functionName
|
|
@@ -191743,7 +191743,7 @@ var require_multicall2 = __commonJS({
|
|
|
191743
191743
|
results.push(allowFailure ? { result: result2, status: "success" } : result2);
|
|
191744
191744
|
} catch (err) {
|
|
191745
191745
|
const error45 = (0, getContractError_js_1.getContractError)(err, {
|
|
191746
|
-
abi:
|
|
191746
|
+
abi: abi29,
|
|
191747
191747
|
address,
|
|
191748
191748
|
args,
|
|
191749
191749
|
docsPath: "/docs/contract/multicall",
|
|
@@ -191821,13 +191821,13 @@ var require_simulateBlocks = __commonJS({
|
|
|
191821
191821
|
return result.map((block2, i) => ({
|
|
191822
191822
|
...(0, block_js_1.formatBlock)(block2),
|
|
191823
191823
|
calls: block2.calls.map((call2, j) => {
|
|
191824
|
-
const { abi:
|
|
191824
|
+
const { abi: abi29, args, functionName, to } = blocks[i].calls[j];
|
|
191825
191825
|
const data = call2.error?.data ?? call2.returnData;
|
|
191826
191826
|
const gasUsed = BigInt(call2.gasUsed);
|
|
191827
191827
|
const logs = call2.logs?.map((log2) => (0, log_js_1.formatLog)(log2));
|
|
191828
191828
|
const status = call2.status === "0x1" ? "success" : "failure";
|
|
191829
|
-
const result2 =
|
|
191830
|
-
abi:
|
|
191829
|
+
const result2 = abi29 && status === "success" && data !== "0x" ? (0, decodeFunctionResult_js_1.decodeFunctionResult)({
|
|
191830
|
+
abi: abi29,
|
|
191831
191831
|
data,
|
|
191832
191832
|
functionName
|
|
191833
191833
|
}) : null;
|
|
@@ -191842,7 +191842,7 @@ var require_simulateBlocks = __commonJS({
|
|
|
191842
191842
|
if (!error46)
|
|
191843
191843
|
return void 0;
|
|
191844
191844
|
return (0, getContractError_js_1.getContractError)(error46, {
|
|
191845
|
-
abi:
|
|
191845
|
+
abi: abi29 ?? [],
|
|
191846
191846
|
address: to ?? "0x",
|
|
191847
191847
|
args,
|
|
191848
191848
|
functionName: functionName ?? "<unknown>"
|
|
@@ -192017,10 +192017,10 @@ var require_AbiItem = __commonJS({
|
|
|
192017
192017
|
...prepare ? { hash: getSignatureHash2(item) } : {}
|
|
192018
192018
|
};
|
|
192019
192019
|
}
|
|
192020
|
-
function fromAbi3(
|
|
192020
|
+
function fromAbi3(abi29, name, options) {
|
|
192021
192021
|
const { args = [], prepare = true } = options ?? {};
|
|
192022
192022
|
const isSelector = Hex.validate(name, { strict: false });
|
|
192023
|
-
const abiItems =
|
|
192023
|
+
const abiItems = abi29.filter((abiItem2) => {
|
|
192024
192024
|
if (isSelector) {
|
|
192025
192025
|
if (abiItem2.type === "function" || abiItem2.type === "error")
|
|
192026
192026
|
return getSelector3(abiItem2) === Hex.slice(name, 0, 4);
|
|
@@ -192190,8 +192190,8 @@ var require_AbiConstructor = __commonJS({
|
|
|
192190
192190
|
function from14(abiConstructor) {
|
|
192191
192191
|
return AbiItem.from(abiConstructor);
|
|
192192
192192
|
}
|
|
192193
|
-
function fromAbi3(
|
|
192194
|
-
const item =
|
|
192193
|
+
function fromAbi3(abi29) {
|
|
192194
|
+
const item = abi29.find((item2) => item2.type === "constructor");
|
|
192195
192195
|
if (!item)
|
|
192196
192196
|
throw new AbiItem.NotFoundError({ name: "constructor" });
|
|
192197
192197
|
return item;
|
|
@@ -192266,8 +192266,8 @@ var require_AbiFunction = __commonJS({
|
|
|
192266
192266
|
function from14(abiFunction, options = {}) {
|
|
192267
192267
|
return AbiItem.from(abiFunction, options);
|
|
192268
192268
|
}
|
|
192269
|
-
function fromAbi3(
|
|
192270
|
-
const item = AbiItem.fromAbi(
|
|
192269
|
+
function fromAbi3(abi29, name, options) {
|
|
192270
|
+
const item = AbiItem.fromAbi(abi29, name, options);
|
|
192271
192271
|
if (item.type !== "function")
|
|
192272
192272
|
throw new AbiItem.NotFoundError({ name, type: "function" });
|
|
192273
192273
|
return item;
|
|
@@ -194411,8 +194411,8 @@ var require_deployContract = __commonJS({
|
|
|
194411
194411
|
var encodeDeployData_js_1 = require_encodeDeployData();
|
|
194412
194412
|
var sendTransaction_js_1 = require_sendTransaction();
|
|
194413
194413
|
function deployContract2(walletClient, parameters) {
|
|
194414
|
-
const { abi:
|
|
194415
|
-
const calldata = (0, encodeDeployData_js_1.encodeDeployData)({ abi:
|
|
194414
|
+
const { abi: abi29, args, bytecode, ...request } = parameters;
|
|
194415
|
+
const calldata = (0, encodeDeployData_js_1.encodeDeployData)({ abi: abi29, args, bytecode });
|
|
194416
194416
|
return (0, sendTransaction_js_1.sendTransaction)(walletClient, {
|
|
194417
194417
|
...request,
|
|
194418
194418
|
...request.authorizationList ? { to: null } : {},
|
|
@@ -195259,10 +195259,10 @@ var require_decodeDeployData = __commonJS({
|
|
|
195259
195259
|
var decodeAbiParameters_js_1 = require_decodeAbiParameters();
|
|
195260
195260
|
var docsPath8 = "/docs/contract/decodeDeployData";
|
|
195261
195261
|
function decodeDeployData(parameters) {
|
|
195262
|
-
const { abi:
|
|
195262
|
+
const { abi: abi29, bytecode, data } = parameters;
|
|
195263
195263
|
if (data === bytecode)
|
|
195264
195264
|
return { bytecode };
|
|
195265
|
-
const description =
|
|
195265
|
+
const description = abi29.find((x) => "type" in x && x.type === "constructor");
|
|
195266
195266
|
if (!description)
|
|
195267
195267
|
throw new abi_js_1.AbiConstructorNotFoundError({ docsPath: docsPath8 });
|
|
195268
195268
|
if (!("inputs" in description))
|
|
@@ -249192,21 +249192,21 @@ var require_BaseContract2 = __commonJS({
|
|
|
249192
249192
|
return this.contractAddress;
|
|
249193
249193
|
};
|
|
249194
249194
|
this.encode = (functionToEncode, args) => {
|
|
249195
|
-
const
|
|
249195
|
+
const abi29 = this.contractAbi;
|
|
249196
249196
|
const functionName = functionToEncode;
|
|
249197
249197
|
const params = args;
|
|
249198
249198
|
return (0, viem_1.encodeFunctionData)({
|
|
249199
|
-
abi:
|
|
249199
|
+
abi: abi29,
|
|
249200
249200
|
functionName,
|
|
249201
249201
|
args: params
|
|
249202
249202
|
});
|
|
249203
249203
|
};
|
|
249204
249204
|
this.estimateGas = async (functionToEstimate, args, options = {}) => {
|
|
249205
249205
|
const contractOptions = this.convertOptions(options);
|
|
249206
|
-
const
|
|
249206
|
+
const abi29 = this.contractAbi;
|
|
249207
249207
|
const params = args;
|
|
249208
249208
|
return (0, actions_1.estimateContractGas)(this.runner, {
|
|
249209
|
-
abi:
|
|
249209
|
+
abi: abi29,
|
|
249210
249210
|
functionName: functionToEstimate,
|
|
249211
249211
|
address: this.getAddress(),
|
|
249212
249212
|
args: params,
|
|
@@ -299210,17 +299210,17 @@ var require_interface3 = __commonJS({
|
|
|
299210
299210
|
* Create a new Interface for the %%fragments%%.
|
|
299211
299211
|
*/
|
|
299212
299212
|
constructor(fragments) {
|
|
299213
|
-
let
|
|
299213
|
+
let abi29 = [];
|
|
299214
299214
|
if (typeof fragments === "string") {
|
|
299215
|
-
|
|
299215
|
+
abi29 = JSON.parse(fragments);
|
|
299216
299216
|
} else {
|
|
299217
|
-
|
|
299217
|
+
abi29 = fragments;
|
|
299218
299218
|
}
|
|
299219
299219
|
this.#functions = /* @__PURE__ */ new Map();
|
|
299220
299220
|
this.#errors = /* @__PURE__ */ new Map();
|
|
299221
299221
|
this.#events = /* @__PURE__ */ new Map();
|
|
299222
299222
|
const frags = [];
|
|
299223
|
-
for (const a of
|
|
299223
|
+
for (const a of abi29) {
|
|
299224
299224
|
try {
|
|
299225
299225
|
frags.push(fragments_js_1.Fragment.from(a));
|
|
299226
299226
|
} catch (error45) {
|
|
@@ -299284,16 +299284,16 @@ var require_interface3 = __commonJS({
|
|
|
299284
299284
|
*/
|
|
299285
299285
|
format(minimal) {
|
|
299286
299286
|
const format2 = minimal ? "minimal" : "full";
|
|
299287
|
-
const
|
|
299288
|
-
return
|
|
299287
|
+
const abi29 = this.fragments.map((f) => f.format(format2));
|
|
299288
|
+
return abi29;
|
|
299289
299289
|
}
|
|
299290
299290
|
/**
|
|
299291
299291
|
* Return the JSON-encoded ABI. This is the format Solidiy
|
|
299292
299292
|
* returns.
|
|
299293
299293
|
*/
|
|
299294
299294
|
formatJson() {
|
|
299295
|
-
const
|
|
299296
|
-
return JSON.stringify(
|
|
299295
|
+
const abi29 = this.fragments.map((f) => f.format("json"));
|
|
299296
|
+
return JSON.stringify(abi29.map((j) => JSON.parse(j)));
|
|
299297
299297
|
}
|
|
299298
299298
|
/**
|
|
299299
299299
|
* The ABI coder that will be used to encode and decode binary
|
|
@@ -302061,12 +302061,12 @@ var require_contract5 = __commonJS({
|
|
|
302061
302061
|
* optionally connected to a %%runner%% to perform operations on behalf
|
|
302062
302062
|
* of.
|
|
302063
302063
|
*/
|
|
302064
|
-
constructor(target,
|
|
302064
|
+
constructor(target, abi29, runner, _deployTx) {
|
|
302065
302065
|
(0, index_js_3.assertArgument)(typeof target === "string" || (0, index_js_2.isAddressable)(target), "invalid value for Contract target", "target", target);
|
|
302066
302066
|
if (runner == null) {
|
|
302067
302067
|
runner = null;
|
|
302068
302068
|
}
|
|
302069
|
-
const iface = index_js_1.Interface.from(
|
|
302069
|
+
const iface = index_js_1.Interface.from(abi29);
|
|
302070
302070
|
(0, index_js_3.defineProperties)(this, { target, runner, interface: iface });
|
|
302071
302071
|
Object.defineProperty(this, internal, { value: {} });
|
|
302072
302072
|
let addrPromise;
|
|
@@ -302429,10 +302429,10 @@ var require_contract5 = __commonJS({
|
|
|
302429
302429
|
/**
|
|
302430
302430
|
* Create a new Class for the %%abi%%.
|
|
302431
302431
|
*/
|
|
302432
|
-
static buildClass(
|
|
302432
|
+
static buildClass(abi29) {
|
|
302433
302433
|
class CustomContract extends _BaseContract {
|
|
302434
302434
|
constructor(address, runner = null) {
|
|
302435
|
-
super(address,
|
|
302435
|
+
super(address, abi29, runner);
|
|
302436
302436
|
}
|
|
302437
302437
|
}
|
|
302438
302438
|
return CustomContract;
|
|
@@ -302440,11 +302440,11 @@ var require_contract5 = __commonJS({
|
|
|
302440
302440
|
/**
|
|
302441
302441
|
* Create a new BaseContract with a specified Interface.
|
|
302442
302442
|
*/
|
|
302443
|
-
static from(target,
|
|
302443
|
+
static from(target, abi29, runner) {
|
|
302444
302444
|
if (runner == null) {
|
|
302445
302445
|
runner = null;
|
|
302446
302446
|
}
|
|
302447
|
-
const contract = new this(target,
|
|
302447
|
+
const contract = new this(target, abi29, runner);
|
|
302448
302448
|
return contract;
|
|
302449
302449
|
}
|
|
302450
302450
|
};
|
|
@@ -302488,8 +302488,8 @@ var require_factory2 = __commonJS({
|
|
|
302488
302488
|
* The %%bytecode%% may be the ``bytecode`` property within the
|
|
302489
302489
|
* standard Solidity JSON output.
|
|
302490
302490
|
*/
|
|
302491
|
-
constructor(
|
|
302492
|
-
const iface = index_js_1.Interface.from(
|
|
302491
|
+
constructor(abi29, bytecode, runner) {
|
|
302492
|
+
const iface = index_js_1.Interface.from(abi29);
|
|
302493
302493
|
if (bytecode instanceof Uint8Array) {
|
|
302494
302494
|
bytecode = (0, index_js_3.hexlify)((0, index_js_3.getBytes)(bytecode));
|
|
302495
302495
|
} else {
|
|
@@ -302559,14 +302559,14 @@ var require_factory2 = __commonJS({
|
|
|
302559
302559
|
if (typeof output === "string") {
|
|
302560
302560
|
output = JSON.parse(output);
|
|
302561
302561
|
}
|
|
302562
|
-
const
|
|
302562
|
+
const abi29 = output.abi;
|
|
302563
302563
|
let bytecode = "";
|
|
302564
302564
|
if (output.bytecode) {
|
|
302565
302565
|
bytecode = output.bytecode;
|
|
302566
302566
|
} else if (output.evm && output.evm.bytecode) {
|
|
302567
302567
|
bytecode = output.evm.bytecode;
|
|
302568
302568
|
}
|
|
302569
|
-
return new this(
|
|
302569
|
+
return new this(abi29, bytecode, runner);
|
|
302570
302570
|
}
|
|
302571
302571
|
};
|
|
302572
302572
|
exports2.ContractFactory = ContractFactory;
|
|
@@ -307516,8 +307516,8 @@ var require_provider_etherscan2 = __commonJS({
|
|
|
307516
307516
|
action: "getabi",
|
|
307517
307517
|
address
|
|
307518
307518
|
});
|
|
307519
|
-
const
|
|
307520
|
-
return new index_js_2.Contract(address,
|
|
307519
|
+
const abi29 = JSON.parse(resp);
|
|
307520
|
+
return new index_js_2.Contract(address, abi29, this);
|
|
307521
307521
|
} catch (error45) {
|
|
307522
307522
|
return null;
|
|
307523
307523
|
}
|
|
@@ -334204,13 +334204,13 @@ var require_interface4 = __commonJS({
|
|
|
334204
334204
|
function Interface2(fragments) {
|
|
334205
334205
|
var _newTarget = this.constructor;
|
|
334206
334206
|
var _this = this;
|
|
334207
|
-
var
|
|
334207
|
+
var abi29 = [];
|
|
334208
334208
|
if (typeof fragments === "string") {
|
|
334209
|
-
|
|
334209
|
+
abi29 = JSON.parse(fragments);
|
|
334210
334210
|
} else {
|
|
334211
|
-
|
|
334211
|
+
abi29 = fragments;
|
|
334212
334212
|
}
|
|
334213
|
-
(0, properties_1.defineReadOnly)(this, "fragments",
|
|
334213
|
+
(0, properties_1.defineReadOnly)(this, "fragments", abi29.map(function(fragment) {
|
|
334214
334214
|
return fragments_1.Fragment.from(fragment);
|
|
334215
334215
|
}).filter(function(fragment) {
|
|
334216
334216
|
return fragment != null;
|
|
@@ -334264,15 +334264,15 @@ var require_interface4 = __commonJS({
|
|
|
334264
334264
|
if (format2 === fragments_1.FormatTypes.sighash) {
|
|
334265
334265
|
logger2.throwArgumentError("interface does not support formatting sighash", "format", format2);
|
|
334266
334266
|
}
|
|
334267
|
-
var
|
|
334267
|
+
var abi29 = this.fragments.map(function(fragment) {
|
|
334268
334268
|
return fragment.format(format2);
|
|
334269
334269
|
});
|
|
334270
334270
|
if (format2 === fragments_1.FormatTypes.json) {
|
|
334271
|
-
return JSON.stringify(
|
|
334271
|
+
return JSON.stringify(abi29.map(function(j) {
|
|
334272
334272
|
return JSON.parse(j);
|
|
334273
334273
|
}));
|
|
334274
334274
|
}
|
|
334275
|
-
return
|
|
334275
|
+
return abi29;
|
|
334276
334276
|
};
|
|
334277
334277
|
Interface2.getAbiCoder = function() {
|
|
334278
334278
|
return abi_coder_1.defaultAbiCoder;
|
|
@@ -366344,10 +366344,10 @@ init_formatAbiItem2();
|
|
|
366344
366344
|
init_getAbiItem();
|
|
366345
366345
|
var docsPath = "/docs/contract/encodeEventTopics";
|
|
366346
366346
|
function encodeEventTopics(parameters) {
|
|
366347
|
-
const { abi:
|
|
366348
|
-
let abiItem =
|
|
366347
|
+
const { abi: abi29, eventName, args } = parameters;
|
|
366348
|
+
let abiItem = abi29[0];
|
|
366349
366349
|
if (eventName) {
|
|
366350
|
-
const item = getAbiItem({ abi:
|
|
366350
|
+
const item = getAbiItem({ abi: abi29, name: eventName });
|
|
366351
366351
|
if (!item)
|
|
366352
366352
|
throw new AbiEventNotFoundError(eventName, { docsPath });
|
|
366353
366353
|
abiItem = item;
|
|
@@ -366394,12 +366394,12 @@ function createFilterRequestScope(client, { method }) {
|
|
|
366394
366394
|
|
|
366395
366395
|
// ../../node_modules/viem/_esm/actions/public/createContractEventFilter.js
|
|
366396
366396
|
async function createContractEventFilter(client, parameters) {
|
|
366397
|
-
const { address, abi:
|
|
366397
|
+
const { address, abi: abi29, args, eventName, fromBlock, strict, toBlock } = parameters;
|
|
366398
366398
|
const getRequest = createFilterRequestScope(client, {
|
|
366399
366399
|
method: "eth_newFilter"
|
|
366400
366400
|
});
|
|
366401
366401
|
const topics = eventName ? encodeEventTopics({
|
|
366402
|
-
abi:
|
|
366402
|
+
abi: abi29,
|
|
366403
366403
|
args,
|
|
366404
366404
|
eventName
|
|
366405
366405
|
}) : void 0;
|
|
@@ -366415,7 +366415,7 @@ async function createContractEventFilter(client, parameters) {
|
|
|
366415
366415
|
]
|
|
366416
366416
|
});
|
|
366417
366417
|
return {
|
|
366418
|
-
abi:
|
|
366418
|
+
abi: abi29,
|
|
366419
366419
|
args,
|
|
366420
366420
|
eventName,
|
|
366421
366421
|
id,
|
|
@@ -366436,7 +366436,7 @@ init_contract();
|
|
|
366436
366436
|
init_request();
|
|
366437
366437
|
init_rpc();
|
|
366438
366438
|
var EXECUTION_REVERTED_ERROR_CODE = 3;
|
|
366439
|
-
function getContractError(err, { abi:
|
|
366439
|
+
function getContractError(err, { abi: abi29, address, args, docsPath: docsPath8, functionName, sender }) {
|
|
366440
366440
|
const error45 = err instanceof RawContractError ? err : err instanceof BaseError2 ? err.walk((err2) => "data" in err2) || err.walk() : {};
|
|
366441
366441
|
const { code, data, details, message: message2, shortMessage } = error45;
|
|
366442
366442
|
const cause = (() => {
|
|
@@ -366444,7 +366444,7 @@ function getContractError(err, { abi: abi27, address, args, docsPath: docsPath8,
|
|
|
366444
366444
|
return new ContractFunctionZeroDataError({ functionName });
|
|
366445
366445
|
if ([EXECUTION_REVERTED_ERROR_CODE, InternalRpcError.code].includes(code) && (data || details || message2 || shortMessage)) {
|
|
366446
366446
|
return new ContractFunctionRevertedError({
|
|
366447
|
-
abi:
|
|
366447
|
+
abi: abi29,
|
|
366448
366448
|
data: typeof data === "object" ? data.data : data,
|
|
366449
366449
|
functionName,
|
|
366450
366450
|
message: error45 instanceof RpcRequestError ? details : shortMessage ?? message2
|
|
@@ -366453,7 +366453,7 @@ function getContractError(err, { abi: abi27, address, args, docsPath: docsPath8,
|
|
|
366453
366453
|
return err;
|
|
366454
366454
|
})();
|
|
366455
366455
|
return new ContractFunctionExecutionError(cause, {
|
|
366456
|
-
abi:
|
|
366456
|
+
abi: abi29,
|
|
366457
366457
|
args,
|
|
366458
366458
|
contractAddress: address,
|
|
366459
366459
|
docsPath: docsPath8,
|
|
@@ -367421,9 +367421,9 @@ async function estimateGas(client, args) {
|
|
|
367421
367421
|
|
|
367422
367422
|
// ../../node_modules/viem/_esm/actions/public/estimateContractGas.js
|
|
367423
367423
|
async function estimateContractGas(client, parameters) {
|
|
367424
|
-
const { abi:
|
|
367424
|
+
const { abi: abi29, address, args, functionName, dataSuffix, ...request } = parameters;
|
|
367425
367425
|
const data = encodeFunctionData({
|
|
367426
|
-
abi:
|
|
367426
|
+
abi: abi29,
|
|
367427
367427
|
args,
|
|
367428
367428
|
functionName
|
|
367429
367429
|
});
|
|
@@ -367437,7 +367437,7 @@ async function estimateContractGas(client, parameters) {
|
|
|
367437
367437
|
} catch (error45) {
|
|
367438
367438
|
const account = request.account ? parseAccount(request.account) : void 0;
|
|
367439
367439
|
throw getContractError(error45, {
|
|
367440
|
-
abi:
|
|
367440
|
+
abi: abi29,
|
|
367441
367441
|
address,
|
|
367442
367442
|
args,
|
|
367443
367443
|
docsPath: "/docs/contract/estimateContractGas",
|
|
@@ -367466,12 +367466,12 @@ init_decodeAbiParameters();
|
|
|
367466
367466
|
init_formatAbiItem2();
|
|
367467
367467
|
var docsPath3 = "/docs/contract/decodeEventLog";
|
|
367468
367468
|
function decodeEventLog(parameters) {
|
|
367469
|
-
const { abi:
|
|
367469
|
+
const { abi: abi29, data, strict: strict_, topics } = parameters;
|
|
367470
367470
|
const strict = strict_ ?? true;
|
|
367471
367471
|
const [signature, ...argTopics] = topics;
|
|
367472
367472
|
if (!signature)
|
|
367473
367473
|
throw new AbiEventSignatureEmptyTopicsError({ docsPath: docsPath3 });
|
|
367474
|
-
const abiItem =
|
|
367474
|
+
const abiItem = abi29.find((x) => x.type === "event" && signature === toEventSelector(formatAbiItem2(x)));
|
|
367475
367475
|
if (!(abiItem && "name" in abiItem) || abiItem.type !== "event")
|
|
367476
367476
|
throw new AbiEventSignatureNotFoundError(signature, { docsPath: docsPath3 });
|
|
367477
367477
|
const { name, inputs } = abiItem;
|
|
@@ -367539,7 +367539,7 @@ function decodeTopic({ param, value }) {
|
|
|
367539
367539
|
|
|
367540
367540
|
// ../../node_modules/viem/_esm/utils/abi/parseEventLogs.js
|
|
367541
367541
|
function parseEventLogs(parameters) {
|
|
367542
|
-
const { abi:
|
|
367542
|
+
const { abi: abi29, args, logs, strict = true } = parameters;
|
|
367543
367543
|
const eventName = (() => {
|
|
367544
367544
|
if (!parameters.eventName)
|
|
367545
367545
|
return void 0;
|
|
@@ -367549,7 +367549,7 @@ function parseEventLogs(parameters) {
|
|
|
367549
367549
|
})();
|
|
367550
367550
|
return logs.map((log2) => {
|
|
367551
367551
|
try {
|
|
367552
|
-
const abiItem =
|
|
367552
|
+
const abiItem = abi29.find((abiItem2) => abiItem2.type === "event" && log2.topics[0] === toEventSelector(abiItem2));
|
|
367553
367553
|
if (!abiItem)
|
|
367554
367554
|
return null;
|
|
367555
367555
|
const event = decodeEventLog({
|
|
@@ -367685,9 +367685,9 @@ async function getLogs(client, { address, blockHash, fromBlock, toBlock, event,
|
|
|
367685
367685
|
|
|
367686
367686
|
// ../../node_modules/viem/_esm/actions/public/getContractEvents.js
|
|
367687
367687
|
async function getContractEvents(client, parameters) {
|
|
367688
|
-
const { abi:
|
|
367689
|
-
const event = eventName ? getAbiItem({ abi:
|
|
367690
|
-
const events = !event ?
|
|
367688
|
+
const { abi: abi29, address, args, blockHash, eventName, fromBlock, toBlock, strict } = parameters;
|
|
367689
|
+
const event = eventName ? getAbiItem({ abi: abi29, name: eventName }) : void 0;
|
|
367690
|
+
const events = !event ? abi29.filter((x) => x.type === "event") : void 0;
|
|
367691
367691
|
return getAction(client, getLogs, "getLogs")({
|
|
367692
367692
|
address,
|
|
367693
367693
|
args,
|
|
@@ -367705,9 +367705,9 @@ init_decodeFunctionResult();
|
|
|
367705
367705
|
init_encodeFunctionData();
|
|
367706
367706
|
init_call();
|
|
367707
367707
|
async function readContract(client, parameters) {
|
|
367708
|
-
const { abi:
|
|
367708
|
+
const { abi: abi29, address, args, functionName, ...rest } = parameters;
|
|
367709
367709
|
const calldata = encodeFunctionData({
|
|
367710
|
-
abi:
|
|
367710
|
+
abi: abi29,
|
|
367711
367711
|
args,
|
|
367712
367712
|
functionName
|
|
367713
367713
|
});
|
|
@@ -367718,14 +367718,14 @@ async function readContract(client, parameters) {
|
|
|
367718
367718
|
to: address
|
|
367719
367719
|
});
|
|
367720
367720
|
return decodeFunctionResult({
|
|
367721
|
-
abi:
|
|
367721
|
+
abi: abi29,
|
|
367722
367722
|
args,
|
|
367723
367723
|
functionName,
|
|
367724
367724
|
data: data || "0x"
|
|
367725
367725
|
});
|
|
367726
367726
|
} catch (error45) {
|
|
367727
367727
|
throw getContractError(error45, {
|
|
367728
|
-
abi:
|
|
367728
|
+
abi: abi29,
|
|
367729
367729
|
address,
|
|
367730
367730
|
args,
|
|
367731
367731
|
docsPath: "/docs/contract/readContract",
|
|
@@ -367740,9 +367740,9 @@ init_decodeFunctionResult();
|
|
|
367740
367740
|
init_encodeFunctionData();
|
|
367741
367741
|
init_call();
|
|
367742
367742
|
async function simulateContract(client, parameters) {
|
|
367743
|
-
const { abi:
|
|
367743
|
+
const { abi: abi29, address, args, dataSuffix, functionName, ...callRequest } = parameters;
|
|
367744
367744
|
const account = callRequest.account ? parseAccount(callRequest.account) : client.account;
|
|
367745
|
-
const calldata = encodeFunctionData({ abi:
|
|
367745
|
+
const calldata = encodeFunctionData({ abi: abi29, args, functionName });
|
|
367746
367746
|
try {
|
|
367747
367747
|
const { data } = await getAction(client, call, "call")({
|
|
367748
367748
|
batch: false,
|
|
@@ -367752,12 +367752,12 @@ async function simulateContract(client, parameters) {
|
|
|
367752
367752
|
account
|
|
367753
367753
|
});
|
|
367754
367754
|
const result = decodeFunctionResult({
|
|
367755
|
-
abi:
|
|
367755
|
+
abi: abi29,
|
|
367756
367756
|
args,
|
|
367757
367757
|
functionName,
|
|
367758
367758
|
data: data || "0x"
|
|
367759
367759
|
});
|
|
367760
|
-
const minimizedAbi =
|
|
367760
|
+
const minimizedAbi = abi29.filter((abiItem) => "name" in abiItem && abiItem.name === parameters.functionName);
|
|
367761
367761
|
return {
|
|
367762
367762
|
result,
|
|
367763
367763
|
request: {
|
|
@@ -367772,7 +367772,7 @@ async function simulateContract(client, parameters) {
|
|
|
367772
367772
|
};
|
|
367773
367773
|
} catch (error45) {
|
|
367774
367774
|
throw getContractError(error45, {
|
|
367775
|
-
abi:
|
|
367775
|
+
abi: abi29,
|
|
367776
367776
|
address,
|
|
367777
367777
|
args,
|
|
367778
367778
|
docsPath: "/docs/contract/simulateContract",
|
|
@@ -367944,7 +367944,7 @@ async function uninstallFilter(_client, { filter }) {
|
|
|
367944
367944
|
|
|
367945
367945
|
// ../../node_modules/viem/_esm/actions/public/watchContractEvent.js
|
|
367946
367946
|
function watchContractEvent(client, parameters) {
|
|
367947
|
-
const { abi:
|
|
367947
|
+
const { abi: abi29, address, args, batch = true, eventName, fromBlock, onError, onLogs, poll: poll_, pollingInterval = client.pollingInterval, strict: strict_ } = parameters;
|
|
367948
367948
|
const enablePolling = (() => {
|
|
367949
367949
|
if (typeof poll_ !== "undefined")
|
|
367950
367950
|
return poll_;
|
|
@@ -367979,7 +367979,7 @@ function watchContractEvent(client, parameters) {
|
|
|
367979
367979
|
if (!initialized) {
|
|
367980
367980
|
try {
|
|
367981
367981
|
filter = await getAction(client, createContractEventFilter, "createContractEventFilter")({
|
|
367982
|
-
abi:
|
|
367982
|
+
abi: abi29,
|
|
367983
367983
|
address,
|
|
367984
367984
|
args,
|
|
367985
367985
|
eventName,
|
|
@@ -367999,7 +367999,7 @@ function watchContractEvent(client, parameters) {
|
|
|
367999
367999
|
const blockNumber = await getAction(client, getBlockNumber, "getBlockNumber")({});
|
|
368000
368000
|
if (previousBlockNumber && previousBlockNumber < blockNumber) {
|
|
368001
368001
|
logs = await getAction(client, getContractEvents, "getContractEvents")({
|
|
368002
|
-
abi:
|
|
368002
|
+
abi: abi29,
|
|
368003
368003
|
address,
|
|
368004
368004
|
args,
|
|
368005
368005
|
eventName,
|
|
@@ -368063,7 +368063,7 @@ function watchContractEvent(client, parameters) {
|
|
|
368063
368063
|
return client.transport;
|
|
368064
368064
|
})();
|
|
368065
368065
|
const topics = eventName ? encodeEventTopics({
|
|
368066
|
-
abi:
|
|
368066
|
+
abi: abi29,
|
|
368067
368067
|
eventName,
|
|
368068
368068
|
args
|
|
368069
368069
|
}) : [];
|
|
@@ -368075,7 +368075,7 @@ function watchContractEvent(client, parameters) {
|
|
|
368075
368075
|
const log2 = data.result;
|
|
368076
368076
|
try {
|
|
368077
368077
|
const { eventName: eventName2, args: args2 } = decodeEventLog({
|
|
368078
|
-
abi:
|
|
368078
|
+
abi: abi29,
|
|
368079
368079
|
data: log2.data,
|
|
368080
368080
|
topics: log2.topics,
|
|
368081
368081
|
strict: strict_
|
|
@@ -368330,14 +368330,14 @@ async function sendTransaction(client, parameters) {
|
|
|
368330
368330
|
|
|
368331
368331
|
// ../../node_modules/viem/_esm/actions/wallet/writeContract.js
|
|
368332
368332
|
async function writeContract(client, parameters) {
|
|
368333
|
-
const { abi:
|
|
368333
|
+
const { abi: abi29, account: account_ = client.account, address, args, dataSuffix, functionName, ...request } = parameters;
|
|
368334
368334
|
if (typeof account_ === "undefined")
|
|
368335
368335
|
throw new AccountNotFoundError({
|
|
368336
368336
|
docsPath: "/docs/contract/writeContract"
|
|
368337
368337
|
});
|
|
368338
368338
|
const account = account_ ? parseAccount(account_) : null;
|
|
368339
368339
|
const data = encodeFunctionData({
|
|
368340
|
-
abi:
|
|
368340
|
+
abi: abi29,
|
|
368341
368341
|
args,
|
|
368342
368342
|
functionName
|
|
368343
368343
|
});
|
|
@@ -368350,7 +368350,7 @@ async function writeContract(client, parameters) {
|
|
|
368350
368350
|
});
|
|
368351
368351
|
} catch (error45) {
|
|
368352
368352
|
throw getContractError(error45, {
|
|
368353
|
-
abi:
|
|
368353
|
+
abi: abi29,
|
|
368354
368354
|
address,
|
|
368355
368355
|
args,
|
|
368356
368356
|
docsPath: "/docs/contract/writeContract",
|
|
@@ -368361,7 +368361,7 @@ async function writeContract(client, parameters) {
|
|
|
368361
368361
|
}
|
|
368362
368362
|
|
|
368363
368363
|
// ../../node_modules/viem/_esm/actions/getContract.js
|
|
368364
|
-
function getContract({ abi:
|
|
368364
|
+
function getContract({ abi: abi29, address, client: client_ }) {
|
|
368365
368365
|
const client = client_;
|
|
368366
368366
|
const [publicClient, walletClient] = (() => {
|
|
368367
368367
|
if (!client)
|
|
@@ -368380,7 +368380,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368380
368380
|
let hasReadFunction = false;
|
|
368381
368381
|
let hasWriteFunction = false;
|
|
368382
368382
|
let hasEvent = false;
|
|
368383
|
-
for (const item of
|
|
368383
|
+
for (const item of abi29) {
|
|
368384
368384
|
if (item.type === "function")
|
|
368385
368385
|
if (item.stateMutability === "view" || item.stateMutability === "pure")
|
|
368386
368386
|
hasReadFunction = true;
|
|
@@ -368398,7 +368398,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368398
368398
|
return (...parameters) => {
|
|
368399
368399
|
const { args, options } = getFunctionParameters(parameters);
|
|
368400
368400
|
return getAction(publicClient, readContract, "readContract")({
|
|
368401
|
-
abi:
|
|
368401
|
+
abi: abi29,
|
|
368402
368402
|
address,
|
|
368403
368403
|
functionName,
|
|
368404
368404
|
args,
|
|
@@ -368413,7 +368413,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368413
368413
|
return (...parameters) => {
|
|
368414
368414
|
const { args, options } = getFunctionParameters(parameters);
|
|
368415
368415
|
return getAction(publicClient, simulateContract, "simulateContract")({
|
|
368416
|
-
abi:
|
|
368416
|
+
abi: abi29,
|
|
368417
368417
|
address,
|
|
368418
368418
|
functionName,
|
|
368419
368419
|
args,
|
|
@@ -368426,10 +368426,10 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368426
368426
|
contract.createEventFilter = new Proxy({}, {
|
|
368427
368427
|
get(_, eventName) {
|
|
368428
368428
|
return (...parameters) => {
|
|
368429
|
-
const abiEvent =
|
|
368429
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
368430
368430
|
const { args, options } = getEventParameters(parameters, abiEvent);
|
|
368431
368431
|
return getAction(publicClient, createContractEventFilter, "createContractEventFilter")({
|
|
368432
|
-
abi:
|
|
368432
|
+
abi: abi29,
|
|
368433
368433
|
address,
|
|
368434
368434
|
eventName,
|
|
368435
368435
|
args,
|
|
@@ -368441,10 +368441,10 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368441
368441
|
contract.getEvents = new Proxy({}, {
|
|
368442
368442
|
get(_, eventName) {
|
|
368443
368443
|
return (...parameters) => {
|
|
368444
|
-
const abiEvent =
|
|
368444
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
368445
368445
|
const { args, options } = getEventParameters(parameters, abiEvent);
|
|
368446
368446
|
return getAction(publicClient, getContractEvents, "getContractEvents")({
|
|
368447
|
-
abi:
|
|
368447
|
+
abi: abi29,
|
|
368448
368448
|
address,
|
|
368449
368449
|
eventName,
|
|
368450
368450
|
args,
|
|
@@ -368456,10 +368456,10 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368456
368456
|
contract.watchEvent = new Proxy({}, {
|
|
368457
368457
|
get(_, eventName) {
|
|
368458
368458
|
return (...parameters) => {
|
|
368459
|
-
const abiEvent =
|
|
368459
|
+
const abiEvent = abi29.find((x) => x.type === "event" && x.name === eventName);
|
|
368460
368460
|
const { args, options } = getEventParameters(parameters, abiEvent);
|
|
368461
368461
|
return getAction(publicClient, watchContractEvent, "watchContractEvent")({
|
|
368462
|
-
abi:
|
|
368462
|
+
abi: abi29,
|
|
368463
368463
|
address,
|
|
368464
368464
|
eventName,
|
|
368465
368465
|
args,
|
|
@@ -368477,7 +368477,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368477
368477
|
return (...parameters) => {
|
|
368478
368478
|
const { args, options } = getFunctionParameters(parameters);
|
|
368479
368479
|
return getAction(walletClient, writeContract, "writeContract")({
|
|
368480
|
-
abi:
|
|
368480
|
+
abi: abi29,
|
|
368481
368481
|
address,
|
|
368482
368482
|
functionName,
|
|
368483
368483
|
args,
|
|
@@ -368495,7 +368495,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368495
368495
|
const { args, options } = getFunctionParameters(parameters);
|
|
368496
368496
|
const client2 = publicClient ?? walletClient;
|
|
368497
368497
|
return getAction(client2, estimateContractGas, "estimateContractGas")({
|
|
368498
|
-
abi:
|
|
368498
|
+
abi: abi29,
|
|
368499
368499
|
address,
|
|
368500
368500
|
functionName,
|
|
368501
368501
|
args,
|
|
@@ -368507,7 +368507,7 @@ function getContract({ abi: abi27, address, client: client_ }) {
|
|
|
368507
368507
|
});
|
|
368508
368508
|
}
|
|
368509
368509
|
contract.address = address;
|
|
368510
|
-
contract.abi =
|
|
368510
|
+
contract.abi = abi29;
|
|
368511
368511
|
return contract;
|
|
368512
368512
|
}
|
|
368513
368513
|
function getFunctionParameters(values) {
|
|
@@ -372534,9 +372534,9 @@ async function multicall(client, parameters) {
|
|
|
372534
372534
|
let currentChunk = 0;
|
|
372535
372535
|
let currentChunkSize = 0;
|
|
372536
372536
|
for (let i = 0; i < contracts2.length; i++) {
|
|
372537
|
-
const { abi:
|
|
372537
|
+
const { abi: abi29, address, args, functionName } = contracts2[i];
|
|
372538
372538
|
try {
|
|
372539
|
-
const callData = encodeFunctionData({ abi:
|
|
372539
|
+
const callData = encodeFunctionData({ abi: abi29, args, functionName });
|
|
372540
372540
|
currentChunkSize += (callData.length - 2) / 2;
|
|
372541
372541
|
if (
|
|
372542
372542
|
// Check if batching is enabled.
|
|
@@ -372558,7 +372558,7 @@ async function multicall(client, parameters) {
|
|
|
372558
372558
|
];
|
|
372559
372559
|
} catch (err) {
|
|
372560
372560
|
const error45 = getContractError(err, {
|
|
372561
|
-
abi:
|
|
372561
|
+
abi: abi29,
|
|
372562
372562
|
address,
|
|
372563
372563
|
args,
|
|
372564
372564
|
docsPath: "/docs/contract/multicall",
|
|
@@ -372608,14 +372608,14 @@ async function multicall(client, parameters) {
|
|
|
372608
372608
|
for (let j = 0; j < aggregate3Result.length; j++) {
|
|
372609
372609
|
const { returnData, success: success2 } = aggregate3Result[j];
|
|
372610
372610
|
const { callData } = chunkedCalls[i][j];
|
|
372611
|
-
const { abi:
|
|
372611
|
+
const { abi: abi29, address, functionName, args } = contracts2[results.length];
|
|
372612
372612
|
try {
|
|
372613
372613
|
if (callData === "0x")
|
|
372614
372614
|
throw new AbiDecodingZeroDataError();
|
|
372615
372615
|
if (!success2)
|
|
372616
372616
|
throw new RawContractError({ data: returnData });
|
|
372617
372617
|
const result2 = decodeFunctionResult({
|
|
372618
|
-
abi:
|
|
372618
|
+
abi: abi29,
|
|
372619
372619
|
args,
|
|
372620
372620
|
data: returnData,
|
|
372621
372621
|
functionName
|
|
@@ -372623,7 +372623,7 @@ async function multicall(client, parameters) {
|
|
|
372623
372623
|
results.push(allowFailure ? { result: result2, status: "success" } : result2);
|
|
372624
372624
|
} catch (err) {
|
|
372625
372625
|
const error45 = getContractError(err, {
|
|
372626
|
-
abi:
|
|
372626
|
+
abi: abi29,
|
|
372627
372627
|
address,
|
|
372628
372628
|
args,
|
|
372629
372629
|
docsPath: "/docs/contract/multicall",
|
|
@@ -372691,13 +372691,13 @@ async function simulateBlocks(client, parameters) {
|
|
|
372691
372691
|
return result.map((block2, i) => ({
|
|
372692
372692
|
...formatBlock(block2),
|
|
372693
372693
|
calls: block2.calls.map((call2, j) => {
|
|
372694
|
-
const { abi:
|
|
372694
|
+
const { abi: abi29, args, functionName, to } = blocks[i].calls[j];
|
|
372695
372695
|
const data = call2.error?.data ?? call2.returnData;
|
|
372696
372696
|
const gasUsed = BigInt(call2.gasUsed);
|
|
372697
372697
|
const logs = call2.logs?.map((log2) => formatLog(log2));
|
|
372698
372698
|
const status = call2.status === "0x1" ? "success" : "failure";
|
|
372699
|
-
const result2 =
|
|
372700
|
-
abi:
|
|
372699
|
+
const result2 = abi29 && status === "success" && data !== "0x" ? decodeFunctionResult({
|
|
372700
|
+
abi: abi29,
|
|
372701
372701
|
data,
|
|
372702
372702
|
functionName
|
|
372703
372703
|
}) : null;
|
|
@@ -372712,7 +372712,7 @@ async function simulateBlocks(client, parameters) {
|
|
|
372712
372712
|
if (!error46)
|
|
372713
372713
|
return void 0;
|
|
372714
372714
|
return getContractError(error46, {
|
|
372715
|
-
abi:
|
|
372715
|
+
abi: abi29 ?? [],
|
|
372716
372716
|
address: to ?? "0x",
|
|
372717
372717
|
args,
|
|
372718
372718
|
functionName: functionName ?? "<unknown>"
|
|
@@ -372862,10 +372862,10 @@ function from10(abiItem, options = {}) {
|
|
|
372862
372862
|
...prepare ? { hash: getSignatureHash(item) } : {}
|
|
372863
372863
|
};
|
|
372864
372864
|
}
|
|
372865
|
-
function fromAbi(
|
|
372865
|
+
function fromAbi(abi29, name, options) {
|
|
372866
372866
|
const { args = [], prepare = true } = options ?? {};
|
|
372867
372867
|
const isSelector = validate2(name, { strict: false });
|
|
372868
|
-
const abiItems =
|
|
372868
|
+
const abiItems = abi29.filter((abiItem2) => {
|
|
372869
372869
|
if (isSelector) {
|
|
372870
372870
|
if (abiItem2.type === "function" || abiItem2.type === "error")
|
|
372871
372871
|
return getSelector(abiItem2) === slice3(name, 0, 4);
|
|
@@ -373013,8 +373013,8 @@ function encodeData2(abiFunction, ...args) {
|
|
|
373013
373013
|
function from12(abiFunction, options = {}) {
|
|
373014
373014
|
return from10(abiFunction, options);
|
|
373015
373015
|
}
|
|
373016
|
-
function fromAbi2(
|
|
373017
|
-
const item = fromAbi(
|
|
373016
|
+
function fromAbi2(abi29, name, options) {
|
|
373017
|
+
const item = fromAbi(abi29, name, options);
|
|
373018
373018
|
if (item.type !== "function")
|
|
373019
373019
|
throw new NotFoundError({ name, type: "function" });
|
|
373020
373020
|
return item;
|
|
@@ -374677,8 +374677,8 @@ async function addChain(client, { chain }) {
|
|
|
374677
374677
|
// ../../node_modules/viem/_esm/actions/wallet/deployContract.js
|
|
374678
374678
|
init_encodeDeployData();
|
|
374679
374679
|
function deployContract(walletClient, parameters) {
|
|
374680
|
-
const { abi:
|
|
374681
|
-
const calldata = encodeDeployData({ abi:
|
|
374680
|
+
const { abi: abi29, args, bytecode, ...request } = parameters;
|
|
374681
|
+
const calldata = encodeDeployData({ abi: abi29, args, bytecode });
|
|
374682
374682
|
return sendTransaction(walletClient, {
|
|
374683
374683
|
...request,
|
|
374684
374684
|
...request.authorizationList ? { to: null } : {},
|
|
@@ -389203,12 +389203,12 @@ var json_parse = (s) => {
|
|
|
389203
389203
|
function createRawTx(to, parameters, description) {
|
|
389204
389204
|
const { args } = parameters;
|
|
389205
389205
|
const fname = parameters.functionName;
|
|
389206
|
-
const { abi:
|
|
389206
|
+
const { abi: abi29, functionName } = (() => {
|
|
389207
389207
|
if (parameters.abi.length === 1 && parameters.functionName?.startsWith("0x"))
|
|
389208
389208
|
return parameters;
|
|
389209
389209
|
return prepareEncodeFunctionData(parameters);
|
|
389210
389210
|
})();
|
|
389211
|
-
const abiItem =
|
|
389211
|
+
const abiItem = abi29[0];
|
|
389212
389212
|
const signature = functionName;
|
|
389213
389213
|
const data = "inputs" in abiItem && abiItem.inputs ? encodeAbiParameters(abiItem.inputs, args ?? []) : void 0;
|
|
389214
389214
|
const functionEncodedData = concatHex([signature, data ?? "0x"]);
|
|
@@ -411701,9 +411701,9 @@ async function simulateMulticall(client, parameters) {
|
|
|
411701
411701
|
}
|
|
411702
411702
|
const calls = [];
|
|
411703
411703
|
for (const contract of contracts2) {
|
|
411704
|
-
const { abi:
|
|
411704
|
+
const { abi: abi29, address, args, functionName } = contract;
|
|
411705
411705
|
try {
|
|
411706
|
-
const callData = encodeFunctionData({ abi:
|
|
411706
|
+
const callData = encodeFunctionData({ abi: abi29, args, functionName });
|
|
411707
411707
|
calls.push({
|
|
411708
411708
|
allowFailure: true,
|
|
411709
411709
|
callData,
|
|
@@ -411711,7 +411711,7 @@ async function simulateMulticall(client, parameters) {
|
|
|
411711
411711
|
});
|
|
411712
411712
|
} catch (err) {
|
|
411713
411713
|
const error45 = getContractError(err, {
|
|
411714
|
-
abi:
|
|
411714
|
+
abi: abi29,
|
|
411715
411715
|
address,
|
|
411716
411716
|
args,
|
|
411717
411717
|
docsPath: "/docs/contract/multicall",
|
|
@@ -411754,12 +411754,12 @@ async function simulateMulticall(client, parameters) {
|
|
|
411754
411754
|
for (let j = 0; j < result.length; j++) {
|
|
411755
411755
|
const { returnData, success: success2 } = result[j];
|
|
411756
411756
|
const { callData } = calls[j];
|
|
411757
|
-
const { abi:
|
|
411757
|
+
const { abi: abi29, address, functionName, args } = contracts2[results.length];
|
|
411758
411758
|
try {
|
|
411759
411759
|
if (callData === "0x") throw new AbiDecodingZeroDataError();
|
|
411760
411760
|
if (!success2) throw new RawContractError({ data: returnData });
|
|
411761
411761
|
const result2 = decodeFunctionResult({
|
|
411762
|
-
abi:
|
|
411762
|
+
abi: abi29,
|
|
411763
411763
|
args,
|
|
411764
411764
|
data: returnData,
|
|
411765
411765
|
functionName
|
|
@@ -411767,7 +411767,7 @@ async function simulateMulticall(client, parameters) {
|
|
|
411767
411767
|
results.push(allowFailure ? { result: result2, status: "success" } : result2);
|
|
411768
411768
|
} catch (err) {
|
|
411769
411769
|
const error45 = getContractError(err, {
|
|
411770
|
-
abi:
|
|
411770
|
+
abi: abi29,
|
|
411771
411771
|
address,
|
|
411772
411772
|
args,
|
|
411773
411773
|
docsPath: "/docs/contract/multicall",
|
|
@@ -439760,6 +439760,10 @@ var iPriceOracleV2Abi = [
|
|
|
439760
439760
|
{ type: "error", inputs: [], name: "ZeroPriceException" }
|
|
439761
439761
|
];
|
|
439762
439762
|
|
|
439763
|
+
// ../../packages/node/dist/constants.js
|
|
439764
|
+
var GEARBOX_V1_BLOCK = 13810899;
|
|
439765
|
+
var CROSS_CHAIN_MULTISIG_ADDRESS = "0xcCCCCcCc42B7DA9fdEc1761698Fb55fdD41CDF55";
|
|
439766
|
+
|
|
439763
439767
|
// ../../packages/node/dist/helpers/fs.js
|
|
439764
439768
|
import { readdir } from "node:fs/promises";
|
|
439765
439769
|
import { join, resolve } from "node:path";
|
|
@@ -439831,7 +439835,7 @@ function normalizeTransactions(batch) {
|
|
|
439831
439835
|
});
|
|
439832
439836
|
}
|
|
439833
439837
|
function normalizeDirectTx(t) {
|
|
439834
|
-
const
|
|
439838
|
+
const abi29 = [
|
|
439835
439839
|
{
|
|
439836
439840
|
type: "function",
|
|
439837
439841
|
outputs: [],
|
|
@@ -439853,10 +439857,10 @@ function normalizeDirectTx(t) {
|
|
|
439853
439857
|
return {
|
|
439854
439858
|
target: t.to,
|
|
439855
439859
|
value: t.value,
|
|
439856
|
-
signature: formatAbiItem2(
|
|
439860
|
+
signature: formatAbiItem2(abi29[0], { includeName: false }),
|
|
439857
439861
|
parameters,
|
|
439858
439862
|
data: encodeFunctionData({
|
|
439859
|
-
abi:
|
|
439863
|
+
abi: abi29,
|
|
439860
439864
|
functionName: t.contractMethod.name,
|
|
439861
439865
|
args: values
|
|
439862
439866
|
})
|
|
@@ -439886,6 +439890,9 @@ function normalizeTimelockTx(t) {
|
|
|
439886
439890
|
};
|
|
439887
439891
|
}
|
|
439888
439892
|
function normalizeSafeApiBatch(tx) {
|
|
439893
|
+
if (tx.to === CROSS_CHAIN_MULTISIG_ADDRESS && tx.data?.startsWith("0x725601a8")) {
|
|
439894
|
+
return normalizeCrossChainMultisigBatch(tx);
|
|
439895
|
+
}
|
|
439889
439896
|
const transactions = tx.dataDecoded.parameters[0].valueDecoded.map(normalizeMultisendTransactionDecoded);
|
|
439890
439897
|
return {
|
|
439891
439898
|
id: tx.safeTxHash,
|
|
@@ -439897,6 +439904,65 @@ function normalizeSafeApiBatch(tx) {
|
|
|
439897
439904
|
// TODO: determine, or wait till they are made the same in deploy-v3
|
|
439898
439905
|
};
|
|
439899
439906
|
}
|
|
439907
|
+
function normalizeCrossChainMultisigBatch(tx) {
|
|
439908
|
+
const { args } = decodeFunctionData({
|
|
439909
|
+
abi: [
|
|
439910
|
+
{
|
|
439911
|
+
type: "function",
|
|
439912
|
+
name: "submitBatch",
|
|
439913
|
+
inputs: [
|
|
439914
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
439915
|
+
{
|
|
439916
|
+
name: "calls",
|
|
439917
|
+
type: "tuple[]",
|
|
439918
|
+
internalType: "struct CrossChainCall[]",
|
|
439919
|
+
components: [
|
|
439920
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
439921
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
439922
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
439923
|
+
]
|
|
439924
|
+
},
|
|
439925
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" }
|
|
439926
|
+
],
|
|
439927
|
+
outputs: [],
|
|
439928
|
+
stateMutability: "nonpayable"
|
|
439929
|
+
}
|
|
439930
|
+
],
|
|
439931
|
+
data: tx.data
|
|
439932
|
+
});
|
|
439933
|
+
const [name, calls, prevHash] = args;
|
|
439934
|
+
return {
|
|
439935
|
+
id: tx.safeTxHash,
|
|
439936
|
+
safeTxHash: tx.safeTxHash,
|
|
439937
|
+
description: "",
|
|
439938
|
+
transactions: [
|
|
439939
|
+
{
|
|
439940
|
+
data: tx.data,
|
|
439941
|
+
target: CROSS_CHAIN_MULTISIG_ADDRESS,
|
|
439942
|
+
value: tx.value,
|
|
439943
|
+
signature: "submitBatch(string,(uint256,address,bytes)[],bytes32)",
|
|
439944
|
+
parameters: [
|
|
439945
|
+
{
|
|
439946
|
+
name: "name",
|
|
439947
|
+
type: "string",
|
|
439948
|
+
value: name
|
|
439949
|
+
},
|
|
439950
|
+
{
|
|
439951
|
+
name: "calls",
|
|
439952
|
+
type: "tuple[]",
|
|
439953
|
+
value: calls
|
|
439954
|
+
},
|
|
439955
|
+
{
|
|
439956
|
+
name: "prevHash",
|
|
439957
|
+
type: "bytes32",
|
|
439958
|
+
value: prevHash
|
|
439959
|
+
}
|
|
439960
|
+
]
|
|
439961
|
+
}
|
|
439962
|
+
],
|
|
439963
|
+
type: "crossChainMultisig"
|
|
439964
|
+
};
|
|
439965
|
+
}
|
|
439900
439966
|
function normalizeMultisendTransactionDecoded(t) {
|
|
439901
439967
|
if (!t.dataDecoded) {
|
|
439902
439968
|
try {
|
|
@@ -444438,15 +444504,15 @@ var Create2Deployer = class extends SDKConstruct {
|
|
|
444438
444504
|
this.#walletClient = walletClient;
|
|
444439
444505
|
}
|
|
444440
444506
|
async ensureExists(parameters) {
|
|
444441
|
-
const { abi:
|
|
444507
|
+
const { abi: abi29, args, bytecode } = parameters;
|
|
444442
444508
|
const address = getPublicCreate2Address({
|
|
444443
|
-
abi:
|
|
444509
|
+
abi: abi29,
|
|
444444
444510
|
bytecode,
|
|
444445
444511
|
args
|
|
444446
444512
|
});
|
|
444447
444513
|
this.#logger?.info(`will deploy contract at ${address}`);
|
|
444448
444514
|
const isDeployed = await isDeployedUsingPublicCreate2(this.client, {
|
|
444449
|
-
abi:
|
|
444515
|
+
abi: abi29,
|
|
444450
444516
|
bytecode,
|
|
444451
444517
|
args
|
|
444452
444518
|
});
|
|
@@ -444471,13 +444537,13 @@ var Create2Deployer = class extends SDKConstruct {
|
|
|
444471
444537
|
};
|
|
444472
444538
|
async function deployUsingPublicCreate2(walletClient, parameters) {
|
|
444473
444539
|
const {
|
|
444474
|
-
abi:
|
|
444540
|
+
abi: abi29,
|
|
444475
444541
|
args,
|
|
444476
444542
|
bytecode,
|
|
444477
444543
|
salt = DEFAULT_CREATE2_SALT,
|
|
444478
444544
|
...request
|
|
444479
444545
|
} = parameters;
|
|
444480
|
-
const calldata = encodeDeployData({ abi:
|
|
444546
|
+
const calldata = encodeDeployData({ abi: abi29, bytecode, args });
|
|
444481
444547
|
const saltHex = stringToHex(salt, { size: 32 });
|
|
444482
444548
|
const data = concatHex([saltHex, calldata]);
|
|
444483
444549
|
return sendTransaction(walletClient, {
|
|
@@ -444488,12 +444554,12 @@ async function deployUsingPublicCreate2(walletClient, parameters) {
|
|
|
444488
444554
|
}
|
|
444489
444555
|
function getPublicCreate2Address(params) {
|
|
444490
444556
|
const {
|
|
444491
|
-
abi:
|
|
444557
|
+
abi: abi29,
|
|
444492
444558
|
args,
|
|
444493
444559
|
bytecode,
|
|
444494
444560
|
salt = DEFAULT_CREATE2_SALT
|
|
444495
444561
|
} = params;
|
|
444496
|
-
const deployBytecode = encodeDeployData({ abi:
|
|
444562
|
+
const deployBytecode = encodeDeployData({ abi: abi29, bytecode, args });
|
|
444497
444563
|
const saltHex = stringToHex(salt, { size: 32 });
|
|
444498
444564
|
return getCreate2Address({
|
|
444499
444565
|
from: PUBLIC_CREATE2_FACTORY,
|
|
@@ -445070,9 +445136,6 @@ var Queue = class extends EventTarget {
|
|
|
445070
445136
|
}
|
|
445071
445137
|
};
|
|
445072
445138
|
|
|
445073
|
-
// ../../packages/node/dist/constants.js
|
|
445074
|
-
var GEARBOX_V1_BLOCK = 13810899;
|
|
445075
|
-
|
|
445076
445139
|
// ../../packages/node/dist/Verifier.js
|
|
445077
445140
|
var import_bytecode_utils2 = __toESM(require_main(), 1);
|
|
445078
445141
|
var import_lib_sourcify = __toESM(require_main2(), 1);
|
|
@@ -446509,6 +446572,16 @@ var GearboxAddressTree = class _GearboxAddressTree extends ProviderBase {
|
|
|
446509
446572
|
address: this.address("BATCH_CHAIN"),
|
|
446510
446573
|
contract: "BATCH_CHAIN",
|
|
446511
446574
|
version: VERSION_UNVERSIONED
|
|
446575
|
+
},
|
|
446576
|
+
{
|
|
446577
|
+
address: CROSS_CHAIN_MULTISIG_ADDRESS,
|
|
446578
|
+
contract: "CROSS_CHAIN_MULTISIG",
|
|
446579
|
+
version: VERSION_UNVERSIONED
|
|
446580
|
+
},
|
|
446581
|
+
{
|
|
446582
|
+
address: "0x77777777144339Bdc3aCceE992D8d4D31734CB2e",
|
|
446583
|
+
contract: "INSTANCE_MANAGER",
|
|
446584
|
+
version: VERSION_UNVERSIONED
|
|
446512
446585
|
}
|
|
446513
446586
|
]);
|
|
446514
446587
|
if (this.network === "Mainnet") {
|
|
@@ -447080,9 +447153,9 @@ var AbstractParser = class {
|
|
|
447080
447153
|
};
|
|
447081
447154
|
}
|
|
447082
447155
|
parseConstructor(address, encodedArgs) {
|
|
447083
|
-
for (const { abi:
|
|
447156
|
+
for (const { abi: abi29, comment } of this.constructorAbis) {
|
|
447084
447157
|
try {
|
|
447085
|
-
return this.#parseConstructor(address, encodedArgs,
|
|
447158
|
+
return this.#parseConstructor(address, encodedArgs, abi29, comment);
|
|
447086
447159
|
} catch (e) {
|
|
447087
447160
|
this.logger.warn(`constructor ${comment} of ${address} failed to parse args: ${e}`);
|
|
447088
447161
|
}
|
|
@@ -448293,6 +448366,552 @@ var CreditManagerV3Parser = class extends AbstractParser {
|
|
|
448293
448366
|
}
|
|
448294
448367
|
};
|
|
448295
448368
|
|
|
448369
|
+
// ../../packages/node/dist/parsers/CrossChainMultisigParser.js
|
|
448370
|
+
var abi25 = [
|
|
448371
|
+
{
|
|
448372
|
+
type: "constructor",
|
|
448373
|
+
inputs: [
|
|
448374
|
+
{ name: "signers_", type: "address[]", internalType: "address[]" },
|
|
448375
|
+
{ name: "confirmationThreshold_", type: "uint8", internalType: "uint8" },
|
|
448376
|
+
{ name: "owner_", type: "address", internalType: "address" }
|
|
448377
|
+
],
|
|
448378
|
+
stateMutability: "nonpayable"
|
|
448379
|
+
},
|
|
448380
|
+
{
|
|
448381
|
+
type: "function",
|
|
448382
|
+
name: "BATCH_TYPEHASH",
|
|
448383
|
+
inputs: [],
|
|
448384
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448385
|
+
stateMutability: "view"
|
|
448386
|
+
},
|
|
448387
|
+
{
|
|
448388
|
+
type: "function",
|
|
448389
|
+
name: "COMPACT_BATCH_TYPEHASH",
|
|
448390
|
+
inputs: [],
|
|
448391
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448392
|
+
stateMutability: "view"
|
|
448393
|
+
},
|
|
448394
|
+
{
|
|
448395
|
+
type: "function",
|
|
448396
|
+
name: "CROSS_CHAIN_CALL_TYPEHASH",
|
|
448397
|
+
inputs: [],
|
|
448398
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448399
|
+
stateMutability: "view"
|
|
448400
|
+
},
|
|
448401
|
+
{
|
|
448402
|
+
type: "function",
|
|
448403
|
+
name: "RECOVERY_MODE_TYPEHASH",
|
|
448404
|
+
inputs: [],
|
|
448405
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448406
|
+
stateMutability: "view"
|
|
448407
|
+
},
|
|
448408
|
+
{
|
|
448409
|
+
type: "function",
|
|
448410
|
+
name: "addSigner",
|
|
448411
|
+
inputs: [{ name: "signer", type: "address", internalType: "address" }],
|
|
448412
|
+
outputs: [],
|
|
448413
|
+
stateMutability: "nonpayable"
|
|
448414
|
+
},
|
|
448415
|
+
{
|
|
448416
|
+
type: "function",
|
|
448417
|
+
name: "computeBatchHash",
|
|
448418
|
+
inputs: [
|
|
448419
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448420
|
+
{
|
|
448421
|
+
name: "calls",
|
|
448422
|
+
type: "tuple[]",
|
|
448423
|
+
internalType: "struct CrossChainCall[]",
|
|
448424
|
+
components: [
|
|
448425
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448426
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
448427
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
448428
|
+
]
|
|
448429
|
+
},
|
|
448430
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" }
|
|
448431
|
+
],
|
|
448432
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448433
|
+
stateMutability: "pure"
|
|
448434
|
+
},
|
|
448435
|
+
{
|
|
448436
|
+
type: "function",
|
|
448437
|
+
name: "computeCompactBatchHash",
|
|
448438
|
+
inputs: [
|
|
448439
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448440
|
+
{ name: "batchHash", type: "bytes32", internalType: "bytes32" },
|
|
448441
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" }
|
|
448442
|
+
],
|
|
448443
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448444
|
+
stateMutability: "pure"
|
|
448445
|
+
},
|
|
448446
|
+
{
|
|
448447
|
+
type: "function",
|
|
448448
|
+
name: "computeCrossChainCallHash",
|
|
448449
|
+
inputs: [
|
|
448450
|
+
{
|
|
448451
|
+
name: "call",
|
|
448452
|
+
type: "tuple",
|
|
448453
|
+
internalType: "struct CrossChainCall",
|
|
448454
|
+
components: [
|
|
448455
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448456
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
448457
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
448458
|
+
]
|
|
448459
|
+
}
|
|
448460
|
+
],
|
|
448461
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448462
|
+
stateMutability: "pure"
|
|
448463
|
+
},
|
|
448464
|
+
{
|
|
448465
|
+
type: "function",
|
|
448466
|
+
name: "computeRecoveryModeHash",
|
|
448467
|
+
inputs: [
|
|
448468
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448469
|
+
{ name: "startingBatchHash", type: "bytes32", internalType: "bytes32" }
|
|
448470
|
+
],
|
|
448471
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448472
|
+
stateMutability: "pure"
|
|
448473
|
+
},
|
|
448474
|
+
{
|
|
448475
|
+
type: "function",
|
|
448476
|
+
name: "confirmationThreshold",
|
|
448477
|
+
inputs: [],
|
|
448478
|
+
outputs: [{ name: "", type: "uint8", internalType: "uint8" }],
|
|
448479
|
+
stateMutability: "view"
|
|
448480
|
+
},
|
|
448481
|
+
{
|
|
448482
|
+
type: "function",
|
|
448483
|
+
name: "contractType",
|
|
448484
|
+
inputs: [],
|
|
448485
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448486
|
+
stateMutability: "view"
|
|
448487
|
+
},
|
|
448488
|
+
{
|
|
448489
|
+
type: "function",
|
|
448490
|
+
name: "disableRecoveryMode",
|
|
448491
|
+
inputs: [{ name: "chainId", type: "uint256", internalType: "uint256" }],
|
|
448492
|
+
outputs: [],
|
|
448493
|
+
stateMutability: "nonpayable"
|
|
448494
|
+
},
|
|
448495
|
+
{
|
|
448496
|
+
type: "function",
|
|
448497
|
+
name: "domainSeparatorV4",
|
|
448498
|
+
inputs: [],
|
|
448499
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448500
|
+
stateMutability: "view"
|
|
448501
|
+
},
|
|
448502
|
+
{
|
|
448503
|
+
type: "function",
|
|
448504
|
+
name: "eip712Domain",
|
|
448505
|
+
inputs: [],
|
|
448506
|
+
outputs: [
|
|
448507
|
+
{ name: "fields", type: "bytes1", internalType: "bytes1" },
|
|
448508
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448509
|
+
{ name: "version", type: "string", internalType: "string" },
|
|
448510
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448511
|
+
{ name: "verifyingContract", type: "address", internalType: "address" },
|
|
448512
|
+
{ name: "salt", type: "bytes32", internalType: "bytes32" },
|
|
448513
|
+
{ name: "extensions", type: "uint256[]", internalType: "uint256[]" }
|
|
448514
|
+
],
|
|
448515
|
+
stateMutability: "view"
|
|
448516
|
+
},
|
|
448517
|
+
{
|
|
448518
|
+
type: "function",
|
|
448519
|
+
name: "enableRecoveryMode",
|
|
448520
|
+
inputs: [
|
|
448521
|
+
{
|
|
448522
|
+
name: "message",
|
|
448523
|
+
type: "tuple",
|
|
448524
|
+
internalType: "struct SignedRecoveryModeMessage",
|
|
448525
|
+
components: [
|
|
448526
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448527
|
+
{
|
|
448528
|
+
name: "startingBatchHash",
|
|
448529
|
+
type: "bytes32",
|
|
448530
|
+
internalType: "bytes32"
|
|
448531
|
+
},
|
|
448532
|
+
{ name: "signatures", type: "bytes[]", internalType: "bytes[]" }
|
|
448533
|
+
]
|
|
448534
|
+
}
|
|
448535
|
+
],
|
|
448536
|
+
outputs: [],
|
|
448537
|
+
stateMutability: "nonpayable"
|
|
448538
|
+
},
|
|
448539
|
+
{
|
|
448540
|
+
type: "function",
|
|
448541
|
+
name: "executeBatch",
|
|
448542
|
+
inputs: [
|
|
448543
|
+
{
|
|
448544
|
+
name: "signedBatch",
|
|
448545
|
+
type: "tuple",
|
|
448546
|
+
internalType: "struct SignedBatch",
|
|
448547
|
+
components: [
|
|
448548
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448549
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" },
|
|
448550
|
+
{
|
|
448551
|
+
name: "calls",
|
|
448552
|
+
type: "tuple[]",
|
|
448553
|
+
internalType: "struct CrossChainCall[]",
|
|
448554
|
+
components: [
|
|
448555
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448556
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
448557
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
448558
|
+
]
|
|
448559
|
+
},
|
|
448560
|
+
{ name: "signatures", type: "bytes[]", internalType: "bytes[]" }
|
|
448561
|
+
]
|
|
448562
|
+
}
|
|
448563
|
+
],
|
|
448564
|
+
outputs: [],
|
|
448565
|
+
stateMutability: "nonpayable"
|
|
448566
|
+
},
|
|
448567
|
+
{
|
|
448568
|
+
type: "function",
|
|
448569
|
+
name: "getBatch",
|
|
448570
|
+
inputs: [{ name: "batchHash", type: "bytes32", internalType: "bytes32" }],
|
|
448571
|
+
outputs: [
|
|
448572
|
+
{
|
|
448573
|
+
name: "result",
|
|
448574
|
+
type: "tuple",
|
|
448575
|
+
internalType: "struct SignedBatch",
|
|
448576
|
+
components: [
|
|
448577
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448578
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" },
|
|
448579
|
+
{
|
|
448580
|
+
name: "calls",
|
|
448581
|
+
type: "tuple[]",
|
|
448582
|
+
internalType: "struct CrossChainCall[]",
|
|
448583
|
+
components: [
|
|
448584
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448585
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
448586
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
448587
|
+
]
|
|
448588
|
+
},
|
|
448589
|
+
{ name: "signatures", type: "bytes[]", internalType: "bytes[]" }
|
|
448590
|
+
]
|
|
448591
|
+
}
|
|
448592
|
+
],
|
|
448593
|
+
stateMutability: "view"
|
|
448594
|
+
},
|
|
448595
|
+
{
|
|
448596
|
+
type: "function",
|
|
448597
|
+
name: "getConnectedBatchHashes",
|
|
448598
|
+
inputs: [{ name: "batchHash", type: "bytes32", internalType: "bytes32" }],
|
|
448599
|
+
outputs: [{ name: "", type: "bytes32[]", internalType: "bytes32[]" }],
|
|
448600
|
+
stateMutability: "view"
|
|
448601
|
+
},
|
|
448602
|
+
{
|
|
448603
|
+
type: "function",
|
|
448604
|
+
name: "getCurrentBatchHashes",
|
|
448605
|
+
inputs: [],
|
|
448606
|
+
outputs: [{ name: "", type: "bytes32[]", internalType: "bytes32[]" }],
|
|
448607
|
+
stateMutability: "view"
|
|
448608
|
+
},
|
|
448609
|
+
{
|
|
448610
|
+
type: "function",
|
|
448611
|
+
name: "getExecutedBatchHashes",
|
|
448612
|
+
inputs: [],
|
|
448613
|
+
outputs: [{ name: "", type: "bytes32[]", internalType: "bytes32[]" }],
|
|
448614
|
+
stateMutability: "view"
|
|
448615
|
+
},
|
|
448616
|
+
{
|
|
448617
|
+
type: "function",
|
|
448618
|
+
name: "getSigners",
|
|
448619
|
+
inputs: [],
|
|
448620
|
+
outputs: [{ name: "", type: "address[]", internalType: "address[]" }],
|
|
448621
|
+
stateMutability: "view"
|
|
448622
|
+
},
|
|
448623
|
+
{
|
|
448624
|
+
type: "function",
|
|
448625
|
+
name: "isRecoveryModeEnabled",
|
|
448626
|
+
inputs: [],
|
|
448627
|
+
outputs: [{ name: "", type: "bool", internalType: "bool" }],
|
|
448628
|
+
stateMutability: "view"
|
|
448629
|
+
},
|
|
448630
|
+
{
|
|
448631
|
+
type: "function",
|
|
448632
|
+
name: "isSigner",
|
|
448633
|
+
inputs: [{ name: "account", type: "address", internalType: "address" }],
|
|
448634
|
+
outputs: [{ name: "", type: "bool", internalType: "bool" }],
|
|
448635
|
+
stateMutability: "view"
|
|
448636
|
+
},
|
|
448637
|
+
{
|
|
448638
|
+
type: "function",
|
|
448639
|
+
name: "lastBatchHash",
|
|
448640
|
+
inputs: [],
|
|
448641
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
448642
|
+
stateMutability: "view"
|
|
448643
|
+
},
|
|
448644
|
+
{
|
|
448645
|
+
type: "function",
|
|
448646
|
+
name: "owner",
|
|
448647
|
+
inputs: [],
|
|
448648
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
448649
|
+
stateMutability: "view"
|
|
448650
|
+
},
|
|
448651
|
+
{
|
|
448652
|
+
type: "function",
|
|
448653
|
+
name: "removeSigner",
|
|
448654
|
+
inputs: [{ name: "signer", type: "address", internalType: "address" }],
|
|
448655
|
+
outputs: [],
|
|
448656
|
+
stateMutability: "nonpayable"
|
|
448657
|
+
},
|
|
448658
|
+
{
|
|
448659
|
+
type: "function",
|
|
448660
|
+
name: "renounceOwnership",
|
|
448661
|
+
inputs: [],
|
|
448662
|
+
outputs: [],
|
|
448663
|
+
stateMutability: "nonpayable"
|
|
448664
|
+
},
|
|
448665
|
+
{
|
|
448666
|
+
type: "function",
|
|
448667
|
+
name: "setConfirmationThreshold",
|
|
448668
|
+
inputs: [
|
|
448669
|
+
{
|
|
448670
|
+
name: "newConfirmationThreshold",
|
|
448671
|
+
type: "uint8",
|
|
448672
|
+
internalType: "uint8"
|
|
448673
|
+
}
|
|
448674
|
+
],
|
|
448675
|
+
outputs: [],
|
|
448676
|
+
stateMutability: "nonpayable"
|
|
448677
|
+
},
|
|
448678
|
+
{
|
|
448679
|
+
type: "function",
|
|
448680
|
+
name: "signBatch",
|
|
448681
|
+
inputs: [
|
|
448682
|
+
{ name: "batchHash", type: "bytes32", internalType: "bytes32" },
|
|
448683
|
+
{ name: "signature", type: "bytes", internalType: "bytes" }
|
|
448684
|
+
],
|
|
448685
|
+
outputs: [],
|
|
448686
|
+
stateMutability: "nonpayable"
|
|
448687
|
+
},
|
|
448688
|
+
{
|
|
448689
|
+
type: "function",
|
|
448690
|
+
name: "submitBatch",
|
|
448691
|
+
inputs: [
|
|
448692
|
+
{ name: "name", type: "string", internalType: "string" },
|
|
448693
|
+
{
|
|
448694
|
+
name: "calls",
|
|
448695
|
+
type: "tuple[]",
|
|
448696
|
+
internalType: "struct CrossChainCall[]",
|
|
448697
|
+
components: [
|
|
448698
|
+
{ name: "chainId", type: "uint256", internalType: "uint256" },
|
|
448699
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
448700
|
+
{ name: "callData", type: "bytes", internalType: "bytes" }
|
|
448701
|
+
]
|
|
448702
|
+
},
|
|
448703
|
+
{ name: "prevHash", type: "bytes32", internalType: "bytes32" }
|
|
448704
|
+
],
|
|
448705
|
+
outputs: [],
|
|
448706
|
+
stateMutability: "nonpayable"
|
|
448707
|
+
},
|
|
448708
|
+
{
|
|
448709
|
+
type: "function",
|
|
448710
|
+
name: "transferOwnership",
|
|
448711
|
+
inputs: [{ name: "newOwner", type: "address", internalType: "address" }],
|
|
448712
|
+
outputs: [],
|
|
448713
|
+
stateMutability: "nonpayable"
|
|
448714
|
+
},
|
|
448715
|
+
{
|
|
448716
|
+
type: "function",
|
|
448717
|
+
name: "version",
|
|
448718
|
+
inputs: [],
|
|
448719
|
+
outputs: [{ name: "", type: "uint256", internalType: "uint256" }],
|
|
448720
|
+
stateMutability: "view"
|
|
448721
|
+
},
|
|
448722
|
+
{
|
|
448723
|
+
type: "event",
|
|
448724
|
+
name: "AddSigner",
|
|
448725
|
+
inputs: [
|
|
448726
|
+
{
|
|
448727
|
+
name: "signer",
|
|
448728
|
+
type: "address",
|
|
448729
|
+
indexed: true,
|
|
448730
|
+
internalType: "address"
|
|
448731
|
+
}
|
|
448732
|
+
],
|
|
448733
|
+
anonymous: false
|
|
448734
|
+
},
|
|
448735
|
+
{ type: "event", name: "DisableRecoveryMode", inputs: [], anonymous: false },
|
|
448736
|
+
{ type: "event", name: "EIP712DomainChanged", inputs: [], anonymous: false },
|
|
448737
|
+
{
|
|
448738
|
+
type: "event",
|
|
448739
|
+
name: "EnableRecoveryMode",
|
|
448740
|
+
inputs: [
|
|
448741
|
+
{
|
|
448742
|
+
name: "startingBatchHash",
|
|
448743
|
+
type: "bytes32",
|
|
448744
|
+
indexed: true,
|
|
448745
|
+
internalType: "bytes32"
|
|
448746
|
+
}
|
|
448747
|
+
],
|
|
448748
|
+
anonymous: false
|
|
448749
|
+
},
|
|
448750
|
+
{
|
|
448751
|
+
type: "event",
|
|
448752
|
+
name: "ExecuteBatch",
|
|
448753
|
+
inputs: [
|
|
448754
|
+
{
|
|
448755
|
+
name: "batchHash",
|
|
448756
|
+
type: "bytes32",
|
|
448757
|
+
indexed: true,
|
|
448758
|
+
internalType: "bytes32"
|
|
448759
|
+
}
|
|
448760
|
+
],
|
|
448761
|
+
anonymous: false
|
|
448762
|
+
},
|
|
448763
|
+
{
|
|
448764
|
+
type: "event",
|
|
448765
|
+
name: "OwnershipTransferred",
|
|
448766
|
+
inputs: [
|
|
448767
|
+
{
|
|
448768
|
+
name: "previousOwner",
|
|
448769
|
+
type: "address",
|
|
448770
|
+
indexed: true,
|
|
448771
|
+
internalType: "address"
|
|
448772
|
+
},
|
|
448773
|
+
{
|
|
448774
|
+
name: "newOwner",
|
|
448775
|
+
type: "address",
|
|
448776
|
+
indexed: true,
|
|
448777
|
+
internalType: "address"
|
|
448778
|
+
}
|
|
448779
|
+
],
|
|
448780
|
+
anonymous: false
|
|
448781
|
+
},
|
|
448782
|
+
{
|
|
448783
|
+
type: "event",
|
|
448784
|
+
name: "RemoveSigner",
|
|
448785
|
+
inputs: [
|
|
448786
|
+
{
|
|
448787
|
+
name: "signer",
|
|
448788
|
+
type: "address",
|
|
448789
|
+
indexed: true,
|
|
448790
|
+
internalType: "address"
|
|
448791
|
+
}
|
|
448792
|
+
],
|
|
448793
|
+
anonymous: false
|
|
448794
|
+
},
|
|
448795
|
+
{
|
|
448796
|
+
type: "event",
|
|
448797
|
+
name: "SetConfirmationThreshold",
|
|
448798
|
+
inputs: [
|
|
448799
|
+
{
|
|
448800
|
+
name: "newConfirmationThreshold",
|
|
448801
|
+
type: "uint8",
|
|
448802
|
+
indexed: false,
|
|
448803
|
+
internalType: "uint8"
|
|
448804
|
+
}
|
|
448805
|
+
],
|
|
448806
|
+
anonymous: false
|
|
448807
|
+
},
|
|
448808
|
+
{
|
|
448809
|
+
type: "event",
|
|
448810
|
+
name: "SignBatch",
|
|
448811
|
+
inputs: [
|
|
448812
|
+
{
|
|
448813
|
+
name: "batchHash",
|
|
448814
|
+
type: "bytes32",
|
|
448815
|
+
indexed: true,
|
|
448816
|
+
internalType: "bytes32"
|
|
448817
|
+
},
|
|
448818
|
+
{
|
|
448819
|
+
name: "signer",
|
|
448820
|
+
type: "address",
|
|
448821
|
+
indexed: true,
|
|
448822
|
+
internalType: "address"
|
|
448823
|
+
}
|
|
448824
|
+
],
|
|
448825
|
+
anonymous: false
|
|
448826
|
+
},
|
|
448827
|
+
{
|
|
448828
|
+
type: "event",
|
|
448829
|
+
name: "SubmitBatch",
|
|
448830
|
+
inputs: [
|
|
448831
|
+
{
|
|
448832
|
+
name: "batchHash",
|
|
448833
|
+
type: "bytes32",
|
|
448834
|
+
indexed: true,
|
|
448835
|
+
internalType: "bytes32"
|
|
448836
|
+
}
|
|
448837
|
+
],
|
|
448838
|
+
anonymous: false
|
|
448839
|
+
},
|
|
448840
|
+
{
|
|
448841
|
+
type: "error",
|
|
448842
|
+
name: "BatchIsNotSubmittedException",
|
|
448843
|
+
inputs: [{ name: "batchHash", type: "bytes32", internalType: "bytes32" }]
|
|
448844
|
+
},
|
|
448845
|
+
{
|
|
448846
|
+
type: "error",
|
|
448847
|
+
name: "CallerIsNotSelfException",
|
|
448848
|
+
inputs: [{ name: "caller", type: "address", internalType: "address" }]
|
|
448849
|
+
},
|
|
448850
|
+
{ type: "error", name: "CantBeExecutedOnCurrentChainException", inputs: [] },
|
|
448851
|
+
{
|
|
448852
|
+
type: "error",
|
|
448853
|
+
name: "DuplicateSignatureException",
|
|
448854
|
+
inputs: [{ name: "signer", type: "address", internalType: "address" }]
|
|
448855
|
+
},
|
|
448856
|
+
{
|
|
448857
|
+
type: "error",
|
|
448858
|
+
name: "InsufficientNumberOfSignaturesException",
|
|
448859
|
+
inputs: []
|
|
448860
|
+
},
|
|
448861
|
+
{ type: "error", name: "InvalidBatchException", inputs: [] },
|
|
448862
|
+
{ type: "error", name: "InvalidConfirmationThresholdException", inputs: [] },
|
|
448863
|
+
{ type: "error", name: "InvalidPrevHashException", inputs: [] },
|
|
448864
|
+
{ type: "error", name: "InvalidRecoveryModeMessageException", inputs: [] },
|
|
448865
|
+
{ type: "error", name: "InvalidShortString", inputs: [] },
|
|
448866
|
+
{ type: "error", name: "InvalidSignerAddressException", inputs: [] },
|
|
448867
|
+
{
|
|
448868
|
+
type: "error",
|
|
448869
|
+
name: "SignerIsAlreadyApprovedException",
|
|
448870
|
+
inputs: [{ name: "signer", type: "address", internalType: "address" }]
|
|
448871
|
+
},
|
|
448872
|
+
{
|
|
448873
|
+
type: "error",
|
|
448874
|
+
name: "SignerIsNotApprovedException",
|
|
448875
|
+
inputs: [{ name: "signer", type: "address", internalType: "address" }]
|
|
448876
|
+
},
|
|
448877
|
+
{
|
|
448878
|
+
type: "error",
|
|
448879
|
+
name: "StringTooLong",
|
|
448880
|
+
inputs: [{ name: "str", type: "string", internalType: "string" }]
|
|
448881
|
+
}
|
|
448882
|
+
];
|
|
448883
|
+
var CrossChainMultisigParser = class extends AbstractParser {
|
|
448884
|
+
constructor(contractType) {
|
|
448885
|
+
super(contractType);
|
|
448886
|
+
this._abi = abi25;
|
|
448887
|
+
}
|
|
448888
|
+
async parse(to, calldata, signature, metaRepo) {
|
|
448889
|
+
if (!metaRepo) {
|
|
448890
|
+
throw new Error(`meta repo not found to parse create2 transaction`);
|
|
448891
|
+
}
|
|
448892
|
+
const data = await super.parse(to, calldata, signature, metaRepo);
|
|
448893
|
+
if (data.contract === "CROSS_CHAIN_MULTISIG" && data.method === "submitBatch(string,(uint256,address,bytes)[],bytes32)") {
|
|
448894
|
+
return this.#parseSubmitBatch(data);
|
|
448895
|
+
}
|
|
448896
|
+
return data;
|
|
448897
|
+
}
|
|
448898
|
+
async #parseSubmitBatch(data) {
|
|
448899
|
+
const rawCalls = data.parameters[1].raw.value;
|
|
448900
|
+
const calls = [];
|
|
448901
|
+
for (const rc of rawCalls) {
|
|
448902
|
+
const entry = container.addressTree.getContract(rc.target);
|
|
448903
|
+
if (!entry) {
|
|
448904
|
+
throw new Error(`found create2factory.${data.method} to ${rc.target}, but cannot find it in tree`);
|
|
448905
|
+
}
|
|
448906
|
+
this.logger.debug(`parsing external call to ${entry.address}`);
|
|
448907
|
+
const parser = parserFor(entry);
|
|
448908
|
+
const parsedCall = await parser.parse(rc.target, rc.callData);
|
|
448909
|
+
calls.push({ ...parsedCall, chainId: Number(rc.chainId) });
|
|
448910
|
+
}
|
|
448911
|
+
return { ...data, calls };
|
|
448912
|
+
}
|
|
448913
|
+
};
|
|
448914
|
+
|
|
448296
448915
|
// ../../packages/node/dist/parsers/DataCompressorV2Parser.js
|
|
448297
448916
|
var DataCompressorV2Parser = class extends AbstractParser {
|
|
448298
448917
|
constructor(contractType) {
|
|
@@ -449104,6 +449723,261 @@ var InflationAttackBlockerParser = class extends AbstractParser {
|
|
|
449104
449723
|
}
|
|
449105
449724
|
};
|
|
449106
449725
|
|
|
449726
|
+
// ../../packages/node/dist/parsers/InstanceManagerParser.js
|
|
449727
|
+
var abi26 = [
|
|
449728
|
+
{
|
|
449729
|
+
type: "constructor",
|
|
449730
|
+
inputs: [{ name: "owner_", type: "address", internalType: "address" }],
|
|
449731
|
+
stateMutability: "nonpayable"
|
|
449732
|
+
},
|
|
449733
|
+
{
|
|
449734
|
+
type: "function",
|
|
449735
|
+
name: "acceptGovernance",
|
|
449736
|
+
inputs: [],
|
|
449737
|
+
outputs: [],
|
|
449738
|
+
stateMutability: "nonpayable"
|
|
449739
|
+
},
|
|
449740
|
+
{
|
|
449741
|
+
type: "function",
|
|
449742
|
+
name: "activate",
|
|
449743
|
+
inputs: [
|
|
449744
|
+
{ name: "instanceOwner", type: "address", internalType: "address" },
|
|
449745
|
+
{ name: "treasury", type: "address", internalType: "address" },
|
|
449746
|
+
{ name: "weth", type: "address", internalType: "address" },
|
|
449747
|
+
{ name: "gear", type: "address", internalType: "address" }
|
|
449748
|
+
],
|
|
449749
|
+
outputs: [],
|
|
449750
|
+
stateMutability: "nonpayable"
|
|
449751
|
+
},
|
|
449752
|
+
{
|
|
449753
|
+
type: "function",
|
|
449754
|
+
name: "addressProvider",
|
|
449755
|
+
inputs: [],
|
|
449756
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449757
|
+
stateMutability: "view"
|
|
449758
|
+
},
|
|
449759
|
+
{
|
|
449760
|
+
type: "function",
|
|
449761
|
+
name: "bytecodeRepository",
|
|
449762
|
+
inputs: [],
|
|
449763
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449764
|
+
stateMutability: "view"
|
|
449765
|
+
},
|
|
449766
|
+
{
|
|
449767
|
+
type: "function",
|
|
449768
|
+
name: "configureGlobal",
|
|
449769
|
+
inputs: [
|
|
449770
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
449771
|
+
{ name: "data", type: "bytes", internalType: "bytes" }
|
|
449772
|
+
],
|
|
449773
|
+
outputs: [],
|
|
449774
|
+
stateMutability: "nonpayable"
|
|
449775
|
+
},
|
|
449776
|
+
{
|
|
449777
|
+
type: "function",
|
|
449778
|
+
name: "configureLocal",
|
|
449779
|
+
inputs: [
|
|
449780
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
449781
|
+
{ name: "data", type: "bytes", internalType: "bytes" }
|
|
449782
|
+
],
|
|
449783
|
+
outputs: [],
|
|
449784
|
+
stateMutability: "nonpayable"
|
|
449785
|
+
},
|
|
449786
|
+
{
|
|
449787
|
+
type: "function",
|
|
449788
|
+
name: "configureTreasury",
|
|
449789
|
+
inputs: [
|
|
449790
|
+
{ name: "target", type: "address", internalType: "address" },
|
|
449791
|
+
{ name: "data", type: "bytes", internalType: "bytes" }
|
|
449792
|
+
],
|
|
449793
|
+
outputs: [],
|
|
449794
|
+
stateMutability: "nonpayable"
|
|
449795
|
+
},
|
|
449796
|
+
{
|
|
449797
|
+
type: "function",
|
|
449798
|
+
name: "contractType",
|
|
449799
|
+
inputs: [],
|
|
449800
|
+
outputs: [{ name: "", type: "bytes32", internalType: "bytes32" }],
|
|
449801
|
+
stateMutability: "view"
|
|
449802
|
+
},
|
|
449803
|
+
{
|
|
449804
|
+
type: "function",
|
|
449805
|
+
name: "crossChainGovernanceProxy",
|
|
449806
|
+
inputs: [],
|
|
449807
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449808
|
+
stateMutability: "view"
|
|
449809
|
+
},
|
|
449810
|
+
{
|
|
449811
|
+
type: "function",
|
|
449812
|
+
name: "deploySystemContract",
|
|
449813
|
+
inputs: [
|
|
449814
|
+
{ name: "contractType_", type: "bytes32", internalType: "bytes32" },
|
|
449815
|
+
{ name: "version_", type: "uint256", internalType: "uint256" },
|
|
449816
|
+
{ name: "saveVersion", type: "bool", internalType: "bool" }
|
|
449817
|
+
],
|
|
449818
|
+
outputs: [],
|
|
449819
|
+
stateMutability: "nonpayable"
|
|
449820
|
+
},
|
|
449821
|
+
{
|
|
449822
|
+
type: "function",
|
|
449823
|
+
name: "instanceManagerProxy",
|
|
449824
|
+
inputs: [],
|
|
449825
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449826
|
+
stateMutability: "view"
|
|
449827
|
+
},
|
|
449828
|
+
{
|
|
449829
|
+
type: "function",
|
|
449830
|
+
name: "isActivated",
|
|
449831
|
+
inputs: [],
|
|
449832
|
+
outputs: [{ name: "", type: "bool", internalType: "bool" }],
|
|
449833
|
+
stateMutability: "view"
|
|
449834
|
+
},
|
|
449835
|
+
{
|
|
449836
|
+
type: "function",
|
|
449837
|
+
name: "owner",
|
|
449838
|
+
inputs: [],
|
|
449839
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449840
|
+
stateMutability: "view"
|
|
449841
|
+
},
|
|
449842
|
+
{
|
|
449843
|
+
type: "function",
|
|
449844
|
+
name: "pendingGovernance",
|
|
449845
|
+
inputs: [],
|
|
449846
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449847
|
+
stateMutability: "view"
|
|
449848
|
+
},
|
|
449849
|
+
{
|
|
449850
|
+
type: "function",
|
|
449851
|
+
name: "renounceOwnership",
|
|
449852
|
+
inputs: [],
|
|
449853
|
+
outputs: [],
|
|
449854
|
+
stateMutability: "nonpayable"
|
|
449855
|
+
},
|
|
449856
|
+
{
|
|
449857
|
+
type: "function",
|
|
449858
|
+
name: "setGlobalAddress",
|
|
449859
|
+
inputs: [
|
|
449860
|
+
{ name: "key", type: "bytes32", internalType: "bytes32" },
|
|
449861
|
+
{ name: "addr", type: "address", internalType: "address" },
|
|
449862
|
+
{ name: "saveVersion", type: "bool", internalType: "bool" }
|
|
449863
|
+
],
|
|
449864
|
+
outputs: [],
|
|
449865
|
+
stateMutability: "nonpayable"
|
|
449866
|
+
},
|
|
449867
|
+
{
|
|
449868
|
+
type: "function",
|
|
449869
|
+
name: "setLocalAddress",
|
|
449870
|
+
inputs: [
|
|
449871
|
+
{ name: "key", type: "bytes32", internalType: "bytes32" },
|
|
449872
|
+
{ name: "addr", type: "address", internalType: "address" },
|
|
449873
|
+
{ name: "saveVersion", type: "bool", internalType: "bool" }
|
|
449874
|
+
],
|
|
449875
|
+
outputs: [],
|
|
449876
|
+
stateMutability: "nonpayable"
|
|
449877
|
+
},
|
|
449878
|
+
{
|
|
449879
|
+
type: "function",
|
|
449880
|
+
name: "setPendingGovernance",
|
|
449881
|
+
inputs: [
|
|
449882
|
+
{ name: "newGovernance", type: "address", internalType: "address" }
|
|
449883
|
+
],
|
|
449884
|
+
outputs: [],
|
|
449885
|
+
stateMutability: "nonpayable"
|
|
449886
|
+
},
|
|
449887
|
+
{
|
|
449888
|
+
type: "function",
|
|
449889
|
+
name: "transferOwnership",
|
|
449890
|
+
inputs: [{ name: "newOwner", type: "address", internalType: "address" }],
|
|
449891
|
+
outputs: [],
|
|
449892
|
+
stateMutability: "nonpayable"
|
|
449893
|
+
},
|
|
449894
|
+
{
|
|
449895
|
+
type: "function",
|
|
449896
|
+
name: "treasuryProxy",
|
|
449897
|
+
inputs: [],
|
|
449898
|
+
outputs: [{ name: "", type: "address", internalType: "address" }],
|
|
449899
|
+
stateMutability: "view"
|
|
449900
|
+
},
|
|
449901
|
+
{
|
|
449902
|
+
type: "function",
|
|
449903
|
+
name: "version",
|
|
449904
|
+
inputs: [],
|
|
449905
|
+
outputs: [{ name: "", type: "uint256", internalType: "uint256" }],
|
|
449906
|
+
stateMutability: "view"
|
|
449907
|
+
},
|
|
449908
|
+
{
|
|
449909
|
+
type: "event",
|
|
449910
|
+
name: "AcceptGovernance",
|
|
449911
|
+
inputs: [
|
|
449912
|
+
{
|
|
449913
|
+
name: "newGovernance",
|
|
449914
|
+
type: "address",
|
|
449915
|
+
indexed: true,
|
|
449916
|
+
internalType: "address"
|
|
449917
|
+
}
|
|
449918
|
+
],
|
|
449919
|
+
anonymous: false
|
|
449920
|
+
},
|
|
449921
|
+
{
|
|
449922
|
+
type: "event",
|
|
449923
|
+
name: "OwnershipTransferred",
|
|
449924
|
+
inputs: [
|
|
449925
|
+
{
|
|
449926
|
+
name: "previousOwner",
|
|
449927
|
+
type: "address",
|
|
449928
|
+
indexed: true,
|
|
449929
|
+
internalType: "address"
|
|
449930
|
+
},
|
|
449931
|
+
{
|
|
449932
|
+
name: "newOwner",
|
|
449933
|
+
type: "address",
|
|
449934
|
+
indexed: true,
|
|
449935
|
+
internalType: "address"
|
|
449936
|
+
}
|
|
449937
|
+
],
|
|
449938
|
+
anonymous: false
|
|
449939
|
+
},
|
|
449940
|
+
{
|
|
449941
|
+
type: "event",
|
|
449942
|
+
name: "SetPendingGovernance",
|
|
449943
|
+
inputs: [
|
|
449944
|
+
{
|
|
449945
|
+
name: "newGovernance",
|
|
449946
|
+
type: "address",
|
|
449947
|
+
indexed: true,
|
|
449948
|
+
internalType: "address"
|
|
449949
|
+
}
|
|
449950
|
+
],
|
|
449951
|
+
anonymous: false
|
|
449952
|
+
},
|
|
449953
|
+
{
|
|
449954
|
+
type: "error",
|
|
449955
|
+
name: "CallerIsNotCrossChainGovernanceException",
|
|
449956
|
+
inputs: [{ name: "caller", type: "address", internalType: "address" }]
|
|
449957
|
+
},
|
|
449958
|
+
{
|
|
449959
|
+
type: "error",
|
|
449960
|
+
name: "CallerIsNotPendingGovernanceException",
|
|
449961
|
+
inputs: [{ name: "caller", type: "address", internalType: "address" }]
|
|
449962
|
+
},
|
|
449963
|
+
{
|
|
449964
|
+
type: "error",
|
|
449965
|
+
name: "CallerIsNotTreasuryException",
|
|
449966
|
+
inputs: [{ name: "caller", type: "address", internalType: "address" }]
|
|
449967
|
+
},
|
|
449968
|
+
{
|
|
449969
|
+
type: "error",
|
|
449970
|
+
name: "InvalidKeyException",
|
|
449971
|
+
inputs: [{ name: "key", type: "bytes32", internalType: "bytes32" }]
|
|
449972
|
+
}
|
|
449973
|
+
];
|
|
449974
|
+
var InstanceManagerParser = class extends AbstractParser {
|
|
449975
|
+
constructor(contractType) {
|
|
449976
|
+
super(contractType);
|
|
449977
|
+
this._abi = abi26;
|
|
449978
|
+
}
|
|
449979
|
+
};
|
|
449980
|
+
|
|
449107
449981
|
// ../../packages/node/dist/parsers/InterestRateModelV1Parser.js
|
|
449108
449982
|
var InterestRateModelV1Parser = class extends AbstractParser {
|
|
449109
449983
|
constructor(contractType) {
|
|
@@ -449443,6 +450317,8 @@ var CONTRACT_NAME_TO_TYPE = new Map([
|
|
|
449443
450317
|
["ZapperRegister", "ZAPPER_REGISTER"],
|
|
449444
450318
|
["MultiPause", "MULTIPAUSE"],
|
|
449445
450319
|
["BatchesChain", "BATCH_CHAIN"],
|
|
450320
|
+
["InstanceManager", "INSTANCE_MANAGER"],
|
|
450321
|
+
["CrossChainMultisig", "CROSS_CHAIN_MULTISIG"],
|
|
449446
450322
|
...Object.keys(ZAPPER_CONSTRUCTORS).map((z) => [z, "ZAPPER"]),
|
|
449447
450323
|
...Object.entries(ADAPTER_NAMES),
|
|
449448
450324
|
...Object.entries(ADAPTER_HELPER_NAMES),
|
|
@@ -449495,6 +450371,8 @@ function parserForContractType(contract, version5, contractName) {
|
|
|
449495
450371
|
return new CreditManagerV2Parser(contract);
|
|
449496
450372
|
case "CREDIT_MANAGER_V3":
|
|
449497
450373
|
return new CreditManagerV3Parser(contract);
|
|
450374
|
+
case "CROSS_CHAIN_MULTISIG":
|
|
450375
|
+
return new CrossChainMultisigParser(contract);
|
|
449498
450376
|
case "DATA_COMPRESSOR_V2":
|
|
449499
450377
|
return new DataCompressorV2Parser(contract);
|
|
449500
450378
|
case "DATA_COMPRESSOR_V210":
|
|
@@ -449517,6 +450395,8 @@ function parserForContractType(contract, version5, contractName) {
|
|
|
449517
450395
|
return new InterestRateModelV1Parser(contract);
|
|
449518
450396
|
case "INTEREST_RATE_MODEL_V3":
|
|
449519
450397
|
return new InterestRateModelV3Parser(contract);
|
|
450398
|
+
case "INSTANCE_MANAGER":
|
|
450399
|
+
return new InstanceManagerParser(contract);
|
|
449520
450400
|
case "MULTIPAUSE":
|
|
449521
450401
|
return new MultiPauseParser(contract);
|
|
449522
450402
|
case "ONE_INCH_FARMING_POOL":
|
|
@@ -451491,7 +452371,7 @@ function getRenderer(opts) {
|
|
|
451491
452371
|
var package_default = {
|
|
451492
452372
|
name: "@gearbox-protocol/deploy-tools",
|
|
451493
452373
|
description: "Gearbox deploy tools",
|
|
451494
|
-
version: "5.45.
|
|
452374
|
+
version: "5.45.18",
|
|
451495
452375
|
homepage: "https://gearbox.fi",
|
|
451496
452376
|
keywords: [
|
|
451497
452377
|
"gearbox"
|
|
@@ -452078,12 +452958,12 @@ var PartialLiquidationBotBaseContract = class extends BaseContract {
|
|
|
452078
452958
|
};
|
|
452079
452959
|
|
|
452080
452960
|
// ../../node_modules/@gearbox-protocol/sdk/dist/esm/plugins/bots/PartialLiquidationBotV300Contract.js
|
|
452081
|
-
var
|
|
452961
|
+
var abi27 = iPartialLiquidationBotV300Abi;
|
|
452082
452962
|
var PartialLiquidationBotV300Contract = class extends PartialLiquidationBotBaseContract {
|
|
452083
452963
|
#botType;
|
|
452084
452964
|
constructor(sdk, args, marketConfigurator) {
|
|
452085
452965
|
super(sdk, {
|
|
452086
|
-
abi:
|
|
452966
|
+
abi: abi27,
|
|
452087
452967
|
...args.baseParams,
|
|
452088
452968
|
requiredPermissions: args.requiredPermissions,
|
|
452089
452969
|
marketConfigurator,
|
|
@@ -452116,11 +452996,11 @@ var PartialLiquidationBotV300Contract = class extends PartialLiquidationBotBaseC
|
|
|
452116
452996
|
};
|
|
452117
452997
|
|
|
452118
452998
|
// ../../node_modules/@gearbox-protocol/sdk/dist/esm/plugins/bots/PartialLiquidationBotV310Contract.js
|
|
452119
|
-
var
|
|
452999
|
+
var abi28 = iPartialLiquidationBotV310Abi;
|
|
452120
453000
|
var PartialLiquidationBotV310Contract = class extends PartialLiquidationBotBaseContract {
|
|
452121
453001
|
constructor(sdk, args, marketConfigurator) {
|
|
452122
453002
|
super(sdk, {
|
|
452123
|
-
abi:
|
|
453003
|
+
abi: abi28,
|
|
452124
453004
|
...args.baseParams,
|
|
452125
453005
|
requiredPermissions: args.requiredPermissions,
|
|
452126
453006
|
marketConfigurator,
|