-
Notifications
You must be signed in to change notification settings - Fork 4
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
feat!: simplify penalty handling logic #9
Commits on Jul 20, 2023
-
when insurance is under 5.75% of chunk size, then un-delegate it. now we can make sure that during unbonding or re-delegation period, there must be no case where un-pairing insurance cannot cover penalty. remainings: * fix broken tests * remove re-delegation info's deletable and amt field * add tcs for new logics.
Configuration menu - View commit details
-
Copy full SHA for 2449a35 - Browse repository at this point
Copy the full SHA 2449a35View commit details -
handle decimal penalty and fix broken tests
when calc penaltyAmt, must check shares value based on amt.
Configuration menu - View commit details
-
Copy full SHA for ae843ab - Browse repository at this point
Copy the full SHA ae843abView commit details -
Those fields are introduced to cover the situation where unpairing ins at previous epoch cannot cover the penalty during re-delegation period. But now we check paired ins with IsEnoughToCoverSlash so we don't need PenaltyAmt and Deletable anymore. Because that scenario will not happen.
Configuration menu - View commit details
-
Copy full SHA for ed61848 - Browse repository at this point
Copy the full SHA ed61848View commit details
Commits on Jul 21, 2023
-
* panic when validator is invalid (this must not happen) * remove empty branch * fix wrong calc in IsEnoughToCoverSlash feedbacks: * #9 (comment) * #9 (comment)
Configuration menu - View commit details
-
Copy full SHA for 57fee4b - Browse repository at this point
Copy the full SHA 57fee4bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 77b34f6 - Browse repository at this point
Copy the full SHA 77b34f6View commit details -
remove un-reached checking logic and un-necessary comments
by adding IsEnoughToCoverSlash function, the edge cases we were previously worried about are gone. (unpairing ins at previous epoch cannot cover the penalty during re-delegation period). so comments and checking logics for that edge should be deleted as now.
Configuration menu - View commit details
-
Copy full SHA for 792742c - Browse repository at this point
Copy the full SHA 792742cView commit details -
update spec related with this pr
updated spec related with this pr remove tc created during test locally change function name of mustDelegate mustDelegatePenaltyAmt is more readable and meaningful
Configuration menu - View commit details
-
Copy full SHA for 1031455 - Browse repository at this point
Copy the full SHA 1031455View commit details -
Update lintk in x/liquidstaking/spec/02_state.md
Co-authored-by: dongsam <dongsamb@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for b26a8a1 - Browse repository at this point
Copy the full SHA b26a8a1View commit details -
Update link in x/liquidstaking/spec/02_state.md
Co-authored-by: dongsam <dongsamb@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 88d24ad - Browse repository at this point
Copy the full SHA 88d24adView commit details