@@ -122,16 +122,12 @@ def key(self):
122
122
def key (self , key : 'Key' ):
123
123
self ._key = c .get_key (key , create_if_not_exists = True )
124
124
return self ._key
125
-
126
125
@classmethod
127
126
def call (cls , * args , ** kwargs ) -> None :
128
127
return c .module ('client' ).call ( * args , ** kwargs )
129
-
130
128
@classmethod
131
129
async def async_call (cls , * args ,** kwargs ):
132
130
return c .call (* args , ** kwargs )
133
-
134
-
135
131
@classmethod
136
132
def call_search (cls ,* args , ** kwargs ) -> None :
137
133
return c .m ('client' ).call_search (* args , ** kwargs )
@@ -1407,10 +1403,15 @@ def search_dict(self, d:dict = 'k,d', search:str = {'k.d': 1}) -> dict:
1407
1403
1408
1404
1409
1405
1406
+ @classmethod
1407
+ def tree (cls , * args , ** kwargs ) -> List [str ]:
1408
+ return c .module ('tree' ).tree (* args , ** kwargs )
1409
+
1410
1410
@classmethod
1411
1411
def tree (cls , * args , ** kwargs ) -> List [str ]:
1412
1412
return c .module ('tree' ).tree (* args , ** kwargs )
1413
1413
1414
+
1414
1415
@classmethod
1415
1416
def tree2path (cls , * args , ** kwargs ) -> List [str ]:
1416
1417
return c .module ('tree' ).tree2path ( * args , ** kwargs )
@@ -1466,10 +1467,13 @@ def simple2path(cls, path:str, **kwargs) -> str:
1466
1467
1467
1468
@classmethod
1468
1469
def simple2objectpath (cls , path :str ,path2objectpath = {'tree' : 'commune.tree.tree.Tree' }, ** kwargs ) -> str :
1470
+
1471
+
1469
1472
if path in path2objectpath :
1470
1473
object_path = path2objectpath [path ]
1471
1474
else :
1472
1475
object_path = c .module ('tree' ).simple2objectpath (path , ** kwargs )
1476
+
1473
1477
return object_path
1474
1478
@classmethod
1475
1479
def simple2object (cls , path :str , ** kwargs ) -> str :
@@ -1541,10 +1545,6 @@ def has_config(cls) -> bool:
1541
1545
@classmethod
1542
1546
def has_module (cls , module ):
1543
1547
return module in c .modules ()
1544
-
1545
- @classmethod
1546
- def Vali (cls , * args , ** kwargs ):
1547
- return c .module ('vali' )
1548
1548
1549
1549
@classmethod
1550
1550
def tasks (cls , task = None , mode = 'pm2' ,** kwargs ) -> List [str ]:
@@ -2492,7 +2492,9 @@ def serve(cls,
2492
2492
'name' : name ,
2493
2493
'address' :address ,
2494
2494
'kwargs' :kwargs
2495
- }
2495
+ }
2496
+
2497
+ c .print (module , name )
2496
2498
module_class = c .module (module )
2497
2499
2498
2500
kwargs .update (extra_kwargs )
@@ -2584,7 +2586,7 @@ def dummy_gen(cls):
2584
2586
def info (self ,
2585
2587
module = None ,
2586
2588
features = ['schema' , 'namespace' , 'commit_hash' , 'hardware' ,'attributes' ,'functions' ],
2587
- lite_features = ['name' , 'address' , 'schema' , 'ss58_address ' , 'description' ],
2589
+ lite_features = ['name' , 'address' , 'schema' , 'key ' , 'description' ],
2588
2590
lite = True ,
2589
2591
cost = False ,
2590
2592
** kwargs
@@ -2619,8 +2621,8 @@ def info(self ,
2619
2621
info ['path' ] = self .module_path () # get the path of the module
2620
2622
if 'address' in features :
2621
2623
info ['address' ] = self .address .replace (c .default_ip , c .ip (update = False ))
2622
- if 'ss58_address ' in features :
2623
- info ['ss58_address ' ] = self .key .ss58_address
2624
+ if 'key ' in features :
2625
+ info ['key ' ] = self .key .ss58_address
2624
2626
if 'code_hash' in features :
2625
2627
info ['code_hash' ] = self .chash () # get the hash of the module (code)
2626
2628
if 'commit_hash' in features :
@@ -3122,8 +3124,8 @@ def transfer_multiple(cls, *args, **kwargs):
3122
3124
3123
3125
3124
3126
@classmethod
3125
- def transfer_stake (cls , * args , ** kwargs ):
3126
- return c .module ('subspace' )().transfer_stake (* args , ** kwargs )
3127
+ def stake_transfer (cls , * args , ** kwargs ):
3128
+ return c .module ('subspace' )().stake_transfer (* args , ** kwargs )
3127
3129
3128
3130
3129
3131
@classmethod
@@ -7012,7 +7014,7 @@ def load_ticket(self, key=None, **kwargs):
7012
7014
@classmethod
7013
7015
def verify_ticket (cls , * args , ** kwargs ):
7014
7016
7015
- return c .get_key ( ).verify_ticket (* args , ** kwargs )
7017
+ return c .module ( 'ticket' ).verify_ticket (* args , ** kwargs )
7016
7018
7017
7019
@classmethod
7018
7020
def load_style (cls ):
0 commit comments