From 6bf1aaca7a7841f4f02f622ba88e51834226ba85 Mon Sep 17 00:00:00 2001 From: Chandragupta Singh Date: Mon, 14 Nov 2022 23:06:53 +0530 Subject: [PATCH 1/2] module name changed in tx and query --- scripts/comdex_local_setup/main.py | 2 +- x/bandoracle/client/cli/cli.go | 9 ++++----- x/collector/client/cli/tx.go | 2 +- x/esm/client/cli/tx.go | 4 ++-- x/liquidity/client/cli/query.go | 4 ++-- x/liquidity/client/cli/tx.go | 4 ++-- x/locker/client/cli/cli.go | 9 ++++----- x/rewards/client/cli/query.go | 4 ++-- x/rewards/client/cli/tx.go | 4 ++-- x/tokenmint/client/cli/query.go | 4 ++-- x/tokenmint/client/cli/tx.go | 4 ++-- x/vault/client/cli/query.go | 4 ++-- x/vault/client/cli/tx.go | 4 ++-- 13 files changed, 28 insertions(+), 30 deletions(-) diff --git a/scripts/comdex_local_setup/main.py b/scripts/comdex_local_setup/main.py index 3fb31159c..8f7d41ee2 100644 --- a/scripts/comdex_local_setup/main.py +++ b/scripts/comdex_local_setup/main.py @@ -190,7 +190,7 @@ def CreateLiquidityPair(appID, baseCoinDenom, quoteCoinDenom): print(f"New Liquidity Pair ({baseCoinDenom}, {quoteCoinDenom}) Proposal Submitted ✔️") def CreateLiquidityPool(appID, pairID, depositCoins): - command = f"comdex tx liquidityV1 create-pool {appID} {pairID} {depositCoins} --from {GENESIS_ACCOUNT_NAME} --chain-id {CHAIN_ID} --gas 5000000 --keyring-backend test -y" + command = f"comdex tx liquidity create-pool {appID} {pairID} {depositCoins} --from {GENESIS_ACCOUNT_NAME} --chain-id {CHAIN_ID} --gas 5000000 --keyring-backend test -y" output = subprocess.getstatusoutput(command)[1] output = json.loads(output) if int(output["code"]) != 0: diff --git a/x/bandoracle/client/cli/cli.go b/x/bandoracle/client/cli/cli.go index 2f9b861f4..f6aaa0f47 100644 --- a/x/bandoracle/client/cli/cli.go +++ b/x/bandoracle/client/cli/cli.go @@ -7,15 +7,14 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/comdex-official/comdex/x/bandoracle/types" ) // GetQueryCmd returns the cli query commands for this module. func GetQueryCmd(queryRoute string) *cobra.Command { // Group bandoracle queries under a subcommand. cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "bandoracle", + Short: fmt.Sprintf("Querying commands for the %s module", "bandoracle"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, @@ -32,8 +31,8 @@ func GetQueryCmd(queryRoute string) *cobra.Command { // GetTxCmd returns the transaction commands for this module. func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "bandoracle", + Short: fmt.Sprintf("%s transactions subcommands", "bandoracle"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/collector/client/cli/tx.go b/x/collector/client/cli/tx.go index 7cd18e97b..51d692e61 100644 --- a/x/collector/client/cli/tx.go +++ b/x/collector/client/cli/tx.go @@ -13,7 +13,7 @@ import ( // GetTxCmd returns the transaction commands for this module. func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, + Use: "collector", Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, diff --git a/x/esm/client/cli/tx.go b/x/esm/client/cli/tx.go index a175077b8..83a593b15 100644 --- a/x/esm/client/cli/tx.go +++ b/x/esm/client/cli/tx.go @@ -16,8 +16,8 @@ import ( func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "esm", + Short: fmt.Sprintf("%s transactions subcommands", "esm"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/liquidity/client/cli/query.go b/x/liquidity/client/cli/query.go index e7addd864..f5afa2dec 100644 --- a/x/liquidity/client/cli/query.go +++ b/x/liquidity/client/cli/query.go @@ -17,8 +17,8 @@ import ( // GetQueryCmd returns the cli query commands for this module. func GetQueryCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "liquidity", + Short: fmt.Sprintf("Querying commands for the %s module", "liquidity"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/liquidity/client/cli/tx.go b/x/liquidity/client/cli/tx.go index 8f8d2f891..32f4bb5fc 100644 --- a/x/liquidity/client/cli/tx.go +++ b/x/liquidity/client/cli/tx.go @@ -21,8 +21,8 @@ import ( // GetTxCmd returns the transaction commands for the module. func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "liquidity", + Short: fmt.Sprintf("%s transactions subcommands", "liquidity"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/locker/client/cli/cli.go b/x/locker/client/cli/cli.go index 467240343..c2b51075b 100644 --- a/x/locker/client/cli/cli.go +++ b/x/locker/client/cli/cli.go @@ -7,15 +7,14 @@ import ( "github.com/cosmos/cosmos-sdk/client" - "github.com/comdex-official/comdex/x/locker/types" ) // GetQueryCmd returns the cli query commands for this module. func GetQueryCmd() *cobra.Command { // Group locker queries under a subcommand cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "locker", + Short: fmt.Sprintf("Querying commands for the %s module", "locker"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, @@ -48,8 +47,8 @@ func GetQueryCmd() *cobra.Command { // GetTxCmd returns the transaction commands for this module. func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "locker", + Short: fmt.Sprintf("%s transactions subcommands", "locker"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/rewards/client/cli/query.go b/x/rewards/client/cli/query.go index ed1651595..76467ecf9 100644 --- a/x/rewards/client/cli/query.go +++ b/x/rewards/client/cli/query.go @@ -20,8 +20,8 @@ import ( func GetQueryCmd() *cobra.Command { // Group rewards queries under a subcommand cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "rewards", + Short: fmt.Sprintf("Querying commands for the %s module", "rewards"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/rewards/client/cli/tx.go b/x/rewards/client/cli/tx.go index 953dcf885..bb2cb5ef6 100644 --- a/x/rewards/client/cli/tx.go +++ b/x/rewards/client/cli/tx.go @@ -20,8 +20,8 @@ import ( // GetTxCmd returns the transaction commands for this module . func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "rewards", + Short: fmt.Sprintf("%s transactions subcommands", "rewards"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/tokenmint/client/cli/query.go b/x/tokenmint/client/cli/query.go index da9a20e0d..0ca960c7e 100644 --- a/x/tokenmint/client/cli/query.go +++ b/x/tokenmint/client/cli/query.go @@ -16,8 +16,8 @@ import ( func GetQueryCmd() *cobra.Command { // Group tokenmint queries under a subcommand cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "tokenmint", + Short: fmt.Sprintf("Querying commands for the %s module", "tokenmint"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/tokenmint/client/cli/tx.go b/x/tokenmint/client/cli/tx.go index f8b1ef869..e2409b781 100644 --- a/x/tokenmint/client/cli/tx.go +++ b/x/tokenmint/client/cli/tx.go @@ -16,8 +16,8 @@ import ( // GetTxCmd returns the transaction commands for this module. func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "tokenmint", + Short: fmt.Sprintf("%s transactions subcommands", "tokenmint"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/vault/client/cli/query.go b/x/vault/client/cli/query.go index 2e36719a0..8d61b8f0d 100644 --- a/x/vault/client/cli/query.go +++ b/x/vault/client/cli/query.go @@ -14,8 +14,8 @@ import ( func GetQueryCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "vault", + Short: fmt.Sprintf("Querying commands for the %s module", "vault"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, diff --git a/x/vault/client/cli/tx.go b/x/vault/client/cli/tx.go index f4e59805c..f71f0c89a 100644 --- a/x/vault/client/cli/tx.go +++ b/x/vault/client/cli/tx.go @@ -17,8 +17,8 @@ import ( // GetTxCmd returns the transaction commands for this module . func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), + Use: "vault", + Short: fmt.Sprintf("%s transactions subcommands", "vault"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, From f390da83807e9ab10c17a394ce4882fbb74a13e2 Mon Sep 17 00:00:00 2001 From: Chandragupta Singh Date: Mon, 14 Nov 2022 23:08:47 +0530 Subject: [PATCH 2/2] module name changed in tx and query --- x/esm/client/cli/query.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/x/esm/client/cli/query.go b/x/esm/client/cli/query.go index 332b2a377..fa6d3d0f8 100644 --- a/x/esm/client/cli/query.go +++ b/x/esm/client/cli/query.go @@ -18,8 +18,8 @@ import ( func GetQueryCmd(queryRoute string) *cobra.Command { // Group esm queries under a subcommand cmd := &cobra.Command{ - Use: types.ModuleName, - Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), + Use: "esm", + Short: fmt.Sprintf("Querying commands for the %s module", "esm"), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd,