From 945c91574905e9c8ee5325619afc370e8530706c Mon Sep 17 00:00:00 2001 From: Bryan White Date: Mon, 10 Feb 2025 10:51:30 +0100 Subject: [PATCH] chore: review feedback Co-authored-by: Daniel Olshansky --- ...acy.pulsar.go => morse_offchain.pulsar.go} | 590 +++++++++--------- ...ypes.pulsar.go => morse_onchain.pulsar.go} | 189 +++--- cmd/poktrolld/cmd/migrate/migrate.go | 15 +- cmd/poktrolld/cmd/migrate/migrate_test.go | 2 +- cmd/poktrolld/cmd/migrate/types.go | 67 +- .../operate/morse_migration/_category_.json | 8 + .../morse_migration/morse-migration.md | 245 ++++++++ .../docs/operate/networks/_category_.json | 2 +- .../operate/user_guide/create-new-wallet.md | 2 +- docusaurus/yarn.lock | 16 +- .../{legacy.proto => morse_offchain.proto} | 36 +- .../{types.proto => morse_onchain.proto} | 6 +- x/migration/types/morse_account_state.go | 4 +- .../{legacy.pb.go => morse_offchain.pb.go} | 454 +++++++------- .../{types.pb.go => morse_onchain.pb.go} | 180 +++--- 15 files changed, 1081 insertions(+), 735 deletions(-) rename api/poktroll/migration/{legacy.pulsar.go => morse_offchain.pulsar.go} (87%) rename api/poktroll/migration/{types.pulsar.go => morse_onchain.pulsar.go} (88%) create mode 100644 docusaurus/docs/operate/morse_migration/_category_.json create mode 100644 docusaurus/docs/operate/morse_migration/morse-migration.md rename proto/poktroll/migration/{legacy.proto => morse_offchain.proto} (72%) rename proto/poktroll/migration/{types.proto => morse_onchain.proto} (89%) rename x/migration/types/{legacy.pb.go => morse_offchain.pb.go} (75%) rename x/migration/types/{types.pb.go => morse_onchain.pb.go} (73%) diff --git a/api/poktroll/migration/legacy.pulsar.go b/api/poktroll/migration/morse_offchain.pulsar.go similarity index 87% rename from api/poktroll/migration/legacy.pulsar.go rename to api/poktroll/migration/morse_offchain.pulsar.go index 413b53649..f8b459abc 100644 --- a/api/poktroll/migration/legacy.pulsar.go +++ b/api/poktroll/migration/morse_offchain.pulsar.go @@ -20,8 +20,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseStateExport = File_poktroll_migration_legacy_proto.Messages().ByName("MorseStateExport") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseStateExport = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseStateExport") fd_MorseStateExport_app_hash = md_MorseStateExport.Fields().ByName("app_hash") fd_MorseStateExport_app_state = md_MorseStateExport.Fields().ByName("app_state") } @@ -35,7 +35,7 @@ func (x *MorseStateExport) ProtoReflect() protoreflect.Message { } func (x *MorseStateExport) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[0] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -187,7 +187,7 @@ func (x *fastReflection_MorseStateExport) Set(fd protoreflect.FieldDescriptor, v case "poktroll.migration.MorseStateExport.app_hash": x.AppHash = value.Interface().(string) case "poktroll.migration.MorseStateExport.app_state": - x.AppState = value.Message().Interface().(*MorseAppState) + x.AppState = value.Message().Interface().(*MorseTendermintAppState) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseStateExport")) @@ -210,7 +210,7 @@ func (x *fastReflection_MorseStateExport) Mutable(fd protoreflect.FieldDescripto switch fd.FullName() { case "poktroll.migration.MorseStateExport.app_state": if x.AppState == nil { - x.AppState = new(MorseAppState) + x.AppState = new(MorseTendermintAppState) } return protoreflect.ValueOfMessage(x.AppState.ProtoReflect()) case "poktroll.migration.MorseStateExport.app_hash": @@ -231,7 +231,7 @@ func (x *fastReflection_MorseStateExport) NewField(fd protoreflect.FieldDescript case "poktroll.migration.MorseStateExport.app_hash": return protoreflect.ValueOfString("") case "poktroll.migration.MorseStateExport.app_state": - m := new(MorseAppState) + m := new(MorseTendermintAppState) return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { @@ -471,7 +471,7 @@ func (x *fastReflection_MorseStateExport) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF } if x.AppState == nil { - x.AppState = &MorseAppState{} + x.AppState = &MorseTendermintAppState{} } if err := options.Unmarshal(dAtA[iNdEx:postIndex], x.AppState); err != nil { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err @@ -513,30 +513,30 @@ func (x *fastReflection_MorseStateExport) ProtoMethods() *protoiface.Methods { } var ( - md_MorseAppState protoreflect.MessageDescriptor - fd_MorseAppState_application protoreflect.FieldDescriptor - fd_MorseAppState_auth protoreflect.FieldDescriptor - fd_MorseAppState_pos protoreflect.FieldDescriptor + md_MorseTendermintAppState protoreflect.MessageDescriptor + fd_MorseTendermintAppState_application protoreflect.FieldDescriptor + fd_MorseTendermintAppState_auth protoreflect.FieldDescriptor + fd_MorseTendermintAppState_pos protoreflect.FieldDescriptor ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseAppState = File_poktroll_migration_legacy_proto.Messages().ByName("MorseAppState") - fd_MorseAppState_application = md_MorseAppState.Fields().ByName("application") - fd_MorseAppState_auth = md_MorseAppState.Fields().ByName("auth") - fd_MorseAppState_pos = md_MorseAppState.Fields().ByName("pos") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseTendermintAppState = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseTendermintAppState") + fd_MorseTendermintAppState_application = md_MorseTendermintAppState.Fields().ByName("application") + fd_MorseTendermintAppState_auth = md_MorseTendermintAppState.Fields().ByName("auth") + fd_MorseTendermintAppState_pos = md_MorseTendermintAppState.Fields().ByName("pos") } -var _ protoreflect.Message = (*fastReflection_MorseAppState)(nil) +var _ protoreflect.Message = (*fastReflection_MorseTendermintAppState)(nil) -type fastReflection_MorseAppState MorseAppState +type fastReflection_MorseTendermintAppState MorseTendermintAppState -func (x *MorseAppState) ProtoReflect() protoreflect.Message { - return (*fastReflection_MorseAppState)(x) +func (x *MorseTendermintAppState) ProtoReflect() protoreflect.Message { + return (*fastReflection_MorseTendermintAppState)(x) } -func (x *MorseAppState) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[1] +func (x *MorseTendermintAppState) slowProtoReflect() protoreflect.Message { + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -547,43 +547,43 @@ func (x *MorseAppState) slowProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -var _fastReflection_MorseAppState_messageType fastReflection_MorseAppState_messageType -var _ protoreflect.MessageType = fastReflection_MorseAppState_messageType{} +var _fastReflection_MorseTendermintAppState_messageType fastReflection_MorseTendermintAppState_messageType +var _ protoreflect.MessageType = fastReflection_MorseTendermintAppState_messageType{} -type fastReflection_MorseAppState_messageType struct{} +type fastReflection_MorseTendermintAppState_messageType struct{} -func (x fastReflection_MorseAppState_messageType) Zero() protoreflect.Message { - return (*fastReflection_MorseAppState)(nil) +func (x fastReflection_MorseTendermintAppState_messageType) Zero() protoreflect.Message { + return (*fastReflection_MorseTendermintAppState)(nil) } -func (x fastReflection_MorseAppState_messageType) New() protoreflect.Message { - return new(fastReflection_MorseAppState) +func (x fastReflection_MorseTendermintAppState_messageType) New() protoreflect.Message { + return new(fastReflection_MorseTendermintAppState) } -func (x fastReflection_MorseAppState_messageType) Descriptor() protoreflect.MessageDescriptor { - return md_MorseAppState +func (x fastReflection_MorseTendermintAppState_messageType) Descriptor() protoreflect.MessageDescriptor { + return md_MorseTendermintAppState } // Descriptor returns message descriptor, which contains only the protobuf // type information for the message. -func (x *fastReflection_MorseAppState) Descriptor() protoreflect.MessageDescriptor { - return md_MorseAppState +func (x *fastReflection_MorseTendermintAppState) Descriptor() protoreflect.MessageDescriptor { + return md_MorseTendermintAppState } // Type returns the message type, which encapsulates both Go and protobuf // type information. If the Go type information is not needed, // it is recommended that the message descriptor be used instead. -func (x *fastReflection_MorseAppState) Type() protoreflect.MessageType { - return _fastReflection_MorseAppState_messageType +func (x *fastReflection_MorseTendermintAppState) Type() protoreflect.MessageType { + return _fastReflection_MorseTendermintAppState_messageType } // New returns a newly allocated and mutable empty message. -func (x *fastReflection_MorseAppState) New() protoreflect.Message { - return new(fastReflection_MorseAppState) +func (x *fastReflection_MorseTendermintAppState) New() protoreflect.Message { + return new(fastReflection_MorseTendermintAppState) } // Interface unwraps the message reflection interface and // returns the underlying ProtoMessage interface. -func (x *fastReflection_MorseAppState) Interface() protoreflect.ProtoMessage { - return (*MorseAppState)(x) +func (x *fastReflection_MorseTendermintAppState) Interface() protoreflect.ProtoMessage { + return (*MorseTendermintAppState)(x) } // Range iterates over every populated field in an undefined order, @@ -591,22 +591,22 @@ func (x *fastReflection_MorseAppState) Interface() protoreflect.ProtoMessage { // Range returns immediately if f returns false. // While iterating, mutating operations may only be performed // on the current field descriptor. -func (x *fastReflection_MorseAppState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { +func (x *fastReflection_MorseTendermintAppState) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { if x.Application != nil { value := protoreflect.ValueOfMessage(x.Application.ProtoReflect()) - if !f(fd_MorseAppState_application, value) { + if !f(fd_MorseTendermintAppState_application, value) { return } } if x.Auth != nil { value := protoreflect.ValueOfMessage(x.Auth.ProtoReflect()) - if !f(fd_MorseAppState_auth, value) { + if !f(fd_MorseTendermintAppState_auth, value) { return } } if x.Pos != nil { value := protoreflect.ValueOfMessage(x.Pos.ProtoReflect()) - if !f(fd_MorseAppState_pos, value) { + if !f(fd_MorseTendermintAppState_pos, value) { return } } @@ -623,19 +623,19 @@ func (x *fastReflection_MorseAppState) Range(f func(protoreflect.FieldDescriptor // In other cases (aside from the nullable cases above), // a proto3 scalar field is populated if it contains a non-zero value, and // a repeated field is populated if it is non-empty. -func (x *fastReflection_MorseAppState) Has(fd protoreflect.FieldDescriptor) bool { +func (x *fastReflection_MorseTendermintAppState) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": return x.Application != nil - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": return x.Auth != nil - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": return x.Pos != nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", fd.FullName())) } } @@ -645,19 +645,19 @@ func (x *fastReflection_MorseAppState) Has(fd protoreflect.FieldDescriptor) bool // associated with the given field number. // // Clear is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_MorseAppState) Clear(fd protoreflect.FieldDescriptor) { +func (x *fastReflection_MorseTendermintAppState) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": x.Application = nil - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": x.Auth = nil - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": x.Pos = nil default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", fd.FullName())) } } @@ -667,22 +667,22 @@ func (x *fastReflection_MorseAppState) Clear(fd protoreflect.FieldDescriptor) { // the default value of a bytes scalar is guaranteed to be a copy. // For unpopulated composite types, it returns an empty, read-only view // of the value; to obtain a mutable reference, use Mutable. -func (x *fastReflection_MorseAppState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_MorseTendermintAppState) Get(descriptor protoreflect.FieldDescriptor) protoreflect.Value { switch descriptor.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": value := x.Application return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": value := x.Auth return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": value := x.Pos return protoreflect.ValueOfMessage(value.ProtoReflect()) default: if descriptor.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", descriptor.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", descriptor.FullName())) } } @@ -696,19 +696,19 @@ func (x *fastReflection_MorseAppState) Get(descriptor protoreflect.FieldDescript // empty, read-only value, then it panics. // // Set is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_MorseAppState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { +func (x *fastReflection_MorseTendermintAppState) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": x.Application = value.Message().Interface().(*MorseApplications) - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": x.Auth = value.Message().Interface().(*MorseAuth) - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": x.Pos = value.Message().Interface().(*MorsePos) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", fd.FullName())) } } @@ -722,60 +722,60 @@ func (x *fastReflection_MorseAppState) Set(fd protoreflect.FieldDescriptor, valu // It panics if the field does not contain a composite type. // // Mutable is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_MorseAppState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_MorseTendermintAppState) Mutable(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": if x.Application == nil { x.Application = new(MorseApplications) } return protoreflect.ValueOfMessage(x.Application.ProtoReflect()) - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": if x.Auth == nil { x.Auth = new(MorseAuth) } return protoreflect.ValueOfMessage(x.Auth.ProtoReflect()) - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": if x.Pos == nil { x.Pos = new(MorsePos) } return protoreflect.ValueOfMessage(x.Pos.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", fd.FullName())) } } // NewField returns a new value that is assignable to the field // for the given descriptor. For scalars, this returns the default value. // For lists, maps, and messages, this returns a new, empty, mutable value. -func (x *fastReflection_MorseAppState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { +func (x *fastReflection_MorseTendermintAppState) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { - case "poktroll.migration.MorseAppState.application": + case "poktroll.migration.MorseTendermintAppState.application": m := new(MorseApplications) return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "poktroll.migration.MorseAppState.auth": + case "poktroll.migration.MorseTendermintAppState.auth": m := new(MorseAuth) return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "poktroll.migration.MorseAppState.pos": + case "poktroll.migration.MorseTendermintAppState.pos": m := new(MorsePos) return protoreflect.ValueOfMessage(m.ProtoReflect()) default: if fd.IsExtension() { - panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseAppState")) + panic(fmt.Errorf("proto3 declared messages do not support extensions: poktroll.migration.MorseTendermintAppState")) } - panic(fmt.Errorf("message poktroll.migration.MorseAppState does not contain field %s", fd.FullName())) + panic(fmt.Errorf("message poktroll.migration.MorseTendermintAppState does not contain field %s", fd.FullName())) } } // WhichOneof reports which field within the oneof is populated, // returning nil if none are populated. // It panics if the oneof descriptor does not belong to this message. -func (x *fastReflection_MorseAppState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { +func (x *fastReflection_MorseTendermintAppState) WhichOneof(d protoreflect.OneofDescriptor) protoreflect.FieldDescriptor { switch d.FullName() { default: - panic(fmt.Errorf("%s is not a oneof field in poktroll.migration.MorseAppState", d.FullName())) + panic(fmt.Errorf("%s is not a oneof field in poktroll.migration.MorseTendermintAppState", d.FullName())) } panic("unreachable") } @@ -783,7 +783,7 @@ func (x *fastReflection_MorseAppState) WhichOneof(d protoreflect.OneofDescriptor // GetUnknown retrieves the entire list of unknown fields. // The caller may only mutate the contents of the RawFields // if the mutated bytes are stored back into the message with SetUnknown. -func (x *fastReflection_MorseAppState) GetUnknown() protoreflect.RawFields { +func (x *fastReflection_MorseTendermintAppState) GetUnknown() protoreflect.RawFields { return x.unknownFields } @@ -794,7 +794,7 @@ func (x *fastReflection_MorseAppState) GetUnknown() protoreflect.RawFields { // An empty RawFields may be passed to clear the fields. // // SetUnknown is a mutating operation and unsafe for concurrent use. -func (x *fastReflection_MorseAppState) SetUnknown(fields protoreflect.RawFields) { +func (x *fastReflection_MorseTendermintAppState) SetUnknown(fields protoreflect.RawFields) { x.unknownFields = fields } @@ -806,7 +806,7 @@ func (x *fastReflection_MorseAppState) SetUnknown(fields protoreflect.RawFields) // message type, but the details are implementation dependent. // Validity is not part of the protobuf data model, and may not // be preserved in marshaling or other operations. -func (x *fastReflection_MorseAppState) IsValid() bool { +func (x *fastReflection_MorseTendermintAppState) IsValid() bool { return x != nil } @@ -816,9 +816,9 @@ func (x *fastReflection_MorseAppState) IsValid() bool { // The returned methods type is identical to // "google.golang.org/protobuf/runtime/protoiface".Methods. // Consult the protoiface package documentation for details. -func (x *fastReflection_MorseAppState) ProtoMethods() *protoiface.Methods { +func (x *fastReflection_MorseTendermintAppState) ProtoMethods() *protoiface.Methods { size := func(input protoiface.SizeInput) protoiface.SizeOutput { - x := input.Message.Interface().(*MorseAppState) + x := input.Message.Interface().(*MorseTendermintAppState) if x == nil { return protoiface.SizeOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -852,7 +852,7 @@ func (x *fastReflection_MorseAppState) ProtoMethods() *protoiface.Methods { } marshal := func(input protoiface.MarshalInput) (protoiface.MarshalOutput, error) { - x := input.Message.Interface().(*MorseAppState) + x := input.Message.Interface().(*MorseTendermintAppState) if x == nil { return protoiface.MarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -924,7 +924,7 @@ func (x *fastReflection_MorseAppState) ProtoMethods() *protoiface.Methods { }, nil } unmarshal := func(input protoiface.UnmarshalInput) (protoiface.UnmarshalOutput, error) { - x := input.Message.Interface().(*MorseAppState) + x := input.Message.Interface().(*MorseTendermintAppState) if x == nil { return protoiface.UnmarshalOutput{ NoUnkeyedLiterals: input.NoUnkeyedLiterals, @@ -956,10 +956,10 @@ func (x *fastReflection_MorseAppState) ProtoMethods() *protoiface.Methods { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MorseAppState: wiretype end group for non-group") + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MorseTendermintAppState: wiretype end group for non-group") } if fieldNum <= 0 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MorseAppState: illegal tag %d (wire type %d)", fieldNum, wire) + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: MorseTendermintAppState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -1162,8 +1162,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseApplications = File_poktroll_migration_legacy_proto.Messages().ByName("MorseApplications") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseApplications = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseApplications") fd_MorseApplications_applications = md_MorseApplications.Fields().ByName("applications") } @@ -1176,7 +1176,7 @@ func (x *MorseApplications) ProtoReflect() protoreflect.Message { } func (x *MorseApplications) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[2] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1656,8 +1656,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseAuth = File_poktroll_migration_legacy_proto.Messages().ByName("MorseAuth") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseAuth = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseAuth") fd_MorseAuth_accounts = md_MorseAuth.Fields().ByName("accounts") } @@ -1670,7 +1670,7 @@ func (x *MorseAuth) ProtoReflect() protoreflect.Message { } func (x *MorseAuth) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[3] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2100,8 +2100,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseAuthAccount = File_poktroll_migration_legacy_proto.Messages().ByName("MorseAuthAccount") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseAuthAccount = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseAuthAccount") fd_MorseAuthAccount_type = md_MorseAuthAccount.Fields().ByName("type") fd_MorseAuthAccount_value = md_MorseAuthAccount.Fields().ByName("value") } @@ -2115,7 +2115,7 @@ func (x *MorseAuthAccount) ProtoReflect() protoreflect.Message { } func (x *MorseAuthAccount) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[4] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2649,8 +2649,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorsePos = File_poktroll_migration_legacy_proto.Messages().ByName("MorsePos") + file_poktroll_migration_morse_offchain_proto_init() + md_MorsePos = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorsePos") fd_MorsePos_validators = md_MorsePos.Fields().ByName("validators") } @@ -2663,7 +2663,7 @@ func (x *MorsePos) ProtoReflect() protoreflect.Message { } func (x *MorsePos) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[5] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3096,8 +3096,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseApplication = File_poktroll_migration_legacy_proto.Messages().ByName("MorseApplication") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseApplication = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseApplication") fd_MorseApplication_address = md_MorseApplication.Fields().ByName("address") fd_MorseApplication_public_key = md_MorseApplication.Fields().ByName("public_key") fd_MorseApplication_jailed = md_MorseApplication.Fields().ByName("jailed") @@ -3114,7 +3114,7 @@ func (x *MorseApplication) ProtoReflect() protoreflect.Message { } func (x *MorseApplication) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[6] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3750,8 +3750,8 @@ var ( ) func init() { - file_poktroll_migration_legacy_proto_init() - md_MorseValidator = File_poktroll_migration_legacy_proto.Messages().ByName("MorseValidator") + file_poktroll_migration_morse_offchain_proto_init() + md_MorseValidator = File_poktroll_migration_morse_offchain_proto.Messages().ByName("MorseValidator") fd_MorseValidator_address = md_MorseValidator.Fields().ByName("address") fd_MorseValidator_public_key = md_MorseValidator.Fields().ByName("public_key") fd_MorseValidator_jailed = md_MorseValidator.Fields().ByName("jailed") @@ -3768,7 +3768,7 @@ func (x *MorseValidator) ProtoReflect() protoreflect.Message { } func (x *MorseValidator) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_legacy_proto_msgTypes[7] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4398,16 +4398,27 @@ func (x *fastReflection_MorseValidator) ProtoMethods() *protoiface.Methods { // versions: // protoc-gen-go v1.27.0 // protoc (unknown) -// source: poktroll/migration/legacy.proto +// source: poktroll/migration/morse_offchain.proto // Types in this file are ONLY present to facilitate the verifiability of the // migration state from Morse to Shannon. // +// These types reproduce a 1:1 de/serialization for the corresponding Morse data structures +// but are not completely identical to their Morse counterparts, not all of which are defined +// as protobuf types in the Morse codebase. +// +// Morse also leverages pb.Any types, as well as the gogoproto.casttype option in several places. +// All usages of pb.Any have been replaced with equivalent protobuf types +// (i.e. an interstitial type with `type` and/or `value` field(s)). +// All usages of gogoproto.casttype which previously referenced Morse data structures have been removed. +// A few specific fields have retained this option where the type is changed to the underlying +// external lib type that the Morse type was wrapping (e.g. address and public key fields). +// // These types are used by the migration subcommand to transform // the Morse state export into the Shannon state import. // Ref: `poktrolld migrate collect-morse-accounts ...` // -// They ARE NOT persisted on-chain at any point. +// They ARE NOT persisted on-chain (Shannon) at any point. const ( // Verify that this generated code is sufficiently up-to-date. @@ -4418,6 +4429,7 @@ const ( // MorseStateExport is the data structure that is serialized and output when running // `pocket utils export-genesis-for-reset`. +// // See: https://editor.swagger.io/?url=https://raw.githubusercontent.com/pokt-network/pocket-core/staging/doc/specs/rpc-spec.yaml#operations-query-post_query_state type MorseStateExport struct { state protoimpl.MessageState @@ -4427,13 +4439,13 @@ type MorseStateExport struct { // app_hash is the Morse tendermint state hash. AppHash string `protobuf:"bytes,1,opt,name=app_hash,json=appHash,proto3" json:"app_hash,omitempty"` // app_state is the entire Morse tendermint application state. - AppState *MorseAppState `protobuf:"bytes,2,opt,name=app_state,json=appState,proto3" json:"app_state,omitempty"` + AppState *MorseTendermintAppState `protobuf:"bytes,2,opt,name=app_state,json=appState,proto3" json:"app_state,omitempty"` } func (x *MorseStateExport) Reset() { *x = MorseStateExport{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[0] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4447,7 +4459,7 @@ func (*MorseStateExport) ProtoMessage() {} // Deprecated: Use MorseStateExport.ProtoReflect.Descriptor instead. func (*MorseStateExport) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{0} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{0} } func (x *MorseStateExport) GetAppHash() string { @@ -4457,16 +4469,19 @@ func (x *MorseStateExport) GetAppHash() string { return "" } -func (x *MorseStateExport) GetAppState() *MorseAppState { +func (x *MorseStateExport) GetAppState() *MorseTendermintAppState { if x != nil { return x.AppState } return nil } -// MorseAppState is the tendermint application state for the Morse tendermint +// MorseTendermintAppState is the tendermint application state for the Morse tendermint // application; not to be confused with the pokt protocol actor. -type MorseAppState struct { +// It is constructed in Morse via `PocketCoreApp#ExportAppState()`. +// +// See: https://github.com/pokt-network/pocket-core/blob/5fa61920aa9d45ca6bf9e01e863134e242c95fa7/app/pocket.go#L142 +type MorseTendermintAppState struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields @@ -4476,41 +4491,41 @@ type MorseAppState struct { Pos *MorsePos `protobuf:"bytes,3,opt,name=pos,proto3" json:"pos,omitempty"` } -func (x *MorseAppState) Reset() { - *x = MorseAppState{} +func (x *MorseTendermintAppState) Reset() { + *x = MorseTendermintAppState{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[1] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *MorseAppState) String() string { +func (x *MorseTendermintAppState) String() string { return protoimpl.X.MessageStringOf(x) } -func (*MorseAppState) ProtoMessage() {} +func (*MorseTendermintAppState) ProtoMessage() {} -// Deprecated: Use MorseAppState.ProtoReflect.Descriptor instead. -func (*MorseAppState) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{1} +// Deprecated: Use MorseTendermintAppState.ProtoReflect.Descriptor instead. +func (*MorseTendermintAppState) Descriptor() ([]byte, []int) { + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{1} } -func (x *MorseAppState) GetApplication() *MorseApplications { +func (x *MorseTendermintAppState) GetApplication() *MorseApplications { if x != nil { return x.Application } return nil } -func (x *MorseAppState) GetAuth() *MorseAuth { +func (x *MorseTendermintAppState) GetAuth() *MorseAuth { if x != nil { return x.Auth } return nil } -func (x *MorseAppState) GetPos() *MorsePos { +func (x *MorseTendermintAppState) GetPos() *MorsePos { if x != nil { return x.Pos } @@ -4518,6 +4533,9 @@ func (x *MorseAppState) GetPos() *MorsePos { } // A wrapper around the list of MorseApplications, necessary in order to conform to the Morse genesis structure. +// It encapsulates the minimum information required to import Morse applications. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/apps/types/genesis.go#L4 type MorseApplications struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -4529,7 +4547,7 @@ type MorseApplications struct { func (x *MorseApplications) Reset() { *x = MorseApplications{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[2] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4543,7 +4561,7 @@ func (*MorseApplications) ProtoMessage() {} // Deprecated: Use MorseApplications.ProtoReflect.Descriptor instead. func (*MorseApplications) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{2} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{2} } func (x *MorseApplications) GetApplications() []*MorseApplication { @@ -4554,6 +4572,9 @@ func (x *MorseApplications) GetApplications() []*MorseApplication { } // A wrapper around a list of Morse accounts. +// It encapsulates the minimum information required to import Morse accounts. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/auth/types/genesis.go#L9 type MorseAuth struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -4565,7 +4586,7 @@ type MorseAuth struct { func (x *MorseAuth) Reset() { *x = MorseAuth{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[3] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4579,7 +4600,7 @@ func (*MorseAuth) ProtoMessage() {} // Deprecated: Use MorseAuth.ProtoReflect.Descriptor instead. func (*MorseAuth) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{3} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{3} } func (x *MorseAuth) GetAccounts() []*MorseAuthAccount { @@ -4607,7 +4628,7 @@ type MorseAuthAccount struct { func (x *MorseAuthAccount) Reset() { *x = MorseAuthAccount{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[4] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4621,7 +4642,7 @@ func (*MorseAuthAccount) ProtoMessage() {} // Deprecated: Use MorseAuthAccount.ProtoReflect.Descriptor instead. func (*MorseAuthAccount) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{4} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{4} } func (x *MorseAuthAccount) GetType_() string { @@ -4640,6 +4661,8 @@ func (x *MorseAuthAccount) GetValue() *MorseAccount { // A wrapper around the list of Morse suppliers (aka "validators", "nodes", of "servicers"). // It is necessary to conform to the Morse genesis structure. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/nodes/types/genesis.go#L8 type MorsePos struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -4651,7 +4674,7 @@ type MorsePos struct { func (x *MorsePos) Reset() { *x = MorsePos{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[5] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4665,7 +4688,7 @@ func (*MorsePos) ProtoMessage() {} // Deprecated: Use MorsePos.ProtoReflect.Descriptor instead. func (*MorsePos) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{5} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{5} } func (x *MorsePos) GetValidators() []*MorseValidator { @@ -4677,6 +4700,7 @@ func (x *MorsePos) GetValidators() []*MorseValidator { // MorseApplication is a subset of the Morse ProtoApplication type. // It encapsulates the minimum information required to import Morse applications. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/apps/apps.proto#L16 type MorseApplication struct { state protoimpl.MessageState @@ -4697,7 +4721,7 @@ type MorseApplication struct { func (x *MorseApplication) Reset() { *x = MorseApplication{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[6] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4711,7 +4735,7 @@ func (*MorseApplication) ProtoMessage() {} // Deprecated: Use MorseApplication.ProtoReflect.Descriptor instead. func (*MorseApplication) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{6} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{6} } func (x *MorseApplication) GetAddress() []byte { @@ -4751,6 +4775,7 @@ func (x *MorseApplication) GetStakedTokens() string { // MorseValidator is a subset of the Morse ProtoValidator type. // It encapsulates the minimum information required to import Morse suppliers (aka "servicers" or "validators"). +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/pos/types.proto#L16 type MorseValidator struct { state protoimpl.MessageState @@ -4770,7 +4795,7 @@ type MorseValidator struct { func (x *MorseValidator) Reset() { *x = MorseValidator{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_legacy_proto_msgTypes[7] + mi := &file_poktroll_migration_morse_offchain_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4784,7 +4809,7 @@ func (*MorseValidator) ProtoMessage() {} // Deprecated: Use MorseValidator.ProtoReflect.Descriptor instead. func (*MorseValidator) Descriptor() ([]byte, []int) { - return file_poktroll_migration_legacy_proto_rawDescGZIP(), []int{7} + return file_poktroll_migration_morse_offchain_proto_rawDescGZIP(), []int{7} } func (x *MorseValidator) GetAddress() []byte { @@ -4822,89 +4847,69 @@ func (x *MorseValidator) GetStakedTokens() string { return "" } -var File_poktroll_migration_legacy_proto protoreflect.FileDescriptor +var File_poktroll_migration_morse_offchain_proto protoreflect.FileDescriptor -var file_poktroll_migration_legacy_proto_rawDesc = []byte{ - 0x0a, 0x1f, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x6c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x12, 0x12, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1e, 0x70, 0x6f, 0x6b, - 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, - 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x8a, 0x01, 0x0a, 0x10, +var file_poktroll_migration_morse_offchain_proto_rawDesc = []byte{ + 0x0a, 0x27, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x6d, 0x6f, 0x72, 0x73, 0x65, 0x5f, 0x6f, 0x66, 0x66, 0x63, 0x68, + 0x61, 0x69, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x70, 0x6f, 0x6b, 0x74, 0x72, + 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x1a, 0x14, 0x67, + 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x1a, 0x26, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, + 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x6d, 0x6f, 0x72, 0x73, 0x65, 0x5f, 0x6f, 0x6e, + 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x94, 0x01, 0x0a, 0x10, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x53, 0x74, 0x61, 0x74, 0x65, 0x45, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x27, 0x0a, 0x08, 0x61, 0x70, 0x70, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x61, 0x70, 0x70, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x52, 0x07, 0x61, 0x70, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x4d, 0x0a, 0x09, 0x61, 0x70, 0x70, - 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x70, + 0x52, 0x07, 0x61, 0x70, 0x70, 0x48, 0x61, 0x73, 0x68, 0x12, 0x57, 0x0a, 0x09, 0x61, 0x70, 0x70, + 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, - 0x0d, 0xea, 0xde, 0x1f, 0x09, 0x61, 0x70, 0x70, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52, 0x08, - 0x61, 0x70, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x22, 0xdf, 0x01, 0x0a, 0x0d, 0x4d, 0x6f, 0x72, - 0x73, 0x65, 0x41, 0x70, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x58, 0x0a, 0x0b, 0x61, 0x70, - 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x25, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x42, 0x0f, 0xea, 0xde, 0x1f, 0x0b, 0x61, 0x70, 0x70, 0x6c, - 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3b, 0x0a, 0x04, 0x61, 0x75, 0x74, 0x68, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, - 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x75, 0x74, - 0x68, 0x42, 0x08, 0xea, 0xde, 0x1f, 0x04, 0x61, 0x75, 0x74, 0x68, 0x52, 0x04, 0x61, 0x75, 0x74, - 0x68, 0x12, 0x37, 0x0a, 0x03, 0x70, 0x6f, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, + 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x54, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x6d, 0x69, 0x6e, + 0x74, 0x41, 0x70, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x42, 0x0d, 0xea, 0xde, 0x1f, 0x09, 0x61, + 0x70, 0x70, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52, 0x08, 0x61, 0x70, 0x70, 0x53, 0x74, 0x61, + 0x74, 0x65, 0x22, 0xe9, 0x01, 0x0a, 0x17, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x54, 0x65, 0x6e, 0x64, + 0x65, 0x72, 0x6d, 0x69, 0x6e, 0x74, 0x41, 0x70, 0x70, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x58, + 0x0a, 0x0b, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, + 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, + 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x42, 0x0f, 0xea, 0xde, 0x1f, 0x0b, + 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x61, 0x70, 0x70, + 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x3b, 0x0a, 0x04, 0x61, 0x75, 0x74, 0x68, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, + 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, + 0x65, 0x41, 0x75, 0x74, 0x68, 0x42, 0x08, 0xea, 0xde, 0x1f, 0x04, 0x61, 0x75, 0x74, 0x68, 0x52, + 0x04, 0x61, 0x75, 0x74, 0x68, 0x12, 0x37, 0x0a, 0x03, 0x70, 0x6f, 0x73, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, + 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x6f, 0x73, + 0x42, 0x07, 0xea, 0xde, 0x1f, 0x03, 0x70, 0x6f, 0x73, 0x52, 0x03, 0x70, 0x6f, 0x73, 0x22, 0x6f, + 0x0a, 0x11, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x12, 0x5a, 0x0a, 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x70, 0x6f, 0x6b, 0x74, + 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, + 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, + 0x10, 0xea, 0xde, 0x1f, 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x73, 0x52, 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, + 0x5b, 0x0a, 0x09, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x75, 0x74, 0x68, 0x12, 0x4e, 0x0a, 0x08, + 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x6f, 0x73, 0x42, 0x07, 0xea, 0xde, - 0x1f, 0x03, 0x70, 0x6f, 0x73, 0x52, 0x03, 0x70, 0x6f, 0x73, 0x22, 0x6f, 0x0a, 0x11, 0x4d, 0x6f, - 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, - 0x5a, 0x0a, 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, - 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, - 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x10, 0xea, 0xde, 0x1f, - 0x0c, 0x61, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x0c, 0x61, - 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x5b, 0x0a, 0x09, 0x4d, - 0x6f, 0x72, 0x73, 0x65, 0x41, 0x75, 0x74, 0x68, 0x12, 0x4e, 0x0a, 0x08, 0x61, 0x63, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x70, 0x6f, 0x6b, - 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, + 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x75, 0x74, 0x68, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x73, 0x52, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x22, 0x73, 0x0a, 0x10, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x75, 0x74, 0x68, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x52, 0x08, - 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x22, 0x73, 0x0a, 0x10, 0x4d, 0x6f, 0x72, 0x73, - 0x65, 0x41, 0x75, 0x74, 0x68, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1c, 0x0a, 0x04, - 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x08, 0xea, 0xde, 0x1f, 0x04, - 0x74, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x41, 0x0a, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x70, 0x6f, 0x6b, 0x74, - 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, - 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x09, 0xea, 0xde, 0x1f, - 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x22, 0x5e, 0x0a, - 0x08, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x6f, 0x73, 0x12, 0x52, 0x0a, 0x0a, 0x76, 0x61, 0x6c, - 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, + 0x12, 0x1c, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x08, + 0xea, 0xde, 0x1f, 0x04, 0x74, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x41, + 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, - 0x72, 0x42, 0x0e, 0xea, 0xde, 0x1f, 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, - 0x73, 0x52, 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x22, 0xe3, 0x02, - 0x0a, 0x10, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x66, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0c, 0x42, 0x4c, 0xea, 0xde, 0x1f, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, - 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x22, 0xfa, 0xde, 0x1f, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, - 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, - 0x66, 0x74, 0x2f, 0x63, 0x72, 0x79, 0x70, 0x74, 0x6f, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x42, 0x0a, 0x0a, 0x70, 0x75, - 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x23, - 0xea, 0xde, 0x1f, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0xf2, 0xde, - 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, - 0x65, 0x79, 0x22, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x33, - 0x0a, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x42, 0x1b, - 0xea, 0xde, 0x1f, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0xf2, 0xde, 0x1f, 0x0d, 0x79, 0x61, - 0x6d, 0x6c, 0x3a, 0x22, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x52, 0x06, 0x6a, 0x61, 0x69, - 0x6c, 0x65, 0x64, 0x12, 0x33, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x05, 0x42, 0x1b, 0xea, 0xde, 0x1f, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0xf2, - 0xde, 0x1f, 0x0d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22, - 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x2f, 0x0a, 0x0d, 0x73, 0x74, 0x61, 0x6b, - 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x42, - 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x52, 0x0c, 0x73, 0x74, 0x61, - 0x6b, 0x65, 0x64, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x3a, 0x08, 0x88, 0xa0, 0x1f, 0x00, 0xe8, - 0xa0, 0x1f, 0x01, 0x22, 0xc3, 0x02, 0x0a, 0x0e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x56, 0x61, 0x6c, - 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x66, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, + 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, + 0x09, 0xea, 0xde, 0x1f, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, + 0x65, 0x22, 0x5e, 0x0a, 0x08, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x6f, 0x73, 0x12, 0x52, 0x0a, + 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x0b, 0x32, 0x22, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x56, 0x61, 0x6c, 0x69, + 0x64, 0x61, 0x74, 0x6f, 0x72, 0x42, 0x0e, 0xea, 0xde, 0x1f, 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, + 0x61, 0x74, 0x6f, 0x72, 0x73, 0x52, 0x0a, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, + 0x73, 0x22, 0xe3, 0x02, 0x0a, 0x10, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x70, 0x70, 0x6c, 0x69, + 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x66, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x4c, 0xea, 0xde, 0x1f, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xfa, 0xde, 0x1f, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, @@ -4915,58 +4920,81 @@ var file_poktroll_migration_legacy_proto_rawDesc = []byte{ 0x28, 0x0c, 0x42, 0x23, 0xea, 0xde, 0x1f, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x22, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x12, 0x22, 0x0a, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x08, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x52, 0x06, - 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x12, 0x22, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x73, 0x74, 0x61, 0x74, - 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x2f, 0x0a, 0x0d, 0x73, 0x74, - 0x61, 0x6b, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x09, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x52, 0x0c, 0x73, - 0x74, 0x61, 0x6b, 0x65, 0x64, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x3a, 0x0c, 0x88, 0xa0, 0x1f, - 0x00, 0x98, 0xa0, 0x1f, 0x01, 0xe8, 0xa0, 0x1f, 0x01, 0x42, 0xb7, 0x01, 0xd8, 0xe2, 0x1e, 0x01, - 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, - 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0b, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x23, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, - 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, - 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xa2, 0x02, 0x03, 0x50, - 0x4d, 0x58, 0xaa, 0x02, 0x12, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x4d, 0x69, - 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xca, 0x02, 0x12, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, - 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xe2, 0x02, 0x1e, 0x50, - 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x13, - 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x3a, 0x3a, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x65, 0x79, 0x12, 0x33, 0x0a, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x08, 0x42, 0x1b, 0xea, 0xde, 0x1f, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0xf2, 0xde, + 0x1f, 0x0d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x22, 0x52, + 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x12, 0x33, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, + 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x42, 0x1b, 0xea, 0xde, 0x1f, 0x06, 0x73, 0x74, 0x61, + 0x74, 0x75, 0x73, 0xf2, 0xde, 0x1f, 0x0d, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x73, 0x74, 0x61, + 0x74, 0x75, 0x73, 0x22, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x2f, 0x0a, 0x0d, + 0x73, 0x74, 0x61, 0x6b, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x09, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x52, + 0x0c, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x64, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x3a, 0x08, 0x88, + 0xa0, 0x1f, 0x00, 0xe8, 0xa0, 0x1f, 0x01, 0x22, 0xc3, 0x02, 0x0a, 0x0e, 0x4d, 0x6f, 0x72, 0x73, + 0x65, 0x56, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x66, 0x0a, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x4c, 0xea, 0xde, 0x1f, + 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0xf2, 0xde, 0x1f, 0x0e, 0x79, 0x61, 0x6d, 0x6c, + 0x3a, 0x22, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x22, 0xfa, 0xde, 0x1f, 0x2b, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, 0x66, + 0x74, 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x72, 0x79, 0x70, 0x74, + 0x6f, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, + 0x73, 0x73, 0x12, 0x42, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x23, 0xea, 0xde, 0x1f, 0x0a, 0x70, 0x75, 0x62, 0x6c, + 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, + 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x22, 0x52, 0x09, 0x70, 0x75, 0x62, + 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x22, 0x0a, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x6a, 0x61, 0x69, 0x6c, + 0x65, 0x64, 0x52, 0x06, 0x6a, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x12, 0x22, 0x0a, 0x06, 0x73, 0x74, + 0x61, 0x74, 0x75, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x2f, + 0x0a, 0x0d, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xea, 0xde, 0x1f, 0x06, 0x74, 0x6f, 0x6b, 0x65, 0x6e, + 0x73, 0x52, 0x0c, 0x73, 0x74, 0x61, 0x6b, 0x65, 0x64, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x73, 0x3a, + 0x0c, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x01, 0xe8, 0xa0, 0x1f, 0x01, 0x42, 0xbe, 0x01, + 0xd8, 0xe2, 0x1e, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, + 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x12, 0x4d, 0x6f, + 0x72, 0x73, 0x65, 0x4f, 0x66, 0x66, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, + 0x50, 0x01, 0x5a, 0x23, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, + 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, + 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xa2, 0x02, 0x03, 0x50, 0x4d, 0x58, 0xaa, 0x02, 0x12, + 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0xca, 0x02, 0x12, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, + 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xe2, 0x02, 0x1e, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, + 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5c, 0x47, 0x50, 0x42, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x13, 0x50, 0x6f, 0x6b, 0x74, 0x72, + 0x6f, 0x6c, 0x6c, 0x3a, 0x3a, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x62, 0x06, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( - file_poktroll_migration_legacy_proto_rawDescOnce sync.Once - file_poktroll_migration_legacy_proto_rawDescData = file_poktroll_migration_legacy_proto_rawDesc + file_poktroll_migration_morse_offchain_proto_rawDescOnce sync.Once + file_poktroll_migration_morse_offchain_proto_rawDescData = file_poktroll_migration_morse_offchain_proto_rawDesc ) -func file_poktroll_migration_legacy_proto_rawDescGZIP() []byte { - file_poktroll_migration_legacy_proto_rawDescOnce.Do(func() { - file_poktroll_migration_legacy_proto_rawDescData = protoimpl.X.CompressGZIP(file_poktroll_migration_legacy_proto_rawDescData) +func file_poktroll_migration_morse_offchain_proto_rawDescGZIP() []byte { + file_poktroll_migration_morse_offchain_proto_rawDescOnce.Do(func() { + file_poktroll_migration_morse_offchain_proto_rawDescData = protoimpl.X.CompressGZIP(file_poktroll_migration_morse_offchain_proto_rawDescData) }) - return file_poktroll_migration_legacy_proto_rawDescData -} - -var file_poktroll_migration_legacy_proto_msgTypes = make([]protoimpl.MessageInfo, 8) -var file_poktroll_migration_legacy_proto_goTypes = []interface{}{ - (*MorseStateExport)(nil), // 0: poktroll.migration.MorseStateExport - (*MorseAppState)(nil), // 1: poktroll.migration.MorseAppState - (*MorseApplications)(nil), // 2: poktroll.migration.MorseApplications - (*MorseAuth)(nil), // 3: poktroll.migration.MorseAuth - (*MorseAuthAccount)(nil), // 4: poktroll.migration.MorseAuthAccount - (*MorsePos)(nil), // 5: poktroll.migration.MorsePos - (*MorseApplication)(nil), // 6: poktroll.migration.MorseApplication - (*MorseValidator)(nil), // 7: poktroll.migration.MorseValidator - (*MorseAccount)(nil), // 8: poktroll.migration.MorseAccount -} -var file_poktroll_migration_legacy_proto_depIdxs = []int32{ - 1, // 0: poktroll.migration.MorseStateExport.app_state:type_name -> poktroll.migration.MorseAppState - 2, // 1: poktroll.migration.MorseAppState.application:type_name -> poktroll.migration.MorseApplications - 3, // 2: poktroll.migration.MorseAppState.auth:type_name -> poktroll.migration.MorseAuth - 5, // 3: poktroll.migration.MorseAppState.pos:type_name -> poktroll.migration.MorsePos + return file_poktroll_migration_morse_offchain_proto_rawDescData +} + +var file_poktroll_migration_morse_offchain_proto_msgTypes = make([]protoimpl.MessageInfo, 8) +var file_poktroll_migration_morse_offchain_proto_goTypes = []interface{}{ + (*MorseStateExport)(nil), // 0: poktroll.migration.MorseStateExport + (*MorseTendermintAppState)(nil), // 1: poktroll.migration.MorseTendermintAppState + (*MorseApplications)(nil), // 2: poktroll.migration.MorseApplications + (*MorseAuth)(nil), // 3: poktroll.migration.MorseAuth + (*MorseAuthAccount)(nil), // 4: poktroll.migration.MorseAuthAccount + (*MorsePos)(nil), // 5: poktroll.migration.MorsePos + (*MorseApplication)(nil), // 6: poktroll.migration.MorseApplication + (*MorseValidator)(nil), // 7: poktroll.migration.MorseValidator + (*MorseAccount)(nil), // 8: poktroll.migration.MorseAccount +} +var file_poktroll_migration_morse_offchain_proto_depIdxs = []int32{ + 1, // 0: poktroll.migration.MorseStateExport.app_state:type_name -> poktroll.migration.MorseTendermintAppState + 2, // 1: poktroll.migration.MorseTendermintAppState.application:type_name -> poktroll.migration.MorseApplications + 3, // 2: poktroll.migration.MorseTendermintAppState.auth:type_name -> poktroll.migration.MorseAuth + 5, // 3: poktroll.migration.MorseTendermintAppState.pos:type_name -> poktroll.migration.MorsePos 6, // 4: poktroll.migration.MorseApplications.applications:type_name -> poktroll.migration.MorseApplication 4, // 5: poktroll.migration.MorseAuth.accounts:type_name -> poktroll.migration.MorseAuthAccount 8, // 6: poktroll.migration.MorseAuthAccount.value:type_name -> poktroll.migration.MorseAccount @@ -4978,14 +5006,14 @@ var file_poktroll_migration_legacy_proto_depIdxs = []int32{ 0, // [0:8] is the sub-list for field type_name } -func init() { file_poktroll_migration_legacy_proto_init() } -func file_poktroll_migration_legacy_proto_init() { - if File_poktroll_migration_legacy_proto != nil { +func init() { file_poktroll_migration_morse_offchain_proto_init() } +func file_poktroll_migration_morse_offchain_proto_init() { + if File_poktroll_migration_morse_offchain_proto != nil { return } - file_poktroll_migration_types_proto_init() + file_poktroll_migration_morse_onchain_proto_init() if !protoimpl.UnsafeEnabled { - file_poktroll_migration_legacy_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseStateExport); i { case 0: return &v.state @@ -4997,8 +5025,8 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*MorseAppState); i { + file_poktroll_migration_morse_offchain_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MorseTendermintAppState); i { case 0: return &v.state case 1: @@ -5009,7 +5037,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseApplications); i { case 0: return &v.state @@ -5021,7 +5049,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseAuth); i { case 0: return &v.state @@ -5033,7 +5061,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseAuthAccount); i { case 0: return &v.state @@ -5045,7 +5073,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorsePos); i { case 0: return &v.state @@ -5057,7 +5085,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseApplication); i { case 0: return &v.state @@ -5069,7 +5097,7 @@ func file_poktroll_migration_legacy_proto_init() { return nil } } - file_poktroll_migration_legacy_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_offchain_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseValidator); i { case 0: return &v.state @@ -5086,18 +5114,18 @@ func file_poktroll_migration_legacy_proto_init() { out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_poktroll_migration_legacy_proto_rawDesc, + RawDescriptor: file_poktroll_migration_morse_offchain_proto_rawDesc, NumEnums: 0, NumMessages: 8, NumExtensions: 0, NumServices: 0, }, - GoTypes: file_poktroll_migration_legacy_proto_goTypes, - DependencyIndexes: file_poktroll_migration_legacy_proto_depIdxs, - MessageInfos: file_poktroll_migration_legacy_proto_msgTypes, + GoTypes: file_poktroll_migration_morse_offchain_proto_goTypes, + DependencyIndexes: file_poktroll_migration_morse_offchain_proto_depIdxs, + MessageInfos: file_poktroll_migration_morse_offchain_proto_msgTypes, }.Build() - File_poktroll_migration_legacy_proto = out.File - file_poktroll_migration_legacy_proto_rawDesc = nil - file_poktroll_migration_legacy_proto_goTypes = nil - file_poktroll_migration_legacy_proto_depIdxs = nil + File_poktroll_migration_morse_offchain_proto = out.File + file_poktroll_migration_morse_offchain_proto_rawDesc = nil + file_poktroll_migration_morse_offchain_proto_goTypes = nil + file_poktroll_migration_morse_offchain_proto_depIdxs = nil } diff --git a/api/poktroll/migration/types.pulsar.go b/api/poktroll/migration/morse_onchain.pulsar.go similarity index 88% rename from api/poktroll/migration/types.pulsar.go rename to api/poktroll/migration/morse_onchain.pulsar.go index fe64423be..5758dd5dd 100644 --- a/api/poktroll/migration/types.pulsar.go +++ b/api/poktroll/migration/morse_onchain.pulsar.go @@ -72,8 +72,8 @@ var ( ) func init() { - file_poktroll_migration_types_proto_init() - md_MorseAccountState = File_poktroll_migration_types_proto.Messages().ByName("MorseAccountState") + file_poktroll_migration_morse_onchain_proto_init() + md_MorseAccountState = File_poktroll_migration_morse_onchain_proto.Messages().ByName("MorseAccountState") fd_MorseAccountState_accounts = md_MorseAccountState.Fields().ByName("accounts") } @@ -86,7 +86,7 @@ func (x *MorseAccountState) ProtoReflect() protoreflect.Message { } func (x *MorseAccountState) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_types_proto_msgTypes[0] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -568,8 +568,8 @@ var ( ) func init() { - file_poktroll_migration_types_proto_init() - md_MorseAccount = File_poktroll_migration_types_proto.Messages().ByName("MorseAccount") + file_poktroll_migration_morse_onchain_proto_init() + md_MorseAccount = File_poktroll_migration_morse_onchain_proto.Messages().ByName("MorseAccount") fd_MorseAccount_address = md_MorseAccount.Fields().ByName("address") fd_MorseAccount_pub_key = md_MorseAccount.Fields().ByName("pub_key") fd_MorseAccount_coins = md_MorseAccount.Fields().ByName("coins") @@ -584,7 +584,7 @@ func (x *MorseAccount) ProtoReflect() protoreflect.Message { } func (x *MorseAccount) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_types_proto_msgTypes[1] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1154,8 +1154,8 @@ var ( ) func init() { - file_poktroll_migration_types_proto_init() - md_MorsePublicKey = File_poktroll_migration_types_proto.Messages().ByName("MorsePublicKey") + file_poktroll_migration_morse_onchain_proto_init() + md_MorsePublicKey = File_poktroll_migration_morse_onchain_proto.Messages().ByName("MorsePublicKey") fd_MorsePublicKey_value = md_MorsePublicKey.Fields().ByName("value") } @@ -1168,7 +1168,7 @@ func (x *MorsePublicKey) ProtoReflect() protoreflect.Message { } func (x *MorsePublicKey) slowProtoReflect() protoreflect.Message { - mi := &file_poktroll_migration_types_proto_msgTypes[2] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1574,7 +1574,7 @@ func (x *fastReflection_MorsePublicKey) ProtoMethods() *protoiface.Methods { // versions: // protoc-gen-go v1.27.0 // protoc (unknown) -// source: poktroll/migration/types.proto +// source: poktroll/migration/morse_onchain.proto const ( // Verify that this generated code is sufficiently up-to-date. @@ -1595,7 +1595,7 @@ type MorseAccountState struct { func (x *MorseAccountState) Reset() { *x = MorseAccountState{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_types_proto_msgTypes[0] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1609,7 +1609,7 @@ func (*MorseAccountState) ProtoMessage() {} // Deprecated: Use MorseAccountState.ProtoReflect.Descriptor instead. func (*MorseAccountState) Descriptor() ([]byte, []int) { - return file_poktroll_migration_types_proto_rawDescGZIP(), []int{0} + return file_poktroll_migration_morse_onchain_proto_rawDescGZIP(), []int{0} } func (x *MorseAccountState) GetAccounts() []*MorseAccount { @@ -1619,14 +1619,16 @@ func (x *MorseAccountState) GetAccounts() []*MorseAccount { return nil } -// MorseAccount is an analog of the Morse ProtoBaseAccount type. It encapsulates -// the minimum information required to import accounts. +// MorseAccount is an analog of the Morse ProtoBaseAccount type. +// It encapsulates the minimum information required to import accounts. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/auth/auth.proto#L14. type MorseAccount struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields + // A binary representation of the address corresponding to a Morse application's ed25519 public key. Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` PubKey *MorsePublicKey `protobuf:"bytes,2,opt,name=pub_key,json=pubKey,proto3" json:"pub_key,omitempty"` Coins []*v1beta1.Coin `protobuf:"bytes,3,rep,name=coins,proto3" json:"coins,omitempty"` @@ -1635,7 +1637,7 @@ type MorseAccount struct { func (x *MorseAccount) Reset() { *x = MorseAccount{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_types_proto_msgTypes[1] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1649,7 +1651,7 @@ func (*MorseAccount) ProtoMessage() {} // Deprecated: Use MorseAccount.ProtoReflect.Descriptor instead. func (*MorseAccount) Descriptor() ([]byte, []int) { - return file_poktroll_migration_types_proto_rawDescGZIP(), []int{1} + return file_poktroll_migration_morse_onchain_proto_rawDescGZIP(), []int{1} } func (x *MorseAccount) GetAddress() []byte { @@ -1686,7 +1688,7 @@ type MorsePublicKey struct { func (x *MorsePublicKey) Reset() { *x = MorsePublicKey{} if protoimpl.UnsafeEnabled { - mi := &file_poktroll_migration_types_proto_msgTypes[2] + mi := &file_poktroll_migration_morse_onchain_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1700,7 +1702,7 @@ func (*MorsePublicKey) ProtoMessage() {} // Deprecated: Use MorsePublicKey.ProtoReflect.Descriptor instead. func (*MorsePublicKey) Descriptor() ([]byte, []int) { - return file_poktroll_migration_types_proto_rawDescGZIP(), []int{2} + return file_poktroll_migration_morse_onchain_proto_rawDescGZIP(), []int{2} } func (x *MorsePublicKey) GetValue() []byte { @@ -1710,80 +1712,81 @@ func (x *MorsePublicKey) GetValue() []byte { return nil } -var File_poktroll_migration_types_proto protoreflect.FileDescriptor - -var file_poktroll_migration_types_proto_rawDesc = []byte{ - 0x0a, 0x1e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x12, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 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, - 0x1e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, - 0x65, 0x74, 0x61, 0x31, 0x2f, 0x63, 0x6f, 0x69, 0x6e, 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, 0x5f, 0x0a, 0x11, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x4a, 0x0a, 0x08, 0x61, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x70, - 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x0c, - 0xea, 0xde, 0x1f, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x52, 0x08, 0x61, 0x63, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x22, 0x9f, 0x02, 0x0a, 0x0c, 0x4d, 0x6f, 0x72, 0x73, 0x65, - 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x54, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, - 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x3a, 0xea, 0xde, 0x1f, 0x07, 0x61, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 0xfa, 0xde, 0x1f, 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, - 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x6f, 0x6d, - 0x65, 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x72, 0x79, 0x70, 0x74, 0x6f, 0x2e, 0x41, 0x64, 0x64, - 0x72, 0x65, 0x73, 0x73, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x60, 0x0a, - 0x07, 0x70, 0x75, 0x62, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, - 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, - 0x65, 0x79, 0x42, 0x23, 0xea, 0xde, 0x1f, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, - 0x65, 0x79, 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x75, 0x62, 0x6c, - 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x22, 0x52, 0x06, 0x70, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, - 0x3e, 0x0a, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, - 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, 0x6e, 0x42, 0x0d, 0xc8, 0xde, 0x1f, 0x00, 0xea, - 0xde, 0x1f, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, 0x52, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, 0x3a, - 0x17, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, 0x01, 0x88, 0xa2, 0x1f, 0x01, 0xca, 0xb4, 0x2d, - 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x44, 0x0a, 0x0e, 0x4d, 0x6f, 0x72, 0x73, - 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x32, 0x0a, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x1c, 0xfa, 0xde, 0x1f, 0x18, 0x63, - 0x72, 0x79, 0x70, 0x74, 0x6f, 0x2f, 0x65, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x2e, 0x50, 0x75, - 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0xb6, - 0x01, 0xd8, 0xe2, 0x1e, 0x01, 0x0a, 0x16, 0x63, 0x6f, 0x6d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, - 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x0a, 0x54, - 0x79, 0x70, 0x65, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x23, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6f, - 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0xa2, 0x02, 0x03, 0x50, 0x4d, 0x58, 0xaa, 0x02, 0x12, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, - 0x6c, 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xca, 0x02, 0x12, 0x50, 0x6f, - 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0xe2, 0x02, 0x1e, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, - 0x61, 0xea, 0x02, 0x13, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x3a, 0x3a, 0x4d, 0x69, - 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, +var File_poktroll_migration_morse_onchain_proto protoreflect.FileDescriptor + +var file_poktroll_migration_morse_onchain_proto_rawDesc = []byte{ + 0x0a, 0x26, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x6d, 0x6f, 0x72, 0x73, 0x65, 0x5f, 0x6f, 0x6e, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, + 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 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, 0x1e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, + 0x62, 0x61, 0x73, 0x65, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2f, 0x63, 0x6f, 0x69, + 0x6e, 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, 0x5f, 0x0a, + 0x11, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x53, 0x74, 0x61, + 0x74, 0x65, 0x12, 0x4a, 0x0a, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, + 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x0c, 0xea, 0xde, 0x1f, 0x08, 0x61, 0x63, 0x63, 0x6f, + 0x75, 0x6e, 0x74, 0x73, 0x52, 0x08, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x22, 0x9f, + 0x02, 0x0a, 0x0c, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x54, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, + 0x42, 0x3a, 0xea, 0xde, 0x1f, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0xfa, 0xde, 0x1f, + 0x2b, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x6d, 0x65, + 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x6f, 0x6d, 0x65, 0x74, 0x62, 0x66, 0x74, 0x2f, 0x63, 0x72, + 0x79, 0x70, 0x74, 0x6f, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x52, 0x07, 0x61, 0x64, + 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x60, 0x0a, 0x07, 0x70, 0x75, 0x62, 0x5f, 0x6b, 0x65, 0x79, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, + 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x6f, 0x72, 0x73, + 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x42, 0x23, 0xea, 0xde, 0x1f, 0x0a, + 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0xf2, 0xde, 0x1f, 0x11, 0x79, 0x61, + 0x6d, 0x6c, 0x3a, 0x22, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x22, 0x52, + 0x06, 0x70, 0x75, 0x62, 0x4b, 0x65, 0x79, 0x12, 0x3e, 0x0a, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, + 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, + 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x43, 0x6f, 0x69, + 0x6e, 0x42, 0x0d, 0xc8, 0xde, 0x1f, 0x00, 0xea, 0xde, 0x1f, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, + 0x52, 0x05, 0x63, 0x6f, 0x69, 0x6e, 0x73, 0x3a, 0x17, 0x88, 0xa0, 0x1f, 0x00, 0x98, 0xa0, 0x1f, + 0x01, 0x88, 0xa2, 0x1f, 0x01, 0xca, 0xb4, 0x2d, 0x07, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x22, 0x44, 0x0a, 0x0e, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, + 0x65, 0x79, 0x12, 0x32, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0c, 0x42, 0x1c, 0xfa, 0xde, 0x1f, 0x18, 0x63, 0x72, 0x79, 0x70, 0x74, 0x6f, 0x2f, 0x65, 0x64, + 0x32, 0x35, 0x35, 0x31, 0x39, 0x2e, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x52, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x42, 0xbd, 0x01, 0xd8, 0xe2, 0x1e, 0x01, 0x0a, 0x16, 0x63, + 0x6f, 0x6d, 0x2e, 0x70, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2e, 0x6d, 0x69, 0x67, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x11, 0x4d, 0x6f, 0x72, 0x73, 0x65, 0x4f, 0x6e, 0x63, 0x68, + 0x61, 0x69, 0x6e, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x23, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x70, 0x6f, 0x6b, + 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x2f, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xa2, + 0x02, 0x03, 0x50, 0x4d, 0x58, 0xaa, 0x02, 0x12, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, + 0x2e, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xca, 0x02, 0x12, 0x50, 0x6f, 0x6b, + 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0xe2, + 0x02, 0x1e, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x5c, 0x4d, 0x69, 0x67, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x13, 0x50, 0x6f, 0x6b, 0x74, 0x72, 0x6f, 0x6c, 0x6c, 0x3a, 0x3a, 0x4d, 0x69, 0x67, + 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( - file_poktroll_migration_types_proto_rawDescOnce sync.Once - file_poktroll_migration_types_proto_rawDescData = file_poktroll_migration_types_proto_rawDesc + file_poktroll_migration_morse_onchain_proto_rawDescOnce sync.Once + file_poktroll_migration_morse_onchain_proto_rawDescData = file_poktroll_migration_morse_onchain_proto_rawDesc ) -func file_poktroll_migration_types_proto_rawDescGZIP() []byte { - file_poktroll_migration_types_proto_rawDescOnce.Do(func() { - file_poktroll_migration_types_proto_rawDescData = protoimpl.X.CompressGZIP(file_poktroll_migration_types_proto_rawDescData) +func file_poktroll_migration_morse_onchain_proto_rawDescGZIP() []byte { + file_poktroll_migration_morse_onchain_proto_rawDescOnce.Do(func() { + file_poktroll_migration_morse_onchain_proto_rawDescData = protoimpl.X.CompressGZIP(file_poktroll_migration_morse_onchain_proto_rawDescData) }) - return file_poktroll_migration_types_proto_rawDescData + return file_poktroll_migration_morse_onchain_proto_rawDescData } -var file_poktroll_migration_types_proto_msgTypes = make([]protoimpl.MessageInfo, 3) -var file_poktroll_migration_types_proto_goTypes = []interface{}{ +var file_poktroll_migration_morse_onchain_proto_msgTypes = make([]protoimpl.MessageInfo, 3) +var file_poktroll_migration_morse_onchain_proto_goTypes = []interface{}{ (*MorseAccountState)(nil), // 0: poktroll.migration.MorseAccountState (*MorseAccount)(nil), // 1: poktroll.migration.MorseAccount (*MorsePublicKey)(nil), // 2: poktroll.migration.MorsePublicKey (*v1beta1.Coin)(nil), // 3: cosmos.base.v1beta1.Coin } -var file_poktroll_migration_types_proto_depIdxs = []int32{ +var file_poktroll_migration_morse_onchain_proto_depIdxs = []int32{ 1, // 0: poktroll.migration.MorseAccountState.accounts:type_name -> poktroll.migration.MorseAccount 2, // 1: poktroll.migration.MorseAccount.pub_key:type_name -> poktroll.migration.MorsePublicKey 3, // 2: poktroll.migration.MorseAccount.coins:type_name -> cosmos.base.v1beta1.Coin @@ -1794,13 +1797,13 @@ var file_poktroll_migration_types_proto_depIdxs = []int32{ 0, // [0:3] is the sub-list for field type_name } -func init() { file_poktroll_migration_types_proto_init() } -func file_poktroll_migration_types_proto_init() { - if File_poktroll_migration_types_proto != nil { +func init() { file_poktroll_migration_morse_onchain_proto_init() } +func file_poktroll_migration_morse_onchain_proto_init() { + if File_poktroll_migration_morse_onchain_proto != nil { return } if !protoimpl.UnsafeEnabled { - file_poktroll_migration_types_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_onchain_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseAccountState); i { case 0: return &v.state @@ -1812,7 +1815,7 @@ func file_poktroll_migration_types_proto_init() { return nil } } - file_poktroll_migration_types_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_onchain_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorseAccount); i { case 0: return &v.state @@ -1824,7 +1827,7 @@ func file_poktroll_migration_types_proto_init() { return nil } } - file_poktroll_migration_types_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + file_poktroll_migration_morse_onchain_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MorsePublicKey); i { case 0: return &v.state @@ -1841,18 +1844,18 @@ func file_poktroll_migration_types_proto_init() { out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_poktroll_migration_types_proto_rawDesc, + RawDescriptor: file_poktroll_migration_morse_onchain_proto_rawDesc, NumEnums: 0, NumMessages: 3, NumExtensions: 0, NumServices: 0, }, - GoTypes: file_poktroll_migration_types_proto_goTypes, - DependencyIndexes: file_poktroll_migration_types_proto_depIdxs, - MessageInfos: file_poktroll_migration_types_proto_msgTypes, + GoTypes: file_poktroll_migration_morse_onchain_proto_goTypes, + DependencyIndexes: file_poktroll_migration_morse_onchain_proto_depIdxs, + MessageInfos: file_poktroll_migration_morse_onchain_proto_msgTypes, }.Build() - File_poktroll_migration_types_proto = out.File - file_poktroll_migration_types_proto_rawDesc = nil - file_poktroll_migration_types_proto_goTypes = nil - file_poktroll_migration_types_proto_depIdxs = nil + File_poktroll_migration_morse_onchain_proto = out.File + file_poktroll_migration_morse_onchain_proto_rawDesc = nil + file_poktroll_migration_morse_onchain_proto_goTypes = nil + file_poktroll_migration_morse_onchain_proto_depIdxs = nil } diff --git a/cmd/poktrolld/cmd/migrate/migrate.go b/cmd/poktrolld/cmd/migrate/migrate.go index 0109383e7..0587678ad 100644 --- a/cmd/poktrolld/cmd/migrate/migrate.go +++ b/cmd/poktrolld/cmd/migrate/migrate.go @@ -23,6 +23,11 @@ var ( flagLogOutput string logger polylog.Logger + // DEV_NOTE: AutoCLI does not apply here because there is no gRPC service, + // message, or query. The purpose of this command is to facilitate the + // deterministic (i.e. reproducible) transformation from the Morse export + // data structure (MorseStateExport) into the Shannon import data structure + // (MorseAccountState). It does not interact with the network directly. collectMorseAccountsCmd = &cobra.Command{ Use: "collect-morse-accounts [morse-state-export-path] [morse-account-state-path]", Args: cobra.ExactArgs(2), @@ -145,6 +150,10 @@ func validatePathIsFile(path string) error { // transformMorseState consolidates the Morse account balance, application stake, // and supplier stake for each account as an entry in the resulting MorseAccountState. +// NOTE: In Shannon terms, "supplier" is equivalent to the following in Morse terms: +// - "validator" +// - "node" +// - "servicer" func transformMorseState( inputState *migrationtypes.MorseStateExport, morseWorkspace *morseImportWorkspace, @@ -185,7 +194,7 @@ func collectInputAccountBalances(inputState *migrationtypes.MorseStateExport, mo } accountAddr := exportAccount.Value.Address.String() - if _, _, err := morseWorkspace.ensureAccount(accountAddr, exportAccount); err != nil { + if _, _, err := morseWorkspace.addAccount(accountAddr, exportAccount); err != nil { return err } @@ -251,7 +260,7 @@ func collectInputApplicationStakes(inputState *migrationtypes.MorseStateExport, ) } - morseWorkspace.lastAccTotalAppStake = morseWorkspace.lastAccTotalAppStake.Add(appStakeAmtUpokt) + morseWorkspace.accumulatedTotalAppStake = morseWorkspace.accumulatedTotalAppStake.Add(appStakeAmtUpokt) } return nil } @@ -279,7 +288,7 @@ func collectInputSupplierStakes(inputState *migrationtypes.MorseStateExport, mor ) } - morseWorkspace.lastAccTotalSupplierStake = morseWorkspace.lastAccTotalSupplierStake.Add(supplierStakeAmtUpokt) + morseWorkspace.accumulatedTotalSupplierStake = morseWorkspace.accumulatedTotalSupplierStake.Add(supplierStakeAmtUpokt) } return nil } diff --git a/cmd/poktrolld/cmd/migrate/migrate_test.go b/cmd/poktrolld/cmd/migrate/migrate_test.go index 27c453ac8..5b2aa5696 100644 --- a/cmd/poktrolld/cmd/migrate/migrate_test.go +++ b/cmd/poktrolld/cmd/migrate/migrate_test.go @@ -107,7 +107,7 @@ func newMorseStateExportAndAccountState( ) (morseStateExportBz []byte, morseAccountStateBz []byte) { morseStateExport := &migrationtypes.MorseStateExport{ AppHash: "", - AppState: &migrationtypes.MorseAppState{ + AppState: &migrationtypes.MorseTendermintAppState{ Application: &migrationtypes.MorseApplications{}, Auth: &migrationtypes.MorseAuth{}, Pos: &migrationtypes.MorsePos{}, diff --git a/cmd/poktrolld/cmd/migrate/types.go b/cmd/poktrolld/cmd/migrate/types.go index 6951f22ef..bd8e4c95f 100644 --- a/cmd/poktrolld/cmd/migrate/types.go +++ b/cmd/poktrolld/cmd/migrate/types.go @@ -17,9 +17,9 @@ func newMorseImportWorkspace() *morseImportWorkspace { accountState: &migrationtypes.MorseAccountState{ Accounts: make([]*migrationtypes.MorseAccount, 0), }, - lastAccTotalBalance: cosmosmath.ZeroInt(), - lastAccTotalAppStake: cosmosmath.ZeroInt(), - lastAccTotalSupplierStake: cosmosmath.ZeroInt(), + accumulatedTotalBalance: cosmosmath.ZeroInt(), + accumulatedTotalAppStake: cosmosmath.ZeroInt(), + accumulatedTotalSupplierStake: cosmosmath.ZeroInt(), } } @@ -34,16 +34,15 @@ type morseImportWorkspace struct { // the input MorseStateExport into the output MorseAccountState. accountState *migrationtypes.MorseAccountState - // lastAccTotalBalance is the most recently accumulated balances of all Morse + // accumulatedTotalBalance is the most recently accumulated balances of all Morse // accounts which have been processed. - lastAccTotalBalance cosmosmath.Int - // lastAccTotalAppStake is the most recently accumulated application stakes of + accumulatedTotalBalance cosmosmath.Int + // accumulatedTotalAppStake is the most recently accumulated application stakes of // all Morse accounts which have been processed. - lastAccTotalAppStake cosmosmath.Int - // lastAccTotalSupplierStake is the most recently accumulated supplier stakes of + accumulatedTotalAppStake cosmosmath.Int + // accumulatedTotalSupplierStake is the most recently accumulated supplier stakes of // all Morse accounts which have been processed. - lastAccTotalSupplierStake cosmosmath.Int - + accumulatedTotalSupplierStake cosmosmath.Int // numAccounts is the number of accounts that have been processed. numAccounts uint64 // numApplications is the number of applications that have been processed. @@ -71,10 +70,10 @@ func (miw *morseImportWorkspace) debugLogProgress(accountIdx int) { Uint64("num_accounts", miw.numAccounts). Uint64("num_applications", miw.numApplications). Uint64("num_suppliers", miw.numSuppliers). - Str("total_balance", miw.lastAccTotalBalance.String()). - Str("total_app_stake", miw.lastAccTotalAppStake.String()). - Str("total_supplier_stake", miw.lastAccTotalSupplierStake.String()). - Str("grand_total", miw.lastAccGrandTotal().String()). + Str("total_balance", miw.accumulatedTotalBalance.String()). + Str("total_app_stake", miw.accumulatedTotalAppStake.String()). + Str("total_supplier_stake", miw.accumulatedTotalSupplierStake.String()). + Str("grand_total", miw.accumulatedTotalsSum().String()). Msg("processing accounts...") } @@ -89,27 +88,27 @@ func (miw *morseImportWorkspace) infoLogComplete() error { Uint64("num_accounts", miw.numAccounts). Uint64("num_applications", miw.numApplications). Uint64("num_suppliers", miw.numSuppliers). - Str("total_balance", miw.lastAccTotalBalance.String()). - Str("total_app_stake", miw.lastAccTotalAppStake.String()). - Str("total_supplier_stake", miw.lastAccTotalSupplierStake.String()). - Str("grand_total", miw.lastAccGrandTotal().String()). + Str("total_balance", miw.accumulatedTotalBalance.String()). + Str("total_app_stake", miw.accumulatedTotalAppStake.String()). + Str("total_supplier_stake", miw.accumulatedTotalSupplierStake.String()). + Str("grand_total", miw.accumulatedTotalsSum().String()). Str("morse_account_state_hash", fmt.Sprintf("%x", accountStateHash)). Msg("processing accounts complete") return nil } -// lastAccGrandTotal returns the sum of the lastAccTotalBalance, lastAccTotalAppStake, -// and lastAccTotalSupplierStake. -func (miw *morseImportWorkspace) lastAccGrandTotal() cosmosmath.Int { - return miw.lastAccTotalBalance. - Add(miw.lastAccTotalAppStake). - Add(miw.lastAccTotalSupplierStake) +// accumulatedTotalsSum returns the sum of the accumulatedTotalBalance, +// accumulatedTotalAppStake, and accumulatedTotalSupplierStake. +func (miw *morseImportWorkspace) accumulatedTotalsSum() cosmosmath.Int { + return miw.accumulatedTotalBalance. + Add(miw.accumulatedTotalAppStake). + Add(miw.accumulatedTotalSupplierStake) } -// ensureAccount ensures that the given address is present in the accounts slice -// and that its corresponding address is in the addressToIdx map. If the address -// is not present, it is added to the accounts slice and the addressToIdx map. -func (miw *morseImportWorkspace) ensureAccount( +// addAccount adds the account with the given address to the accounts slice and +// its corresponding address is in the addressToIdx map. +// If the address is already present, an error is returned. +func (miw *morseImportWorkspace) addAccount( addr string, exportAccount *migrationtypes.MorseAuthAccount, ) (accountIdx uint64, balance cosmostypes.Coin, err error) { @@ -118,15 +117,9 @@ func (miw *morseImportWorkspace) ensureAccount( var ok bool if accountIdx, ok = miw.addressToIdx[addr]; ok { - logger.Warn().Str("address", addr).Msg("unexpected workspace state: account already exists") - - importAccount := miw.accountState.Accounts[accountIdx] - // Each account should have EXACTLY one token denomination. - if len(importAccount.Coins) != 1 { - err := ErrMorseStateTransform.Wrapf("account %q has multiple token denominations: %s", addr, importAccount.Coins) - return 0, cosmostypes.Coin{}, err - } - balance = importAccount.Coins[0] + return 0, cosmostypes.Coin{}, ErrMorseStateTransform.Wrapf( + "unexpected workspace state: account already exists (%s)", addr, + ) } else { accountIdx = miw.nextIdx() importAccount := &migrationtypes.MorseAccount{ diff --git a/docusaurus/docs/operate/morse_migration/_category_.json b/docusaurus/docs/operate/morse_migration/_category_.json new file mode 100644 index 000000000..d4757bcde --- /dev/null +++ b/docusaurus/docs/operate/morse_migration/_category_.json @@ -0,0 +1,8 @@ +{ + "label": "Morse -> Shannon Migration", + "position": 4, + "link": { + "type": "generated-index", + "description": "Morse to Shannon network migration documentation" + } +} diff --git a/docusaurus/docs/operate/morse_migration/morse-migration.md b/docusaurus/docs/operate/morse_migration/morse-migration.md new file mode 100644 index 000000000..57d5e838e --- /dev/null +++ b/docusaurus/docs/operate/morse_migration/morse-migration.md @@ -0,0 +1,245 @@ +--- +title: Diagrams +sidebar_position: 1 +--- + +// TODO_UPNEXT(@bryanchriswhite#1034): Expand migration docs and re-organize this page. + +## Complete E2E User Sequence + +```mermaid +sequenceDiagram +autonumber +actor A as Authority (Foundation) +actor MA as Morse Account Holders +participant MN as Morse Network +participant SN as Shannon Network + +loop (Re-)Generate morse_account_state.json + + A ->>+ MN: $ pocket util export-geneis-for-reset + MN ->>- A: return morse_state_export.json + + A ->> A: $ poktrolld migrate collect-morse-accounts + note over A: morse_account_state.json generated + + A ->>+ MA: distribute for verification
morse_account_state.json + + opt Morse Stakeholders optionally do local verification + MA ->>+ MN: $ pocket util export-geneis-for-reset + MN ->>- MA: return for local verification
morse_state_export.json + + MA ->> MA: $ poktrolld migrate collect-morse-accounts + note over MA: morse_account_state.json generated + MA ->> MA: manual comparison of
morse_account_state.json hashes + + MA ->>- A: ** (off-chain feedback) ** + end + +end + +A ->>+ SN: upload morse state
(MsgCreateMorseAccountState) +SN ->> SN: verify morse_account_state_hash field +SN -->- A: + +MA ->> SN: $ poktrolld migration claim-morse-pokt
claim morse POKT
(MsgClaimMorsePOKT): +``` + +## Onchain Actors & Messages + +```mermaid +flowchart +m1[MsgCreateMorseAccountClaim]:::account +m2[MsgCreateMorseSupplierClaim]:::supplier +m3[MsgCreateMorseApplicationClaim]:::application +m4[MsgCreateMorseGatewayClaim]:::gateway + +subgraph MigrationKeeper +h1([CreateMorseAccountClaim]):::account +h2([CreateMorseSupplierClaim]):::supplier +h3([CreateMorseApplicationClaim]):::application +h4([CreateMorseGatewayClaim]):::gateway +%% ms[[MorseAccountState]] +ac[[MorseAccountClaims]]:::general +end + +h1 --"Morse Account Claim Creation
(ensure not previously claimed)"--> ac +h2 --"Morse Account Claim Creation
(ensure not previously claimed)"--> ac +h3 --"Morse Account Claim Creation
(ensure not previously claimed)"--> ac +h4 --"Morse Account Claim Creation
(ensure not previously claimed)"--> ac + +%% h1 --"ensure claim is valid"--> ms +%% h2 --"ensure claim is valid"--> ms +%% h3 --"ensure claim is valid"--> ms +%% h4 --"ensure claim is valid"--> ms + +m1 --> h1 +m2 --> h2 +m3 --> h3 +m4 --> h4 + +subgraph BankKeeper +bk1[[Balances]]:::general +end + +subgraph SupplierKeeper +sk1[["Suppliers"]]:::supplier +end + +subgraph ApplicationKeeper +ak1[["Applications"]]:::application +end + +subgraph GatewayKeeper +gk1[["Gateways"]]:::gateway +end + +h1 --"Mint Balance"----> bk1 +h2 --"Mint Supplier Stake &
Non-staked Balance"--> bk1 +h2 --"Stake Supplier"---> sk1 +h3 --"Mint Application Stake &
Non-staked Balance"--> bk1 +h3 --"Stake Application"---> ak1 +h4 --"Mint Gateway Stake &
Non-staked Balance"--> bk1 +h4 --"Stake Gateway"---> gk1 + +classDef account fill:#90EE90,color:#000 +classDef supplier fill:#FFA500,color:#000 +classDef application fill:#FFB6C6,color:#000 +classDef gateway fill:#FF0000,color:#000 +classDef general fill:#87CEEB,color:#000 +``` + +## Data Structures + +```mermaid +--- +title: MorseStateExport --> MorseAccountState Transform +--- + +flowchart + +subgraph OffC[Off-Chain] + MorseStateExport --> MorseAppState + MorseAppState --> MorseApplications + MorseAppState --> MorseAuth + MorseAppState --> MorsePos + MorseApplications --> MorseApplication + MorseAuth --> MorseAuthAccount + MorseAuthAccount --> MAOff[MorseAccount] + MorsePos --> MorseValidator +end + + +subgraph OnC[On-Chain] + MorseAccountState + MorseAccountState --> MAOn + MAOn[MorseAccount] +end + +MAOff -.add exported account balance..-> MAOn +MorseValidator -.add exported stake to account balance.-> MAOn +MorseApplication -.add exported stake to account balance.-> MAOn +``` + +```mermaid +--- +title: MorseStateExport Structure(s) +--- + +classDiagram + +class MorseStateExport { + app_hash: string + app_state: MorseAppState +} +MorseStateExport --* MorseAppState + +class MorseAppState { + application: MorseApplications + auth: MorseAuth + pos: MorsePos +} +MorseAppState --* MorseApplications +MorseAppState --* MorseAuth +MorseAppState --* MorsePos + +class MorseApplications { + applications: []MorseApplication +} + +class MorseAuth { + accounts: []MorseAuthAccount +} +MorseAuth --* MorseAuthAccount + +class MorseAuthAccount { + type: string + value: MorseAccount +} +MorseAuthAccount --* MorseAccount + +class MorsePos { + validators: []MorseValidator +} +MorsePos --* MorseValidator + +class MorseValidator { + address: bytes + public_key: bytes + jailed: bool + status: int32 + staked_tokens: string +} + +class MorseApplication { + address: bytes + public_key: bytes + jailed: bool + status: int32 + staked_tokens: string +} +MorseApplications --* MorseApplication + +class MorseAccount { + address: string + pub_key: MorsePublicKey + coins: []cosmostypes.Coin +} +MorseAccount --* MorsePublicKey + +class MorsePublicKey { + value crypto/ed25519.PublicKey +} +``` + +```mermaid +--- +title: MsgCreateMorseAccountState Structure(s) +--- + +classDiagram + +class MsgCreateMorseAccountState { + authority: string + morse_account_state: MorseAccountState + morse_account_state_hash: bytes +} +MsgCreateMorseAccountState --* MorseAccountState + +class MorseAccountState { + accounts: []MorseAccount + GetHash(): []bytes +} +MorseAccountState --* MorseAccount + +class MorseAccount { + address: string + pub_key: MorsePublicKey + coins: []cosmostypes.Coin +} +MorseAccount --* MorsePublicKey + +class MorsePublicKey { + value crypto/ed25519.PublicKey +} +``` \ No newline at end of file diff --git a/docusaurus/docs/operate/networks/_category_.json b/docusaurus/docs/operate/networks/_category_.json index 978afd7cc..a04271fc1 100644 --- a/docusaurus/docs/operate/networks/_category_.json +++ b/docusaurus/docs/operate/networks/_category_.json @@ -1,6 +1,6 @@ { "label": "Networks", - "position": 4, + "position": 5, "link": { "type": "generated-index", "description": "Documentation on Poktroll Networks." diff --git a/docusaurus/docs/operate/user_guide/create-new-wallet.md b/docusaurus/docs/operate/user_guide/create-new-wallet.md index d5444dce7..140929994 100644 --- a/docusaurus/docs/operate/user_guide/create-new-wallet.md +++ b/docusaurus/docs/operate/user_guide/create-new-wallet.md @@ -1,6 +1,6 @@ --- title: Create a New Wallet -sidebar_position: 1 +sidebar_position: 2 --- # Create a New Wallet diff --git a/docusaurus/yarn.lock b/docusaurus/yarn.lock index b40707ca6..edfa5129b 100644 --- a/docusaurus/yarn.lock +++ b/docusaurus/yarn.lock @@ -1810,10 +1810,15 @@ dependencies: "@types/mdx" "^2.0.0" -"@node-rs/jieba-darwin-arm64@1.10.0": +"@node-rs/jieba-linux-x64-gnu@1.10.0": version "1.10.0" - resolved "https://registry.npmjs.org/@node-rs/jieba-darwin-arm64/-/jieba-darwin-arm64-1.10.0.tgz" - integrity sha512-IhR5r+XxFcfhVsF93zQ3uCJy8ndotRntXzoW/JCyKqOahUo/ITQRT6vTKHKMyD9xNmjl222OZonBSo2+mlI2fQ== + resolved "https://registry.npmjs.org/@node-rs/jieba-linux-x64-gnu/-/jieba-linux-x64-gnu-1.10.0.tgz" + integrity sha512-rS5Shs8JITxJjFIjoIZ5a9O+GO21TJgKu03g2qwFE3QaN5ZOvXtz+/AqqyfT4GmmMhCujD83AGqfOGXDmItF9w== + +"@node-rs/jieba-linux-x64-musl@1.10.0": + version "1.10.0" + resolved "https://registry.npmjs.org/@node-rs/jieba-linux-x64-musl/-/jieba-linux-x64-musl-1.10.0.tgz" + integrity sha512-BvSiF2rR8Birh2oEVHcYwq0WGC1cegkEdddWsPrrSmpKmukJE2zyjcxaOOggq2apb8fIRsjyeeUh6X3R5AgjvA== "@node-rs/jieba@^1.6.0": version "1.10.0" @@ -4614,11 +4619,6 @@ fs.realpath@^1.0.0: resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== -fsevents@~2.3.2: - version "2.3.3" - resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz" - integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== - function-bind@^1.1.2: version "1.1.2" resolved "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz" diff --git a/proto/poktroll/migration/legacy.proto b/proto/poktroll/migration/morse_offchain.proto similarity index 72% rename from proto/poktroll/migration/legacy.proto rename to proto/poktroll/migration/morse_offchain.proto index 2e9231c13..0f2753534 100644 --- a/proto/poktroll/migration/legacy.proto +++ b/proto/poktroll/migration/morse_offchain.proto @@ -3,43 +3,65 @@ syntax = "proto3"; // Types in this file are ONLY present to facilitate the verifiability of the // migration state from Morse to Shannon. // +// These types reproduce a 1:1 de/serialization for the corresponding Morse data structures +// but are not completely identical to their Morse counterparts, not all of which are defined +// as protobuf types in the Morse codebase. +// +// Morse also leverages pb.Any types, as well as the gogoproto.casttype option in several places. +// All usages of pb.Any have been replaced with equivalent protobuf types +// (i.e. an interstitial type with `type` and/or `value` field(s)). +// All usages of gogoproto.casttype which previously referenced Morse data structures have been removed. +// A few specific fields have retained this option where the type is changed to the underlying +// external lib type that the Morse type was wrapping (e.g. address and public key fields). +// // These types are used by the migration subcommand to transform // the Morse state export into the Shannon state import. // Ref: `poktrolld migrate collect-morse-accounts ...` // -// They ARE NOT persisted on-chain at any point. +// They ARE NOT persisted on-chain (Shannon) at any point. package poktroll.migration; import "gogoproto/gogo.proto"; -import "poktroll/migration/types.proto"; +import "poktroll/migration/morse_onchain.proto"; option go_package = "github.com/pokt-network/poktroll/x/migration/types"; option (gogoproto.stable_marshaler_all) = true; // MorseStateExport is the data structure that is serialized and output when running // `pocket utils export-genesis-for-reset`. +// // See: https://editor.swagger.io/?url=https://raw.githubusercontent.com/pokt-network/pocket-core/staging/doc/specs/rpc-spec.yaml#operations-query-post_query_state message MorseStateExport { // app_hash is the Morse tendermint state hash. string app_hash = 1 [(gogoproto.jsontag) = "app_hash"]; + // app_state is the entire Morse tendermint application state. - MorseAppState app_state = 2 [(gogoproto.jsontag) = "app_state"]; + MorseTendermintAppState app_state = 2 [(gogoproto.jsontag) = "app_state"]; } -// MorseAppState is the tendermint application state for the Morse tendermint +// MorseTendermintAppState is the tendermint application state for the Morse tendermint // application; not to be confused with the pokt protocol actor. -message MorseAppState { +// It is constructed in Morse via `PocketCoreApp#ExportAppState()`. +// +// See: https://github.com/pokt-network/pocket-core/blob/5fa61920aa9d45ca6bf9e01e863134e242c95fa7/app/pocket.go#L142 +message MorseTendermintAppState { MorseApplications application = 1 [(gogoproto.jsontag) = "application"]; MorseAuth auth = 2 [(gogoproto.jsontag) = "auth"]; MorsePos pos = 3 [(gogoproto.jsontag) = "pos"]; } // A wrapper around the list of MorseApplications, necessary in order to conform to the Morse genesis structure. +// It encapsulates the minimum information required to import Morse applications. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/apps/types/genesis.go#L4 message MorseApplications { repeated MorseApplication applications = 1 [(gogoproto.jsontag) = "applications"]; } // A wrapper around a list of Morse accounts. +// It encapsulates the minimum information required to import Morse accounts. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/auth/types/genesis.go#L9 message MorseAuth { repeated MorseAuthAccount accounts = 1 [(gogoproto.jsontag) = "accounts"]; } @@ -55,12 +77,15 @@ message MorseAuthAccount { // A wrapper around the list of Morse suppliers (aka "validators", "nodes", of "servicers"). // It is necessary to conform to the Morse genesis structure. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/nodes/types/genesis.go#L8 message MorsePos { repeated MorseValidator validators = 1 [(gogoproto.jsontag) = "validators"]; } // MorseApplication is a subset of the Morse ProtoApplication type. // It encapsulates the minimum information required to import Morse applications. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/apps/apps.proto#L16 message MorseApplication { option (gogoproto.equal) = true; @@ -79,6 +104,7 @@ message MorseApplication { // MorseValidator is a subset of the Morse ProtoValidator type. // It encapsulates the minimum information required to import Morse suppliers (aka "servicers" or "validators"). +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/pos/types.proto#L16 message MorseValidator { option (gogoproto.equal) = true; diff --git a/proto/poktroll/migration/types.proto b/proto/poktroll/migration/morse_onchain.proto similarity index 89% rename from proto/poktroll/migration/types.proto rename to proto/poktroll/migration/morse_onchain.proto index 0b003e269..b0f8d408d 100644 --- a/proto/poktroll/migration/types.proto +++ b/proto/poktroll/migration/morse_onchain.proto @@ -14,8 +14,9 @@ message MorseAccountState { repeated MorseAccount accounts = 1 [(gogoproto.jsontag) = "accounts"]; } -// MorseAccount is an analog of the Morse ProtoBaseAccount type. It encapsulates -// the minimum information required to import accounts. +// MorseAccount is an analog of the Morse ProtoBaseAccount type. +// It encapsulates the minimum information required to import accounts. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/auth/auth.proto#L14. message MorseAccount { option (gogoproto.messagename) = true; @@ -23,6 +24,7 @@ message MorseAccount { option (gogoproto.goproto_stringer) = true; option (cosmos_proto.implements_interface) = "Account"; + // A binary representation of the address corresponding to a Morse application's ed25519 public key. bytes address = 1 [(gogoproto.jsontag) = "address", (gogoproto.casttype) = "github.com/cometbft/cometbft/crypto.Address"]; MorsePublicKey pub_key = 2 [(gogoproto.jsontag) = "public_key", (gogoproto.moretags) = "yaml:\"public_key\""]; repeated cosmos.base.v1beta1.Coin coins = 3 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "coins"]; diff --git a/x/migration/types/morse_account_state.go b/x/migration/types/morse_account_state.go index 8c4863217..1ca2a9770 100644 --- a/x/migration/types/morse_account_state.go +++ b/x/migration/types/morse_account_state.go @@ -9,11 +9,11 @@ import ( // GetHash calculates the sha256 hash of the MorseAccountState proto structure. // It is intended to be used to verify the integrity of the MorseAccountState by network actors offchain. func (m MorseAccountState) GetHash() ([]byte, error) { - accountStateBz, err := proto.Marshal(&m) + morseAccountStateBz, err := proto.Marshal(&m) if err != nil { return nil, err } - hash := sha256.Sum256(accountStateBz) + hash := sha256.Sum256(morseAccountStateBz) return hash[:], nil } diff --git a/x/migration/types/legacy.pb.go b/x/migration/types/morse_offchain.pb.go similarity index 75% rename from x/migration/types/legacy.pb.go rename to x/migration/types/morse_offchain.pb.go index b998ee9ce..141ef139c 100644 --- a/x/migration/types/legacy.pb.go +++ b/x/migration/types/morse_offchain.pb.go @@ -1,14 +1,25 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: poktroll/migration/legacy.proto +// source: poktroll/migration/morse_offchain.proto // Types in this file are ONLY present to facilitate the verifiability of the // migration state from Morse to Shannon. // +// These types reproduce a 1:1 de/serialization for the corresponding Morse data structures +// but are not completely identical to their Morse counterparts, not all of which are defined +// as protobuf types in the Morse codebase. +// +// Morse also leverages pb.Any types, as well as the gogoproto.casttype option in several places. +// All usages of pb.Any have been replaced with equivalent protobuf types +// (i.e. an interstitial type with `type` and/or `value` field(s)). +// All usages of gogoproto.casttype which previously referenced Morse data structures have been removed. +// A few specific fields have retained this option where the type is changed to the underlying +// external lib type that the Morse type was wrapping (e.g. address and public key fields). +// // These types are used by the migration subcommand to transform // the Morse state export into the Shannon state import. // Ref: `poktrolld migrate collect-morse-accounts ...` // -// They ARE NOT persisted on-chain at any point. +// They ARE NOT persisted on-chain (Shannon) at any point. package types @@ -36,19 +47,20 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // MorseStateExport is the data structure that is serialized and output when running // `pocket utils export-genesis-for-reset`. +// // See: https://editor.swagger.io/?url=https://raw.githubusercontent.com/pokt-network/pocket-core/staging/doc/specs/rpc-spec.yaml#operations-query-post_query_state type MorseStateExport struct { // app_hash is the Morse tendermint state hash. AppHash string `protobuf:"bytes,1,opt,name=app_hash,json=appHash,proto3" json:"app_hash"` // app_state is the entire Morse tendermint application state. - AppState *MorseAppState `protobuf:"bytes,2,opt,name=app_state,json=appState,proto3" json:"app_state"` + AppState *MorseTendermintAppState `protobuf:"bytes,2,opt,name=app_state,json=appState,proto3" json:"app_state"` } func (m *MorseStateExport) Reset() { *m = MorseStateExport{} } func (m *MorseStateExport) String() string { return proto.CompactTextString(m) } func (*MorseStateExport) ProtoMessage() {} func (*MorseStateExport) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{0} + return fileDescriptor_a3da515ab792a974, []int{0} } func (m *MorseStateExport) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -80,31 +92,34 @@ func (m *MorseStateExport) GetAppHash() string { return "" } -func (m *MorseStateExport) GetAppState() *MorseAppState { +func (m *MorseStateExport) GetAppState() *MorseTendermintAppState { if m != nil { return m.AppState } return nil } -// MorseAppState is the tendermint application state for the Morse tendermint +// MorseTendermintAppState is the tendermint application state for the Morse tendermint // application; not to be confused with the pokt protocol actor. -type MorseAppState struct { +// It is constructed in Morse via `PocketCoreApp#ExportAppState()`. +// +// See: https://github.com/pokt-network/pocket-core/blob/5fa61920aa9d45ca6bf9e01e863134e242c95fa7/app/pocket.go#L142 +type MorseTendermintAppState struct { Application *MorseApplications `protobuf:"bytes,1,opt,name=application,proto3" json:"application"` Auth *MorseAuth `protobuf:"bytes,2,opt,name=auth,proto3" json:"auth"` Pos *MorsePos `protobuf:"bytes,3,opt,name=pos,proto3" json:"pos"` } -func (m *MorseAppState) Reset() { *m = MorseAppState{} } -func (m *MorseAppState) String() string { return proto.CompactTextString(m) } -func (*MorseAppState) ProtoMessage() {} -func (*MorseAppState) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{1} +func (m *MorseTendermintAppState) Reset() { *m = MorseTendermintAppState{} } +func (m *MorseTendermintAppState) String() string { return proto.CompactTextString(m) } +func (*MorseTendermintAppState) ProtoMessage() {} +func (*MorseTendermintAppState) Descriptor() ([]byte, []int) { + return fileDescriptor_a3da515ab792a974, []int{1} } -func (m *MorseAppState) XXX_Unmarshal(b []byte) error { +func (m *MorseTendermintAppState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } -func (m *MorseAppState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { +func (m *MorseTendermintAppState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { @@ -112,33 +127,33 @@ func (m *MorseAppState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error } return b[:n], nil } -func (m *MorseAppState) XXX_Merge(src proto.Message) { - xxx_messageInfo_MorseAppState.Merge(m, src) +func (m *MorseTendermintAppState) XXX_Merge(src proto.Message) { + xxx_messageInfo_MorseTendermintAppState.Merge(m, src) } -func (m *MorseAppState) XXX_Size() int { +func (m *MorseTendermintAppState) XXX_Size() int { return m.Size() } -func (m *MorseAppState) XXX_DiscardUnknown() { - xxx_messageInfo_MorseAppState.DiscardUnknown(m) +func (m *MorseTendermintAppState) XXX_DiscardUnknown() { + xxx_messageInfo_MorseTendermintAppState.DiscardUnknown(m) } -var xxx_messageInfo_MorseAppState proto.InternalMessageInfo +var xxx_messageInfo_MorseTendermintAppState proto.InternalMessageInfo -func (m *MorseAppState) GetApplication() *MorseApplications { +func (m *MorseTendermintAppState) GetApplication() *MorseApplications { if m != nil { return m.Application } return nil } -func (m *MorseAppState) GetAuth() *MorseAuth { +func (m *MorseTendermintAppState) GetAuth() *MorseAuth { if m != nil { return m.Auth } return nil } -func (m *MorseAppState) GetPos() *MorsePos { +func (m *MorseTendermintAppState) GetPos() *MorsePos { if m != nil { return m.Pos } @@ -146,6 +161,9 @@ func (m *MorseAppState) GetPos() *MorsePos { } // A wrapper around the list of MorseApplications, necessary in order to conform to the Morse genesis structure. +// It encapsulates the minimum information required to import Morse applications. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/apps/types/genesis.go#L4 type MorseApplications struct { Applications []*MorseApplication `protobuf:"bytes,1,rep,name=applications,proto3" json:"applications"` } @@ -154,7 +172,7 @@ func (m *MorseApplications) Reset() { *m = MorseApplications{} } func (m *MorseApplications) String() string { return proto.CompactTextString(m) } func (*MorseApplications) ProtoMessage() {} func (*MorseApplications) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{2} + return fileDescriptor_a3da515ab792a974, []int{2} } func (m *MorseApplications) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -187,6 +205,9 @@ func (m *MorseApplications) GetApplications() []*MorseApplication { } // A wrapper around a list of Morse accounts. +// It encapsulates the minimum information required to import Morse accounts. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/auth/types/genesis.go#L9 type MorseAuth struct { Accounts []*MorseAuthAccount `protobuf:"bytes,1,rep,name=accounts,proto3" json:"accounts"` } @@ -195,7 +216,7 @@ func (m *MorseAuth) Reset() { *m = MorseAuth{} } func (m *MorseAuth) String() string { return proto.CompactTextString(m) } func (*MorseAuth) ProtoMessage() {} func (*MorseAuth) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{3} + return fileDescriptor_a3da515ab792a974, []int{3} } func (m *MorseAuth) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -242,7 +263,7 @@ func (m *MorseAuthAccount) Reset() { *m = MorseAuthAccount{} } func (m *MorseAuthAccount) String() string { return proto.CompactTextString(m) } func (*MorseAuthAccount) ProtoMessage() {} func (*MorseAuthAccount) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{4} + return fileDescriptor_a3da515ab792a974, []int{4} } func (m *MorseAuthAccount) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -283,6 +304,8 @@ func (m *MorseAuthAccount) GetValue() *MorseAccount { // A wrapper around the list of Morse suppliers (aka "validators", "nodes", of "servicers"). // It is necessary to conform to the Morse genesis structure. +// +// See: https://github.com/pokt-network/pocket-core/blob/staging/x/nodes/types/genesis.go#L8 type MorsePos struct { Validators []*MorseValidator `protobuf:"bytes,1,rep,name=validators,proto3" json:"validators"` } @@ -291,7 +314,7 @@ func (m *MorsePos) Reset() { *m = MorsePos{} } func (m *MorsePos) String() string { return proto.CompactTextString(m) } func (*MorsePos) ProtoMessage() {} func (*MorsePos) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{5} + return fileDescriptor_a3da515ab792a974, []int{5} } func (m *MorsePos) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -325,6 +348,7 @@ func (m *MorsePos) GetValidators() []*MorseValidator { // MorseApplication is a subset of the Morse ProtoApplication type. // It encapsulates the minimum information required to import Morse applications. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/apps/apps.proto#L16 type MorseApplication struct { // Address is a binary representation of the address corresponding @@ -342,7 +366,7 @@ func (m *MorseApplication) Reset() { *m = MorseApplication{} } func (m *MorseApplication) String() string { return proto.CompactTextString(m) } func (*MorseApplication) ProtoMessage() {} func (*MorseApplication) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{6} + return fileDescriptor_a3da515ab792a974, []int{6} } func (m *MorseApplication) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -369,6 +393,7 @@ var xxx_messageInfo_MorseApplication proto.InternalMessageInfo // MorseValidator is a subset of the Morse ProtoValidator type. // It encapsulates the minimum information required to import Morse suppliers (aka "servicers" or "validators"). +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/pos/types.proto#L16 type MorseValidator struct { // A binary representation of the address corresponding to a Morse application's ed25519 public key. @@ -385,7 +410,7 @@ func (m *MorseValidator) Reset() { *m = MorseValidator{} } func (m *MorseValidator) String() string { return proto.CompactTextString(m) } func (*MorseValidator) ProtoMessage() {} func (*MorseValidator) Descriptor() ([]byte, []int) { - return fileDescriptor_3ba469df9d72c7fc, []int{7} + return fileDescriptor_a3da515ab792a974, []int{7} } func (m *MorseValidator) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -412,7 +437,7 @@ var xxx_messageInfo_MorseValidator proto.InternalMessageInfo func init() { proto.RegisterType((*MorseStateExport)(nil), "poktroll.migration.MorseStateExport") - proto.RegisterType((*MorseAppState)(nil), "poktroll.migration.MorseAppState") + proto.RegisterType((*MorseTendermintAppState)(nil), "poktroll.migration.MorseTendermintAppState") proto.RegisterType((*MorseApplications)(nil), "poktroll.migration.MorseApplications") proto.RegisterType((*MorseAuth)(nil), "poktroll.migration.MorseAuth") proto.RegisterType((*MorseAuthAccount)(nil), "poktroll.migration.MorseAuthAccount") @@ -421,54 +446,57 @@ func init() { proto.RegisterType((*MorseValidator)(nil), "poktroll.migration.MorseValidator") } -func init() { proto.RegisterFile("poktroll/migration/legacy.proto", fileDescriptor_3ba469df9d72c7fc) } - -var fileDescriptor_3ba469df9d72c7fc = []byte{ - // 705 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x55, 0xcf, 0x6f, 0x13, 0x39, - 0x14, 0xce, 0xf4, 0x57, 0x12, 0x27, 0xe9, 0xb6, 0xd6, 0x1e, 0xa2, 0x6e, 0x77, 0x9c, 0xf5, 0xee, - 0x6a, 0x23, 0xad, 0x48, 0xa4, 0xf4, 0x80, 0x54, 0x4e, 0x19, 0x09, 0x09, 0x09, 0x8a, 0x2a, 0x83, - 0x10, 0x2a, 0x12, 0x95, 0x93, 0x4c, 0x93, 0x90, 0x49, 0x6c, 0x8d, 0x3d, 0xa5, 0xf9, 0x0f, 0x10, - 0x27, 0x8e, 0x1c, 0xfb, 0xbf, 0x70, 0xe1, 0xd8, 0x63, 0x4f, 0x03, 0x4a, 0x2e, 0x68, 0x8e, 0x3d, - 0x72, 0x42, 0xb6, 0x67, 0x92, 0x49, 0x4b, 0xa0, 0x57, 0x2e, 0x1e, 0xbf, 0xe7, 0xef, 0x7b, 0x3f, - 0x3e, 0xbf, 0x91, 0x01, 0xe2, 0x6c, 0x20, 0x7d, 0xe6, 0x79, 0xf5, 0x61, 0xbf, 0xeb, 0x53, 0xd9, - 0x67, 0xa3, 0xba, 0xe7, 0x76, 0x69, 0x7b, 0x5c, 0xe3, 0x3e, 0x93, 0x0c, 0xc2, 0x04, 0x50, 0x9b, - 0x01, 0x76, 0x7e, 0xef, 0xb2, 0x2e, 0xd3, 0xc7, 0x75, 0xb5, 0x33, 0xc8, 0x1d, 0xfb, 0x3b, 0xa1, - 0xe4, 0x98, 0xbb, 0xc2, 0x9c, 0xe3, 0xb7, 0x16, 0xd8, 0x3a, 0x60, 0xbe, 0x70, 0x9f, 0x48, 0x2a, - 0xdd, 0xfb, 0x67, 0x9c, 0xf9, 0x12, 0xfe, 0x07, 0x72, 0x94, 0xf3, 0xe3, 0x1e, 0x15, 0xbd, 0xb2, - 0x55, 0xb1, 0xaa, 0x79, 0xa7, 0x18, 0x85, 0x68, 0xe6, 0x23, 0x59, 0xca, 0xf9, 0x03, 0x2a, 0x7a, - 0xf0, 0x00, 0xe4, 0x95, 0x53, 0x28, 0x6e, 0x79, 0xa5, 0x62, 0x55, 0x0b, 0x8d, 0xbf, 0x6a, 0x37, - 0x6b, 0xab, 0xe9, 0x0c, 0x4d, 0xce, 0x75, 0x12, 0xa7, 0x14, 0x85, 0x68, 0xce, 0x23, 0x2a, 0xae, - 0x3e, 0xc0, 0x9f, 0x2c, 0x50, 0x5a, 0x80, 0xc2, 0xe7, 0xa0, 0x40, 0x39, 0xf7, 0xfa, 0x6d, 0x1d, - 0x47, 0x17, 0x53, 0x68, 0xfc, 0xfb, 0xa3, 0x14, 0x09, 0x56, 0x38, 0xbf, 0x45, 0x21, 0x4a, 0xb3, - 0x49, 0xda, 0x80, 0xf7, 0xc0, 0x1a, 0x0d, 0x64, 0x2f, 0xae, 0xfa, 0xcf, 0xe5, 0x21, 0x03, 0xd9, - 0x73, 0x72, 0x51, 0x88, 0x34, 0x9c, 0xe8, 0x15, 0xde, 0x05, 0xab, 0x9c, 0x89, 0xf2, 0xaa, 0xe6, - 0xee, 0x2e, 0xe5, 0x1e, 0x32, 0xe1, 0x64, 0xa3, 0x10, 0x29, 0x30, 0x51, 0x0b, 0x66, 0x60, 0xfb, - 0x46, 0xa1, 0xf0, 0x08, 0x14, 0x53, 0x95, 0x89, 0xb2, 0x55, 0x59, 0xad, 0x16, 0x1a, 0xff, 0xdc, - 0xa6, 0x4b, 0x67, 0x2b, 0x0a, 0xd1, 0x02, 0x9b, 0x2c, 0x58, 0xf8, 0x05, 0xc8, 0xcf, 0xda, 0x80, - 0x8f, 0x41, 0x8e, 0xb6, 0xdb, 0x2c, 0x18, 0xc9, 0x5b, 0x24, 0x09, 0x64, 0xaf, 0x69, 0xc0, 0xf1, - 0xed, 0xc7, 0x4c, 0x32, 0xdb, 0x61, 0x11, 0xcf, 0x4e, 0x0a, 0x0b, 0x77, 0xc1, 0x9a, 0x9a, 0xaf, - 0x78, 0x6e, 0xb4, 0x70, 0xca, 0x26, 0x7a, 0x85, 0x4d, 0xb0, 0x7e, 0x4a, 0xbd, 0x20, 0x19, 0x96, - 0xca, 0xf2, 0xf4, 0x71, 0xea, 0x7c, 0x14, 0x22, 0x43, 0x21, 0xe6, 0x83, 0x5f, 0x82, 0x5c, 0x22, - 0x2e, 0x24, 0x00, 0x9c, 0x52, 0xaf, 0xdf, 0xa1, 0x92, 0xf9, 0x49, 0x4b, 0x78, 0x69, 0xcc, 0x67, - 0x09, 0xd4, 0xd9, 0x8c, 0x42, 0x94, 0x62, 0x92, 0xd4, 0x1e, 0x4f, 0x57, 0x92, 0xae, 0x52, 0xd3, - 0x72, 0x02, 0xb2, 0xb4, 0xd3, 0xf1, 0x5d, 0x21, 0x74, 0x63, 0x45, 0xe7, 0x51, 0x14, 0xa2, 0xc4, - 0x75, 0x15, 0xa2, 0xcd, 0x31, 0x1d, 0x7a, 0xfb, 0x38, 0x76, 0xe0, 0xaf, 0x21, 0xfa, 0xbf, 0xdb, - 0x97, 0xbd, 0xa0, 0x55, 0x6b, 0xb3, 0x61, 0xbd, 0xcd, 0x86, 0xae, 0x6c, 0x9d, 0xc8, 0xd4, 0xc6, - 0x1f, 0x73, 0xc9, 0x6a, 0x4d, 0x83, 0x27, 0x49, 0x24, 0xe8, 0x00, 0xc0, 0x83, 0x96, 0xd7, 0x6f, - 0x1f, 0x0f, 0xdc, 0xb1, 0x16, 0xa9, 0xe8, 0xfc, 0xad, 0x8a, 0x9d, 0x7b, 0xaf, 0x42, 0xb4, 0x6d, - 0xb2, 0xcd, 0x7d, 0x98, 0xe4, 0x8d, 0xf1, 0xd0, 0x1d, 0xc3, 0x3d, 0xb0, 0xf1, 0x8a, 0xf6, 0x3d, - 0xb7, 0xa3, 0xe7, 0x33, 0xe7, 0xfc, 0x11, 0x85, 0x28, 0xf6, 0x5c, 0x85, 0xa8, 0x64, 0xb8, 0xc6, - 0xc6, 0x24, 0x3e, 0x50, 0x24, 0xf5, 0x37, 0x06, 0xa2, 0xbc, 0x56, 0xb1, 0xaa, 0xeb, 0x86, 0x64, - 0x3c, 0x73, 0x92, 0xb1, 0x31, 0x89, 0x0f, 0x60, 0x1d, 0x94, 0x84, 0xa4, 0x03, 0xb7, 0x73, 0x2c, - 0xd9, 0xc0, 0x1d, 0x89, 0xf2, 0x86, 0xbe, 0x74, 0xa0, 0xb8, 0xc6, 0x43, 0x8a, 0x06, 0xf0, 0x54, - 0x5b, 0xfb, 0xb9, 0x37, 0xe7, 0x28, 0xf3, 0xe5, 0x1c, 0x59, 0xf8, 0xc3, 0x0a, 0xd8, 0x5c, 0xbc, - 0x94, 0x5f, 0x4a, 0x63, 0x7c, 0x4d, 0x63, 0x30, 0xd7, 0x78, 0x26, 0x29, 0xbe, 0x26, 0x29, 0x98, - 0x4b, 0xba, 0x5c, 0xc1, 0xec, 0x4f, 0x14, 0x2c, 0x2a, 0x05, 0xdf, 0x9f, 0x23, 0x4b, 0xa9, 0xe8, - 0x1c, 0x7e, 0x9c, 0xd8, 0xd6, 0xc5, 0xc4, 0xb6, 0x2e, 0x27, 0xb6, 0xf5, 0x79, 0x62, 0x5b, 0xef, - 0xa6, 0x76, 0xe6, 0x62, 0x6a, 0x67, 0x2e, 0xa7, 0x76, 0xe6, 0xa8, 0x91, 0x92, 0x47, 0xfd, 0x13, - 0x77, 0x46, 0xae, 0x7c, 0xcd, 0xfc, 0x41, 0x7d, 0xf6, 0x26, 0x9c, 0x5d, 0x7f, 0x15, 0x5a, 0x1b, - 0xfa, 0x59, 0xd8, 0xfb, 0x16, 0x00, 0x00, 0xff, 0xff, 0x02, 0x82, 0xc9, 0x0f, 0x83, 0x06, 0x00, +func init() { + proto.RegisterFile("poktroll/migration/morse_offchain.proto", fileDescriptor_a3da515ab792a974) +} + +var fileDescriptor_a3da515ab792a974 = []byte{ + // 721 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x55, 0x4b, 0x6b, 0xdb, 0x4a, + 0x14, 0xb6, 0xf2, 0xb2, 0x3d, 0x76, 0x72, 0x13, 0x71, 0xe1, 0x9a, 0xdc, 0x5c, 0x8f, 0x99, 0xdb, + 0x36, 0x86, 0x50, 0x1b, 0x9c, 0x45, 0x21, 0x5d, 0x59, 0x50, 0x28, 0xf4, 0x41, 0x98, 0x86, 0xb6, + 0xa4, 0x50, 0x33, 0xb6, 0x65, 0x4b, 0xb5, 0xac, 0x19, 0x34, 0xa3, 0x34, 0xfe, 0x07, 0x5d, 0x76, + 0xd1, 0x45, 0x97, 0xf9, 0x2f, 0xdd, 0x74, 0x99, 0x65, 0x56, 0xa2, 0xd8, 0x9b, 0x56, 0xcb, 0x2c, + 0xbb, 0x2a, 0x33, 0x92, 0x6c, 0x25, 0x41, 0x34, 0xdb, 0x6e, 0x46, 0x73, 0xce, 0x7c, 0xdf, 0x79, + 0x7c, 0x3a, 0xc3, 0x80, 0x5d, 0x46, 0x47, 0xc2, 0xa3, 0x8e, 0xd3, 0x1c, 0xdb, 0x43, 0x8f, 0x08, + 0x9b, 0xba, 0xcd, 0x31, 0xf5, 0xb8, 0xd9, 0xa1, 0x83, 0x41, 0xcf, 0x22, 0xb6, 0xdb, 0x60, 0x1e, + 0x15, 0x54, 0xd7, 0x13, 0x60, 0x63, 0x0e, 0xdc, 0xfe, 0x7b, 0x48, 0x87, 0x54, 0x1d, 0x37, 0xe5, + 0x2e, 0x42, 0x6e, 0xdf, 0xcb, 0x0e, 0xe9, 0xa6, 0x22, 0xa2, 0x4f, 0x1a, 0xd8, 0x7c, 0x26, 0xfd, + 0x2f, 0x04, 0x11, 0xe6, 0xa3, 0x53, 0x46, 0x3d, 0xa1, 0xef, 0x82, 0x02, 0x61, 0xac, 0x63, 0x11, + 0x6e, 0x55, 0xb4, 0x9a, 0x56, 0x2f, 0x1a, 0xe5, 0x30, 0x80, 0x73, 0x1f, 0xce, 0x13, 0xc6, 0x1e, + 0x13, 0x6e, 0xe9, 0xaf, 0x40, 0x51, 0x3a, 0xb9, 0xe4, 0x56, 0x96, 0x6a, 0x5a, 0xbd, 0xd4, 0xda, + 0x6b, 0xdc, 0xac, 0xb1, 0xa1, 0x32, 0x1c, 0x99, 0x6e, 0xdf, 0xf4, 0xc6, 0xb6, 0x2b, 0xda, 0x8c, + 0xa9, 0x74, 0xc6, 0x7a, 0x18, 0xc0, 0x45, 0x04, 0x2c, 0x33, 0xa8, 0x03, 0xf4, 0x43, 0x03, 0xff, + 0x64, 0x90, 0xf4, 0xd7, 0xa0, 0x44, 0x18, 0x73, 0xec, 0x9e, 0x8a, 0xad, 0x0a, 0x2c, 0xb5, 0xee, + 0x66, 0xa6, 0x6d, 0x2f, 0xb0, 0xdc, 0xf8, 0x2b, 0x0c, 0x60, 0x9a, 0x8d, 0xd3, 0x86, 0xfe, 0x10, + 0xac, 0x10, 0x5f, 0x58, 0x71, 0x27, 0xff, 0x65, 0x87, 0xf4, 0x85, 0x65, 0x14, 0xc2, 0x00, 0x2a, + 0x38, 0x56, 0xab, 0xfe, 0x00, 0x2c, 0x33, 0xca, 0x2b, 0xcb, 0x8a, 0xbb, 0x93, 0xc9, 0x3d, 0xa4, + 0xdc, 0xc8, 0x87, 0x01, 0x94, 0x60, 0x2c, 0x17, 0x44, 0xc1, 0xd6, 0x8d, 0x42, 0xf5, 0x63, 0x50, + 0x4e, 0x55, 0xc6, 0x2b, 0x5a, 0x6d, 0xb9, 0x5e, 0x6a, 0xdd, 0xb9, 0x4d, 0x97, 0xc6, 0x66, 0x18, + 0xc0, 0x2b, 0x6c, 0x7c, 0xc5, 0x42, 0x6f, 0x40, 0x71, 0xde, 0x86, 0xfe, 0x1c, 0x14, 0x48, 0xaf, + 0x47, 0x7d, 0x57, 0xdc, 0x22, 0x89, 0x2f, 0xac, 0x76, 0x04, 0x8e, 0x27, 0x22, 0x66, 0xe2, 0xf9, + 0x0e, 0xf1, 0x78, 0x9e, 0x52, 0x58, 0x7d, 0x07, 0xac, 0x88, 0x09, 0x33, 0xe3, 0x59, 0x52, 0xc2, + 0x49, 0x1b, 0xab, 0x55, 0x6f, 0x83, 0xd5, 0x13, 0xe2, 0xf8, 0xc9, 0x00, 0xd5, 0xb2, 0xd3, 0xc7, + 0xa9, 0x8b, 0x61, 0x00, 0x23, 0x0a, 0x8e, 0x3e, 0xe8, 0x2d, 0x28, 0x24, 0xe2, 0xea, 0x18, 0x80, + 0x13, 0xe2, 0xd8, 0x7d, 0x22, 0xa8, 0x97, 0xb4, 0x84, 0x32, 0x63, 0xbe, 0x4c, 0xa0, 0xc6, 0x46, + 0x18, 0xc0, 0x14, 0x13, 0xa7, 0xf6, 0x68, 0xb6, 0x94, 0x74, 0x95, 0x9a, 0x96, 0x01, 0xc8, 0x93, + 0x7e, 0xdf, 0x33, 0x39, 0x57, 0x8d, 0x95, 0x8d, 0xa7, 0x61, 0x00, 0x13, 0xd7, 0x65, 0x00, 0x37, + 0x26, 0x64, 0xec, 0x1c, 0xa0, 0xd8, 0x81, 0x7e, 0x06, 0x70, 0x6f, 0x68, 0x0b, 0xcb, 0xef, 0x36, + 0x7a, 0x74, 0xdc, 0xec, 0xd1, 0xb1, 0x29, 0xba, 0x03, 0x91, 0xda, 0x78, 0x13, 0x26, 0x68, 0xa3, + 0x1d, 0xe1, 0x71, 0x12, 0x49, 0x37, 0x00, 0x60, 0x7e, 0xd7, 0xb1, 0x7b, 0x9d, 0x91, 0x39, 0x51, + 0x22, 0x95, 0x8d, 0xff, 0x65, 0xb1, 0x0b, 0xef, 0x65, 0x00, 0xb7, 0xa2, 0x6c, 0x0b, 0x1f, 0xc2, + 0xc5, 0xc8, 0x78, 0x62, 0x4e, 0xf4, 0x7d, 0xb0, 0xf6, 0x8e, 0xd8, 0x8e, 0xd9, 0x57, 0xf3, 0x59, + 0x30, 0xfe, 0x0d, 0x03, 0x18, 0x7b, 0x2e, 0x03, 0xb8, 0x1e, 0x71, 0x23, 0x1b, 0xe1, 0xf8, 0x40, + 0x92, 0xe4, 0xbd, 0xf4, 0x79, 0x65, 0xa5, 0xa6, 0xd5, 0x57, 0x23, 0x52, 0xe4, 0x59, 0x90, 0x22, + 0x1b, 0xe1, 0xf8, 0x40, 0x6f, 0x82, 0x75, 0x2e, 0xc8, 0xc8, 0xec, 0x77, 0x04, 0x1d, 0x99, 0x2e, + 0xaf, 0xac, 0xa9, 0x9f, 0x0e, 0x24, 0x37, 0xf2, 0xe0, 0x72, 0x04, 0x38, 0x52, 0xd6, 0x41, 0xe1, + 0xc3, 0x19, 0xcc, 0x7d, 0x3f, 0x83, 0x1a, 0xfa, 0xb2, 0x04, 0x36, 0xae, 0xfe, 0x94, 0x3f, 0x4a, + 0x63, 0x74, 0x4d, 0x63, 0xb0, 0xd0, 0x78, 0x2e, 0x29, 0xba, 0x26, 0x29, 0x58, 0x48, 0x9a, 0xad, + 0x60, 0xfe, 0x37, 0x0a, 0x96, 0xa5, 0x82, 0x9f, 0xcf, 0xa0, 0x26, 0x55, 0x34, 0x0e, 0xbf, 0x4e, + 0xab, 0xda, 0xf9, 0xb4, 0xaa, 0x5d, 0x4c, 0xab, 0xda, 0xb7, 0x69, 0x55, 0xfb, 0x38, 0xab, 0xe6, + 0xce, 0x67, 0xd5, 0xdc, 0xc5, 0xac, 0x9a, 0x3b, 0x6e, 0xa5, 0xe4, 0x91, 0x77, 0xe2, 0xbe, 0x6b, + 0x8a, 0xf7, 0xd4, 0x1b, 0x35, 0xe7, 0xef, 0xc5, 0x69, 0xea, 0xc5, 0x90, 0xf7, 0x93, 0x77, 0xd7, + 0xd4, 0x53, 0xb1, 0xff, 0x2b, 0x00, 0x00, 0xff, 0xff, 0xa9, 0x66, 0x0b, 0xd9, 0xa7, 0x06, 0x00, 0x00, } @@ -571,7 +599,7 @@ func (m *MorseStateExport) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 @@ -579,14 +607,14 @@ func (m *MorseStateExport) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.AppHash) > 0 { i -= len(m.AppHash) copy(dAtA[i:], m.AppHash) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.AppHash))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.AppHash))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } -func (m *MorseAppState) Marshal() (dAtA []byte, err error) { +func (m *MorseTendermintAppState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -596,12 +624,12 @@ func (m *MorseAppState) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *MorseAppState) MarshalTo(dAtA []byte) (int, error) { +func (m *MorseTendermintAppState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *MorseAppState) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *MorseTendermintAppState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -613,7 +641,7 @@ func (m *MorseAppState) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a @@ -625,7 +653,7 @@ func (m *MorseAppState) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 @@ -637,7 +665,7 @@ func (m *MorseAppState) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa @@ -673,7 +701,7 @@ func (m *MorseApplications) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa @@ -710,7 +738,7 @@ func (m *MorseAuth) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa @@ -746,7 +774,7 @@ func (m *MorseAuthAccount) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 @@ -754,7 +782,7 @@ func (m *MorseAuthAccount) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.Type) > 0 { i -= len(m.Type) copy(dAtA[i:], m.Type) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.Type))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.Type))) i-- dAtA[i] = 0xa } @@ -789,7 +817,7 @@ func (m *MorsePos) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintLegacy(dAtA, i, uint64(size)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa @@ -821,12 +849,12 @@ func (m *MorseApplication) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.StakedTokens) > 0 { i -= len(m.StakedTokens) copy(dAtA[i:], m.StakedTokens) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.StakedTokens))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.StakedTokens))) i-- dAtA[i] = 0x32 } if m.Status != 0 { - i = encodeVarintLegacy(dAtA, i, uint64(m.Status)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(m.Status)) i-- dAtA[i] = 0x20 } @@ -843,14 +871,14 @@ func (m *MorseApplication) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.PublicKey) > 0 { i -= len(m.PublicKey) copy(dAtA[i:], m.PublicKey) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.PublicKey))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.PublicKey))) i-- dAtA[i] = 0x12 } if len(m.Address) > 0 { i -= len(m.Address) copy(dAtA[i:], m.Address) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.Address))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.Address))) i-- dAtA[i] = 0xa } @@ -880,12 +908,12 @@ func (m *MorseValidator) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.StakedTokens) > 0 { i -= len(m.StakedTokens) copy(dAtA[i:], m.StakedTokens) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.StakedTokens))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.StakedTokens))) i-- dAtA[i] = 0x3a } if m.Status != 0 { - i = encodeVarintLegacy(dAtA, i, uint64(m.Status)) + i = encodeVarintMorseOffchain(dAtA, i, uint64(m.Status)) i-- dAtA[i] = 0x20 } @@ -902,22 +930,22 @@ func (m *MorseValidator) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.PublicKey) > 0 { i -= len(m.PublicKey) copy(dAtA[i:], m.PublicKey) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.PublicKey))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.PublicKey))) i-- dAtA[i] = 0x12 } if len(m.Address) > 0 { i -= len(m.Address) copy(dAtA[i:], m.Address) - i = encodeVarintLegacy(dAtA, i, uint64(len(m.Address))) + i = encodeVarintMorseOffchain(dAtA, i, uint64(len(m.Address))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } -func encodeVarintLegacy(dAtA []byte, offset int, v uint64) int { - offset -= sovLegacy(v) +func encodeVarintMorseOffchain(dAtA []byte, offset int, v uint64) int { + offset -= sovMorseOffchain(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) @@ -935,16 +963,16 @@ func (m *MorseStateExport) Size() (n int) { _ = l l = len(m.AppHash) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.AppState != nil { l = m.AppState.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } return n } -func (m *MorseAppState) Size() (n int) { +func (m *MorseTendermintAppState) Size() (n int) { if m == nil { return 0 } @@ -952,15 +980,15 @@ func (m *MorseAppState) Size() (n int) { _ = l if m.Application != nil { l = m.Application.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.Auth != nil { l = m.Auth.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.Pos != nil { l = m.Pos.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } return n } @@ -974,7 +1002,7 @@ func (m *MorseApplications) Size() (n int) { if len(m.Applications) > 0 { for _, e := range m.Applications { l = e.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } } return n @@ -989,7 +1017,7 @@ func (m *MorseAuth) Size() (n int) { if len(m.Accounts) > 0 { for _, e := range m.Accounts { l = e.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } } return n @@ -1003,11 +1031,11 @@ func (m *MorseAuthAccount) Size() (n int) { _ = l l = len(m.Type) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.Value != nil { l = m.Value.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } return n } @@ -1021,7 +1049,7 @@ func (m *MorsePos) Size() (n int) { if len(m.Validators) > 0 { for _, e := range m.Validators { l = e.Size() - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } } return n @@ -1035,21 +1063,21 @@ func (m *MorseApplication) Size() (n int) { _ = l l = len(m.Address) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } l = len(m.PublicKey) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.Jailed { n += 2 } if m.Status != 0 { - n += 1 + sovLegacy(uint64(m.Status)) + n += 1 + sovMorseOffchain(uint64(m.Status)) } l = len(m.StakedTokens) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } return n } @@ -1062,30 +1090,30 @@ func (m *MorseValidator) Size() (n int) { _ = l l = len(m.Address) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } l = len(m.PublicKey) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } if m.Jailed { n += 2 } if m.Status != 0 { - n += 1 + sovLegacy(uint64(m.Status)) + n += 1 + sovMorseOffchain(uint64(m.Status)) } l = len(m.StakedTokens) if l > 0 { - n += 1 + l + sovLegacy(uint64(l)) + n += 1 + l + sovMorseOffchain(uint64(l)) } return n } -func sovLegacy(x uint64) (n int) { +func sovMorseOffchain(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } -func sozLegacy(x uint64) (n int) { - return sovLegacy(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +func sozMorseOffchain(x uint64) (n int) { + return sovMorseOffchain(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MorseStateExport) Unmarshal(dAtA []byte) error { l := len(dAtA) @@ -1095,7 +1123,7 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1123,7 +1151,7 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1137,11 +1165,11 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { } intStringLen := int(stringLen) if intStringLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + intStringLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1155,7 +1183,7 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1168,17 +1196,17 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF } if m.AppState == nil { - m.AppState = &MorseAppState{} + m.AppState = &MorseTendermintAppState{} } if err := m.AppState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err @@ -1186,12 +1214,12 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1205,7 +1233,7 @@ func (m *MorseStateExport) Unmarshal(dAtA []byte) error { } return nil } -func (m *MorseAppState) Unmarshal(dAtA []byte) error { +func (m *MorseTendermintAppState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -1213,7 +1241,7 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1228,10 +1256,10 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: MorseAppState: wiretype end group for non-group") + return fmt.Errorf("proto: MorseTendermintAppState: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: MorseAppState: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: MorseTendermintAppState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -1241,7 +1269,7 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1254,11 +1282,11 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1277,7 +1305,7 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1290,11 +1318,11 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1313,7 +1341,7 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1326,11 +1354,11 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1344,12 +1372,12 @@ func (m *MorseAppState) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1371,7 +1399,7 @@ func (m *MorseApplications) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1399,7 +1427,7 @@ func (m *MorseApplications) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1412,11 +1440,11 @@ func (m *MorseApplications) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1428,12 +1456,12 @@ func (m *MorseApplications) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1455,7 +1483,7 @@ func (m *MorseAuth) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1483,7 +1511,7 @@ func (m *MorseAuth) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1496,11 +1524,11 @@ func (m *MorseAuth) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1512,12 +1540,12 @@ func (m *MorseAuth) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1539,7 +1567,7 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1567,7 +1595,7 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1581,11 +1609,11 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { } intStringLen := int(stringLen) if intStringLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + intStringLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1599,7 +1627,7 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1612,11 +1640,11 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1630,12 +1658,12 @@ func (m *MorseAuthAccount) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1657,7 +1685,7 @@ func (m *MorsePos) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1685,7 +1713,7 @@ func (m *MorsePos) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1698,11 +1726,11 @@ func (m *MorsePos) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1714,12 +1742,12 @@ func (m *MorsePos) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1741,7 +1769,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1769,7 +1797,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1782,11 +1810,11 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1803,7 +1831,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1816,11 +1844,11 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1837,7 +1865,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1857,7 +1885,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { m.Status = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1876,7 +1904,7 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1890,11 +1918,11 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { } intStringLen := int(stringLen) if intStringLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + intStringLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1903,12 +1931,12 @@ func (m *MorseApplication) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -1930,7 +1958,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1958,7 +1986,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -1971,11 +1999,11 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -1992,7 +2020,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -2005,11 +2033,11 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -2026,7 +2054,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -2046,7 +2074,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { m.Status = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -2065,7 +2093,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowLegacy + return ErrIntOverflowMorseOffchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -2079,11 +2107,11 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { } intStringLen := int(stringLen) if intStringLen < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } postIndex := iNdEx + intStringLen if postIndex < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -2092,12 +2120,12 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipLegacy(dAtA[iNdEx:]) + skippy, err := skipMorseOffchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthLegacy + return ErrInvalidLengthMorseOffchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -2111,7 +2139,7 @@ func (m *MorseValidator) Unmarshal(dAtA []byte) error { } return nil } -func skipLegacy(dAtA []byte) (n int, err error) { +func skipMorseOffchain(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 @@ -2119,7 +2147,7 @@ func skipLegacy(dAtA []byte) (n int, err error) { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowLegacy + return 0, ErrIntOverflowMorseOffchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -2136,7 +2164,7 @@ func skipLegacy(dAtA []byte) (n int, err error) { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowLegacy + return 0, ErrIntOverflowMorseOffchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -2152,7 +2180,7 @@ func skipLegacy(dAtA []byte) (n int, err error) { var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowLegacy + return 0, ErrIntOverflowMorseOffchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -2165,14 +2193,14 @@ func skipLegacy(dAtA []byte) (n int, err error) { } } if length < 0 { - return 0, ErrInvalidLengthLegacy + return 0, ErrInvalidLengthMorseOffchain } iNdEx += length case 3: depth++ case 4: if depth == 0 { - return 0, ErrUnexpectedEndOfGroupLegacy + return 0, ErrUnexpectedEndOfGroupMorseOffchain } depth-- case 5: @@ -2181,7 +2209,7 @@ func skipLegacy(dAtA []byte) (n int, err error) { return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { - return 0, ErrInvalidLengthLegacy + return 0, ErrInvalidLengthMorseOffchain } if depth == 0 { return iNdEx, nil @@ -2191,7 +2219,7 @@ func skipLegacy(dAtA []byte) (n int, err error) { } var ( - ErrInvalidLengthLegacy = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowLegacy = fmt.Errorf("proto: integer overflow") - ErrUnexpectedEndOfGroupLegacy = fmt.Errorf("proto: unexpected end of group") + ErrInvalidLengthMorseOffchain = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowMorseOffchain = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupMorseOffchain = fmt.Errorf("proto: unexpected end of group") ) diff --git a/x/migration/types/types.pb.go b/x/migration/types/morse_onchain.pb.go similarity index 73% rename from x/migration/types/types.pb.go rename to x/migration/types/morse_onchain.pb.go index c63ed04c8..8f2c93e6c 100644 --- a/x/migration/types/types.pb.go +++ b/x/migration/types/morse_onchain.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: poktroll/migration/types.proto +// source: poktroll/migration/morse_onchain.proto package types @@ -36,7 +36,7 @@ func (m *MorseAccountState) Reset() { *m = MorseAccountState{} } func (m *MorseAccountState) String() string { return proto.CompactTextString(m) } func (*MorseAccountState) ProtoMessage() {} func (*MorseAccountState) Descriptor() ([]byte, []int) { - return fileDescriptor_7ed31f79aa0bc330, []int{0} + return fileDescriptor_e74ea76a959fdb61, []int{0} } func (m *MorseAccountState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -68,10 +68,12 @@ func (m *MorseAccountState) GetAccounts() []*MorseAccount { return nil } -// MorseAccount is an analog of the Morse ProtoBaseAccount type. It encapsulates -// the minimum information required to import accounts. +// MorseAccount is an analog of the Morse ProtoBaseAccount type. +// It encapsulates the minimum information required to import accounts. +// // See: https://github.com/pokt-network/pocket-core/blob/staging/proto/x/auth/auth.proto#L14. type MorseAccount struct { + // A binary representation of the address corresponding to a Morse application's ed25519 public key. Address github_com_cometbft_cometbft_crypto.Address `protobuf:"bytes,1,opt,name=address,proto3,casttype=github.com/cometbft/cometbft/crypto.Address" json:"address"` PubKey *MorsePublicKey `protobuf:"bytes,2,opt,name=pub_key,json=pubKey,proto3" json:"public_key" yaml:"public_key"` Coins []types.Coin `protobuf:"bytes,3,rep,name=coins,proto3" json:"coins"` @@ -81,7 +83,7 @@ func (m *MorseAccount) Reset() { *m = MorseAccount{} } func (m *MorseAccount) String() string { return proto.CompactTextString(m) } func (*MorseAccount) ProtoMessage() {} func (*MorseAccount) Descriptor() ([]byte, []int) { - return fileDescriptor_7ed31f79aa0bc330, []int{1} + return fileDescriptor_e74ea76a959fdb61, []int{1} } func (m *MorseAccount) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -120,7 +122,7 @@ func (m *MorsePublicKey) Reset() { *m = MorsePublicKey{} } func (m *MorsePublicKey) String() string { return proto.CompactTextString(m) } func (*MorsePublicKey) ProtoMessage() {} func (*MorsePublicKey) Descriptor() ([]byte, []int) { - return fileDescriptor_7ed31f79aa0bc330, []int{2} + return fileDescriptor_e74ea76a959fdb61, []int{2} } func (m *MorsePublicKey) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -158,39 +160,41 @@ func init() { proto.RegisterType((*MorsePublicKey)(nil), "poktroll.migration.MorsePublicKey") } -func init() { proto.RegisterFile("poktroll/migration/types.proto", fileDescriptor_7ed31f79aa0bc330) } - -var fileDescriptor_7ed31f79aa0bc330 = []byte{ - // 449 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x92, 0x31, 0x6f, 0xd3, 0x40, - 0x14, 0xc7, 0x7d, 0xad, 0xda, 0xa0, 0x6b, 0x40, 0xaa, 0x85, 0x44, 0x5a, 0xa1, 0xbb, 0xc8, 0x2c, - 0x91, 0x50, 0xef, 0x14, 0xa3, 0x0e, 0x64, 0x40, 0xaa, 0x61, 0xa2, 0x42, 0xaa, 0x0c, 0x13, 0x4b, - 0xb0, 0x9d, 0x23, 0x58, 0xb1, 0xfd, 0x2c, 0xfb, 0x5c, 0xf0, 0x37, 0xe8, 0xc8, 0xc8, 0x46, 0xc5, - 0x67, 0xe0, 0x43, 0x54, 0x4c, 0x1d, 0x3b, 0x9d, 0x50, 0xb2, 0x65, 0x64, 0xcc, 0x84, 0xec, 0x4b, - 0x8c, 0x01, 0x75, 0xf2, 0xfb, 0xbf, 0xf7, 0xff, 0x5b, 0xef, 0x7e, 0x7a, 0x98, 0xa4, 0x30, 0x93, - 0x19, 0x44, 0x11, 0x8f, 0xc3, 0x69, 0xe6, 0xc9, 0x10, 0x12, 0x2e, 0xcb, 0x54, 0xe4, 0x2c, 0xcd, - 0x40, 0x82, 0x69, 0x6e, 0xe6, 0xac, 0x99, 0x1f, 0x1e, 0x04, 0x90, 0xc7, 0x90, 0x8f, 0x6b, 0x07, - 0xd7, 0x42, 0xdb, 0x0f, 0x89, 0x56, 0xdc, 0xf7, 0x72, 0xc1, 0xcf, 0x87, 0xbe, 0x90, 0xde, 0x90, - 0x07, 0x10, 0x26, 0xeb, 0xf9, 0xfd, 0x29, 0x4c, 0x41, 0xe7, 0xaa, 0x4a, 0x77, 0xad, 0x31, 0xde, - 0x7f, 0x05, 0x59, 0x2e, 0x4e, 0x82, 0x00, 0x8a, 0x44, 0xbe, 0x96, 0x9e, 0x14, 0xe6, 0x4b, 0x7c, - 0xc7, 0xd3, 0x3a, 0xef, 0xa1, 0xfe, 0xf6, 0x60, 0xcf, 0xee, 0xb3, 0xff, 0x97, 0x61, 0xed, 0xa0, - 0xd3, 0x5d, 0x2a, 0xda, 0xa4, 0xdc, 0xa6, 0xb2, 0xbe, 0x6e, 0xe1, 0x6e, 0xdb, 0x68, 0xbe, 0xc1, - 0x1d, 0x6f, 0x32, 0xc9, 0x44, 0x5e, 0xfd, 0x1b, 0x0d, 0xba, 0xce, 0x68, 0xa9, 0xe8, 0xa6, 0xb5, - 0x52, 0xf4, 0xf1, 0x34, 0x94, 0x1f, 0x0a, 0x9f, 0x05, 0x10, 0xf3, 0x00, 0x62, 0x21, 0xfd, 0xf7, - 0xb2, 0x55, 0x64, 0x65, 0x2a, 0x81, 0x9d, 0x68, 0xbb, 0xbb, 0xc9, 0x99, 0xef, 0x70, 0x27, 0x2d, - 0xfc, 0xf1, 0x4c, 0x94, 0xbd, 0xad, 0x3e, 0x1a, 0xec, 0xd9, 0xd6, 0xad, 0x1b, 0x9f, 0x15, 0x7e, - 0x14, 0x06, 0xa7, 0xa2, 0x74, 0x1e, 0x2d, 0x15, 0xc5, 0x69, 0x2d, 0xab, 0xe4, 0x2f, 0x45, 0xf7, - 0x4b, 0x2f, 0x8e, 0x46, 0xd6, 0x9f, 0x9e, 0xe5, 0xee, 0xa6, 0x85, 0x7f, 0x2a, 0x4a, 0xf3, 0x19, - 0xde, 0xa9, 0x68, 0xe6, 0xbd, 0xed, 0x9a, 0xc8, 0x01, 0x5b, 0xd3, 0xaf, 0x78, 0xb3, 0x35, 0x6f, - 0xf6, 0x1c, 0xc2, 0xc4, 0xb9, 0x7b, 0xa5, 0xa8, 0xb1, 0x54, 0x54, 0xfb, 0x5d, 0xfd, 0x19, 0x3d, - 0xb8, 0xb8, 0xa4, 0xc6, 0x97, 0x4b, 0x8a, 0x2e, 0xbe, 0x51, 0xf4, 0xe3, 0xfb, 0x51, 0x67, 0x0d, - 0xc4, 0x7a, 0x81, 0xef, 0xfd, 0xbd, 0x97, 0x69, 0xe3, 0x9d, 0x73, 0x2f, 0x2a, 0x44, 0xfd, 0x94, - 0xae, 0xf3, 0x70, 0xa5, 0x68, 0x4f, 0x3f, 0x9c, 0x8b, 0x89, 0x7d, 0x7c, 0x3c, 0x7c, 0xca, 0x1a, - 0xb3, 0xab, 0xad, 0xce, 0xd9, 0xd5, 0x9c, 0xa0, 0xeb, 0x39, 0x41, 0x37, 0x73, 0x82, 0x7e, 0xce, - 0x09, 0xfa, 0xbc, 0x20, 0xc6, 0xf5, 0x82, 0x18, 0x37, 0x0b, 0x62, 0xbc, 0xb5, 0x5b, 0x50, 0x2b, - 0x2e, 0x47, 0x89, 0x90, 0x1f, 0x21, 0x9b, 0xf1, 0xe6, 0x06, 0x3f, 0xfd, 0x7b, 0x85, 0xfe, 0x6e, - 0x7d, 0x21, 0x4f, 0x7e, 0x07, 0x00, 0x00, 0xff, 0xff, 0x7d, 0x7c, 0x0e, 0x0e, 0xa8, 0x02, 0x00, - 0x00, +func init() { + proto.RegisterFile("poktroll/migration/morse_onchain.proto", fileDescriptor_e74ea76a959fdb61) +} + +var fileDescriptor_e74ea76a959fdb61 = []byte{ + // 458 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x92, 0x41, 0x6b, 0xd4, 0x40, + 0x14, 0xc7, 0x33, 0x2d, 0xed, 0xca, 0x74, 0x15, 0x1a, 0x04, 0xb7, 0x8b, 0x64, 0x96, 0x08, 0xb2, + 0x20, 0x9d, 0x61, 0x23, 0x3d, 0xb8, 0x07, 0xa1, 0xd1, 0x93, 0x45, 0x28, 0xd1, 0x93, 0x97, 0x75, + 0x92, 0x1d, 0xb7, 0x61, 0x93, 0xbc, 0x90, 0x4c, 0xaa, 0xf9, 0x06, 0x3d, 0x7a, 0xf4, 0x66, 0xf1, + 0x33, 0xf8, 0x21, 0x8a, 0xa7, 0x1e, 0x7b, 0x1a, 0x64, 0xf7, 0xb6, 0x47, 0x8f, 0x3d, 0x49, 0x32, + 0xbb, 0x31, 0x22, 0x9e, 0xf2, 0xfe, 0x8f, 0xdf, 0x7f, 0xf2, 0xde, 0x9f, 0x87, 0x1f, 0xa7, 0x30, + 0x97, 0x19, 0x44, 0x11, 0x8b, 0xc3, 0x59, 0xc6, 0x65, 0x08, 0x09, 0x8b, 0x21, 0xcb, 0xc5, 0x04, + 0x92, 0xe0, 0x8c, 0x87, 0x09, 0x4d, 0x33, 0x90, 0x60, 0x9a, 0x1b, 0x8e, 0x36, 0x5c, 0xff, 0x20, + 0x80, 0x3c, 0x86, 0x7c, 0x52, 0x13, 0x4c, 0x0b, 0x8d, 0xf7, 0x2d, 0xad, 0x98, 0xcf, 0x73, 0xc1, + 0xce, 0x47, 0xbe, 0x90, 0x7c, 0xc4, 0x02, 0xd8, 0x3c, 0xd7, 0xbf, 0x3f, 0x83, 0x19, 0x68, 0x5f, + 0x55, 0xe9, 0xae, 0x3d, 0xc1, 0xfb, 0xaf, 0xab, 0x7f, 0x1f, 0x07, 0x01, 0x14, 0x89, 0x7c, 0x23, + 0xb9, 0x14, 0xe6, 0x2b, 0x7c, 0x87, 0x6b, 0x9d, 0xf7, 0xd0, 0x60, 0x7b, 0xb8, 0xe7, 0x0c, 0xe8, + 0xbf, 0xc3, 0xd0, 0xb6, 0xd1, 0xed, 0xae, 0x14, 0x69, 0x5c, 0x5e, 0x53, 0xd9, 0x5f, 0xb7, 0x70, + 0xb7, 0x0d, 0x9a, 0x6f, 0x71, 0x87, 0x4f, 0xa7, 0x99, 0xc8, 0xab, 0xb7, 0xd1, 0xb0, 0xeb, 0x8e, + 0x57, 0x8a, 0x6c, 0x5a, 0xb7, 0x8a, 0x3c, 0x99, 0x85, 0xf2, 0xac, 0xf0, 0x69, 0x00, 0x31, 0x0b, + 0x20, 0x16, 0xd2, 0xff, 0x20, 0x5b, 0x45, 0x56, 0xa6, 0x12, 0xe8, 0xb1, 0xc6, 0xbd, 0x8d, 0xcf, + 0x7c, 0x8f, 0x3b, 0x69, 0xe1, 0x4f, 0xe6, 0xa2, 0xec, 0x6d, 0x0d, 0xd0, 0x70, 0xcf, 0xb1, 0xff, + 0x3b, 0xf1, 0x69, 0xe1, 0x47, 0x61, 0x70, 0x22, 0x4a, 0xf7, 0xd1, 0x4a, 0x11, 0x9c, 0xd6, 0xb2, + 0x72, 0xfe, 0x52, 0x64, 0xbf, 0xe4, 0x71, 0x34, 0xb6, 0xff, 0xf4, 0x6c, 0x6f, 0x37, 0x2d, 0xfc, + 0x13, 0x51, 0x9a, 0xcf, 0xf1, 0x4e, 0x95, 0x66, 0xde, 0xdb, 0xae, 0x13, 0x39, 0xa0, 0xeb, 0xf4, + 0xab, 0xbc, 0xe9, 0x3a, 0x6f, 0xfa, 0x02, 0xc2, 0xc4, 0xbd, 0x7b, 0xa5, 0x88, 0xb1, 0x52, 0x44, + 0xf3, 0x9e, 0xfe, 0x8c, 0x1f, 0x5c, 0x5c, 0x12, 0xe3, 0xcb, 0x25, 0x41, 0x17, 0xdf, 0x08, 0xfa, + 0xf1, 0xfd, 0xb0, 0xb3, 0x0e, 0xc4, 0x7e, 0x89, 0xef, 0xfd, 0x3d, 0x97, 0xe9, 0xe0, 0x9d, 0x73, + 0x1e, 0x15, 0xa2, 0x5e, 0xa5, 0xeb, 0x3e, 0xbc, 0x55, 0xa4, 0xa7, 0x17, 0x67, 0x62, 0xea, 0x1c, + 0x1d, 0x8d, 0x9e, 0xd1, 0x06, 0xf6, 0x34, 0xea, 0x9e, 0x5e, 0x2d, 0x2c, 0x74, 0xbd, 0xb0, 0xd0, + 0xcd, 0xc2, 0x42, 0x3f, 0x17, 0x16, 0xfa, 0xbc, 0xb4, 0x8c, 0xeb, 0xa5, 0x65, 0xdc, 0x2c, 0x2d, + 0xe3, 0x9d, 0xd3, 0x0a, 0xb5, 0xca, 0xe5, 0x30, 0x11, 0xf2, 0x23, 0x64, 0x73, 0xd6, 0xdc, 0xe2, + 0xa7, 0xd6, 0x35, 0xca, 0x32, 0x15, 0xb9, 0xbf, 0x5b, 0x5f, 0xc8, 0xd3, 0xdf, 0x01, 0x00, 0x00, + 0xff, 0xff, 0x41, 0x70, 0x0e, 0x24, 0xb0, 0x02, 0x00, 0x00, } func (m *MorseAccountState) Marshal() (dAtA []byte, err error) { @@ -221,7 +225,7 @@ func (m *MorseAccountState) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintTypes(dAtA, i, uint64(size)) + i = encodeVarintMorseOnchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa @@ -258,7 +262,7 @@ func (m *MorseAccount) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintTypes(dAtA, i, uint64(size)) + i = encodeVarintMorseOnchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a @@ -271,7 +275,7 @@ func (m *MorseAccount) MarshalToSizedBuffer(dAtA []byte) (int, error) { return 0, err } i -= size - i = encodeVarintTypes(dAtA, i, uint64(size)) + i = encodeVarintMorseOnchain(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 @@ -279,7 +283,7 @@ func (m *MorseAccount) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.Address) > 0 { i -= len(m.Address) copy(dAtA[i:], m.Address) - i = encodeVarintTypes(dAtA, i, uint64(len(m.Address))) + i = encodeVarintMorseOnchain(dAtA, i, uint64(len(m.Address))) i-- dAtA[i] = 0xa } @@ -309,15 +313,15 @@ func (m *MorsePublicKey) MarshalToSizedBuffer(dAtA []byte) (int, error) { if len(m.Value) > 0 { i -= len(m.Value) copy(dAtA[i:], m.Value) - i = encodeVarintTypes(dAtA, i, uint64(len(m.Value))) + i = encodeVarintMorseOnchain(dAtA, i, uint64(len(m.Value))) i-- dAtA[i] = 0x12 } return len(dAtA) - i, nil } -func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { - offset -= sovTypes(v) +func encodeVarintMorseOnchain(dAtA []byte, offset int, v uint64) int { + offset -= sovMorseOnchain(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) @@ -336,7 +340,7 @@ func (m *MorseAccountState) Size() (n int) { if len(m.Accounts) > 0 { for _, e := range m.Accounts { l = e.Size() - n += 1 + l + sovTypes(uint64(l)) + n += 1 + l + sovMorseOnchain(uint64(l)) } } return n @@ -350,16 +354,16 @@ func (m *MorseAccount) Size() (n int) { _ = l l = len(m.Address) if l > 0 { - n += 1 + l + sovTypes(uint64(l)) + n += 1 + l + sovMorseOnchain(uint64(l)) } if m.PubKey != nil { l = m.PubKey.Size() - n += 1 + l + sovTypes(uint64(l)) + n += 1 + l + sovMorseOnchain(uint64(l)) } if len(m.Coins) > 0 { for _, e := range m.Coins { l = e.Size() - n += 1 + l + sovTypes(uint64(l)) + n += 1 + l + sovMorseOnchain(uint64(l)) } } return n @@ -373,16 +377,16 @@ func (m *MorsePublicKey) Size() (n int) { _ = l l = len(m.Value) if l > 0 { - n += 1 + l + sovTypes(uint64(l)) + n += 1 + l + sovMorseOnchain(uint64(l)) } return n } -func sovTypes(x uint64) (n int) { +func sovMorseOnchain(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } -func sozTypes(x uint64) (n int) { - return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +func sozMorseOnchain(x uint64) (n int) { + return sovMorseOnchain(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MorseAccountState) Unmarshal(dAtA []byte) error { l := len(dAtA) @@ -392,7 +396,7 @@ func (m *MorseAccountState) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -420,7 +424,7 @@ func (m *MorseAccountState) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -433,11 +437,11 @@ func (m *MorseAccountState) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -449,12 +453,12 @@ func (m *MorseAccountState) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipTypes(dAtA[iNdEx:]) + skippy, err := skipMorseOnchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -476,7 +480,7 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -504,7 +508,7 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -517,11 +521,11 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -538,7 +542,7 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -551,11 +555,11 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -574,7 +578,7 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -587,11 +591,11 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { } } if msglen < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } postIndex := iNdEx + msglen if postIndex < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -603,12 +607,12 @@ func (m *MorseAccount) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipTypes(dAtA[iNdEx:]) + skippy, err := skipMorseOnchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -630,7 +634,7 @@ func (m *MorsePublicKey) Unmarshal(dAtA []byte) error { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -658,7 +662,7 @@ func (m *MorsePublicKey) Unmarshal(dAtA []byte) error { var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return ErrIntOverflowTypes + return ErrIntOverflowMorseOnchain } if iNdEx >= l { return io.ErrUnexpectedEOF @@ -671,11 +675,11 @@ func (m *MorsePublicKey) Unmarshal(dAtA []byte) error { } } if byteLen < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } postIndex := iNdEx + byteLen if postIndex < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if postIndex > l { return io.ErrUnexpectedEOF @@ -687,12 +691,12 @@ func (m *MorsePublicKey) Unmarshal(dAtA []byte) error { iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipTypes(dAtA[iNdEx:]) + skippy, err := skipMorseOnchain(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthTypes + return ErrInvalidLengthMorseOnchain } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF @@ -706,7 +710,7 @@ func (m *MorsePublicKey) Unmarshal(dAtA []byte) error { } return nil } -func skipTypes(dAtA []byte) (n int, err error) { +func skipMorseOnchain(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 @@ -714,7 +718,7 @@ func skipTypes(dAtA []byte) (n int, err error) { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowTypes + return 0, ErrIntOverflowMorseOnchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -731,7 +735,7 @@ func skipTypes(dAtA []byte) (n int, err error) { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowTypes + return 0, ErrIntOverflowMorseOnchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -747,7 +751,7 @@ func skipTypes(dAtA []byte) (n int, err error) { var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { - return 0, ErrIntOverflowTypes + return 0, ErrIntOverflowMorseOnchain } if iNdEx >= l { return 0, io.ErrUnexpectedEOF @@ -760,14 +764,14 @@ func skipTypes(dAtA []byte) (n int, err error) { } } if length < 0 { - return 0, ErrInvalidLengthTypes + return 0, ErrInvalidLengthMorseOnchain } iNdEx += length case 3: depth++ case 4: if depth == 0 { - return 0, ErrUnexpectedEndOfGroupTypes + return 0, ErrUnexpectedEndOfGroupMorseOnchain } depth-- case 5: @@ -776,7 +780,7 @@ func skipTypes(dAtA []byte) (n int, err error) { return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { - return 0, ErrInvalidLengthTypes + return 0, ErrInvalidLengthMorseOnchain } if depth == 0 { return iNdEx, nil @@ -786,7 +790,7 @@ func skipTypes(dAtA []byte) (n int, err error) { } var ( - ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") - ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") + ErrInvalidLengthMorseOnchain = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowMorseOnchain = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupMorseOnchain = fmt.Errorf("proto: unexpected end of group") )