Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Voting power refactor : 1 cycle delay (#51)
* update: updating submodule to include fixes to voting power * fix: updating refactor to match with upstream natspec pr, version is compiling * fix: refactoring tests and making one work * fix: updating tests (all working) and some initilization functionality * fix: issue with 0 voters in a cycle addressed * fix: amending deploy script * fix: addressing typo" * fix: fixing another typo * chore: adding two view functions for #53 , #52 * fix: fixing spacing mistake * chore: adding min voting power for current bread holders * fix: amending hardcoded value to be equivalent to maxpoints, assures no division errors * fix: if the first mint is after the end period, return 0 * fix: fixing prevKey > _end * fix: further minimizing and documenting the code * fix: fixing some more issues with the voting func * fix: amending to conform to natspect * fix: reverting named variable * fix: deprecated nastspec comment block * fix: removing extra space * fix: changing ownable call location * fix: adding linebreak after check * fix: removing line break before function * fix: spacing and unbulking comments * fix: removing maxpoints and fixing spacing * fix: removing setter for block time * fix: removing voting power from last block, simplyfing checkpoint filtering, accounting for no checkpoints in the interval, renaming variables for clarity * fix: reordering variables and adding line breaks after checks for consistency * fix: deprecating the usage of timestamps * fix: removing extraneous variables, initalizing with preconfigured values * fix: amending initalizer ordering * fix: ordering initalizers constants > public variable * fix: adding division loss protection * fix: documentation update * fix: trimming trailing whitespace * fix: incorrect reverse traversal of list * fix: fixing setup of tests to properly init cycling * fix: amending tests to work with changes * fix: voting with above required voting power * Refactor 'getVotingPowerForPeriod' function * fix: changing grace voting power to to constant, view function to test wrapper * fix: timestamp ref deprecated * A few small additional changes to 'getVotingPowerForPeriod' * Fix bug with decrementing index in 'getVotingPowerForPeriod' * Changes to variables names to fix broken build * Remove grace period vote logic and slight refactor of * General style cleanup, removed unused settings, remove return values from errors * Refactor 'distributeYield' function and other small changes * Refactor add/remove projects and errors, events, and globals * Add missing 'votingPower' param * Change contract name to YieldDistributor * Fix minimum voting power test * Update src/YieldDisburser.sol Co-authored-by: RonTuretzky <[email protected]> * Update src/YieldDisburser.sol * fix: removing extra linebreak * Non-breaking changes cleanup (#58) * Refactor 'getVotingPowerForPeriod' function * A few small additional changes to 'getVotingPowerForPeriod' * Fix bug with decrementing index in 'getVotingPowerForPeriod' * Changes to variables names to fix broken build * Remove grace period vote logic and slight refactor of * General style cleanup, removed unused settings, remove return values from errors * Refactor 'distributeYield' function and other small changes * Refactor add/remove projects and errors, events, and globals * Add missing 'votingPower' param * Fix minimum voting power test * Update src/YieldDisburser.sol Co-authored-by: RonTuretzky <[email protected]> * Update src/YieldDisburser.sol * fix: removing extra linebreak --------- Co-authored-by: RonTuretzky <[email protected]> Co-authored-by: Ron Turetzky <[email protected]> --------- Co-authored-by: bagelface.eth <[email protected]> Co-authored-by: bagelface <[email protected]>
- Loading branch information