Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: file keyring backend key recover error #106

Merged
merged 5 commits into from
Jul 30, 2021

Conversation

daeMOn63
Copy link
Contributor

key recover fails with EOF errors when attempting to read keyring
password from piped file.

This change allows to recover the current *bufio.Reader from the context
instead of creating a new one, in order to have the mnemonic and
password read from the same source.

In still require the application to init the context with a
*bufio.Reader argument to WithInput(r io.Reader).

daeMOn63 added 5 commits July 30, 2021 11:41
key recover fails with EOF errors when attempting to read keyring
password from piped file.

This change allows to recover the current `*bufio.Reader` from the context
instead of creating a new one, in order to have the mnemonic and
password read from the same source.

In still require the application to init the context with a
`*bufio.Reader` argument to `WithInput(r io.Reader)`.
@daeMOn63 daeMOn63 force-pushed the fix_file_keyring_key_recovery branch from 69bd28c to d543d4b Compare July 30, 2021 09:43
@codecov-commenter
Copy link

Codecov Report

Merging #106 (d543d4b) into master (4967618) will increase coverage by 0.11%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #106      +/-   ##
==========================================
+ Coverage   62.94%   63.06%   +0.11%     
==========================================
  Files         631      631              
  Lines       41470    41470              
==========================================
+ Hits        26105    26154      +49     
+ Misses      12967    12909      -58     
- Partials     2398     2407       +9     
Impacted Files Coverage Δ
simapp/app.go 79.59% <ø> (ø)
client/keys/add.go 63.21% <100.00%> (ø)
x/airdrop/types/msgs.go 45.83% <100.00%> (+45.83%) ⬆️
x/bank/types/balance.go 86.66% <100.00%> (ø)
x/airdrop/keeper/keeper.go 69.09% <0.00%> (+14.54%) ⬆️
x/airdrop/keeper/genesis.go 69.23% <0.00%> (+69.23%) ⬆️
x/airdrop/types/airdrop.go 86.66% <0.00%> (+86.66%) ⬆️

@daeMOn63 daeMOn63 merged commit 0cdd05e into master Jul 30, 2021
@daeMOn63 daeMOn63 deleted the fix_file_keyring_key_recovery branch July 30, 2021 13:20
daeMOn63 added a commit that referenced this pull request Aug 2, 2021
* continuation from #106 on other impacted commands:
  *  keys import
  *  keys export
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants