diff --git a/app/app.go b/app/app.go index 8c1ba19bf9..a5e5632607 100644 --- a/app/app.go +++ b/app/app.go @@ -761,7 +761,6 @@ func New( icaModule, ) - // TODO[1760]: app-module: BasicModuleManager: Make sure that this setup has everything we need (it was just copied from the SDK). // BasicModuleManager defines the module BasicManager is in charge of setting up basic, // non-dependant module elements, such as codec registration and genesis verification. // By default it is composed of all the module from the module manager. diff --git a/go.mod b/go.mod index 4d976c2bbc..622f91d400 100644 --- a/go.mod +++ b/go.mod @@ -3,6 +3,7 @@ module github.com/provenance-io/provenance go 1.21 require ( + cosmossdk.io/core v0.11.0 cosmossdk.io/errors v1.0.1 cosmossdk.io/log v1.3.1 cosmossdk.io/math v1.2.0 @@ -32,6 +33,7 @@ require ( github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/hashicorp/go-metrics v0.5.2 github.com/rakyll/statik v0.1.7 + github.com/regen-network/cosmos-proto v0.3.1 // TODO[1760]: Verify that this is still needed github.com/rs/zerolog v1.32.0 github.com/spf13/cast v1.6.0 github.com/spf13/cobra v1.8.0 @@ -46,8 +48,6 @@ require ( gopkg.in/yaml.v2 v2.4.0 ) -require github.com/regen-network/cosmos-proto v0.3.1 - require ( cloud.google.com/go v0.110.10 // indirect cloud.google.com/go/compute v1.23.3 // indirect @@ -57,7 +57,6 @@ require ( cosmossdk.io/api v0.7.3 // indirect cosmossdk.io/client/v2 v2.0.0-beta.1 // indirect cosmossdk.io/collections v0.4.0 // indirect - cosmossdk.io/core v0.11.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect cosmossdk.io/x/circuit v0.1.0 // indirect cosmossdk.io/x/nft v0.1.0 // indirect diff --git a/x/attribute/module.go b/x/attribute/module.go index f1d4bcfdda..d2a5534476 100644 --- a/x/attribute/module.go +++ b/x/attribute/module.go @@ -11,6 +11,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -28,10 +29,11 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) + _ appmodule.HasBeginBlocker = (*AppModule)(nil) ) // AppModuleBasic contains non-dependent elements for the attribute module. diff --git a/x/exchange/module/module.go b/x/exchange/module/module.go index a1f399d199..99f4d7d5f8 100644 --- a/x/exchange/module/module.go +++ b/x/exchange/module/module.go @@ -6,6 +6,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -25,10 +26,10 @@ import ( ) var ( - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModule = AppModule{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) type AppModuleBasic struct { diff --git a/x/hold/module/module.go b/x/hold/module/module.go index 404e7dcc47..40f1d8ba69 100644 --- a/x/hold/module/module.go +++ b/x/hold/module/module.go @@ -6,6 +6,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -25,10 +26,10 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) type AppModule struct { diff --git a/x/ibchooks/module.go b/x/ibchooks/module.go index 936bd5650a..a7f40b527b 100644 --- a/x/ibchooks/module.go +++ b/x/ibchooks/module.go @@ -5,6 +5,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -26,9 +27,10 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the ibchooks module. diff --git a/x/ibcratelimit/module/module.go b/x/ibcratelimit/module/module.go index ecdad2a450..01e51d9f42 100644 --- a/x/ibcratelimit/module/module.go +++ b/x/ibcratelimit/module/module.go @@ -6,6 +6,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -28,10 +29,10 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the ibcratelimit module. diff --git a/x/marker/module.go b/x/marker/module.go index 730b3f1328..e36cd4be88 100644 --- a/x/marker/module.go +++ b/x/marker/module.go @@ -11,6 +11,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" feegrantkeeper "cosmossdk.io/x/feegrant/keeper" "github.com/cosmos/cosmos-sdk/client" @@ -31,9 +32,11 @@ import ( // type check to ensure the interface is properly implemented var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) + _ appmodule.HasBeginBlocker = (*AppModule)(nil) ) // AppModuleBasic contains non-dependent elements for the marker module. diff --git a/x/metadata/module.go b/x/metadata/module.go index f83e94887d..a67d1b40eb 100644 --- a/x/metadata/module.go +++ b/x/metadata/module.go @@ -6,6 +6,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -36,9 +37,10 @@ const StoreKey = types.StoreKey // type check to ensure the interface is properly implemented var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic contains non-dependent elements for the metadata module. diff --git a/x/msgfees/module/module.go b/x/msgfees/module/module.go index de827fdf2b..8b680268eb 100644 --- a/x/msgfees/module/module.go +++ b/x/msgfees/module/module.go @@ -10,6 +10,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" cerrs "cosmossdk.io/errors" sdkclient "github.com/cosmos/cosmos-sdk/client" @@ -26,10 +27,10 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the msgfee module. diff --git a/x/name/module.go b/x/name/module.go index dec09cd7a8..ea37c1656b 100644 --- a/x/name/module.go +++ b/x/name/module.go @@ -6,6 +6,7 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" @@ -28,10 +29,10 @@ import ( // type check to ensure the interface is properly implemented var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic contains non-dependent elements for the name module. diff --git a/x/oracle/module/module.go b/x/oracle/module/module.go index 2a823db534..5b7b3e9543 100644 --- a/x/oracle/module/module.go +++ b/x/oracle/module/module.go @@ -11,6 +11,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" cerrs "cosmossdk.io/errors" sdkclient "github.com/cosmos/cosmos-sdk/client" @@ -30,10 +31,10 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the oracle module. diff --git a/x/reward/module/module.go b/x/reward/module/module.go index a427f916f6..1fb2730042 100644 --- a/x/reward/module/module.go +++ b/x/reward/module/module.go @@ -11,6 +11,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" cerrs "cosmossdk.io/errors" sdkclient "github.com/cosmos/cosmos-sdk/client" @@ -30,9 +31,12 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) + _ appmodule.HasBeginBlocker = (*AppModule)(nil) + _ appmodule.HasEndBlocker = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the reward module. diff --git a/x/trigger/module/module.go b/x/trigger/module/module.go index 977a574237..fdd8401471 100644 --- a/x/trigger/module/module.go +++ b/x/trigger/module/module.go @@ -11,6 +11,7 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" cerrs "cosmossdk.io/errors" sdkclient "github.com/cosmos/cosmos-sdk/client" @@ -30,10 +31,12 @@ import ( ) var ( - _ module.AppModule = AppModule{} - _ module.AppModuleBasic = AppModuleBasic{} - _ module.AppModuleSimulation = AppModule{} - // TODO[1760]: app-module: Add more assertions for the new types and clean up stuff no longer needed. + _ module.AppModuleBasic = (*AppModule)(nil) + _ module.AppModuleSimulation = (*AppModule)(nil) + + _ appmodule.AppModule = (*AppModule)(nil) + _ appmodule.HasBeginBlocker = (*AppModule)(nil) + _ appmodule.HasEndBlocker = (*AppModule)(nil) ) // AppModuleBasic defines the basic application module used by the trigger module.