-
Notifications
You must be signed in to change notification settings - Fork 814
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Changes the target list score type from balance to `u128` (`ExtendedBalance`) - simplifies `balance/ vote_weight/ extended_balance` conversions - relies less on the currency total issuance call - ensures approval stake calculations/storage is safe - Simplifies stake tracker logic - removes a few redundant checks - split `on_stake_update` code - Ensures `VoterUpdateMode` is taken into consideration in try-state checks - use voter mode lazy in benchmarks - update weights + check the diff with voter lazy - Docs improvements - All tests passing after merging validator disabling and virtual stakers **new** - ensures duplicate nominations are dedup before calculating the approvals stake - chills nominator after total slash to ensure the target can be reaped/kill without leaving nominations behind. - ensures that switching from validator to nominator and back is correct - a nominator may have an entry in the targetlist (if it was a validator + has nominations) - ensure target node is removed if balance is 0 and it is a nominator. - addresses paritytech-secops/srlabs_findings#383 --- **Other experiments:** (not included) - #4402 (passing the status of the staker with who in the OnStakingUpdate interface is less clean, it turns out) - #4361 --------- Co-authored-by: command-bot <>
- Loading branch information
Showing
15 changed files
with
934 additions
and
704 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.