diff --git a/proto/elys/commitment/tx.proto b/proto/elys/commitment/tx.proto index 76aad91be..c2fb2078e 100644 --- a/proto/elys/commitment/tx.proto +++ b/proto/elys/commitment/tx.proto @@ -78,6 +78,13 @@ message MsgVest { string denom = 3; } +message MsgVestCW { + string creator = 1; + string address = 2; + string amount = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; + string denom = 4; +} + message MsgVestResponse {} message MsgCancelVest { @@ -86,6 +93,13 @@ message MsgCancelVest { string denom = 3; } +message MsgCancelVestCW { + string creator = 1; + string address = 2; + string amount = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; + string denom = 4; +} + message MsgCancelVestResponse {} message MsgVestNow { @@ -124,9 +138,10 @@ message MsgClaimRewardsResponse {} message MsgStake { string creator = 1; - string amount = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; - string asset = 3; - string validator_address = 4; + string address = 2; + string amount = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; + string asset = 4; + string validator_address = 5; } message MsgStakeResponse { @@ -136,9 +151,10 @@ message MsgStakeResponse { message MsgUnstake { string creator = 1; - string amount = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; - string asset = 3; - string validator_address = 4; + string address = 2; + string amount = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; + string asset = 4; + string validator_address = 5; } message MsgUnstakeResponse { diff --git a/proto/elys/incentive/tx.proto b/proto/elys/incentive/tx.proto index 765ef1841..846f922f5 100644 --- a/proto/elys/incentive/tx.proto +++ b/proto/elys/incentive/tx.proto @@ -5,6 +5,7 @@ package elys.incentive; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; import "elys/commitment/params.proto"; +import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/elys-network/elys/x/incentive/types"; @@ -25,8 +26,9 @@ service Msg { message MsgWithdrawRewards { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - elys.commitment.EarnType withdraw_type = 2; + string creator = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string delegator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + elys.commitment.EarnType withdraw_type = 3; } // MsgWithdrawDelegatorRewardResponse defines the Msg/WithdrawDelegatorReward response type. @@ -37,8 +39,9 @@ message MsgWithdrawRewardsResponse {} message MsgWithdrawValidatorCommission { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string creator = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string delegator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string validator_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; } // MsgWithdrawValidatorCommissionResponse defines the Msg/WithdrawValidatorCommission response type. @@ -70,3 +73,26 @@ message MsgUpdateIncentiveParams { message MsgUpdateIncentiveParamsResponse {} +message MsgBeginRedelegate { + option (gogoproto.equal) = false; + option (gogoproto.goproto_getters) = false; + + string creator = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string delegator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string validator_src_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string validator_dst_address = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + cosmos.base.v1beta1.Coin amount = 5 [(gogoproto.nullable) = false]; +} + +message MsgCancelUnbondingDelegation{ + option (gogoproto.equal) = false; + option (gogoproto.goproto_getters) = false; + + string creator = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string delegator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string validator_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + // amount is always less than or equal to unbonding delegation entry balance + cosmos.base.v1beta1.Coin amount = 4 [(gogoproto.nullable) = false]; + // creation_height is the height which the unbonding took place. + int64 creation_height = 5; +} \ No newline at end of file diff --git a/wasmbindings/types/types.go b/wasmbindings/types/types.go index c85d9d4ed..3a18b15c4 100644 --- a/wasmbindings/types/types.go +++ b/wasmbindings/types/types.go @@ -9,7 +9,6 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" accountedpoolkeeper "github.com/elys-network/elys/x/accountedpool/keeper" accountedpooltypes "github.com/elys-network/elys/x/accountedpool/types" ammkeeper "github.com/elys-network/elys/x/amm/keeper" @@ -254,10 +253,10 @@ type ElysMsg struct { CommitmentCommitLiquidTokens *commitmenttypes.MsgCommitLiquidTokens `json:"commitment_commit_liquid_tokens,omitempty"` CommitmentCommitUnclaimedRewards *commitmenttypes.MsgCommitClaimedRewards `json:"commitment_commit_unclaimed_rewards,omitempty"` CommitmentUncommitTokens *commitmenttypes.MsgUncommitTokens `json:"commitment_uncommit_tokens,omitempty"` - CommitmentVest *commitmenttypes.MsgVest `json:"commitment_vest"` + CommitmentVest *commitmenttypes.MsgVestCW `json:"commitment_vest"` CommitmentVestNow *commitmenttypes.MsgVestNow `json:"commitment_vest_now"` CommitmentVestLiquid *commitmenttypes.MsgVestLiquid `json:"commitment_vest_liquid"` - CommitmentCancelVest *commitmenttypes.MsgCancelVest `json:"commitment_cancel_vest"` + CommitmentCancelVest *commitmenttypes.MsgCancelVestCW `json:"commitment_cancel_vest"` CommitmentUpdateVestingInfo *commitmenttypes.MsgUpdateVestingInfo `json:"commitment_update_vesting_info"` CommitmentStake *commitmenttypes.MsgStake `json:"commitment_stake,omitempty"` CommitmentUnstake *commitmenttypes.MsgUnstake `json:"commitment_unstake,omitempty"` @@ -265,8 +264,8 @@ type ElysMsg struct { // epochs messages // incentive messages - IncentiveBeginRedelegate *stakingtypes.MsgBeginRedelegate `json:"incentive_begin_redelegate,omitempty"` - IncentiveCancelUnbondingDelegation *stakingtypes.MsgCancelUnbondingDelegation `json:"incentive_cancel_unbonding_delegation"` + IncentiveBeginRedelegate *incentivetypes.MsgBeginRedelegate `json:"incentive_begin_redelegate,omitempty"` + IncentiveCancelUnbondingDelegation *incentivetypes.MsgCancelUnbondingDelegation `json:"incentive_cancel_unbonding_delegation"` IncentiveWithdrawRewards *incentivetypes.MsgWithdrawRewards `json:"incentive_withdraw_rewards"` IncentiveWithdrawValidatorCommission *incentivetypes.MsgWithdrawValidatorCommission `json:"incentive_withdraw_validator_commission"` diff --git a/x/commitment/client/wasm/msg_cancel_vest.go b/x/commitment/client/wasm/msg_cancel_vest.go index 2948a2ea3..70b7d57f3 100644 --- a/x/commitment/client/wasm/msg_cancel_vest.go +++ b/x/commitment/client/wasm/msg_cancel_vest.go @@ -12,7 +12,7 @@ import ( paramtypes "github.com/elys-network/elys/x/parameter/types" ) -func (m *Messenger) msgCancelVest(ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelVest *commitmenttypes.MsgCancelVest) ([]sdk.Event, [][]byte, error) { +func (m *Messenger) msgCancelVest(ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelVest *commitmenttypes.MsgCancelVestCW) ([]sdk.Event, [][]byte, error) { if msgCancelVest == nil { return nil, nil, wasmvmtypes.InvalidRequest{Err: "cancel vest null msg"} } @@ -43,13 +43,13 @@ func (m *Messenger) msgCancelVest(ctx sdk.Context, contractAddr sdk.AccAddress, return nil, resp, nil } -func performMsgCancelVestEden(f *commitmentkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelVest *commitmenttypes.MsgCancelVest) (*wasmbindingstypes.RequestResponse, error) { +func performMsgCancelVestEden(f *commitmentkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelVest *commitmenttypes.MsgCancelVestCW) (*wasmbindingstypes.RequestResponse, error) { if msgCancelVest == nil { return nil, wasmvmtypes.InvalidRequest{Err: "Invalid cancel vesting parameter"} } msgServer := commitmentkeeper.NewMsgServerImpl(*f) - msgMsgCancelVest := commitmenttypes.NewMsgCancelVest(msgCancelVest.Creator, msgCancelVest.Amount, msgCancelVest.Denom) + msgMsgCancelVest := commitmenttypes.NewMsgCancelVest(msgCancelVest.Address, msgCancelVest.Amount, msgCancelVest.Denom) if err := msgMsgCancelVest.ValidateBasic(); err != nil { return nil, errorsmod.Wrap(err, "failed validating msgMsgCancelVest") diff --git a/x/commitment/client/wasm/msg_stake.go b/x/commitment/client/wasm/msg_stake.go index d27662e95..26d13637f 100644 --- a/x/commitment/client/wasm/msg_stake.go +++ b/x/commitment/client/wasm/msg_stake.go @@ -34,7 +34,7 @@ func (m *Messenger) msgStake(ctx sdk.Context, contractAddr sdk.AccAddress, msgSt // USDC if msgStake.Asset == baseCurrency { msgServer := stablekeeper.NewMsgServerImpl(*m.stableKeeper) - msgMsgBond := stabletypes.NewMsgBond(msgStake.Creator, msgStake.Amount) + msgMsgBond := stabletypes.NewMsgBond(msgStake.Address, msgStake.Amount) if err = msgMsgBond.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msgMsgBond") @@ -51,7 +51,7 @@ func (m *Messenger) msgStake(ctx sdk.Context, contractAddr sdk.AccAddress, msgSt } else { // Elys, Eden, Eden Boost msgServer := commitmentkeeper.NewMsgServerImpl(*m.keeper) - msgMsgStake := commitmenttypes.NewMsgStake(msgStake.Creator, msgStake.Amount, msgStake.Asset, msgStake.ValidatorAddress) + msgMsgStake := commitmenttypes.NewMsgStake(msgStake.Address, msgStake.Amount, msgStake.Asset, msgStake.ValidatorAddress) if err = msgMsgStake.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msgMsgStake") diff --git a/x/commitment/client/wasm/msg_unstake.go b/x/commitment/client/wasm/msg_unstake.go index 1c64af3a5..adcff0ff7 100644 --- a/x/commitment/client/wasm/msg_unstake.go +++ b/x/commitment/client/wasm/msg_unstake.go @@ -34,7 +34,7 @@ func (m *Messenger) msgUnstake(ctx sdk.Context, contractAddr sdk.AccAddress, msg // USDC if msgUnstake.Asset == baseCurrency { msgServer := stablekeeper.NewMsgServerImpl(*m.stableKeeper) - msgMsgUnBond := stabletypes.NewMsgUnbond(msgUnstake.Creator, msgUnstake.Amount) + msgMsgUnBond := stabletypes.NewMsgUnbond(msgUnstake.Address, msgUnstake.Amount) if err = msgMsgUnBond.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msgMsgBond") @@ -50,7 +50,7 @@ func (m *Messenger) msgUnstake(ctx sdk.Context, contractAddr sdk.AccAddress, msg } } else { msgServer := commitmentkeeper.NewMsgServerImpl(*m.keeper) - msgMsgUnstake := commitmenttypes.NewMsgUnstake(msgUnstake.Creator, msgUnstake.Amount, msgUnstake.Asset, msgUnstake.ValidatorAddress) + msgMsgUnstake := commitmenttypes.NewMsgUnstake(msgUnstake.Address, msgUnstake.Amount, msgUnstake.Asset, msgUnstake.ValidatorAddress) if err = msgMsgUnstake.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msgMsgUnstake") diff --git a/x/commitment/client/wasm/msg_vest.go b/x/commitment/client/wasm/msg_vest.go index 51908c36c..42a7d71e6 100644 --- a/x/commitment/client/wasm/msg_vest.go +++ b/x/commitment/client/wasm/msg_vest.go @@ -12,7 +12,7 @@ import ( paramtypes "github.com/elys-network/elys/x/parameter/types" ) -func (m *Messenger) msgVest(ctx sdk.Context, contractAddr sdk.AccAddress, msgVest *commitmenttypes.MsgVest) ([]sdk.Event, [][]byte, error) { +func (m *Messenger) msgVest(ctx sdk.Context, contractAddr sdk.AccAddress, msgVest *commitmenttypes.MsgVestCW) ([]sdk.Event, [][]byte, error) { if msgVest == nil { return nil, nil, wasmvmtypes.InvalidRequest{Err: "Vest null msg"} } @@ -43,13 +43,13 @@ func (m *Messenger) msgVest(ctx sdk.Context, contractAddr sdk.AccAddress, msgVes return nil, resp, nil } -func performMsgVestEden(f *commitmentkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgVest *commitmenttypes.MsgVest) (*wasmbindingstypes.RequestResponse, error) { +func performMsgVestEden(f *commitmentkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgVest *commitmenttypes.MsgVestCW) (*wasmbindingstypes.RequestResponse, error) { if msgVest == nil { return nil, wasmvmtypes.InvalidRequest{Err: "Invalid vesting parameter"} } msgServer := commitmentkeeper.NewMsgServerImpl(*f) - msgMsgVest := commitmenttypes.NewMsgVest(msgVest.Creator, msgVest.Amount, msgVest.Denom) + msgMsgVest := commitmenttypes.NewMsgVest(msgVest.Address, msgVest.Amount, msgVest.Denom) if err := msgMsgVest.ValidateBasic(); err != nil { return nil, errorsmod.Wrap(err, "failed validating msgVest") diff --git a/x/commitment/keeper/msg_server_stake.go b/x/commitment/keeper/msg_server_stake.go index 1384ec4ff..e76a0a050 100644 --- a/x/commitment/keeper/msg_server_stake.go +++ b/x/commitment/keeper/msg_server_stake.go @@ -38,7 +38,7 @@ func (k msgServer) performStakeElys(ctx sdk.Context, msg *types.MsgStake) error msgServer := stakingkeeper.NewMsgServerImpl(stakingKeeper) - address, err := sdk.AccAddressFromBech32(msg.Creator) + address, err := sdk.AccAddressFromBech32(msg.Address) if err != nil { return errorsmod.Wrap(err, "invalid address") } @@ -63,7 +63,7 @@ func (k msgServer) performStakeElys(ctx sdk.Context, msg *types.MsgStake) error } func (k msgServer) performCommit(ctx sdk.Context, msg *types.MsgStake) error { - msgMsgCommit := types.NewMsgCommitClaimedRewards(msg.Creator, msg.Amount, msg.Asset) + msgMsgCommit := types.NewMsgCommitClaimedRewards(msg.Address, msg.Amount, msg.Asset) if err := msgMsgCommit.ValidateBasic(); err != nil { return errorsmod.Wrap(err, "failed validating msgMsgCommit") diff --git a/x/commitment/keeper/msg_server_unstake.go b/x/commitment/keeper/msg_server_unstake.go index 4218333d3..bb35150d2 100644 --- a/x/commitment/keeper/msg_server_unstake.go +++ b/x/commitment/keeper/msg_server_unstake.go @@ -39,7 +39,7 @@ func (k msgServer) performUnstakeElys(ctx sdk.Context, msg *types.MsgUnstake) er msgServer := stakingkeeper.NewMsgServerImpl(stakingKeeper) - address, err := sdk.AccAddressFromBech32(msg.Creator) + address, err := sdk.AccAddressFromBech32(msg.Address) if err != nil { return errorsmod.Wrap(err, "invalid address") } @@ -64,7 +64,7 @@ func (k msgServer) performUnstakeElys(ctx sdk.Context, msg *types.MsgUnstake) er } func (k msgServer) performUncommit(ctx sdk.Context, msg *types.MsgUnstake) error { - msgMsgUncommit := types.NewMsgUncommitTokens(msg.Creator, msg.Amount, msg.Asset) + msgMsgUncommit := types.NewMsgUncommitTokens(msg.Address, msg.Amount, msg.Asset) if err := msgMsgUncommit.ValidateBasic(); err != nil { return errorsmod.Wrap(err, "failed validating msgMsgUncommit") diff --git a/x/commitment/types/message_stake.go b/x/commitment/types/message_stake.go index fe8ac4666..431bc53f6 100644 --- a/x/commitment/types/message_stake.go +++ b/x/commitment/types/message_stake.go @@ -9,9 +9,10 @@ const TypeMsgStake = "stake" var _ sdk.Msg = &MsgStake{} -func NewMsgStake(creator string, amount sdk.Int, asset string, validatorAddress string) *MsgStake { +func NewMsgStake(address string, amount sdk.Int, asset string, validatorAddress string) *MsgStake { return &MsgStake{ - Creator: creator, + Creator: address, + Address: address, Amount: amount, Asset: asset, ValidatorAddress: validatorAddress, diff --git a/x/commitment/types/message_unstake.go b/x/commitment/types/message_unstake.go index 9bb21219a..1303faac4 100644 --- a/x/commitment/types/message_unstake.go +++ b/x/commitment/types/message_unstake.go @@ -9,9 +9,10 @@ const TypeMsgUnstake = "unstake" var _ sdk.Msg = &MsgUnstake{} -func NewMsgUnstake(creator string, amount sdk.Int, asset string, validatorAddress string) *MsgUnstake { +func NewMsgUnstake(address string, amount sdk.Int, asset string, validatorAddress string) *MsgUnstake { return &MsgUnstake{ - Creator: creator, + Creator: address, + Address: address, Amount: amount, Asset: asset, ValidatorAddress: validatorAddress, diff --git a/x/commitment/types/tx.pb.go b/x/commitment/types/tx.pb.go index 2232d4bfa..0d51862e3 100644 --- a/x/commitment/types/tx.pb.go +++ b/x/commitment/types/tx.pb.go @@ -446,6 +446,67 @@ func (m *MsgVest) GetDenom() string { return "" } +type MsgVestCW struct { + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,3,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` + Denom string `protobuf:"bytes,4,opt,name=denom,proto3" json:"denom,omitempty"` +} + +func (m *MsgVestCW) Reset() { *m = MsgVestCW{} } +func (m *MsgVestCW) String() string { return proto.CompactTextString(m) } +func (*MsgVestCW) ProtoMessage() {} +func (*MsgVestCW) Descriptor() ([]byte, []int) { + return fileDescriptor_eda78aafe7eb119c, []int{9} +} +func (m *MsgVestCW) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgVestCW) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgVestCW.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgVestCW) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgVestCW.Merge(m, src) +} +func (m *MsgVestCW) XXX_Size() int { + return m.Size() +} +func (m *MsgVestCW) XXX_DiscardUnknown() { + xxx_messageInfo_MsgVestCW.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgVestCW proto.InternalMessageInfo + +func (m *MsgVestCW) GetCreator() string { + if m != nil { + return m.Creator + } + return "" +} + +func (m *MsgVestCW) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + +func (m *MsgVestCW) GetDenom() string { + if m != nil { + return m.Denom + } + return "" +} + type MsgVestResponse struct { } @@ -453,7 +514,7 @@ func (m *MsgVestResponse) Reset() { *m = MsgVestResponse{} } func (m *MsgVestResponse) String() string { return proto.CompactTextString(m) } func (*MsgVestResponse) ProtoMessage() {} func (*MsgVestResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{9} + return fileDescriptor_eda78aafe7eb119c, []int{10} } func (m *MsgVestResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -492,7 +553,7 @@ func (m *MsgCancelVest) Reset() { *m = MsgCancelVest{} } func (m *MsgCancelVest) String() string { return proto.CompactTextString(m) } func (*MsgCancelVest) ProtoMessage() {} func (*MsgCancelVest) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{10} + return fileDescriptor_eda78aafe7eb119c, []int{11} } func (m *MsgCancelVest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -535,6 +596,67 @@ func (m *MsgCancelVest) GetDenom() string { return "" } +type MsgCancelVestCW struct { + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,3,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` + Denom string `protobuf:"bytes,4,opt,name=denom,proto3" json:"denom,omitempty"` +} + +func (m *MsgCancelVestCW) Reset() { *m = MsgCancelVestCW{} } +func (m *MsgCancelVestCW) String() string { return proto.CompactTextString(m) } +func (*MsgCancelVestCW) ProtoMessage() {} +func (*MsgCancelVestCW) Descriptor() ([]byte, []int) { + return fileDescriptor_eda78aafe7eb119c, []int{12} +} +func (m *MsgCancelVestCW) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgCancelVestCW) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgCancelVestCW.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgCancelVestCW) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgCancelVestCW.Merge(m, src) +} +func (m *MsgCancelVestCW) XXX_Size() int { + return m.Size() +} +func (m *MsgCancelVestCW) XXX_DiscardUnknown() { + xxx_messageInfo_MsgCancelVestCW.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgCancelVestCW proto.InternalMessageInfo + +func (m *MsgCancelVestCW) GetCreator() string { + if m != nil { + return m.Creator + } + return "" +} + +func (m *MsgCancelVestCW) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + +func (m *MsgCancelVestCW) GetDenom() string { + if m != nil { + return m.Denom + } + return "" +} + type MsgCancelVestResponse struct { } @@ -542,7 +664,7 @@ func (m *MsgCancelVestResponse) Reset() { *m = MsgCancelVestResponse{} } func (m *MsgCancelVestResponse) String() string { return proto.CompactTextString(m) } func (*MsgCancelVestResponse) ProtoMessage() {} func (*MsgCancelVestResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{11} + return fileDescriptor_eda78aafe7eb119c, []int{13} } func (m *MsgCancelVestResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -581,7 +703,7 @@ func (m *MsgVestNow) Reset() { *m = MsgVestNow{} } func (m *MsgVestNow) String() string { return proto.CompactTextString(m) } func (*MsgVestNow) ProtoMessage() {} func (*MsgVestNow) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{12} + return fileDescriptor_eda78aafe7eb119c, []int{14} } func (m *MsgVestNow) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -631,7 +753,7 @@ func (m *MsgVestNowResponse) Reset() { *m = MsgVestNowResponse{} } func (m *MsgVestNowResponse) String() string { return proto.CompactTextString(m) } func (*MsgVestNowResponse) ProtoMessage() {} func (*MsgVestNowResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{13} + return fileDescriptor_eda78aafe7eb119c, []int{15} } func (m *MsgVestNowResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -674,7 +796,7 @@ func (m *MsgUpdateVestingInfo) Reset() { *m = MsgUpdateVestingInfo{} } func (m *MsgUpdateVestingInfo) String() string { return proto.CompactTextString(m) } func (*MsgUpdateVestingInfo) ProtoMessage() {} func (*MsgUpdateVestingInfo) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{14} + return fileDescriptor_eda78aafe7eb119c, []int{16} } func (m *MsgUpdateVestingInfo) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -759,7 +881,7 @@ func (m *MsgUpdateVestingInfoResponse) Reset() { *m = MsgUpdateVestingIn func (m *MsgUpdateVestingInfoResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateVestingInfoResponse) ProtoMessage() {} func (*MsgUpdateVestingInfoResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{15} + return fileDescriptor_eda78aafe7eb119c, []int{17} } func (m *MsgUpdateVestingInfoResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -798,7 +920,7 @@ func (m *MsgVestLiquid) Reset() { *m = MsgVestLiquid{} } func (m *MsgVestLiquid) String() string { return proto.CompactTextString(m) } func (*MsgVestLiquid) ProtoMessage() {} func (*MsgVestLiquid) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{16} + return fileDescriptor_eda78aafe7eb119c, []int{18} } func (m *MsgVestLiquid) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -848,7 +970,7 @@ func (m *MsgVestLiquidResponse) Reset() { *m = MsgVestLiquidResponse{} } func (m *MsgVestLiquidResponse) String() string { return proto.CompactTextString(m) } func (*MsgVestLiquidResponse) ProtoMessage() {} func (*MsgVestLiquidResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{17} + return fileDescriptor_eda78aafe7eb119c, []int{19} } func (m *MsgVestLiquidResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -885,7 +1007,7 @@ func (m *MsgClaimRewards) Reset() { *m = MsgClaimRewards{} } func (m *MsgClaimRewards) String() string { return proto.CompactTextString(m) } func (*MsgClaimRewards) ProtoMessage() {} func (*MsgClaimRewards) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{18} + return fileDescriptor_eda78aafe7eb119c, []int{20} } func (m *MsgClaimRewards) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -928,7 +1050,7 @@ func (m *MsgClaimRewardsResponse) Reset() { *m = MsgClaimRewardsResponse func (m *MsgClaimRewardsResponse) String() string { return proto.CompactTextString(m) } func (*MsgClaimRewardsResponse) ProtoMessage() {} func (*MsgClaimRewardsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{19} + return fileDescriptor_eda78aafe7eb119c, []int{21} } func (m *MsgClaimRewardsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -959,16 +1081,17 @@ var xxx_messageInfo_MsgClaimRewardsResponse proto.InternalMessageInfo type MsgStake struct { Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` - Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,2,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` - Asset string `protobuf:"bytes,3,opt,name=asset,proto3" json:"asset,omitempty"` - ValidatorAddress string `protobuf:"bytes,4,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,3,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` + Asset string `protobuf:"bytes,4,opt,name=asset,proto3" json:"asset,omitempty"` + ValidatorAddress string `protobuf:"bytes,5,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` } func (m *MsgStake) Reset() { *m = MsgStake{} } func (m *MsgStake) String() string { return proto.CompactTextString(m) } func (*MsgStake) ProtoMessage() {} func (*MsgStake) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{20} + return fileDescriptor_eda78aafe7eb119c, []int{22} } func (m *MsgStake) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1004,6 +1127,13 @@ func (m *MsgStake) GetCreator() string { return "" } +func (m *MsgStake) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + func (m *MsgStake) GetAsset() string { if m != nil { return m.Asset @@ -1027,7 +1157,7 @@ func (m *MsgStakeResponse) Reset() { *m = MsgStakeResponse{} } func (m *MsgStakeResponse) String() string { return proto.CompactTextString(m) } func (*MsgStakeResponse) ProtoMessage() {} func (*MsgStakeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{21} + return fileDescriptor_eda78aafe7eb119c, []int{23} } func (m *MsgStakeResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1072,16 +1202,17 @@ func (m *MsgStakeResponse) GetResult() string { type MsgUnstake struct { Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` - Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,2,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` - Asset string `protobuf:"bytes,3,opt,name=asset,proto3" json:"asset,omitempty"` - ValidatorAddress string `protobuf:"bytes,4,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Amount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,3,opt,name=amount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"amount"` + Asset string `protobuf:"bytes,4,opt,name=asset,proto3" json:"asset,omitempty"` + ValidatorAddress string `protobuf:"bytes,5,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` } func (m *MsgUnstake) Reset() { *m = MsgUnstake{} } func (m *MsgUnstake) String() string { return proto.CompactTextString(m) } func (*MsgUnstake) ProtoMessage() {} func (*MsgUnstake) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{22} + return fileDescriptor_eda78aafe7eb119c, []int{24} } func (m *MsgUnstake) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1117,6 +1248,13 @@ func (m *MsgUnstake) GetCreator() string { return "" } +func (m *MsgUnstake) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + func (m *MsgUnstake) GetAsset() string { if m != nil { return m.Asset @@ -1140,7 +1278,7 @@ func (m *MsgUnstakeResponse) Reset() { *m = MsgUnstakeResponse{} } func (m *MsgUnstakeResponse) String() string { return proto.CompactTextString(m) } func (*MsgUnstakeResponse) ProtoMessage() {} func (*MsgUnstakeResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_eda78aafe7eb119c, []int{23} + return fileDescriptor_eda78aafe7eb119c, []int{25} } func (m *MsgUnstakeResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1193,8 +1331,10 @@ func init() { proto.RegisterType((*MsgCommitLiquidTokens)(nil), "elys.commitment.MsgCommitLiquidTokens") proto.RegisterType((*MsgCommitLiquidTokensResponse)(nil), "elys.commitment.MsgCommitLiquidTokensResponse") proto.RegisterType((*MsgVest)(nil), "elys.commitment.MsgVest") + proto.RegisterType((*MsgVestCW)(nil), "elys.commitment.MsgVestCW") proto.RegisterType((*MsgVestResponse)(nil), "elys.commitment.MsgVestResponse") proto.RegisterType((*MsgCancelVest)(nil), "elys.commitment.MsgCancelVest") + proto.RegisterType((*MsgCancelVestCW)(nil), "elys.commitment.MsgCancelVestCW") proto.RegisterType((*MsgCancelVestResponse)(nil), "elys.commitment.MsgCancelVestResponse") proto.RegisterType((*MsgVestNow)(nil), "elys.commitment.MsgVestNow") proto.RegisterType((*MsgVestNowResponse)(nil), "elys.commitment.MsgVestNowResponse") @@ -1213,62 +1353,64 @@ func init() { func init() { proto.RegisterFile("elys/commitment/tx.proto", fileDescriptor_eda78aafe7eb119c) } var fileDescriptor_eda78aafe7eb119c = []byte{ - // 867 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x97, 0xcf, 0x6f, 0xe3, 0x44, - 0x14, 0xc7, 0xeb, 0x36, 0x6d, 0xc8, 0x13, 0xdb, 0x1f, 0xa3, 0xb0, 0xeb, 0xba, 0xbb, 0x6e, 0xd7, - 0x2b, 0xa2, 0xc0, 0xaa, 0x09, 0x82, 0x3b, 0x82, 0x2e, 0xbb, 0x52, 0x04, 0xe9, 0xc1, 0x6c, 0x39, - 0x70, 0x31, 0xae, 0x3d, 0x75, 0xad, 0xd8, 0x33, 0xc1, 0x33, 0xde, 0xa4, 0x47, 0x24, 0x10, 0x48, - 0x5c, 0x40, 0xe2, 0xef, 0x00, 0xf1, 0x5f, 0xec, 0x71, 0x8f, 0x88, 0xc3, 0x0a, 0xb5, 0xff, 0x08, - 0x9a, 0x19, 0x67, 0xe2, 0xa4, 0x4e, 0xa9, 0x38, 0x10, 0x71, 0x4a, 0xe6, 0x7d, 0xdf, 0xbc, 0xf9, - 0xbc, 0xf1, 0xcc, 0x7b, 0x36, 0x98, 0x38, 0xb9, 0x60, 0xdd, 0x80, 0xa6, 0x69, 0xcc, 0x53, 0x4c, - 0x78, 0x97, 0x8f, 0x3b, 0xc3, 0x8c, 0x72, 0x8a, 0xb6, 0x84, 0xd2, 0x99, 0x2a, 0x56, 0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0xe4, 0x83, 0xbf, 0x03, 0x00, 0x00, 0xff, 0xff, 0x2c, 0x1a, 0xf6, 0xc9, 0xd6, - 0x0c, 0x00, 0x00, + // 908 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x57, 0xcf, 0x6f, 0xe3, 0x44, + 0x14, 0xee, 0x6c, 0xd3, 0x86, 0x3c, 0xb1, 0xfd, 0x31, 0x0a, 0xbb, 0xae, 0xbb, 0x9b, 0x76, 0xbd, + 0xa2, 0x0a, 0xac, 0x9a, 0x20, 0xb8, 0x23, 0x68, 0xd9, 0x95, 0x2a, 0x48, 0x0f, 0x66, 0x0b, 0x12, + 0x17, 0xe3, 0xc6, 0x53, 0xd7, 0x4a, 0x3c, 0x13, 0x3c, 0xe3, 0x4d, 0x7b, 0x44, 0x02, 0x81, 0xc4, + 0x05, 0x24, 0xae, 0x9c, 0xb8, 0xf3, 0x77, 0x2c, 0xe2, 0xb2, 0x47, 0xc4, 0x61, 0x85, 0xda, 0x7f, + 0x04, 0xcd, 0x8c, 0x3d, 0x71, 0x53, 0x27, 0x54, 0x08, 0xc9, 0x88, 0x53, 0x32, 0xef, 0xfb, 0xfc, + 0xe6, 0x7b, 0x9f, 0xf3, 0xde, 0x4c, 0xc0, 0x22, 0xc3, 0x73, 0xde, 0xed, 0xb3, 0x38, 0x8e, 0x44, + 0x4c, 0xa8, 0xe8, 0x8a, 0xb3, 0xce, 0x28, 0x61, 0x82, 0xe1, 0x55, 0x89, 0x74, 0x26, 0x88, 0xdd, + 0x0c, 0x59, 0xc8, 0x14, 0xd6, 0x95, 0xdf, 0x34, 0xcd, 0xf9, 0x01, 0xc1, 0xdd, 0x1e, 0x0f, 0xf7, + 0x15, 0x6f, 0x7f, 0xe8, 0x47, 0x31, 0x09, 0x5c, 0x32, 0xf6, 0x93, 0x80, 0x63, 0x0b, 0xea, 0xfd, + 0x84, 0xf8, 0x82, 0x25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5e, 0x56, 0xff, 0x06, 0xdf, 0xf9, 0x2b, + 0x00, 0x00, 0xff, 0xff, 0xf3, 0x17, 0xcb, 0x72, 0x50, 0x0e, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -2027,6 +2169,60 @@ func (m *MsgVest) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *MsgVestCW) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgVestCW) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgVestCW) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Denom) > 0 { + i -= len(m.Denom) + copy(dAtA[i:], m.Denom) + i = encodeVarintTx(dAtA, i, uint64(len(m.Denom))) + i-- + dAtA[i] = 0x22 + } + { + size := m.Amount.Size() + i -= size + if _, err := m.Amount.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *MsgVestResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -2097,6 +2293,60 @@ func (m *MsgCancelVest) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *MsgCancelVestCW) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgCancelVestCW) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgCancelVestCW) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Denom) > 0 { + i -= len(m.Denom) + copy(dAtA[i:], m.Denom) + i = encodeVarintTx(dAtA, i, uint64(len(m.Denom))) + i-- + dAtA[i] = 0x22 + } + { + size := m.Amount.Size() + i -= size + if _, err := m.Amount.MarshalTo(dAtA[i:]); err != nil { + return 0, err + } + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *MsgCancelVestResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -2427,14 +2677,14 @@ func (m *MsgStake) MarshalToSizedBuffer(dAtA []byte) (int, error) { copy(dAtA[i:], m.ValidatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorAddress))) i-- - dAtA[i] = 0x22 + dAtA[i] = 0x2a } if len(m.Asset) > 0 { i -= len(m.Asset) copy(dAtA[i:], m.Asset) i = encodeVarintTx(dAtA, i, uint64(len(m.Asset))) i-- - dAtA[i] = 0x1a + dAtA[i] = 0x22 } { size := m.Amount.Size() @@ -2445,7 +2695,14 @@ func (m *MsgStake) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintTx(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x12 + dAtA[i] = 0x1a + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0x12 + } if len(m.Creator) > 0 { i -= len(m.Creator) copy(dAtA[i:], m.Creator) @@ -2516,14 +2773,14 @@ func (m *MsgUnstake) MarshalToSizedBuffer(dAtA []byte) (int, error) { copy(dAtA[i:], m.ValidatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorAddress))) i-- - dAtA[i] = 0x22 + dAtA[i] = 0x2a } if len(m.Asset) > 0 { i -= len(m.Asset) copy(dAtA[i:], m.Asset) i = encodeVarintTx(dAtA, i, uint64(len(m.Asset))) i-- - dAtA[i] = 0x1a + dAtA[i] = 0x22 } { size := m.Amount.Size() @@ -2534,7 +2791,14 @@ func (m *MsgUnstake) MarshalToSizedBuffer(dAtA []byte) (int, error) { i = encodeVarintTx(dAtA, i, uint64(size)) } i-- - dAtA[i] = 0x12 + dAtA[i] = 0x1a + if len(m.Address) > 0 { + i -= len(m.Address) + copy(dAtA[i:], m.Address) + i = encodeVarintTx(dAtA, i, uint64(len(m.Address))) + i-- + dAtA[i] = 0x12 + } if len(m.Creator) > 0 { i -= len(m.Creator) copy(dAtA[i:], m.Creator) @@ -2725,16 +2989,7 @@ func (m *MsgVest) Size() (n int) { return n } -func (m *MsgVestResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func (m *MsgCancelVest) Size() (n int) { +func (m *MsgVestCW) Size() (n int) { if m == nil { return 0 } @@ -2744,6 +2999,10 @@ func (m *MsgCancelVest) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } + l = len(m.Address) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.Denom) @@ -2753,7 +3012,7 @@ func (m *MsgCancelVest) Size() (n int) { return n } -func (m *MsgCancelVestResponse) Size() (n int) { +func (m *MsgVestResponse) Size() (n int) { if m == nil { return 0 } @@ -2762,7 +3021,7 @@ func (m *MsgCancelVestResponse) Size() (n int) { return n } -func (m *MsgVestNow) Size() (n int) { +func (m *MsgCancelVest) Size() (n int) { if m == nil { return 0 } @@ -2781,31 +3040,82 @@ func (m *MsgVestNow) Size() (n int) { return n } -func (m *MsgVestNowResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - -func (m *MsgUpdateVestingInfo) Size() (n int) { +func (m *MsgCancelVestCW) Size() (n int) { if m == nil { return 0 } var l int _ = l - l = len(m.Authority) + l = len(m.Creator) if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.BaseDenom) + l = len(m.Address) if l > 0 { n += 1 + l + sovTx(uint64(l)) } - l = len(m.VestingDenom) - if l > 0 { + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) + l = len(m.Denom) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgCancelVestResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *MsgVestNow) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Creator) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) + l = len(m.Denom) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + return n +} + +func (m *MsgVestNowResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *MsgUpdateVestingInfo) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Authority) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.BaseDenom) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.VestingDenom) + if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.EpochIdentifier) @@ -2893,6 +3203,10 @@ func (m *MsgStake) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } + l = len(m.Address) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.Asset) @@ -2932,6 +3246,10 @@ func (m *MsgUnstake) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } + l = len(m.Address) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.Asset) @@ -3926,6 +4244,186 @@ func (m *MsgVest) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgVestCW) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgVestCW: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgVestCW: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *MsgVestResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -4124,6 +4622,186 @@ func (m *MsgCancelVest) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgCancelVestCW) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgCancelVestCW: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgCancelVestCW: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Denom = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *MsgCancelVestResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -5049,6 +5727,38 @@ func (m *MsgStake) Unmarshal(dAtA []byte) error { m.Creator = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } @@ -5082,7 +5792,7 @@ func (m *MsgStake) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 3: + case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Asset", wireType) } @@ -5114,7 +5824,7 @@ func (m *MsgStake) Unmarshal(dAtA []byte) error { } m.Asset = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ValidatorAddress", wireType) } @@ -5330,6 +6040,38 @@ func (m *MsgUnstake) Unmarshal(dAtA []byte) error { m.Creator = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Address = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } @@ -5363,7 +6105,7 @@ func (m *MsgUnstake) Unmarshal(dAtA []byte) error { return err } iNdEx = postIndex - case 3: + case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Asset", wireType) } @@ -5395,7 +6137,7 @@ func (m *MsgUnstake) Unmarshal(dAtA []byte) error { } m.Asset = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ValidatorAddress", wireType) } diff --git a/x/incentive/client/wasm/msg_begin_redelegate.go b/x/incentive/client/wasm/msg_begin_redelegate.go index a599cd6fb..fb6e06007 100644 --- a/x/incentive/client/wasm/msg_begin_redelegate.go +++ b/x/incentive/client/wasm/msg_begin_redelegate.go @@ -9,15 +9,16 @@ import ( stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" wasmbindingstypes "github.com/elys-network/elys/wasmbindings/types" + "github.com/elys-network/elys/x/incentive/types" paramtypes "github.com/elys-network/elys/x/parameter/types" ) -func (m *Messenger) msgBeginRedelegate(ctx sdk.Context, contractAddr sdk.AccAddress, msgRedelegate *stakingtypes.MsgBeginRedelegate) ([]sdk.Event, [][]byte, error) { +func (m *Messenger) msgBeginRedelegate(ctx sdk.Context, contractAddr sdk.AccAddress, msgRedelegate *types.MsgBeginRedelegate) ([]sdk.Event, [][]byte, error) { var res *wasmbindingstypes.RequestResponse var err error brokerAddress := m.parameterKeeper.GetParams(ctx).BrokerAddress - if msgRedelegate.DelegatorAddress != contractAddr.String() && contractAddr.String() != brokerAddress { + if msgRedelegate.Creator != contractAddr.String() && contractAddr.String() != brokerAddress { return nil, nil, wasmvmtypes.InvalidRequest{Err: "wrong sender"} } @@ -40,7 +41,7 @@ func (m *Messenger) msgBeginRedelegate(ctx sdk.Context, contractAddr sdk.AccAddr return nil, resp, nil } -func performMsgRedelegateElys(f *stakingkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgRedelegate *stakingtypes.MsgBeginRedelegate) (*wasmbindingstypes.RequestResponse, error) { +func performMsgRedelegateElys(f *stakingkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgRedelegate *types.MsgBeginRedelegate) (*wasmbindingstypes.RequestResponse, error) { if msgRedelegate == nil { return nil, wasmvmtypes.InvalidRequest{Err: "Invalid redelegate parameter"} } diff --git a/x/incentive/client/wasm/msg_cancel_unbonding_delegation.go b/x/incentive/client/wasm/msg_cancel_unbonding_delegation.go index dd3215a95..6c0a006c6 100644 --- a/x/incentive/client/wasm/msg_cancel_unbonding_delegation.go +++ b/x/incentive/client/wasm/msg_cancel_unbonding_delegation.go @@ -9,15 +9,16 @@ import ( stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" wasmbindingstypes "github.com/elys-network/elys/wasmbindings/types" + "github.com/elys-network/elys/x/incentive/types" paramtypes "github.com/elys-network/elys/x/parameter/types" ) -func (m *Messenger) msgCancelUnbondingDelegation(ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelUnbonding *stakingtypes.MsgCancelUnbondingDelegation) ([]sdk.Event, [][]byte, error) { +func (m *Messenger) msgCancelUnbondingDelegation(ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelUnbonding *types.MsgCancelUnbondingDelegation) ([]sdk.Event, [][]byte, error) { var res *wasmbindingstypes.RequestResponse var err error brokerAddress := m.parameterKeeper.GetParams(ctx).BrokerAddress - if msgCancelUnbonding.DelegatorAddress != contractAddr.String() && contractAddr.String() != brokerAddress { + if msgCancelUnbonding.Creator != contractAddr.String() && contractAddr.String() != brokerAddress { return nil, nil, wasmvmtypes.InvalidRequest{Err: "wrong sender"} } @@ -40,7 +41,7 @@ func (m *Messenger) msgCancelUnbondingDelegation(ctx sdk.Context, contractAddr s return nil, resp, nil } -func performMsgCancelUnbondingElys(f *stakingkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelUnbonding *stakingtypes.MsgCancelUnbondingDelegation) (*wasmbindingstypes.RequestResponse, error) { +func performMsgCancelUnbondingElys(f *stakingkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, msgCancelUnbonding *types.MsgCancelUnbondingDelegation) (*wasmbindingstypes.RequestResponse, error) { if msgCancelUnbonding == nil { return nil, wasmvmtypes.InvalidRequest{Err: "Invalid cancel unbonding parameter"} } diff --git a/x/incentive/client/wasm/msg_withdraw_rewards.go b/x/incentive/client/wasm/msg_withdraw_rewards.go index 8ad483fa8..3051c2f6c 100644 --- a/x/incentive/client/wasm/msg_withdraw_rewards.go +++ b/x/incentive/client/wasm/msg_withdraw_rewards.go @@ -17,7 +17,7 @@ func (m *Messenger) msgWithdrawRewards(ctx sdk.Context, contractAddr sdk.AccAddr var err error brokerAddress := m.parameterKeeper.GetParams(ctx).BrokerAddress - if msgWithdrawRewards.DelegatorAddress != contractAddr.String() && contractAddr.String() != brokerAddress { + if msgWithdrawRewards.Creator != contractAddr.String() && contractAddr.String() != brokerAddress { return nil, nil, wasmvmtypes.InvalidRequest{Err: "wrong sender"} } diff --git a/x/incentive/client/wasm/msg_withdraw_validator_commission.go b/x/incentive/client/wasm/msg_withdraw_validator_commission.go index 739872f1b..8d29059f5 100644 --- a/x/incentive/client/wasm/msg_withdraw_validator_commission.go +++ b/x/incentive/client/wasm/msg_withdraw_validator_commission.go @@ -17,7 +17,7 @@ func (m *Messenger) msgWithdrawValidatorCommission(ctx sdk.Context, contractAddr var err error brokerAddress := m.parameterKeeper.GetParams(ctx).BrokerAddress - if msgWithdrawValidatorCommission.DelegatorAddress != contractAddr.String() && contractAddr.String() != brokerAddress { + if msgWithdrawValidatorCommission.Creator != contractAddr.String() && contractAddr.String() != brokerAddress { return nil, nil, wasmvmtypes.InvalidRequest{Err: "wrong sender"} } diff --git a/x/incentive/keeper/apr.go b/x/incentive/keeper/apr.go index 8f794e953..806d338f4 100644 --- a/x/incentive/keeper/apr.go +++ b/x/incentive/keeper/apr.go @@ -118,7 +118,10 @@ func (k Keeper) CalculateApr(ctx sdk.Context, query *types.QueryAprRequest) (sdk // Calc Eden price in usdc // We put Elys as denom as Eden won't be avaialble in amm pool and has the same value as Elys - edenPrice := k.EstimatePrice(ctx, sdk.NewCoin(ptypes.Elys, sdk.NewInt(10)), baseCurrency) + edenPrice := k.EstimatePrice(ctx, sdk.NewCoin(ptypes.Elys, sdk.NewInt(1000000)), baseCurrency) + if edenPrice.IsZero() { + return sdk.ZeroInt(), nil + } // Update total committed states k.UpdateTotalCommitmentInfo(ctx, baseCurrency) @@ -131,7 +134,7 @@ func (k Keeper) CalculateApr(ctx sdk.Context, query *types.QueryAprRequest) (sdk // Usdc apr for elys staking = (24 hour dex rewards in USDC generated for stakers) * 365*100/ {price ( elys/usdc)*( sum of (elys staked, Eden committed, Eden boost committed))} // we multiply 10 as we have use 10elys as input in the price estimation - apr := amtDexRewardPerDay.MulInt(sdk.NewInt(ptypes.DaysPerYear)).MulInt(sdk.NewInt(100)).MulInt(sdk.NewInt(10)).QuoInt(edenPrice).QuoInt(totalStakedSnapshot) + apr := amtDexRewardPerDay.MulInt(sdk.NewInt(ptypes.DaysPerYear)).MulInt(sdk.NewInt(100)).MulInt(sdk.NewInt(1000000)).QuoInt(edenPrice).QuoInt(totalStakedSnapshot) return apr.TruncateInt(), nil } diff --git a/x/incentive/types/tx.pb.go b/x/incentive/types/tx.pb.go index fbd2cdb5c..5cb5ee58b 100644 --- a/x/incentive/types/tx.pb.go +++ b/x/incentive/types/tx.pb.go @@ -8,6 +8,7 @@ import ( fmt "fmt" _ "github.com/cosmos/cosmos-proto" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" + types1 "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -34,8 +35,9 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // MsgWithdrawDelegatorReward represents delegation withdrawal to a delegator // from a single validator. type MsgWithdrawRewards struct { - DelegatorAddress string `protobuf:"bytes,1,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` - WithdrawType types.EarnType `protobuf:"varint,2,opt,name=withdraw_type,json=withdrawType,proto3,enum=elys.commitment.EarnType" json:"withdraw_type,omitempty"` + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + DelegatorAddress string `protobuf:"bytes,2,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` + WithdrawType types.EarnType `protobuf:"varint,3,opt,name=withdraw_type,json=withdrawType,proto3,enum=elys.commitment.EarnType" json:"withdraw_type,omitempty"` } func (m *MsgWithdrawRewards) Reset() { *m = MsgWithdrawRewards{} } @@ -111,8 +113,9 @@ var xxx_messageInfo_MsgWithdrawRewardsResponse proto.InternalMessageInfo // MsgWithdrawValidatorCommission withdraws the full commission to the validator // address. type MsgWithdrawValidatorCommission struct { - DelegatorAddress string `protobuf:"bytes,1,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` - ValidatorAddress string `protobuf:"bytes,2,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + DelegatorAddress string `protobuf:"bytes,2,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` + ValidatorAddress string `protobuf:"bytes,3,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` } func (m *MsgWithdrawValidatorCommission) Reset() { *m = MsgWithdrawValidatorCommission{} } @@ -303,6 +306,90 @@ func (m *MsgUpdateIncentiveParamsResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgUpdateIncentiveParamsResponse proto.InternalMessageInfo +type MsgBeginRedelegate struct { + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + DelegatorAddress string `protobuf:"bytes,2,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` + ValidatorSrcAddress string `protobuf:"bytes,3,opt,name=validator_src_address,json=validatorSrcAddress,proto3" json:"validator_src_address,omitempty"` + ValidatorDstAddress string `protobuf:"bytes,4,opt,name=validator_dst_address,json=validatorDstAddress,proto3" json:"validator_dst_address,omitempty"` + Amount types1.Coin `protobuf:"bytes,5,opt,name=amount,proto3" json:"amount"` +} + +func (m *MsgBeginRedelegate) Reset() { *m = MsgBeginRedelegate{} } +func (m *MsgBeginRedelegate) String() string { return proto.CompactTextString(m) } +func (*MsgBeginRedelegate) ProtoMessage() {} +func (*MsgBeginRedelegate) Descriptor() ([]byte, []int) { + return fileDescriptor_59dc3bedfb1cce84, []int{6} +} +func (m *MsgBeginRedelegate) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgBeginRedelegate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgBeginRedelegate.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgBeginRedelegate) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgBeginRedelegate.Merge(m, src) +} +func (m *MsgBeginRedelegate) XXX_Size() int { + return m.Size() +} +func (m *MsgBeginRedelegate) XXX_DiscardUnknown() { + xxx_messageInfo_MsgBeginRedelegate.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgBeginRedelegate proto.InternalMessageInfo + +type MsgCancelUnbondingDelegation struct { + Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty"` + DelegatorAddress string `protobuf:"bytes,2,opt,name=delegator_address,json=delegatorAddress,proto3" json:"delegator_address,omitempty"` + ValidatorAddress string `protobuf:"bytes,3,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` + // amount is always less than or equal to unbonding delegation entry balance + Amount types1.Coin `protobuf:"bytes,4,opt,name=amount,proto3" json:"amount"` + // creation_height is the height which the unbonding took place. + CreationHeight int64 `protobuf:"varint,5,opt,name=creation_height,json=creationHeight,proto3" json:"creation_height,omitempty"` +} + +func (m *MsgCancelUnbondingDelegation) Reset() { *m = MsgCancelUnbondingDelegation{} } +func (m *MsgCancelUnbondingDelegation) String() string { return proto.CompactTextString(m) } +func (*MsgCancelUnbondingDelegation) ProtoMessage() {} +func (*MsgCancelUnbondingDelegation) Descriptor() ([]byte, []int) { + return fileDescriptor_59dc3bedfb1cce84, []int{7} +} +func (m *MsgCancelUnbondingDelegation) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgCancelUnbondingDelegation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgCancelUnbondingDelegation.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgCancelUnbondingDelegation) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgCancelUnbondingDelegation.Merge(m, src) +} +func (m *MsgCancelUnbondingDelegation) XXX_Size() int { + return m.Size() +} +func (m *MsgCancelUnbondingDelegation) XXX_DiscardUnknown() { + xxx_messageInfo_MsgCancelUnbondingDelegation.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgCancelUnbondingDelegation proto.InternalMessageInfo + func init() { proto.RegisterType((*MsgWithdrawRewards)(nil), "elys.incentive.MsgWithdrawRewards") proto.RegisterType((*MsgWithdrawRewardsResponse)(nil), "elys.incentive.MsgWithdrawRewardsResponse") @@ -310,53 +397,66 @@ func init() { proto.RegisterType((*MsgWithdrawValidatorCommissionResponse)(nil), "elys.incentive.MsgWithdrawValidatorCommissionResponse") proto.RegisterType((*MsgUpdateIncentiveParams)(nil), "elys.incentive.MsgUpdateIncentiveParams") proto.RegisterType((*MsgUpdateIncentiveParamsResponse)(nil), "elys.incentive.MsgUpdateIncentiveParamsResponse") + proto.RegisterType((*MsgBeginRedelegate)(nil), "elys.incentive.MsgBeginRedelegate") + proto.RegisterType((*MsgCancelUnbondingDelegation)(nil), "elys.incentive.MsgCancelUnbondingDelegation") } func init() { proto.RegisterFile("elys/incentive/tx.proto", fileDescriptor_59dc3bedfb1cce84) } var fileDescriptor_59dc3bedfb1cce84 = []byte{ - // 656 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x55, 0xcf, 0x4e, 0x13, 0x41, - 0x1c, 0xee, 0x82, 0x20, 0x4c, 0x10, 0x65, 0x80, 0xb0, 0x14, 0xb2, 0x6d, 0x7a, 0x20, 0x1b, 0x13, - 0x76, 0x09, 0x1a, 0x63, 0x3c, 0x18, 0x41, 0x97, 0x68, 0x22, 0x09, 0x59, 0x50, 0x13, 0x2f, 0x38, - 0xdd, 0x9d, 0x6c, 0x27, 0xed, 0xce, 0x6c, 0x66, 0xa6, 0xb4, 0x7d, 0x00, 0x13, 0x8f, 0x3e, 0x81, - 0xe1, 0xe2, 0x1b, 0x78, 0xf0, 0x11, 0x38, 0x12, 0x4f, 0xc6, 0x03, 0x31, 0x10, 0x13, 0x1f, 0xc3, - 0xcc, 0xfe, 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0xa3, 0x02, 0xd7, 0xbe, 0x6a, 0xc0, - 0xe8, 0x83, 0x5f, 0xa3, 0x16, 0xf1, 0x95, 0x8f, 0xa7, 0x2a, 0x82, 0x10, 0x84, 0xd1, 0xff, 0x95, - 0x91, 0x03, 0xa6, 0xf6, 0x32, 0xf5, 0x5c, 0x66, 0xe8, 0x2a, 0x99, 0xfc, 0x48, 0xba, 0xdf, 0x97, - 0x98, 0x09, 0x96, 0x06, 0x3b, 0xcf, 0x93, 0xfc, 0x34, 0x02, 0xf4, 0x4d, 0x11, 0xbc, 0x8a, 0x7c, - 0x24, 0xf1, 0x8b, 0x6c, 0x20, 0xb6, 0xe2, 0x6e, 0xc2, 0x45, 0x30, 0x8e, 0xda, 0xb2, 0xc1, 0x38, - 0x91, 0xbd, 0x24, 0x2d, 0xf7, 0x74, 0x03, 0xba, 0x60, 0x42, 0x15, 0xbb, 0x4d, 0x89, 0xec, 0xed, - 0xa0, 0x6e, 0x6a, 0xd8, 0x3a, 0x38, 0xaa, 0x94, 0x7e, 0x1c, 0x55, 0x96, 0x02, 0x22, 0x1b, 0xed, - 0xba, 0xea, 0x47, 0x3a, 0x3a, 0xe9, 0xcf, 0xb2, 0xf0, 0x9b, 0xb6, 0xea, 0x9b, 0xb0, 0x9e, 0x61, - 0xcf, 0x3d, 0xa3, 0x01, 0x57, 0xc0, 0x74, 0xd6, 0x2b, 0x95, 0x95, 0x43, 0x51, 0xbd, 0x85, 0x7d, - 0x7d, 0xb8, 0xaa, 0x99, 0x63, 0x6e, 0x11, 0x04, 0xdf, 0x81, 0x69, 0x1e, 0x37, 0x6e, 0x8b, 0x71, - 0x49, 0x18, 0xdd, 0x60, 0xfc, 0x65, 0x24, 0xf4, 0x1b, 0xd7, 0x32, 0x53, 0x24, 0x05, 0xef, 0x83, - 0x59, 0x35, 0x59, 0xdb, 0x12, 0x35, 0xf1, 0x0e, 0x47, 0x5e, 0x53, 0x55, 0x1f, 0x49, 0xac, 0x8f, - 0x54, 0x35, 0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85, 0xdd, 0xed, 0x7f, 0x83, 0xd4, 0xa8, 0xd5, 0x47, 0xe3, 0x87, - 0xe2, 0xde, 0x9f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7b, 0xf1, 0x05, 0x2c, 0xa2, 0x06, 0x00, 0x00, + // 828 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xdc, 0x56, 0x4d, 0x6f, 0x23, 0x35, + 0x18, 0xce, 0x24, 0xd9, 0x6e, 0x6b, 0x96, 0x2e, 0xeb, 0x6e, 0xd5, 0x69, 0x36, 0x9a, 0x44, 0x39, + 0x2c, 0x11, 0x52, 0x67, 0xda, 0x80, 0x00, 0x71, 0x40, 0x34, 0x6d, 0xaa, 0x22, 0x35, 0x52, 0x35, + 0x6d, 0x41, 0xe2, 0x12, 0x9c, 0x19, 0x6b, 0x62, 0x25, 0xb1, 0x47, 0xb6, 0xd3, 0x24, 0x3f, 0x00, + 0x89, 0x23, 0xbf, 0x00, 0xf5, 0x47, 0xf0, 0x23, 0x7a, 0xe0, 0x50, 0x71, 0x02, 0x0e, 0x15, 0x6a, + 0x85, 0xc4, 0x01, 0xf1, 0x1b, 0x90, 0xe7, 0x2b, 0x69, 0x3b, 0x4d, 0x3f, 0x2e, 0x95, 0xf6, 0x94, + 0xd8, 0xcf, 0xe3, 0x67, 0xde, 0xf7, 0xf1, 0x6b, 0xbf, 0x06, 0x2b, 0xb8, 0x37, 0x16, 0x16, 0xa1, + 0x0e, 0xa6, 0x92, 0x1c, 0x63, 0x4b, 0x8e, 0x4c, 0x9f, 0x33, 0xc9, 0xe0, 0xa2, 0x02, 0xcc, 0x04, + 0x28, 0xbc, 0xf6, 0x98, 0xc7, 0x02, 0xc8, 0x52, 0xff, 0x42, 0x56, 0x61, 0xd5, 0x61, 0xa2, 0xcf, + 0x44, 0x2b, 0x04, 0xc2, 0x41, 0x04, 0x15, 0x03, 0x65, 0x87, 0xf5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x30, 0x3b, 0xb1, 0xb3, 0xf6, 0x77, + 0x16, 0xe4, 0x9a, 0xc2, 0x83, 0x08, 0xbc, 0xbc, 0xde, 0x9b, 0x2b, 0xe6, 0xd5, 0x27, 0x83, 0x79, + 0xb3, 0xc9, 0x15, 0x3e, 0xba, 0x9b, 0x13, 0x1f, 0x15, 0xf8, 0x83, 0x06, 0xde, 0xcc, 0xea, 0x82, + 0xe6, 0x0c, 0xad, 0x14, 0x7e, 0xe1, 0xd3, 0x87, 0xf1, 0x93, 0x38, 0x04, 0x58, 0x4e, 0xef, 0x39, + 0xd5, 0x14, 0xc1, 0x54, 0x66, 0x61, 0xfd, 0xbe, 0xcc, 0xf8, 0xa3, 0xf5, 0xdd, 0xd3, 0x0b, 0x43, + 0x3b, 0xbb, 0x30, 0xb4, 0xbf, 0x2e, 0x0c, 0xed, 0xa7, 0x4b, 0x23, 0x73, 0x76, 0x69, 0x64, 0x7e, + 0xbf, 0x34, 0x32, 0xdf, 0x99, 0x53, 0xd7, 0xa3, 0x52, 0x5d, 0xa3, 0x58, 0x0e, 0x19, 0xef, 0x06, + 0x03, 0x6b, 0x34, 0xfd, 0x96, 0x53, 0x57, 0x65, 0x7b, 0x2e, 0x78, 0x50, 0x7d, 0xfc, 0x7f, 0x00, + 0x00, 0x00, 0xff, 0xff, 0x8b, 0x4d, 0x54, 0xa8, 0xea, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -542,13 +642,20 @@ func (m *MsgWithdrawRewards) MarshalToSizedBuffer(dAtA []byte) (int, error) { if m.WithdrawType != 0 { i = encodeVarintTx(dAtA, i, uint64(m.WithdrawType)) i-- - dAtA[i] = 0x10 + dAtA[i] = 0x18 } if len(m.DelegatorAddress) > 0 { i -= len(m.DelegatorAddress) copy(dAtA[i:], m.DelegatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.DelegatorAddress))) i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- dAtA[i] = 0xa } return len(dAtA) - i, nil @@ -602,13 +709,20 @@ func (m *MsgWithdrawValidatorCommission) MarshalToSizedBuffer(dAtA []byte) (int, copy(dAtA[i:], m.ValidatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorAddress))) i-- - dAtA[i] = 0x12 + dAtA[i] = 0x1a } if len(m.DelegatorAddress) > 0 { i -= len(m.DelegatorAddress) copy(dAtA[i:], m.DelegatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.DelegatorAddress))) i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- dAtA[i] = 0xa } return len(dAtA) - i, nil @@ -755,6 +869,126 @@ func (m *MsgUpdateIncentiveParamsResponse) MarshalToSizedBuffer(dAtA []byte) (in return len(dAtA) - i, nil } +func (m *MsgBeginRedelegate) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgBeginRedelegate) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgBeginRedelegate) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + if len(m.ValidatorDstAddress) > 0 { + i -= len(m.ValidatorDstAddress) + copy(dAtA[i:], m.ValidatorDstAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorDstAddress))) + i-- + dAtA[i] = 0x22 + } + if len(m.ValidatorSrcAddress) > 0 { + i -= len(m.ValidatorSrcAddress) + copy(dAtA[i:], m.ValidatorSrcAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorSrcAddress))) + i-- + dAtA[i] = 0x1a + } + if len(m.DelegatorAddress) > 0 { + i -= len(m.DelegatorAddress) + copy(dAtA[i:], m.DelegatorAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.DelegatorAddress))) + i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgCancelUnbondingDelegation) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgCancelUnbondingDelegation) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgCancelUnbondingDelegation) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.CreationHeight != 0 { + i = encodeVarintTx(dAtA, i, uint64(m.CreationHeight)) + i-- + dAtA[i] = 0x28 + } + { + size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + if len(m.ValidatorAddress) > 0 { + i -= len(m.ValidatorAddress) + copy(dAtA[i:], m.ValidatorAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.ValidatorAddress))) + i-- + dAtA[i] = 0x1a + } + if len(m.DelegatorAddress) > 0 { + i -= len(m.DelegatorAddress) + copy(dAtA[i:], m.DelegatorAddress) + i = encodeVarintTx(dAtA, i, uint64(len(m.DelegatorAddress))) + i-- + dAtA[i] = 0x12 + } + if len(m.Creator) > 0 { + i -= len(m.Creator) + copy(dAtA[i:], m.Creator) + i = encodeVarintTx(dAtA, i, uint64(len(m.Creator))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset @@ -772,6 +1006,10 @@ func (m *MsgWithdrawRewards) Size() (n int) { } var l int _ = l + l = len(m.Creator) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } l = len(m.DelegatorAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) @@ -797,6 +1035,10 @@ func (m *MsgWithdrawValidatorCommission) Size() (n int) { } var l int _ = l + l = len(m.Creator) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } l = len(m.DelegatorAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) @@ -859,6 +1101,59 @@ func (m *MsgUpdateIncentiveParamsResponse) Size() (n int) { return n } +func (m *MsgBeginRedelegate) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Creator) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.DelegatorAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.ValidatorSrcAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.ValidatorDstAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgCancelUnbondingDelegation) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Creator) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.DelegatorAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.ValidatorAddress) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) + if m.CreationHeight != 0 { + n += 1 + sovTx(uint64(m.CreationHeight)) + } + return n +} + func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -895,6 +1190,38 @@ func (m *MsgWithdrawRewards) Unmarshal(dAtA []byte) error { } switch fieldNum { case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DelegatorAddress", wireType) } @@ -926,7 +1253,7 @@ func (m *MsgWithdrawRewards) Unmarshal(dAtA []byte) error { } m.DelegatorAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field WithdrawType", wireType) } @@ -1046,6 +1373,38 @@ func (m *MsgWithdrawValidatorCommission) Unmarshal(dAtA []byte) error { } switch fieldNum { case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DelegatorAddress", wireType) } @@ -1077,7 +1436,7 @@ func (m *MsgWithdrawValidatorCommission) Unmarshal(dAtA []byte) error { } m.DelegatorAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ValidatorAddress", wireType) } @@ -1525,6 +1884,415 @@ func (m *MsgUpdateIncentiveParamsResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgBeginRedelegate) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgBeginRedelegate: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgBeginRedelegate: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DelegatorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.DelegatorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ValidatorSrcAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ValidatorSrcAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ValidatorDstAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ValidatorDstAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgCancelUnbondingDelegation) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgCancelUnbondingDelegation: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgCancelUnbondingDelegation: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Creator = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DelegatorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.DelegatorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ValidatorAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ValidatorAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CreationHeight", wireType) + } + m.CreationHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CreationHeight |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0