From f1b1f69e00793a5ff2a548806551863ec1173282 Mon Sep 17 00:00:00 2001 From: forcodedancing Date: Fri, 11 Aug 2023 17:53:44 -0600 Subject: [PATCH] fix test issue --- api/cosmos/base/abci/v1beta1/abci.pulsar.go | 141 ++++++++++++---- baseapp/abci.go | 11 +- proto/cosmos/base/abci/v1beta1/abci.proto | 17 +- store/gaskv/store_test.go | 44 ++--- types/abci.pb.go | 176 +++++++++++++------- 5 files changed, 268 insertions(+), 121 deletions(-) diff --git a/api/cosmos/base/abci/v1beta1/abci.pulsar.go b/api/cosmos/base/abci/v1beta1/abci.pulsar.go index 82421304e0..d3f6216863 100644 --- a/api/cosmos/base/abci/v1beta1/abci.pulsar.go +++ b/api/cosmos/base/abci/v1beta1/abci.pulsar.go @@ -5382,6 +5382,7 @@ var ( md_TxMsgData protoreflect.MessageDescriptor fd_TxMsgData_data protoreflect.FieldDescriptor fd_TxMsgData_msg_responses protoreflect.FieldDescriptor + fd_TxMsgData_extra_data protoreflect.FieldDescriptor ) func init() { @@ -5389,6 +5390,7 @@ func init() { md_TxMsgData = File_cosmos_base_abci_v1beta1_abci_proto.Messages().ByName("TxMsgData") fd_TxMsgData_data = md_TxMsgData.Fields().ByName("data") fd_TxMsgData_msg_responses = md_TxMsgData.Fields().ByName("msg_responses") + fd_TxMsgData_extra_data = md_TxMsgData.Fields().ByName("extra_data") } var _ protoreflect.Message = (*fastReflection_TxMsgData)(nil) @@ -5468,6 +5470,12 @@ func (x *fastReflection_TxMsgData) Range(f func(protoreflect.FieldDescriptor, pr return } } + if len(x.ExtraData) != 0 { + value := protoreflect.ValueOfBytes(x.ExtraData) + if !f(fd_TxMsgData_extra_data, value) { + return + } + } } // Has reports whether a field is populated. @@ -5487,6 +5495,8 @@ func (x *fastReflection_TxMsgData) Has(fd protoreflect.FieldDescriptor) bool { return len(x.Data) != 0 case "cosmos.base.abci.v1beta1.TxMsgData.msg_responses": return len(x.MsgResponses) != 0 + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + return len(x.ExtraData) != 0 default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5507,6 +5517,8 @@ func (x *fastReflection_TxMsgData) Clear(fd protoreflect.FieldDescriptor) { x.Data = nil case "cosmos.base.abci.v1beta1.TxMsgData.msg_responses": x.MsgResponses = nil + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + x.ExtraData = nil default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5535,6 +5547,9 @@ func (x *fastReflection_TxMsgData) Get(descriptor protoreflect.FieldDescriptor) } listValue := &_TxMsgData_2_list{list: &x.MsgResponses} return protoreflect.ValueOfList(listValue) + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + value := x.ExtraData + return protoreflect.ValueOfBytes(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5563,6 +5578,8 @@ func (x *fastReflection_TxMsgData) Set(fd protoreflect.FieldDescriptor, value pr lv := value.List() clv := lv.(*_TxMsgData_2_list) x.MsgResponses = *clv.list + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + x.ExtraData = value.Bytes() default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5595,6 +5612,8 @@ func (x *fastReflection_TxMsgData) Mutable(fd protoreflect.FieldDescriptor) prot } value := &_TxMsgData_2_list{list: &x.MsgResponses} return protoreflect.ValueOfList(value) + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + panic(fmt.Errorf("field extra_data of message cosmos.base.abci.v1beta1.TxMsgData is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5614,6 +5633,8 @@ func (x *fastReflection_TxMsgData) NewField(fd protoreflect.FieldDescriptor) pro case "cosmos.base.abci.v1beta1.TxMsgData.msg_responses": list := []*anypb.Any{} return protoreflect.ValueOfList(&_TxMsgData_2_list{list: &list}) + case "cosmos.base.abci.v1beta1.TxMsgData.extra_data": + return protoreflect.ValueOfBytes(nil) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.TxMsgData")) @@ -5695,6 +5716,10 @@ func (x *fastReflection_TxMsgData) ProtoMethods() *protoiface.Methods { n += 1 + l + runtime.Sov(uint64(l)) } } + l = len(x.ExtraData) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -5724,6 +5749,13 @@ func (x *fastReflection_TxMsgData) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.ExtraData) > 0 { + i -= len(x.ExtraData) + copy(dAtA[i:], x.ExtraData) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.ExtraData))) + i-- + dAtA[i] = 0x1a + } if len(x.MsgResponses) > 0 { for iNdEx := len(x.MsgResponses) - 1; iNdEx >= 0; iNdEx-- { encoded, err := options.Marshal(x.MsgResponses[iNdEx]) @@ -5873,6 +5905,40 @@ func (x *fastReflection_TxMsgData) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 3: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field ExtraData", wireType) + } + var byteLen int + 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++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, runtime.ErrInvalidLength + } + postIndex := iNdEx + byteLen + 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.ExtraData = append(x.ExtraData[:0], dAtA[iNdEx:postIndex]...) + if x.ExtraData == nil { + x.ExtraData = []byte{} + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -7197,6 +7263,8 @@ type TxMsgData struct { // // Since: cosmos-sdk 0.46 MsgResponses []*anypb.Any `protobuf:"bytes,2,rep,name=msg_responses,json=msgResponses,proto3" json:"msg_responses,omitempty"` + // extra data - the r/w info + ExtraData []byte `protobuf:"bytes,3,opt,name=extra_data,json=extraData,proto3" json:"extra_data,omitempty"` } func (x *TxMsgData) Reset() { @@ -7234,6 +7302,13 @@ func (x *TxMsgData) GetMsgResponses() []*anypb.Any { return nil } +func (x *TxMsgData) GetExtraData() []byte { + if x != nil { + return x.ExtraData + } + return nil +} + // SearchTxsResult defines a structure for querying txs pageable type SearchTxsResult struct { state protoimpl.MessageState @@ -7410,7 +7485,7 @@ var file_cosmos_base_abci_v1beta1_abci_proto_rawDesc = []byte{ 0x44, 0x61, 0x74, 0x61, 0x12, 0x19, 0x0a, 0x08, 0x6d, 0x73, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x73, 0x67, 0x54, 0x79, 0x70, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, - 0x61, 0x74, 0x61, 0x3a, 0x06, 0x18, 0x01, 0x80, 0xdc, 0x20, 0x01, 0x22, 0x87, 0x01, 0x0a, 0x09, + 0x61, 0x74, 0x61, 0x3a, 0x06, 0x18, 0x01, 0x80, 0xdc, 0x20, 0x01, 0x22, 0xa6, 0x01, 0x0a, 0x09, 0x54, 0x78, 0x4d, 0x73, 0x67, 0x44, 0x61, 0x74, 0x61, 0x12, 0x39, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x61, 0x62, 0x63, 0x69, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, @@ -7418,37 +7493,39 @@ var file_cosmos_base_abci_v1beta1_abci_proto_rawDesc = []byte{ 0x64, 0x61, 0x74, 0x61, 0x12, 0x39, 0x0a, 0x0d, 0x6d, 0x73, 0x67, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, - 0x79, 0x52, 0x0c, 0x6d, 0x73, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x73, 0x3a, - 0x04, 0x80, 0xdc, 0x20, 0x01, 0x22, 0xdc, 0x01, 0x0a, 0x0f, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, - 0x54, 0x78, 0x73, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, - 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, - 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, - 0x75, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75, 0x6d, 0x62, 0x65, - 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x74, 0x61, 0x6c, - 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, - 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x36, 0x0a, 0x03, 0x74, 0x78, 0x73, 0x18, 0x06, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, - 0x65, 0x2e, 0x61, 0x62, 0x63, 0x69, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x54, - 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x03, 0x74, 0x78, 0x73, 0x3a, 0x04, - 0x80, 0xdc, 0x20, 0x01, 0x42, 0xe7, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x61, 0x62, 0x63, 0x69, 0x2e, 0x76, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0x42, 0x09, 0x41, 0x62, 0x63, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, - 0x50, 0x01, 0x5a, 0x35, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, - 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, - 0x2f, 0x61, 0x62, 0x63, 0x69, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x3b, 0x61, 0x62, - 0x63, 0x69, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x42, 0x41, 0xaa, - 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x2e, 0x41, 0x62, - 0x63, 0x69, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xca, 0x02, 0x18, 0x43, 0x6f, 0x73, - 0x6d, 0x6f, 0x73, 0x5c, 0x42, 0x61, 0x73, 0x65, 0x5c, 0x41, 0x62, 0x63, 0x69, 0x5c, 0x56, 0x31, - 0x62, 0x65, 0x74, 0x61, 0x31, 0xe2, 0x02, 0x24, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x42, - 0x61, 0x73, 0x65, 0x5c, 0x41, 0x62, 0x63, 0x69, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, - 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x43, - 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x42, 0x61, 0x73, 0x65, 0x3a, 0x3a, 0x41, 0x62, 0x63, - 0x69, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xd8, 0xe1, 0x1e, 0x00, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x79, 0x52, 0x0c, 0x6d, 0x73, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x73, 0x12, + 0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x74, 0x72, 0x61, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0c, 0x52, 0x09, 0x65, 0x78, 0x74, 0x72, 0x61, 0x44, 0x61, 0x74, 0x61, 0x3a, 0x04, + 0x80, 0xdc, 0x20, 0x01, 0x22, 0xdc, 0x01, 0x0a, 0x0f, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x54, + 0x78, 0x73, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, + 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x74, + 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, + 0x1f, 0x0a, 0x0b, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x12, + 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, + 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x36, 0x0a, 0x03, 0x74, 0x78, 0x73, 0x18, 0x06, 0x20, 0x03, + 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, + 0x2e, 0x61, 0x62, 0x63, 0x69, 0x2e, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x2e, 0x54, 0x78, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x52, 0x03, 0x74, 0x78, 0x73, 0x3a, 0x04, 0x80, + 0xdc, 0x20, 0x01, 0x42, 0xe7, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x63, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x2e, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x61, 0x62, 0x63, 0x69, 0x2e, 0x76, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x31, 0x42, 0x09, 0x41, 0x62, 0x63, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, + 0x01, 0x5a, 0x35, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x73, 0x64, 0x6b, 0x2e, 0x69, 0x6f, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2f, 0x62, 0x61, 0x73, 0x65, 0x2f, + 0x61, 0x62, 0x63, 0x69, 0x2f, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x3b, 0x61, 0x62, 0x63, + 0x69, 0x76, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xa2, 0x02, 0x03, 0x43, 0x42, 0x41, 0xaa, 0x02, + 0x18, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x2e, 0x42, 0x61, 0x73, 0x65, 0x2e, 0x41, 0x62, 0x63, + 0x69, 0x2e, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xca, 0x02, 0x18, 0x43, 0x6f, 0x73, 0x6d, + 0x6f, 0x73, 0x5c, 0x42, 0x61, 0x73, 0x65, 0x5c, 0x41, 0x62, 0x63, 0x69, 0x5c, 0x56, 0x31, 0x62, + 0x65, 0x74, 0x61, 0x31, 0xe2, 0x02, 0x24, 0x43, 0x6f, 0x73, 0x6d, 0x6f, 0x73, 0x5c, 0x42, 0x61, + 0x73, 0x65, 0x5c, 0x41, 0x62, 0x63, 0x69, 0x5c, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1b, 0x43, 0x6f, + 0x73, 0x6d, 0x6f, 0x73, 0x3a, 0x3a, 0x42, 0x61, 0x73, 0x65, 0x3a, 0x3a, 0x41, 0x62, 0x63, 0x69, + 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x65, 0x74, 0x61, 0x31, 0xd8, 0xe1, 0x1e, 0x00, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/baseapp/abci.go b/baseapp/abci.go index 4887add419..af93bc9354 100644 --- a/baseapp/abci.go +++ b/baseapp/abci.go @@ -448,11 +448,20 @@ func (app *BaseApp) DeliverTx(req abci.RequestDeliverTx) (res abci.ResponseDeliv app.deliverState.ctx.Logger().Debug("Gas info rw used", "RwUsed", gInfo.RwUsed, "height", app.deliverState.ctx.BlockHeight()) rwUsedBz := sdk.Uint64ToBigEndian(gInfo.RwUsed) + msgData := &sdk.TxMsgData{} + proto.Unmarshal(result.Data, msgData) + msgData.ExtraData = rwUsedBz + bz, err := proto.Marshal(msgData) + if err != nil { + resultStr = "failed" + return sdkerrors.ResponseDeliverTxWithEvents(err, gInfo.GasWanted, gInfo.GasUsed, sdk.MarkEventsToIndex(anteEvents, app.indexEvents), app.trace) + } + return abci.ResponseDeliverTx{ GasWanted: int64(gInfo.GasWanted), // TODO: Should type accept unsigned ints? GasUsed: int64(gInfo.GasUsed), // TODO: Should type accept unsigned ints? Log: result.Log, - Data: append(result.Data, rwUsedBz...), + Data: bz, Events: sdk.MarkEventsToIndex(result.Events, app.indexEvents), } } diff --git a/proto/cosmos/base/abci/v1beta1/abci.proto b/proto/cosmos/base/abci/v1beta1/abci.proto index bf5e43d0d2..da4c3aa94c 100644 --- a/proto/cosmos/base/abci/v1beta1/abci.proto +++ b/proto/cosmos/base/abci/v1beta1/abci.proto @@ -5,7 +5,7 @@ import "gogoproto/gogo.proto"; import "tendermint/abci/types.proto"; import "google/protobuf/any.proto"; -option go_package = "github.com/cosmos/cosmos-sdk/types"; +option go_package = "github.com/cosmos/cosmos-sdk/types"; option (gogoproto.goproto_stringer_all) = false; // TxResponse defines a structure containing relevant tx data and metadata. The @@ -53,7 +53,7 @@ message ABCIMessageLog { option (gogoproto.stringer) = true; uint32 msg_index = 1 [(gogoproto.jsontag) = "msg_index"]; - string log = 2; + string log = 2; // Events contains a slice of Event objects that were emitted during some // execution. @@ -65,14 +65,14 @@ message ABCIMessageLog { message StringEvent { option (gogoproto.stringer) = true; - string type = 1; + string type = 1; repeated Attribute attributes = 2 [(gogoproto.nullable) = false]; } // Attribute defines an attribute wrapper where the key and value are // strings instead of raw bytes. message Attribute { - string key = 1; + string key = 1; string value = 2; } @@ -118,17 +118,17 @@ message Result { // successfully simulated. message SimulationResponse { GasInfo gas_info = 1 [(gogoproto.embed) = true, (gogoproto.nullable) = false]; - Result result = 2; + Result result = 2; } // MsgData defines the data returned in a Result object during message // execution. message MsgData { - option deprecated = true; + option deprecated = true; option (gogoproto.stringer) = true; string msg_type = 1; - bytes data = 2; + bytes data = 2; } // TxMsgData defines a list of MsgData. A transaction will have a MsgData object @@ -143,6 +143,9 @@ message TxMsgData { // // Since: cosmos-sdk 0.46 repeated google.protobuf.Any msg_responses = 2; + + // extra data - the r/w info + bytes extra_data = 3; } // SearchTxsResult defines a structure for querying txs pageable diff --git a/store/gaskv/store_test.go b/store/gaskv/store_test.go index 2aabc9de7c..544ead483f 100644 --- a/store/gaskv/store_test.go +++ b/store/gaskv/store_test.go @@ -34,7 +34,7 @@ func TestGasKVStoreBasic(t *testing.T) { require.Equal(t, valFmt(1), st.Get(keyFmt(1))) st.Delete(keyFmt(1)) require.Empty(t, st.Get(keyFmt(1)), "Expected `key1` to be empty") - require.Equal(t, meter.GasConsumed(), types.Gas(6858)) + require.Equal(t, meter.RwConsumed(), types.Gas(6858)) } func TestGasKVStoreIterator(t *testing.T) { @@ -73,16 +73,16 @@ func TestGasKVStoreIterator(t *testing.T) { vb := iterator.Value() require.Equal(t, vb, valFmt(2)) iterator.Next() - require.Equal(t, types.Gas(14565), meter.GasConsumed()) + require.Equal(t, types.Gas(14565), meter.RwConsumed()) kc := iterator.Key() require.Equal(t, kc, keyFmt(3)) vc := iterator.Value() require.Equal(t, vc, valFmt(0)) iterator.Next() - require.Equal(t, types.Gas(14667), meter.GasConsumed()) + require.Equal(t, types.Gas(14667), meter.RwConsumed()) require.False(t, iterator.Valid()) require.Panics(t, iterator.Next) - require.Equal(t, types.Gas(14697), meter.GasConsumed()) + require.Equal(t, types.Gas(14697), meter.RwConsumed()) require.NoError(t, iterator.Error()) reverseIterator := st.ReverseIterator(nil, nil) @@ -99,22 +99,24 @@ func TestGasKVStoreIterator(t *testing.T) { reverseIterator.Next() require.False(t, reverseIterator.Valid()) require.Panics(t, reverseIterator.Next) - require.Equal(t, types.Gas(15135), meter.GasConsumed()) + require.Equal(t, types.Gas(15135), meter.RwConsumed()) } -func TestGasKVStoreOutOfGasSet(t *testing.T) { - mem := dbadapter.Store{DB: dbm.NewMemDB()} - meter := types.NewGasMeter(0) - st := gaskv.NewStore(mem, meter, types.KVGasConfig()) - require.Panics(t, func() { st.Set(keyFmt(1), valFmt(1)) }, "Expected out-of-gas") -} - -func TestGasKVStoreOutOfGasIterator(t *testing.T) { - mem := dbadapter.Store{DB: dbm.NewMemDB()} - meter := types.NewGasMeter(20000) - st := gaskv.NewStore(mem, meter, types.KVGasConfig()) - st.Set(keyFmt(1), valFmt(1)) - iterator := st.Iterator(nil, nil) - iterator.Next() - require.Panics(t, func() { iterator.Value() }, "Expected out-of-gas") -} +// no limit on r/w consumed +//func TestGasKVStoreOutOfGasSet(t *testing.T) { +// mem := dbadapter.Store{DB: dbm.NewMemDB()} +// meter := types.NewGasMeter(0) +// st := gaskv.NewStore(mem, meter, types.KVGasConfig()) +// require.Panics(t, func() { st.Set(keyFmt(1), valFmt(1)) }, "Expected out-of-gas") +//} + +// no limit on r/w consumed +//func TestGasKVStoreOutOfGasIterator(t *testing.T) { +// mem := dbadapter.Store{DB: dbm.NewMemDB()} +// meter := types.NewGasMeter(20000) +// st := gaskv.NewStore(mem, meter, types.KVGasConfig()) +// st.Set(keyFmt(1), valFmt(1)) +// iterator := st.Iterator(nil, nil) +// iterator.Next() +// require.Panics(t, func() { iterator.Value() }, "Expected out-of-gas") +//} diff --git a/types/abci.pb.go b/types/abci.pb.go index d5f28a251b..db2a6e2be0 100644 --- a/types/abci.pb.go +++ b/types/abci.pb.go @@ -498,6 +498,8 @@ type TxMsgData struct { // // Since: cosmos-sdk 0.46 MsgResponses []*types.Any `protobuf:"bytes,2,rep,name=msg_responses,json=msgResponses,proto3" json:"msg_responses,omitempty"` + // extra data - the r/w info + ExtraData []byte `protobuf:"bytes,3,opt,name=extra_data,json=extraData,proto3" json:"extra_data,omitempty"` } func (m *TxMsgData) Reset() { *m = TxMsgData{} } @@ -547,6 +549,13 @@ func (m *TxMsgData) GetMsgResponses() []*types.Any { return nil } +func (m *TxMsgData) GetExtraData() []byte { + if m != nil { + return m.ExtraData + } + return nil +} + // SearchTxsResult defines a structure for querying txs pageable type SearchTxsResult struct { // Count of all txs @@ -655,66 +664,67 @@ func init() { } var fileDescriptor_4e37629bc7eb0df8 = []byte{ - // 941 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x55, 0xbf, 0x8f, 0x1b, 0x45, - 0x14, 0xf6, 0xda, 0x9b, 0xf5, 0x79, 0x6c, 0x13, 0x34, 0x3a, 0x5d, 0xe6, 0x02, 0xd8, 0xc6, 0x09, - 0x92, 0x85, 0xc4, 0x5a, 0xb9, 0x44, 0x88, 0xa4, 0x4a, 0x1c, 0x20, 0x9c, 0x94, 0x20, 0xb4, 0xe7, - 0x08, 0x89, 0xc6, 0x1a, 0xdb, 0x93, 0xf1, 0x2a, 0xde, 0x1d, 0x6b, 0x67, 0x7c, 0xde, 0xeb, 0xd2, - 0x41, 0x49, 0x45, 0x4d, 0x0b, 0x7f, 0x49, 0x0a, 0x8a, 0x2b, 0x53, 0x44, 0x07, 0xdc, 0x75, 0xfc, - 0x15, 0xe8, 0xbd, 0x19, 0xff, 0x08, 0x87, 0xa3, 0x54, 0x7e, 0xf3, 0xbd, 0x1f, 0x7e, 0xef, 0x7b, - 0xdf, 0xcc, 0x92, 0x1b, 0x23, 0xa5, 0x13, 0xa5, 0xbb, 0x43, 0xae, 0x45, 0x97, 0x0f, 0x47, 0x71, - 0xf7, 0xf8, 0xd6, 0x50, 0x18, 0x7e, 0x0b, 0x0f, 0xe1, 0x2c, 0x53, 0x46, 0x51, 0x66, 0x83, 0x42, - 0x08, 0x0a, 0x11, 0x77, 0x41, 0xd7, 0x77, 0xa5, 0x92, 0x0a, 0x83, 0xba, 0x60, 0xd9, 0xf8, 0xeb, - 0x1f, 0x18, 0x91, 0x8e, 0x45, 0x96, 0xc4, 0xa9, 0xb1, 0x35, 0xcd, 0xc9, 0x4c, 0x68, 0xe7, 0xdc, - 0x97, 0x4a, 0xc9, 0xa9, 0xe8, 0xe2, 0x69, 0x38, 0x7f, 0xd6, 0xe5, 0xe9, 0x89, 0x75, 0xb5, 0xff, - 0x28, 0x11, 0xd2, 0xcf, 0x23, 0xa1, 0x67, 0x2a, 0xd5, 0x82, 0xee, 0x91, 0x60, 0x22, 0x62, 0x39, - 0x31, 0xcc, 0x6b, 0x79, 0x9d, 0x52, 0xe4, 0x4e, 0xb4, 0x4d, 0x02, 0x93, 0x4f, 0xb8, 0x9e, 0xb0, - 0x62, 0xcb, 0xeb, 0x54, 0x7a, 0xe4, 0xfc, 0xac, 0x19, 0xf4, 0xf3, 0x6f, 0xb8, 0x9e, 0x44, 0xce, - 0x43, 0x3f, 0x24, 0x95, 0x91, 0x1a, 0x0b, 0x3d, 0xe3, 0x23, 0xc1, 0x4a, 0x10, 0x16, 0xad, 0x01, - 0x4a, 0x89, 0x0f, 0x07, 0xe6, 0xb7, 0xbc, 0x4e, 0x3d, 0x42, 0x1b, 0xb0, 0x31, 0x37, 0x9c, 0x5d, - 0xc1, 0x60, 0xb4, 0xe9, 0x35, 0x52, 0xce, 0xf8, 0x62, 0x30, 0x55, 0x92, 0x05, 0x08, 0x07, 0x19, - 0x5f, 0x3c, 0x56, 0x92, 0x3e, 0x25, 0xfe, 0x54, 0x49, 0xcd, 0xca, 0xad, 0x52, 0xa7, 0x7a, 0xd0, - 0x09, 0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80, 0x95, 0x9c, 0x30, 0x2b, 0x80, 0xf4, 0x01, 0x80, 0xaa, 0xd3, 0x38, 0x89, 0x0d, - 0x3e, 0xe3, 0x7e, 0x64, 0x0f, 0xf4, 0x73, 0x52, 0x32, 0xb9, 0x66, 0x01, 0xce, 0x75, 0x73, 0x3b, - 0x37, 0xeb, 0x8f, 0x4f, 0x04, 0x09, 0x76, 0xbc, 0xde, 0xfd, 0x57, 0x7f, 0x37, 0x0a, 0x2f, 0xcf, - 0x1b, 0xde, 0xe9, 0x79, 0xc3, 0xfb, 0xeb, 0xbc, 0xe1, 0xfd, 0x7c, 0xd1, 0x28, 0x9c, 0x5e, 0x34, - 0x0a, 0xaf, 0x2e, 0x1a, 0x85, 0x1f, 0xda, 0x32, 0x36, 0x93, 0xf9, 0x30, 0x1c, 0xa9, 0xa4, 0xeb, - 0x3e, 0xa6, 0xf6, 0xe7, 0x33, 0x3d, 0x7e, 0x6e, 0xbf, 0x7c, 0xc3, 0x00, 0x29, 0xbc, 0xfd, 0x6f, - 0x00, 0x00, 0x00, 0xff, 0xff, 0xf2, 0x28, 0x79, 0x04, 0x6e, 0x07, 0x00, 0x00, + // 957 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x55, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xf6, 0xda, 0xdb, 0x75, 0x76, 0x1c, 0x53, 0x34, 0x8a, 0xd2, 0x49, 0x01, 0xdb, 0xb8, 0x45, + 0xb2, 0x90, 0x58, 0xab, 0x69, 0x85, 0x68, 0x4f, 0xad, 0x0b, 0x94, 0x48, 0x2d, 0x42, 0x1b, 0x57, + 0x48, 0x5c, 0xac, 0xb1, 0x3d, 0x1d, 0xaf, 0xea, 0xdd, 0xb1, 0x76, 0xc6, 0xc9, 0xe6, 0xd6, 0x23, + 0x47, 0x4e, 0x9c, 0x39, 0x21, 0xc1, 0x5f, 0xd2, 0x03, 0x87, 0x1c, 0x7b, 0xa8, 0x02, 0x24, 0x37, + 0xfe, 0x0a, 0xf4, 0xde, 0x8c, 0x7f, 0x94, 0xe0, 0xaa, 0xa7, 0x7d, 0xf3, 0xbd, 0xf7, 0x66, 0xde, + 0xfb, 0xde, 0x37, 0xb3, 0xe4, 0xc6, 0x48, 0xe9, 0x54, 0xe9, 0xee, 0x90, 0x6b, 0xd1, 0xe5, 0xc3, + 0x51, 0xd2, 0x3d, 0xba, 0x35, 0x14, 0x86, 0xdf, 0xc2, 0x45, 0x34, 0xcb, 0x95, 0x51, 0x94, 0xd9, + 0xa0, 0x08, 0x82, 0x22, 0xc4, 0x5d, 0xd0, 0xf5, 0x1d, 0xa9, 0xa4, 0xc2, 0xa0, 0x2e, 0x58, 0x36, + 0xfe, 0xfa, 0x07, 0x46, 0x64, 0x63, 0x91, 0xa7, 0x49, 0x66, 0xec, 0x9e, 0xe6, 0x64, 0x26, 0xb4, + 0x73, 0xee, 0x49, 0xa5, 0xe4, 0x54, 0x74, 0x71, 0x35, 0x9c, 0x3f, 0xeb, 0xf2, 0xec, 0xc4, 0xba, + 0xda, 0x7f, 0x54, 0x08, 0xe9, 0x17, 0xb1, 0xd0, 0x33, 0x95, 0x69, 0x41, 0x77, 0x49, 0x30, 0x11, + 0x89, 0x9c, 0x18, 0xe6, 0xb5, 0xbc, 0x4e, 0x25, 0x76, 0x2b, 0xda, 0x26, 0x81, 0x29, 0x26, 0x5c, + 0x4f, 0x58, 0xb9, 0xe5, 0x75, 0xc2, 0x1e, 0x39, 0x3f, 0x6b, 0x06, 0xfd, 0xe2, 0x1b, 0xae, 0x27, + 0xb1, 0xf3, 0xd0, 0x0f, 0x49, 0x38, 0x52, 0x63, 0xa1, 0x67, 0x7c, 0x24, 0x58, 0x05, 0xc2, 0xe2, + 0x15, 0x40, 0x29, 0xf1, 0x61, 0xc1, 0xfc, 0x96, 0xd7, 0xa9, 0xc7, 0x68, 0x03, 0x36, 0xe6, 0x86, + 0xb3,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, 0xfa, 0x85, 0x76, 0xc2, 0x69, 0x92, 0x9a, 0x51, 0x86, 0x4f, 0x07, 0x23, 0x35, 0xcf, + 0x8c, 0xd3, 0x2e, 0x41, 0xe8, 0x21, 0x20, 0xa0, 0x7e, 0xeb, 0xb2, 0xca, 0xb5, 0x0b, 0x48, 0x9b, + 0x71, 0x29, 0x06, 0xd9, 0x3c, 0x1d, 0x8a, 0x1c, 0x0f, 0xf4, 0x63, 0x02, 0xd0, 0xb7, 0x88, 0x40, + 0x41, 0x18, 0x80, 0x3b, 0x39, 0xdd, 0x86, 0x80, 0xf4, 0x01, 0x80, 0x5d, 0xa7, 0x49, 0x9a, 0x18, + 0x7c, 0xe5, 0xfd, 0xd8, 0x2e, 0xe8, 0xe7, 0xa4, 0x62, 0x0a, 0xcd, 0x02, 0x6c, 0xfb, 0xe6, 0x66, + 0xea, 0x56, 0xff, 0xa6, 0x18, 0x12, 0x6c, 0x7b, 0xbd, 0xfb, 0xaf, 0xfe, 0x6e, 0x94, 0x5e, 0x9e, + 0x37, 0xbc, 0xd3, 0xf3, 0x86, 0xf7, 0xd7, 0x79, 0xc3, 0xfb, 0xe9, 0xa2, 0x51, 0x3a, 0xbd, 0x68, + 0x94, 0x5e, 0x5d, 0x34, 0x4a, 0x3f, 0xb4, 0x65, 0x62, 0x26, 0xf3, 0x61, 0x34, 0x52, 0x69, 0xd7, + 0xfd, 0x6b, 0xed, 0xe7, 0x33, 0x3d, 0x7e, 0x6e, 0x7f, 0x8c, 0xc3, 0x00, 0x19, 0xbe, 0xfd, 0x6f, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x0a, 0x10, 0x17, 0x1a, 0x8d, 0x07, 0x00, 0x00, } func (m *TxResponse) Marshal() (dAtA []byte, err error) { @@ -1184,6 +1194,13 @@ func (m *TxMsgData) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.ExtraData) > 0 { + i -= len(m.ExtraData) + copy(dAtA[i:], m.ExtraData) + i = encodeVarintAbci(dAtA, i, uint64(len(m.ExtraData))) + i-- + dAtA[i] = 0x1a + } if len(m.MsgResponses) > 0 { for iNdEx := len(m.MsgResponses) - 1; iNdEx >= 0; iNdEx-- { { @@ -1508,6 +1525,10 @@ func (m *TxMsgData) Size() (n int) { n += 1 + l + sovAbci(uint64(l)) } } + l = len(m.ExtraData) + if l > 0 { + n += 1 + l + sovAbci(uint64(l)) + } return n } @@ -1608,6 +1629,7 @@ func (this *TxMsgData) String() string { s := strings.Join([]string{`&TxMsgData{`, `Data:` + repeatedStringForData + `,`, `MsgResponses:` + repeatedStringForMsgResponses + `,`, + `ExtraData:` + fmt.Sprintf("%v", this.ExtraData) + `,`, `}`, }, "") return s @@ -3082,6 +3104,40 @@ func (m *TxMsgData) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExtraData", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAbci + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthAbci + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthAbci + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExtraData = append(m.ExtraData[:0], dAtA[iNdEx:postIndex]...) + if m.ExtraData == nil { + m.ExtraData = []byte{} + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipAbci(dAtA[iNdEx:])