-
Notifications
You must be signed in to change notification settings - Fork 0
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
Add a checkpoint module to hyperdrive-math
#23
Comments
hyperdrive-math
hyperdrive-math
This ideally would also need to account for auto-closing positions & zombie interest |
Yeah, that was the idea behind this issue. Checkpointing accounts for matured positions (you could call this auto-closing), zombie interest, and it distributes excess idle to the withdrawal pool. Here is the checkpoint function in Solidity for context: https://github.com/delvtech/hyperdrive/blob/main/contracts/src/internal/HyperdriveCheckpoint.sol |
One of the current limitations of the Rust SDK is that it doesn't simulate checkpoints. This means that when the Rust SDK is used to run a simulation at a checkpoint boundary before a new trade has been made, the result could be very inaccurate. The best version of the Rust SDK would simulate the application of checkpoints by replicating the checkpointing logic and the distribute excess idle calculation.
The text was updated successfully, but these errors were encountered: