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

Fix/strategy lib muldiv #100

Merged
merged 4 commits into from
Apr 1, 2024
Merged

Conversation

@clemlak clemlak self-assigned this Mar 29, 2024
@clemlak clemlak requested review from Alexangelj and kinrezC and removed request for Alexangelj March 29, 2024 12:51
@clemlak clemlak added 📃 contracts Anything related to the DFMM contracts (or strategies) 🔨 audit fix Patching audit findings labels Mar 29, 2024
@clemlak
Copy link
Contributor Author

clemlak commented Mar 29, 2024

One test is still failing, looks like the function we're using the compute the price of a LogNormal pool is rounding in the wrong direction?

@clemlak
Copy link
Contributor Author

clemlak commented Apr 1, 2024

@kinrezC and I discovered a weird behavior in the LogNormal pool, if someone allocates a small amount of token Y (for example 0.77), the price of the pool might change and decrease by 2. This issue is only happening if the total liquidity in the pool is less than 20 WAD and the price is 1.

@clemlak clemlak merged commit 32a5572 into fix/spearbit-audit Apr 1, 2024
5 checks passed
@clemlak clemlak deleted the fix/strategy-lib-muldiv branch April 1, 2024 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔨 audit fix Patching audit findings 📃 contracts Anything related to the DFMM contracts (or strategies)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants