Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: implement new gov msg & query servers #10868

Merged
merged 49 commits into from
Jan 21, 2022
Merged
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
50bdd18
checkpoint
cmwaters Dec 22, 2021
f9d43a7
add logic for executing and submitting a proposal
cmwaters Jan 4, 2022
b3b859a
go fmt
cmwaters Jan 4, 2022
79c7a64
add proposal test and nil check
cmwaters Jan 4, 2022
be5bcc9
Merge branch 'master' into callum/gov-msg-server
cmwaters Jan 4, 2022
46d984c
Merge branch 'master' into callum/gov-msg-server
cmwaters Jan 7, 2022
099a3c2
resolve merge conflicts
cmwaters Jan 7, 2022
7871f98
fix auth
cmwaters Jan 7, 2022
dbbb0c9
fix missed compile errors
cmwaters Jan 7, 2022
673e972
fix a few tests
cmwaters Jan 7, 2022
3af7d07
fix more tests
cmwaters Jan 7, 2022
833db47
Fix some tests
amaury1093 Jan 11, 2022
1f46581
Fix some more tests
amaury1093 Jan 11, 2022
0b8eeb3
Merge branch 'master' of ssh://github.com/cosmos/cosmos-sdk into call…
amaury1093 Jan 12, 2022
3355e07
Fix 2 or 3 more tests
amaury1093 Jan 12, 2022
d148522
Small cleanups
amaury1093 Jan 12, 2022
b24374a
Fix more
amaury1093 Jan 13, 2022
d46152c
Fix gov query
amaury1093 Jan 13, 2022
f601e56
Use Msg ExecLegacyContent
amaury1093 Jan 13, 2022
c84a25d
Switch some more CLI to v1beta2
amaury1093 Jan 13, 2022
35e16ec
Refactor codec stuff
amaury1093 Jan 14, 2022
176a570
Merge branch 'master' into callum/gov-msg-server
amaury1093 Jan 14, 2022
b255add
Revert proto lints
amaury1093 Jan 14, 2022
d6d24d3
revert orm changes
amaury1093 Jan 14, 2022
06d26d3
Fix proposal_handler test
amaury1093 Jan 14, 2022
a0a4e55
Revert some changes
amaury1093 Jan 14, 2022
b78b053
Move legacy stuff into ExecLegacyContent
amaury1093 Jan 14, 2022
a7e06f6
don't leave any empty []sdk.Msg{}
amaury1093 Jan 14, 2022
e6f2e7c
changelog
amaury1093 Jan 14, 2022
99b0e8f
Merge branch 'master' of ssh://github.com/cosmos/cosmos-sdk into call…
amaury1093 Jan 17, 2022
cf89ee0
Make proto-gen
amaury1093 Jan 17, 2022
24f9a9d
Fix genesis tests
amaury1093 Jan 17, 2022
11ba488
Fix genesis state
amaury1093 Jan 17, 2022
8f13e99
Add test with nested anys
amaury1093 Jan 17, 2022
e910dbf
Fix all tests?
amaury1093 Jan 18, 2022
171ce46
Merge branch 'master' of ssh://github.com/cosmos/cosmos-sdk into call…
amaury1093 Jan 18, 2022
3acea89
Fix feegrant tests with more gas
amaury1093 Jan 18, 2022
be045bd
Update x/gov/keeper/msg_server.go
amaury1093 Jan 20, 2022
43e18e5
Address reviews
amaury1093 Jan 20, 2022
175ffad
Fix querier test
amaury1093 Jan 20, 2022
c760b1e
Merge branch 'master' of ssh://github.com/cosmos/cosmos-sdk into call…
amaury1093 Jan 20, 2022
d16e290
Update x/gov/keeper/querier_test.go
amaury1093 Jan 20, 2022
9ef5dad
Update x/gov/keeper/proposal.go
amaury1093 Jan 20, 2022
4bad077
Address reviews
amaury1093 Jan 20, 2022
0a6e01a
Merge branch 'callum/gov-msg-server' of ssh://github.com/cosmos/cosmo…
amaury1093 Jan 20, 2022
69b2e66
Move all errors to types/errors.go
amaury1093 Jan 20, 2022
a0a2289
Merge branch 'master' of ssh://github.com/cosmos/cosmos-sdk into call…
amaury1093 Jan 21, 2022
d9e4067
make proto-gen
amaury1093 Jan 21, 2022
e1d59ef
Merge branch 'master' into callum/gov-msg-server
amaury1093 Jan 21, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 56 additions & 50 deletions orm/internal/testpb/testschema.proto
Original file line number Diff line number Diff line change
Expand Up @@ -11,72 +11,78 @@ option go_package = "github.com/cosmos/cosmos-sdk/orm/internal/testpb";
message A {
option (cosmos.orm.v1alpha1.table) = {
id: 1;
primary_key: {
fields: "u32,u64,str"
}
index:{
id: 1;
fields:"u64,str"
}
index:{
id: 2;
fields:"str,u32"
}
index:{
id: 3;
fields:"bz,str"
}
};
primary_key: {
fields:
"u32,u64,str"
}
index: {
id:
1;
fields:
"u64,str"
}
index: {
id:
2;
fields:
"str,u32"
}
index: {
id:
3;
fields:
"bz,str"
}
};

// Valid key fields:
uint32 u32 = 1;
uint64 u64 = 2;
string str = 3;
bytes bz = 4;
google.protobuf.Timestamp ts = 5;
google.protobuf.Duration dur = 6;
int32 i32 = 7;
sint32 s32 = 8;
sfixed32 sf32 = 9;
int64 i64 = 10;
sint64 s64 = 11;
sfixed64 sf64 = 12;
fixed32 f32 = 13;
fixed64 f64 = 14;
bool b = 15;
Enum e = 16;
// Valid key fields:
uint32 u32 = 1;
uint64 u64 = 2;
string str = 3;
bytes bz = 4;
google.protobuf.Timestamp ts = 5;
google.protobuf.Duration dur = 6;
int32 i32 = 7;
sint32 s32 = 8;
sfixed32 sf32 = 9;
int64 i64 = 10;
sint64 s64 = 11;
sfixed64 sf64 = 12;
fixed32 f32 = 13;
fixed64 f64 = 14;
bool b = 15;
Enum e = 16;

// Invalid key fields:
repeated uint32 repeated = 17;
map<string, uint32> map = 18;
B msg = 19;
oneof sum {
uint32 oneof = 20;
}
// Invalid key fields:
repeated uint32 repeated = 17;
map<string, uint32> map = 18;
B msg = 19;
oneof sum {
uint32 oneof = 20;
}
}

enum Enum {
ENUM_UNSPECIFIED = 0;
ENUM_ONE = 1;
ENUM_TWO = 2;
ENUM_FIVE = 5;
ENUM_NEG_THREE = -3;
ENUM_ONE = 1;
ENUM_TWO = 2;
ENUM_FIVE = 5;
ENUM_NEG_THREE = -3;
}

message B {
option (cosmos.orm.v1alpha1.singleton) = {id: 2};
option (cosmos.orm.v1alpha1.singleton) = {
id: 2
};
string x = 1;
}

message C {
option (cosmos.orm.v1alpha1.table) = {
id: 3
primary_key:{
fields:"id"
auto_increment: true
}
primary_key: {fields: "id" auto_increment: true}
};

uint64 id = 1;
string x = 2;
string x = 2;
}
30 changes: 8 additions & 22 deletions proto/cosmos/gov/v1beta1/gov.proto
Original file line number Diff line number Diff line change
Expand Up @@ -149,45 +149,31 @@ message Vote {
// DepositParams defines the params for deposits on governance proposals.
message DepositParams {
// Minimum deposit for a proposal to enter voting period.
repeated cosmos.base.v1beta1.Coin min_deposit = 1 [
(gogoproto.nullable) = false,
(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"
];
repeated cosmos.base.v1beta1.Coin min_deposit = 1
[(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"];

// Maximum period for Atom holders to deposit on a proposal. Initial value: 2
// months.
google.protobuf.Duration max_deposit_period = 2 [
(gogoproto.nullable) = false,
(gogoproto.stdduration) = true
];
google.protobuf.Duration max_deposit_period = 2 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true];
}

// VotingParams defines the params for voting on governance proposals.
message VotingParams {
// Length of the voting period.
google.protobuf.Duration voting_period = 1
[(gogoproto.nullable) = false, (gogoproto.stdduration) = true];
google.protobuf.Duration voting_period = 1 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true];
}

// TallyParams defines the params for tallying votes on governance proposals.
message TallyParams {
// Minimum percentage of total stake needed to vote for a result to be
// considered valid.
bytes quorum = 1 [
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec",
(gogoproto.nullable) = false
];
bytes quorum = 1 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false];

// Minimum proportion of Yes votes for proposal to pass. Default value: 0.5.
bytes threshold = 2 [
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec",
(gogoproto.nullable) = false
];
bytes threshold = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false];

// Minimum value of Veto votes to Total votes ratio for proposal to be
// vetoed. Default value: 1/3.
bytes veto_threshold = 3 [
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec",
(gogoproto.nullable) = false
];
bytes veto_threshold = 3
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false];
}
6 changes: 6 additions & 0 deletions proto/cosmos/gov/v1beta2/gov.proto
Original file line number Diff line number Diff line change
Expand Up @@ -121,3 +121,9 @@ message TallyParams {
// vetoed. Default value: 1/3.
string veto_threshold = 3 [(cosmos_proto.scalar) = "cosmos.Dec"];
}

// Content is used to wrap the legacy content field into a message. This ensures backwards compatibility
message MsgContent {
google.protobuf.Any content = 1 [(cosmos_proto.accepts_interface) = "Content"];
string authority = 2;
}
amaury1093 marked this conversation as resolved.
Show resolved Hide resolved
4 changes: 2 additions & 2 deletions proto/cosmos/staking/v1beta1/staking.proto
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ message UnbondingDelegation {
// validator_address is the bech32-encoded address of the validator.
string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"];
// entries are the unbonding delegation entries.
repeated UnbondingDelegationEntry entries = 3 [(gogoproto.nullable) = false]; // unbonding delegation entries
repeated UnbondingDelegationEntry entries = 3 [(gogoproto.nullable) = false]; // unbonding delegation entries
}

// UnbondingDelegationEntry defines an unbonding object with relevant metadata.
Expand Down Expand Up @@ -277,7 +277,7 @@ message Redelegation {
// validator_dst_address is the validator redelegation destination operator address.
string validator_dst_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"];
// entries are the redelegation entries.
repeated RedelegationEntry entries = 4 [(gogoproto.nullable) = false]; // redelegation entries
repeated RedelegationEntry entries = 4 [(gogoproto.nullable) = false]; // redelegation entries
}

// Params defines the parameters for the staking module.
Expand Down
11 changes: 6 additions & 5 deletions simapp/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ import (
"github.com/cosmos/cosmos-sdk/x/gov"
govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types"
oldgovtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta2 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"
"github.com/cosmos/cosmos-sdk/x/group"
groupkeeper "github.com/cosmos/cosmos-sdk/x/group/keeper"
groupmodule "github.com/cosmos/cosmos-sdk/x/group/module"
Expand Down Expand Up @@ -296,14 +297,14 @@ func NewSimApp(
app.GroupKeeper = groupkeeper.NewKeeper(keys[group.StoreKey], appCodec, app.msgSvcRouter, app.AccountKeeper)

// register the proposal types
govRouter := oldgovtypes.NewRouter()
govRouter.AddRoute(govtypes.RouterKey, oldgovtypes.ProposalHandler).
govRouter := govv1beta1.NewRouter()
govRouter.AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler).
AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(app.ParamsKeeper)).
AddRoute(distrtypes.RouterKey, distr.NewCommunityPoolSpendProposalHandler(app.DistrKeeper)).
AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(app.UpgradeKeeper))
govKeeper := govkeeper.NewKeeper(
appCodec, keys[govtypes.StoreKey], app.GetSubspace(govtypes.ModuleName), app.AccountKeeper, app.BankKeeper,
&stakingKeeper, govRouter,
&stakingKeeper, govRouter, app.msgSvcRouter,
)

