From 91dd808b49e18c4b03dafc2746e9d0050f58eef5 Mon Sep 17 00:00:00 2001 From: seungyeon-hwang Date: Tue, 3 Mar 2020 22:32:52 +0900 Subject: [PATCH] crypto: print an error message if the password input failed (#5739) --- CHANGELOG.md | 4 ++++ crypto/keys/keyring.go | 1 + 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 830c683e5c4c..ebeca00ea5ec 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,6 +39,10 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## [v0.38.2] - TBD +### Improvements + +* (crypto/keys) [\#5739](https://github.com/cosmos/cosmos-sdk/pull/5739) Print an error message if the password input failed. + ## [v0.38.1] - 2020-02-11 ### Improvements diff --git a/crypto/keys/keyring.go b/crypto/keys/keyring.go index 3e79c796bdbf..2135c3381719 100644 --- a/crypto/keys/keyring.go +++ b/crypto/keys/keyring.go @@ -569,6 +569,7 @@ func newRealPrompt(dir string, buf io.Reader) func(string) (string, error) { buf := bufio.NewReader(buf) pass, err := input.GetPassword("Enter keyring passphrase:", buf) if err != nil { + fmt.Fprintln(os.Stderr, err) continue }