From ee34e20ee35dc37392bc9238a97dfc7caa0ffc7a Mon Sep 17 00:00:00 2001 From: atheesh Date: Wed, 29 Dec 2021 12:23:21 +0530 Subject: [PATCH 01/11] move gov types to v1beta2 --- proto/cosmos/gov/v1beta2/genesis.proto | 2 +- proto/cosmos/gov/v1beta2/gov.proto | 2 +- proto/cosmos/gov/v1beta2/query.proto | 2 +- proto/cosmos/gov/v1beta2/tx.proto | 2 +- x/authz/simulation/genesis.go | 4 +- x/gov/keeper/params.go | 14 +-- x/gov/keeper/querier.go | 38 +++--- x/gov/simulation/genesis.go | 12 +- x/gov/types/{ => v1beta2}/codec.go | 2 +- x/gov/types/v1beta2/content.go | 27 ++++ x/gov/types/{ => v1beta2}/deposit.go | 2 +- x/gov/types/v1beta2/errors.go | 22 ++++ x/gov/types/{ => v1beta2}/genesis.go | 2 +- x/gov/types/{ => v1beta2}/genesis.pb.go | 48 +++---- x/gov/types/{ => v1beta2}/genesis_test.go | 7 +- x/gov/types/{ => v1beta2}/gov.pb.go | 132 ++++++++++---------- x/gov/types/{ => v1beta2}/msgs.go | 2 +- x/gov/types/{ => v1beta2}/msgs_test.go | 69 +++++----- x/gov/types/{ => v1beta2}/params.go | 2 +- x/gov/types/{ => v1beta2}/proposal.go | 2 +- x/gov/types/{ => v1beta2}/proposals_test.go | 8 +- x/gov/types/{ => v1beta2}/querier.go | 2 +- x/gov/types/{ => v1beta2}/query.pb.go | 120 +++++++++--------- x/gov/types/{ => v1beta2}/query.pb.gw.go | 32 +---- x/gov/types/{ => v1beta2}/tally.go | 2 +- x/gov/types/{ => v1beta2}/tx.pb.go | 78 ++++++------ x/gov/types/{ => v1beta2}/vote.go | 2 +- 27 files changed, 331 insertions(+), 306 deletions(-) rename x/gov/types/{ => v1beta2}/codec.go (99%) create mode 100644 x/gov/types/v1beta2/content.go rename x/gov/types/{ => v1beta2}/deposit.go (98%) create mode 100644 x/gov/types/v1beta2/errors.go rename x/gov/types/{ => v1beta2}/genesis.go (99%) rename x/gov/types/{ => v1beta2}/genesis.pb.go (88%) mode change 100644 => 100755 rename x/gov/types/{ => v1beta2}/genesis_test.go (53%) rename x/gov/types/{ => v1beta2}/gov.pb.go (91%) mode change 100644 => 100755 rename x/gov/types/{ => v1beta2}/msgs.go (99%) rename x/gov/types/{ => v1beta2}/msgs_test.go (53%) rename x/gov/types/{ => v1beta2}/params.go (99%) rename x/gov/types/{ => v1beta2}/proposal.go (99%) rename x/gov/types/{ => v1beta2}/proposals_test.go (67%) rename x/gov/types/{ => v1beta2}/querier.go (99%) rename x/gov/types/{ => v1beta2}/query.pb.go (94%) mode change 100644 => 100755 rename x/gov/types/{ => v1beta2}/query.pb.gw.go (94%) mode change 100644 => 100755 rename x/gov/types/{ => v1beta2}/tally.go (99%) rename x/gov/types/{ => v1beta2}/tx.pb.go (93%) mode change 100644 => 100755 rename x/gov/types/{ => v1beta2}/vote.go (99%) diff --git a/proto/cosmos/gov/v1beta2/genesis.proto b/proto/cosmos/gov/v1beta2/genesis.proto index 082def6ab26d..edb68877f452 100644 --- a/proto/cosmos/gov/v1beta2/genesis.proto +++ b/proto/cosmos/gov/v1beta2/genesis.proto @@ -4,7 +4,7 @@ package cosmos.gov.v1beta2; import "cosmos/gov/v1beta2/gov.proto"; -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types"; +option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"; // GenesisState defines the gov module's genesis state. message GenesisState { diff --git a/proto/cosmos/gov/v1beta2/gov.proto b/proto/cosmos/gov/v1beta2/gov.proto index 81fc4ebee083..92bcbb2c6def 100644 --- a/proto/cosmos/gov/v1beta2/gov.proto +++ b/proto/cosmos/gov/v1beta2/gov.proto @@ -8,7 +8,7 @@ import "google/protobuf/any.proto"; import "google/protobuf/duration.proto"; import "cosmos_proto/cosmos.proto"; -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types"; +option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"; // VoteOption enumerates the valid vote options for a given governance proposal. enum VoteOption { diff --git a/proto/cosmos/gov/v1beta2/query.proto b/proto/cosmos/gov/v1beta2/query.proto index 14e97dfb932d..944a21566fbc 100644 --- a/proto/cosmos/gov/v1beta2/query.proto +++ b/proto/cosmos/gov/v1beta2/query.proto @@ -6,7 +6,7 @@ import "google/api/annotations.proto"; import "cosmos/gov/v1beta2/gov.proto"; import "cosmos_proto/cosmos.proto"; -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types"; +option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"; // Query defines the gRPC querier service for gov module service Query { diff --git a/proto/cosmos/gov/v1beta2/tx.proto b/proto/cosmos/gov/v1beta2/tx.proto index cb60a3e9c38b..f1869d7150b4 100644 --- a/proto/cosmos/gov/v1beta2/tx.proto +++ b/proto/cosmos/gov/v1beta2/tx.proto @@ -7,7 +7,7 @@ import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; import "google/protobuf/any.proto"; -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types"; +option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2"; // Msg defines the gov Msg service. service Msg { diff --git a/x/authz/simulation/genesis.go b/x/authz/simulation/genesis.go index b95207be9758..2955bf259730 100644 --- a/x/authz/simulation/genesis.go +++ b/x/authz/simulation/genesis.go @@ -9,7 +9,7 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/authz" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) // genGrant returns a slice of authorization grants. @@ -31,7 +31,7 @@ func genGrant(r *rand.Rand, accounts []simtypes.Account) []authz.GrantAuthorizat func generateRandomGrant(r *rand.Rand) *codectypes.Any { authorizations := make([]*codectypes.Any, 2) authorizations[0] = newAnyAuthorization(banktypes.NewSendAuthorization(sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1000))))) - authorizations[1] = newAnyAuthorization(authz.NewGenericAuthorization(sdk.MsgTypeURL(&govtypes.MsgSubmitProposal{}))) + authorizations[1] = newAnyAuthorization(authz.NewGenericAuthorization(sdk.MsgTypeURL(&v1beta2.MsgSubmitProposal{}))) return authorizations[r.Intn(len(authorizations))] } diff --git a/x/gov/keeper/params.go b/x/gov/keeper/params.go index 4ff77cf39216..19200b8d80e0 100644 --- a/x/gov/keeper/params.go +++ b/x/gov/keeper/params.go @@ -2,42 +2,42 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) // GetDepositParams returns the current DepositParams from the global param store func (keeper Keeper) GetDepositParams(ctx sdk.Context) v1beta1.DepositParams { var depositParams v1beta1.DepositParams - keeper.paramSpace.Get(ctx, types.ParamStoreKeyDepositParams, &depositParams) + keeper.paramSpace.Get(ctx, v1beta2.ParamStoreKeyDepositParams, &depositParams) return depositParams } // GetVotingParams returns the current VotingParams from the global param store func (keeper Keeper) GetVotingParams(ctx sdk.Context) v1beta1.VotingParams { var votingParams v1beta1.VotingParams - keeper.paramSpace.Get(ctx, types.ParamStoreKeyVotingParams, &votingParams) + keeper.paramSpace.Get(ctx, v1beta2.ParamStoreKeyVotingParams, &votingParams) return votingParams } // GetTallyParams returns the current TallyParam from the global param store func (keeper Keeper) GetTallyParams(ctx sdk.Context) v1beta1.TallyParams { var tallyParams v1beta1.TallyParams - keeper.paramSpace.Get(ctx, types.ParamStoreKeyTallyParams, &tallyParams) + keeper.paramSpace.Get(ctx, v1beta2.ParamStoreKeyTallyParams, &tallyParams) return tallyParams } // SetDepositParams sets DepositParams to the global param store func (keeper Keeper) SetDepositParams(ctx sdk.Context, depositParams v1beta1.DepositParams) { - keeper.paramSpace.Set(ctx, types.ParamStoreKeyDepositParams, &depositParams) + keeper.paramSpace.Set(ctx, v1beta2.ParamStoreKeyDepositParams, &depositParams) } // SetVotingParams sets VotingParams to the global param store func (keeper Keeper) SetVotingParams(ctx sdk.Context, votingParams v1beta1.VotingParams) { - keeper.paramSpace.Set(ctx, types.ParamStoreKeyVotingParams, &votingParams) + keeper.paramSpace.Set(ctx, v1beta2.ParamStoreKeyVotingParams, &votingParams) } // SetTallyParams sets TallyParams to the global param store func (keeper Keeper) SetTallyParams(ctx sdk.Context, tallyParams v1beta1.TallyParams) { - keeper.paramSpace.Set(ctx, types.ParamStoreKeyTallyParams, &tallyParams) + keeper.paramSpace.Set(ctx, v1beta2.ParamStoreKeyTallyParams, &tallyParams) } diff --git a/x/gov/keeper/querier.go b/x/gov/keeper/querier.go index ff37b1184240..940db802db08 100644 --- a/x/gov/keeper/querier.go +++ b/x/gov/keeper/querier.go @@ -7,36 +7,36 @@ import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) // NewQuerier creates a new gov Querier instance func NewQuerier(keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) sdk.Querier { return func(ctx sdk.Context, path []string, req abci.RequestQuery) ([]byte, error) { switch path[0] { - case types.QueryParams: + case v1beta2.QueryParams: return queryParams(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryProposals: + case v1beta2.QueryProposals: return queryProposals(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryProposal: + case v1beta2.QueryProposal: return queryProposal(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryDeposits: + case v1beta2.QueryDeposits: return queryDeposits(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryDeposit: + case v1beta2.QueryDeposit: return queryDeposit(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryVotes: + case v1beta2.QueryVotes: return queryVotes(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryVote: + case v1beta2.QueryVote: return queryVote(ctx, path[1:], req, keeper, legacyQuerierCdc) - case types.QueryTally: + case v1beta2.QueryTally: return queryTally(ctx, path[1:], req, keeper, legacyQuerierCdc) default: @@ -47,21 +47,21 @@ func NewQuerier(keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) sdk.Querier func queryParams(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { switch path[0] { - case types.ParamDeposit: + case v1beta2.ParamDeposit: bz, err := codec.MarshalJSONIndent(legacyQuerierCdc, keeper.GetDepositParams(ctx)) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONMarshal, err.Error()) } return bz, nil - case types.ParamVoting: + case v1beta2.ParamVoting: bz, err := codec.MarshalJSONIndent(legacyQuerierCdc, keeper.GetVotingParams(ctx)) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONMarshal, err.Error()) } return bz, nil - case types.ParamTallying: + case v1beta2.ParamTallying: bz, err := codec.MarshalJSONIndent(legacyQuerierCdc, keeper.GetTallyParams(ctx)) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONMarshal, err.Error()) @@ -75,7 +75,7 @@ func queryParams(ctx sdk.Context, path []string, req abci.RequestQuery, keeper K // nolint: unparam func queryProposal(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryProposalParams + var params v1beta2.QueryProposalParams err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) @@ -83,7 +83,7 @@ func queryProposal(ctx sdk.Context, path []string, req abci.RequestQuery, keeper proposal, ok := keeper.GetProposal(ctx, params.ProposalID) if !ok { - return nil, sdkerrors.Wrapf(types.ErrUnknownProposal, "%d", params.ProposalID) + return nil, sdkerrors.Wrapf(v1beta2.ErrUnknownProposal, "%d", params.ProposalID) } bz, err := codec.MarshalJSONIndent(legacyQuerierCdc, proposal) @@ -96,7 +96,7 @@ func queryProposal(ctx sdk.Context, path []string, req abci.RequestQuery, keeper // nolint: unparam func queryDeposit(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryDepositParams + var params v1beta2.QueryDepositParams err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) @@ -113,7 +113,7 @@ func queryDeposit(ctx sdk.Context, path []string, req abci.RequestQuery, keeper // nolint: unparam func queryVote(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryVoteParams + var params v1beta2.QueryVoteParams err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) @@ -130,7 +130,7 @@ func queryVote(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Kee // nolint: unparam func queryDeposits(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryProposalParams + var params v1beta2.QueryProposalParams err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) @@ -151,7 +151,7 @@ func queryDeposits(ctx sdk.Context, path []string, req abci.RequestQuery, keeper // nolint: unparam func queryTally(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryProposalParams + var params v1beta2.QueryProposalParams err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) @@ -161,7 +161,7 @@ func queryTally(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Ke proposal, ok := keeper.GetProposal(ctx, proposalID) if !ok { - return nil, sdkerrors.Wrapf(types.ErrUnknownProposal, "%d", proposalID) + return nil, sdkerrors.Wrapf(v1beta2.ErrUnknownProposal, "%d", proposalID) } var tallyResult v1beta1.TallyResult diff --git a/x/gov/simulation/genesis.go b/x/gov/simulation/genesis.go index 3f9ed2d086a7..1d696f0f6f27 100644 --- a/x/gov/simulation/genesis.go +++ b/x/gov/simulation/genesis.go @@ -11,7 +11,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) // Simulation parameter constants @@ -94,11 +94,11 @@ func RandomizedGenState(simState *module.SimulationState) { func(r *rand.Rand) { veto = GenTallyParamsVeto(r) }, ) - govGenesis := types.NewGenesisState( + govGenesis := v1beta2.NewGenesisState( startingProposalID, - types.NewDepositParams(minDeposit, depositPeriod), - types.NewVotingParams(votingPeriod), - types.NewTallyParams(quorum, threshold, veto), + v1beta2.NewDepositParams(minDeposit, depositPeriod), + v1beta2.NewVotingParams(votingPeriod), + v1beta2.NewTallyParams(quorum, threshold, veto), ) bz, err := json.MarshalIndent(&govGenesis, "", " ") @@ -106,5 +106,5 @@ func RandomizedGenState(simState *module.SimulationState) { panic(err) } fmt.Printf("Selected randomly generated governance parameters:\n%s\n", bz) - simState.GenState[types.ModuleName] = simState.Cdc.MustMarshalJSON(govGenesis) + simState.GenState[v1beta2.ModuleName] = simState.Cdc.MustMarshalJSON(govGenesis) } diff --git a/x/gov/types/codec.go b/x/gov/types/v1beta2/codec.go similarity index 99% rename from x/gov/types/codec.go rename to x/gov/types/v1beta2/codec.go index 62da2c5b227b..94915af36907 100644 --- a/x/gov/types/codec.go +++ b/x/gov/types/v1beta2/codec.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "github.com/cosmos/cosmos-sdk/codec" diff --git a/x/gov/types/v1beta2/content.go b/x/gov/types/v1beta2/content.go new file mode 100644 index 000000000000..db0ff42ccc46 --- /dev/null +++ b/x/gov/types/v1beta2/content.go @@ -0,0 +1,27 @@ +package v1beta2 + +import sdk "github.com/cosmos/cosmos-sdk/types" + +// Copied over from /x/gov/types/keys.go to avoid circular imports +const ( + ModuleName = "gov" + + RouterKey = ModuleName +) + +// Content defines an interface that a proposal must implement. It contains +// information such as the title and description along with the type and routing +// information for the appropriate handler to process the proposal. Content can +// have additional fields, which will handled by a proposal's Handler. +type Content interface { + GetTitle() string + GetDescription() string + ProposalRoute() string + ProposalType() string + ValidateBasic() error + String() string +} + +// Handler defines a function that handles a proposal after it has passed the +// governance process. +type Handler func(ctx sdk.Context, content Content) error diff --git a/x/gov/types/deposit.go b/x/gov/types/v1beta2/deposit.go similarity index 98% rename from x/gov/types/deposit.go rename to x/gov/types/v1beta2/deposit.go index 5f106859f1d3..8a5d82ceabf4 100644 --- a/x/gov/types/deposit.go +++ b/x/gov/types/v1beta2/deposit.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "fmt" diff --git a/x/gov/types/v1beta2/errors.go b/x/gov/types/v1beta2/errors.go new file mode 100644 index 000000000000..5dd356a9e6fa --- /dev/null +++ b/x/gov/types/v1beta2/errors.go @@ -0,0 +1,22 @@ +package v1beta2 + +import ( + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +) + +// x/gov module sentinel errors +var ( + ErrUnknownProposal = sdkerrors.Register(ModuleName, 2, "unknown proposal") + ErrInactiveProposal = sdkerrors.Register(ModuleName, 3, "inactive proposal") + ErrAlreadyActiveProposal = sdkerrors.Register(ModuleName, 4, "proposal already active") + // Errors 5 & 6 are reserved as legacy errors + // See x/gov/types/v1beta1/errors.go + ErrInvalidGenesis = sdkerrors.Register(ModuleName, 8, "invalid genesis state") + ErrNoProposalHandlerExists = sdkerrors.Register(ModuleName, 9, "no handler exists for proposal type") + ErrUnroutableProposalMsg = sdkerrors.Register(ModuleName, 10, "proposal message not recognized by router") + ErrNoProposalMsgs = sdkerrors.Register(ModuleName, 11, "no messages proposed") + ErrInvalidProposalMsg = sdkerrors.Register(ModuleName, 12, "invalid proposal message") + ErrInvalidSigner = sdkerrors.Register(ModuleName, 13, "expected gov account as only signer for proposal message") + ErrInvalidSignalMsg = sdkerrors.Register(ModuleName, 14, "signal message is invalid") + ErrInvalidVote = sdkerrors.Register(ModuleName, 15, "invalid vote option") +) diff --git a/x/gov/types/genesis.go b/x/gov/types/v1beta2/genesis.go similarity index 99% rename from x/gov/types/genesis.go rename to x/gov/types/v1beta2/genesis.go index 276a06c442a6..693082b3f581 100644 --- a/x/gov/types/genesis.go +++ b/x/gov/types/v1beta2/genesis.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "errors" diff --git a/x/gov/types/genesis.pb.go b/x/gov/types/v1beta2/genesis.pb.go old mode 100644 new mode 100755 similarity index 88% rename from x/gov/types/genesis.pb.go rename to x/gov/types/v1beta2/genesis.pb.go index 8f6fece87aa8..36df7540052d --- a/x/gov/types/genesis.pb.go +++ b/x/gov/types/v1beta2/genesis.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cosmos/gov/v1beta2/genesis.proto -package types +package v1beta2 import ( fmt "fmt" @@ -129,29 +129,29 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/genesis.proto", fileDescriptor_7915ab39bb5aa171) } var fileDescriptor_7915ab39bb5aa171 = []byte{ - // 341 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xbd, 0x4e, 0xc3, 0x30, - 0x14, 0x85, 0x1b, 0xfa, 0x03, 0xb8, 0x2d, 0x83, 0xc5, 0x10, 0x41, 0x15, 0x02, 0x53, 0x16, 0x1c, - 0x28, 0x03, 0x12, 0x63, 0x05, 0x02, 0xb6, 0x2a, 0x20, 0x06, 0x96, 0xca, 0x6d, 0xac, 0x10, 0xd1, - 0xf6, 0x46, 0xf1, 0xc5, 0xa2, 0x6f, 0xc1, 0xf3, 0xf0, 0x04, 0x8c, 0x1d, 0x19, 0x51, 0xf3, 0x22, - 0xa8, 0x76, 0x42, 0x2b, 0x11, 0x98, 0xa2, 0x2b, 0x7f, 0xe7, 0xcb, 0x91, 0x7d, 0x89, 0x3b, 0x02, - 0x39, 0x01, 0xe9, 0x47, 0xa0, 0x7c, 0x75, 0x3a, 0x14, 0xc8, 0xbb, 0x7e, 0x24, 0xa6, 0x42, 0xc6, - 0x92, 0x25, 0x29, 0x20, 0x50, 0x6a, 0x08, 0x16, 0x81, 0x62, 0x39, 0xb1, 0xd7, 0x29, 0x4b, 0x81, - 0x32, 0x89, 0xa3, 0xf7, 0x2a, 0x69, 0x5d, 0x1b, 0xc7, 0x1d, 0x72, 0x14, 0xf4, 0x84, 0xec, 0x4a, - 0xe4, 0x29, 0xc6, 0xd3, 0x68, 0x90, 0xa4, 0x90, 0x80, 0xe4, 0xe3, 0x41, 0x1c, 0xda, 0x96, 0x6b, - 0x79, 0xb5, 0x80, 0x16, 0x67, 0xfd, 0xfc, 0xe8, 0x36, 0xa4, 0xe7, 0x64, 0x2b, 0x14, 0x09, 0xc8, - 0x18, 0xa5, 0xbd, 0xe1, 0x56, 0xbd, 0x66, 0x77, 0x9f, 0xfd, 0xee, 0xc1, 0x2e, 0x0d, 0x13, 0xfc, - 0xc0, 0x94, 0x91, 0xba, 0x02, 0x14, 0xd2, 0xae, 0xea, 0x94, 0x5d, 0x96, 0x7a, 0x00, 0x14, 0x81, - 0xc1, 0xe8, 0x05, 0xd9, 0x2e, 0x1a, 0x49, 0xbb, 0xa6, 0x33, 0x9d, 0xb2, 0x4c, 0xd1, 0x2d, 0x58, - 0xe1, 0xf4, 0x86, 0xec, 0xe4, 0xff, 0x1d, 0x24, 0x3c, 0xe5, 0x13, 0x69, 0xd7, 0x5d, 0xcb, 0x6b, - 0x76, 0x0f, 0xff, 0xa9, 0xda, 0xd7, 0x60, 0xd0, 0x0e, 0xd7, 0x47, 0x7a, 0x45, 0xda, 0x0a, 0xcc, - 0xf5, 0x18, 0x51, 0x43, 0x8b, 0xdc, 0x3f, 0xda, 0x2f, 0xef, 0xca, 0x78, 0x5a, 0x6a, 0x6d, 0xa2, - 0x3d, 0xd2, 0x42, 0x3e, 0x1e, 0xcf, 0x0a, 0xcb, 0xa6, 0xb6, 0x1c, 0x94, 0x59, 0xee, 0x97, 0x5c, - 0x2e, 0x69, 0xe2, 0x6a, 0xe8, 0xf5, 0x3e, 0x16, 0x8e, 0x35, 0x5f, 0x38, 0xd6, 0xd7, 0xc2, 0xb1, - 0xde, 0x32, 0xa7, 0x32, 0xcf, 0x9c, 0xca, 0x67, 0xe6, 0x54, 0x1e, 0xbd, 0x28, 0xc6, 0xa7, 0x97, - 0x21, 0x1b, 0xc1, 0xc4, 0xcf, 0xdf, 0xdf, 0x7c, 0x8e, 0x65, 0xf8, 0xec, 0xbf, 0xea, 0x65, 0xc0, - 0x59, 0x22, 0xe4, 0xb0, 0xa1, 0xf7, 0xe0, 0xec, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x5f, 0x73, 0x78, - 0xdf, 0x5d, 0x02, 0x00, 0x00, + // 345 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0xbb, 0x4e, 0xc3, 0x30, + 0x14, 0x86, 0x1b, 0x7a, 0x01, 0xdc, 0x96, 0xc1, 0x62, 0x88, 0xa0, 0x0a, 0x81, 0xa9, 0x0b, 0x4e, + 0x29, 0x03, 0x12, 0x63, 0x05, 0xe2, 0x32, 0x55, 0x01, 0x31, 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bb, 0x87, 0xff, 0x54, 0xed, 0x6b, 0xd0, 0x6f, 0x06, 0xeb, 0x23, 0xbd, 0x24, 0x4d, 0x05, + 0xe6, 0x7a, 0x8c, 0xa8, 0xa6, 0x45, 0xee, 0x1f, 0xed, 0x97, 0x77, 0x65, 0x3c, 0x0d, 0xb5, 0x36, + 0xd1, 0x1e, 0x69, 0x20, 0x1f, 0x8f, 0x67, 0xb9, 0x65, 0x53, 0x5b, 0x0e, 0x8a, 0x2c, 0xf7, 0x4b, + 0x2e, 0x93, 0xd4, 0x71, 0x35, 0xf4, 0x6e, 0x3f, 0x16, 0x8e, 0x35, 0x5f, 0x38, 0xd6, 0xd7, 0xc2, + 0xb1, 0xde, 0x52, 0xa7, 0x34, 0x4f, 0x9d, 0xd2, 0x67, 0xea, 0x94, 0x1e, 0x3b, 0x61, 0x84, 0x4f, + 0x2f, 0x43, 0x36, 0x82, 0x89, 0x97, 0xbd, 0xbf, 0xf9, 0x1c, 0xcb, 0xe0, 0xd9, 0x7b, 0xd5, 0xcb, + 0x80, 0xb3, 0x58, 0xc8, 0x7c, 0x25, 0x86, 0x35, 0xbd, 0x0f, 0xa7, 0xdf, 0x01, 0x00, 0x00, 0xff, + 0xff, 0xb6, 0x88, 0x7e, 0xc1, 0x65, 0x02, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/gov/types/genesis_test.go b/x/gov/types/v1beta2/genesis_test.go similarity index 53% rename from x/gov/types/genesis_test.go rename to x/gov/types/v1beta2/genesis_test.go index 6f13c5ebae42..26d54c93a4dc 100644 --- a/x/gov/types/genesis_test.go +++ b/x/gov/types/v1beta2/genesis_test.go @@ -1,15 +1,16 @@ -package types +package v1beta2_test import ( "testing" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" "github.com/stretchr/testify/require" ) func TestEmptyGenesis(t *testing.T) { - state1 := GenesisState{} + state1 := v1beta2.GenesisState{} require.True(t, state1.Empty()) - state2 := DefaultGenesisState() + state2 := v1beta2.DefaultGenesisState() require.False(t, state2.Empty()) } diff --git a/x/gov/types/gov.pb.go b/x/gov/types/v1beta2/gov.pb.go old mode 100644 new mode 100755 similarity index 91% rename from x/gov/types/gov.pb.go rename to x/gov/types/v1beta2/gov.pb.go index 0a9ad1dac4c4..b8064e10147e --- a/x/gov/types/gov.pb.go +++ b/x/gov/types/v1beta2/gov.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cosmos/gov/v1beta2/gov.proto -package types +package v1beta2 import ( fmt "fmt" @@ -671,71 +671,71 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/gov.proto", fileDescriptor_5abf7b8852811c49) } var fileDescriptor_5abf7b8852811c49 = []byte{ - // 1019 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0xc1, 0x6e, 0xdb, 0x46, - 0x10, 0x35, 0x25, 0x59, 0xb6, 0x47, 0xb6, 0xc2, 0x6e, 0x8c, 0x86, 0x76, 0x52, 0xca, 0xd5, 0xc1, - 0x10, 0x82, 0x5a, 0x8a, 0x5d, 0x34, 0x05, 0x7a, 0x8a, 0x64, 0x32, 0x0d, 0x03, 0xc7, 0x14, 0x48, - 0x46, 0x46, 0x7b, 0x21, 0x28, 0x73, 0x43, 0x11, 0x15, 0xb9, 0x2a, 0x77, 0xe5, 0xd8, 0x9f, 0xd0, - 0x5b, 0x8e, 0x45, 0x7b, 0xe9, 0xbd, 0xd7, 0x7c, 0x44, 0x4e, 0x45, 0x10, 0x20, 0x40, 0x4f, 0x6d, - 0x61, 0xff, 0x48, 0xc1, 0xe5, 0xd2, 0x96, 0x65, 0x05, 0xd6, 0xc9, 0xab, 0x99, 0xf7, 0xde, 0xce, - 0xec, 0xbe, 0x1d, 0x13, 0x1e, 0x1c, 0x13, 0x1a, 0x11, 0xda, 0x0a, 0xc8, 0x49, 0xeb, 0x64, 0xb7, - 0x8f, 0x99, 0xb7, 0x97, 0xae, 0x9b, 0xa3, 0x84, 0x30, 0x82, 0x50, 0x96, 0x6d, 0xa6, 0x11, 0x91, - 0xdd, 0x54, 0x05, 0xa3, 0xef, 0x51, 0x2c, 0x28, 0xbb, 0xad, 0x63, 0x12, 0xc6, 0x19, 0x67, 0x73, - 0x3d, 0x20, 0x01, 0xe1, 0xcb, 0x56, 0xba, 0x12, 0xd1, 0x5a, 0x40, 0x48, 0x30, 0xc4, 0x2d, 0xfe, - 0xab, 0x3f, 0x7e, 0xd5, 0x62, 0x61, 0x84, 0x29, 0xf3, 0xa2, 0x91, 0x00, 0x6c, 0x4c, 0x03, 0xbc, - 0xf8, 0x4c, 0xa4, 0xd4, 0xe9, 0x94, 0x3f, 0x4e, 0x3c, 0x16, 0x92, 0x7c, 0xc7, 0x8d, 0xac, 0x22, - 0x37, 0xdb, 0x54, 0x94, 0xcc, 0x7f, 0xd4, 0x19, 0xa0, 0x23, 0x1c, 0x06, 0x03, 0x86, 0xfd, 0x1e, - 0x61, 0xd8, 0x1c, 0xa5, 0x34, 0xf4, 0x18, 0xca, 0x84, 0xaf, 0x14, 0x69, 0x4b, 0x6a, 0x54, 0xf7, - 0xd4, 0xe6, 0xcd, 0x3e, 0x9b, 0x57, 0x78, 0x4b, 0xa0, 0xd1, 0x36, 0x94, 0x5f, 0x73, 0x35, 0xa5, - 0xb0, 0x25, 0x35, 0x56, 0x3a, 0xd5, 0x0f, 0x6f, 0x77, 0x40, 0x50, 0x35, 0x7c, 0x6c, 0x89, 0x6c, - 0xfd, 0x77, 0x09, 0x96, 0x34, 0x3c, 0x22, 0x34, 0x64, 0xa8, 0x06, 0x95, 0x51, 0x42, 0x46, 0x84, - 0x7a, 0x43, 0x37, 0xf4, 0xf9, 0x86, 0x25, 0x0b, 0xf2, 0x90, 0xe1, 0xa3, 0xc7, 0xb0, 0xe2, 0x67, - 0x58, 0x92, 0x08, 0x5d, 0xe5, 0xc3, 0xdb, 0x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, 0x12, 0xac, 0x09, 0xa7, 0x74, 0xbd, 0xc4, 0x8b, 0x28, 0x7a, 0x02, 0x95, - 0x28, 0x8c, 0x2f, 0x3d, 0x27, 0xcd, 0xe7, 0x39, 0x88, 0xc2, 0x38, 0x77, 0xdc, 0x0b, 0x40, 0x91, - 0x77, 0x9a, 0x2b, 0xb8, 0x23, 0x9c, 0x84, 0xc4, 0xe7, 0xc7, 0x91, 0x0a, 0x4d, 0xdb, 0x44, 0x13, - 0xd3, 0xb9, 0x53, 0xfa, 0x35, 0x75, 0x89, 0x1c, 0x79, 0xa7, 0x79, 0x41, 0x9c, 0x58, 0x77, 0x60, - 0xb5, 0xc7, 0x9d, 0x23, 0x0a, 0xd4, 0x40, 0x38, 0x29, 0x57, 0x96, 0xe6, 0x53, 0x5e, 0xcd, 0x58, - 0x42, 0xf5, 0xb7, 0xdc, 0x7e, 0x42, 0x75, 0x1b, 0xca, 0x3f, 0x8f, 0x49, 0x32, 0x8e, 0x66, 0x38, - 0x90, 0x0f, 0xeb, 0x2c, 0x8b, 0xbe, 0x82, 0x15, 0x36, 0x48, 0x30, 0x1d, 0x90, 0xa1, 0xff, 0x89, - 0xb9, 0x7e, 0x05, 0x40, 0xdf, 0x40, 0x35, 0x35, 0x98, 0x7b, 0x45, 0x29, 0xce, 0xa4, 0xac, 0xa5, - 0x28, 0x27, 0x07, 0x3d, 0xfc, 0x45, 0x02, 0x98, 0xf8, 0x07, 0x74, 0x1f, 0xee, 0xf5, 0x4c, 0x47, - 0x77, 0xcd, 0xae, 0x63, 0x98, 0x87, 0xee, 0xcb, 0x43, 0xbb, 0xab, 0xef, 0x1b, 0x4f, 0x0d, 0x5d, - 0x93, 0x17, 0xd0, 0x5d, 0xb8, 0x33, 0x99, 0xfc, 0x41, 0xb7, 0x65, 0x09, 0xdd, 0x83, 0xbb, 0x93, - 0xc1, 0x76, 0xc7, 0x76, 0xda, 0xc6, 0xa1, 0x5c, 0x40, 0x08, 0xaa, 0x93, 0x89, 0x43, 0x53, 0x2e, - 0xa2, 0x07, 0xa0, 0x5c, 0x8f, 0xb9, 0x47, 0x86, 0xf3, 0xcc, 0xed, 0xe9, 0x8e, 0x29, 0x97, 0x1e, - 0xfe, 0x25, 0x41, 0xf5, 0xfa, 0xf8, 0x45, 0x35, 0xb8, 0xdf, 0xb5, 0xcc, 0xae, 0x69, 0xb7, 0x0f, - 0x5c, 0xdb, 0x69, 0x3b, 0x2f, 0xed, 0xa9, 0x9a, 0xea, 0xa0, 0x4e, 0x03, 0x34, 0xbd, 0x6b, 0xda, - 0x86, 0xe3, 0x76, 0x75, 0xcb, 0x30, 0x35, 0x59, 0x42, 0x5f, 0xc2, 0x17, 0xd3, 0x98, 0x9e, 0xe9, - 0x18, 0x87, 0xdf, 0xe7, 0x90, 0x02, 0xda, 0x84, 0xcf, 0xa7, 0x21, 0xdd, 0xb6, 0x6d, 0xeb, 0x5a, - 0x56, 0xf4, 0x74, 0xce, 0xd2, 0x9f, 0xeb, 0xfb, 0x8e, 0xae, 0xc9, 0xa5, 0x59, 0xcc, 0xa7, 0x6d, - 0xe3, 0x40, 0xd7, 0xe4, 0xc5, 0x4e, 0xe7, 0xdd, 0xb9, 0x2a, 0xbd, 0x3f, 0x57, 0xa5, 0xff, 0xce, - 0x55, 0xe9, 0xcd, 0x85, 0xba, 0xf0, 0xfe, 0x42, 0x5d, 0xf8, 0xfb, 0x42, 0x5d, 0xf8, 0xb1, 0x11, - 0x84, 0x6c, 0x30, 0xee, 0x37, 0x8f, 0x49, 0x24, 0xbe, 0x0b, 0xc4, 0x9f, 0x1d, 0xea, 0xff, 0xd4, - 0x3a, 0xe5, 0x5f, 0x3d, 0xec, 0x6c, 0x84, 0x69, 0xbf, 0xcc, 0x4d, 0xf6, 0xf5, 0xff, 0x01, 0x00, - 0x00, 0xff, 0xff, 0xa4, 0x3d, 0x7c, 0xd7, 0x10, 0x09, 0x00, 0x00, + // 1022 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x41, 0x6f, 0xdb, 0x36, + 0x14, 0x8e, 0x6c, 0xc7, 0x49, 0x9e, 0x13, 0x57, 0x63, 0x83, 0x55, 0x49, 0x3b, 0x39, 0xf3, 0x21, + 0x08, 0x8a, 0xc5, 0x4e, 0x32, 0xac, 0x03, 0x76, 0xaa, 0x1d, 0xa9, 0xab, 0x82, 0x34, 0x32, 0x24, + 0xd5, 0xc1, 0x76, 0x11, 0xe4, 0x88, 0x95, 0x85, 0x59, 0xa2, 0x27, 0xd2, 0x69, 0xf2, 0x13, 0x76, + 0xeb, 0x71, 0xd8, 0x2e, 0xbb, 0xef, 0xda, 0x1f, 0xd1, 0xd3, 0x50, 0x14, 0x28, 0xb0, 0xd3, 0x36, + 0x24, 0x7f, 0x64, 0x10, 0x45, 0x25, 0x8e, 0xe3, 0x22, 0x3e, 0x99, 0x7a, 0xef, 0xfb, 0x3e, 0x3e, + 0x92, 0x1f, 0x9f, 0x09, 0x8f, 0x4e, 0x08, 0x8d, 0x08, 0x6d, 0x06, 0xe4, 0xb4, 0x79, 0xba, 0xdb, + 0xc3, 0xcc, 0xdb, 0x4b, 0xc7, 0x8d, 0x61, 0x42, 0x18, 0x41, 0x28, 0xcb, 0x36, 0xd2, 0x88, 0xc8, + 0xae, 0xab, 0x82, 0xd1, 0xf3, 0x28, 0x16, 0x94, 0xdd, 0xe6, 0x09, 0x09, 0xe3, 0x8c, 0xb3, 0xbe, + 0x1a, 0x90, 0x80, 0xf0, 0x61, 0x33, 0x1d, 0x89, 0x68, 0x2d, 0x20, 0x24, 0x18, 0xe0, 0x26, 0xff, + 0xea, 0x8d, 0x5e, 0x35, 0x59, 0x18, 0x61, 0xca, 0xbc, 0x68, 0x28, 0x00, 0x6b, 0x93, 0x00, 0x2f, + 0x3e, 0x17, 0x29, 0x75, 0x32, 0xe5, 0x8f, 0x12, 0x8f, 0x85, 0x24, 0x9f, 0x71, 0x2d,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 0x75, 0xf8, 0x7c, 0x12, 0xd2, 0x69, 0xd9, 0xb6, 0xae, + 0x65, 0x45, 0x4f, 0xe6, 0x2c, 0xfd, 0x40, 0xdf, 0x77, 0x74, 0x4d, 0x2e, 0x4d, 0x63, 0x3e, 0x6b, + 0x19, 0x87, 0xba, 0x26, 0xcf, 0xb7, 0x0f, 0xde, 0x5d, 0xa8, 0xd2, 0xfb, 0x0b, 0x55, 0xfa, 0xef, + 0x42, 0x95, 0xde, 0x5c, 0xaa, 0x73, 0xef, 0x2f, 0xd5, 0xb9, 0xbf, 0x2f, 0xd5, 0xb9, 0x1f, 0x77, + 0x82, 0x90, 0xf5, 0x47, 0xbd, 0xc6, 0x09, 0x89, 0xc4, 0xbb, 0x40, 0xfc, 0x6c, 0x53, 0xff, 0xa7, + 0xe6, 0x19, 0x7f, 0xf5, 0xb0, 0xf3, 0x21, 0xa6, 0xf9, 0xdb, 0xa7, 0x57, 0xe6, 0x66, 0xfb, 0xfa, + 0xff, 0x00, 0x00, 0x00, 0xff, 0xff, 0x59, 0x87, 0xaa, 0xdc, 0x18, 0x09, 0x00, 0x00, } func (m *WeightedVoteOption) Marshal() (dAtA []byte, err error) { diff --git a/x/gov/types/msgs.go b/x/gov/types/v1beta2/msgs.go similarity index 99% rename from x/gov/types/msgs.go rename to x/gov/types/v1beta2/msgs.go index 8b9a6e58bb8b..745867e7a699 100644 --- a/x/gov/types/msgs.go +++ b/x/gov/types/v1beta2/msgs.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "fmt" diff --git a/x/gov/types/msgs_test.go b/x/gov/types/v1beta2/msgs_test.go similarity index 53% rename from x/gov/types/msgs_test.go rename to x/gov/types/v1beta2/msgs_test.go index 616023e1deaa..1977ba990b9f 100644 --- a/x/gov/types/msgs_test.go +++ b/x/gov/types/v1beta2/msgs_test.go @@ -1,4 +1,4 @@ -package types +package v1beta2_test import ( "testing" @@ -6,6 +6,7 @@ import ( "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) var ( @@ -24,7 +25,7 @@ func init() { func TestMsgDepositGetSignBytes(t *testing.T) { addr := sdk.AccAddress("addr1") - msg := NewMsgDeposit(addr, 0, coinsPos) + msg := v1beta2.NewMsgDeposit(addr, 0, coinsPos) res := msg.GetSignBytes() expected := `{"type":"cosmos-sdk/MsgDeposit","value":{"amount":[{"amount":"1000","denom":"stake"}],"depositor":"cosmos1v9jxgu33kfsgr5"}}` @@ -46,7 +47,7 @@ func TestMsgDeposit(t *testing.T) { } for i, tc := range tests { - msg := NewMsgDeposit(tc.depositorAddr, tc.proposalID, tc.depositAmount) + msg := v1beta2.NewMsgDeposit(tc.depositorAddr, tc.proposalID, tc.depositAmount) if tc.expectPass { require.NoError(t, msg.ValidateBasic(), "test: %v", i) } else { @@ -60,19 +61,19 @@ func TestMsgVote(t *testing.T) { tests := []struct { proposalID uint64 voterAddr sdk.AccAddress - option VoteOption + option v1beta2.VoteOption expectPass bool }{ - {0, addrs[0], OptionYes, true}, - {0, sdk.AccAddress{}, OptionYes, false}, - {0, addrs[0], OptionNo, true}, - {0, addrs[0], OptionNoWithVeto, true}, - {0, addrs[0], OptionAbstain, true}, - {0, addrs[0], VoteOption(0x13), false}, + {0, addrs[0], v1beta2.OptionYes, true}, + {0, sdk.AccAddress{}, v1beta2.OptionYes, false}, + {0, addrs[0], v1beta2.OptionNo, true}, + {0, addrs[0], v1beta2.OptionNoWithVeto, true}, + {0, addrs[0], v1beta2.OptionAbstain, true}, + {0, addrs[0], v1beta2.VoteOption(0x13), false}, } for i, tc := range tests { - msg := NewMsgVote(tc.voterAddr, tc.proposalID, tc.option) + msg := v1beta2.NewMsgVote(tc.voterAddr, tc.proposalID, tc.option) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", i) } else { @@ -86,37 +87,37 @@ func TestMsgVoteWeighted(t *testing.T) { tests := []struct { proposalID uint64 voterAddr sdk.AccAddress - options WeightedVoteOptions + options v1beta2.WeightedVoteOptions expectPass bool }{ - {0, addrs[0], NewNonSplitVoteOption(OptionYes), true}, - {0, sdk.AccAddress{}, NewNonSplitVoteOption(OptionYes), false}, - {0, addrs[0], NewNonSplitVoteOption(OptionNo), true}, - {0, addrs[0], NewNonSplitVoteOption(OptionNoWithVeto), true}, - {0, addrs[0], NewNonSplitVoteOption(OptionAbstain), true}, - {0, addrs[0], WeightedVoteOptions{ // weight sum > 1 - NewWeightedVoteOption(OptionYes, sdk.NewDec(1)), - NewWeightedVoteOption(OptionAbstain, sdk.NewDec(1)), + {0, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.OptionYes), true}, + {0, sdk.AccAddress{}, v1beta2.NewNonSplitVoteOption(v1beta2.OptionYes), false}, + {0, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.OptionNo), true}, + {0, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.OptionNoWithVeto), true}, + {0, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.OptionAbstain), true}, + {0, addrs[0], v1beta2.WeightedVoteOptions{ // weight sum > 1 + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDec(1)), + v1beta2.NewWeightedVoteOption(v1beta2.OptionAbstain, sdk.NewDec(1)), }, false}, - {0, addrs[0], WeightedVoteOptions{ // duplicate option - NewWeightedVoteOption(OptionYes, sdk.NewDecWithPrec(5, 1)), - NewWeightedVoteOption(OptionYes, sdk.NewDecWithPrec(5, 1)), + {0, addrs[0], v1beta2.WeightedVoteOptions{ // duplicate option + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDecWithPrec(5, 1)), + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDecWithPrec(5, 1)), }, false}, - {0, addrs[0], WeightedVoteOptions{ // zero weight - NewWeightedVoteOption(OptionYes, sdk.NewDec(0)), + {0, addrs[0], v1beta2.WeightedVoteOptions{ // zero weight + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDec(0)), }, false}, - {0, addrs[0], WeightedVoteOptions{ // negative weight - NewWeightedVoteOption(OptionYes, sdk.NewDec(-1)), + {0, addrs[0], v1beta2.WeightedVoteOptions{ // negative weight + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDec(-1)), }, false}, - {0, addrs[0], WeightedVoteOptions{}, false}, - {0, addrs[0], NewNonSplitVoteOption(VoteOption(0x13)), false}, - {0, addrs[0], WeightedVoteOptions{ // weight sum <1 - NewWeightedVoteOption(OptionYes, sdk.NewDecWithPrec(5, 1)), + {0, addrs[0], v1beta2.WeightedVoteOptions{}, false}, + {0, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.VoteOption(0x13)), false}, + {0, addrs[0], v1beta2.WeightedVoteOptions{ // weight sum <1 + v1beta2.NewWeightedVoteOption(v1beta2.OptionYes, sdk.NewDecWithPrec(5, 1)), }, false}, } for i, tc := range tests { - msg := NewMsgVoteWeighted(tc.voterAddr, tc.proposalID, tc.options) + msg := v1beta2.NewMsgVoteWeighted(tc.voterAddr, tc.proposalID, tc.options) if tc.expectPass { require.Nil(t, msg.ValidateBasic(), "test: %v", i) } else { @@ -127,8 +128,8 @@ func TestMsgVoteWeighted(t *testing.T) { // this tests that Amino JSON MsgSubmitProposal.GetSignBytes() still works with Content as Any using the ModuleCdc func TestMsgSubmitProposal_GetSignBytes(t *testing.T) { - proposal := []sdk.Msg{NewMsgVote(addrs[0], 1, OptionYes)} - msg, err := NewMsgSubmitProposal(proposal, sdk.NewCoins(), sdk.AccAddress{}) + proposal := []sdk.Msg{v1beta2.NewMsgVote(addrs[0], 1, v1beta2.OptionYes)} + msg, err := v1beta2.NewMsgSubmitProposal(proposal, sdk.NewCoins(), sdk.AccAddress{}) require.NoError(t, err) var bz []byte require.NotPanics(t, func() { diff --git a/x/gov/types/params.go b/x/gov/types/v1beta2/params.go similarity index 99% rename from x/gov/types/params.go rename to x/gov/types/v1beta2/params.go index a4ab8d965927..f65cf333ccc3 100644 --- a/x/gov/types/params.go +++ b/x/gov/types/v1beta2/params.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "errors" diff --git a/x/gov/types/proposal.go b/x/gov/types/v1beta2/proposal.go similarity index 99% rename from x/gov/types/proposal.go rename to x/gov/types/v1beta2/proposal.go index b22808f9c5cd..4c27f5ba66a3 100644 --- a/x/gov/types/proposal.go +++ b/x/gov/types/v1beta2/proposal.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "fmt" diff --git a/x/gov/types/proposals_test.go b/x/gov/types/v1beta2/proposals_test.go similarity index 67% rename from x/gov/types/proposals_test.go rename to x/gov/types/v1beta2/proposals_test.go index ca670e91e9ab..f038ebfaf663 100644 --- a/x/gov/types/proposals_test.go +++ b/x/gov/types/v1beta2/proposals_test.go @@ -1,17 +1,17 @@ -package types_test +package v1beta2_test import ( "fmt" "testing" - "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" "github.com/stretchr/testify/require" ) func TestProposalStatus_Format(t *testing.T) { - statusDepositPeriod, _ := types.ProposalStatusFromString("PROPOSAL_STATUS_DEPOSIT_PERIOD") + statusDepositPeriod, _ := v1beta2.ProposalStatusFromString("PROPOSAL_STATUS_DEPOSIT_PERIOD") tests := []struct { - pt types.ProposalStatus + pt v1beta2.ProposalStatus sprintFArgs string expectedStringOutput string }{ diff --git a/x/gov/types/querier.go b/x/gov/types/v1beta2/querier.go similarity index 99% rename from x/gov/types/querier.go rename to x/gov/types/v1beta2/querier.go index fe9b5e0f15cb..a78df106e9fc 100644 --- a/x/gov/types/querier.go +++ b/x/gov/types/v1beta2/querier.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/x/gov/types/query.pb.go b/x/gov/types/v1beta2/query.pb.go old mode 100644 new mode 100755 similarity index 94% rename from x/gov/types/query.pb.go rename to x/gov/types/v1beta2/query.pb.go index d696f322c0c7..7605012ba695 --- a/x/gov/types/query.pb.go +++ b/x/gov/types/v1beta2/query.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cosmos/gov/v1beta2/query.proto -package types +package v1beta2 import ( context "context" @@ -895,67 +895,67 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/query.proto", fileDescriptor_3efdc0c4615c3665) } var fileDescriptor_3efdc0c4615c3665 = []byte{ - // 952 bytes of a gzipped FileDescriptorProto + // 955 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x57, 0x4f, 0x6f, 0x1b, 0x45, 0x14, 0xcf, 0x38, 0x49, 0x1b, 0xbf, 0xb4, 0x01, 0x1e, 0x05, 0x8c, 0x29, 0x4e, 0x58, 0xd1, 0xd6, - 0xa4, 0xcd, 0x2e, 0x49, 0x68, 0x4b, 0x0b, 0x07, 0x62, 0x41, 0x29, 0x42, 0x48, 0xa9, 0x5b, 0x71, - 0xe0, 0x12, 0x6d, 0xe2, 0xd5, 0xb2, 0xc2, 0xd9, 0xd9, 0x7a, 0xc6, 0x16, 0x51, 0x88, 0x90, 0xb8, - 0x21, 0x84, 0x04, 0xa2, 0x42, 0xe2, 0xd0, 0x13, 0x12, 0x9f, 0x80, 0x0f, 0xc1, 0xb1, 0x02, 0x0e, - 0x1c, 0x51, 0xc2, 0x89, 0x4f, 0x81, 0x76, 0xe6, 0xcd, 0x7a, 0xd7, 0x59, 0x7b, 0xed, 0x12, 0xf5, - 0x14, 0xcd, 0xcc, 0xef, 0xbd, 0xf7, 0x7b, 0x7f, 0xf6, 0xf7, 0x62, 0xa8, 0xed, 0x70, 0xb1, 0xcb, - 0x85, 0xe3, 0xf3, 0x9e, 0xd3, 0x5b, 0xdd, 0xf6, 0xa4, 0xbb, 0xe6, 0xdc, 0xef, 0x7a, 0x9d, 0x3d, - 0x3b, 0xea, 0x70, 0xc9, 0x11,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a, 0x81, 0xd6, 0x5b, 0x8a, 0xeb, 0x55, 0x7c, 0xfd, 0x51, 0xb8, 0xe2, 0xcf, 0x0c, 0x66, + 0x33, 0x3a, 0x82, 0x17, 0x07, 0x06, 0x3e, 0xae, 0x70, 0xf5, 0x4b, 0xa3, 0x81, 0xff, 0xcf, 0xf0, + 0x29, 0x59, 0x5b, 0xff, 0xe0, 0xb7, 0x83, 0x06, 0x7b, 0x78, 0xd0, 0x60, 0x7f, 0x1f, 0x34, 0xd8, + 0x77, 0x87, 0x8d, 0x89, 0x87, 0x87, 0x8d, 0x89, 0xbf, 0x0e, 0x1b, 0x13, 0x9f, 0x5c, 0xf6, 0x03, + 0xf9, 0x69, 0x77, 0xcb, 0xde, 0xe6, 0x3b, 0xc6, 0xad, 0xfe, 0xb3, 0x24, 0xda, 0x9f, 0x39, 0x9f, + 0xab, 0x18, 0xc9, 0xc8, 0x08, 0x13, 0x69, 0xeb, 0x84, 0xfa, 0xc5, 0xb2, 0xfa, 0x5f, 0x00, 0x00, + 0x00, 0xff, 0xff, 0xb2, 0x31, 0x71, 0x47, 0x6a, 0x0d, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/gov/types/query.pb.gw.go b/x/gov/types/v1beta2/query.pb.gw.go old mode 100644 new mode 100755 similarity index 94% rename from x/gov/types/query.pb.gw.go rename to x/gov/types/v1beta2/query.pb.gw.go index db14e2a20439..73fbf22e789d --- a/x/gov/types/query.pb.gw.go +++ b/x/gov/types/v1beta2/query.pb.gw.go @@ -2,11 +2,11 @@ // source: cosmos/gov/v1beta2/query.proto /* -Package types is a reverse proxy. +Package v1beta2 is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ -package types +package v1beta2 import ( "context" @@ -20,7 +20,6 @@ import ( "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" - "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) @@ -31,7 +30,6 @@ var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage -var _ = metadata.Join func request_Query_Proposal_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryProposalRequest @@ -530,14 +528,12 @@ func local_request_Query_TallyResult_0(ctx context.Context, marshaler runtime.Ma // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. -// Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. +// Note that using this registration option will cause many gRPC library features (such as grpc.SendHeader, etc) to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Proposal_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -545,7 +541,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Proposal_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -559,8 +554,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Proposals_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -568,7 +561,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Proposals_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -582,8 +574,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Vote_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -591,7 +581,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Vote_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -605,8 +594,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Votes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -614,7 +601,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Votes_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -628,8 +614,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -637,7 +621,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -651,8 +634,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Deposit_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -660,7 +641,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Deposit_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -674,8 +654,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_Deposits_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -683,7 +661,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_Deposits_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -697,8 +674,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv mux.Handle("GET", pattern_Query_TallyResult_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() - var stream runtime.ServerTransportStream - ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { @@ -706,7 +681,6 @@ func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, serv return } resp, md, err := local_request_Query_TallyResult_0(rctx, inboundMarshaler, server, req, pathParams) - md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) diff --git a/x/gov/types/tally.go b/x/gov/types/v1beta2/tally.go similarity index 99% rename from x/gov/types/tally.go rename to x/gov/types/v1beta2/tally.go index 25d1e35846f5..e8c5d9941021 100644 --- a/x/gov/types/tally.go +++ b/x/gov/types/v1beta2/tally.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/x/gov/types/tx.pb.go b/x/gov/types/v1beta2/tx.pb.go old mode 100644 new mode 100755 similarity index 93% rename from x/gov/types/tx.pb.go rename to x/gov/types/v1beta2/tx.pb.go index c6062c7c8267..e211ffac2c5f --- a/x/gov/types/tx.pb.go +++ b/x/gov/types/v1beta2/tx.pb.go @@ -1,7 +1,7 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cosmos/gov/v1beta2/tx.proto -package types +package v1beta2 import ( context "context" @@ -450,44 +450,44 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/tx.proto", fileDescriptor_4214261f6b3f9ed4) } var fileDescriptor_4214261f6b3f9ed4 = []byte{ - // 585 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcd, 0x6e, 0xd3, 0x4c, - 0x14, 0x8d, 0x9b, 0x7e, 0xfd, 0xb9, 0xfd, 0x94, 0xaa, 0x56, 0x24, 0x1c, 0x17, 0xb9, 0x91, 0x11, - 0x55, 0x24, 0x94, 0x31, 0x09, 0xa8, 0x6c, 0x58, 0xd0, 0xc0, 0xa2, 0x2c, 0x22, 0xc0, 0x95, 0x40, - 0x62, 0x13, 0xec, 0x78, 0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bd, 0xd4, 0xfc, 0x01, 0x6c, 0xaa, 0x3c, 0xe1, 0xf2, 0x05, 0x2e, 0xa9, 0xfa, 0x23, 0x58, 0xf3, - 0xfa, 0x38, 0x08, 0xa5, 0xda, 0x61, 0x69, 0x0c, 0x15, 0xdd, 0x2e, 0x83, 0x7e, 0xe9, 0x2f, 0xb3, - 0xdd, 0xfc, 0xb5, 0x02, 0xc5, 0xb6, 0x60, 0xfa, 0x09, 0x94, 0xae, 0x7c, 0x2a, 0x77, 0xe7, 0xbd, - 0x9c, 0x99, 0x28, 0x9a, 0xf5, 0x1b, 0xd1, 0xf2, 0xc4, 0x1e, 0xc1, 0x6a, 0x12, 0xc6, 0xdd, 0x6b, - 0x64, 0x53, 0xd0, 0xbc, 0xb3, 0x00, 0xcc, 0x3b, 0xbd, 0x83, 0xff, 0xff, 0x8a, 0xcb, 0x22, 0x51, - 0x46, 0x32, 0xef, 0xdd, 0x80, 0x94, 0x4f, 0x78, 0x05, 0xeb, 0xd9, 0x71, 0x5a, 0xd7, 0xe8, 0x14, - 0x6e, 0xee, 0x2f, 0xc6, 0xb3, 0x96, 0xad, 0xd6, 0xf9, 0xd8, 0xd2, 0x2e, 0xc6, 0x96, 0xf6, 0x73, - 0x6c, 0x69, 0x1f, 0x26, 0x56, 0xe1, 0x62, 0x62, 0x15, 0xbe, 0x4f, 0xac, 0xc2, 0xdb, 0x1a, 0xe3, - 0xf2, 0x74, 0xe0, 0x93, 0x2e, 0xf6, 0xd5, 0x1d, 0xa7, 0x7e, 0xea, 0x22, 0x78, 0xef, 0x9c, 0x25, - 0x37, 0xa6, 0x1c, 0x45, 0x54, 0xf8, 0x6b, 0xc9, 0x4d, 0xf5, 0xe0, 0x77, 0x00, 0x00, 0x00, 0xff, - 0xff, 0xe7, 0x3b, 0xf1, 0xb1, 0x9d, 0x05, 0x00, 0x00, + // 588 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02,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xf5, 0x7d, 0x58, 0xeb, 0x51, 0x21, 0x3c, 0x46, 0x85, 0xa1, 0x55, 0x8a, 0xd5, 0x8d, 0x46, 0x89, + 0xa4, 0x39, 0x48, 0x96, 0x83, 0x1c, 0x86, 0x43, 0x37, 0x67, 0xe9, 0x47, 0xb0, 0xc5, 0x43, 0x2e, + 0xb9, 0xd7, 0x6d, 0x07, 0x34, 0x42, 0xc1, 0xa5, 0xb1, 0x94, 0x08, 0xcb, 0x44, 0x59, 0x99, 0xf4, + 0xaa, 0x2e, 0xa0, 0x4e, 0x9e, 0x20, 0x0f, 0x9b, 0xcb, 0xe7, 0x3f, 0x76, 0x0b, 0xee, 0xa6, 0xd2, + 0x3d, 0x4d, 0x65, 0xfa, 0x03, 0x58, 0x8b, 0x12, 0x1f, 0x34, 0x36, 0x8a, 0x15, 0xad, 0xba, 0xde, + 0x34, 0xbe, 0x7d, 0xa9, 0x95, 0x54, 0x96, 0xc3, 0x20, 0x88, 0xa9, 0x10, 0xc7, 0x32, 0xe6, 0x21, + 0x73, 0x73, 0xa6, 0xfd, 0x08, 0xca, 0x53, 0x6d, 0xb8, 0x54, 0x44, 0x18, 0x0a, 0xaa, 0xef, 0xc2, + 0x46, 0xa4, 0x62, 0x6d, 0x1e, 0x18, 0x5a, 0x45, 0xab, 0x2e, 0xbb, 0x90, 0x85, 0x9e, 0x05, 0xf6, + 0x47, 0x0d, 0x56, 0x5b, 0x82, 0xbd, 0x46, 0xb9, 0x98, 0xac, 0x13, 0xf8, 0x6f, 0x80, 0x92, 0xc6, + 0xc6, 0xd2, 0x02, 0x77, 0x29, 0x4d, 0x3f, 0x80, 0x15, 0x8c, 0x24, 0xc7, 0x30, 0x69, 0x67, 0xb3, + 0x61, 0x91, 0xe9, 0x89, 0x20, 0x93, 0xd2, 0x2f, 0x12, 0x96, 0xab, 0xd8, 0xf6, 0x36, 0x6c, 0x29, + 0x4f, 0x59, 0x23, 0xf6, 0x67, 0x2d, 0x8f, 0xbd, 0xa1, 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e7, + 0x2c, 0xd9, 0x98, 0x72, 0x18, 0x51, 0x91, 0xed, 0x4d, 0x7f, 0x25, 0xd9, 0x58, 0xf7, 0x7f, 0x07, + 0x00, 0x00, 0xff, 0xff, 0x86, 0xf2, 0x34, 0xac, 0xa5, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/gov/types/vote.go b/x/gov/types/v1beta2/vote.go similarity index 99% rename from x/gov/types/vote.go rename to x/gov/types/v1beta2/vote.go index 4b83d3ac325d..4873f5ec91aa 100644 --- a/x/gov/types/vote.go +++ b/x/gov/types/v1beta2/vote.go @@ -1,4 +1,4 @@ -package types +package v1beta2 import ( "fmt" From 823e0aaf02059e63167639840bf4f2fafebf5448 Mon Sep 17 00:00:00 2001 From: atheesh Date: Wed, 29 Dec 2021 12:51:38 +0530 Subject: [PATCH 02/11] fix tests --- x/gov/keeper/querier.go | 5 +++-- x/gov/types/v1beta2/errors.go | 22 ---------------------- x/gov/types/v1beta2/msgs.go | 15 ++++++++------- 3 files changed, 11 insertions(+), 31 deletions(-) delete mode 100644 x/gov/types/v1beta2/errors.go diff --git a/x/gov/keeper/querier.go b/x/gov/keeper/querier.go index 940db802db08..0e9cd59c3d12 100644 --- a/x/gov/keeper/querier.go +++ b/x/gov/keeper/querier.go @@ -7,6 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) @@ -83,7 +84,7 @@ func queryProposal(ctx sdk.Context, path []string, req abci.RequestQuery, keeper proposal, ok := keeper.GetProposal(ctx, params.ProposalID) if !ok { - return nil, sdkerrors.Wrapf(v1beta2.ErrUnknownProposal, "%d", params.ProposalID) + return nil, sdkerrors.Wrapf(types.ErrUnknownProposal, "%d", params.ProposalID) } bz, err := codec.MarshalJSONIndent(legacyQuerierCdc, proposal) @@ -161,7 +162,7 @@ func queryTally(ctx sdk.Context, path []string, req abci.RequestQuery, keeper Ke proposal, ok := keeper.GetProposal(ctx, proposalID) if !ok { - return nil, sdkerrors.Wrapf(v1beta2.ErrUnknownProposal, "%d", proposalID) + return nil, sdkerrors.Wrapf(types.ErrUnknownProposal, "%d", proposalID) } var tallyResult v1beta1.TallyResult diff --git a/x/gov/types/v1beta2/errors.go b/x/gov/types/v1beta2/errors.go deleted file mode 100644 index 5dd356a9e6fa..000000000000 --- a/x/gov/types/v1beta2/errors.go +++ /dev/null @@ -1,22 +0,0 @@ -package v1beta2 - -import ( - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" -) - -// x/gov module sentinel errors -var ( - ErrUnknownProposal = sdkerrors.Register(ModuleName, 2, "unknown proposal") - ErrInactiveProposal = sdkerrors.Register(ModuleName, 3, "inactive proposal") - ErrAlreadyActiveProposal = sdkerrors.Register(ModuleName, 4, "proposal already active") - // Errors 5 & 6 are reserved as legacy errors - // See x/gov/types/v1beta1/errors.go - ErrInvalidGenesis = sdkerrors.Register(ModuleName, 8, "invalid genesis state") - ErrNoProposalHandlerExists = sdkerrors.Register(ModuleName, 9, "no handler exists for proposal type") - ErrUnroutableProposalMsg = sdkerrors.Register(ModuleName, 10, "proposal message not recognized by router") - ErrNoProposalMsgs = sdkerrors.Register(ModuleName, 11, "no messages proposed") - ErrInvalidProposalMsg = sdkerrors.Register(ModuleName, 12, "invalid proposal message") - ErrInvalidSigner = sdkerrors.Register(ModuleName, 13, "expected gov account as only signer for proposal message") - ErrInvalidSignalMsg = sdkerrors.Register(ModuleName, 14, "signal message is invalid") - ErrInvalidVote = sdkerrors.Register(ModuleName, 15, "invalid vote option") -) diff --git a/x/gov/types/v1beta2/msgs.go b/x/gov/types/v1beta2/msgs.go index 745867e7a699..a5a512681e4b 100644 --- a/x/gov/types/v1beta2/msgs.go +++ b/x/gov/types/v1beta2/msgs.go @@ -9,6 +9,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" sdktx "github.com/cosmos/cosmos-sdk/types/tx" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" ) // Governance message types and routes @@ -104,7 +105,7 @@ func (m MsgSubmitProposal) ValidateBasic() error { for idx, msg := range msgs { if err := msg.ValidateBasic(); err != nil { - return sdkerrors.Wrap(ErrInvalidProposalMsg, + return sdkerrors.Wrap(govtypes.ErrInvalidProposalMsg, fmt.Sprintf("msg: %d, err: %s", idx, err.Error())) } } @@ -187,7 +188,7 @@ func (msg MsgVote) ValidateBasic() error { return sdkerrors.ErrInvalidAddress.Wrapf("invalid voter address: %s", err) } if !ValidVoteOption(msg.Option) { - return sdkerrors.Wrap(ErrInvalidVote, msg.Option.String()) + return sdkerrors.Wrap(govtypes.ErrInvalidVote, msg.Option.String()) } return nil @@ -230,25 +231,25 @@ func (msg MsgVoteWeighted) ValidateBasic() error { usedOptions := make(map[VoteOption]bool) for _, option := range msg.Options { if !option.IsValid() { - return sdkerrors.Wrap(ErrInvalidVote, option.String()) + return sdkerrors.Wrap(govtypes.ErrInvalidVote, option.String()) } weight, err := sdk.NewDecFromStr(option.Weight) if err != nil { - return sdkerrors.Wrapf(ErrInvalidVote, "Invalid weight: %s", err) + return sdkerrors.Wrapf(govtypes.ErrInvalidVote, "Invalid weight: %s", err) } totalWeight = totalWeight.Add(weight) if usedOptions[option.Option] { - return sdkerrors.Wrap(ErrInvalidVote, "Duplicated vote option") + return sdkerrors.Wrap(govtypes.ErrInvalidVote, "Duplicated vote option") } usedOptions[option.Option] = true } if totalWeight.GT(sdk.NewDec(1)) { - return sdkerrors.Wrap(ErrInvalidVote, "Total weight overflow 1.00") + return sdkerrors.Wrap(govtypes.ErrInvalidVote, "Total weight overflow 1.00") } if totalWeight.LT(sdk.NewDec(1)) { - return sdkerrors.Wrap(ErrInvalidVote, "Total weight lower than 1.00") + return sdkerrors.Wrap(govtypes.ErrInvalidVote, "Total weight lower than 1.00") } return nil From 019b2ee38ccb1348b875ce1c6b0578b9489360e0 Mon Sep 17 00:00:00 2001 From: atheesh Date: Wed, 29 Dec 2021 13:16:07 +0530 Subject: [PATCH 03/11] fix tests --- x/gov/client/testutil/cli_test.go | 8 ++++---- x/gov/keeper/querier_test.go | 5 +++-- x/gov/simulation/genesis_test.go | 12 ++++++------ 3 files changed, 13 insertions(+), 12 deletions(-) diff --git a/x/gov/client/testutil/cli_test.go b/x/gov/client/testutil/cli_test.go index 907879f502b6..94a102d1083b 100644 --- a/x/gov/client/testutil/cli_test.go +++ b/x/gov/client/testutil/cli_test.go @@ -6,7 +6,7 @@ import ( "github.com/cosmos/cosmos-sdk/testutil/network" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" @@ -17,9 +17,9 @@ func TestIntegrationTestSuite(t *testing.T) { cfg.NumValidators = 1 suite.Run(t, NewIntegrationTestSuite(cfg)) - dp := types.NewDepositParams(sdk.NewCoins(sdk.NewCoin(cfg.BondDenom, types.DefaultMinDepositTokens)), time.Duration(15)*time.Second) - vp := types.NewVotingParams(time.Duration(5) * time.Second) - genesisState := types.DefaultGenesisState() + dp := v1beta2.NewDepositParams(sdk.NewCoins(sdk.NewCoin(cfg.BondDenom, v1beta2.DefaultMinDepositTokens)), time.Duration(15)*time.Second) + vp := v1beta2.NewVotingParams(time.Duration(5) * time.Second) + genesisState := v1beta2.DefaultGenesisState() genesisState.DepositParams = &dp genesisState.VotingParams = &vp bz, err := cfg.Codec.MarshalJSON(genesisState) diff --git a/x/gov/keeper/querier_test.go b/x/gov/keeper/querier_test.go index 6b8cab612df2..a06e4189f40b 100644 --- a/x/gov/keeper/querier_test.go +++ b/x/gov/keeper/querier_test.go @@ -16,6 +16,7 @@ import ( "github.com/cosmos/cosmos-sdk/x/gov/keeper" "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) const custom = "custom" @@ -202,7 +203,7 @@ func TestQueries(t *testing.T) { proposal2.TotalDeposit = proposal2.TotalDeposit.Add(deposit4.Amount...) proposal2.Status = v1beta1.StatusVotingPeriod - proposal2.VotingEndTime = proposal2.VotingEndTime.Add(types.DefaultPeriod) + proposal2.VotingEndTime = proposal2.VotingEndTime.Add(v1beta2.DefaultPeriod) deposit5 := v1beta1.NewDeposit(proposal3.ProposalId, TestAddrs[1], depositParams.MinDeposit) depositer5, err := sdk.AccAddressFromBech32(deposit5.Depositor) @@ -212,7 +213,7 @@ func TestQueries(t *testing.T) { proposal3.TotalDeposit = proposal3.TotalDeposit.Add(deposit5.Amount...) proposal3.Status = v1beta1.StatusVotingPeriod - proposal3.VotingEndTime = proposal3.VotingEndTime.Add(types.DefaultPeriod) + proposal3.VotingEndTime = proposal3.VotingEndTime.Add(v1beta2.DefaultPeriod) // total deposit of TestAddrs[1] on proposal #3 is worth the proposal deposit + individual deposit deposit5.Amount = deposit5.Amount.Add(deposit3.Amount...) diff --git a/x/gov/simulation/genesis_test.go b/x/gov/simulation/genesis_test.go index a7e7e4bd4145..2042d342aacf 100644 --- a/x/gov/simulation/genesis_test.go +++ b/x/gov/simulation/genesis_test.go @@ -13,7 +13,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/gov/simulation" - "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta2" ) // TestRandomizedGenState tests the normal scenario of applying RandomizedGenState. @@ -37,8 +37,8 @@ func TestRandomizedGenState(t *testing.T) { simulation.RandomizedGenState(&simState) - var govGenesis types.GenesisState - simState.Cdc.MustUnmarshalJSON(simState.GenState[types.ModuleName], &govGenesis) + var govGenesis v1beta2.GenesisState + simState.Cdc.MustUnmarshalJSON(simState.GenState[v1beta2.ModuleName], &govGenesis) dec1, _ := sdk.NewDecFromStr("0.361000000000000000") dec2, _ := sdk.NewDecFromStr("0.512000000000000000") @@ -51,9 +51,9 @@ func TestRandomizedGenState(t *testing.T) { require.Equal(t, dec2.String(), govGenesis.TallyParams.Threshold) require.Equal(t, dec3.String(), govGenesis.TallyParams.VetoThreshold) require.Equal(t, uint64(0x28), govGenesis.StartingProposalId) - require.Equal(t, []*types.Deposit{}, govGenesis.Deposits) - require.Equal(t, []*types.Vote{}, govGenesis.Votes) - require.Equal(t, []*types.Proposal{}, govGenesis.Proposals) + require.Equal(t, []*v1beta2.Deposit{}, govGenesis.Deposits) + require.Equal(t, []*v1beta2.Vote{}, govGenesis.Votes) + require.Equal(t, []*v1beta2.Proposal{}, govGenesis.Proposals) } // TestRandomizedGenState tests abnormal scenarios of applying RandomizedGenState. From 340517cfc8b3057a201eef0c5930aad7db9ff808 Mon Sep 17 00:00:00 2001 From: atheesh Date: Fri, 31 Dec 2021 15:41:17 +0530 Subject: [PATCH 04/11] removed deprecated vote option --- docs/core/proto-docs.md | 1 - proto/cosmos/gov/v1beta2/gov.proto | 4 - x/gov/types/v1beta2/gov.pb.go | 175 +++++++++++------------------ 3 files changed, 68 insertions(+), 112 deletions(-) mode change 100755 => 100644 x/gov/types/v1beta2/gov.pb.go diff --git a/docs/core/proto-docs.md b/docs/core/proto-docs.md index 4670b34325e4..4cea67e39da3 100644 --- a/docs/core/proto-docs.md +++ b/docs/core/proto-docs.md @@ -6205,7 +6205,6 @@ A Vote consists of a proposal ID, the voter, and the vote option. | ----- | ---- | ----- | ----------- | | `proposal_id` | [uint64](#uint64) | | | | `voter` | [string](#string) | | | -| `option` | [VoteOption](#cosmos.gov.v1beta2.VoteOption) | | **Deprecated.** Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. | | `options` | [WeightedVoteOption](#cosmos.gov.v1beta2.WeightedVoteOption) | repeated | | diff --git a/proto/cosmos/gov/v1beta2/gov.proto b/proto/cosmos/gov/v1beta2/gov.proto index 92bcbb2c6def..0582c4ee45f5 100644 --- a/proto/cosmos/gov/v1beta2/gov.proto +++ b/proto/cosmos/gov/v1beta2/gov.proto @@ -85,10 +85,6 @@ message TallyResult { message Vote { uint64 proposal_id = 1; string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Deprecated: Prefer to use `options` instead. This field is set in queries - // if and only if `len(options) == 1` and that option has weight 1. In all - // other cases, this field will default to VOTE_OPTION_UNSPECIFIED. - VoteOption option = 3 [deprecated = true]; repeated WeightedVoteOption options = 4; } diff --git a/x/gov/types/v1beta2/gov.pb.go b/x/gov/types/v1beta2/gov.pb.go old mode 100755 new mode 100644 index b8064e10147e..ad37297dda16 --- a/x/gov/types/v1beta2/gov.pb.go +++ b/x/gov/types/v1beta2/gov.pb.go @@ -416,13 +416,9 @@ func (m *TallyResult) GetNoWithVeto() string { // Vote defines a vote on a governance proposal. // A Vote consists of a proposal ID, the voter, and the vote option. type Vote struct { - ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` - Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` - // Deprecated: Prefer to use `options` instead. This field is set in queries - // if and only if `len(options) == 1` and that option has weight 1. In all - // other cases, this field will default to VOTE_OPTION_UNSPECIFIED. - Option VoteOption `protobuf:"varint,3,opt,name=option,proto3,enum=cosmos.gov.v1beta2.VoteOption" json:"option,omitempty"` // Deprecated: Do not use. - Options []*WeightedVoteOption `protobuf:"bytes,4,rep,name=options,proto3" json:"options,omitempty"` + ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` + Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` + Options []*WeightedVoteOption `protobuf:"bytes,4,rep,name=options,proto3" json:"options,omitempty"` } func (m *Vote) Reset() { *m = Vote{} } @@ -472,14 +468,6 @@ func (m *Vote) GetVoter() string { return "" } -// Deprecated: Do not use. -func (m *Vote) GetOption() VoteOption { - if m != nil { - return m.Option - } - return VoteOption_VOTE_OPTION_UNSPECIFIED -} - func (m *Vote) GetOptions() []*WeightedVoteOption { if m != nil { return m.Options @@ -671,71 +659,71 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/gov.proto", fileDescriptor_5abf7b8852811c49) } var fileDescriptor_5abf7b8852811c49 = []byte{ - // 1022 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x41, 0x6f, 0xdb, 0x36, - 0x14, 0x8e, 0x6c, 0xc7, 0x49, 0x9e, 0x13, 0x57, 0x63, 0x83, 0x55, 0x49, 0x3b, 0x39, 0xf3, 0x21, - 0x08, 0x8a, 0xc5, 0x4e, 0x32, 0xac, 0x03, 0x76, 0xaa, 0x1d, 0xa9, 0xab, 0x82, 0x34, 0x32, 0x24, - 0xd5, 0xc1, 0x76, 0x11, 0xe4, 0x88, 0x95, 0x85, 0x59, 0xa2, 0x27, 0xd2, 0x69, 0xf2, 0x13, 0x76, - 0xeb, 0x71, 0xd8, 0x2e, 0xbb, 0xef, 0xda, 0x1f, 0xd1, 0xd3, 0x50, 0x14, 0x28, 0xb0, 0xd3, 0x36, - 0x24, 0x7f, 0x64, 0x10, 0x45, 0x25, 0x8e, 0xe3, 0x22, 0x3e, 0x99, 0x7a, 0xef, 0xfb, 0x3e, 0x3e, - 0x92, 0x1f, 0x9f, 0x09, 0x8f, 0x4e, 0x08, 0x8d, 0x08, 0x6d, 0x06, 0xe4, 0xb4, 0x79, 0xba, 0xdb, - 0xc3, 0xcc, 0xdb, 0x4b, 0xc7, 0x8d, 0x61, 0x42, 0x18, 0x41, 0x28, 0xcb, 0x36, 0xd2, 0x88, 0xc8, - 0xae, 0xab, 0x82, 0xd1, 0xf3, 0x28, 0x16, 0x94, 0xdd, 0xe6, 0x09, 0x09, 0xe3, 0x8c, 0xb3, 0xbe, - 0x1a, 0x90, 0x80, 0xf0, 0x61, 0x33, 0x1d, 0x89, 0x68, 0x2d, 0x20, 0x24, 0x18, 0xe0, 0x26, 0xff, - 0xea, 0x8d, 0x5e, 0x35, 0x59, 0x18, 0x61, 0xca, 0xbc, 0x68, 0x28, 0x00, 0x6b, 0x93, 0x00, 0x2f, - 0x3e, 0x17, 0x29, 0x75, 0x32, 0xe5, 0x8f, 0x12, 0x8f, 0x85, 0x24, 0x9f, 0x71, 0x2d, 0xab, 0xc8, - 0xcd, 0x26, 0x15, 0x25, 0xf3, 0x8f, 0x3a, 0x03, 0x74, 0x8c, 0xc3, 0xa0, 0xcf, 0xb0, 0xdf, 0x25, - 0x0c, 0x9b, 0xc3, 0x94, 0x86, 0x9e, 0x40, 0x99, 0xf0, 0x91, 0x22, 0x6d, 0x48, 0x5b, 0xd5, 0x3d, - 0xb5, 0x71, 0x7b, 0x9d, 0x8d, 0x6b, 0xbc, 0x25, 0xd0, 0x68, 0x13, 0xca, 0xaf, 0xb9, 0x9a, 0x52, - 0xd8, 0x90, 0xb6, 0x96, 0xda, 0xd5, 0x0f, 0x6f, 0xb7, 0x41, 0x50, 0x35, 0x7c, 0x62, 0x89, 0x6c, - 0xfd, 0x77, 0x09, 0x16, 0x34, 0x3c, 0x24, 0x34, 0x64, 0xa8, 0x06, 0x95, 0x61, 0x42, 0x86, 0x84, - 0x7a, 0x03, 0x37, 0xf4, 0xf9, 0x84, 0x25, 0x0b, 0xf2, 0x90, 0xe1, 0xa3, 0x27, 0xb0, 0xe4, 0x67, - 0x58, 0x92, 0x08, 0x5d, 0xe5, 0xc3, 0xdb, 0xed, 0x55, 0xa1, 0xdb, 0xf2, 0xfd, 0x04, 0x53, 0x6a, - 0xb3, 0x24, 0x8c, 0x03, 0xe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 0x98, 0x37, 0x70, 0x45, 0x5c, 0x59, 0x98, - 0xed, 0xe4, 0x96, 0x39, 0x2b, 0x77, 0xd4, 0x21, 0x7c, 0x76, 0x4a, 0x58, 0x18, 0x07, 0x2e, 0x65, - 0x5e, 0x22, 0x96, 0xb6, 0x38, 0x63, 0x49, 0xf7, 0x32, 0xaa, 0x9d, 0x32, 0x79, 0x4d, 0xcf, 0x41, - 0x84, 0xae, 0x97, 0xb7, 0x34, 0xa3, 0xd6, 0x4a, 0x46, 0x14, 0xab, 0xab, 0xff, 0x29, 0x41, 0x65, - 0x7c, 0xf3, 0x37, 0xa0, 0x78, 0x8e, 0x29, 0xb7, 0xd4, 0xcd, 0xab, 0x62, 0xc4, 0xcc, 0x4a, 0x53, - 0x68, 0x0b, 0x16, 0xbc, 0x1e, 0x65, 0x5e, 0x18, 0x4f, 0xb9, 0x50, 0x29, 0x2a, 0x4f, 0x23, 0x15, - 0x0a, 0x31, 0xe1, 0x7e, 0xba, 0x0d, 0x2a, 0xc4, 0x04, 0xed, 0xc0, 0x72, 0x4c, 0xdc, 0xd7, 0x21, - 0xeb, 0xbb, 0xa7, 0x98, 0x11, 0xee, 0x98, 0xdb, 0x48, 0x88, 0xc9, 0x71, 0xc8, 0xfa, 0x5d, 0xcc, - 0x48, 0xfd, 0xa3, 0x04, 0xa5, 0xf4, 0x8a, 0xdf, 0x7d, 0x03, 0x1a, 0x30, 0x7f, 0x4a, 0x18, 0xbe, - 0xfb, 0x72, 0x66, 0xb0, 0xd4, 0xff, 0xa2, 0xbb, 0x14, 0x67, 0xe9, 0x2e, 0xed, 0x82, 0x22, 0x5d, - 0x75, 0x98, 0xa7, 0xb0, 0x90, 0x8d, 0xa8, 0x52, 0xe2, 0xde, 0xd8, 0x9c, 0x46, 0xbe, 0xdd, 0xd2, - 0xac, 0x9c, 0x56, 0xff, 0x43, 0x82, 0x15, 0xe1, 0x94, 0x8e, 0x97, 0x78, 0x11, 0x45, 0x4f, 0xa1, - 0x12, 0x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 0x6c, 0x38, 0xcf, 0xdd, 0xae, 0xee, 0x98, 0x72, 0xe9, - 0xf1, 0x5f, 0x12, 0x54, 0x6f, 0xb6, 0x5f, 0x54, 0x83, 0x87, 0x1d, 0xcb, 0xec, 0x98, 0x76, 0xeb, - 0xd0, 0xb5, 0x9d, 0x96, 0xf3, 0xd2, 0x9e, 0xa8, 0xa9, 0x0e, 0xea, 0x24, 0x40, 0xd3, 0x3b, 0xa6, - 0x6d, 0x38, 0x6e, 0x47, 0xb7, 0x0c, 0x53, 0x93, 0x25, 0xf4, 0x25, 0x7c, 0x31, 0x89, 0xe9, 0x9a, - 0x8e, 0x71, 0xf4, 0x7d, 0x0e, 0x29, 0xa0, 0x75, 0xf8, 0x7c, 0x12, 0xd2, 0x69, 0xd9, 0xb6, 0xae, - 0x65, 0x45, 0x4f, 0xe6, 0x2c, 0xfd, 0x40, 0xdf, 0x77, 0x74, 0x4d, 0x2e, 0x4d, 0x63, 0x3e, 0x6b, - 0x19, 0x87, 0xba, 0x26, 0xcf, 0xb7, 0x0f, 0xde, 0x5d, 0xa8, 0xd2, 0xfb, 0x0b, 0x55, 0xfa, 0xef, - 0x42, 0x95, 0xde, 0x5c, 0xaa, 0x73, 0xef, 0x2f, 0xd5, 0xb9, 0xbf, 0x2f, 0xd5, 0xb9, 0x1f, 0x77, - 0x82, 0x90, 0xf5, 0x47, 0xbd, 0xc6, 0x09, 0x89, 0xc4, 0xbb, 0x40, 0xfc, 0x6c, 0x53, 0xff, 0xa7, - 0xe6, 0x19, 0x7f, 0xf5, 0xb0, 0xf3, 0x21, 0xa6, 0xf9, 0xdb, 0xa7, 0x57, 0xe6, 0x66, 0xfb, 0xfa, - 0xff, 0x00, 0x00, 0x00, 0xff, 0xff, 0x59, 0x87, 0xaa, 0xdc, 0x18, 0x09, 0x00, 0x00, + // 1011 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x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 0x7e, 0xe8, 0xe8, 0x9a, + 0x5c, 0x9a, 0xc5, 0x7c, 0xd6, 0x32, 0x8e, 0x75, 0x4d, 0x5e, 0x6c, 0x1f, 0xbd, 0xbb, 0x52, 0xa5, + 0xf7, 0x57, 0xaa, 0xf4, 0xcf, 0x95, 0x2a, 0xbd, 0xb9, 0x56, 0x17, 0xde, 0x5f, 0xab, 0x0b, 0x7f, + 0x5e, 0xab, 0x0b, 0xdf, 0xee, 0x05, 0x21, 0xeb, 0x8f, 0x7a, 0x8d, 0x33, 0x12, 0x89, 0xdf, 0x76, + 0xf1, 0xb1, 0x4b, 0xfd, 0xef, 0x9a, 0x17, 0xfc, 0x9f, 0x0b, 0xbb, 0x1c, 0x62, 0x9a, 0xff, 0x7f, + 0xe9, 0x95, 0xb9, 0xd9, 0x3e, 0xff, 0x37, 0x00, 0x00, 0xff, 0xff, 0xd3, 0xab, 0x24, 0x9b, 0xdc, + 0x08, 0x00, 0x00, } func (m *WeightedVoteOption) Marshal() (dAtA []byte, err error) { @@ -1020,11 +1008,6 @@ func (m *Vote) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x22 } } - if m.Option != 0 { - i = encodeVarintGov(dAtA, i, uint64(m.Option)) - i-- - dAtA[i] = 0x18 - } if len(m.Voter) > 0 { i -= len(m.Voter) copy(dAtA[i:], m.Voter) @@ -1298,9 +1281,6 @@ func (m *Vote) Size() (n int) { if l > 0 { n += 1 + l + sovGov(uint64(l)) } - if m.Option != 0 { - n += 1 + sovGov(uint64(m.Option)) - } if len(m.Options) > 0 { for _, e := range m.Options { l = e.Size() @@ -2199,25 +2179,6 @@ func (m *Vote) Unmarshal(dAtA []byte) error { } m.Voter = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Option", wireType) - } - m.Option = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGov - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Option |= VoteOption(b&0x7F) << shift - if b < 0x80 { - break - } - } case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) From 5855e81c2563806f3516b93102c0d41504c523e1 Mon Sep 17 00:00:00 2001 From: atheesh Date: Wed, 5 Jan 2022 11:22:14 +0530 Subject: [PATCH 05/11] revert mod --- x/gov/types/v1beta2/genesis.pb.go | 0 x/gov/types/v1beta2/query.pb.go | 0 x/gov/types/v1beta2/query.pb.gw.go | 0 x/gov/types/v1beta2/tx.pb.go | 0 4 files changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 x/gov/types/v1beta2/genesis.pb.go mode change 100755 => 100644 x/gov/types/v1beta2/query.pb.go mode change 100755 => 100644 x/gov/types/v1beta2/query.pb.gw.go mode change 100755 => 100644 x/gov/types/v1beta2/tx.pb.go diff --git a/x/gov/types/v1beta2/genesis.pb.go b/x/gov/types/v1beta2/genesis.pb.go old mode 100755 new mode 100644 diff --git a/x/gov/types/v1beta2/query.pb.go b/x/gov/types/v1beta2/query.pb.go old mode 100755 new mode 100644 diff --git a/x/gov/types/v1beta2/query.pb.gw.go b/x/gov/types/v1beta2/query.pb.gw.go old mode 100755 new mode 100644 diff --git a/x/gov/types/v1beta2/tx.pb.go b/x/gov/types/v1beta2/tx.pb.go old mode 100755 new mode 100644 From dd2eb6392a39282637f6c3c125b3d02bce59d3b4 Mon Sep 17 00:00:00 2001 From: atheesh Date: Wed, 5 Jan 2022 11:32:09 +0530 Subject: [PATCH 06/11] add reserved --- proto/cosmos/gov/v1beta2/gov.proto | 1 + x/gov/types/v1beta2/gov.pb.go | 130 ++++++++++++++--------------- 2 files changed, 66 insertions(+), 65 deletions(-) diff --git a/proto/cosmos/gov/v1beta2/gov.proto b/proto/cosmos/gov/v1beta2/gov.proto index 0582c4ee45f5..8057b94d7385 100644 --- a/proto/cosmos/gov/v1beta2/gov.proto +++ b/proto/cosmos/gov/v1beta2/gov.proto @@ -85,6 +85,7 @@ message TallyResult { message Vote { uint64 proposal_id = 1; string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + reserved 3; repeated WeightedVoteOption options = 4; } diff --git a/x/gov/types/v1beta2/gov.pb.go b/x/gov/types/v1beta2/gov.pb.go index ad37297dda16..dd15ce3d154f 100644 --- a/x/gov/types/v1beta2/gov.pb.go +++ b/x/gov/types/v1beta2/gov.pb.go @@ -659,71 +659,71 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/gov.proto", fileDescriptor_5abf7b8852811c49) } var fileDescriptor_5abf7b8852811c49 = []byte{ - // 1011 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x4f, 0x6f, 0xdb, 0xc6, - 0x13, 0x35, 0x25, 0x59, 0xb6, 0x47, 0xb6, 0xc2, 0xdf, 0xc6, 0xf8, 0x85, 0x76, 0x52, 0xca, 0xd5, - 0xc1, 0x30, 0x82, 0x5a, 0xb2, 0x5d, 0x34, 0x05, 0x7a, 0x8a, 0x64, 0x32, 0x0d, 0x0d, 0xc7, 0x14, - 0x48, 0x46, 0x46, 0x7b, 0x21, 0x28, 0x73, 0x43, 0x11, 0x15, 0xb9, 0x2a, 0x77, 0xe5, 0xd8, 0x1f, - 0xa1, 0xb7, 0x1c, 0xfb, 0xe7, 0xd2, 0x7b, 0xaf, 0xf9, 0x10, 0x39, 0x15, 0x41, 0x80, 0x02, 0x3d, - 0xb5, 0x85, 0xfd, 0x45, 0x0a, 0x2e, 0x97, 0xb1, 0x2c, 0xa9, 0xb0, 0x4e, 0x5a, 0xcd, 0xbc, 0xf7, - 0x76, 0x66, 0xe7, 0xed, 0x4a, 0xf0, 0xe8, 0x8c, 0xd0, 0x88, 0xd0, 0x66, 0x40, 0xce, 0x9b, 0xe7, - 0xfb, 0x3d, 0xcc, 0xbc, 0x83, 0x74, 0xdd,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4c, 0xb9, 0xf4, 0xf8, 0x77, 0x09, 0xaa, 0xb7, 0x9f, 0x50, 0x54, 0x83, 0x87, 0x1d, - 0xcb, 0xec, 0x98, 0x76, 0xeb, 0xd8, 0xb5, 0x9d, 0x96, 0xf3, 0xd2, 0x9e, 0xa8, 0xa9, 0x0e, 0xea, - 0x24, 0x40, 0xd3, 0x3b, 0xa6, 0x6d, 0x38, 0x6e, 0x47, 0xb7, 0x0c, 0x53, 0x93, 0x25, 0xf4, 0x29, - 0x7c, 0x32, 0x89, 0xe9, 0x9a, 0x8e, 0x71, 0xf2, 0x75, 0x0e, 0x29, 0xa0, 0x4d, 0xf8, 0xff, 0x24, - 0xa4, 0xd3, 0xb2, 0x6d, 0x5d, 0xcb, 0x8a, 0x9e, 0xcc, 0x59, 0xfa, 0x91, 0x7e, 0xe8, 0xe8, 0x9a, - 0x5c, 0x9a, 0xc5, 0x7c, 0xd6, 0x32, 0x8e, 0x75, 0x4d, 0x5e, 0x6c, 0x1f, 0xbd, 0xbb, 0x52, 0xa5, - 0xf7, 0x57, 0xaa, 0xf4, 0xcf, 0x95, 0x2a, 0xbd, 0xb9, 0x56, 0x17, 0xde, 0x5f, 0xab, 0x0b, 0x7f, - 0x5e, 0xab, 0x0b, 0xdf, 0xee, 0x05, 0x21, 0xeb, 0x8f, 0x7a, 0x8d, 0x33, 0x12, 0x89, 0xdf, 0x76, - 0xf1, 0xb1, 0x4b, 0xfd, 0xef, 0x9a, 0x17, 0xfc, 0x9f, 0x0b, 0xbb, 0x1c, 0x62, 0x9a, 0xff, 0x7f, - 0xe9, 0x95, 0xb9, 0xd9, 0x3e, 0xff, 0x37, 0x00, 0x00, 0xff, 0xff, 0xd3, 0xab, 0x24, 0x9b, 0xdc, - 0x08, 0x00, 0x00, + // 1017 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x41, 0x6f, 0xdb, 0x46, + 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x1b, + 0x47, 0xc6, 0xa1, 0x6b, 0xe8, 0x8a, 0x3c, 0x8b, 0xf9, 0xac, 0x69, 0x1e, 0x1b, 0xba, 0xb2, 0xd8, + 0x3a, 0x7a, 0x77, 0xa5, 0x49, 0xef, 0xaf, 0x34, 0xe9, 0x9f, 0x2b, 0x4d, 0x7a, 0x73, 0xad, 0x2d, + 0xbc, 0xbf, 0xd6, 0x16, 0xfe, 0xbc, 0xd6, 0x16, 0xbe, 0xdd, 0xeb, 0x85, 0xac, 0x3f, 0xea, 0xd6, + 0xcf, 0x48, 0x24, 0x7e, 0xe1, 0xc5, 0xc7, 0x2e, 0x0d, 0xbe, 0x6b, 0x5c, 0xf0, 0xff, 0x2f, 0xec, + 0x72, 0x88, 0x69, 0xfe, 0x2f, 0xa6, 0x5b, 0xe2, 0x66, 0xfb, 0xfc, 0xdf, 0x00, 0x00, 0x00, 0xff, + 0xff, 0xce, 0x0b, 0x1c, 0x6c, 0xe2, 0x08, 0x00, 0x00, } func (m *WeightedVoteOption) Marshal() (dAtA []byte, err error) { From 26ccc2697c1a18a865818273316b2d46becfcbe6 Mon Sep 17 00:00:00 2001 From: atheesh Date: Mon, 24 Jan 2022 19:16:18 +0530 Subject: [PATCH 07/11] remove `populateLegacyOption` func --- api/cosmos/gov/v1beta2/gov.pulsar.go | 236 ++++++++++----------------- orm/internal/testpb/bank.pulsar.go | 10 +- x/gov/keeper/grpc_query.go | 1 - x/gov/keeper/vote.go | 13 -- x/gov/types/v1beta2/gov.pb.go | 133 ++++++++------- 5 files changed, 155 insertions(+), 238 deletions(-) diff --git a/api/cosmos/gov/v1beta2/gov.pulsar.go b/api/cosmos/gov/v1beta2/gov.pulsar.go index c2d3cd802cbd..07c3b2a672cd 100644 --- a/api/cosmos/gov/v1beta2/gov.pulsar.go +++ b/api/cosmos/gov/v1beta2/gov.pulsar.go @@ -2881,7 +2881,6 @@ var ( md_Vote protoreflect.MessageDescriptor fd_Vote_proposal_id protoreflect.FieldDescriptor fd_Vote_voter protoreflect.FieldDescriptor - fd_Vote_option protoreflect.FieldDescriptor fd_Vote_options protoreflect.FieldDescriptor ) @@ -2890,7 +2889,6 @@ func init() { md_Vote = File_cosmos_gov_v1beta2_gov_proto.Messages().ByName("Vote") fd_Vote_proposal_id = md_Vote.Fields().ByName("proposal_id") fd_Vote_voter = md_Vote.Fields().ByName("voter") - fd_Vote_option = md_Vote.Fields().ByName("option") fd_Vote_options = md_Vote.Fields().ByName("options") } @@ -2971,12 +2969,6 @@ func (x *fastReflection_Vote) Range(f func(protoreflect.FieldDescriptor, protore return } } - if x.Option != 0 { - value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Option)) - if !f(fd_Vote_option, value) { - return - } - } if len(x.Options) != 0 { value := protoreflect.ValueOfList(&_Vote_4_list{list: &x.Options}) if !f(fd_Vote_options, value) { @@ -3002,8 +2994,6 @@ func (x *fastReflection_Vote) Has(fd protoreflect.FieldDescriptor) bool { return x.ProposalId != uint64(0) case "cosmos.gov.v1beta2.Vote.voter": return x.Voter != "" - case "cosmos.gov.v1beta2.Vote.option": - return x.Option != 0 case "cosmos.gov.v1beta2.Vote.options": return len(x.Options) != 0 default: @@ -3026,8 +3016,6 @@ func (x *fastReflection_Vote) Clear(fd protoreflect.FieldDescriptor) { x.ProposalId = uint64(0) case "cosmos.gov.v1beta2.Vote.voter": x.Voter = "" - case "cosmos.gov.v1beta2.Vote.option": - x.Option = 0 case "cosmos.gov.v1beta2.Vote.options": x.Options = nil default: @@ -3052,9 +3040,6 @@ func (x *fastReflection_Vote) Get(descriptor protoreflect.FieldDescriptor) proto case "cosmos.gov.v1beta2.Vote.voter": value := x.Voter return protoreflect.ValueOfString(value) - case "cosmos.gov.v1beta2.Vote.option": - value := x.Option - return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) case "cosmos.gov.v1beta2.Vote.options": if len(x.Options) == 0 { return protoreflect.ValueOfList(&_Vote_4_list{}) @@ -3085,8 +3070,6 @@ func (x *fastReflection_Vote) Set(fd protoreflect.FieldDescriptor, value protore x.ProposalId = value.Uint() case "cosmos.gov.v1beta2.Vote.voter": x.Voter = value.Interface().(string) - case "cosmos.gov.v1beta2.Vote.option": - x.Option = (VoteOption)(value.Enum()) case "cosmos.gov.v1beta2.Vote.options": lv := value.List() clv := lv.(*_Vote_4_list) @@ -3121,8 +3104,6 @@ func (x *fastReflection_Vote) Mutable(fd protoreflect.FieldDescriptor) protorefl panic(fmt.Errorf("field proposal_id of message cosmos.gov.v1beta2.Vote is not mutable")) case "cosmos.gov.v1beta2.Vote.voter": panic(fmt.Errorf("field voter of message cosmos.gov.v1beta2.Vote is not mutable")) - case "cosmos.gov.v1beta2.Vote.option": - panic(fmt.Errorf("field option of message cosmos.gov.v1beta2.Vote is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.gov.v1beta2.Vote")) @@ -3140,8 +3121,6 @@ func (x *fastReflection_Vote) NewField(fd protoreflect.FieldDescriptor) protoref return protoreflect.ValueOfUint64(uint64(0)) case "cosmos.gov.v1beta2.Vote.voter": return protoreflect.ValueOfString("") - case "cosmos.gov.v1beta2.Vote.option": - return protoreflect.ValueOfEnum(0) case "cosmos.gov.v1beta2.Vote.options": list := []*WeightedVoteOption{} return protoreflect.ValueOfList(&_Vote_4_list{list: &list}) @@ -3221,9 +3200,6 @@ func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods { if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - if x.Option != 0 { - n += 1 + runtime.Sov(uint64(x.Option)) - } if len(x.Options) > 0 { for _, e := range x.Options { l = options.Size(e) @@ -3275,11 +3251,6 @@ func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods { dAtA[i] = 0x22 } } - if x.Option != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.Option)) - i-- - dAtA[i] = 0x18 - } if len(x.Voter) > 0 { i -= len(x.Voter) copy(dAtA[i:], x.Voter) @@ -3392,25 +3363,6 @@ func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods { } x.Voter = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Option", wireType) - } - x.Option = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow - } - if iNdEx >= l { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - x.Option |= VoteOption(b&0x7F) << shift - if b < 0x80 { - break - } - } case 4: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Options", wireType) @@ -5444,15 +5396,9 @@ type Vote struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` - Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` - // Deprecated: Prefer to use `options` instead. This field is set in queries - // if and only if `len(options) == 1` and that option has weight 1. In all - // other cases, this field will default to VOTE_OPTION_UNSPECIFIED. - // - // Deprecated: Do not use. - Option VoteOption `protobuf:"varint,3,opt,name=option,proto3,enum=cosmos.gov.v1beta2.VoteOption" json:"option,omitempty"` - Options []*WeightedVoteOption `protobuf:"bytes,4,rep,name=options,proto3" json:"options,omitempty"` + ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` + Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` + Options []*WeightedVoteOption `protobuf:"bytes,4,rep,name=options,proto3" json:"options,omitempty"` } func (x *Vote) Reset() { @@ -5489,14 +5435,6 @@ func (x *Vote) GetVoter() string { return "" } -// Deprecated: Do not use. -func (x *Vote) GetOption() VoteOption { - if x != nil { - return x.Option - } - return VoteOption_VOTE_OPTION_UNSPECIFIED -} - func (x *Vote) GetOptions() []*WeightedVoteOption { if x != nil { return x.Options @@ -5727,89 +5665,86 @@ var file_cosmos_gov_v1beta2_gov_proto_rawDesc = []byte{ 0x49, 0x6e, 0x74, 0x52, 0x02, 0x6e, 0x6f, 0x12, 0x30, 0x0a, 0x0c, 0x6e, 0x6f, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x5f, 0x76, 0x65, 0x74, 0x6f, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0e, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x49, 0x6e, 0x74, 0x52, 0x0a, 0x6e, - 0x6f, 0x57, 0x69, 0x74, 0x68, 0x56, 0x65, 0x74, 0x6f, 0x22, 0xd5, 0x01, 0x0a, 0x04, 0x56, 0x6f, + 0x6f, 0x57, 0x69, 0x74, 0x68, 0x56, 0x65, 0x74, 0x6f, 0x22, 0x9f, 0x01, 0x0a, 0x04, 0x56, 0x6f, 0x74, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x49, 0x64, 0x12, 0x2e, 0x0a, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x05, 0x76, 0x6f, - 0x74, 0x65, 0x72, 0x12, 0x3a, 0x0a, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x0e, 0x32, 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, - 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x2e, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x42, 0x02, 0x18, 0x01, 0x52, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, - 0x40, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x32, 0x2e, 0x57, 0x65, 0x69, 0x67, 0x68, 0x74, 0x65, 0x64, 0x56, 0x6f, - 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0x22, 0xd9, 0x01, 0x0a, 0x0d, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x61, 0x72, - 0x61, 0x6d, 0x73, 0x12, 0x59, 0x0a, 0x0b, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, - 0x69, 0x74, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, - 0x6f, 0x69, 0x6e, 0x42, 0x1d, 0xc8, 0xde, 0x1f, 0x00, 0xea, 0xde, 0x1f, 0x15, 0x6d, 0x69, 0x6e, - 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, - 0x74, 0x79, 0x52, 0x0a, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x6d, - 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x70, 0x65, - 0x72, 0x69, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x24, 0xea, 0xde, 0x1f, 0x1c, 0x6d, 0x61, 0x78, 0x5f, 0x64, - 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x2c, 0x6f, 0x6d, - 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x10, 0x6d, 0x61, 0x78, - 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x22, 0x54, 0x0a, - 0x0c, 0x56, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x44, 0x0a, - 0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x01, + 0x74, 0x65, 0x72, 0x12, 0x40, 0x0a, 0x07, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x04, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, + 0x76, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x2e, 0x57, 0x65, 0x69, 0x67, 0x68, 0x74, + 0x65, 0x64, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x07, 0x6f, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x4a, 0x04, 0x08, 0x03, 0x10, 0x04, 0x22, 0xd9, 0x01, 0x0a, 0x0d, + 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x59, 0x0a, + 0x0b, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x18, 0x01, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x1d, 0xc8, + 0xde, 0x1f, 0x00, 0xea, 0xde, 0x1f, 0x15, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, + 0x69, 0x74, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x52, 0x0a, 0x6d, 0x69, + 0x6e, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x12, 0x6d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, + 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, - 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x0c, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x65, 0x72, - 0x69, 0x6f, 0x64, 0x22, 0xe1, 0x01, 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x50, 0x61, 0x72, - 0x61, 0x6d, 0x73, 0x12, 0x3a, 0x0a, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x42, 0x22, 0xea, 0xde, 0x1f, 0x10, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x2c, - 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, - 0x43, 0x0a, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x25, 0xea, 0xde, 0x1f, 0x13, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, - 0x64, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, - 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x51, 0x0a, 0x0e, 0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68, 0x72, - 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2a, 0xea, 0xde, - 0x1f, 0x18, 0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, - 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, 0x63, 0x52, 0x0d, 0x76, 0x65, 0x74, 0x6f, 0x54, 0x68, - 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x2a, 0x89, 0x01, 0x0a, 0x0a, 0x56, 0x6f, 0x74, 0x65, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1b, 0x0a, 0x17, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, - 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, - 0x44, 0x10, 0x00, 0x12, 0x13, 0x0a, 0x0f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, - 0x4f, 0x4e, 0x5f, 0x59, 0x45, 0x53, 0x10, 0x01, 0x12, 0x17, 0x0a, 0x13, 0x56, 0x4f, 0x54, 0x45, - 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x41, 0x42, 0x53, 0x54, 0x41, 0x49, 0x4e, 0x10, - 0x02, 0x12, 0x12, 0x0a, 0x0e, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, - 0x5f, 0x4e, 0x4f, 0x10, 0x03, 0x12, 0x1c, 0x0a, 0x18, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, - 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4e, 0x4f, 0x5f, 0x57, 0x49, 0x54, 0x48, 0x5f, 0x56, 0x45, 0x54, - 0x4f, 0x10, 0x04, 0x2a, 0xce, 0x01, 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, - 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, - 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, - 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x22, 0x0a, 0x1e, 0x50, 0x52, 0x4f, 0x50, 0x4f, - 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x44, 0x45, 0x50, 0x4f, 0x53, - 0x49, 0x54, 0x5f, 0x50, 0x45, 0x52, 0x49, 0x4f, 0x44, 0x10, 0x01, 0x12, 0x21, 0x0a, 0x1d, 0x50, - 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x56, - 0x4f, 0x54, 0x49, 0x4e, 0x47, 0x5f, 0x50, 0x45, 0x52, 0x49, 0x4f, 0x44, 0x10, 0x02, 0x12, 0x1a, - 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, - 0x53, 0x5f, 0x50, 0x41, 0x53, 0x53, 0x45, 0x44, 0x10, 0x03, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, - 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, - 0x4a, 0x45, 0x43, 0x54, 0x45, 0x44, 0x10, 0x04, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, - 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x46, 0x41, 0x49, 0x4c, - 0x45, 0x44, 0x10, 0x05, 0x42, 0xcc, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, 0x76, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x42, - 0x08, 0x47, 0x6f, 0x76, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, 0x6f, 0x76, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, - 0x3b, 0x67, 0x6f, 0x76, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0xa2, 0x02, 0x03, 0x43, 0x47, - 0x58, 0xaa, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x6f, 0x76, 0x2e, 0x56, - 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0xca, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, - 0x47, 0x6f, 0x76, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0xe2, 0x02, 0x1e, 0x43, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x6f, 0x76, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, - 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x14, 0x43, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x47, 0x6f, 0x76, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, - 0x74, 0x61, 0x32, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x24, 0xea, 0xde, 0x1f, 0x1c, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x6f, 0x73, 0x69, 0x74, + 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, + 0x79, 0x98, 0xdf, 0x1f, 0x01, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, 0x6f, 0x73, 0x69, + 0x74, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x22, 0x54, 0x0a, 0x0c, 0x56, 0x6f, 0x74, 0x69, 0x6e, + 0x67, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x44, 0x0a, 0x0d, 0x76, 0x6f, 0x74, 0x69, 0x6e, + 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x44, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x04, 0x98, 0xdf, 0x1f, 0x01, 0x52, + 0x0c, 0x76, 0x6f, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x22, 0xe1, 0x01, + 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x3a, 0x0a, + 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x22, 0xea, + 0xde, 0x1f, 0x10, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, + 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, 0x65, + 0x63, 0x52, 0x06, 0x71, 0x75, 0x6f, 0x72, 0x75, 0x6d, 0x12, 0x43, 0x0a, 0x09, 0x74, 0x68, 0x72, + 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x25, 0xea, 0xde, + 0x1f, 0x13, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x2c, 0x6f, 0x6d, 0x69, 0x74, + 0x65, 0x6d, 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x44, 0x65, 0x63, 0x52, 0x09, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x12, 0x51, + 0x0a, 0x0e, 0x76, 0x65, 0x74, 0x6f, 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x2a, 0xea, 0xde, 0x1f, 0x18, 0x76, 0x65, 0x74, 0x6f, + 0x5f, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x2c, 0x6f, 0x6d, 0x69, 0x74, 0x65, + 0x6d, 0x70, 0x74, 0x79, 0xd2, 0xb4, 0x2d, 0x0a, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x44, + 0x65, 0x63, 0x52, 0x0d, 0x76, 0x65, 0x74, 0x6f, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, + 0x64, 0x2a, 0x89, 0x01, 0x0a, 0x0a, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, + 0x12, 0x1b, 0x0a, 0x17, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, + 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x13, 0x0a, + 0x0f, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x59, 0x45, 0x53, + 0x10, 0x01, 0x12, 0x17, 0x0a, 0x13, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, + 0x4e, 0x5f, 0x41, 0x42, 0x53, 0x54, 0x41, 0x49, 0x4e, 0x10, 0x02, 0x12, 0x12, 0x0a, 0x0e, 0x56, + 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4e, 0x4f, 0x10, 0x03, 0x12, + 0x1c, 0x0a, 0x18, 0x56, 0x4f, 0x54, 0x45, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4e, + 0x4f, 0x5f, 0x57, 0x49, 0x54, 0x48, 0x5f, 0x56, 0x45, 0x54, 0x4f, 0x10, 0x04, 0x2a, 0xce, 0x01, + 0x0a, 0x0e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x12, 0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, + 0x54, 0x55, 0x53, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, + 0x00, 0x12, 0x22, 0x0a, 0x1e, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, + 0x41, 0x54, 0x55, 0x53, 0x5f, 0x44, 0x45, 0x50, 0x4f, 0x53, 0x49, 0x54, 0x5f, 0x50, 0x45, 0x52, + 0x49, 0x4f, 0x44, 0x10, 0x01, 0x12, 0x21, 0x0a, 0x1d, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, + 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x56, 0x4f, 0x54, 0x49, 0x4e, 0x47, 0x5f, + 0x50, 0x45, 0x52, 0x49, 0x4f, 0x44, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, + 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x50, 0x41, 0x53, 0x53, + 0x45, 0x44, 0x10, 0x03, 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, + 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, 0x54, 0x45, 0x44, + 0x10, 0x04, 0x12, 0x1a, 0x0a, 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, + 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x46, 0x41, 0x49, 0x4c, 0x45, 0x44, 0x10, 0x05, 0x42, 0xcc, + 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x6f, + 0x76, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x42, 0x08, 0x47, 0x6f, 0x76, 0x50, 0x72, + 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, + 0x73, 0x64, 0x6b, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, + 0x6f, 0x76, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x3b, 0x67, 0x6f, 0x76, 0x76, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x32, 0xa2, 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x12, 0x43, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x6f, 0x76, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, + 0xca, 0x02, 0x12, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x6f, 0x76, 0x5c, 0x56, 0x31, + 0x62, 0x65, 0x74, 0x61, 0x32, 0xe2, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, + 0x6f, 0x76, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x14, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, + 0x3a, 0x47, 0x6f, 0x76, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x32, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -5853,16 +5788,15 @@ var file_cosmos_gov_v1beta2_gov_proto_depIdxs = []int32{ 10, // 7: cosmos.gov.v1beta2.Proposal.total_deposit:type_name -> cosmos.base.v1beta1.Coin 12, // 8: cosmos.gov.v1beta2.Proposal.voting_start_time:type_name -> google.protobuf.Timestamp 12, // 9: cosmos.gov.v1beta2.Proposal.voting_end_time:type_name -> google.protobuf.Timestamp - 0, // 10: cosmos.gov.v1beta2.Vote.option:type_name -> cosmos.gov.v1beta2.VoteOption - 2, // 11: cosmos.gov.v1beta2.Vote.options:type_name -> cosmos.gov.v1beta2.WeightedVoteOption - 10, // 12: cosmos.gov.v1beta2.DepositParams.min_deposit:type_name -> cosmos.base.v1beta1.Coin - 13, // 13: cosmos.gov.v1beta2.DepositParams.max_deposit_period:type_name -> google.protobuf.Duration - 13, // 14: cosmos.gov.v1beta2.VotingParams.voting_period:type_name -> google.protobuf.Duration - 15, // [15:15] is the sub-list for method output_type - 15, // [15:15] is the sub-list for method input_type - 15, // [15:15] is the sub-list for extension type_name - 15, // [15:15] is the sub-list for extension extendee - 0, // [0:15] is the sub-list for field type_name + 2, // 10: cosmos.gov.v1beta2.Vote.options:type_name -> cosmos.gov.v1beta2.WeightedVoteOption + 10, // 11: cosmos.gov.v1beta2.DepositParams.min_deposit:type_name -> cosmos.base.v1beta1.Coin + 13, // 12: cosmos.gov.v1beta2.DepositParams.max_deposit_period:type_name -> google.protobuf.Duration + 13, // 13: cosmos.gov.v1beta2.VotingParams.voting_period:type_name -> google.protobuf.Duration + 14, // [14:14] is the sub-list for method output_type + 14, // [14:14] is the sub-list for method input_type + 14, // [14:14] is the sub-list for extension type_name + 14, // [14:14] is the sub-list for extension extendee + 0, // [0:14] is the sub-list for field type_name } func init() { file_cosmos_gov_v1beta2_gov_proto_init() } diff --git a/orm/internal/testpb/bank.pulsar.go b/orm/internal/testpb/bank.pulsar.go index 524ccf76abbf..36cfc62a53a4 100644 --- a/orm/internal/testpb/bank.pulsar.go +++ b/orm/internal/testpb/bank.pulsar.go @@ -2,16 +2,14 @@ package testpb import ( fmt "fmt" - io "io" - reflect "reflect" - sync "sync" - runtime "github.com/cosmos/cosmos-proto/runtime" + _ "github.com/cosmos/cosmos-sdk/api/cosmos/orm/v1alpha1" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoiface "google.golang.org/protobuf/runtime/protoiface" protoimpl "google.golang.org/protobuf/runtime/protoimpl" - - _ "github.com/cosmos/cosmos-sdk/api/cosmos/orm/v1alpha1" + io "io" + reflect "reflect" + sync "sync" ) var ( diff --git a/x/gov/keeper/grpc_query.go b/x/gov/keeper/grpc_query.go index 05ab8c4171ab..f0a605c34bc2 100644 --- a/x/gov/keeper/grpc_query.go +++ b/x/gov/keeper/grpc_query.go @@ -143,7 +143,6 @@ func (q Keeper) Votes(c context.Context, req *v1beta2.QueryVotesRequest) (*v1bet if err := q.cdc.Unmarshal(value, &vote); err != nil { return err } - populateLegacyOption(&vote) votes = append(votes, &vote) return nil diff --git a/x/gov/keeper/vote.go b/x/gov/keeper/vote.go index dd18950dc40a..4180ffec64e7 100644 --- a/x/gov/keeper/vote.go +++ b/x/gov/keeper/vote.go @@ -45,7 +45,6 @@ func (keeper Keeper) AddVote(ctx sdk.Context, proposalID uint64, voterAddr sdk.A // GetAllVotes returns all the votes from the store func (keeper Keeper) GetAllVotes(ctx sdk.Context) (votes v1beta2.Votes) { keeper.IterateAllVotes(ctx, func(vote v1beta2.Vote) bool { - populateLegacyOption(&vote) votes = append(votes, &vote) return false }) @@ -55,7 +54,6 @@ func (keeper Keeper) GetAllVotes(ctx sdk.Context) (votes v1beta2.Votes) { // GetVotes returns all the votes from a proposal func (keeper Keeper) GetVotes(ctx sdk.Context, proposalID uint64) (votes v1beta2.Votes) { keeper.IterateVotes(ctx, proposalID, func(vote v1beta2.Vote) bool { - populateLegacyOption(&vote) votes = append(votes, &vote) return false }) @@ -71,7 +69,6 @@ func (keeper Keeper) GetVote(ctx sdk.Context, proposalID uint64, voterAddr sdk.A } keeper.cdc.MustUnmarshal(bz, &vote) - populateLegacyOption(&vote) return vote, true } @@ -101,7 +98,6 @@ func (keeper Keeper) IterateAllVotes(ctx sdk.Context, cb func(vote v1beta2.Vote) for ; iterator.Valid(); iterator.Next() { var vote v1beta2.Vote keeper.cdc.MustUnmarshal(iterator.Value(), &vote) - populateLegacyOption(&vote) if cb(vote) { break @@ -118,7 +114,6 @@ func (keeper Keeper) IterateVotes(ctx sdk.Context, proposalID uint64, cb func(vo for ; iterator.Valid(); iterator.Next() { var vote v1beta2.Vote keeper.cdc.MustUnmarshal(iterator.Value(), &vote) - populateLegacyOption(&vote) if cb(vote) { break @@ -131,11 +126,3 @@ func (keeper Keeper) deleteVote(ctx sdk.Context, proposalID uint64, voterAddr sd store := ctx.KVStore(keeper.storeKey) store.Delete(types.VoteKey(proposalID, voterAddr)) } - -// populateLegacyOption adds graceful fallback of deprecated `Option` field, in case -// there's only 1 VoteOption. -func populateLegacyOption(vote *v1beta2.Vote) { - if len(vote.Options) == 1 && sdk.MustNewDecFromStr(vote.Options[0].Weight).Equal(sdk.MustNewDecFromStr("1.0")) { - vote.Option = vote.Options[0].Option // nolint - } -} diff --git a/x/gov/types/v1beta2/gov.pb.go b/x/gov/types/v1beta2/gov.pb.go index d55e324483fc..5d837096f3e1 100644 --- a/x/gov/types/v1beta2/gov.pb.go +++ b/x/gov/types/v1beta2/gov.pb.go @@ -659,75 +659,74 @@ func init() { func init() { proto.RegisterFile("cosmos/gov/v1beta2/gov.proto", fileDescriptor_5abf7b8852811c49) } var fileDescriptor_5abf7b8852811c49 = []byte{ - // 1078 bytes of a gzipped FileDescriptorProto + // 1072 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x41, 0x4f, 0x1b, 0x47, - 0x14, 0x66, 0x6d, 0x63, 0xe0, 0x19, 0x9c, 0xed, 0x40, 0x9b, 0x85, 0x10, 0x9b, 0x5a, 0x6d, 0x84, - 0x50, 0xb1, 0x81, 0x4a, 0xa9, 0x94, 0x53, 0x6d, 0xbc, 0x69, 0x16, 0x51, 0xd6, 0xdd, 0xdd, 0x18, + 0x14, 0x66, 0xed, 0xc5, 0xc0, 0x33, 0x38, 0xdb, 0x81, 0x36, 0x0b, 0x21, 0x36, 0xb5, 0xda, 0x08, + 0xa1, 0x62, 0x03, 0x95, 0x52, 0x29, 0xa7, 0xda, 0x78, 0xd3, 0x18, 0x51, 0xd6, 0xdd, 0xdd, 0x18, 0xa5, 0x97, 0xd5, 0x9a, 0x9d, 0xd8, 0xab, 0x7a, 0x77, 0xdc, 0x9d, 0x31, 0xc1, 0x3f, 0xa1, 0xb7, - 0x1c, 0x2b, 0xf5, 0x27, 0xf4, 0x9a, 0x1f, 0x91, 0x53, 0x15, 0x45, 0x8a, 0xd4, 0x5e, 0xdc, 0x16, - 0x6e, 0xfc, 0x8a,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0x31, 0x54, 0x84, 0x5c, 0x2f, 0x24, - 0x3d, 0x42, 0x9d, 0xae, 0xed, 0xb9, 0xbc, 0x60, 0xc6, 0x80, 0x24, 0xa4, 0xb9, 0xe8, 0x31, 0x2c, - 0xb8, 0x31, 0x96, 0x84, 0x42, 0x57, 0x79, 0xff, 0x66, 0x7b, 0x45, 0xe8, 0x56, 0x5d, 0x37, 0xc4, - 0x94, 0x9a, 0x2c, 0xf4, 0x82, 0xb6, 0x31, 0x82, 0xa2, 0xef, 0x20, 0xeb, 0xf8, 0xa4, 0x1f, 0x30, - 0x25, 0xbd, 0x91, 0xde, 0xcc, 0xed, 0xad, 0x26, 0x43, 0x44, 0x07, 0x23, 0xa6, 0xd8, 0x2d, 0xef, - 0x13, 0x2f, 0xa8, 0x65, 0xde, 0x0e, 0x8b, 0x33, 0x86, 0x80, 0x97, 0x3e, 0x64, 0x60, 0xbe, 0x21, - 0xea, 0xdf, 0xde, 0xde, 0x0e, 0xcc, 0xfb, 0x98, 0x52, 0xa7, 0x8d, 0xa9, 0x92, 0xe2, 0x85, 0x56, - 0xca, 0xf1, 0x79, 0x94, 0x93, 0xf3, 0x28, 0x57, 0x83, 0x81, 0x71, 0x85, 0x42, 0x4f, 0x20, 0x4b, - 0x99, 0xc3, 0xfa, 0x54, 0x49, 0xf3, 0xdd, 0x2d, 0xdd, 0xb4, 0xbb, 0x49, 0x03, 0x26, 0x47, 0x1a, - 0x82, 0x81, 0x7e, 0x04, 0xf4, 0xd2, 0x0b, 0x9c, 0xae, 0xcd, 0x9c, 0x6e, 0x77, 0x60, 0x87, 0x98, - 0xf6, 0xbb, 0x4c, 0xc9, 0x6c, 0x48, 0x9b, 0xb9, 0xbd, 0xe2, 0x4d, 0x3a, 0x56, 0x84, 0x33, 0x38, - 0xcc, 0x90, 0x39, 0x75, 0x2c, 0x82, 0xaa, 0x90, 0xa3, 0xfd, 0x96, 0xef, 0x31, 0x3b, 0xb2, 0x9b, - 0x32, 0xcb, 0x75, 0x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() (dAtA []byte, err error) { From d4480efb107930e3b41aa8bad22a62f1a7836d8f Mon Sep 17 00:00:00 2001 From: atheesh Date: Tue, 25 Jan 2022 15:32:08 +0530 Subject: [PATCH 08/11] fix build --- x/gov/keeper/vote.go | 5 ----- x/gov/keeper/vote_test.go | 4 ---- 2 files changed, 9 deletions(-) diff --git a/x/gov/keeper/vote.go b/x/gov/keeper/vote.go index 4180ffec64e7..75eb0108d71b 100644 --- a/x/gov/keeper/vote.go +++ b/x/gov/keeper/vote.go @@ -75,11 +75,6 @@ func (keeper Keeper) GetVote(ctx sdk.Context, proposalID uint64, voterAddr sdk.A // SetVote sets a Vote to the gov store func (keeper Keeper) SetVote(ctx sdk.Context, vote v1beta2.Vote) { - // vote.Option is a deprecated field, we don't set it in state - if vote.Option != v1beta2.OptionEmpty { // nolint - vote.Option = v1beta2.OptionEmpty // nolint - } - store := ctx.KVStore(keeper.storeKey) bz := keeper.cdc.MustMarshal(&vote) addr, err := sdk.AccAddressFromBech32(vote.Voter) diff --git a/x/gov/keeper/vote_test.go b/x/gov/keeper/vote_test.go index 1ca73f64d2e0..73dfab22af06 100644 --- a/x/gov/keeper/vote_test.go +++ b/x/gov/keeper/vote_test.go @@ -40,7 +40,6 @@ func TestVotes(t *testing.T) { require.Equal(t, proposalID, vote.ProposalId) require.True(t, len(vote.Options) == 1) require.Equal(t, v1beta2.OptionAbstain, vote.Options[0].Option) - require.Equal(t, v1beta2.OptionAbstain, vote.Option) // Test change of vote require.NoError(t, app.GovKeeper.AddVote(ctx, proposalID, addrs[0], v1beta2.NewNonSplitVoteOption(v1beta2.OptionYes))) @@ -50,7 +49,6 @@ func TestVotes(t *testing.T) { require.Equal(t, proposalID, vote.ProposalId) require.True(t, len(vote.Options) == 1) require.Equal(t, v1beta2.OptionYes, vote.Options[0].Option) - require.Equal(t, v1beta2.OptionYes, vote.Option) // Test second vote require.NoError(t, app.GovKeeper.AddVote(ctx, proposalID, addrs[1], v1beta2.WeightedVoteOptions{ @@ -72,7 +70,6 @@ func TestVotes(t *testing.T) { require.Equal(t, vote.Options[1].Weight, sdk.NewDecWithPrec(30, 2).String()) require.Equal(t, vote.Options[2].Weight, sdk.NewDecWithPrec(5, 2).String()) require.Equal(t, vote.Options[3].Weight, sdk.NewDecWithPrec(5, 2).String()) - require.Equal(t, v1beta2.OptionEmpty, vote.Option) // Test vote iterator // NOTE order of deposits is determined by the addresses @@ -90,5 +87,4 @@ func TestVotes(t *testing.T) { require.Equal(t, votes[1].Options[1].Weight, sdk.NewDecWithPrec(30, 2).String()) require.Equal(t, votes[1].Options[2].Weight, sdk.NewDecWithPrec(5, 2).String()) require.Equal(t, votes[1].Options[3].Weight, sdk.NewDecWithPrec(5, 2).String()) - require.Equal(t, v1beta2.OptionEmpty, vote.Option) } From f01dfa10fe8b2444cd3432a7a07acd841432369e Mon Sep 17 00:00:00 2001 From: atheesh Date: Tue, 25 Jan 2022 15:58:09 +0530 Subject: [PATCH 09/11] fix tests --- x/gov/keeper/grpc_query_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/x/gov/keeper/grpc_query_test.go b/x/gov/keeper/grpc_query_test.go index 5143cf1ea105..f100a9d4a083 100644 --- a/x/gov/keeper/grpc_query_test.go +++ b/x/gov/keeper/grpc_query_test.go @@ -315,7 +315,7 @@ func (suite *KeeperTestSuite) TestGRPCQueryVote() { Voter: addrs[0].String(), } - expRes = &v1beta2.QueryVoteResponse{Vote: &v1beta2.Vote{ProposalId: proposal.ProposalId, Voter: addrs[0].String(), Option: v1beta2.OptionAbstain, Options: []*v1beta2.WeightedVoteOption{{Option: v1beta2.OptionAbstain, Weight: sdk.MustNewDecFromStr("1.0").String()}}}} + expRes = &v1beta2.QueryVoteResponse{Vote: &v1beta2.Vote{ProposalId: proposal.ProposalId, Voter: addrs[0].String(), Options: []*v1beta2.WeightedVoteOption{{Option: v1beta2.OptionAbstain, Weight: sdk.MustNewDecFromStr("1.0").String()}}}} }, true, }, @@ -412,8 +412,8 @@ func (suite *KeeperTestSuite) TestGRPCQueryVotes() { app.GovKeeper.SetProposal(ctx, proposal) votes = []*v1beta2.Vote{ - {ProposalId: proposal.ProposalId, Voter: addrs[0].String(), Option: v1beta2.OptionAbstain, Options: v1beta2.NewNonSplitVoteOption(v1beta2.OptionAbstain)}, - {ProposalId: proposal.ProposalId, Voter: addrs[1].String(), Option: v1beta2.OptionYes, Options: v1beta2.NewNonSplitVoteOption(v1beta2.OptionYes)}, + {ProposalId: proposal.ProposalId, Voter: addrs[0].String(), Options: v1beta2.NewNonSplitVoteOption(v1beta2.OptionAbstain)}, + {ProposalId: proposal.ProposalId, Voter: addrs[1].String(), Options: v1beta2.NewNonSplitVoteOption(v1beta2.OptionYes)}, } accAddr1, err1 := sdk.AccAddressFromBech32(votes[0].Voter) accAddr2, err2 := sdk.AccAddressFromBech32(votes[1].Voter) From c9e84524baab0094eecdcfaa82b4dd3ce1e27e0c Mon Sep 17 00:00:00 2001 From: atheesh Date: Tue, 25 Jan 2022 16:43:26 +0530 Subject: [PATCH 10/11] fix conflicts --- x/gov/types/v1beta2/tx.pb.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/gov/types/v1beta2/tx.pb.go b/x/gov/types/v1beta2/tx.pb.go index 82d5d9d74872..5067ce8b5ade 100644 --- a/x/gov/types/v1beta2/tx.pb.go +++ b/x/gov/types/v1beta2/tx.pb.go @@ -37,7 +37,7 @@ type MsgSubmitProposal struct { Messages []*types.Any `protobuf:"bytes,1,rep,name=messages,proto3" json:"messages,omitempty"` InitialDeposit []types1.Coin `protobuf:"bytes,2,rep,name=initial_deposit,json=initialDeposit,proto3" json:"initial_deposit"` Proposer string `protobuf:"bytes,3,opt,name=proposer,proto3" json:"proposer,omitempty"` - // metadata is any arbitrary metadata to attached to the proposal. + // metadata is any arbitrary metadata attached to the proposal. Metadata []byte `protobuf:"bytes,4,opt,name=metadata,proto3" json:"metadata,omitempty"` } From 527ce92f0d4d00e4fe8076ad761d04f77047a69b Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Wed, 26 Jan 2022 11:23:46 +0100 Subject: [PATCH 11/11] Add changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9e3fc88c0c9a..5ede04485d5f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -148,6 +148,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (deps) [\#10210](https://github.com/cosmos/cosmos-sdk/pull/10210) Bump Tendermint to [v0.35.0](https://github.com/tendermint/tendermint/releases/tag/v0.35.0). * (deps) [\#10706](https://github.com/cosmos/cosmos-sdk/issues/10706) Bump rosetta-sdk-go to v0.7.2 and rosetta-cli to v0.7.3 * (types/errors) [\#10779](https://github.com/cosmos/cosmos-sdk/pull/10779) Move most functionality in `types/errors` to a standalone `errors` go module, except the `RootCodespace` errors and ABCI response helpers. All functions and types that used to live in `types/errors` are now aliased so this is not a breaking change. +* (gov) [\#10854](https://github.com/cosmos/cosmos-sdk/pull/10854) v1beta2's vote doesn't include the deprecate `option VoteOption` anymore. Instead, it only uses `WeightedVoteOption`. ### Bug Fixes