@gearbox-protocol/sdk 12.3.8 → 12.3.10
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/cjs/abi/errors.js
CHANGED
|
@@ -21,6 +21,7 @@ __export(errors_exports, {
|
|
|
21
21
|
errorAbis: () => errorAbis,
|
|
22
22
|
iExceptionsV300Abi: () => iExceptionsV300Abi,
|
|
23
23
|
iExceptionsV310Abi: () => iExceptionsV310Abi,
|
|
24
|
+
iPartialLiquidationBotV310ErrorsAbi: () => iPartialLiquidationBotV310ErrorsAbi,
|
|
24
25
|
iRedstoneErrorsAbi: () => iRedstoneErrorsAbi,
|
|
25
26
|
iRedstonePriceFeedExceptionsAbi: () => iRedstonePriceFeedExceptionsAbi,
|
|
26
27
|
iRouterErrorsV300Abi: () => iRouterErrorsV300Abi,
|
|
@@ -399,6 +400,12 @@ const iExceptionsV310Abi = [
|
|
|
399
400
|
{ type: "error", name: "VotingContractNotAllowedException", inputs: [] },
|
|
400
401
|
{ type: "error", name: "ZeroAddressException", inputs: [] }
|
|
401
402
|
];
|
|
403
|
+
const iPartialLiquidationBotV310ErrorsAbi = [
|
|
404
|
+
{ type: "error", name: "LiquidatedLessThanNeededException", inputs: [] },
|
|
405
|
+
{ type: "error", name: "LiquidatedMoreThanNeededException", inputs: [] },
|
|
406
|
+
{ type: "error", name: "SeizedLessThanRequiredException", inputs: [] },
|
|
407
|
+
{ type: "error", name: "UnderlyingNotLiquidatableException", inputs: [] }
|
|
408
|
+
];
|
|
402
409
|
const errorAbis = [
|
|
403
410
|
...iExceptionsV300Abi,
|
|
404
411
|
...iExceptionsV310Abi,
|
|
@@ -406,13 +413,15 @@ const errorAbis = [
|
|
|
406
413
|
...iRedstoneErrorsAbi,
|
|
407
414
|
...ilpPriceFeedExceptionsAbi,
|
|
408
415
|
...iRouterErrorsV300Abi,
|
|
409
|
-
...iRouterErrorsV310Abi
|
|
416
|
+
...iRouterErrorsV310Abi,
|
|
417
|
+
...iPartialLiquidationBotV310ErrorsAbi
|
|
410
418
|
];
|
|
411
419
|
// Annotate the CommonJS export names for ESM import in node:
|
|
412
420
|
0 && (module.exports = {
|
|
413
421
|
errorAbis,
|
|
414
422
|
iExceptionsV300Abi,
|
|
415
423
|
iExceptionsV310Abi,
|
|
424
|
+
iPartialLiquidationBotV310ErrorsAbi,
|
|
416
425
|
iRedstoneErrorsAbi,
|
|
417
426
|
iRedstonePriceFeedExceptionsAbi,
|
|
418
427
|
iRouterErrorsV300Abi,
|
|
@@ -99,7 +99,14 @@ class TreasurySplitterContract extends import_sdk.BaseContract {
|
|
|
99
99
|
});
|
|
100
100
|
return {
|
|
101
101
|
functionName: decoded.functionName,
|
|
102
|
-
...
|
|
102
|
+
...this.parseFunctionParams(decoded)
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
case "setDefaultSplit": {
|
|
106
|
+
const [receivers, proportions] = args;
|
|
107
|
+
return {
|
|
108
|
+
receivers: (0, import_sdk.json_stringify)(receivers),
|
|
109
|
+
proportions: (0, import_sdk.json_stringify)(proportions.map((proportion) => `${proportion / 100}% [${proportion}]`))
|
|
103
110
|
};
|
|
104
111
|
}
|
|
105
112
|
default:
|
package/dist/esm/abi/errors.js
CHANGED
|
@@ -369,6 +369,12 @@ const iExceptionsV310Abi = [
|
|
|
369
369
|
{ type: "error", name: "VotingContractNotAllowedException", inputs: [] },
|
|
370
370
|
{ type: "error", name: "ZeroAddressException", inputs: [] }
|
|
371
371
|
];
|
|
372
|
+
const iPartialLiquidationBotV310ErrorsAbi = [
|
|
373
|
+
{ type: "error", name: "LiquidatedLessThanNeededException", inputs: [] },
|
|
374
|
+
{ type: "error", name: "LiquidatedMoreThanNeededException", inputs: [] },
|
|
375
|
+
{ type: "error", name: "SeizedLessThanRequiredException", inputs: [] },
|
|
376
|
+
{ type: "error", name: "UnderlyingNotLiquidatableException", inputs: [] }
|
|
377
|
+
];
|
|
372
378
|
const errorAbis = [
|
|
373
379
|
...iExceptionsV300Abi,
|
|
374
380
|
...iExceptionsV310Abi,
|
|
@@ -376,12 +382,14 @@ const errorAbis = [
|
|
|
376
382
|
...iRedstoneErrorsAbi,
|
|
377
383
|
...ilpPriceFeedExceptionsAbi,
|
|
378
384
|
...iRouterErrorsV300Abi,
|
|
379
|
-
...iRouterErrorsV310Abi
|
|
385
|
+
...iRouterErrorsV310Abi,
|
|
386
|
+
...iPartialLiquidationBotV310ErrorsAbi
|
|
380
387
|
];
|
|
381
388
|
export {
|
|
382
389
|
errorAbis,
|
|
383
390
|
iExceptionsV300Abi,
|
|
384
391
|
iExceptionsV310Abi,
|
|
392
|
+
iPartialLiquidationBotV310ErrorsAbi,
|
|
385
393
|
iRedstoneErrorsAbi,
|
|
386
394
|
iRedstonePriceFeedExceptionsAbi,
|
|
387
395
|
iRouterErrorsV300Abi,
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
decodeFunctionData
|
|
3
3
|
} from "viem";
|
|
4
4
|
import { ITreasurySplitterAbi } from "../../abi/310/iTreasurySplitter.js";
|
|
5
|
-
import { BaseContract } from "../../sdk/index.js";
|
|
5
|
+
import { BaseContract, json_stringify } from "../../sdk/index.js";
|
|
6
6
|
const abi = ITreasurySplitterAbi;
|
|
7
7
|
class TreasurySplitterContract extends BaseContract {
|
|
8
8
|
constructor(addr, client) {
|
|
@@ -78,7 +78,14 @@ class TreasurySplitterContract extends BaseContract {
|
|
|
78
78
|
});
|
|
79
79
|
return {
|
|
80
80
|
functionName: decoded.functionName,
|
|
81
|
-
...
|
|
81
|
+
...this.parseFunctionParams(decoded)
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
case "setDefaultSplit": {
|
|
85
|
+
const [receivers, proportions] = args;
|
|
86
|
+
return {
|
|
87
|
+
receivers: json_stringify(receivers),
|
|
88
|
+
proportions: json_stringify(proportions.map((proportion) => `${proportion / 100}% [${proportion}]`))
|
|
82
89
|
};
|
|
83
90
|
}
|
|
84
91
|
default:
|
|
@@ -953,6 +953,23 @@ export declare const iExceptionsV310Abi: readonly [{
|
|
|
953
953
|
readonly name: "ZeroAddressException";
|
|
954
954
|
readonly inputs: readonly [];
|
|
955
955
|
}];
|
|
956
|
+
export declare const iPartialLiquidationBotV310ErrorsAbi: readonly [{
|
|
957
|
+
readonly type: "error";
|
|
958
|
+
readonly name: "LiquidatedLessThanNeededException";
|
|
959
|
+
readonly inputs: readonly [];
|
|
960
|
+
}, {
|
|
961
|
+
readonly type: "error";
|
|
962
|
+
readonly name: "LiquidatedMoreThanNeededException";
|
|
963
|
+
readonly inputs: readonly [];
|
|
964
|
+
}, {
|
|
965
|
+
readonly type: "error";
|
|
966
|
+
readonly name: "SeizedLessThanRequiredException";
|
|
967
|
+
readonly inputs: readonly [];
|
|
968
|
+
}, {
|
|
969
|
+
readonly type: "error";
|
|
970
|
+
readonly name: "UnderlyingNotLiquidatableException";
|
|
971
|
+
readonly inputs: readonly [];
|
|
972
|
+
}];
|
|
956
973
|
export declare const errorAbis: readonly [{
|
|
957
974
|
readonly type: "error";
|
|
958
975
|
readonly inputs: readonly [];
|
|
@@ -1901,5 +1918,21 @@ export declare const errorAbis: readonly [{
|
|
|
1901
1918
|
readonly type: "address";
|
|
1902
1919
|
readonly internalType: "address";
|
|
1903
1920
|
}];
|
|
1921
|
+
}, {
|
|
1922
|
+
readonly type: "error";
|
|
1923
|
+
readonly name: "LiquidatedLessThanNeededException";
|
|
1924
|
+
readonly inputs: readonly [];
|
|
1925
|
+
}, {
|
|
1926
|
+
readonly type: "error";
|
|
1927
|
+
readonly name: "LiquidatedMoreThanNeededException";
|
|
1928
|
+
readonly inputs: readonly [];
|
|
1929
|
+
}, {
|
|
1930
|
+
readonly type: "error";
|
|
1931
|
+
readonly name: "SeizedLessThanRequiredException";
|
|
1932
|
+
readonly inputs: readonly [];
|
|
1933
|
+
}, {
|
|
1934
|
+
readonly type: "error";
|
|
1935
|
+
readonly name: "UnderlyingNotLiquidatableException";
|
|
1936
|
+
readonly inputs: readonly [];
|
|
1904
1937
|
}];
|
|
1905
1938
|
export type errorAbis = typeof errorAbis;
|