diff --git a/api/cosmos/base/abci/v1beta1/abci.pulsar.go b/api/cosmos/base/abci/v1beta1/abci.pulsar.go index 9b5ea1a430a8..afde15940d36 100644 --- a/api/cosmos/base/abci/v1beta1/abci.pulsar.go +++ b/api/cosmos/base/abci/v1beta1/abci.pulsar.go @@ -3511,6 +3511,7 @@ var ( fd_Result_log protoreflect.FieldDescriptor fd_Result_events protoreflect.FieldDescriptor fd_Result_msg_responses protoreflect.FieldDescriptor + fd_Result_evm_error protoreflect.FieldDescriptor ) func init() { @@ -3520,6 +3521,7 @@ func init() { fd_Result_log = md_Result.Fields().ByName("log") fd_Result_events = md_Result.Fields().ByName("events") fd_Result_msg_responses = md_Result.Fields().ByName("msg_responses") + fd_Result_evm_error = md_Result.Fields().ByName("evm_error") } var _ protoreflect.Message = (*fastReflection_Result)(nil) @@ -3611,6 +3613,12 @@ func (x *fastReflection_Result) Range(f func(protoreflect.FieldDescriptor, proto return } } + if x.EvmError != "" { + value := protoreflect.ValueOfString(x.EvmError) + if !f(fd_Result_evm_error, value) { + return + } + } } // Has reports whether a field is populated. @@ -3634,6 +3642,8 @@ func (x *fastReflection_Result) Has(fd protoreflect.FieldDescriptor) bool { return len(x.Events) != 0 case "cosmos.base.abci.v1beta1.Result.msg_responses": return len(x.MsgResponses) != 0 + case "cosmos.base.abci.v1beta1.Result.evm_error": + return x.EvmError != "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3658,6 +3668,8 @@ func (x *fastReflection_Result) Clear(fd protoreflect.FieldDescriptor) { x.Events = nil case "cosmos.base.abci.v1beta1.Result.msg_responses": x.MsgResponses = nil + case "cosmos.base.abci.v1beta1.Result.evm_error": + x.EvmError = "" default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3692,6 +3704,9 @@ func (x *fastReflection_Result) Get(descriptor protoreflect.FieldDescriptor) pro } listValue := &_Result_4_list{list: &x.MsgResponses} return protoreflect.ValueOfList(listValue) + case "cosmos.base.abci.v1beta1.Result.evm_error": + value := x.EvmError + return protoreflect.ValueOfString(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3724,6 +3739,8 @@ func (x *fastReflection_Result) Set(fd protoreflect.FieldDescriptor, value proto lv := value.List() clv := lv.(*_Result_4_list) x.MsgResponses = *clv.list + case "cosmos.base.abci.v1beta1.Result.evm_error": + x.EvmError = value.Interface().(string) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3760,6 +3777,8 @@ func (x *fastReflection_Result) Mutable(fd protoreflect.FieldDescriptor) protore panic(fmt.Errorf("field data of message cosmos.base.abci.v1beta1.Result is not mutable")) case "cosmos.base.abci.v1beta1.Result.log": panic(fmt.Errorf("field log of message cosmos.base.abci.v1beta1.Result is not mutable")) + case "cosmos.base.abci.v1beta1.Result.evm_error": + panic(fmt.Errorf("field evm_error of message cosmos.base.abci.v1beta1.Result is not mutable")) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3783,6 +3802,8 @@ func (x *fastReflection_Result) NewField(fd protoreflect.FieldDescriptor) protor case "cosmos.base.abci.v1beta1.Result.msg_responses": list := []*anypb.Any{} return protoreflect.ValueOfList(&_Result_4_list{list: &list}) + case "cosmos.base.abci.v1beta1.Result.evm_error": + return protoreflect.ValueOfString("") default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.base.abci.v1beta1.Result")) @@ -3872,6 +3893,10 @@ func (x *fastReflection_Result) ProtoMethods() *protoiface.Methods { n += 1 + l + runtime.Sov(uint64(l)) } } + l = len(x.EvmError) + if l > 0 { + n += 1 + l + runtime.Sov(uint64(l)) + } if x.unknownFields != nil { n += len(x.unknownFields) } @@ -3901,6 +3926,13 @@ func (x *fastReflection_Result) ProtoMethods() *protoiface.Methods { i -= len(x.unknownFields) copy(dAtA[i:], x.unknownFields) } + if len(x.EvmError) > 0 { + i -= len(x.EvmError) + copy(dAtA[i:], x.EvmError) + i = runtime.EncodeVarint(dAtA, i, uint64(len(x.EvmError))) + i-- + dAtA[i] = 0x2a + } if len(x.MsgResponses) > 0 { for iNdEx := len(x.MsgResponses) - 1; iNdEx >= 0; iNdEx-- { encoded, err := options.Marshal(x.MsgResponses[iNdEx]) @@ -4130,6 +4162,38 @@ func (x *fastReflection_Result) ProtoMethods() *protoiface.Methods { return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, err } iNdEx = postIndex + case 5: + if wireType != 2 { + return protoiface.UnmarshalOutput{NoUnkeyedLiterals: input.NoUnkeyedLiterals, Flags: input.Flags}, fmt.Errorf("proto: wrong wireType = %d for field EvmError", 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.EvmError = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := runtime.Skip(dAtA[iNdEx:]) @@ -7644,6 +7708,8 @@ type Result struct { // // Since: cosmos-sdk 0.46 MsgResponses []*anypb.Any `protobuf:"bytes,4,rep,name=msg_responses,json=msgResponses,proto3" json:"msg_responses,omitempty"` + // EVM VM error during execution + EvmError string `protobuf:"bytes,5,opt,name=evm_error,json=evmError,proto3" json:"evm_error,omitempty"` } func (x *Result) Reset() { @@ -7695,6 +7761,13 @@ func (x *Result) GetMsgResponses() []*anypb.Any { return nil } +func (x *Result) GetEvmError() string { + if x != nil { + return x.EvmError + } + return "" +} + // SimulationResponse defines the response generated when a transaction is // successfully simulated. type SimulationResponse struct { @@ -8071,7 +8144,7 @@ var file_cosmos_base_abci_v1beta1_abci_proto_rawDesc = []byte{ 0x73, 0x5f, 0x77, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x67, 0x61, 0x73, 0x57, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x61, 0x73, - 0x55, 0x73, 0x65, 0x64, 0x22, 0xa9, 0x01, 0x0a, 0x06, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, + 0x55, 0x73, 0x65, 0x64, 0x22, 0xc6, 0x01, 0x0a, 0x06, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x16, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x42, 0x02, 0x18, 0x01, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x6c, 0x6f, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6c, 0x6f, 0x67, 0x12, 0x34, 0x0a, 0x06, 0x65, 0x76, 0x65, @@ -8081,73 +8154,74 @@ var file_cosmos_base_abci_v1beta1_abci_proto_rawDesc = []byte{ 0x39, 0x0a, 0x0d, 0x6d, 0x73, 0x67, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x73, 0x18, 0x04, 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, 0x88, 0xa0, 0x1f, 0x00, - 0x22, 0x96, 0x01, 0x0a, 0x12, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x46, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x69, - 0x6e, 0x66, 0x6f, 0x18, 0x01, 0x20, 0x01, 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, 0x61, 0x31, 0x2e, 0x47, 0x61, 0x73, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x08, 0xc8, 0xde, - 0x1f, 0x00, 0xd0, 0xde, 0x1f, 0x01, 0x52, 0x07, 0x67, 0x61, 0x73, 0x49, 0x6e, 0x66, 0x6f, 0x12, - 0x38, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x20, 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, 0x52, 0x65, 0x73, 0x75, 0x6c, - 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x40, 0x0a, 0x07, 0x4d, 0x73, 0x67, - 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, - 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, - 0x61, 0x31, 0x2e, 0x4d, 0x73, 0x67, 0x44, 0x61, 0x74, 0x61, 0x42, 0x02, 0x18, 0x01, 0x52, 0x04, - 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, 0x22, 0xd8, 0x01, 0x0a, 0x12, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 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, 0x03, - 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, 0x03, 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, 0x03, 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, 0x03, 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, - 0x03, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x2f, 0x0a, 0x06, 0x62, 0x6c, 0x6f, 0x63, - 0x6b, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x74, 0x65, 0x6e, 0x64, 0x65, - 0x72, 0x6d, 0x69, 0x6e, 0x74, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x52, 0x06, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 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, + 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x65, 0x76, + 0x6d, 0x5f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x65, + 0x76, 0x6d, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x3a, 0x04, 0x88, 0xa0, 0x1f, 0x00, 0x22, 0x96, 0x01, + 0x0a, 0x12, 0x53, 0x69, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x46, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x69, 0x6e, 0x66, 0x6f, + 0x18, 0x01, 0x20, 0x01, 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, 0x61, + 0x31, 0x2e, 0x47, 0x61, 0x73, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x08, 0xc8, 0xde, 0x1f, 0x00, 0xd0, + 0xde, 0x1f, 0x01, 0x52, 0x07, 0x67, 0x61, 0x73, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x38, 0x0a, 0x06, + 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 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, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x06, + 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x40, 0x0a, 0x07, 0x4d, 0x73, 0x67, 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, 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, 0x61, 0x31, 0x2e, + 0x4d, 0x73, 0x67, 0x44, 0x61, 0x74, 0x61, 0x42, 0x02, 0x18, 0x01, 0x52, 0x04, 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, 0x22, 0xd8, 0x01, 0x0a, 0x12, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x42, 0x6c, 0x6f, 0x63, + 0x6b, 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, 0x03, 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, 0x03, 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, 0x03, 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, 0x03, 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, 0x03, 0x52, 0x05, + 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x2f, 0x0a, 0x06, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x73, 0x18, + 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x74, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x6d, 0x69, + 0x6e, 0x74, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x06, + 0x62, 0x6c, 0x6f, 0x63, 0x6b, 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/noopgasmeter.go b/baseapp/noopgasmeter.go index c341bcbe7b11..a91388871a42 100644 --- a/baseapp/noopgasmeter.go +++ b/baseapp/noopgasmeter.go @@ -6,12 +6,13 @@ type noopGasMeter struct{} var _ storetypes.GasMeter = noopGasMeter{} -func (noopGasMeter) GasConsumed() storetypes.Gas { return 0 } -func (noopGasMeter) GasConsumedToLimit() storetypes.Gas { return 0 } -func (noopGasMeter) GasRemaining() storetypes.Gas { return 0 } -func (noopGasMeter) Limit() storetypes.Gas { return 0 } -func (noopGasMeter) ConsumeGas(storetypes.Gas, string) {} -func (noopGasMeter) RefundGas(storetypes.Gas, string) {} -func (noopGasMeter) IsPastLimit() bool { return false } -func (noopGasMeter) IsOutOfGas() bool { return false } -func (noopGasMeter) String() string { return "noopGasMeter" } +func (noopGasMeter) GasConsumed() storetypes.Gas { return 0 } +func (noopGasMeter) GasConsumedToLimit() storetypes.Gas { return 0 } +func (noopGasMeter) GasRemaining() storetypes.Gas { return 0 } +func (noopGasMeter) Limit() storetypes.Gas { return 0 } +func (noopGasMeter) ConsumeGas(storetypes.Gas, string) {} +func (noopGasMeter) RefundGas(storetypes.Gas, string) {} +func (noopGasMeter) IsPastLimit() bool { return false } +func (noopGasMeter) IsOutOfGas() bool { return false } +func (noopGasMeter) String() string { return "noopGasMeter" } +func (noopGasMeter) Multiplier() (numerator uint64, denominator uint64) { return 1, 1 } diff --git a/client/context.go b/client/context.go index d73d72e21543..24dfe5c9fd8e 100644 --- a/client/context.go +++ b/client/context.go @@ -8,6 +8,7 @@ import ( "io" "os" + rpcclient "github.com/cometbft/cometbft/rpc/client" "github.com/cosmos/gogoproto/proto" "github.com/spf13/viper" "google.golang.org/grpc" @@ -26,7 +27,7 @@ type PreprocessTxFn func(chainID string, key keyring.KeyType, tx TxBuilder) erro // handling and queries. type Context struct { FromAddress sdk.AccAddress - Client CometRPC + Client rpcclient.Client GRPCClient *grpc.ClientConn ChainID string Codec codec.Codec @@ -140,7 +141,7 @@ func (ctx Context) WithHeight(height int64) Context { // WithClient returns a copy of the context with an updated RPC client // instance. -func (ctx Context) WithClient(client CometRPC) Context { +func (ctx Context) WithClient(client rpcclient.Client) Context { ctx.Client = client return ctx } diff --git a/go.mod b/go.mod index 87677ef1c945..8d13cc482113 100644 --- a/go.mod +++ b/go.mod @@ -2,6 +2,14 @@ go 1.21 module github.com/cosmos/cosmos-sdk +replace ( + cosmossdk.io/store => ./store + // reece/evm-v50s + github.com/cometbft/cometbft => /home/reece/Desktop/Programming/Go/cometbft + + github.com/ethereum/go-ethereum => github.com/sei-protocol/go-ethereum v1.13.5-sei-22 +) + require ( cosmossdk.io/api v0.7.5 cosmossdk.io/collections v0.4.0 @@ -14,7 +22,7 @@ require ( cosmossdk.io/x/tx v0.13.3 github.com/99designs/keyring v1.2.1 github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 - github.com/bits-and-blooms/bitset v1.8.0 + github.com/bits-and-blooms/bitset v1.10.0 github.com/chzyer/readline v1.5.1 github.com/cockroachdb/apd/v2 v2.0.2 github.com/cockroachdb/errors v1.11.1 @@ -27,6 +35,7 @@ require ( github.com/cosmos/gogoproto v1.4.12 github.com/cosmos/ledger-cosmos-go v0.13.3 github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 + github.com/ethereum/go-ethereum v1.13.2 github.com/golang/mock v1.6.0 github.com/golang/protobuf v1.5.4 github.com/google/go-cmp v0.6.0 @@ -80,8 +89,11 @@ require ( github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/cometbft/cometbft-db v0.9.1 // indirect + github.com/consensys/bavard v0.1.13 // indirect + github.com/consensys/gnark-crypto v0.12.1 // indirect github.com/cosmos/iavl v1.1.2 // indirect github.com/cosmos/ics23/go v0.10.0 // indirect + github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect @@ -91,6 +103,7 @@ require ( github.com/dustin/go-humanize v1.0.1 // indirect github.com/dvsekhvalnov/jose2go v1.6.0 // indirect github.com/emicklei/dot v1.6.1 // indirect + github.com/ethereum/c-kzg-4844 v0.4.0 // indirect github.com/fatih/color v1.15.0 // indirect github.com/felixge/httpsnoop v1.0.2 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect @@ -102,7 +115,7 @@ require ( github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/glog v1.2.0 // indirect - github.com/golang/snappy v0.0.4 // indirect + github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb // indirect github.com/google/btree v1.1.2 // indirect github.com/google/orderedcode v0.0.1 // indirect github.com/gorilla/websocket v1.5.0 // indirect @@ -110,8 +123,10 @@ require ( github.com/hashicorp/go-hclog v1.5.0 // indirect github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/go-plugin v1.5.2 // indirect + github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect github.com/hashicorp/hcl v1.0.0 // indirect github.com/hashicorp/yamux v0.1.1 // indirect + github.com/holiman/uint256 v1.2.4 // indirect github.com/iancoleman/strcase v0.3.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect @@ -119,12 +134,12 @@ require ( github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect github.com/lib/pq v1.10.7 // indirect - github.com/libp2p/go-buffer-pool v0.1.0 // indirect github.com/linxGnu/grocksdb v1.8.14 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/minio/highwayhash v1.0.2 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/mmcloughlin/addchain v0.4.0 // indirect github.com/mtibben/percent v0.2.1 // indirect github.com/nxadm/tail v1.4.8 // indirect github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect @@ -144,6 +159,7 @@ require ( github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/afero v1.11.0 // indirect github.com/subosito/gotenv v1.6.0 // indirect + github.com/supranational/blst v0.3.11 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect github.com/tidwall/btree v1.7.0 // indirect github.com/zondax/hid v0.9.2 // indirect @@ -159,6 +175,7 @@ require ( gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect + rsc.io/tmplfunc v0.0.3 // indirect ) // Here are the short-lived replace from the Cosmos SDK diff --git a/go.sum b/go.sum index d31f4a5f6e75..a44e3f3da83b 100644 --- a/go.sum +++ b/go.sum @@ -14,8 +14,6 @@ cosmossdk.io/log v1.3.1 h1:UZx8nWIkfbbNEWusZqzAx3ZGvu54TZacWib3EzUYmGI= cosmossdk.io/log v1.3.1/go.mod h1:2/dIomt8mKdk6vl3OWJcPk2be3pGOS8OQaLUM/3/tCM= cosmossdk.io/math v1.3.0 h1:RC+jryuKeytIiictDslBP9i1fhkVm6ZDmZEoNP316zE= cosmossdk.io/math v1.3.0/go.mod h1:vnRTxewy+M7BtXBNFybkuhSH4WfedVAAnERHgVFhp3k= -cosmossdk.io/store v1.1.0 h1:LnKwgYMc9BInn9PhpTFEQVbL9UK475G2H911CGGnWHk= -cosmossdk.io/store v1.1.0/go.mod h1:oZfW/4Fc/zYqu3JmQcQdUJ3fqu5vnYTn3LZFFy8P8ng= cosmossdk.io/x/tx v0.13.3 h1:Ha4mNaHmxBc6RMun9aKuqul8yHiL78EKJQ8g23Zf73g= cosmossdk.io/x/tx v0.13.3/go.mod h1:I8xaHv0rhUdIvIdptKIqzYy27+n2+zBVaxO6fscFhys= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= @@ -40,6 +38,10 @@ 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/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= +github.com/StackExchange/wmi v1.2.1 h1:VIkavFPXSjcnS+O8yTq7NI32k0R5Aj+v39y29VYDOSA= +github.com/StackExchange/wmi v1.2.1/go.mod h1:rcmrprowKIVzvc+NUiLncP2uuArMWLCbu9SBzvHz7e8= +github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= +github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= github.com/adlio/schema v1.3.3 h1:oBJn8I02PyTB466pZO1UZEn1TV5XLlifBSyMrmHl/1I= @@ -69,8 +71,8 @@ github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6r 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/bits-and-blooms/bitset v1.8.0 h1:FD+XqgOZDUxxZ8hzoBFuV9+cGWY9CslN6d5MS5JVb4c= -github.com/bits-and-blooms/bitset v1.8.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/bits-and-blooms/bitset v1.10.0 h1:ePXTeiPEazB5+opbv5fr8umg2R/1NlzgDsyepwsSr88= +github.com/bits-and-blooms/bitset v1.10.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= 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.3 h1:xfbtw8lwpp0G6NwSHb+UE67ryTFHJAiNuipusjXSohQ= @@ -133,10 +135,12 @@ github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZ github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/cometbft/cometbft v0.38.7 h1:ULhIOJ9+LgSy6nLekhq9ae3juX3NnQUMMPyVdhZV6Hk= -github.com/cometbft/cometbft v0.38.7/go.mod h1:HIyf811dFMI73IE0F7RrnY/Fr+d1+HuJAgtkEpQjCMY= github.com/cometbft/cometbft-db v0.9.1 h1:MIhVX5ja5bXNHF8EYrThkG9F7r9kSfv8BX4LWaxWJ4M= github.com/cometbft/cometbft-db v0.9.1/go.mod h1:iliyWaoV0mRwBJoizElCwwRA9Tf7jZJOURcRZF9m60U= +github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/YjhQ= +github.com/consensys/bavard v0.1.13/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= +github.com/consensys/gnark-crypto v0.12.1 h1:lHH39WuuFgVHONRl3J0LRBtuYdQTumFSDtJF7HpyG8M= +github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -169,6 +173,10 @@ github.com/cosmos/ledger-cosmos-go v0.13.3/go.mod h1:HENcEP+VtahZFw38HZ3+LS3Iv5X github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/crate-crypto/go-ipa v0.0.0-20231025140028-3c0104f4b233 h1:d28BXYi+wUpz1KBmiF9bWrjEMacUEREV6MBi2ODnrfQ= +github.com/crate-crypto/go-ipa v0.0.0-20231025140028-3c0104f4b233/go.mod h1:geZJZH3SzKCqnz5VT0q/DyIG/tvu/dZk+VIfXicupJs= +github.com/crate-crypto/go-kzg-4844 v0.7.0 h1:C0vgZRk4q4EZ/JgPfzuSoxdCq3C3mOZMBShovmncxvA= +github.com/crate-crypto/go-kzg-4844 v0.7.0/go.mod h1:1kMhvPgI0Ky3yIa+9lFySEBUBXkYxeOi8ZF1sYioxhc= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= @@ -215,6 +223,8 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY= +github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= @@ -234,6 +244,8 @@ github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nos github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/gabriel-vasile/mimetype v1.4.2 h1:w5qFW6JKBz9Y393Y4q372O9A7cUSequkh1Q7OhCmWKU= github.com/gabriel-vasile/mimetype v1.4.2/go.mod h1:zApsH/mKG4w07erKIaJPFiX0Tsq9BFQgN3qGY5GnNgA= +github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 h1:BAIP2GihuqhwdILrV+7GJel5lyPV3u1+PgzrWLc0TkE= +github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46/go.mod h1:QNpY22eby74jVhqH4WhDLDwxc/vqsern6pW+u2kbkpc= github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= @@ -257,6 +269,8 @@ 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.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= +github.com/go-ole/go-ole v1.2.5 h1:t4MGB5xEDZvXI+0rMjjsfBsD7yAgp/s9ZDkL1JndXwY= +github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= @@ -277,6 +291,8 @@ github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MG github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= +github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= +github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= github.com/gogo/googleapis v1.4.1 h1:1Yx4Myt7BxzvUr5ldGSbwYiZG6t9wGBZ+8/fX3Wvtq0= @@ -316,8 +332,9 @@ github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 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/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= +github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 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= @@ -339,6 +356,7 @@ github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/ github.com/google/orderedcode v0.0.1 h1:UzfcAexk9Vhv8+9pNOgRu41f16lHq725vPwnSeiG/Us= github.com/google/orderedcode v0.0.1/go.mod h1:iVyU4/qPKHY5h/wSd6rZZCDcLJNxiWO6dvsYES2Sb20= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= +github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= @@ -392,6 +410,8 @@ github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v1.0.2 h1:dV3g9Z/unq5DpblPpw+Oqcv4dU/1omnb4Ok8iPY6p1c= github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= +github.com/hashicorp/golang-lru/v2 v2.0.7/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= @@ -402,6 +422,8 @@ github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE github.com/hashicorp/yamux v0.1.1/go.mod h1:CtWFDAQgb7dxtzFs4tWbplKIe2jSi3+5vKbgIO0SLnQ= github.com/hdevalence/ed25519consensus v0.1.0 h1:jtBwzzcHuTmFrQN6xQZn6CQEO/V9f7HsjsjeEZ6auqU= github.com/hdevalence/ed25519consensus v0.1.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= +github.com/holiman/uint256 v1.2.4 h1:jUc4Nk8fm9jZabQuqr2JzednajVmBpC+oiTiXZJEApU= +github.com/holiman/uint256 v1.2.4/go.mod h1:EOMSn4q6Nyt9P6efbI3bueV4e1b3dGlUCXeiRV4ng7E= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= @@ -455,12 +477,14 @@ 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/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= +github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= +github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= +github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= github.com/lib/pq v1.10.7/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= -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/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/linxGnu/grocksdb v1.8.14 h1:HTgyYalNwBSG/1qCQUIott44wU5b2Y9Kr3z7SK5OfGQ= @@ -485,6 +509,8 @@ github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= +github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU= +github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= @@ -501,6 +527,9 @@ github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:F github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= +github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= +github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -532,6 +561,8 @@ github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQ github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= +github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= +github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= @@ -621,6 +652,8 @@ github.com/prometheus/procfs v0.13.0/go.mod h1:cd4PFCR54QLnGKPaKGA6l+cfuNXtht43Z github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= +github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= +github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= 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= @@ -645,6 +678,10 @@ github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0 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/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= +github.com/sei-protocol/go-ethereum v1.13.5-sei-22 h1:t/m1qXER+DEMrcpqgoYmUxifkAdmz5T8xpL9KRVgLtw= +github.com/sei-protocol/go-ethereum v1.13.5-sei-22/go.mod h1:kcRZmuzRn1lVejiFNTz4l4W7imnpq1bDAnuKS/RyhbQ= +github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU= +github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= 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= @@ -705,12 +742,18 @@ github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsT github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= +github.com/supranational/blst v0.3.11 h1:LyU6FolezeWAhvQk0k6O/d49jqgO52MSDDfYgbeoEm4= +github.com/supranational/blst v0.3.11/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= 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/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= +github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= +github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= +github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= +github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= @@ -1032,6 +1075,8 @@ gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= @@ -1047,6 +1092,8 @@ nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0 pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= +rsc.io/tmplfunc v0.0.3 h1:53XFQh69AfOa8Tw0Jm7t+GV7KZhOi6jzsCzTtKbMvzU= +rsc.io/tmplfunc v0.0.3/go.mod h1:AG3sTPzElb1Io3Yg4voV9AGZJuleGAwaVRxL9M49PhA= sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/proto/cosmos/base/abci/v1beta1/abci.proto b/proto/cosmos/base/abci/v1beta1/abci.proto index 9e3b4e55dbc7..6d24e847266d 100644 --- a/proto/cosmos/base/abci/v1beta1/abci.proto +++ b/proto/cosmos/base/abci/v1beta1/abci.proto @@ -107,6 +107,9 @@ message Result { // // Since: cosmos-sdk 0.46 repeated google.protobuf.Any msg_responses = 4; + + // EVM VM error during execution + string evm_error = 5; } // SimulationResponse defines the response generated when a transaction is diff --git a/store/cachekv/store.go b/store/cachekv/store.go index 08cfc2b325f6..89d3fe5d7c5a 100644 --- a/store/cachekv/store.go +++ b/store/cachekv/store.go @@ -406,3 +406,7 @@ func (store *Store) setCacheValue(key, value []byte, dirty bool) { store.unsortedCache[keyStr] = struct{}{} } } + +func (store *Store) GetParent() types.KVStore { + return store.parent +} diff --git a/store/types/evm_gas.go b/store/types/evm_gas.go new file mode 100644 index 000000000000..8d293748912d --- /dev/null +++ b/store/types/evm_gas.go @@ -0,0 +1,87 @@ +package types + +// TODO: ideally get this into sdk types instead of the cosmossdk.io/store/types package + +type multiplierGasMeter struct { + basicGasMeter + multiplierNumerator uint64 + multiplierDenominator uint64 +} + +func NewMultiplierGasMeter(limit Gas, multiplierNumerator uint64, multiplierDenominator uint64) GasMeter { + return &multiplierGasMeter{ + basicGasMeter: basicGasMeter{ + limit: limit, + consumed: 0, + // lock: &sync.Mutex{}, + }, + multiplierNumerator: multiplierNumerator, + multiplierDenominator: multiplierDenominator, + } +} + +func (g *multiplierGasMeter) adjustGas(original Gas) Gas { + return original * g.multiplierNumerator / g.multiplierDenominator +} + +func (g *multiplierGasMeter) ConsumeGas(amount Gas, descriptor string) { + g.basicGasMeter.ConsumeGas(g.adjustGas(amount), descriptor) +} + +func (g *multiplierGasMeter) RefundGas(amount Gas, descriptor string) { + g.basicGasMeter.RefundGas(g.adjustGas(amount), descriptor) +} + +func (g *multiplierGasMeter) Multiplier() (numerator uint64, denominator uint64) { + return g.multiplierNumerator, g.multiplierDenominator +} + +type infiniteMultiplierGasMeter struct { + infiniteGasMeter + multiplierNumerator uint64 + multiplierDenominator uint64 +} + +func NewInfiniteMultiplierGasMeter(multiplierNumerator uint64, multiplierDenominator uint64) GasMeter { + return &infiniteMultiplierGasMeter{ + infiniteGasMeter: infiniteGasMeter{ + consumed: 0, + // lock: &sync.Mutex{}, + }, + multiplierNumerator: multiplierNumerator, + multiplierDenominator: multiplierDenominator, + } +} + +func (g *infiniteMultiplierGasMeter) adjustGas(original Gas) Gas { + return original * g.multiplierNumerator / g.multiplierDenominator +} + +func (g *infiniteMultiplierGasMeter) ConsumeGas(amount Gas, descriptor string) { + g.infiniteGasMeter.ConsumeGas(g.adjustGas(amount), descriptor) +} + +func (g *infiniteMultiplierGasMeter) RefundGas(amount Gas, descriptor string) { + g.infiniteGasMeter.RefundGas(g.adjustGas(amount), descriptor) +} + +func (g *infiniteMultiplierGasMeter) Multiplier() (numerator uint64, denominator uint64) { + return g.multiplierNumerator, g.multiplierDenominator +} + +// Helpers for setting gas meter with parent ctx multiplier +func NewGasMeterWithMultiplier(ctxGasMeter GasMeter, limit uint64) GasMeter { + if ctxGasMeter == nil { + return NewGasMeter(limit) + } + n, d := ctxGasMeter.Multiplier() + return NewMultiplierGasMeter(limit, n, d) +} + +func NewInfiniteGasMeterWithMultiplier(ctxGasMeter GasMeter) GasMeter { + if ctxGasMeter == nil { + return NewInfiniteGasMeter() + } + n, d := ctxGasMeter.Multiplier() + return NewInfiniteMultiplierGasMeter(n, d) +} diff --git a/store/types/gas.go b/store/types/gas.go index baceb7ce2544..ad452a144cb1 100644 --- a/store/types/gas.go +++ b/store/types/gas.go @@ -48,19 +48,22 @@ type GasMeter interface { IsPastLimit() bool IsOutOfGas() bool String() string + Multiplier() (numerator uint64, denominator uint64) // EVM } type basicGasMeter struct { limit Gas consumed Gas + // lock *sync.Mutex // TODO: for evm? or is this a sei parallel thing? } // NewGasMeter returns a reference to a new basicGasMeter. func NewGasMeter(limit Gas) GasMeter { - return &basicGasMeter{ - limit: limit, - consumed: 0, - } + return NewMultiplierGasMeter(limit, 1, 1) +} + +func (g *basicGasMeter) Multiplier() (numerator uint64, denominator uint64) { + return 1, 1 } // GasConsumed returns the gas consumed from the GasMeter. @@ -157,6 +160,11 @@ func NewInfiniteGasMeter() GasMeter { } } +// Multiplier implements GasMeter. +func (g *infiniteGasMeter) Multiplier() (numerator uint64, denominator uint64) { + return 1, 1 +} + // GasConsumed returns the gas consumed from the GasMeter. func (g *infiniteGasMeter) GasConsumed() Gas { return g.consumed diff --git a/types/abci.pb.go b/types/abci.pb.go index 5f4da7f089d1..487b8c5cc1a3 100644 --- a/types/abci.pb.go +++ b/types/abci.pb.go @@ -337,6 +337,8 @@ type Result struct { // // Since: cosmos-sdk 0.46 MsgResponses []*types.Any `protobuf:"bytes,4,rep,name=msg_responses,json=msgResponses,proto3" json:"msg_responses,omitempty"` + // EVM VM error during execution + EvmError string `protobuf:"bytes,5,opt,name=evm_error,json=evmError,proto3" json:"evm_error,omitempty"` } func (m *Result) Reset() { *m = Result{} } @@ -729,68 +731,69 @@ func init() { } var fileDescriptor_4e37629bc7eb0df8 = []byte{ - // 968 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0x4f, 0x6f, 0x1b, 0xb7, - 0x13, 0xd5, 0x6a,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d, 0x99, 0x98, 0xd1, 0xb4, 0x1f, 0x0d, 0x54, 0xda, 0x76, 0xff, 0x07, 0xd8, 0x3f, 0x1f, - 0xeb, 0xe1, 0x91, 0x7d, 0x9c, 0xfb, 0x21, 0xba, 0xe3, 0xe1, 0xdf, 0x01, 0x00, 0x00, 0xff, 0xff, - 0x4d, 0x51, 0x55, 0xd9, 0x29, 0x08, 0x00, 0x00, + // 988 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x56, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xf6, 0x7a, 0xb7, 0xeb, 0xec, 0x38, 0xa6, 0x68, 0x14, 0x25, 0x9b, 0xb6, 0xd8, 0xc6, 0x2d, + 0x92, 0x85, 0xc4, 0x5a, 0x4d, 0x2b, 0x44, 0x7b, 0x6a, 0x1d, 0x0a, 0x44, 0x6a, 0x39, 0x6c, 0x5c, + 0x21, 0x71, 0xb1, 0xc6, 0xf6, 0x74, 0xbc, 0x8a, 0x77, 0xc7, 0xda, 0x19, 0x3b, 0xce, 0x8d, 0x1b, + 0x1c, 0x39, 0x71, 0xe6, 0x0a, 0x7f, 0x08, 0xea, 0x81, 0x43, 0x8e, 0x39, 0x54, 0x01, 0x92, 0x1b, + 0x7f, 0x05, 0x7a, 0x6f, 0xc6, 0x3f, 0x4a, 0x70, 0xe8, 0x29, 0xf3, 0xbe, 0xf7, 0x66, 0xfc, 0xbe, + 0xef, 0x7d, 0xb3, 0x13, 0x72, 0xb7, 0x2f, 0x55, 0x2a, 0x55, 0xab, 0xc7, 0x14, 0x6f, 0xb1, 0x5e, + 0x3f, 0x69, 0x4d, 0xef, 0xf7, 0xb8, 0x66, 0xf7, 0x31, 0x88, 0xc6, 0xb9, 0xd4, 0x92, 0x86, 0xa6, + 0x28, 0x82, 0xa2, 0x08, 0x71, 0x5b, 0x74, 0x6b, 0x4b, 0x48, 0x21, 0xb1, 0xa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0x6b, 0xb3, 0x7c, 0x5b, 0x62, 0xd8, 0x60, 0xe9, 0x9d, 0x81, 0x87, 0x90, 0x5e, + 0x1b, 0x9e, 0xa9, 0x6b, 0x18, 0xba, 0xeb, 0x19, 0xba, 0xd7, 0x30, 0x74, 0xff, 0x87, 0xa1, 0xbb, + 0x96, 0xa1, 0x3b, 0x67, 0xd8, 0x22, 0x3e, 0xbe, 0xa1, 0x73, 0x92, 0x3b, 0xab, 0x77, 0xcf, 0xbc, + 0xbd, 0xd8, 0x7c, 0x6c, 0xcb, 0x0c, 0xb5, 0xf6, 0x93, 0xb3, 0xbf, 0xaa, 0x85, 0xd7, 0x17, 0x55, + 0xe7, 0xf4, 0xa2, 0xea, 0xfc, 0x79, 0x51, 0x75, 0x7e, 0xbc, 0xac, 0x16, 0x4e, 0x2f, 0xab, 0x85, + 0xb3, 0xcb, 0x6a, 0xe1, 0xdb, 0x86, 0x48, 0xf4, 0x70, 0xd2, 0x8b, 0xfa, 0x32, 0x6d, 0xd9, 0x7f, + 0x12, 0xcc, 0x9f, 0x4f, 0xd4, 0xe0, 0xc8, 0xbc, 0xdc, 0x3d, 0x1f, 0xdd, 0xf1, 0xe0, 0x9f, 0x00, + 0x00, 0x00, 0xff, 0xff, 0x01, 0xd5, 0x9e, 0xdd, 0x46, 0x08, 0x00, 0x00, } func (m *TxResponse) Marshal() (dAtA []byte, err error) { @@ -1101,6 +1104,13 @@ func (m *Result) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.EvmError) > 0 { + i -= len(m.EvmError) + copy(dAtA[i:], m.EvmError) + i = encodeVarintAbci(dAtA, i, uint64(len(m.EvmError))) + i-- + dAtA[i] = 0x2a + } if len(m.MsgResponses) > 0 { for iNdEx := len(m.MsgResponses) - 1; iNdEx >= 0; iNdEx-- { { @@ -1574,6 +1584,10 @@ func (m *Result) Size() (n int) { n += 1 + l + sovAbci(uint64(l)) } } + l = len(m.EvmError) + if l > 0 { + n += 1 + l + sovAbci(uint64(l)) + } return n } @@ -2847,6 +2861,38 @@ func (m *Result) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EvmError", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAbci + } + 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 ErrInvalidLengthAbci + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthAbci + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.EvmError = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipAbci(dAtA[iNdEx:]) diff --git a/types/context.go b/types/context.go index c07689e5b12b..4723cc5d9f53 100644 --- a/types/context.go +++ b/types/context.go @@ -46,24 +46,42 @@ type Context struct { // Deprecated: Use HeaderService for hash headerHash []byte // Deprecated: Use HeaderService for chainID and CometService for the rest - chainID string - txBytes []byte - logger log.Logger - voteInfo []abci.VoteInfo - gasMeter storetypes.GasMeter - blockGasMeter storetypes.GasMeter - checkTx bool - recheckTx bool // if recheckTx == true, then checkTx must also be true - execMode ExecMode - minGasPrice DecCoins - consParams cmtproto.ConsensusParams - eventManager EventManagerI + chainID string + txBytes []byte + logger log.Logger + voteInfo []abci.VoteInfo + gasMeter storetypes.GasMeter + blockGasMeter storetypes.GasMeter + checkTx bool + recheckTx bool // if recheckTx == true, then checkTx must also be true + execMode ExecMode + minGasPrice DecCoins + consParams cmtproto.ConsensusParams + eventManager EventManagerI + priority int64 // The tx priority, only relevant in CheckTx kvGasConfig storetypes.GasConfig transientKVGasConfig storetypes.GasConfig streamingManager storetypes.StreamingManager cometInfo comet.BlockInfo headerInfo header.Info + + // EVM properties + evmEventManager *EVMEventManager + evm bool // EVM transaction flag + evmNonce uint64 // EVM Transaction nonce + evmSenderAddress string // EVM Sender address + evmTxHash string // EVM TX hash + evmVmError string // EVM VM error during execution + txIndex int // The index of the transaction being processed (may not be required due to no multi-processing) + + pendingTxChecker abci.PendingTxChecker // Checker for pending transaction, only relevant in CheckTx + checkTxCallback func(Context, error) // callback to make at the end of CheckTx. Input param is the error (nil-able) of `runMsgs` + expireTxHandler func() // callback that the mempool invokes when a tx is expired +} + +func (c Context) EVMEventManager() *EVMEventManager { + return c.evmEventManager } // Proposed rename, not done to avoid API breakage @@ -135,6 +153,7 @@ func NewContext(ms storetypes.MultiStore, header cmtproto.Header, isCheckTx bool gasMeter: storetypes.NewInfiniteGasMeter(), minGasPrice: DecCoins{}, eventManager: NewEventManager(), + evmEventManager: NewEVMEventManager(), kvGasConfig: storetypes.KVGasConfig(), transientKVGasConfig: storetypes.TransientGasConfig(), } @@ -284,6 +303,61 @@ func (c Context) WithEventManager(em EventManagerI) Context { return c } +func (c Context) WithEvmEventManager(em *EVMEventManager) Context { + c.evmEventManager = em + return c +} + +func (c Context) TxIndex() int { + return c.txIndex +} + +func (c Context) WithEVMSenderAddress(address string) Context { + c.evmSenderAddress = address + return c +} + +func (c Context) WithEVMNonce(nonce uint64) Context { + c.evmNonce = nonce + return c +} + +func (c Context) WithIsEVM(isEVM bool) Context { + c.evm = isEVM + return c +} + +func (c Context) WithEVMTxHash(txHash string) Context { + c.evmTxHash = txHash + return c +} + +func (c Context) WithEVMVMError(vmError string) Context { + c.evmVmError = vmError + return c +} + +// WithTxIndex returns a Context with the current transaction index that's being processed +func (c Context) WithTxIndex(txIndex int) Context { + c.txIndex = txIndex + return c +} + +func (c Context) WithPendingTxChecker(checker abci.PendingTxChecker) Context { + c.pendingTxChecker = checker + return c +} + +func (c Context) WithCheckTxCallback(checkTxCallback func(Context, error)) Context { + c.checkTxCallback = checkTxCallback + return c +} + +func (c Context) WithExpireTxHandler(expireTxHandler func()) Context { + c.expireTxHandler = expireTxHandler + return c +} + // WithPriority returns a Context with an updated tx priority func (c Context) WithPriority(p int64) Context { c.priority = p diff --git a/types/denom.go b/types/denom.go index 5cd0910ad44f..210eb78a9a40 100644 --- a/types/denom.go +++ b/types/denom.go @@ -66,6 +66,14 @@ func GetBaseDenom() (string, error) { return baseDenom, nil } +func MustGetBaseDenom() string { + bd, err := GetBaseDenom() + if err != nil { + panic(err) + } + return bd +} + // ConvertCoin attempts to convert a coin to a given denomination. If the given // denomination is invalid or if neither denomination is registered, an error // is returned. diff --git a/types/errors/errors.go b/types/errors/errors.go index 5e17f2df481a..feb654f30c0e 100644 --- a/types/errors/errors.go +++ b/types/errors/errors.go @@ -140,6 +140,12 @@ var ( // supplied. ErrInvalidGasLimit = errorsmod.Register(RootCodespace, 41, "invalid gas limit") + // ErrUnsupportedTxType defines an error for an unsupported transaction type (e.g., EIP-4844 transactions) + ErrUnsupportedTxType = errorsmod.Register(RootCodespace, 42, "unsupported transaction type") + + // ErrEVMVMError defines an error for an evm vm error (eg. revert) + ErrEVMVMError = errorsmod.Register(RootCodespace, 43, "evm reverted") + // ErrPanic should only be set when we recovering from a panic ErrPanic = errorsmod.ErrPanic ) diff --git a/types/evm.go b/types/evm.go new file mode 100644 index 000000000000..3e83453b8181 --- /dev/null +++ b/types/evm.go @@ -0,0 +1,20 @@ +package types + +import ( + ethtypes "github.com/ethereum/go-ethereum/core/types" +) + +// used in context.go +type EVMEventManager struct { + events []*ethtypes.Log +} + +func NewEVMEventManager() *EVMEventManager { + return &EVMEventManager{events: []*ethtypes.Log{}} +} + +func (eem *EVMEventManager) Events() []*ethtypes.Log { return eem.events } + +func (eem *EVMEventManager) EmitEvents(events []*ethtypes.Log) { + eem.events = append(eem.events, events...) +} diff --git a/x/bank/keeper/genesis.go b/x/bank/keeper/genesis.go index cb208b22d33b..ccce2a9a3fde 100644 --- a/x/bank/keeper/genesis.go +++ b/x/bank/keeper/genesis.go @@ -47,7 +47,7 @@ func (k BaseKeeper) InitGenesis(ctx context.Context, genState *types.GenesisStat } for _, supply := range totalSupply { - k.setSupply(ctx, supply) + k.SetSupply(ctx, supply) } for _, meta := range genState.DenomMetadata { diff --git a/x/bank/keeper/keeper.go b/x/bank/keeper/keeper.go index bfa45d23f64e..76b568185c64 100644 --- a/x/bank/keeper/keeper.go +++ b/x/bank/keeper/keeper.go @@ -49,6 +49,8 @@ type Keeper interface { DelegateCoins(ctx context.Context, delegatorAddr, moduleAccAddr sdk.AccAddress, amt sdk.Coins) error UndelegateCoins(ctx context.Context, moduleAccAddr, delegatorAddr sdk.AccAddress, amt sdk.Coins) error + SetSupply(ctx context.Context, coin sdk.Coin) + types.QueryServer } @@ -157,7 +159,7 @@ func (k BaseKeeper) DelegateCoins(ctx context.Context, delegatorAddr, moduleAccA types.NewCoinSpentEvent(delegatorAddr, amt), ) - err := k.addCoins(ctx, moduleAccAddr, amt) + err := k.AddCoins(ctx, moduleAccAddr, amt) if err != nil { return err } @@ -180,7 +182,7 @@ func (k BaseKeeper) UndelegateCoins(ctx context.Context, moduleAccAddr, delegato return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, amt.String()) } - err := k.subUnlockedCoins(ctx, moduleAccAddr, amt) + err := k.SubUnlockedCoins(ctx, moduleAccAddr, amt) if err != nil { return err } @@ -189,7 +191,7 @@ func (k BaseKeeper) UndelegateCoins(ctx context.Context, moduleAccAddr, delegato return errorsmod.Wrap(err, "failed to track undelegation") } - err = k.addCoins(ctx, delegatorAddr, amt) + err = k.AddCoins(ctx, delegatorAddr, amt) if err != nil { return err } @@ -357,7 +359,7 @@ func (k BaseKeeper) MintCoins(ctx context.Context, moduleName string, amounts sd panic(errorsmod.Wrapf(sdkerrors.ErrUnauthorized, "module account %s does not have permissions to mint tokens", moduleName)) } - err = k.addCoins(ctx, acc.GetAddress(), amounts) + err = k.AddCoins(ctx, acc.GetAddress(), amounts) if err != nil { return err } @@ -365,7 +367,7 @@ func (k BaseKeeper) MintCoins(ctx context.Context, moduleName string, amounts sd for _, amount := range amounts { supply := k.GetSupply(ctx, amount.GetDenom()) supply = supply.Add(amount) - k.setSupply(ctx, supply) + k.SetSupply(ctx, supply) } k.logger.Debug("minted coins from module account", "amount", amounts.String(), "from", moduleName) @@ -390,7 +392,7 @@ func (k BaseKeeper) BurnCoins(ctx context.Context, moduleName string, amounts sd panic(errorsmod.Wrapf(sdkerrors.ErrUnauthorized, "module account %s does not have permissions to burn tokens", moduleName)) } - err := k.subUnlockedCoins(ctx, acc.GetAddress(), amounts) + err := k.SubUnlockedCoins(ctx, acc.GetAddress(), amounts) if err != nil { return err } @@ -398,7 +400,7 @@ func (k BaseKeeper) BurnCoins(ctx context.Context, moduleName string, amounts sd for _, amount := range amounts { supply := k.GetSupply(ctx, amount.GetDenom()) supply = supply.Sub(amount) - k.setSupply(ctx, supply) + k.SetSupply(ctx, supply) } k.logger.Debug("burned tokens from module account", "amount", amounts.String(), "from", moduleName) @@ -412,8 +414,8 @@ func (k BaseKeeper) BurnCoins(ctx context.Context, moduleName string, amounts sd return nil } -// setSupply sets the supply for the given coin -func (k BaseKeeper) setSupply(ctx context.Context, coin sdk.Coin) { +// SetSupply sets the supply for the given coin +func (k BaseKeeper) SetSupply(ctx context.Context, coin sdk.Coin) { // Bank invariants and IBC requires to remove zero coins. if coin.IsZero() { _ = k.Supply.Remove(ctx, coin.Denom) diff --git a/x/bank/keeper/send.go b/x/bank/keeper/send.go index c8aad5446f3b..86c3bde55b9f 100644 --- a/x/bank/keeper/send.go +++ b/x/bank/keeper/send.go @@ -46,10 +46,21 @@ type SendKeeper interface { BlockedAddr(addr sdk.AccAddress) bool GetBlockedAddresses() map[string]bool + // EVM + SendCoinsWithoutAccCreation(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error + SendCoinsAndWei(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress, amt math.Int, wei math.Int) error + SubWei(ctx sdk.Context, addr sdk.AccAddress, amt math.Int) error + AddWei(ctx sdk.Context, addr sdk.AccAddress, amt math.Int) error + AddCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error + SubUnlockedCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error + GetAuthority() string } -var _ SendKeeper = (*BaseSendKeeper)(nil) +var ( + _ SendKeeper = (*BaseSendKeeper)(nil) + OneUseiInWei math.Int = math.NewInt(1_000_000_000_000) +) // BaseSendKeeper only allows transfers between accounts without the possibility of // creating coins. It implements the SendKeeper interface. @@ -152,7 +163,7 @@ func (k BaseSendKeeper) InputOutputCoins(ctx context.Context, input types.Input, return err } - err = k.subUnlockedCoins(ctx, inAddress, input.Coins) + err = k.SubUnlockedCoins(ctx, inAddress, input.Coins) if err != nil { return err } @@ -177,7 +188,7 @@ func (k BaseSendKeeper) InputOutputCoins(ctx context.Context, input types.Input, return err } - if err := k.addCoins(ctx, outAddress, out.Coins); err != nil { + if err := k.AddCoins(ctx, outAddress, out.Coins); err != nil { return err } @@ -206,8 +217,9 @@ func (k BaseSendKeeper) InputOutputCoins(ctx context.Context, input types.Input, // SendCoins transfers amt coins from a sending account to a receiving account. // An error is returned upon failure. func (k BaseSendKeeper) SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccAddress, amt sdk.Coins) error { + var err error - err = k.subUnlockedCoins(ctx, fromAddr, amt) + err = k.SubUnlockedCoins(ctx, fromAddr, amt) if err != nil { return err } @@ -217,7 +229,7 @@ func (k BaseSendKeeper) SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccA return err } - err = k.addCoins(ctx, toAddr, amt) + err = k.AddCoins(ctx, toAddr, amt) if err != nil { return err } @@ -251,10 +263,10 @@ func (k BaseSendKeeper) SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccA return nil } -// subUnlockedCoins removes the unlocked amt coins of the given account. An error is +// SubUnlockedCoins removes the unlocked amt coins of the given account. An error is // returned if the resulting balance is negative or the initial amount is invalid. // A coin_spent event is emitted after. -func (k BaseSendKeeper) subUnlockedCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error { +func (k BaseSendKeeper) SubUnlockedCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error { if !amt.IsValid() { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, amt.String()) } @@ -297,9 +309,9 @@ func (k BaseSendKeeper) subUnlockedCoins(ctx context.Context, addr sdk.AccAddres return nil } -// addCoins increase the addr balance by the given amt. Fails if the provided +// AddCoins increase the addr balance by the given amt. Fails if the provided // amt is invalid. It emits a coin received event. -func (k BaseSendKeeper) addCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error { +func (k BaseSendKeeper) AddCoins(ctx context.Context, addr sdk.AccAddress, amt sdk.Coins) error { if !amt.IsValid() { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, amt.String()) } @@ -505,3 +517,133 @@ func (r *sendRestriction) apply(ctx context.Context, fromAddr, toAddr sdk.AccAdd } return r.fn(ctx, fromAddr, toAddr, amt) } + +// EVM + +func (k BaseSendKeeper) SubWei(ctx sdk.Context, addr sdk.AccAddress, amt math.Int) (err error) { + if amt.Equal(math.ZeroInt()) { + return nil + } + defer func() { + if err == nil { + ctx.EventManager().EmitEvent( + types.NewWeiSpentEvent(addr, amt), + ) + } + }() + currentWeiBalance := k.GetWeiBalance(ctx, addr) + if amt.LTE(currentWeiBalance) { + // no need to change usei balance + return k.setWeiBalance(ctx, addr, currentWeiBalance.Sub(amt)) + } + currentUseiBalance := k.GetBalance(ctx, addr, sdk.MustGetBaseDenom()).Amount + currentAggregatedBalance := currentUseiBalance.Mul(OneUseiInWei).Add(currentWeiBalance) + postAggregatedbalance := currentAggregatedBalance.Sub(amt) + if postAggregatedbalance.IsNegative() { + return errorsmod.Wrapf(sdkerrors.ErrInsufficientFunds, "%swei is smaller than %swei", currentAggregatedBalance, amt) + } + useiBalance, weiBalance := SplitUseiWeiAmount(postAggregatedbalance) + if err := k.setBalance(ctx, addr, sdk.NewCoin(sdk.MustGetBaseDenom(), useiBalance)); err != nil { + return err + } + return k.setWeiBalance(ctx, addr, weiBalance) +} + +func (k BaseSendKeeper) AddWei(ctx sdk.Context, addr sdk.AccAddress, amt math.Int) (err error) { + if amt.Equal(math.ZeroInt()) { + return nil + } + defer func() { + if err == nil { + ctx.EventManager().EmitEvent( + types.NewWeiReceivedEvent(addr, amt), + ) + } + }() + currentWeiBalance := k.GetWeiBalance(ctx, addr) + postWeiBalance := currentWeiBalance.Add(amt) + if postWeiBalance.LT(OneUseiInWei) { + // no need to change usei balance + return k.setWeiBalance(ctx, addr, postWeiBalance) + } + currentUseiBalance := k.GetBalance(ctx, addr, sdk.MustGetBaseDenom()).Amount + useiCredit, weiBalance := SplitUseiWeiAmount(postWeiBalance) + if err := k.setBalance(ctx, addr, sdk.NewCoin(sdk.MustGetBaseDenom(), currentUseiBalance.Add(useiCredit))); err != nil { + return err + } + return k.setWeiBalance(ctx, addr, weiBalance) +} + +func (k BaseSendKeeper) SendCoinsAndWei(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress, amt math.Int, wei math.Int) error { + if err := k.SubWei(ctx, from, wei); err != nil { + return err + } + if err := k.AddWei(ctx, to, wei); err != nil { + return err + } + ctx.EventManager().EmitEvents(sdk.Events{ + sdk.NewEvent( + types.EventTypeWeiTransfer, + sdk.NewAttribute(types.AttributeKeyRecipient, to.String()), + sdk.NewAttribute(types.AttributeKeySender, from.String()), + sdk.NewAttribute(sdk.AttributeKeyAmount, wei.String()), + ), + }) + if amt.GT(math.ZeroInt()) { + return k.SendCoinsWithoutAccCreation(ctx, from, to, sdk.NewCoins(sdk.NewCoin(sdk.MustGetBaseDenom(), amt))) + } + return nil +} + +func SplitUseiWeiAmount(amt math.Int) (math.Int, math.Int) { + return amt.Quo(OneUseiInWei), amt.Mod(OneUseiInWei) +} + +func (k BaseSendKeeper) SendCoinsWithoutAccCreation(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error { + return k.sendCoinsWithoutAccCreation(ctx, fromAddr, toAddr, amt) +} + +// EVM Helpers +func (k BaseSendKeeper) sendCoinsWithoutAccCreation(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error { + if !amt.IsValid() { + return errorsmod.Wrapf(sdkerrors.ErrInvalidCoins, "invalid coin amount: %s", amt) + } + + err := k.SubUnlockedCoins(ctx, fromAddr, amt) + if err != nil { + return err + } + + err = k.AddCoins(ctx, toAddr, amt) + if err != nil { + return err + } + + ctx.EventManager().EmitEvents(sdk.Events{ + sdk.NewEvent( + types.EventTypeTransfer, + sdk.NewAttribute(types.AttributeKeyRecipient, toAddr.String()), + sdk.NewAttribute(types.AttributeKeySender, fromAddr.String()), + sdk.NewAttribute(sdk.AttributeKeyAmount, amt.String()), + ), + sdk.NewEvent( + sdk.EventTypeMessage, + sdk.NewAttribute(types.AttributeKeySender, fromAddr.String()), + ), + }) + + return nil +} + +func (k BaseSendKeeper) setWeiBalance(ctx sdk.Context, addr sdk.AccAddress, amt math.Int) error { + if amt.IsZero() { + return k.WeiBalances.Remove(ctx, addr) + } + + // todo: this may not be required, but ensures we don't accidentally shoot ourselves in the foot + if amt.IsNegative() { + return errorsmod.Wrapf(sdkerrors.ErrInvalidCoins, "set invalid coin amount: %s", amt) + } + + return k.WeiBalances.Set(ctx, addr, amt) +} diff --git a/x/bank/keeper/view.go b/x/bank/keeper/view.go index d4e2544bc796..17771f81e339 100644 --- a/x/bank/keeper/view.go +++ b/x/bank/keeper/view.go @@ -32,6 +32,10 @@ type ViewKeeper interface { SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins SpendableCoin(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin + // EVM + GetWeiBalance(ctx sdk.Context, addr sdk.AccAddress) math.Int + IterateAllWeiBalances(ctx sdk.Context, cb func(sdk.AccAddress, math.Int) bool) + IterateAccountBalances(ctx context.Context, addr sdk.AccAddress, cb func(coin sdk.Coin) (stop bool)) IterateAllBalances(ctx context.Context, cb func(address sdk.AccAddress, coin sdk.Coin) (stop bool)) } @@ -66,6 +70,7 @@ type BaseViewKeeper struct { DenomMetadata collections.Map[string, types.Metadata] SendEnabled collections.Map[string, bool] Balances *collections.IndexedMap[collections.Pair[sdk.AccAddress, string], math.Int, BalancesIndexes] + WeiBalances collections.Map[sdk.AccAddress, math.Int] Params collections.Item[types.Params] } @@ -81,6 +86,7 @@ func NewBaseViewKeeper(cdc codec.BinaryCodec, storeService store.KVStoreService, DenomMetadata: collections.NewMap(sb, types.DenomMetadataPrefix, "denom_metadata", collections.StringKey, codec.CollValue[types.Metadata](cdc)), SendEnabled: collections.NewMap(sb, types.SendEnabledPrefix, "send_enabled", collections.StringKey, codec.BoolValue), // NOTE: we use a bool value which uses protobuf to retain state backwards compat Balances: collections.NewIndexedMap(sb, types.BalancesPrefix, "balances", collections.PairKeyCodec(sdk.AccAddressKey, collections.StringKey), types.BalanceValueCodec, newBalancesIndexes(sb)), + WeiBalances: collections.NewMap(sb, types.WeiBalancesPrefix, "wei_balances", sdk.AccAddressKey, sdk.IntValue), Params: collections.NewItem(sb, types.ParamsKey, "params", codec.CollValue[types.Params](cdc)), } @@ -250,3 +256,23 @@ func (k BaseViewKeeper) ValidateBalance(ctx context.Context, addr sdk.AccAddress return nil } + +// EVM +func (k BaseViewKeeper) GetWeiBalance(ctx sdk.Context, addr sdk.AccAddress) math.Int { + v, err := k.WeiBalances.Get(ctx, addr) + if err != nil { + return math.ZeroInt() + } + + return v +} + +func (k BaseViewKeeper) IterateAllWeiBalances(ctx sdk.Context, cb func(sdk.AccAddress, math.Int) bool) { + err := k.WeiBalances.Walk(ctx, nil, func(key sdk.AccAddress, value math.Int) (stop bool, err error) { + return cb(key, value), nil + }) + if err != nil { + panic(err) + } + +} diff --git a/x/bank/types/events.go b/x/bank/types/events.go index 098eebc37251..f024842cd394 100644 --- a/x/bank/types/events.go +++ b/x/bank/types/events.go @@ -1,6 +1,7 @@ package types import ( + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -21,6 +22,11 @@ const ( AttributeKeyReceiver = "receiver" AttributeKeyMinter = "minter" AttributeKeyBurner = "burner" + + // EVM + EventTypeWeiSpent = "wei_spent" + EventTypeWeiReceived = "wei_received" + EventTypeWeiTransfer = "wei_transfer" ) // NewCoinSpentEvent constructs a new coin spent sdk.Event @@ -58,3 +64,21 @@ func NewCoinBurnEvent(burner sdk.AccAddress, amount sdk.Coins) sdk.Event { sdk.NewAttribute(sdk.AttributeKeyAmount, amount.String()), ) } + +// NewWeiSpentEvent constructs a new wei spent sdk.Event +func NewWeiSpentEvent(spender sdk.AccAddress, amount math.Int) sdk.Event { + return sdk.NewEvent( + EventTypeWeiSpent, + sdk.NewAttribute(AttributeKeySpender, spender.String()), + sdk.NewAttribute(sdk.AttributeKeyAmount, amount.String()), + ) +} + +// NewWeiReceivedEvent constructs a new wei received sdk.Event +func NewWeiReceivedEvent(receiver sdk.AccAddress, amount math.Int) sdk.Event { + return sdk.NewEvent( + EventTypeWeiReceived, + sdk.NewAttribute(AttributeKeyReceiver, receiver.String()), + sdk.NewAttribute(sdk.AttributeKeyAmount, amount.String()), + ) +} diff --git a/x/bank/types/keys.go b/x/bank/types/keys.go index b4ea683d4b69..9eea778c22e7 100644 --- a/x/bank/types/keys.go +++ b/x/bank/types/keys.go @@ -32,6 +32,8 @@ var ( // ParamsKey is the prefix for x/bank parameters ParamsKey = collections.NewPrefix(5) + + WeiBalancesPrefix = collections.NewPrefix(6) ) // BalanceValueCodec is a codec for encoding bank balances in a backwards compatible way. diff --git a/x/gov/testutil/expected_keepers_mocks.go b/x/gov/testutil/expected_keepers_mocks.go index 5970d3822f6a..b5fc8cabe4f0 100644 --- a/x/gov/testutil/expected_keepers_mocks.go +++ b/x/gov/testutil/expected_keepers_mocks.go @@ -144,6 +144,34 @@ func (m *MockBankKeeper) EXPECT() *MockBankKeeperMockRecorder { return m.recorder } +// AddCoins mocks base method. +func (m *MockBankKeeper) AddCoins(ctx context.Context, addr types.AccAddress, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "AddCoins", ctx, addr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// AddCoins indicates an expected call of AddCoins. +func (mr *MockBankKeeperMockRecorder) AddCoins(ctx, addr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddCoins", reflect.TypeOf((*MockBankKeeper)(nil).AddCoins), ctx, addr, amt) +} + +// AddWei mocks base method. +func (m *MockBankKeeper) AddWei(ctx types.Context, addr types.AccAddress, amt math.Int) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "AddWei", ctx, addr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// AddWei indicates an expected call of AddWei. +func (mr *MockBankKeeperMockRecorder) AddWei(ctx, addr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddWei", reflect.TypeOf((*MockBankKeeper)(nil).AddWei), ctx, addr, amt) +} + // AllBalances mocks base method. func (m *MockBankKeeper) AllBalances(arg0 context.Context, arg1 *types0.QueryAllBalancesRequest) (*types0.QueryAllBalancesResponse, error) { m.ctrl.T.Helper() @@ -532,6 +560,20 @@ func (mr *MockBankKeeperMockRecorder) GetSupply(ctx, denom interface{}) *gomock. return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetSupply", reflect.TypeOf((*MockBankKeeper)(nil).GetSupply), ctx, denom) } +// GetWeiBalance mocks base method. +func (m *MockBankKeeper) GetWeiBalance(ctx types.Context, addr types.AccAddress) math.Int { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetWeiBalance", ctx, addr) + ret0, _ := ret[0].(math.Int) + return ret0 +} + +// GetWeiBalance indicates an expected call of GetWeiBalance. +func (mr *MockBankKeeperMockRecorder) GetWeiBalance(ctx, addr interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetWeiBalance", reflect.TypeOf((*MockBankKeeper)(nil).GetWeiBalance), ctx, addr) +} + // HasBalance mocks base method. func (m *MockBankKeeper) HasBalance(ctx context.Context, addr types.AccAddress, amt types.Coin) bool { m.ctrl.T.Helper() @@ -683,6 +725,18 @@ func (mr *MockBankKeeperMockRecorder) IterateAllDenomMetaData(ctx, cb interface{ return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IterateAllDenomMetaData", reflect.TypeOf((*MockBankKeeper)(nil).IterateAllDenomMetaData), ctx, cb) } +// IterateAllWeiBalances mocks base method. +func (m *MockBankKeeper) IterateAllWeiBalances(ctx types.Context, cb func(types.AccAddress, math.Int) bool) { + m.ctrl.T.Helper() + m.ctrl.Call(m, "IterateAllWeiBalances", ctx, cb) +} + +// IterateAllWeiBalances indicates an expected call of IterateAllWeiBalances. +func (mr *MockBankKeeperMockRecorder) IterateAllWeiBalances(ctx, cb interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "IterateAllWeiBalances", reflect.TypeOf((*MockBankKeeper)(nil).IterateAllWeiBalances), ctx, cb) +} + // IterateSendEnabledEntries mocks base method. func (m *MockBankKeeper) IterateSendEnabledEntries(ctx context.Context, cb func(string, bool) bool) { m.ctrl.T.Helper() @@ -776,6 +830,20 @@ func (mr *MockBankKeeperMockRecorder) SendCoins(ctx, fromAddr, toAddr, amt inter return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoins", reflect.TypeOf((*MockBankKeeper)(nil).SendCoins), ctx, fromAddr, toAddr, amt) } +// SendCoinsAndWei mocks base method. +func (m *MockBankKeeper) SendCoinsAndWei(ctx types.Context, from, to types.AccAddress, amt, wei math.Int) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendCoinsAndWei", ctx, from, to, amt, wei) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendCoinsAndWei indicates an expected call of SendCoinsAndWei. +func (mr *MockBankKeeperMockRecorder) SendCoinsAndWei(ctx, from, to, amt, wei interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsAndWei", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsAndWei), ctx, from, to, amt, wei) +} + // SendCoinsFromAccountToModule mocks base method. func (m *MockBankKeeper) SendCoinsFromAccountToModule(ctx context.Context, senderAddr types.AccAddress, recipientModule string, amt types.Coins) error { m.ctrl.T.Helper() @@ -818,6 +886,20 @@ func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToModule(ctx, senderMod return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsFromModuleToModule", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsFromModuleToModule), ctx, senderModule, recipientModule, amt) } +// SendCoinsWithoutAccCreation mocks base method. +func (m *MockBankKeeper) SendCoinsWithoutAccCreation(ctx types.Context, fromAddr, toAddr types.AccAddress, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SendCoinsWithoutAccCreation", ctx, fromAddr, toAddr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SendCoinsWithoutAccCreation indicates an expected call of SendCoinsWithoutAccCreation. +func (mr *MockBankKeeperMockRecorder) SendCoinsWithoutAccCreation(ctx, fromAddr, toAddr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SendCoinsWithoutAccCreation", reflect.TypeOf((*MockBankKeeper)(nil).SendCoinsWithoutAccCreation), ctx, fromAddr, toAddr, amt) +} + // SendEnabled mocks base method. func (m *MockBankKeeper) SendEnabled(arg0 context.Context, arg1 *types0.QuerySendEnabledRequest) (*types0.QuerySendEnabledResponse, error) { m.ctrl.T.Helper() @@ -883,6 +965,18 @@ func (mr *MockBankKeeperMockRecorder) SetSendEnabled(ctx, denom, value interface return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetSendEnabled", reflect.TypeOf((*MockBankKeeper)(nil).SetSendEnabled), ctx, denom, value) } +// SetSupply mocks base method. +func (m *MockBankKeeper) SetSupply(ctx context.Context, coin types.Coin) { + m.ctrl.T.Helper() + m.ctrl.Call(m, "SetSupply", ctx, coin) +} + +// SetSupply indicates an expected call of SetSupply. +func (mr *MockBankKeeperMockRecorder) SetSupply(ctx, coin interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetSupply", reflect.TypeOf((*MockBankKeeper)(nil).SetSupply), ctx, coin) +} + // SpendableBalanceByDenom mocks base method. func (m *MockBankKeeper) SpendableBalanceByDenom(arg0 context.Context, arg1 *types0.QuerySpendableBalanceByDenomRequest) (*types0.QuerySpendableBalanceByDenomResponse, error) { m.ctrl.T.Helper() @@ -941,6 +1035,34 @@ func (mr *MockBankKeeperMockRecorder) SpendableCoins(ctx, addr interface{}) *gom return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SpendableCoins", reflect.TypeOf((*MockBankKeeper)(nil).SpendableCoins), ctx, addr) } +// SubUnlockedCoins mocks base method. +func (m *MockBankKeeper) SubUnlockedCoins(ctx context.Context, addr types.AccAddress, amt types.Coins) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SubUnlockedCoins", ctx, addr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SubUnlockedCoins indicates an expected call of SubUnlockedCoins. +func (mr *MockBankKeeperMockRecorder) SubUnlockedCoins(ctx, addr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SubUnlockedCoins", reflect.TypeOf((*MockBankKeeper)(nil).SubUnlockedCoins), ctx, addr, amt) +} + +// SubWei mocks base method. +func (m *MockBankKeeper) SubWei(ctx types.Context, addr types.AccAddress, amt math.Int) error { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "SubWei", ctx, addr, amt) + ret0, _ := ret[0].(error) + return ret0 +} + +// SubWei indicates an expected call of SubWei. +func (mr *MockBankKeeperMockRecorder) SubWei(ctx, addr, amt interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SubWei", reflect.TypeOf((*MockBankKeeper)(nil).SubWei), ctx, addr, amt) +} + // SupplyOf mocks base method. func (m *MockBankKeeper) SupplyOf(arg0 context.Context, arg1 *types0.QuerySupplyOfRequest) (*types0.QuerySupplyOfResponse, error) { m.ctrl.T.Helper() diff --git a/x/group/internal/orm/testsupport.go b/x/group/internal/orm/testsupport.go index b4fe3d0354ee..a8b7109ad754 100644 --- a/x/group/internal/orm/testsupport.go +++ b/x/group/internal/orm/testsupport.go @@ -40,6 +40,11 @@ type debuggingGasMeter struct { g storetypes.GasMeter } +// Multiplier implements types.GasMeter. +func (d *debuggingGasMeter) Multiplier() (numerator uint64, denominator uint64) { + return 1, 1 +} + func (d debuggingGasMeter) GasConsumed() storetypes.Gas { return d.g.GasConsumed() }