From 726ec5f9abc4444f1b3d74aafa8e18c8871e7ced Mon Sep 17 00:00:00 2001 From: aleem1413 Date: Thu, 7 Jan 2021 20:01:16 +0530 Subject: [PATCH 1/3] fix cli queries --- x/upgrade/client/cli/query.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/x/upgrade/client/cli/query.go b/x/upgrade/client/cli/query.go index 675dba3a9e8d..e6731d582603 100644 --- a/x/upgrade/client/cli/query.go +++ b/x/upgrade/client/cli/query.go @@ -14,8 +14,11 @@ import ( // GetQueryCmd returns the parent command for all x/upgrade CLi query commands. func GetQueryCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: "Querying commands for the upgrade module", + Use: types.ModuleName, + Short: "Querying commands for the upgrade module", + DisableFlagParsing: true, + SuggestionsMinimumDistance: 2, + RunE: client.ValidateCmd, } cmd.AddCommand( From cdb8104c8e359859b753a6acf21cf095c964653a Mon Sep 17 00:00:00 2001 From: aleem1413 Date: Thu, 7 Jan 2021 20:39:51 +0530 Subject: [PATCH 2/3] fix codec issue --- x/upgrade/client/rest/query.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/upgrade/client/rest/query.go b/x/upgrade/client/rest/query.go index 946430634eff..299f7f7d8f96 100644 --- a/x/upgrade/client/rest/query.go +++ b/x/upgrade/client/rest/query.go @@ -34,7 +34,7 @@ func getCurrentPlanHandler(clientCtx client.Context) func(http.ResponseWriter, * } var plan types.Plan - err = clientCtx.LegacyAmino.UnmarshalBinaryBare(res, &plan) + err = clientCtx.LegacyAmino.UnmarshalJSON(res, &plan) if rest.CheckInternalServerError(w, err) { return } From d7d93c28ba4252e747668844e8e2b2c1b35d6ebd Mon Sep 17 00:00:00 2001 From: aleem1413 Date: Fri, 8 Jan 2021 10:34:06 +0530 Subject: [PATCH 3/3] revert cli --- x/upgrade/client/cli/query.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/x/upgrade/client/cli/query.go b/x/upgrade/client/cli/query.go index e6731d582603..675dba3a9e8d 100644 --- a/x/upgrade/client/cli/query.go +++ b/x/upgrade/client/cli/query.go @@ -14,11 +14,8 @@ import ( // GetQueryCmd returns the parent command for all x/upgrade CLi query commands. func GetQueryCmd() *cobra.Command { cmd := &cobra.Command{ - Use: types.ModuleName, - Short: "Querying commands for the upgrade module", - DisableFlagParsing: true, - SuggestionsMinimumDistance: 2, - RunE: client.ValidateCmd, + Use: types.ModuleName, + Short: "Querying commands for the upgrade module", } cmd.AddCommand(