From e7e046841fab8c74b3bedcd8c285a2bf79975a15 Mon Sep 17 00:00:00 2001 From: Julien Robert Date: Thu, 8 Dec 2022 10:56:53 +0100 Subject: [PATCH] feat: add `order_migrations` argument in runtime.Module config --- .../app/runtime/v1alpha1/module.pulsar.go | 192 +++++++++++++++--- api/cosmos/consensus/v1/query.pulsar.go | 7 +- api/cosmos/consensus/v1/tx.pulsar.go | 2 +- .../cosmos/app/runtime/v1alpha1/module.proto | 5 + .../store/snapshots/v1beta1/snapshot.proto | 2 +- .../cosmos/base/store/v1beta1/listening.proto | 22 +- proto/cosmos/evidence/v1beta1/evidence.proto | 8 +- proto/cosmos/evidence/v1beta1/tx.proto | 6 +- proto/cosmos/gov/module/v1/module.proto | 2 +- proto/cosmos/gov/v1/gov.proto | 46 ++--- proto/cosmos/gov/v1/tx.proto | 42 ++-- proto/cosmos/gov/v1beta1/gov.proto | 42 ++-- proto/cosmos/gov/v1beta1/tx.proto | 30 +-- tx/textual/internal/testpb/1.proto | 50 ++--- x/consensus/types/query.pb.go | 7 +- x/consensus/types/tx.pb.go | 2 +- 16 files changed, 307 insertions(+), 158 deletions(-) diff --git a/api/cosmos/app/runtime/v1alpha1/module.pulsar.go b/api/cosmos/app/runtime/v1alpha1/module.pulsar.go index 56b5ff66fc27..e8fe74d59cd5 100644 --- a/api/cosmos/app/runtime/v1alpha1/module.pulsar.go +++ b/api/cosmos/app/runtime/v1alpha1/module.pulsar.go @@ -248,6 +248,52 @@ func (x *_Module_6_list) IsValid() bool { return x.list != nil } +var _ protoreflect.List = (*_Module_7_list)(nil) + +type _Module_7_list struct { + list *[]string +} + +func (x *_Module_7_list) Len() int { + if x.list == nil { + return 0 + } + return len(*x.list) +} + +func (x *_Module_7_list) Get(i int) protoreflect.Value { + return protoreflect.ValueOfString((*x.list)[i]) +} + +func (x *_Module_7_list) Set(i int, value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + (*x.list)[i] = concreteValue +} + +func (x *_Module_7_list) Append(value protoreflect.Value) { + valueUnwrapped := value.String() + concreteValue := valueUnwrapped + *x.list = append(*x.list, concreteValue) +} + +func (x *_Module_7_list) AppendMutable() protoreflect.Value { + panic(fmt.Errorf("AppendMutable can not be called on message Module at list field OrderMigrations as it is not of Message kind")) +} + +func (x *_Module_7_list) Truncate(n int) { + *x.list = (*x.list)[:n] +} + +func (x *_Module_7_list) NewElement() protoreflect.Value { + v := "" + return protoreflect.ValueOfString(v) +} + +func (x *_Module_7_list) IsValid() bool { + return x.list != nil +} + var ( md_Module protoreflect.MessageDescriptor fd_Module_app_name protoreflect.FieldDescriptor @@ -256,6 +302,7 @@ var ( fd_Module_init_genesis protoreflect.FieldDescriptor fd_Module_export_genesis protoreflect.FieldDescriptor fd_Module_override_store_keys protoreflect.FieldDescriptor + fd_Module_order_migrations protoreflect.FieldDescriptor ) func init() { @@ -267,6 +314,7 @@ func init() { fd_Module_init_genesis = md_Module.Fields().ByName("init_genesis") fd_Module_export_genesis = md_Module.Fields().ByName("export_genesis") fd_Module_override_store_keys = md_Module.Fields().ByName("override_store_keys") + fd_Module_order_migrations = md_Module.Fields().ByName("order_migrations") } var _ protoreflect.Message = (*fastReflection_Module)(nil) @@ -370,6 +418,12 @@ func (x *fastReflection_Module) Range(f func(protoreflect.FieldDescriptor, proto return } } + if len(x.OrderMigrations) != 0 { + value := protoreflect.ValueOfList(&_Module_7_list{list: &x.OrderMigrations}) + if !f(fd_Module_order_migrations, value) { + return + } + } } // Has reports whether a field is populated. @@ -397,6 +451,8 @@ func (x *fastReflection_Module) Has(fd protoreflect.FieldDescriptor) bool { return len(x.ExportGenesis) != 0 case "cosmos.app.runtime.v1alpha1.Module.override_store_keys": return len(x.OverrideStoreKeys) != 0 + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + return len(x.OrderMigrations) != 0 default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.app.runtime.v1alpha1.Module")) @@ -425,6 +481,8 @@ func (x *fastReflection_Module) Clear(fd protoreflect.FieldDescriptor) { x.ExportGenesis = nil case "cosmos.app.runtime.v1alpha1.Module.override_store_keys": x.OverrideStoreKeys = nil + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + x.OrderMigrations = nil default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.app.runtime.v1alpha1.Module")) @@ -474,6 +532,12 @@ func (x *fastReflection_Module) Get(descriptor protoreflect.FieldDescriptor) pro } listValue := &_Module_6_list{list: &x.OverrideStoreKeys} return protoreflect.ValueOfList(listValue) + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + if len(x.OrderMigrations) == 0 { + return protoreflect.ValueOfList(&_Module_7_list{}) + } + listValue := &_Module_7_list{list: &x.OrderMigrations} + return protoreflect.ValueOfList(listValue) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.app.runtime.v1alpha1.Module")) @@ -516,6 +580,10 @@ func (x *fastReflection_Module) Set(fd protoreflect.FieldDescriptor, value proto lv := value.List() clv := lv.(*_Module_6_list) x.OverrideStoreKeys = *clv.list + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + lv := value.List() + clv := lv.(*_Module_7_list) + x.OrderMigrations = *clv.list default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.app.runtime.v1alpha1.Module")) @@ -566,6 +634,12 @@ func (x *fastReflection_Module) Mutable(fd protoreflect.FieldDescriptor) protore } value := &_Module_6_list{list: &x.OverrideStoreKeys} return protoreflect.ValueOfList(value) + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + if x.OrderMigrations == nil { + x.OrderMigrations = []string{} + } + value := &_Module_7_list{list: &x.OrderMigrations} + return protoreflect.ValueOfList(value) case "cosmos.app.runtime.v1alpha1.Module.app_name": panic(fmt.Errorf("field app_name of message cosmos.app.runtime.v1alpha1.Module is not mutable")) default: @@ -598,6 +672,9 @@ func (x *fastReflection_Module) NewField(fd protoreflect.FieldDescriptor) protor case "cosmos.app.runtime.v1alpha1.Module.override_store_keys": list := []*StoreKeyConfig{} return protoreflect.ValueOfList(&_Module_6_list{list: &list}) + case "cosmos.app.runtime.v1alpha1.Module.order_migrations": + list := []string{} + return protoreflect.ValueOfList(&_Module_7_list{list: &list}) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.app.runtime.v1alpha1.Module")) @@ -701,6 +778,12 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { n += 1 + l + runtime.Sov(uint64(l)) } } + if len(x.OrderMigrations) > 0 { + for _, s := range x.OrderMigrations { + l = len(s) + n += 1 + l + runtime.Sov(uint64(l)) + } + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -730,6 +813,15 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.OrderMigrations) > 0 { + for iNdEx := len(x.OrderMigrations) - 1; iNdEx >= 0; iNdEx-- { + i -= len(x.OrderMigrations[iNdEx]) + copy(dAtA[i:], x.OrderMigrations[iNdEx]) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.OrderMigrations[iNdEx]))) + i-- + dAtA[i] = 0x3a + } + } if len(x.OverrideStoreKeys) > 0 { for iNdEx := len(x.OverrideStoreKeys) - 1; iNdEx >= 0; iNdEx-- { encoded, err := options.Marshal(x.OverrideStoreKeys[iNdEx]) @@ -1032,6 +1124,38 @@ func (x *fastReflection_Module) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 7: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field OrderMigrations", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrIntOverflow + } + if iNdEx >= l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + if postIndex > l { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, io.ErrUnexpectedEOF + } + x.OrderMigrations = append(x.OrderMigrations, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -1591,6 +1715,10 @@ type Module struct { // override_store_keys is an optional list of overrides for the module store keys // to be used in keeper construction. OverrideStoreKeys []*StoreKeyConfig `protobuf:"bytes,6,rep,name=override_store_keys,json=overrideStoreKeys,proto3" json:"override_store_keys,omitempty"` + // order_migrations defines the order in which module migrations are performed. + // If this is left empty, it uses the default migration order. + // https://pkg.go.dev/github.com/cosmos/cosmos-sdk@v0.47.0-alpha2/types/module#DefaultMigrationsOrder + OrderMigrations []string `protobuf:"bytes,7,rep,name=order_migrations,json=orderMigrations,proto3" json:"order_migrations,omitempty"` } func (x *Module) Reset() { @@ -1655,6 +1783,13 @@ func (x *Module) GetOverrideStoreKeys() []*StoreKeyConfig { return nil } +func (x *Module) GetOrderMigrations() []string { + if x != nil { + return x.OrderMigrations + } + return nil +} + // StoreKeyConfig may be supplied to override the default module store key, which // is the module name. type StoreKeyConfig struct { @@ -1711,7 +1846,7 @@ var file_cosmos_app_runtime_v1alpha1_module_proto_rawDesc = []byte{ 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x1a, 0x20, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2f, 0x6d, 0x6f, 0x64, - 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xd9, 0x02, 0x0a, 0x06, 0x4d, 0x6f, + 0x75, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x84, 0x03, 0x0a, 0x06, 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x61, 0x70, 0x70, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x61, 0x70, 0x70, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x25, 0x0a, 0x0e, 0x62, 0x65, 0x67, 0x69, 0x6e, 0x5f, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x65, 0x72, @@ -1729,32 +1864,35 @@ var file_cosmos_app_runtime_v1alpha1_module_proto_rawDesc = []byte{ 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x2e, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x4b, 0x65, 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x11, 0x6f, 0x76, 0x65, 0x72, 0x72, 0x69, 0x64, 0x65, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x4b, 0x65, 0x79, 0x73, - 0x3a, 0x43, 0xba, 0xc0, 0x96, 0xda, 0x01, 0x3d, 0x0a, 0x24, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, - 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x15, - 0x0a, 0x13, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x76, 0x31, 0x61, - 0x6c, 0x70, 0x68, 0x61, 0x31, 0x22, 0x53, 0x0a, 0x0e, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x4b, 0x65, - 0x79, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, - 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x6f, - 0x64, 0x75, 0x6c, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a, 0x0c, 0x6b, 0x76, 0x5f, 0x73, - 0x74, 0x6f, 0x72, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x6b, 0x76, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x4b, 0x65, 0x79, 0x42, 0xfb, 0x01, 0x0a, 0x1f, 0x63, - 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x72, 0x75, - 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x0b, - 0x4d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x72, 0x75, 0x6e, 0x74, 0x69, - 0x6d, 0x65, 0x2f, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x3b, 0x72, 0x75, 0x6e, 0x74, - 0x69, 0x6d, 0x65, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x41, - 0x52, 0xaa, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x70, 0x2e, 0x52, - 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xca, - 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x70, 0x5c, 0x52, 0x75, 0x6e, - 0x74, 0x69, 0x6d, 0x65, 0x5c, 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xe2, 0x02, 0x27, - 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x70, 0x5c, 0x52, 0x75, 0x6e, 0x74, 0x69, - 0x6d, 0x65, 0x5c, 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x3a, 0x3a, 0x41, 0x70, 0x70, 0x3a, 0x3a, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x3a, 0x3a, - 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x12, 0x29, 0x0a, 0x10, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x5f, 0x6d, 0x69, 0x67, 0x72, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0f, 0x6f, 0x72, 0x64, 0x65, + 0x72, 0x4d, 0x69, 0x67, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x3a, 0x43, 0xba, 0xc0, 0x96, + 0xda, 0x01, 0x3d, 0x0a, 0x24, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, + 0x6b, 0x2f, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x15, 0x0a, 0x13, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, + 0x22, 0x53, 0x0a, 0x0e, 0x53, 0x74, 0x6f, 0x72, 0x65, 0x4b, 0x65, 0x79, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5f, 0x6e, 0x61, 0x6d, + 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x4e, + 0x61, 0x6d, 0x65, 0x12, 0x20, 0x0a, 0x0c, 0x6b, 0x76, 0x5f, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x5f, + 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6b, 0x76, 0x53, 0x74, 0x6f, + 0x72, 0x65, 0x4b, 0x65, 0x79, 0x42, 0xfb, 0x01, 0x0a, 0x1f, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, + 0x2e, 0x76, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x42, 0x0b, 0x4d, 0x6f, 0x64, 0x75, 0x6c, + 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x2f, 0x76, 0x31, + 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x3b, 0x72, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x76, 0x31, + 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x41, 0x52, 0xaa, 0x02, 0x1b, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x70, 0x70, 0x2e, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, + 0x65, 0x2e, 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xca, 0x02, 0x1b, 0x43, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x5c, 0x41, 0x70, 0x70, 0x5c, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x5c, + 0x56, 0x31, 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0xe2, 0x02, 0x27, 0x43, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x5c, 0x41, 0x70, 0x70, 0x5c, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x5c, 0x56, 0x31, + 0x61, 0x6c, 0x70, 0x68, 0x61, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0xea, 0x02, 0x1e, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x41, 0x70, 0x70, + 0x3a, 0x3a, 0x52, 0x75, 0x6e, 0x74, 0x69, 0x6d, 0x65, 0x3a, 0x3a, 0x56, 0x31, 0x61, 0x6c, 0x70, + 0x68, 0x61, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/cosmos/consensus/v1/query.pulsar.go b/api/cosmos/consensus/v1/query.pulsar.go index 8cce55a6a622..2e60bb1777e1 100644 --- a/api/cosmos/consensus/v1/query.pulsar.go +++ b/api/cosmos/consensus/v1/query.pulsar.go @@ -820,7 +820,7 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) -// QueryParamsRequest defines the request type for querying x/consensus_param parameters. +// QueryParamsRequest defines the request type for querying x/consensus parameters. type QueryParamsRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -847,12 +847,15 @@ func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return file_cosmos_consensus_v1_query_proto_rawDescGZIP(), []int{0} } -// QueryParamsResponse defines the response type for querying x/consensus_param parameters. +// QueryParamsResponse defines the response type for querying x/consensus parameters. type QueryParamsResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields + // params are the tendermint consensus params stored in the consensus module. + // Please note that `params.version` is not populated in this response, it is + // tracked separately in the x/upgrade module. Params *types.ConsensusParams `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` } diff --git a/api/cosmos/consensus/v1/tx.pulsar.go b/api/cosmos/consensus/v1/tx.pulsar.go index b455e4ca0088..9fe12cdd84df 100644 --- a/api/cosmos/consensus/v1/tx.pulsar.go +++ b/api/cosmos/consensus/v1/tx.pulsar.go @@ -1051,7 +1051,7 @@ type MsgUpdateParams struct { // authority is the address of the governance account. Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` - // params defines the x/consensus_params parameters to update. + // params defines the x/consensus parameters to update. // VersionsParams is not included in this Msg because it is tracked // separarately in x/upgrade. // diff --git a/proto/cosmos/app/runtime/v1alpha1/module.proto b/proto/cosmos/app/runtime/v1alpha1/module.proto index 4598ba44dc2f..e92ce482f3f9 100644 --- a/proto/cosmos/app/runtime/v1alpha1/module.proto +++ b/proto/cosmos/app/runtime/v1alpha1/module.proto @@ -37,6 +37,11 @@ message Module { // override_store_keys is an optional list of overrides for the module store keys // to be used in keeper construction. repeated StoreKeyConfig override_store_keys = 6; + + // order_migrations defines the order in which module migrations are performed. + // If this is left empty, it uses the default migration order. + // https://pkg.go.dev/github.com/cosmos/cosmos-sdk@v0.47.0-alpha2/types/module#DefaultMigrationsOrder + repeated string order_migrations = 7; } // StoreKeyConfig may be supplied to override the default module store key, which diff --git a/proto/cosmos/base/store/snapshots/v1beta1/snapshot.proto b/proto/cosmos/base/store/snapshots/v1beta1/snapshot.proto index a525be2013db..a949edea3d4a 100644 --- a/proto/cosmos/base/store/snapshots/v1beta1/snapshot.proto +++ b/proto/cosmos/base/store/snapshots/v1beta1/snapshot.proto @@ -16,7 +16,7 @@ message Snapshot { // Metadata contains SDK-specific snapshot metadata. message Metadata { - repeated bytes chunk_hashes = 1; // SHA-256 chunk hashes + repeated bytes chunk_hashes = 1; // SHA-256 chunk hashes } // SnapshotItem is an item contained in a rootmulti.Store snapshot. diff --git a/proto/cosmos/base/store/v1beta1/listening.proto b/proto/cosmos/base/store/v1beta1/listening.proto index 753f7c165512..d6f7128931ea 100644 --- a/proto/cosmos/base/store/v1beta1/listening.proto +++ b/proto/cosmos/base/store/v1beta1/listening.proto @@ -20,15 +20,15 @@ message StoreKVPair { // BlockMetadata contains all the abci event data of a block // the file streamer dump them into files together with the state changes. message BlockMetadata { - // DeliverTx encapulate deliver tx request and response. - message DeliverTx { - tendermint.abci.RequestDeliverTx request = 1; - tendermint.abci.ResponseDeliverTx response = 2; - } - tendermint.abci.RequestBeginBlock request_begin_block = 1; - tendermint.abci.ResponseBeginBlock response_begin_block = 2; - repeated DeliverTx deliver_txs = 3; - tendermint.abci.RequestEndBlock request_end_block = 4; - tendermint.abci.ResponseEndBlock response_end_block = 5; - tendermint.abci.ResponseCommit response_commit = 6; + // DeliverTx encapulate deliver tx request and response. + message DeliverTx { + tendermint.abci.RequestDeliverTx request = 1; + tendermint.abci.ResponseDeliverTx response = 2; + } + tendermint.abci.RequestBeginBlock request_begin_block = 1; + tendermint.abci.ResponseBeginBlock response_begin_block = 2; + repeated DeliverTx deliver_txs = 3; + tendermint.abci.RequestEndBlock request_end_block = 4; + tendermint.abci.ResponseEndBlock response_end_block = 5; + tendermint.abci.ResponseCommit response_commit = 6; } diff --git a/proto/cosmos/evidence/v1beta1/evidence.proto b/proto/cosmos/evidence/v1beta1/evidence.proto index e77ab82f70f4..12ac5b6c3f29 100644 --- a/proto/cosmos/evidence/v1beta1/evidence.proto +++ b/proto/cosmos/evidence/v1beta1/evidence.proto @@ -17,14 +17,14 @@ message Equivocation { option (gogoproto.equal) = false; // height is the equivocation height. - int64 height = 1; + int64 height = 1; // time is the equivocation time. - google.protobuf.Timestamp time = 2 + google.protobuf.Timestamp time = 2 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true, (gogoproto.stdtime) = true]; - + // power is the equivocation validator power. - int64 power = 3; + int64 power = 3; // consensus_address is the equivocation validator consensus address. string consensus_address = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; diff --git a/proto/cosmos/evidence/v1beta1/tx.proto b/proto/cosmos/evidence/v1beta1/tx.proto index 826239529762..ad4c35c26a09 100644 --- a/proto/cosmos/evidence/v1beta1/tx.proto +++ b/proto/cosmos/evidence/v1beta1/tx.proto @@ -29,10 +29,10 @@ message MsgSubmitEvidence { option (gogoproto.goproto_getters) = false; // submitter is the signer account address of evidence. - string submitter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string submitter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // evidence defines the evidence of misbehavior. - google.protobuf.Any evidence = 2 [(cosmos_proto.accepts_interface) = "Evidence"]; + google.protobuf.Any evidence = 2 [(cosmos_proto.accepts_interface) = "Evidence"]; } // MsgSubmitEvidenceResponse defines the Msg/SubmitEvidence response type. diff --git a/proto/cosmos/gov/module/v1/module.proto b/proto/cosmos/gov/module/v1/module.proto index 9544cfe2b4d3..9cade9af0159 100644 --- a/proto/cosmos/gov/module/v1/module.proto +++ b/proto/cosmos/gov/module/v1/module.proto @@ -10,7 +10,7 @@ message Module { go_import: "github.com/cosmos/cosmos-sdk/x/gov" }; - // max_metadata_len defines the maximum proposal metadata length. + // max_metadata_len defines the maximum proposal metadata length. // Defaults to 255 if not explicitly set. uint64 max_metadata_len = 1; diff --git a/proto/cosmos/gov/v1/gov.proto b/proto/cosmos/gov/v1/gov.proto index 22baf185f7ab..a0ab8c0bf352 100644 --- a/proto/cosmos/gov/v1/gov.proto +++ b/proto/cosmos/gov/v1/gov.proto @@ -32,18 +32,18 @@ message WeightedVoteOption { VoteOption option = 1; // weight is the vote weight associated with the vote option. - string weight = 2 [(cosmos_proto.scalar) = "cosmos.Dec"]; + string weight = 2 [(cosmos_proto.scalar) = "cosmos.Dec"]; } // Deposit defines an amount deposited by an account address to an active // proposal. message Deposit { // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - + uint64 proposal_id = 1; + // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // amount to be deposited by depositor. repeated cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; } @@ -51,33 +51,33 @@ message Deposit { // Proposal defines the core field members of a governance proposal. message Proposal { // id defines the unique id of the proposal. - uint64 id = 1; + uint64 id = 1; // messages are the arbitrary messages to be executed if the proposal passes. repeated google.protobuf.Any messages = 2; // status defines the proposal status. - ProposalStatus status = 3; + ProposalStatus status = 3; // final_tally_result is the final tally result of the proposal. When // querying a proposal via gRPC, this field is not populated until the // proposal's voting period has ended. - TallyResult final_tally_result = 4; - + TallyResult final_tally_result = 4; + // submit_time is the time of proposal submission. - google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true]; - + google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true]; + // deposit_end_time is the end time for deposition. - google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true]; - + google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true]; + // total_deposit is the total deposit on the proposal. - repeated cosmos.base.v1beta1.Coin total_deposit = 7 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + repeated cosmos.base.v1beta1.Coin total_deposit = 7 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; + // voting_start_time is the starting time to vote on a proposal. - google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true]; - + google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true]; + // voting_end_time is the end time of voting on a proposal. - google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true]; + google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true]; // metadata is any arbitrary metadata attached to the proposal. string metadata = 10; @@ -107,11 +107,11 @@ enum ProposalStatus { // TallyResult defines a standard tally for a governance proposal. message TallyResult { // yes_count is the number of yes votes on a proposal. - string yes_count = 1 [(cosmos_proto.scalar) = "cosmos.Int"]; + string yes_count = 1 [(cosmos_proto.scalar) = "cosmos.Int"]; // abstain_count is the number of abstain votes on a proposal. - string abstain_count = 2 [(cosmos_proto.scalar) = "cosmos.Int"]; + string abstain_count = 2 [(cosmos_proto.scalar) = "cosmos.Int"]; // no_count is the number of no votes on a proposal. - string no_count = 3 [(cosmos_proto.scalar) = "cosmos.Int"]; + string no_count = 3 [(cosmos_proto.scalar) = "cosmos.Int"]; // no_with_veto_count is the number of no with veto votes on a proposal. string no_with_veto_count = 4 [(cosmos_proto.scalar) = "cosmos.Int"]; } @@ -123,8 +123,8 @@ message Vote { uint64 proposal_id = 1; // voter is the voter address of the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + reserved 3; // options is the weighted vote options. diff --git a/proto/cosmos/gov/v1/tx.proto b/proto/cosmos/gov/v1/tx.proto index e878bcd64b5d..adb421c84be9 100644 --- a/proto/cosmos/gov/v1/tx.proto +++ b/proto/cosmos/gov/v1/tx.proto @@ -46,14 +46,14 @@ message MsgSubmitProposal { option (amino.name) = "cosmos-sdk/v1/MsgSubmitProposal"; // messages are the arbitrary messages to be executed if proposal passes. - repeated google.protobuf.Any messages = 1; + repeated google.protobuf.Any messages = 1; // initial_deposit is the deposit value that must be paid at proposal submission. repeated cosmos.base.v1beta1.Coin initial_deposit = 2 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + // proposer is the account address of the proposer. - string proposer = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string proposer = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // metadata is any arbitrary metadata attached to the proposal. string metadata = 4; } @@ -85,16 +85,16 @@ message MsgVote { option (amino.name) = "cosmos-sdk/v1/MsgVote"; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; - + uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; + // voter is the voter address for the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // option defines the vote option. - VoteOption option = 3; - + VoteOption option = 3; + // metadata is any arbitrary metadata attached to the Vote. - string metadata = 4; + string metadata = 4; } // MsgVoteResponse defines the Msg/Vote response type. @@ -106,16 +106,16 @@ message MsgVoteWeighted { option (amino.name) = "cosmos-sdk/v1/MsgVoteWeighted"; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; - + uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; + // voter is the voter address for the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // options defines the weighted vote options. - repeated WeightedVoteOption options = 3; + repeated WeightedVoteOption options = 3; // metadata is any arbitrary metadata attached to the VoteWeighted. - string metadata = 4; + string metadata = 4; } // MsgVoteWeightedResponse defines the Msg/VoteWeighted response type. @@ -127,11 +127,11 @@ message MsgDeposit { option (amino.name) = "cosmos-sdk/v1/MsgDeposit"; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; - + uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; + // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // amount to be deposited by depositor. repeated cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; } diff --git a/proto/cosmos/gov/v1beta1/gov.proto b/proto/cosmos/gov/v1beta1/gov.proto index 72389c5ab5b0..c1f8f50ab89e 100644 --- a/proto/cosmos/gov/v1beta1/gov.proto +++ b/proto/cosmos/gov/v1beta1/gov.proto @@ -36,8 +36,8 @@ message WeightedVoteOption { // option defines the valid vote options, it must not contain duplicate vote options. VoteOption option = 1; - // weight is the vote weight associated with the vote option. - string weight = 2 [ + // weight is the vote weight associated with the vote option. + string weight = 2 [ (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false @@ -53,7 +53,7 @@ message TextProposal { option (gogoproto.equal) = true; // title of the proposal. - string title = 1; + string title = 1; // description associated with the proposal. string description = 2; @@ -66,11 +66,11 @@ message Deposit { option (gogoproto.equal) = false; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - + uint64 proposal_id = 1; + // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // amount to be deposited by depositor. repeated cosmos.base.v1beta1.Coin amount = 3 [ (gogoproto.nullable) = false, @@ -84,27 +84,27 @@ message Proposal { option (gogoproto.equal) = true; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; + uint64 proposal_id = 1; // content is the proposal's content. - google.protobuf.Any content = 2 [(cosmos_proto.accepts_interface) = "Content"]; - + google.protobuf.Any content = 2 [(cosmos_proto.accepts_interface) = "Content"]; + // status defines the proposal status. - ProposalStatus status = 3; - + ProposalStatus status = 3; + // final_tally_result is the final tally result of the proposal. When // querying a proposal via gRPC, this field is not populated until the // proposal's voting period has ended. - TallyResult final_tally_result = 4 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + TallyResult final_tally_result = 4 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; + // submit_time is the time of proposal submission. - google.protobuf.Timestamp submit_time = 5 + google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + // deposit_end_time is the end time for deposition. google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + // total_deposit is the total deposit on the proposal. repeated cosmos.base.v1beta1.Coin total_deposit = 7 [ (gogoproto.nullable) = false, @@ -115,7 +115,7 @@ message Proposal { // voting_start_time is the starting time to vote on a proposal. google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false, (amino.dont_omitempty) = true]; - + // voting_end_time is the end time of voting on a proposal. google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false, (amino.dont_omitempty) = true]; @@ -184,14 +184,14 @@ message Vote { // proposal_id defines the unique id of the proposal. uint64 proposal_id = 1 [(gogoproto.jsontag) = "id", (amino.field_name) = "id", (amino.dont_omitempty) = true]; - + // voter is the voter address of the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; // Deprecated: Prefer to use `options` instead. This field is set in queries // if and only if `len(options) == 1` and that option has weight 1. In all // other cases, this field will default to VOTE_OPTION_UNSPECIFIED. VoteOption option = 3 [deprecated = true]; - + // options is the weighted vote options. // // Since: cosmos-sdk 0.43 diff --git a/proto/cosmos/gov/v1beta1/tx.proto b/proto/cosmos/gov/v1beta1/tx.proto index e7ce61b583f0..4d88ef4ac4e1 100644 --- a/proto/cosmos/gov/v1beta1/tx.proto +++ b/proto/cosmos/gov/v1beta1/tx.proto @@ -40,8 +40,8 @@ message MsgSubmitProposal { option (gogoproto.goproto_getters) = false; // content is the proposal's content. - google.protobuf.Any content = 1 [(cosmos_proto.accepts_interface) = "Content"]; - + google.protobuf.Any content = 1 [(cosmos_proto.accepts_interface) = "Content"]; + // initial_deposit is the deposit value that must be paid at proposal submission. repeated cosmos.base.v1beta1.Coin initial_deposit = 2 [ (gogoproto.nullable) = false, @@ -68,13 +68,13 @@ message MsgVote { option (gogoproto.goproto_getters) = false; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; + uint64 proposal_id = 1; // voter is the voter address for the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // option defines the vote option. - VoteOption option = 3; + VoteOption option = 3; } // MsgVoteResponse defines the Msg/Vote response type. @@ -91,13 +91,13 @@ message MsgVoteWeighted { option (gogoproto.goproto_getters) = false; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; + uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; // voter is the voter address for the proposal. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // options defines the weighted vote options. - repeated WeightedVoteOption options = 3 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; + string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + + // options defines the weighted vote options. + repeated WeightedVoteOption options = 3 [(gogoproto.nullable) = false, (amino.dont_omitempty) = true]; } // MsgVoteWeightedResponse defines the Msg/VoteWeighted response type. @@ -115,11 +115,11 @@ message MsgDeposit { option (gogoproto.goproto_getters) = false; // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; - + uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id", (amino.dont_omitempty) = true]; + // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - + string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // amount to be deposited by depositor. repeated cosmos.base.v1beta1.Coin amount = 3 [ (gogoproto.nullable) = false, diff --git a/tx/textual/internal/testpb/1.proto b/tx/textual/internal/testpb/1.proto index fa3bf0d3744c..070e91264b78 100644 --- a/tx/textual/internal/testpb/1.proto +++ b/tx/textual/internal/testpb/1.proto @@ -27,31 +27,31 @@ message A { google.protobuf.Any ANY = 13; // Fields that are not handled by SIGN_MODE_TEXTUAL. - sint32 SINT32 = 101; - sint64 SINT64 = 102; - sfixed32 SFIXED32 = 105; - fixed32 FIXED32 = 106; - float FLOAT = 107; - sfixed64 SFIXED64 = 108; - fixed64 FIXED64 = 109; - double DOUBLE = 110; - map MAP = 111; + sint32 SINT32 = 101; + sint64 SINT64 = 102; + sfixed32 SFIXED32 = 105; + fixed32 FIXED32 = 106; + float FLOAT = 107; + sfixed64 SFIXED64 = 108; + fixed64 FIXED64 = 109; + double DOUBLE = 110; + map MAP = 111; } // Foo is a sample message type used for testing message rendering. message Foo { - string full_name = 1; - string nickname = 2; - google.protobuf.Timestamp mtime = 3; - Foo left = 4; - Foo right = 5; - Bar bar = 8; // skip some field numbers + string full_name = 1; + string nickname = 2; + google.protobuf.Timestamp mtime = 3; + Foo left = 4; + Foo right = 5; + Bar bar = 8; // skip some field numbers } // Bar is a sample message type used for testing message rendering. message Bar { - string bar_id = 1; - bytes data = 2; + string bar_id = 1; + bytes data = 2; google.protobuf.Any payload = 3; } @@ -74,19 +74,19 @@ message Baz { } enum BallotOption { - BALLOT_OPTION_UNSPECIFIED = 0; - BALLOT_OPTION_YES = 1; - BALLOT_OPTION_ABSTAIN = 2; - BALLOT_OPTION_NO = 3; + BALLOT_OPTION_UNSPECIFIED = 0; + BALLOT_OPTION_YES = 1; + BALLOT_OPTION_ABSTAIN = 2; + BALLOT_OPTION_NO = 3; BALLOT_OPTION_NO_WITH_VETO = 4; } // Qux is a sample message type used for testing repeated rendering. message Qux { - repeated Foo messages = 1; - repeated string string_messages = 2; - Ballot vote = 3; - repeated cosmos.base.v1beta1.Coin price = 4; + repeated Foo messages = 1; + repeated string string_messages = 2; + Ballot vote = 3; + repeated cosmos.base.v1beta1.Coin price = 4; repeated google.protobuf.Timestamp expirations = 5; } diff --git a/x/consensus/types/query.pb.go b/x/consensus/types/query.pb.go index cad159a682a2..6b66f70ff431 100644 --- a/x/consensus/types/query.pb.go +++ b/x/consensus/types/query.pb.go @@ -29,7 +29,7 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -// QueryParamsRequest defines the request type for querying x/consensus_param parameters. +// QueryParamsRequest defines the request type for querying x/consensus parameters. type QueryParamsRequest struct { } @@ -66,8 +66,11 @@ func (m *QueryParamsRequest) XXX_DiscardUnknown() { var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo -// QueryParamsResponse defines the response type for querying x/consensus_param parameters. +// QueryParamsResponse defines the response type for querying x/consensus parameters. type QueryParamsResponse struct { + // params are the tendermint consensus params stored in the consensus module. + // Please note that `params.version` is not populated in this response, it is + // tracked separately in the x/upgrade module. Params *types.ConsensusParams `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` } diff --git a/x/consensus/types/tx.pb.go b/x/consensus/types/tx.pb.go index 1c36f34eef75..6244d2ef8564 100644 --- a/x/consensus/types/tx.pb.go +++ b/x/consensus/types/tx.pb.go @@ -34,7 +34,7 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgUpdateParams struct { // authority is the address of the governance account. Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` - // params defines the x/consensus_params parameters to update. + // params defines the x/consensus parameters to update. // VersionsParams is not included in this Msg because it is tracked // separarately in x/upgrade. //