Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

R4R: Simulate transactions for fee distribution, simulate inflation, and fix a multitude of bugs discovered in the process of doing so #2501

Merged
merged 58 commits into from
Oct 23, 2018
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
1674625
Update PENDING.md
cwgoes Oct 16, 2018
2fff810
This PR now will do something else
cwgoes Oct 16, 2018
67258c4
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 16, 2018
b700107
Add simulated distribution msgs
cwgoes Oct 16, 2018
1d4b595
Correctly set power in vote info
cwgoes Oct 16, 2018
74780c6
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 18, 2018
f527163
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 18, 2018
e099491
Merge PR #2526: Distribution fixes from simulation
cwgoes Oct 18, 2018
06c7e27
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 18, 2018
25ce0de
Update stake module simulation and fix linter errors
cwgoes Oct 18, 2018
42ae267
Simulation fixes work-in-progress
cwgoes Oct 19, 2018
4779359
Linter, enable simulated distribution msgs again
cwgoes Oct 19, 2018
d21f93a
Simulation debugging contd.
cwgoes Oct 19, 2018
c3d3a79
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 19, 2018
375e821
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 19, 2018
22cb698
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 19, 2018
d9916f9
bugfix (#2535)
rigelrozanski Oct 19, 2018
4f719d6
Remove the print statement
cwgoes Oct 19, 2018
6c9ad8c
Add sanity checks
cwgoes Oct 19, 2018
2e8f354
Fixup stake hooks (hopefully...)
cwgoes Oct 19, 2018
843ccaf
Remove comment
cwgoes Oct 19, 2018
1afb5bf
Simulate minting, fix bug where pool was not updated
cwgoes Oct 19, 2018
dc13a0c
Use InflateSupply instead
cwgoes Oct 19, 2018
a6ef3c4
use power instead of total tokens
rigelrozanski Oct 19, 2018
7770aec
Withdraw rewards on bonded to unbonding
cwgoes Oct 19, 2018
255a6a5
Cleanup to one hook
cwgoes Oct 19, 2018
c88fc48
Fix linter issues
cwgoes Oct 19, 2018
c9e5c32
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 19, 2018
3fa5778
Update naming (BondedValidatorIndex->ValidatorsBondedIndex) and add s…
jaekwon Oct 21, 2018
015b829
GetValidatorsBonded -> LastValidators etc
jaekwon Oct 21, 2018
5416af8
LastValidatorPower -> LastValidator
jaekwon Oct 21, 2018
1cc7432
Replicate Rigel's changes but w/ modifications as discussed + some na…
jaekwon Oct 22, 2018
19225fc
Print debugging info
jaekwon Oct 22, 2018
471ddee
tweak debug output
jaekwon Oct 22, 2018
278d237
call hook on slashing
rigelrozanski Oct 22, 2018
a3447cd
debug cleanup
rigelrozanski Oct 22, 2018
c4d7747
Merge remote-tracking branch 'origin/cwgoes/check-supply-in-simulatio…
rigelrozanski Oct 22, 2018
bcc3192
correct LastValidatorPower
rigelrozanski Oct 22, 2018
e088c8b
Merge pull request #2552 from cosmos/jae/check-supply-in-simulation
rigelrozanski Oct 22, 2018
c3008d5
Add more useful logging
jaekwon Oct 22, 2018
7f43860
Merge branch 'cwgoes/check-supply-in-simulation' of github.com:cosmos…
cwgoes Oct 23, 2018
ea565ba
WIP intermediate...
jaekwon Oct 23, 2018
1630c0f
WIP intermediate...
jaekwon Oct 23, 2018
fa3730a
WIP looking for bug...
jaekwon Oct 23, 2018
5a559f7
simulation stop early with no proposers
rigelrozanski Oct 23, 2018
8999ee8
re-enable simulation parameters
rigelrozanski Oct 23, 2018
f82d6a5
Merge pull request #2564 from cosmos/rigel/check-supply-in-simulation2
cwgoes Oct 23, 2018
5790d01
Merge remote-tracking branch 'origin/jae/check-supply-in-simulation2'…
cwgoes Oct 23, 2018
be66a49
Remove debugging print statements
cwgoes Oct 23, 2018
c14fa12
Back to 50 initially bonded
cwgoes Oct 23, 2018
33c8238
Merge branch 'develop' into cwgoes/check-supply-in-simulation
cwgoes Oct 23, 2018
f587b46
Update PENDING.md
cwgoes Oct 23, 2018
6bf7e02
Back to on-operation=false, update PENDING.md
cwgoes Oct 23, 2018
604de85
Remove unnecessary change, clarify amt in sim_test.go
cwgoes Oct 23, 2018
edd56be
Cleanup, additional item in PENDING.md
cwgoes Oct 23, 2018
306fb8f
Address @rigelrozanski comments
cwgoes Oct 23, 2018
cd9373d
Make linter happy
cwgoes Oct 23, 2018
3d270ba
Store last total power as sdk.Int, not sdk.Dec
cwgoes Oct 23, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Back to on-operation=false, update PENDING.md
  • Loading branch information
cwgoes committed Oct 23, 2018
commit 6bf7e02a27770f55ea7b7011171526ee27973430
7 changes: 7 additions & 0 deletions PENDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,16 @@ BREAKING CHANGES
* [x/auth] Simulate random fee payments
* [cmd/gaia/app] Simulate non-zero inflation
* [x/stake] Call hooks correctly in several cases related to delegation/validator updates
* [x/stake] Check full supply invariants, including yet-to-be-withdrawn fees
* [x/stake] Remove no-longer-in-use store key
* [x/slashing] Call hooks correctly when a validator is slashed
* [x/slashing] Truncate withdrawals (unbonding, redelegation) and burn change
* [x/mock/simulation] Ensure the simulation cannot set a proposer address of nil
* [x/mock/simulation] Add more event logs on begin block / end block for clarity
* [x/minting] Correctly call stake keeper to track inflated supply
* [x/distribution] Sanity check for nonexistent rewards
* [x/distribution] Truncate withdrawals and return change to the community pool
* [x/distribution] Add sanity checks for incorrect accum / total accum relations
* [x/distribution] Correctly calculate total power using Tendermint updates
* [x/distribution] Simulate withdrawal transactions
* [x/distribution] Fix a bug where the fee pool was not correctly tracked on WithdrawDelegatorRewardsAll
Expand Down
2 changes: 1 addition & 1 deletion x/mock/simulation/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const (
evidenceFraction float64 = 0.5

// TODO Remove in favor of binary search for invariant violation
onOperation bool = true
onOperation bool = false
)

var (
Expand Down