File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
async_substrate_interface Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 2424
2525import websockets .exceptions
2626from bt_decode import MetadataV15 , PortableRegistry , decode as decode_by_type_string
27+ from scalecodec import GenericVariant
2728from scalecodec .base import ScaleBytes , ScaleType , RuntimeConfigurationObject
2829from scalecodec .type_registry import load_type_registry_preset
2930from scalecodec .types import (
@@ -3912,18 +3913,17 @@ async def get_metadata_call_function(
39123913 module_name : str ,
39133914 call_function_name : str ,
39143915 block_hash : Optional [str ] = None ,
3915- ) -> Optional [list ]:
3916+ ) -> Optional [GenericVariant ]:
39163917 """
3917- Retrieves a list of all call functions in metadata active for given block_hash (or chaintip if block_hash
3918- is omitted)
3918+ Retrieves specified call from the metadata at the block specified, or the chain tip if omitted.
39193919
39203920 Args:
39213921 module_name: name of the module
39223922 call_function_name: name of the call function
39233923 block_hash: optional block hash
39243924
39253925 Returns:
3926- list of call functions
3926+ The dict-like call definition, if found. None otherwise.
39273927 """
39283928 runtime = await self .init_runtime (block_hash = block_hash )
39293929
Original file line number Diff line number Diff line change 1313 GenericRuntimeCallDefinition ,
1414 ss58_encode ,
1515 MultiAccountId ,
16+ GenericVariant ,
1617)
1718from scalecodec .base import ScaleBytes , ScaleType
1819from websockets .sync .client import connect , ClientConnection
@@ -3290,18 +3291,17 @@ def get_metadata_call_function(
32903291 module_name : str ,
32913292 call_function_name : str ,
32923293 block_hash : Optional [str ] = None ,
3293- ) -> Optional [list ]:
3294+ ) -> Optional [GenericVariant ]:
32943295 """
3295- Retrieves a list of all call functions in metadata active for given block_hash (or chaintip if block_hash
3296- is omitted)
3296+ Retrieves specified call from the metadata at the block specified, or the chain tip if omitted.
32973297
32983298 Args:
32993299 module_name: name of the module
33003300 call_function_name: name of the call function
33013301 block_hash: optional block hash
33023302
33033303 Returns:
3304- list of call functions
3304+ The dict-like call definition, if found. None otherwise.
33053305 """
33063306 self .init_runtime (block_hash = block_hash )
33073307
You can’t perform that action at this time.
0 commit comments