witnet-rust
witnet-rust copied to clipboard
A set of fixes and features for wit\2
The first four commits are part of https://github.com/witnet/witnet-rust/pull/2469.
The latter four commits are all new self-contained patches that introduce a fix or feature, but they build upon each other, so I kept them in the same branch.
Pertaining to above discussions, this is what is currently implemented in the branch up to commit 9ec8d09:
- All
rfstakers are eligible to produce a block - Block winner comparison is power, vrf, block hash, in that order
- If none of the eligible stakers produce a block, they will get slashed proportional to their rank
- Validation code to make sure no one stakes on a validator with a different withdrawer address
- A way to switch block times moving from V1_8 to V2_0
- A bunch of small features and bugfixes
Things to (potentially) still implement (of the top of my head):
- Multiplication for the
rffactor when more than one block is missing - Move wit/2 constants to a central file
- Better ratios for slashing validators
For the sake of an easier review, the block time patch is on https://github.com/witnet/witnet-rust/pull/2473.