From 0a509c467465b8f80690dbb509ec5794d0dd3dad Mon Sep 17 00:00:00 2001 From: beer-1 Date: Tue, 24 Sep 2024 13:52:23 +0900 Subject: [PATCH] prepare software upgrade --- app/upgrade.go | 2 +- proto/initia/gov/v1/gov.proto | 70 ++ x/gov/keeper/migrations.go | 24 + x/gov/migrations/v2/convert.go | 66 ++ x/gov/module.go | 41 +- x/gov/types/gov.pb.go | 1320 +++++++++++++++++++++++++++++--- 6 files changed, 1392 insertions(+), 131 deletions(-) create mode 100644 x/gov/keeper/migrations.go create mode 100644 x/gov/migrations/v2/convert.go diff --git a/app/upgrade.go b/app/upgrade.go index 8a4533ed..55a1000a 100644 --- a/app/upgrade.go +++ b/app/upgrade.go @@ -7,7 +7,7 @@ import ( "github.com/cosmos/cosmos-sdk/types/module" ) -const upgradeName = "0.2.2" +const upgradeName = "0.4.11-initation.0" // RegisterUpgradeHandlers returns upgrade handlers func (app *InitiaApp) RegisterUpgradeHandlers(cfg module.Configurator) { diff --git a/proto/initia/gov/v1/gov.proto b/proto/initia/gov/v1/gov.proto index d1087b02..91034c38 100644 --- a/proto/initia/gov/v1/gov.proto +++ b/proto/initia/gov/v1/gov.proto @@ -224,3 +224,73 @@ message Proposal { // Since: cosmos-sdk 0.50 string failed_reason = 18; } + +// LegacyProposal defines the core field members of a governance proposal. +message LegacyProposal { + // id defines the unique id of the proposal. + uint64 id = 1; + + // messages are the arbitrary messages to be executed if the proposal passes. + repeated google.protobuf.Any messages = 2; + + // status defines the proposal status. + cosmos.gov.v1.ProposalStatus status = 3; + + // final_tally_result is the final tally result of the proposal. When + // querying a proposal via gRPC, this field is not populated until the + // proposal's voting period has ended. + cosmos.gov.v1.TallyResult final_tally_result = 4; + + // submit_time is the time of proposal submission. + google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true]; + + // deposit_end_time is the end time for deposition. + google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true]; + + // total_deposit is the total deposit on the proposal. + repeated cosmos.base.v1beta1.Coin total_deposit = 7 [ + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true + ]; + + // voting_start_time is the starting time to vote on a proposal. + google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true]; + + // voting_end_time is the end time of voting on a proposal. + google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true]; + + google.protobuf.Timestamp emergency_start_time = 10 [(gogoproto.stdtime) = true]; + google.protobuf.Timestamp emergency_next_tally_time = 11 [(gogoproto.stdtime) = true]; + + // metadata is any arbitrary metadata attached to the proposal. + // the recommended format of the metadata is to be found here: + // https://docs.cosmos.network/v0.47/modules/gov#proposal-3 + string metadata = 12; + + // title is the title of the proposal + // + // Since: cosmos-sdk 0.47 + string title = 13; + + // summary is a short summary of the proposal + // + // Since: cosmos-sdk 0.47 + string summary = 14; + + // proposer is the address of the proposal sumbitter + // + // Since: cosmos-sdk 0.47 + string proposer = 15 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + + // expedited defines if the proposal is expedited + // + // Since: cosmos-sdk 0.50 + bool expedited = 16; + + bool emergency = 17; + + // failed_reason defines the reason why the proposal failed + // + // Since: cosmos-sdk 0.50 + string failed_reason = 18; +} diff --git a/x/gov/keeper/migrations.go b/x/gov/keeper/migrations.go new file mode 100644 index 00000000..69c43f76 --- /dev/null +++ b/x/gov/keeper/migrations.go @@ -0,0 +1,24 @@ +package keeper + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + + v2 "github.com/initia-labs/initia/x/gov/migrations/v2" +) + +// Migrator is a struct for handling in-place store migrations. +type Migrator struct { + keeper *Keeper +} + +// NewMigrator returns a new Migrator. +func NewMigrator(keeper *Keeper) Migrator { + return Migrator{ + keeper: keeper, + } +} + +// Migrate1to2 migrates from version 1 to 2. +func (m Migrator) Migrate1to2(ctx sdk.Context) error { + return v2.MigrateStore(ctx, m.keeper.Proposals, m.keeper.storeService, m.keeper.cdc) +} diff --git a/x/gov/migrations/v2/convert.go b/x/gov/migrations/v2/convert.go new file mode 100644 index 00000000..60620924 --- /dev/null +++ b/x/gov/migrations/v2/convert.go @@ -0,0 +1,66 @@ +package v1 + +import ( + "context" + "fmt" + + "cosmossdk.io/collections" + corestoretypes "cosmossdk.io/core/store" + + "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/x/gov/types" + customtypes "github.com/initia-labs/initia/x/gov/types" +) + +const ( + ModuleName = "gov" +) + +func ConvertLegacyProposalToProposal(proposal customtypes.LegacyProposal) customtypes.Proposal { + return customtypes.Proposal{ + Id: proposal.Id, + Messages: proposal.Messages, + EmergencyStartTime: proposal.EmergencyStartTime, + EmergencyNextTallyTime: proposal.EmergencyNextTallyTime, + Metadata: proposal.Metadata, + Title: proposal.Title, + Summary: proposal.Summary, + Proposer: proposal.Proposer, + Expedited: proposal.Expedited, + Emergency: proposal.Emergency, + FailedReason: proposal.FailedReason, + Status: proposal.Status, + SubmitTime: proposal.SubmitTime, + DepositEndTime: proposal.DepositEndTime, + TotalDeposit: proposal.TotalDeposit, + VotingStartTime: proposal.VotingStartTime, + VotingEndTime: proposal.VotingEndTime, + + // Convert the final tally result + FinalTallyResult: customtypes.TallyResult{ + TallyHeight: 0, + TotalStakingPower: "0", + TotalVestingPower: "0", + V1TallyResult: proposal.FinalTallyResult, + }, + } +} + +func MigrateStore( + ctx context.Context, + proposals collections.Map[uint64, customtypes.Proposal], + storeService corestoretypes.KVStoreService, cdc codec.BinaryCodec, +) error { + sb := collections.NewSchemaBuilder(storeService) + legacyProposals := collections.NewMap(sb, types.ProposalsKeyPrefix, "proposals", collections.Uint64Key, codec.CollValue[customtypes.LegacyProposal](cdc)) + _, err := sb.Build() + if err != nil { + return err + } + + fmt.Println("SIBONG") + return legacyProposals.Walk(ctx, nil, func(pid uint64, lp customtypes.LegacyProposal) (bool, error) { + p := ConvertLegacyProposalToProposal(lp) + return false, proposals.Set(ctx, pid, p) + }) +} diff --git a/x/gov/module.go b/x/gov/module.go index cb5ebf59..7045fe49 100644 --- a/x/gov/module.go +++ b/x/gov/module.go @@ -29,7 +29,7 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govclient "github.com/cosmos/cosmos-sdk/x/gov/client" "github.com/cosmos/cosmos-sdk/x/gov/client/cli" - "github.com/cosmos/cosmos-sdk/x/gov/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" v1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" @@ -39,7 +39,7 @@ import ( customcli "github.com/initia-labs/initia/x/gov/client/cli" ) -const ConsensusVersion = 1 +const ConsensusVersion = 2 var ( _ module.AppModuleBasic = AppModuleBasic{} @@ -67,7 +67,7 @@ func NewAppModuleBasic(cdc codec.Codec, legacyProposalHandlers ...govclient.Prop // Name returns the gov module's name. func (AppModuleBasic) Name() string { - return types.ModuleName + return govtypes.ModuleName } // RegisterLegacyAminoCodec registers the gov module's types for the given codec. @@ -87,7 +87,7 @@ func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { func (b AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncodingConfig, bz json.RawMessage) error { var data customtypes.GenesisState if err := cdc.UnmarshalJSON(bz, &data); err != nil { - return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) + return fmt.Errorf("failed to unmarshal %s genesis state: %w", govtypes.ModuleName, err) } return customtypes.ValidateGenesis(&data, b.cdc.InterfaceRegistry().SigningContext().AddressCodec()) @@ -136,16 +136,16 @@ type AppModule struct { AppModuleBasic keeper *keeper.Keeper - accountKeeper types.AccountKeeper - bankKeeper types.BankKeeper + accountKeeper govtypes.AccountKeeper + bankKeeper govtypes.BankKeeper } // NewAppModule creates a new AppModule object func NewAppModule( cdc codec.Codec, keeper *keeper.Keeper, - ak types.AccountKeeper, - bk types.BankKeeper, + ak govtypes.AccountKeeper, + bk govtypes.BankKeeper, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, @@ -177,10 +177,10 @@ type ModuleInputs struct { ModuleKey depinject.OwnModuleKey MsgServiceRouter baseapp.MessageRouter - AccountKeeper types.AccountKeeper - BankKeeper types.BankKeeper + AccountKeeper govtypes.AccountKeeper + BankKeeper govtypes.BankKeeper StakingKeeper customtypes.StakingKeeper - DistributionKeeper types.DistributionKeeper + DistributionKeeper govtypes.DistributionKeeper VestingKeeper customtypes.VestingKeeper } @@ -193,13 +193,13 @@ type ModuleOutputs struct { } func ProvideModule(in ModuleInputs) ModuleOutputs { - defaultConfig := types.DefaultConfig() + defaultConfig := govtypes.DefaultConfig() if in.Config.MaxMetadataLen != 0 { defaultConfig.MaxMetadataLen = in.Config.MaxMetadataLen } // default to governance authority if not provided - authority := authtypes.NewModuleAddress(types.ModuleName) + authority := authtypes.NewModuleAddress(govtypes.ModuleName) if in.Config.Authority != "" { authority = authtypes.NewModuleAddressOrBech32Address(in.Config.Authority) } @@ -218,7 +218,7 @@ func ProvideModule(in ModuleInputs) ModuleOutputs { ) m := NewAppModule(in.Cdc, k, in.AccountKeeper, in.BankKeeper) - hr := v1beta1.HandlerRoute{Handler: v1beta1.ProposalHandler, RouteKey: types.RouterKey} + hr := v1beta1.HandlerRoute{Handler: v1beta1.ProposalHandler, RouteKey: govtypes.RouterKey} return ModuleOutputs{Module: m, Keeper: k, HandlerRoute: hr} } @@ -241,7 +241,7 @@ func InvokeAddRoutes(keeper *keeper.Keeper, routes []v1beta1.HandlerRoute) { keeper.SetLegacyRouter(router) } -func InvokeSetHooks(keeper *keeper.Keeper, govHooks map[string]types.GovHooksWrapper) error { +func InvokeSetHooks(keeper *keeper.Keeper, govHooks map[string]govtypes.GovHooksWrapper) error { if keeper == nil || govHooks == nil { return nil } @@ -252,7 +252,7 @@ func InvokeSetHooks(keeper *keeper.Keeper, govHooks map[string]types.GovHooksWra order := modNames sort.Strings(order) - var multiHooks types.MultiGovHooks + var multiHooks govtypes.MultiGovHooks for _, modName := range order { hook, ok := govHooks[modName] if !ok { @@ -267,7 +267,7 @@ func InvokeSetHooks(keeper *keeper.Keeper, govHooks map[string]types.GovHooksWra // Name returns the gov module's name. func (AppModule) Name() string { - return types.ModuleName + return govtypes.ModuleName } // RegisterInvariants registers module invariants @@ -278,7 +278,7 @@ func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry) { // RegisterServices registers module services. func (am AppModule) RegisterServices(cfg module.Configurator) { msgServer := keeper.NewMsgServerImpl(am.keeper) - v1beta1.RegisterMsgServer(cfg.MsgServer(), keeper.NewLegacyMsgServerImpl(am.accountKeeper.GetModuleAddress(types.ModuleName).String(), msgServer)) + v1beta1.RegisterMsgServer(cfg.MsgServer(), keeper.NewLegacyMsgServerImpl(am.accountKeeper.GetModuleAddress(govtypes.ModuleName).String(), msgServer)) v1.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) legacyQueryServer := keeper.NewLegacyQueryServer(am.keeper) @@ -287,6 +287,11 @@ func (am AppModule) RegisterServices(cfg module.Configurator) { customtypes.RegisterMsgServer(cfg.MsgServer(), keeper.NewCustomMsgServerImpl(am.keeper)) customtypes.RegisterQueryServer(cfg.QueryServer(), keeper.NewCustomQueryServer(am.keeper)) + + m := keeper.NewMigrator(am.keeper) + if err := cfg.RegisterMigration(govtypes.ModuleName, 1, m.Migrate1to2); err != nil { + panic(fmt.Sprintf("failed to migrate x/gov from version 1 to 2: %v", err)) + } } // InitGenesis performs genesis initialization for the gov module. It returns diff --git a/x/gov/types/gov.pb.go b/x/gov/types/gov.pb.go index cb1ceab1..df0a3c48 100644 --- a/x/gov/types/gov.pb.go +++ b/x/gov/types/gov.pb.go @@ -611,96 +611,309 @@ func (m *Proposal) GetFailedReason() string { return "" } +// LegacyProposal defines the core field members of a governance proposal. +type LegacyProposal struct { + // id defines the unique id of the proposal. + Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + // messages are the arbitrary messages to be executed if the proposal passes. + Messages []*types1.Any `protobuf:"bytes,2,rep,name=messages,proto3" json:"messages,omitempty"` + // status defines the proposal status. + Status v1.ProposalStatus `protobuf:"varint,3,opt,name=status,proto3,enum=cosmos.gov.v1.ProposalStatus" json:"status,omitempty"` + // final_tally_result is the final tally result of the proposal. When + // querying a proposal via gRPC, this field is not populated until the + // proposal's voting period has ended. + FinalTallyResult *v1.TallyResult `protobuf:"bytes,4,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result,omitempty"` + // submit_time is the time of proposal submission. + SubmitTime *time.Time `protobuf:"bytes,5,opt,name=submit_time,json=submitTime,proto3,stdtime" json:"submit_time,omitempty"` + // deposit_end_time is the end time for deposition. + DepositEndTime *time.Time `protobuf:"bytes,6,opt,name=deposit_end_time,json=depositEndTime,proto3,stdtime" json:"deposit_end_time,omitempty"` + // total_deposit is the total deposit on the proposal. + TotalDeposit []types.Coin `protobuf:"bytes,7,rep,name=total_deposit,json=totalDeposit,proto3" json:"total_deposit"` + // voting_start_time is the starting time to vote on a proposal. + VotingStartTime *time.Time `protobuf:"bytes,8,opt,name=voting_start_time,json=votingStartTime,proto3,stdtime" json:"voting_start_time,omitempty"` + // voting_end_time is the end time of voting on a proposal. + VotingEndTime *time.Time `protobuf:"bytes,9,opt,name=voting_end_time,json=votingEndTime,proto3,stdtime" json:"voting_end_time,omitempty"` + EmergencyStartTime *time.Time `protobuf:"bytes,10,opt,name=emergency_start_time,json=emergencyStartTime,proto3,stdtime" json:"emergency_start_time,omitempty"` + EmergencyNextTallyTime *time.Time `protobuf:"bytes,11,opt,name=emergency_next_tally_time,json=emergencyNextTallyTime,proto3,stdtime" json:"emergency_next_tally_time,omitempty"` + // metadata is any arbitrary metadata attached to the proposal. + // the recommended format of the metadata is to be found here: + // https://docs.cosmos.network/v0.47/modules/gov#proposal-3 + Metadata string `protobuf:"bytes,12,opt,name=metadata,proto3" json:"metadata,omitempty"` + // title is the title of the proposal + // + // Since: cosmos-sdk 0.47 + Title string `protobuf:"bytes,13,opt,name=title,proto3" json:"title,omitempty"` + // summary is a short summary of the proposal + // + // Since: cosmos-sdk 0.47 + Summary string `protobuf:"bytes,14,opt,name=summary,proto3" json:"summary,omitempty"` + // proposer is the address of the proposal sumbitter + // + // Since: cosmos-sdk 0.47 + Proposer string `protobuf:"bytes,15,opt,name=proposer,proto3" json:"proposer,omitempty"` + // expedited defines if the proposal is expedited + // + // Since: cosmos-sdk 0.50 + Expedited bool `protobuf:"varint,16,opt,name=expedited,proto3" json:"expedited,omitempty"` + Emergency bool `protobuf:"varint,17,opt,name=emergency,proto3" json:"emergency,omitempty"` + // failed_reason defines the reason why the proposal failed + // + // Since: cosmos-sdk 0.50 + FailedReason string `protobuf:"bytes,18,opt,name=failed_reason,json=failedReason,proto3" json:"failed_reason,omitempty"` +} + +func (m *LegacyProposal) Reset() { *m = LegacyProposal{} } +func (m *LegacyProposal) String() string { return proto.CompactTextString(m) } +func (*LegacyProposal) ProtoMessage() {} +func (*LegacyProposal) Descriptor() ([]byte, []int) { + return fileDescriptor_6adfe7a550f5e4ec, []int{4} +} +func (m *LegacyProposal) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *LegacyProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_LegacyProposal.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *LegacyProposal) XXX_Merge(src proto.Message) { + xxx_messageInfo_LegacyProposal.Merge(m, src) +} +func (m *LegacyProposal) XXX_Size() int { + return m.Size() +} +func (m *LegacyProposal) XXX_DiscardUnknown() { + xxx_messageInfo_LegacyProposal.DiscardUnknown(m) +} + +var xxx_messageInfo_LegacyProposal proto.InternalMessageInfo + +func (m *LegacyProposal) GetId() uint64 { + if m != nil { + return m.Id + } + return 0 +} + +func (m *LegacyProposal) GetMessages() []*types1.Any { + if m != nil { + return m.Messages + } + return nil +} + +func (m *LegacyProposal) GetStatus() v1.ProposalStatus { + if m != nil { + return m.Status + } + return v1.ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED +} + +func (m *LegacyProposal) GetFinalTallyResult() *v1.TallyResult { + if m != nil { + return m.FinalTallyResult + } + return nil +} + +func (m *LegacyProposal) GetSubmitTime() *time.Time { + if m != nil { + return m.SubmitTime + } + return nil +} + +func (m *LegacyProposal) GetDepositEndTime() *time.Time { + if m != nil { + return m.DepositEndTime + } + return nil +} + +func (m *LegacyProposal) GetTotalDeposit() []types.Coin { + if m != nil { + return m.TotalDeposit + } + return nil +} + +func (m *LegacyProposal) GetVotingStartTime() *time.Time { + if m != nil { + return m.VotingStartTime + } + return nil +} + +func (m *LegacyProposal) GetVotingEndTime() *time.Time { + if m != nil { + return m.VotingEndTime + } + return nil +} + +func (m *LegacyProposal) GetEmergencyStartTime() *time.Time { + if m != nil { + return m.EmergencyStartTime + } + return nil +} + +func (m *LegacyProposal) GetEmergencyNextTallyTime() *time.Time { + if m != nil { + return m.EmergencyNextTallyTime + } + return nil +} + +func (m *LegacyProposal) GetMetadata() string { + if m != nil { + return m.Metadata + } + return "" +} + +func (m *LegacyProposal) GetTitle() string { + if m != nil { + return m.Title + } + return "" +} + +func (m *LegacyProposal) GetSummary() string { + if m != nil { + return m.Summary + } + return "" +} + +func (m *LegacyProposal) GetProposer() string { + if m != nil { + return m.Proposer + } + return "" +} + +func (m *LegacyProposal) GetExpedited() bool { + if m != nil { + return m.Expedited + } + return false +} + +func (m *LegacyProposal) GetEmergency() bool { + if m != nil { + return m.Emergency + } + return false +} + +func (m *LegacyProposal) GetFailedReason() string { + if m != nil { + return m.FailedReason + } + return "" +} + func init() { proto.RegisterType((*Params)(nil), "initia.gov.v1.Params") proto.RegisterType((*Vesting)(nil), "initia.gov.v1.Vesting") proto.RegisterType((*TallyResult)(nil), "initia.gov.v1.TallyResult") proto.RegisterType((*Proposal)(nil), "initia.gov.v1.Proposal") + proto.RegisterType((*LegacyProposal)(nil), "initia.gov.v1.LegacyProposal") } func init() { proto.RegisterFile("initia/gov/v1/gov.proto", fileDescriptor_6adfe7a550f5e4ec) } var fileDescriptor_6adfe7a550f5e4ec = []byte{ - // 1257 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x56, 0x4f, 0x6f, 0x1b, 0x45, - 0x14, 0xcf, 0x26, 0x6d, 0x62, 0x3f, 0xff, 0x49, 0x32, 0x4d, 0x9b, 0x4d, 0x44, 0xed, 0x10, 0x10, - 0x0a, 0x15, 0xb5, 0x49, 0xa1, 0x1c, 0x8a, 0x04, 0x8a, 0x9b, 0xa2, 0xa6, 0xa2, 0x55, 0xd8, 0x54, - 0x11, 0xa2, 0xc0, 0x32, 0xf6, 0x4e, 0x9c, 0x11, 0xbb, 0x3b, 0x66, 0x67, 0xd6, 0x75, 0xbe, 0x02, - 0xa7, 0x1e, 0x7b, 0xec, 0x91, 0x63, 0x0f, 0xfd, 0x10, 0x3d, 0x56, 0x3d, 0x71, 0x6a, 0x51, 0x73, - 0x28, 0x1f, 0x00, 0x71, 0x46, 0xf3, 0x6f, 0xd7, 0x36, 0x56, 0x15, 0x5f, 0x12, 0xcf, 0x7b, 0xbf, - 0xdf, 0x6f, 0xde, 0x7b, 0xf3, 0x66, 0xde, 0xc2, 0x2a, 0x8d, 0xa9, 0xa0, 0xb8, 0xd9, 0x65, 0xfd, - 0x66, 0x7f, 0x5b, 0xfe, 0x6b, 0xf4, 0x12, 0x26, 0x18, 0xaa, 0x68, 0x47, 0x43, 0x5a, 0xfa, 0xdb, - 0xeb, 0xcb, 0x38, 0xa2, 0x31, 0x6b, 0xaa, 0xbf, 0x1a, 0xb1, 0x5e, 0xeb, 0x30, 0x1e, 0x31, 0xde, - 0x6c, 0x63, 0x4e, 0x9a, 0xfd, 0xed, 0x36, 0x11, 0x78, 0xbb, 0xd9, 0x61, 0x34, 0x36, 0xfe, 0x55, - 0xe3, 0x1f, 0x97,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e, 0x7c, 0x76, 0x15, 0x4c, 0xae, 0xbb, 0xa4, 0xe3, - 0x19, 0x2f, 0xfa, 0x04, 0x8a, 0xe2, 0x38, 0x21, 0xfc, 0x98, 0x85, 0x81, 0x7b, 0x7e, 0x22, 0x34, - 0x07, 0xa0, 0xeb, 0x50, 0xed, 0x13, 0xc1, 0xfc, 0x9c, 0x32, 0x3f, 0x91, 0x52, 0x91, 0xa8, 0xfb, - 0x19, 0x6d, 0x0f, 0xd6, 0x64, 0xe9, 0x75, 0xcf, 0x85, 0x59, 0xed, 0x54, 0x1e, 0xee, 0xc2, 0x44, - 0x85, 0x4b, 0x11, 0x8d, 0xf7, 0x34, 0xde, 0xd4, 0xc9, 0x93, 0x68, 0xd4, 0x82, 0x8b, 0xbd, 0x84, - 0xf5, 0x18, 0xc7, 0xa1, 0xdf, 0xc1, 0x71, 0x87, 0x84, 0x46, 0xa6, 0x30, 0x51, 0xe6, 0x82, 0x05, - 0xdf, 0x54, 0x58, 0xad, 0x71, 0x07, 0x56, 0xc6, 0x35, 0x02, 0xc2, 0x85, 0x5b, 0x54, 0x12, 0xee, - 0xcb, 0x67, 0x57, 0x57, 0x8c, 0xc4, 0x4e, 0x10, 0x24, 0x84, 0xf3, 0x03, 0x91, 0xd0, 0xb8, 0xeb, - 0xa1, 0x51, 0xb1, 0x5d, 0xc2, 0x05, 0xfa, 0x05, 0x56, 0xc9, 0xa0, 0x47, 0x02, 0x2a, 0x48, 0xe0, - 0x8f, 0x1e, 0x20, 0x4c, 0x79, 0x80, 0x17, 0x33, 0xa1, 0xc3, 0xe1, 0x93, 0xfc, 0x1a, 0x2e, 0xe4, - 0x3b, 0xe4, 0x85, 0x2f, 0x4d, 0xcc, 0x17, 0x65, 0xd0, 0xbc, 0xfa, 0xdf, 0x43, 0xae, 0xec, 0x0f, - 0x5f, 0x81, 0xf2, 0x14, 0x57, 0x20, 0x8f, 0xe1, 0x6e, 0x7e, 0x17, 0xb6, 0x60, 0xa9, 0x9d, 0x26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1e, 0x51, 0xc2, 0xa5, 0x33, 0x0a, 0xe7, 0x8f, 0xdf, 0x3d, 0x32, - 0x10, 0xaa, 0x49, 0x94, 0xf8, 0xba, 0x6c, 0x70, 0x81, 0x03, 0x2c, 0xb0, 0x5b, 0x56, 0xaf, 0x43, - 0xb6, 0x46, 0x2b, 0x70, 0x5e, 0x50, 0x11, 0x12, 0x35, 0x9a, 0x8a, 0x9e, 0x5e, 0x20, 0x17, 0x16, - 0x78, 0x1a, 0x45, 0x38, 0x39, 0x51, 0xb3, 0xa7, 0xe8, 0xd9, 0x25, 0xfa, 0x1c, 0x0a, 0x7a, 0x4c, - 0x91, 0x44, 0x8d, 0x98, 0x77, 0x7d, 0x12, 0x64, 0x48, 0xf4, 0x1e, 0x14, 0xb3, 0x11, 0xa9, 0x06, - 0x4e, 0xc1, 0xcb, 0x0d, 0xca, 0x6b, 0x23, 0x77, 0x97, 0x8d, 0xd7, 0x1a, 0xd0, 0x07, 0x50, 0x39, - 0xc2, 0x34, 0x24, 0x81, 0x9f, 0x10, 0xcc, 0x59, 0xec, 0x22, 0x15, 0x51, 0x59, 0x1b, 0x3d, 0x65, - 0x6b, 0xdd, 0x7c, 0xfe, 0xa6, 0xe6, 0xbc, 0x78, 0x53, 0x73, 0xfe, 0x7a, 0x53, 0x73, 0x1e, 0x9d, - 0xd6, 0x66, 0x5e, 0x9c, 0xd6, 0x66, 0xfe, 0x3c, 0xad, 0xcd, 0xfc, 0xf0, 0x71, 0x97, 0x8a, 0xe3, - 0xb4, 0xdd, 0xe8, 0xb0, 0xa8, 0xa9, 0xaf, 0xd8, 0xd5, 0x10, 0xb7, 0xb9, 0xf9, 0xdd, 0x1c, 0xa8, - 0x6f, 0x74, 0x71, 0xd2, 0x23, 0xbc, 0x3d, 0xaf, 0x2a, 0xfb, 0xd9, 0x7f, 0x01, 0x00, 0x00, 0xff, - 0xff, 0x58, 0xb1, 0xcc, 0x82, 0x19, 0x0c, 0x00, 0x00, + // 1292 bytes of a gzipped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x35, 0x29, 0xdf, 0x63, 0x82, 0x7c, 0xad, 0xcb, 0x6c, 0x13, 0xce, 0x2b, 0x64, 0x96, 0xf7, 0xac, + 0x7f, 0x12, 0x22, 0xad, 0xdd, 0x9a, 0x32, 0x5b, 0x91, 0xa0, 0x1d, 0x83, 0xb1, 0xfd, 0xa1, 0x11, + 0xe8, 0x7d, 0xa8, 0xe5, 0x97, 0xc9, 0xfa, 0x72, 0xe7, 0x94, 0x4d, 0xc5, 0x5e, 0xb5, 0x47, 0x04, + 0x43, 0x57, 0x60, 0x61, 0x2c, 0x44, 0x53, 0x1b, 0xf3, 0x13, 0x73, 0x35, 0x97, 0x77, 0xb5, 0xae, + 0x0b, 0x99, 0xa8, 0x88, 0x24, 0x3d, 0x12, 0x77, 0x47, 0x87, 0x12, 0x75, 0xf7, 0x44, 0x89, 0xb2, + 0x14, 0x63, 0x89, 0xea, 0x80, 0x9b, 0x33, 0x0b, 0x1c, 0x86, 0x23, 0x9f, 0xc6, 0x82, 0x24, 0x03, + 0x1c, 0xba, 0xdf, 0x9d, 0xb0, 0x4c, 0xce, 0x65, 0x4c, 0x77, 0x24, 0xd1, 0xb6, 0xe1, 0x41, 0x9f, + 0xc1, 0x52, 0xc8, 0xee, 0xe5, 0x15, 0xe2, 0xef, 0xa7, 0x71, 0x57, 0x12, 0x70, 0xf7, 0xfb, 0xd5, + 0x99, 0xf5, 0x92, 0x77, 0x36, 0x64, 0xf7, 0xb2, 0xaa, 0xf8, 0xca, 0x2a, 0xd1, 0xe7, 0x50, 0x18, + 0x10, 0x2e, 0x0b, 0xce, 0xfd, 0x41, 0xb9, 0x72, 0xae, 0x79, 0x68, 0x39, 0x34, 0xf7, 0xb4, 0x56, + 0x05, 0xa9, 0x7c, 0x98, 0xf2, 0xac, 0xc5, 0x95, 0xa5, 0x07, 0x0f, 0x1b, 0x53, 0x7f, 0x3e, 0x6c, + 0x38, 0xbf, 0xbc, 0x7e, 0x74, 0x01, 0xe4, 0x2e, 0xd0, 0xd3, 0x76, 0x6d, 0x08, 0x05, 0x63, 0x87, + 0x1a, 0x50, 0x8e, 0x58, 0x90, 0x86, 0xc4, 0xc7, 0x41, 0x90, 0xb8, 0x8e, 0x7c, 0x0c, 0x0f, 0xb4, + 0x48, 0x36, 0xd8, 0x18, 0x20, 0xc6, 0x11, 0x51, 0xb3, 0x34, 0x03, 0xdc, 0xc6, 0x11, 0x41, 0xff, + 0x87, 0x4a, 0x37, 0x21, 0x58, 0xb0, 0x44, 0x53, 0xcc, 0x28, 0x44, 0xd9, 0xc8, 0x24, 0xc7, 0x95, + 0xa2, 0x75, 0x64, 0xed, 0x2f, 0x07, 0xca, 0x2a, 0x33, 0x1e, 0xe1, 0x69, 0x28, 0xa4, 0xb1, 0xce, + 0xf8, 0x01, 0xa1, 0xbd, 0x03, 0xa1, 0xee, 0x3f, 0xe5, 0x95, 0x95, 0xec, 0xba, 0x12, 0xa1, 0x2f, + 0xe0, 0x8c, 0x60, 0x02, 0x87, 0x3e, 0x17, 0xf8, 0x27, 0xd5, 0xc1, 0xec, 0x1e, 0x49, 0xb4, 0x23, + 0x87, 0xca, 0x66, 0x3b, 0x16, 0xde, 0x82, 0x82, 0xee, 0x6a, 0xe4, 0x8e, 0x04, 0xe6, 0xf6, 0x26, + 0x2d, 0xc6, 0x7e, 0xe6, 0x2d, 0xf6, 0x26, 0x39, 0xda, 0xbe, 0x0d, 0x73, 0x83, 0x0d, 0x53, 0x17, + 0x89, 0xf2, 0x5a, 0x4d, 0xed, 0xf2, 0xa5, 0x15, 0x5b, 0x72, 0xe6, 0x29, 0xc6, 0xe2, 0xf2, 0xaa, + 0x83, 0x8d, 0xb1, 0xe3, 0xda, 0xf3, 0x02, 0x14, 0x6d, 0xe7, 0xa0, 0x1a, 0x4c, 0xd3, 0xc0, 0x44, + 0x3a, 0x4d, 0x03, 0xf4, 0x31, 0x14, 0x23, 0xc2, 0x39, 0xee, 0x11, 0xee, 0x4e, 0xab, 0x62, 0x5e, + 0x7c, 0xa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f9, 0x27, + 0x00, 0x00, 0xff, 0xff, 0xda, 0x8d, 0xad, 0x29, 0xf5, 0x0f, 0x00, 0x00, } func (this *Params) Equal(that interface{}) bool { @@ -1338,46 +1551,240 @@ func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func encodeVarintGov(dAtA []byte, offset int, v uint64) int { - offset -= sovGov(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ +func (m *LegacyProposal) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err } - dAtA[offset] = uint8(v) - return base + return dAtA[:n], nil } -func (m *Params) Size() (n int) { - if m == nil { - return 0 - } + +func (m *LegacyProposal) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *LegacyProposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i var l int _ = l - if len(m.MinDeposit) > 0 { - for _, e := range m.MinDeposit { - l = e.Size() - n += 1 + l + sovGov(uint64(l)) - } + if len(m.FailedReason) > 0 { + i -= len(m.FailedReason) + copy(dAtA[i:], m.FailedReason) + i = encodeVarintGov(dAtA, i, uint64(len(m.FailedReason))) + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x92 } - l = github_com_cosmos_gogoproto_types.SizeOfStdDuration(m.MaxDepositPeriod) - n += 1 + l + sovGov(uint64(l)) - l = github_com_cosmos_gogoproto_types.SizeOfStdDuration(m.VotingPeriod) - n += 1 + l + sovGov(uint64(l)) - l = len(m.Quorum) - if l > 0 { - n += 1 + l + sovGov(uint64(l)) + if m.Emergency { + i-- + if m.Emergency { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x88 } - l = len(m.Threshold) - if l > 0 { - n += 1 + l + sovGov(uint64(l)) + if m.Expedited { + i-- + if m.Expedited { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x1 + i-- + dAtA[i] = 0x80 } - l = len(m.VetoThreshold) - if l > 0 { - n += 1 + l + sovGov(uint64(l)) + if len(m.Proposer) > 0 { + i -= len(m.Proposer) + copy(dAtA[i:], m.Proposer) + i = encodeVarintGov(dAtA, i, uint64(len(m.Proposer))) + i-- + dAtA[i] = 0x7a } - l = len(m.MinInitialDepositRatio) + if len(m.Summary) > 0 { + i -= len(m.Summary) + copy(dAtA[i:], m.Summary) + i = encodeVarintGov(dAtA, i, uint64(len(m.Summary))) + i-- + dAtA[i] = 0x72 + } + if len(m.Title) > 0 { + i -= len(m.Title) + copy(dAtA[i:], m.Title) + i = encodeVarintGov(dAtA, i, uint64(len(m.Title))) + i-- + dAtA[i] = 0x6a + } + if len(m.Metadata) > 0 { + i -= len(m.Metadata) + copy(dAtA[i:], m.Metadata) + i = encodeVarintGov(dAtA, i, uint64(len(m.Metadata))) + i-- + dAtA[i] = 0x62 + } + if m.EmergencyNextTallyTime != nil { + n14, err14 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.EmergencyNextTallyTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.EmergencyNextTallyTime):]) + if err14 != nil { + return 0, err14 + } + i -= n14 + i = encodeVarintGov(dAtA, i, uint64(n14)) + i-- + dAtA[i] = 0x5a + } + if m.EmergencyStartTime != nil { + n15, err15 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.EmergencyStartTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.EmergencyStartTime):]) + if err15 != nil { + return 0, err15 + } + i -= n15 + i = encodeVarintGov(dAtA, i, uint64(n15)) + i-- + dAtA[i] = 0x52 + } + if m.VotingEndTime != nil { + n16, err16 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.VotingEndTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.VotingEndTime):]) + if err16 != nil { + return 0, err16 + } + i -= n16 + i = encodeVarintGov(dAtA, i, uint64(n16)) + i-- + dAtA[i] = 0x4a + } + if m.VotingStartTime != nil { + n17, err17 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.VotingStartTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.VotingStartTime):]) + if err17 != nil { + return 0, err17 + } + i -= n17 + i = encodeVarintGov(dAtA, i, uint64(n17)) + i-- + dAtA[i] = 0x42 + } + if len(m.TotalDeposit) > 0 { + for iNdEx := len(m.TotalDeposit) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.TotalDeposit[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGov(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x3a + } + } + if m.DepositEndTime != nil { + n18, err18 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.DepositEndTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.DepositEndTime):]) + if err18 != nil { + return 0, err18 + } + i -= n18 + i = encodeVarintGov(dAtA, i, uint64(n18)) + i-- + dAtA[i] = 0x32 + } + if m.SubmitTime != nil { + n19, err19 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(*m.SubmitTime, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.SubmitTime):]) + if err19 != nil { + return 0, err19 + } + i -= n19 + i = encodeVarintGov(dAtA, i, uint64(n19)) + i-- + dAtA[i] = 0x2a + } + if m.FinalTallyResult != nil { + { + size, err := m.FinalTallyResult.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGov(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + } + if m.Status != 0 { + i = encodeVarintGov(dAtA, i, uint64(m.Status)) + i-- + dAtA[i] = 0x18 + } + if len(m.Messages) > 0 { + for iNdEx := len(m.Messages) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Messages[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintGov(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + } + if m.Id != 0 { + i = encodeVarintGov(dAtA, i, uint64(m.Id)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func encodeVarintGov(dAtA []byte, offset int, v uint64) int { + offset -= sovGov(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *Params) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.MinDeposit) > 0 { + for _, e := range m.MinDeposit { + l = e.Size() + n += 1 + l + sovGov(uint64(l)) + } + } + l = github_com_cosmos_gogoproto_types.SizeOfStdDuration(m.MaxDepositPeriod) + n += 1 + l + sovGov(uint64(l)) + l = github_com_cosmos_gogoproto_types.SizeOfStdDuration(m.VotingPeriod) + n += 1 + l + sovGov(uint64(l)) + l = len(m.Quorum) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.Threshold) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.VetoThreshold) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.MinInitialDepositRatio) if l > 0 { n += 1 + l + sovGov(uint64(l)) } @@ -1559,6 +1966,87 @@ func (m *Proposal) Size() (n int) { return n } +func (m *LegacyProposal) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Id != 0 { + n += 1 + sovGov(uint64(m.Id)) + } + if len(m.Messages) > 0 { + for _, e := range m.Messages { + l = e.Size() + n += 1 + l + sovGov(uint64(l)) + } + } + if m.Status != 0 { + n += 1 + sovGov(uint64(m.Status)) + } + if m.FinalTallyResult != nil { + l = m.FinalTallyResult.Size() + n += 1 + l + sovGov(uint64(l)) + } + if m.SubmitTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.SubmitTime) + n += 1 + l + sovGov(uint64(l)) + } + if m.DepositEndTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.DepositEndTime) + n += 1 + l + sovGov(uint64(l)) + } + if len(m.TotalDeposit) > 0 { + for _, e := range m.TotalDeposit { + l = e.Size() + n += 1 + l + sovGov(uint64(l)) + } + } + if m.VotingStartTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.VotingStartTime) + n += 1 + l + sovGov(uint64(l)) + } + if m.VotingEndTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.VotingEndTime) + n += 1 + l + sovGov(uint64(l)) + } + if m.EmergencyStartTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.EmergencyStartTime) + n += 1 + l + sovGov(uint64(l)) + } + if m.EmergencyNextTallyTime != nil { + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(*m.EmergencyNextTallyTime) + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.Metadata) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.Title) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.Summary) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + l = len(m.Proposer) + if l > 0 { + n += 1 + l + sovGov(uint64(l)) + } + if m.Expedited { + n += 3 + } + if m.Emergency { + n += 3 + } + l = len(m.FailedReason) + if l > 0 { + n += 2 + l + sovGov(uint64(l)) + } + return n +} + func sovGov(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -3153,6 +3641,614 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { } return nil } +func (m *LegacyProposal) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LegacyProposal: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LegacyProposal: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) + } + m.Id = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Id |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Messages", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Messages = append(m.Messages, &types1.Any{}) + if err := m.Messages[len(m.Messages)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + m.Status = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Status |= v1.ProposalStatus(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FinalTallyResult", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.FinalTallyResult == nil { + m.FinalTallyResult = &v1.TallyResult{} + } + if err := m.FinalTallyResult.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SubmitTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SubmitTime == nil { + m.SubmitTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.SubmitTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DepositEndTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.DepositEndTime == nil { + m.DepositEndTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.DepositEndTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TotalDeposit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.TotalDeposit = append(m.TotalDeposit, types.Coin{}) + if err := m.TotalDeposit[len(m.TotalDeposit)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VotingStartTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.VotingStartTime == nil { + m.VotingStartTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.VotingStartTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 9: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VotingEndTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.VotingEndTime == nil { + m.VotingEndTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.VotingEndTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EmergencyStartTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.EmergencyStartTime == nil { + m.EmergencyStartTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.EmergencyStartTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 11: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EmergencyNextTallyTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.EmergencyNextTallyTime == nil { + m.EmergencyNextTallyTime = new(time.Time) + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(m.EmergencyNextTallyTime, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 12: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Metadata = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 13: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Title = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 14: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Summary", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Summary = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Proposer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Proposer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 16: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Expedited", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.Expedited = bool(v != 0) + case 17: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Emergency", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.Emergency = bool(v != 0) + case 18: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailedReason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGov + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGov + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthGov + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FailedReason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGov(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthGov + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipGov(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0