11# pylint: disable=too-many-lines
22
33from marshmallow import EXCLUDE , fields , post_load
4- from marshmallow_oneofschema import OneOfSchema
4+ from marshmallow_oneofschema . one_of_schema import OneOfSchema
55
66from starknet_py .abi .v0 .schemas import ContractAbiEntrySchema
77from starknet_py .net .client_models import (
@@ -415,10 +415,10 @@ def make_dataclass(self, data, **kwargs) -> DeployAccountTransactionV3:
415415
416416class DeclareTransactionSchema (OneOfSchema ):
417417 type_schemas = {
418- 0 : DeclareTransactionV0Schema ,
419- 1 : DeclareTransactionV1Schema ,
420- 2 : DeclareTransactionV2Schema ,
421- 3 : DeclareTransactionV3Schema ,
418+ "0" : DeclareTransactionV0Schema ,
419+ "1" : DeclareTransactionV1Schema ,
420+ "2" : DeclareTransactionV2Schema ,
421+ "3" : DeclareTransactionV3Schema ,
422422 }
423423
424424 def get_data_type (self , data ):
@@ -427,9 +427,9 @@ def get_data_type(self, data):
427427
428428class InvokeTransactionSchema (OneOfSchema ):
429429 type_schemas = {
430- 0 : InvokeTransactionV0Schema ,
431- 1 : InvokeTransactionV1Schema ,
432- 3 : InvokeTransactionV3Schema ,
430+ "0" : InvokeTransactionV0Schema ,
431+ "1" : InvokeTransactionV1Schema ,
432+ "3" : InvokeTransactionV3Schema ,
433433 }
434434
435435 def get_obj_type (self , obj ):
@@ -441,8 +441,8 @@ def get_data_type(self, data):
441441
442442class DeployAccountTransactionSchema (OneOfSchema ):
443443 type_schemas = {
444- 1 : DeployAccountTransactionV1Schema ,
445- 3 : DeployAccountTransactionV3Schema ,
444+ "1" : DeployAccountTransactionV1Schema ,
445+ "3" : DeployAccountTransactionV3Schema ,
446446 }
447447
448448 def get_obj_type (self , obj ):
0 commit comments