From dea3c33f18aefeea248ee9ec96a85c46463dc1a4 Mon Sep 17 00:00:00 2001 From: Khanh Hoa Date: Fri, 29 Mar 2024 13:44:51 +0700 Subject: [PATCH] fix duplicate keys --- app/keepers/keepers.go | 8 ++++---- app/keepers/keys.go | 6 ++---- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/app/keepers/keepers.go b/app/keepers/keepers.go index 8e7099e0..96434db0 100644 --- a/app/keepers/keepers.go +++ b/app/keepers/keepers.go @@ -540,13 +540,13 @@ func (appKeepers *AppKeepers) initParamsKeeper(appCodec codec.BinaryCodec, legac paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(govtypesv1.ParamKeyTable()) //nolint:staticcheck paramsKeeper.Subspace(minttypes.ModuleName).WithKeyTable(minttypes.ParamKeyTable()) paramsKeeper.Subspace(crisistypes.ModuleName) - paramsKeeper.Subspace(ibctransfertypes.ModuleName) + paramsKeeper.Subspace(ibctransfertypes.ModuleName).WithKeyTable(ibctransfertypes.ParamKeyTable()) paramsKeeper.Subspace(ratelimitmoduletypes.ModuleName) - paramsKeeper.Subspace(icqtypes.ModuleName) - paramsKeeper.Subspace(icahosttypes.SubModuleName) + paramsKeeper.Subspace(icqtypes.ModuleName).WithKeyTable(icqtypes.ParamKeyTable()) + paramsKeeper.Subspace(icahosttypes.SubModuleName).WithKeyTable(icahosttypes.ParamKeyTable()) paramsKeeper.Subspace(wasm08types.ModuleName) paramsKeeper.Subspace(wasmtypes.ModuleName) - paramsKeeper.Subspace(transfermiddlewaretypes.ModuleName) + paramsKeeper.Subspace(transfermiddlewaretypes.ModuleName).WithKeyTable(transfermiddlewaretypes.ParamKeyTable()) paramsKeeper.Subspace(stakingmiddlewaretypes.ModuleName) paramsKeeper.Subspace(ibctransfermiddlewaretypes.ModuleName) diff --git a/app/keepers/keys.go b/app/keepers/keys.go index 7d616793..e185abde 100644 --- a/app/keepers/keys.go +++ b/app/keepers/keys.go @@ -23,12 +23,10 @@ import ( paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + routertypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v8/packetforward/types" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v8/types" icahosttypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/types" ibctransfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" - ibchost "github.com/cosmos/ibc-go/v8/modules/core/exported" - - routertypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v8/packetforward/types" ibchookstypes "github.com/notional-labs/composable/v6/x/ibc-hooks/types" ratelimitmoduletypes "github.com/notional-labs/composable/v6/x/ratelimit/types" @@ -55,7 +53,7 @@ func (appKeepers *AppKeepers) GenerateKeys() { // Cosmos-SDK modules each have a "key" that allows the application to reference what they've stored on the chain. appKeepers.keys = storetypes.NewKVStoreKeys( authtypes.StoreKey, banktypes.StoreKey, stakingtypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, - govtypes.StoreKey, paramstypes.StoreKey, ibchost.StoreKey, upgradetypes.StoreKey, feegrant.StoreKey, + govtypes.StoreKey, paramstypes.StoreKey, upgradetypes.StoreKey, feegrant.StoreKey, evidencetypes.StoreKey, circuittypes.StoreKey, ibctransfertypes.StoreKey,