AstarNetwork / astar-frame

Core frame modules for Astar & Shiden network.
Other
58 stars 38 forks source link

Nomination Transfer #41

Closed Dinonard closed 2 years ago

Dinonard commented 2 years ago

Nomination Transfer

Summary

A new functionality is introduced for the dapps-staking pallet - nomination transfer. The idea is to allow stakers to transfer their nomination from contract_A to contract_B while bypassing the unbonding period. This is great for stakers who have already staked on some contract but found another one they would like to nominate instead. Prior to nomination_transfer, they would have to wait first for the unbonding period to complete, not earning any staking rewards, before being able to re-stake their rewards.

Requirements (useful for UI)

There are certain requirements that must be met in order for nomination transfer to work:

TODO

Check list

Maar-io commented 2 years ago

My only comment is usability of the precompile changes to support withdraw_from_unregistered and nomination_transfer. Maybe Astar portal will have use of these but I do not see why would evm smart contract use these calls.

Dinonard commented 2 years ago

@Maar-io for the withdraw_from_unregistered, if contract is staking on another contract that gets unregistered, they cannot get their staked tokens out otherwise.

For nomination_transfer, I added it for consistency.