SIP | Title | Author | Status | Track | Created |
---|---|---|---|---|---|
20 |
Staking contract updates |
James Howlett (@jameshowlett977) |
Ready for vote |
Contract |
2021-06-07 |
If approved, this proposal will:
- Replace the current staking contract with a new staking contract, with the only changes being targeted fixes for the issues described below.
- Add the Exchequer Multisig as an admin of the staking contract, with the authority to revoke team vesting contracts and adding contracts' code hash.
Fixing staking contract bugs
There are two main issues with the staking contract that are fixed by this SIP:
-
If a user stakes SOV until date
x
, withdraws their SOV, then stakes SOV again until datex
, they will not be able to perform any of the expected functions on their staked SOV (e.g. extend staking, delegate staking, or withdraw staking). -
For users who have more than one transaction adding to their vesting contract, the vesting contract is skipping a staking period when calculating the amount available to withdraw. If for example a user stakes on June 1 for a duration of two staking periods ending on June 29, then the vesting contract will only count the second staking period as being available for withdrawal.
Improving management workflow of team vesting contracts
To improve the management workflow of team vestint contracts, Exchequer needs the ability to invoke the governanceWithdrawVesting
function. This will be used in the event that a team member resigns or otherwise requires to have the remaining SOV withdrawn from their vesting contract before the full vesting period as elapsed.
- Existing Staking Logic contract:
0x962Ce6E2Fa1A4917DfF12Ad10135b1a4F16c2DB0
- The new Staking Logic contract:
0xcAB5028619839dbb92a193f59026383973F04008
- Proposed changes: DistributedCollective/Sovryn-smart-contracts#250
Copyright and related rights waived via CC0.