From e8678348ec567d1f19224a996fdf31a4cd9c87e4 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 8 Nov 2022 10:17:24 +0100 Subject: [PATCH 01/48] wip --- types/tx/amino/validate.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 types/tx/amino/validate.go diff --git a/types/tx/amino/validate.go b/types/tx/amino/validate.go new file mode 100644 index 00000000000..8f18177107e --- /dev/null +++ b/types/tx/amino/validate.go @@ -0,0 +1,14 @@ +package amino + +import ( + "github.com/cosmos/cosmos-sdk/codec" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" +) + +// ValidateAminoAnnotations validates the `amino.*` protobuf annotations. It +// performs the following validations: +// - Make sure `amino.name` is equal to the name in the Amino codec's +// registry. +func ValidateAminoAnnotations(interfaceRegistry codectypes.InterfaceRegistry, aminoCdc *codec.LegacyAmino) { + +} From 88cb125119cbab998f9ae84624dd780d7bb4282f Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 8 Nov 2022 16:19:55 +0100 Subject: [PATCH 02/48] feat: Validate Msg proto annotations --- baseapp/baseapp.go | 2 +- baseapp/deliver_tx_test.go | 2 +- baseapp/msg_service_router.go | 17 +++- baseapp/msg_service_router_test.go | 2 + testutil/testdata/tx.go | 6 +- testutil/testdata/tx.pb.go | 88 +++++++++++++---- testutil/testdata/tx.proto | 6 ++ testutil/testdata_pulsar/tx.pulsar.go | 131 ++++++++++++++++++++------ types/msgservice/validate.go | 70 ++++++++++++++ 9 files changed, 275 insertions(+), 49 deletions(-) create mode 100644 types/msgservice/validate.go diff --git a/baseapp/baseapp.go b/baseapp/baseapp.go index 2ff90cb8eff..d5f300ce4e9 100644 --- a/baseapp/baseapp.go +++ b/baseapp/baseapp.go @@ -152,7 +152,7 @@ func NewBaseApp( cms: store.NewCommitMultiStore(db), storeLoader: DefaultStoreLoader, grpcQueryRouter: NewGRPCQueryRouter(), - msgServiceRouter: NewMsgServiceRouter(), + msgServiceRouter: NewMsgServiceRouter(logger), txDecoder: txDecoder, fauxMerkleMode: false, } diff --git a/baseapp/deliver_tx_test.go b/baseapp/deliver_tx_test.go index dd819cccdd0..80aba78b639 100644 --- a/baseapp/deliver_tx_test.go +++ b/baseapp/deliver_tx_test.go @@ -97,7 +97,7 @@ func setupBaseAppWithSnapshots(t *testing.T, config *setupConfig) (*baseapp.Base registry := codectypes.NewInterfaceRegistry() cdc := codec.NewProtoCodec(registry) baseapptestutil.RegisterInterfaces(cdc.InterfaceRegistry()) - app.SetMsgServiceRouter(baseapp.NewMsgServiceRouter()) + app.SetMsgServiceRouter(baseapp.NewMsgServiceRouter(nil)) app.SetInterfaceRegistry(registry) baseapptestutil.RegisterKeyValueServer(app.MsgServiceRouter(), MsgKeyValueImpl{}) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 2df4e113d83..469f114f241 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -6,15 +6,18 @@ import ( gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" + "github.com/tendermint/tendermint/libs/log" "google.golang.org/grpc" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/types/msgservice" ) // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { + logger log.Logger interfaceRegistry codectypes.InterfaceRegistry routes map[string]MsgServiceHandler } @@ -22,7 +25,7 @@ type MsgServiceRouter struct { var _ gogogrpc.Server = &MsgServiceRouter{} // NewMsgServiceRouter creates a new MsgServiceRouter. -func NewMsgServiceRouter() *MsgServiceRouter { +func NewMsgServiceRouter(logger log.Logger) *MsgServiceRouter { return &MsgServiceRouter{ routes: map[string]MsgServiceHandler{}, } @@ -50,6 +53,12 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { + err := msgservice.ValidateServiceAnnotations(sd.ServiceName) + if err != nil { + // We might panic here in the future, instead of logging. + msr.logger.Info(fmt.Sprintf("The SDK is requiring protobuf annotation on Msgs; %+v", err)) + } + // Adds a top-level query handler based on the gRPC service name. for _, method := range sd.Methods { fqMethod := fmt.Sprintf("/%s/%s", sd.ServiceName, method.MethodName) @@ -69,6 +78,12 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(fmt.Errorf("unable to register service method %s: %T does not implement sdk.Msg", fqMethod, i)) } + err := msgservice.ValidateMsgAnnotations(proto.MessageName(msg)) + if err != nil { + // We might panic here in the future, instead of logging. + msr.logger.Info(fmt.Sprintf("The SDK is requiring protobuf annotation on sdMsgs; %+v", err)) + } + requestTypeName = sdk.MsgTypeURL(msg) return nil }, noopInterceptor) diff --git a/baseapp/msg_service_router_test.go b/baseapp/msg_service_router_test.go index 06e5bc3e9c8..227ced77bb8 100644 --- a/baseapp/msg_service_router_test.go +++ b/baseapp/msg_service_router_test.go @@ -47,6 +47,8 @@ func TestRegisterMsgService(t *testing.T) { testdata.MsgServerImpl{}, ) }) + + require.False(t, true) } func TestRegisterMsgServiceTwice(t *testing.T) { diff --git a/testutil/testdata/tx.go b/testutil/testdata/tx.go index 3d130b39887..55b16bb5a4d 100644 --- a/testutil/testdata/tx.go +++ b/testutil/testdata/tx.go @@ -107,5 +107,7 @@ func (msg *TestMsg) ValidateBasic() error { var _ sdk.Msg = &MsgCreateDog{} -func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return []sdk.AccAddress{} } -func (msg *MsgCreateDog) ValidateBasic() error { return nil } +func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { + return []sdk.AccAddress{sdk.MustAccAddressFromBech32(msg.Signer)} +} +func (msg *MsgCreateDog) ValidateBasic() error { return nil } diff --git a/testutil/testdata/tx.pb.go b/testutil/testdata/tx.pb.go index d291b1ee156..61bcb803385 100644 --- a/testutil/testdata/tx.pb.go +++ b/testutil/testdata/tx.pb.go @@ -6,6 +6,7 @@ package testdata import ( context "context" fmt "fmt" + _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -29,7 +30,8 @@ var _ = math.Inf const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCreateDog struct { - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` } func (m *MsgCreateDog) Reset() { *m = MsgCreateDog{} } @@ -72,6 +74,13 @@ func (m *MsgCreateDog) GetDog() *Dog { return nil } +func (m *MsgCreateDog) GetSigner() string { + if m != nil { + return m.Signer + } + return "" +} + type MsgCreateDogResponse struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` } @@ -164,24 +173,26 @@ func init() { func init() { proto.RegisterFile("tx.proto", fileDescriptor_0fd2153dc07d3b5c) } var fileDescriptor_0fd2153dc07d3b5c = []byte{ - // 258 bytes of a gzipped FileDescriptorProto + // 302 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x28, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x28, 0x49, 0x2d, 0x2e, 0x49, 0x49, 0x2c, 0x49, 0x94, 0x12, - 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x0b, 0xea, 0x83,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, 0x8c, 0x0a, 0xcc, 0x1a, 0x9c, 0x41, 0x30, 0xae, 0x15, 0x4b, 0xc7, 0x02, + 0x79, 0x06, 0xa3, 0x40, 0x2e, 0x66, 0x90, 0x32, 0x67, 0x2e, 0x4e, 0x84, 0x83, 0xc5, 0x10, 0x6e, + 0x44, 0xb6, 0x52, 0x4a, 0x0e, 0xbb, 0x38, 0xcc, 0x29, 0x52, 0xac, 0x0d, 0xcf, 0x37, 0x68, 0x31, + 0x3a, 0x79, 0x9c, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, + 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x5e, 0x7a, 0x66, + 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x3e, 0x34, 0xf4, 0x20, 0x94, 0x6e, 0x71, 0x4a, + 0xb6, 0x3e, 0xc8, 0xf0, 0xd2, 0x92, 0xcc, 0x1c, 0x7d, 0x98, 0x2d, 0x49, 0x6c, 0xe0, 0x00, 0x35, + 0x06, 0x04, 0x00, 0x00, 0xff, 0xff, 0x21, 0x5f, 0x39, 0x2a, 0xa5, 0x01, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -284,6 +295,13 @@ func (m *MsgCreateDog) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.Signer) > 0 { + i -= len(m.Signer) + copy(dAtA[i:], m.Signer) + i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) + i-- + dAtA[i] = 0x12 + } if m.Dog != nil { { size, err := m.Dog.MarshalToSizedBuffer(dAtA[:i]) @@ -382,6 +400,10 @@ func (m *MsgCreateDog) Size() (n int) { l = m.Dog.Size() n += 1 + l + sovTx(uint64(l)) } + l = len(m.Signer) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } return n } @@ -484,6 +506,38 @@ func (m *MsgCreateDog) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) diff --git a/testutil/testdata/tx.proto b/testutil/testdata/tx.proto index eaeb9580e5e..2a812bb4471 100644 --- a/testutil/testdata/tx.proto +++ b/testutil/testdata/tx.proto @@ -3,17 +3,23 @@ package testdata; import "gogoproto/gogo.proto"; import "testdata.proto"; +import "cosmos/msg/v1/msg.proto"; option go_package = "github.com/cosmos/cosmos-sdk/testutil/testdata"; // Msg tests the Protobuf message service as defined in // https://github.com/cosmos/cosmos-sdk/issues/7500. service Msg { + option (cosmos.msg.v1.service) = true; + rpc CreateDog(MsgCreateDog) returns (MsgCreateDogResponse); } message MsgCreateDog { + option (cosmos.msg.v1.signer) = "signer"; + testdata.Dog dog = 1; + string signer = 2; } message MsgCreateDogResponse { diff --git a/testutil/testdata_pulsar/tx.pulsar.go b/testutil/testdata_pulsar/tx.pulsar.go index 1f171f9bd91..7fbd3cf3ceb 100644 --- a/testutil/testdata_pulsar/tx.pulsar.go +++ b/testutil/testdata_pulsar/tx.pulsar.go @@ -2,6 +2,7 @@ package testdata_pulsar import ( + _ "cosmossdk.io/api/cosmos/msg/v1" fmt "fmt" runtime "github.com/cosmos/cosmos-proto/runtime" _ "github.com/cosmos/gogoproto/gogoproto" @@ -14,14 +15,16 @@ import ( ) var ( - md_MsgCreateDog protoreflect.MessageDescriptor - fd_MsgCreateDog_dog protoreflect.FieldDescriptor + md_MsgCreateDog protoreflect.MessageDescriptor + fd_MsgCreateDog_dog protoreflect.FieldDescriptor + fd_MsgCreateDog_signer protoreflect.FieldDescriptor ) func init() { file_tx_proto_init() md_MsgCreateDog = File_tx_proto.Messages().ByName("MsgCreateDog") fd_MsgCreateDog_dog = md_MsgCreateDog.Fields().ByName("dog") + fd_MsgCreateDog_signer = md_MsgCreateDog.Fields().ByName("signer") } var _ protoreflect.Message = (*fastReflection_MsgCreateDog)(nil) @@ -95,6 +98,12 @@ func (x *fastReflection_MsgCreateDog) Range(f func(protoreflect.FieldDescriptor, return } } + if x.Signer != "" { + value := protoreflect.ValueOfString(x.Signer) + if !f(fd_MsgCreateDog_signer, value) { + return + } + } } // Has reports whether a field is populated. @@ -112,6 +121,8 @@ func (x *fastReflection_MsgCreateDog) Has(fd protoreflect.FieldDescriptor) bool switch fd.FullName() { case "testdata.MsgCreateDog.dog": return x.Dog != nil + case "testdata.MsgCreateDog.signer": + return x.Signer != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -130,6 +141,8 @@ func (x *fastReflection_MsgCreateDog) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "testdata.MsgCreateDog.dog": x.Dog = nil + case "testdata.MsgCreateDog.signer": + x.Signer = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -149,6 +162,9 @@ func (x *fastReflection_MsgCreateDog) Get(descriptor protoreflect.FieldDescripto case "testdata.MsgCreateDog.dog": value := x.Dog return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "testdata.MsgCreateDog.signer": + value := x.Signer + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -171,6 +187,8 @@ func (x *fastReflection_MsgCreateDog) Set(fd protoreflect.FieldDescriptor, value switch fd.FullName() { case "testdata.MsgCreateDog.dog": x.Dog = value.Message().Interface().(*Dog) + case "testdata.MsgCreateDog.signer": + x.Signer = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -196,6 +214,8 @@ func (x *fastReflection_MsgCreateDog) Mutable(fd protoreflect.FieldDescriptor) p x.Dog = new(Dog) } return protoreflect.ValueOfMessage(x.Dog.ProtoReflect()) + case "testdata.MsgCreateDog.signer": + panic(fmt.Errorf("field signer of message testdata.MsgCreateDog is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -212,6 +232,8 @@ func (x *fastReflection_MsgCreateDog) NewField(fd protoreflect.FieldDescriptor) case "testdata.MsgCreateDog.dog": m := new(Dog) return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "testdata.MsgCreateDog.signer": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -285,6 +307,10 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { l = options.Size(x.Dog) n += 1 + l + runtime.Sov(uint64(l)) } + l = len(x.Signer) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -314,6 +340,13 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.Signer) > 0 { + i -= len(x.Signer) + copy(dAtA[i:], x.Signer) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Signer))) + i-- + dAtA[i] = 0x12 + } if x.Dog != nil { encoded, err := options.Marshal(x.Dog) if err != nil { @@ -413,6 +446,38 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Signer", 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.Signer = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -1366,7 +1431,8 @@ type MsgCreateDog struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` } func (x *MsgCreateDog) Reset() { @@ -1396,6 +1462,13 @@ func (x *MsgCreateDog) GetDog() *Dog { return nil } +func (x *MsgCreateDog) GetSigner() string { + if x != nil { + return x.Signer + } + return "" +} + type MsgCreateDogResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1474,30 +1547,34 @@ var file_tx_proto_rawDesc = []byte{ 0x0a, 0x08, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0e, 0x74, 0x65, 0x73, 0x74, - 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x2f, 0x0a, 0x0c, 0x4d, 0x73, - 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x1f, 0x0a, 0x03, 0x64, 0x6f, - 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, - 0x74, 0x61, 0x2e, 0x44, 0x6f, 0x67, 0x52, 0x03, 0x64, 0x6f, 0x67, 0x22, 0x2a, 0x0a, 0x14, 0x4d, - 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, - 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, - 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, - 0x1f, 0x00, 0x32, 0x4a, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, - 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, - 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x8e, - 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x42, - 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x35, 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, 0x74, 0x65, 0x73, 0x74, 0x75, 0x74, 0x69, - 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x70, 0x75, 0x6c, 0x73, 0x61, - 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, - 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xe2, 0x02, 0x14, - 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x22, 0x54, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x44, 0x6f, 0x67, 0x12, 0x1f, 0x0a, 0x03, 0x64, 0x6f, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x0d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x6f, 0x67, 0x52, + 0x03, 0x64, 0x6f, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x3a, 0x0b, 0x82, 0xe7, + 0xb0, 0x2a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, + 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, + 0x09, 0x52, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, + 0x32, 0x51, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x44, 0x6f, 0x67, 0x12, 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, + 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, 0x2e, 0x74, + 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, + 0xb0, 0x2a, 0x01, 0x42, 0x8e, 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, 0x74, 0x65, 0x73, 0x74, + 0x64, 0x61, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x35, 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, 0x74, 0x65, + 0x73, 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5f, + 0x70, 0x75, 0x6c, 0x73, 0x61, 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x54, + 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, + 0x74, 0x61, 0xe2, 0x02, 0x14, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, + 0x64, 0x61, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go new file mode 100644 index 00000000000..61d7aae69ca --- /dev/null +++ b/types/msgservice/validate.go @@ -0,0 +1,70 @@ +package msgservice + +import ( + "fmt" + + "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protoreflect" + "google.golang.org/protobuf/reflect/protoregistry" + + msg "cosmossdk.io/api/cosmos/msg/v1" +) + +// ValidateServiceAnnotations validates that all Msg services have the +// `(cosmos.msg.v1.service) = true` proto annotation. +func ValidateServiceAnnotations(serviceName string) error { + sd, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(serviceName)) + if err != nil { + return fmt.Errorf("error with Msg service %s; %+v", serviceName, err) + } + + ext := proto.GetExtension(sd.Options(), msg.E_Service) + hasOption, ok := ext.(bool) + if !ok { + return fmt.Errorf("expected bool, got %T", ext) + } + + if !hasOption { + return fmt.Errorf("service %s does not have cosmos.msg.v1.service proto annotation", serviceName) + } + + return nil +} + +// ValidateMsgAnnotations validates that all sdk.Msg services have the correct +// `(cosmos.msg.v1.signer) = "..."` proto annotation. +func ValidateMsgAnnotations(fqName string) error { + d, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(fqName)) + if err != nil { + return fmt.Errorf("error with sdk.Msg %s; %+v", fqName, err) + } + md := d.(protoreflect.MessageDescriptor) + + ext := proto.GetExtension(md.Options(), msg.E_Signer) + signers, ok := ext.([]string) + if !ok { + return fmt.Errorf("expected bool, got %T", ext) + } + + if len(signers) == 0 { + return fmt.Errorf("sdk.Msg %s does not have cosmos.msg.v1.signer proto annotation", fqName) + } + + for i, signer := range signers { + if signer == "" { + return fmt.Errorf("sdk.Msg %s signer at index %d is empty", fqName, i) + } + + // Make sure the signer annotation is a correct field of type string + fd := md.Fields().ByName(protoreflect.Name(signer)) + if fd == nil { + return fmt.Errorf("sdk.Msg %s has incorrect signer %s", fqName, signer) + } + + if fd.Kind() != protoreflect.StringKind { + return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string, got %s", fqName, signer, fd.Kind()) + } + } + + return nil +} From 4e88fe66702ff0a840ddb63f81f111ac0ae1a021 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 8 Nov 2022 16:40:56 +0100 Subject: [PATCH 03/48] Regenerate --- api/cosmos/consensus/v1/tx.pulsar.go | 30 ++-- api/cosmos/group/v1/tx.pulsar.go | 245 ++++++++++++++------------- baseapp/baseapp.go | 2 +- baseapp/deliver_tx_test.go | 2 +- baseapp/msg_service_router.go | 6 +- proto/cosmos/consensus/v1/tx.proto | 2 + proto/cosmos/group/v1/tx.proto | 2 +- types/msgservice/validate.go | 19 +++ x/consensus/types/tx.pb.go | 16 +- x/group/tx.pb.go | 172 +++++++++---------- 10 files changed, 259 insertions(+), 237 deletions(-) diff --git a/api/cosmos/consensus/v1/tx.pulsar.go b/api/cosmos/consensus/v1/tx.pulsar.go index fbfaf5d071d..6c0b7a7ff1e 100644 --- a/api/cosmos/consensus/v1/tx.pulsar.go +++ b/api/cosmos/consensus/v1/tx.pulsar.go @@ -1165,26 +1165,26 @@ var file_cosmos_consensus_v1_tx_proto_rawDesc = []byte{ 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x19, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x32, 0x69, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x62, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, + 0x65, 0x32, 0x70, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x62, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, - 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0xc2, 0x01, 0x0a, - 0x17, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, - 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, - 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6e, - 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, - 0x73, 0x75, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x43, 0x58, 0xaa, 0x02, 0x13, 0x43, 0x6f, - 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x56, - 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, - 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, - 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x15, 0x43, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x3a, 0x3a, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x3a, 0x3a, 0x56, - 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, + 0xb0, 0x2a, 0x01, 0x42, 0xc2, 0x01, 0x0a, 0x17, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x42, + 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, + 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, + 0x3b, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, + 0x43, 0x58, 0xaa, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, + 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, + 0x1f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, + 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0xea, 0x02, 0x15, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x43, 0x6f, 0x6e, 0x73, 0x65, + 0x6e, 0x73, 0x75, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/api/cosmos/group/v1/tx.pulsar.go b/api/cosmos/group/v1/tx.pulsar.go index 2d9b105c8cf..5a4647b5992 100644 --- a/api/cosmos/group/v1/tx.pulsar.go +++ b/api/cosmos/group/v1/tx.pulsar.go @@ -15100,138 +15100,139 @@ var file_cosmos_group_v1_tx_proto_rawDesc = []byte{ 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x76, 0x6f, 0x74, 0x65, 0x72, 0x8a, 0xe7, 0xb0, 0x2a, 0x18, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2f, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x22, 0x11, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x56, 0x6f, - 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x8a, 0x01, 0x0a, 0x07, 0x4d, + 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x8c, 0x01, 0x0a, 0x07, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x49, 0x64, 0x12, 0x34, 0x0a, 0x08, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, - 0x69, 0x6e, 0x67, 0x52, 0x08, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x3a, 0x28, 0x82, - 0xe7, 0xb0, 0x2a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x8a, 0xe7, 0xb0, 0x2a, 0x18, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2f, - 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x22, 0x52, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x45, 0x78, - 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x06, 0x72, 0x65, - 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, - 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, 0x65, 0x73, - 0x75, 0x6c, 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x8f, 0x01, 0x0a, 0x0d, - 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x32, 0x0a, - 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, - 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, - 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x3a, 0x2f, 0x82, 0xe7, - 0xb0, 0x2a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x8a, 0xe7, 0xb0, 0x2a, 0x1e, 0x63, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2f, - 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x22, 0x17, 0x0a, - 0x15, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2a, 0x2a, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x14, - 0x0a, 0x10, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, - 0x45, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x54, 0x52, 0x59, - 0x10, 0x01, 0x32, 0xca, 0x0b, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x57, 0x0a, 0x0b, 0x43, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x1a, 0x27, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x12, 0x6c, 0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, - 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, - 0x73, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, - 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, - 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x66, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x2c, 0x2e, 0x63, 0x6f, + 0x69, 0x6e, 0x67, 0x52, 0x08, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x3a, 0x2a, 0x82, + 0xe7, 0xb0, 0x2a, 0x08, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x8a, 0xe7, 0xb0, 0x2a, + 0x18, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x2f, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x22, 0x52, 0x0a, 0x0f, 0x4d, 0x73, 0x67, + 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x06, + 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x50, + 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x45, 0x78, 0x65, 0x63, 0x75, 0x74, 0x6f, 0x72, 0x52, + 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x8f, 0x01, + 0x0a, 0x0d, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, + 0x32, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x18, 0xd2, 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, + 0x72, 0x65, 0x73, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, + 0x65, 0x73, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x3a, 0x2f, + 0x82, 0xe7, 0xb0, 0x2a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x8a, 0xe7, 0xb0, 0x2a, + 0x1e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2d, 0x73, 0x64, 0x6b, 0x2f, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x2f, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x22, + 0x17, 0x0a, 0x15, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2a, 0x2a, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, + 0x12, 0x14, 0x0a, 0x10, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, + 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x45, 0x58, 0x45, 0x43, 0x5f, 0x54, + 0x52, 0x59, 0x10, 0x01, 0x32, 0xca, 0x0b, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x57, 0x0a, 0x0b, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1f, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x1a, 0x27, 0x2e, 0x63, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, + 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6c, 0x0a, 0x12, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, + 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x12, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, - 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, - 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6f, 0x0a, 0x13, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, - 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, + 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, + 0x65, 0x72, 0x73, 0x1a, 0x2e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, + 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, + 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x2c, 0x2e, + 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x41, 0x64, + 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x6f, 0x0a, 0x13, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, 0x11, 0x43, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, - 0x25, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, - 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, - 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x29, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, - 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, - 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x31, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x78, 0x0a, 0x16, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, - 0x69, 0x6e, 0x1a, 0x32, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, + 0x74, 0x61, 0x12, 0x27, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x93, 0x01, 0x0a, 0x1f, 0x55, 0x70, 0x64, 0x61, 0x74, - 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, - 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x33, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, - 0x3b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, - 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, - 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x81, 0x01, 0x0a, - 0x19, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, - 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, - 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x35, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x60, 0x0a, 0x0e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, - 0x61, 0x6c, 0x12, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, - 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, - 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x66, 0x0a, 0x10, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, - 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, - 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2c, 0x2e, 0x63, + 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x2f, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x69, 0x0a, 0x11, + 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, + 0x79, 0x12, 0x25, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x75, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x12, 0x29, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, + 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x57, 0x69, 0x74, 0x68, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x1a, 0x31, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x57, 0x69, 0x74, 0x68, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x78, + 0x0a, 0x16, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, + 0x64, 0x6d, 0x69, 0x6e, 0x1a, 0x32, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x93, 0x01, 0x0a, 0x1f, 0x55, 0x70, 0x64, + 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, + 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x33, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, - 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x04, 0x56, 0x6f, - 0x74, 0x65, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x1a, 0x20, 0x2e, 0x63, + 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, + 0x79, 0x1a, 0x3b, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, + 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x44, 0x65, 0x63, 0x69, 0x73, 0x69, 0x6f, 0x6e, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x81, + 0x01, 0x0a, 0x19, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, + 0x6c, 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x2d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, - 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, - 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, - 0x1a, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x54, 0x0a, 0x0a, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x12, 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x1a, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, - 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, 0x2a, 0x01, 0x42, - 0xa6, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, - 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x28, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, 0x72, 0x6f, 0x75, - 0x70, 0x2f, 0x76, 0x31, 0x3b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, - 0x47, 0x58, 0xaa, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x72, 0x6f, 0x75, - 0x70, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x47, 0x72, - 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, - 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x47, - 0x72, 0x6f, 0x75, 0x70, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, + 0x69, 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x35, 0x2e, 0x63, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, + 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x50, 0x6f, 0x6c, 0x69, + 0x63, 0x79, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x60, 0x0a, 0x0e, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x22, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, 0x62, 0x6d, 0x69, 0x74, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2a, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x53, 0x75, + 0x62, 0x6d, 0x69, 0x74, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x10, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, + 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, + 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x1a, 0x2c, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x73, 0x67, 0x57, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x50, 0x72, 0x6f, 0x70, + 0x6f, 0x73, 0x61, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x42, 0x0a, 0x04, + 0x56, 0x6f, 0x74, 0x65, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x1a, 0x20, + 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, + 0x2e, 0x4d, 0x73, 0x67, 0x56, 0x6f, 0x74, 0x65, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x12, 0x42, 0x0a, 0x04, 0x45, 0x78, 0x65, 0x63, 0x12, 0x18, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, + 0x65, 0x63, 0x1a, 0x20, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x45, 0x78, 0x65, 0x63, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x54, 0x0a, 0x0a, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x12, 0x1e, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x1a, 0x26, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x67, 0x72, 0x6f, 0x75, + 0x70, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x4c, 0x65, 0x61, 0x76, 0x65, 0x47, 0x72, 0x6f, + 0x75, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, 0x2a, + 0x01, 0x42, 0xa6, 0x01, 0x0a, 0x13, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x28, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, + 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x67, 0x72, + 0x6f, 0x75, 0x70, 0x2f, 0x76, 0x31, 0x3b, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x76, 0x31, 0xa2, 0x02, + 0x03, 0x43, 0x47, 0x58, 0xaa, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x47, 0x72, + 0x6f, 0x75, 0x70, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x0f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, + 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1b, 0x43, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x5c, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x11, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, + 0x3a, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x33, } var ( diff --git a/baseapp/baseapp.go b/baseapp/baseapp.go index d5f300ce4e9..2ff90cb8eff 100644 --- a/baseapp/baseapp.go +++ b/baseapp/baseapp.go @@ -152,7 +152,7 @@ func NewBaseApp( cms: store.NewCommitMultiStore(db), storeLoader: DefaultStoreLoader, grpcQueryRouter: NewGRPCQueryRouter(), - msgServiceRouter: NewMsgServiceRouter(logger), + msgServiceRouter: NewMsgServiceRouter(), txDecoder: txDecoder, fauxMerkleMode: false, } diff --git a/baseapp/deliver_tx_test.go b/baseapp/deliver_tx_test.go index 80aba78b639..dd819cccdd0 100644 --- a/baseapp/deliver_tx_test.go +++ b/baseapp/deliver_tx_test.go @@ -97,7 +97,7 @@ func setupBaseAppWithSnapshots(t *testing.T, config *setupConfig) (*baseapp.Base registry := codectypes.NewInterfaceRegistry() cdc := codec.NewProtoCodec(registry) baseapptestutil.RegisterInterfaces(cdc.InterfaceRegistry()) - app.SetMsgServiceRouter(baseapp.NewMsgServiceRouter(nil)) + app.SetMsgServiceRouter(baseapp.NewMsgServiceRouter()) app.SetInterfaceRegistry(registry) baseapptestutil.RegisterKeyValueServer(app.MsgServiceRouter(), MsgKeyValueImpl{}) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 469f114f241..5a697270781 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -25,7 +25,7 @@ type MsgServiceRouter struct { var _ gogogrpc.Server = &MsgServiceRouter{} // NewMsgServiceRouter creates a new MsgServiceRouter. -func NewMsgServiceRouter(logger log.Logger) *MsgServiceRouter { +func NewMsgServiceRouter() *MsgServiceRouter { return &MsgServiceRouter{ routes: map[string]MsgServiceHandler{}, } @@ -56,7 +56,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter err := msgservice.ValidateServiceAnnotations(sd.ServiceName) if err != nil { // We might panic here in the future, instead of logging. - msr.logger.Info(fmt.Sprintf("The SDK is requiring protobuf annotation on Msgs; %+v", err)) + fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) } // Adds a top-level query handler based on the gRPC service name. @@ -81,7 +81,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter err := msgservice.ValidateMsgAnnotations(proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. - msr.logger.Info(fmt.Sprintf("The SDK is requiring protobuf annotation on sdMsgs; %+v", err)) + fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) } requestTypeName = sdk.MsgTypeURL(msg) diff --git a/proto/cosmos/consensus/v1/tx.proto b/proto/cosmos/consensus/v1/tx.proto index ae0473a0a41..fa2421f7cd2 100644 --- a/proto/cosmos/consensus/v1/tx.proto +++ b/proto/cosmos/consensus/v1/tx.proto @@ -10,6 +10,8 @@ option go_package = "github.com/cosmos/cosmos-sdk/x/consensus/types"; // Msg defines the bank Msg service. service Msg { + option (cosmos.msg.v1.service) = true; + // UpdateParams defines a governance operation for updating the x/consensus_param module parameters. // The authority is defined in the keeper. // diff --git a/proto/cosmos/group/v1/tx.proto b/proto/cosmos/group/v1/tx.proto index cf8a2788632..48aff96b34a 100644 --- a/proto/cosmos/group/v1/tx.proto +++ b/proto/cosmos/group/v1/tx.proto @@ -356,7 +356,7 @@ message MsgVoteResponse {} // MsgExec is the Msg/Exec request type. message MsgExec { - option (cosmos.msg.v1.signer) = "signer"; + option (cosmos.msg.v1.signer) = "executor"; option (amino.name) = "cosmos-sdk/group/MsgExec"; // proposal is the unique ID of the proposal. diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index 61d7aae69ca..ba9d2b0b47f 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -8,6 +8,25 @@ import ( "google.golang.org/protobuf/reflect/protoregistry" msg "cosmossdk.io/api/cosmos/msg/v1" + + // Import the descriptors + _ "cosmossdk.io/api/cosmos/auth/v1beta1" + _ "cosmossdk.io/api/cosmos/authz/v1beta1" + _ "cosmossdk.io/api/cosmos/bank/v1beta1" + _ "cosmossdk.io/api/cosmos/consensus/v1" + _ "cosmossdk.io/api/cosmos/crisis/v1beta1" + _ "cosmossdk.io/api/cosmos/distribution/v1beta1" + _ "cosmossdk.io/api/cosmos/evidence/v1beta1" + _ "cosmossdk.io/api/cosmos/feegrant/v1beta1" + _ "cosmossdk.io/api/cosmos/gov/v1" + _ "cosmossdk.io/api/cosmos/gov/v1beta1" + _ "cosmossdk.io/api/cosmos/group/v1" + _ "cosmossdk.io/api/cosmos/mint/v1beta1" + _ "cosmossdk.io/api/cosmos/nft/v1beta1" + _ "cosmossdk.io/api/cosmos/slashing/v1beta1" + _ "cosmossdk.io/api/cosmos/staking/v1beta1" + _ "cosmossdk.io/api/cosmos/upgrade/v1beta1" + _ "cosmossdk.io/api/cosmos/vesting/v1beta1" ) // ValidateServiceAnnotations validates that all Msg services have the diff --git a/x/consensus/types/tx.pb.go b/x/consensus/types/tx.pb.go index d8ef6119430..fa3f98efc68 100644 --- a/x/consensus/types/tx.pb.go +++ b/x/consensus/types/tx.pb.go @@ -149,7 +149,7 @@ func init() { func init() { proto.RegisterFile("cosmos/consensus/v1/tx.proto", fileDescriptor_2135c60575ab504d) } var fileDescriptor_2135c60575ab504d = []byte{ - // 370 bytes of a gzipped FileDescriptorProto + // 378 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x49, 0xce, 0x2f, 0xce, 0xcd, 0x2f, 0xd6, 0x4f, 0xce, 0xcf, 0x2b, 0x4e, 0xcd, 0x2b, 0x2e, 0x2d, 0xd6, 0x2f, 0x33, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x86, 0xc8, 0xea, 0xc1, 0x65, 0xf5, @@ -166,14 +166,14 @@ var fileDescriptor_2135c60575ab504d = []byte{ 0xeb, 0x53, 0xc0, 0xd4, 0xe7, 0x0a, 0x55, 0x01, 0xd5, 0x0a, 0xd7, 0x21, 0x64, 0xcf, 0xc5, 0x59, 0x96, 0x98, 0x93, 0x99, 0x92, 0x58, 0x92, 0x5f, 0x24, 0xc1, 0x02, 0xd6, 0xae, 0x88, 0xa9, 0x3d, 0x0c, 0xa6, 0x04, 0xaa, 0x1f, 0xa1, 0xc7, 0x8a, 0xaf, 0xe9, 0xf9, 0x06, 0x2d, 0x84, 0x1f, 0x94, - 0x24, 0xb9, 0xc4, 0xd1, 0x82, 0x23, 0x28, 0xb5, 0xb8, 0x00, 0x14, 0x09, 0x46, 0x99, 0x5c, 0xcc, + 0x24, 0xb9, 0xc4, 0xd1, 0x82, 0x23, 0x28, 0xb5, 0xb8, 0x00, 0x14, 0x09, 0x46, 0x05, 0x5c, 0xcc, 0xbe, 0xc5, 0xe9, 0x42, 0x49, 0x5c, 0x3c, 0x28, 0xa1, 0xa5, 0xa2, 0x87, 0x25, 0xaa, 0xf4, 0xd0, - 0x0c, 0x91, 0xd2, 0x21, 0x46, 0x15, 0xcc, 0x2a, 0x27, 0x8f, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, - 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, - 0x3c, 0x96, 0x63, 0x88, 0xd2, 0x4b, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, - 0x87, 0x27, 0x20, 0x10, 0xa5, 0x5b, 0x9c, 0x92, 0xad, 0x5f, 0x81, 0x94, 0x9a, 0xc0, 0x5e, 0x4f, - 0x62, 0x03, 0x47, 0xb3, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0x3b, 0x89, 0xc5, 0x6c, 0x6e, 0x02, - 0x00, 0x00, + 0x0c, 0x91, 0xd2, 0x21, 0x46, 0x15, 0xcc, 0x2a, 0x29, 0xd6, 0x86, 0xe7, 0x1b, 0xb4, 0x18, 0x9d, + 0x3c, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, + 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x2f, 0x3d, 0xb3, 0x24, + 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x9e, 0x8e, 0x40, 0x94, 0x6e, 0x71, 0x4a, 0xb6, + 0x7e, 0x05, 0x52, 0xa2, 0x02, 0x87, 0x40, 0x12, 0x1b, 0x38, 0xb6, 0x8d, 0x01, 0x01, 0x00, 0x00, + 0xff, 0xff, 0xf7, 0x5c, 0x67, 0xfe, 0x75, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/group/tx.pb.go b/x/group/tx.pb.go index c472341c6a7..e2c81aa0368 100644 --- a/x/group/tx.pb.go +++ b/x/group/tx.pb.go @@ -1496,96 +1496,96 @@ func init() { func init() { proto.RegisterFile("cosmos/group/v1/tx.proto", fileDescriptor_6b8d3d629f136420) } var fileDescriptor_6b8d3d629f136420 = []byte{ - // 1413 bytes of a gzipped FileDescriptorProto + // 1412 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x58, 0xcd, 0x6f, 0x1b, 0x45, 0x14, 0xcf, 0xda, 0x6e, 0x3e, 0x5e, 0xa8, 0x9b, 0x6c, 0x93, 0xd6, 0xd9, 0xb6, 0x6b, 0x77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 0x78, 0x76, + 0x3f, 0xef, 0x32, 0x56, 0xc0, 0xda, 0x07, 0x25, 0x3e, 0x74, 0xb4, 0x0e, 0x27, 0xf8, 0x15, 0x45, + 0xc7, 0x6d, 0xab, 0x85, 0x75, 0x71, 0x09, 0xa6, 0x49, 0x34, 0x75, 0x53, 0x23, 0x79, 0xa5, 0x94, + 0x29, 0xf2, 0xbd, 0xa5, 0xa1, 0xbf, 0x04, 0x58, 0xac, 0x61, 0xe3, 0x56, 0x5b, 0xf3, 0xb4, 0x6a, + 0x6e, 0x50, 0x87, 0x65, 0xc2, 0xef, 0x24, 0xc1, 0x39, 0x11, 0xb7, 0x21, 0x4d, 0x53, 0xad, 0x77, + 0x89, 0x1f, 0x9c, 0x49, 0x1e, 0x96, 0xab, 0xa3, 0xd4, 0x00, 0x8d, 0x13, 0x57, 0x4a, 0x3c, 0x2b, + 0x39, 0x9e, 0x95, 0x60, 0x36, 0x28, 0x0b, 0x67, 0x42, 0x05, 0x1e, 0x47, 0xe8, 0x17, 0x01, 0x8e, + 0xf3, 0x88, 0x6b, 0x24, 0xad, 0x31, 0xd2, 0x70, 0x05, 0x66, 0x5a, 0xfa, 0xbd, 0x3a, 0x35, 0x97, + 0x8c, 0x31, 0x37, 0xdd, 0xd2, 0xef, 0x91, 0x08, 0x2a, 0x05, 0x3e, 0x57, 0x39, 0x32, 0x57, 0x02, + 0x47, 0x67, 0xe0, 0x54, 0xc8, 0x32, 0xcb, 0xf3, 0x47, 0x81, 0x94, 0x09, 0xc7, 0x04, 0x2d, 0xb5, + 0x71, 0xa6, 0x3a, 0xa8, 0xa2, 0x2f, 0xf3, 0xf9, 0x9c, 0x1d, 0xb0, 0x77, 0x54, 0x03, 0xe5, 0x40, + 0x0e, 0x97, 0xb0, 0xac, 0xbe, 0x4d, 0xc0, 0x02, 0x5f, 0xfc, 0xdb, 0xd6, 0xae, 0xd9, 0x38, 0xf8, + 0x8f, 0x72, 0x12, 0x55, 0x38, 0xa6, 0xe9, 0x0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, 0xe1, 0xb1, 0xcc, 0xf3, 0x37, 0x02, 0x64, 0xe3, 0x6e, 0xa3, 0xeb, 0x43, 0xd9, 0xe5, 0x95, + 0xa4, 0x17, 0x47, 0x50, 0x62, 0x51, 0x7d, 0x2c, 0xc0, 0x52, 0xf4, 0x9d, 0xad, 0x30, 0x94, 0x69, + 0x56, 0x6f, 0x57, 0x0e, 0x05, 0x67, 0x31, 0xbc, 0x0f, 0xe9, 0xbe, 0xdb, 0x11, 0x0a, 0x33, 0xc4, + 0x63, 0xa4, 0x7c, 0x3c, 0xc6, 0x7f, 0x60, 0x03, 0xb7, 0x81, 0xd0, 0x03, 0xdb, 0x8f, 0x0a, 0x3f, + 0xb0, 0x51, 0x63, 0x5b, 0xdc, 0x80, 0x14, 0x19, 0xd9, 0x99, 0x30, 0x2d, 0x47, 0x22, 0xe5, 0xa2, + 0x24, 0x7e, 0x1b, 0xa4, 0xaf, 0x86, 0xda, 0x70, 0x24, 0xe1, 0x36, 0xb8, 0x39, 0x74, 0x13, 0xc0, + 0x37, 0x42, 0xe4, 0x30, 0x7c, 0x4f, 0x2e, 0x5d, 0x18, 0x2c, 0xf7, 0xac, 0x4a, 0x47, 0x3e, 0x72, + 0xde, 0xc5, 0x1b, 0x2f, 0x3f, 0x7c, 0x22, 0x0b, 0x8f, 0x9f, 0xc8, 0xc2, 0x9f, 0x4f, 0x64, 0xe1, + 0xeb, 0xa7, 0xf2, 0xc4, 0xe3, 0xa7, 0xf2, 0xc4, 0xef, 0x4f, 0xe5, 0x89, 0xf7, 0x96, 0x0d, 0xd3, + 0xbe, 0xdb, 0xdd, 0x29, 0x36, 0xac, 0xa6, 0xfb, 0xbb, 0x74, 0xc9, 0x37, 0x5d, 0xf6, 0xe9, 0x7c, + 0xd9, 0x99, 0x24, 0x57, 0xcb, 0xf5, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x50, 0xfd, 0x39, 0xc9, + 0x09, 0x17, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. From 419418a97c3f96d2f0c1ed0c8dee8151e233f372 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 8 Nov 2022 16:42:51 +0100 Subject: [PATCH 04/48] Update --- go.mod | 3 +++ go.sum | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/go.mod b/go.mod index e6143e3b63c..902f331f419 100644 --- a/go.mod +++ b/go.mod @@ -161,6 +161,9 @@ require ( ) replace ( + // Temporary until we tag a new version + cosmossdk.io/api => ./api + github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 // Update to rosetta-sdk-go temporarly to have `check:spec` passing. See https://github.com/coinbase/rosetta-sdk-go/issues/449 github.com/coinbase/rosetta-sdk-go => github.com/coinbase/rosetta-sdk-go v0.8.2-0.20221007214527-e03849ba430a diff --git a/go.sum b/go.sum index 70e31b8454c..dcf1ddfdb3a 100644 --- a/go.sum +++ b/go.sum @@ -57,8 +57,6 @@ cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RX cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0 h1:6RRlFMv1omScs6iq2hfE3IvgE+l6RfJPampq8UZc5TU= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= -cosmossdk.io/api v0.2.4 h1:o2t77GXWWEN5egCzD2ZyyFgbsoAif/XdF3T+/sAYiHQ= -cosmossdk.io/api v0.2.4/go.mod h1:7xfxe8ghXHoKj3W2oG/HcuxGVwUHN3q8piiIEiJ3CEU= cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= From 40b3958eb357c2e9ec5a5cd7965b3926a7f3d1ef Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 8 Nov 2022 16:47:10 +0100 Subject: [PATCH 05/48] Add comments --- types/msgservice/validate.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index ba9d2b0b47f..d0b2605b401 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -34,7 +34,10 @@ import ( func ValidateServiceAnnotations(serviceName string) error { sd, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(serviceName)) if err != nil { - return fmt.Errorf("error with Msg service %s; %+v", serviceName, err) + // If we don't find the pulsar-generated descriptors, we just skip + // validation. This allows chain developers to migrate to pulsar at + // their own pace. + return nil } ext := proto.GetExtension(sd.Options(), msg.E_Service) @@ -55,7 +58,10 @@ func ValidateServiceAnnotations(serviceName string) error { func ValidateMsgAnnotations(fqName string) error { d, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(fqName)) if err != nil { - return fmt.Errorf("error with sdk.Msg %s; %+v", fqName, err) + // If we don't find the pulsar-generated descriptors, we just skip + // validation. This allows chain developers to migrate to pulsar at + // their own pace. + return nil } md := d.(protoreflect.MessageDescriptor) From 1ac94688557b9e237e7ebcf9a1aba598bfac8c17 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Mon, 21 Nov 2022 14:50:11 +0100 Subject: [PATCH 06/48] go mod tidy --- go.sum | 2 -- 1 file changed, 2 deletions(-) diff --git a/go.sum b/go.sum index 79a94049fc6..805070071ed 100644 --- a/go.sum +++ b/go.sum @@ -66,8 +66,6 @@ cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3f cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= cloud.google.com/go/storage v1.23.0 h1:wWRIaDURQA8xxHguFCshYepGlrWIrbBnAmc7wfg07qY= cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= -cosmossdk.io/api v0.2.4 h1:o2t77GXWWEN5egCzD2ZyyFgbsoAif/XdF3T+/sAYiHQ= -cosmossdk.io/api v0.2.4/go.mod h1:7xfxe8ghXHoKj3W2oG/HcuxGVwUHN3q8piiIEiJ3CEU= cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= From db4cafe9d386033772776abe707df806896073eb Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Tue, 22 Nov 2022 11:20:16 +0100 Subject: [PATCH 07/48] wip merge fd sets --- baseapp/msg_service_router.go | 19 ++++++++--- runtime/services/reflection.go | 50 +++------------------------- types/msgservice/validate.go | 40 ++++++++++------------ types/reflection/reflection.go | 61 ++++++++++++++++++++++++++++++++++ types/tx/amino/validate.go | 14 +++++--- 5 files changed, 107 insertions(+), 77 deletions(-) create mode 100644 types/reflection/reflection.go diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index f116bb9270c..a0d00c1d50d 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -6,18 +6,18 @@ import ( gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" - "github.com/tendermint/tendermint/libs/log" "google.golang.org/grpc" + "google.golang.org/protobuf/reflect/protodesc" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/msgservice" + "github.com/cosmos/cosmos-sdk/types/reflection" ) // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { - logger log.Logger interfaceRegistry codectypes.InterfaceRegistry routes map[string]MsgServiceHandler } @@ -53,9 +53,18 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - err := msgservice.ValidateServiceAnnotations(sd.ServiceName) + fdSet, err := reflection.GetFileDescriptorSet() if err != nil { - // We might panic here in the future, instead of logging. + panic(err) + } + fdFiles, err := protodesc.NewFiles(fdSet) + if err != nil { + panic(err) + } + + err = msgservice.ValidateServiceAnnotations(fdFiles, sd.ServiceName) + if err != nil { + // We might panic here in the future, instead of simply logging. fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) } @@ -78,7 +87,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(fmt.Errorf("unable to register service method %s: %T does not implement sdk.Msg", fqMethod, i)) } - err := msgservice.ValidateMsgAnnotations(proto.MessageName(msg)) + err := msgservice.ValidateMsgAnnotations(fdFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) diff --git a/runtime/services/reflection.go b/runtime/services/reflection.go index b165ea633ed..c07cac7327d 100644 --- a/runtime/services/reflection.go +++ b/runtime/services/reflection.go @@ -1,18 +1,11 @@ package services import ( - "bytes" - "compress/gzip" "context" - "io" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - "github.com/cosmos/gogoproto/proto" - "golang.org/x/exp/slices" - protov2 "google.golang.org/protobuf/proto" - "google.golang.org/protobuf/reflect/protodesc" - "google.golang.org/protobuf/reflect/protoreflect" - "google.golang.org/protobuf/reflect/protoregistry" + "github.com/cosmos/cosmos-sdk/types/reflection" + "google.golang.org/protobuf/types/descriptorpb" ) @@ -23,44 +16,11 @@ type ReflectionService struct { } func NewReflectionService() (*ReflectionService, error) { - fds := &descriptorpb.FileDescriptorSet{} - - // load gogo proto file descriptors - allFds := proto.AllFileDescriptors() - haveFileDescriptor := map[string]bool{} - for _, compressedBz := range allFds { - rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) - if err != nil { - return nil, err - } - - bz, err := io.ReadAll(rdr) - if err != nil { - return nil, err - } - - fd := &descriptorpb.FileDescriptorProto{} - err = protov2.Unmarshal(bz, fd) - if err != nil { - return nil, err - } - - fds.File = append(fds.File, fd) - haveFileDescriptor[*fd.Name] = true + fds, err := reflection.GetFileDescriptorSet() + if err != nil { + return nil, err } - // load any protoregistry file descriptors not in gogo - protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { - if !haveFileDescriptor[fileDescriptor.Path()] { - fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) - } - return true - }) - - slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { - return *x.Name < *y.Name - }) - return &ReflectionService{files: fds}, nil } diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index d0b2605b401..d1e8aae41aa 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -4,35 +4,23 @@ import ( "fmt" "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protodesc" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" msg "cosmossdk.io/api/cosmos/msg/v1" - - // Import the descriptors - _ "cosmossdk.io/api/cosmos/auth/v1beta1" - _ "cosmossdk.io/api/cosmos/authz/v1beta1" - _ "cosmossdk.io/api/cosmos/bank/v1beta1" - _ "cosmossdk.io/api/cosmos/consensus/v1" - _ "cosmossdk.io/api/cosmos/crisis/v1beta1" - _ "cosmossdk.io/api/cosmos/distribution/v1beta1" - _ "cosmossdk.io/api/cosmos/evidence/v1beta1" - _ "cosmossdk.io/api/cosmos/feegrant/v1beta1" - _ "cosmossdk.io/api/cosmos/gov/v1" - _ "cosmossdk.io/api/cosmos/gov/v1beta1" - _ "cosmossdk.io/api/cosmos/group/v1" - _ "cosmossdk.io/api/cosmos/mint/v1beta1" - _ "cosmossdk.io/api/cosmos/nft/v1beta1" - _ "cosmossdk.io/api/cosmos/slashing/v1beta1" - _ "cosmossdk.io/api/cosmos/staking/v1beta1" - _ "cosmossdk.io/api/cosmos/upgrade/v1beta1" - _ "cosmossdk.io/api/cosmos/vesting/v1beta1" ) // ValidateServiceAnnotations validates that all Msg services have the // `(cosmos.msg.v1.service) = true` proto annotation. -func ValidateServiceAnnotations(serviceName string) error { - sd, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(serviceName)) +// +// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. +func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName string) error { + if fileResolver == nil { + fileResolver = protoregistry.GlobalFiles + } + + sd, err := fileResolver.FindDescriptorByName(protoreflect.FullName(serviceName)) if err != nil { // If we don't find the pulsar-generated descriptors, we just skip // validation. This allows chain developers to migrate to pulsar at @@ -55,8 +43,14 @@ func ValidateServiceAnnotations(serviceName string) error { // ValidateMsgAnnotations validates that all sdk.Msg services have the correct // `(cosmos.msg.v1.signer) = "..."` proto annotation. -func ValidateMsgAnnotations(fqName string) error { - d, err := protoregistry.GlobalFiles.FindDescriptorByName(protoreflect.FullName(fqName)) +// +// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. +func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) error { + if fileResolver == nil { + fileResolver = protoregistry.GlobalFiles + } + + d, err := fileResolver.FindDescriptorByName(protoreflect.FullName(fqName)) if err != nil { // If we don't find the pulsar-generated descriptors, we just skip // validation. This allows chain developers to migrate to pulsar at diff --git a/types/reflection/reflection.go b/types/reflection/reflection.go new file mode 100644 index 00000000000..82eedccd4d2 --- /dev/null +++ b/types/reflection/reflection.go @@ -0,0 +1,61 @@ +package reflection + +import ( + "bytes" + "compress/gzip" + "fmt" + "io" + + "github.com/cosmos/gogoproto/proto" + "golang.org/x/exp/slices" + protov2 "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoreflect" + "google.golang.org/protobuf/reflect/protoregistry" + "google.golang.org/protobuf/types/descriptorpb" +) + +// GetFileDescriptorSet returns the global file descriptor set by merging +// the one from gogoproto global registry and from protoregistry.GlobalFiles. +func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { + fmt.Println("Calling GetFileDescriptorSet") + fds := &descriptorpb.FileDescriptorSet{} + + // load gogo proto file descriptors + allFds := proto.AllFileDescriptors() + haveFileDescriptor := map[string]bool{} + for _, compressedBz := range allFds { + rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) + if err != nil { + return nil, err + } + + bz, err := io.ReadAll(rdr) + if err != nil { + return nil, err + } + + fd := &descriptorpb.FileDescriptorProto{} + err = protov2.Unmarshal(bz, fd) + if err != nil { + return nil, err + } + + fds.File = append(fds.File, fd) + haveFileDescriptor[*fd.Name] = true + } + + // load any protoregistry file descriptors not in gogo + protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { + if !haveFileDescriptor[fileDescriptor.Path()] { + fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) + } + return true + }) + + slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { + return *x.Name < *y.Name + }) + + return fds, nil +} diff --git a/types/tx/amino/validate.go b/types/tx/amino/validate.go index 8f18177107e..d1145ecc22d 100644 --- a/types/tx/amino/validate.go +++ b/types/tx/amino/validate.go @@ -1,14 +1,20 @@ package amino import ( + "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoregistry" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" ) // ValidateAminoAnnotations validates the `amino.*` protobuf annotations. It // performs the following validations: -// - Make sure `amino.name` is equal to the name in the Amino codec's -// registry. -func ValidateAminoAnnotations(interfaceRegistry codectypes.InterfaceRegistry, aminoCdc *codec.LegacyAmino) { - +// - Make sure `amino.name` is equal to the name in the Amino codec's registry. +// +// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. +func ValidateAminoAnnotations(fileResolver protodesc.Resolver, interfaceRegistry codectypes.InterfaceRegistry, aminoCdc *codec.LegacyAmino) { + if fileResolver == nil { + fileResolver = protoregistry.GlobalFiles + } } From 3b5d07d442a46146955ad2fa41976bee426d59ca Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Mon, 28 Nov 2022 17:26:51 +0100 Subject: [PATCH 08/48] fix gomods --- simapp/go.mod | 3 +++ simapp/go.sum | 2 -- tests/go.mod | 3 +++ tests/go.sum | 2 -- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/simapp/go.mod b/simapp/go.mod index 7f003b1b4d4..9629bc3619b 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -162,6 +162,9 @@ require ( ) replace ( + // Temporary until we tag a new version + cosmossdk.io/api => ../api + github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 // Update to rosetta-sdk-go temporarly to have `check:spec` passing. See https://github.com/coinbase/rosetta-sdk-go/issues/449 github.com/coinbase/rosetta-sdk-go => github.com/coinbase/rosetta-sdk-go v0.8.2-0.20221007214527-e03849ba430a diff --git a/simapp/go.sum b/simapp/go.sum index 663ae2e2705..cfb37c2cc62 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -66,8 +66,6 @@ cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3f cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= cloud.google.com/go/storage v1.23.0 h1:wWRIaDURQA8xxHguFCshYepGlrWIrbBnAmc7wfg07qY= cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= -cosmossdk.io/api v0.2.4 h1:o2t77GXWWEN5egCzD2ZyyFgbsoAif/XdF3T+/sAYiHQ= -cosmossdk.io/api v0.2.4/go.mod h1:7xfxe8ghXHoKj3W2oG/HcuxGVwUHN3q8piiIEiJ3CEU= cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= diff --git a/tests/go.mod b/tests/go.mod index 88aff42dbf8..0b6519435e8 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -164,6 +164,9 @@ require ( ) replace ( + // Temporary until we tag a new version + cosmossdk.io/api => ../api + // We always want to test against the latest version of the simapp. cosmossdk.io/simapp => ../simapp github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 diff --git a/tests/go.sum b/tests/go.sum index 0922c9c0797..0823b83fd9e 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -66,8 +66,6 @@ cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3f cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= cloud.google.com/go/storage v1.23.0 h1:wWRIaDURQA8xxHguFCshYepGlrWIrbBnAmc7wfg07qY= cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= -cosmossdk.io/api v0.2.4 h1:o2t77GXWWEN5egCzD2ZyyFgbsoAif/XdF3T+/sAYiHQ= -cosmossdk.io/api v0.2.4/go.mod h1:7xfxe8ghXHoKj3W2oG/HcuxGVwUHN3q8piiIEiJ3CEU= cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= From 168d125aaf75f87352be216bee7e0cd6e424bea3 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Mon, 28 Nov 2022 18:12:03 +0100 Subject: [PATCH 09/48] wip --- codec/types/interface_registry.go | 1 + simapp/app_test.go | 20 ++++++++++++ types/reflection/reflection.go | 10 ++++-- types/tx/amino/validate.go | 51 ++++++++++++++++++++++++++++--- x/feegrant/filtered_fee.go | 7 ++++- 5 files changed, 81 insertions(+), 8 deletions(-) diff --git a/codec/types/interface_registry.go b/codec/types/interface_registry.go index b911cb6bf6e..a54eb66f72d 100644 --- a/codec/types/interface_registry.go +++ b/codec/types/interface_registry.go @@ -292,6 +292,7 @@ func (registry *interfaceRegistry) Resolve(typeURL string) (proto.Message, error // on x if x implements UnpackInterfacesMessage func UnpackInterfaces(x interface{}, unpacker AnyUnpacker) error { if msg, ok := x.(UnpackInterfacesMessage); ok { + fmt.Printf("UnpackInterfaces %T %s=\n", msg, msg) return msg.UnpackInterfaces(unpacker) } return nil diff --git a/simapp/app_test.go b/simapp/app_test.go index e9175e9bb2f..6c4faf0a25d 100644 --- a/simapp/app_test.go +++ b/simapp/app_test.go @@ -12,12 +12,15 @@ import ( "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" dbm "github.com/tendermint/tm-db" + "google.golang.org/protobuf/reflect/protodesc" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/testutil/mock" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/types/reflection" + "github.com/cosmos/cosmos-sdk/types/tx/amino" "github.com/cosmos/cosmos-sdk/x/auth" "github.com/cosmos/cosmos-sdk/x/auth/vesting" authzmodule "github.com/cosmos/cosmos-sdk/x/authz/module" @@ -261,3 +264,20 @@ func TestUpgradeStateOnGenesis(t *testing.T) { require.NotNil(t, app.UpgradeKeeper.GetVersionSetter()) } + +func TestAminoAnnotations(t *testing.T) { + db := dbm.NewMemDB() + logger := log.NewTMLogger(log.NewSyncWriter(os.Stdout)) + app := NewSimApp(logger, db, nil, true, simtestutil.NewAppOptionsWithFlagHome(DefaultNodeHome)) + + fdSet, err := reflection.GetFileDescriptorSet() + require.NoError(t, err) + + fdFiles, err := protodesc.NewFiles(fdSet) + require.NoError(t, err) + + err = amino.ValidateAminoAnnotations(fdFiles, app.legacyAmino) + require.NoError(t, err) + + require.False(t, true) +} diff --git a/types/reflection/reflection.go b/types/reflection/reflection.go index 82eedccd4d2..fcdc234bfa3 100644 --- a/types/reflection/reflection.go +++ b/types/reflection/reflection.go @@ -3,7 +3,6 @@ package reflection import ( "bytes" "compress/gzip" - "fmt" "io" "github.com/cosmos/gogoproto/proto" @@ -18,7 +17,6 @@ import ( // GetFileDescriptorSet returns the global file descriptor set by merging // the one from gogoproto global registry and from protoregistry.GlobalFiles. func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { - fmt.Println("Calling GetFileDescriptorSet") fds := &descriptorpb.FileDescriptorSet{} // load gogo proto file descriptors @@ -41,6 +39,14 @@ func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { return nil, err } + // It seems we're registering twice gogo.proto. + // See Frojdi's comments in server/grpc/gogoreflection/fix_registration.go. + if *fd.Name == "gogo.proto" || + // WHY?? TODO + *fd.Name == "descriptor.proto" { + continue + } + fds.File = append(fds.File, fd) haveFileDescriptor[*fd.Name] = true } diff --git a/types/tx/amino/validate.go b/types/tx/amino/validate.go index d1145ecc22d..49abeb839c2 100644 --- a/types/tx/amino/validate.go +++ b/types/tx/amino/validate.go @@ -1,11 +1,17 @@ package amino import ( - "google.golang.org/protobuf/reflect/protodesc" + fmt "fmt" + "reflect" + "strings" + + gogoproto "github.com/cosmos/gogoproto/proto" + "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" + "cosmossdk.io/api/amino" "github.com/cosmos/cosmos-sdk/codec" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" ) // ValidateAminoAnnotations validates the `amino.*` protobuf annotations. It @@ -13,8 +19,43 @@ import ( // - Make sure `amino.name` is equal to the name in the Amino codec's registry. // // If `fileResolver` is nil, then protoregistry.GlobalFile will be used. -func ValidateAminoAnnotations(fileResolver protodesc.Resolver, interfaceRegistry codectypes.InterfaceRegistry, aminoCdc *codec.LegacyAmino) { - if fileResolver == nil { - fileResolver = protoregistry.GlobalFiles +func ValidateAminoAnnotations(fdFiles *protoregistry.Files, aminoCdc *codec.LegacyAmino) error { + var err error + + // Range through all files, and for each file, range through all its + // messages to check the amino annotation. + fdFiles.RangeFiles(func(fd protoreflect.FileDescriptor) bool { + for i := 0; i < fd.Messages().Len(); i++ { + md := fd.Messages().Get(i) + aminoName, found := proto.GetExtension(md.Options(), amino.E_Name).(string) + if !found || aminoName == "" { + continue + } + + gogoMsgType := gogoproto.MessageType(string(md.FullName())) + gogoMsg := reflect.New(gogoMsgType.Elem()).Interface() + fmt.Printf("gogoMs=%T\n", gogoMsg) + + jsonBz, innerErr := aminoCdc.MarshalJSON(gogoMsg) + if innerErr != nil { + err = innerErr + return false + } + + if !strings.HasPrefix(string(jsonBz), fmt.Sprintf(`{"type":"%s",`, aminoName)) { + fmt.Println(string(jsonBz)) + err = fmt.Errorf("proto message %s has incorrectly registered amino name %s", aminoName, md.FullName()) + } + + fmt.Println("aminoName=", aminoName) + } + + return true + }) + + if err != nil { + return err } + + return nil } diff --git a/x/feegrant/filtered_fee.go b/x/feegrant/filtered_fee.go index 28679ed5a42..17eee83504a 100644 --- a/x/feegrant/filtered_fee.go +++ b/x/feegrant/filtered_fee.go @@ -24,7 +24,12 @@ var ( // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (a *AllowedMsgAllowance) UnpackInterfaces(unpacker types.AnyUnpacker) error { var allowance FeeAllowanceI - return unpacker.UnpackAny(a.Allowance, &allowance) + + if a.Allowance != nil { + return unpacker.UnpackAny(a.Allowance, &allowance) + } + + return nil } // NewAllowedMsgFeeAllowance creates new filtered fee allowance. From 9981a0bd590c411112f2633cc5978e18fa532afb Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 14:48:08 +0100 Subject: [PATCH 10/48] Fix nil any --- codec/types/compat.go | 5 +++++ x/auth/types/account.go | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/codec/types/compat.go b/codec/types/compat.go index 3b669385624..c5bab5e31a2 100644 --- a/codec/types/compat.go +++ b/codec/types/compat.go @@ -170,6 +170,11 @@ type AminoJSONPacker struct { var _ AnyUnpacker = AminoJSONPacker{} func (a AminoJSONPacker) UnpackAny(any *Any, _ interface{}) error { + // here we gracefully handle the case in which `any` itself is `nil`, which may occur in message decoding + if any == nil { + return nil + } + err := UnpackInterfaces(any.cachedValue, a) if err != nil { return err diff --git a/x/auth/types/account.go b/x/auth/types/account.go index 16ffaf29358..ad6aab97101 100644 --- a/x/auth/types/account.go +++ b/x/auth/types/account.go @@ -151,8 +151,8 @@ func (acc BaseAccount) MarshalYAML() (interface{}, error) { } // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces -func (acc BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - if acc.PubKey == nil { +func (acc *BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { + if acc == nil || acc.PubKey == nil { return nil } var pubKey cryptotypes.PubKey From 0dad4946a485dff6fa3a021c807e43a34686f46b Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 14:52:11 +0100 Subject: [PATCH 11/48] Revert --- x/auth/types/account.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/auth/types/account.go b/x/auth/types/account.go index 17f1b58c21c..2026f2a9e24 100644 --- a/x/auth/types/account.go +++ b/x/auth/types/account.go @@ -137,7 +137,7 @@ func (acc BaseAccount) Validate() error { // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (acc *BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - if acc == nil || acc.PubKey == nil { + if acc.PubKey == nil { return nil } var pubKey cryptotypes.PubKey From 2ae491436ffc38fc756326e71c9e2aa3ccf60e02 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 14:59:23 +0100 Subject: [PATCH 12/48] Small cleanup --- baseapp/msg_service_router.go | 2 ++ codec/types/interface_registry.go | 1 - simapp/app_test.go | 2 -- types/msgservice/validate.go | 4 ++-- types/reflection/reflection.go | 5 ++++- 5 files changed, 8 insertions(+), 6 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 51ee0ab80ff..0fb733770ff 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -62,6 +62,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(err) } + // Make sure all Msg services has the `cosmos.msg.service` proto annotation. err = msgservice.ValidateServiceAnnotations(fdFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. @@ -87,6 +88,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(fmt.Errorf("unable to register service method %s: %T does not implement sdk.Msg", fqMethod, i)) } + // Make sure all Msg annotations are correct, like the `cosmos.msg.signer` one. err := msgservice.ValidateMsgAnnotations(fdFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. diff --git a/codec/types/interface_registry.go b/codec/types/interface_registry.go index a54eb66f72d..b911cb6bf6e 100644 --- a/codec/types/interface_registry.go +++ b/codec/types/interface_registry.go @@ -292,7 +292,6 @@ func (registry *interfaceRegistry) Resolve(typeURL string) (proto.Message, error // on x if x implements UnpackInterfacesMessage func UnpackInterfaces(x interface{}, unpacker AnyUnpacker) error { if msg, ok := x.(UnpackInterfacesMessage); ok { - fmt.Printf("UnpackInterfaces %T %s=\n", msg, msg) return msg.UnpackInterfaces(unpacker) } return nil diff --git a/simapp/app_test.go b/simapp/app_test.go index 2cb886f3e93..e7ce0d2f18e 100644 --- a/simapp/app_test.go +++ b/simapp/app_test.go @@ -286,6 +286,4 @@ func TestAminoAnnotations(t *testing.T) { err = amino.ValidateAminoAnnotations(fdFiles, app.legacyAmino) require.NoError(t, err) - - require.False(t, true) } diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index d1e8aae41aa..c7c4c070515 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -29,12 +29,12 @@ func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName str } ext := proto.GetExtension(sd.Options(), msg.E_Service) - hasOption, ok := ext.(bool) + isService, ok := ext.(bool) if !ok { return fmt.Errorf("expected bool, got %T", ext) } - if !hasOption { + if !isService { return fmt.Errorf("service %s does not have cosmos.msg.v1.service proto annotation", serviceName) } diff --git a/types/reflection/reflection.go b/types/reflection/reflection.go index fcdc234bfa3..3eafab66748 100644 --- a/types/reflection/reflection.go +++ b/types/reflection/reflection.go @@ -41,8 +41,11 @@ func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { // It seems we're registering twice gogo.proto. // See Frojdi's comments in server/grpc/gogoreflection/fix_registration.go. + // Skipping here `gogo.proto` and only including `gogoproto/gogo.proto`. if *fd.Name == "gogo.proto" || - // WHY?? TODO + // If we don't skip this one, we have the error: + // proto: file "descriptor.proto" has a name conflict over google.protobuf.FileDescriptorSet + // Is it because we're importing "google.golang.org/protobuf/types/descriptorpb"? *fd.Name == "descriptor.proto" { continue } From 3b59f38e6cc07292ae341739dd247e65075e3cea Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 15:20:11 +0100 Subject: [PATCH 13/48] Move registration fix to types --- baseapp/msg_service_router.go | 29 +++++++++++-------- baseapp/msg_service_router_test.go | 2 -- server/grpc/gogoreflection/doc.go | 5 ---- server/grpc/server.go | 2 +- .../reflection}/fix_registration.go | 2 +- .../reflection}/fix_registration_test.go | 2 +- types/reflection/reflection.go | 4 +-- .../reflection}/serverreflection.go | 2 +- 8 files changed, 23 insertions(+), 25 deletions(-) delete mode 100644 server/grpc/gogoreflection/doc.go rename {server/grpc/gogoreflection => types/reflection}/fix_registration.go (99%) rename {server/grpc/gogoreflection => types/reflection}/fix_registration_test.go (94%) rename {server/grpc/gogoreflection => types/reflection}/serverreflection.go (99%) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 0fb733770ff..37e6dd49b8c 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -8,6 +8,7 @@ import ( "github.com/cosmos/gogoproto/proto" "google.golang.org/grpc" "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoregistry" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -16,6 +17,19 @@ import ( "github.com/cosmos/cosmos-sdk/types/reflection" ) +var fdFiles *protoregistry.Files + +func init() { + fdSet, err := reflection.GetFileDescriptorSet() + if err != nil { + panic(err) + } + fdFiles, err = protodesc.NewFiles(fdSet) + if err != nil { + panic(err) + } +} + // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { interfaceRegistry codectypes.InterfaceRegistry @@ -53,17 +67,8 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - fdSet, err := reflection.GetFileDescriptorSet() - if err != nil { - panic(err) - } - fdFiles, err := protodesc.NewFiles(fdSet) - if err != nil { - panic(err) - } - - // Make sure all Msg services has the `cosmos.msg.service` proto annotation. - err = msgservice.ValidateServiceAnnotations(fdFiles, sd.ServiceName) + // Make sure the Msg services has the `cosmos.msg.service` proto annotation. + err := msgservice.ValidateServiceAnnotations(fdFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) @@ -88,7 +93,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(fmt.Errorf("unable to register service method %s: %T does not implement sdk.Msg", fqMethod, i)) } - // Make sure all Msg annotations are correct, like the `cosmos.msg.signer` one. + // Make sure Msg annotations are correct, like the `cosmos.msg.signer` one. err := msgservice.ValidateMsgAnnotations(fdFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. diff --git a/baseapp/msg_service_router_test.go b/baseapp/msg_service_router_test.go index 9dd587db135..6c0c1adcf48 100644 --- a/baseapp/msg_service_router_test.go +++ b/baseapp/msg_service_router_test.go @@ -47,8 +47,6 @@ func TestRegisterMsgService(t *testing.T) { testdata.MsgServerImpl{}, ) }) - - require.False(t, true) } func TestRegisterMsgServiceTwice(t *testing.T) { diff --git a/server/grpc/gogoreflection/doc.go b/server/grpc/gogoreflection/doc.go deleted file mode 100644 index 691e632d0ee..00000000000 --- a/server/grpc/gogoreflection/doc.go +++ /dev/null @@ -1,5 +0,0 @@ -// Package gogoreflection implements gRPC reflection for gogoproto consumers -// the normal reflection library does not work as it points to a different -// singleton registry. The API and codebase is taken from the official gRPC -// reflection repository. -package gogoreflection diff --git a/server/grpc/server.go b/server/grpc/server.go index 79a9be3dca2..bfa2e279a9c 100644 --- a/server/grpc/server.go +++ b/server/grpc/server.go @@ -10,10 +10,10 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/server/config" - "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" reflection "github.com/cosmos/cosmos-sdk/server/grpc/reflection/v2alpha1" "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" + gogoreflection "github.com/cosmos/cosmos-sdk/types/reflection" _ "github.com/cosmos/cosmos-sdk/types/tx/amino" // Import amino.proto file for reflection ) diff --git a/server/grpc/gogoreflection/fix_registration.go b/types/reflection/fix_registration.go similarity index 99% rename from server/grpc/gogoreflection/fix_registration.go rename to types/reflection/fix_registration.go index 48678203b94..eaf00f3a4f8 100644 --- a/server/grpc/gogoreflection/fix_registration.go +++ b/types/reflection/fix_registration.go @@ -1,4 +1,4 @@ -package gogoreflection +package reflection import ( "bytes" diff --git a/server/grpc/gogoreflection/fix_registration_test.go b/types/reflection/fix_registration_test.go similarity index 94% rename from server/grpc/gogoreflection/fix_registration_test.go rename to types/reflection/fix_registration_test.go index 0693556688e..647a8e16789 100644 --- a/server/grpc/gogoreflection/fix_registration_test.go +++ b/types/reflection/fix_registration_test.go @@ -1,4 +1,4 @@ -package gogoreflection +package reflection import ( "testing" diff --git a/types/reflection/reflection.go b/types/reflection/reflection.go index 3eafab66748..a0d1db50ea0 100644 --- a/types/reflection/reflection.go +++ b/types/reflection/reflection.go @@ -5,7 +5,7 @@ import ( "compress/gzip" "io" - "github.com/cosmos/gogoproto/proto" + gogoproto "github.com/cosmos/gogoproto/proto" "golang.org/x/exp/slices" protov2 "google.golang.org/protobuf/proto" "google.golang.org/protobuf/reflect/protodesc" @@ -20,7 +20,7 @@ func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { fds := &descriptorpb.FileDescriptorSet{} // load gogo proto file descriptors - allFds := proto.AllFileDescriptors() + allFds := gogoproto.AllFileDescriptors() haveFileDescriptor := map[string]bool{} for _, compressedBz := range allFds { rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) diff --git a/server/grpc/gogoreflection/serverreflection.go b/types/reflection/serverreflection.go similarity index 99% rename from server/grpc/gogoreflection/serverreflection.go rename to types/reflection/serverreflection.go index ac1e3c2d052..a74ca1dc76e 100644 --- a/server/grpc/gogoreflection/serverreflection.go +++ b/types/reflection/serverreflection.go @@ -34,7 +34,7 @@ To register server reflection on a gRPC server: s.Serve(lis) */ -package gogoreflection // import "google.golang.org/grpc/reflection" +package reflection // import "google.golang.org/grpc/reflection" import ( "bytes" From e48ded06746cae0c3e580127782b7739b958cfec Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 15:23:18 +0100 Subject: [PATCH 14/48] revert some stuff --- codec/types/compat.go | 5 ----- go.mod | 1 + types/reflection/doc.go | 5 +++++ x/auth/types/account.go | 2 +- x/feegrant/filtered_fee.go | 7 +------ 5 files changed, 8 insertions(+), 12 deletions(-) create mode 100644 types/reflection/doc.go diff --git a/codec/types/compat.go b/codec/types/compat.go index c5bab5e31a2..3b669385624 100644 --- a/codec/types/compat.go +++ b/codec/types/compat.go @@ -170,11 +170,6 @@ type AminoJSONPacker struct { var _ AnyUnpacker = AminoJSONPacker{} func (a AminoJSONPacker) UnpackAny(any *Any, _ interface{}) error { - // here we gracefully handle the case in which `any` itself is `nil`, which may occur in message decoding - if any == nil { - return nil - } - err := UnpackInterfaces(any.cachedValue, a) if err != nil { return err diff --git a/go.mod b/go.mod index 81a8672a186..e2b671d1996 100644 --- a/go.mod +++ b/go.mod @@ -165,6 +165,7 @@ require ( replace ( // Temporary until we tag a new version cosmossdk.io/api => ./api + cosmossdk.io/tools/rosetta => ./tools/rosetta github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 // dgrijalva/jwt-go is deprecated and doesn't receive security updates. diff --git a/types/reflection/doc.go b/types/reflection/doc.go new file mode 100644 index 00000000000..78c8d733513 --- /dev/null +++ b/types/reflection/doc.go @@ -0,0 +1,5 @@ +// Package reflection implements gRPC reflection for gogoproto consumers +// the normal reflection library does not work as it points to a different +// singleton registry. The API and codebase is taken from the official gRPC +// reflection repository. +package reflection diff --git a/x/auth/types/account.go b/x/auth/types/account.go index 2026f2a9e24..7f8df232673 100644 --- a/x/auth/types/account.go +++ b/x/auth/types/account.go @@ -136,7 +136,7 @@ func (acc BaseAccount) Validate() error { } // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces -func (acc *BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { +func (acc BaseAccount) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { if acc.PubKey == nil { return nil } diff --git a/x/feegrant/filtered_fee.go b/x/feegrant/filtered_fee.go index 17eee83504a..28679ed5a42 100644 --- a/x/feegrant/filtered_fee.go +++ b/x/feegrant/filtered_fee.go @@ -24,12 +24,7 @@ var ( // UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces func (a *AllowedMsgAllowance) UnpackInterfaces(unpacker types.AnyUnpacker) error { var allowance FeeAllowanceI - - if a.Allowance != nil { - return unpacker.UnpackAny(a.Allowance, &allowance) - } - - return nil + return unpacker.UnpackAny(a.Allowance, &allowance) } // NewAllowedMsgFeeAllowance creates new filtered fee allowance. From f0f2fd8178fee3c3483bd76d751a2bacb3ce8ae0 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 15:27:13 +0100 Subject: [PATCH 15/48] comments --- types/tx/amino/validate.go | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/types/tx/amino/validate.go b/types/tx/amino/validate.go index 49abeb839c2..cb5ef22cd07 100644 --- a/types/tx/amino/validate.go +++ b/types/tx/amino/validate.go @@ -34,7 +34,6 @@ func ValidateAminoAnnotations(fdFiles *protoregistry.Files, aminoCdc *codec.Lega gogoMsgType := gogoproto.MessageType(string(md.FullName())) gogoMsg := reflect.New(gogoMsgType.Elem()).Interface() - fmt.Printf("gogoMs=%T\n", gogoMsg) jsonBz, innerErr := aminoCdc.MarshalJSON(gogoMsg) if innerErr != nil { @@ -42,20 +41,15 @@ func ValidateAminoAnnotations(fdFiles *protoregistry.Files, aminoCdc *codec.Lega return false } + // If the Amino JSON output has the "type" field, it means that the + // underlying type has been registered in amino's registry. if !strings.HasPrefix(string(jsonBz), fmt.Sprintf(`{"type":"%s",`, aminoName)) { - fmt.Println(string(jsonBz)) err = fmt.Errorf("proto message %s has incorrectly registered amino name %s", aminoName, md.FullName()) } - - fmt.Println("aminoName=", aminoName) } return true }) - if err != nil { - return err - } - - return nil + return err } From 0458789d4a1722e0b0b84100bd0722e422d06b97 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 1 Dec 2022 15:42:32 +0100 Subject: [PATCH 16/48] Return err --- types/msgservice/validate.go | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index c7c4c070515..daaa75df452 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -22,10 +22,7 @@ func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName str sd, err := fileResolver.FindDescriptorByName(protoreflect.FullName(serviceName)) if err != nil { - // If we don't find the pulsar-generated descriptors, we just skip - // validation. This allows chain developers to migrate to pulsar at - // their own pace. - return nil + return err } ext := proto.GetExtension(sd.Options(), msg.E_Service) @@ -52,10 +49,7 @@ func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) erro d, err := fileResolver.FindDescriptorByName(protoreflect.FullName(fqName)) if err != nil { - // If we don't find the pulsar-generated descriptors, we just skip - // validation. This allows chain developers to migrate to pulsar at - // their own pace. - return nil + return err } md := d.(protoreflect.MessageDescriptor) From b2a041458209c914e7c66e8691218f3c93a31163 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 15 Dec 2022 15:24:40 +0100 Subject: [PATCH 17/48] go mod tidy --- go.sum | 5 ----- simapp/go.sum | 5 ----- tests/go.sum | 5 ----- 3 files changed, 15 deletions(-) diff --git a/go.sum b/go.sum index da73546610a..a002d7654e1 100644 --- a/go.sum +++ b/go.sum @@ -46,11 +46,6 @@ cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9 cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= cloud.google.com/go/storage v1.27.0 h1:YOO045NZI9RKfCj1c5A/ZtuuENUc8OAW+gHdGnDgyMQ= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= -<<<<<<< HEAD -======= -cosmossdk.io/api v0.2.6 h1:AoNwaLLapcLsphhMK6+o0kZl+D6MMUaHVqSdwinASGU= -cosmossdk.io/api v0.2.6/go.mod h1:u/d+GAxil0nWpl1XnQL8nkziQDIWuBDhv8VnDm/s6dI= ->>>>>>> ce167a2074b98b0ccf533e119dd707fa3aaca6df cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= diff --git a/simapp/go.sum b/simapp/go.sum index 95809d69255..07e36f10b1d 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -46,11 +46,6 @@ cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9 cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= cloud.google.com/go/storage v1.27.0 h1:YOO045NZI9RKfCj1c5A/ZtuuENUc8OAW+gHdGnDgyMQ= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= -<<<<<<< HEAD -======= -cosmossdk.io/api v0.2.6 h1:AoNwaLLapcLsphhMK6+o0kZl+D6MMUaHVqSdwinASGU= -cosmossdk.io/api v0.2.6/go.mod h1:u/d+GAxil0nWpl1XnQL8nkziQDIWuBDhv8VnDm/s6dI= ->>>>>>> ce167a2074b98b0ccf533e119dd707fa3aaca6df cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= diff --git a/tests/go.sum b/tests/go.sum index 302bc970f55..91ea28eae21 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -46,11 +46,6 @@ cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9 cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= cloud.google.com/go/storage v1.27.0 h1:YOO045NZI9RKfCj1c5A/ZtuuENUc8OAW+gHdGnDgyMQ= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= -<<<<<<< HEAD -======= -cosmossdk.io/api v0.2.6 h1:AoNwaLLapcLsphhMK6+o0kZl+D6MMUaHVqSdwinASGU= -cosmossdk.io/api v0.2.6/go.mod h1:u/d+GAxil0nWpl1XnQL8nkziQDIWuBDhv8VnDm/s6dI= ->>>>>>> ce167a2074b98b0ccf533e119dd707fa3aaca6df cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= From 3fcd4c0f1fbc01eaeba7a213371fbed58299d452 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 18 Jan 2023 18:22:43 +0100 Subject: [PATCH 18/48] Revert some stuff --- baseapp/msg_service_router.go | 16 -- go.mod | 3 - go.sum | 2 - runtime/services/reflection.go | 50 ++++- .../grpc/gogoreflection}/doc.go | 2 +- .../grpc/gogoreflection}/fix_registration.go | 2 +- .../gogoreflection}/fix_registration_test.go | 2 +- .../grpc/gogoreflection}/reflection.go | 2 +- .../grpc/gogoreflection}/serverreflection.go | 2 +- simapp/go.mod | 5 +- simapp/go.sum | 4 - tests/go.mod | 3 - tests/go.sum | 2 - types/tx/amino/validate.go | 55 ------ x/group/tx.pb.go | 176 +++++++++--------- 15 files changed, 140 insertions(+), 186 deletions(-) rename {types/reflection => server/grpc/gogoreflection}/doc.go (91%) rename {types/reflection => server/grpc/gogoreflection}/fix_registration.go (99%) rename {types/reflection => server/grpc/gogoreflection}/fix_registration_test.go (94%) rename {types/reflection => server/grpc/gogoreflection}/reflection.go (98%) rename {types/reflection => server/grpc/gogoreflection}/serverreflection.go (99%) delete mode 100644 types/tx/amino/validate.go diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 37e6dd49b8c..97b17076512 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -7,29 +7,13 @@ import ( gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" "google.golang.org/grpc" - "google.golang.org/protobuf/reflect/protodesc" - "google.golang.org/protobuf/reflect/protoregistry" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/msgservice" - "github.com/cosmos/cosmos-sdk/types/reflection" ) -var fdFiles *protoregistry.Files - -func init() { - fdSet, err := reflection.GetFileDescriptorSet() - if err != nil { - panic(err) - } - fdFiles, err = protodesc.NewFiles(fdSet) - if err != nil { - panic(err) - } -} - // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { interfaceRegistry codectypes.InterfaceRegistry diff --git a/go.mod b/go.mod index 9125250b8fe..7a132345f55 100644 --- a/go.mod +++ b/go.mod @@ -178,9 +178,6 @@ require ( ) replace ( - // Temporary until we tag a new version - cosmossdk.io/api => ./api - github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 // dgrijalva/jwt-go is deprecated and doesn't receive security updates. // TODO: remove it: https://github.com/cosmos/cosmos-sdk/issues/13134 diff --git a/go.sum b/go.sum index 2969071fd43..393226ea8fa 100644 --- a/go.sum +++ b/go.sum @@ -46,8 +46,6 @@ cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9 cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= cloud.google.com/go/storage v1.27.0 h1:YOO045NZI9RKfCj1c5A/ZtuuENUc8OAW+gHdGnDgyMQ= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= -cosmossdk.io/core v0.3.2 h1:KlQIufpJHJvOs7YLGTZsZcCo1WlkencDXepsr8STKZQ= -cosmossdk.io/core v0.3.2/go.mod h1:CO7vbe+evrBvHc0setFHL/u7nlY7HJGzdRSBkT/sirc= cosmossdk.io/api v0.2.6 h1:AoNwaLLapcLsphhMK6+o0kZl+D6MMUaHVqSdwinASGU= cosmossdk.io/api v0.2.6/go.mod h1:u/d+GAxil0nWpl1XnQL8nkziQDIWuBDhv8VnDm/s6dI= cosmossdk.io/collections v0.0.0-20230106101515-aeac21494476 h1:dszme7EMNp/qxjgZKjhY4lm5SN+g1Tz95UlX/qZUK64= diff --git a/runtime/services/reflection.go b/runtime/services/reflection.go index c07cac7327d..b165ea633ed 100644 --- a/runtime/services/reflection.go +++ b/runtime/services/reflection.go @@ -1,11 +1,18 @@ package services import ( + "bytes" + "compress/gzip" "context" + "io" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - "github.com/cosmos/cosmos-sdk/types/reflection" - + "github.com/cosmos/gogoproto/proto" + "golang.org/x/exp/slices" + protov2 "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoreflect" + "google.golang.org/protobuf/reflect/protoregistry" "google.golang.org/protobuf/types/descriptorpb" ) @@ -16,11 +23,44 @@ type ReflectionService struct { } func NewReflectionService() (*ReflectionService, error) { - fds, err := reflection.GetFileDescriptorSet() - if err != nil { - return nil, err + fds := &descriptorpb.FileDescriptorSet{} + + // load gogo proto file descriptors + allFds := proto.AllFileDescriptors() + haveFileDescriptor := map[string]bool{} + for _, compressedBz := range allFds { + rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) + if err != nil { + return nil, err + } + + bz, err := io.ReadAll(rdr) + if err != nil { + return nil, err + } + + fd := &descriptorpb.FileDescriptorProto{} + err = protov2.Unmarshal(bz, fd) + if err != nil { + return nil, err + } + + fds.File = append(fds.File, fd) + haveFileDescriptor[*fd.Name] = true } + // load any protoregistry file descriptors not in gogo + protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { + if !haveFileDescriptor[fileDescriptor.Path()] { + fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) + } + return true + }) + + slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { + return *x.Name < *y.Name + }) + return &ReflectionService{files: fds}, nil } diff --git a/types/reflection/doc.go b/server/grpc/gogoreflection/doc.go similarity index 91% rename from types/reflection/doc.go rename to server/grpc/gogoreflection/doc.go index 78c8d733513..81fbf5c4c24 100644 --- a/types/reflection/doc.go +++ b/server/grpc/gogoreflection/doc.go @@ -2,4 +2,4 @@ // the normal reflection library does not work as it points to a different // singleton registry. The API and codebase is taken from the official gRPC // reflection repository. -package reflection +package gogoreflection diff --git a/types/reflection/fix_registration.go b/server/grpc/gogoreflection/fix_registration.go similarity index 99% rename from types/reflection/fix_registration.go rename to server/grpc/gogoreflection/fix_registration.go index 14f9fc513a1..38d6c9f3625 100644 --- a/types/reflection/fix_registration.go +++ b/server/grpc/gogoreflection/fix_registration.go @@ -1,4 +1,4 @@ -package reflection +package gogoreflection import ( "bytes" diff --git a/types/reflection/fix_registration_test.go b/server/grpc/gogoreflection/fix_registration_test.go similarity index 94% rename from types/reflection/fix_registration_test.go rename to server/grpc/gogoreflection/fix_registration_test.go index 647a8e16789..0693556688e 100644 --- a/types/reflection/fix_registration_test.go +++ b/server/grpc/gogoreflection/fix_registration_test.go @@ -1,4 +1,4 @@ -package reflection +package gogoreflection import ( "testing" diff --git a/types/reflection/reflection.go b/server/grpc/gogoreflection/reflection.go similarity index 98% rename from types/reflection/reflection.go rename to server/grpc/gogoreflection/reflection.go index a0d1db50ea0..c3e4f668801 100644 --- a/types/reflection/reflection.go +++ b/server/grpc/gogoreflection/reflection.go @@ -1,4 +1,4 @@ -package reflection +package gogoreflection import ( "bytes" diff --git a/types/reflection/serverreflection.go b/server/grpc/gogoreflection/serverreflection.go similarity index 99% rename from types/reflection/serverreflection.go rename to server/grpc/gogoreflection/serverreflection.go index a74ca1dc76e..ac1e3c2d052 100644 --- a/types/reflection/serverreflection.go +++ b/server/grpc/gogoreflection/serverreflection.go @@ -34,7 +34,7 @@ To register server reflection on a gRPC server: s.Serve(lis) */ -package reflection // import "google.golang.org/grpc/reflection" +package gogoreflection // import "google.golang.org/grpc/reflection" import ( "bytes" diff --git a/simapp/go.mod b/simapp/go.mod index 0944676e348..617567727d9 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -23,6 +23,8 @@ require ( google.golang.org/protobuf v1.28.1 ) +require github.com/tendermint/tm-db v0.6.7 + require ( cloud.google.com/go v0.105.0 // indirect cloud.google.com/go/compute v1.13.0 // indirect @@ -156,7 +158,6 @@ require ( github.com/tendermint/btcd v0.1.1 // indirect github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tendermint/tm-db v0.6.7 // indirect github.com/tidwall/btree v1.6.0 // indirect github.com/ulikunitz/xz v0.5.8 // indirect github.com/zondax/hid v0.9.1 // indirect @@ -185,8 +186,6 @@ require ( ) replace ( - // Temporary until we tag a new version - cosmossdk.io/api => ../api // TODO delete after release of confix cosmossdk.io/tools/confix => ../tools/confix github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 diff --git a/simapp/go.sum b/simapp/go.sum index 8b39c1ab1ce..1ca076c930d 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -60,8 +60,6 @@ cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE= cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= -cosmossdk.io/tools/confix v0.0.0-20230110102841-9742029158ad h1:pKd9i/hHfUDZ4KCxIqXYHMIm9iJ3M6TGCQPpdC3bo3s= -cosmossdk.io/tools/confix v0.0.0-20230110102841-9742029158ad/go.mod h1:2Nh3ruqssRMhsrsCv404hW6fqSJGFfl2fWp6RDJbRAw= cosmossdk.io/tools/rosetta v0.2.0 h1:Ae499UiZ9yPNCXvjOBO/R9I1pksCJfxoqWauEZgA/gs= cosmossdk.io/tools/rosetta v0.2.0/go.mod h1:3mn8QuE2wLUdTi77/gbDXdFqXZdBdiBJhgAWUTSXPv8= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= @@ -197,8 +195,6 @@ github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32 h1:zlCp9n3uwQieEL github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32/go.mod h1:kwMlEC4wWvB48zAShGKVqboJL6w4zCLesaNQ3YLU2BQ= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= -github.com/cosmos/cosmos-sdk/x/nft v0.0.0-20230113085233-fae3332d62fc h1:sWSnxj3Yb4suTbO2mveJoJTQznW23d9/fIulZ3VIdnM= -github.com/cosmos/cosmos-sdk/x/nft v0.0.0-20230113085233-fae3332d62fc/go.mod h1:1sllUQ6kHXQoYNIkvHcyTElmOfNWsYqJUVLMsZhjJOI= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= diff --git a/tests/go.mod b/tests/go.mod index d5557202b43..c7c76adef77 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -179,9 +179,6 @@ require ( ) replace ( - // Temporary until we tag a new version - cosmossdk.io/api => ../api - // We always want to test against the latest version of the simapp. cosmossdk.io/simapp => ../simapp github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 diff --git a/tests/go.sum b/tests/go.sum index 34204cd3b55..fa21ea21196 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -192,8 +192,6 @@ github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32 h1:zlCp9n3uwQieEL github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32/go.mod h1:kwMlEC4wWvB48zAShGKVqboJL6w4zCLesaNQ3YLU2BQ= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= -github.com/cosmos/cosmos-sdk/x/nft v0.0.0-20230113085233-fae3332d62fc h1:sWSnxj3Yb4suTbO2mveJoJTQznW23d9/fIulZ3VIdnM= -github.com/cosmos/cosmos-sdk/x/nft v0.0.0-20230113085233-fae3332d62fc/go.mod h1:1sllUQ6kHXQoYNIkvHcyTElmOfNWsYqJUVLMsZhjJOI= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= diff --git a/types/tx/amino/validate.go b/types/tx/amino/validate.go deleted file mode 100644 index cb5ef22cd07..00000000000 --- a/types/tx/amino/validate.go +++ /dev/null @@ -1,55 +0,0 @@ -package amino - -import ( - fmt "fmt" - "reflect" - "strings" - - gogoproto "github.com/cosmos/gogoproto/proto" - "google.golang.org/protobuf/proto" - "google.golang.org/protobuf/reflect/protoreflect" - "google.golang.org/protobuf/reflect/protoregistry" - - "cosmossdk.io/api/amino" - "github.com/cosmos/cosmos-sdk/codec" -) - -// ValidateAminoAnnotations validates the `amino.*` protobuf annotations. It -// performs the following validations: -// - Make sure `amino.name` is equal to the name in the Amino codec's registry. -// -// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. -func ValidateAminoAnnotations(fdFiles *protoregistry.Files, aminoCdc *codec.LegacyAmino) error { - var err error - - // Range through all files, and for each file, range through all its - // messages to check the amino annotation. - fdFiles.RangeFiles(func(fd protoreflect.FileDescriptor) bool { - for i := 0; i < fd.Messages().Len(); i++ { - md := fd.Messages().Get(i) - aminoName, found := proto.GetExtension(md.Options(), amino.E_Name).(string) - if !found || aminoName == "" { - continue - } - - gogoMsgType := gogoproto.MessageType(string(md.FullName())) - gogoMsg := reflect.New(gogoMsgType.Elem()).Interface() - - jsonBz, innerErr := aminoCdc.MarshalJSON(gogoMsg) - if innerErr != nil { - err = innerErr - return false - } - - // If the Amino JSON output has the "type" field, it means that the - // underlying type has been registered in amino's registry. - if !strings.HasPrefix(string(jsonBz), fmt.Sprintf(`{"type":"%s",`, aminoName)) { - err = fmt.Errorf("proto message %s has incorrectly registered amino name %s", aminoName, md.FullName()) - } - } - - return true - }) - - return err -} diff --git a/x/group/tx.pb.go b/x/group/tx.pb.go index ca81aa00d7c..51cd22261fd 100644 --- a/x/group/tx.pb.go +++ b/x/group/tx.pb.go @@ -1504,98 +1504,98 @@ func init() { func init() { proto.RegisterFile("cosmos/group/v1/tx.proto", fileDescriptor_6b8d3d629f136420) } var fileDescriptor_6b8d3d629f136420 = []byte{ - // 1443 bytes of a gzipped FileDescriptorProto + // 1442 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x58, 0xcf, 0x6f, 0x1b, 0xc5, 0x17, 0xcf, 0xda, 0xce, 0xaf, 0x97, 0x6f, 0xdd, 0x64, 0x9b, 0xb4, 0x9b, 0x6d, 0x6b, 0xbb, 0xd3, 0xb4, 0x49, 0xad, 0xc6, 0x6e, 0x9c, 0x6f, 0x2b, 0x61, 0x10, 0xa8, 0x49, 0x0d, 0x0a, 0xc2, 0x10, 0x6d, 0x5b, 0x0a, 0x5c, 0xcc, 0x26, 0xde, 0x6e, 0x57, 0x64, 0xbd, 0xc6, 0xb3, 0x4e, 0x93, 0x1b, - 0x3f, 0x2e, 0xd0, 0x0b, 0x48, 0xf0, 0x07, 0xc0, 0x8d, 0x63, 0x91, 0x7a, 0xe0, 0xc6, 0x0d, 0x55, - 0xe5, 0x52, 0x71, 0xe2, 0x84, 0xa0, 0x15, 0xea, 0x8d, 0x7f, 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, 0x07, 0x71, 0x72, - 0x29, 0x19, 0x8e, 0x79, 0xbb, 0x0d, 0xb3, 0x81, 0x07, 0xf2, 0x52, 0x8c, 0x0d, 0x82, 0x92, 0x2f, - 0x26, 0x41, 0x31, 0x3f, 0x16, 0x1c, 0x0b, 0x7b, 0xa0, 0x2e, 0xc7, 0x86, 0x4b, 0x81, 0x72, 0x39, - 0x21, 0x90, 0x39, 0x34, 0x60, 0x2e, 0xf8, 0x76, 0x3c, 0x17, 0x53, 0x04, 0x0a, 0x93, 0x57, 0x13, - 0xc1, 0x98, 0xab, 0x2e, 0x2c, 0x84, 0x3f, 0x08, 0x2e, 0xc4, 0xd8, 0xe9, 0x41, 0xe5, 0xb5, 0xc4, - 0x50, 0xe6, 0xf6, 0x00, 0x8e, 0x47, 0x3c, 0xd9, 0x8a, 0x31, 0x64, 0xf9, 0xb0, 0x72, 0x25, 0x39, - 0x96, 0x79, 0xfe, 0x4a, 0x80, 0x7c, 0xdc, 0xdd, 0x75, 0x3d, 0x91, 0x5d, 0x5e, 0x49, 0x7e, 0x71, - 0x08, 0x25, 0x16, 0xd5, 0xc7, 0x02, 0x2c, 0x46, 0xdf, 0xf0, 0x56, 0x13, 0x99, 0x66, 0xfd, 0x76, - 0xf9, 0xb9, 0xe0, 0x2c, 0x86, 0xf7, 0x21, 0xdb, 0x77, 0x97, 0x42, 0x61, 0x86, 0x78, 0x8c, 0x5c, - 0x8c, 0xc7, 0xf8, 0x37, 0x6c, 0xe0, 0x2e, 0x10, 0xba, 0x61, 0xfb, 0x51, 0xe1, 0x1b, 0x36, 0xea, - 0xd0, 0x16, 0x37, 0x20, 0x43, 0x0e, 0x6c, 0x29, 0x4c, 0xcb, 0x91, 0xc8, 0x85, 0x28, 0x89, 0xdf, - 0x06, 0x99, 0xab, 0xa1, 0x36, 0x1c, 0x49, 0xb8, 0x0d, 0xee, 0x1c, 0xba, 0x01, 0xe0, 0x3b, 0x42, - 0x72, 0x61, 0xf8, 0x9e, 0x5c, 0x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, 0x00, } // Reference imports to suppress errors if they are not otherwise used. From 43b0a0453ac53bc0b1daf65ce890fa504afaddda Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 18 Jan 2023 18:24:54 +0100 Subject: [PATCH 19/48] Revert --- server/grpc/gogoreflection/doc.go | 2 +- server/grpc/server.go | 3 +-- simapp/app_test.go | 19 ------------------- simapp/go.mod | 3 +-- 4 files changed, 3 insertions(+), 24 deletions(-) diff --git a/server/grpc/gogoreflection/doc.go b/server/grpc/gogoreflection/doc.go index 81fbf5c4c24..691e632d0ee 100644 --- a/server/grpc/gogoreflection/doc.go +++ b/server/grpc/gogoreflection/doc.go @@ -1,4 +1,4 @@ -// Package reflection implements gRPC reflection for gogoproto consumers +// Package gogoreflection implements gRPC reflection for gogoproto consumers // the normal reflection library does not work as it points to a different // singleton registry. The API and codebase is taken from the official gRPC // reflection repository. diff --git a/server/grpc/server.go b/server/grpc/server.go index bfa2e279a9c..78a8e1955af 100644 --- a/server/grpc/server.go +++ b/server/grpc/server.go @@ -10,11 +10,10 @@ import ( "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/server/config" + "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" reflection "github.com/cosmos/cosmos-sdk/server/grpc/reflection/v2alpha1" "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" - gogoreflection "github.com/cosmos/cosmos-sdk/types/reflection" - _ "github.com/cosmos/cosmos-sdk/types/tx/amino" // Import amino.proto file for reflection ) // StartGRPCServer starts a gRPC server on the given address. diff --git a/simapp/app_test.go b/simapp/app_test.go index 43a88835094..c0aa3bd4bf1 100644 --- a/simapp/app_test.go +++ b/simapp/app_test.go @@ -12,16 +12,12 @@ import ( abci "github.com/tendermint/tendermint/abci/types" "github.com/tendermint/tendermint/libs/log" tmproto "github.com/tendermint/tendermint/proto/tendermint/types" - dbm "github.com/tendermint/tm-db" - "google.golang.org/protobuf/reflect/protodesc" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/testutil/mock" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/cosmos/cosmos-sdk/types/reflection" - "github.com/cosmos/cosmos-sdk/types/tx/amino" "github.com/cosmos/cosmos-sdk/x/auth" "github.com/cosmos/cosmos-sdk/x/auth/vesting" authzmodule "github.com/cosmos/cosmos-sdk/x/authz/module" @@ -273,18 +269,3 @@ func TestUpgradeStateOnGenesis(t *testing.T) { require.NotNil(t, app.UpgradeKeeper.GetVersionSetter()) } - -func TestAminoAnnotations(t *testing.T) { - db := dbm.NewMemDB() - logger := log.NewTMLogger(log.NewSyncWriter(os.Stdout)) - app := NewSimApp(logger, db, nil, true, simtestutil.NewAppOptionsWithFlagHome(DefaultNodeHome)) - - fdSet, err := reflection.GetFileDescriptorSet() - require.NoError(t, err) - - fdFiles, err := protodesc.NewFiles(fdSet) - require.NoError(t, err) - - err = amino.ValidateAminoAnnotations(fdFiles, app.legacyAmino) - require.NoError(t, err) -} diff --git a/simapp/go.mod b/simapp/go.mod index 617567727d9..addfd0e82c9 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -23,8 +23,6 @@ require ( google.golang.org/protobuf v1.28.1 ) -require github.com/tendermint/tm-db v0.6.7 - require ( cloud.google.com/go v0.105.0 // indirect cloud.google.com/go/compute v1.13.0 // indirect @@ -158,6 +156,7 @@ require ( github.com/tendermint/btcd v0.1.1 // indirect github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect github.com/tendermint/go-amino v0.16.0 // indirect + github.com/tendermint/tm-db v0.6.7 // indirect github.com/tidwall/btree v1.6.0 // indirect github.com/ulikunitz/xz v0.5.8 // indirect github.com/zondax/hid v0.9.1 // indirect From 61e9b54468d046876c0ae9035882548fddb3488b Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 18 Jan 2023 18:34:43 +0100 Subject: [PATCH 20/48] revert --- simapp/go.sum | 13 ++++++------- tests/go.sum | 9 ++++----- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/simapp/go.sum b/simapp/go.sum index 1ca076c930d..456ed506d19 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -62,6 +62,8 @@ cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= cosmossdk.io/tools/rosetta v0.2.0 h1:Ae499UiZ9yPNCXvjOBO/R9I1pksCJfxoqWauEZgA/gs= cosmossdk.io/tools/rosetta v0.2.0/go.mod h1:3mn8QuE2wLUdTi77/gbDXdFqXZdBdiBJhgAWUTSXPv8= +cosmossdk.io/x/tx v0.1.0 h1:uyyYVjG22B+jf54N803Z99Y1uPvfuNP3K1YShoCHYL8= +cosmossdk.io/x/tx v0.1.0/go.mod h1:qsDv7e1fSftkF16kpSAk+7ROOojyj+SC0Mz3ukI52EQ= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= @@ -125,8 +127,9 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= -github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= @@ -526,6 +529,8 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= +github.com/informalsystems/tendermint v0.37.0-rc2 h1:246LkAwGzKExkwbk7ZP1QVPBd8BZ2L6NMQlzmWgLR34= +github.com/informalsystems/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcVREDC2/HST+EiU5g2+A= github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= @@ -842,14 +847,8 @@ github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= -github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= -github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= -github.com/tendermint/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcVREDC2/HST+EiU5g2+A= github.com/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= github.com/tendermint/tm-db v0.6.7/go.mod h1:byQDzFkZV1syXr/ReXS808NxA2xvyuuVgXOJ/088L6I= github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= diff --git a/tests/go.sum b/tests/go.sum index fa21ea21196..39079f7a2c8 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -60,6 +60,8 @@ cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE= cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= +cosmossdk.io/x/tx v0.1.0 h1:uyyYVjG22B+jf54N803Z99Y1uPvfuNP3K1YShoCHYL8= +cosmossdk.io/x/tx v0.1.0/go.mod h1:qsDv7e1fSftkF16kpSAk+7ROOojyj+SC0Mz3ukI52EQ= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= @@ -123,8 +125,9 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= -github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= @@ -825,10 +828,6 @@ github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= -github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= From bd9dd663ad8bd89b94499392743aa19287a80d5f Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 18 Jan 2023 19:00:11 +0100 Subject: [PATCH 21/48] Make it cleaner --- baseapp/msg_service_router.go | 10 +++-- runtime/services/reflection.go | 49 ++---------------------- server/grpc/gogoreflection/reflection.go | 23 +++++++++++ simapp/go.sum | 13 ++++--- tests/go.sum | 9 +++-- types/msgservice/validate.go | 5 ++- 6 files changed, 48 insertions(+), 61 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 97b17076512..f5cd5eb3c2d 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -9,6 +9,7 @@ import ( "google.golang.org/grpc" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/msgservice" @@ -51,11 +52,12 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { + protoFiles := gogoreflection.GetProtodescResolver() // Make sure the Msg services has the `cosmos.msg.service` proto annotation. - err := msgservice.ValidateServiceAnnotations(fdFiles, sd.ServiceName) + err := msgservice.ValidateServiceAnnotations(protoFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. - fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) + fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %s\n", err) } // Adds a top-level query handler based on the gRPC service name. @@ -78,10 +80,10 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter } // Make sure Msg annotations are correct, like the `cosmos.msg.signer` one. - err := msgservice.ValidateMsgAnnotations(fdFiles, proto.MessageName(msg)) + err := msgservice.ValidateMsgAnnotations(protoFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. - fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %+v\n", err) + fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %s\n", err) } requestTypeName = sdk.MsgTypeURL(msg) diff --git a/runtime/services/reflection.go b/runtime/services/reflection.go index b165ea633ed..5e5ec6ba7b2 100644 --- a/runtime/services/reflection.go +++ b/runtime/services/reflection.go @@ -1,18 +1,10 @@ package services import ( - "bytes" - "compress/gzip" "context" - "io" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - "github.com/cosmos/gogoproto/proto" - "golang.org/x/exp/slices" - protov2 "google.golang.org/protobuf/proto" - "google.golang.org/protobuf/reflect/protodesc" - "google.golang.org/protobuf/reflect/protoreflect" - "google.golang.org/protobuf/reflect/protoregistry" + "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" "google.golang.org/protobuf/types/descriptorpb" ) @@ -23,44 +15,11 @@ type ReflectionService struct { } func NewReflectionService() (*ReflectionService, error) { - fds := &descriptorpb.FileDescriptorSet{} - - // load gogo proto file descriptors - allFds := proto.AllFileDescriptors() - haveFileDescriptor := map[string]bool{} - for _, compressedBz := range allFds { - rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) - if err != nil { - return nil, err - } - - bz, err := io.ReadAll(rdr) - if err != nil { - return nil, err - } - - fd := &descriptorpb.FileDescriptorProto{} - err = protov2.Unmarshal(bz, fd) - if err != nil { - return nil, err - } - - fds.File = append(fds.File, fd) - haveFileDescriptor[*fd.Name] = true + fds, err := gogoreflection.GetFileDescriptorSet() + if err != nil { + return nil, err } - // load any protoregistry file descriptors not in gogo - protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { - if !haveFileDescriptor[fileDescriptor.Path()] { - fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) - } - return true - }) - - slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { - return *x.Name < *y.Name - }) - return &ReflectionService{files: fds}, nil } diff --git a/server/grpc/gogoreflection/reflection.go b/server/grpc/gogoreflection/reflection.go index c3e4f668801..87cf6b24dbf 100644 --- a/server/grpc/gogoreflection/reflection.go +++ b/server/grpc/gogoreflection/reflection.go @@ -14,8 +14,31 @@ import ( "google.golang.org/protobuf/types/descriptorpb" ) +var fdFiles *protoregistry.Files + +// GetProtodescResolver returns the protodesc.Resolver that is combined by +// merging gogo's file descriptor set and protoregistry's one. +func GetProtodescResolver() protodesc.Resolver { + // See if there's a cache already + if fdFiles != nil { + return fdFiles + } + + fdSet, err := GetFileDescriptorSet() + if err != nil { + panic(err) + } + fdFiles, err = protodesc.NewFiles(fdSet) + if err != nil { + panic(err) + } + + return fdFiles +} + // GetFileDescriptorSet returns the global file descriptor set by merging // the one from gogoproto global registry and from protoregistry.GlobalFiles. +// If there's a name conflict, gogo's descriptor is chosen func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { fds := &descriptorpb.FileDescriptorSet{} diff --git a/simapp/go.sum b/simapp/go.sum index 456ed506d19..1ca076c930d 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -62,8 +62,6 @@ cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= cosmossdk.io/tools/rosetta v0.2.0 h1:Ae499UiZ9yPNCXvjOBO/R9I1pksCJfxoqWauEZgA/gs= cosmossdk.io/tools/rosetta v0.2.0/go.mod h1:3mn8QuE2wLUdTi77/gbDXdFqXZdBdiBJhgAWUTSXPv8= -cosmossdk.io/x/tx v0.1.0 h1:uyyYVjG22B+jf54N803Z99Y1uPvfuNP3K1YShoCHYL8= -cosmossdk.io/x/tx v0.1.0/go.mod h1:qsDv7e1fSftkF16kpSAk+7ROOojyj+SC0Mz3ukI52EQ= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= @@ -127,9 +125,8 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= +github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= @@ -529,8 +526,6 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/informalsystems/tendermint v0.37.0-rc2 h1:246LkAwGzKExkwbk7ZP1QVPBd8BZ2L6NMQlzmWgLR34= -github.com/informalsystems/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcVREDC2/HST+EiU5g2+A= github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= @@ -847,8 +842,14 @@ github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= +github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= +github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= +github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= +github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= +github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= +github.com/tendermint/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcVREDC2/HST+EiU5g2+A= github.com/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= github.com/tendermint/tm-db v0.6.7/go.mod h1:byQDzFkZV1syXr/ReXS808NxA2xvyuuVgXOJ/088L6I= github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= diff --git a/tests/go.sum b/tests/go.sum index 39079f7a2c8..fa21ea21196 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -60,8 +60,6 @@ cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE= cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= -cosmossdk.io/x/tx v0.1.0 h1:uyyYVjG22B+jf54N803Z99Y1uPvfuNP3K1YShoCHYL8= -cosmossdk.io/x/tx v0.1.0/go.mod h1:qsDv7e1fSftkF16kpSAk+7ROOojyj+SC0Mz3ukI52EQ= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= @@ -125,9 +123,8 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= +github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= -github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= @@ -828,6 +825,10 @@ github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= +github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= +github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= +github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= +github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index daaa75df452..36d46c22541 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -9,6 +9,7 @@ import ( "google.golang.org/protobuf/reflect/protoregistry" msg "cosmossdk.io/api/cosmos/msg/v1" + "cosmossdk.io/errors" ) // ValidateServiceAnnotations validates that all Msg services have the @@ -22,7 +23,7 @@ func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName str sd, err := fileResolver.FindDescriptorByName(protoreflect.FullName(serviceName)) if err != nil { - return err + return errors.Wrapf(err, "error while validating service annotations for %s", serviceName) } ext := proto.GetExtension(sd.Options(), msg.E_Service) @@ -49,7 +50,7 @@ func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) erro d, err := fileResolver.FindDescriptorByName(protoreflect.FullName(fqName)) if err != nil { - return err + return errors.Wrapf(err, "error while validating msg annotations for %s", fqName) } md := d.(protoreflect.MessageDescriptor) From 39eaea59e3eff3bdf445b1118b890b00cdf39275 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 18 Jan 2023 23:01:24 +0100 Subject: [PATCH 22/48] Add tests --- testutil/testdata/tx.pb.go | 81 +++-------------- testutil/testdata/tx.proto | 5 -- testutil/testdata_pulsar/tx.pulsar.go | 123 +++++--------------------- types/msgservice/validate_test.go | 29 ++++++ 4 files changed, 67 insertions(+), 171 deletions(-) create mode 100644 types/msgservice/validate_test.go diff --git a/testutil/testdata/tx.pb.go b/testutil/testdata/tx.pb.go index 61bcb803385..509d416d283 100644 --- a/testutil/testdata/tx.pb.go +++ b/testutil/testdata/tx.pb.go @@ -30,8 +30,7 @@ var _ = math.Inf const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCreateDog struct { - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` - Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` } func (m *MsgCreateDog) Reset() { *m = MsgCreateDog{} } @@ -74,13 +73,6 @@ func (m *MsgCreateDog) GetDog() *Dog { return nil } -func (m *MsgCreateDog) GetSigner() string { - if m != nil { - return m.Signer - } - return "" -} - type MsgCreateDogResponse struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` } @@ -173,26 +165,24 @@ func init() { func init() { proto.RegisterFile("tx.proto", fileDescriptor_0fd2153dc07d3b5c) } var fileDescriptor_0fd2153dc07d3b5c = []byte{ - // 302 bytes of a gzipped FileDescriptorProto + // 272 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff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xa2, 0x62, 0x09, 0x46, 0x05, 0x66, + 0x0d, 0xce, 0x20, 0x18, 0xd7, 0x8a, 0xa5, 0x63, 0x81, 0x3c, 0x83, 0x91, 0x17, 0x17, 0x33, 0x48, + 0x99, 0x33, 0x17, 0x27, 0xc2, 0x2d, 0x62, 0x08, 0xeb, 0x91, 0xad, 0x94, 0x92, 0xc3, 0x2e, 0x0e, + 0x73, 0x8a, 0x93, 0xc7, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, + 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0xe9, 0xa5, + 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0x43, 0x43, 0x04, 0x42, 0xe9, 0x16, + 0xa7, 0x64, 0xeb, 0x83, 0x4c, 0x2d, 0x2d, 0xc9, 0xcc, 0xd1, 0x87, 0x19, 0x9f, 0xc4, 0x06, 0x0e, + 0x24, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x25, 0x7f, 0x27, 0xad, 0x79, 0x01, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -295,13 +285,6 @@ func (m *MsgCreateDog) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l - if len(m.Signer) > 0 { - i -= len(m.Signer) - copy(dAtA[i:], m.Signer) - i = encodeVarintTx(dAtA, i, uint64(len(m.Signer))) - i-- - dAtA[i] = 0x12 - } if m.Dog != nil { { size, err := m.Dog.MarshalToSizedBuffer(dAtA[:i]) @@ -400,10 +383,6 @@ func (m *MsgCreateDog) Size() (n int) { l = m.Dog.Size() n += 1 + l + sovTx(uint64(l)) } - l = len(m.Signer) - if l > 0 { - n += 1 + l + sovTx(uint64(l)) - } return n } @@ -506,38 +485,6 @@ func (m *MsgCreateDog) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Signer", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowTx - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthTx - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthTx - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) diff --git a/testutil/testdata/tx.proto b/testutil/testdata/tx.proto index 2a812bb4471..aee50d67add 100644 --- a/testutil/testdata/tx.proto +++ b/testutil/testdata/tx.proto @@ -10,16 +10,11 @@ option go_package = "github.com/cosmos/cosmos-sdk/testutil/testdata"; // Msg tests the Protobuf message service as defined in // https://github.com/cosmos/cosmos-sdk/issues/7500. service Msg { - option (cosmos.msg.v1.service) = true; - rpc CreateDog(MsgCreateDog) returns (MsgCreateDogResponse); } message MsgCreateDog { - option (cosmos.msg.v1.signer) = "signer"; - testdata.Dog dog = 1; - string signer = 2; } message MsgCreateDogResponse { diff --git a/testutil/testdata_pulsar/tx.pulsar.go b/testutil/testdata_pulsar/tx.pulsar.go index 7fbd3cf3ceb..cb34be1af77 100644 --- a/testutil/testdata_pulsar/tx.pulsar.go +++ b/testutil/testdata_pulsar/tx.pulsar.go @@ -15,16 +15,14 @@ import ( ) var ( - md_MsgCreateDog protoreflect.MessageDescriptor - fd_MsgCreateDog_dog protoreflect.FieldDescriptor - fd_MsgCreateDog_signer protoreflect.FieldDescriptor + md_MsgCreateDog protoreflect.MessageDescriptor + fd_MsgCreateDog_dog protoreflect.FieldDescriptor ) func init() { file_tx_proto_init() md_MsgCreateDog = File_tx_proto.Messages().ByName("MsgCreateDog") fd_MsgCreateDog_dog = md_MsgCreateDog.Fields().ByName("dog") - fd_MsgCreateDog_signer = md_MsgCreateDog.Fields().ByName("signer") } var _ protoreflect.Message = (*fastReflection_MsgCreateDog)(nil) @@ -98,12 +96,6 @@ func (x *fastReflection_MsgCreateDog) Range(f func(protoreflect.FieldDescriptor, return } } - if x.Signer != "" { - value := protoreflect.ValueOfString(x.Signer) - if !f(fd_MsgCreateDog_signer, value) { - return - } - } } // Has reports whether a field is populated. @@ -121,8 +113,6 @@ func (x *fastReflection_MsgCreateDog) Has(fd protoreflect.FieldDescriptor) bool switch fd.FullName() { case "testdata.MsgCreateDog.dog": return x.Dog != nil - case "testdata.MsgCreateDog.signer": - return x.Signer != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -141,8 +131,6 @@ func (x *fastReflection_MsgCreateDog) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "testdata.MsgCreateDog.dog": x.Dog = nil - case "testdata.MsgCreateDog.signer": - x.Signer = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -162,9 +150,6 @@ func (x *fastReflection_MsgCreateDog) Get(descriptor protoreflect.FieldDescripto case "testdata.MsgCreateDog.dog": value := x.Dog return protoreflect.ValueOfMessage(value.ProtoReflect()) - case "testdata.MsgCreateDog.signer": - value := x.Signer - return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -187,8 +172,6 @@ func (x *fastReflection_MsgCreateDog) Set(fd protoreflect.FieldDescriptor, value switch fd.FullName() { case "testdata.MsgCreateDog.dog": x.Dog = value.Message().Interface().(*Dog) - case "testdata.MsgCreateDog.signer": - x.Signer = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -214,8 +197,6 @@ func (x *fastReflection_MsgCreateDog) Mutable(fd protoreflect.FieldDescriptor) p x.Dog = new(Dog) } return protoreflect.ValueOfMessage(x.Dog.ProtoReflect()) - case "testdata.MsgCreateDog.signer": - panic(fmt.Errorf("field signer of message testdata.MsgCreateDog is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -232,8 +213,6 @@ func (x *fastReflection_MsgCreateDog) NewField(fd protoreflect.FieldDescriptor) case "testdata.MsgCreateDog.dog": m := new(Dog) return protoreflect.ValueOfMessage(m.ProtoReflect()) - case "testdata.MsgCreateDog.signer": - return protoreflect.ValueOfString("") default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testdata.MsgCreateDog")) @@ -307,10 +286,6 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { l = options.Size(x.Dog) n += 1 + l + runtime.Sov(uint64(l)) } - l = len(x.Signer) - if l > 0 { - n += 1 + l + runtime.Sov(uint64(l)) - } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -340,13 +315,6 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } - if len(x.Signer) > 0 { - i -= len(x.Signer) - copy(dAtA[i:], x.Signer) - i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Signer))) - i-- - dAtA[i] = 0x12 - } if x.Dog != nil { encoded, err := options.Marshal(x.Dog) if err != nil { @@ -446,38 +414,6 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex - case 2: - if wireType != 2 { - return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Signer", 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.Signer = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -1431,8 +1367,7 @@ type MsgCreateDog struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` - Signer string `protobuf:"bytes,2,opt,name=signer,proto3" json:"signer,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` } func (x *MsgCreateDog) Reset() { @@ -1462,13 +1397,6 @@ func (x *MsgCreateDog) GetDog() *Dog { return nil } -func (x *MsgCreateDog) GetSigner() string { - if x != nil { - return x.Signer - } - return "" -} - type MsgCreateDogResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1549,32 +1477,29 @@ var file_tx_proto_rawDesc = []byte{ 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x22, 0x54, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, + 0x6f, 0x74, 0x6f, 0x22, 0x2f, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x1f, 0x0a, 0x03, 0x64, 0x6f, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x6f, 0x67, 0x52, - 0x03, 0x64, 0x6f, 0x67, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x3a, 0x0b, 0x82, 0xe7, - 0xb0, 0x2a, 0x06, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, - 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, - 0x09, 0x52, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, - 0x32, 0x51, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x44, 0x6f, 0x67, 0x12, 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, - 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, 0x2e, 0x74, - 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, - 0xb0, 0x2a, 0x01, 0x42, 0x8e, 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, 0x74, 0x65, 0x73, 0x74, - 0x64, 0x61, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, - 0x35, 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, 0x74, 0x65, - 0x73, 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5f, - 0x70, 0x75, 0x6c, 0x73, 0x61, 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x54, - 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, - 0x74, 0x61, 0xe2, 0x02, 0x14, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5c, 0x47, 0x50, - 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, - 0x64, 0x61, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x03, 0x64, 0x6f, 0x67, 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, + 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, + 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, + 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, + 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x32, 0x4a, 0x0a, 0x03, 0x4d, + 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, + 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, + 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x8e, 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, + 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, + 0x6f, 0x50, 0x01, 0x5a, 0x35, 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, 0x74, 0x65, 0x73, 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, + 0x61, 0x74, 0x61, 0x5f, 0x70, 0x75, 0x6c, 0x73, 0x61, 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, + 0xaa, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, + 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xe2, 0x02, 0x14, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, + 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, + 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go new file mode 100644 index 00000000000..8d6a29dde23 --- /dev/null +++ b/types/msgservice/validate_test.go @@ -0,0 +1,29 @@ +package msgservice_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + + _ "cosmossdk.io/api/cosmos/bank/v1beta1" + _ "github.com/cosmos/cosmos-sdk/testutil/testdata_pulsar" + "github.com/cosmos/cosmos-sdk/types/msgservice" +) + +func TestValidateServiceAnnotations(t *testing.T) { + // We didn't add the `msg.service = true` annotation on testdata. + err := msgservice.ValidateServiceAnnotations(nil, "testdata.Msg") + require.Error(t, err) + + err = msgservice.ValidateServiceAnnotations(nil, "cosmos.bank.v1beta1.Msg") + require.NoError(t, err) +} + +func TestValidateMsgAnnotations(t *testing.T) { + // We didn't add any signer on MsgCreateDog. + err := msgservice.ValidateMsgAnnotations(nil, "testdata.MsgCreateDog") + require.Error(t, err) + + err = msgservice.ValidateMsgAnnotations(nil, "cosmos.bank.v1beta1.MsgSend") + require.NoError(t, err) +} From 33f09eda3989543028cfa12c7d53b5c978d4a435 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 10:52:52 +0100 Subject: [PATCH 23/48] Add comments --- types/msgservice/validate_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index 8d6a29dde23..7c6edc02d21 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -11,7 +11,7 @@ import ( ) func TestValidateServiceAnnotations(t *testing.T) { - // We didn't add the `msg.service = true` annotation on testdata. + // We didn't add the `msg.service = true` annotation on testdata's Msg. err := msgservice.ValidateServiceAnnotations(nil, "testdata.Msg") require.Error(t, err) From 64be08449ee4faf1e94b2a6b95aee187ec012471 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:06:36 +0100 Subject: [PATCH 24/48] Support MultiMsgsend --- testutil/testdata/tx.go | 6 ++---- types/msgservice/validate.go | 17 +++++++++++++++-- types/msgservice/validate_test.go | 25 ++++++++++++++++++++----- 3 files changed, 37 insertions(+), 11 deletions(-) diff --git a/testutil/testdata/tx.go b/testutil/testdata/tx.go index 6c6b0aa95b1..f5a40689048 100644 --- a/testutil/testdata/tx.go +++ b/testutil/testdata/tx.go @@ -108,7 +108,5 @@ func (msg *TestMsg) ValidateBasic() error { var _ sdk.Msg = &MsgCreateDog{} -func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { - return []sdk.AccAddress{sdk.MustAccAddressFromBech32(msg.Signer)} -} -func (msg *MsgCreateDog) ValidateBasic() error { return nil } +func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return nil } +func (msg *MsgCreateDog) ValidateBasic() error { return nil } diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index 36d46c22541..f091b869d7b 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -75,8 +75,21 @@ func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) erro return fmt.Errorf("sdk.Msg %s has incorrect signer %s", fqName, signer) } - if fd.Kind() != protoreflect.StringKind { - return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string, got %s", fqName, signer, fd.Kind()) + // The signer annotation should point to: + // - either be a string field, + // - or a message field who recursively has a "signer" string field. + switch fd.Kind() { + case protoreflect.StringKind: + continue + case protoreflect.MessageKind: + err := ValidateMsgAnnotations(fileResolver, string(fd.Message().FullName())) + if err != nil { + return err + } + + continue + default: + return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string or message, got %s", fqName, signer, fd.Kind()) } } diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index 7c6edc02d21..b8c9dd17d26 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -20,10 +20,25 @@ func TestValidateServiceAnnotations(t *testing.T) { } func TestValidateMsgAnnotations(t *testing.T) { - // We didn't add any signer on MsgCreateDog. - err := msgservice.ValidateMsgAnnotations(nil, "testdata.MsgCreateDog") - require.Error(t, err) + testcases := []struct { + name string + typeURL string + expErr bool + }{ + {"no signer annotation", "testdata.MsgCreateDog", true}, + {"valid signer", "cosmos.bank.v1beta1.MsgSend", false}, + {"valid signer as message", "cosmos.bank.v1beta1.MsgMultiSend", false}, + } - err = msgservice.ValidateMsgAnnotations(nil, "cosmos.bank.v1beta1.MsgSend") - require.NoError(t, err) + for _, tc := range testcases { + tc := tc + t.Run(tc.name, func(t *testing.T) { + err := msgservice.ValidateMsgAnnotations(nil, tc.typeURL) + if tc.expErr { + require.Error(t, err) + } else { + require.NoError(t, err) + } + }) + } } From 7152c27778f5c9f3ab1c822072bdf7e34d0ebbb6 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:11:10 +0100 Subject: [PATCH 25/48] Add comments --- server/grpc/gogoreflection/reflection.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/grpc/gogoreflection/reflection.go b/server/grpc/gogoreflection/reflection.go index 87cf6b24dbf..356ea3b41f8 100644 --- a/server/grpc/gogoreflection/reflection.go +++ b/server/grpc/gogoreflection/reflection.go @@ -16,7 +16,7 @@ import ( var fdFiles *protoregistry.Files -// GetProtodescResolver returns the protodesc.Resolver that is combined by +// GetProtodescResolver returns a protodesc.Resolver that is combined by // merging gogo's file descriptor set and protoregistry's one. func GetProtodescResolver() protodesc.Resolver { // See if there's a cache already @@ -38,7 +38,7 @@ func GetProtodescResolver() protodesc.Resolver { // GetFileDescriptorSet returns the global file descriptor set by merging // the one from gogoproto global registry and from protoregistry.GlobalFiles. -// If there's a name conflict, gogo's descriptor is chosen +// If there's a name conflict, gogo's descriptor is chosen. func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { fds := &descriptorpb.FileDescriptorSet{} From ab2000197199502f88bd5a95a82ea7eaeeb2a345 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:12:47 +0100 Subject: [PATCH 26/48] Revert --- testutil/testdata/tx.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testutil/testdata/tx.go b/testutil/testdata/tx.go index f5a40689048..19c1532d640 100644 --- a/testutil/testdata/tx.go +++ b/testutil/testdata/tx.go @@ -108,5 +108,5 @@ func (msg *TestMsg) ValidateBasic() error { var _ sdk.Msg = &MsgCreateDog{} -func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return nil } +func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return []sdk.AccAddress } func (msg *MsgCreateDog) ValidateBasic() error { return nil } From dd1d67ffa1395703e52b8a620b7dde470aa6a62e Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:15:17 +0100 Subject: [PATCH 27/48] revert --- testutil/testdata/tx.pb.go | 33 +++++++++--------- testutil/testdata/tx.proto | 1 - testutil/testdata_pulsar/tx.pulsar.go | 50 +++++++++++++-------------- 3 files changed, 40 insertions(+), 44 deletions(-) diff --git a/testutil/testdata/tx.pb.go b/testutil/testdata/tx.pb.go index 509d416d283..d291b1ee156 100644 --- a/testutil/testdata/tx.pb.go +++ b/testutil/testdata/tx.pb.go @@ -6,7 +6,6 @@ package testdata import ( context "context" fmt "fmt" - _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -165,24 +164,24 @@ func init() { func init() { proto.RegisterFile("tx.proto", fileDescriptor_0fd2153dc07d3b5c) } var fileDescriptor_0fd2153dc07d3b5c = []byte{ - // 272 bytes of a gzipped FileDescriptorProto + // 258 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x28, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x28, 0x49, 0x2d, 0x2e, 0x49, 0x49, 0x2c, 0x49, 0x94, 0x12, - 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x0b, 0xea, 0x83, 0x58, 0x10, 0x79, 0x29, 0x3e, 0x98, 0x3c, 0x94, - 0x2f, 0x9e, 0x9c, 0x5f, 0x9c, 0x9b, 0x5f, 0xac, 0x9f, 0x5b, 0x9c, 0xae, 0x5f, 0x66, 0x08, 0xa2, - 0x20, 0x12, 0x4a, 0xfa, 0x5c, 0x3c, 0xbe, 0xc5, 0xe9, 0xce, 0x45, 0xa9, 0x89, 0x25, 0xa9, 0x2e, - 0xf9, 0xe9, 0x42, 0xf2, 0x5c, 0xcc, 0x29, 0xf9, 0xe9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0xdc, 0x46, - 0xbc, 0x7a, 0x70, 0x63, 0x5c, 0xf2, 0xd3, 0x83, 0x40, 0x32, 0x4a, 0x5a, 0x5c, 0x22, 0xc8, 0x1a, - 0x82, 0x52, 0x8b, 0x0b, 0xf2, 0xf3, 0x8a, 0x53, 0x85, 0x84, 0xb8, 0x58, 0xf2, 0x12, 0x73, 0x53, - 0xc1, 0x3a, 0x39, 0x83, 0xc0, 0x6c, 0x25, 0x4d, 0x2e, 0xf6, 0x90, 0xd4, 0xe2, 0x12, 0xdf, 0xe2, - 0x74, 0x21, 0x09, 0x2e, 0xf6, 0xe2, 0xcc, 0xf4, 0xbc, 0xd4, 0xa2, 0x62, 0x09, 0x46, 0x05, 0x66, - 0x0d, 0xce, 0x20, 0x18, 0xd7, 0x8a, 0xa5, 0x63, 0x81, 0x3c, 0x83, 0x91, 0x17, 0x17, 0x33, 0x48, - 0x99, 0x33, 0x17, 0x27, 0xc2, 0x2d, 0x62, 0x08, 0xeb, 0x91, 0xad, 0x94, 0x92, 0xc3, 0x2e, 0x0e, - 0x73, 0x8a, 0x93, 0xc7, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, - 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0xe9, 0xa5, - 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0x43, 0x43, 0x04, 0x42, 0xe9, 0x16, - 0xa7, 0x64, 0xeb, 0x83, 0x4c, 0x2d, 0x2d, 0xc9, 0xcc, 0xd1, 0x87, 0x19, 0x9f, 0xc4, 0x06, 0x0e, - 0x24, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x25, 0x7f, 0x27, 0xad, 0x79, 0x01, 0x00, 0x00, + 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x0b, 0xea, 0x83, 0x58, 0x10, 0x79, 0x29, 0x3e, 0x98, 0x3c, 0x84, + 0xaf, 0xa4, 0xcf, 0xc5, 0xe3, 0x5b, 0x9c, 0xee, 0x5c, 0x94, 0x9a, 0x58, 0x92, 0xea, 0x92, 0x9f, + 0x2e, 0x24, 0xcf, 0xc5, 0x9c, 0x92, 0x9f, 0x2e, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0x6d, 0xc4, 0xab, + 0x07, 0x57, 0xed, 0x92, 0x9f, 0x1e, 0x04, 0x92, 0x51, 0xd2, 0xe2, 0x12, 0x41, 0xd6, 0x10, 0x94, + 0x5a, 0x5c, 0x90, 0x9f, 0x57, 0x9c, 0x2a, 0x24, 0xc4, 0xc5, 0x92, 0x97, 0x98, 0x9b, 0x0a, 0xd6, + 0xc9, 0x19, 0x04, 0x66, 0x2b, 0x69, 0x72, 0xb1, 0x87, 0xa4, 0x16, 0x97, 0xf8, 0x16, 0xa7, 0x0b, + 0x49, 0x70, 0xb1, 0x17, 0x67, 0xa6, 0xe7, 0xa5, 0x16, 0x15, 0x4b, 0x30, 0x2a, 0x30, 0x6b, 0x70, + 0x06, 0xc1, 0xb8, 0x56, 0x2c, 0x1d, 0x0b, 0xe4, 0x19, 0x8c, 0xbc, 0xb8, 0x98, 0x41, 0xca, 0x9c, + 0xb9, 0x38, 0x11, 0x6e, 0x11, 0x43, 0x58, 0x8f, 0x6c, 0xa5, 0x94, 0x1c, 0x76, 0x71, 0x98, 0x53, + 0x9c, 0x3c, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, + 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x2f, 0x3d, 0xb3, + 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x3f, 0x39, 0xbf, 0x38, 0x37, 0xbf, 0x18, 0x4a, + 0xe9, 0x16, 0xa7, 0x64, 0xeb, 0x83, 0x4c, 0x2d, 0x2d, 0xc9, 0xcc, 0xd1, 0x87, 0x19, 0x9f, 0xc4, + 0x06, 0x0e, 0x24, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x15, 0x63, 0x9a, 0x1b, 0x60, 0x01, + 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/testutil/testdata/tx.proto b/testutil/testdata/tx.proto index aee50d67add..eaeb9580e5e 100644 --- a/testutil/testdata/tx.proto +++ b/testutil/testdata/tx.proto @@ -3,7 +3,6 @@ package testdata; import "gogoproto/gogo.proto"; import "testdata.proto"; -import "cosmos/msg/v1/msg.proto"; option go_package = "github.com/cosmos/cosmos-sdk/testutil/testdata"; diff --git a/testutil/testdata_pulsar/tx.pulsar.go b/testutil/testdata_pulsar/tx.pulsar.go index cb34be1af77..1f171f9bd91 100644 --- a/testutil/testdata_pulsar/tx.pulsar.go +++ b/testutil/testdata_pulsar/tx.pulsar.go @@ -2,7 +2,6 @@ package testdata_pulsar import ( - _ "cosmossdk.io/api/cosmos/msg/v1" fmt "fmt" runtime "github.com/cosmos/cosmos-proto/runtime" _ "github.com/cosmos/gogoproto/gogoproto" @@ -1475,31 +1474,30 @@ var file_tx_proto_rawDesc = []byte{ 0x0a, 0x08, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0e, 0x74, 0x65, 0x73, 0x74, - 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x22, 0x2f, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, - 0x44, 0x6f, 0x67, 0x12, 0x1f, 0x0a, 0x03, 0x64, 0x6f, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x0d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x44, 0x6f, 0x67, 0x52, - 0x03, 0x64, 0x6f, 0x67, 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, - 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, - 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, - 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, - 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x32, 0x4a, 0x0a, 0x03, 0x4d, - 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, - 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, - 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, - 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x8e, 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, - 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, - 0x6f, 0x50, 0x01, 0x5a, 0x35, 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, 0x74, 0x65, 0x73, 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, - 0x61, 0x74, 0x61, 0x5f, 0x70, 0x75, 0x6c, 0x73, 0x61, 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, - 0xaa, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, - 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xe2, 0x02, 0x14, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, - 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, - 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x2f, 0x0a, 0x0c, 0x4d, 0x73, + 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x1f, 0x0a, 0x03, 0x64, 0x6f, + 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, + 0x74, 0x61, 0x2e, 0x44, 0x6f, 0x67, 0x52, 0x03, 0x64, 0x6f, 0x67, 0x22, 0x2a, 0x0a, 0x14, 0x4d, + 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, + 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, + 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, + 0x1f, 0x00, 0x32, 0x4a, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x43, 0x0a, 0x09, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x16, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, + 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1e, + 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x8e, + 0x01, 0x0a, 0x0c, 0x63, 0x6f, 0x6d, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x42, + 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x35, 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, 0x74, 0x65, 0x73, 0x74, 0x75, 0x74, 0x69, + 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x70, 0x75, 0x6c, 0x73, 0x61, + 0x72, 0xa2, 0x02, 0x03, 0x54, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, + 0x74, 0x61, 0xca, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0xe2, 0x02, 0x14, + 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x08, 0x54, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( From e6e6a9829ac11907556bd767e2f8bb2d250dae49 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:16:01 +0100 Subject: [PATCH 28/48] revert --- testutil/testdata/tx.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testutil/testdata/tx.go b/testutil/testdata/tx.go index 19c1532d640..3d659e77d5c 100644 --- a/testutil/testdata/tx.go +++ b/testutil/testdata/tx.go @@ -108,5 +108,5 @@ func (msg *TestMsg) ValidateBasic() error { var _ sdk.Msg = &MsgCreateDog{} -func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return []sdk.AccAddress } +func (msg *MsgCreateDog) GetSigners() []sdk.AccAddress { return []sdk.AccAddress{} } func (msg *MsgCreateDog) ValidateBasic() error { return nil } From cbeddfb4c552d154bee30f52be36bf1ec855702a Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 19 Jan 2023 11:56:28 +0100 Subject: [PATCH 29/48] Don't panic --- baseapp/msg_service_router.go | 8 ++++++-- server/grpc/gogoreflection/reflection.go | 10 +++++----- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index f5cd5eb3c2d..d378e7a684c 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -52,9 +52,13 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - protoFiles := gogoreflection.GetProtodescResolver() + protoFiles, err := gogoreflection.GetProtodescResolver() + if err != nil { + panic(err) + } + // Make sure the Msg services has the `cosmos.msg.service` proto annotation. - err := msgservice.ValidateServiceAnnotations(protoFiles, sd.ServiceName) + err = msgservice.ValidateServiceAnnotations(protoFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %s\n", err) diff --git a/server/grpc/gogoreflection/reflection.go b/server/grpc/gogoreflection/reflection.go index 356ea3b41f8..827908ea3a1 100644 --- a/server/grpc/gogoreflection/reflection.go +++ b/server/grpc/gogoreflection/reflection.go @@ -18,22 +18,22 @@ var fdFiles *protoregistry.Files // GetProtodescResolver returns a protodesc.Resolver that is combined by // merging gogo's file descriptor set and protoregistry's one. -func GetProtodescResolver() protodesc.Resolver { +func GetProtodescResolver() (protodesc.Resolver, error) { // See if there's a cache already if fdFiles != nil { - return fdFiles + return fdFiles, nil } fdSet, err := GetFileDescriptorSet() if err != nil { - panic(err) + return nil, err } fdFiles, err = protodesc.NewFiles(fdSet) if err != nil { - panic(err) + return nil, err } - return fdFiles + return fdFiles, nil } // GetFileDescriptorSet returns the global file descriptor set by merging From 489b2f3ce0c34927455437c9e2f27b6fa8224fda Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Tue, 31 Jan 2023 12:38:12 +0100 Subject: [PATCH 30/48] go-mod-tidy-all --- x/circuit/go.mod | 18 +---- x/circuit/go.sum | 174 ----------------------------------------------- 2 files changed, 1 insertion(+), 191 deletions(-) diff --git a/x/circuit/go.mod b/x/circuit/go.mod index 7d708c32221..b37ed2fab20 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -3,11 +3,9 @@ module github.com/cosmos/cosmos-sdk/x/circuit go 1.19 require ( - github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c github.com/cosmos/cosmos-sdk v0.47.0-rc1 github.com/cosmos/gogoproto v1.4.4 github.com/regen-network/gocuke v0.6.2 - github.com/tendermint/tendermint v0.37.0-rc2 google.golang.org/grpc v1.52.3 gotest.tools/v3 v3.1.0 ) @@ -15,25 +13,16 @@ require ( require ( cosmossdk.io/errors v1.0.0-beta.7 // indirect cosmossdk.io/math v1.0.0-beta.4 // indirect - github.com/DataDog/zstd v1.4.5 // indirect - github.com/HdrHistogram/hdrhistogram-go v1.1.2 // indirect github.com/alecthomas/participle/v2 v2.0.0-alpha7 // indirect - github.com/armon/go-metrics v0.4.1 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect github.com/cockroachdb/apd/v3 v3.1.0 // indirect - github.com/cockroachdb/errors v1.8.1 // indirect - github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f // indirect - github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 // indirect - github.com/cockroachdb/redact v1.0.8 // indirect - github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 // indirect github.com/confio/ics23/go v0.9.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-proto v1.0.0-beta.1 // indirect github.com/cosmos/gorocksdb v1.2.0 // indirect - github.com/cosmos/iavl v0.19.4 // indirect github.com/cucumber/common/gherkin/go/v22 v22.0.0 // indirect github.com/cucumber/common/messages/go/v17 v17.1.1 // indirect github.com/davecgh/go-spew v1.1.1 // indirect @@ -55,16 +44,12 @@ require ( github.com/google/go-cmp v0.5.9 // indirect github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect github.com/gtank/merlin v0.1.1 // indirect - github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect github.com/hashicorp/hcl v1.0.0 // indirect github.com/inconshreveable/mousetrap v1.0.1 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.15.12 // indirect - github.com/kr/pretty v0.3.0 // indirect - github.com/kr/text v0.2.0 // indirect github.com/libp2p/go-buffer-pool v0.1.0 // indirect - github.com/linxGnu/grocksdb v1.7.10 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect @@ -76,7 +61,6 @@ require ( github.com/prometheus/client_model v0.3.0 // indirect github.com/prometheus/common v0.37.0 // indirect github.com/prometheus/procfs v0.8.0 // indirect - github.com/rogpeppe/go-internal v1.8.1 // indirect github.com/sasha-s/go-deadlock v0.3.1 // indirect github.com/spf13/afero v1.9.3 // indirect github.com/spf13/cast v1.5.0 // indirect @@ -87,8 +71,8 @@ require ( github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect github.com/tendermint/go-amino v0.16.0 // indirect + github.com/tendermint/tendermint v0.37.0-rc2 // indirect github.com/tendermint/tm-db v0.6.7 // indirect - github.com/tidwall/btree v1.5.2 // indirect go.etcd.io/bbolt v1.3.6 // indirect golang.org/x/crypto v0.4.0 // indirect golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect diff --git a/x/circuit/go.sum b/x/circuit/go.sum index c9d5246378f..acf995e5055 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -46,25 +46,12 @@ dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7 filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/keyring v1.2.1 h1:tYLp1ULvO7i3fI5vE21ReQuj99QFSs7lGm0xWyJo87o= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= -github.com/CloudyKit/fastprinter v0.0.0-20170127035650-74b38d55f37a/go.mod h1:EFZQ978U7x8IRnstaskI3IysnWY5Ao3QgZUKOXlsAdw= -github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mod h1:HPYO+50pSWkPoj9Q/eq0aRGByCL6ScRlUmiEX5Zgm+w= -github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= -github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= -github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= -github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= -github.com/Joker/jade v1.0.1-0.20190614124447-d475f43051e7/go.mod h1:6E6s8o2AE4KhCrqr6GRJjdC/gNfTdxkIXvuGZZda2VM= github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= -github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= -github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= github.com/alecthomas/participle/v2 v2.0.0-alpha7 h1:cK4vjj0VSgb3lN1nuKA5F7dw+1s1pWBe5bx7nNCnN+c= github.com/alecthomas/participle/v2 v2.0.0-alpha7/go.mod h1:NumScqsC42o9x+dGj8/YqsIfhrIQjFEOFovxotbBirA= github.com/alecthomas/repr v0.0.0-20181024024818-d37bc2a10ba1 h1:GDQdwm/gAcJcLAKQQZGOJ4knlw+7rfEQQcmwTbt4p5E= @@ -77,8 +64,6 @@ github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk5 github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= -github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -97,27 +82,12 @@ github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XL github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= -github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cockroachdb/apd/v3 v3.1.0 h1:MK3Ow7LH0W8zkd5GMKA1PvS9qG3bWFI95WaVNfyZJ/w= github.com/cockroachdb/apd/v3 v3.1.0/go.mod h1:6qgPBMXjATAdD/VefbRP9NoSLKjbB4LCoA7gN4LpHs4= -github.com/cockroachdb/datadriven v1.0.0/go.mod h1:5Ib8Meh+jk1RlHIXej6Pzevx/NLlNvQB9pmSBZErGA4= -github.com/cockroachdb/errors v1.6.1/go.mod h1:tm6FTP5G81vwJ5lC0SizQo374JNCOPrHyXGitRJoDqM= -github.com/cockroachdb/errors v1.8.1 h1:A5+txlVZfOqFBDa4mGz2bUWSp0aHElvHX2bKkdbQu+Y= -github.com/cockroachdb/errors v1.8.1/go.mod h1:qGwQn6JmZ+oMjuLwjWzUNqblqk0xl4CVV3SQbGwK7Ac= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f h1:o/kfcElHqOiXqcou5a3rIlMc7oJbMQkeLk0VQJ7zgqY= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 h1:qbb/AE938DFhOajUYh9+OXELpSF9KZw2ZivtmW6eX1Q= -github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677/go.mod h1:890yq1fUb9b6dGNwssgeUO5vQV9qfXnCPxAJhBQfXw0= -github.com/cockroachdb/redact v1.0.8 h1:8QG/764wK+vmEYoOlfobpe12EQcS81ukx/a4hdVMxNw= -github.com/cockroachdb/redact v1.0.8/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 h1:IKgmqgMQlVJIZj19CdocBeSfSaiCbEBZGKODaixqtHM= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2/go.mod h1:8BT+cPK6xvFOcRlk0R8eg+OTkcqI6baNH4xAkpiYVvQ= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -125,8 +95,6 @@ github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8Nz github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= -github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c h1:18vrPZBG4Zuh8A/sD5hFu252QLLgwdQ6mTsc8pT56QU= -github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c/go.mod h1:NoM5UQkpKJY86c0Acb8Hy7HyNrltal8+BxQyerU8fzM= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= github.com/cosmos/cosmos-sdk v0.47.0-rc1 h1:ptoLIOAqFGoqnZeqgec9KvC2JIZ6CVIyMHHjti9p6dQ= @@ -138,11 +106,9 @@ github.com/cosmos/gogoproto v1.4.4/go.mod h1:/yl6/nLwsZcZ2JY3OrqjRqvqCG9InUMcXRf github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= github.com/cosmos/iavl v0.19.4 h1:t82sN+Y0WeqxDLJRSpNd8YFX5URIrT+p8n6oJbJ2Dok= -github.com/cosmos/iavl v0.19.4/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVNihy1Y984w= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= github.com/cucumber/common/gherkin/go/v22 v22.0.0/go.mod h1:3mJT10B2GGn3MvVPd3FwR7m2u4tLhSRhWUqJU4KN4Fg= github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= @@ -154,49 +120,34 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 h1:HbphB4TFFXpv7MNrT52FGrrgVXF1owhMVTHFZIlnvd4= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= -github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o= github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= -github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dvsekhvalnov/jose2go v1.5.0 h1:3j8ya4Z4kMCwT5nXIKFSV84YS+HdqSSO0VsTQxaLAeM= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 h1:7HZCaLC5+BZpmbhCOZJ293Lz68O7PYrF2EzeiFMwCLk= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/felixge/httpsnoop v1.0.2 h1:+nS9g82KMXccJ/wp0zyRW9ZBHFETmMGtkk+2CTTrW4o= -github.com/flosch/pongo2 v0.0.0-20190707114632-bbf5a6c351f4/go.mod h1:T9YF2M40nIgbVgp3rreNmTged+9HrbNTIQf1PsaIiTA= -github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/frankban/quicktest v1.14.3 h1:FJKSZTDHjyhriyC81FLQ0LY93eSai0ZyR/ZIkd3ZUKE= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= -github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= -github.com/ghemawat/stream v0.0.0-20171120220530-696b145b53b9/go.mod h1:106OIgooyS7OzLDOpUGgm9fA3bQENb/cFSyyBmMoJDs= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= -github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= -github.com/go-errors/errors v1.0.1 h1:LUHzmkK3GUKUrL/1gfBUxAHzcev3apQlezX/+O7ma6w= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -213,24 +164,15 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.5.1 h1:otpy5pqBCBZ1ng9RQ0dPu4PN7ba75Y/aA+UpowDyNVA= github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.2.0+incompatible h1:yyYWMnhkhrKwwr8gAOcOCYxOOscHgDS9yZgBrnJfGa0= github.com/gofrs/uuid v4.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869 h1:kRpU4zq+Pzh4feET49aEWPOzwQy3U2SsbZEQ7QEcif0= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= -github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.0.0 h1:nfP3RFugxnNRyKgeWd4oI1nYvXpxrx8ck8ZrcizshdQ= github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= @@ -266,7 +208,6 @@ github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiu github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= @@ -283,7 +224,6 @@ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -305,10 +245,8 @@ github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= -github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= @@ -317,15 +255,7 @@ github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8 github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= -github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= -github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= -github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= -github.com/hashicorp/go-uuid v1.0.0 h1:RS8zrF7PhGwyNPOtxSClXXj9HA8feRnJzgnI1RJCSnM= -github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= -github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= @@ -335,82 +265,46 @@ github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 h1:aSVUgRRRtOrZOC1fYmY9gV0e9z/Iu+xNVSASWjsuyGU= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= -github.com/hydrogen18/memlistener v0.0.0-20141126152155-54553eb933fb/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= -github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= -github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5/go.mod h1:W54LbzXuIE0boCoNJfwqpmkKJ1O4TCTZMetAt6jGk7Q= -github.com/juju/loggo v0.0.0-20180524022052-584905176618/go.mod h1:vgyd7OREkbtVEN/8IXZe5Ooef3LQePvuBm9UWj6ZL8U= -github.com/juju/testing v0.0.0-20180920084828-472a3e8b2073/go.mod h1:63prj8cnj0tU0S9OHjGJn+b1h0ZghCndfnbQolrYTwA= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= -github.com/kataras/golog v0.0.9/go.mod h1:12HJgwBIZFNGL0EJnMRhmvGA0PQGx8VFwrZtM4CqbAk= -github.com/kataras/iris/v12 v12.0.1/go.mod h1:udK4vLQKkdDqMGJJVd/msuMtN6hpYJhg/lSzuxjhO+U= -github.com/kataras/neffos v0.0.10/go.mod h1:ZYmJC07hQPW67eKuzlfY7SO3bC0mw83A3j6im82hfqw= -github.com/kataras/pio v0.0.0-20190103105442-ea782b38602d/go.mod h1:NV88laa9UiiDuX9AhMbDPkGYSPugBOV6yTZB1l2K9Z0= -github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.15.12 h1:YClS/PImqYbn+UILDnqxQCZ3RehC9N318SU3kElDUEM= github.com/klauspost/compress v1.15.12/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= -github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/labstack/echo/v4 v4.1.11/go.mod h1:i541M3Fj6f76NZtHSj7TXnyM8n2gaodfvfxNnFqi74g= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6cdF0Y8= github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= -github.com/linxGnu/grocksdb v1.7.10 h1:dz7RY7GnFUA+GJO6jodyxgkUeGMEkPp3ikt9hAcNGEw= -github.com/linxGnu/grocksdb v1.7.10/go.mod h1:0hTf+iA+GOr0jDX4CgIYyJZxqOH9XlBh6KVj8+zmF34= github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ= -github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mediocregopher/mediocre-go-lib v0.0.0-20181029021733-cb65787f37ed/go.mod h1:dSsfyI2zABAdhcbvkXqgxOxrCsbYeHCPgrZkku60dSg= -github.com/mediocregopher/radix/v3 v3.3.0/go.mod h1:EmfVyvspXz1uZEyPBMyGK+kjWiKQGvsUt6O3Pj+LDCQ= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= @@ -423,34 +317,23 @@ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= -github.com/nats-io/nats.go v1.8.1/go.mod h1:BrFz9vVn0fU3AcH9Vn4Kd7W0NpJ651tD5omQ3M8LwxM= -github.com/nats-io/nkeys v0.0.2/go.mod h1:dab7URMsZm6Z/jp9Z5UGa87Uutgc2mVpXLC4B7TDb/4= -github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= -github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.13.0/go.mod h1:+REjRxOmWfHCjfv9TTWB1jD1Frx4XydAD3zm1lskyM0= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.20.0 h1:8W0cWlwFkflGPLltQvLRB7ZVD5HuP6ng320w2IS245Q= -github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= -github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml/v2 v2.0.6 h1:nrzqCb7j9cDFj2coyLNLaZuJTLjWjlaz6nvTvIwycIU= github.com/pelletier/go-toml/v2 v2.0.6/go.mod h1:eumQOmlWiOPt5WriQQqoM5y18pDHwha2N+QD+EUNTek= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5 h1:q2e307iGHPdTGp0hoxKjt1H5pDo6utceo3dQVK3I5XQ= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= -github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= -github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= -github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -460,7 +343,6 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= -github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= @@ -473,7 +355,6 @@ github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6T github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= @@ -481,7 +362,6 @@ github.com/prometheus/common v0.37.0 h1:ccBbHCgIiT9uSoFY0vX8H3zsNR5eLt17/RQLUvn8 github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= @@ -492,22 +372,14 @@ github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGn github.com/regen-network/gocuke v0.6.2/go.mod h1:zYaqIHZobHyd0xOrHGPQjbhGJsuZ1oElx150u2o1xuk= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rogpeppe/go-internal v1.8.1 h1:geMPLpDpQOgVyCg5z5GoRwLHepNdb71NXb67XFkP+Eg= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= -github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZKJ48R1S7H23Ji7oFO5Bw= -github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= -github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= -github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= @@ -555,23 +427,8 @@ github.com/tendermint/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcV github.com/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= github.com/tendermint/tm-db v0.6.7/go.mod h1:byQDzFkZV1syXr/ReXS808NxA2xvyuuVgXOJ/088L6I= github.com/tidwall/btree v1.5.2 h1:5eA83Gfki799V3d3bJo9sWk+yL2LRoTEah3O/SA6/8w= -github.com/tidwall/btree v1.5.2/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= -github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= -github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= -github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -591,17 +448,13 @@ golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnf golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.4.0 h1:UVQgzMY87xqpKNgb+kDsll2Igd33HszWHFLmpaRMq/8= golang.org/x/crypto v0.4.0/go.mod h1:3quD/ATkf6oY+rnes5c3ExXTbLc8mueNue5/DoinL80= -golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= @@ -611,10 +464,8 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= -golang.org/x/exp v0.0.0-20200513190911-00229845015e/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg= golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= -golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -642,11 +493,9 @@ golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -655,7 +504,6 @@ golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -703,14 +551,12 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -720,7 +566,6 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -758,7 +603,6 @@ golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210909193231-528a39cd75f3/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -781,18 +625,12 @@ golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -840,11 +678,6 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.8.2 h1:CCXrcPKiGGotvnN6jfUsKk4rRqm7q09/YbKb5xCEvtM= -gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0= -gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -871,7 +704,6 @@ google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= @@ -912,7 +744,6 @@ google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa h1:qQPhfbPO23fwm/9lQr91L1u62Zo6cm+zI+slZT+uf+o= google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= -google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -950,15 +781,11 @@ gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLks gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= -gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -984,7 +811,6 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 pgregory.net/rapid v0.5.3 h1:163N50IHFqr1phZens4FQOdPgfJscR7a562mjQqeo4M= pgregory.net/rapid v0.5.3/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= From 862cbec96a2abb733b246ec3c3102cffed70cad8 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Tue, 31 Jan 2023 12:42:41 +0100 Subject: [PATCH 31/48] Revert --- runtime/services/reflection.go | 49 ++++++- server/grpc/gogoreflection/reflection.go | 93 ------------ server/grpc/server.go | 1 + x/circuit/go.mod | 18 ++- x/circuit/go.sum | 174 +++++++++++++++++++++++ 5 files changed, 237 insertions(+), 98 deletions(-) delete mode 100644 server/grpc/gogoreflection/reflection.go diff --git a/runtime/services/reflection.go b/runtime/services/reflection.go index 5e5ec6ba7b2..b165ea633ed 100644 --- a/runtime/services/reflection.go +++ b/runtime/services/reflection.go @@ -1,10 +1,18 @@ package services import ( + "bytes" + "compress/gzip" "context" + "io" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" + "github.com/cosmos/gogoproto/proto" + "golang.org/x/exp/slices" + protov2 "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoreflect" + "google.golang.org/protobuf/reflect/protoregistry" "google.golang.org/protobuf/types/descriptorpb" ) @@ -15,11 +23,44 @@ type ReflectionService struct { } func NewReflectionService() (*ReflectionService, error) { - fds, err := gogoreflection.GetFileDescriptorSet() - if err != nil { - return nil, err + fds := &descriptorpb.FileDescriptorSet{} + + // load gogo proto file descriptors + allFds := proto.AllFileDescriptors() + haveFileDescriptor := map[string]bool{} + for _, compressedBz := range allFds { + rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) + if err != nil { + return nil, err + } + + bz, err := io.ReadAll(rdr) + if err != nil { + return nil, err + } + + fd := &descriptorpb.FileDescriptorProto{} + err = protov2.Unmarshal(bz, fd) + if err != nil { + return nil, err + } + + fds.File = append(fds.File, fd) + haveFileDescriptor[*fd.Name] = true } + // load any protoregistry file descriptors not in gogo + protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { + if !haveFileDescriptor[fileDescriptor.Path()] { + fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) + } + return true + }) + + slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { + return *x.Name < *y.Name + }) + return &ReflectionService{files: fds}, nil } diff --git a/server/grpc/gogoreflection/reflection.go b/server/grpc/gogoreflection/reflection.go deleted file mode 100644 index 827908ea3a1..00000000000 --- a/server/grpc/gogoreflection/reflection.go +++ /dev/null @@ -1,93 +0,0 @@ -package gogoreflection - -import ( - "bytes" - "compress/gzip" - "io" - - gogoproto "github.com/cosmos/gogoproto/proto" - "golang.org/x/exp/slices" - protov2 "google.golang.org/protobuf/proto" - "google.golang.org/protobuf/reflect/protodesc" - "google.golang.org/protobuf/reflect/protoreflect" - "google.golang.org/protobuf/reflect/protoregistry" - "google.golang.org/protobuf/types/descriptorpb" -) - -var fdFiles *protoregistry.Files - -// GetProtodescResolver returns a protodesc.Resolver that is combined by -// merging gogo's file descriptor set and protoregistry's one. -func GetProtodescResolver() (protodesc.Resolver, error) { - // See if there's a cache already - if fdFiles != nil { - return fdFiles, nil - } - - fdSet, err := GetFileDescriptorSet() - if err != nil { - return nil, err - } - fdFiles, err = protodesc.NewFiles(fdSet) - if err != nil { - return nil, err - } - - return fdFiles, nil -} - -// GetFileDescriptorSet returns the global file descriptor set by merging -// the one from gogoproto global registry and from protoregistry.GlobalFiles. -// If there's a name conflict, gogo's descriptor is chosen. -func GetFileDescriptorSet() (*descriptorpb.FileDescriptorSet, error) { - fds := &descriptorpb.FileDescriptorSet{} - - // load gogo proto file descriptors - allFds := gogoproto.AllFileDescriptors() - haveFileDescriptor := map[string]bool{} - for _, compressedBz := range allFds { - rdr, err := gzip.NewReader(bytes.NewReader(compressedBz)) - if err != nil { - return nil, err - } - - bz, err := io.ReadAll(rdr) - if err != nil { - return nil, err - } - - fd := &descriptorpb.FileDescriptorProto{} - err = protov2.Unmarshal(bz, fd) - if err != nil { - return nil, err - } - - // It seems we're registering twice gogo.proto. - // See Frojdi's comments in server/grpc/gogoreflection/fix_registration.go. - // Skipping here `gogo.proto` and only including `gogoproto/gogo.proto`. - if *fd.Name == "gogo.proto" || - // If we don't skip this one, we have the error: - // proto: file "descriptor.proto" has a name conflict over google.protobuf.FileDescriptorSet - // Is it because we're importing "google.golang.org/protobuf/types/descriptorpb"? - *fd.Name == "descriptor.proto" { - continue - } - - fds.File = append(fds.File, fd) - haveFileDescriptor[*fd.Name] = true - } - - // load any protoregistry file descriptors not in gogo - protoregistry.GlobalFiles.RangeFiles(func(fileDescriptor protoreflect.FileDescriptor) bool { - if !haveFileDescriptor[fileDescriptor.Path()] { - fds.File = append(fds.File, protodesc.ToFileDescriptorProto(fileDescriptor)) - } - return true - }) - - slices.SortFunc(fds.File, func(x, y *descriptorpb.FileDescriptorProto) bool { - return *x.Name < *y.Name - }) - - return fds, nil -} diff --git a/server/grpc/server.go b/server/grpc/server.go index 78a8e1955af..79a9be3dca2 100644 --- a/server/grpc/server.go +++ b/server/grpc/server.go @@ -14,6 +14,7 @@ import ( reflection "github.com/cosmos/cosmos-sdk/server/grpc/reflection/v2alpha1" "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" // Import amino.proto file for reflection ) // StartGRPCServer starts a gRPC server on the given address. diff --git a/x/circuit/go.mod b/x/circuit/go.mod index b37ed2fab20..7d708c32221 100644 --- a/x/circuit/go.mod +++ b/x/circuit/go.mod @@ -3,9 +3,11 @@ module github.com/cosmos/cosmos-sdk/x/circuit go 1.19 require ( + github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c github.com/cosmos/cosmos-sdk v0.47.0-rc1 github.com/cosmos/gogoproto v1.4.4 github.com/regen-network/gocuke v0.6.2 + github.com/tendermint/tendermint v0.37.0-rc2 google.golang.org/grpc v1.52.3 gotest.tools/v3 v3.1.0 ) @@ -13,16 +15,25 @@ require ( require ( cosmossdk.io/errors v1.0.0-beta.7 // indirect cosmossdk.io/math v1.0.0-beta.4 // indirect + github.com/DataDog/zstd v1.4.5 // indirect + github.com/HdrHistogram/hdrhistogram-go v1.1.2 // indirect github.com/alecthomas/participle/v2 v2.0.0-alpha7 // indirect + github.com/armon/go-metrics v0.4.1 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.1.2 // indirect github.com/cockroachdb/apd/v3 v3.1.0 // indirect + github.com/cockroachdb/errors v1.8.1 // indirect + github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f // indirect + github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 // indirect + github.com/cockroachdb/redact v1.0.8 // indirect + github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 // indirect github.com/confio/ics23/go v0.9.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-proto v1.0.0-beta.1 // indirect github.com/cosmos/gorocksdb v1.2.0 // indirect + github.com/cosmos/iavl v0.19.4 // indirect github.com/cucumber/common/gherkin/go/v22 v22.0.0 // indirect github.com/cucumber/common/messages/go/v17 v17.1.1 // indirect github.com/davecgh/go-spew v1.1.1 // indirect @@ -44,12 +55,16 @@ require ( github.com/google/go-cmp v0.5.9 // indirect github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect github.com/gtank/merlin v0.1.1 // indirect + github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect github.com/hashicorp/hcl v1.0.0 // indirect github.com/inconshreveable/mousetrap v1.0.1 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.15.12 // indirect + github.com/kr/pretty v0.3.0 // indirect + github.com/kr/text v0.2.0 // indirect github.com/libp2p/go-buffer-pool v0.1.0 // indirect + github.com/linxGnu/grocksdb v1.7.10 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect @@ -61,6 +76,7 @@ require ( github.com/prometheus/client_model v0.3.0 // indirect github.com/prometheus/common v0.37.0 // indirect github.com/prometheus/procfs v0.8.0 // indirect + github.com/rogpeppe/go-internal v1.8.1 // indirect github.com/sasha-s/go-deadlock v0.3.1 // indirect github.com/spf13/afero v1.9.3 // indirect github.com/spf13/cast v1.5.0 // indirect @@ -71,8 +87,8 @@ require ( github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tendermint/tendermint v0.37.0-rc2 // indirect github.com/tendermint/tm-db v0.6.7 // indirect + github.com/tidwall/btree v1.5.2 // indirect go.etcd.io/bbolt v1.3.6 // indirect golang.org/x/crypto v0.4.0 // indirect golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect diff --git a/x/circuit/go.sum b/x/circuit/go.sum index acf995e5055..c9d5246378f 100644 --- a/x/circuit/go.sum +++ b/x/circuit/go.sum @@ -46,12 +46,25 @@ dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7 filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/keyring v1.2.1 h1:tYLp1ULvO7i3fI5vE21ReQuj99QFSs7lGm0xWyJo87o= +github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= +github.com/CloudyKit/fastprinter v0.0.0-20170127035650-74b38d55f37a/go.mod h1:EFZQ978U7x8IRnstaskI3IysnWY5Ao3QgZUKOXlsAdw= +github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mod h1:HPYO+50pSWkPoj9Q/eq0aRGByCL6ScRlUmiEX5Zgm+w= +github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= +github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= +github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= +github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= +github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo= +github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= +github.com/Joker/jade v1.0.1-0.20190614124447-d475f43051e7/go.mod h1:6E6s8o2AE4KhCrqr6GRJjdC/gNfTdxkIXvuGZZda2VM= github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= +github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= +github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= +github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= github.com/alecthomas/participle/v2 v2.0.0-alpha7 h1:cK4vjj0VSgb3lN1nuKA5F7dw+1s1pWBe5bx7nNCnN+c= github.com/alecthomas/participle/v2 v2.0.0-alpha7/go.mod h1:NumScqsC42o9x+dGj8/YqsIfhrIQjFEOFovxotbBirA= github.com/alecthomas/repr v0.0.0-20181024024818-d37bc2a10ba1 h1:GDQdwm/gAcJcLAKQQZGOJ4knlw+7rfEQQcmwTbt4p5E= @@ -64,6 +77,8 @@ github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk5 github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= +github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= +github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -82,12 +97,27 @@ github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XL github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= +github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= +github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cockroachdb/apd/v3 v3.1.0 h1:MK3Ow7LH0W8zkd5GMKA1PvS9qG3bWFI95WaVNfyZJ/w= github.com/cockroachdb/apd/v3 v3.1.0/go.mod h1:6qgPBMXjATAdD/VefbRP9NoSLKjbB4LCoA7gN4LpHs4= +github.com/cockroachdb/datadriven v1.0.0/go.mod h1:5Ib8Meh+jk1RlHIXej6Pzevx/NLlNvQB9pmSBZErGA4= +github.com/cockroachdb/errors v1.6.1/go.mod h1:tm6FTP5G81vwJ5lC0SizQo374JNCOPrHyXGitRJoDqM= +github.com/cockroachdb/errors v1.8.1 h1:A5+txlVZfOqFBDa4mGz2bUWSp0aHElvHX2bKkdbQu+Y= +github.com/cockroachdb/errors v1.8.1/go.mod h1:qGwQn6JmZ+oMjuLwjWzUNqblqk0xl4CVV3SQbGwK7Ac= +github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f h1:o/kfcElHqOiXqcou5a3rIlMc7oJbMQkeLk0VQJ7zgqY= +github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= +github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 h1:qbb/AE938DFhOajUYh9+OXELpSF9KZw2ZivtmW6eX1Q= +github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677/go.mod h1:890yq1fUb9b6dGNwssgeUO5vQV9qfXnCPxAJhBQfXw0= +github.com/cockroachdb/redact v1.0.8 h1:8QG/764wK+vmEYoOlfobpe12EQcS81ukx/a4hdVMxNw= +github.com/cockroachdb/redact v1.0.8/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 h1:IKgmqgMQlVJIZj19CdocBeSfSaiCbEBZGKODaixqtHM= +github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2/go.mod h1:8BT+cPK6xvFOcRlk0R8eg+OTkcqI6baNH4xAkpiYVvQ= +github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -95,6 +125,8 @@ github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8Nz github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= +github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c h1:18vrPZBG4Zuh8A/sD5hFu252QLLgwdQ6mTsc8pT56QU= +github.com/cosmos/cosmos-db v0.0.0-20230119180254-161cf3632b7c/go.mod h1:NoM5UQkpKJY86c0Acb8Hy7HyNrltal8+BxQyerU8fzM= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= github.com/cosmos/cosmos-sdk v0.47.0-rc1 h1:ptoLIOAqFGoqnZeqgec9KvC2JIZ6CVIyMHHjti9p6dQ= @@ -106,9 +138,11 @@ github.com/cosmos/gogoproto v1.4.4/go.mod h1:/yl6/nLwsZcZ2JY3OrqjRqvqCG9InUMcXRf github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= github.com/cosmos/iavl v0.19.4 h1:t82sN+Y0WeqxDLJRSpNd8YFX5URIrT+p8n6oJbJ2Dok= +github.com/cosmos/iavl v0.19.4/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVNihy1Y984w= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= github.com/cucumber/common/gherkin/go/v22 v22.0.0/go.mod h1:3mJT10B2GGn3MvVPd3FwR7m2u4tLhSRhWUqJU4KN4Fg= github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= @@ -120,34 +154,49 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 h1:HbphB4TFFXpv7MNrT52FGrrgVXF1owhMVTHFZIlnvd4= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= +github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o= github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= +github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dvsekhvalnov/jose2go v1.5.0 h1:3j8ya4Z4kMCwT5nXIKFSV84YS+HdqSSO0VsTQxaLAeM= +github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 h1:7HZCaLC5+BZpmbhCOZJ293Lz68O7PYrF2EzeiFMwCLk= +github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= +github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/felixge/httpsnoop v1.0.2 h1:+nS9g82KMXccJ/wp0zyRW9ZBHFETmMGtkk+2CTTrW4o= +github.com/flosch/pongo2 v0.0.0-20190707114632-bbf5a6c351f4/go.mod h1:T9YF2M40nIgbVgp3rreNmTged+9HrbNTIQf1PsaIiTA= +github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/frankban/quicktest v1.14.3 h1:FJKSZTDHjyhriyC81FLQ0LY93eSai0ZyR/ZIkd3ZUKE= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= +github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= +github.com/ghemawat/stream v0.0.0-20171120220530-696b145b53b9/go.mod h1:106OIgooyS7OzLDOpUGgm9fA3bQENb/cFSyyBmMoJDs= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= +github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= +github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= +github.com/go-errors/errors v1.0.1 h1:LUHzmkK3GUKUrL/1gfBUxAHzcev3apQlezX/+O7ma6w= +github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= @@ -164,15 +213,24 @@ github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.5.1 h1:otpy5pqBCBZ1ng9RQ0dPu4PN7ba75Y/aA+UpowDyNVA= github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= +github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= +github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.2.0+incompatible h1:yyYWMnhkhrKwwr8gAOcOCYxOOscHgDS9yZgBrnJfGa0= github.com/gofrs/uuid v4.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= +github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869 h1:kRpU4zq+Pzh4feET49aEWPOzwQy3U2SsbZEQ7QEcif0= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= +github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.0.0 h1:nfP3RFugxnNRyKgeWd4oI1nYvXpxrx8ck8ZrcizshdQ= github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= @@ -208,6 +266,7 @@ github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiu github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= @@ -224,6 +283,7 @@ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -245,8 +305,10 @@ github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= +github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= +github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= @@ -255,7 +317,15 @@ github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8 github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= +github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= +github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= +github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= +github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= +github.com/hashicorp/go-uuid v1.0.0 h1:RS8zrF7PhGwyNPOtxSClXXj9HA8feRnJzgnI1RJCSnM= +github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= +github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= @@ -265,46 +335,82 @@ github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 h1:aSVUgRRRtOrZOC1fYmY9gV0e9z/Iu+xNVSASWjsuyGU= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= +github.com/hydrogen18/memlistener v0.0.0-20141126152155-54553eb933fb/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= +github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= +github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= +github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= +github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= +github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/juju/errors v0.0.0-20181118221551-089d3ea4e4d5/go.mod h1:W54LbzXuIE0boCoNJfwqpmkKJ1O4TCTZMetAt6jGk7Q= +github.com/juju/loggo v0.0.0-20180524022052-584905176618/go.mod h1:vgyd7OREkbtVEN/8IXZe5Ooef3LQePvuBm9UWj6ZL8U= +github.com/juju/testing v0.0.0-20180920084828-472a3e8b2073/go.mod h1:63prj8cnj0tU0S9OHjGJn+b1h0ZghCndfnbQolrYTwA= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= +github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= +github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= +github.com/kataras/golog v0.0.9/go.mod h1:12HJgwBIZFNGL0EJnMRhmvGA0PQGx8VFwrZtM4CqbAk= +github.com/kataras/iris/v12 v12.0.1/go.mod h1:udK4vLQKkdDqMGJJVd/msuMtN6hpYJhg/lSzuxjhO+U= +github.com/kataras/neffos v0.0.10/go.mod h1:ZYmJC07hQPW67eKuzlfY7SO3bC0mw83A3j6im82hfqw= +github.com/kataras/pio v0.0.0-20190103105442-ea782b38602d/go.mod h1:NV88laa9UiiDuX9AhMbDPkGYSPugBOV6yTZB1l2K9Z0= +github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= +github.com/klauspost/compress v1.9.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= +github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.15.12 h1:YClS/PImqYbn+UILDnqxQCZ3RehC9N318SU3kElDUEM= github.com/klauspost/compress v1.15.12/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= +github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0= +github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/labstack/echo/v4 v4.1.11/go.mod h1:i541M3Fj6f76NZtHSj7TXnyM8n2gaodfvfxNnFqi74g= +github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6cdF0Y8= github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= +github.com/linxGnu/grocksdb v1.7.10 h1:dz7RY7GnFUA+GJO6jodyxgkUeGMEkPp3ikt9hAcNGEw= +github.com/linxGnu/grocksdb v1.7.10/go.mod h1:0hTf+iA+GOr0jDX4CgIYyJZxqOH9XlBh6KVj8+zmF34= github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= +github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= +github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= +github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= +github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.16 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ= +github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= +github.com/mediocregopher/mediocre-go-lib v0.0.0-20181029021733-cb65787f37ed/go.mod h1:dSsfyI2zABAdhcbvkXqgxOxrCsbYeHCPgrZkku60dSg= +github.com/mediocregopher/radix/v3 v3.3.0/go.mod h1:EmfVyvspXz1uZEyPBMyGK+kjWiKQGvsUt6O3Pj+LDCQ= +github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= @@ -317,23 +423,34 @@ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= +github.com/nats-io/nats.go v1.8.1/go.mod h1:BrFz9vVn0fU3AcH9Vn4Kd7W0NpJ651tD5omQ3M8LwxM= +github.com/nats-io/nkeys v0.0.2/go.mod h1:dab7URMsZm6Z/jp9Z5UGa87Uutgc2mVpXLC4B7TDb/4= +github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= +github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.13.0/go.mod h1:+REjRxOmWfHCjfv9TTWB1jD1Frx4XydAD3zm1lskyM0= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.20.0 h1:8W0cWlwFkflGPLltQvLRB7ZVD5HuP6ng320w2IS245Q= +github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= +github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml/v2 v2.0.6 h1:nrzqCb7j9cDFj2coyLNLaZuJTLjWjlaz6nvTvIwycIU= github.com/pelletier/go-toml/v2 v2.0.6/go.mod h1:eumQOmlWiOPt5WriQQqoM5y18pDHwha2N+QD+EUNTek= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5 h1:q2e307iGHPdTGp0hoxKjt1H5pDo6utceo3dQVK3I5XQ= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= +github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= +github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= +github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -343,6 +460,7 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= +github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= @@ -355,6 +473,7 @@ github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6T github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= +github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= @@ -362,6 +481,7 @@ github.com/prometheus/common v0.37.0 h1:ccBbHCgIiT9uSoFY0vX8H3zsNR5eLt17/RQLUvn8 github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= +github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= @@ -372,14 +492,22 @@ github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGn github.com/regen-network/gocuke v0.6.2/go.mod h1:zYaqIHZobHyd0xOrHGPQjbhGJsuZ1oElx150u2o1xuk= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= +github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rogpeppe/go-internal v1.8.1 h1:geMPLpDpQOgVyCg5z5GoRwLHepNdb71NXb67XFkP+Eg= +github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= +github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZKJ48R1S7H23Ji7oFO5Bw= +github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= +github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= +github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= +github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= @@ -427,8 +555,23 @@ github.com/tendermint/tendermint v0.37.0-rc2/go.mod h1:uYQO9DRNPeZROa9X3hJOZpYcV github.com/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= github.com/tendermint/tm-db v0.6.7/go.mod h1:byQDzFkZV1syXr/ReXS808NxA2xvyuuVgXOJ/088L6I= github.com/tidwall/btree v1.5.2 h1:5eA83Gfki799V3d3bJo9sWk+yL2LRoTEah3O/SA6/8w= +github.com/tidwall/btree v1.5.2/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= +github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= +github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= +github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= +github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= +github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= +github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= +github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= +github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= +github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= +github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= +github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= +github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= +github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= +github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -448,13 +591,17 @@ golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnf golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.4.0 h1:UVQgzMY87xqpKNgb+kDsll2Igd33HszWHFLmpaRMq/8= golang.org/x/crypto v0.4.0/go.mod h1:3quD/ATkf6oY+rnes5c3ExXTbLc8mueNue5/DoinL80= +golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= @@ -464,8 +611,10 @@ golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= +golang.org/x/exp v0.0.0-20200513190911-00229845015e/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg= golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= +golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -493,9 +642,11 @@ golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -504,6 +655,7 @@ golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -551,12 +703,14 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -566,6 +720,7 @@ golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -603,6 +758,7 @@ golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210909193231-528a39cd75f3/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -625,12 +781,18 @@ golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -678,6 +840,11 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= +gonum.org/v1/gonum v0.8.2 h1:CCXrcPKiGGotvnN6jfUsKk4rRqm7q09/YbKb5xCEvtM= +gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0= +gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= +gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -704,6 +871,7 @@ google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= +google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= @@ -744,6 +912,7 @@ google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa h1:qQPhfbPO23fwm/9lQr91L1u62Zo6cm+zI+slZT+uf+o= google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -781,11 +950,15 @@ gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLks gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= +gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= +gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -811,6 +984,7 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 pgregory.net/rapid v0.5.3 h1:163N50IHFqr1phZens4FQOdPgfJscR7a562mjQqeo4M= pgregory.net/rapid v0.5.3/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= +rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= From e5d877b92ecfd79ebfb73f13502b8b4cc48192c5 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Feb 2023 16:33:56 +0100 Subject: [PATCH 32/48] make proto-gen --- api/cosmos/consensus/v1/tx.pulsar.go | 77 ++++++---------------------- types/msgservice/validate_test.go | 2 +- x/consensus/types/tx.pb.go | 42 +++------------ 3 files changed, 23 insertions(+), 98 deletions(-) diff --git a/api/cosmos/consensus/v1/tx.pulsar.go b/api/cosmos/consensus/v1/tx.pulsar.go index 6afd49dd3c6..ec2ba1c0bf5 100644 --- a/api/cosmos/consensus/v1/tx.pulsar.go +++ b/api/cosmos/consensus/v1/tx.pulsar.go @@ -1144,52 +1144,6 @@ var file_cosmos_consensus_v1_tx_proto_rawDesc = []byte{ 0x0a, 0x1c, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, 0x2f, 0x74, 0x78, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x13, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, -<<<<<<< HEAD - 0x2e, 0x76, 0x31, 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, 0x17, - 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, - 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1d, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x6d, - 0x69, 0x6e, 0x74, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2f, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x73, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x8d, 0x02, 0x0a, 0x0f, 0x4d, 0x73, 0x67, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x36, 0x0a, 0x09, 0x61, 0x75, - 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x18, 0xd2, - 0xb4, 0x2d, 0x14, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, - 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x52, 0x09, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, - 0x74, 0x79, 0x12, 0x33, 0x0a, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1d, 0x2e, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x74, - 0x79, 0x70, 0x65, 0x73, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, - 0x52, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x3c, 0x0a, 0x08, 0x65, 0x76, 0x69, 0x64, 0x65, - 0x6e, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x74, 0x65, 0x6e, 0x64, - 0x65, 0x72, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x45, 0x76, 0x69, - 0x64, 0x65, 0x6e, 0x63, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x08, 0x65, 0x76, 0x69, - 0x64, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x3f, 0x0a, 0x09, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, - 0x6f, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x74, 0x65, 0x6e, 0x64, 0x65, - 0x72, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x56, 0x61, 0x6c, 0x69, - 0x64, 0x61, 0x74, 0x6f, 0x72, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x09, 0x76, 0x61, 0x6c, - 0x69, 0x64, 0x61, 0x74, 0x6f, 0x72, 0x3a, 0x0e, 0x82, 0xe7, 0xb0, 0x2a, 0x09, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x19, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, - 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x32, 0x70, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x62, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, - 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, - 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x2c, - 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, - 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, - 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, - 0xb0, 0x2a, 0x01, 0x42, 0xc2, 0x01, 0x0a, 0x17, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x42, - 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, - 0x3b, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, - 0x43, 0x58, 0xaa, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, - 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, - 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, - 0x1f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, - 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0xea, 0x02, 0x15, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x43, 0x6f, 0x6e, 0x73, 0x65, - 0x6e, 0x73, 0x75, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -======= 0x2e, 0x76, 0x31, 0x1a, 0x11, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x6d, 0x69, 0x6e, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, @@ -1218,27 +1172,26 @@ var file_cosmos_consensus_v1_tx_proto_rawDesc = []byte{ 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x22, 0x19, 0x0a, 0x17, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x32, - 0x69, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x62, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x70, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x62, 0x0a, 0x0c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x12, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, 0x6d, 0x73, 0x1a, 0x2c, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x61, 0x72, 0x61, - 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x42, 0xc2, 0x01, 0x0a, 0x17, 0x63, - 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, - 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, - 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, - 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, - 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, - 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x43, 0x58, 0xaa, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, - 0x6f, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x56, 0x31, 0xca, - 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, - 0x75, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1f, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, - 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x15, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, - 0x3a, 0x3a, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, ->>>>>>> 96876f8e01af2e8309610233f01cfc85c299f94a + 0x6d, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, 0x05, 0x80, 0xe7, 0xb0, 0x2a, + 0x01, 0x42, 0xc2, 0x01, 0x0a, 0x17, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2e, 0x76, 0x31, 0x42, 0x07, 0x54, + 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x30, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, + 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, + 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x63, + 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x76, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x43, 0x58, + 0xaa, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, + 0x73, 0x75, 0x73, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x13, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, + 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x1f, 0x43, + 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, 0x75, 0x73, 0x5c, + 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, + 0x15, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x43, 0x6f, 0x6e, 0x73, 0x65, 0x6e, 0x73, + 0x75, 0x73, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index b8c9dd17d26..56c300dc078 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -6,7 +6,7 @@ import ( "github.com/stretchr/testify/require" _ "cosmossdk.io/api/cosmos/bank/v1beta1" - _ "github.com/cosmos/cosmos-sdk/testutil/testdata_pulsar" + _ "github.com/cosmos/cosmos-sdk/testutil/testdata/testpb" "github.com/cosmos/cosmos-sdk/types/msgservice" ) diff --git a/x/consensus/types/tx.pb.go b/x/consensus/types/tx.pb.go index fc8b3a06620..48d8732859e 100644 --- a/x/consensus/types/tx.pb.go +++ b/x/consensus/types/tx.pb.go @@ -152,34 +152,7 @@ func init() { func init() { proto.RegisterFile("cosmos/consensus/v1/tx.proto", fileDescriptor_2135c60575ab504d) } var fileDescriptor_2135c60575ab504d = []byte{ -<<<<<<< HEAD - // 378 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x49, 0xce, 0x2f, 0xce, - 0xcd, 0x2f, 0xd6, 0x4f, 0xce, 0xcf, 0x2b, 0x4e,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06, - 0xeb, 0x53, 0xc0, 0xd4, 0xe7, 0x0a, 0x55, 0x01, 0xd5, 0x0a, 0xd7, 0x21, 0x64, 0xcf, 0xc5, 0x59, - 0x96, 0x98, 0x93, 0x99, 0x92, 0x58, 0x92, 0x5f, 0x24, 0xc1, 0x02, 0xd6, 0xae, 0x88, 0xa9, 0x3d, - 0x0c, 0xa6, 0x04, 0xaa, 0x1f, 0xa1, 0xc7, 0x8a, 0xaf, 0xe9, 0xf9, 0x06, 0x2d, 0x84, 0x1f, 0x94, - 0x24, 0xb9, 0xc4, 0xd1, 0x82, 0x23, 0x28, 0xb5, 0xb8, 0x00, 0x14, 0x09, 0x46, 0x05, 0x5c, 0xcc, - 0xbe, 0xc5, 0xe9, 0x42, 0x49, 0x5c, 0x3c, 0x28, 0xa1, 0xa5, 0xa2, 0x87, 0x25, 0xaa, 0xf4, 0xd0, - 0x0c, 0x91, 0xd2, 0x21, 0x46, 0x15, 0xcc, 0x2a, 0x29, 0xd6, 0x86, 0xe7, 0x1b, 0xb4, 0x18, 0x9d, - 0x3c, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, - 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x2f, 0x3d, 0xb3, 0x24, - 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x9e, 0x8e, 0x40, 0x94, 0x6e, 0x71, 0x4a, 0xb6, - 0x7e, 0x05, 0x52, 0xa2, 0x02, 0x87, 0x40, 0x12, 0x1b, 0x38, 0xb6, 0x8d, 0x01, 0x01, 0x00, 0x00, - 0xff, 0xff, 0xf7, 0x5c, 0x67, 0xfe, 0x75, 0x02, 0x00, 0x00, -======= - // 391 bytes of a gzipped FileDescriptorProto + // 399 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x49, 0xce, 0x2f, 0xce, 0xcd, 0x2f, 0xd6, 0x4f, 0xce, 0xcf, 0x2b, 0x4e, 0xcd, 0x2b, 0x2e, 0x2d, 0xd6, 0x2f, 0x33, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x86, 0xc8, 0xea, 0xc1, 0x65, 0xf5, @@ -198,14 +171,13 @@ var fileDescriptor_2135c60575ab504d = []byte{ 0x96, 0xe4, 0x17, 0x49, 0xb0, 0x80, 0xb5, 0x2b, 0x62, 0x6a, 0x0f, 0x83, 0x29, 0x81, 0xea, 0x47, 0xe8, 0xb1, 0xb2, 0x6c, 0x7a, 0xbe, 0x41, 0x0b, 0xe1, 0x87, 0xae, 0xe7, 0x1b, 0xb4, 0xd4, 0x20, 0xfe, 0xd4, 0x2d, 0x4e, 0xc9, 0xd6, 0xaf, 0x40, 0x8a, 0x31, 0xb4, 0x60, 0x52, 0x92, 0xe4, 0x12, - 0x47, 0x13, 0x0a, 0x4a, 0x2d, 0x2e, 0x00, 0x29, 0x37, 0xca, 0xe4, 0x62, 0xf6, 0x2d, 0x4e, 0x17, + 0x47, 0x13, 0x0a, 0x4a, 0x2d, 0x2e, 0x00, 0x29, 0x37, 0x2a, 0xe0, 0x62, 0xf6, 0x2d, 0x4e, 0x17, 0x4a, 0xe2, 0xe2, 0x41, 0x09, 0x58, 0x15, 0x3d, 0x2c, 0x11, 0xad, 0x87, 0x66, 0x88, 0x94, 0x0e, - 0x31, 0xaa, 0x60, 0x56, 0x39, 0x79, 0x9c, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, - 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, - 0x94, 0x5e, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x3e, 0x3c, 0xf9, 0x61, - 0xf5, 0x19, 0x38, 0x94, 0x92, 0xd8, 0xc0, 0x29, 0xc2, 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0xbd, - 0x91, 0xef, 0x75, 0xac, 0x02, 0x00, 0x00, ->>>>>>> 96876f8e01af2e8309610233f01cfc85c299f94a + 0x31, 0xaa, 0x60, 0x56, 0x49, 0xb1, 0x36, 0x3c, 0xdf, 0xa0, 0xc5, 0xe8, 0xe4, 0x71, 0xe2, 0x91, + 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, + 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0x7a, 0xe9, 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, + 0xc9, 0xf9, 0xb9, 0xfa, 0xf0, 0x54, 0x88, 0xd5, 0x83, 0xe0, 0xc0, 0x4a, 0x62, 0x03, 0x27, 0x0c, + 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x79, 0x2c, 0x44, 0x5c, 0xb3, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. From a229a648c23ad1dff1caab2fafa2d1d93f61512d Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Feb 2023 16:35:01 +0100 Subject: [PATCH 33/48] Use merged registry --- baseapp/msg_service_router.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 158037d6b3c..3341fe3b1e9 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -11,7 +11,6 @@ import ( errorsmod "cosmossdk.io/errors" codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/server/grpc/gogoreflection" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/types/msgservice" @@ -61,7 +60,7 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - protoFiles, err := gogoreflection.GetProtodescResolver() + protoFiles, err := proto.MergedRegistry() if err != nil { panic(err) } From 767c236d858ccc81069b999ed24babdd979c0988 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Feb 2023 16:43:54 +0100 Subject: [PATCH 34/48] Use os.StdErr --- baseapp/msg_service_router.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 3341fe3b1e9..1d47f972990 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -3,6 +3,7 @@ package baseapp import ( "context" "fmt" + "os" gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" @@ -69,7 +70,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter err = msgservice.ValidateServiceAnnotations(protoFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. - fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %s\n", err) + fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) } // Adds a top-level query handler based on the gRPC service name. @@ -95,7 +96,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter err := msgservice.ValidateMsgAnnotations(protoFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. - fmt.Printf("The SDK is requiring protobuf annotation on Msgs; %s\n", err) + fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) } requestTypeName = sdk.MsgTypeURL(msg) From 69a6ed4b5038d17be501c3b06e8b8d29dc0216ef Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 8 Mar 2023 15:59:53 +0100 Subject: [PATCH 35/48] Use MergedRegistry --- baseapp/msg_service_router.go | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 1d47f972990..6bbf91bae10 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -8,6 +8,7 @@ import ( gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" "google.golang.org/grpc" + "google.golang.org/protobuf/reflect/protoregistry" errorsmod "cosmossdk.io/errors" @@ -26,6 +27,7 @@ type MessageRouter interface { // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { + protoFiles *protoregistry.Files interfaceRegistry codectypes.InterfaceRegistry routes map[string]MsgServiceHandler } @@ -34,8 +36,14 @@ var _ gogogrpc.Server = &MsgServiceRouter{} // NewMsgServiceRouter creates a new MsgServiceRouter. func NewMsgServiceRouter() *MsgServiceRouter { + protoFiles, err := proto.MergedRegistry() + if err != nil { + panic(err) + } + return &MsgServiceRouter{ - routes: map[string]MsgServiceHandler{}, + protoFiles: protoFiles, + routes: map[string]MsgServiceHandler{}, } } @@ -61,13 +69,8 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - protoFiles, err := proto.MergedRegistry() - if err != nil { - panic(err) - } - // Make sure the Msg services has the `cosmos.msg.service` proto annotation. - err = msgservice.ValidateServiceAnnotations(protoFiles, sd.ServiceName) + err := msgservice.ValidateServiceAnnotations(msr.protoFiles, sd.ServiceName) if err != nil { // We might panic here in the future, instead of simply logging. fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) @@ -93,7 +96,7 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter } // Make sure Msg annotations are correct, like the `cosmos.msg.signer` one. - err := msgservice.ValidateMsgAnnotations(protoFiles, proto.MessageName(msg)) + err := msgservice.ValidateMsgAnnotations(msr.protoFiles, proto.MessageName(msg)) if err != nil { // We might panic here in the future, instead of logging. fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) From b8e7beee5fa3e76a85f23b7a97ae76404354ad3f Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 8 Mar 2023 17:35:08 +0100 Subject: [PATCH 36/48] Use standalone validation --- baseapp/msg_service_router.go | 16 ---- go.mod | 3 + go.sum | 2 - runtime/app.go | 12 +++ simapp/app_test.go | 8 ++ simapp/go.mod | 1 + simapp/go.sum | 2 - testutil/testdata/testpb/tx.proto | 6 ++ testutil/testdata/testpb/tx.pulsar.go | 129 ++++++++++++++++++++------ testutil/testdata/tx.pb.go | 87 +++++++++++++---- types/msgservice/validate.go | 85 ++++++++++------- types/msgservice/validate_test.go | 30 +++--- 12 files changed, 274 insertions(+), 107 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index 6bbf91bae10..a218034c5e2 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -3,7 +3,6 @@ package baseapp import ( "context" "fmt" - "os" gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" @@ -15,7 +14,6 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/types/msgservice" ) // MessageRouter ADR 031 request type routing @@ -69,13 +67,6 @@ func (msr *MsgServiceRouter) HandlerByTypeURL(typeURL string) MsgServiceHandler // RegisterInterfaces, // - or if a service is being registered twice. func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler interface{}) { - // Make sure the Msg services has the `cosmos.msg.service` proto annotation. - err := msgservice.ValidateServiceAnnotations(msr.protoFiles, sd.ServiceName) - if err != nil { - // We might panic here in the future, instead of simply logging. - fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) - } - // Adds a top-level query handler based on the gRPC service name. for _, method := range sd.Methods { fqMethod := fmt.Sprintf("/%s/%s", sd.ServiceName, method.MethodName) @@ -95,13 +86,6 @@ func (msr *MsgServiceRouter) RegisterService(sd *grpc.ServiceDesc, handler inter panic(fmt.Errorf("unable to register service method %s: %T does not implement sdk.Msg", fqMethod, i)) } - // Make sure Msg annotations are correct, like the `cosmos.msg.signer` one. - err := msgservice.ValidateMsgAnnotations(msr.protoFiles, proto.MessageName(msg)) - if err != nil { - // We might panic here in the future, instead of logging. - fmt.Fprintf(os.Stderr, "The SDK is requiring protobuf annotation on Msgs; %s\n", err) - } - requestTypeName = sdk.MsgTypeURL(msg) return nil }, noopInterceptor) diff --git a/go.mod b/go.mod index 44067b9ee33..31f157ddee1 100644 --- a/go.mod +++ b/go.mod @@ -154,6 +154,9 @@ require ( nhooyr.io/websocket v1.8.6 // indirect ) +// Here are the short-lived replace for the Cosmos SDK +replace cosmossdk.io/api => ./api + // Below are the long-lived replace of the Cosmos SDK replace ( // use cosmos fork of keyring diff --git a/go.sum b/go.sum index 218a0243fd7..385f2e960f5 100644 --- a/go.sum +++ b/go.sum @@ -35,8 +35,6 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= cosmossdk.io/collections v0.0.0-20230214153846-b6c6e4e99177 h1:At2M0aYQKEAWqr6JtZrJPOlfhdvENiGwJg2NCNHwIdc= cosmossdk.io/collections v0.0.0-20230214153846-b6c6e4e99177/go.mod h1:uqCi8FG+Bh2vv/qf5xZ8iab0E0c/DMA/cwafbp8dkcU= cosmossdk.io/core v0.6.0 h1:V2zyaMVFN6hJSVENYx2XE9CMhzqwJPMjzSQpj0MyXAU= diff --git a/runtime/app.go b/runtime/app.go index 7388ec9faa2..3da3ea3c6be 100644 --- a/runtime/app.go +++ b/runtime/app.go @@ -23,7 +23,9 @@ import ( servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/types/msgservice" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" + "github.com/cosmos/gogoproto/proto" ) // App is a wrapper around BaseApp and ModuleManager that can be used in hybrid @@ -112,6 +114,16 @@ func (a *App) Load(loadLatest bool) error { } } + // At startup, check that all proto annotations are correct. + protoFiles, err := proto.MergedRegistry() + if err != nil { + return err + } + err = msgservice.ValidateProtoAnnotations(protoFiles) + if err != nil { + panic(err) + } + return nil } diff --git a/simapp/app_test.go b/simapp/app_test.go index a29c38c81cb..4c0e438aa32 100644 --- a/simapp/app_test.go +++ b/simapp/app_test.go @@ -22,6 +22,7 @@ import ( simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/types/msgservice" "github.com/cosmos/cosmos-sdk/x/auth" "github.com/cosmos/cosmos-sdk/x/auth/vesting" authzmodule "github.com/cosmos/cosmos-sdk/x/authz/module" @@ -282,3 +283,10 @@ func TestMergedRegistry(t *testing.T) { require.NoError(t, err) require.Greater(t, r.NumFiles(), 0) } + +func TestProtoAnnotations(t *testing.T) { + r, err := proto.MergedRegistry() + require.NoError(t, err) + err = msgservice.ValidateProtoAnnotations(r) + require.NoError(t, err) +} diff --git a/simapp/go.mod b/simapp/go.mod index febf642ffc5..72c6b9e42fc 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -191,6 +191,7 @@ require ( // Replace here are pending PRs, or version to be tagged replace ( // TODO tag all extracted modules after SDK refactor + cosmossdk.io/api => ../api cosmossdk.io/tools/confix => ../tools/confix cosmossdk.io/tools/rosetta => ../tools/rosetta cosmossdk.io/x/evidence => ../x/evidence diff --git a/simapp/go.sum b/simapp/go.sum index 69f00a56a9e..cd90433e0f4 100644 --- a/simapp/go.sum +++ b/simapp/go.sum @@ -188,8 +188,6 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= cosmossdk.io/client/v2 v2.0.0-20230220152935-67f04e629623 h1:QzZA1P+twvj10ylCVXzHodLge+RvrwoNIlWpU+MrRa0= cosmossdk.io/client/v2 v2.0.0-20230220152935-67f04e629623/go.mod h1:Yo6R3XSXKxi+G642kK7+ZOh2czNTwTO1b8ywOvwaFQo= cosmossdk.io/collections v0.0.0-20230214153846-b6c6e4e99177 h1:At2M0aYQKEAWqr6JtZrJPOlfhdvENiGwJg2NCNHwIdc= diff --git a/testutil/testdata/testpb/tx.proto b/testutil/testdata/testpb/tx.proto index 2e570569454..464e3390478 100644 --- a/testutil/testdata/testpb/tx.proto +++ b/testutil/testdata/testpb/tx.proto @@ -3,17 +3,23 @@ package testpb; import "gogoproto/gogo.proto"; import "testpb/testdata.proto"; +import "cosmos/msg/v1/msg.proto"; option go_package = "github.com/cosmos/cosmos-sdk/testutil/testdata"; // Msg tests the Protobuf message service as defined in // https://github.com/cosmos/cosmos-sdk/issues/7500. service Msg { + option (cosmos.msg.v1.service) = true; + rpc CreateDog(MsgCreateDog) returns (MsgCreateDogResponse); } message MsgCreateDog { + option (cosmos.msg.v1.signer) = "owner"; + testpb.Dog dog = 1; + string owner = 2; } message MsgCreateDogResponse { diff --git a/testutil/testdata/testpb/tx.pulsar.go b/testutil/testdata/testpb/tx.pulsar.go index e423bb60004..b0d65307662 100644 --- a/testutil/testdata/testpb/tx.pulsar.go +++ b/testutil/testdata/testpb/tx.pulsar.go @@ -2,6 +2,7 @@ package testpb import ( + _ "cosmossdk.io/api/cosmos/msg/v1" fmt "fmt" runtime "github.com/cosmos/cosmos-proto/runtime" _ "github.com/cosmos/gogoproto/gogoproto" @@ -14,14 +15,16 @@ import ( ) var ( - md_MsgCreateDog protoreflect.MessageDescriptor - fd_MsgCreateDog_dog protoreflect.FieldDescriptor + md_MsgCreateDog protoreflect.MessageDescriptor + fd_MsgCreateDog_dog protoreflect.FieldDescriptor + fd_MsgCreateDog_owner protoreflect.FieldDescriptor ) func init() { file_testpb_tx_proto_init() md_MsgCreateDog = File_testpb_tx_proto.Messages().ByName("MsgCreateDog") fd_MsgCreateDog_dog = md_MsgCreateDog.Fields().ByName("dog") + fd_MsgCreateDog_owner = md_MsgCreateDog.Fields().ByName("owner") } var _ protoreflect.Message = (*fastReflection_MsgCreateDog)(nil) @@ -95,6 +98,12 @@ func (x *fastReflection_MsgCreateDog) Range(f func(protoreflect.FieldDescriptor, return } } + if x.Owner != "" { + value := protoreflect.ValueOfString(x.Owner) + if !f(fd_MsgCreateDog_owner, value) { + return + } + } } // Has reports whether a field is populated. @@ -112,6 +121,8 @@ func (x *fastReflection_MsgCreateDog) Has(fd protoreflect.FieldDescriptor) bool switch fd.FullName() { case "testpb.MsgCreateDog.dog": return x.Dog != nil + case "testpb.MsgCreateDog.owner": + return x.Owner != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -130,6 +141,8 @@ func (x *fastReflection_MsgCreateDog) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "testpb.MsgCreateDog.dog": x.Dog = nil + case "testpb.MsgCreateDog.owner": + x.Owner = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -149,6 +162,9 @@ func (x *fastReflection_MsgCreateDog) Get(descriptor protoreflect.FieldDescripto case "testpb.MsgCreateDog.dog": value := x.Dog return protoreflect.ValueOfMessage(value.ProtoReflect()) + case "testpb.MsgCreateDog.owner": + value := x.Owner + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -171,6 +187,8 @@ func (x *fastReflection_MsgCreateDog) Set(fd protoreflect.FieldDescriptor, value switch fd.FullName() { case "testpb.MsgCreateDog.dog": x.Dog = value.Message().Interface().(*Dog) + case "testpb.MsgCreateDog.owner": + x.Owner = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -196,6 +214,8 @@ func (x *fastReflection_MsgCreateDog) Mutable(fd protoreflect.FieldDescriptor) p x.Dog = new(Dog) } return protoreflect.ValueOfMessage(x.Dog.ProtoReflect()) + case "testpb.MsgCreateDog.owner": + panic(fmt.Errorf("field owner of message testpb.MsgCreateDog is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -212,6 +232,8 @@ func (x *fastReflection_MsgCreateDog) NewField(fd protoreflect.FieldDescriptor) case "testpb.MsgCreateDog.dog": m := new(Dog) return protoreflect.ValueOfMessage(m.ProtoReflect()) + case "testpb.MsgCreateDog.owner": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: testpb.MsgCreateDog")) @@ -285,6 +307,10 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { l = options.Size(x.Dog) n += 1 + l + runtime.Sov(uint64(l)) } + l = len(x.Owner) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -314,6 +340,13 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.Owner) > 0 { + i -= len(x.Owner) + copy(dAtA[i:], x.Owner) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.Owner))) + i-- + dAtA[i] = 0x12 + } if x.Dog != nil { encoded, err := options.Marshal(x.Dog) if err != nil { @@ -413,6 +446,38 @@ func (x *fastReflection_MsgCreateDog) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 2: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field Owner", 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.Owner = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -1366,7 +1431,8 @@ type MsgCreateDog struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Owner string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"` } func (x *MsgCreateDog) Reset() { @@ -1396,6 +1462,13 @@ func (x *MsgCreateDog) GetDog() *Dog { return nil } +func (x *MsgCreateDog) GetOwner() string { + if x != nil { + return x.Owner + } + return "" +} + type MsgCreateDogResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -1475,29 +1548,33 @@ var file_testpb_tx_proto_rawDesc = []byte{ 0x6f, 0x12, 0x06, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x1a, 0x14, 0x67, 0x6f, 0x67, 0x6f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x67, 0x6f, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x15, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x2d, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x1d, 0x0a, 0x03, 0x64, 0x6f, 0x67, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x2e, 0x44, 0x6f, 0x67, - 0x52, 0x03, 0x64, 0x6f, 0x67, 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, - 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x22, 0x29, 0x0a, 0x07, 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, - 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, - 0x69, 0x67, 0x6e, 0x65, 0x72, 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x32, 0x46, 0x0a, 0x03, - 0x4d, 0x73, 0x67, 0x12, 0x3f, 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, - 0x12, 0x14, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, - 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x1a, 0x1c, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x2e, - 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x42, 0x8b, 0x01, 0x0a, 0x0a, 0x63, 0x6f, 0x6d, 0x2e, 0x74, 0x65, 0x73, - 0x74, 0x70, 0x62, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x3c, - 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, 0x74, 0x65, 0x73, - 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x70, - 0x75, 0x6c, 0x73, 0x61, 0x72, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0xa2, 0x02, 0x03, 0x54, - 0x58, 0x58, 0xaa, 0x02, 0x06, 0x54, 0x65, 0x73, 0x74, 0x70, 0x62, 0xca, 0x02, 0x06, 0x54, 0x65, - 0x73, 0x74, 0x70, 0x62, 0xe2, 0x02, 0x12, 0x54, 0x65, 0x73, 0x74, 0x70, 0x62, 0x5c, 0x47, 0x50, - 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, 0x54, 0x65, 0x73, 0x74, - 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x17, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x6d, + 0x73, 0x67, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, + 0x4f, 0x0a, 0x0c, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, + 0x1d, 0x0a, 0x03, 0x64, 0x6f, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x74, + 0x65, 0x73, 0x74, 0x70, 0x62, 0x2e, 0x44, 0x6f, 0x67, 0x52, 0x03, 0x64, 0x6f, 0x67, 0x12, 0x14, + 0x0a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x6f, + 0x77, 0x6e, 0x65, 0x72, 0x3a, 0x0a, 0x82, 0xe7, 0xb0, 0x2a, 0x05, 0x6f, 0x77, 0x6e, 0x65, 0x72, + 0x22, 0x2a, 0x0a, 0x14, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x29, 0x0a, 0x07, + 0x54, 0x65, 0x73, 0x74, 0x4d, 0x73, 0x67, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, + 0x72, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x69, 0x67, 0x6e, 0x65, 0x72, + 0x73, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x32, 0x4d, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x12, 0x3f, + 0x0a, 0x09, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x12, 0x14, 0x2e, 0x74, 0x65, + 0x73, 0x74, 0x70, 0x62, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, + 0x67, 0x1a, 0x1c, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0x2e, 0x4d, 0x73, 0x67, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x44, 0x6f, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x1a, + 0x05, 0x80, 0xe7, 0xb0, 0x2a, 0x01, 0x42, 0x8b, 0x01, 0x0a, 0x0a, 0x63, 0x6f, 0x6d, 0x2e, 0x74, + 0x65, 0x73, 0x74, 0x70, 0x62, 0x42, 0x07, 0x54, 0x78, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, + 0x5a, 0x3c, 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, 0x74, + 0x65, 0x73, 0x74, 0x75, 0x74, 0x69, 0x6c, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x64, 0x61, 0x74, 0x61, + 0x5f, 0x70, 0x75, 0x6c, 0x73, 0x61, 0x72, 0x2f, 0x74, 0x65, 0x73, 0x74, 0x70, 0x62, 0xa2, 0x02, + 0x03, 0x54, 0x58, 0x58, 0xaa, 0x02, 0x06, 0x54, 0x65, 0x73, 0x74, 0x70, 0x62, 0xca, 0x02, 0x06, + 0x54, 0x65, 0x73, 0x74, 0x70, 0x62, 0xe2, 0x02, 0x12, 0x54, 0x65, 0x73, 0x74, 0x70, 0x62, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x06, 0x54, 0x65, + 0x73, 0x74, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/testutil/testdata/tx.pb.go b/testutil/testdata/tx.pb.go index 9f7abdf9b75..b12e6fa2eb3 100644 --- a/testutil/testdata/tx.pb.go +++ b/testutil/testdata/tx.pb.go @@ -6,6 +6,7 @@ package testdata import ( context "context" fmt "fmt" + _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -29,7 +30,8 @@ var _ = math.Inf const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCreateDog struct { - Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Dog *Dog `protobuf:"bytes,1,opt,name=dog,proto3" json:"dog,omitempty"` + Owner string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"` } func (m *MsgCreateDog) Reset() { *m = MsgCreateDog{} } @@ -72,6 +74,13 @@ func (m *MsgCreateDog) GetDog() *Dog { return nil } +func (m *MsgCreateDog) GetOwner() string { + if m != nil { + return m.Owner + } + return "" +} + type MsgCreateDogResponse struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` } @@ -164,24 +173,27 @@ func init() { func init() { proto.RegisterFile("testpb/tx.proto", fileDescriptor_1c54006dba274b2e) } var fileDescriptor_1c54006dba274b2e = []byte{ - // 265 bytes of a gzipped FileDescriptorProto + // 313 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x2f, 0x49, 0x2d, 0x2e, 0x29, 0x48, 0xd2, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x83, 0x08, 0x48, 0x89, 0xa4, 0xe7, 0xa7, 0xe7, 0x83, 0x85, 0xf4, 0x41, 0x2c, 0x88, 0xac, 0x94, 0x28, 0x4c, 0x79, - 0x6a, 0x71, 0x49, 0x4a, 0x62, 0x49, 0x22, 0x44, 0x58, 0x49, 0x97, 0x8b, 0xc7, 0xb7, 0x38, 0xdd, - 0xb9, 0x28, 0x35, 0xb1, 0x24, 0xd5, 0x25, 0x3f, 0x5d, 0x48, 0x96, 0x8b, 0x39, 0x25, 0x3f, 0x5d, - 0x82, 0x51, 0x81, 0x51, 0x83, 0xdb, 0x88, 0x5b, 0x0f, 0xa2, 0x49, 0xcf, 0x25, 0x3f, 0x3d, 0x08, - 0x24, 0xae, 0xa4, 0xc5, 0x25, 0x82, 0xac, 0x3c, 0x28, 0xb5, 0xb8, 0x20, 0x3f, 0xaf, 0x38, 0x55, - 0x48, 0x88, 0x8b, 0x25, 0x2f, 0x31, 0x37, 0x15, 0xac, 0x8f, 0x33, 0x08, 0xcc, 0x56, 0xd2, 0xe4, - 0x62, 0x0f, 0x49, 0x2d, 0x2e, 0xf1, 0x2d, 0x4e, 0x17, 0x92, 0xe0, 0x62, 0x2f, 0xce, 0x4c, 0xcf, - 0x4b, 0x2d, 0x2a, 0x96, 0x60, 0x54, 0x60, 0xd6, 0xe0, 0x0c, 0x82, 0x71, 0xad, 0x58, 0x3a, 0x16, - 0xc8, 0x33, 0x18, 0xb9, 0x71, 0x31, 0x83, 0x94, 0xd9, 0x73, 0x71, 0x22, 0x5c, 0x22, 0x02, 0xb3, - 0x1c, 0xd9, 0x42, 0x29, 0x19, 0x6c, 0xa2, 0x30, 0x67, 0x38, 0x79, 0x9c, 0x78, 0x24, 0xc7, 0x78, - 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, - 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x5e, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, - 0xae, 0x7e, 0x72, 0x7e, 0x71, 0x6e, 0x7e, 0x31, 0x94, 0xd2, 0x2d, 0x4e, 0xc9, 0x06, 0x07, 0x4a, - 0x69, 0x49, 0x66, 0x0e, 0x3c, 0x74, 0x92, 0xd8, 0xc0, 0xc1, 0x63, 0x0c, 0x08, 0x00, 0x00, 0xff, - 0xff, 0xd5, 0x7f, 0x29, 0x59, 0x66, 0x01, 0x00, 0x00, + 0x6a, 0x71, 0x49, 0x4a, 0x62, 0x49, 0x22, 0x54, 0x58, 0x3c, 0x39, 0xbf, 0x38, 0x37, 0xbf, 0x58, + 0x3f, 0xb7, 0x38, 0x5d, 0xbf, 0xcc, 0x10, 0x44, 0x41, 0x24, 0x94, 0xfc, 0xb9, 0x78, 0x7c, 0x8b, + 0xd3, 0x9d, 0x8b, 0x52, 0x13, 0x4b, 0x52, 0x5d, 0xf2, 0xd3, 0x85, 0x64, 0xb9, 0x98, 0x53, 0xf2, + 0xd3, 0x25, 0x18, 0x15, 0x18, 0x35, 0xb8, 0x8d, 0xb8, 0xf5, 0x20, 0xa6, 0xe9, 0xb9, 0xe4, 0xa7, + 0x07, 0x81, 0xc4, 0x85, 0x44, 0xb8, 0x58, 0xf3, 0xcb, 0xf3, 0x52, 0x8b, 0x24, 0x98, 0x14, 0x18, + 0x35, 0x38, 0x83, 0x20, 0x1c, 0x2b, 0xae, 0xa6, 0xe7, 0x1b, 0xb4, 0x20, 0x6c, 0x25, 0x2d, 0x2e, + 0x11, 0x64, 0x03, 0x83, 0x52, 0x8b, 0x0b, 0xf2, 0xf3, 0x8a, 0x53, 0x85, 0x84, 0xb8, 0x58, 0xf2, + 0x12, 0x73, 0x53, 0xc1, 0x26, 0x73, 0x06, 0x81, 0xd9, 0x4a, 0x9a, 0x5c, 0xec, 0x21, 0xa9, 0xc5, + 0x25, 0xbe, 0xc5, 0xe9, 0x42, 0x12, 0x5c, 0xec, 0xc5, 0x99, 0xe9, 0x79, 0xa9, 0x45, 0xc5, 0x12, + 0x8c, 0x0a, 0xcc, 0x1a, 0x9c, 0x41, 0x30, 0xae, 0x15, 0x4b, 0xc7, 0x02, 0x79, 0x06, 0x23, 0x5f, + 0x2e, 0x66, 0x90, 0x32, 0x7b, 0x2e, 0x4e, 0x84, 0x5b, 0x45, 0x60, 0xce, 0x43, 0xb6, 0x50, 0x4a, + 0x06, 0x9b, 0x28, 0xcc, 0x19, 0x52, 0xac, 0x0d, 0xcf, 0x37, 0x68, 0x31, 0x3a, 0x79, 0x9c, 0x78, + 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, + 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x5e, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, + 0x5e, 0x72, 0x7e, 0xae, 0x3e, 0x34, 0xd0, 0x20, 0x94, 0x6e, 0x71, 0x4a, 0x36, 0x38, 0x58, 0x4b, + 0x4b, 0x32, 0x73, 0xe0, 0xe1, 0x9b, 0xc4, 0x06, 0x0e, 0x47, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x0a, 0x96, 0x8c, 0x83, 0xa8, 0x01, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -284,6 +296,13 @@ func (m *MsgCreateDog) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.Owner) > 0 { + i -= len(m.Owner) + copy(dAtA[i:], m.Owner) + i = encodeVarintTx(dAtA, i, uint64(len(m.Owner))) + i-- + dAtA[i] = 0x12 + } if m.Dog != nil { { size, err := m.Dog.MarshalToSizedBuffer(dAtA[:i]) @@ -382,6 +401,10 @@ func (m *MsgCreateDog) Size() (n int) { l = m.Dog.Size() n += 1 + l + sovTx(uint64(l)) } + l = len(m.Owner) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } return n } @@ -484,6 +507,38 @@ func (m *MsgCreateDog) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Owner", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Owner = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index f091b869d7b..08858bddfa9 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -1,31 +1,62 @@ package msgservice import ( + "errors" "fmt" "google.golang.org/protobuf/proto" - "google.golang.org/protobuf/reflect/protodesc" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" msg "cosmossdk.io/api/cosmos/msg/v1" - "cosmossdk.io/errors" ) -// ValidateServiceAnnotations validates that all Msg services have the -// `(cosmos.msg.v1.service) = true` proto annotation. +// ValidateAnnotations validates that the proto annotations are correct. +// More specifically, it verifies: +// - all services named "Msg" have `(cosmos.msg.v1.service) = true`, +// - all sdk.Msgs have correct `(cosmos.msg.v1.signer) = "..."`. +// +// More validations can be added here in the future. // -// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. -func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName string) error { - if fileResolver == nil { - fileResolver = protoregistry.GlobalFiles +// If `protoFiles` is nil, then protoregistry.GlobalFile will be used. +func ValidateProtoAnnotations(protoFiles *protoregistry.Files) error { + if protoFiles == nil { + protoFiles = protoregistry.GlobalFiles } - sd, err := fileResolver.FindDescriptorByName(protoreflect.FullName(serviceName)) - if err != nil { - return errors.Wrapf(err, "error while validating service annotations for %s", serviceName) - } + var ( + serviceErrs []error + messageErrs []error + ) + protoFiles.RangeFiles(func(fd protoreflect.FileDescriptor) bool { + for i := 0; i < fd.Services().Len(); i++ { + sd := fd.Services().Get(i) + if sd.Name() == "Msg" { + // We use the heuristic that services name Msg are exactly the + // ones that need the proto annotations check. + err := validateMsgServiceAnnotations(protoFiles, sd) + if err != nil { + serviceErrs = append(serviceErrs, err) + } + + for j := 0; j < sd.Methods().Len(); j++ { + err := validateMsgAnnotations(protoFiles, sd.Methods().Get(j).Input()) + if err != nil { + messageErrs = append(messageErrs, err) + } + } + } + } + + return true + }) + + return errors.Join(errors.Join(serviceErrs...), errors.Join(messageErrs...)) +} +// validateMsgServiceAnnotations validates that the service has the +// `(cosmos.msg.v1.service) = true` proto annotation. +func validateMsgServiceAnnotations(protoFiles *protoregistry.Files, sd protoreflect.ServiceDescriptor) error { ext := proto.GetExtension(sd.Options(), msg.E_Service) isService, ok := ext.(bool) if !ok { @@ -33,46 +64,34 @@ func ValidateServiceAnnotations(fileResolver protodesc.Resolver, serviceName str } if !isService { - return fmt.Errorf("service %s does not have cosmos.msg.v1.service proto annotation", serviceName) + return fmt.Errorf("service %s does not have cosmos.msg.v1.service proto annotation", sd.FullName()) } return nil } -// ValidateMsgAnnotations validates that all sdk.Msg services have the correct +// validateMsgAnnotations validates the sdk.Msg service has the correct // `(cosmos.msg.v1.signer) = "..."` proto annotation. -// -// If `fileResolver` is nil, then protoregistry.GlobalFile will be used. -func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) error { - if fileResolver == nil { - fileResolver = protoregistry.GlobalFiles - } - - d, err := fileResolver.FindDescriptorByName(protoreflect.FullName(fqName)) - if err != nil { - return errors.Wrapf(err, "error while validating msg annotations for %s", fqName) - } - md := d.(protoreflect.MessageDescriptor) - +func validateMsgAnnotations(protoFiles *protoregistry.Files, md protoreflect.MessageDescriptor) error { ext := proto.GetExtension(md.Options(), msg.E_Signer) signers, ok := ext.([]string) if !ok { - return fmt.Errorf("expected bool, got %T", ext) + return fmt.Errorf("expected []string, got %T", ext) } if len(signers) == 0 { - return fmt.Errorf("sdk.Msg %s does not have cosmos.msg.v1.signer proto annotation", fqName) + return fmt.Errorf("sdk.Msg %s does not have cosmos.msg.v1.signer proto annotation", md.FullName()) } for i, signer := range signers { if signer == "" { - return fmt.Errorf("sdk.Msg %s signer at index %d is empty", fqName, i) + return fmt.Errorf("sdk.Msg %s signer at index %d is empty", md.FullName(), i) } // Make sure the signer annotation is a correct field of type string fd := md.Fields().ByName(protoreflect.Name(signer)) if fd == nil { - return fmt.Errorf("sdk.Msg %s has incorrect signer %s", fqName, signer) + return fmt.Errorf("sdk.Msg %s has incorrect signer %s", md.FullName(), signer) } // The signer annotation should point to: @@ -82,14 +101,14 @@ func ValidateMsgAnnotations(fileResolver protodesc.Resolver, fqName string) erro case protoreflect.StringKind: continue case protoreflect.MessageKind: - err := ValidateMsgAnnotations(fileResolver, string(fd.Message().FullName())) + err := validateMsgAnnotations(protoFiles, fd.Message()) if err != nil { return err } continue default: - return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string or message, got %s", fqName, signer, fd.Kind()) + return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string or message, got %s", md.FullName(), signer, fd.Kind()) } } diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index 56c300dc078..b9b505ca6e8 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -1,39 +1,45 @@ -package msgservice_test +package msgservice import ( "testing" "github.com/stretchr/testify/require" + "google.golang.org/protobuf/proto" + "google.golang.org/protobuf/reflect/protoreflect" + "google.golang.org/protobuf/reflect/protoregistry" - _ "cosmossdk.io/api/cosmos/bank/v1beta1" - _ "github.com/cosmos/cosmos-sdk/testutil/testdata/testpb" - "github.com/cosmos/cosmos-sdk/types/msgservice" + bankv1beta1 "cosmossdk.io/api/cosmos/bank/v1beta1" + "github.com/cosmos/cosmos-sdk/testutil/testdata/testpb" ) func TestValidateServiceAnnotations(t *testing.T) { - // We didn't add the `msg.service = true` annotation on testdata's Msg. - err := msgservice.ValidateServiceAnnotations(nil, "testdata.Msg") + // Find an arbitrary query service that hasn't the service=true annotation. + sd, err := protoregistry.GlobalFiles.FindDescriptorByName("cosmos.bank.v1beta1.Query") + require.NoError(t, err) + err = validateMsgServiceAnnotations(nil, sd.(protoreflect.ServiceDescriptor)) require.Error(t, err) - err = msgservice.ValidateServiceAnnotations(nil, "cosmos.bank.v1beta1.Msg") + sd, err = protoregistry.GlobalFiles.FindDescriptorByName("cosmos.bank.v1beta1.Msg") + require.NoError(t, err) + err = validateMsgServiceAnnotations(nil, sd.(protoreflect.ServiceDescriptor)) require.NoError(t, err) } func TestValidateMsgAnnotations(t *testing.T) { testcases := []struct { name string - typeURL string + message proto.Message expErr bool }{ - {"no signer annotation", "testdata.MsgCreateDog", true}, - {"valid signer", "cosmos.bank.v1beta1.MsgSend", false}, - {"valid signer as message", "cosmos.bank.v1beta1.MsgMultiSend", false}, + {"no signer annotation", &testpb.Dog{}, true}, + {"valid signer", &bankv1beta1.MsgSend{}, false}, + {"valid signer as message", &bankv1beta1.MsgMultiSend{}, false}, } for _, tc := range testcases { tc := tc t.Run(tc.name, func(t *testing.T) { - err := msgservice.ValidateMsgAnnotations(nil, tc.typeURL) + err := validateMsgAnnotations(nil, tc.message.ProtoReflect().Descriptor()) if tc.expErr { require.Error(t, err) } else { From d226a51bdfaa0d7c12991fd10b42f9a2bd5d4da2 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 8 Mar 2023 17:37:16 +0100 Subject: [PATCH 37/48] Log instead of panic --- runtime/app.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/runtime/app.go b/runtime/app.go index 3da3ea3c6be..42dcd7783b0 100644 --- a/runtime/app.go +++ b/runtime/app.go @@ -3,6 +3,7 @@ package runtime import ( "encoding/json" "fmt" + "os" abci "github.com/cometbft/cometbft/abci/types" "golang.org/x/exp/slices" @@ -121,7 +122,9 @@ func (a *App) Load(loadLatest bool) error { } err = msgservice.ValidateProtoAnnotations(protoFiles) if err != nil { - panic(err) + // Once we switch to using protoreflect-based antehandlers, we might + // want to panic here instead of logging a warning. + fmt.Fprintln(os.Stderr, err.Error()) } return nil From aa62be7af3cc38cab00fa9004583945bea3311de Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Wed, 8 Mar 2023 17:38:05 +0100 Subject: [PATCH 38/48] revert --- baseapp/msg_service_router.go | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/baseapp/msg_service_router.go b/baseapp/msg_service_router.go index a218034c5e2..ed08986d47e 100644 --- a/baseapp/msg_service_router.go +++ b/baseapp/msg_service_router.go @@ -7,7 +7,6 @@ import ( gogogrpc "github.com/cosmos/gogoproto/grpc" "github.com/cosmos/gogoproto/proto" "google.golang.org/grpc" - "google.golang.org/protobuf/reflect/protoregistry" errorsmod "cosmossdk.io/errors" @@ -25,7 +24,6 @@ type MessageRouter interface { // MsgServiceRouter routes fully-qualified Msg service methods to their handler. type MsgServiceRouter struct { - protoFiles *protoregistry.Files interfaceRegistry codectypes.InterfaceRegistry routes map[string]MsgServiceHandler } @@ -34,14 +32,8 @@ var _ gogogrpc.Server = &MsgServiceRouter{} // NewMsgServiceRouter creates a new MsgServiceRouter. func NewMsgServiceRouter() *MsgServiceRouter { - protoFiles, err := proto.MergedRegistry() - if err != nil { - panic(err) - } - return &MsgServiceRouter{ - protoFiles: protoFiles, - routes: map[string]MsgServiceHandler{}, + routes: map[string]MsgServiceHandler{}, } } From 7fa349767e18e6657459cc458f4eb1d009792211 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 14:17:42 +0100 Subject: [PATCH 39/48] Move msg validation to GetSignersContext --- api/cosmos/app/v1alpha1/module.pulsar.go | 2 +- types/msgservice/validate.go | 60 +----------------------- types/msgservice/validate_test.go | 28 ----------- x/tx/signing/get_signers.go | 42 ++++++++++++++++- x/tx/signing/get_signers_test.go | 3 +- 5 files changed, 45 insertions(+), 90 deletions(-) diff --git a/api/cosmos/app/v1alpha1/module.pulsar.go b/api/cosmos/app/v1alpha1/module.pulsar.go index 914894677e5..9d17b5460a9 100644 --- a/api/cosmos/app/v1alpha1/module.pulsar.go +++ b/api/cosmos/app/v1alpha1/module.pulsar.go @@ -1698,7 +1698,7 @@ type PackageReference struct { // // When a new version of a module is released and items are added to existing // .proto files, these definitions should contain comments of the form - // "Since Revision N" where N is an integer revision. + // "Since: Revision N" where N is an integer revision. // // When the module runtime starts up, it will check the pinned proto // image and panic if there are runtime protobuf definitions that are not diff --git a/types/msgservice/validate.go b/types/msgservice/validate.go index 08858bddfa9..cbbed0ad9d8 100644 --- a/types/msgservice/validate.go +++ b/types/msgservice/validate.go @@ -14,7 +14,6 @@ import ( // ValidateAnnotations validates that the proto annotations are correct. // More specifically, it verifies: // - all services named "Msg" have `(cosmos.msg.v1.service) = true`, -// - all sdk.Msgs have correct `(cosmos.msg.v1.signer) = "..."`. // // More validations can be added here in the future. // @@ -24,10 +23,7 @@ func ValidateProtoAnnotations(protoFiles *protoregistry.Files) error { protoFiles = protoregistry.GlobalFiles } - var ( - serviceErrs []error - messageErrs []error - ) + var serviceErrs []error protoFiles.RangeFiles(func(fd protoreflect.FileDescriptor) bool { for i := 0; i < fd.Services().Len(); i++ { sd := fd.Services().Get(i) @@ -38,20 +34,13 @@ func ValidateProtoAnnotations(protoFiles *protoregistry.Files) error { if err != nil { serviceErrs = append(serviceErrs, err) } - - for j := 0; j < sd.Methods().Len(); j++ { - err := validateMsgAnnotations(protoFiles, sd.Methods().Get(j).Input()) - if err != nil { - messageErrs = append(messageErrs, err) - } - } } } return true }) - return errors.Join(errors.Join(serviceErrs...), errors.Join(messageErrs...)) + return errors.Join(serviceErrs...) } // validateMsgServiceAnnotations validates that the service has the @@ -69,48 +58,3 @@ func validateMsgServiceAnnotations(protoFiles *protoregistry.Files, sd protorefl return nil } - -// validateMsgAnnotations validates the sdk.Msg service has the correct -// `(cosmos.msg.v1.signer) = "..."` proto annotation. -func validateMsgAnnotations(protoFiles *protoregistry.Files, md protoreflect.MessageDescriptor) error { - ext := proto.GetExtension(md.Options(), msg.E_Signer) - signers, ok := ext.([]string) - if !ok { - return fmt.Errorf("expected []string, got %T", ext) - } - - if len(signers) == 0 { - return fmt.Errorf("sdk.Msg %s does not have cosmos.msg.v1.signer proto annotation", md.FullName()) - } - - for i, signer := range signers { - if signer == "" { - return fmt.Errorf("sdk.Msg %s signer at index %d is empty", md.FullName(), i) - } - - // Make sure the signer annotation is a correct field of type string - fd := md.Fields().ByName(protoreflect.Name(signer)) - if fd == nil { - return fmt.Errorf("sdk.Msg %s has incorrect signer %s", md.FullName(), signer) - } - - // The signer annotation should point to: - // - either be a string field, - // - or a message field who recursively has a "signer" string field. - switch fd.Kind() { - case protoreflect.StringKind: - continue - case protoreflect.MessageKind: - err := validateMsgAnnotations(protoFiles, fd.Message()) - if err != nil { - return err - } - - continue - default: - return fmt.Errorf("sdk.Msg %s has signer %s of incorrect type; expected string or message, got %s", md.FullName(), signer, fd.Kind()) - } - } - - return nil -} diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index b9b505ca6e8..45c7f37ca8a 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -4,12 +4,8 @@ import ( "testing" "github.com/stretchr/testify/require" - "google.golang.org/protobuf/proto" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" - - bankv1beta1 "cosmossdk.io/api/cosmos/bank/v1beta1" - "github.com/cosmos/cosmos-sdk/testutil/testdata/testpb" ) func TestValidateServiceAnnotations(t *testing.T) { @@ -24,27 +20,3 @@ func TestValidateServiceAnnotations(t *testing.T) { err = validateMsgServiceAnnotations(nil, sd.(protoreflect.ServiceDescriptor)) require.NoError(t, err) } - -func TestValidateMsgAnnotations(t *testing.T) { - testcases := []struct { - name string - message proto.Message - expErr bool - }{ - {"no signer annotation", &testpb.Dog{}, true}, - {"valid signer", &bankv1beta1.MsgSend{}, false}, - {"valid signer as message", &bankv1beta1.MsgMultiSend{}, false}, - } - - for _, tc := range testcases { - tc := tc - t.Run(tc.name, func(t *testing.T) { - err := validateMsgAnnotations(nil, tc.message.ProtoReflect().Descriptor()) - if tc.expErr { - require.Error(t, err) - } else { - require.NoError(t, err) - } - }) - } -} diff --git a/x/tx/signing/get_signers.go b/x/tx/signing/get_signers.go index a494ddcd821..cbc0a5141fb 100644 --- a/x/tx/signing/get_signers.go +++ b/x/tx/signing/get_signers.go @@ -1,12 +1,14 @@ package signing import ( + "errors" "fmt" msgv1 "cosmossdk.io/api/cosmos/msg/v1" "google.golang.org/protobuf/proto" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" + "google.golang.org/protobuf/types/dynamicpb" ) // GetSignersContext is a context for retrieving the list of signers from a @@ -25,16 +27,20 @@ type GetSignersOptions struct { } // NewGetSignersContext creates a new GetSignersContext using the provided options. -func NewGetSignersContext(options GetSignersOptions) *GetSignersContext { +func NewGetSignersContext(options GetSignersOptions) (*GetSignersContext, error) { protoFiles := options.ProtoFiles if protoFiles == nil { protoFiles = protoregistry.GlobalFiles } - return &GetSignersContext{ + c := &GetSignersContext{ protoFiles: protoFiles, getSignersFuncs: map[protoreflect.FullName]getSignersFunc{}, } + + err := c.init() + + return c, err } type getSignersFunc func(proto.Message) []string @@ -48,6 +54,38 @@ func getSignersFieldNames(descriptor protoreflect.MessageDescriptor) ([]string, return signersFields, nil } +// init performs a dry run of getting all msg's signers. This has 2 benefits: +// - it will error if any Msg has forgotten the "cosmos.msg.v1.signer" +// annotation +// - it will pre-populate the context's internal cache for getSignersFuncs +// so that calling it in antehandlers will be faster. +func (c *GetSignersContext) init() error { + var errs []error + c.protoFiles.RangeFiles(func(fd protoreflect.FileDescriptor) bool { + for i := 0; i < fd.Services().Len(); i++ { + sd := fd.Services().Get(i) + // We use the heuristic that services named "Msg" are exactly the + // ones that need the proto annotation check. + if sd.Name() != "Msg" { + continue + } + + for j := 0; j < sd.Methods().Len(); j++ { + md := sd.Methods().Get(j).Input() + msg := dynamicpb.NewMessage(md) + _, err := c.GetSigners(msg) + if err != nil { + errs = append(errs, err) + } + } + } + + return true + }) + + return errors.Join(errs...) +} + func (*GetSignersContext) makeGetSignersFunc(descriptor protoreflect.MessageDescriptor) (getSignersFunc, error) { signersFields, err := getSignersFieldNames(descriptor) if err != nil { diff --git a/x/tx/signing/get_signers_test.go b/x/tx/signing/get_signers_test.go index 85dde062acb..53b03f8a977 100644 --- a/x/tx/signing/get_signers_test.go +++ b/x/tx/signing/get_signers_test.go @@ -12,7 +12,8 @@ import ( ) func TestGetSigners(t *testing.T) { - ctx := NewGetSignersContext(GetSignersOptions{}) + ctx, err := NewGetSignersContext(GetSignersOptions{}) + require.NoError(t, err) tests := []struct { name string msg proto.Message From b8435e20e7da71beb72b3929a97e79942f5c74ca Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 14:21:15 +0100 Subject: [PATCH 40/48] Use commit hash for api --- go.mod | 2 +- simapp/go.mod | 2 +- tests/go.mod | 2 +- tests/go.sum | 4 ++-- x/tx/go.mod | 2 +- x/tx/go.sum | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/go.mod b/go.mod index 984fe82feb4..58dd5011e36 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ go 1.20 module github.com/cosmos/cosmos-sdk require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 cosmossdk.io/collections v0.0.0-20230309163709-87da587416ba cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba cosmossdk.io/depinject v1.0.0-alpha.3 diff --git a/simapp/go.mod b/simapp/go.mod index f1cbdc27dcd..8d140eb3852 100644 --- a/simapp/go.mod +++ b/simapp/go.mod @@ -3,7 +3,7 @@ module cosmossdk.io/simapp go 1.20 require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 cosmossdk.io/client/v2 v2.0.0-20230309163709-87da587416ba cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba cosmossdk.io/depinject v1.0.0-alpha.3 diff --git a/tests/go.mod b/tests/go.mod index 54bbe38fb30..be1cf63e44e 100644 --- a/tests/go.mod +++ b/tests/go.mod @@ -3,7 +3,7 @@ module github.com/cosmos/cosmos-sdk/tests go 1.20 require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 cosmossdk.io/depinject v1.0.0-alpha.3 cosmossdk.io/errors v1.0.0-beta.7 cosmossdk.io/log v0.0.0-20230313123454-0fe816b71a62 diff --git a/tests/go.sum b/tests/go.sum index c48a61626b1..7567166fee3 100644 --- a/tests/go.sum +++ b/tests/go.sum @@ -188,8 +188,8 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 h1:4LrWK+uGP5IxznxtHHsHD+ZBs2+oZRH2loYOGjHLzZM= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7/go.mod h1:yVns7mKgcsG+hZW/3C5FdJtC6QYWdFIcRlKb9+5HV5g= cosmossdk.io/client/v2 v2.0.0-20230309163709-87da587416ba h1:LuPHCncU2KLMNPItFECs709uo46I9wSu2fAWYVCx+/U= cosmossdk.io/client/v2 v2.0.0-20230309163709-87da587416ba/go.mod h1:SXdwqO7cN5htalh/lhXWP8V4zKtBrhhcSTU+ytuEtmM= cosmossdk.io/collections v0.0.0-20230309163709-87da587416ba h1:S4PYij/tX3Op/hwenVEN9D+M27JRcwSwVqE3UA0BnwM= diff --git a/x/tx/go.mod b/x/tx/go.mod index 96f87f615ba..5a684fead50 100644 --- a/x/tx/go.mod +++ b/x/tx/go.mod @@ -3,7 +3,7 @@ module cosmossdk.io/x/tx go 1.20 require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba cosmossdk.io/math v1.0.0-beta.6 github.com/cosmos/cosmos-proto v1.0.0-beta.3 diff --git a/x/tx/go.sum b/x/tx/go.sum index e636261d26c..ebc5de24a55 100644 --- a/x/tx/go.sum +++ b/x/tx/go.sum @@ -1,5 +1,5 @@ -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 h1:4LrWK+uGP5IxznxtHHsHD+ZBs2+oZRH2loYOGjHLzZM= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7/go.mod h1:yVns7mKgcsG+hZW/3C5FdJtC6QYWdFIcRlKb9+5HV5g= cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba h1:kSnaDzbwMInpQYwz8ESgvi6ceUQWcXAJdEVZW454dX0= cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba/go.mod h1:WiFk9ZQbFVBHk9AqQIkLFqyj30NPQB6C45CIeAZxDcw= cosmossdk.io/math v1.0.0-beta.6 h1:WF29SiFYNde5eYvqO2kdOM9nYbDb44j3YW5B8M1m9KE= From 34fa561ae93dfbf700fafe738c8e528920649bd0 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 14:25:40 +0100 Subject: [PATCH 41/48] Put in ProvideApp --- runtime/app.go | 15 --------------- runtime/module.go | 23 ++++++++++++++++++++++- simapp/app.go | 14 ++++++++++++++ 3 files changed, 36 insertions(+), 16 deletions(-) diff --git a/runtime/app.go b/runtime/app.go index 42dcd7783b0..7388ec9faa2 100644 --- a/runtime/app.go +++ b/runtime/app.go @@ -3,7 +3,6 @@ package runtime import ( "encoding/json" "fmt" - "os" abci "github.com/cometbft/cometbft/abci/types" "golang.org/x/exp/slices" @@ -24,9 +23,7 @@ import ( servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/cosmos/cosmos-sdk/types/msgservice" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" - "github.com/cosmos/gogoproto/proto" ) // App is a wrapper around BaseApp and ModuleManager that can be used in hybrid @@ -115,18 +112,6 @@ func (a *App) Load(loadLatest bool) error { } } - // At startup, check that all proto annotations are correct. - protoFiles, err := proto.MergedRegistry() - if err != nil { - return err - } - err = msgservice.ValidateProtoAnnotations(protoFiles) - if err != nil { - // Once we switch to using protoreflect-based antehandlers, we might - // want to panic here instead of logging a warning. - fmt.Fprintln(os.Stderr, err.Error()) - } - return nil } diff --git a/runtime/module.go b/runtime/module.go index c64c7b47219..30556ba050a 100644 --- a/runtime/module.go +++ b/runtime/module.go @@ -2,8 +2,11 @@ package runtime import ( "fmt" + "os" "cosmossdk.io/core/store" + "google.golang.org/protobuf/reflect/protodesc" + "google.golang.org/protobuf/reflect/protoregistry" abci "github.com/cometbft/cometbft/abci/types" @@ -19,6 +22,8 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/std" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/types/msgservice" + "github.com/cosmos/gogoproto/proto" ) type appModule struct { @@ -71,6 +76,8 @@ func ProvideApp() ( codec.ProtoCodecMarshaler, *baseapp.MsgServiceRouter, appmodule.AppModule, + protodesc.Resolver, + protoregistry.MessageTypeResolver, ) { interfaceRegistry := codectypes.NewInterfaceRegistry() amino := codec.NewLegacyAmino() @@ -90,7 +97,21 @@ func ProvideApp() ( } appBuilder := &AppBuilder{app} - return interfaceRegistry, cdc, amino, appBuilder, cdc, msgServiceRouter, appModule{app} + protoFiles, err := proto.MergedRegistry() + if err != nil { + panic(err) + } + protoTypes := protoregistry.GlobalTypes + + // At startup, check that all proto annotations are correct. + err = msgservice.ValidateProtoAnnotations(protoFiles) + if err != nil { + // Once we switch to using protoreflect-based antehandlers, we might + // want to panic here instead of logging a warning. + fmt.Fprintln(os.Stderr, err.Error()) + } + + return interfaceRegistry, cdc, amino, appBuilder, cdc, msgServiceRouter, appModule{app}, protoFiles, protoTypes } type AppInputs struct { diff --git a/simapp/app.go b/simapp/app.go index 6dbdc5f8969..b7e5300dcb0 100644 --- a/simapp/app.go +++ b/simapp/app.go @@ -507,6 +507,20 @@ func NewSimApp( // upgrade. app.setPostHandler() + // At startup, after all modules have been registered, check that all prot + // annotations are correct. + protoFiles, err := proto.MergedRegistry() + if err != nil { + panic(err) + } + protoTypes := protoregistry.GlobalTypes + err = msgservice.ValidateProtoAnnotations(protoFiles) + if err != nil { + // Once we switch to using protoreflect-based antehandlers, we might + // want to panic here instead of logging a warning. + fmt.Fprintln(os.Stderr, err.Error()) + } + if loadLatest { if err := app.LoadLatestVersion(); err != nil { panic(fmt.Errorf("error loading last version: %w", err)) From b39b168ceb17407b55c297a80007b3e637a4e246 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 14:35:21 +0100 Subject: [PATCH 42/48] Fix build --- simapp/app.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/simapp/app.go b/simapp/app.go index b7e5300dcb0..8bbe12dbbd3 100644 --- a/simapp/app.go +++ b/simapp/app.go @@ -16,6 +16,7 @@ import ( "cosmossdk.io/log" abci "github.com/cometbft/cometbft/abci/types" dbm "github.com/cosmos/cosmos-db" + "github.com/cosmos/gogoproto/proto" "github.com/spf13/cast" simappparams "cosmossdk.io/simapp/params" @@ -50,6 +51,7 @@ import ( testdata_pulsar "github.com/cosmos/cosmos-sdk/testutil/testdata/testpb" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" + "github.com/cosmos/cosmos-sdk/types/msgservice" "github.com/cosmos/cosmos-sdk/version" "github.com/cosmos/cosmos-sdk/x/auth" "github.com/cosmos/cosmos-sdk/x/auth/ante" @@ -513,7 +515,6 @@ func NewSimApp( if err != nil { panic(err) } - protoTypes := protoregistry.GlobalTypes err = msgservice.ValidateProtoAnnotations(protoFiles) if err != nil { // Once we switch to using protoreflect-based antehandlers, we might From 0e20595ef7cd917643550b49a678a195c5c83104 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 14:37:04 +0100 Subject: [PATCH 43/48] Remove replace --- go.mod | 3 --- go.sum | 2 ++ 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 58dd5011e36..dd2d76fe6ce 100644 --- a/go.mod +++ b/go.mod @@ -152,9 +152,6 @@ require ( nhooyr.io/websocket v1.8.6 // indirect ) -// Here are the short-lived replace for the Cosmos SDK -replace cosmossdk.io/api => ./api - // Below are the long-lived replace of the Cosmos SDK replace ( // use cosmos fork of keyring diff --git a/go.sum b/go.sum index ab40832b3a2..b86b04d0ca5 100644 --- a/go.sum +++ b/go.sum @@ -35,6 +35,8 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7 h1:4LrWK+uGP5IxznxtHHsHD+ZBs2+oZRH2loYOGjHLzZM= +cosmossdk.io/api v0.3.2-0.20230313131911-55bf5d4efbe7/go.mod h1:yVns7mKgcsG+hZW/3C5FdJtC6QYWdFIcRlKb9+5HV5g= cosmossdk.io/collections v0.0.0-20230309163709-87da587416ba h1:S4PYij/tX3Op/hwenVEN9D+M27JRcwSwVqE3UA0BnwM= cosmossdk.io/collections v0.0.0-20230309163709-87da587416ba/go.mod h1:lpS+G8bGC2anqzWdndTzjnQnuMO/qAcgZUkGJp4i3rc= cosmossdk.io/core v0.6.1-0.20230309163709-87da587416ba h1:kSnaDzbwMInpQYwz8ESgvi6ceUQWcXAJdEVZW454dX0= From a302c5d59c35197052d26549bc36c369e6d68b7d Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 13 Mar 2023 16:26:52 +0100 Subject: [PATCH 44/48] Fix test --- types/msgservice/validate_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/types/msgservice/validate_test.go b/types/msgservice/validate_test.go index 45c7f37ca8a..8a72f724b04 100644 --- a/types/msgservice/validate_test.go +++ b/types/msgservice/validate_test.go @@ -6,6 +6,8 @@ import ( "github.com/stretchr/testify/require" "google.golang.org/protobuf/reflect/protoreflect" "google.golang.org/protobuf/reflect/protoregistry" + + _ "cosmossdk.io/api/cosmos/bank/v1beta1" ) func TestValidateServiceAnnotations(t *testing.T) { From c596277a7de95d177f0d6ccedb9b7eecfdd63bc6 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Tue, 14 Mar 2023 10:39:11 +0100 Subject: [PATCH 45/48] Update x/tx/signing/get_signers.go Co-authored-by: Marko --- x/tx/signing/get_signers.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/x/tx/signing/get_signers.go b/x/tx/signing/get_signers.go index cbc0a5141fb..7b62b6601fb 100644 --- a/x/tx/signing/get_signers.go +++ b/x/tx/signing/get_signers.go @@ -38,9 +38,7 @@ func NewGetSignersContext(options GetSignersOptions) (*GetSignersContext, error) getSignersFuncs: map[protoreflect.FullName]getSignersFunc{}, } - err := c.init() - - return c, err + return c, c.init() } type getSignersFunc func(proto.Message) []string From 90bdbe8d0b959f549e011dabbcc8a2524713b321 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Mar 2023 09:43:00 +0100 Subject: [PATCH 46/48] Fix build --- x/tx/signing/direct_aux/direct_aux.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/x/tx/signing/direct_aux/direct_aux.go b/x/tx/signing/direct_aux/direct_aux.go index 85269420490..59dcbf6be2c 100644 --- a/x/tx/signing/direct_aux/direct_aux.go +++ b/x/tx/signing/direct_aux/direct_aux.go @@ -50,7 +50,11 @@ func NewSignModeHandler(options SignModeHandlerOptions) SignModeHandler { } if options.SignersContext == nil { - h.signersContext = signing.NewGetSignersContext(signing.GetSignersOptions{ProtoFiles: h.fileResolver}) + var err error + h.signersContext, err = signing.NewGetSignersContext(signing.GetSignersOptions{ProtoFiles: h.fileResolver}) + if err != nil { + panic(err) + } } else { h.signersContext = options.SignersContext } From 2cb4fab16d4a55593272831846119f3cfa42d479 Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Mar 2023 15:52:05 +0100 Subject: [PATCH 47/48] Return err --- x/tx/CHANGELOG.md | 1 + x/tx/signing/direct_aux/direct_aux.go | 6 +++--- x/tx/signing/direct_aux/direct_aux_test.go | 3 ++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/x/tx/CHANGELOG.md b/x/tx/CHANGELOG.md index fbf674c28be..c3593705224 100644 --- a/x/tx/CHANGELOG.md +++ b/x/tx/CHANGELOG.md @@ -33,6 +33,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## API Breaking +* [#15278](https://github.com/cosmos/cosmos-sdk/pull/13793) `direct_aux.NewSignModeHandler` constructor function now returns an additional error argument. * [#15278](https://github.com/cosmos/cosmos-sdk/pull/15278) Move `x/tx/{textual,aminojson}` into `x/tx/signing`. * [#15302](https://github.com/cosmos/cosmos-sdk/pull/15302) `textual.NewSignModeHandler` now takes an options struct instead of a simple coin querier argument. It also returns an error. diff --git a/x/tx/signing/direct_aux/direct_aux.go b/x/tx/signing/direct_aux/direct_aux.go index 59dcbf6be2c..c9ef9d86403 100644 --- a/x/tx/signing/direct_aux/direct_aux.go +++ b/x/tx/signing/direct_aux/direct_aux.go @@ -34,7 +34,7 @@ type SignModeHandlerOptions struct { } // NewSignModeHandler returns a new SignModeHandler. -func NewSignModeHandler(options SignModeHandlerOptions) SignModeHandler { +func NewSignModeHandler(options SignModeHandlerOptions) (SignModeHandler, error) { h := SignModeHandler{} if options.FileResolver == nil { @@ -53,13 +53,13 @@ func NewSignModeHandler(options SignModeHandlerOptions) SignModeHandler { var err error h.signersContext, err = signing.NewGetSignersContext(signing.GetSignersOptions{ProtoFiles: h.fileResolver}) if err != nil { - panic(err) + return h, err } } else { h.signersContext = options.SignersContext } - return h + return h, nil } var _ signing.SignModeHandler = SignModeHandler{} diff --git a/x/tx/signing/direct_aux/direct_aux_test.go b/x/tx/signing/direct_aux/direct_aux_test.go index 45ef96e5a48..2b82ce59dd7 100644 --- a/x/tx/signing/direct_aux/direct_aux_test.go +++ b/x/tx/signing/direct_aux/direct_aux_test.go @@ -83,7 +83,8 @@ func TestDirectAuxHandler(t *testing.T) { AuthInfoBytes: authInfoBz, BodyBytes: bodyBz, } - modeHandler := direct_aux.NewSignModeHandler(direct_aux.SignModeHandlerOptions{}) + modeHandler, err := direct_aux.NewSignModeHandler(direct_aux.SignModeHandlerOptions{}) + require.NoError(t, err) t.Log("verify fee payer cannot use SIGN_MODE_DIRECT_AUX") feePayerSigningData := signing.SignerData{ From 449d98c4019b91064d35499870c70e89780cbeef Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Mon, 20 Mar 2023 15:53:15 +0100 Subject: [PATCH 48/48] Fix PR number in CL --- x/tx/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/tx/CHANGELOG.md b/x/tx/CHANGELOG.md index c3593705224..baf46b9f622 100644 --- a/x/tx/CHANGELOG.md +++ b/x/tx/CHANGELOG.md @@ -33,7 +33,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ## API Breaking -* [#15278](https://github.com/cosmos/cosmos-sdk/pull/13793) `direct_aux.NewSignModeHandler` constructor function now returns an additional error argument. +* [#13793](https://github.com/cosmos/cosmos-sdk/pull/13793) `direct_aux.NewSignModeHandler` constructor function now returns an additional error argument. * [#15278](https://github.com/cosmos/cosmos-sdk/pull/15278) Move `x/tx/{textual,aminojson}` into `x/tx/signing`. * [#15302](https://github.com/cosmos/cosmos-sdk/pull/15302) `textual.NewSignModeHandler` now takes an options struct instead of a simple coin querier argument. It also returns an error.