From 9493d6f05ee2944fba9e47c525b54ba1a80e005b Mon Sep 17 00:00:00 2001 From: mmsqe Date: Sat, 28 Sep 2024 20:38:00 +0800 Subject: [PATCH] fix: avoid Address cannot be empty error when upgrade-channels read Tx cmd flags including from address to put in context for more info, https://github.com/cosmos/cosmos-sdk/blob/release/v0.50.x/client/cmd.go#L278 https://github.com/cosmos/cosmos-sdk/blob/release/v0.50.x/client/cmd.go#L192 --- CHANGELOG.md | 1 + modules/core/04-channel/client/cli/tx.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bce1f292dc5..9ef85b65507 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -63,6 +63,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Bug Fixes * (apps/27-interchain-accounts) [\#7277](https://github.com/cosmos/ibc-go/pull/7277) Use `GogoResolver` when populating module query safe allow list to avoid panics from unresolvable protobuf dependencies. +* (core/04-channel) [\#7342](https://github.com/cosmos/ibc-go/pull/7342) Read Tx cmd flags including from address to avoid Address cannot be empty error when upgrade-channels via cli. ## v9.0.0 (unreleased) diff --git a/modules/core/04-channel/client/cli/tx.go b/modules/core/04-channel/client/cli/tx.go index c904336d9f4..748f9cf82be 100644 --- a/modules/core/04-channel/client/cli/tx.go +++ b/modules/core/04-channel/client/cli/tx.go @@ -70,7 +70,7 @@ func newUpgradeChannelsTxCmd() *cobra.Command { RunE: func(cmd *cobra.Command, args []string) error { versionStr := args[0] - clientCtx, err := client.GetClientQueryContext(cmd) + clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err }