@gearbox-protocol/deploy-tools 5.16.4 → 5.16.6
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 +81 -11
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -394030,7 +394030,46 @@ function normalizeTimelockTx(t) {
|
|
|
394030
394030
|
};
|
|
394031
394031
|
}
|
|
394032
394032
|
function normalizeSafeApiBatch(tx) {
|
|
394033
|
-
const transactions = tx.dataDecoded.parameters[0].valueDecoded.map(
|
|
394033
|
+
const transactions = tx.dataDecoded.parameters[0].valueDecoded.map(normalizeMultisendTransactionDecoded);
|
|
394034
|
+
return {
|
|
394035
|
+
id: tx.safeTxHash,
|
|
394036
|
+
safeTxHash: tx.safeTxHash,
|
|
394037
|
+
description: "",
|
|
394038
|
+
// TODO
|
|
394039
|
+
transactions: normalizeTransactions({ transactions }),
|
|
394040
|
+
type: "governor"
|
|
394041
|
+
// TODO: determine, or wait till they are made the same in deploy-v3
|
|
394042
|
+
};
|
|
394043
|
+
}
|
|
394044
|
+
function normalizeMultisendTransactionDecoded(t) {
|
|
394045
|
+
if (!t.dataDecoded) {
|
|
394046
|
+
try {
|
|
394047
|
+
const { args, functionName } = decodeFunctionData({
|
|
394048
|
+
abi: iGovernorAbi,
|
|
394049
|
+
data: t.data
|
|
394050
|
+
});
|
|
394051
|
+
const funcAbi = getAbiItem({
|
|
394052
|
+
abi: iGovernorAbi,
|
|
394053
|
+
name: functionName
|
|
394054
|
+
});
|
|
394055
|
+
return {
|
|
394056
|
+
to: t.to,
|
|
394057
|
+
value: t.value,
|
|
394058
|
+
contractMethod: {
|
|
394059
|
+
name: functionName,
|
|
394060
|
+
inputs: funcAbi.inputs.map((i) => ({
|
|
394061
|
+
name: i.name,
|
|
394062
|
+
type: i.type
|
|
394063
|
+
})),
|
|
394064
|
+
payable: false
|
|
394065
|
+
},
|
|
394066
|
+
contractInputsValues: Object.fromEntries(args.map((v, i) => [funcAbi.inputs[i].name, v]))
|
|
394067
|
+
};
|
|
394068
|
+
} catch (e) {
|
|
394069
|
+
throw new Error(`multisend tx has no dataDecoded and is not a governor tx: ${e}`);
|
|
394070
|
+
}
|
|
394071
|
+
}
|
|
394072
|
+
return {
|
|
394034
394073
|
to: t.to,
|
|
394035
394074
|
value: t.value,
|
|
394036
394075
|
contractMethod: {
|
|
@@ -394042,15 +394081,6 @@ function normalizeSafeApiBatch(tx) {
|
|
|
394042
394081
|
payable: false
|
|
394043
394082
|
},
|
|
394044
394083
|
contractInputsValues: Object.fromEntries(t.dataDecoded.parameters.map((p) => [p.name, p.value]))
|
|
394045
|
-
}));
|
|
394046
|
-
return {
|
|
394047
|
-
id: tx.safeTxHash,
|
|
394048
|
-
safeTxHash: tx.safeTxHash,
|
|
394049
|
-
description: "",
|
|
394050
|
-
// TODO
|
|
394051
|
-
transactions: normalizeTransactions({ transactions }),
|
|
394052
|
-
type: "governor"
|
|
394053
|
-
// TODO: determine, or wait till they are made the same in deploy-v3
|
|
394054
394084
|
};
|
|
394055
394085
|
}
|
|
394056
394086
|
|
|
@@ -408766,12 +408796,50 @@ var CreditFacadeV2Parser = class extends AbstractParser {
|
|
|
408766
408796
|
}
|
|
408767
408797
|
};
|
|
408768
408798
|
|
|
408799
|
+
// ../../node_modules/@gearbox-protocol/sdk/dist/esm/abi/iPausable.mjs
|
|
408800
|
+
var iPausableAbi2 = [
|
|
408801
|
+
{
|
|
408802
|
+
type: "function",
|
|
408803
|
+
name: "paused",
|
|
408804
|
+
inputs: [],
|
|
408805
|
+
outputs: [{ name: "", type: "bool", internalType: "bool" }],
|
|
408806
|
+
stateMutability: "view"
|
|
408807
|
+
},
|
|
408808
|
+
{
|
|
408809
|
+
type: "event",
|
|
408810
|
+
name: "Paused",
|
|
408811
|
+
inputs: [
|
|
408812
|
+
{
|
|
408813
|
+
name: "account",
|
|
408814
|
+
type: "address",
|
|
408815
|
+
indexed: false,
|
|
408816
|
+
internalType: "address"
|
|
408817
|
+
}
|
|
408818
|
+
],
|
|
408819
|
+
anonymous: false
|
|
408820
|
+
},
|
|
408821
|
+
{
|
|
408822
|
+
type: "event",
|
|
408823
|
+
name: "Unpaused",
|
|
408824
|
+
inputs: [
|
|
408825
|
+
{
|
|
408826
|
+
name: "account",
|
|
408827
|
+
type: "address",
|
|
408828
|
+
indexed: false,
|
|
408829
|
+
internalType: "address"
|
|
408830
|
+
}
|
|
408831
|
+
],
|
|
408832
|
+
anonymous: false
|
|
408833
|
+
}
|
|
408834
|
+
];
|
|
408835
|
+
|
|
408769
408836
|
// ../../packages/node/dist/parsers/CreditFacadeV3Parser.js
|
|
408770
408837
|
var CreditFacadeV3Parser = class extends AbstractParser {
|
|
408771
408838
|
constructor(contractType) {
|
|
408772
408839
|
super(contractType, "constructor(address creditManager, address degenNFT, bool expirable)");
|
|
408773
408840
|
this._abi = [
|
|
408774
408841
|
...iCreditFacadeV3Abi,
|
|
408842
|
+
...iPausableAbi2,
|
|
408775
408843
|
...parseAbi(["function setController(address newController) external"])
|
|
408776
408844
|
];
|
|
408777
408845
|
this.parameterParsers = {
|
|
@@ -409810,6 +409878,7 @@ var PoolV3Parser = class extends AbstractParser {
|
|
|
409810
409878
|
super(contractType, "constructor(address addressProvider, address underlyingToken, address interestRateModel, uint256 totalDebtLimit, string name, string symbol)");
|
|
409811
409879
|
this._abi = [
|
|
409812
409880
|
...iPoolV3Abi,
|
|
409881
|
+
...iPausableAbi2,
|
|
409813
409882
|
...parseAbi(["function setController(address newController) external"])
|
|
409814
409883
|
];
|
|
409815
409884
|
this.parameterParsers = {
|
|
@@ -410165,6 +410234,7 @@ var UpdateParser = class extends ProviderBase {
|
|
|
410165
410234
|
const parsed = await this.#parseNormalizedBatch(normalizeSafeApiBatch(txs[i]), i, total);
|
|
410166
410235
|
this.#output.batches.push(parsed);
|
|
410167
410236
|
} catch (e) {
|
|
410237
|
+
this.logger.error(e, `error parsing batch ${i}`);
|
|
410168
410238
|
this.#output.batches.push({
|
|
410169
410239
|
id: txs[i].safeTxHash,
|
|
410170
410240
|
error: `${e}`.replaceAll("\n", "\\n")
|
|
@@ -411965,7 +412035,7 @@ function getRenderer(opts) {
|
|
|
411965
412035
|
var package_default = {
|
|
411966
412036
|
name: "@gearbox-protocol/deploy-tools",
|
|
411967
412037
|
description: "Gearbox deploy tools",
|
|
411968
|
-
version: "5.16.
|
|
412038
|
+
version: "5.16.6",
|
|
411969
412039
|
homepage: "https://gearbox.fi",
|
|
411970
412040
|
keywords: [
|
|
411971
412041
|
"gearbox"
|