-
Notifications
You must be signed in to change notification settings - Fork 32
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
Remove liquidity funcs and tests #276
Conversation
Coverage reportThe coverage rate went from
Diff Coverage details (click to unfold)curvesim/pool/stableswap/pool.py
|
4e7d13a
to
ba71bd4
Compare
Nice work (haven't reviewed thoroughly though). By the way, you can run Happy first contribution! |
Good work @Tcintra. Before you merge, could you leave a comment in this thread explaining your use case for returning fees/amounts from |
The Since |
Description
Addresses #258 (but only for StableSwap pools)
Added
remove_liquidity
andremove_liquidity_imbalanced
for the vanilla StableSwap pools, along with their Vyper fixtures and unit tests. The unit tests just do the same as the other add/remove liquidity tests: it checks that the Vyper and Python instances of the 3pool will end with the samebalances
,tokens
, andD
.The Vyper implementation is largely copied from what already exists in
metapool.vy
, with minor changes. The Python implementation is similar to thecalc_token_amount
function.Disclaimer: this is my first time contributing and it is very possible that I am missing something. Please let me know and I will address any concerns.
Hygiene checklist
(modules, public functions, classes, and public methods)
and descriptive commit messages following Tim Pope's style
Cute Animal Picture