diff --git a/.changeset/entries/c11d327fbc88921861fa668675bec2a375e4b30c4ee12d8dbf03bf2bba25bfa5.yaml b/.changeset/entries/c11d327fbc88921861fa668675bec2a375e4b30c4ee12d8dbf03bf2bba25bfa5.yaml new file mode 100644 index 0000000000..ff76ef6e72 --- /dev/null +++ b/.changeset/entries/c11d327fbc88921861fa668675bec2a375e4b30c4ee12d8dbf03bf2bba25bfa5.yaml @@ -0,0 +1,6 @@ +type: deps +module: other +pull_request: 1245 +description: Bump cosmos-sdk to 0.47.5 +backward_compatible: true +date: 2023-09-22T07:47:04.001240328Z diff --git a/app/app.go b/app/app.go index 7cd944480c..c3ddbd40a5 100644 --- a/app/app.go +++ b/app/app.go @@ -127,9 +127,6 @@ type DesmosApp struct { txConfig client.TxConfig interfaceRegistry types.InterfaceRegistry - // non depinject support modules store keys - keys map[string]*storetypes.KVStoreKey - // Keepers AccountKeeper authkeeper.AccountKeeper BankKeeper bankkeeper.Keeper @@ -283,11 +280,13 @@ func NewDesmosApp( app.App = appBuilder.Build(logger, db, traceStore, baseAppOptions...) // set up non depinject support modules store keys - app.keys = sdk.NewKVStoreKeys( + storeKeys := sdk.NewKVStoreKeys( ibcexported.StoreKey, ibctransfertypes.StoreKey, ibcfeetypes.StoreKey, icahosttypes.StoreKey, icacontrollertypes.StoreKey, wasmtypes.StoreKey, ) - app.MountKVStores(app.keys) + for _, key := range storeKeys { + app.RegisterStores(key) + } // load state streaming if enabled if _, _, err := streaming.LoadStreamingServices(app.App.BaseApp, appOpts, app.appCodec, logger, app.kvStoreKeys()); err != nil { @@ -461,12 +460,8 @@ func NewDesmosApp( wasm.NewAppModule(app.appCodec, &app.WasmKeeper, app.StakingKeeper, app.AccountKeeper, app.BankKeeper, app.MsgServiceRouter(), app.GetSubspace(wasmtypes.ModuleName)), } - app.RegisterModules(legacyModules...) - cfg := app.Configurator() - for _, m := range legacyModules { - if s, ok := m.(module.HasServices); ok { - s.RegisterServices(cfg) - } + if err := app.RegisterModules(legacyModules...); err != nil { + panic(err) } // create the simulation manager and define the order of the modules for deterministic simulations @@ -611,10 +606,6 @@ func (app *DesmosApp) TxConfig() client.TxConfig { // // NOTE: This is solely to be used for testing purposes. func (app *DesmosApp) GetKey(storeKey string) *storetypes.KVStoreKey { - if key, ok := app.keys[storeKey]; ok { - return key - } - sk := app.UnsafeFindStoreKey(storeKey) kvStoreKey, ok := sk.(*storetypes.KVStoreKey) if !ok { @@ -632,10 +623,6 @@ func (app *DesmosApp) kvStoreKeys() map[string]*storetypes.KVStoreKey { } } - for _, kv := range app.keys { - keys[kv.Name()] = kv - } - return keys } diff --git a/go.mod b/go.mod index f929a85b36..fa997fafe2 100644 --- a/go.mod +++ b/go.mod @@ -332,7 +332,7 @@ replace ( github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 // Our cosmos-sdk branch is: https://github.com/desmos-labs/cosmos-sdk v0.47.x-desmos - github.com/cosmos/cosmos-sdk => github.com/desmos-labs/cosmos-sdk v0.47.4-desmos + github.com/cosmos/cosmos-sdk => github.com/desmos-labs/cosmos-sdk v0.47.5-desmos // Replace the Cosmos Ledger app with the Desmos fork github.com/cosmos/ledger-cosmos-go => github.com/desmos-labs/ledger-desmos-go v0.12.1-desmos diff --git a/go.sum b/go.sum index 95d795b2ce..452f83b80e 100644 --- a/go.sum +++ b/go.sum @@ -469,8 +469,8 @@ github.com/denis-tingaikin/go-header v0.4.3 h1:tEaZKAlqql6SKCY++utLmkPLd6K8IBM20 github.com/denis-tingaikin/go-header v0.4.3/go.mod h1:0wOCWuN71D5qIgE2nz9KrKmuYBAC2Mra5RassOIQ2/c= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= -github.com/desmos-labs/cosmos-sdk v0.47.4-desmos h1:+pknvZ4fy4tlmN2+pVfXcKP2dO2Co6w6D5FmY0jBbnw= -github.com/desmos-labs/cosmos-sdk v0.47.4-desmos/go.mod h1:R5n+uM7vguVPFap4pgkdvQCT1nVo/OtPwrlAU40rvok= +github.com/desmos-labs/cosmos-sdk v0.47.5-desmos h1:Ogg9qwwhoHaOWRNw8gMzsLjZig5D3jQ1xVqTYb09cc0= +github.com/desmos-labs/cosmos-sdk v0.47.5-desmos/go.mod h1:EHwCeN9IXonsjKcjpS12MqeStdZvIdxt3VYXhus3G3c= github.com/desmos-labs/ledger-desmos-go v0.12.1-desmos h1:uYU67f1pZ7Jht/q9cn5sTdeto0J+lRUHIJgmedDGEVM= github.com/desmos-labs/ledger-desmos-go v0.12.1-desmos/go.mod h1:dhO6kj+Y+AHIOgAe4L9HL/6NDdyyth4q238I9yFpD2g= github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o=