app.GovKeeper = *govKeeper.SetHooks(
Expand Down Expand Up @@ -619,7 +620,7 @@ func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino
paramsKeeper.Subspace(minttypes.ModuleName)
paramsKeeper.Subspace(distrtypes.ModuleName)
paramsKeeper.Subspace(slashingtypes.ModuleName)
paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(oldgovtypes.ParamKeyTable())
paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(govv1beta2.ParamKeyTable())
paramsKeeper.Subspace(crisistypes.ModuleName)

return paramsKeeper
Expand Down
6 changes: 3 additions & 3 deletions x/auth/client/testutil/suite.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import (
banktypes "github.com/cosmos/cosmos-sdk/x/bank/types"
"github.com/cosmos/cosmos-sdk/x/genutil/client/cli"
govtestutil "github.com/cosmos/cosmos-sdk/x/gov/client/testutil"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
v1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
)

type IntegrationTestSuite struct {
Expand Down Expand Up @@ -1508,7 +1508,7 @@ func (s *IntegrationTestSuite) TestAuxSigner() {
val.Address.String(),
"test",
"test desc",
govtypes.ProposalTypeText,
v1beta1.ProposalTypeText,
tc.args...,
)
if tc.expectErr {
Expand Down Expand Up @@ -1752,7 +1752,7 @@ func (s *IntegrationTestSuite) TestAuxToFee() {
tipper.String(),
"test",
"test desc",
govtypes.ProposalTypeText,
v1beta1.ProposalTypeText,
tc.tipperArgs...,
)

Expand Down
4 changes: 2 additions & 2 deletions x/auth/middleware/tips_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/cosmos/cosmos-sdk/types/tx"
"github.com/cosmos/cosmos-sdk/types/tx/signing"
authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"
minttypes "github.com/cosmos/cosmos-sdk/x/mint/types"
)

Expand All @@ -32,7 +32,7 @@ func (s *MWTestSuite) setupAcctsForTips(ctx sdk.Context) (sdk.Context, []testAcc
s.Require().NoError(err)

// Create dummy proposal for tipper to vote on.
prop, err := govtypes.NewProposal(govtypes.NewTextProposal("foo", "bar"), 1, time.Now(), time.Now().Add(time.Hour))
prop, err := govtypes.NewProposal([]sdk.Msg{}, 1, time.Now(), time.Now().Add(time.Hour))
s.Require().NoError(err)
s.app.GovKeeper.SetProposal(ctx, prop)
s.app.GovKeeper.ActivateVotingPeriod(ctx, prop)
Expand Down
2 changes: 1 addition & 1 deletion x/authz/client/cli/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func NewCmdGrantAuthorization() *cobra.Command {

Examples:
$ %s tx %s grant cosmos1skjw.. send %s --spend-limit=1000stake --from=cosmos1skl..
$ %s tx %s grant cosmos1skjw.. generic --msg-type=/cosmos.gov.v1beta1.MsgVote --from=cosmos1sk..
$ %s tx %s grant cosmos1skjw.. generic --msg-type=/cosmos.gov.v1beta2.MsgVote --from=cosmos1sk..
`, version.AppName, authz.ModuleName, bank.SendAuthorization{}.MsgTypeURL(), version.AppName, authz.ModuleName),
),
Args: cobra.ExactArgs(2),
Expand Down
15 changes: 8 additions & 7 deletions x/authz/client/testutil/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ import (
bank "github.com/cosmos/cosmos-sdk/x/bank/types"
govcli "github.com/cosmos/cosmos-sdk/x/gov/client/cli"
govtestutil "github.com/cosmos/cosmos-sdk/x/gov/client/testutil"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta2 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"
stakingcli "github.com/cosmos/cosmos-sdk/x/staking/client/cli"
)

Expand Down Expand Up @@ -54,8 +55,8 @@ func (s *IntegrationTestSuite) SetupSuite() {

// create a proposal with deposit
_, err = govtestutil.MsgSubmitProposal(val.ClientCtx, val.Address.String(),
"Text Proposal 1", "Where is the title!?", govtypes.ProposalTypeText,
fmt.Sprintf("--%s=%s", govcli.FlagDeposit, sdk.NewCoin(s.cfg.BondDenom, govtypes.DefaultMinDepositTokens).String()))
"Text Proposal 1", "Where is the title!?", govv1beta1.ProposalTypeText,
fmt.Sprintf("--%s=%s", govcli.FlagDeposit, sdk.NewCoin(s.cfg.BondDenom, govv1beta2.DefaultMinDepositTokens).String()))
s.Require().NoError(err)

// Create new account in the keyring.
Expand Down Expand Up @@ -139,8 +140,8 @@ func (s *IntegrationTestSuite) TearDownSuite() {
}

var typeMsgSend = bank.SendAuthorization{}.MsgTypeURL()
var typeMsgVote = sdk.MsgTypeURL(&govtypes.MsgVote{})
var typeMsgSubmitProposal = sdk.MsgTypeURL(&govtypes.MsgSubmitProposal{})
var typeMsgVote = sdk.MsgTypeURL(&govv1beta2.MsgVote{})
var typeMsgSubmitProposal = sdk.MsgTypeURL(&govv1beta2.MsgSubmitProposal{})

func (s *IntegrationTestSuite) TestCLITxGrantAuthorization() {
val := s.network.Validators[0]
Expand Down Expand Up @@ -531,7 +532,7 @@ func (s *IntegrationTestSuite) TestExecAuthorizationWithExpiration() {
)
s.Require().NoError(err)
// msg vote
voteTx := fmt.Sprintf(`{"body":{"messages":[{"@type":"/cosmos.gov.v1beta1.MsgVote","proposal_id":"1","voter":"%s","option":"VOTE_OPTION_YES"}],"memo":"","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":[]}`, val.Address.String())
voteTx := fmt.Sprintf(`{"body":{"messages":[{"@type":"/cosmos.gov.v1beta2.MsgVote","proposal_id":"1","voter":"%s","option":"VOTE_OPTION_YES"}],"memo":"","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":[]}`, val.Address.String())
execMsg := testutil.WriteToNewTempFile(s.T(), voteTx)

// waiting for authorization to expires
Expand Down Expand Up @@ -572,7 +573,7 @@ func (s *IntegrationTestSuite) TestNewExecGenericAuthorized() {
s.Require().NoError(err)

// msg vote
voteTx := fmt.Sprintf(`{"body":{"messages":[{"@type":"/cosmos.gov.v1beta1.MsgVote","proposal_id":"1","voter":"%s","option":"VOTE_OPTION_YES"}],"memo":"","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":[]}`, val.Address.String())
voteTx := fmt.Sprintf(`{"body":{"messages":[{"@type":"/cosmos.gov.v1beta2.MsgVote","proposal_id":"1","voter":"%s","option":"VOTE_OPTION_YES"}],"memo":"","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":[]}`, val.Address.String())
execMsg := testutil.WriteToNewTempFile(s.T(), voteTx)

testCases := []struct {
Expand Down
4 changes: 2 additions & 2 deletions x/distribution/client/cli/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/version"
"github.com/cosmos/cosmos-sdk/x/distribution/types"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
)

// Transaction flags for the x/distribution module
Expand Down Expand Up @@ -312,7 +312,7 @@ Where proposal.json contains:
}
content := types.NewCommunityPoolSpendProposal(proposal.Title, proposal.Description, recpAddr, amount)

msg, err := govtypes.NewMsgSubmitProposal(content, deposit, from)
msg, err := govv1beta1.NewMsgSubmitProposal(content, deposit, from)
if err != nil {
return err
}
Expand Down
4 changes: 2 additions & 2 deletions x/distribution/types/codec.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/msgservice"
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"
)

// RegisterLegacyAminoCodec registers the necessary x/distribution interfaces and concrete types
Expand All @@ -28,7 +28,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) {
&MsgFundCommunityPool{},
)
registry.RegisterImplementations(
(*govtypes.Content)(nil),
(*govv1beta1.Content)(nil),
&CommunityPoolSpendProposal{},
)

Expand Down
Loading