Skip to content

Commit

Permalink
Problem: app don't have access to current keyring-backend config (#483)
Browse files Browse the repository at this point in the history
* Problem: app don't have access to current keyring-backend config

Update CHANGELOG.md

Signed-off-by: yihuang <huang@crypto.com>

* fix lint

---------

Signed-off-by: yihuang <huang@crypto.com>
  • Loading branch information
yihuang committed May 2, 2024
1 parent 7a841e8 commit 62852ba
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (evm) [#469](https://github.com/crypto-org-chain/ethermint/pull/469) More aggressive cache of common parameters in object store.
* (evm) [#470](https://github.com/crypto-org-chain/ethermint/pull/470) State machine always use `ethtypes.MakeSigner` based on current chain config and block number, this is
more accurate.
* (app) [#483](https://github.com/crypto-org-chain/ethermint/pull/483) Make keyring-backend client config accessible in app.

## v0.21.x-cronos

Expand Down
7 changes: 5 additions & 2 deletions server/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,14 +149,17 @@ which accepts a path for the resulting pprof file.
serverCtx.Logger.Info("Unlocking keyring")

// fire unlock precess for keyring
keyringBackend, _ := cmd.Flags().GetString(flags.FlagKeyringBackend)
if keyringBackend == keyring.BackendFile {
krBackend := clientCtx.Keyring.Backend()
if krBackend == keyring.BackendFile {
_, err = clientCtx.Keyring.List()
if err != nil {
return err
}
}

// set keyring backend type to the server context
serverCtx.Viper.Set(flags.FlagKeyringBackend, krBackend)

serverCtx.Logger.Info("starting ABCI with CometBFT")

// amino is needed here for backwards compatibility of REST routes
Expand Down

0 comments on commit 62852ba

Please sign in to comment.