-
Notifications
You must be signed in to change notification settings - Fork 68
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: stableswap gradual amplification change #629
feat: stableswap gradual amplification change #629
Conversation
Crate versions that have been updated:
Runtime version has not been increased. |
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #629 +/- ##
==========================================
+ Coverage 64.94% 65.17% +0.22%
==========================================
Files 131 131
Lines 9559 9647 +88
==========================================
+ Hits 6208 6287 +79
- Misses 3351 3360 +9
☔ View full report in Codecov by Sentry. |
); | ||
ensure!( | ||
pool.final_amplification.get() != final_amplification, | ||
Error::<T>::SameAmplification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what if you want to speed up or slow down ramp up? this check seems not very effective as it could be bypassed by just changing final amp by 1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this just ensures that you dont set the same value as there is now as it does not make any change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can still change it however with the same final amp, as you can set different end block therefore slow down or hasten the change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes. now it is different - this was a case when you had to wait for previous change to finish.
now it makes sense to ensure that the new final amplification != initial ampfliciation, isnt it ?
This PR introduces gradual change of amplification for stableswap pool.