Co-authored-by: Adam Tucker <adam@osmosis.team> Co-authored-by: Julien Robert <julien@rbrt.fr>
This commit is contained in:
parent
ced9572d86
commit
4e74a30430
@ -42,6 +42,10 @@ Ref: https://keepachangelog.com/en/1.0.0/
|
||||
|
||||
* (crypto/keyring) [#21653](https://github.com/cosmos/cosmos-sdk/pull/21653) New Linux-only backend that adds Linux kernel's `keyctl` support.
|
||||
|
||||
### Improvements
|
||||
|
||||
* (server) [#21941](https://github.com/cosmos/cosmos-sdk/pull/21941) Regenerate addrbook.json for in place testnet.
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* (sims) [21906](https://github.com/cosmos/cosmos-sdk/pull/21906) Skip sims test when running dry on validators
|
||||
|
||||
@ -7,6 +7,7 @@ import (
|
||||
"io"
|
||||
"net"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"runtime/pprof"
|
||||
"strings"
|
||||
"time"
|
||||
@ -749,6 +750,17 @@ func testnetify(ctx *Context, testnetAppCreator types.AppCreator, db dbm.DB, tra
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Regenerate addrbook.json to prevent peers on old network from causing error logs.
|
||||
addrBookPath := filepath.Join(config.RootDir, "config", "addrbook.json")
|
||||
if err := os.Remove(addrBookPath); err != nil && !os.IsNotExist(err) {
|
||||
return nil, fmt.Errorf("failed to remove existing addrbook.json: %w", err)
|
||||
}
|
||||
|
||||
emptyAddrBook := []byte("{}")
|
||||
if err := os.WriteFile(addrBookPath, emptyAddrBook, 0o600); err != nil {
|
||||
return nil, fmt.Errorf("failed to create empty addrbook.json: %w", err)
|
||||
}
|
||||
|
||||
// Load the comet genesis doc provider.
|
||||
genDocProvider := node.DefaultGenesisDocProviderFunc(config)
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user