diff --git a/api/layer/dispute/module/module.pulsar.go b/api/layer/dispute/module/module.pulsar.go index 4f48bce33..36a6cbfce 100644 --- a/api/layer/dispute/module/module.pulsar.go +++ b/api/layer/dispute/module/module.pulsar.go @@ -4,6 +4,7 @@ package module import ( _ "cosmossdk.io/api/cosmos/app/v1alpha1" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" runtime "github.com/cosmos/cosmos-proto/runtime" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoiface "google.golang.org/protobuf/runtime/protoiface" @@ -14,12 +15,14 @@ import ( ) var ( - md_Module protoreflect.MessageDescriptor + md_Module protoreflect.MessageDescriptor + fd_Module_team_address protoreflect.FieldDescriptor ) func init() { file_layer_dispute_module_module_proto_init() md_Module = File_layer_dispute_module_module_proto.Messages().ByName("Module") + fd_Module_team_address = md_Module.Fields().ByName("team_address") } var _ protoreflect.Message = (*fastReflection_Module)(nil) @@ -87,6 +90,12 @@ func (x *fastReflection_Module) Interface() protoreflect.ProtoMessage { // While iterating, mutating operations may only be performed // on the current field descriptor. func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { + if x.TeamAddress != "" { + value := protoreflect.ValueOfString(x.TeamAddress) + if !f(fd_Module_team_address, value) { + return + } + } } // Has reports whether a field is populated. @@ -102,6 +111,8 @@ func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, proto // a repeated field is populated if it is non-empty. func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { + case "layer.dispute.module.Module.team_address": + return x.TeamAddress != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -118,6 +129,8 @@ func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { // Clear is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { + case "layer.dispute.module.Module.team_address": + x.TeamAddress = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -134,6 +147,9 @@ func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { // of the value; to obtain a mutable reference, use Mutable. func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { + case "layer.dispute.module.Module.team_address": + value := x.TeamAddress + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -154,6 +170,8 @@ func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) pro // Set is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { + case "layer.dispute.module.Module.team_address": + x.TeamAddress = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -174,6 +192,8 @@ func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value proto // Mutable is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { + case "layer.dispute.module.Module.team_address": + panic(fmt.Errorf("field team_address of message layer.dispute.module.Module is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -187,6 +207,8 @@ func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protore // For lists, maps, and messages, this returns a new, empty, mutable value. func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { + case "layer.dispute.module.Module.team_address": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.module.Module")) @@ -256,6 +278,10 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { var n int var l int _ = l + l = len(x.TeamAddress) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -285,6 +311,13 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.TeamAddress) > 0 { + i -= len(x.TeamAddress) + copy(dAtA[i:], x.TeamAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TeamAddress))) + i-- + dAtA[i] = 0xa + } if input.Buf != nil { input.Buf = append(input.Buf, dAtA...) } else { @@ -334,6 +367,38 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: Module: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TeamAddress", wireType) + } + var stringLen uint64 + 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++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.TeamAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -387,6 +452,9 @@ type Module struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields + + // authority defines the custom module authority. If not set, defaults to the governance module. + TeamAddress string `protobuf:"bytes,1,opt,name=team_address,json=teamAddress,proto3" json:"team_address,omitempty"` } func (x *Module) Reset() { @@ -409,6 +477,13 @@ func (*Module) Descriptor() ([]byte, []int) { return file_layer_dispute_module_module_proto_rawDescGZIP(), []int{0} } +func (x *Module) GetTeamAddress() string { + if x != nil { + return x.TeamAddress + } + return "" +} + var File_layer_dispute_module_module_proto protoreflect.FileDescriptor var file_layer_dispute_module_module_proto_rawDesc = []byte{ @@ -417,24 +492,30 @@ var file_layer_dispute_module_module_proto_rawDesc = []byte{ 0x6f, 0x74, 0x6f, 0x12, 0x14, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, - 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x36, 0x0a, 0x06, 0x4d, - 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x3a, 0x2c, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x26, 0x0a, 0x24, 0x67, - 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, 0x6f, 0x72, - 0x2d, 0x69, 0x6f, 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x78, 0x2f, 0x64, 0x69, 0x73, 0x70, - 0x75, 0x74, 0x65, 0x42, 0xce, 0x01, 0x0a, 0x18, 0x63, 0x6f, 0x6d, 0x2e, 0x6c, 0x61, 0x79, 0x65, - 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, - 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, - 0x33, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, - 0x6f, 0x72, 0x2d, 0x69, 0x6f, 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, - 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x2f, 0x6d, 0x6f, - 0x64, 0x75, 0x6c, 0x65, 0xa2, 0x02, 0x03, 0x4c, 0x44, 0x4d, 0xaa, 0x02, 0x14, 0x4c, 0x61, 0x79, - 0x65, 0x72, 0x2e, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, - 0x65, 0xca, 0x02, 0x14, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, - 0x65, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0xe2, 0x02, 0x20, 0x4c, 0x61, 0x79, 0x65, 0x72, - 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, - 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x16, 0x4c, 0x61, - 0x79, 0x65, 0x72, 0x3a, 0x3a, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x3a, 0x3a, 0x4d, 0x6f, - 0x64, 0x75, 0x6c, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x73, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, + 0x12, 0x3b, 0x0a, 0x0c, 0x74, 0x65, 0x61, 0x6d, 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, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x3a, 0x2c, 0xba, + 0xc0, 0x96, 0xda, 0x01, 0x26, 0x0a, 0x24, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, + 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, 0x6f, 0x72, 0x2d, 0x69, 0x6f, 0x2f, 0x6c, 0x61, 0x79, 0x65, + 0x72, 0x2f, 0x78, 0x2f, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x42, 0xce, 0x01, 0x0a, 0x18, + 0x63, 0x6f, 0x6d, 0x2e, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, + 0x65, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, + 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x33, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, + 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, 0x6f, 0x72, 0x2d, 0x69, 0x6f, 0x2f, 0x6c, 0x61, + 0x79, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x64, 0x69, + 0x73, 0x70, 0x75, 0x74, 0x65, 0x2f, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0xa2, 0x02, 0x03, 0x4c, + 0x44, 0x4d, 0xaa, 0x02, 0x14, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x44, 0x69, 0x73, 0x70, 0x75, + 0x74, 0x65, 0x2e, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0xca, 0x02, 0x14, 0x4c, 0x61, 0x79, 0x65, + 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, + 0xe2, 0x02, 0x20, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, + 0x5c, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0xea, 0x02, 0x16, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x3a, 0x3a, 0x44, 0x69, 0x73, + 0x70, 0x75, 0x74, 0x65, 0x3a, 0x3a, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/layer/dispute/params.pulsar.go b/api/layer/dispute/params.pulsar.go index cc177f154..71d0fa107 100644 --- a/api/layer/dispute/params.pulsar.go +++ b/api/layer/dispute/params.pulsar.go @@ -3,6 +3,7 @@ package dispute import ( fmt "fmt" + _ "github.com/cosmos/cosmos-proto" runtime "github.com/cosmos/cosmos-proto/runtime" _ "github.com/cosmos/gogoproto/gogoproto" protoreflect "google.golang.org/protobuf/reflect/protoreflect" @@ -14,14 +15,14 @@ import ( ) var ( - md_Params protoreflect.MessageDescriptor - fd_Params_team protoreflect.FieldDescriptor + md_Params protoreflect.MessageDescriptor + fd_Params_team_address protoreflect.FieldDescriptor ) func init() { file_layer_dispute_params_proto_init() md_Params = File_layer_dispute_params_proto.Messages().ByName("Params") - fd_Params_team = md_Params.Fields().ByName("team") + fd_Params_team_address = md_Params.Fields().ByName("team_address") } var _ protoreflect.Message = (*fastReflection_Params)(nil) @@ -89,9 +90,9 @@ func (x *fastReflection_Params) Interface() protoreflect.ProtoMessage { // While iterating, mutating operations may only be performed // on the current field descriptor. func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Team != "" { - value := protoreflect.ValueOfString(x.Team) - if !f(fd_Params_team, value) { + if x.TeamAddress != "" { + value := protoreflect.ValueOfString(x.TeamAddress) + if !f(fd_Params_team_address, value) { return } } @@ -110,8 +111,8 @@ func (x *fastReflection_Params) Range(f func(protoreflect.FieldDescriptor, proto // a repeated field is populated if it is non-empty. func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "layer.dispute.Params.team": - return x.Team != "" + case "layer.dispute.Params.team_address": + return x.TeamAddress != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.Params")) @@ -128,8 +129,8 @@ func (x *fastReflection_Params) Has(fd protoreflect.FieldDescriptor) bool { // Clear is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "layer.dispute.Params.team": - x.Team = "" + case "layer.dispute.Params.team_address": + x.TeamAddress = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.Params")) @@ -146,8 +147,8 @@ func (x *fastReflection_Params) Clear(fd protoreflect.FieldDescriptor) { // of the value; to obtain a mutable reference, use Mutable. func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "layer.dispute.Params.team": - value := x.Team + case "layer.dispute.Params.team_address": + value := x.TeamAddress return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { @@ -169,8 +170,8 @@ func (x *fastReflection_Params) Get(descriptor protoreflect.FieldDescriptor) pro // Set is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "layer.dispute.Params.team": - x.Team = value.Interface().(string) + case "layer.dispute.Params.team_address": + x.TeamAddress = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.Params")) @@ -191,8 +192,8 @@ func (x *fastReflection_Params) Set(fd protoreflect.FieldDescriptor, value proto // Mutable is a mutating operation and unsafe for concurrent use. func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "layer.dispute.Params.team": - panic(fmt.Errorf("field team of message layer.dispute.Params is not mutable")) + case "layer.dispute.Params.team_address": + panic(fmt.Errorf("field team_address of message layer.dispute.Params is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: layer.dispute.Params")) @@ -206,7 +207,7 @@ func (x *fastReflection_Params) Mutable(fd protoreflect.FieldDescriptor) protore // For lists, maps, and messages, this returns a new, empty, mutable value. func (x *fastReflection_Params) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "layer.dispute.Params.team": + case "layer.dispute.Params.team_address": return protoreflect.ValueOfString("") default: if fd.IsExtension() { @@ -277,7 +278,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { var n int var l int _ = l - l = len(x.Team) + l = len(x.TeamAddress) if l > 0 { n += 1 + l + runtime.Sov(uint64(l)) } @@ -310,10 +311,10 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Team) > 0 { - i -= len(x.Team) - copy(dAtA[i:], x.Team) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Team))) + if len(x.TeamAddress) > 0 { + i -= len(x.TeamAddress) + copy(dAtA[i:], x.TeamAddress) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.TeamAddress))) i-- dAtA[i] = 0xa } @@ -368,7 +369,7 @@ func (x *fastReflection_Params) 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 Team", wireType) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field TeamAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -396,7 +397,7 @@ func (x *fastReflection_Params) ProtoMethods() *protoiface.Methods { if postIndex > l { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } - x.Team = string(dAtA[iNdEx:postIndex]) + x.TeamAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex @@ -452,7 +453,7 @@ type Params struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Team string `protobuf:"bytes,1,opt,name=team,proto3" json:"team,omitempty"` + TeamAddress string `protobuf:"bytes,1,opt,name=team_address,json=teamAddress,proto3" json:"team_address,omitempty"` } func (x *Params) Reset() { @@ -475,9 +476,9 @@ func (*Params) Descriptor() ([]byte, []int) { return file_layer_dispute_params_proto_rawDescGZIP(), []int{0} } -func (x *Params) GetTeam() string { +func (x *Params) GetTeamAddress() string { if x != nil { - return x.Team + return x.TeamAddress } return "" } @@ -487,22 +488,26 @@ var File_layer_dispute_params_proto protoreflect.FileDescriptor var file_layer_dispute_params_proto_rawDesc = []byte{ 0x0a, 0x1a, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0d, 0x6c, 0x61, - 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x1a, 0x14, 0x67, 0x6f, 0x67, - 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x22, 0x22, 0x0a, 0x06, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x74, - 0x65, 0x61, 0x6d, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x3a, - 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xa3, 0x01, 0x0a, 0x11, 0x63, 0x6f, 0x6d, 0x2e, 0x6c, 0x61, - 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x42, 0x0b, 0x50, 0x61, 0x72, - 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, 0x6f, 0x72, 0x2d, 0x69, 0x6f, - 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, - 0x2f, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0xa2, 0x02, 0x03, 0x4c, 0x44, 0x58, 0xaa, 0x02, - 0x0d, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0xca, 0x02, - 0x0d, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0xe2, 0x02, - 0x19, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x5c, 0x47, - 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0e, 0x4c, 0x61, 0x79, - 0x65, 0x72, 0x3a, 0x3a, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x1a, 0x19, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x4b, 0x0a, 0x06, + 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x3b, 0x0a, 0x0c, 0x74, 0x65, 0x61, 0x6d, 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, 0x0b, 0x74, 0x65, 0x61, 0x6d, 0x41, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x3a, 0x04, 0x98, 0xa0, 0x1f, 0x00, 0x42, 0xa3, 0x01, 0x0a, 0x11, 0x63, 0x6f, + 0x6d, 0x2e, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x42, + 0x0b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, + 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x74, 0x65, 0x6c, 0x6c, 0x6f, + 0x72, 0x2d, 0x69, 0x6f, 0x2f, 0x6c, 0x61, 0x79, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x6c, + 0x61, 0x79, 0x65, 0x72, 0x2f, 0x64, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0xa2, 0x02, 0x03, 0x4c, + 0x44, 0x58, 0xaa, 0x02, 0x0d, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x2e, 0x44, 0x69, 0x73, 0x70, 0x75, + 0x74, 0x65, 0xca, 0x02, 0x0d, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, + 0x74, 0x65, 0xe2, 0x02, 0x19, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x5c, 0x44, 0x69, 0x73, 0x70, 0x75, + 0x74, 0x65, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x0e, 0x4c, 0x61, 0x79, 0x65, 0x72, 0x3a, 0x3a, 0x44, 0x69, 0x73, 0x70, 0x75, 0x74, 0x65, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/cmd/layerd/cmd/genaccounts.go b/cmd/layerd/cmd/genaccounts.go deleted file mode 100644 index 2d4b524b2..000000000 --- a/cmd/layerd/cmd/genaccounts.go +++ /dev/null @@ -1,134 +0,0 @@ -package cmd - -import ( - "bufio" - "encoding/json" - "fmt" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - "github.com/cosmos/cosmos-sdk/server" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/cosmos/cosmos-sdk/x/genutil" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - "github.com/spf13/cobra" - disputetypes "github.com/tellor-io/layer/x/dispute/types" -) - -// AddGenesisAccountCmd returns add-genesis-account cobra Command. -func AddTeamAccountCmd(defaultNodeHome string) *cobra.Command { - cmd := &cobra.Command{ - Use: "add-team-account [address_or_key_name]", - Short: "Add a team account to genesis.json,", - Long: `Add a team account to genesis.json. -`, - Args: cobra.ExactArgs(1), - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx := client.GetClientContextFromCmd(cmd) - cdc := clientCtx.Codec - - serverCtx := server.GetServerContextFromCmd(cmd) - config := serverCtx.Config - - config.SetRoot(clientCtx.HomeDir) - - addr, err := sdk.AccAddressFromBech32(args[0]) - if err != nil { - inBuf := bufio.NewReader(cmd.InOrStdin()) - keyringBackend, err := cmd.Flags().GetString(flags.FlagKeyringBackend) - if err != nil { - return err - } - - // attempt to lookup address from Keybase if no address was provided - kb, err := keyring.New(sdk.KeyringServiceName(), keyringBackend, clientCtx.HomeDir, inBuf, cdc) - if err != nil { - return err - } - - info, err := kb.Key(args[0]) - if err != nil { - return fmt.Errorf("failed to get address from Keybase: %w", err) - } - - addr, err = info.GetAddress() - if err != nil { - return fmt.Errorf("failed to get address from Keybase: %w", err) - } - } - - // create concrete account type based on input parameters - var genAccount authtypes.GenesisAccount - - baseAccount := authtypes.NewBaseAccount(addr, nil, 0, 0) - - genAccount = baseAccount - - if err := genAccount.Validate(); err != nil { - return fmt.Errorf("failed to validate new genesis account: %w", err) - } - - genFile := config.GenesisFile() - appState, genDoc, err := genutiltypes.GenesisStateFromGenFile(genFile) - if err != nil { - return fmt.Errorf("failed to unmarshal genesis state: %w", err) - } - - authGenState := authtypes.GetGenesisStateFromAppState(cdc, appState) - - accs, err := authtypes.UnpackAccounts(authGenState.Accounts) - if err != nil { - return fmt.Errorf("failed to get accounts from any: %w", err) - } - - if accs.Contains(addr) { - return fmt.Errorf("cannot add account at existing address %s", addr) - } - - // Add the new account to the set of genesis accounts and sanitize the - // accounts afterwards. - accs = append(accs, genAccount) - accs = authtypes.SanitizeGenesisAccounts(accs) - - genAccs, err := authtypes.PackAccounts(accs) - if err != nil { - return fmt.Errorf("failed to convert accounts into any's: %w", err) - } - - authGenState.Accounts = genAccs - - authGenStateBz, err := cdc.MarshalJSON(&authGenState) - if err != nil { - return fmt.Errorf("failed to marshal auth genesis state: %w", err) - } - - appState[authtypes.ModuleName] = authGenStateBz - - disputeGenState := disputetypes.GetGenesisStateFromAppState(cdc, appState) - disputeGenState.Params.Team = genAccount.GetAddress().String() - - disputeGenStateBz, err := cdc.MarshalJSON(disputeGenState) - if err != nil { - return fmt.Errorf("failed to marshal bank genesis state: %w", err) - } - - appState[disputetypes.ModuleName] = disputeGenStateBz - - appStateJSON, err := json.Marshal(appState) - if err != nil { - return fmt.Errorf("failed to marshal application genesis state: %w", err) - } - - genDoc.AppState = appStateJSON - return genutil.ExportGenesisFile(genDoc, genFile) - }, - } - - cmd.Flags().String(flags.FlagKeyringBackend, flags.DefaultKeyringBackend, "Select keyring's backend (os|file|kwallet|pass|test)") - cmd.Flags().String(flags.FlagHome, defaultNodeHome, "The application home directory") - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} diff --git a/cmd/layerd/cmd/root.go b/cmd/layerd/cmd/root.go index d95695913..5d3166925 100644 --- a/cmd/layerd/cmd/root.go +++ b/cmd/layerd/cmd/root.go @@ -147,10 +147,11 @@ func initRootCmd( // genesisCommand builds genesis-related `simd genesis` command. Users may provide application specific commands as a parameter func genesisCommand(txConfig client.TxConfig, basicManager module.BasicManager, cmds ...*cobra.Command) *cobra.Command { cmd := genutilcli.Commands(txConfig, basicManager, app.DefaultNodeHome) - cmd.AddCommand(AddTeamAccountCmd(app.DefaultNodeHome)) + for _, subCmd := range cmds { cmd.AddCommand(subCmd) } + cmd.AddCommand(AddTeamAccountCmd(app.DefaultNodeHome)) return cmd } diff --git a/proto/layer/dispute/module/module.proto b/proto/layer/dispute/module/module.proto new file mode 100644 index 000000000..3b97eb1ee --- /dev/null +++ b/proto/layer/dispute/module/module.proto @@ -0,0 +1,13 @@ +syntax = "proto3"; +package layer.dispute.module; + +import "cosmos/app/v1alpha1/module.proto"; +import "cosmos_proto/cosmos.proto"; + +// Module is the config object for the module. +message Module { + option (cosmos.app.v1alpha1.module) = {go_import: "github.com/tellor-io/layer/x/dispute"}; + + // authority defines the custom module authority. If not set, defaults to the governance module. + string team_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; +} diff --git a/proto/layer/dispute/params.proto b/proto/layer/dispute/params.proto index d19c70847..a88b97af0 100644 --- a/proto/layer/dispute/params.proto +++ b/proto/layer/dispute/params.proto @@ -1,6 +1,7 @@ syntax = "proto3"; package layer.dispute; +import "cosmos_proto/cosmos.proto"; import "gogoproto/gogo.proto"; option go_package = "github.com/tellor-io/layer/x/dispute/types"; @@ -8,5 +9,5 @@ option go_package = "github.com/tellor-io/layer/x/dispute/types"; // Params defines the parameters for the module. message Params { option (gogoproto.goproto_stringer) = false; - string team = 1; + string team_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; } diff --git a/start_scripts/start_test_node.sh b/start_scripts/start_test_node.sh new file mode 100755 index 000000000..98874d5db --- /dev/null +++ b/start_scripts/start_test_node.sh @@ -0,0 +1,62 @@ +#!/bin/bash + +# clear the terminal +clear + +# Stop execution if any command fails +set -e + +KEYRING_BACKEND="test" +PASSWORD="password" + +export LAYERD_NODE_HOME="$HOME/.layer/alice" + +# Remove old test chain data (if present) +echo "Removing old test chain data..." +rm -rf ~/.layer + +# Build layerd +echo "Building layerd..." +go build ./cmd/layerd + +# Initialize chain node with the folder for alice +echo "Initializing chain node for alice..." +./layerd init alicemoniker --chain-id layer --home ~/.layer/alice + +# Add a validator account for alice +echo "Adding validator account for alice..." +./layerd keys add alice --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice +./layerd keys add bill --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice +./layerd keys add team --multisig alice,bill --multisig-threshold 2 --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice + +# Update vote_extensions_enable_height in genesis.json for alice +echo "Updating vote_extensions_enable_height in genesis.json for alice..." +jq '.consensus.params.abci.vote_extensions_enable_height = "1"' ~/.layer/alice/config/genesis.json > temp.json && mv temp.json ~/.layer/alice/config/genesis.json + +# Create a tx to give alice loyas to stake +echo "Adding genesis account for alice..." +./layerd genesis add-genesis-account $(./layerd keys show alice -a --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice) 10000000000000loya --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice +echo "Adding team multisig account to dispute params..." +./layerd genesis add-team-account $(./layerd keys show team -a --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice) --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice +# Create a tx to stake some loyas for alice +echo "Creating gentx for alice..." +./layerd genesis gentx alice 1000000000000loya --chain-id layer --keyring-backend $KEYRING_BACKEND --home ~/.layer/alice --keyring-dir ~/.layer/alice + +# Add the transactions to the genesis block +echo "Collecting gentxs..." +./layerd genesis collect-gentxs --home ~/.layer/alice + +# Modify timeout_commit in config.toml for alice +echo "Modifying timeout_commit in config.toml for alice..." +sed -i '' 's/timeout_commit = "5s"/timeout_commit = "500ms"/' ~/.layer/alice/config/config.toml + + +# Modify keyring-backend in client.toml for alice +echo "Modifying keyring-backend in client.toml for alice..." +sed -i '' 's/keyring-backend = "os"/keyring-backend = "test"/' ~/.layer/alice/config/client.toml +# update for main dir as well. why is this needed? +sed -i '' 's/keyring-backend = "os"/keyring-backend = "test"/' ~/.layer/config/client.toml + + +echo "Starting chain for alice..." +./layerd start --home ~/.layer/alice --api.enable --api.swagger \ No newline at end of file diff --git a/x/dispute/keeper/msg_update_team.go b/x/dispute/keeper/msg_update_team.go index 6ee018089..5d23ada07 100644 --- a/x/dispute/keeper/msg_update_team.go +++ b/x/dispute/keeper/msg_update_team.go @@ -12,10 +12,10 @@ func (k msgServer) UpdateTeam(ctx context.Context, msg *types.MsgUpdateTeam) (*t if err != nil { return nil, err } - if param.Team != msg.CurrentTeamAddress { - return nil, errorsmod.Wrapf(types.ErrInvalidSigner, "invalid team address; expected %s, got %s", param.Team, msg.CurrentTeamAddress) + if param.TeamAddress != msg.CurrentTeamAddress { + return nil, errorsmod.Wrapf(types.ErrInvalidSigner, "invalid team address; expected %s, got %s", param.TeamAddress, msg.CurrentTeamAddress) } - param.Team = msg.NewTeamAddress + param.TeamAddress = msg.NewTeamAddress if err := k.Params.Set(ctx, param); err != nil { return nil, err } diff --git a/x/dispute/keeper/tally.go b/x/dispute/keeper/tally.go index 80fb3d481..5f700c745 100644 --- a/x/dispute/keeper/tally.go +++ b/x/dispute/keeper/tally.go @@ -314,7 +314,7 @@ func (k Keeper) IsTeamAddress(ctx context.Context, voter sdk.AccAddress) math.In panic(err) } - if !bytes.Equal(voter, sdk.MustAccAddressFromBech32(params.Team)) { + if !bytes.Equal(voter, sdk.MustAccAddressFromBech32(params.TeamAddress)) { return math.ZeroInt() } return math.NewInt(1) diff --git a/x/dispute/module.go b/x/dispute/module.go index 0a3e1d672..3b1607dfc 100644 --- a/x/dispute/module.go +++ b/x/dispute/module.go @@ -185,6 +185,7 @@ type DisputeOutputs struct { } func ProvideModule(in DisputeInputs) DisputeOutputs { + k := keeper.NewKeeper( in.Cdc, in.StoreService, @@ -193,6 +194,7 @@ func ProvideModule(in DisputeInputs) DisputeOutputs { in.OracleKeeper, in.ReporterKeeper, ) + m := NewAppModule( in.Cdc, k, diff --git a/x/dispute/types/params.go b/x/dispute/types/params.go index 0b3ae3487..c91f005dd 100644 --- a/x/dispute/types/params.go +++ b/x/dispute/types/params.go @@ -26,7 +26,7 @@ func NewParams( team string, ) Params { return Params{ - Team: team, + TeamAddress: team, } } @@ -40,13 +40,13 @@ func DefaultParams() Params { // ParamSetPairs get the params.ParamSet func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(KeyTeamAddress, &p.Team, validateTeamAddress), + paramtypes.NewParamSetPair(KeyTeamAddress, &p.TeamAddress, validateTeamAddress), } } // Validate validates the set of params func (p Params) Validate() error { - if err := validateTeamAddress(p.Team); err != nil { + if err := validateTeamAddress(p.TeamAddress); err != nil { return err } diff --git a/x/dispute/types/params.pb.go b/x/dispute/types/params.pb.go index 3e0dece58..795eaaf4b 100644 --- a/x/dispute/types/params.pb.go +++ b/x/dispute/types/params.pb.go @@ -5,6 +5,7 @@ package types import ( fmt "fmt" + _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -25,7 +26,7 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Params defines the parameters for the module. type Params struct { - Team string `protobuf:"bytes,1,opt,name=team,proto3" json:"team,omitempty"` + TeamAddress string `protobuf:"bytes,1,opt,name=team_address,json=teamAddress,proto3" json:"team_address,omitempty"` } func (m *Params) Reset() { *m = Params{} } @@ -60,9 +61,9 @@ func (m *Params) XXX_DiscardUnknown() { var xxx_messageInfo_Params proto.InternalMessageInfo -func (m *Params) GetTeam() string { +func (m *Params) GetTeamAddress() string { if m != nil { - return m.Team + return m.TeamAddress } return "" } @@ -74,18 +75,21 @@ func init() { func init() { proto.RegisterFile("layer/dispute/params.proto", fileDescriptor_390f710f1a5ca025) } var fileDescriptor_390f710f1a5ca025 = []byte{ - // 168 bytes of a gzipped FileDescriptorProto + // 211 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xca, 0x49, 0xac, 0x4c, 0x2d, 0xd2, 0x4f, 0xc9, 0x2c, 0x2e, 0x28, 0x2d, 0x49, 0xd5, 0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, - 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x05, 0xcb, 0xe9, 0x41, 0xe5, 0xa4, 0x44, 0xd2, - 0xf3, 0xd3, 0xf3, 0xc1, 0x32, 0xfa, 0x20, 0x16, 0x44, 0x91, 0x92, 0x12, 0x17, 0x5b, 0x00, 0x58, - 0x93, 0x90, 0x10, 0x17, 0x4b, 0x49, 0x6a, 0x62, 0xae, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0x67, 0x10, - 0x98, 0x6d, 0xc5, 0x32, 0x63, 0x81, 0x3c, 0x83, 0x93, 0xcb, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, - 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, - 0x1e, 0xcb, 0x31, 0x44, 0x69, 0xa5, 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, - 0x97, 0xa4, 0xe6, 0xe4, 0xe4, 0x17, 0xe9, 0x66, 0xe6, 0xeb, 0x43, 0xdc, 0x54, 0x01, 0x77, 0x55, - 0x49, 0x65, 0x41, 0x6a, 0x71, 0x12, 0x1b, 0xd8, 0x42, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, - 0xf7, 0x56, 0x7a, 0xc9, 0xb3, 0x00, 0x00, 0x00, + 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x05, 0xcb, 0xe9, 0x41, 0xe5, 0xa4, 0x24, 0x93, + 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0xe3, 0xc1, 0x92, 0xfa, 0x10, 0x0e, 0x44, 0xa5, 0x94, 0x48, 0x7a, + 0x7e, 0x7a, 0x3e, 0x44, 0x1c, 0xc4, 0x82, 0x88, 0x2a, 0x79, 0x73, 0xb1, 0x05, 0x80, 0xcd, 0x13, + 0xb2, 0xe6, 0xe2, 0x29, 0x49, 0x4d, 0xcc, 0x8d, 0x4f, 0x4c, 0x49, 0x29, 0x4a, 0x2d, 0x2e, 0x96, + 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x74, 0x92, 0xb8, 0xb4, 0x45, 0x57, 0x04, 0x6a, 0x8e, 0x23, 0x44, + 0x26, 0xb8, 0xa4, 0x28, 0x33, 0x2f, 0x3d, 0x88, 0x1b, 0xa4, 0x1a, 0x2a, 0x64, 0xc5, 0x32, 0x63, + 0x81, 0x3c, 0x83, 0x93, 0xcb, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, + 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0x69, + 0xa5, 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0x97, 0xa4, 0xe6, 0xe4, 0xe4, + 0x17, 0xe9, 0x66, 0xe6, 0xeb, 0x43, 0xfc, 0x55, 0x01, 0xf7, 0x59, 0x49, 0x65, 0x41, 0x6a, 0x71, + 0x12, 0x1b, 0xd8, 0x65, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x19, 0x3b, 0x4d, 0xa6, 0xf7, + 0x00, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -108,10 +112,10 @@ func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if len(m.Team) > 0 { - i -= len(m.Team) - copy(dAtA[i:], m.Team) - i = encodeVarintParams(dAtA, i, uint64(len(m.Team))) + if len(m.TeamAddress) > 0 { + i -= len(m.TeamAddress) + copy(dAtA[i:], m.TeamAddress) + i = encodeVarintParams(dAtA, i, uint64(len(m.TeamAddress))) i-- dAtA[i] = 0xa } @@ -135,7 +139,7 @@ func (m *Params) Size() (n int) { } var l int _ = l - l = len(m.Team) + l = len(m.TeamAddress) if l > 0 { n += 1 + l + sovParams(uint64(l)) } @@ -179,7 +183,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Team", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TeamAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -207,7 +211,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Team = string(dAtA[iNdEx:postIndex]) + m.TeamAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex