0g-chain/x/incentive
Ruaridh 6f193c7f2a
Refactor incentive accumulators to be the same (#970)
* add test for validate multi reward periods

* tidy up: combine files

* don't accumulate global indexes containing zeros
Previously if the time since last block was 0,
indexes were added containing 0s.
Now leave them out. Missing is assumed to be 0.

* move state independent test to types folder

* clarify reward source concept to "source shares"
- rename variables and update doc comments
- extract method from swap accumulation

* tidy up and expand swap accumulation unit tests

* rename swap test file to match others

* update swap pool id format in tests

* refactor borrow accumulation, use new accumulator

* refactor supply accumulation, use new accumulator

* refactor delegator accumulation, use accumulator

* refactor usdx accumulation, use new accumulator

* fix types const

* remove unsed methods

* more usdx minting param validation.
Protect against the rewards per second denom changing.
It should always be "ukava".

* add safety check in InitGenesis
It prevents huge accumulations on the first block by limiting all
previous accumulation times to be within one year of genesis

* add todo for adding swp token distirbution info
2021-07-22 13:53:18 +01:00
..
client Refactor incentive payout (#953), Users can claim swap rewards (#955) 2021-07-15 15:05:54 +01:00
keeper Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
legacy Incentive genesis refactor: remove sync on export (#954) 2021-07-15 15:41:55 +01:00
simulation Incentive/Hard rebase to master (#773) 2021-01-21 14:52:09 +01:00
spec Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
testutil Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
types Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
abci.go Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
alias.go Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
doc.go USDX incentives implementation (#399) 2020-04-24 11:20:34 -04:00
genesis_test.go Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
genesis.go Refactor incentive accumulators to be the same (#970) 2021-07-22 13:53:18 +01:00
handler_delegator_test.go Refactor incentive payout (#953), Users can claim swap rewards (#955) 2021-07-15 15:05:54 +01:00
handler_hard_test.go Refactor incentive payout (#953), Users can claim swap rewards (#955) 2021-07-15 15:05:54 +01:00
handler_swap_test.go Update Pool ID Separator (#968) 2021-07-15 19:09:35 -05:00
handler_usdx_test.go Refactor incentive payout (#953), Users can claim swap rewards (#955) 2021-07-15 15:05:54 +01:00
handler.go Refactor incentive payout (#953), Users can claim swap rewards (#955) 2021-07-15 15:05:54 +01:00
integration_test.go fix: update swap genesis in test (#964) 2021-07-15 10:03:30 -05:00
module.go [R4R] fix: validate usdx minting collaterals in incentive genesis (#770) 2021-01-19 22:42:50 -07:00