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

Please fix rounding issues #60

Open
kaber2 opened this issue Mar 25, 2024 · 1 comment
Open

Please fix rounding issues #60

kaber2 opened this issue Mar 25, 2024 · 1 comment
Labels
duplicate This issue or pull request already exists

Comments

@kaber2
Copy link

kaber2 commented Mar 25, 2024

Hello guys,

could you please fix that annoying rounding issue when transferring stETH tokens?

AFAICT, it should be relatively simple as you are using a proxy architecture. An easy fix would be to upscale share values internally by 1e18. For compatibility, you could use a new balanceOf map and, if an account has no balance there, you fall back to reading from the old unscaled map. This would impose a relatively minor one time gas cost on the first transfer for every account.

Thanks!

@mymphe
Copy link
Collaborator

mymphe commented Apr 5, 2024

Hey @kaber2! Thanks for submitting this issue and contributing to the Lido protocol!

Your proposed solution will not work since this issue does not only occur for the initial mint but any transfer as well. However, we have some developments in this area, please see lidofinance/lido-dao#442 for more details.

@tamtamchik tamtamchik added the duplicate This issue or pull request already exists label Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants