From 6372b59f1a210e793f5e16b067007ed8512b53f1 Mon Sep 17 00:00:00 2001 From: javiersuweijie Date: Mon, 4 Sep 2023 15:39:56 +0800 Subject: [PATCH] fix: added ica controller params --- app/app.go | 1 + app/upgrades/v2.5/upgrade.go | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/app/app.go b/app/app.go index 6ed498f6..15ea52e7 100644 --- a/app/app.go +++ b/app/app.go @@ -1134,6 +1134,7 @@ func (app *TerraApp) RegisterUpgradeHandlers(cfg module.Configurator) { app.IBCKeeper.ClientKeeper, app.ParamsKeeper, app.ConsensusParamsKeeper, + app.ICAControllerKeeper, ), ) } diff --git a/app/upgrades/v2.5/upgrade.go b/app/upgrades/v2.5/upgrade.go index 268b408a..1c1482c8 100644 --- a/app/upgrades/v2.5/upgrade.go +++ b/app/upgrades/v2.5/upgrade.go @@ -9,6 +9,8 @@ import ( paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" + icacontrollerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" + icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" clientkeeper "github.com/cosmos/ibc-go/v7/modules/core/02-client/keeper" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ibctmmigrations "github.com/cosmos/ibc-go/v7/modules/light-clients/07-tendermint/migrations" @@ -21,6 +23,7 @@ func CreateUpgradeHandler( clientKeeper clientkeeper.Keeper, paramsKeeper paramskeeper.Keeper, consensusParamsKeeper consensuskeeper.Keeper, + icacontrollerKeeper icacontrollerkeeper.Keeper, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { // READ: https://github.com/cosmos/cosmos-sdk/blob/v0.47.4/UPGRADING.md#xconsensus @@ -39,6 +42,9 @@ func CreateUpgradeHandler( params.AllowedClients = append(params.AllowedClients, ibcexported.Localhost) clientKeeper.SetParams(ctx, params) + // READ: https://github.com/terra-money/core/issues/166 + icacontrollerKeeper.SetParams(ctx, icacontrollertypes.DefaultParams()) + return mm.RunMigrations(ctx, cfg, fromVM) } }