-
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
3-coin crypto pool #159
3-coin crypto pool #159
Conversation
Coverage reportThe coverage rate went from
Diff Coverage details (click to unfold)curvesim/pool/cryptoswap/pool.py
curvesim/pool/cryptoswap/calcs/factory_2_coin.py
curvesim/pool/cryptoswap/calcs/tricrypto_ng.py
|
Looks like the |
f85c903
to
20bf041
Compare
`test_get_virtual_price` works fine before this but gets a several hundred wei discrepancy after changing the calc.
Test passes now but we need to remove the kludge with the fixed value of `ma_time`.
Vyper will do signed integer division which rounds toward zero and thus behaves differently when dividing a negative number. Solving this issue allows us to reproduce to-the-wei results for tricrypto-ng operations. Tests updated to check for exact values.
Closes #91
The goal is to do only what is required to get reliable crypto sims going, as we expect there will be a lot of work to tune the sims to reflect accurate repegging and other timing issues.
This means that cryptopools only need:
exchange
tweak_price
dydx
The
SimPool
wrapper will only need these to do crypto sims.Some further work remains:
n_coins
(if possible)exchange
under more conditions, especially swap sequences, and checking repegsgmpy2
Bonus!
(Cherry-picked into
main
)