diff --git a/CHANGELOG.md b/CHANGELOG.md index 9b9ac55cf..b42cafe32 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -99,7 +99,8 @@ Ref: https://keepachangelog.com/en/1.0.0/ * `marker` add `UpdateParams` endpoint and cli [#1991](https://github.com/provenance-io/provenance/pull/1991). * `name` add `UpdateParams` endpoint and cli [#2004](https://github.com/provenance-io/provenance/pull/2004). * Update the exchange `commitment-settlement-fee-calc` cli query to utilize the keyring [#2001](https://github.com/provenance-io/provenance/pull/2001). -* Implement the ProposalMsgs module interface for the internal/provwasm, ibcratelimit, oracle, and sanction modules [#1993](https://github.com/provenance-io/provenance/pull/1993.) +* Implement the ProposalMsgs module interface for the internal/provwasm, ibcratelimit, oracle, and sanction modules [#1993](https://github.com/provenance-io/provenance/pull/1993). +* Update ibcnet relayer to v2.5.2 and fix chain ids for localnet and ibcnet [#2021](https://github.com/provenance-io/provenance/pull/2021). * Breakdown internal/helpers into multiple internal packages [#2019](https://github.com/provenance-io/provenance/pull/2019). ### Client Breaking diff --git a/Makefile b/Makefile index 61b7dab09..165614f64 100644 --- a/Makefile +++ b/Makefile @@ -398,7 +398,7 @@ localnet-stop: # Quick build using ibc environment and go platform target options. RELAYER_MNEMONIC ?= "list judge day spike walk easily outer state fashion library review include leisure casino wagon zoo chuckle alien stock bargain stone wait squeeze fade" RELAYER_KEY ?= tp18uev5722xrwpfd2hnqducmt3qdjsyktmtw558y -RELAYER_VERSION ?= v2.1.2 +RELAYER_VERSION ?= v2.5.2 docker-build-ibc: vendor docker build --target provenance-$(shell uname -m) --tag provenance-io/blockchain-ibc -f networks/ibc/blockchain-ibc/Dockerfile . docker build --target relayer --tag provenance-io/blockchain-relayer -f networks/ibc/blockchain-relayer/Dockerfile --build-arg MNEMONIC=$(RELAYER_MNEMONIC) --build-arg VERSION=$(RELAYER_VERSION) . diff --git a/cmd/provenanced/cmd/root.go b/cmd/provenanced/cmd/root.go index 7c53da56e..74b01bce2 100644 --- a/cmd/provenanced/cmd/root.go +++ b/cmd/provenanced/cmd/root.go @@ -44,6 +44,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/cosmos-sdk/x/crisis" + genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" "github.com/provenance-io/provenance/app" "github.com/provenance-io/provenance/app/params" @@ -307,7 +308,21 @@ func newApp(logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts serverty cast.ToUint32(appOpts.Get(server.FlagStateSyncSnapshotKeepRecent)), ) + homeDir := cast.ToString(appOpts.Get(flags.FlagHome)) chainID := cast.ToString(appOpts.Get(flags.FlagChainID)) + if chainID == "" { + // fallback to genesis chain-id + reader, err := os.Open(filepath.Join(homeDir, "config", "genesis.json")) + if err != nil { + panic(err) + } + defer reader.Close() + + chainID, err = genutiltypes.ParseChainIDFromGenesis(reader) + if err != nil { + panic(fmt.Errorf("failed to parse chain-id from genesis file: %w", err)) + } + } return app.New( logger, db, traceStore, true, skipUpgradeHeights,