diff --git a/app/app.go b/app/app.go index b6f17490c..acdea5aea 100644 --- a/app/app.go +++ b/app/app.go @@ -306,6 +306,10 @@ func (app *Quicksilver) AppCodec() codec.Codec { return app.appCodec } +func (app *Quicksilver) GetModuleManager() *module.Manager { + return app.mm +} + // InterfaceRegistry returns Quicksilver's InterfaceRegistry. func (app *Quicksilver) InterfaceRegistry() types.InterfaceRegistry { return app.interfaceRegistry diff --git a/go.work.sum b/go.work.sum index 6274cbfb5..a03566d84 100644 --- a/go.work.sum +++ b/go.work.sum @@ -590,6 +590,7 @@ github.com/dave/jennifer v1.2.0/go.mod h1:fIb+770HOpJ2fmN9EPPKOqm1vMGhB+TwXKMZhr github.com/davecgh/go-spew v0.0.0-20161028175848-04cdfd42973b/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c/go.mod h1:6UhI8N9EjYm1c2odKpFpAYeR8dsBeM7PtzQhRgxRr9U= github.com/deckarep/golang-set/v2 v2.6.0/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= +github.com/decred/dcrd/dcrec/secp256k1/v2 v2.0.1/go.mod h1:XmyzkaXBy7ZvHdrTAlXAjpog8qKSAWa3ze7yqzWmgmc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= @@ -611,6 +612,7 @@ github.com/docker/cli v20.10.17+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hH github.com/docker/distribution v2.8.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/docker v1.4.2-0.20180625184442-8e610b2b55bf/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/docker v20.10.19+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v24.0.1+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/docker-credential-helpers v0.6.4/go.mod h1:ofX3UI0Gz1TteYBjtgs07O36Pyasyp66D2uKT7H8W1c= github.com/docker/go-events v0.0.0-20190806004212-e31b211e4f1c/go.mod h1:Uw6UezgYA44ePAFQYUehOuCzmy5zmg/+nl2ZfMWGkpA= github.com/docker/go-metrics v0.0.1/go.mod h1:cG1hvH2utMXtqgqqYE9plW6lDxS3/5ayHzueweSI3Vw= @@ -809,6 +811,7 @@ github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= github.com/google/gofuzz v1.1.1-0.20200604201612-c04b05f3adfa/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gopacket v1.1.19/go.mod h1:iJ8V8n6KS+z2U1A8pUwu8bW5SyEMkXJB8Yo/Vo+TKTo= +github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= github.com/google/martian/v3 v3.3.2/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= github.com/google/pprof v0.0.0-20200507031123-427632fa3b1c/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= @@ -1376,6 +1379,7 @@ github.com/steakknife/hamming v0.0.0-20180906055917-c99c65617cd3/go.mod h1:hpGUW github.com/stefanberger/go-pkcs11uri v0.0.0-20201008174630-78d3cae3a980/go.mod h1:AO3tvPzVZ/ayst6UlUKUv6rcPQInYe3IknH3jYhAKu8= github.com/strangelove-ventures/go-subkey v1.0.7 h1:cOP/Lajg3uxV/tvspu0m6+0Cu+DJgygkEAbx/s+f35I= github.com/strangelove-ventures/go-subkey v1.0.7/go.mod h1:E34izOIEm+sZ1YmYawYRquqBQWeZBjVB4pF7bMuhc1c= +github.com/strangelove-ventures/interchaintest/v6 v6.0.0/go.mod h1:AvF3PkMN6d34VSQuOFz1d6D/fRsx4SMG82V9VBr4ATA= github.com/streadway/amqp v1.0.0/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20200128134331-0f66f006fb2e/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= github.com/stretchr/objx v0.3.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= diff --git a/icq-relayer/go.mod b/icq-relayer/go.mod index a34dd983f..6a5154acb 100644 --- a/icq-relayer/go.mod +++ b/icq-relayer/go.mod @@ -104,6 +104,7 @@ require ( github.com/hashicorp/go-getter v1.7.4 // indirect github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/go-safetemp v1.0.0 // indirect + github.com/hashicorp/go-uuid v1.0.3 // indirect github.com/hashicorp/go-version v1.7.0 // indirect github.com/hashicorp/golang-lru v1.0.2 // indirect github.com/hashicorp/hcl v1.0.0 // indirect diff --git a/test/interchaintest/go.mod b/test/interchaintest/go.mod index 9ee4c6438..17f1959a9 100644 --- a/test/interchaintest/go.mod +++ b/test/interchaintest/go.mod @@ -31,6 +31,7 @@ require ( github.com/armon/go-metrics v0.4.1 // indirect github.com/avast/retry-go/v4 v4.6.0 // indirect github.com/aws/aws-sdk-go v1.54.4 // indirect + github.com/benbjohnson/clock v1.3.0 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect diff --git a/test/interchaintest/go.sum b/test/interchaintest/go.sum index e17eec5ec..b1e05e99e 100644 --- a/test/interchaintest/go.sum +++ b/test/interchaintest/go.sum @@ -859,6 +859,8 @@ github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= github.com/spf13/viper v1.19.0 h1:RWq5SEjt8o25SROyN3z2OrDB9l7RPd3lwTWU8EcEdcI= github.com/spf13/viper v1.19.0/go.mod h1:GQUN9bilAbhU/jgc1bKs99f/suXKeUMct8Adx5+Ntkg= +github.com/strangelove-ventures/go-subkey v1.0.7 h1:cOP/Lajg3uxV/tvspu0m6+0Cu+DJgygkEAbx/s+f35I= +github.com/strangelove-ventures/go-subkey v1.0.7/go.mod h1:E34izOIEm+sZ1YmYawYRquqBQWeZBjVB4pF7bMuhc1c= github.com/strangelove-ventures/interchaintest/v6 v6.0.0 h1:BWdp4v3T/ZCXMzCGQmm+fekEIK2GEyzliLs2UjpdTLE= github.com/strangelove-ventures/interchaintest/v6 v6.0.0/go.mod h1:AvF3PkMN6d34VSQuOFz1d6D/fRsx4SMG82V9VBr4ATA= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= diff --git a/third-party-chains/osmosis-types/validation.go b/third-party-chains/osmosis-types/validation.go index 2428601c8..73279dd53 100644 --- a/third-party-chains/osmosis-types/validation.go +++ b/third-party-chains/osmosis-types/validation.go @@ -93,7 +93,7 @@ func CalculateUnderlyingAssetsFromPosition(ctx sdk.Context, position clmodel.Pos func DetermineApplicableTokensInClPool(ctx sdk.Context, prKeeper ParticipationRewardsKeeper, position clmodel.Position, chainID string) (math.Int, error) { poolID := position.PoolId - pd, ok := prKeeper.GetProtocolData(ctx, participationrewardstypes.ProtocolDataTypeOsmosisPool, fmt.Sprintf("%d", poolID)) + pd, ok := prKeeper.GetProtocolData(ctx, participationrewardstypes.ProtocolDataTypeOsmosisCLPool, fmt.Sprintf("%d", poolID)) if !ok { return sdk.ZeroInt(), fmt.Errorf("unable to obtain protocol data for poolID=%d", poolID) } diff --git a/x/interchainquery/genesis_test.go b/x/interchainquery/genesis_test.go index b7a366103..01e951ba5 100644 --- a/x/interchainquery/genesis_test.go +++ b/x/interchainquery/genesis_test.go @@ -81,6 +81,11 @@ func (s *InterChainQueryTestSuite) TestInitGenesis() { s.Equal("", queryResponse.CallbackId) } +func (s *InterChainQueryTestSuite) TestInitGenesisDefault() { + app := s.GetSimApp(s.chainA) + app.GetModuleManager().Modules[types.ModuleName].InitGenesis(s.chainA.GetContext(), app.AppCodec(), app.GetModuleManager().Modules[types.ModuleName].DefaultGenesis(app.AppCodec())) +} + func newSimAppPath(chainA, chainB *ibctesting.TestChain) *ibctesting.Path { path := ibctesting.NewPath(chainA, chainB) path.EndpointA.ChannelConfig.PortID = ibctesting.TransferPort diff --git a/x/interchainquery/module.go b/x/interchainquery/module.go index c3971bbca..70c5d91ad 100644 --- a/x/interchainquery/module.go +++ b/x/interchainquery/module.go @@ -57,8 +57,8 @@ func (AppModuleBasic) RegisterInterfaces(reg cdctypes.InterfaceRegistry) { } // DefaultGenesis returns the capability module's default genesis state. -func (AppModuleBasic) DefaultGenesis(_ codec.JSONCodec) json.RawMessage { - return nil +func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { + return cdc.MustMarshalJSON(&types.GenesisState{}) } // ValidateGenesis performs genesis state validation for the capability module.