diff --git a/CHANGELOG.md b/CHANGELOG.md index c5f8534..1a22e13 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,7 @@ - [#117](https://github.com/crypto-com/pystarport/pull/117) make event_query_tx_for optional. - [#121](https://github.com/crypto-com/pystarport/pull/121), [#122](https://github.com/crypto-com/pystarport/pull/122), [#125](https://github.com/crypto-com/pystarport/pull/125) Support sdk 0.50. - [#127](https://github.com/crypto-com/pystarport/pull/127) Support adding new key when patching config +- [#128](https://github.com/crypto-com/pystarport/pull/128) fix wrong description on empty flag when create validator and align flags for edit validator. *Feb 7, 2023* diff --git a/pystarport/cluster.py b/pystarport/cluster.py index e1767c6..3b29a9f 100644 --- a/pystarport/cluster.py +++ b/pystarport/cluster.py @@ -416,16 +416,16 @@ def transfer( coins, i=0, generate_only=False, - fees=None, event_query_tx=True, + **kwargs, ): return self.cosmos_cli(i).transfer( from_, to, coins, generate_only, - fees, event_query_tx=event_query_tx, + **kwargs, ) def transfer_from_ledger( @@ -554,11 +554,8 @@ def create_validator( commission_rate="0.1", commission_max_rate="0.2", min_self_delegation="1", - identity="", - website="", - security_contact="", - details="", event_query_tx=True, + **kwargs, ): """MsgCreateValidator create the node with create_node before call this""" @@ -569,11 +566,8 @@ def create_validator( commission_rate, commission_max_rate, min_self_delegation, - identity, - website, - security_contact, - details, event_query_tx=event_query_tx, + **kwargs, ) def edit_validator( @@ -586,6 +580,7 @@ def edit_validator( security_contact=None, details=None, event_query_tx=True, + **kwargs, ): """MsgEditValidator""" return self.cosmos_cli(i).edit_validator( @@ -596,6 +591,7 @@ def edit_validator( security_contact, details, event_query_tx=event_query_tx, + **kwargs, ) def gov_propose(self, proposer, kind, proposal, i=0): diff --git a/pystarport/cosmoscli.py b/pystarport/cosmoscli.py index 869ce1e..55b21b8 100644 --- a/pystarport/cosmoscli.py +++ b/pystarport/cosmoscli.py @@ -346,8 +346,8 @@ def transfer( to, coins, generate_only=False, - fees=None, event_query_tx=True, + **kwargs, ): rsp = json.loads( self.raw( @@ -363,7 +363,7 @@ def transfer( keyring_backend="test", chain_id=self.chain_id, node=self.node_rpc, - fees=fees, + **kwargs, ) ) if not generate_only and rsp["code"] == 0 and event_query_tx: @@ -660,11 +660,8 @@ def create_validator( commission_rate="0.1", commission_max_rate="0.2", min_self_delegation="1", - identity="", - website="", - security_contact="", - details="", event_query_tx=True, + **kwargs, ): """MsgCreateValidator create the node with create_node before call this""" @@ -697,15 +694,12 @@ def create_validator( commission_max_change_rate=commission_max_change_rate, # description moniker=moniker, - identity=identity, - website=website, - security_contact=security_contact, - details=details, # basic home=self.data_dir, node=self.node_rpc, keyring_backend="test", chain_id=self.chain_id, + **kwargs, ) ) if rsp["code"] == 0 and event_query_tx: @@ -721,6 +715,7 @@ def edit_validator( security_contact=None, details=None, event_query_tx=True, + **kwargs, ): """MsgEditValidator""" options = dict( @@ -744,6 +739,7 @@ def edit_validator( keyring_backend="test", chain_id=self.chain_id, **{k: v for k, v in options.items() if v is not None}, + **kwargs, ) ) if rsp["code"] == 0 and event_query_tx: