@sentio/runtime 2.40.0-rc.1 → 2.40.0-rc.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/lib/{chunk-LMUCLUM5.js → chunk-FFU5RYDX.js} +927 -232
- package/lib/index.d.ts +68 -5
- package/lib/index.js +3 -1
- package/lib/processor-runner.js +4 -1
- package/package.json +1 -1
- package/src/full-service.ts +5 -0
- package/src/gen/processor/protos/processor.ts +763 -173
- package/src/provider.ts +2 -0
- package/src/service.ts +98 -20
- package/src/utils.ts +11 -3
@@ -44325,6 +44325,7 @@ var HandlerType;
|
|
44325
44325
|
HandlerType4[HandlerType4["SUI_OBJECT_CHANGE"] = 12] = "SUI_OBJECT_CHANGE";
|
44326
44326
|
HandlerType4[HandlerType4["FUEL_CALL"] = 13] = "FUEL_CALL";
|
44327
44327
|
HandlerType4[HandlerType4["COSMOS_CALL"] = 14] = "COSMOS_CALL";
|
44328
|
+
HandlerType4[HandlerType4["STARKNET_EVENT"] = 15] = "STARKNET_EVENT";
|
44328
44329
|
HandlerType4[HandlerType4["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
44329
44330
|
})(HandlerType || (HandlerType = {}));
|
44330
44331
|
function handlerTypeFromJSON(object2) {
|
@@ -44374,6 +44375,9 @@ function handlerTypeFromJSON(object2) {
|
|
44374
44375
|
case 14:
|
44375
44376
|
case "COSMOS_CALL":
|
44376
44377
|
return HandlerType.COSMOS_CALL;
|
44378
|
+
case 15:
|
44379
|
+
case "STARKNET_EVENT":
|
44380
|
+
return HandlerType.STARKNET_EVENT;
|
44377
44381
|
case -1:
|
44378
44382
|
case "UNRECOGNIZED":
|
44379
44383
|
default:
|
@@ -44412,6 +44416,8 @@ function handlerTypeToJSON(object2) {
|
|
44412
44416
|
return "FUEL_CALL";
|
44413
44417
|
case HandlerType.COSMOS_CALL:
|
44414
44418
|
return "COSMOS_CALL";
|
44419
|
+
case HandlerType.STARKNET_EVENT:
|
44420
|
+
return "STARKNET_EVENT";
|
44415
44421
|
case HandlerType.UNRECOGNIZED:
|
44416
44422
|
default:
|
44417
44423
|
return "UNRECOGNIZED";
|
@@ -44892,6 +44898,7 @@ function createBaseContractConfig() {
|
|
44892
44898
|
assetConfigs: [],
|
44893
44899
|
fuelLogConfigs: [],
|
44894
44900
|
cosmosLogConfigs: [],
|
44901
|
+
starknetEventConfigs: [],
|
44895
44902
|
instructionConfig: void 0,
|
44896
44903
|
startBlock: BigInt("0"),
|
44897
44904
|
endBlock: BigInt("0"),
|
@@ -44936,6 +44943,9 @@ var ContractConfig = {
|
|
44936
44943
|
for (const v of message.cosmosLogConfigs) {
|
44937
44944
|
CosmosLogHandlerConfig.encode(v, writer.uint32(130).fork()).ldelim();
|
44938
44945
|
}
|
44946
|
+
for (const v of message.starknetEventConfigs) {
|
44947
|
+
StarknetEventHandlerConfig.encode(v, writer.uint32(138).fork()).ldelim();
|
44948
|
+
}
|
44939
44949
|
if (message.instructionConfig !== void 0) {
|
44940
44950
|
InstructionHandlerConfig.encode(message.instructionConfig, writer.uint32(50).fork()).ldelim();
|
44941
44951
|
}
|
@@ -45035,6 +45045,12 @@ var ContractConfig = {
|
|
45035
45045
|
}
|
45036
45046
|
message.cosmosLogConfigs.push(CosmosLogHandlerConfig.decode(reader, reader.uint32()));
|
45037
45047
|
continue;
|
45048
|
+
case 17:
|
45049
|
+
if (tag !== 138) {
|
45050
|
+
break;
|
45051
|
+
}
|
45052
|
+
message.starknetEventConfigs.push(StarknetEventHandlerConfig.decode(reader, reader.uint32()));
|
45053
|
+
continue;
|
45038
45054
|
case 6:
|
45039
45055
|
if (tag !== 50) {
|
45040
45056
|
break;
|
@@ -45081,6 +45097,7 @@ var ContractConfig = {
|
|
45081
45097
|
assetConfigs: globalThis.Array.isArray(object2?.assetConfigs) ? object2.assetConfigs.map((e) => FuelAssetHandlerConfig.fromJSON(e)) : [],
|
45082
45098
|
fuelLogConfigs: globalThis.Array.isArray(object2?.fuelLogConfigs) ? object2.fuelLogConfigs.map((e) => FuelLogHandlerConfig.fromJSON(e)) : [],
|
45083
45099
|
cosmosLogConfigs: globalThis.Array.isArray(object2?.cosmosLogConfigs) ? object2.cosmosLogConfigs.map((e) => CosmosLogHandlerConfig.fromJSON(e)) : [],
|
45100
|
+
starknetEventConfigs: globalThis.Array.isArray(object2?.starknetEventConfigs) ? object2.starknetEventConfigs.map((e) => StarknetEventHandlerConfig.fromJSON(e)) : [],
|
45084
45101
|
instructionConfig: isSet3(object2.instructionConfig) ? InstructionHandlerConfig.fromJSON(object2.instructionConfig) : void 0,
|
45085
45102
|
startBlock: isSet3(object2.startBlock) ? BigInt(object2.startBlock) : BigInt("0"),
|
45086
45103
|
endBlock: isSet3(object2.endBlock) ? BigInt(object2.endBlock) : BigInt("0"),
|
@@ -45125,6 +45142,9 @@ var ContractConfig = {
|
|
45125
45142
|
if (message.cosmosLogConfigs?.length) {
|
45126
45143
|
obj.cosmosLogConfigs = message.cosmosLogConfigs.map((e) => CosmosLogHandlerConfig.toJSON(e));
|
45127
45144
|
}
|
45145
|
+
if (message.starknetEventConfigs?.length) {
|
45146
|
+
obj.starknetEventConfigs = message.starknetEventConfigs.map((e) => StarknetEventHandlerConfig.toJSON(e));
|
45147
|
+
}
|
45128
45148
|
if (message.instructionConfig !== void 0) {
|
45129
45149
|
obj.instructionConfig = InstructionHandlerConfig.toJSON(message.instructionConfig);
|
45130
45150
|
}
|
@@ -45156,6 +45176,7 @@ var ContractConfig = {
|
|
45156
45176
|
message.assetConfigs = object2.assetConfigs?.map((e) => FuelAssetHandlerConfig.fromPartial(e)) || [];
|
45157
45177
|
message.fuelLogConfigs = object2.fuelLogConfigs?.map((e) => FuelLogHandlerConfig.fromPartial(e)) || [];
|
45158
45178
|
message.cosmosLogConfigs = object2.cosmosLogConfigs?.map((e) => CosmosLogHandlerConfig.fromPartial(e)) || [];
|
45179
|
+
message.starknetEventConfigs = object2.starknetEventConfigs?.map((e) => StarknetEventHandlerConfig.fromPartial(e)) || [];
|
45159
45180
|
message.instructionConfig = object2.instructionConfig !== void 0 && object2.instructionConfig !== null ? InstructionHandlerConfig.fromPartial(object2.instructionConfig) : void 0;
|
45160
45181
|
message.startBlock = object2.startBlock ?? BigInt("0");
|
45161
45182
|
message.endBlock = object2.endBlock ?? BigInt("0");
|
@@ -48071,6 +48092,138 @@ var MoveCallFilter_FromAndToAddress = {
|
|
48071
48092
|
return message;
|
48072
48093
|
}
|
48073
48094
|
};
|
48095
|
+
function createBaseStarknetEventHandlerConfig() {
|
48096
|
+
return { filters: [], handlerId: 0 };
|
48097
|
+
}
|
48098
|
+
var StarknetEventHandlerConfig = {
|
48099
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
48100
|
+
for (const v of message.filters) {
|
48101
|
+
StarknetEventFilter.encode(v, writer.uint32(10).fork()).ldelim();
|
48102
|
+
}
|
48103
|
+
if (message.handlerId !== 0) {
|
48104
|
+
writer.uint32(16).int32(message.handlerId);
|
48105
|
+
}
|
48106
|
+
return writer;
|
48107
|
+
},
|
48108
|
+
decode(input, length) {
|
48109
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
48110
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
48111
|
+
const message = createBaseStarknetEventHandlerConfig();
|
48112
|
+
while (reader.pos < end) {
|
48113
|
+
const tag = reader.uint32();
|
48114
|
+
switch (tag >>> 3) {
|
48115
|
+
case 1:
|
48116
|
+
if (tag !== 10) {
|
48117
|
+
break;
|
48118
|
+
}
|
48119
|
+
message.filters.push(StarknetEventFilter.decode(reader, reader.uint32()));
|
48120
|
+
continue;
|
48121
|
+
case 2:
|
48122
|
+
if (tag !== 16) {
|
48123
|
+
break;
|
48124
|
+
}
|
48125
|
+
message.handlerId = reader.int32();
|
48126
|
+
continue;
|
48127
|
+
}
|
48128
|
+
if ((tag & 7) === 4 || tag === 0) {
|
48129
|
+
break;
|
48130
|
+
}
|
48131
|
+
reader.skipType(tag & 7);
|
48132
|
+
}
|
48133
|
+
return message;
|
48134
|
+
},
|
48135
|
+
fromJSON(object2) {
|
48136
|
+
return {
|
48137
|
+
filters: globalThis.Array.isArray(object2?.filters) ? object2.filters.map((e) => StarknetEventFilter.fromJSON(e)) : [],
|
48138
|
+
handlerId: isSet3(object2.handlerId) ? globalThis.Number(object2.handlerId) : 0
|
48139
|
+
};
|
48140
|
+
},
|
48141
|
+
toJSON(message) {
|
48142
|
+
const obj = {};
|
48143
|
+
if (message.filters?.length) {
|
48144
|
+
obj.filters = message.filters.map((e) => StarknetEventFilter.toJSON(e));
|
48145
|
+
}
|
48146
|
+
if (message.handlerId !== 0) {
|
48147
|
+
obj.handlerId = Math.round(message.handlerId);
|
48148
|
+
}
|
48149
|
+
return obj;
|
48150
|
+
},
|
48151
|
+
create(base) {
|
48152
|
+
return StarknetEventHandlerConfig.fromPartial(base ?? {});
|
48153
|
+
},
|
48154
|
+
fromPartial(object2) {
|
48155
|
+
const message = createBaseStarknetEventHandlerConfig();
|
48156
|
+
message.filters = object2.filters?.map((e) => StarknetEventFilter.fromPartial(e)) || [];
|
48157
|
+
message.handlerId = object2.handlerId ?? 0;
|
48158
|
+
return message;
|
48159
|
+
}
|
48160
|
+
};
|
48161
|
+
function createBaseStarknetEventFilter() {
|
48162
|
+
return { address: "", keys: [] };
|
48163
|
+
}
|
48164
|
+
var StarknetEventFilter = {
|
48165
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
48166
|
+
if (message.address !== "") {
|
48167
|
+
writer.uint32(10).string(message.address);
|
48168
|
+
}
|
48169
|
+
for (const v of message.keys) {
|
48170
|
+
writer.uint32(18).string(v);
|
48171
|
+
}
|
48172
|
+
return writer;
|
48173
|
+
},
|
48174
|
+
decode(input, length) {
|
48175
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
48176
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
48177
|
+
const message = createBaseStarknetEventFilter();
|
48178
|
+
while (reader.pos < end) {
|
48179
|
+
const tag = reader.uint32();
|
48180
|
+
switch (tag >>> 3) {
|
48181
|
+
case 1:
|
48182
|
+
if (tag !== 10) {
|
48183
|
+
break;
|
48184
|
+
}
|
48185
|
+
message.address = reader.string();
|
48186
|
+
continue;
|
48187
|
+
case 2:
|
48188
|
+
if (tag !== 18) {
|
48189
|
+
break;
|
48190
|
+
}
|
48191
|
+
message.keys.push(reader.string());
|
48192
|
+
continue;
|
48193
|
+
}
|
48194
|
+
if ((tag & 7) === 4 || tag === 0) {
|
48195
|
+
break;
|
48196
|
+
}
|
48197
|
+
reader.skipType(tag & 7);
|
48198
|
+
}
|
48199
|
+
return message;
|
48200
|
+
},
|
48201
|
+
fromJSON(object2) {
|
48202
|
+
return {
|
48203
|
+
address: isSet3(object2.address) ? globalThis.String(object2.address) : "",
|
48204
|
+
keys: globalThis.Array.isArray(object2?.keys) ? object2.keys.map((e) => globalThis.String(e)) : []
|
48205
|
+
};
|
48206
|
+
},
|
48207
|
+
toJSON(message) {
|
48208
|
+
const obj = {};
|
48209
|
+
if (message.address !== "") {
|
48210
|
+
obj.address = message.address;
|
48211
|
+
}
|
48212
|
+
if (message.keys?.length) {
|
48213
|
+
obj.keys = message.keys;
|
48214
|
+
}
|
48215
|
+
return obj;
|
48216
|
+
},
|
48217
|
+
create(base) {
|
48218
|
+
return StarknetEventFilter.fromPartial(base ?? {});
|
48219
|
+
},
|
48220
|
+
fromPartial(object2) {
|
48221
|
+
const message = createBaseStarknetEventFilter();
|
48222
|
+
message.address = object2.address ?? "";
|
48223
|
+
message.keys = object2.keys?.map((e) => e) || [];
|
48224
|
+
return message;
|
48225
|
+
}
|
48226
|
+
};
|
48074
48227
|
function createBaseFuelCallFilter() {
|
48075
48228
|
return { function: "", includeFailed: false };
|
48076
48229
|
}
|
@@ -48430,9 +48583,75 @@ var ProcessResult = {
|
|
48430
48583
|
}
|
48431
48584
|
};
|
48432
48585
|
function createBaseEthCallParam() {
|
48433
|
-
return {
|
48586
|
+
return { context: void 0, calldata: "" };
|
48434
48587
|
}
|
48435
48588
|
var EthCallParam = {
|
48589
|
+
encode(message, writer = import_minimal5.default.Writer.create()) {
|
48590
|
+
if (message.context !== void 0) {
|
48591
|
+
EthCallContext.encode(message.context, writer.uint32(10).fork()).ldelim();
|
48592
|
+
}
|
48593
|
+
if (message.calldata !== "") {
|
48594
|
+
writer.uint32(18).string(message.calldata);
|
48595
|
+
}
|
48596
|
+
return writer;
|
48597
|
+
},
|
48598
|
+
decode(input, length) {
|
48599
|
+
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
48600
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
48601
|
+
const message = createBaseEthCallParam();
|
48602
|
+
while (reader.pos < end) {
|
48603
|
+
const tag = reader.uint32();
|
48604
|
+
switch (tag >>> 3) {
|
48605
|
+
case 1:
|
48606
|
+
if (tag !== 10) {
|
48607
|
+
break;
|
48608
|
+
}
|
48609
|
+
message.context = EthCallContext.decode(reader, reader.uint32());
|
48610
|
+
continue;
|
48611
|
+
case 2:
|
48612
|
+
if (tag !== 18) {
|
48613
|
+
break;
|
48614
|
+
}
|
48615
|
+
message.calldata = reader.string();
|
48616
|
+
continue;
|
48617
|
+
}
|
48618
|
+
if ((tag & 7) === 4 || tag === 0) {
|
48619
|
+
break;
|
48620
|
+
}
|
48621
|
+
reader.skipType(tag & 7);
|
48622
|
+
}
|
48623
|
+
return message;
|
48624
|
+
},
|
48625
|
+
fromJSON(object2) {
|
48626
|
+
return {
|
48627
|
+
context: isSet3(object2.context) ? EthCallContext.fromJSON(object2.context) : void 0,
|
48628
|
+
calldata: isSet3(object2.calldata) ? globalThis.String(object2.calldata) : ""
|
48629
|
+
};
|
48630
|
+
},
|
48631
|
+
toJSON(message) {
|
48632
|
+
const obj = {};
|
48633
|
+
if (message.context !== void 0) {
|
48634
|
+
obj.context = EthCallContext.toJSON(message.context);
|
48635
|
+
}
|
48636
|
+
if (message.calldata !== "") {
|
48637
|
+
obj.calldata = message.calldata;
|
48638
|
+
}
|
48639
|
+
return obj;
|
48640
|
+
},
|
48641
|
+
create(base) {
|
48642
|
+
return EthCallParam.fromPartial(base ?? {});
|
48643
|
+
},
|
48644
|
+
fromPartial(object2) {
|
48645
|
+
const message = createBaseEthCallParam();
|
48646
|
+
message.context = object2.context !== void 0 && object2.context !== null ? EthCallContext.fromPartial(object2.context) : void 0;
|
48647
|
+
message.calldata = object2.calldata ?? "";
|
48648
|
+
return message;
|
48649
|
+
}
|
48650
|
+
};
|
48651
|
+
function createBaseEthCallContext() {
|
48652
|
+
return { chainId: "", address: "", blockTag: "" };
|
48653
|
+
}
|
48654
|
+
var EthCallContext = {
|
48436
48655
|
encode(message, writer = import_minimal5.default.Writer.create()) {
|
48437
48656
|
if (message.chainId !== "") {
|
48438
48657
|
writer.uint32(10).string(message.chainId);
|
@@ -48440,21 +48659,15 @@ var EthCallParam = {
|
|
48440
48659
|
if (message.address !== "") {
|
48441
48660
|
writer.uint32(18).string(message.address);
|
48442
48661
|
}
|
48443
|
-
if (message.
|
48444
|
-
writer.uint32(26).string(message.
|
48445
|
-
}
|
48446
|
-
if (message.signature !== "") {
|
48447
|
-
writer.uint32(34).string(message.signature);
|
48448
|
-
}
|
48449
|
-
for (const v of message.args) {
|
48450
|
-
Value.encode(Value.wrap(v), writer.uint32(42).fork()).ldelim();
|
48662
|
+
if (message.blockTag !== "") {
|
48663
|
+
writer.uint32(26).string(message.blockTag);
|
48451
48664
|
}
|
48452
48665
|
return writer;
|
48453
48666
|
},
|
48454
48667
|
decode(input, length) {
|
48455
48668
|
const reader = input instanceof import_minimal5.default.Reader ? input : import_minimal5.default.Reader.create(input);
|
48456
48669
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
48457
|
-
const message =
|
48670
|
+
const message = createBaseEthCallContext();
|
48458
48671
|
while (reader.pos < end) {
|
48459
48672
|
const tag = reader.uint32();
|
48460
48673
|
switch (tag >>> 3) {
|
@@ -48474,19 +48687,7 @@ var EthCallParam = {
|
|
48474
48687
|
if (tag !== 26) {
|
48475
48688
|
break;
|
48476
48689
|
}
|
48477
|
-
message.
|
48478
|
-
continue;
|
48479
|
-
case 4:
|
48480
|
-
if (tag !== 34) {
|
48481
|
-
break;
|
48482
|
-
}
|
48483
|
-
message.signature = reader.string();
|
48484
|
-
continue;
|
48485
|
-
case 5:
|
48486
|
-
if (tag !== 42) {
|
48487
|
-
break;
|
48488
|
-
}
|
48489
|
-
message.args.push(Value.unwrap(Value.decode(reader, reader.uint32())));
|
48690
|
+
message.blockTag = reader.string();
|
48490
48691
|
continue;
|
48491
48692
|
}
|
48492
48693
|
if ((tag & 7) === 4 || tag === 0) {
|
@@ -48500,9 +48701,7 @@ var EthCallParam = {
|
|
48500
48701
|
return {
|
48501
48702
|
chainId: isSet3(object2.chainId) ? globalThis.String(object2.chainId) : "",
|
48502
48703
|
address: isSet3(object2.address) ? globalThis.String(object2.address) : "",
|
48503
|
-
|
48504
|
-
signature: isSet3(object2.signature) ? globalThis.String(object2.signature) : "",
|
48505
|
-
args: globalThis.Array.isArray(object2?.args) ? [...object2.args] : []
|
48704
|
+
blockTag: isSet3(object2.blockTag) ? globalThis.String(object2.blockTag) : ""
|
48506
48705
|
};
|
48507
48706
|
},
|
48508
48707
|
toJSON(message) {
|
@@ -48513,27 +48712,19 @@ var EthCallParam = {
|
|
48513
48712
|
if (message.address !== "") {
|
48514
48713
|
obj.address = message.address;
|
48515
48714
|
}
|
48516
|
-
if (message.
|
48517
|
-
obj.
|
48518
|
-
}
|
48519
|
-
if (message.signature !== "") {
|
48520
|
-
obj.signature = message.signature;
|
48521
|
-
}
|
48522
|
-
if (message.args?.length) {
|
48523
|
-
obj.args = message.args;
|
48715
|
+
if (message.blockTag !== "") {
|
48716
|
+
obj.blockTag = message.blockTag;
|
48524
48717
|
}
|
48525
48718
|
return obj;
|
48526
48719
|
},
|
48527
48720
|
create(base) {
|
48528
|
-
return
|
48721
|
+
return EthCallContext.fromPartial(base ?? {});
|
48529
48722
|
},
|
48530
48723
|
fromPartial(object2) {
|
48531
|
-
const message =
|
48724
|
+
const message = createBaseEthCallContext();
|
48532
48725
|
message.chainId = object2.chainId ?? "";
|
48533
48726
|
message.address = object2.address ?? "";
|
48534
|
-
message.
|
48535
|
-
message.signature = object2.signature ?? "";
|
48536
|
-
message.args = object2.args?.map((e) => e) || [];
|
48727
|
+
message.blockTag = object2.blockTag ?? "";
|
48537
48728
|
return message;
|
48538
48729
|
}
|
48539
48730
|
};
|
@@ -50957,6 +51148,9 @@ function handlerTypeFromJSON2(object2) {
|
|
50957
51148
|
case 14:
|
50958
51149
|
case "COSMOS_CALL":
|
50959
51150
|
return 14 /* COSMOS_CALL */;
|
51151
|
+
case 15:
|
51152
|
+
case "STARKNET_EVENT":
|
51153
|
+
return 15 /* STARKNET_EVENT */;
|
50960
51154
|
case -1:
|
50961
51155
|
case "UNRECOGNIZED":
|
50962
51156
|
default:
|
@@ -50995,6 +51189,8 @@ function handlerTypeToJSON2(object2) {
|
|
50995
51189
|
return "FUEL_CALL";
|
50996
51190
|
case 14 /* COSMOS_CALL */:
|
50997
51191
|
return "COSMOS_CALL";
|
51192
|
+
case 15 /* STARKNET_EVENT */:
|
51193
|
+
return "STARKNET_EVENT";
|
50998
51194
|
case -1 /* UNRECOGNIZED */:
|
50999
51195
|
default:
|
51000
51196
|
return "UNRECOGNIZED";
|
@@ -51546,6 +51742,7 @@ function createBaseContractConfig2() {
|
|
51546
51742
|
assetConfigs: [],
|
51547
51743
|
fuelLogConfigs: [],
|
51548
51744
|
cosmosLogConfigs: [],
|
51745
|
+
starknetEventConfigs: [],
|
51549
51746
|
instructionConfig: void 0,
|
51550
51747
|
startBlock: BigInt("0"),
|
51551
51748
|
endBlock: BigInt("0"),
|
@@ -51590,6 +51787,9 @@ var ContractConfig2 = {
|
|
51590
51787
|
for (const v of message.cosmosLogConfigs) {
|
51591
51788
|
CosmosLogHandlerConfig2.encode(v, writer.uint32(130).fork()).ldelim();
|
51592
51789
|
}
|
51790
|
+
for (const v of message.starknetEventConfigs) {
|
51791
|
+
StarknetEventHandlerConfig2.encode(v, writer.uint32(138).fork()).ldelim();
|
51792
|
+
}
|
51593
51793
|
if (message.instructionConfig !== void 0) {
|
51594
51794
|
InstructionHandlerConfig2.encode(message.instructionConfig, writer.uint32(50).fork()).ldelim();
|
51595
51795
|
}
|
@@ -51689,6 +51889,12 @@ var ContractConfig2 = {
|
|
51689
51889
|
}
|
51690
51890
|
message.cosmosLogConfigs.push(CosmosLogHandlerConfig2.decode(reader, reader.uint32()));
|
51691
51891
|
continue;
|
51892
|
+
case 17:
|
51893
|
+
if (tag !== 138) {
|
51894
|
+
break;
|
51895
|
+
}
|
51896
|
+
message.starknetEventConfigs.push(StarknetEventHandlerConfig2.decode(reader, reader.uint32()));
|
51897
|
+
continue;
|
51692
51898
|
case 6:
|
51693
51899
|
if (tag !== 50) {
|
51694
51900
|
break;
|
@@ -51735,6 +51941,7 @@ var ContractConfig2 = {
|
|
51735
51941
|
assetConfigs: globalThis.Array.isArray(object2?.assetConfigs) ? object2.assetConfigs.map((e) => FuelAssetHandlerConfig2.fromJSON(e)) : [],
|
51736
51942
|
fuelLogConfigs: globalThis.Array.isArray(object2?.fuelLogConfigs) ? object2.fuelLogConfigs.map((e) => FuelLogHandlerConfig2.fromJSON(e)) : [],
|
51737
51943
|
cosmosLogConfigs: globalThis.Array.isArray(object2?.cosmosLogConfigs) ? object2.cosmosLogConfigs.map((e) => CosmosLogHandlerConfig2.fromJSON(e)) : [],
|
51944
|
+
starknetEventConfigs: globalThis.Array.isArray(object2?.starknetEventConfigs) ? object2.starknetEventConfigs.map((e) => StarknetEventHandlerConfig2.fromJSON(e)) : [],
|
51738
51945
|
instructionConfig: isSet7(object2.instructionConfig) ? InstructionHandlerConfig2.fromJSON(object2.instructionConfig) : void 0,
|
51739
51946
|
startBlock: isSet7(object2.startBlock) ? BigInt(object2.startBlock) : BigInt("0"),
|
51740
51947
|
endBlock: isSet7(object2.endBlock) ? BigInt(object2.endBlock) : BigInt("0"),
|
@@ -51779,6 +51986,9 @@ var ContractConfig2 = {
|
|
51779
51986
|
if (message.cosmosLogConfigs?.length) {
|
51780
51987
|
obj.cosmosLogConfigs = message.cosmosLogConfigs.map((e) => CosmosLogHandlerConfig2.toJSON(e));
|
51781
51988
|
}
|
51989
|
+
if (message.starknetEventConfigs?.length) {
|
51990
|
+
obj.starknetEventConfigs = message.starknetEventConfigs.map((e) => StarknetEventHandlerConfig2.toJSON(e));
|
51991
|
+
}
|
51782
51992
|
if (message.instructionConfig !== void 0) {
|
51783
51993
|
obj.instructionConfig = InstructionHandlerConfig2.toJSON(message.instructionConfig);
|
51784
51994
|
}
|
@@ -51810,6 +52020,7 @@ var ContractConfig2 = {
|
|
51810
52020
|
message.assetConfigs = object2.assetConfigs?.map((e) => FuelAssetHandlerConfig2.fromPartial(e)) || [];
|
51811
52021
|
message.fuelLogConfigs = object2.fuelLogConfigs?.map((e) => FuelLogHandlerConfig2.fromPartial(e)) || [];
|
51812
52022
|
message.cosmosLogConfigs = object2.cosmosLogConfigs?.map((e) => CosmosLogHandlerConfig2.fromPartial(e)) || [];
|
52023
|
+
message.starknetEventConfigs = object2.starknetEventConfigs?.map((e) => StarknetEventHandlerConfig2.fromPartial(e)) || [];
|
51813
52024
|
message.instructionConfig = object2.instructionConfig !== void 0 && object2.instructionConfig !== null ? InstructionHandlerConfig2.fromPartial(object2.instructionConfig) : void 0;
|
51814
52025
|
message.startBlock = object2.startBlock ?? BigInt("0");
|
51815
52026
|
message.endBlock = object2.endBlock ?? BigInt("0");
|
@@ -54858,6 +55069,138 @@ var MoveCallFilter_FromAndToAddress2 = {
|
|
54858
55069
|
return message;
|
54859
55070
|
}
|
54860
55071
|
};
|
55072
|
+
function createBaseStarknetEventHandlerConfig2() {
|
55073
|
+
return { filters: [], handlerId: 0 };
|
55074
|
+
}
|
55075
|
+
var StarknetEventHandlerConfig2 = {
|
55076
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
55077
|
+
for (const v of message.filters) {
|
55078
|
+
StarknetEventFilter2.encode(v, writer.uint32(10).fork()).ldelim();
|
55079
|
+
}
|
55080
|
+
if (message.handlerId !== 0) {
|
55081
|
+
writer.uint32(16).int32(message.handlerId);
|
55082
|
+
}
|
55083
|
+
return writer;
|
55084
|
+
},
|
55085
|
+
decode(input, length) {
|
55086
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
55087
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
55088
|
+
const message = createBaseStarknetEventHandlerConfig2();
|
55089
|
+
while (reader.pos < end) {
|
55090
|
+
const tag = reader.uint32();
|
55091
|
+
switch (tag >>> 3) {
|
55092
|
+
case 1:
|
55093
|
+
if (tag !== 10) {
|
55094
|
+
break;
|
55095
|
+
}
|
55096
|
+
message.filters.push(StarknetEventFilter2.decode(reader, reader.uint32()));
|
55097
|
+
continue;
|
55098
|
+
case 2:
|
55099
|
+
if (tag !== 16) {
|
55100
|
+
break;
|
55101
|
+
}
|
55102
|
+
message.handlerId = reader.int32();
|
55103
|
+
continue;
|
55104
|
+
}
|
55105
|
+
if ((tag & 7) === 4 || tag === 0) {
|
55106
|
+
break;
|
55107
|
+
}
|
55108
|
+
reader.skipType(tag & 7);
|
55109
|
+
}
|
55110
|
+
return message;
|
55111
|
+
},
|
55112
|
+
fromJSON(object2) {
|
55113
|
+
return {
|
55114
|
+
filters: globalThis.Array.isArray(object2?.filters) ? object2.filters.map((e) => StarknetEventFilter2.fromJSON(e)) : [],
|
55115
|
+
handlerId: isSet7(object2.handlerId) ? globalThis.Number(object2.handlerId) : 0
|
55116
|
+
};
|
55117
|
+
},
|
55118
|
+
toJSON(message) {
|
55119
|
+
const obj = {};
|
55120
|
+
if (message.filters?.length) {
|
55121
|
+
obj.filters = message.filters.map((e) => StarknetEventFilter2.toJSON(e));
|
55122
|
+
}
|
55123
|
+
if (message.handlerId !== 0) {
|
55124
|
+
obj.handlerId = Math.round(message.handlerId);
|
55125
|
+
}
|
55126
|
+
return obj;
|
55127
|
+
},
|
55128
|
+
create(base) {
|
55129
|
+
return StarknetEventHandlerConfig2.fromPartial(base ?? {});
|
55130
|
+
},
|
55131
|
+
fromPartial(object2) {
|
55132
|
+
const message = createBaseStarknetEventHandlerConfig2();
|
55133
|
+
message.filters = object2.filters?.map((e) => StarknetEventFilter2.fromPartial(e)) || [];
|
55134
|
+
message.handlerId = object2.handlerId ?? 0;
|
55135
|
+
return message;
|
55136
|
+
}
|
55137
|
+
};
|
55138
|
+
function createBaseStarknetEventFilter2() {
|
55139
|
+
return { address: "", keys: [] };
|
55140
|
+
}
|
55141
|
+
var StarknetEventFilter2 = {
|
55142
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
55143
|
+
if (message.address !== "") {
|
55144
|
+
writer.uint32(10).string(message.address);
|
55145
|
+
}
|
55146
|
+
for (const v of message.keys) {
|
55147
|
+
writer.uint32(18).string(v);
|
55148
|
+
}
|
55149
|
+
return writer;
|
55150
|
+
},
|
55151
|
+
decode(input, length) {
|
55152
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
55153
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
55154
|
+
const message = createBaseStarknetEventFilter2();
|
55155
|
+
while (reader.pos < end) {
|
55156
|
+
const tag = reader.uint32();
|
55157
|
+
switch (tag >>> 3) {
|
55158
|
+
case 1:
|
55159
|
+
if (tag !== 10) {
|
55160
|
+
break;
|
55161
|
+
}
|
55162
|
+
message.address = reader.string();
|
55163
|
+
continue;
|
55164
|
+
case 2:
|
55165
|
+
if (tag !== 18) {
|
55166
|
+
break;
|
55167
|
+
}
|
55168
|
+
message.keys.push(reader.string());
|
55169
|
+
continue;
|
55170
|
+
}
|
55171
|
+
if ((tag & 7) === 4 || tag === 0) {
|
55172
|
+
break;
|
55173
|
+
}
|
55174
|
+
reader.skipType(tag & 7);
|
55175
|
+
}
|
55176
|
+
return message;
|
55177
|
+
},
|
55178
|
+
fromJSON(object2) {
|
55179
|
+
return {
|
55180
|
+
address: isSet7(object2.address) ? globalThis.String(object2.address) : "",
|
55181
|
+
keys: globalThis.Array.isArray(object2?.keys) ? object2.keys.map((e) => globalThis.String(e)) : []
|
55182
|
+
};
|
55183
|
+
},
|
55184
|
+
toJSON(message) {
|
55185
|
+
const obj = {};
|
55186
|
+
if (message.address !== "") {
|
55187
|
+
obj.address = message.address;
|
55188
|
+
}
|
55189
|
+
if (message.keys?.length) {
|
55190
|
+
obj.keys = message.keys;
|
55191
|
+
}
|
55192
|
+
return obj;
|
55193
|
+
},
|
55194
|
+
create(base) {
|
55195
|
+
return StarknetEventFilter2.fromPartial(base ?? {});
|
55196
|
+
},
|
55197
|
+
fromPartial(object2) {
|
55198
|
+
const message = createBaseStarknetEventFilter2();
|
55199
|
+
message.address = object2.address ?? "";
|
55200
|
+
message.keys = object2.keys?.map((e) => e) || [];
|
55201
|
+
return message;
|
55202
|
+
}
|
55203
|
+
};
|
54861
55204
|
function createBaseFuelCallFilter2() {
|
54862
55205
|
return { function: "", includeFailed: false };
|
54863
55206
|
}
|
@@ -55320,6 +55663,204 @@ var ProcessStreamResponse = {
|
|
55320
55663
|
return message;
|
55321
55664
|
}
|
55322
55665
|
};
|
55666
|
+
function createBasePreprocessStreamRequest() {
|
55667
|
+
return { processId: 0, bindings: void 0, dbResult: void 0 };
|
55668
|
+
}
|
55669
|
+
var PreprocessStreamRequest = {
|
55670
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
55671
|
+
if (message.processId !== 0) {
|
55672
|
+
writer.uint32(8).int32(message.processId);
|
55673
|
+
}
|
55674
|
+
if (message.bindings !== void 0) {
|
55675
|
+
PreprocessStreamRequest_DataBindings.encode(message.bindings, writer.uint32(18).fork()).ldelim();
|
55676
|
+
}
|
55677
|
+
if (message.dbResult !== void 0) {
|
55678
|
+
DBResponse.encode(message.dbResult, writer.uint32(26).fork()).ldelim();
|
55679
|
+
}
|
55680
|
+
return writer;
|
55681
|
+
},
|
55682
|
+
decode(input, length) {
|
55683
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
55684
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
55685
|
+
const message = createBasePreprocessStreamRequest();
|
55686
|
+
while (reader.pos < end) {
|
55687
|
+
const tag = reader.uint32();
|
55688
|
+
switch (tag >>> 3) {
|
55689
|
+
case 1:
|
55690
|
+
if (tag !== 8) {
|
55691
|
+
break;
|
55692
|
+
}
|
55693
|
+
message.processId = reader.int32();
|
55694
|
+
continue;
|
55695
|
+
case 2:
|
55696
|
+
if (tag !== 18) {
|
55697
|
+
break;
|
55698
|
+
}
|
55699
|
+
message.bindings = PreprocessStreamRequest_DataBindings.decode(reader, reader.uint32());
|
55700
|
+
continue;
|
55701
|
+
case 3:
|
55702
|
+
if (tag !== 26) {
|
55703
|
+
break;
|
55704
|
+
}
|
55705
|
+
message.dbResult = DBResponse.decode(reader, reader.uint32());
|
55706
|
+
continue;
|
55707
|
+
}
|
55708
|
+
if ((tag & 7) === 4 || tag === 0) {
|
55709
|
+
break;
|
55710
|
+
}
|
55711
|
+
reader.skipType(tag & 7);
|
55712
|
+
}
|
55713
|
+
return message;
|
55714
|
+
},
|
55715
|
+
fromJSON(object2) {
|
55716
|
+
return {
|
55717
|
+
processId: isSet7(object2.processId) ? globalThis.Number(object2.processId) : 0,
|
55718
|
+
bindings: isSet7(object2.bindings) ? PreprocessStreamRequest_DataBindings.fromJSON(object2.bindings) : void 0,
|
55719
|
+
dbResult: isSet7(object2.dbResult) ? DBResponse.fromJSON(object2.dbResult) : void 0
|
55720
|
+
};
|
55721
|
+
},
|
55722
|
+
toJSON(message) {
|
55723
|
+
const obj = {};
|
55724
|
+
if (message.processId !== 0) {
|
55725
|
+
obj.processId = Math.round(message.processId);
|
55726
|
+
}
|
55727
|
+
if (message.bindings !== void 0) {
|
55728
|
+
obj.bindings = PreprocessStreamRequest_DataBindings.toJSON(message.bindings);
|
55729
|
+
}
|
55730
|
+
if (message.dbResult !== void 0) {
|
55731
|
+
obj.dbResult = DBResponse.toJSON(message.dbResult);
|
55732
|
+
}
|
55733
|
+
return obj;
|
55734
|
+
},
|
55735
|
+
create(base) {
|
55736
|
+
return PreprocessStreamRequest.fromPartial(base ?? {});
|
55737
|
+
},
|
55738
|
+
fromPartial(object2) {
|
55739
|
+
const message = createBasePreprocessStreamRequest();
|
55740
|
+
message.processId = object2.processId ?? 0;
|
55741
|
+
message.bindings = object2.bindings !== void 0 && object2.bindings !== null ? PreprocessStreamRequest_DataBindings.fromPartial(object2.bindings) : void 0;
|
55742
|
+
message.dbResult = object2.dbResult !== void 0 && object2.dbResult !== null ? DBResponse.fromPartial(object2.dbResult) : void 0;
|
55743
|
+
return message;
|
55744
|
+
}
|
55745
|
+
};
|
55746
|
+
function createBasePreprocessStreamRequest_DataBindings() {
|
55747
|
+
return { bindings: [] };
|
55748
|
+
}
|
55749
|
+
var PreprocessStreamRequest_DataBindings = {
|
55750
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
55751
|
+
for (const v of message.bindings) {
|
55752
|
+
DataBinding2.encode(v, writer.uint32(10).fork()).ldelim();
|
55753
|
+
}
|
55754
|
+
return writer;
|
55755
|
+
},
|
55756
|
+
decode(input, length) {
|
55757
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
55758
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
55759
|
+
const message = createBasePreprocessStreamRequest_DataBindings();
|
55760
|
+
while (reader.pos < end) {
|
55761
|
+
const tag = reader.uint32();
|
55762
|
+
switch (tag >>> 3) {
|
55763
|
+
case 1:
|
55764
|
+
if (tag !== 10) {
|
55765
|
+
break;
|
55766
|
+
}
|
55767
|
+
message.bindings.push(DataBinding2.decode(reader, reader.uint32()));
|
55768
|
+
continue;
|
55769
|
+
}
|
55770
|
+
if ((tag & 7) === 4 || tag === 0) {
|
55771
|
+
break;
|
55772
|
+
}
|
55773
|
+
reader.skipType(tag & 7);
|
55774
|
+
}
|
55775
|
+
return message;
|
55776
|
+
},
|
55777
|
+
fromJSON(object2) {
|
55778
|
+
return {
|
55779
|
+
bindings: globalThis.Array.isArray(object2?.bindings) ? object2.bindings.map((e) => DataBinding2.fromJSON(e)) : []
|
55780
|
+
};
|
55781
|
+
},
|
55782
|
+
toJSON(message) {
|
55783
|
+
const obj = {};
|
55784
|
+
if (message.bindings?.length) {
|
55785
|
+
obj.bindings = message.bindings.map((e) => DataBinding2.toJSON(e));
|
55786
|
+
}
|
55787
|
+
return obj;
|
55788
|
+
},
|
55789
|
+
create(base) {
|
55790
|
+
return PreprocessStreamRequest_DataBindings.fromPartial(base ?? {});
|
55791
|
+
},
|
55792
|
+
fromPartial(object2) {
|
55793
|
+
const message = createBasePreprocessStreamRequest_DataBindings();
|
55794
|
+
message.bindings = object2.bindings?.map((e) => DataBinding2.fromPartial(e)) || [];
|
55795
|
+
return message;
|
55796
|
+
}
|
55797
|
+
};
|
55798
|
+
function createBasePreprocessStreamResponse() {
|
55799
|
+
return { processId: 0, dbRequest: void 0 };
|
55800
|
+
}
|
55801
|
+
var PreprocessStreamResponse = {
|
55802
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
55803
|
+
if (message.processId !== 0) {
|
55804
|
+
writer.uint32(8).int32(message.processId);
|
55805
|
+
}
|
55806
|
+
if (message.dbRequest !== void 0) {
|
55807
|
+
DBRequest.encode(message.dbRequest, writer.uint32(18).fork()).ldelim();
|
55808
|
+
}
|
55809
|
+
return writer;
|
55810
|
+
},
|
55811
|
+
decode(input, length) {
|
55812
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
55813
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
55814
|
+
const message = createBasePreprocessStreamResponse();
|
55815
|
+
while (reader.pos < end) {
|
55816
|
+
const tag = reader.uint32();
|
55817
|
+
switch (tag >>> 3) {
|
55818
|
+
case 1:
|
55819
|
+
if (tag !== 8) {
|
55820
|
+
break;
|
55821
|
+
}
|
55822
|
+
message.processId = reader.int32();
|
55823
|
+
continue;
|
55824
|
+
case 2:
|
55825
|
+
if (tag !== 18) {
|
55826
|
+
break;
|
55827
|
+
}
|
55828
|
+
message.dbRequest = DBRequest.decode(reader, reader.uint32());
|
55829
|
+
continue;
|
55830
|
+
}
|
55831
|
+
if ((tag & 7) === 4 || tag === 0) {
|
55832
|
+
break;
|
55833
|
+
}
|
55834
|
+
reader.skipType(tag & 7);
|
55835
|
+
}
|
55836
|
+
return message;
|
55837
|
+
},
|
55838
|
+
fromJSON(object2) {
|
55839
|
+
return {
|
55840
|
+
processId: isSet7(object2.processId) ? globalThis.Number(object2.processId) : 0,
|
55841
|
+
dbRequest: isSet7(object2.dbRequest) ? DBRequest.fromJSON(object2.dbRequest) : void 0
|
55842
|
+
};
|
55843
|
+
},
|
55844
|
+
toJSON(message) {
|
55845
|
+
const obj = {};
|
55846
|
+
if (message.processId !== 0) {
|
55847
|
+
obj.processId = Math.round(message.processId);
|
55848
|
+
}
|
55849
|
+
if (message.dbRequest !== void 0) {
|
55850
|
+
obj.dbRequest = DBRequest.toJSON(message.dbRequest);
|
55851
|
+
}
|
55852
|
+
return obj;
|
55853
|
+
},
|
55854
|
+
create(base) {
|
55855
|
+
return PreprocessStreamResponse.fromPartial(base ?? {});
|
55856
|
+
},
|
55857
|
+
fromPartial(object2) {
|
55858
|
+
const message = createBasePreprocessStreamResponse();
|
55859
|
+
message.processId = object2.processId ?? 0;
|
55860
|
+
message.dbRequest = object2.dbRequest !== void 0 && object2.dbRequest !== null ? DBRequest.fromPartial(object2.dbRequest) : void 0;
|
55861
|
+
return message;
|
55862
|
+
}
|
55863
|
+
};
|
55323
55864
|
function createBaseDBResponse() {
|
55324
55865
|
return {
|
55325
55866
|
opId: BigInt("0"),
|
@@ -56157,7 +56698,8 @@ function createBaseData() {
|
|
56157
56698
|
suiObject: void 0,
|
56158
56699
|
suiObjectChange: void 0,
|
56159
56700
|
fuelCall: void 0,
|
56160
|
-
cosmosCall: void 0
|
56701
|
+
cosmosCall: void 0,
|
56702
|
+
starknetEvents: void 0
|
56161
56703
|
};
|
56162
56704
|
}
|
56163
56705
|
var Data = {
|
@@ -56207,6 +56749,9 @@ var Data = {
|
|
56207
56749
|
if (message.cosmosCall !== void 0) {
|
56208
56750
|
Data_CosmosCall.encode(message.cosmosCall, writer.uint32(122).fork()).ldelim();
|
56209
56751
|
}
|
56752
|
+
if (message.starknetEvents !== void 0) {
|
56753
|
+
Data_StarknetEvent.encode(message.starknetEvents, writer.uint32(130).fork()).ldelim();
|
56754
|
+
}
|
56210
56755
|
return writer;
|
56211
56756
|
},
|
56212
56757
|
decode(input, length) {
|
@@ -56306,6 +56851,12 @@ var Data = {
|
|
56306
56851
|
}
|
56307
56852
|
message.cosmosCall = Data_CosmosCall.decode(reader, reader.uint32());
|
56308
56853
|
continue;
|
56854
|
+
case 16:
|
56855
|
+
if (tag !== 130) {
|
56856
|
+
break;
|
56857
|
+
}
|
56858
|
+
message.starknetEvents = Data_StarknetEvent.decode(reader, reader.uint32());
|
56859
|
+
continue;
|
56309
56860
|
}
|
56310
56861
|
if ((tag & 7) === 4 || tag === 0) {
|
56311
56862
|
break;
|
@@ -56330,7 +56881,8 @@ var Data = {
|
|
56330
56881
|
suiObject: isSet7(object2.suiObject) ? Data_SuiObject.fromJSON(object2.suiObject) : void 0,
|
56331
56882
|
suiObjectChange: isSet7(object2.suiObjectChange) ? Data_SuiObjectChange.fromJSON(object2.suiObjectChange) : void 0,
|
56332
56883
|
fuelCall: isSet7(object2.fuelCall) ? Data_FuelCall.fromJSON(object2.fuelCall) : void 0,
|
56333
|
-
cosmosCall: isSet7(object2.cosmosCall) ? Data_CosmosCall.fromJSON(object2.cosmosCall) : void 0
|
56884
|
+
cosmosCall: isSet7(object2.cosmosCall) ? Data_CosmosCall.fromJSON(object2.cosmosCall) : void 0,
|
56885
|
+
starknetEvents: isSet7(object2.starknetEvents) ? Data_StarknetEvent.fromJSON(object2.starknetEvents) : void 0
|
56334
56886
|
};
|
56335
56887
|
},
|
56336
56888
|
toJSON(message) {
|
@@ -56380,6 +56932,9 @@ var Data = {
|
|
56380
56932
|
if (message.cosmosCall !== void 0) {
|
56381
56933
|
obj.cosmosCall = Data_CosmosCall.toJSON(message.cosmosCall);
|
56382
56934
|
}
|
56935
|
+
if (message.starknetEvents !== void 0) {
|
56936
|
+
obj.starknetEvents = Data_StarknetEvent.toJSON(message.starknetEvents);
|
56937
|
+
}
|
56383
56938
|
return obj;
|
56384
56939
|
},
|
56385
56940
|
create(base) {
|
@@ -56402,6 +56957,7 @@ var Data = {
|
|
56402
56957
|
message.suiObjectChange = object2.suiObjectChange !== void 0 && object2.suiObjectChange !== null ? Data_SuiObjectChange.fromPartial(object2.suiObjectChange) : void 0;
|
56403
56958
|
message.fuelCall = object2.fuelCall !== void 0 && object2.fuelCall !== null ? Data_FuelCall.fromPartial(object2.fuelCall) : void 0;
|
56404
56959
|
message.cosmosCall = object2.cosmosCall !== void 0 && object2.cosmosCall !== null ? Data_CosmosCall.fromPartial(object2.cosmosCall) : void 0;
|
56960
|
+
message.starknetEvents = object2.starknetEvents !== void 0 && object2.starknetEvents !== null ? Data_StarknetEvent.fromPartial(object2.starknetEvents) : void 0;
|
56405
56961
|
return message;
|
56406
56962
|
}
|
56407
56963
|
};
|
@@ -57148,15 +57704,194 @@ var Data_SuiEvent = {
|
|
57148
57704
|
},
|
57149
57705
|
fromJSON(object2) {
|
57150
57706
|
return {
|
57151
|
-
transaction: isObject5(object2.transaction) ? object2.transaction : void 0,
|
57707
|
+
transaction: isObject5(object2.transaction) ? object2.transaction : void 0,
|
57708
|
+
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0,
|
57709
|
+
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
57710
|
+
};
|
57711
|
+
},
|
57712
|
+
toJSON(message) {
|
57713
|
+
const obj = {};
|
57714
|
+
if (message.transaction !== void 0) {
|
57715
|
+
obj.transaction = message.transaction;
|
57716
|
+
}
|
57717
|
+
if (message.timestamp !== void 0) {
|
57718
|
+
obj.timestamp = message.timestamp.toISOString();
|
57719
|
+
}
|
57720
|
+
if (message.slot !== BigInt("0")) {
|
57721
|
+
obj.slot = message.slot.toString();
|
57722
|
+
}
|
57723
|
+
return obj;
|
57724
|
+
},
|
57725
|
+
create(base) {
|
57726
|
+
return Data_SuiEvent.fromPartial(base ?? {});
|
57727
|
+
},
|
57728
|
+
fromPartial(object2) {
|
57729
|
+
const message = createBaseData_SuiEvent();
|
57730
|
+
message.transaction = object2.transaction ?? void 0;
|
57731
|
+
message.timestamp = object2.timestamp ?? void 0;
|
57732
|
+
message.slot = object2.slot ?? BigInt("0");
|
57733
|
+
return message;
|
57734
|
+
}
|
57735
|
+
};
|
57736
|
+
function createBaseData_SuiCall() {
|
57737
|
+
return { transaction: void 0, timestamp: void 0, slot: BigInt("0") };
|
57738
|
+
}
|
57739
|
+
var Data_SuiCall = {
|
57740
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57741
|
+
if (message.transaction !== void 0) {
|
57742
|
+
Struct2.encode(Struct2.wrap(message.transaction), writer.uint32(10).fork()).ldelim();
|
57743
|
+
}
|
57744
|
+
if (message.timestamp !== void 0) {
|
57745
|
+
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
57746
|
+
}
|
57747
|
+
if (message.slot !== BigInt("0")) {
|
57748
|
+
if (BigInt.asUintN(64, message.slot) !== message.slot) {
|
57749
|
+
throw new globalThis.Error("value provided for field message.slot of type uint64 too large");
|
57750
|
+
}
|
57751
|
+
writer.uint32(24).uint64(message.slot.toString());
|
57752
|
+
}
|
57753
|
+
return writer;
|
57754
|
+
},
|
57755
|
+
decode(input, length) {
|
57756
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57757
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
57758
|
+
const message = createBaseData_SuiCall();
|
57759
|
+
while (reader.pos < end) {
|
57760
|
+
const tag = reader.uint32();
|
57761
|
+
switch (tag >>> 3) {
|
57762
|
+
case 1:
|
57763
|
+
if (tag !== 10) {
|
57764
|
+
break;
|
57765
|
+
}
|
57766
|
+
message.transaction = Struct2.unwrap(Struct2.decode(reader, reader.uint32()));
|
57767
|
+
continue;
|
57768
|
+
case 2:
|
57769
|
+
if (tag !== 18) {
|
57770
|
+
break;
|
57771
|
+
}
|
57772
|
+
message.timestamp = fromTimestamp2(Timestamp2.decode(reader, reader.uint32()));
|
57773
|
+
continue;
|
57774
|
+
case 3:
|
57775
|
+
if (tag !== 24) {
|
57776
|
+
break;
|
57777
|
+
}
|
57778
|
+
message.slot = longToBigint3(reader.uint64());
|
57779
|
+
continue;
|
57780
|
+
}
|
57781
|
+
if ((tag & 7) === 4 || tag === 0) {
|
57782
|
+
break;
|
57783
|
+
}
|
57784
|
+
reader.skipType(tag & 7);
|
57785
|
+
}
|
57786
|
+
return message;
|
57787
|
+
},
|
57788
|
+
fromJSON(object2) {
|
57789
|
+
return {
|
57790
|
+
transaction: isObject5(object2.transaction) ? object2.transaction : void 0,
|
57791
|
+
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0,
|
57792
|
+
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
57793
|
+
};
|
57794
|
+
},
|
57795
|
+
toJSON(message) {
|
57796
|
+
const obj = {};
|
57797
|
+
if (message.transaction !== void 0) {
|
57798
|
+
obj.transaction = message.transaction;
|
57799
|
+
}
|
57800
|
+
if (message.timestamp !== void 0) {
|
57801
|
+
obj.timestamp = message.timestamp.toISOString();
|
57802
|
+
}
|
57803
|
+
if (message.slot !== BigInt("0")) {
|
57804
|
+
obj.slot = message.slot.toString();
|
57805
|
+
}
|
57806
|
+
return obj;
|
57807
|
+
},
|
57808
|
+
create(base) {
|
57809
|
+
return Data_SuiCall.fromPartial(base ?? {});
|
57810
|
+
},
|
57811
|
+
fromPartial(object2) {
|
57812
|
+
const message = createBaseData_SuiCall();
|
57813
|
+
message.transaction = object2.transaction ?? void 0;
|
57814
|
+
message.timestamp = object2.timestamp ?? void 0;
|
57815
|
+
message.slot = object2.slot ?? BigInt("0");
|
57816
|
+
return message;
|
57817
|
+
}
|
57818
|
+
};
|
57819
|
+
function createBaseData_SuiObject() {
|
57820
|
+
return { objects: [], self: void 0, timestamp: void 0, slot: BigInt("0") };
|
57821
|
+
}
|
57822
|
+
var Data_SuiObject = {
|
57823
|
+
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57824
|
+
for (const v of message.objects) {
|
57825
|
+
Struct2.encode(Struct2.wrap(v), writer.uint32(10).fork()).ldelim();
|
57826
|
+
}
|
57827
|
+
if (message.self !== void 0) {
|
57828
|
+
Struct2.encode(Struct2.wrap(message.self), writer.uint32(34).fork()).ldelim();
|
57829
|
+
}
|
57830
|
+
if (message.timestamp !== void 0) {
|
57831
|
+
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
57832
|
+
}
|
57833
|
+
if (message.slot !== BigInt("0")) {
|
57834
|
+
if (BigInt.asUintN(64, message.slot) !== message.slot) {
|
57835
|
+
throw new globalThis.Error("value provided for field message.slot of type uint64 too large");
|
57836
|
+
}
|
57837
|
+
writer.uint32(24).uint64(message.slot.toString());
|
57838
|
+
}
|
57839
|
+
return writer;
|
57840
|
+
},
|
57841
|
+
decode(input, length) {
|
57842
|
+
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57843
|
+
let end = length === void 0 ? reader.len : reader.pos + length;
|
57844
|
+
const message = createBaseData_SuiObject();
|
57845
|
+
while (reader.pos < end) {
|
57846
|
+
const tag = reader.uint32();
|
57847
|
+
switch (tag >>> 3) {
|
57848
|
+
case 1:
|
57849
|
+
if (tag !== 10) {
|
57850
|
+
break;
|
57851
|
+
}
|
57852
|
+
message.objects.push(Struct2.unwrap(Struct2.decode(reader, reader.uint32())));
|
57853
|
+
continue;
|
57854
|
+
case 4:
|
57855
|
+
if (tag !== 34) {
|
57856
|
+
break;
|
57857
|
+
}
|
57858
|
+
message.self = Struct2.unwrap(Struct2.decode(reader, reader.uint32()));
|
57859
|
+
continue;
|
57860
|
+
case 2:
|
57861
|
+
if (tag !== 18) {
|
57862
|
+
break;
|
57863
|
+
}
|
57864
|
+
message.timestamp = fromTimestamp2(Timestamp2.decode(reader, reader.uint32()));
|
57865
|
+
continue;
|
57866
|
+
case 3:
|
57867
|
+
if (tag !== 24) {
|
57868
|
+
break;
|
57869
|
+
}
|
57870
|
+
message.slot = longToBigint3(reader.uint64());
|
57871
|
+
continue;
|
57872
|
+
}
|
57873
|
+
if ((tag & 7) === 4 || tag === 0) {
|
57874
|
+
break;
|
57875
|
+
}
|
57876
|
+
reader.skipType(tag & 7);
|
57877
|
+
}
|
57878
|
+
return message;
|
57879
|
+
},
|
57880
|
+
fromJSON(object2) {
|
57881
|
+
return {
|
57882
|
+
objects: globalThis.Array.isArray(object2?.objects) ? [...object2.objects] : [],
|
57883
|
+
self: isObject5(object2.self) ? object2.self : void 0,
|
57152
57884
|
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0,
|
57153
57885
|
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
57154
57886
|
};
|
57155
57887
|
},
|
57156
57888
|
toJSON(message) {
|
57157
57889
|
const obj = {};
|
57158
|
-
if (message.
|
57159
|
-
obj.
|
57890
|
+
if (message.objects?.length) {
|
57891
|
+
obj.objects = message.objects;
|
57892
|
+
}
|
57893
|
+
if (message.self !== void 0) {
|
57894
|
+
obj.self = message.self;
|
57160
57895
|
}
|
57161
57896
|
if (message.timestamp !== void 0) {
|
57162
57897
|
obj.timestamp = message.timestamp.toISOString();
|
@@ -57167,27 +57902,31 @@ var Data_SuiEvent = {
|
|
57167
57902
|
return obj;
|
57168
57903
|
},
|
57169
57904
|
create(base) {
|
57170
|
-
return
|
57905
|
+
return Data_SuiObject.fromPartial(base ?? {});
|
57171
57906
|
},
|
57172
57907
|
fromPartial(object2) {
|
57173
|
-
const message =
|
57174
|
-
message.
|
57908
|
+
const message = createBaseData_SuiObject();
|
57909
|
+
message.objects = object2.objects?.map((e) => e) || [];
|
57910
|
+
message.self = object2.self ?? void 0;
|
57175
57911
|
message.timestamp = object2.timestamp ?? void 0;
|
57176
57912
|
message.slot = object2.slot ?? BigInt("0");
|
57177
57913
|
return message;
|
57178
57914
|
}
|
57179
57915
|
};
|
57180
|
-
function
|
57181
|
-
return {
|
57916
|
+
function createBaseData_SuiObjectChange() {
|
57917
|
+
return { changes: [], timestamp: void 0, txDigest: "", slot: BigInt("0") };
|
57182
57918
|
}
|
57183
|
-
var
|
57919
|
+
var Data_SuiObjectChange = {
|
57184
57920
|
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57185
|
-
|
57186
|
-
Struct2.encode(Struct2.wrap(
|
57921
|
+
for (const v of message.changes) {
|
57922
|
+
Struct2.encode(Struct2.wrap(v), writer.uint32(10).fork()).ldelim();
|
57187
57923
|
}
|
57188
57924
|
if (message.timestamp !== void 0) {
|
57189
57925
|
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
57190
57926
|
}
|
57927
|
+
if (message.txDigest !== "") {
|
57928
|
+
writer.uint32(34).string(message.txDigest);
|
57929
|
+
}
|
57191
57930
|
if (message.slot !== BigInt("0")) {
|
57192
57931
|
if (BigInt.asUintN(64, message.slot) !== message.slot) {
|
57193
57932
|
throw new globalThis.Error("value provided for field message.slot of type uint64 too large");
|
@@ -57199,7 +57938,7 @@ var Data_SuiCall = {
|
|
57199
57938
|
decode(input, length) {
|
57200
57939
|
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57201
57940
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
57202
|
-
const message =
|
57941
|
+
const message = createBaseData_SuiObjectChange();
|
57203
57942
|
while (reader.pos < end) {
|
57204
57943
|
const tag = reader.uint32();
|
57205
57944
|
switch (tag >>> 3) {
|
@@ -57207,7 +57946,7 @@ var Data_SuiCall = {
|
|
57207
57946
|
if (tag !== 10) {
|
57208
57947
|
break;
|
57209
57948
|
}
|
57210
|
-
message.
|
57949
|
+
message.changes.push(Struct2.unwrap(Struct2.decode(reader, reader.uint32())));
|
57211
57950
|
continue;
|
57212
57951
|
case 2:
|
57213
57952
|
if (tag !== 18) {
|
@@ -57215,97 +57954,11 @@ var Data_SuiCall = {
|
|
57215
57954
|
}
|
57216
57955
|
message.timestamp = fromTimestamp2(Timestamp2.decode(reader, reader.uint32()));
|
57217
57956
|
continue;
|
57218
|
-
case 3:
|
57219
|
-
if (tag !== 24) {
|
57220
|
-
break;
|
57221
|
-
}
|
57222
|
-
message.slot = longToBigint3(reader.uint64());
|
57223
|
-
continue;
|
57224
|
-
}
|
57225
|
-
if ((tag & 7) === 4 || tag === 0) {
|
57226
|
-
break;
|
57227
|
-
}
|
57228
|
-
reader.skipType(tag & 7);
|
57229
|
-
}
|
57230
|
-
return message;
|
57231
|
-
},
|
57232
|
-
fromJSON(object2) {
|
57233
|
-
return {
|
57234
|
-
transaction: isObject5(object2.transaction) ? object2.transaction : void 0,
|
57235
|
-
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0,
|
57236
|
-
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
57237
|
-
};
|
57238
|
-
},
|
57239
|
-
toJSON(message) {
|
57240
|
-
const obj = {};
|
57241
|
-
if (message.transaction !== void 0) {
|
57242
|
-
obj.transaction = message.transaction;
|
57243
|
-
}
|
57244
|
-
if (message.timestamp !== void 0) {
|
57245
|
-
obj.timestamp = message.timestamp.toISOString();
|
57246
|
-
}
|
57247
|
-
if (message.slot !== BigInt("0")) {
|
57248
|
-
obj.slot = message.slot.toString();
|
57249
|
-
}
|
57250
|
-
return obj;
|
57251
|
-
},
|
57252
|
-
create(base) {
|
57253
|
-
return Data_SuiCall.fromPartial(base ?? {});
|
57254
|
-
},
|
57255
|
-
fromPartial(object2) {
|
57256
|
-
const message = createBaseData_SuiCall();
|
57257
|
-
message.transaction = object2.transaction ?? void 0;
|
57258
|
-
message.timestamp = object2.timestamp ?? void 0;
|
57259
|
-
message.slot = object2.slot ?? BigInt("0");
|
57260
|
-
return message;
|
57261
|
-
}
|
57262
|
-
};
|
57263
|
-
function createBaseData_SuiObject() {
|
57264
|
-
return { objects: [], self: void 0, timestamp: void 0, slot: BigInt("0") };
|
57265
|
-
}
|
57266
|
-
var Data_SuiObject = {
|
57267
|
-
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57268
|
-
for (const v of message.objects) {
|
57269
|
-
Struct2.encode(Struct2.wrap(v), writer.uint32(10).fork()).ldelim();
|
57270
|
-
}
|
57271
|
-
if (message.self !== void 0) {
|
57272
|
-
Struct2.encode(Struct2.wrap(message.self), writer.uint32(34).fork()).ldelim();
|
57273
|
-
}
|
57274
|
-
if (message.timestamp !== void 0) {
|
57275
|
-
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
57276
|
-
}
|
57277
|
-
if (message.slot !== BigInt("0")) {
|
57278
|
-
if (BigInt.asUintN(64, message.slot) !== message.slot) {
|
57279
|
-
throw new globalThis.Error("value provided for field message.slot of type uint64 too large");
|
57280
|
-
}
|
57281
|
-
writer.uint32(24).uint64(message.slot.toString());
|
57282
|
-
}
|
57283
|
-
return writer;
|
57284
|
-
},
|
57285
|
-
decode(input, length) {
|
57286
|
-
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57287
|
-
let end = length === void 0 ? reader.len : reader.pos + length;
|
57288
|
-
const message = createBaseData_SuiObject();
|
57289
|
-
while (reader.pos < end) {
|
57290
|
-
const tag = reader.uint32();
|
57291
|
-
switch (tag >>> 3) {
|
57292
|
-
case 1:
|
57293
|
-
if (tag !== 10) {
|
57294
|
-
break;
|
57295
|
-
}
|
57296
|
-
message.objects.push(Struct2.unwrap(Struct2.decode(reader, reader.uint32())));
|
57297
|
-
continue;
|
57298
57957
|
case 4:
|
57299
57958
|
if (tag !== 34) {
|
57300
57959
|
break;
|
57301
57960
|
}
|
57302
|
-
message.
|
57303
|
-
continue;
|
57304
|
-
case 2:
|
57305
|
-
if (tag !== 18) {
|
57306
|
-
break;
|
57307
|
-
}
|
57308
|
-
message.timestamp = fromTimestamp2(Timestamp2.decode(reader, reader.uint32()));
|
57961
|
+
message.txDigest = reader.string();
|
57309
57962
|
continue;
|
57310
57963
|
case 3:
|
57311
57964
|
if (tag !== 24) {
|
@@ -57323,66 +57976,57 @@ var Data_SuiObject = {
|
|
57323
57976
|
},
|
57324
57977
|
fromJSON(object2) {
|
57325
57978
|
return {
|
57326
|
-
|
57327
|
-
self: isObject5(object2.self) ? object2.self : void 0,
|
57979
|
+
changes: globalThis.Array.isArray(object2?.changes) ? [...object2.changes] : [],
|
57328
57980
|
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0,
|
57981
|
+
txDigest: isSet7(object2.txDigest) ? globalThis.String(object2.txDigest) : "",
|
57329
57982
|
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
57330
57983
|
};
|
57331
57984
|
},
|
57332
57985
|
toJSON(message) {
|
57333
57986
|
const obj = {};
|
57334
|
-
if (message.
|
57335
|
-
obj.
|
57336
|
-
}
|
57337
|
-
if (message.self !== void 0) {
|
57338
|
-
obj.self = message.self;
|
57987
|
+
if (message.changes?.length) {
|
57988
|
+
obj.changes = message.changes;
|
57339
57989
|
}
|
57340
57990
|
if (message.timestamp !== void 0) {
|
57341
57991
|
obj.timestamp = message.timestamp.toISOString();
|
57342
57992
|
}
|
57993
|
+
if (message.txDigest !== "") {
|
57994
|
+
obj.txDigest = message.txDigest;
|
57995
|
+
}
|
57343
57996
|
if (message.slot !== BigInt("0")) {
|
57344
57997
|
obj.slot = message.slot.toString();
|
57345
57998
|
}
|
57346
57999
|
return obj;
|
57347
58000
|
},
|
57348
58001
|
create(base) {
|
57349
|
-
return
|
58002
|
+
return Data_SuiObjectChange.fromPartial(base ?? {});
|
57350
58003
|
},
|
57351
58004
|
fromPartial(object2) {
|
57352
|
-
const message =
|
57353
|
-
message.
|
57354
|
-
message.self = object2.self ?? void 0;
|
58005
|
+
const message = createBaseData_SuiObjectChange();
|
58006
|
+
message.changes = object2.changes?.map((e) => e) || [];
|
57355
58007
|
message.timestamp = object2.timestamp ?? void 0;
|
58008
|
+
message.txDigest = object2.txDigest ?? "";
|
57356
58009
|
message.slot = object2.slot ?? BigInt("0");
|
57357
58010
|
return message;
|
57358
58011
|
}
|
57359
58012
|
};
|
57360
|
-
function
|
57361
|
-
return {
|
58013
|
+
function createBaseData_FuelCall() {
|
58014
|
+
return { transaction: void 0, timestamp: void 0 };
|
57362
58015
|
}
|
57363
|
-
var
|
58016
|
+
var Data_FuelCall = {
|
57364
58017
|
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57365
|
-
|
57366
|
-
Struct2.encode(Struct2.wrap(
|
58018
|
+
if (message.transaction !== void 0) {
|
58019
|
+
Struct2.encode(Struct2.wrap(message.transaction), writer.uint32(10).fork()).ldelim();
|
57367
58020
|
}
|
57368
58021
|
if (message.timestamp !== void 0) {
|
57369
58022
|
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
57370
58023
|
}
|
57371
|
-
if (message.txDigest !== "") {
|
57372
|
-
writer.uint32(34).string(message.txDigest);
|
57373
|
-
}
|
57374
|
-
if (message.slot !== BigInt("0")) {
|
57375
|
-
if (BigInt.asUintN(64, message.slot) !== message.slot) {
|
57376
|
-
throw new globalThis.Error("value provided for field message.slot of type uint64 too large");
|
57377
|
-
}
|
57378
|
-
writer.uint32(24).uint64(message.slot.toString());
|
57379
|
-
}
|
57380
58024
|
return writer;
|
57381
58025
|
},
|
57382
58026
|
decode(input, length) {
|
57383
58027
|
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57384
58028
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
57385
|
-
const message =
|
58029
|
+
const message = createBaseData_FuelCall();
|
57386
58030
|
while (reader.pos < end) {
|
57387
58031
|
const tag = reader.uint32();
|
57388
58032
|
switch (tag >>> 3) {
|
@@ -57390,7 +58034,7 @@ var Data_SuiObjectChange = {
|
|
57390
58034
|
if (tag !== 10) {
|
57391
58035
|
break;
|
57392
58036
|
}
|
57393
|
-
message.
|
58037
|
+
message.transaction = Struct2.unwrap(Struct2.decode(reader, reader.uint32()));
|
57394
58038
|
continue;
|
57395
58039
|
case 2:
|
57396
58040
|
if (tag !== 18) {
|
@@ -57398,18 +58042,6 @@ var Data_SuiObjectChange = {
|
|
57398
58042
|
}
|
57399
58043
|
message.timestamp = fromTimestamp2(Timestamp2.decode(reader, reader.uint32()));
|
57400
58044
|
continue;
|
57401
|
-
case 4:
|
57402
|
-
if (tag !== 34) {
|
57403
|
-
break;
|
57404
|
-
}
|
57405
|
-
message.txDigest = reader.string();
|
57406
|
-
continue;
|
57407
|
-
case 3:
|
57408
|
-
if (tag !== 24) {
|
57409
|
-
break;
|
57410
|
-
}
|
57411
|
-
message.slot = longToBigint3(reader.uint64());
|
57412
|
-
continue;
|
57413
58045
|
}
|
57414
58046
|
if ((tag & 7) === 4 || tag === 0) {
|
57415
58047
|
break;
|
@@ -57420,44 +58052,34 @@ var Data_SuiObjectChange = {
|
|
57420
58052
|
},
|
57421
58053
|
fromJSON(object2) {
|
57422
58054
|
return {
|
57423
|
-
|
57424
|
-
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0
|
57425
|
-
txDigest: isSet7(object2.txDigest) ? globalThis.String(object2.txDigest) : "",
|
57426
|
-
slot: isSet7(object2.slot) ? BigInt(object2.slot) : BigInt("0")
|
58055
|
+
transaction: isObject5(object2.transaction) ? object2.transaction : void 0,
|
58056
|
+
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0
|
57427
58057
|
};
|
57428
58058
|
},
|
57429
58059
|
toJSON(message) {
|
57430
58060
|
const obj = {};
|
57431
|
-
if (message.
|
57432
|
-
obj.
|
58061
|
+
if (message.transaction !== void 0) {
|
58062
|
+
obj.transaction = message.transaction;
|
57433
58063
|
}
|
57434
58064
|
if (message.timestamp !== void 0) {
|
57435
58065
|
obj.timestamp = message.timestamp.toISOString();
|
57436
58066
|
}
|
57437
|
-
if (message.txDigest !== "") {
|
57438
|
-
obj.txDigest = message.txDigest;
|
57439
|
-
}
|
57440
|
-
if (message.slot !== BigInt("0")) {
|
57441
|
-
obj.slot = message.slot.toString();
|
57442
|
-
}
|
57443
58067
|
return obj;
|
57444
58068
|
},
|
57445
58069
|
create(base) {
|
57446
|
-
return
|
58070
|
+
return Data_FuelCall.fromPartial(base ?? {});
|
57447
58071
|
},
|
57448
58072
|
fromPartial(object2) {
|
57449
|
-
const message =
|
57450
|
-
message.
|
58073
|
+
const message = createBaseData_FuelCall();
|
58074
|
+
message.transaction = object2.transaction ?? void 0;
|
57451
58075
|
message.timestamp = object2.timestamp ?? void 0;
|
57452
|
-
message.txDigest = object2.txDigest ?? "";
|
57453
|
-
message.slot = object2.slot ?? BigInt("0");
|
57454
58076
|
return message;
|
57455
58077
|
}
|
57456
58078
|
};
|
57457
|
-
function
|
58079
|
+
function createBaseData_CosmosCall() {
|
57458
58080
|
return { transaction: void 0, timestamp: void 0 };
|
57459
58081
|
}
|
57460
|
-
var
|
58082
|
+
var Data_CosmosCall = {
|
57461
58083
|
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57462
58084
|
if (message.transaction !== void 0) {
|
57463
58085
|
Struct2.encode(Struct2.wrap(message.transaction), writer.uint32(10).fork()).ldelim();
|
@@ -57470,7 +58092,7 @@ var Data_FuelCall = {
|
|
57470
58092
|
decode(input, length) {
|
57471
58093
|
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57472
58094
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
57473
|
-
const message =
|
58095
|
+
const message = createBaseData_CosmosCall();
|
57474
58096
|
while (reader.pos < end) {
|
57475
58097
|
const tag = reader.uint32();
|
57476
58098
|
switch (tag >>> 3) {
|
@@ -57511,22 +58133,22 @@ var Data_FuelCall = {
|
|
57511
58133
|
return obj;
|
57512
58134
|
},
|
57513
58135
|
create(base) {
|
57514
|
-
return
|
58136
|
+
return Data_CosmosCall.fromPartial(base ?? {});
|
57515
58137
|
},
|
57516
58138
|
fromPartial(object2) {
|
57517
|
-
const message =
|
58139
|
+
const message = createBaseData_CosmosCall();
|
57518
58140
|
message.transaction = object2.transaction ?? void 0;
|
57519
58141
|
message.timestamp = object2.timestamp ?? void 0;
|
57520
58142
|
return message;
|
57521
58143
|
}
|
57522
58144
|
};
|
57523
|
-
function
|
57524
|
-
return {
|
58145
|
+
function createBaseData_StarknetEvent() {
|
58146
|
+
return { result: void 0, timestamp: void 0 };
|
57525
58147
|
}
|
57526
|
-
var
|
58148
|
+
var Data_StarknetEvent = {
|
57527
58149
|
encode(message, writer = import_minimal10.default.Writer.create()) {
|
57528
|
-
if (message.
|
57529
|
-
Struct2.encode(Struct2.wrap(message.
|
58150
|
+
if (message.result !== void 0) {
|
58151
|
+
Struct2.encode(Struct2.wrap(message.result), writer.uint32(10).fork()).ldelim();
|
57530
58152
|
}
|
57531
58153
|
if (message.timestamp !== void 0) {
|
57532
58154
|
Timestamp2.encode(toTimestamp2(message.timestamp), writer.uint32(18).fork()).ldelim();
|
@@ -57536,7 +58158,7 @@ var Data_CosmosCall = {
|
|
57536
58158
|
decode(input, length) {
|
57537
58159
|
const reader = input instanceof import_minimal10.default.Reader ? input : import_minimal10.default.Reader.create(input);
|
57538
58160
|
let end = length === void 0 ? reader.len : reader.pos + length;
|
57539
|
-
const message =
|
58161
|
+
const message = createBaseData_StarknetEvent();
|
57540
58162
|
while (reader.pos < end) {
|
57541
58163
|
const tag = reader.uint32();
|
57542
58164
|
switch (tag >>> 3) {
|
@@ -57544,7 +58166,7 @@ var Data_CosmosCall = {
|
|
57544
58166
|
if (tag !== 10) {
|
57545
58167
|
break;
|
57546
58168
|
}
|
57547
|
-
message.
|
58169
|
+
message.result = Struct2.unwrap(Struct2.decode(reader, reader.uint32()));
|
57548
58170
|
continue;
|
57549
58171
|
case 2:
|
57550
58172
|
if (tag !== 18) {
|
@@ -57562,14 +58184,14 @@ var Data_CosmosCall = {
|
|
57562
58184
|
},
|
57563
58185
|
fromJSON(object2) {
|
57564
58186
|
return {
|
57565
|
-
|
58187
|
+
result: isObject5(object2.result) ? object2.result : void 0,
|
57566
58188
|
timestamp: isSet7(object2.timestamp) ? fromJsonTimestamp2(object2.timestamp) : void 0
|
57567
58189
|
};
|
57568
58190
|
},
|
57569
58191
|
toJSON(message) {
|
57570
58192
|
const obj = {};
|
57571
|
-
if (message.
|
57572
|
-
obj.
|
58193
|
+
if (message.result !== void 0) {
|
58194
|
+
obj.result = message.result;
|
57573
58195
|
}
|
57574
58196
|
if (message.timestamp !== void 0) {
|
57575
58197
|
obj.timestamp = message.timestamp.toISOString();
|
@@ -57577,11 +58199,11 @@ var Data_CosmosCall = {
|
|
57577
58199
|
return obj;
|
57578
58200
|
},
|
57579
58201
|
create(base) {
|
57580
|
-
return
|
58202
|
+
return Data_StarknetEvent.fromPartial(base ?? {});
|
57581
58203
|
},
|
57582
58204
|
fromPartial(object2) {
|
57583
|
-
const message =
|
57584
|
-
message.
|
58205
|
+
const message = createBaseData_StarknetEvent();
|
58206
|
+
message.result = object2.result ?? void 0;
|
57585
58207
|
message.timestamp = object2.timestamp ?? void 0;
|
57586
58208
|
return message;
|
57587
58209
|
}
|
@@ -58816,6 +59438,14 @@ var ProcessorDefinition = {
|
|
58816
59438
|
responseType: ProcessStreamResponse,
|
58817
59439
|
responseStream: true,
|
58818
59440
|
options: {}
|
59441
|
+
},
|
59442
|
+
preprocessBindingsStream: {
|
59443
|
+
name: "PreprocessBindingsStream",
|
59444
|
+
requestType: PreprocessStreamRequest,
|
59445
|
+
requestStream: true,
|
59446
|
+
responseType: PreprocessStreamResponse,
|
59447
|
+
responseStream: true,
|
59448
|
+
options: {}
|
58819
59449
|
}
|
58820
59450
|
}
|
58821
59451
|
};
|
@@ -58896,6 +59526,13 @@ function errorString(e) {
|
|
58896
59526
|
return e.message + "\n" + e.stack;
|
58897
59527
|
}
|
58898
59528
|
var USER_PROCESSOR = "user_processor";
|
59529
|
+
function makeEthCallKey(param) {
|
59530
|
+
if (!param.context) {
|
59531
|
+
throw new Error("null context for eth call");
|
59532
|
+
}
|
59533
|
+
const { chainId, address, blockTag } = param.context;
|
59534
|
+
return `${chainId}|${address}|${blockTag}|${param.calldata}`;
|
59535
|
+
}
|
58899
59536
|
|
58900
59537
|
// src/endpoints.ts
|
58901
59538
|
var _Endpoints = class {
|
@@ -77669,6 +78306,7 @@ function getProvider2(chainId) {
|
|
77669
78306
|
const network = Network.from(parseInt(chainId));
|
77670
78307
|
const address = Endpoints.INSTANCE.chainServer.get(chainId);
|
77671
78308
|
const key = network.chainId.toString() + "-" + address;
|
78309
|
+
console.debug(`init provider for ${chainId}, address: ${address}`);
|
77672
78310
|
let provider = providers.get(key);
|
77673
78311
|
if (provider) {
|
77674
78312
|
return provider;
|
@@ -77790,6 +78428,7 @@ var ProcessorServiceImpl = class {
|
|
77790
78428
|
// private processorConfig: ProcessConfigResponse
|
77791
78429
|
loader;
|
77792
78430
|
shutdownHandler;
|
78431
|
+
preprocessedEthCalls;
|
77793
78432
|
constructor(loader, shutdownHandler) {
|
77794
78433
|
this.loader = loader;
|
77795
78434
|
this.shutdownHandler = shutdownHandler;
|
@@ -77829,7 +78468,7 @@ var ProcessorServiceImpl = class {
|
|
77829
78468
|
return {};
|
77830
78469
|
}
|
77831
78470
|
async processBindings(request, options) {
|
77832
|
-
const ethCallResults = await this.preprocessBindings(request, options);
|
78471
|
+
const ethCallResults = await this.preprocessBindings(request.bindings, void 0, options);
|
77833
78472
|
const promises = [];
|
77834
78473
|
for (const binding of request.bindings) {
|
77835
78474
|
const promise2 = this.processBinding(binding, { ethCallResults });
|
@@ -77849,10 +78488,11 @@ var ProcessorServiceImpl = class {
|
|
77849
78488
|
result
|
77850
78489
|
};
|
77851
78490
|
}
|
77852
|
-
async preprocessBindings(
|
78491
|
+
async preprocessBindings(bindings, dbContext, options) {
|
78492
|
+
console.debug(`preprocessBindings start, bindings: ${bindings.length}`);
|
77853
78493
|
const promises = [];
|
77854
|
-
for (const binding of
|
77855
|
-
promises.push(this.preprocessBinding(binding, options));
|
78494
|
+
for (const binding of bindings) {
|
78495
|
+
promises.push(this.preprocessBinding(binding, dbContext, options));
|
77856
78496
|
}
|
77857
78497
|
let preprocessResults;
|
77858
78498
|
try {
|
@@ -77860,14 +78500,19 @@ var ProcessorServiceImpl = class {
|
|
77860
78500
|
} catch (e) {
|
77861
78501
|
throw e;
|
77862
78502
|
}
|
78503
|
+
console.debug(
|
78504
|
+
"ethCallParams: ",
|
78505
|
+
preprocessResults.map((r) => r.ethCallParams)
|
78506
|
+
);
|
77863
78507
|
const groupedRequests = /* @__PURE__ */ new Map();
|
77864
78508
|
const providers2 = /* @__PURE__ */ new Map();
|
77865
78509
|
for (const result of preprocessResults) {
|
77866
78510
|
for (const param of result.ethCallParams) {
|
77867
|
-
|
77868
|
-
|
78511
|
+
const { chainId, address, blockTag } = param.context;
|
78512
|
+
if (!providers2.has(chainId)) {
|
78513
|
+
providers2.set(chainId, getProvider2(chainId));
|
77869
78514
|
}
|
77870
|
-
const key =
|
78515
|
+
const key = [chainId, address, blockTag].join("|");
|
77871
78516
|
if (!groupedRequests.has(key)) {
|
77872
78517
|
groupedRequests.set(key, []);
|
77873
78518
|
}
|
@@ -77877,23 +78522,28 @@ var ProcessorServiceImpl = class {
|
|
77877
78522
|
const start = Date.now();
|
77878
78523
|
const callPromises = [];
|
77879
78524
|
for (const params of groupedRequests.values()) {
|
77880
|
-
|
78525
|
+
const { chainId, address, blockTag } = params[0].context;
|
78526
|
+
console.log(`chain: ${chainId}, address: ${address}, blockTag: ${blockTag}, totalCalls: ${params.length}`);
|
77881
78527
|
for (const param of params) {
|
77882
|
-
const frag = new Interface(param.signature);
|
77883
|
-
const calldata = frag.encodeFunctionData(param.function, param.args);
|
77884
78528
|
callPromises.push(
|
77885
|
-
providers2.get(
|
77886
|
-
to:
|
77887
|
-
data: calldata
|
77888
|
-
|
78529
|
+
providers2.get(chainId).call({
|
78530
|
+
to: address,
|
78531
|
+
data: param.calldata,
|
78532
|
+
blockTag
|
78533
|
+
}).then((result) => [makeEthCallKey(param), result])
|
77889
78534
|
);
|
77890
78535
|
}
|
77891
78536
|
}
|
77892
|
-
|
78537
|
+
let results = {};
|
78538
|
+
try {
|
78539
|
+
results = Object.fromEntries(await Promise.all(callPromises));
|
78540
|
+
} catch (e) {
|
78541
|
+
console.error(`eth call error: ${e}`);
|
78542
|
+
}
|
77893
78543
|
console.log(`${callPromises.length} calls finished, elapsed: ${Date.now() - start}ms`);
|
77894
78544
|
return results;
|
77895
78545
|
}
|
77896
|
-
async preprocessBinding(request, options) {
|
78546
|
+
async preprocessBinding(request, dbContext, options) {
|
77897
78547
|
if (!this.started) {
|
77898
78548
|
throw new import_nice_grpc.ServerError(import_nice_grpc.Status.UNAVAILABLE, "Service Not started.");
|
77899
78549
|
}
|
@@ -77909,7 +78559,7 @@ var ProcessorServiceImpl = class {
|
|
77909
78559
|
]
|
77910
78560
|
);
|
77911
78561
|
}
|
77912
|
-
return await PluginManager.INSTANCE.preprocessBinding(request);
|
78562
|
+
return await PluginManager.INSTANCE.preprocessBinding(request, dbContext);
|
77913
78563
|
}
|
77914
78564
|
async processBinding(request, preparedData, options) {
|
77915
78565
|
if (!this.started) {
|
@@ -77944,6 +78594,50 @@ var ProcessorServiceImpl = class {
|
|
77944
78594
|
});
|
77945
78595
|
yield* (0, import_Ix_dom_asynciterable.from)(subject).pipe((0, import_Ix_dom_asynciterable_operators.withAbort)(context2.signal));
|
77946
78596
|
}
|
78597
|
+
async handlePreprocessRequests(requests, subject) {
|
78598
|
+
const contexts = new Contexts();
|
78599
|
+
for await (const request of requests) {
|
78600
|
+
try {
|
78601
|
+
console.debug("received request:", request);
|
78602
|
+
if (request.bindings) {
|
78603
|
+
const bindings = request.bindings.bindings;
|
78604
|
+
const dbContext = contexts.new(request.processId, subject);
|
78605
|
+
const start = Date.now();
|
78606
|
+
this.preprocessBindings(bindings, dbContext).then(() => {
|
78607
|
+
subject.next({
|
78608
|
+
processId: request.processId
|
78609
|
+
});
|
78610
|
+
}).catch((e) => {
|
78611
|
+
console.debug(e);
|
78612
|
+
dbContext.error(request.processId, e);
|
78613
|
+
}).finally(() => {
|
78614
|
+
const cost = Date.now() - start;
|
78615
|
+
console.debug("preprocessBinding", request.processId, " took", cost, "ms");
|
78616
|
+
contexts.delete(request.processId);
|
78617
|
+
});
|
78618
|
+
}
|
78619
|
+
if (request.dbResult) {
|
78620
|
+
const dbContext = contexts.get(request.processId);
|
78621
|
+
dbContext?.result(request.dbResult);
|
78622
|
+
}
|
78623
|
+
} catch (e) {
|
78624
|
+
console.error("unexpect error during handle loop", e);
|
78625
|
+
}
|
78626
|
+
}
|
78627
|
+
}
|
78628
|
+
async *preprocessBindingsStream(requests, context2) {
|
78629
|
+
if (!this.started) {
|
78630
|
+
throw new import_nice_grpc.ServerError(import_nice_grpc.Status.UNAVAILABLE, "Service Not started.");
|
78631
|
+
}
|
78632
|
+
const subject = new import_rxjs.Subject();
|
78633
|
+
this.handlePreprocessRequests(requests, subject).then(() => {
|
78634
|
+
subject.complete();
|
78635
|
+
}).catch((e) => {
|
78636
|
+
console.error(e);
|
78637
|
+
subject.error(e);
|
78638
|
+
});
|
78639
|
+
yield* (0, import_Ix_dom_asynciterable.from)(subject).pipe((0, import_Ix_dom_asynciterable_operators.withAbort)(context2.signal));
|
78640
|
+
}
|
77947
78641
|
async handleRequests(requests, subject) {
|
77948
78642
|
const contexts = new Contexts();
|
77949
78643
|
for await (const request of requests) {
|
@@ -78023,6 +78717,7 @@ export {
|
|
78023
78717
|
mergeProcessResults,
|
78024
78718
|
errorString,
|
78025
78719
|
USER_PROCESSOR,
|
78720
|
+
makeEthCallKey,
|
78026
78721
|
Endpoints,
|
78027
78722
|
require_lib,
|
78028
78723
|
require_lodash,
|