diff --git a/proto/umee/uibc/v1/events.proto b/proto/umee/uibc/v1/events.proto index f7035c0932..c5f54ad287 100644 --- a/proto/umee/uibc/v1/events.proto +++ b/proto/umee/uibc/v1/events.proto @@ -15,7 +15,7 @@ message EventBadRevert { string packet = 2; } -// EventQuotaPause is emitted on quota tracking pause status change. -message EventQuotaPause { +// EventIBCTransferStatus is emitted on quota tracking pause status change. +message EventIBCTransferStatus { IBCTransferStatus status = 1; } diff --git a/proto/umee/uibc/v1/quota.proto b/proto/umee/uibc/v1/quota.proto index 567f8e6054..31960afd5d 100644 --- a/proto/umee/uibc/v1/quota.proto +++ b/proto/umee/uibc/v1/quota.proto @@ -10,7 +10,7 @@ option go_package = "github.com/umee-network/umee/v4/x/uibc"; // Params of x/uibc module message Params { // ibc_status defines the wethever ibc-transfer enabled, disbaled or paused - IBCTransferStatus ibc_pause = 1; + IBCTransferStatus ibc_status = 1; // total_quota defines the total outflow limit of ibc-transfer in USD string total_quota = 2 [ (cosmos_proto.scalar) = "cosmos.Dec", @@ -36,10 +36,10 @@ message Params { enum IBCTransferStatus { // UNSPECIFIED defines a no-op status. IBC_TRANSFER_STATUS_UNSPECIFIED = 0; - // DISABLED defines the quota checking diabled for ibc-transfer. - IBC_TRANSFER_STATUS_DISABLED = 1; - // ENABLED defines the enable quota checking for ibc-transfer. - IBC_TRANSFER_STATUS_ENABLED = 2; - // PAUSED defines pause the ibc-transfer from app. - IBC_TRANSFER_STATUS_PAUSED = 3; + // DISABLED: quota checks are disabled. + IBC_TRANSFER_STATUS_QUOTA_DISABLED = 1; + // ENABLED: quota checks are enabled. + IBC_TRANSFER_STATUS_QUOTA_ENABLED = 2; + // PAUSED: all IBC transfers are paused. + IBC_TRANSFER_STATUS_TRANSFERS_PAUSED = 3; } diff --git a/proto/umee/uibc/v1/tx.proto b/proto/umee/uibc/v1/tx.proto index 861f5daa64..de21d20df2 100644 --- a/proto/umee/uibc/v1/tx.proto +++ b/proto/umee/uibc/v1/tx.proto @@ -18,8 +18,8 @@ service Msg { // updates the quota for existed ibc denoms. rpc GovUpdateQuota(MsgGovUpdateQuota) returns (MsgGovUpdateQuotaResponse); - // GovSetIBCPause update the status of ibc-transfer - rpc GovSetIBCPause(MsgGovSetIBCPause) returns (MsgGovSetIBCPauseResponse); + // GovSetIBCStatus update the status of ibc-transfer + rpc GovSetIBCStatus(MsgGovSetIBCStatus) returns (MsgGovSetIBCStatusResponse); } // MsgGovUpdateQuota defines the Msg/GovUpdateQuota request type. @@ -56,8 +56,8 @@ message MsgGovUpdateQuota { // MsgGovUpdateQuotaResponse defines response type for the Msg/GovUpdateQuota for with x/gov proposals. message MsgGovUpdateQuotaResponse {}; -// MsgGovSetIBCPause defines request type for UpdateIBCTransferStatus -message MsgGovSetIBCPause { +// MsgGovSetIbcstatus defines request type for UpdateIBCTransferStatus +message MsgGovSetIBCStatus { option (gogoproto.goproto_getters) = false; option (gogoproto.goproto_stringer) = false; option (cosmos.msg.v1.signer) = "authority"; @@ -65,9 +65,9 @@ message MsgGovSetIBCPause { string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; string title = 2; string description = 3; - // ibc_pause_status defines ibc transfer pause status - IBCTransferStatus ibc_pause_status = 4; + // ibc_status defines ibc transfer pause status + IBCTransferStatus ibc_status = 4; } -// MsgGovSetIBCPauseResponse definesresponse type for Msg/MsgGovSetIBCPause for with x/gov proposals. -message MsgGovSetIBCPauseResponse {} +// MsgGovSetIbcstatusResponse definesresponse type for Msg/MsgGovSetIbcstatus for with x/gov proposals. +message MsgGovSetIBCStatusResponse {} diff --git a/x/uibc/codec.go b/x/uibc/codec.go index a790b3bcc6..e805c8b818 100644 --- a/x/uibc/codec.go +++ b/x/uibc/codec.go @@ -28,14 +28,14 @@ func init() { // Amino JSON serialization. func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgGovUpdateQuota{}, "umee/uibc/MsgGovUpdateQuota", nil) - cdc.RegisterConcrete(&MsgGovSetIBCPause{}, "umee/uibc/MsgGovSetIBCPause", nil) + cdc.RegisterConcrete(&MsgGovSetIBCStatus{}, "umee/uibc/MsgGovSetIBCStatus", nil) } func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { registry.RegisterImplementations( (*sdk.Msg)(nil), &MsgGovUpdateQuota{}, - &MsgGovSetIBCPause{}, + &MsgGovSetIBCStatus{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) diff --git a/x/uibc/events.pb.go b/x/uibc/events.pb.go index 2ab5a5a219..4971a16b2c 100644 --- a/x/uibc/events.pb.go +++ b/x/uibc/events.pb.go @@ -64,23 +64,23 @@ func (m *EventBadRevert) XXX_DiscardUnknown() { var xxx_messageInfo_EventBadRevert proto.InternalMessageInfo -// EventQuotaPause is emitted on quota tracking pause status change. -type EventQuotaPause struct { +// EventIBCTransferStatus is emitted on quota tracking pause status change. +type EventIBCTransferStatus struct { Status IBCTransferStatus `protobuf:"varint,1,opt,name=status,proto3,enum=umee.uibc.v1.IBCTransferStatus" json:"status,omitempty"` } -func (m *EventQuotaPause) Reset() { *m = EventQuotaPause{} } -func (m *EventQuotaPause) String() string { return proto.CompactTextString(m) } -func (*EventQuotaPause) ProtoMessage() {} -func (*EventQuotaPause) Descriptor() ([]byte, []int) { +func (m *EventIBCTransferStatus) Reset() { *m = EventIBCTransferStatus{} } +func (m *EventIBCTransferStatus) String() string { return proto.CompactTextString(m) } +func (*EventIBCTransferStatus) ProtoMessage() {} +func (*EventIBCTransferStatus) Descriptor() ([]byte, []int) { return fileDescriptor_c64e60b79cebf048, []int{1} } -func (m *EventQuotaPause) XXX_Unmarshal(b []byte) error { +func (m *EventIBCTransferStatus) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } -func (m *EventQuotaPause) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { +func (m *EventIBCTransferStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { - return xxx_messageInfo_EventQuotaPause.Marshal(b, m, deterministic) + return xxx_messageInfo_EventIBCTransferStatus.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) @@ -90,27 +90,27 @@ func (m *EventQuotaPause) XXX_Marshal(b []byte, deterministic bool) ([]byte, err return b[:n], nil } } -func (m *EventQuotaPause) XXX_Merge(src proto.Message) { - xxx_messageInfo_EventQuotaPause.Merge(m, src) +func (m *EventIBCTransferStatus) XXX_Merge(src proto.Message) { + xxx_messageInfo_EventIBCTransferStatus.Merge(m, src) } -func (m *EventQuotaPause) XXX_Size() int { +func (m *EventIBCTransferStatus) XXX_Size() int { return m.Size() } -func (m *EventQuotaPause) XXX_DiscardUnknown() { - xxx_messageInfo_EventQuotaPause.DiscardUnknown(m) +func (m *EventIBCTransferStatus) XXX_DiscardUnknown() { + xxx_messageInfo_EventIBCTransferStatus.DiscardUnknown(m) } -var xxx_messageInfo_EventQuotaPause proto.InternalMessageInfo +var xxx_messageInfo_EventIBCTransferStatus proto.InternalMessageInfo func init() { proto.RegisterType((*EventBadRevert)(nil), "umee.uibc.v1.EventBadRevert") - proto.RegisterType((*EventQuotaPause)(nil), "umee.uibc.v1.EventQuotaPause") + proto.RegisterType((*EventIBCTransferStatus)(nil), "umee.uibc.v1.EventIBCTransferStatus") } func init() { proto.RegisterFile("umee/uibc/v1/events.proto", fileDescriptor_c64e60b79cebf048) } var fileDescriptor_c64e60b79cebf048 = []byte{ - // 266 bytes of a gzipped FileDescriptorProto + // 260 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2c, 0xcd, 0x4d, 0x4d, 0xd5, 0x2f, 0xcd, 0x4c, 0x4a, 0xd6, 0x2f, 0x33, 0xd4, 0x4f, 0x2d, 0x4b, 0xcd, 0x2b, 0x29, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x01, 0x49, 0xe9, 0x81, 0xa4, 0xf4, 0xca, 0x0c, 0xa5, @@ -119,15 +119,15 @@ var fileDescriptor_c64e60b79cebf048 = []byte{ 0x94, 0xa0, 0xd4, 0xb2, 0xd4, 0xa2, 0x12, 0x21, 0x45, 0x2e, 0x9e, 0xb4, 0xc4, 0xcc, 0x9c, 0xd2, 0xa2, 0xd4, 0xf8, 0x92, 0xca, 0x82, 0x54, 0x09, 0x46, 0x05, 0x46, 0x0d, 0xce, 0x20, 0x6e, 0xa8, 0x58, 0x48, 0x65, 0x41, 0xaa, 0x90, 0x18, 0x17, 0x5b, 0x41, 0x62, 0x72, 0x76, 0x6a, 0x89, 0x04, - 0x13, 0x58, 0x12, 0xca, 0x53, 0xf2, 0xe2, 0xe2, 0x07, 0x1b, 0x16, 0x08, 0xb2, 0x20, 0x20, 0xb1, - 0xb4, 0x38, 0x55, 0xc8, 0x9c, 0x8b, 0xad, 0xb8, 0x24, 0xb1, 0xa4, 0xb4, 0x18, 0x6c, 0x0e, 0x9f, - 0x91, 0xbc, 0x1e, 0xb2, 0x73, 0xf5, 0x3c, 0x9d, 0x9c, 0x43, 0x8a, 0x12, 0xf3, 0x8a, 0xd3, 0x52, - 0x8b, 0x82, 0xc1, 0xca, 0x82, 0xa0, 0xca, 0x9d, 0x5c, 0x4e, 0x3c, 0x94, 0x63, 0x38, 0xf1, 0x48, - 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, - 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xb5, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, - 0xe4, 0xfc, 0x5c, 0x7d, 0x90, 0x81, 0xba, 0x79, 0xa9, 0x25, 0xe5, 0xf9, 0x45, 0xd9, 0x60, 0x8e, - 0x7e, 0x99, 0x89, 0x7e, 0x05, 0xd8, 0xb7, 0x49, 0x6c, 0x60, 0x5f, 0x1a, 0x03, 0x02, 0x00, 0x00, - 0xff, 0xff, 0x3f, 0x48, 0xe0, 0x6d, 0x40, 0x01, 0x00, 0x00, + 0x13, 0x58, 0x12, 0xca, 0x53, 0x0a, 0xe4, 0x12, 0x03, 0x1b, 0xe6, 0xe9, 0xe4, 0x1c, 0x52, 0x94, + 0x98, 0x57, 0x9c, 0x96, 0x5a, 0x14, 0x5c, 0x92, 0x58, 0x52, 0x5a, 0x2c, 0x64, 0xce, 0xc5, 0x56, + 0x0c, 0x66, 0x81, 0x8d, 0xe3, 0x33, 0x92, 0xd7, 0x43, 0x76, 0xb5, 0x1e, 0x86, 0x86, 0x20, 0xa8, + 0x72, 0x27, 0x97, 0x13, 0x0f, 0xe5, 0x18, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, + 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, + 0x21, 0x4a, 0x2d, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x64, 0xa0, + 0x6e, 0x5e, 0x6a, 0x49, 0x79, 0x7e, 0x51, 0x36, 0x98, 0xa3, 0x5f, 0x66, 0xa2, 0x5f, 0x01, 0xf6, + 0x74, 0x12, 0x1b, 0xd8, 0xb3, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x2f, 0xc0, 0x80, 0xb6, + 0x47, 0x01, 0x00, 0x00, } func (m *EventBadRevert) Marshal() (dAtA []byte, err error) { @@ -167,7 +167,7 @@ func (m *EventBadRevert) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } -func (m *EventQuotaPause) Marshal() (dAtA []byte, err error) { +func (m *EventIBCTransferStatus) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) @@ -177,12 +177,12 @@ func (m *EventQuotaPause) Marshal() (dAtA []byte, err error) { return dAtA[:n], nil } -func (m *EventQuotaPause) MarshalTo(dAtA []byte) (int, error) { +func (m *EventIBCTransferStatus) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } -func (m *EventQuotaPause) MarshalToSizedBuffer(dAtA []byte) (int, error) { +func (m *EventIBCTransferStatus) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int @@ -223,7 +223,7 @@ func (m *EventBadRevert) Size() (n int) { return n } -func (m *EventQuotaPause) Size() (n int) { +func (m *EventIBCTransferStatus) Size() (n int) { if m == nil { return 0 } @@ -355,7 +355,7 @@ func (m *EventBadRevert) Unmarshal(dAtA []byte) error { } return nil } -func (m *EventQuotaPause) Unmarshal(dAtA []byte) error { +func (m *EventIBCTransferStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -378,10 +378,10 @@ func (m *EventQuotaPause) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: EventQuotaPause: wiretype end group for non-group") + return fmt.Errorf("proto: EventIBCTransferStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: EventQuotaPause: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: EventIBCTransferStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: diff --git a/x/uibc/msg.go b/x/uibc/msg.go index e94c126ac8..4f79ec5b4e 100644 --- a/x/uibc/msg.go +++ b/x/uibc/msg.go @@ -11,7 +11,7 @@ import ( var ( _ sdk.Msg = &MsgGovUpdateQuota{} - _ sdk.Msg = &MsgGovSetIBCPause{} + _ sdk.Msg = &MsgGovSetIBCStatus{} ) // GetTitle returns the title of the proposal. @@ -64,30 +64,30 @@ func (msg *MsgGovUpdateQuota) GetSigners() []sdk.AccAddress { } // GetTitle implements govv1b1.Content interface. -func (msg *MsgGovSetIBCPause) GetTitle() string { return msg.Title } +func (msg *MsgGovSetIBCStatus) GetTitle() string { return msg.Title } // GetDescription implements govv1b1.Content interface. -func (msg *MsgGovSetIBCPause) GetDescription() string { return msg.Description } +func (msg *MsgGovSetIBCStatus) GetDescription() string { return msg.Description } // Route implements Msg -func (msg MsgGovSetIBCPause) Route() string { return RouterKey } +func (msg MsgGovSetIBCStatus) Route() string { return RouterKey } // Type implements Msg -func (msg MsgGovSetIBCPause) Type() string { return sdk.MsgTypeURL(&msg) } +func (msg MsgGovSetIBCStatus) Type() string { return sdk.MsgTypeURL(&msg) } // String implements the Stringer interface. -func (msg *MsgGovSetIBCPause) String() string { +func (msg *MsgGovSetIBCStatus) String() string { out, _ := json.Marshal(msg) return string(out) } // ValidateBasic implements Msg -func (msg *MsgGovSetIBCPause) ValidateBasic() error { +func (msg *MsgGovSetIBCStatus) ValidateBasic() error { if err := checkers.ValidateAddr(msg.Authority, "authority"); err != nil { return err } - if err := validateIBCTransferStatus(msg.IbcPauseStatus); err != nil { + if err := validateIBCTransferStatus(msg.IbcStatus); err != nil { return err } @@ -95,12 +95,12 @@ func (msg *MsgGovSetIBCPause) ValidateBasic() error { } // GetSignBytes implements Msg -func (msg *MsgGovSetIBCPause) GetSignBytes() []byte { +func (msg *MsgGovSetIBCStatus) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(msg) return sdk.MustSortJSON(bz) } // GetSigners implements Msg -func (msg *MsgGovSetIBCPause) GetSigners() []sdk.AccAddress { +func (msg *MsgGovSetIBCStatus) GetSigners() []sdk.AccAddress { return checkers.Signers(msg.Authority) } diff --git a/x/uibc/msg_test.go b/x/uibc/msg_test.go index e10c2c2032..68ba565417 100644 --- a/x/uibc/msg_test.go +++ b/x/uibc/msg_test.go @@ -62,27 +62,27 @@ func TestMsgGovUpdateQuota(t *testing.T) { } } -func validMsgGovSetIBCPause() MsgGovSetIBCPause { - return MsgGovSetIBCPause{ - Title: "title", - Authority: authtypes.NewModuleAddress("gov").String(), - Description: "desc", - IbcPauseStatus: 1, +func validMsgGovSetIBCStatus() MsgGovSetIBCStatus { + return MsgGovSetIBCStatus{ + Title: "title", + Authority: authtypes.NewModuleAddress("gov").String(), + Description: "desc", + IbcStatus: 1, } } -func TestMsgGovSetIBCPause(t *testing.T) { +func TestMsgGovSetIBCStatus(t *testing.T) { t.Parallel() - validMsg := validMsgGovSetIBCPause() + validMsg := validMsgGovSetIBCStatus() invalidAuthority := validMsg invalidAuthority.Authority = authtypes.NewModuleAddress("govv").String() - invalidIBCPauseStatus := validMsg - invalidIBCPauseStatus.IbcPauseStatus = 10 + invalidIBCStatus := validMsg + invalidIBCStatus.IbcStatus = 10 tests := []struct { - msg MsgGovSetIBCPause + msg MsgGovSetIBCStatus name string errMsg string }{ @@ -96,7 +96,7 @@ func TestMsgGovSetIBCPause(t *testing.T) { errMsg: "invalid authority", }, { name: "invalid ibc pause status in msg", - msg: invalidIBCPauseStatus, + msg: invalidIBCStatus, errMsg: "invalid ibc-transfer status", }, } diff --git a/x/uibc/params.go b/x/uibc/params.go index 0468c37a18..027859969b 100644 --- a/x/uibc/params.go +++ b/x/uibc/params.go @@ -10,7 +10,7 @@ import ( // DefaultParams returns default genesis params func DefaultParams() Params { return Params{ - IbcPause: IBCTransferStatus_IBC_TRANSFER_STATUS_DISABLED, + IbcStatus: IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_ENABLED, TotalQuota: sdk.NewDec(1_000_000), TokenQuota: sdk.NewDec(600_000), QuotaDuration: time.Second * 60 * 60 * 24, // 24h @@ -18,22 +18,18 @@ func DefaultParams() Params { } func (p Params) Validate() error { - if err := validateIBCTransferStatus(p.IbcPause); err != nil { + if err := validateIBCTransferStatus(p.IbcStatus); err != nil { return err } - if err := validateQuotaDuration(p.QuotaDuration); err != nil { return err } - if err := validateQuota(p.TotalQuota, "total quota"); err != nil { return err } - if err := validateQuota(p.TokenQuota, "quota per token"); err != nil { return err } - if p.TotalQuota.LT(p.TokenQuota) { return fmt.Errorf("token quota shouldn't be less than quota per denom") } @@ -42,9 +38,9 @@ func (p Params) Validate() error { } func validateIBCTransferStatus(status IBCTransferStatus) error { - if status == IBCTransferStatus_IBC_TRANSFER_STATUS_DISABLED || - status == IBCTransferStatus_IBC_TRANSFER_STATUS_ENABLED || - status == IBCTransferStatus_IBC_TRANSFER_STATUS_PAUSED { + if status == IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_DISABLED || + status == IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_ENABLED || + status == IBCTransferStatus_IBC_TRANSFER_STATUS_TRANSFERS_PAUSED { return nil } diff --git a/x/uibc/quota.pb.go b/x/uibc/quota.pb.go index fadc1d6eaf..b0bc83a27e 100644 --- a/x/uibc/quota.pb.go +++ b/x/uibc/quota.pb.go @@ -35,26 +35,26 @@ type IBCTransferStatus int32 const ( // UNSPECIFIED defines a no-op status. IBCTransferStatus_IBC_TRANSFER_STATUS_UNSPECIFIED IBCTransferStatus = 0 - // DISABLED defines the quota checking diabled for ibc-transfer. - IBCTransferStatus_IBC_TRANSFER_STATUS_DISABLED IBCTransferStatus = 1 - // ENABLED defines the enable quota checking for ibc-transfer. - IBCTransferStatus_IBC_TRANSFER_STATUS_ENABLED IBCTransferStatus = 2 - // PAUSED defines pause the ibc-transfer from app. - IBCTransferStatus_IBC_TRANSFER_STATUS_PAUSED IBCTransferStatus = 3 + // DISABLED: quota checks are disabled. + IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_DISABLED IBCTransferStatus = 1 + // ENABLED: quota checks are enabled. + IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_ENABLED IBCTransferStatus = 2 + // PAUSED: all IBC transfers are paused. + IBCTransferStatus_IBC_TRANSFER_STATUS_TRANSFERS_PAUSED IBCTransferStatus = 3 ) var IBCTransferStatus_name = map[int32]string{ 0: "IBC_TRANSFER_STATUS_UNSPECIFIED", - 1: "IBC_TRANSFER_STATUS_DISABLED", - 2: "IBC_TRANSFER_STATUS_ENABLED", - 3: "IBC_TRANSFER_STATUS_PAUSED", + 1: "IBC_TRANSFER_STATUS_QUOTA_DISABLED", + 2: "IBC_TRANSFER_STATUS_QUOTA_ENABLED", + 3: "IBC_TRANSFER_STATUS_TRANSFERS_PAUSED", } var IBCTransferStatus_value = map[string]int32{ - "IBC_TRANSFER_STATUS_UNSPECIFIED": 0, - "IBC_TRANSFER_STATUS_DISABLED": 1, - "IBC_TRANSFER_STATUS_ENABLED": 2, - "IBC_TRANSFER_STATUS_PAUSED": 3, + "IBC_TRANSFER_STATUS_UNSPECIFIED": 0, + "IBC_TRANSFER_STATUS_QUOTA_DISABLED": 1, + "IBC_TRANSFER_STATUS_QUOTA_ENABLED": 2, + "IBC_TRANSFER_STATUS_TRANSFERS_PAUSED": 3, } func (x IBCTransferStatus) String() string { @@ -68,7 +68,7 @@ func (IBCTransferStatus) EnumDescriptor() ([]byte, []int) { // Params of x/uibc module type Params struct { // ibc_status defines the wethever ibc-transfer enabled, disbaled or paused - IbcPause IBCTransferStatus `protobuf:"varint,1,opt,name=ibc_pause,json=ibcPause,proto3,enum=umee.uibc.v1.IBCTransferStatus" json:"ibc_pause,omitempty"` + IbcStatus IBCTransferStatus `protobuf:"varint,1,opt,name=ibc_status,json=ibcStatus,proto3,enum=umee.uibc.v1.IBCTransferStatus" json:"ibc_status,omitempty"` // total_quota defines the total outflow limit of ibc-transfer in USD TotalQuota github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,2,opt,name=total_quota,json=totalQuota,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"total_quota"` // token_quota defines the outflow limit per token in USD @@ -110,9 +110,9 @@ func (m *Params) XXX_DiscardUnknown() { var xxx_messageInfo_Params proto.InternalMessageInfo -func (m *Params) GetIbcPause() IBCTransferStatus { +func (m *Params) GetIbcStatus() IBCTransferStatus { if m != nil { - return m.IbcPause + return m.IbcStatus } return IBCTransferStatus_IBC_TRANSFER_STATUS_UNSPECIFIED } @@ -132,37 +132,37 @@ func init() { func init() { proto.RegisterFile("umee/uibc/v1/quota.proto", fileDescriptor_651be1a0280abcb6) } var fileDescriptor_651be1a0280abcb6 = []byte{ - // 470 bytes of a gzipped FileDescriptorProto + // 478 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x92, 0x41, 0x8b, 0xd3, 0x40, - 0x14, 0xc7, 0x33, 0x5b, 0x59, 0xdc, 0x59, 0x5d, 0x6a, 0x50, 0xc8, 0x56, 0x49, 0x4a, 0x05, 0x29, - 0x62, 0x67, 0xd8, 0xd5, 0x93, 0xac, 0x60, 0xd3, 0x64, 0x21, 0x20, 0xa5, 0x26, 0xed, 0x45, 0x90, - 0x30, 0xc9, 0xce, 0xc6, 0xd0, 0x26, 0x53, 0x93, 0x49, 0xb5, 0x27, 0x4f, 0xde, 0x3d, 0x0a, 0x7e, - 0x0d, 0x3f, 0xc4, 0x1e, 0x17, 0x4f, 0xe2, 0xa1, 0x4a, 0x7b, 0xf3, 0xe8, 0x27, 0x90, 0xcc, 0xa4, - 0xb0, 0xc5, 0x1e, 0x3d, 0x25, 0x6f, 0xfe, 0xff, 0xf7, 0x7b, 0x8f, 0x3f, 0x0f, 0x6a, 0x45, 0x42, - 0x29, 0x2e, 0xe2, 0x20, 0xc4, 0xb3, 0x23, 0xfc, 0xb6, 0x60, 0x9c, 0xa0, 0x69, 0xc6, 0x38, 0x53, - 0x6f, 0x94, 0x0a, 0x2a, 0x15, 0x34, 0x3b, 0x6a, 0xdc, 0x8e, 0x58, 0xc4, 0x84, 0x80, 0xcb, 0x3f, - 0xe9, 0x69, 0xe8, 0x11, 0x63, 0xd1, 0x84, 0x62, 0x51, 0x05, 0xc5, 0x39, 0x3e, 0x2b, 0x32, 0xc2, - 0x63, 0x96, 0x56, 0xfa, 0x61, 0xc8, 0xf2, 0x84, 0xe5, 0xbe, 0x6c, 0x94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 0x42, 0x05, 0x1f, 0x97, 0xaa, 0x74, + 0xbe, 0x54, 0xa5, 0x6f, 0x4b, 0x55, 0x7a, 0x79, 0xf1, 0x42, 0xaa, 0x27, 0xd4, 0xcd, 0x08, 0x7b, + 0x4b, 0xf3, 0x11, 0x17, 0xfa, 0xf4, 0xa1, 0xfe, 0x8e, 0xbf, 0xf6, 0x70, 0x93, 0xd7, 0xfa, 0xe0, + 0x4f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x26, 0x38, 0x22, 0xb8, 0x01, 0x03, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -213,8 +213,8 @@ func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { } i-- dAtA[i] = 0x12 - if m.IbcPause != 0 { - i = encodeVarintQuota(dAtA, i, uint64(m.IbcPause)) + if m.IbcStatus != 0 { + i = encodeVarintQuota(dAtA, i, uint64(m.IbcStatus)) i-- dAtA[i] = 0x8 } @@ -238,8 +238,8 @@ func (m *Params) Size() (n int) { } var l int _ = l - if m.IbcPause != 0 { - n += 1 + sovQuota(uint64(m.IbcPause)) + if m.IbcStatus != 0 { + n += 1 + sovQuota(uint64(m.IbcStatus)) } l = m.TotalQuota.Size() n += 1 + l + sovQuota(uint64(l)) @@ -287,9 +287,9 @@ func (m *Params) Unmarshal(dAtA []byte) error { switch fieldNum { case 1: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field IbcPause", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field IbcStatus", wireType) } - m.IbcPause = 0 + m.IbcStatus = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuota @@ -299,7 +299,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.IbcPause |= IBCTransferStatus(b&0x7F) << shift + m.IbcStatus |= IBCTransferStatus(b&0x7F) << shift if b < 0x80 { break } diff --git a/x/uibc/quota/keeper/genesis_test.go b/x/uibc/quota/keeper/genesis_test.go index ec64f5c954..e1c22bab68 100644 --- a/x/uibc/quota/keeper/genesis_test.go +++ b/x/uibc/quota/keeper/genesis_test.go @@ -12,9 +12,10 @@ func TestInitGenesis(t *testing.T) { app, ctx := s.app, s.ctx defaultGs := uibc.DefaultGenesisState() + assert.Equal(t, uibc.IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_ENABLED, defaultGs.Params.IbcStatus) app.UIbcQuotaKeeper.InitGenesis(ctx, *defaultGs) params := app.UIbcQuotaKeeper.GetParams(ctx) - assert.Equal(t, params.IbcPause, defaultGs.Params.IbcPause) + assert.Equal(t, params.IbcStatus, defaultGs.Params.IbcStatus) } func TestExportGenesis(t *testing.T) { @@ -25,8 +26,8 @@ func TestExportGenesis(t *testing.T) { eGs := app.UIbcQuotaKeeper.ExportGenesis(ctx) assert.DeepEqual(t, eGs, defaultGs) // update params in genesis state - defaultGs.Params.IbcPause = uibc.IBCTransferStatus_IBC_TRANSFER_STATUS_ENABLED + defaultGs.Params.IbcStatus = uibc.IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_DISABLED app.UIbcQuotaKeeper.InitGenesis(ctx, *defaultGs) eGs = app.UIbcQuotaKeeper.ExportGenesis(ctx) - assert.Equal(t, eGs.Params.IbcPause, uibc.IBCTransferStatus_IBC_TRANSFER_STATUS_ENABLED) + assert.Equal(t, eGs.Params.IbcStatus, uibc.IBCTransferStatus_IBC_TRANSFER_STATUS_QUOTA_DISABLED) } diff --git a/x/uibc/quota/keeper/msg_server.go b/x/uibc/quota/keeper/msg_server.go index 81772d7b69..34e4e8e15b 100644 --- a/x/uibc/quota/keeper/msg_server.go +++ b/x/uibc/quota/keeper/msg_server.go @@ -37,22 +37,22 @@ func (m msgServer) GovUpdateQuota(goCtx context.Context, msg *uibc.MsgGovUpdateQ return &uibc.MsgGovUpdateQuotaResponse{}, nil } -// GovSetIBCPause implements types.MsgServer -func (m msgServer) GovSetIBCPause( - goCtx context.Context, msg *uibc.MsgGovSetIBCPause, -) (*uibc.MsgGovSetIBCPauseResponse, error) { +// GovSetIBCStatus implements types.MsgServer +func (m msgServer) GovSetIBCStatus( + goCtx context.Context, msg *uibc.MsgGovSetIBCStatus, +) (*uibc.MsgGovSetIBCStatusResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if err := msg.ValidateBasic(); err != nil { return nil, err } - if err := m.keeper.SetIBCPause(ctx, msg.IbcPauseStatus); err != nil { - return &uibc.MsgGovSetIBCPauseResponse{}, err + if err := m.keeper.SetIBCStatus(ctx, msg.IbcStatus); err != nil { + return &uibc.MsgGovSetIBCStatusResponse{}, err } - sdkutil.Emit(&ctx, &uibc.EventQuotaPause{ - Status: msg.IbcPauseStatus, + sdkutil.Emit(&ctx, &uibc.EventIBCTransferStatus{ + Status: msg.IbcStatus, }) - return &uibc.MsgGovSetIBCPauseResponse{}, nil + return &uibc.MsgGovSetIBCStatusResponse{}, nil } diff --git a/x/uibc/quota/keeper/msg_server_test.go b/x/uibc/quota/keeper/msg_server_test.go index 5b1bcd0686..9a493dbbba 100644 --- a/x/uibc/quota/keeper/msg_server_test.go +++ b/x/uibc/quota/keeper/msg_server_test.go @@ -88,41 +88,41 @@ func TestMsgServer_GovUpdateQuota(t *testing.T) { } } -func TestMsgServer_GovSetIBCPause(t *testing.T) { +func TestMsgServer_GovSetIBCStatus(t *testing.T) { t.Parallel() s := initKeeperTestSuite(t) ctx := s.ctx tests := []struct { name string - msg uibc.MsgGovSetIBCPause + msg uibc.MsgGovSetIBCStatus errMsg string }{ { name: "invalid authority address in msg", - msg: uibc.MsgGovSetIBCPause{ - Title: "title", - Description: "desc", - Authority: authtypes.NewModuleAddress("govv").String(), - IbcPauseStatus: 1, + msg: uibc.MsgGovSetIBCStatus{ + Title: "title", + Description: "desc", + Authority: authtypes.NewModuleAddress("govv").String(), + IbcStatus: 1, }, errMsg: "expected gov account as only signer for proposal message", }, { name: "invalid ibc-transfer status in msg", - msg: uibc.MsgGovSetIBCPause{ - Title: "title", - Description: "desc", - Authority: authtypes.NewModuleAddress("gov").String(), - IbcPauseStatus: 5, + msg: uibc.MsgGovSetIBCStatus{ + Title: "title", + Description: "desc", + Authority: authtypes.NewModuleAddress("gov").String(), + IbcStatus: 5, }, errMsg: "invalid ibc-transfer status", }, { name: "valid in msg 0 { n += 1 + l + sovTx(uint64(l)) } - if m.IbcPauseStatus != 0 { - n += 1 + sovTx(uint64(m.IbcPauseStatus)) + if m.IbcStatus != 0 { + n += 1 + sovTx(uint64(m.IbcStatus)) } return n } -func (m *MsgGovSetIBCPauseResponse) Size() (n int) { +func (m *MsgGovSetIBCStatusResponse) Size() (n int) { if m == nil { return 0 } @@ -934,7 +934,7 @@ func (m *MsgGovUpdateQuotaResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *MsgGovSetIBCPause) Unmarshal(dAtA []byte) error { +func (m *MsgGovSetIBCStatus) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -957,10 +957,10 @@ func (m *MsgGovSetIBCPause) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: MsgGovSetIBCPause: wiretype end group for non-group") + return fmt.Errorf("proto: MsgGovSetIBCStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: MsgGovSetIBCPause: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: MsgGovSetIBCStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -1061,9 +1061,9 @@ func (m *MsgGovSetIBCPause) Unmarshal(dAtA []byte) error { iNdEx = postIndex case 4: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field IbcPauseStatus", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field IbcStatus", wireType) } - m.IbcPauseStatus = 0 + m.IbcStatus = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx @@ -1073,7 +1073,7 @@ func (m *MsgGovSetIBCPause) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.IbcPauseStatus |= IBCTransferStatus(b&0x7F) << shift + m.IbcStatus |= IBCTransferStatus(b&0x7F) << shift if b < 0x80 { break } @@ -1099,7 +1099,7 @@ func (m *MsgGovSetIBCPause) Unmarshal(dAtA []byte) error { } return nil } -func (m *MsgGovSetIBCPauseResponse) Unmarshal(dAtA []byte) error { +func (m *MsgGovSetIBCStatusResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -1122,10 +1122,10 @@ func (m *MsgGovSetIBCPauseResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: MsgGovSetIBCPauseResponse: wiretype end group for non-group") + return fmt.Errorf("proto: MsgGovSetIBCStatusResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: MsgGovSetIBCPauseResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: MsgGovSetIBCStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: