From e52556b916113e2d41349d1f8400125886c49acf Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 6 Apr 2022 13:16:23 +0200 Subject: [PATCH] refactor(group): API naming audit (#11515) ## Description ref: #10968 --- ### Author Checklist *All items are required. Please add a note to the item if the item is not applicable and please add links to any relevant follow up issues.* I have... - [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] added `!` to the type prefix if API or client breaking change - [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting)) - [ ] provided a link to the relevant issue or specification - [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules) - [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing) - [ ] added a changelog entry to `CHANGELOG.md` - [ ] included comments for [documenting Go code](https://blog.golang.org/godoc) - [ ] updated the relevant documentation or specification - [ ] reviewed "Files changed" and left comments if necessary - [ ] confirmed all CI checks have passed ### Reviewers Checklist *All items are required. Please add a note if the item is not applicable and please add your handle next to the items reviewed if you only reviewed selected items.* I have... - [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] confirmed `!` in the type prefix if API or client breaking change - [ ] confirmed all author checklist items have been addressed - [ ] reviewed state machine logic - [ ] reviewed API design and naming - [ ] reviewed documentation is accurate - [ ] reviewed tests and test coverage - [ ] manually tested (if applicable) --- api/cosmos/group/v1/events.pulsar.go | 2 + api/cosmos/group/v1/genesis.pulsar.go | 2 + api/cosmos/group/v1/query.pulsar.go | 2 + api/cosmos/group/v1/query_grpc.pb.go | 12 +- api/cosmos/group/v1/tx.pulsar.go | 765 +++++++++++++------------- api/cosmos/group/v1/types.pulsar.go | 631 +++++++++------------ proto/cosmos/group/v1/events.proto | 1 + proto/cosmos/group/v1/genesis.proto | 1 + proto/cosmos/group/v1/query.proto | 7 +- proto/cosmos/group/v1/tx.proto | 30 +- proto/cosmos/group/v1/types.proto | 103 ++-- x/group/client/cli/tx.go | 14 +- x/group/genesis.go | 4 +- x/group/genesis_test.go | 33 +- x/group/keeper/genesis_test.go | 8 +- x/group/keeper/grpc_query.go | 116 ++-- x/group/keeper/invariants.go | 2 +- x/group/keeper/keeper.go | 10 +- x/group/keeper/keeper_test.go | 272 ++++----- x/group/keeper/msg_server.go | 43 +- x/group/keeper/proposal_executor.go | 2 +- x/group/keeper/tally.go | 13 +- x/group/module/abci.go | 2 +- x/group/module/abci_test.go | 84 ++- x/group/msgs.go | 24 +- x/group/msgs_test.go | 58 +- x/group/query.pb.go | 12 +- x/group/simulation/genesis.go | 3 +- x/group/simulation/operations.go | 22 +- x/group/simulation/operations_test.go | 10 +- x/group/tx.pb.go | 262 ++++----- x/group/types.go | 8 +- x/group/types.pb.go | 361 ++++++------ 33 files changed, 1393 insertions(+), 1526 deletions(-) diff --git a/api/cosmos/group/v1/events.pulsar.go b/api/cosmos/group/v1/events.pulsar.go index 9678ef871b..cde73c9638 100644 --- a/api/cosmos/group/v1/events.pulsar.go +++ b/api/cosmos/group/v1/events.pulsar.go @@ -3793,6 +3793,8 @@ func (x *fastReflection_EventLeaveGroup) ProtoMethods() *protoiface.Methods { } } +// Since: cosmos-sdk 0.46 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 diff --git a/api/cosmos/group/v1/genesis.pulsar.go b/api/cosmos/group/v1/genesis.pulsar.go index 4993a5a826..f3fc2f2dd6 100644 --- a/api/cosmos/group/v1/genesis.pulsar.go +++ b/api/cosmos/group/v1/genesis.pulsar.go @@ -1202,6 +1202,8 @@ func (x *fastReflection_GenesisState) ProtoMethods() *protoiface.Methods { } } +// Since: cosmos-sdk 0.46 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 diff --git a/api/cosmos/group/v1/query.pulsar.go b/api/cosmos/group/v1/query.pulsar.go index 24c8b4479d..e43ad72db7 100644 --- a/api/cosmos/group/v1/query.pulsar.go +++ b/api/cosmos/group/v1/query.pulsar.go @@ -12819,6 +12819,8 @@ func (x *fastReflection_QueryTallyResultResponse) ProtoMethods() *protoiface.Met } } +// Since: cosmos-sdk 0.46 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 diff --git a/api/cosmos/group/v1/query_grpc.pb.go b/api/cosmos/group/v1/query_grpc.pb.go index 03f1d8977c..b9da9a6107 100644 --- a/api/cosmos/group/v1/query_grpc.pb.go +++ b/api/cosmos/group/v1/query_grpc.pb.go @@ -46,7 +46,11 @@ type QueryClient interface { VotesByVoter(ctx context.Context, in *QueryVotesByVoterRequest, opts ...grpc.CallOption) (*QueryVotesByVoterResponse, error) // GroupsByMember queries groups by member address. GroupsByMember(ctx context.Context, in *QueryGroupsByMemberRequest, opts ...grpc.CallOption) (*QueryGroupsByMemberResponse, error) - // TallyResult queries the tally of a proposal votes. + // TallyResult returns the tally result of a proposal. If the proposal is + // still in voting period, then this query computes the current tally state, + // which might not be final. On the other hand, if the proposal is final, + // then it simply returns the `final_tally_result` state stored in the + // proposal itself. TallyResult(ctx context.Context, in *QueryTallyResultRequest, opts ...grpc.CallOption) (*QueryTallyResultResponse, error) } @@ -203,7 +207,11 @@ type QueryServer interface { VotesByVoter(context.Context, *QueryVotesByVoterRequest) (*QueryVotesByVoterResponse, error) // GroupsByMember queries groups by member address. GroupsByMember(context.Context, *QueryGroupsByMemberRequest) (*QueryGroupsByMemberResponse, error) - // TallyResult queries the tally of a proposal votes. + // TallyResult returns the tally result of a proposal. If the proposal is + // still in voting period, then this query computes the current tally state, + // which might not be final. On the other hand, if the proposal is final, + // then it simply returns the `final_tally_result` state stored in the + // proposal itself. TallyResult(context.Context, *QueryTallyResultRequest) (*QueryTallyResultResponse, error) mustEmbedUnimplementedQueryServer() } diff --git a/api/cosmos/group/v1/tx.pulsar.go b/api/cosmos/group/v1/tx.pulsar.go index 78e15d6d19..f309d16cb7 100644 --- a/api/cosmos/group/v1/tx.pulsar.go +++ b/api/cosmos/group/v1/tx.pulsar.go @@ -4812,17 +4812,17 @@ func (x *fastReflection_MsgCreateGroupPolicyResponse) ProtoMethods() *protoiface } var ( - md_MsgUpdateGroupPolicyAdmin protoreflect.MessageDescriptor - fd_MsgUpdateGroupPolicyAdmin_admin protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyAdmin_address protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyAdmin_new_admin protoreflect.FieldDescriptor + md_MsgUpdateGroupPolicyAdmin protoreflect.MessageDescriptor + fd_MsgUpdateGroupPolicyAdmin_admin protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyAdmin_group_policy_address protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyAdmin_new_admin protoreflect.FieldDescriptor ) func init() { file_cosmos_group_v1_tx_proto_init() md_MsgUpdateGroupPolicyAdmin = File_cosmos_group_v1_tx_proto.Messages().ByName("MsgUpdateGroupPolicyAdmin") fd_MsgUpdateGroupPolicyAdmin_admin = md_MsgUpdateGroupPolicyAdmin.Fields().ByName("admin") - fd_MsgUpdateGroupPolicyAdmin_address = md_MsgUpdateGroupPolicyAdmin.Fields().ByName("address") + fd_MsgUpdateGroupPolicyAdmin_group_policy_address = md_MsgUpdateGroupPolicyAdmin.Fields().ByName("group_policy_address") fd_MsgUpdateGroupPolicyAdmin_new_admin = md_MsgUpdateGroupPolicyAdmin.Fields().ByName("new_admin") } @@ -4897,9 +4897,9 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Range(f func(protoreflect.Fie return } } - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_MsgUpdateGroupPolicyAdmin_address, value) { + if x.GroupPolicyAddress != "" { + value := protoreflect.ValueOfString(x.GroupPolicyAddress) + if !f(fd_MsgUpdateGroupPolicyAdmin_group_policy_address, value) { return } } @@ -4926,8 +4926,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Has(fd protoreflect.FieldDesc switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": return x.Admin != "" - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": - return x.Address != "" + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": + return x.GroupPolicyAddress != "" case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": return x.NewAdmin != "" default: @@ -4948,8 +4948,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Clear(fd protoreflect.FieldDe switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": x.Admin = "" - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": - x.Address = "" + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": + x.GroupPolicyAddress = "" case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": x.NewAdmin = "" default: @@ -4971,8 +4971,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Get(descriptor protoreflect.F case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": value := x.Admin return protoreflect.ValueOfString(value) - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": - value := x.Address + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": + value := x.GroupPolicyAddress return protoreflect.ValueOfString(value) case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": value := x.NewAdmin @@ -4999,8 +4999,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Set(fd protoreflect.FieldDesc switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": x.Admin = value.Interface().(string) - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": - x.Address = value.Interface().(string) + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": + x.GroupPolicyAddress = value.Interface().(string) case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": x.NewAdmin = value.Interface().(string) default: @@ -5025,8 +5025,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) Mutable(fd protoreflect.Field switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": panic(fmt.Errorf("field admin of message cosmos.group.v1.MsgUpdateGroupPolicyAdmin is not mutable")) - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": - panic(fmt.Errorf("field address of message cosmos.group.v1.MsgUpdateGroupPolicyAdmin is not mutable")) + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": + panic(fmt.Errorf("field group_policy_address of message cosmos.group.v1.MsgUpdateGroupPolicyAdmin is not mutable")) case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": panic(fmt.Errorf("field new_admin of message cosmos.group.v1.MsgUpdateGroupPolicyAdmin is not mutable")) default: @@ -5044,7 +5044,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) NewField(fd protoreflect.Fiel switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.admin": return protoreflect.ValueOfString("") - case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.address": + case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.group_policy_address": return protoreflect.ValueOfString("") case "cosmos.group.v1.MsgUpdateGroupPolicyAdmin.new_admin": return protoreflect.ValueOfString("") @@ -5121,7 +5121,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) ProtoMethods() *protoiface.Me if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Address) + l = len(x.GroupPolicyAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -5165,10 +5165,10 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) ProtoMethods() *protoiface.Me i-- dAtA[i] = 0x1a } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.GroupPolicyAddress) > 0 { + i -= len(x.GroupPolicyAddress) + copy(dAtA[i:], x.GroupPolicyAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -5262,7 +5262,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) ProtoMethods() *protoiface.Me iNdEx = postIndex case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5290,7 +5290,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdmin) ProtoMethods() *protoiface.Me if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -7003,17 +7003,17 @@ func (x *fastReflection_MsgUpdateGroupPolicyAdminResponse) ProtoMethods() *proto } var ( - md_MsgUpdateGroupPolicyDecisionPolicy protoreflect.MessageDescriptor - fd_MsgUpdateGroupPolicyDecisionPolicy_admin protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyDecisionPolicy_address protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyDecisionPolicy_decision_policy protoreflect.FieldDescriptor + md_MsgUpdateGroupPolicyDecisionPolicy protoreflect.MessageDescriptor + fd_MsgUpdateGroupPolicyDecisionPolicy_admin protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyDecisionPolicy_group_policy_address protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyDecisionPolicy_decision_policy protoreflect.FieldDescriptor ) func init() { file_cosmos_group_v1_tx_proto_init() md_MsgUpdateGroupPolicyDecisionPolicy = File_cosmos_group_v1_tx_proto.Messages().ByName("MsgUpdateGroupPolicyDecisionPolicy") fd_MsgUpdateGroupPolicyDecisionPolicy_admin = md_MsgUpdateGroupPolicyDecisionPolicy.Fields().ByName("admin") - fd_MsgUpdateGroupPolicyDecisionPolicy_address = md_MsgUpdateGroupPolicyDecisionPolicy.Fields().ByName("address") + fd_MsgUpdateGroupPolicyDecisionPolicy_group_policy_address = md_MsgUpdateGroupPolicyDecisionPolicy.Fields().ByName("group_policy_address") fd_MsgUpdateGroupPolicyDecisionPolicy_decision_policy = md_MsgUpdateGroupPolicyDecisionPolicy.Fields().ByName("decision_policy") } @@ -7088,9 +7088,9 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Range(f func(protore return } } - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_MsgUpdateGroupPolicyDecisionPolicy_address, value) { + if x.GroupPolicyAddress != "" { + value := protoreflect.ValueOfString(x.GroupPolicyAddress) + if !f(fd_MsgUpdateGroupPolicyDecisionPolicy_group_policy_address, value) { return } } @@ -7117,8 +7117,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Has(fd protoreflect. switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": return x.Admin != "" - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": - return x.Address != "" + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": + return x.GroupPolicyAddress != "" case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.decision_policy": return x.DecisionPolicy != nil default: @@ -7139,8 +7139,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Clear(fd protoreflec switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": x.Admin = "" - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": - x.Address = "" + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": + x.GroupPolicyAddress = "" case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.decision_policy": x.DecisionPolicy = nil default: @@ -7162,8 +7162,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Get(descriptor proto case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": value := x.Admin return protoreflect.ValueOfString(value) - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": - value := x.Address + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": + value := x.GroupPolicyAddress return protoreflect.ValueOfString(value) case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.decision_policy": value := x.DecisionPolicy @@ -7190,8 +7190,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Set(fd protoreflect. switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": x.Admin = value.Interface().(string) - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": - x.Address = value.Interface().(string) + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": + x.GroupPolicyAddress = value.Interface().(string) case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.decision_policy": x.DecisionPolicy = value.Message().Interface().(*anypb.Any) default: @@ -7221,8 +7221,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) Mutable(fd protorefl return protoreflect.ValueOfMessage(x.DecisionPolicy.ProtoReflect()) case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": panic(fmt.Errorf("field admin of message cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy is not mutable")) - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": - panic(fmt.Errorf("field address of message cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy is not mutable")) + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": + panic(fmt.Errorf("field group_policy_address of message cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy")) @@ -7238,7 +7238,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) NewField(fd protoref switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.admin": return protoreflect.ValueOfString("") - case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.address": + case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.group_policy_address": return protoreflect.ValueOfString("") case "cosmos.group.v1.MsgUpdateGroupPolicyDecisionPolicy.decision_policy": m := new(anypb.Any) @@ -7316,7 +7316,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) ProtoMethods() *prot if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Address) + l = len(x.GroupPolicyAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -7367,10 +7367,10 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) ProtoMethods() *prot i-- dAtA[i] = 0x1a } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.GroupPolicyAddress) > 0 { + i -= len(x.GroupPolicyAddress) + copy(dAtA[i:], x.GroupPolicyAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -7464,7 +7464,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) ProtoMethods() *prot iNdEx = postIndex case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -7492,7 +7492,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicy) ProtoMethods() *prot if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -7922,17 +7922,17 @@ func (x *fastReflection_MsgUpdateGroupPolicyDecisionPolicyResponse) ProtoMethods } var ( - md_MsgUpdateGroupPolicyMetadata protoreflect.MessageDescriptor - fd_MsgUpdateGroupPolicyMetadata_admin protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyMetadata_address protoreflect.FieldDescriptor - fd_MsgUpdateGroupPolicyMetadata_metadata protoreflect.FieldDescriptor + md_MsgUpdateGroupPolicyMetadata protoreflect.MessageDescriptor + fd_MsgUpdateGroupPolicyMetadata_admin protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyMetadata_group_policy_address protoreflect.FieldDescriptor + fd_MsgUpdateGroupPolicyMetadata_metadata protoreflect.FieldDescriptor ) func init() { file_cosmos_group_v1_tx_proto_init() md_MsgUpdateGroupPolicyMetadata = File_cosmos_group_v1_tx_proto.Messages().ByName("MsgUpdateGroupPolicyMetadata") fd_MsgUpdateGroupPolicyMetadata_admin = md_MsgUpdateGroupPolicyMetadata.Fields().ByName("admin") - fd_MsgUpdateGroupPolicyMetadata_address = md_MsgUpdateGroupPolicyMetadata.Fields().ByName("address") + fd_MsgUpdateGroupPolicyMetadata_group_policy_address = md_MsgUpdateGroupPolicyMetadata.Fields().ByName("group_policy_address") fd_MsgUpdateGroupPolicyMetadata_metadata = md_MsgUpdateGroupPolicyMetadata.Fields().ByName("metadata") } @@ -8007,9 +8007,9 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Range(f func(protoreflect. return } } - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_MsgUpdateGroupPolicyMetadata_address, value) { + if x.GroupPolicyAddress != "" { + value := protoreflect.ValueOfString(x.GroupPolicyAddress) + if !f(fd_MsgUpdateGroupPolicyMetadata_group_policy_address, value) { return } } @@ -8036,8 +8036,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Has(fd protoreflect.FieldD switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": return x.Admin != "" - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": - return x.Address != "" + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": + return x.GroupPolicyAddress != "" case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": return x.Metadata != "" default: @@ -8058,8 +8058,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Clear(fd protoreflect.Fiel switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": x.Admin = "" - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": - x.Address = "" + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": + x.GroupPolicyAddress = "" case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": x.Metadata = "" default: @@ -8081,8 +8081,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Get(descriptor protoreflec case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": value := x.Admin return protoreflect.ValueOfString(value) - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": - value := x.Address + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": + value := x.GroupPolicyAddress return protoreflect.ValueOfString(value) case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": value := x.Metadata @@ -8109,8 +8109,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Set(fd protoreflect.FieldD switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": x.Admin = value.Interface().(string) - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": - x.Address = value.Interface().(string) + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": + x.GroupPolicyAddress = value.Interface().(string) case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": x.Metadata = value.Interface().(string) default: @@ -8135,8 +8135,8 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) Mutable(fd protoreflect.Fi switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": panic(fmt.Errorf("field admin of message cosmos.group.v1.MsgUpdateGroupPolicyMetadata is not mutable")) - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": - panic(fmt.Errorf("field address of message cosmos.group.v1.MsgUpdateGroupPolicyMetadata is not mutable")) + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": + panic(fmt.Errorf("field group_policy_address of message cosmos.group.v1.MsgUpdateGroupPolicyMetadata is not mutable")) case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": panic(fmt.Errorf("field metadata of message cosmos.group.v1.MsgUpdateGroupPolicyMetadata is not mutable")) default: @@ -8154,7 +8154,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) NewField(fd protoreflect.F switch fd.FullName() { case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.admin": return protoreflect.ValueOfString("") - case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.address": + case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.group_policy_address": return protoreflect.ValueOfString("") case "cosmos.group.v1.MsgUpdateGroupPolicyMetadata.metadata": return protoreflect.ValueOfString("") @@ -8231,7 +8231,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) ProtoMethods() *protoiface if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Address) + l = len(x.GroupPolicyAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -8275,10 +8275,10 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) ProtoMethods() *protoiface i-- dAtA[i] = 0x1a } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.GroupPolicyAddress) > 0 { + i -= len(x.GroupPolicyAddress) + copy(dAtA[i:], x.GroupPolicyAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -8372,7 +8372,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) ProtoMethods() *protoiface iNdEx = postIndex case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -8400,7 +8400,7 @@ func (x *fastReflection_MsgUpdateGroupPolicyMetadata) ProtoMethods() *protoiface if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -8923,18 +8923,18 @@ func (x *_MsgSubmitProposal_4_list) IsValid() bool { } var ( - md_MsgSubmitProposal protoreflect.MessageDescriptor - fd_MsgSubmitProposal_address protoreflect.FieldDescriptor - fd_MsgSubmitProposal_proposers protoreflect.FieldDescriptor - fd_MsgSubmitProposal_metadata protoreflect.FieldDescriptor - fd_MsgSubmitProposal_messages protoreflect.FieldDescriptor - fd_MsgSubmitProposal_exec protoreflect.FieldDescriptor + md_MsgSubmitProposal protoreflect.MessageDescriptor + fd_MsgSubmitProposal_group_policy_address protoreflect.FieldDescriptor + fd_MsgSubmitProposal_proposers protoreflect.FieldDescriptor + fd_MsgSubmitProposal_metadata protoreflect.FieldDescriptor + fd_MsgSubmitProposal_messages protoreflect.FieldDescriptor + fd_MsgSubmitProposal_exec protoreflect.FieldDescriptor ) func init() { file_cosmos_group_v1_tx_proto_init() md_MsgSubmitProposal = File_cosmos_group_v1_tx_proto.Messages().ByName("MsgSubmitProposal") - fd_MsgSubmitProposal_address = md_MsgSubmitProposal.Fields().ByName("address") + fd_MsgSubmitProposal_group_policy_address = md_MsgSubmitProposal.Fields().ByName("group_policy_address") fd_MsgSubmitProposal_proposers = md_MsgSubmitProposal.Fields().ByName("proposers") fd_MsgSubmitProposal_metadata = md_MsgSubmitProposal.Fields().ByName("metadata") fd_MsgSubmitProposal_messages = md_MsgSubmitProposal.Fields().ByName("messages") @@ -9006,9 +9006,9 @@ func (x *fastReflection_MsgSubmitProposal) Interface() protoreflect.ProtoMessage // While iterating, mutating operations may only be performed // on the current field descriptor. func (x *fastReflection_MsgSubmitProposal) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_MsgSubmitProposal_address, value) { + if x.GroupPolicyAddress != "" { + value := protoreflect.ValueOfString(x.GroupPolicyAddress) + if !f(fd_MsgSubmitProposal_group_policy_address, value) { return } } @@ -9051,8 +9051,8 @@ func (x *fastReflection_MsgSubmitProposal) Range(f func(protoreflect.FieldDescri // a repeated field is populated if it is non-empty. func (x *fastReflection_MsgSubmitProposal) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "cosmos.group.v1.MsgSubmitProposal.address": - return x.Address != "" + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": + return x.GroupPolicyAddress != "" case "cosmos.group.v1.MsgSubmitProposal.proposers": return len(x.Proposers) != 0 case "cosmos.group.v1.MsgSubmitProposal.metadata": @@ -9077,8 +9077,8 @@ func (x *fastReflection_MsgSubmitProposal) Has(fd protoreflect.FieldDescriptor) // Clear is a mutating operation and unsafe for concurrent use. func (x *fastReflection_MsgSubmitProposal) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "cosmos.group.v1.MsgSubmitProposal.address": - x.Address = "" + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": + x.GroupPolicyAddress = "" case "cosmos.group.v1.MsgSubmitProposal.proposers": x.Proposers = nil case "cosmos.group.v1.MsgSubmitProposal.metadata": @@ -9103,8 +9103,8 @@ func (x *fastReflection_MsgSubmitProposal) Clear(fd protoreflect.FieldDescriptor // of the value; to obtain a mutable reference, use Mutable. func (x *fastReflection_MsgSubmitProposal) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "cosmos.group.v1.MsgSubmitProposal.address": - value := x.Address + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": + value := x.GroupPolicyAddress return protoreflect.ValueOfString(value) case "cosmos.group.v1.MsgSubmitProposal.proposers": if len(x.Proposers) == 0 { @@ -9144,8 +9144,8 @@ func (x *fastReflection_MsgSubmitProposal) Get(descriptor protoreflect.FieldDesc // Set is a mutating operation and unsafe for concurrent use. func (x *fastReflection_MsgSubmitProposal) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "cosmos.group.v1.MsgSubmitProposal.address": - x.Address = value.Interface().(string) + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": + x.GroupPolicyAddress = value.Interface().(string) case "cosmos.group.v1.MsgSubmitProposal.proposers": lv := value.List() clv := lv.(*_MsgSubmitProposal_2_list) @@ -9190,8 +9190,8 @@ func (x *fastReflection_MsgSubmitProposal) Mutable(fd protoreflect.FieldDescript } value := &_MsgSubmitProposal_4_list{list: &x.Messages} return protoreflect.ValueOfList(value) - case "cosmos.group.v1.MsgSubmitProposal.address": - panic(fmt.Errorf("field address of message cosmos.group.v1.MsgSubmitProposal is not mutable")) + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": + panic(fmt.Errorf("field group_policy_address of message cosmos.group.v1.MsgSubmitProposal is not mutable")) case "cosmos.group.v1.MsgSubmitProposal.metadata": panic(fmt.Errorf("field metadata of message cosmos.group.v1.MsgSubmitProposal is not mutable")) case "cosmos.group.v1.MsgSubmitProposal.exec": @@ -9209,7 +9209,7 @@ func (x *fastReflection_MsgSubmitProposal) Mutable(fd protoreflect.FieldDescript // For lists, maps, and messages, this returns a new, empty, mutable value. func (x *fastReflection_MsgSubmitProposal) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "cosmos.group.v1.MsgSubmitProposal.address": + case "cosmos.group.v1.MsgSubmitProposal.group_policy_address": return protoreflect.ValueOfString("") case "cosmos.group.v1.MsgSubmitProposal.proposers": list := []string{} @@ -9290,7 +9290,7 @@ func (x *fastReflection_MsgSubmitProposal) ProtoMethods() *protoiface.Methods { var n int var l int _ = l - l = len(x.Address) + l = len(x.GroupPolicyAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -9379,10 +9379,10 @@ func (x *fastReflection_MsgSubmitProposal) ProtoMethods() *protoiface.Methods { dAtA[i] = 0x12 } } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.GroupPolicyAddress) > 0 { + i -= len(x.GroupPolicyAddress) + copy(dAtA[i:], x.GroupPolicyAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.GroupPolicyAddress))) i-- dAtA[i] = 0xa } @@ -9437,7 +9437,7 @@ func (x *fastReflection_MsgSubmitProposal) ProtoMethods() *protoiface.Methods { switch fieldNum { case 1: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -9465,7 +9465,7 @@ func (x *fastReflection_MsgSubmitProposal) ProtoMethods() *protoiface.Methods { if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -11834,14 +11834,14 @@ func (x *fastReflection_MsgVoteResponse) ProtoMethods() *protoiface.Methods { var ( md_MsgExec protoreflect.MessageDescriptor fd_MsgExec_proposal_id protoreflect.FieldDescriptor - fd_MsgExec_signer protoreflect.FieldDescriptor + fd_MsgExec_executor protoreflect.FieldDescriptor ) func init() { file_cosmos_group_v1_tx_proto_init() md_MsgExec = File_cosmos_group_v1_tx_proto.Messages().ByName("MsgExec") fd_MsgExec_proposal_id = md_MsgExec.Fields().ByName("proposal_id") - fd_MsgExec_signer = md_MsgExec.Fields().ByName("signer") + fd_MsgExec_executor = md_MsgExec.Fields().ByName("executor") } var _ protoreflect.Message = (*fastReflection_MsgExec)(nil) @@ -11915,9 +11915,9 @@ func (x *fastReflection_MsgExec) Range(f func(protoreflect.FieldDescriptor, prot return } } - if x.Signer != "" { - value := protoreflect.ValueOfString(x.Signer) - if !f(fd_MsgExec_signer, value) { + if x.Executor != "" { + value := protoreflect.ValueOfString(x.Executor) + if !f(fd_MsgExec_executor, value) { return } } @@ -11938,8 +11938,8 @@ func (x *fastReflection_MsgExec) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { case "cosmos.group.v1.MsgExec.proposal_id": return x.ProposalId != uint64(0) - case "cosmos.group.v1.MsgExec.signer": - return x.Signer != "" + case "cosmos.group.v1.MsgExec.executor": + return x.Executor != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.MsgExec")) @@ -11958,8 +11958,8 @@ func (x *fastReflection_MsgExec) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "cosmos.group.v1.MsgExec.proposal_id": x.ProposalId = uint64(0) - case "cosmos.group.v1.MsgExec.signer": - x.Signer = "" + case "cosmos.group.v1.MsgExec.executor": + x.Executor = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.MsgExec")) @@ -11979,8 +11979,8 @@ func (x *fastReflection_MsgExec) Get(descriptor protoreflect.FieldDescriptor) pr case "cosmos.group.v1.MsgExec.proposal_id": value := x.ProposalId return protoreflect.ValueOfUint64(value) - case "cosmos.group.v1.MsgExec.signer": - value := x.Signer + case "cosmos.group.v1.MsgExec.executor": + value := x.Executor return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { @@ -12004,8 +12004,8 @@ func (x *fastReflection_MsgExec) Set(fd protoreflect.FieldDescriptor, value prot switch fd.FullName() { case "cosmos.group.v1.MsgExec.proposal_id": x.ProposalId = value.Uint() - case "cosmos.group.v1.MsgExec.signer": - x.Signer = value.Interface().(string) + case "cosmos.group.v1.MsgExec.executor": + x.Executor = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.MsgExec")) @@ -12028,8 +12028,8 @@ func (x *fastReflection_MsgExec) Mutable(fd protoreflect.FieldDescriptor) protor switch fd.FullName() { case "cosmos.group.v1.MsgExec.proposal_id": panic(fmt.Errorf("field proposal_id of message cosmos.group.v1.MsgExec is not mutable")) - case "cosmos.group.v1.MsgExec.signer": - panic(fmt.Errorf("field signer of message cosmos.group.v1.MsgExec is not mutable")) + case "cosmos.group.v1.MsgExec.executor": + panic(fmt.Errorf("field executor of message cosmos.group.v1.MsgExec is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.MsgExec")) @@ -12045,7 +12045,7 @@ func (x *fastReflection_MsgExec) NewField(fd protoreflect.FieldDescriptor) proto switch fd.FullName() { case "cosmos.group.v1.MsgExec.proposal_id": return protoreflect.ValueOfUint64(uint64(0)) - case "cosmos.group.v1.MsgExec.signer": + case "cosmos.group.v1.MsgExec.executor": return protoreflect.ValueOfString("") default: if fd.IsExtension() { @@ -12119,7 +12119,7 @@ func (x *fastReflection_MsgExec) ProtoMethods() *protoiface.Methods { if x.ProposalId != 0 { n += 1 + runtime.Sov(uint64(x.ProposalId)) } - l = len(x.Signer) + l = len(x.Executor) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -12152,10 +12152,10 @@ func (x *fastReflection_MsgExec) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Signer) > 0 { - i -= len(x.Signer) - copy(dAtA[i:], x.Signer) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Signer))) + if len(x.Executor) > 0 { + i -= len(x.Executor) + copy(dAtA[i:], x.Executor) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Executor))) i-- dAtA[i] = 0x12 } @@ -12234,7 +12234,7 @@ func (x *fastReflection_MsgExec) ProtoMethods() *protoiface.Methods { } case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Executor", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -12262,7 +12262,7 @@ func (x *fastReflection_MsgExec) ProtoMethods() *protoiface.Methods { if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Signer = string(dAtA[iNdEx:postIndex]) + x.Executor = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -13479,6 +13479,8 @@ func (x *fastReflection_MsgLeaveGroupResponse) ProtoMethods() *protoiface.Method } } +// Since: cosmos-sdk 0.46 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 @@ -13993,8 +13995,8 @@ type MsgUpdateGroupPolicyAdmin struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of the group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of the group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // new_admin is the new group policy admin. NewAdmin string `protobuf:"bytes,3,opt,name=new_admin,json=newAdmin,proto3" json:"new_admin,omitempty"` } @@ -14026,9 +14028,9 @@ func (x *MsgUpdateGroupPolicyAdmin) GetAdmin() string { return "" } -func (x *MsgUpdateGroupPolicyAdmin) GetAddress() string { +func (x *MsgUpdateGroupPolicyAdmin) GetGroupPolicyAddress() string { if x != nil { - return x.Address + return x.GroupPolicyAddress } return "" } @@ -14054,7 +14056,8 @@ type MsgCreateGroupWithPolicy struct { GroupMetadata string `protobuf:"bytes,3,opt,name=group_metadata,json=groupMetadata,proto3" json:"group_metadata,omitempty"` // group_policy_metadata is any arbitrary metadata attached to the group policy. GroupPolicyMetadata string `protobuf:"bytes,4,opt,name=group_policy_metadata,json=groupPolicyMetadata,proto3" json:"group_policy_metadata,omitempty"` - // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group and group policy admin. + // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group + // and group policy admin. GroupPolicyAsAdmin bool `protobuf:"varint,5,opt,name=group_policy_as_admin,json=groupPolicyAsAdmin,proto3" json:"group_policy_as_admin,omitempty"` // decision_policy specifies the group policy's decision policy. DecisionPolicy *anypb.Any `protobuf:"bytes,6,opt,name=decision_policy,json=decisionPolicy,proto3" json:"decision_policy,omitempty"` @@ -14203,8 +14206,8 @@ type MsgUpdateGroupPolicyDecisionPolicy struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // decision_policy is the updated group policy's decision policy. DecisionPolicy *anypb.Any `protobuf:"bytes,3,opt,name=decision_policy,json=decisionPolicy,proto3" json:"decision_policy,omitempty"` } @@ -14236,9 +14239,9 @@ func (x *MsgUpdateGroupPolicyDecisionPolicy) GetAdmin() string { return "" } -func (x *MsgUpdateGroupPolicyDecisionPolicy) GetAddress() string { +func (x *MsgUpdateGroupPolicyDecisionPolicy) GetGroupPolicyAddress() string { if x != nil { - return x.Address + return x.GroupPolicyAddress } return "" } @@ -14285,8 +14288,8 @@ type MsgUpdateGroupPolicyMetadata struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // metadata is the updated group policy metadata. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` } @@ -14318,9 +14321,9 @@ func (x *MsgUpdateGroupPolicyMetadata) GetAdmin() string { return "" } -func (x *MsgUpdateGroupPolicyMetadata) GetAddress() string { +func (x *MsgUpdateGroupPolicyMetadata) GetGroupPolicyAddress() string { if x != nil { - return x.Address + return x.GroupPolicyAddress } return "" } @@ -14365,8 +14368,8 @@ type MsgSubmitProposal struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // address is the account address of group policy. - Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,1,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // proposers are the account addresses of the proposers. // Proposers signatures will be counted as yes votes. Proposers []string `protobuf:"bytes,2,rep,name=proposers,proto3" json:"proposers,omitempty"` @@ -14400,9 +14403,9 @@ func (*MsgSubmitProposal) Descriptor() ([]byte, []int) { return file_cosmos_group_v1_tx_proto_rawDescGZIP(), []int{18} } -func (x *MsgSubmitProposal) GetAddress() string { +func (x *MsgSubmitProposal) GetGroupPolicyAddress() string { if x != nil { - return x.Address + return x.GroupPolicyAddress } return "" } @@ -14654,8 +14657,8 @@ type MsgExec struct { // proposal is the unique ID of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` - // signer is the account address used to execute the proposal. - Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` + // executor is the account address used to execute the proposal. + Executor string `protobuf:"bytes,2,opt,name=executor,proto3" json:"executor,omitempty"` } func (x *MsgExec) Reset() { @@ -14685,9 +14688,9 @@ func (x *MsgExec) GetProposalId() uint64 { return 0 } -func (x *MsgExec) GetSigner() string { +func (x *MsgExec) GetExecutor() string { if x != nil { - return x.Signer + return x.Executor } return "" } @@ -14875,251 +14878,259 @@ var file_cosmos_group_v1_tx_proto_rawDesc = []byte{ 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 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, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xc2, 0x01, 0x0a, 0x19, 0x4d, + 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xda, 0x01, 0x0a, 0x19, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x2e, 0x0a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, - 0x65, 0x73, 0x73, 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, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x35, 0x0a, 0x09, - 0x6e, 0x65, 0x77, 0x5f, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x03, 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, 0x08, 0x6e, 0x65, 0x77, 0x41, 0x64, - 0x6d, 0x69, 0x6e, 0x3a, 0x0a, 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, - 0xea, 0x02, 0x0a, 0x18, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, - 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x2e, 0x0a, 0x05, - 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x37, 0x0a, 0x07, - 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, - 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x6d, 0x65, - 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x25, 0x0a, 0x0e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x6d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x15, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x6d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x13, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x12, 0x31, 0x0a, 0x15, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, - 0x5f, 0x61, 0x73, 0x5f, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, - 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x73, 0x41, 0x64, - 0x6d, 0x69, 0x6e, 0x12, 0x51, 0x0a, 0x0f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x5f, - 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, - 0x6e, 0x79, 0x42, 0x12, 0xca, 0xb4, 0x2d, 0x0e, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, - 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x0e, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, - 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0x89, 0x01, 0x0a, - 0x20, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, - 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x4a, 0x0a, 0x14, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 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, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x23, 0x0a, 0x21, 0x4d, 0x73, 0x67, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, - 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xeb, 0x01, - 0x0a, 0x22, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, + 0x67, 0x52, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x4a, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 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, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x12, 0x35, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x5f, 0x61, 0x64, 0x6d, 0x69, + 0x6e, 0x18, 0x03, 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, 0x08, 0x6e, 0x65, 0x77, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x3a, 0x0a, 0x82, 0xe7, 0xb0, + 0x2a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0xf4, 0x02, 0x0a, 0x18, 0x4d, 0x73, 0x67, 0x43, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x2e, 0x0a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, 0x61, - 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, - 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x51, 0x0a, 0x0f, 0x64, 0x65, 0x63, 0x69, - 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x42, 0x12, 0xca, 0xb4, 0x2d, 0x0e, 0x44, 0x65, 0x63, - 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x0e, 0x64, 0x65, 0x63, - 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x3a, 0x0e, 0x88, 0xa0, 0x1f, - 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0x2c, 0x0a, 0x2a, 0x4d, - 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, - 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xaa, 0x01, 0x0a, 0x1c, 0x4d, 0x73, + 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x37, 0x0a, 0x07, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x18, + 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x42, 0x04, + 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x07, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x25, 0x0a, + 0x0e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0x12, 0x32, 0x0a, 0x15, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, + 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x13, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x31, 0x0a, 0x15, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x73, 0x5f, 0x61, 0x64, 0x6d, 0x69, + 0x6e, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, + 0x6c, 0x69, 0x63, 0x79, 0x41, 0x73, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x51, 0x0a, 0x0f, 0x64, + 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x42, 0x12, 0xca, 0xb4, 0x2d, 0x0e, + 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x0e, + 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x3a, 0x0e, + 0x88, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0x89, + 0x01, 0x0a, 0x20, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x12, 0x4a, + 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, + 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x23, 0x0a, 0x21, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, - 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2e, 0x0a, 0x05, 0x61, 0x64, - 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1a, - 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x3a, 0x0a, 0x82, 0xe7, 0xb0, 0x2a, - 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0x26, 0x0a, 0x24, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, - 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xf2, - 0x01, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, - 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, + 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x83, 0x02, 0x0a, 0x22, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x2e, 0x0a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, - 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x70, - 0x6f, 0x73, 0x65, 0x72, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x70, 0x72, 0x6f, - 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x12, 0x30, 0x0a, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x18, 0x04, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, 0x6d, 0x65, 0x73, 0x73, - 0x61, 0x67, 0x65, 0x73, 0x12, 0x29, 0x0a, 0x04, 0x65, 0x78, 0x65, 0x63, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x52, 0x04, 0x65, 0x78, 0x65, 0x63, 0x3a, - 0x12, 0x88, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, - 0x65, 0x72, 0x73, 0x22, 0x3c, 0x0a, 0x19, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, - 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 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, 0x22, 0x6a, 0x0a, 0x13, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, - 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 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, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 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, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x1d, 0x0a, - 0x1b, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, - 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xe2, 0x01, 0x0a, - 0x07, 0x4d, 0x73, 0x67, 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, 0x33, 0x0a, 0x06, 0x6f, 0x70, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x6f, 0x74, 0x65, - 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, - 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x29, 0x0a, 0x04, 0x65, 0x78, - 0x65, 0x63, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x52, - 0x04, 0x65, 0x78, 0x65, 0x63, 0x3a, 0x0a, 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x76, 0x6f, 0x74, 0x65, - 0x72, 0x22, 0x11, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x69, 0x0a, 0x07, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 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, 0x30, 0x0a, 0x06, 0x73, 0x69, 0x67, 0x6e, 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, 0x06, 0x73, 0x69, 0x67, 0x6e, - 0x65, 0x72, 0x3a, 0x0b, 0x82, 0xe7, 0xb0, 0x2a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x22, - 0x11, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x6c, 0x0a, 0x0d, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, + 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x4a, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, + 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x12, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x12, 0x51, 0x0a, 0x0f, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x5f, 0x70, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, + 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, + 0x79, 0x42, 0x12, 0xca, 0xb4, 0x2d, 0x0e, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x0e, 0x64, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x3a, 0x0e, 0x88, 0xa0, 0x1f, 0x00, 0x82, 0xe7, 0xb0, 0x2a, 0x05, + 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0x2c, 0x0a, 0x2a, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, + 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0xc2, 0x01, 0x0a, 0x1c, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, + 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0x12, 0x2e, 0x0a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x18, 0x01, 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, 0x61, + 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x4a, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, + 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x12, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, + 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x3a, 0x0a, 0x82, 0xe7, + 0xb0, 0x2a, 0x05, 0x61, 0x64, 0x6d, 0x69, 0x6e, 0x22, 0x26, 0x0a, 0x24, 0x4d, 0x73, 0x67, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x8a, 0x02, 0x0a, 0x11, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, + 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x4a, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, + 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, + 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, 0x12, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, 0x18, + 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, + 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x30, 0x0a, 0x08, + 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x12, 0x29, + 0x0a, 0x04, 0x65, 0x78, 0x65, 0x63, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x45, + 0x78, 0x65, 0x63, 0x52, 0x04, 0x65, 0x78, 0x65, 0x63, 0x3a, 0x12, 0x88, 0xa0, 0x1f, 0x00, 0x82, + 0xe7, 0xb0, 0x2a, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, 0x22, 0x3c, 0x0a, + 0x19, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, + 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 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, 0x22, 0x78, 0x0a, 0x13, 0x4d, + 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, + 0x61, 0x6c, 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, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x07, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x49, 0x64, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, - 0x22, 0x17, 0x0a, 0x15, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, - 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2a, 0x2a, 0x0a, 0x04, 0x45, 0x78, 0x65, - 0x63, 0x12, 0x14, 0x0a, 0x10, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, - 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x45, 0x43, 0x5f, - 0x54, 0x52, 0x59, 0x10, 0x01, 0x32, 0xc3, 0x0b, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x57, 0x0a, - 0x0b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1f, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x1a, 0x27, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, - 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6c, 0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x26, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, - 0x62, 0x65, 0x72, 0x73, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, - 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, - 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x2c, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, - 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, - 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6f, 0x0a, 0x13, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, - 0x61, 0x74, 0x61, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, - 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x2f, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, - 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, - 0x11, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, - 0x63, 0x79, 0x12, 0x25, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x0c, 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x1d, 0x0a, 0x1b, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, + 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0xe2, 0x01, 0x0a, 0x07, 0x4d, 0x73, 0x67, 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, 0x33, 0x0a, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x0e, 0x32, 0x1b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, + 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0x12, 0x29, 0x0a, 0x04, 0x65, 0x78, 0x65, 0x63, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, + 0x32, 0x15, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, + 0x76, 0x31, 0x2e, 0x45, 0x78, 0x65, 0x63, 0x52, 0x04, 0x65, 0x78, 0x65, 0x63, 0x3a, 0x0a, 0x82, + 0xe7, 0xb0, 0x2a, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x22, 0x11, 0x0a, 0x0f, 0x4d, 0x73, 0x67, + 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6d, 0x0a, 0x07, + 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 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, 0x34, 0x0a, 0x08, 0x65, 0x78, 0x65, 0x63, + 0x75, 0x74, 0x6f, 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, 0x08, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x3a, 0x0b, + 0x82, 0xe7, 0xb0, 0x2a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x22, 0x11, 0x0a, 0x0f, 0x4d, + 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x6c, + 0x0a, 0x0d, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, + 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 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, 0x07, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x3a, 0x0c, + 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0x17, 0x0a, 0x15, + 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2a, 0x2a, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x14, 0x0a, + 0x10, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, + 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x54, 0x52, 0x59, 0x10, + 0x01, 0x32, 0xc3, 0x0b, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x57, 0x0a, 0x0b, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x12, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, - 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x31, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, - 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x78, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, + 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x6c, 0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, + 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, + 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x66, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, + 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x2c, 0x2e, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6f, 0x0a, 0x13, 0x55, 0x70, 0x64, 0x61, + 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, + 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, + 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, 0x11, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x25, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, + 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x29, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, + 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x78, 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, - 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x32, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x93, 0x01, 0x0a, 0x1f, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, - 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x33, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, - 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, - 0x63, 0x79, 0x1a, 0x3b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, - 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x81, 0x01, 0x0a, 0x19, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, - 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2d, 0x2e, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, - 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x35, 0x2e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, - 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x60, 0x0a, 0x0e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, - 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x6e, 0x1a, 0x32, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x93, 0x01, 0x0a, 0x1f, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, + 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x33, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x3b, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x81, 0x01, 0x0a, 0x19, + 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, + 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x35, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x60, 0x0a, 0x0e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x12, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, - 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, - 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x10, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, - 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x57, - 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, - 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, - 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, - 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, - 0x04, 0x56, 0x6f, 0x74, 0x65, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x1a, + 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x66, 0x0a, 0x10, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, + 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, + 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2c, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, + 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x04, 0x56, 0x6f, 0x74, + 0x65, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x1a, 0x20, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, + 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, + 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x1a, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, - 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x42, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, - 0x78, 0x65, 0x63, 0x1a, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x0a, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x12, 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x1a, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, - 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0xb6, 0x01, 0x0a, 0x13, - 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x38, - 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, 0x72, 0x6f, 0x75, 0x70, 0x2f, 0x76, 0x31, - 0x3b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, - 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x56, 0x31, - 0xca, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, - 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, - 0x70, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0xea, 0x02, 0x11, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x54, 0x0a, 0x0a, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, + 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, + 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x1a, + 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, + 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0xb6, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x42, + 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x38, 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, 0x72, 0x6f, 0x75, 0x70, 0x2f, 0x76, 0x31, 0x3b, 0x67, 0x72, 0x6f, + 0x75, 0x70, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x0f, 0x43, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0xe2, 0x02, + 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, + 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/cosmos/group/v1/types.pulsar.go b/api/cosmos/group/v1/types.pulsar.go index e392f94239..2a5b9980d5 100644 --- a/api/cosmos/group/v1/types.pulsar.go +++ b/api/cosmos/group/v1/types.pulsar.go @@ -4704,68 +4704,67 @@ func (x *_Proposal_4_list) IsValid() bool { return x.list != nil } -var _ protoreflect.List = (*_Proposal_13_list)(nil) +var _ protoreflect.List = (*_Proposal_12_list)(nil) -type _Proposal_13_list struct { +type _Proposal_12_list struct { list *[]*anypb.Any } -func (x *_Proposal_13_list) Len() int { +func (x *_Proposal_12_list) Len() int { if x.list == nil { return 0 } return len(*x.list) } -func (x *_Proposal_13_list) Get(i int) protoreflect.Value { +func (x *_Proposal_12_list) Get(i int) protoreflect.Value { return protoreflect.ValueOfMessage((*x.list)[i].ProtoReflect()) } -func (x *_Proposal_13_list) Set(i int, value protoreflect.Value) { +func (x *_Proposal_12_list) Set(i int, value protoreflect.Value) { valueUnwrapped := value.Message() concreteValue := valueUnwrapped.Interface().(*anypb.Any) (*x.list)[i] = concreteValue } -func (x *_Proposal_13_list) Append(value protoreflect.Value) { +func (x *_Proposal_12_list) Append(value protoreflect.Value) { valueUnwrapped := value.Message() concreteValue := valueUnwrapped.Interface().(*anypb.Any) *x.list = append(*x.list, concreteValue) } -func (x *_Proposal_13_list) AppendMutable() protoreflect.Value { +func (x *_Proposal_12_list) AppendMutable() protoreflect.Value { v := new(anypb.Any) *x.list = append(*x.list, v) return protoreflect.ValueOfMessage(v.ProtoReflect()) } -func (x *_Proposal_13_list) Truncate(n int) { +func (x *_Proposal_12_list) Truncate(n int) { for i := n; i < len(*x.list); i++ { (*x.list)[i] = nil } *x.list = (*x.list)[:n] } -func (x *_Proposal_13_list) NewElement() protoreflect.Value { +func (x *_Proposal_12_list) NewElement() protoreflect.Value { v := new(anypb.Any) return protoreflect.ValueOfMessage(v.ProtoReflect()) } -func (x *_Proposal_13_list) IsValid() bool { +func (x *_Proposal_12_list) IsValid() bool { return x.list != nil } var ( md_Proposal protoreflect.MessageDescriptor fd_Proposal_id protoreflect.FieldDescriptor - fd_Proposal_address protoreflect.FieldDescriptor + fd_Proposal_group_policy_address protoreflect.FieldDescriptor fd_Proposal_metadata protoreflect.FieldDescriptor fd_Proposal_proposers protoreflect.FieldDescriptor fd_Proposal_submit_time protoreflect.FieldDescriptor fd_Proposal_group_version protoreflect.FieldDescriptor fd_Proposal_group_policy_version protoreflect.FieldDescriptor fd_Proposal_status protoreflect.FieldDescriptor - fd_Proposal_result protoreflect.FieldDescriptor fd_Proposal_final_tally_result protoreflect.FieldDescriptor fd_Proposal_voting_period_end protoreflect.FieldDescriptor fd_Proposal_executor_result protoreflect.FieldDescriptor @@ -4776,14 +4775,13 @@ func init() { file_cosmos_group_v1_types_proto_init() md_Proposal = File_cosmos_group_v1_types_proto.Messages().ByName("Proposal") fd_Proposal_id = md_Proposal.Fields().ByName("id") - fd_Proposal_address = md_Proposal.Fields().ByName("address") + fd_Proposal_group_policy_address = md_Proposal.Fields().ByName("group_policy_address") fd_Proposal_metadata = md_Proposal.Fields().ByName("metadata") fd_Proposal_proposers = md_Proposal.Fields().ByName("proposers") fd_Proposal_submit_time = md_Proposal.Fields().ByName("submit_time") fd_Proposal_group_version = md_Proposal.Fields().ByName("group_version") fd_Proposal_group_policy_version = md_Proposal.Fields().ByName("group_policy_version") fd_Proposal_status = md_Proposal.Fields().ByName("status") - fd_Proposal_result = md_Proposal.Fields().ByName("result") fd_Proposal_final_tally_result = md_Proposal.Fields().ByName("final_tally_result") fd_Proposal_voting_period_end = md_Proposal.Fields().ByName("voting_period_end") fd_Proposal_executor_result = md_Proposal.Fields().ByName("executor_result") @@ -4861,9 +4859,9 @@ func (x *fastReflection_Proposal) Range(f func(protoreflect.FieldDescriptor, pro return } } - if x.Address != "" { - value := protoreflect.ValueOfString(x.Address) - if !f(fd_Proposal_address, value) { + if x.GroupPolicyAddress != "" { + value := protoreflect.ValueOfString(x.GroupPolicyAddress) + if !f(fd_Proposal_group_policy_address, value) { return } } @@ -4903,12 +4901,6 @@ func (x *fastReflection_Proposal) Range(f func(protoreflect.FieldDescriptor, pro return } } - if x.Result != 0 { - value := protoreflect.ValueOfEnum((protoreflect.EnumNumber)(x.Result)) - if !f(fd_Proposal_result, value) { - return - } - } if x.FinalTallyResult != nil { value := protoreflect.ValueOfMessage(x.FinalTallyResult.ProtoReflect()) if !f(fd_Proposal_final_tally_result, value) { @@ -4928,7 +4920,7 @@ func (x *fastReflection_Proposal) Range(f func(protoreflect.FieldDescriptor, pro } } if len(x.Messages) != 0 { - value := protoreflect.ValueOfList(&_Proposal_13_list{list: &x.Messages}) + value := protoreflect.ValueOfList(&_Proposal_12_list{list: &x.Messages}) if !f(fd_Proposal_messages, value) { return } @@ -4950,8 +4942,8 @@ func (x *fastReflection_Proposal) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { case "cosmos.group.v1.Proposal.id": return x.Id != uint64(0) - case "cosmos.group.v1.Proposal.address": - return x.Address != "" + case "cosmos.group.v1.Proposal.group_policy_address": + return x.GroupPolicyAddress != "" case "cosmos.group.v1.Proposal.metadata": return x.Metadata != "" case "cosmos.group.v1.Proposal.proposers": @@ -4964,8 +4956,6 @@ func (x *fastReflection_Proposal) Has(fd protoreflect.FieldDescriptor) bool { return x.GroupPolicyVersion != uint64(0) case "cosmos.group.v1.Proposal.status": return x.Status != 0 - case "cosmos.group.v1.Proposal.result": - return x.Result != 0 case "cosmos.group.v1.Proposal.final_tally_result": return x.FinalTallyResult != nil case "cosmos.group.v1.Proposal.voting_period_end": @@ -4992,8 +4982,8 @@ func (x *fastReflection_Proposal) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "cosmos.group.v1.Proposal.id": x.Id = uint64(0) - case "cosmos.group.v1.Proposal.address": - x.Address = "" + case "cosmos.group.v1.Proposal.group_policy_address": + x.GroupPolicyAddress = "" case "cosmos.group.v1.Proposal.metadata": x.Metadata = "" case "cosmos.group.v1.Proposal.proposers": @@ -5006,8 +4996,6 @@ func (x *fastReflection_Proposal) Clear(fd protoreflect.FieldDescriptor) { x.GroupPolicyVersion = uint64(0) case "cosmos.group.v1.Proposal.status": x.Status = 0 - case "cosmos.group.v1.Proposal.result": - x.Result = 0 case "cosmos.group.v1.Proposal.final_tally_result": x.FinalTallyResult = nil case "cosmos.group.v1.Proposal.voting_period_end": @@ -5035,8 +5023,8 @@ func (x *fastReflection_Proposal) Get(descriptor protoreflect.FieldDescriptor) p case "cosmos.group.v1.Proposal.id": value := x.Id return protoreflect.ValueOfUint64(value) - case "cosmos.group.v1.Proposal.address": - value := x.Address + case "cosmos.group.v1.Proposal.group_policy_address": + value := x.GroupPolicyAddress return protoreflect.ValueOfString(value) case "cosmos.group.v1.Proposal.metadata": value := x.Metadata @@ -5059,9 +5047,6 @@ func (x *fastReflection_Proposal) Get(descriptor protoreflect.FieldDescriptor) p case "cosmos.group.v1.Proposal.status": value := x.Status return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) - case "cosmos.group.v1.Proposal.result": - value := x.Result - return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) case "cosmos.group.v1.Proposal.final_tally_result": value := x.FinalTallyResult return protoreflect.ValueOfMessage(value.ProtoReflect()) @@ -5073,9 +5058,9 @@ func (x *fastReflection_Proposal) Get(descriptor protoreflect.FieldDescriptor) p return protoreflect.ValueOfEnum((protoreflect.EnumNumber)(value)) case "cosmos.group.v1.Proposal.messages": if len(x.Messages) == 0 { - return protoreflect.ValueOfList(&_Proposal_13_list{}) + return protoreflect.ValueOfList(&_Proposal_12_list{}) } - listValue := &_Proposal_13_list{list: &x.Messages} + listValue := &_Proposal_12_list{list: &x.Messages} return protoreflect.ValueOfList(listValue) default: if descriptor.IsExtension() { @@ -5099,8 +5084,8 @@ func (x *fastReflection_Proposal) Set(fd protoreflect.FieldDescriptor, value pro switch fd.FullName() { case "cosmos.group.v1.Proposal.id": x.Id = value.Uint() - case "cosmos.group.v1.Proposal.address": - x.Address = value.Interface().(string) + case "cosmos.group.v1.Proposal.group_policy_address": + x.GroupPolicyAddress = value.Interface().(string) case "cosmos.group.v1.Proposal.metadata": x.Metadata = value.Interface().(string) case "cosmos.group.v1.Proposal.proposers": @@ -5115,8 +5100,6 @@ func (x *fastReflection_Proposal) Set(fd protoreflect.FieldDescriptor, value pro x.GroupPolicyVersion = value.Uint() case "cosmos.group.v1.Proposal.status": x.Status = (ProposalStatus)(value.Enum()) - case "cosmos.group.v1.Proposal.result": - x.Result = (ProposalResult)(value.Enum()) case "cosmos.group.v1.Proposal.final_tally_result": x.FinalTallyResult = value.Message().Interface().(*TallyResult) case "cosmos.group.v1.Proposal.voting_period_end": @@ -5125,7 +5108,7 @@ func (x *fastReflection_Proposal) Set(fd protoreflect.FieldDescriptor, value pro x.ExecutorResult = (ProposalExecutorResult)(value.Enum()) case "cosmos.group.v1.Proposal.messages": lv := value.List() - clv := lv.(*_Proposal_13_list) + clv := lv.(*_Proposal_12_list) x.Messages = *clv.list default: if fd.IsExtension() { @@ -5172,12 +5155,12 @@ func (x *fastReflection_Proposal) Mutable(fd protoreflect.FieldDescriptor) proto if x.Messages == nil { x.Messages = []*anypb.Any{} } - value := &_Proposal_13_list{list: &x.Messages} + value := &_Proposal_12_list{list: &x.Messages} return protoreflect.ValueOfList(value) case "cosmos.group.v1.Proposal.id": panic(fmt.Errorf("field id of message cosmos.group.v1.Proposal is not mutable")) - case "cosmos.group.v1.Proposal.address": - panic(fmt.Errorf("field address of message cosmos.group.v1.Proposal is not mutable")) + case "cosmos.group.v1.Proposal.group_policy_address": + panic(fmt.Errorf("field group_policy_address of message cosmos.group.v1.Proposal is not mutable")) case "cosmos.group.v1.Proposal.metadata": panic(fmt.Errorf("field metadata of message cosmos.group.v1.Proposal is not mutable")) case "cosmos.group.v1.Proposal.group_version": @@ -5186,8 +5169,6 @@ func (x *fastReflection_Proposal) Mutable(fd protoreflect.FieldDescriptor) proto panic(fmt.Errorf("field group_policy_version of message cosmos.group.v1.Proposal is not mutable")) case "cosmos.group.v1.Proposal.status": panic(fmt.Errorf("field status of message cosmos.group.v1.Proposal is not mutable")) - case "cosmos.group.v1.Proposal.result": - panic(fmt.Errorf("field result of message cosmos.group.v1.Proposal is not mutable")) case "cosmos.group.v1.Proposal.executor_result": panic(fmt.Errorf("field executor_result of message cosmos.group.v1.Proposal is not mutable")) default: @@ -5205,7 +5186,7 @@ func (x *fastReflection_Proposal) NewField(fd protoreflect.FieldDescriptor) prot switch fd.FullName() { case "cosmos.group.v1.Proposal.id": return protoreflect.ValueOfUint64(uint64(0)) - case "cosmos.group.v1.Proposal.address": + case "cosmos.group.v1.Proposal.group_policy_address": return protoreflect.ValueOfString("") case "cosmos.group.v1.Proposal.metadata": return protoreflect.ValueOfString("") @@ -5221,8 +5202,6 @@ func (x *fastReflection_Proposal) NewField(fd protoreflect.FieldDescriptor) prot return protoreflect.ValueOfUint64(uint64(0)) case "cosmos.group.v1.Proposal.status": return protoreflect.ValueOfEnum(0) - case "cosmos.group.v1.Proposal.result": - return protoreflect.ValueOfEnum(0) case "cosmos.group.v1.Proposal.final_tally_result": m := new(TallyResult) return protoreflect.ValueOfMessage(m.ProtoReflect()) @@ -5233,7 +5212,7 @@ func (x *fastReflection_Proposal) NewField(fd protoreflect.FieldDescriptor) prot return protoreflect.ValueOfEnum(0) case "cosmos.group.v1.Proposal.messages": list := []*anypb.Any{} - return protoreflect.ValueOfList(&_Proposal_13_list{list: &list}) + return protoreflect.ValueOfList(&_Proposal_12_list{list: &list}) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.group.v1.Proposal")) @@ -5306,7 +5285,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { if x.Id != 0 { n += 1 + runtime.Sov(uint64(x.Id)) } - l = len(x.Address) + l = len(x.GroupPolicyAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -5333,9 +5312,6 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { if x.Status != 0 { n += 1 + runtime.Sov(uint64(x.Status)) } - if x.Result != 0 { - n += 1 + runtime.Sov(uint64(x.Result)) - } if x.FinalTallyResult != nil { l = options.Size(x.FinalTallyResult) n += 1 + l + runtime.Sov(uint64(l)) @@ -5395,13 +5371,13 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x6a + dAtA[i] = 0x62 } } if x.ExecutorResult != 0 { i = runtime.EncodeVarint(dAtA, i, uint64(x.ExecutorResult)) i-- - dAtA[i] = 0x60 + dAtA[i] = 0x58 } if x.VotingPeriodEnd != nil { encoded, err := options.Marshal(x.VotingPeriodEnd) @@ -5415,7 +5391,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x5a + dAtA[i] = 0x52 } if x.FinalTallyResult != nil { encoded, err := options.Marshal(x.FinalTallyResult) @@ -5429,12 +5405,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { copy(dAtA[i:], encoded) i = runtime.EncodeVarint(dAtA, i, uint64(len(encoded))) i-- - dAtA[i] = 0x52 - } - if x.Result != 0 { - i = runtime.EncodeVarint(dAtA, i, uint64(x.Result)) - i-- - dAtA[i] = 0x48 + dAtA[i] = 0x4a } if x.Status != 0 { i = runtime.EncodeVarint(dAtA, i, uint64(x.Status)) @@ -5481,10 +5452,10 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { i-- dAtA[i] = 0x1a } - if len(x.Address) > 0 { - i -= len(x.Address) - copy(dAtA[i:], x.Address) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Address))) + if len(x.GroupPolicyAddress) > 0 { + i -= len(x.GroupPolicyAddress) + copy(dAtA[i:], x.GroupPolicyAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -5563,7 +5534,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { } case 2: if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5591,7 +5562,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Address = string(dAtA[iNdEx:postIndex]) + x.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -5751,25 +5722,6 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { } } case 9: - if wireType != 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) - } - x.Result = 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.Result |= ProposalResult(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 10: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field FinalTallyResult", wireType) } @@ -5805,7 +5757,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex - case 11: + case 10: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field VotingPeriodEnd", wireType) } @@ -5841,7 +5793,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex - case 12: + case 11: if wireType != 0 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExecutorResult", wireType) } @@ -5860,7 +5812,7 @@ func (x *fastReflection_Proposal) ProtoMethods() *protoiface.Methods { break } } - case 13: + case 12: if wireType != 2 { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Messages", wireType) } @@ -7200,6 +7152,8 @@ func (x *fastReflection_Vote) ProtoMethods() *protoiface.Methods { } } +// Since: cosmos-sdk 0.46 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.27.0 @@ -7217,7 +7171,8 @@ const ( type VoteOption int32 const ( - // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. + // VOTE_OPTION_UNSPECIFIED defines an unspecified vote option which will + // return an error. VoteOption_VOTE_OPTION_UNSPECIFIED VoteOption = 0 // VOTE_OPTION_YES defines a yes vote option. VoteOption_VOTE_OPTION_YES VoteOption = 1 @@ -7280,15 +7235,20 @@ type ProposalStatus int32 const ( // An empty value is invalid and not allowed. ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED ProposalStatus = 0 - // Initial status of a proposal when persisted. + // Initial status of a proposal when submitted. ProposalStatus_PROPOSAL_STATUS_SUBMITTED ProposalStatus = 1 - // Final status of a proposal when the final tally was executed. - ProposalStatus_PROPOSAL_STATUS_CLOSED ProposalStatus = 2 - // Final status of a proposal when the group was modified before the final tally. - ProposalStatus_PROPOSAL_STATUS_ABORTED ProposalStatus = 3 - // A proposal can be deleted before the voting start time by the owner. When this happens the final status - // is Withdrawn. - ProposalStatus_PROPOSAL_STATUS_WITHDRAWN ProposalStatus = 4 + // Final status of a proposal when the final tally is done and the outcome + // passes the group policy's decision policy. + ProposalStatus_PROPOSAL_STATUS_ACCEPTED ProposalStatus = 2 + // Final status of a proposal when the final tally is done and the outcome + // is rejected by the group policy's decision policy. + ProposalStatus_PROPOSAL_STATUS_REJECTED ProposalStatus = 3 + // Final status of a proposal when the group policy is modified before the + // final tally. + ProposalStatus_PROPOSAL_STATUS_ABORTED ProposalStatus = 4 + // A proposal can be withdrawn before the voting start time by the owner. + // When this happens the final status is Withdrawn. + ProposalStatus_PROPOSAL_STATUS_WITHDRAWN ProposalStatus = 5 ) // Enum value maps for ProposalStatus. @@ -7296,16 +7256,18 @@ var ( ProposalStatus_name = map[int32]string{ 0: "PROPOSAL_STATUS_UNSPECIFIED", 1: "PROPOSAL_STATUS_SUBMITTED", - 2: "PROPOSAL_STATUS_CLOSED", - 3: "PROPOSAL_STATUS_ABORTED", - 4: "PROPOSAL_STATUS_WITHDRAWN", + 2: "PROPOSAL_STATUS_ACCEPTED", + 3: "PROPOSAL_STATUS_REJECTED", + 4: "PROPOSAL_STATUS_ABORTED", + 5: "PROPOSAL_STATUS_WITHDRAWN", } ProposalStatus_value = map[string]int32{ "PROPOSAL_STATUS_UNSPECIFIED": 0, "PROPOSAL_STATUS_SUBMITTED": 1, - "PROPOSAL_STATUS_CLOSED": 2, - "PROPOSAL_STATUS_ABORTED": 3, - "PROPOSAL_STATUS_WITHDRAWN": 4, + "PROPOSAL_STATUS_ACCEPTED": 2, + "PROPOSAL_STATUS_REJECTED": 3, + "PROPOSAL_STATUS_ABORTED": 4, + "PROPOSAL_STATUS_WITHDRAWN": 5, } ) @@ -7336,63 +7298,6 @@ func (ProposalStatus) EnumDescriptor() ([]byte, []int) { return file_cosmos_group_v1_types_proto_rawDescGZIP(), []int{1} } -// ProposalResult defines types of proposal results. -type ProposalResult int32 - -const ( - // An empty value is invalid and not allowed - ProposalResult_PROPOSAL_RESULT_UNSPECIFIED ProposalResult = 0 - // Until a final tally has happened the status is unfinalized - ProposalResult_PROPOSAL_RESULT_UNFINALIZED ProposalResult = 1 - // Final result of the tally - ProposalResult_PROPOSAL_RESULT_ACCEPTED ProposalResult = 2 - // Final result of the tally - ProposalResult_PROPOSAL_RESULT_REJECTED ProposalResult = 3 -) - -// Enum value maps for ProposalResult. -var ( - ProposalResult_name = map[int32]string{ - 0: "PROPOSAL_RESULT_UNSPECIFIED", - 1: "PROPOSAL_RESULT_UNFINALIZED", - 2: "PROPOSAL_RESULT_ACCEPTED", - 3: "PROPOSAL_RESULT_REJECTED", - } - ProposalResult_value = map[string]int32{ - "PROPOSAL_RESULT_UNSPECIFIED": 0, - "PROPOSAL_RESULT_UNFINALIZED": 1, - "PROPOSAL_RESULT_ACCEPTED": 2, - "PROPOSAL_RESULT_REJECTED": 3, - } -) - -func (x ProposalResult) Enum() *ProposalResult { - p := new(ProposalResult) - *p = x - return p -} - -func (x ProposalResult) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (ProposalResult) Descriptor() protoreflect.EnumDescriptor { - return file_cosmos_group_v1_types_proto_enumTypes[2].Descriptor() -} - -func (ProposalResult) Type() protoreflect.EnumType { - return &file_cosmos_group_v1_types_proto_enumTypes[2] -} - -func (x ProposalResult) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use ProposalResult.Descriptor instead. -func (ProposalResult) EnumDescriptor() ([]byte, []int) { - return file_cosmos_group_v1_types_proto_rawDescGZIP(), []int{2} -} - // ProposalExecutorResult defines types of proposal executor results. type ProposalExecutorResult int32 @@ -7434,11 +7339,11 @@ func (x ProposalExecutorResult) String() string { } func (ProposalExecutorResult) Descriptor() protoreflect.EnumDescriptor { - return file_cosmos_group_v1_types_proto_enumTypes[3].Descriptor() + return file_cosmos_group_v1_types_proto_enumTypes[2].Descriptor() } func (ProposalExecutorResult) Type() protoreflect.EnumType { - return &file_cosmos_group_v1_types_proto_enumTypes[3] + return &file_cosmos_group_v1_types_proto_enumTypes[2] } func (x ProposalExecutorResult) Number() protoreflect.EnumNumber { @@ -7447,7 +7352,7 @@ func (x ProposalExecutorResult) Number() protoreflect.EnumNumber { // Deprecated: Use ProposalExecutorResult.Descriptor instead. func (ProposalExecutorResult) EnumDescriptor() ([]byte, []int) { - return file_cosmos_group_v1_types_proto_rawDescGZIP(), []int{3} + return file_cosmos_group_v1_types_proto_rawDescGZIP(), []int{2} } // Member represents a group member with an account address, @@ -7461,7 +7366,7 @@ type Member struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` // weight is the member's voting weight that should be greater than 0. Weight string `protobuf:"bytes,2,opt,name=weight,proto3" json:"weight,omitempty"` - // metadata is any arbitrary metadata to attached to the member. + // metadata is any arbitrary metadata attached to the member. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` // added_at is a timestamp specifying when a member was added. AddedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=added_at,json=addedAt,proto3" json:"added_at,omitempty"` @@ -7552,13 +7457,19 @@ func (x *Members) GetMembers() []*Member { return nil } -// ThresholdDecisionPolicy implements the DecisionPolicy interface +// ThresholdDecisionPolicy is a decision policy where a proposal passes when it +// satisfies the two following conditions: +// 1. The sum of all `YES` voters' weights is greater or equal than the defined +// `threshold`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type ThresholdDecisionPolicy struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // threshold is the minimum weighted sum of yes votes that must be met or exceeded for a proposal to succeed. + // threshold is the minimum weighted sum of `YES` votes that must be met or + // exceeded for a proposal to succeed. Threshold string `protobuf:"bytes,1,opt,name=threshold,proto3" json:"threshold,omitempty"` // windows defines the different windows for voting and execution. Windows *DecisionPolicyWindows `protobuf:"bytes,2,opt,name=windows,proto3" json:"windows,omitempty"` @@ -7598,13 +7509,19 @@ func (x *ThresholdDecisionPolicy) GetWindows() *DecisionPolicyWindows { return nil } -// PercentageDecisionPolicy implements the DecisionPolicy interface +// PercentageDecisionPolicy is a decision policy where a proposal passes when +// it satisfies the two following conditions: +// 1. The percentage of all `YES` voters' weights out of the total group weight +// is greater or equal than the given `percentage`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type PercentageDecisionPolicy struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // percentage is the minimum percentage the weighted sum of yes votes must meet for a proposal to succeed. + // percentage is the minimum percentage the weighted sum of `YES` votes must + // meet for a proposal to succeed. Percentage string `protobuf:"bytes,1,opt,name=percentage,proto3" json:"percentage,omitempty"` // windows defines the different windows for voting and execution. Windows *DecisionPolicyWindows `protobuf:"bytes,2,opt,name=windows,proto3" json:"windows,omitempty"` @@ -7935,40 +7852,39 @@ type Proposal struct { // id is the unique id of the proposal. Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // metadata is any arbitrary metadata to attached to the proposal. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` // proposers are the account addresses of the proposers. Proposers []string `protobuf:"bytes,4,rep,name=proposers,proto3" json:"proposers,omitempty"` // submit_time is a timestamp specifying when a proposal was submitted. SubmitTime *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=submit_time,json=submitTime,proto3" json:"submit_time,omitempty"` - // group_version tracks the version of the group that this proposal corresponds to. - // When group membership is changed, existing proposals from previous group versions will become invalid. + // group_version tracks the version of the group at proposal submission. + // This field is here for informational purposes only. GroupVersion uint64 `protobuf:"varint,6,opt,name=group_version,json=groupVersion,proto3" json:"group_version,omitempty"` - // group_policy_version tracks the version of the group policy that this proposal corresponds to. - // When a decision policy is changed, existing proposals from previous policy versions will become invalid. + // group_policy_version tracks the version of the group policy at proposal submission. + // When a decision policy is changed, existing proposals from previous policy + // versions will become invalid with the `ABORTED` status. + // This field is here for informational purposes only. GroupPolicyVersion uint64 `protobuf:"varint,7,opt,name=group_policy_version,json=groupPolicyVersion,proto3" json:"group_policy_version,omitempty"` // status represents the high level position in the life cycle of the proposal. Initial value is Submitted. Status ProposalStatus `protobuf:"varint,8,opt,name=status,proto3,enum=cosmos.group.v1.ProposalStatus" json:"status,omitempty"` - // result is the final result based on the votes and election rule. Initial value is unfinalized. - // The result is persisted so that clients can always rely on this state and not have to replicate the logic. - Result ProposalResult `protobuf:"varint,9,opt,name=result,proto3,enum=cosmos.group.v1.ProposalResult" json:"result,omitempty"` // final_tally_result contains the sums of all weighted votes for this - // proposal for each vote option, after tallying. When querying a proposal - // via gRPC, this field is not populated until the proposal's voting period - // has ended. - FinalTallyResult *TallyResult `protobuf:"bytes,10,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result,omitempty"` + // proposal for each vote option. It is empty at submission, and only + // populated after tallying, at voting period end or at proposal execution, + // whichever happens first. + FinalTallyResult *TallyResult `protobuf:"bytes,9,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result,omitempty"` // voting_period_end is the timestamp before which voting must be done. // Unless a successfull MsgExec is called before (to execute a proposal whose // tally is successful before the voting period ends), tallying will be done - // at this point, and the `final_tally_result`, as well - // as `status` and `result` fields will be accordingly updated. - VotingPeriodEnd *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=voting_period_end,json=votingPeriodEnd,proto3" json:"voting_period_end,omitempty"` + // at this point, and the `final_tally_result`and `status` fields will be + // accordingly updated. + VotingPeriodEnd *timestamppb.Timestamp `protobuf:"bytes,10,opt,name=voting_period_end,json=votingPeriodEnd,proto3" json:"voting_period_end,omitempty"` // executor_result is the final result based on the votes and election rule. Initial value is NotRun. - ExecutorResult ProposalExecutorResult `protobuf:"varint,12,opt,name=executor_result,json=executorResult,proto3,enum=cosmos.group.v1.ProposalExecutorResult" json:"executor_result,omitempty"` - // messages is a list of Msgs that will be executed if the proposal passes. - Messages []*anypb.Any `protobuf:"bytes,13,rep,name=messages,proto3" json:"messages,omitempty"` + ExecutorResult ProposalExecutorResult `protobuf:"varint,11,opt,name=executor_result,json=executorResult,proto3,enum=cosmos.group.v1.ProposalExecutorResult" json:"executor_result,omitempty"` + // messages is a list of `sdk.Msg`s that will be executed if the proposal passes. + Messages []*anypb.Any `protobuf:"bytes,12,rep,name=messages,proto3" json:"messages,omitempty"` } func (x *Proposal) Reset() { @@ -7998,9 +7914,9 @@ func (x *Proposal) GetId() uint64 { return 0 } -func (x *Proposal) GetAddress() string { +func (x *Proposal) GetGroupPolicyAddress() string { if x != nil { - return x.Address + return x.GroupPolicyAddress } return "" } @@ -8047,13 +7963,6 @@ func (x *Proposal) GetStatus() ProposalStatus { return ProposalStatus_PROPOSAL_STATUS_UNSPECIFIED } -func (x *Proposal) GetResult() ProposalResult { - if x != nil { - return x.Result - } - return ProposalResult_PROPOSAL_RESULT_UNSPECIFIED -} - func (x *Proposal) GetFinalTallyResult() *TallyResult { if x != nil { return x.FinalTallyResult @@ -8092,7 +8001,7 @@ type TallyResult struct { YesCount string `protobuf:"bytes,1,opt,name=yes_count,json=yesCount,proto3" json:"yes_count,omitempty"` // abstain_count is the weighted sum of abstainers. AbstainCount string `protobuf:"bytes,2,opt,name=abstain_count,json=abstainCount,proto3" json:"abstain_count,omitempty"` - // no is the weighted sum of no votes. + // no_count is the weighted sum of no votes. NoCount string `protobuf:"bytes,3,opt,name=no_count,json=noCount,proto3" json:"no_count,omitempty"` // no_with_veto_count is the weighted sum of veto. NoWithVetoCount string `protobuf:"bytes,4,opt,name=no_with_veto_count,json=noWithVetoCount,proto3" json:"no_with_veto_count,omitempty"` @@ -8322,132 +8231,122 @@ var file_cosmos_group_v1_types_proto_rawDesc = []byte{ 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x09, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x64, 0x41, 0x74, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, - 0xa0, 0x1f, 0x01, 0x22, 0xe0, 0x05, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, + 0xa0, 0x1f, 0x01, 0x22, 0xbf, 0x05, 0x0a, 0x08, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, 0x64, - 0x12, 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x07, 0x61, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x12, 0x36, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, - 0x03, 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, 0x09, 0x70, - 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, 0x12, 0x45, 0x0a, 0x0b, 0x73, 0x75, 0x62, 0x6d, - 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, - 0xdf, 0x1f, 0x01, 0x52, 0x0a, 0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, - 0x23, 0x0a, 0x0d, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, - 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x56, 0x65, 0x72, - 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x30, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x56, - 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x37, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, - 0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, - 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, - 0x37, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0e, 0x32, - 0x1f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, - 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, - 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x50, 0x0a, 0x12, 0x66, 0x69, 0x6e, 0x61, - 0x6c, 0x5f, 0x74, 0x61, 0x6c, 0x6c, 0x79, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x0a, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, - 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x10, 0x66, 0x69, 0x6e, 0x61, 0x6c, 0x54, - 0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x50, 0x0a, 0x11, 0x76, 0x6f, - 0x74, 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x5f, 0x65, 0x6e, 0x64, 0x18, - 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, + 0x12, 0x4a, 0x0a, 0x14, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 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, 0x12, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x50, + 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1a, 0x0a, 0x08, + 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, + 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x36, 0x0a, 0x09, 0x70, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x03, 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, 0x09, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x65, 0x72, 0x73, + 0x12, 0x45, 0x0a, 0x0b, 0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0f, 0x76, 0x6f, 0x74, - 0x69, 0x6e, 0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x45, 0x6e, 0x64, 0x12, 0x50, 0x0a, 0x0f, - 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, - 0x0c, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, - 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x0e, - 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x30, - 0x0a, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x18, 0x0d, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, - 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0x9d, 0x01, 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, - 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x79, 0x65, 0x73, 0x5f, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x79, 0x65, 0x73, 0x43, 0x6f, - 0x75, 0x6e, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x62, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x5f, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x62, 0x73, 0x74, - 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x6f, 0x5f, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x6f, 0x43, 0x6f, - 0x75, 0x6e, 0x74, 0x12, 0x2b, 0x0a, 0x12, 0x6e, 0x6f, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x5f, 0x76, - 0x65, 0x74, 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0f, 0x6e, 0x6f, 0x57, 0x69, 0x74, 0x68, 0x56, 0x65, 0x74, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74, - 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0xef, 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, 0x33, 0x0a, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, - 0x32, 0x1b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, - 0x76, 0x31, 0x2e, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x6f, - 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, - 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, - 0x61, 0x12, 0x45, 0x0a, 0x0b, 0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, - 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0a, 0x73, 0x75, - 0x62, 0x6d, 0x69, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x2a, 0x8f, 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, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 0x2a, 0xae, 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, 0x1d, - 0x0a, 0x19, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, - 0x53, 0x5f, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x1a, 0x0a, - 0x16, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, - 0x5f, 0x43, 0x4c, 0x4f, 0x53, 0x45, 0x44, 0x10, 0x02, 0x12, 0x1b, 0x0a, 0x17, 0x50, 0x52, 0x4f, - 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x42, 0x4f, - 0x52, 0x54, 0x45, 0x44, 0x10, 0x03, 0x12, 0x1d, 0x0a, 0x19, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, - 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, - 0x41, 0x57, 0x4e, 0x10, 0x04, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 0x2a, 0x94, 0x01, 0x0a, 0x0e, - 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, - 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, + 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0a, 0x73, 0x75, 0x62, + 0x6d, 0x69, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x30, 0x0a, 0x14, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x76, 0x65, 0x72, + 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x52, 0x12, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x37, + 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1f, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, + 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, + 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x50, 0x0a, 0x12, 0x66, 0x69, 0x6e, 0x61, 0x6c, + 0x5f, 0x74, 0x61, 0x6c, 0x6c, 0x79, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x09, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, + 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, + 0x74, 0x42, 0x04, 0xc8, 0xde, 0x1f, 0x00, 0x52, 0x10, 0x66, 0x69, 0x6e, 0x61, 0x6c, 0x54, 0x61, + 0x6c, 0x6c, 0x79, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x50, 0x0a, 0x11, 0x76, 0x6f, 0x74, + 0x69, 0x6e, 0x67, 0x5f, 0x70, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x5f, 0x65, 0x6e, 0x64, 0x18, 0x0a, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, + 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0f, 0x76, 0x6f, 0x74, 0x69, + 0x6e, 0x67, 0x50, 0x65, 0x72, 0x69, 0x6f, 0x64, 0x45, 0x6e, 0x64, 0x12, 0x50, 0x0a, 0x0f, 0x65, + 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x0b, + 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, + 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x0e, 0x65, + 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x30, 0x0a, + 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x18, 0x0c, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, + 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x08, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x73, 0x3a, + 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0x9d, 0x01, 0x0a, 0x0b, 0x54, 0x61, 0x6c, 0x6c, 0x79, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x79, 0x65, 0x73, 0x5f, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x79, 0x65, 0x73, 0x43, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x62, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x5f, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x61, 0x62, 0x73, 0x74, 0x61, + 0x69, 0x6e, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x6f, 0x5f, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6e, 0x6f, 0x43, 0x6f, 0x75, + 0x6e, 0x74, 0x12, 0x2b, 0x0a, 0x12, 0x6e, 0x6f, 0x5f, 0x77, 0x69, 0x74, 0x68, 0x5f, 0x76, 0x65, + 0x74, 0x6f, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, + 0x6e, 0x6f, 0x57, 0x69, 0x74, 0x68, 0x56, 0x65, 0x74, 0x6f, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x3a, + 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0xef, 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, + 0x33, 0x0a, 0x06, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, + 0x1b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, + 0x31, 0x2e, 0x56, 0x6f, 0x74, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x6f, 0x70, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0x12, 0x45, 0x0a, 0x0b, 0x73, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0x90, 0xdf, 0x1f, 0x01, 0x52, 0x0a, 0x73, 0x75, 0x62, + 0x6d, 0x69, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x2a, 0x8f, 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, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 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, 0x1d, 0x0a, + 0x19, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, + 0x5f, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, + 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, + 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x10, 0x02, 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, 0x03, 0x12, 0x1b, 0x0a, 0x17, 0x50, 0x52, 0x4f, 0x50, + 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x41, 0x42, 0x4f, 0x52, + 0x54, 0x45, 0x44, 0x10, 0x04, 0x12, 0x1d, 0x0a, 0x19, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, + 0x4c, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x55, 0x53, 0x5f, 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, 0x41, + 0x57, 0x4e, 0x10, 0x05, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 0x2a, 0xba, 0x01, 0x0a, 0x16, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x28, 0x0a, 0x24, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, + 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, - 0x1f, 0x0a, 0x1b, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, - 0x4c, 0x54, 0x5f, 0x55, 0x4e, 0x46, 0x49, 0x4e, 0x41, 0x4c, 0x49, 0x5a, 0x45, 0x44, 0x10, 0x01, - 0x12, 0x1c, 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, - 0x55, 0x4c, 0x54, 0x5f, 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x10, 0x02, 0x12, 0x1c, - 0x0a, 0x18, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, - 0x54, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, 0x54, 0x45, 0x44, 0x10, 0x03, 0x1a, 0x04, 0x88, 0xa3, - 0x1e, 0x00, 0x2a, 0xba, 0x01, 0x0a, 0x16, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, - 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x28, 0x0a, - 0x24, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, - 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, - 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x24, 0x0a, 0x20, 0x50, 0x52, 0x4f, 0x50, 0x4f, - 0x53, 0x41, 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, - 0x55, 0x4c, 0x54, 0x5f, 0x4e, 0x4f, 0x54, 0x5f, 0x52, 0x55, 0x4e, 0x10, 0x01, 0x12, 0x24, 0x0a, - 0x20, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, - 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x53, 0x55, 0x43, 0x43, 0x45, 0x53, - 0x53, 0x10, 0x02, 0x12, 0x24, 0x0a, 0x20, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, - 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, - 0x46, 0x41, 0x49, 0x4c, 0x55, 0x52, 0x45, 0x10, 0x03, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 0x42, - 0xb9, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x42, 0x0a, 0x54, 0x79, 0x70, 0x65, 0x73, 0x50, 0x72, - 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x38, 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, - 0x72, 0x6f, 0x75, 0x70, 0x2f, 0x76, 0x31, 0x3b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x76, 0x31, 0xa2, - 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x3a, 0x3a, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x24, 0x0a, 0x20, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, + 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x4e, 0x4f, 0x54, 0x5f, + 0x52, 0x55, 0x4e, 0x10, 0x01, 0x12, 0x24, 0x0a, 0x20, 0x50, 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, + 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, + 0x54, 0x5f, 0x53, 0x55, 0x43, 0x43, 0x45, 0x53, 0x53, 0x10, 0x02, 0x12, 0x24, 0x0a, 0x20, 0x50, + 0x52, 0x4f, 0x50, 0x4f, 0x53, 0x41, 0x4c, 0x5f, 0x45, 0x58, 0x45, 0x43, 0x55, 0x54, 0x4f, 0x52, + 0x5f, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x46, 0x41, 0x49, 0x4c, 0x55, 0x52, 0x45, 0x10, + 0x03, 0x1a, 0x04, 0x88, 0xa3, 0x1e, 0x00, 0x42, 0xb9, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x42, + 0x0a, 0x54, 0x79, 0x70, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x38, 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, 0x72, 0x6f, 0x75, 0x70, 0x2f, 0x76, 0x31, 0x3b, + 0x67, 0x72, 0x6f, 0x75, 0x70, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x0f, + 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x56, 0x31, 0xca, + 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, + 0x31, 0xe2, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, + 0x02, 0x11, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x3a, + 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -8462,53 +8361,51 @@ func file_cosmos_group_v1_types_proto_rawDescGZIP() []byte { return file_cosmos_group_v1_types_proto_rawDescData } -var file_cosmos_group_v1_types_proto_enumTypes = make([]protoimpl.EnumInfo, 4) +var file_cosmos_group_v1_types_proto_enumTypes = make([]protoimpl.EnumInfo, 3) var file_cosmos_group_v1_types_proto_msgTypes = make([]protoimpl.MessageInfo, 11) var file_cosmos_group_v1_types_proto_goTypes = []interface{}{ (VoteOption)(0), // 0: cosmos.group.v1.VoteOption (ProposalStatus)(0), // 1: cosmos.group.v1.ProposalStatus - (ProposalResult)(0), // 2: cosmos.group.v1.ProposalResult - (ProposalExecutorResult)(0), // 3: cosmos.group.v1.ProposalExecutorResult - (*Member)(nil), // 4: cosmos.group.v1.Member - (*Members)(nil), // 5: cosmos.group.v1.Members - (*ThresholdDecisionPolicy)(nil), // 6: cosmos.group.v1.ThresholdDecisionPolicy - (*PercentageDecisionPolicy)(nil), // 7: cosmos.group.v1.PercentageDecisionPolicy - (*DecisionPolicyWindows)(nil), // 8: cosmos.group.v1.DecisionPolicyWindows - (*GroupInfo)(nil), // 9: cosmos.group.v1.GroupInfo - (*GroupMember)(nil), // 10: cosmos.group.v1.GroupMember - (*GroupPolicyInfo)(nil), // 11: cosmos.group.v1.GroupPolicyInfo - (*Proposal)(nil), // 12: cosmos.group.v1.Proposal - (*TallyResult)(nil), // 13: cosmos.group.v1.TallyResult - (*Vote)(nil), // 14: cosmos.group.v1.Vote - (*timestamppb.Timestamp)(nil), // 15: google.protobuf.Timestamp - (*durationpb.Duration)(nil), // 16: google.protobuf.Duration - (*anypb.Any)(nil), // 17: google.protobuf.Any + (ProposalExecutorResult)(0), // 2: cosmos.group.v1.ProposalExecutorResult + (*Member)(nil), // 3: cosmos.group.v1.Member + (*Members)(nil), // 4: cosmos.group.v1.Members + (*ThresholdDecisionPolicy)(nil), // 5: cosmos.group.v1.ThresholdDecisionPolicy + (*PercentageDecisionPolicy)(nil), // 6: cosmos.group.v1.PercentageDecisionPolicy + (*DecisionPolicyWindows)(nil), // 7: cosmos.group.v1.DecisionPolicyWindows + (*GroupInfo)(nil), // 8: cosmos.group.v1.GroupInfo + (*GroupMember)(nil), // 9: cosmos.group.v1.GroupMember + (*GroupPolicyInfo)(nil), // 10: cosmos.group.v1.GroupPolicyInfo + (*Proposal)(nil), // 11: cosmos.group.v1.Proposal + (*TallyResult)(nil), // 12: cosmos.group.v1.TallyResult + (*Vote)(nil), // 13: cosmos.group.v1.Vote + (*timestamppb.Timestamp)(nil), // 14: google.protobuf.Timestamp + (*durationpb.Duration)(nil), // 15: google.protobuf.Duration + (*anypb.Any)(nil), // 16: google.protobuf.Any } var file_cosmos_group_v1_types_proto_depIdxs = []int32{ - 15, // 0: cosmos.group.v1.Member.added_at:type_name -> google.protobuf.Timestamp - 4, // 1: cosmos.group.v1.Members.members:type_name -> cosmos.group.v1.Member - 8, // 2: cosmos.group.v1.ThresholdDecisionPolicy.windows:type_name -> cosmos.group.v1.DecisionPolicyWindows - 8, // 3: cosmos.group.v1.PercentageDecisionPolicy.windows:type_name -> cosmos.group.v1.DecisionPolicyWindows - 16, // 4: cosmos.group.v1.DecisionPolicyWindows.voting_period:type_name -> google.protobuf.Duration - 16, // 5: cosmos.group.v1.DecisionPolicyWindows.min_execution_period:type_name -> google.protobuf.Duration - 15, // 6: cosmos.group.v1.GroupInfo.created_at:type_name -> google.protobuf.Timestamp - 4, // 7: cosmos.group.v1.GroupMember.member:type_name -> cosmos.group.v1.Member - 17, // 8: cosmos.group.v1.GroupPolicyInfo.decision_policy:type_name -> google.protobuf.Any - 15, // 9: cosmos.group.v1.GroupPolicyInfo.created_at:type_name -> google.protobuf.Timestamp - 15, // 10: cosmos.group.v1.Proposal.submit_time:type_name -> google.protobuf.Timestamp + 14, // 0: cosmos.group.v1.Member.added_at:type_name -> google.protobuf.Timestamp + 3, // 1: cosmos.group.v1.Members.members:type_name -> cosmos.group.v1.Member + 7, // 2: cosmos.group.v1.ThresholdDecisionPolicy.windows:type_name -> cosmos.group.v1.DecisionPolicyWindows + 7, // 3: cosmos.group.v1.PercentageDecisionPolicy.windows:type_name -> cosmos.group.v1.DecisionPolicyWindows + 15, // 4: cosmos.group.v1.DecisionPolicyWindows.voting_period:type_name -> google.protobuf.Duration + 15, // 5: cosmos.group.v1.DecisionPolicyWindows.min_execution_period:type_name -> google.protobuf.Duration + 14, // 6: cosmos.group.v1.GroupInfo.created_at:type_name -> google.protobuf.Timestamp + 3, // 7: cosmos.group.v1.GroupMember.member:type_name -> cosmos.group.v1.Member + 16, // 8: cosmos.group.v1.GroupPolicyInfo.decision_policy:type_name -> google.protobuf.Any + 14, // 9: cosmos.group.v1.GroupPolicyInfo.created_at:type_name -> google.protobuf.Timestamp + 14, // 10: cosmos.group.v1.Proposal.submit_time:type_name -> google.protobuf.Timestamp 1, // 11: cosmos.group.v1.Proposal.status:type_name -> cosmos.group.v1.ProposalStatus - 2, // 12: cosmos.group.v1.Proposal.result:type_name -> cosmos.group.v1.ProposalResult - 13, // 13: cosmos.group.v1.Proposal.final_tally_result:type_name -> cosmos.group.v1.TallyResult - 15, // 14: cosmos.group.v1.Proposal.voting_period_end:type_name -> google.protobuf.Timestamp - 3, // 15: cosmos.group.v1.Proposal.executor_result:type_name -> cosmos.group.v1.ProposalExecutorResult - 17, // 16: cosmos.group.v1.Proposal.messages:type_name -> google.protobuf.Any - 0, // 17: cosmos.group.v1.Vote.option:type_name -> cosmos.group.v1.VoteOption - 15, // 18: cosmos.group.v1.Vote.submit_time:type_name -> google.protobuf.Timestamp - 19, // [19:19] is the sub-list for method output_type - 19, // [19:19] is the sub-list for method input_type - 19, // [19:19] is the sub-list for extension type_name - 19, // [19:19] is the sub-list for extension extendee - 0, // [0:19] is the sub-list for field type_name + 12, // 12: cosmos.group.v1.Proposal.final_tally_result:type_name -> cosmos.group.v1.TallyResult + 14, // 13: cosmos.group.v1.Proposal.voting_period_end:type_name -> google.protobuf.Timestamp + 2, // 14: cosmos.group.v1.Proposal.executor_result:type_name -> cosmos.group.v1.ProposalExecutorResult + 16, // 15: cosmos.group.v1.Proposal.messages:type_name -> google.protobuf.Any + 0, // 16: cosmos.group.v1.Vote.option:type_name -> cosmos.group.v1.VoteOption + 14, // 17: cosmos.group.v1.Vote.submit_time:type_name -> google.protobuf.Timestamp + 18, // [18:18] is the sub-list for method output_type + 18, // [18:18] is the sub-list for method input_type + 18, // [18:18] is the sub-list for extension type_name + 18, // [18:18] is the sub-list for extension extendee + 0, // [0:18] is the sub-list for field type_name } func init() { file_cosmos_group_v1_types_proto_init() } @@ -8655,7 +8552,7 @@ func file_cosmos_group_v1_types_proto_init() { File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cosmos_group_v1_types_proto_rawDesc, - NumEnums: 4, + NumEnums: 3, NumMessages: 11, NumExtensions: 0, NumServices: 0, diff --git a/proto/cosmos/group/v1/events.proto b/proto/cosmos/group/v1/events.proto index e8907243aa..e8b457c89a 100644 --- a/proto/cosmos/group/v1/events.proto +++ b/proto/cosmos/group/v1/events.proto @@ -1,3 +1,4 @@ +// Since: cosmos-sdk 0.46 syntax = "proto3"; package cosmos.group.v1; diff --git a/proto/cosmos/group/v1/genesis.proto b/proto/cosmos/group/v1/genesis.proto index 49655ad2fa..e4c895e96e 100644 --- a/proto/cosmos/group/v1/genesis.proto +++ b/proto/cosmos/group/v1/genesis.proto @@ -1,3 +1,4 @@ +// Since: cosmos-sdk 0.46 syntax = "proto3"; package cosmos.group.v1; diff --git a/proto/cosmos/group/v1/query.proto b/proto/cosmos/group/v1/query.proto index 1690d5b731..51a011a9db 100644 --- a/proto/cosmos/group/v1/query.proto +++ b/proto/cosmos/group/v1/query.proto @@ -1,3 +1,4 @@ +// Since: cosmos-sdk 0.46 syntax = "proto3"; package cosmos.group.v1; @@ -73,7 +74,11 @@ service Query { option (google.api.http).get = "/cosmos/group/v1/groups_by_member/{address}"; }; - // TallyResult queries the tally of a proposal votes. + // TallyResult returns the tally result of a proposal. If the proposal is + // still in voting period, then this query computes the current tally state, + // which might not be final. On the other hand, if the proposal is final, + // then it simply returns the `final_tally_result` state stored in the + // proposal itself. rpc TallyResult(QueryTallyResultRequest) returns (QueryTallyResultResponse) { option (google.api.http).get = "/cosmos/group/v1/proposals/{proposal_id}/tally"; }; diff --git a/proto/cosmos/group/v1/tx.proto b/proto/cosmos/group/v1/tx.proto index 08d83ede87..4a3deae502 100644 --- a/proto/cosmos/group/v1/tx.proto +++ b/proto/cosmos/group/v1/tx.proto @@ -1,3 +1,4 @@ +// Since: cosmos-sdk 0.46 syntax = "proto3"; package cosmos.group.v1; @@ -65,6 +66,7 @@ service Msg { // MsgCreateGroup is the Msg/CreateGroup request type. message MsgCreateGroup { option (cosmos.msg.v1.signer) = "admin"; + // admin is the account address of the group admin. string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; @@ -171,8 +173,8 @@ message MsgUpdateGroupPolicyAdmin { // admin is the account address of the group admin. string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // address is the account address of the group policy. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // group_policy_address is the account address of the group policy. + string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // new_admin is the new group policy admin. string new_admin = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; @@ -180,6 +182,7 @@ message MsgUpdateGroupPolicyAdmin { // MsgCreateGroupWithPolicy is the Msg/CreateGroupWithPolicy request type. message MsgCreateGroupWithPolicy { + option (cosmos.msg.v1.signer) = "admin"; option (gogoproto.goproto_getters) = false; // admin is the account address of the group and group policy admin. @@ -194,8 +197,9 @@ message MsgCreateGroupWithPolicy { // group_policy_metadata is any arbitrary metadata attached to the group policy. string group_policy_metadata = 4; - // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group and group policy admin. - bool group_policy_as_admin = 5; + // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group + // and group policy admin. + bool group_policy_as_admin = 5; // decision_policy specifies the group policy's decision policy. google.protobuf.Any decision_policy = 6 [(cosmos_proto.accepts_interface) = "DecisionPolicy"]; @@ -223,8 +227,8 @@ message MsgUpdateGroupPolicyDecisionPolicy { // admin is the account address of the group admin. string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // address is the account address of group policy. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // group_policy_address is the account address of group policy. + string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // decision_policy is the updated group policy's decision policy. google.protobuf.Any decision_policy = 3 [(cosmos_proto.accepts_interface) = "DecisionPolicy"]; @@ -240,8 +244,8 @@ message MsgUpdateGroupPolicyMetadata { // admin is the account address of the group admin. string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // address is the account address of group policy. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // group_policy_address is the account address of group policy. + string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // metadata is the updated group policy metadata. string metadata = 3; @@ -274,8 +278,8 @@ message MsgSubmitProposal { option (gogoproto.goproto_getters) = false; - // address is the account address of group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // group_policy_address is the account address of group policy. + string group_policy_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // proposers are the account addresses of the proposers. // Proposers signatures will be counted as yes votes. @@ -302,6 +306,8 @@ message MsgSubmitProposalResponse { // MsgWithdrawProposal is the Msg/WithdrawProposal request type. message MsgWithdrawProposal { + option (cosmos.msg.v1.signer) = "address"; + // proposal is the unique ID of the proposal. uint64 proposal_id = 1; @@ -342,8 +348,8 @@ message MsgExec { // proposal is the unique ID of the proposal. uint64 proposal_id = 1; - // signer is the account address used to execute the proposal. - string signer = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // executor is the account address used to execute the proposal. + string executor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; } // MsgExecResponse is the Msg/Exec request type. diff --git a/proto/cosmos/group/v1/types.proto b/proto/cosmos/group/v1/types.proto index e09a74c135..ec6cd744d8 100644 --- a/proto/cosmos/group/v1/types.proto +++ b/proto/cosmos/group/v1/types.proto @@ -1,3 +1,4 @@ +// Since: cosmos-sdk 0.46 syntax = "proto3"; package cosmos.group.v1; @@ -20,7 +21,7 @@ message Member { // weight is the member's voting weight that should be greater than 0. string weight = 2; - // metadata is any arbitrary metadata to attached to the member. + // metadata is any arbitrary metadata attached to the member. string metadata = 3; // added_at is a timestamp specifying when a member was added. @@ -34,22 +35,34 @@ message Members { repeated Member members = 1 [(gogoproto.nullable) = false]; } -// ThresholdDecisionPolicy implements the DecisionPolicy interface +// ThresholdDecisionPolicy is a decision policy where a proposal passes when it +// satisfies the two following conditions: +// 1. The sum of all `YES` voters' weights is greater or equal than the defined +// `threshold`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. message ThresholdDecisionPolicy { option (cosmos_proto.implements_interface) = "DecisionPolicy"; - // threshold is the minimum weighted sum of yes votes that must be met or exceeded for a proposal to succeed. + // threshold is the minimum weighted sum of `YES` votes that must be met or + // exceeded for a proposal to succeed. string threshold = 1; // windows defines the different windows for voting and execution. DecisionPolicyWindows windows = 2; } -// PercentageDecisionPolicy implements the DecisionPolicy interface +// PercentageDecisionPolicy is a decision policy where a proposal passes when +// it satisfies the two following conditions: +// 1. The percentage of all `YES` voters' weights out of the total group weight +// is greater or equal than the given `percentage`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. message PercentageDecisionPolicy { option (cosmos_proto.implements_interface) = "DecisionPolicy"; - // percentage is the minimum percentage the weighted sum of yes votes must meet for a proposal to succeed. + // percentage is the minimum percentage the weighted sum of `YES` votes must + // meet for a proposal to succeed. string percentage = 1; // windows defines the different windows for voting and execution. @@ -80,7 +93,8 @@ message DecisionPolicyWindows { enum VoteOption { option (gogoproto.goproto_enum_prefix) = false; - // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. + // VOTE_OPTION_UNSPECIFIED defines an unspecified vote option which will + // return an error. VOTE_OPTION_UNSPECIFIED = 0; // VOTE_OPTION_YES defines a yes vote option. VOTE_OPTION_YES = 1; @@ -169,8 +183,8 @@ message Proposal { // id is the unique id of the proposal. uint64 id = 1; - // address is the account address of group policy. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // group_policy_address is the account address of group policy. + string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // metadata is any arbitrary metadata to attached to the proposal. string metadata = 3; @@ -181,39 +195,37 @@ message Proposal { // submit_time is a timestamp specifying when a proposal was submitted. google.protobuf.Timestamp submit_time = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - // group_version tracks the version of the group that this proposal corresponds to. - // When group membership is changed, existing proposals from previous group versions will become invalid. + // group_version tracks the version of the group at proposal submission. + // This field is here for informational purposes only. uint64 group_version = 6; - // group_policy_version tracks the version of the group policy that this proposal corresponds to. - // When a decision policy is changed, existing proposals from previous policy versions will become invalid. + // group_policy_version tracks the version of the group policy at proposal submission. + // When a decision policy is changed, existing proposals from previous policy + // versions will become invalid with the `ABORTED` status. + // This field is here for informational purposes only. uint64 group_policy_version = 7; // status represents the high level position in the life cycle of the proposal. Initial value is Submitted. ProposalStatus status = 8; - // result is the final result based on the votes and election rule. Initial value is unfinalized. - // The result is persisted so that clients can always rely on this state and not have to replicate the logic. - ProposalResult result = 9; - // final_tally_result contains the sums of all weighted votes for this - // proposal for each vote option, after tallying. When querying a proposal - // via gRPC, this field is not populated until the proposal's voting period - // has ended. - TallyResult final_tally_result = 10 [(gogoproto.nullable) = false]; + // proposal for each vote option. It is empty at submission, and only + // populated after tallying, at voting period end or at proposal execution, + // whichever happens first. + TallyResult final_tally_result = 9 [(gogoproto.nullable) = false]; // voting_period_end is the timestamp before which voting must be done. // Unless a successfull MsgExec is called before (to execute a proposal whose // tally is successful before the voting period ends), tallying will be done - // at this point, and the `final_tally_result`, as well - // as `status` and `result` fields will be accordingly updated. - google.protobuf.Timestamp voting_period_end = 11 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; + // at this point, and the `final_tally_result`and `status` fields will be + // accordingly updated. + google.protobuf.Timestamp voting_period_end = 10 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; // executor_result is the final result based on the votes and election rule. Initial value is NotRun. - ProposalExecutorResult executor_result = 12; + ProposalExecutorResult executor_result = 11; - // messages is a list of Msgs that will be executed if the proposal passes. - repeated google.protobuf.Any messages = 13; + // messages is a list of `sdk.Msg`s that will be executed if the proposal passes. + repeated google.protobuf.Any messages = 12; } // ProposalStatus defines proposal statuses. @@ -223,35 +235,24 @@ enum ProposalStatus { // An empty value is invalid and not allowed. PROPOSAL_STATUS_UNSPECIFIED = 0; - // Initial status of a proposal when persisted. + // Initial status of a proposal when submitted. PROPOSAL_STATUS_SUBMITTED = 1; - // Final status of a proposal when the final tally was executed. - PROPOSAL_STATUS_CLOSED = 2; + // Final status of a proposal when the final tally is done and the outcome + // passes the group policy's decision policy. + PROPOSAL_STATUS_ACCEPTED = 2; - // Final status of a proposal when the group was modified before the final tally. - PROPOSAL_STATUS_ABORTED = 3; + // Final status of a proposal when the final tally is done and the outcome + // is rejected by the group policy's decision policy. + PROPOSAL_STATUS_REJECTED = 3; - // A proposal can be deleted before the voting start time by the owner. When this happens the final status - // is Withdrawn. - PROPOSAL_STATUS_WITHDRAWN = 4; -} + // Final status of a proposal when the group policy is modified before the + // final tally. + PROPOSAL_STATUS_ABORTED = 4; -// ProposalResult defines types of proposal results. -enum ProposalResult { - option (gogoproto.goproto_enum_prefix) = false; - - // An empty value is invalid and not allowed - PROPOSAL_RESULT_UNSPECIFIED = 0; - - // Until a final tally has happened the status is unfinalized - PROPOSAL_RESULT_UNFINALIZED = 1; - - // Final result of the tally - PROPOSAL_RESULT_ACCEPTED = 2; - - // Final result of the tally - PROPOSAL_RESULT_REJECTED = 3; + // A proposal can be withdrawn before the voting start time by the owner. + // When this happens the final status is Withdrawn. + PROPOSAL_STATUS_WITHDRAWN = 5; } // ProposalExecutorResult defines types of proposal executor results. @@ -281,7 +282,7 @@ message TallyResult { // abstain_count is the weighted sum of abstainers. string abstain_count = 2; - // no is the weighted sum of no votes. + // no_count is the weighted sum of no votes. string no_count = 3; // no_with_veto_count is the weighted sum of veto. diff --git a/x/group/client/cli/tx.go b/x/group/client/cli/tx.go index 3a3602f874..ff92542e90 100644 --- a/x/group/client/cli/tx.go +++ b/x/group/client/cli/tx.go @@ -448,9 +448,9 @@ func MsgUpdateGroupPolicyAdminCmd() *cobra.Command { } msg := &group.MsgUpdateGroupPolicyAdmin{ - Admin: clientCtx.GetFromAddress().String(), - Address: args[1], - NewAdmin: args[2], + Admin: clientCtx.GetFromAddress().String(), + GroupPolicyAddress: args[1], + NewAdmin: args[2], } if err = msg.ValidateBasic(); err != nil { return fmt.Errorf("message validation failed: %w", err) @@ -532,9 +532,9 @@ func MsgUpdateGroupPolicyMetadataCmd() *cobra.Command { } msg := &group.MsgUpdateGroupPolicyMetadata{ - Admin: clientCtx.GetFromAddress().String(), - Address: args[1], - Metadata: args[2], + Admin: clientCtx.GetFromAddress().String(), + GroupPolicyAddress: args[1], + Metadata: args[2], } if err = msg.ValidateBasic(); err != nil { return fmt.Errorf("message validation failed: %w", err) @@ -763,7 +763,7 @@ func MsgExecCmd() *cobra.Command { msg := &group.MsgExec{ ProposalId: proposalID, - Signer: clientCtx.GetFromAddress().String(), + Executor: clientCtx.GetFromAddress().String(), } if err != nil { return err diff --git a/x/group/genesis.go b/x/group/genesis.go index 80952a6489..0c1c0c7d73 100644 --- a/x/group/genesis.go +++ b/x/group/genesis.go @@ -54,8 +54,8 @@ func (s GenesisState) Validate() error { for _, p := range s.Proposals { // check that group policy with proposal address exists - if _, exists := groupPolicies[p.Address]; !exists { - return sdkerrors.Wrap(sdkerrors.ErrNotFound, fmt.Sprintf("group policy account with address %s doesn't correspond to proposal address", p.Address)) + if _, exists := groupPolicies[p.GroupPolicyAddress]; !exists { + return sdkerrors.Wrap(sdkerrors.ErrNotFound, fmt.Sprintf("group policy account with address %s doesn't correspond to proposal address", p.GroupPolicyAddress)) } if err := p.ValidateBasic(); err != nil { diff --git a/x/group/genesis_test.go b/x/group/genesis_test.go index 2300836d6f..99f7a008fa 100644 --- a/x/group/genesis_test.go +++ b/x/group/genesis_test.go @@ -55,7 +55,7 @@ func TestGenesisStateValidate(t *testing.T) { proposal := &Proposal{ Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -63,8 +63,7 @@ func TestGenesisStateValidate(t *testing.T) { memberAddr.String(), }, SubmitTime: submittedAt, - Status: PROPOSAL_STATUS_CLOSED, - Result: PROPOSAL_RESULT_ACCEPTED, + Status: PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: TallyResult{ YesCount: "1", NoCount: "0", @@ -376,7 +375,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 0, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -403,7 +402,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: "invalid address", + GroupPolicyAddress: "invalid address", Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -430,7 +429,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 0, GroupPolicyVersion: 1, @@ -457,7 +456,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 0, @@ -484,7 +483,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -492,8 +491,7 @@ func TestGenesisStateValidate(t *testing.T) { memberAddr.String(), }, SubmitTime: submittedAt, - Status: PROPOSAL_STATUS_CLOSED, - Result: PROPOSAL_RESULT_ACCEPTED, + Status: PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: TallyResult{ YesCount: "-1", NoCount: "0", @@ -523,7 +521,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -531,8 +529,7 @@ func TestGenesisStateValidate(t *testing.T) { memberAddr.String(), }, SubmitTime: submittedAt, - Status: PROPOSAL_STATUS_CLOSED, - Result: PROPOSAL_RESULT_ACCEPTED, + Status: PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: TallyResult{ YesCount: "0", NoCount: "-1", @@ -562,7 +559,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -570,8 +567,7 @@ func TestGenesisStateValidate(t *testing.T) { memberAddr.String(), }, SubmitTime: submittedAt, - Status: PROPOSAL_STATUS_CLOSED, - Result: PROPOSAL_RESULT_ACCEPTED, + Status: PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: TallyResult{ YesCount: "0", NoCount: "0", @@ -601,7 +597,7 @@ func TestGenesisStateValidate(t *testing.T) { Proposals: []*Proposal{ { Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -609,8 +605,7 @@ func TestGenesisStateValidate(t *testing.T) { memberAddr.String(), }, SubmitTime: submittedAt, - Status: PROPOSAL_STATUS_CLOSED, - Result: PROPOSAL_RESULT_ACCEPTED, + Status: PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: TallyResult{ YesCount: "0", NoCount: "0", diff --git a/x/group/keeper/genesis_test.go b/x/group/keeper/genesis_test.go index fe824025df..27b0582e3c 100644 --- a/x/group/keeper/genesis_test.go +++ b/x/group/keeper/genesis_test.go @@ -81,7 +81,7 @@ func (s *GenesisTestSuite) TestInitExportGenesis() { proposal := &group.Proposal{ Id: 1, - Address: accAddr.String(), + GroupPolicyAddress: accAddr.String(), Metadata: "proposal metadata", GroupVersion: 1, GroupPolicyVersion: 1, @@ -89,8 +89,7 @@ func (s *GenesisTestSuite) TestInitExportGenesis() { memberAddr.String(), }, SubmitTime: submittedAt, - Status: group.PROPOSAL_STATUS_CLOSED, - Result: group.PROPOSAL_RESULT_ACCEPTED, + Status: group.PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: group.TallyResult{ YesCount: "1", NoCount: "0", @@ -209,14 +208,13 @@ func (s *GenesisTestSuite) assertGroupPoliciesEqual(g *group.GroupPolicyInfo, ot func (s *GenesisTestSuite) assertProposalsEqual(g *group.Proposal, other *group.Proposal) { require := s.Require() require.Equal(g.Id, other.Id) - require.Equal(g.Address, other.Address) + require.Equal(g.GroupPolicyAddress, other.GroupPolicyAddress) require.Equal(g.Metadata, other.Metadata) require.Equal(g.Proposers, other.Proposers) require.Equal(g.SubmitTime, other.SubmitTime) require.Equal(g.GroupVersion, other.GroupVersion) require.Equal(g.GroupPolicyVersion, other.GroupPolicyVersion) require.Equal(g.Status, other.Status) - require.Equal(g.Result, other.Result) require.Equal(g.FinalTallyResult, other.FinalTallyResult) require.Equal(g.VotingPeriodEnd, other.VotingPeriodEnd) require.Equal(g.ExecutorResult, other.ExecutorResult) diff --git a/x/group/keeper/grpc_query.go b/x/group/keeper/grpc_query.go index 483e05e57e..f9bef8c8b2 100644 --- a/x/group/keeper/grpc_query.go +++ b/x/group/keeper/grpc_query.go @@ -16,10 +16,11 @@ import ( var _ group.QueryServer = Keeper{} -func (q Keeper) GroupInfo(goCtx context.Context, request *group.QueryGroupInfoRequest) (*group.QueryGroupInfoResponse, error) { +// GroupInfo queries info about a group. +func (k Keeper) GroupInfo(goCtx context.Context, request *group.QueryGroupInfoRequest) (*group.QueryGroupInfoResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) groupID := request.GroupId - groupInfo, err := q.getGroupInfo(ctx, groupID) + groupInfo, err := k.getGroupInfo(ctx, groupID) if err != nil { return nil, sdkerrors.Wrap(err, "group") } @@ -27,15 +28,16 @@ func (q Keeper) GroupInfo(goCtx context.Context, request *group.QueryGroupInfoRe return &group.QueryGroupInfoResponse{Info: &groupInfo}, nil } -func (q Keeper) getGroupInfo(ctx sdk.Context, id uint64) (group.GroupInfo, error) { +func (k Keeper) getGroupInfo(ctx sdk.Context, id uint64) (group.GroupInfo, error) { var obj group.GroupInfo - _, err := q.groupTable.GetOne(ctx.KVStore(q.key), id, &obj) + _, err := k.groupTable.GetOne(ctx.KVStore(k.key), id, &obj) return obj, err } -func (q Keeper) GroupPolicyInfo(goCtx context.Context, request *group.QueryGroupPolicyInfoRequest) (*group.QueryGroupPolicyInfoResponse, error) { +// GroupPolicyInfo queries info about a group policy. +func (k Keeper) GroupPolicyInfo(goCtx context.Context, request *group.QueryGroupPolicyInfoRequest) (*group.QueryGroupPolicyInfoResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) - groupPolicyInfo, err := q.getGroupPolicyInfo(ctx, request.Address) + groupPolicyInfo, err := k.getGroupPolicyInfo(ctx, request.Address) if err != nil { return nil, sdkerrors.Wrap(err, "group policy") } @@ -43,15 +45,16 @@ func (q Keeper) GroupPolicyInfo(goCtx context.Context, request *group.QueryGroup return &group.QueryGroupPolicyInfoResponse{Info: &groupPolicyInfo}, nil } -func (q Keeper) getGroupPolicyInfo(ctx sdk.Context, accountAddress string) (group.GroupPolicyInfo, error) { +func (k Keeper) getGroupPolicyInfo(ctx sdk.Context, accountAddress string) (group.GroupPolicyInfo, error) { var obj group.GroupPolicyInfo - return obj, q.groupPolicyTable.GetOne(ctx.KVStore(q.key), orm.PrimaryKey(&group.GroupPolicyInfo{Address: accountAddress}), &obj) + return obj, k.groupPolicyTable.GetOne(ctx.KVStore(k.key), orm.PrimaryKey(&group.GroupPolicyInfo{Address: accountAddress}), &obj) } -func (q Keeper) GroupMembers(goCtx context.Context, request *group.QueryGroupMembersRequest) (*group.QueryGroupMembersResponse, error) { +// GroupMembers queries all members of a group. +func (k Keeper) GroupMembers(goCtx context.Context, request *group.QueryGroupMembersRequest) (*group.QueryGroupMembersResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) groupID := request.GroupId - it, err := q.getGroupMembers(ctx, groupID, request.Pagination) + it, err := k.getGroupMembers(ctx, groupID, request.Pagination) if err != nil { return nil, err } @@ -68,17 +71,18 @@ func (q Keeper) GroupMembers(goCtx context.Context, request *group.QueryGroupMem }, nil } -func (q Keeper) getGroupMembers(ctx sdk.Context, id uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.groupMemberByGroupIndex.GetPaginated(ctx.KVStore(q.key), id, pageRequest) +func (k Keeper) getGroupMembers(ctx sdk.Context, id uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.groupMemberByGroupIndex.GetPaginated(ctx.KVStore(k.key), id, pageRequest) } -func (q Keeper) GroupsByAdmin(goCtx context.Context, request *group.QueryGroupsByAdminRequest) (*group.QueryGroupsByAdminResponse, error) { +// GroupsByAdmin queries all groups where a given address is admin. +func (k Keeper) GroupsByAdmin(goCtx context.Context, request *group.QueryGroupsByAdminRequest) (*group.QueryGroupsByAdminResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.AccAddressFromBech32(request.Admin) if err != nil { return nil, err } - it, err := q.getGroupsByAdmin(ctx, addr, request.Pagination) + it, err := k.getGroupsByAdmin(ctx, addr, request.Pagination) if err != nil { return nil, err } @@ -95,14 +99,15 @@ func (q Keeper) GroupsByAdmin(goCtx context.Context, request *group.QueryGroupsB }, nil } -func (q Keeper) getGroupsByAdmin(ctx sdk.Context, admin sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.groupByAdminIndex.GetPaginated(ctx.KVStore(q.key), admin.Bytes(), pageRequest) +func (k Keeper) getGroupsByAdmin(ctx sdk.Context, admin sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.groupByAdminIndex.GetPaginated(ctx.KVStore(k.key), admin.Bytes(), pageRequest) } -func (q Keeper) GroupPoliciesByGroup(goCtx context.Context, request *group.QueryGroupPoliciesByGroupRequest) (*group.QueryGroupPoliciesByGroupResponse, error) { +// GroupPoliciesByGroup queries all groups policies of a given group. +func (k Keeper) GroupPoliciesByGroup(goCtx context.Context, request *group.QueryGroupPoliciesByGroupRequest) (*group.QueryGroupPoliciesByGroupResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) groupID := request.GroupId - it, err := q.getGroupPoliciesByGroup(ctx, groupID, request.Pagination) + it, err := k.getGroupPoliciesByGroup(ctx, groupID, request.Pagination) if err != nil { return nil, err } @@ -119,17 +124,19 @@ func (q Keeper) GroupPoliciesByGroup(goCtx context.Context, request *group.Query }, nil } -func (q Keeper) getGroupPoliciesByGroup(ctx sdk.Context, id uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.groupPolicyByGroupIndex.GetPaginated(ctx.KVStore(q.key), id, pageRequest) +func (k Keeper) getGroupPoliciesByGroup(ctx sdk.Context, id uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.groupPolicyByGroupIndex.GetPaginated(ctx.KVStore(k.key), id, pageRequest) } -func (q Keeper) GroupPoliciesByAdmin(goCtx context.Context, request *group.QueryGroupPoliciesByAdminRequest) (*group.QueryGroupPoliciesByAdminResponse, error) { +// GroupPoliciesByAdmin queries all groups policies where a given address is +// admin. +func (k Keeper) GroupPoliciesByAdmin(goCtx context.Context, request *group.QueryGroupPoliciesByAdminRequest) (*group.QueryGroupPoliciesByAdminResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.AccAddressFromBech32(request.Admin) if err != nil { return nil, err } - it, err := q.getGroupPoliciesByAdmin(ctx, addr, request.Pagination) + it, err := k.getGroupPoliciesByAdmin(ctx, addr, request.Pagination) if err != nil { return nil, err } @@ -146,14 +153,15 @@ func (q Keeper) GroupPoliciesByAdmin(goCtx context.Context, request *group.Query }, nil } -func (q Keeper) getGroupPoliciesByAdmin(ctx sdk.Context, admin sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.groupPolicyByAdminIndex.GetPaginated(ctx.KVStore(q.key), admin.Bytes(), pageRequest) +func (k Keeper) getGroupPoliciesByAdmin(ctx sdk.Context, admin sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.groupPolicyByAdminIndex.GetPaginated(ctx.KVStore(k.key), admin.Bytes(), pageRequest) } -func (q Keeper) Proposal(goCtx context.Context, request *group.QueryProposalRequest) (*group.QueryProposalResponse, error) { +// Proposal queries a proposal. +func (k Keeper) Proposal(goCtx context.Context, request *group.QueryProposalRequest) (*group.QueryProposalResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) proposalID := request.ProposalId - proposal, err := q.getProposal(ctx, proposalID) + proposal, err := k.getProposal(ctx, proposalID) if err != nil { return nil, err } @@ -161,13 +169,14 @@ func (q Keeper) Proposal(goCtx context.Context, request *group.QueryProposalRequ return &group.QueryProposalResponse{Proposal: &proposal}, nil } -func (q Keeper) ProposalsByGroupPolicy(goCtx context.Context, request *group.QueryProposalsByGroupPolicyRequest) (*group.QueryProposalsByGroupPolicyResponse, error) { +// Proposal queries all proposals of a group policy. +func (k Keeper) ProposalsByGroupPolicy(goCtx context.Context, request *group.QueryProposalsByGroupPolicyRequest) (*group.QueryProposalsByGroupPolicyResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.AccAddressFromBech32(request.Address) if err != nil { return nil, err } - it, err := q.getProposalsByGroupPolicy(ctx, addr, request.Pagination) + it, err := k.getProposalsByGroupPolicy(ctx, addr, request.Pagination) if err != nil { return nil, err } @@ -184,26 +193,27 @@ func (q Keeper) ProposalsByGroupPolicy(goCtx context.Context, request *group.Que }, nil } -func (q Keeper) getProposalsByGroupPolicy(ctx sdk.Context, account sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.proposalByGroupPolicyIndex.GetPaginated(ctx.KVStore(q.key), account.Bytes(), pageRequest) +func (k Keeper) getProposalsByGroupPolicy(ctx sdk.Context, account sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.proposalByGroupPolicyIndex.GetPaginated(ctx.KVStore(k.key), account.Bytes(), pageRequest) } -func (q Keeper) getProposal(ctx sdk.Context, proposalID uint64) (group.Proposal, error) { +func (k Keeper) getProposal(ctx sdk.Context, proposalID uint64) (group.Proposal, error) { var p group.Proposal - if _, err := q.proposalTable.GetOne(ctx.KVStore(q.key), proposalID, &p); err != nil { + if _, err := k.proposalTable.GetOne(ctx.KVStore(k.key), proposalID, &p); err != nil { return group.Proposal{}, sdkerrors.Wrap(err, "load proposal") } return p, nil } -func (q Keeper) VoteByProposalVoter(goCtx context.Context, request *group.QueryVoteByProposalVoterRequest) (*group.QueryVoteByProposalVoterResponse, error) { +// VoteByProposalVoter queries a vote given a voter and a proposal ID. +func (k Keeper) VoteByProposalVoter(goCtx context.Context, request *group.QueryVoteByProposalVoterRequest) (*group.QueryVoteByProposalVoterResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.AccAddressFromBech32(request.Voter) if err != nil { return nil, err } proposalID := request.ProposalId - vote, err := q.getVote(ctx, proposalID, addr) + vote, err := k.getVote(ctx, proposalID, addr) if err != nil { return nil, err } @@ -212,10 +222,11 @@ func (q Keeper) VoteByProposalVoter(goCtx context.Context, request *group.QueryV }, nil } -func (q Keeper) VotesByProposal(goCtx context.Context, request *group.QueryVotesByProposalRequest) (*group.QueryVotesByProposalResponse, error) { +// VotesByProposal queries all votes on a proposal. +func (k Keeper) VotesByProposal(goCtx context.Context, request *group.QueryVotesByProposalRequest) (*group.QueryVotesByProposalResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) proposalID := request.ProposalId - it, err := q.getVotesByProposal(ctx, proposalID, request.Pagination) + it, err := k.getVotesByProposal(ctx, proposalID, request.Pagination) if err != nil { return nil, err } @@ -232,13 +243,14 @@ func (q Keeper) VotesByProposal(goCtx context.Context, request *group.QueryVotes }, nil } -func (q Keeper) VotesByVoter(goCtx context.Context, request *group.QueryVotesByVoterRequest) (*group.QueryVotesByVoterResponse, error) { +// VotesByProposal queries all votes of a voter. +func (k Keeper) VotesByVoter(goCtx context.Context, request *group.QueryVotesByVoterRequest) (*group.QueryVotesByVoterResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.AccAddressFromBech32(request.Voter) if err != nil { return nil, err } - it, err := q.getVotesByVoter(ctx, addr, request.Pagination) + it, err := k.getVotesByVoter(ctx, addr, request.Pagination) if err != nil { return nil, err } @@ -255,7 +267,8 @@ func (q Keeper) VotesByVoter(goCtx context.Context, request *group.QueryVotesByV }, nil } -func (q Keeper) GroupsByMember(goCtx context.Context, request *group.QueryGroupsByMemberRequest) (*group.QueryGroupsByMemberResponse, error) { +// GroupsByMember queries all groups where the given address is a member of. +func (k Keeper) GroupsByMember(goCtx context.Context, request *group.QueryGroupsByMemberRequest) (*group.QueryGroupsByMemberResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } @@ -266,7 +279,7 @@ func (q Keeper) GroupsByMember(goCtx context.Context, request *group.QueryGroups return nil, err } - iter, err := q.groupMemberByMemberIndex.GetPaginated(ctx.KVStore(q.key), member.Bytes(), request.Pagination) + iter, err := k.groupMemberByMemberIndex.GetPaginated(ctx.KVStore(k.key), member.Bytes(), request.Pagination) if err != nil { return nil, err } @@ -279,7 +292,7 @@ func (q Keeper) GroupsByMember(goCtx context.Context, request *group.QueryGroups var groups []*group.GroupInfo for _, gm := range members { - groupInfo, err := q.getGroupInfo(ctx, gm.GroupId) + groupInfo, err := k.getGroupInfo(ctx, gm.GroupId) if err != nil { return nil, err } @@ -292,24 +305,25 @@ func (q Keeper) GroupsByMember(goCtx context.Context, request *group.QueryGroups }, nil } -func (q Keeper) getVote(ctx sdk.Context, proposalID uint64, voter sdk.AccAddress) (group.Vote, error) { +func (k Keeper) getVote(ctx sdk.Context, proposalID uint64, voter sdk.AccAddress) (group.Vote, error) { var v group.Vote - return v, q.voteTable.GetOne(ctx.KVStore(q.key), orm.PrimaryKey(&group.Vote{ProposalId: proposalID, Voter: voter.String()}), &v) + return v, k.voteTable.GetOne(ctx.KVStore(k.key), orm.PrimaryKey(&group.Vote{ProposalId: proposalID, Voter: voter.String()}), &v) } -func (q Keeper) getVotesByProposal(ctx sdk.Context, proposalID uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.voteByProposalIndex.GetPaginated(ctx.KVStore(q.key), proposalID, pageRequest) +func (k Keeper) getVotesByProposal(ctx sdk.Context, proposalID uint64, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.voteByProposalIndex.GetPaginated(ctx.KVStore(k.key), proposalID, pageRequest) } -func (q Keeper) getVotesByVoter(ctx sdk.Context, voter sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { - return q.voteByVoterIndex.GetPaginated(ctx.KVStore(q.key), voter.Bytes(), pageRequest) +func (k Keeper) getVotesByVoter(ctx sdk.Context, voter sdk.AccAddress, pageRequest *query.PageRequest) (orm.Iterator, error) { + return k.voteByVoterIndex.GetPaginated(ctx.KVStore(k.key), voter.Bytes(), pageRequest) } -func (q Keeper) TallyResult(goCtx context.Context, request *group.QueryTallyResultRequest) (*group.QueryTallyResultResponse, error) { +// TallyResult computes the live tally result of a proposal. +func (k Keeper) TallyResult(goCtx context.Context, request *group.QueryTallyResultRequest) (*group.QueryTallyResultResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) proposalId := request.ProposalId - proposal, err := q.getProposal(ctx, proposalId) + proposal, err := k.getProposal(ctx, proposalId) if err != nil { return nil, err } @@ -319,11 +333,11 @@ func (q Keeper) TallyResult(goCtx context.Context, request *group.QueryTallyResu } var policyInfo group.GroupPolicyInfo - if policyInfo, err = q.getGroupPolicyInfo(ctx, proposal.Address); err != nil { + if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.GroupPolicyAddress); err != nil { return nil, sdkerrors.Wrap(err, "load group policy") } - tallyResult, err := q.Tally(ctx, proposal, policyInfo.GroupId) + tallyResult, err := k.Tally(ctx, proposal, policyInfo.GroupId) if err != nil { return nil, err } diff --git a/x/group/keeper/invariants.go b/x/group/keeper/invariants.go index 9b98e69f89..5db8057e5a 100644 --- a/x/group/keeper/invariants.go +++ b/x/group/keeper/invariants.go @@ -14,7 +14,7 @@ import ( const weightInvariant = "Group-TotalWeight" -// RegisterInvariants registers all group invariants +// RegisterInvariants registers all group invariants. func RegisterInvariants(ir sdk.InvariantRegistry, keeper Keeper) { ir.RegisterRoute(group.ModuleName, weightInvariant, GroupTotalWeightInvariant(keeper)) } diff --git a/x/group/keeper/keeper.go b/x/group/keeper/keeper.go index 7177eefba9..f99c2bc398 100644 --- a/x/group/keeper/keeper.go +++ b/x/group/keeper/keeper.go @@ -80,6 +80,7 @@ type Keeper struct { config group.Config } +// NewKeeper creates a new group keeper. func NewKeeper(storeKey storetypes.StoreKey, cdc codec.Codec, router *authmiddleware.MsgServiceRouter, accKeeper group.AccountKeeper, config group.Config) Keeper { k := Keeper{ key: storeKey, @@ -159,7 +160,7 @@ func NewKeeper(storeKey storetypes.StoreKey, cdc codec.Codec, router *authmiddle panic(err.Error()) } k.proposalByGroupPolicyIndex, err = orm.NewIndex(proposalTable, ProposalByGroupPolicyIndexPrefix, func(value interface{}) ([]interface{}, error) { - account := value.(*group.Proposal).Address + account := value.(*group.Proposal).GroupPolicyAddress addr, err := sdk.AccAddressFromBech32(account) if err != nil { return nil, err @@ -324,9 +325,12 @@ func (k Keeper) PruneProposals(ctx sdk.Context) error { return nil } -func (k Keeper) UpdateTallyOfVPEndProposals(ctx sdk.Context) error { +// TallyProposalsAtVPEnd iterates over all proposals whose voting period +// has ended, tallies their votes, prunes them, and updates the proposal's +// `FinalTallyResult` field. +func (k Keeper) TallyProposalsAtVPEnd(ctx sdk.Context) error { return k.iterateProposalsByVPEnd(ctx, ctx.BlockTime(), func(proposal group.Proposal) (bool, error) { - policyInfo, err := k.getGroupPolicyInfo(ctx, proposal.Address) + policyInfo, err := k.getGroupPolicyInfo(ctx, proposal.GroupPolicyAddress) if err != nil { return true, sdkerrors.Wrap(err, "group policy") } diff --git a/x/group/keeper/keeper_test.go b/x/group/keeper/keeper_test.go index ba1a7d5337..539ff6f9dc 100644 --- a/x/group/keeper/keeper_test.go +++ b/x/group/keeper/keeper_test.go @@ -1036,9 +1036,9 @@ func (s *TestSuite) TestUpdateGroupPolicyAdmin() { }{ "with wrong admin": { req: &group.MsgUpdateGroupPolicyAdmin{ - Admin: addr5.String(), - Address: groupPolicyAddr, - NewAdmin: newAdmin.String(), + Admin: addr5.String(), + GroupPolicyAddress: groupPolicyAddr, + NewAdmin: newAdmin.String(), }, expGroupPolicy: &group.GroupPolicyInfo{ Admin: admin.String(), @@ -1052,9 +1052,9 @@ func (s *TestSuite) TestUpdateGroupPolicyAdmin() { }, "with wrong group policy": { req: &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - Address: addr5.String(), - NewAdmin: newAdmin.String(), + Admin: admin.String(), + GroupPolicyAddress: addr5.String(), + NewAdmin: newAdmin.String(), }, expGroupPolicy: &group.GroupPolicyInfo{ Admin: admin.String(), @@ -1068,9 +1068,9 @@ func (s *TestSuite) TestUpdateGroupPolicyAdmin() { }, "correct data": { req: &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - Address: groupPolicyAddr, - NewAdmin: newAdmin.String(), + Admin: admin.String(), + GroupPolicyAddress: groupPolicyAddr, + NewAdmin: newAdmin.String(), }, expGroupPolicy: &group.GroupPolicyInfo{ Admin: newAdmin.String(), @@ -1124,32 +1124,32 @@ func (s *TestSuite) TestUpdateGroupPolicyMetadata() { }{ "with wrong admin": { req: &group.MsgUpdateGroupPolicyMetadata{ - Admin: addr5.String(), - Address: groupPolicyAddr, + Admin: addr5.String(), + GroupPolicyAddress: groupPolicyAddr, }, expGroupPolicy: &group.GroupPolicyInfo{}, expErr: true, }, "with wrong group policy": { req: &group.MsgUpdateGroupPolicyMetadata{ - Admin: admin.String(), - Address: addr5.String(), + Admin: admin.String(), + GroupPolicyAddress: addr5.String(), }, expGroupPolicy: &group.GroupPolicyInfo{}, expErr: true, }, "with comment too long": { req: &group.MsgUpdateGroupPolicyMetadata{ - Admin: admin.String(), - Address: addr5.String(), + Admin: admin.String(), + GroupPolicyAddress: addr5.String(), }, expGroupPolicy: &group.GroupPolicyInfo{}, expErr: true, }, "correct data": { req: &group.MsgUpdateGroupPolicyMetadata{ - Admin: admin.String(), - Address: groupPolicyAddr, + Admin: admin.String(), + GroupPolicyAddress: groupPolicyAddr, }, expGroupPolicy: &group.GroupPolicyInfo{ Admin: admin.String(), @@ -1205,8 +1205,8 @@ func (s *TestSuite) TestUpdateGroupPolicyDecisionPolicy() { }{ "with wrong admin": { req: &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: addr5.String(), - Address: groupPolicyAddr, + Admin: addr5.String(), + GroupPolicyAddress: groupPolicyAddr, }, policy: policy, expGroupPolicy: &group.GroupPolicyInfo{}, @@ -1214,8 +1214,8 @@ func (s *TestSuite) TestUpdateGroupPolicyDecisionPolicy() { }, "with wrong group policy": { req: &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: addr5.String(), + Admin: admin.String(), + GroupPolicyAddress: addr5.String(), }, policy: policy, expGroupPolicy: &group.GroupPolicyInfo{}, @@ -1223,8 +1223,8 @@ func (s *TestSuite) TestUpdateGroupPolicyDecisionPolicy() { }, "correct data": { req: &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: groupPolicyAddr, + Admin: admin.String(), + GroupPolicyAddress: groupPolicyAddr, }, policy: group.NewThresholdDecisionPolicy( "2", @@ -1246,8 +1246,8 @@ func (s *TestSuite) TestUpdateGroupPolicyDecisionPolicy() { return s.createGroupAndGroupPolicy(admin, nil, policy) }, req: &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: groupPolicyAddr, + Admin: admin.String(), + GroupPolicyAddress: groupPolicyAddr, }, policy: group.NewPercentageDecisionPolicy( "0.5", @@ -1277,7 +1277,7 @@ func (s *TestSuite) TestUpdateGroupPolicyDecisionPolicy() { spec.expGroupPolicy.GroupId = groupId // update req with new group policy addr - spec.req.Address = policyAddr1 + spec.req.GroupPolicyAddress = policyAddr1 } err = spec.req.SetDecisionPolicy(spec.policy) @@ -1425,9 +1425,8 @@ func (s *TestSuite) TestSubmitProposal() { bigThresholdAddr := bigThresholdRes.Address defaultProposal := group.Proposal{ - Address: accountAddr.String(), - Status: group.PROPOSAL_STATUS_SUBMITTED, - Result: group.PROPOSAL_RESULT_UNFINALIZED, + GroupPolicyAddress: accountAddr.String(), + Status: group.PROPOSAL_STATUS_SUBMITTED, FinalTallyResult: group.TallyResult{ YesCount: "0", NoCount: "0", @@ -1445,16 +1444,16 @@ func (s *TestSuite) TestSubmitProposal() { }{ "all good with minimal fields set": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String()}, }, expProposal: defaultProposal, postRun: func(sdkCtx sdk.Context) {}, }, "all good with good msg payload": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String()}, }, msgs: []sdk.Msg{&banktypes.MsgSend{ FromAddress: accountAddr.String(), @@ -1466,9 +1465,9 @@ func (s *TestSuite) TestSubmitProposal() { }, "metadata too long": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String()}, - Metadata: strings.Repeat("a", 256), + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String()}, + Metadata: strings.Repeat("a", 256), }, expErr: true, postRun: func(sdkCtx sdk.Context) {}, @@ -1482,55 +1481,54 @@ func (s *TestSuite) TestSubmitProposal() { }, "existing group policy required": { req: &group.MsgSubmitProposal{ - Address: addr1.String(), - Proposers: []string{addr2.String()}, + GroupPolicyAddress: addr1.String(), + Proposers: []string{addr2.String()}, }, expErr: true, postRun: func(sdkCtx sdk.Context) {}, }, "decision policy threshold > total group weight": { req: &group.MsgSubmitProposal{ - Address: bigThresholdAddr, - Proposers: []string{addr2.String()}, + GroupPolicyAddress: bigThresholdAddr, + Proposers: []string{addr2.String()}, }, expErr: false, expProposal: group.Proposal{ - Address: bigThresholdAddr, - Status: group.PROPOSAL_STATUS_SUBMITTED, - Result: group.PROPOSAL_RESULT_UNFINALIZED, - FinalTallyResult: group.DefaultTallyResult(), - ExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, + GroupPolicyAddress: bigThresholdAddr, + Status: group.PROPOSAL_STATUS_SUBMITTED, + FinalTallyResult: group.DefaultTallyResult(), + ExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, }, postRun: func(sdkCtx sdk.Context) {}, }, "only group members can create a proposal": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr4.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr4.String()}, }, expErr: true, postRun: func(sdkCtx sdk.Context) {}, }, "all proposers must be in group": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String(), addr4.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String(), addr4.String()}, }, expErr: true, postRun: func(sdkCtx sdk.Context) {}, }, "admin that is not a group member can not create proposal": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr1.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr1.String()}, }, expErr: true, postRun: func(sdkCtx sdk.Context) {}, }, "reject msgs that are not authz by group policy": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String()}, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String()}, }, msgs: []sdk.Msg{&testdata.TestMsg{Signers: []string{addr1.String()}}}, expErr: true, @@ -1538,15 +1536,14 @@ func (s *TestSuite) TestSubmitProposal() { }, "with try exec": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr2.String()}, - Exec: group.Exec_EXEC_TRY, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr2.String()}, + Exec: group.Exec_EXEC_TRY, }, msgs: []sdk.Msg{msgSend}, expProposal: group.Proposal{ - Address: accountAddr.String(), - Status: group.PROPOSAL_STATUS_CLOSED, - Result: group.PROPOSAL_RESULT_ACCEPTED, + GroupPolicyAddress: accountAddr.String(), + Status: group.PROPOSAL_STATUS_ACCEPTED, FinalTallyResult: group.TallyResult{ YesCount: "2", NoCount: "0", @@ -1564,15 +1561,14 @@ func (s *TestSuite) TestSubmitProposal() { }, "with try exec, not enough yes votes for proposal to pass": { req: &group.MsgSubmitProposal{ - Address: accountAddr.String(), - Proposers: []string{addr5.String()}, - Exec: group.Exec_EXEC_TRY, + GroupPolicyAddress: accountAddr.String(), + Proposers: []string{addr5.String()}, + Exec: group.Exec_EXEC_TRY, }, msgs: []sdk.Msg{msgSend}, expProposal: group.Proposal{ - Address: accountAddr.String(), - Status: group.PROPOSAL_STATUS_SUBMITTED, - Result: group.PROPOSAL_RESULT_UNFINALIZED, + GroupPolicyAddress: accountAddr.String(), + Status: group.PROPOSAL_STATUS_SUBMITTED, FinalTallyResult: group.TallyResult{ YesCount: "0", // Since tally doesn't pass Allow(), we consider the proposal not final NoCount: "0", @@ -1604,14 +1600,13 @@ func (s *TestSuite) TestSubmitProposal() { s.Require().NoError(err) proposal := proposalRes.Proposal - s.Assert().Equal(spec.expProposal.Address, proposal.Address) + s.Assert().Equal(spec.expProposal.GroupPolicyAddress, proposal.GroupPolicyAddress) s.Assert().Equal(spec.req.Metadata, proposal.Metadata) s.Assert().Equal(spec.req.Proposers, proposal.Proposers) s.Assert().Equal(s.blockTime, proposal.SubmitTime) s.Assert().Equal(uint64(1), proposal.GroupVersion) s.Assert().Equal(uint64(1), proposal.GroupPolicyVersion) s.Assert().Equal(spec.expProposal.Status, proposal.Status) - s.Assert().Equal(spec.expProposal.Result, proposal.Result) s.Assert().Equal(spec.expProposal.FinalTallyResult, proposal.FinalTallyResult) s.Assert().Equal(spec.expProposal.ExecutorResult, proposal.ExecutorResult) s.Assert().Equal(s.blockTime.Add(time.Second), proposal.VotingPeriodEnd) @@ -1755,9 +1750,9 @@ func (s *TestSuite) TestVote() { s.Require().NoError(testutil.FundAccount(s.app.BankKeeper, s.sdkCtx, groupPolicy, sdk.Coins{sdk.NewInt64Coin("test", 10000)})) req := &group.MsgSubmitProposal{ - Address: accountAddr, - Proposers: []string{addr4.String()}, - Messages: nil, + GroupPolicyAddress: accountAddr, + Proposers: []string{addr4.String()}, + Messages: nil, } err = req.SetMsgs([]sdk.Msg{&banktypes.MsgSend{ FromAddress: accountAddr, @@ -1777,15 +1772,13 @@ func (s *TestSuite) TestVote() { s.Require().NoError(err) proposals := proposalsRes.Proposals s.Require().Equal(len(proposals), 1) - s.Assert().Equal(req.Address, proposals[0].Address) + s.Assert().Equal(req.GroupPolicyAddress, proposals[0].GroupPolicyAddress) s.Assert().Equal(req.Metadata, proposals[0].Metadata) s.Assert().Equal(req.Proposers, proposals[0].Proposers) s.Assert().Equal(s.blockTime, proposals[0].SubmitTime) - s.Assert().Equal(uint64(1), proposals[0].GroupVersion) s.Assert().Equal(uint64(1), proposals[0].GroupPolicyVersion) s.Assert().Equal(group.PROPOSAL_STATUS_SUBMITTED, proposals[0].Status) - s.Assert().Equal(group.PROPOSAL_RESULT_UNFINALIZED, proposals[0].Result) s.Assert().Equal(group.DefaultTallyResult(), proposals[0].FinalTallyResult) specs := map[string]struct { @@ -1796,7 +1789,6 @@ func (s *TestSuite) TestVote() { doBefore func(ctx context.Context) postRun func(sdkCtx sdk.Context) expProposalStatus group.ProposalStatus // expected after tallying - expResult group.ProposalResult // expected after tallying expExecutorResult group.ProposalExecutorResult // expected after tallying expErr bool }{ @@ -1813,7 +1805,6 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "0", }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -1831,8 +1822,7 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "0", }, isFinal: true, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_SUCCESS, postRun: func(sdkCtx sdk.Context) { fromBalances := s.app.BankKeeper.GetAllBalances(sdkCtx, groupPolicy) @@ -1855,7 +1845,6 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "0", }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -1872,7 +1861,6 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "0", }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -1889,7 +1877,6 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "0", }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -1906,7 +1893,6 @@ func (s *TestSuite) TestVote() { NoWithVetoCount: "1", }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -1922,8 +1908,7 @@ func (s *TestSuite) TestVote() { AbstainCount: "0", NoWithVetoCount: "0", }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, postRun: func(sdkCtx sdk.Context) {}, }, @@ -2117,7 +2102,6 @@ func (s *TestSuite) TestVote() { proposal := proposalRes.Proposal if spec.isFinal { s.Assert().Equal(spec.expTallyResult, proposal.FinalTallyResult) - s.Assert().Equal(spec.expResult, proposal.Result) s.Assert().Equal(spec.expProposalStatus, proposal.Status) s.Assert().Equal(spec.expExecutorResult, proposal.ExecutorResult) } else { @@ -2161,8 +2145,8 @@ func (s *TestSuite) TestVote() { policyAddr := result.GroupPolicyAddress groupID := result.GroupId reqProposal := &group.MsgSubmitProposal{ - Address: policyAddr, - Proposers: []string{addr4.String()}, + GroupPolicyAddress: policyAddr, + Proposers: []string{addr4.String()}, } require.NoError(reqProposal.SetMsgs([]sdk.Msg{&banktypes.MsgSend{ FromAddress: policyAddr, @@ -2220,7 +2204,6 @@ func (s *TestSuite) TestExecProposal() { setupProposal func(ctx context.Context) uint64 expErr bool expProposalStatus group.ProposalStatus - expProposalResult group.ProposalResult expExecutorResult group.ProposalExecutorResult expBalance bool expFromBalances sdk.Coin @@ -2231,8 +2214,7 @@ func (s *TestSuite) TestExecProposal() { msgs := []sdk.Msg{msgSend1} return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_YES) }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_SUCCESS, expBalance: true, expFromBalances: sdk.NewInt64Coin("test", 9900), @@ -2243,8 +2225,7 @@ func (s *TestSuite) TestExecProposal() { msgs := []sdk.Msg{msgSend1, msgSend1} return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_YES) }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_SUCCESS, expBalance: true, expFromBalances: sdk.NewInt64Coin("test", 9800), @@ -2255,8 +2236,7 @@ func (s *TestSuite) TestExecProposal() { msgs := []sdk.Msg{msgSend1} return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_NO) }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_REJECTED, + expProposalStatus: group.PROPOSAL_STATUS_REJECTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, }, "open proposal must not fail": { @@ -2264,7 +2244,6 @@ func (s *TestSuite) TestExecProposal() { return submitProposal(ctx, s, []sdk.Msg{msgSend1}, proposers) }, expProposalStatus: group.PROPOSAL_STATUS_SUBMITTED, - expProposalResult: group.PROPOSAL_RESULT_UNFINALIZED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, }, "existing proposal required": { @@ -2279,8 +2258,7 @@ func (s *TestSuite) TestExecProposal() { return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_NO) }, srcBlockTime: s.blockTime.Add(time.Second), - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_REJECTED, + expProposalStatus: group.PROPOSAL_STATUS_REJECTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, }, "Decision policy also applied after timeout": { @@ -2289,21 +2267,19 @@ func (s *TestSuite) TestExecProposal() { return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_NO) }, srcBlockTime: s.blockTime.Add(time.Second).Add(time.Millisecond), - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_REJECTED, + expProposalStatus: group.PROPOSAL_STATUS_REJECTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, }, "prevent double execution when successful": { setupProposal: func(ctx context.Context) uint64 { myProposalID := submitProposalAndVote(ctx, s, []sdk.Msg{msgSend1}, proposers, group.VOTE_OPTION_YES) - _, err := s.keeper.Exec(ctx, &group.MsgExec{Signer: addr1.String(), ProposalId: myProposalID}) + _, err := s.keeper.Exec(ctx, &group.MsgExec{Executor: addr1.String(), ProposalId: myProposalID}) s.Require().NoError(err) return myProposalID }, expErr: true, // since proposal is pruned after a successful MsgExec - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_SUCCESS, expBalance: true, expFromBalances: sdk.NewInt64Coin("test", 9900), @@ -2314,8 +2290,7 @@ func (s *TestSuite) TestExecProposal() { msgs := []sdk.Msg{msgSend1, msgSend2} return submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_YES) }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_FAILURE, }, "executable when failed before": { @@ -2323,15 +2298,14 @@ func (s *TestSuite) TestExecProposal() { msgs := []sdk.Msg{msgSend2} myProposalID := submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_YES) - _, err := s.keeper.Exec(ctx, &group.MsgExec{Signer: addr1.String(), ProposalId: myProposalID}) + _, err := s.keeper.Exec(ctx, &group.MsgExec{Executor: addr1.String(), ProposalId: myProposalID}) s.Require().NoError(err) sdkCtx := sdk.UnwrapSDKContext(ctx) s.Require().NoError(testutil.FundAccount(s.app.BankKeeper, sdkCtx, s.groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) return myProposalID }, - expProposalStatus: group.PROPOSAL_STATUS_CLOSED, - expProposalResult: group.PROPOSAL_RESULT_ACCEPTED, + expProposalStatus: group.PROPOSAL_STATUS_ACCEPTED, expExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_SUCCESS, }, } @@ -2347,7 +2321,7 @@ func (s *TestSuite) TestExecProposal() { } ctx = sdk.WrapSDKContext(sdkCtx) - _, err := s.keeper.Exec(ctx, &group.MsgExec{Signer: addr1.String(), ProposalId: proposalID}) + _, err := s.keeper.Exec(ctx, &group.MsgExec{Executor: addr1.String(), ProposalId: proposalID}) if spec.expErr { s.Require().Error(err) return @@ -2361,12 +2335,8 @@ func (s *TestSuite) TestExecProposal() { s.Require().NoError(err) proposal := res.Proposal - exp := group.ProposalResult_name[int32(spec.expProposalResult)] - got := group.ProposalResult_name[int32(proposal.Result)] - s.Assert().Equal(exp, got) - - exp = group.ProposalStatus_name[int32(spec.expProposalStatus)] - got = group.ProposalStatus_name[int32(proposal.Status)] + exp := group.ProposalStatus_name[int32(spec.expProposalStatus)] + got := group.ProposalStatus_name[int32(proposal.Status)] s.Assert().Equal(exp, got) exp = group.ProposalExecutorResult_name[int32(spec.expExecutorResult)] @@ -2454,8 +2424,8 @@ func (s *TestSuite) TestExecPrunedProposalsAndVotes() { setupProposal: func(ctx context.Context) uint64 { myProposalID := submitProposal(ctx, s, []sdk.Msg{msgSend1}, proposers) _, err := s.keeper.UpdateGroupPolicyMetadata(ctx, &group.MsgUpdateGroupPolicyMetadata{ - Admin: addr1.String(), - Address: s.groupPolicyAddr.String(), + Admin: addr1.String(), + GroupPolicyAddress: s.groupPolicyAddr.String(), }) s.Require().NoError(err) return myProposalID @@ -2474,7 +2444,7 @@ func (s *TestSuite) TestExecPrunedProposalsAndVotes() { msgs := []sdk.Msg{msgSend2} myProposalID := submitProposalAndVote(ctx, s, msgs, proposers, group.VOTE_OPTION_YES) - _, err := s.keeper.Exec(ctx, &group.MsgExec{Signer: addr1.String(), ProposalId: myProposalID}) + _, err := s.keeper.Exec(ctx, &group.MsgExec{Executor: addr1.String(), ProposalId: myProposalID}) s.Require().NoError(err) sdkCtx := sdk.UnwrapSDKContext(ctx) s.Require().NoError(testutil.FundAccount(s.app.BankKeeper, sdkCtx, s.groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -2497,7 +2467,7 @@ func (s *TestSuite) TestExecPrunedProposalsAndVotes() { } ctx = sdk.WrapSDKContext(sdkCtx) - _, err := s.keeper.Exec(ctx, &group.MsgExec{Signer: addr1.String(), ProposalId: proposalID}) + _, err := s.keeper.Exec(ctx, &group.MsgExec{Executor: addr1.String(), ProposalId: proposalID}) if spec.expErr { s.Require().Error(err) return @@ -2546,44 +2516,40 @@ func (s *TestSuite) TestProposalsByVPEnd() { proposers := []string{addr2.String()} specs := map[string]struct { - preRun func(sdkCtx sdk.Context) uint64 - proposalId uint64 - admin string - expErrMsg string - newCtx sdk.Context - tallyRes group.TallyResult - expStatus group.ProposalStatus - expExecutorResult group.ProposalResult + preRun func(sdkCtx sdk.Context) uint64 + proposalId uint64 + admin string + expErrMsg string + newCtx sdk.Context + tallyRes group.TallyResult + expStatus group.ProposalStatus }{ "tally updated after voting power end": { preRun: func(sdkCtx sdk.Context) uint64 { return submitProposal(sdkCtx, s, []sdk.Msg{msgSend}, proposers) }, - admin: proposers[0], - newCtx: ctx.WithBlockTime(now.Add(votingPeriod).Add(time.Hour)), - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx.WithBlockTime(now.Add(votingPeriod).Add(time.Hour)), + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally within voting period": { preRun: func(sdkCtx sdk.Context) uint64 { return submitProposal(s.ctx, s, []sdk.Msg{msgSend}, proposers) }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally within voting period(with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { return submitProposalAndVote(s.ctx, s, []sdk.Msg{msgSend}, proposers, group.VOTE_OPTION_YES) }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally after voting period(with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -2597,8 +2563,7 @@ func (s *TestSuite) TestProposalsByVPEnd() { NoWithVetoCount: "0", AbstainCount: "0", }, - expStatus: group.PROPOSAL_STATUS_CLOSED, - expExecutorResult: group.PROPOSAL_RESULT_ACCEPTED, + expStatus: group.PROPOSAL_STATUS_ACCEPTED, }, "tally of closed proposal": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -2611,11 +2576,10 @@ func (s *TestSuite) TestProposalsByVPEnd() { s.Require().NoError(err) return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_WITHDRAWN, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_WITHDRAWN, }, "tally of closed proposal (with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -2628,11 +2592,10 @@ func (s *TestSuite) TestProposalsByVPEnd() { s.Require().NoError(err) return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_WITHDRAWN, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_WITHDRAWN, }, } @@ -2655,7 +2618,6 @@ func (s *TestSuite) TestProposalsByVPEnd() { s.Require().NoError(err) s.Require().Equal(resp.GetProposal().FinalTallyResult, spec.tallyRes) s.Require().Equal(resp.GetProposal().Status, spec.expStatus) - s.Require().Equal(resp.GetProposal().Result, spec.expExecutorResult) }) } } @@ -2844,8 +2806,8 @@ func submitProposal( ctx context.Context, s *TestSuite, msgs []sdk.Msg, proposers []string) uint64 { proposalReq := &group.MsgSubmitProposal{ - Address: s.groupPolicyAddr.String(), - Proposers: proposers, + GroupPolicyAddress: s.groupPolicyAddr.String(), + Proposers: proposers, } err := proposalReq.SetMsgs(msgs) s.Require().NoError(err) diff --git a/x/group/keeper/msg_server.go b/x/group/keeper/msg_server.go index d4f84a3e4a..142f8d7c9c 100644 --- a/x/group/keeper/msg_server.go +++ b/x/group/keeper/msg_server.go @@ -20,7 +20,7 @@ import ( var _ group.MsgServer = Keeper{} -// TODO: Revisit this once we have propoer gas fee framework. +// TODO: Revisit this once we have proper gas fee framework. // Tracking issues https://github.com/cosmos/cosmos-sdk/issues/9054, https://github.com/cosmos/cosmos-sdk/discussions/9072 const gasCostPerIteration = uint64(20) @@ -279,9 +279,9 @@ func (k Keeper) CreateGroupWithPolicy(goCtx context.Context, req *group.MsgCreat } updatePolicyAddressReq := &group.MsgUpdateGroupPolicyAdmin{ - Admin: req.Admin, - Address: groupPolicyAddress, - NewAdmin: groupPolicyAddress, + Admin: req.Admin, + GroupPolicyAddress: groupPolicyAddress, + NewAdmin: groupPolicyAddress, } _, err = k.UpdateGroupPolicyAdmin(goCtx, updatePolicyAddressReq) if err != nil { @@ -383,7 +383,7 @@ func (k Keeper) UpdateGroupPolicyAdmin(goCtx context.Context, req *group.MsgUpda return k.groupPolicyTable.Update(ctx.KVStore(k.key), groupPolicy) } - err := k.doUpdateGroupPolicy(ctx, req.Address, req.Admin, action, "group policy admin updated") + err := k.doUpdateGroupPolicy(ctx, req.GroupPolicyAddress, req.Admin, action, "group policy admin updated") if err != nil { return nil, err } @@ -415,7 +415,7 @@ func (k Keeper) UpdateGroupPolicyDecisionPolicy(goCtx context.Context, req *grou return k.groupPolicyTable.Update(ctx.KVStore(k.key), groupPolicy) } - err := k.doUpdateGroupPolicy(ctx, req.Address, req.Admin, action, "group policy's decision policy updated") + err := k.doUpdateGroupPolicy(ctx, req.GroupPolicyAddress, req.Admin, action, "group policy's decision policy updated") if err != nil { return nil, err } @@ -437,7 +437,7 @@ func (k Keeper) UpdateGroupPolicyMetadata(goCtx context.Context, req *group.MsgU return nil, err } - err := k.doUpdateGroupPolicy(ctx, req.Address, req.Admin, action, "group policy metadata updated") + err := k.doUpdateGroupPolicy(ctx, req.GroupPolicyAddress, req.Admin, action, "group policy metadata updated") if err != nil { return nil, err } @@ -447,7 +447,7 @@ func (k Keeper) UpdateGroupPolicyMetadata(goCtx context.Context, req *group.MsgU func (k Keeper) SubmitProposal(goCtx context.Context, req *group.MsgSubmitProposal) (*group.MsgSubmitProposalResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) - accountAddress, err := sdk.AccAddressFromBech32(req.Address) + accountAddress, err := sdk.AccAddressFromBech32(req.GroupPolicyAddress) if err != nil { return nil, sdkerrors.Wrap(err, "request account address of group policy") } @@ -459,7 +459,7 @@ func (k Keeper) SubmitProposal(goCtx context.Context, req *group.MsgSubmitPropos return nil, err } - policyAcc, err := k.getGroupPolicyInfo(ctx, req.Address) + policyAcc, err := k.getGroupPolicyInfo(ctx, req.GroupPolicyAddress) if err != nil { return nil, sdkerrors.Wrap(err, "load group policy") } @@ -494,13 +494,12 @@ func (k Keeper) SubmitProposal(goCtx context.Context, req *group.MsgSubmitPropos m := &group.Proposal{ Id: k.proposalTable.Sequence().PeekNextVal(ctx.KVStore(k.key)), - Address: req.Address, + GroupPolicyAddress: req.GroupPolicyAddress, Metadata: metadata, Proposers: proposers, SubmitTime: ctx.BlockTime(), GroupVersion: g.Version, GroupPolicyVersion: policyAcc.Version, - Result: group.PROPOSAL_RESULT_UNFINALIZED, Status: group.PROPOSAL_STATUS_SUBMITTED, ExecutorResult: group.PROPOSAL_EXECUTOR_RESULT_NOT_RUN, VotingPeriodEnd: ctx.BlockTime().Add(policy.GetVotingPeriod()), // The voting window begins as soon as the proposal is submitted. @@ -541,7 +540,7 @@ func (k Keeper) SubmitProposal(goCtx context.Context, req *group.MsgSubmitPropos ProposalId: id, // We consider the first proposer as the MsgExecRequest signer // but that could be revisited (eg using the group policy) - Signer: proposers[0], + Executor: proposers[0], }) if err != nil { return &group.MsgSubmitProposalResponse{ProposalId: id}, sdkerrors.Wrap(err, "The proposal was created but failed on exec") @@ -567,7 +566,7 @@ func (k Keeper) WithdrawProposal(goCtx context.Context, req *group.MsgWithdrawPr } var policyInfo group.GroupPolicyInfo - if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.Address); err != nil { + if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.GroupPolicyAddress); err != nil { return nil, sdkerrors.Wrap(err, "load group policy") } @@ -585,7 +584,6 @@ func (k Keeper) WithdrawProposal(goCtx context.Context, req *group.MsgWithdrawPr return nil, err } - proposal.Result = group.PROPOSAL_RESULT_UNFINALIZED proposal.Status = group.PROPOSAL_STATUS_WITHDRAWN return storeUpdates() } @@ -608,7 +606,6 @@ func (k Keeper) WithdrawProposal(goCtx context.Context, req *group.MsgWithdrawPr return nil, err } - proposal.Result = group.PROPOSAL_RESULT_UNFINALIZED proposal.Status = group.PROPOSAL_STATUS_WITHDRAWN return storeUpdates() } @@ -637,7 +634,7 @@ func (k Keeper) Vote(goCtx context.Context, req *group.MsgVote) (*group.MsgVoteR var policyInfo group.GroupPolicyInfo - if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.Address); err != nil { + if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.GroupPolicyAddress); err != nil { return nil, sdkerrors.Wrap(err, "load group policy") } @@ -675,7 +672,7 @@ func (k Keeper) Vote(goCtx context.Context, req *group.MsgVote) (*group.MsgVoteR if req.Exec == group.Exec_EXEC_TRY { _, err = k.Exec(sdk.WrapSDKContext(ctx), &group.MsgExec{ ProposalId: id, - Signer: voterAddr, + Executor: voterAddr, }) if err != nil { return nil, err @@ -713,11 +710,9 @@ func (k Keeper) doTallyAndUpdate(ctx sdk.Context, p *group.Proposal, electorate } p.FinalTallyResult = tallyResult if result.Allow { - p.Result = group.PROPOSAL_RESULT_ACCEPTED - p.Status = group.PROPOSAL_STATUS_CLOSED + p.Status = group.PROPOSAL_STATUS_ACCEPTED } else { - p.Result = group.PROPOSAL_RESULT_REJECTED - p.Status = group.PROPOSAL_STATUS_CLOSED + p.Status = group.PROPOSAL_STATUS_REJECTED } } @@ -734,12 +729,12 @@ func (k Keeper) Exec(goCtx context.Context, req *group.MsgExec) (*group.MsgExecR return nil, err } - if proposal.Status != group.PROPOSAL_STATUS_SUBMITTED && proposal.Status != group.PROPOSAL_STATUS_CLOSED { + if proposal.Status != group.PROPOSAL_STATUS_SUBMITTED && proposal.Status != group.PROPOSAL_STATUS_ACCEPTED { return nil, sdkerrors.Wrapf(errors.ErrInvalid, "not possible with proposal status %s", proposal.Status.String()) } var policyInfo group.GroupPolicyInfo - if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.Address); err != nil { + if policyInfo, err = k.getGroupPolicyInfo(ctx, proposal.GroupPolicyAddress); err != nil { return nil, sdkerrors.Wrap(err, "load group policy") } @@ -772,7 +767,7 @@ func (k Keeper) Exec(goCtx context.Context, req *group.MsgExec) (*group.MsgExecR } // Execute proposal payload. - if proposal.Status == group.PROPOSAL_STATUS_CLOSED && proposal.Result == group.PROPOSAL_RESULT_ACCEPTED && proposal.ExecutorResult != group.PROPOSAL_EXECUTOR_RESULT_SUCCESS { + if proposal.Status == group.PROPOSAL_STATUS_ACCEPTED && proposal.ExecutorResult != group.PROPOSAL_EXECUTOR_RESULT_SUCCESS { logger := ctx.Logger().With("module", fmt.Sprintf("x/%s", group.ModuleName)) // Caching context so that we don't update the store in case of failure. ctx, flush := ctx.CacheContext() diff --git a/x/group/keeper/proposal_executor.go b/x/group/keeper/proposal_executor.go index 917ac575d5..c63d9ad66f 100644 --- a/x/group/keeper/proposal_executor.go +++ b/x/group/keeper/proposal_executor.go @@ -9,7 +9,7 @@ import ( ) // doExecuteMsgs routes the messages to the registered handlers. Messages are limited to those that require no authZ or -// by the account of group policy only. Otherwise this gives access to other peoples accounts as the sdk ant handler is bypassed +// by the account of group policy only. Otherwise this gives access to other peoples accounts as the sdk middlewares are bypassed func (s Keeper) doExecuteMsgs(ctx sdk.Context, router *authmiddleware.MsgServiceRouter, proposal group.Proposal, groupPolicyAcc sdk.AccAddress) ([]sdk.Result, error) { // Ensure it's not too late to execute the messages. // After https://github.com/cosmos/cosmos-sdk/issues/11245, proposals should diff --git a/x/group/keeper/tally.go b/x/group/keeper/tally.go index 2f1a21629a..931c949696 100644 --- a/x/group/keeper/tally.go +++ b/x/group/keeper/tally.go @@ -10,14 +10,17 @@ import ( // Tally is a function that tallies a proposal by iterating through its votes, // and returns the tally result without modifying the proposal or any state. -func (q Keeper) Tally(ctx sdk.Context, p group.Proposal, groupId uint64) (group.TallyResult, error) { +func (k Keeper) Tally(ctx sdk.Context, p group.Proposal, groupId uint64) (group.TallyResult, error) { // If proposal has already been tallied and updated, then its status is - // closed, in which case we just return the previously stored result. - if p.Status == group.PROPOSAL_STATUS_CLOSED { + // accepted/rejected, in which case we just return the previously stored result. + // + // In all other cases (including withdrawn, aborted...) we do the tally + // again. + if p.Status == group.PROPOSAL_STATUS_ACCEPTED || p.Status == group.PROPOSAL_STATUS_REJECTED { return p.FinalTallyResult, nil } - it, err := q.voteByProposalIndex.Get(ctx.KVStore(q.key), p.Id) + it, err := k.voteByProposalIndex.Get(ctx.KVStore(k.key), p.Id) if err != nil { return group.TallyResult{}, err } @@ -36,7 +39,7 @@ func (q Keeper) Tally(ctx sdk.Context, p group.Proposal, groupId uint64) (group. } var member group.GroupMember - err := q.groupMemberTable.GetOne(ctx.KVStore(q.key), orm.PrimaryKey(&group.GroupMember{ + err := k.groupMemberTable.GetOne(ctx.KVStore(k.key), orm.PrimaryKey(&group.GroupMember{ GroupId: groupId, Member: &group.Member{Address: vote.Voter}, }), &member) diff --git a/x/group/module/abci.go b/x/group/module/abci.go index 36354d1e88..4e3817f804 100644 --- a/x/group/module/abci.go +++ b/x/group/module/abci.go @@ -6,7 +6,7 @@ import ( ) func EndBlocker(ctx sdk.Context, k keeper.Keeper) { - if err := k.UpdateTallyOfVPEndProposals(ctx); err != nil { + if err := k.TallyProposalsAtVPEnd(ctx); err != nil { panic(err) } pruneProposals(ctx, k) diff --git a/x/group/module/abci_test.go b/x/group/module/abci_test.go index 4393a7258e..ba4b312986 100644 --- a/x/group/module/abci_test.go +++ b/x/group/module/abci_test.go @@ -77,7 +77,7 @@ func TestEndBlockerPruning(t *testing.T) { msgs := []sdk.Msg{msgSend1} pID, err := submitProposalAndVote(app, ctx, msgs, proposers, groupPolicyAddr, group.VOTE_OPTION_YES) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addr3.String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addr3.String(), ProposalId: pID}) require.NoError(t, err) sdkCtx := sdk.UnwrapSDKContext(ctx) require.NoError(t, testutil.FundAccount(app.BankKeeper, sdkCtx, groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -92,7 +92,7 @@ func TestEndBlockerPruning(t *testing.T) { msgs := []sdk.Msg{msgSend1, msgSend1} pID, err := submitProposalAndVote(app, ctx, msgs, proposers, groupPolicyAddr, group.VOTE_OPTION_YES) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addr3.String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addr3.String(), ProposalId: pID}) require.NoError(t, err) sdkCtx := sdk.UnwrapSDKContext(ctx) require.NoError(t, testutil.FundAccount(app.BankKeeper, sdkCtx, groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -107,7 +107,7 @@ func TestEndBlockerPruning(t *testing.T) { msgs := []sdk.Msg{msgSend1} pID, err := submitProposalAndVote(app, ctx, msgs, proposers, groupPolicyAddr, group.VOTE_OPTION_NO) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addr3.String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addr3.String(), ProposalId: pID}) require.NoError(t, err) sdkCtx := sdk.UnwrapSDKContext(ctx) require.NoError(t, testutil.FundAccount(app.BankKeeper, sdkCtx, groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -120,7 +120,7 @@ func TestEndBlockerPruning(t *testing.T) { setupProposal: func(ctx context.Context) uint64 { pID, err := submitProposal(app, ctx, []sdk.Msg{msgSend1}, proposers, groupPolicyAddr) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addr3.String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addr3.String(), ProposalId: pID}) require.NoError(t, err) sdkCtx := sdk.UnwrapSDKContext(ctx) require.NoError(t, testutil.FundAccount(app.BankKeeper, sdkCtx, groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -134,11 +134,11 @@ func TestEndBlockerPruning(t *testing.T) { pID, err := submitProposal(app, ctx, []sdk.Msg{msgSend1}, proposers, groupPolicyAddr) require.NoError(t, err) _, err = app.GroupKeeper.UpdateGroupPolicyMetadata(ctx, &group.MsgUpdateGroupPolicyMetadata{ - Admin: addr1.String(), - Address: groupPolicyAddr.String(), + Admin: addr1.String(), + GroupPolicyAddress: groupPolicyAddr.String(), }) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addr3.String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addr3.String(), ProposalId: pID}) require.NoError(t, err) sdkCtx := sdk.UnwrapSDKContext(ctx) require.NoError(t, testutil.FundAccount(app.BankKeeper, sdkCtx, groupPolicyAddr, sdk.Coins{sdk.NewInt64Coin("test", 10002)})) @@ -152,7 +152,7 @@ func TestEndBlockerPruning(t *testing.T) { msgs := []sdk.Msg{msgSend1} pID, err := submitProposalAndVote(app, ctx, msgs, proposers, groupPolicyAddr, group.VOTE_OPTION_YES) require.NoError(t, err) - _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Signer: addrs[2].String(), ProposalId: pID}) + _, err = app.GroupKeeper.Exec(ctx, &group.MsgExec{Executor: addrs[2].String(), ProposalId: pID}) require.NoError(t, err) return pID }, @@ -240,14 +240,13 @@ func TestEndBlocker(t *testing.T) { proposers := []string{addrs[2].String()} specs := map[string]struct { - preRun func(sdkCtx sdk.Context) uint64 - proposalId uint64 - admin string - expErrMsg string - newCtx sdk.Context - tallyRes group.TallyResult - expStatus group.ProposalStatus - expExecutorResult group.ProposalResult + preRun func(sdkCtx sdk.Context) uint64 + proposalId uint64 + admin string + expErrMsg string + newCtx sdk.Context + tallyRes group.TallyResult + expStatus group.ProposalStatus }{ "tally updated after voting power end": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -255,11 +254,10 @@ func TestEndBlocker(t *testing.T) { require.NoError(t, err) return pId }, - admin: proposers[0], - newCtx: ctx.WithBlockTime(ctx.BlockTime().Add(votingPeriod).Add(time.Hour)), - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx.WithBlockTime(ctx.BlockTime().Add(votingPeriod).Add(time.Hour)), + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally within voting period": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -268,11 +266,10 @@ func TestEndBlocker(t *testing.T) { return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally within voting period(with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -281,11 +278,10 @@ func TestEndBlocker(t *testing.T) { return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_SUBMITTED, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_SUBMITTED, }, "tally after voting period(with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -302,8 +298,7 @@ func TestEndBlocker(t *testing.T) { NoWithVetoCount: "0", AbstainCount: "0", }, - expStatus: group.PROPOSAL_STATUS_CLOSED, - expExecutorResult: group.PROPOSAL_RESULT_ACCEPTED, + expStatus: group.PROPOSAL_STATUS_ACCEPTED, }, "tally of closed proposal": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -318,11 +313,10 @@ func TestEndBlocker(t *testing.T) { require.NoError(t, err) return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_WITHDRAWN, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_WITHDRAWN, }, "tally of closed proposal (with votes)": { preRun: func(sdkCtx sdk.Context) uint64 { @@ -337,11 +331,10 @@ func TestEndBlocker(t *testing.T) { require.NoError(t, err) return pId }, - admin: proposers[0], - newCtx: ctx, - tallyRes: group.DefaultTallyResult(), - expStatus: group.PROPOSAL_STATUS_WITHDRAWN, - expExecutorResult: group.PROPOSAL_RESULT_UNFINALIZED, + admin: proposers[0], + newCtx: ctx, + tallyRes: group.DefaultTallyResult(), + expStatus: group.PROPOSAL_STATUS_WITHDRAWN, }, } @@ -364,7 +357,6 @@ func TestEndBlocker(t *testing.T) { require.NoError(t, err) require.Equal(t, resp.GetProposal().FinalTallyResult, spec.tallyRes) require.Equal(t, resp.GetProposal().Status, spec.expStatus) - require.Equal(t, resp.GetProposal().Result, spec.expExecutorResult) }) } } @@ -373,8 +365,8 @@ func submitProposal( app *simapp.SimApp, ctx context.Context, msgs []sdk.Msg, proposers []string, groupPolicyAddr sdk.AccAddress) (uint64, error) { proposalReq := &group.MsgSubmitProposal{ - Address: groupPolicyAddr.String(), - Proposers: proposers, + GroupPolicyAddress: groupPolicyAddr.String(), + Proposers: proposers, } err := proposalReq.SetMsgs(msgs) if err != nil { diff --git a/x/group/msgs.go b/x/group/msgs.go index 8e94bc2008..b3e6bb60cb 100644 --- a/x/group/msgs.go +++ b/x/group/msgs.go @@ -389,7 +389,7 @@ func (m MsgUpdateGroupPolicyAdmin) ValidateBasic() error { return sdkerrors.Wrap(err, "new admin") } - _, err = sdk.AccAddressFromBech32(m.Address) + _, err = sdk.AccAddressFromBech32(m.GroupPolicyAddress) if err != nil { return sdkerrors.Wrap(err, "group policy") } @@ -405,8 +405,8 @@ var _ types.UnpackInterfacesMessage = MsgUpdateGroupPolicyDecisionPolicy{} func NewMsgUpdateGroupPolicyDecisionPolicyRequest(admin sdk.AccAddress, address sdk.AccAddress, decisionPolicy DecisionPolicy) (*MsgUpdateGroupPolicyDecisionPolicy, error) { m := &MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: address.String(), + Admin: admin.String(), + GroupPolicyAddress: address.String(), } err := m.SetDecisionPolicy(decisionPolicy) if err != nil { @@ -459,7 +459,7 @@ func (m MsgUpdateGroupPolicyDecisionPolicy) ValidateBasic() error { return sdkerrors.Wrap(err, "admin") } - _, err = sdk.AccAddressFromBech32(m.Address) + _, err = sdk.AccAddressFromBech32(m.GroupPolicyAddress) if err != nil { return sdkerrors.Wrap(err, "group policy") } @@ -521,7 +521,7 @@ func (m MsgUpdateGroupPolicyMetadata) ValidateBasic() error { return sdkerrors.Wrap(err, "admin") } - _, err = sdk.AccAddressFromBech32(m.Address) + _, err = sdk.AccAddressFromBech32(m.GroupPolicyAddress) if err != nil { return sdkerrors.Wrap(err, "group policy") } @@ -590,10 +590,10 @@ var _ sdk.Msg = &MsgSubmitProposal{} // NewMsgSubmitProposalRequest creates a new MsgSubmitProposal. func NewMsgSubmitProposalRequest(address string, proposers []string, msgs []sdk.Msg, metadata string, exec Exec) (*MsgSubmitProposal, error) { m := &MsgSubmitProposal{ - Address: address, - Proposers: proposers, - Metadata: metadata, - Exec: exec, + GroupPolicyAddress: address, + Proposers: proposers, + Metadata: metadata, + Exec: exec, } err := m.SetMsgs(msgs) if err != nil { @@ -630,7 +630,7 @@ func (m MsgSubmitProposal) GetSigners() []sdk.AccAddress { // ValidateBasic does a sanity check on the provided data func (m MsgSubmitProposal) ValidateBasic() error { - _, err := sdk.AccAddressFromBech32(m.Address) + _, err := sdk.AccAddressFromBech32(m.GroupPolicyAddress) if err != nil { return sdkerrors.Wrap(err, "group policy") } @@ -778,7 +778,7 @@ func (m MsgExec) GetSignBytes() []byte { // GetSigners returns the expected signers for a MsgExec. func (m MsgExec) GetSigners() []sdk.AccAddress { - signer, err := sdk.AccAddressFromBech32(m.Signer) + signer, err := sdk.AccAddressFromBech32(m.Executor) if err != nil { panic(err) } @@ -787,7 +787,7 @@ func (m MsgExec) GetSigners() []sdk.AccAddress { // ValidateBasic does a sanity check on the provided data func (m MsgExec) ValidateBasic() error { - _, err := sdk.AccAddressFromBech32(m.Signer) + _, err := sdk.AccAddressFromBech32(m.Executor) if err != nil { return sdkerrors.Wrap(err, "signer") } diff --git a/x/group/msgs_test.go b/x/group/msgs_test.go index 190a7750bb..03e63ecc2f 100644 --- a/x/group/msgs_test.go +++ b/x/group/msgs_test.go @@ -728,8 +728,8 @@ func TestMsgUpdateGroupPolicyDecisionPolicy(t *testing.T) { { "group policy: invalid bech32 address", &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: "address", + Admin: admin.String(), + GroupPolicyAddress: "address", }, true, "group policy: decoding bech32 failed", @@ -737,8 +737,8 @@ func TestMsgUpdateGroupPolicyDecisionPolicy(t *testing.T) { { "group policy: invalid bech32 address", &group.MsgUpdateGroupPolicyDecisionPolicy{ - Admin: admin.String(), - Address: "address", + Admin: admin.String(), + GroupPolicyAddress: "address", }, true, "group policy: decoding bech32 failed", @@ -808,9 +808,9 @@ func TestMsgUpdateGroupPolicyAdmin(t *testing.T) { { "policy address: invalid bech32 address", &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - NewAdmin: member1.String(), - Address: "address", + Admin: admin.String(), + NewAdmin: member1.String(), + GroupPolicyAddress: "address", }, true, "group policy: decoding bech32 failed", @@ -818,9 +818,9 @@ func TestMsgUpdateGroupPolicyAdmin(t *testing.T) { { "new admin: invalid bech32 address", &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - Address: admin.String(), - NewAdmin: "new-admin", + Admin: admin.String(), + GroupPolicyAddress: admin.String(), + NewAdmin: "new-admin", }, true, "new admin: decoding bech32 failed", @@ -828,9 +828,9 @@ func TestMsgUpdateGroupPolicyAdmin(t *testing.T) { { "same old and new admin", &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - Address: admin.String(), - NewAdmin: admin.String(), + Admin: admin.String(), + GroupPolicyAddress: admin.String(), + NewAdmin: admin.String(), }, true, "new and old admin are same", @@ -838,9 +838,9 @@ func TestMsgUpdateGroupPolicyAdmin(t *testing.T) { { "valid test", &group.MsgUpdateGroupPolicyAdmin{ - Admin: admin.String(), - Address: admin.String(), - NewAdmin: member1.String(), + Admin: admin.String(), + GroupPolicyAddress: admin.String(), + NewAdmin: member1.String(), }, false, "", @@ -880,8 +880,8 @@ func TestMsgUpdateGroupPolicyMetadata(t *testing.T) { { "group policy address: invalid bech32 address", &group.MsgUpdateGroupPolicyMetadata{ - Admin: admin.String(), - Address: "address", + Admin: admin.String(), + GroupPolicyAddress: "address", }, true, "group policy: decoding bech32 failed", @@ -889,9 +889,9 @@ func TestMsgUpdateGroupPolicyMetadata(t *testing.T) { { "valid testcase", &group.MsgUpdateGroupPolicyMetadata{ - Admin: admin.String(), - Address: member1.String(), - Metadata: "metadata", + Admin: admin.String(), + GroupPolicyAddress: member1.String(), + Metadata: "metadata", }, false, "", @@ -923,7 +923,7 @@ func TestMsgSubmitProposal(t *testing.T) { { "invalid group policy address", &group.MsgSubmitProposal{ - Address: "address", + GroupPolicyAddress: "address", }, true, "group policy: decoding bech32 failed", @@ -931,7 +931,7 @@ func TestMsgSubmitProposal(t *testing.T) { { "proposers required", &group.MsgSubmitProposal{ - Address: admin.String(), + GroupPolicyAddress: admin.String(), }, true, "proposers: value is empty", @@ -939,8 +939,8 @@ func TestMsgSubmitProposal(t *testing.T) { { "valid testcase", &group.MsgSubmitProposal{ - Address: admin.String(), - Proposers: []string{member1.String(), member2.String()}, + GroupPolicyAddress: admin.String(), + Proposers: []string{member1.String(), member2.String()}, }, false, "", @@ -1080,7 +1080,7 @@ func TestMsgExec(t *testing.T) { { "invalid signer address", &group.MsgExec{ - Signer: "signer", + Executor: "signer", }, true, "signer: decoding bech32 failed", @@ -1088,7 +1088,7 @@ func TestMsgExec(t *testing.T) { { "proposal is required", &group.MsgExec{ - Signer: admin.String(), + Executor: admin.String(), }, true, "proposal id: value is empty", @@ -1096,7 +1096,7 @@ func TestMsgExec(t *testing.T) { { "valid testcase", &group.MsgExec{ - Signer: admin.String(), + Executor: admin.String(), ProposalId: 1, }, false, @@ -1145,7 +1145,7 @@ func TestMsgLeaveGroup(t *testing.T) { "valid testcase", &group.MsgLeaveGroup{ Address: admin.String(), - GroupId: 1, + GroupId: 1, }, false, "", diff --git a/x/group/query.pb.go b/x/group/query.pb.go index e274b18585..47cfd7fccd 100644 --- a/x/group/query.pb.go +++ b/x/group/query.pb.go @@ -1530,7 +1530,11 @@ type QueryClient interface { VotesByVoter(ctx context.Context, in *QueryVotesByVoterRequest, opts ...grpc.CallOption) (*QueryVotesByVoterResponse, error) // GroupsByMember queries groups by member address. GroupsByMember(ctx context.Context, in *QueryGroupsByMemberRequest, opts ...grpc.CallOption) (*QueryGroupsByMemberResponse, error) - // TallyResult queries the tally of a proposal votes. + // TallyResult returns the tally result of a proposal. If the proposal is + // still in voting period, then this query computes the current tally state, + // which might not be final. On the other hand, if the proposal is final, + // then it simply returns the `final_tally_result` state stored in the + // proposal itself. TallyResult(ctx context.Context, in *QueryTallyResultRequest, opts ...grpc.CallOption) (*QueryTallyResultResponse, error) } @@ -1685,7 +1689,11 @@ type QueryServer interface { VotesByVoter(context.Context, *QueryVotesByVoterRequest) (*QueryVotesByVoterResponse, error) // GroupsByMember queries groups by member address. GroupsByMember(context.Context, *QueryGroupsByMemberRequest) (*QueryGroupsByMemberResponse, error) - // TallyResult queries the tally of a proposal votes. + // TallyResult returns the tally result of a proposal. If the proposal is + // still in voting period, then this query computes the current tally state, + // which might not be final. On the other hand, if the proposal is final, + // then it simply returns the `final_tally_result` state stored in the + // proposal itself. TallyResult(context.Context, *QueryTallyResultRequest) (*QueryTallyResultResponse, error) } diff --git a/x/group/simulation/genesis.go b/x/group/simulation/genesis.go index afd283a068..59040a502f 100644 --- a/x/group/simulation/genesis.go +++ b/x/group/simulation/genesis.go @@ -86,11 +86,10 @@ func getProposals(r *rand.Rand, simState *module.SimulationState, groupPolicies proposal := &group.Proposal{ Id: uint64(i + 1), Proposers: proposers, - Address: groupPolicyAddress, + GroupPolicyAddress: groupPolicyAddress, GroupVersion: uint64(i + 1), GroupPolicyVersion: uint64(i + 1), Status: group.PROPOSAL_STATUS_SUBMITTED, - Result: group.PROPOSAL_RESULT_ACCEPTED, FinalTallyResult: group.TallyResult{ YesCount: "1", NoCount: "1", diff --git a/x/group/simulation/operations.go b/x/group/simulation/operations.go index 4bcdcc67ad..1bb8c205b0 100644 --- a/x/group/simulation/operations.go +++ b/x/group/simulation/operations.go @@ -439,9 +439,9 @@ func SimulateMsgSubmitProposal(ak group.AccountKeeper, bk group.BankKeeper, k ke } msg := group.MsgSubmitProposal{ - Address: groupPolicyAddr, - Proposers: []string{acc.Address.String()}, - Metadata: simtypes.RandStringOfLength(r, 10), + GroupPolicyAddress: groupPolicyAddr, + Proposers: []string{acc.Address.String()}, + Metadata: simtypes.RandStringOfLength(r, 10), } txGen := simappparams.MakeTestEncodingConfig().TxConfig @@ -681,9 +681,9 @@ func SimulateMsgUpdateGroupPolicyAdmin(ak group.AccountKeeper, bk group.BankKeep } msg := group.MsgUpdateGroupPolicyAdmin{ - Admin: acc.Address.String(), - Address: groupPolicyAddr, - NewAdmin: newAdmin.Address.String(), + Admin: acc.Address.String(), + GroupPolicyAddress: groupPolicyAddr, + NewAdmin: newAdmin.Address.String(), } txGen := simappparams.MakeTestEncodingConfig().TxConfig @@ -789,9 +789,9 @@ func SimulateMsgUpdateGroupPolicyMetadata(ak group.AccountKeeper, } msg := group.MsgUpdateGroupPolicyMetadata{ - Admin: acc.Address.String(), - Address: groupPolicyAddr, - Metadata: simtypes.RandStringOfLength(r, 10), + Admin: acc.Address.String(), + GroupPolicyAddress: groupPolicyAddr, + Metadata: simtypes.RandStringOfLength(r, 10), } txGen := simappparams.MakeTestEncodingConfig().TxConfig @@ -1056,7 +1056,7 @@ func SimulateMsgExec(ak group.AccountKeeper, proposalID := -1 for _, proposal := range proposals { - if proposal.Status == group.PROPOSAL_STATUS_CLOSED { + if proposal.Status == group.PROPOSAL_STATUS_ACCEPTED { proposalID = int(proposal.Id) break } @@ -1069,7 +1069,7 @@ func SimulateMsgExec(ak group.AccountKeeper, msg := group.MsgExec{ ProposalId: uint64(proposalID), - Signer: acc.Address.String(), + Executor: acc.Address.String(), } txGen := simappparams.MakeTestEncodingConfig().TxConfig tx, err := helpers.GenTx( diff --git a/x/group/simulation/operations_test.go b/x/group/simulation/operations_test.go index 12f476b88a..86c07fd95f 100644 --- a/x/group/simulation/operations_test.go +++ b/x/group/simulation/operations_test.go @@ -244,7 +244,7 @@ func (suite *SimTestSuite) TestSimulateSubmitProposal() { err = legacy.Cdc.UnmarshalJSON(operationMsg.Msg, &msg) suite.Require().NoError(err) suite.Require().True(operationMsg.OK) - suite.Require().Equal(groupPolicyRes.Address, msg.Address) + suite.Require().Equal(groupPolicyRes.Address, msg.GroupPolicyAddress) suite.Require().Len(futureOperations, 0) } @@ -452,7 +452,7 @@ func (suite *SimTestSuite) TestSimulateExec() { err = legacy.Cdc.UnmarshalJSON(operationMsg.Msg, &msg) suite.Require().NoError(err) suite.Require().True(operationMsg.OK) - suite.Require().Equal(addr, msg.Signer) + suite.Require().Equal(addr, msg.Executor) suite.Require().Len(futureOperations, 0) } @@ -631,7 +631,7 @@ func (suite *SimTestSuite) TestSimulateUpdateGroupPolicyAdmin() { err = legacy.Cdc.UnmarshalJSON(operationMsg.Msg, &msg) suite.Require().NoError(err) suite.Require().True(operationMsg.OK) - suite.Require().Equal(groupPolicyRes.Address, msg.Address) + suite.Require().Equal(groupPolicyRes.Address, msg.GroupPolicyAddress) suite.Require().Len(futureOperations, 0) } @@ -684,7 +684,7 @@ func (suite *SimTestSuite) TestSimulateUpdateGroupPolicyDecisionPolicy() { err = legacy.Cdc.UnmarshalJSON(operationMsg.Msg, &msg) suite.Require().NoError(err) suite.Require().True(operationMsg.OK) - suite.Require().Equal(groupPolicyRes.Address, msg.Address) + suite.Require().Equal(groupPolicyRes.Address, msg.GroupPolicyAddress) suite.Require().Len(futureOperations, 0) } @@ -737,7 +737,7 @@ func (suite *SimTestSuite) TestSimulateUpdateGroupPolicyMetadata() { err = legacy.Cdc.UnmarshalJSON(operationMsg.Msg, &msg) suite.Require().NoError(err) suite.Require().True(operationMsg.OK) - suite.Require().Equal(groupPolicyRes.Address, msg.Address) + suite.Require().Equal(groupPolicyRes.Address, msg.GroupPolicyAddress) suite.Require().Len(futureOperations, 0) } diff --git a/x/group/tx.pb.go b/x/group/tx.pb.go index 0f3dee3a2f..4c0eb24d93 100644 --- a/x/group/tx.pb.go +++ b/x/group/tx.pb.go @@ -572,8 +572,8 @@ func (m *MsgCreateGroupPolicyResponse) GetAddress() string { type MsgUpdateGroupPolicyAdmin struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of the group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of the group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // new_admin is the new group policy admin. NewAdmin string `protobuf:"bytes,3,opt,name=new_admin,json=newAdmin,proto3" json:"new_admin,omitempty"` } @@ -618,9 +618,9 @@ func (m *MsgUpdateGroupPolicyAdmin) GetAdmin() string { return "" } -func (m *MsgUpdateGroupPolicyAdmin) GetAddress() string { +func (m *MsgUpdateGroupPolicyAdmin) GetGroupPolicyAddress() string { if m != nil { - return m.Address + return m.GroupPolicyAddress } return "" } @@ -642,7 +642,8 @@ type MsgCreateGroupWithPolicy struct { GroupMetadata string `protobuf:"bytes,3,opt,name=group_metadata,json=groupMetadata,proto3" json:"group_metadata,omitempty"` // group_policy_metadata is any arbitrary metadata attached to the group policy. GroupPolicyMetadata string `protobuf:"bytes,4,opt,name=group_policy_metadata,json=groupPolicyMetadata,proto3" json:"group_policy_metadata,omitempty"` - // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group and group policy admin. + // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group + // and group policy admin. GroupPolicyAsAdmin bool `protobuf:"varint,5,opt,name=group_policy_as_admin,json=groupPolicyAsAdmin,proto3" json:"group_policy_as_admin,omitempty"` // decision_policy specifies the group policy's decision policy. DecisionPolicy *types.Any `protobuf:"bytes,6,opt,name=decision_policy,json=decisionPolicy,proto3" json:"decision_policy,omitempty"` @@ -777,8 +778,8 @@ var xxx_messageInfo_MsgUpdateGroupPolicyAdminResponse proto.InternalMessageInfo type MsgUpdateGroupPolicyDecisionPolicy struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // decision_policy is the updated group policy's decision policy. DecisionPolicy *types.Any `protobuf:"bytes,3,opt,name=decision_policy,json=decisionPolicy,proto3" json:"decision_policy,omitempty"` } @@ -861,8 +862,8 @@ var xxx_messageInfo_MsgUpdateGroupPolicyDecisionPolicyResponse proto.InternalMes type MsgUpdateGroupPolicyMetadata struct { // admin is the account address of the group admin. Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // metadata is the updated group policy metadata. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` } @@ -907,9 +908,9 @@ func (m *MsgUpdateGroupPolicyMetadata) GetAdmin() string { return "" } -func (m *MsgUpdateGroupPolicyMetadata) GetAddress() string { +func (m *MsgUpdateGroupPolicyMetadata) GetGroupPolicyAddress() string { if m != nil { - return m.Address + return m.GroupPolicyAddress } return "" } @@ -960,8 +961,8 @@ var xxx_messageInfo_MsgUpdateGroupPolicyMetadataResponse proto.InternalMessageIn // MsgSubmitProposal is the Msg/SubmitProposal request type. type MsgSubmitProposal struct { - // address is the account address of group policy. - Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,1,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // proposers are the account addresses of the proposers. // Proposers signatures will be counted as yes votes. Proposers []string `protobuf:"bytes,2,rep,name=proposers,proto3" json:"proposers,omitempty"` @@ -1270,8 +1271,8 @@ var xxx_messageInfo_MsgVoteResponse proto.InternalMessageInfo type MsgExec struct { // proposal is the unique ID of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` - // signer is the account address used to execute the proposal. - Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` + // executor is the account address used to execute the proposal. + Executor string `protobuf:"bytes,2,opt,name=executor,proto3" json:"executor,omitempty"` } func (m *MsgExec) Reset() { *m = MsgExec{} } @@ -1314,9 +1315,9 @@ func (m *MsgExec) GetProposalId() uint64 { return 0 } -func (m *MsgExec) GetSigner() string { +func (m *MsgExec) GetExecutor() string { if m != nil { - return m.Signer + return m.Executor } return "" } @@ -1485,84 +1486,85 @@ func init() { func init() { proto.RegisterFile("cosmos/group/v1/tx.proto", fileDescriptor_6b8d3d629f136420) } var fileDescriptor_6b8d3d629f136420 = []byte{ - // 1232 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x58, 0x4b, 0x6f, 0xe3, 0x54, - 0x14, 0xce, 0x6d, 0x32, 0x7d, 0x9c, 0x4c, 0xd3, 0xd6, 0x4d, 0xa7, 0xa9, 0x3b, 0x93, 0x04, 0xd3, - 0xe9, 0x74, 0xa2, 0xa9, 0x33, 0x4d, 0x35, 0x42, 0x2a, 0x08, 0xa9, 0x2f, 0x50, 0x11, 0x81, 0xe2,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0x49, 0xb8, 0x0d, 0xff, 0x15, 0x21, 0x3c, 0x04, 0xf0, 0xdd, - 0x0f, 0xf9, 0x30, 0x7c, 0x47, 0x2e, 0x2e, 0x5e, 0x2c, 0xf7, 0xac, 0x6e, 0xbc, 0xf9, 0xec, 0x2c, - 0x8f, 0x9e, 0x9f, 0xe5, 0xd1, 0x8b, 0xb3, 0x3c, 0xfa, 0xf6, 0x3c, 0x9f, 0x78, 0x7e, 0x9e, 0x4f, - 0xfc, 0x71, 0x9e, 0x4f, 0x7c, 0xb2, 0x60, 0x98, 0xf6, 0xd3, 0xf6, 0xbe, 0x5c, 0xc7, 0x0d, 0xf7, - 0x17, 0x36, 0xf7, 0xcf, 0x32, 0xd1, 0x3e, 0x2f, 0x1f, 0xb3, 0x5f, 0xd1, 0xf6, 0x87, 0xe9, 0x3a, - 0xb5, 0xfa, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x28, 0x4b, 0x31, 0x90, 0xd3, 0x13, 0x00, 0x00, + // 1241 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x58, 0xcd, 0x6e, 0xe3, 0x54, + 0x14, 0x8e, 0x93, 0x4c, 0x9b, 0x9e, 0xcc, 0xa4, 0xad, 0x9b, 0x4e, 0x53, 0x77, 0x26, 0x09, 0xa6, + 0xd3, 0xe9, 0x44, 0x53, 0x87, 0xa6, 0x8c, 0x90, 0x0a, 0x42, 0xea, 0x1f, 0xa8, 0x88, 0x40, 0x71, + 0x67, 0x18, 0x60, 0x13, 0xdc, 0xd8, 0xe3, 0xb1, 0x48, 0x72, 0xad, 0x5c, 0xa7, 0x4d, 0x97, 0xc0, + 0x86, 0x9f, 0x0d, 0x12, 0x2f, 0x00, 0xe2, 0x05, 0x58, 0xf4, 0x09, 0x60, 0x33, 0x62, 0x35, 0x62, + 0x85, 0x58, 0xa0, 0x51, 0xbb, 0xe0, 0x05, 0x78,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2, 0x79, 0x01, 0x52, + 0x4d, 0xcd, 0x52, 0x54, 0xc5, 0x52, 0x72, 0x09, 0x3b, 0x97, 0xcc, 0x9e, 0x37, 0xe1, 0x8b, 0xbf, + 0x7f, 0x2e, 0xd1, 0x04, 0xe2, 0x06, 0xdc, 0xf4, 0x53, 0x94, 0x35, 0x6c, 0xa2, 0x16, 0xd6, 0xf8, + 0x45, 0x48, 0x91, 0x1c, 0x35, 0x43, 0x25, 0x6c, 0x93, 0xf2, 0x24, 0x79, 0xde, 0x57, 0xc5, 0x33, + 0x0e, 0xe6, 0xab, 0x58, 0x7f, 0x64, 0xaa, 0xae, 0x57, 0xd5, 0x49, 0x7b, 0x55, 0x7d, 0xde, 0x24, + 0x71, 0x5f, 0x12, 0x7e, 0x17, 0x32, 0x54, 0x4c, 0xad, 0x43, 0xf2, 0xe0, 0x5c, 0x22, 0x4a, 0x05, + 0x6e, 0x50, 0x27, 0xca, 0x0d, 0xfb, 0xb4, 0x16, 0xe0, 0x76, 0x20, 0x6b, 0x57, 0xb2, 0xf8, 0x13, + 0x07, 0x73, 0x7e, 0xc4, 0x16, 0x61, 0x39, 0x46, 0x55, 0x0f, 0x60, 0xaa, 0xa5, 0x9d, 0xd4, 0x68, + 0xb8, 0x44, 0x48, 0xb8, 0x54, 0x4b, 0x3b, 0x21, 0x0c, 0x7c, 0x32, 0x6e, 0xc3, 0x52, 0x00, 0x49, + 0x26, 0xe2, 0x5b, 0x8e, 0x2c, 0xa9, 0x4f, 0x26, 0x5d, 0xf8, 0x71, 0xea, 0x88, 0xda, 0x5f, 0x45, + 0xc8, 0x07, 0x93, 0x61, 0x7c, 0x5f, 0x70, 0x90, 0xf5, 0xb7, 0xe0, 0x01, 0x6a, 0x18, 0xf5, 0xd3, + 0xff, 0x88, 0x2d, 0xff, 0x01, 0x4c, 0xab, 0x5a, 0xdd, 0xc0, 0x06, 0x6a, 0xd5, 0x4c, 0x92, 0x39, + 0x97, 0x2c, 0x72, 0xab, 0xe9, 0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5, 0x79, + 0x9e, 0xfb, 0xee, 0x22, 0x1f, 0x7b, 0x7e, 0x91, 0x8f, 0xfd, 0x71, 0x91, 0x8f, 0x7d, 0xb2, 0xac, + 0x1b, 0xd6, 0xd3, 0xce, 0x91, 0x54, 0x47, 0x4d, 0xe7, 0xd7, 0x3d, 0xe7, 0xcf, 0x1a, 0x56, 0x3f, + 0x2b, 0x77, 0xe9, 0x2f, 0x78, 0x47, 0x13, 0xe4, 0x82, 0xb5, 0xf1, 0x6f, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x91, 0xea, 0x5a, 0x20, 0x4f, 0x14, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -2533,10 +2535,10 @@ func (m *MsgUpdateGroupPolicyAdmin) MarshalToSizedBuffer(dAtA []byte) (int, erro i-- dAtA[i] = 0x1a } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + if len(m.GroupPolicyAddress) > 0 { + i -= len(m.GroupPolicyAddress) + copy(dAtA[i:], m.GroupPolicyAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -2720,10 +2722,10 @@ func (m *MsgUpdateGroupPolicyDecisionPolicy) MarshalToSizedBuffer(dAtA []byte) ( i-- dAtA[i] = 0x1a } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + if len(m.GroupPolicyAddress) > 0 { + i -= len(m.GroupPolicyAddress) + copy(dAtA[i:], m.GroupPolicyAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -2787,10 +2789,10 @@ func (m *MsgUpdateGroupPolicyMetadata) MarshalToSizedBuffer(dAtA []byte) (int, e i-- dAtA[i] = 0x1a } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + if len(m.GroupPolicyAddress) > 0 { + i -= len(m.GroupPolicyAddress) + copy(dAtA[i:], m.GroupPolicyAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -2882,10 +2884,10 @@ func (m *MsgSubmitProposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { dAtA[i] = 0x12 } } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + if len(m.GroupPolicyAddress) > 0 { + i -= len(m.GroupPolicyAddress) + copy(dAtA[i:], m.GroupPolicyAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.GroupPolicyAddress))) i-- dAtA[i] = 0xa } @@ -3073,10 +3075,10 @@ func (m *MsgExec) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + if len(m.Executor) > 0 { + i -= len(m.Executor) + copy(dAtA[i:], m.Executor) + i = encodeVarintTx(dAtA, i, uint64(len(m.Executor))) i-- dAtA[i] = 0x12 } @@ -3351,7 +3353,7 @@ func (m *MsgUpdateGroupPolicyAdmin) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.Address) + l = len(m.GroupPolicyAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } @@ -3431,7 +3433,7 @@ func (m *MsgUpdateGroupPolicyDecisionPolicy) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.Address) + l = len(m.GroupPolicyAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } @@ -3461,7 +3463,7 @@ func (m *MsgUpdateGroupPolicyMetadata) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.Address) + l = len(m.GroupPolicyAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } @@ -3487,7 +3489,7 @@ func (m *MsgSubmitProposal) Size() (n int) { } var l int _ = l - l = len(m.Address) + l = len(m.GroupPolicyAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } @@ -3594,7 +3596,7 @@ func (m *MsgExec) Size() (n int) { if m.ProposalId != 0 { n += 1 + sovTx(uint64(m.ProposalId)) } - l = len(m.Signer) + l = len(m.Executor) if l > 0 { n += 1 + l + sovTx(uint64(l)) } @@ -4723,7 +4725,7 @@ func (m *MsgUpdateGroupPolicyAdmin) Unmarshal(dAtA []byte) error { iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -4751,7 +4753,7 @@ func (m *MsgUpdateGroupPolicyAdmin) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + m.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -5256,7 +5258,7 @@ func (m *MsgUpdateGroupPolicyDecisionPolicy) Unmarshal(dAtA []byte) error { iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5284,7 +5286,7 @@ func (m *MsgUpdateGroupPolicyDecisionPolicy) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + m.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -5456,7 +5458,7 @@ func (m *MsgUpdateGroupPolicyMetadata) Unmarshal(dAtA []byte) error { iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5484,7 +5486,7 @@ func (m *MsgUpdateGroupPolicyMetadata) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + m.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -5620,7 +5622,7 @@ func (m *MsgSubmitProposal) Unmarshal(dAtA []byte) error { switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -5648,7 +5650,7 @@ func (m *MsgSubmitProposal) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + m.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -6279,7 +6281,7 @@ func (m *MsgExec) Unmarshal(dAtA []byte) error { } case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Executor", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -6307,7 +6309,7 @@ func (m *MsgExec) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Signer = string(dAtA[iNdEx:postIndex]) + m.Executor = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex diff --git a/x/group/types.go b/x/group/types.go index 6dcab3c338..feeab8387b 100644 --- a/x/group/types.go +++ b/x/group/types.go @@ -15,8 +15,14 @@ import ( "github.com/cosmos/cosmos-sdk/x/group/internal/orm" ) +// DecisionPolicyResult is the result of whether a proposal passes or not a +// decision policy. type DecisionPolicyResult struct { + // Allow determines if the proposal is allowed to pass. Allow bool + // Final determines if the tally result is final or not. If final, then + // votes are pruned, and the tally result is saved in the proposal's + // `FinalTallyResult` field. Final bool } @@ -359,7 +365,7 @@ func (p Proposal) ValidateBasic() error { if p.Id == 0 { return sdkerrors.Wrap(errors.ErrEmpty, "proposal id") } - _, err := sdk.AccAddressFromBech32(p.Address) + _, err := sdk.AccAddressFromBech32(p.GroupPolicyAddress) if err != nil { return sdkerrors.Wrap(err, "proposal group policy address") } diff --git a/x/group/types.pb.go b/x/group/types.pb.go index 7da01bbd14..0930b5a198 100644 --- a/x/group/types.pb.go +++ b/x/group/types.pb.go @@ -34,7 +34,8 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type VoteOption int32 const ( - // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. + // VOTE_OPTION_UNSPECIFIED defines an unspecified vote option which will + // return an error. VOTE_OPTION_UNSPECIFIED VoteOption = 0 // VOTE_OPTION_YES defines a yes vote option. VOTE_OPTION_YES VoteOption = 1 @@ -76,31 +77,38 @@ type ProposalStatus int32 const ( // An empty value is invalid and not allowed. PROPOSAL_STATUS_UNSPECIFIED ProposalStatus = 0 - // Initial status of a proposal when persisted. + // Initial status of a proposal when submitted. PROPOSAL_STATUS_SUBMITTED ProposalStatus = 1 - // Final status of a proposal when the final tally was executed. - PROPOSAL_STATUS_CLOSED ProposalStatus = 2 - // Final status of a proposal when the group was modified before the final tally. - PROPOSAL_STATUS_ABORTED ProposalStatus = 3 - // A proposal can be deleted before the voting start time by the owner. When this happens the final status - // is Withdrawn. - PROPOSAL_STATUS_WITHDRAWN ProposalStatus = 4 + // Final status of a proposal when the final tally is done and the outcome + // passes the group policy's decision policy. + PROPOSAL_STATUS_ACCEPTED ProposalStatus = 2 + // Final status of a proposal when the final tally is done and the outcome + // is rejected by the group policy's decision policy. + PROPOSAL_STATUS_REJECTED ProposalStatus = 3 + // Final status of a proposal when the group policy is modified before the + // final tally. + PROPOSAL_STATUS_ABORTED ProposalStatus = 4 + // A proposal can be withdrawn before the voting start time by the owner. + // When this happens the final status is Withdrawn. + PROPOSAL_STATUS_WITHDRAWN ProposalStatus = 5 ) var ProposalStatus_name = map[int32]string{ 0: "PROPOSAL_STATUS_UNSPECIFIED", 1: "PROPOSAL_STATUS_SUBMITTED", - 2: "PROPOSAL_STATUS_CLOSED", - 3: "PROPOSAL_STATUS_ABORTED", - 4: "PROPOSAL_STATUS_WITHDRAWN", + 2: "PROPOSAL_STATUS_ACCEPTED", + 3: "PROPOSAL_STATUS_REJECTED", + 4: "PROPOSAL_STATUS_ABORTED", + 5: "PROPOSAL_STATUS_WITHDRAWN", } var ProposalStatus_value = map[string]int32{ "PROPOSAL_STATUS_UNSPECIFIED": 0, "PROPOSAL_STATUS_SUBMITTED": 1, - "PROPOSAL_STATUS_CLOSED": 2, - "PROPOSAL_STATUS_ABORTED": 3, - "PROPOSAL_STATUS_WITHDRAWN": 4, + "PROPOSAL_STATUS_ACCEPTED": 2, + "PROPOSAL_STATUS_REJECTED": 3, + "PROPOSAL_STATUS_ABORTED": 4, + "PROPOSAL_STATUS_WITHDRAWN": 5, } func (x ProposalStatus) String() string { @@ -111,42 +119,6 @@ func (ProposalStatus) EnumDescriptor() ([]byte, []int) { return fileDescriptor_f5bddd15d7a54a9d, []int{1} } -// ProposalResult defines types of proposal results. -type ProposalResult int32 - -const ( - // An empty value is invalid and not allowed - PROPOSAL_RESULT_UNSPECIFIED ProposalResult = 0 - // Until a final tally has happened the status is unfinalized - PROPOSAL_RESULT_UNFINALIZED ProposalResult = 1 - // Final result of the tally - PROPOSAL_RESULT_ACCEPTED ProposalResult = 2 - // Final result of the tally - PROPOSAL_RESULT_REJECTED ProposalResult = 3 -) - -var ProposalResult_name = map[int32]string{ - 0: "PROPOSAL_RESULT_UNSPECIFIED", - 1: "PROPOSAL_RESULT_UNFINALIZED", - 2: "PROPOSAL_RESULT_ACCEPTED", - 3: "PROPOSAL_RESULT_REJECTED", -} - -var ProposalResult_value = map[string]int32{ - "PROPOSAL_RESULT_UNSPECIFIED": 0, - "PROPOSAL_RESULT_UNFINALIZED": 1, - "PROPOSAL_RESULT_ACCEPTED": 2, - "PROPOSAL_RESULT_REJECTED": 3, -} - -func (x ProposalResult) String() string { - return proto.EnumName(ProposalResult_name, int32(x)) -} - -func (ProposalResult) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_f5bddd15d7a54a9d, []int{2} -} - // ProposalExecutorResult defines types of proposal executor results. type ProposalExecutorResult int32 @@ -180,7 +152,7 @@ func (x ProposalExecutorResult) String() string { } func (ProposalExecutorResult) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_f5bddd15d7a54a9d, []int{3} + return fileDescriptor_f5bddd15d7a54a9d, []int{2} } // Member represents a group member with an account address, @@ -190,7 +162,7 @@ type Member struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` // weight is the member's voting weight that should be greater than 0. Weight string `protobuf:"bytes,2,opt,name=weight,proto3" json:"weight,omitempty"` - // metadata is any arbitrary metadata to attached to the member. + // metadata is any arbitrary metadata attached to the member. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` // added_at is a timestamp specifying when a member was added. AddedAt time.Time `protobuf:"bytes,4,opt,name=added_at,json=addedAt,proto3,stdtime" json:"added_at"` @@ -303,9 +275,15 @@ func (m *Members) GetMembers() []Member { return nil } -// ThresholdDecisionPolicy implements the DecisionPolicy interface +// ThresholdDecisionPolicy is a decision policy where a proposal passes when it +// satisfies the two following conditions: +// 1. The sum of all `YES` voters' weights is greater or equal than the defined +// `threshold`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type ThresholdDecisionPolicy struct { - // threshold is the minimum weighted sum of yes votes that must be met or exceeded for a proposal to succeed. + // threshold is the minimum weighted sum of `YES` votes that must be met or + // exceeded for a proposal to succeed. Threshold string `protobuf:"bytes,1,opt,name=threshold,proto3" json:"threshold,omitempty"` // windows defines the different windows for voting and execution. Windows *DecisionPolicyWindows `protobuf:"bytes,2,opt,name=windows,proto3" json:"windows,omitempty"` @@ -358,9 +336,15 @@ func (m *ThresholdDecisionPolicy) GetWindows() *DecisionPolicyWindows { return nil } -// PercentageDecisionPolicy implements the DecisionPolicy interface +// PercentageDecisionPolicy is a decision policy where a proposal passes when +// it satisfies the two following conditions: +// 1. The percentage of all `YES` voters' weights out of the total group weight +// is greater or equal than the given `percentage`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type PercentageDecisionPolicy struct { - // percentage is the minimum percentage the weighted sum of yes votes must meet for a proposal to succeed. + // percentage is the minimum percentage the weighted sum of `YES` votes must + // meet for a proposal to succeed. Percentage string `protobuf:"bytes,1,opt,name=percentage,proto3" json:"percentage,omitempty"` // windows defines the different windows for voting and execution. Windows *DecisionPolicyWindows `protobuf:"bytes,2,opt,name=windows,proto3" json:"windows,omitempty"` @@ -687,40 +671,39 @@ var xxx_messageInfo_GroupPolicyInfo proto.InternalMessageInfo type Proposal struct { // id is the unique id of the proposal. Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - // address is the account address of group policy. - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + // group_policy_address is the account address of group policy. + GroupPolicyAddress string `protobuf:"bytes,2,opt,name=group_policy_address,json=groupPolicyAddress,proto3" json:"group_policy_address,omitempty"` // metadata is any arbitrary metadata to attached to the proposal. Metadata string `protobuf:"bytes,3,opt,name=metadata,proto3" json:"metadata,omitempty"` // proposers are the account addresses of the proposers. Proposers []string `protobuf:"bytes,4,rep,name=proposers,proto3" json:"proposers,omitempty"` // submit_time is a timestamp specifying when a proposal was submitted. SubmitTime time.Time `protobuf:"bytes,5,opt,name=submit_time,json=submitTime,proto3,stdtime" json:"submit_time"` - // group_version tracks the version of the group that this proposal corresponds to. - // When group membership is changed, existing proposals from previous group versions will become invalid. + // group_version tracks the version of the group at proposal submission. + // This field is here for informational purposes only. GroupVersion uint64 `protobuf:"varint,6,opt,name=group_version,json=groupVersion,proto3" json:"group_version,omitempty"` - // group_policy_version tracks the version of the group policy that this proposal corresponds to. - // When a decision policy is changed, existing proposals from previous policy versions will become invalid. + // group_policy_version tracks the version of the group policy at proposal submission. + // When a decision policy is changed, existing proposals from previous policy + // versions will become invalid with the `ABORTED` status. + // This field is here for informational purposes only. GroupPolicyVersion uint64 `protobuf:"varint,7,opt,name=group_policy_version,json=groupPolicyVersion,proto3" json:"group_policy_version,omitempty"` // status represents the high level position in the life cycle of the proposal. Initial value is Submitted. Status ProposalStatus `protobuf:"varint,8,opt,name=status,proto3,enum=cosmos.group.v1.ProposalStatus" json:"status,omitempty"` - // result is the final result based on the votes and election rule. Initial value is unfinalized. - // The result is persisted so that clients can always rely on this state and not have to replicate the logic. - Result ProposalResult `protobuf:"varint,9,opt,name=result,proto3,enum=cosmos.group.v1.ProposalResult" json:"result,omitempty"` // final_tally_result contains the sums of all weighted votes for this - // proposal for each vote option, after tallying. When querying a proposal - // via gRPC, this field is not populated until the proposal's voting period - // has ended. - FinalTallyResult TallyResult `protobuf:"bytes,10,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result"` + // proposal for each vote option. It is empty at submission, and only + // populated after tallying, at voting period end or at proposal execution, + // whichever happens first. + FinalTallyResult TallyResult `protobuf:"bytes,9,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result"` // voting_period_end is the timestamp before which voting must be done. // Unless a successfull MsgExec is called before (to execute a proposal whose // tally is successful before the voting period ends), tallying will be done - // at this point, and the `final_tally_result`, as well - // as `status` and `result` fields will be accordingly updated. - VotingPeriodEnd time.Time `protobuf:"bytes,11,opt,name=voting_period_end,json=votingPeriodEnd,proto3,stdtime" json:"voting_period_end"` + // at this point, and the `final_tally_result`and `status` fields will be + // accordingly updated. + VotingPeriodEnd time.Time `protobuf:"bytes,10,opt,name=voting_period_end,json=votingPeriodEnd,proto3,stdtime" json:"voting_period_end"` // executor_result is the final result based on the votes and election rule. Initial value is NotRun. - ExecutorResult ProposalExecutorResult `protobuf:"varint,12,opt,name=executor_result,json=executorResult,proto3,enum=cosmos.group.v1.ProposalExecutorResult" json:"executor_result,omitempty"` - // messages is a list of Msgs that will be executed if the proposal passes. - Messages []*types.Any `protobuf:"bytes,13,rep,name=messages,proto3" json:"messages,omitempty"` + ExecutorResult ProposalExecutorResult `protobuf:"varint,11,opt,name=executor_result,json=executorResult,proto3,enum=cosmos.group.v1.ProposalExecutorResult" json:"executor_result,omitempty"` + // messages is a list of `sdk.Msg`s that will be executed if the proposal passes. + Messages []*types.Any `protobuf:"bytes,12,rep,name=messages,proto3" json:"messages,omitempty"` } func (m *Proposal) Reset() { *m = Proposal{} } @@ -762,7 +745,7 @@ type TallyResult struct { YesCount string `protobuf:"bytes,1,opt,name=yes_count,json=yesCount,proto3" json:"yes_count,omitempty"` // abstain_count is the weighted sum of abstainers. AbstainCount string `protobuf:"bytes,2,opt,name=abstain_count,json=abstainCount,proto3" json:"abstain_count,omitempty"` - // no is the weighted sum of no votes. + // no_count is the weighted sum of no votes. NoCount string `protobuf:"bytes,3,opt,name=no_count,json=noCount,proto3" json:"no_count,omitempty"` // no_with_veto_count is the weighted sum of veto. NoWithVetoCount string `protobuf:"bytes,4,opt,name=no_with_veto_count,json=noWithVetoCount,proto3" json:"no_with_veto_count,omitempty"` @@ -886,7 +869,6 @@ func (m *Vote) GetSubmitTime() time.Time { func init() { proto.RegisterEnum("cosmos.group.v1.VoteOption", VoteOption_name, VoteOption_value) proto.RegisterEnum("cosmos.group.v1.ProposalStatus", ProposalStatus_name, ProposalStatus_value) - proto.RegisterEnum("cosmos.group.v1.ProposalResult", ProposalResult_name, ProposalResult_value) proto.RegisterEnum("cosmos.group.v1.ProposalExecutorResult", ProposalExecutorResult_name, ProposalExecutorResult_value) proto.RegisterType((*Member)(nil), "cosmos.group.v1.Member") proto.RegisterType((*Members)(nil), "cosmos.group.v1.Members") @@ -904,91 +886,89 @@ func init() { func init() { proto.RegisterFile("cosmos/group/v1/types.proto", fileDescriptor_f5bddd15d7a54a9d) } var fileDescriptor_f5bddd15d7a54a9d = []byte{ - // 1340 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x57, 0xcd, 0x6f, 0x1b, 0x45, - 0x14, 0xf7, 0x3a, 0x8e, 0x3f, 0x9e, 0x53, 0xdb, 0x4c, 0x43, 0xb3, 0xf9, 0xc0, 0x0e, 0xa6, 0x82, - 0xa8, 0xa8, 0x76, 0xeb, 0x4a, 0x54, 0xea, 0x01, 0xb0, 0x9d, 0x2d, 0x35, 0x4a, 0x6d, 0xb3, 0xbb, - 0x4e, 0x68, 0x2f, 0xab, 0x8d, 0x77, 0xea, 0xac, 0xb0, 0x77, 0xac, 0xdd, 0x71, 0x52, 0xff, 0x07, - 0xbd, 0x20, 0x7a, 0xe0, 0xc0, 0x05, 0xa9, 0x12, 0x77, 0x24, 0xa4, 0x1e, 0x10, 0x7f, 0x41, 0xc5, - 0xa9, 0xe2, 0xc4, 0x09, 0xaa, 0xf6, 0x52, 0x4e, 0xfc, 0x0b, 0x68, 0x67, 0x66, 0x1d, 0x7f, 0xc5, - 0xb4, 0x15, 0x9c, 0xe2, 0x79, 0xef, 0xf7, 0xde, 0xfc, 0xde, 0xe7, 0x64, 0x61, 0xb3, 0x4d, 0xbc, - 0x1e, 0xf1, 0x8a, 0x1d, 0x97, 0x0c, 0xfa, 0xc5, 0xe3, 0xab, 0x45, 0x3a, 0xec, 0x63, 0xaf, 0xd0, - 0x77, 0x09, 0x25, 0x28, 0xcd, 0x95, 0x05, 0xa6, 0x2c, 0x1c, 0x5f, 0xdd, 0x58, 0xed, 0x90, 0x0e, - 0x61, 0xba, 0xa2, 0xff, 0x8b, 0xc3, 0x36, 0xb2, 0x1d, 0x42, 0x3a, 0x5d, 0x5c, 0x64, 0xa7, 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xb4, 0x10, 0xa5, 0xb5, 0xaa, 0x55, 0x45, 0xd3, 0x32, 0xe1, 0x85, 0xa8, 0x9b, - 0xe5, 0xda, 0x5e, 0x4b, 0x55, 0x02, 0xf2, 0x95, 0x8f, 0x9f, 0x3c, 0xcf, 0x4a, 0x4f, 0x9f, 0x67, - 0xa5, 0x67, 0xcf, 0xb3, 0xd2, 0xc3, 0x17, 0xd9, 0xd0, 0xd3, 0x17, 0xd9, 0xd0, 0xef, 0x2f, 0xb2, - 0xa1, 0xbb, 0x17, 0x3b, 0x36, 0x3d, 0x1a, 0x1c, 0x16, 0xda, 0xa4, 0x27, 0xbe, 0x70, 0xc4, 0x9f, - 0xcb, 0x9e, 0xf5, 0x55, 0xf1, 0x3e, 0xff, 0x00, 0x3b, 0x8c, 0xb2, 0x01, 0xb8, 0xf6, 0x4f, 0x00, - 0x00, 0x00, 0xff, 0xff, 0x1f, 0xf6, 0x78, 0x70, 0x97, 0x0d, 0x00, 0x00, + // 1306 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x57, 0x4d, 0x6f, 0x1b, 0xc5, + 0x1b, 0xf7, 0xda, 0x8e, 0x5f, 0x1e, 0xa7, 0xb6, 0xff, 0xd3, 0xfc, 0x9b, 0x4d, 0x52, 0xec, 0x60, + 0x2a, 0x88, 0x8a, 0x6a, 0xb7, 0xae, 0x44, 0xa5, 0x1e, 0x00, 0xdb, 0xd9, 0x52, 0x57, 0xad, 0x6d, + 0x76, 0xd7, 0x09, 0xe5, 0xb2, 0xda, 0x78, 0xa7, 0x9b, 0x15, 0xf6, 0x8e, 0xb5, 0x3b, 0x4e, 0xea, + 0x6f, 0xd0, 0x0b, 0xa2, 0x47, 0x2e, 0x48, 0x95, 0xf8, 0x04, 0x48, 0x3d, 0x20, 0x2e, 0x5c, 0x2b, + 0x0e, 0xa8, 0xe2, 0xc4, 0x09, 0x50, 0x7b, 0x29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x41, 0x15, 0x97, 0xb9, 0x66, 0x87, 0x29, 0xa2, 0x2e, 0xac, 0x0c, 0x1c, + 0xd7, 0xc0, 0x0f, 0x71, 0x6f, 0x14, 0x10, 0x43, 0x83, 0xd1, 0xd7, 0x37, 0x88, 0x06, 0x8e, 0xab, + 0x84, 0xfa, 0xdc, 0x6c, 0xe9, 0x4f, 0x09, 0xd2, 0x9f, 0x04, 0xa1, 0x37, 0xdd, 0x07, 0x04, 0x65, + 0x21, 0xea, 0x70, 0x1f, 0xe3, 0x6a, 0xd4, 0xb1, 0x50, 0x19, 0x96, 0x4c, 0x6b, 0xe0, 0xb8, 0xbc, + 0x67, 0x17, 0xb4, 0x39, 0xa7, 0x2d, 0x6c, 0x66, 0x19, 0x92, 0x07, 0xd8, 0x0b, 0x52, 0xc4, 0x7a, + 0x39, 0xae, 0x86, 0x47, 0xf4, 0x36, 0x2c, 0x53, 0x42, 0xcd, 0xbe, 0x21, 0x06, 0x64, 0x89, 0x69, + 0x66, 0x98, 0x6c, 0x97, 0x4f, 0x49, 0x03, 0xa0, 0xe7, 0x61, 0x93, 0xf2, 0x59, 0x48, 0x9c, 0x61, + 0x16, 0xd2, 0x42, 0xaf, 0x46, 0x4b, 0xf7, 0x21, 0xc3, 0x42, 0x15, 0x53, 0xbc, 0x06, 0x29, 0x56, + 0x74, 0xe3, 0x28, 0xe4, 0x24, 0x3b, 0x37, 0x2d, 0x54, 0x81, 0x04, 0x6f, 0x7f, 0x91, 0xde, 0xd3, + 0x66, 0x45, 0x15, 0xb4, 0xd2, 0xab, 0x28, 0xe4, 0x98, 0x6d, 0x5e, 0x7e, 0x96, 0xcc, 0x37, 0xd9, + 0x12, 0x93, 0x3e, 0x45, 0xa7, 0x7d, 0x3a, 0xaa, 0x45, 0xec, 0xec, 0xb5, 0x88, 0x9f, 0x5e, 0x8b, + 0xa5, 0xe9, 0x5a, 0x7c, 0x0a, 0x39, 0x4b, 0x74, 0xb2, 0x31, 0x64, 0xb1, 0x88, 0x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83, 0x04, 0x17, 0x4e, 0x9e, 0x2b, + 0xb4, 0x05, 0x97, 0x8e, 0xf4, 0x95, 0xcf, 0x94, 0x46, 0x57, 0x6f, 0xab, 0x86, 0xaa, 0x68, 0xdd, + 0xbb, 0xfa, 0x4c, 0x84, 0x97, 0x60, 0xf3, 0x54, 0x66, 0xab, 0xad, 0x1b, 0x6a, 0xb7, 0x95, 0x97, + 0x16, 0xb2, 0xb4, 0x6e, 0xa3, 0xa1, 0x68, 0x5a, 0x3e, 0xba, 0x90, 0x75, 0xab, 0xd6, 0xbc, 0xdb, + 0x55, 0x95, 0x7c, 0x8c, 0x3b, 0x5f, 0xff, 0xf0, 0xd9, 0x8b, 0x82, 0xf4, 0xfc, 0x45, 0x41, 0xfa, + 0xe3, 0x45, 0x41, 0x7a, 0xfc, 0xb2, 0x10, 0x79, 0xfe, 0xb2, 0x10, 0xf9, 0xf5, 0x65, 0x21, 0xf2, + 0xf9, 0x25, 0xdb, 0xa1, 0xfb, 0xa3, 0xbd, 0x72, 0x8f, 0x0c, 0xc4, 0x97, 0x84, 0xf8, 0x73, 0xc5, + 0xb7, 0xbe, 0xa8, 0x3c, 0xe4, 0x1f, 0x3a, 0x7b, 0x09, 0xd6, 0x89, 0xd7, 0xff, 0x0e, 0x00, 0x00, + 0xff, 0xff, 0x5b, 0x5c, 0x1c, 0x07, 0xff, 0x0c, 0x00, 0x00, } func (this *GroupPolicyInfo) Equal(that interface{}) bool { @@ -1452,13 +1432,13 @@ func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x6a + dAtA[i] = 0x62 } } if m.ExecutorResult != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.ExecutorResult)) i-- - dAtA[i] = 0x60 + dAtA[i] = 0x58 } n10, err10 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.VotingPeriodEnd, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.VotingPeriodEnd):]) if err10 != nil { @@ -1467,7 +1447,7 @@ func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { i -= n10 i = encodeVarintTypes(dAtA, i, uint64(n10)) i-- - dAtA[i] = 0x5a + dAtA[i] = 0x52 { size, err := m.FinalTallyResult.MarshalToSizedBuffer(dAtA[:i]) if err != nil { @@ -1477,12 +1457,7 @@ func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x52 - if m.Result != 0 { - i = encodeVarintTypes(dAtA, i, uint64(m.Result)) - i-- - dAtA[i] = 0x48 - } + dAtA[i] = 0x4a if m.Status != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Status)) i-- @@ -1522,10 +1497,10 @@ func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x1a } - if len(m.Address) > 0 { - i -= len(m.Address) - copy(dAtA[i:], m.Address) - i = encodeVarintTypes(dAtA, i, uint64(len(m.Address))) + if len(m.GroupPolicyAddress) > 0 { + i -= len(m.GroupPolicyAddress) + copy(dAtA[i:], m.GroupPolicyAddress) + i = encodeVarintTypes(dAtA, i, uint64(len(m.GroupPolicyAddress))) i-- dAtA[i] = 0x12 } @@ -1826,7 +1801,7 @@ func (m *Proposal) Size() (n int) { if m.Id != 0 { n += 1 + sovTypes(uint64(m.Id)) } - l = len(m.Address) + l = len(m.GroupPolicyAddress) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } @@ -1851,9 +1826,6 @@ func (m *Proposal) Size() (n int) { if m.Status != 0 { n += 1 + sovTypes(uint64(m.Status)) } - if m.Result != 0 { - n += 1 + sovTypes(uint64(m.Result)) - } l = m.FinalTallyResult.Size() n += 1 + l + sovTypes(uint64(l)) l = github_com_gogo_protobuf_types.SizeOfStdTime(m.VotingPeriodEnd) @@ -3166,7 +3138,7 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { } case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field GroupPolicyAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -3194,7 +3166,7 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(dAtA[iNdEx:postIndex]) + m.GroupPolicyAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -3351,25 +3323,6 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { } } case 9: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) - } - m.Result = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTypes - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Result |= ProposalResult(b&0x7F) << shift - if b < 0x80 { - break - } - } - case 10: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field FinalTallyResult", wireType) } @@ -3402,7 +3355,7 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 11: + case 10: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field VotingPeriodEnd", wireType) } @@ -3435,7 +3388,7 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 12: + case 11: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field ExecutorResult", wireType) } @@ -3454,7 +3407,7 @@ func (m *Proposal) Unmarshal(dAtA []byte) error { break } } - case 13: + case 12: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Messages", wireType) }