-
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
feat: add set redemption script fnc for ENA S2 #47
Conversation
proof[4] = 0x0fe239692610c805880a540ea359a0f3f8314f94bb95cd4ec53d712ae6cdc63d; | ||
|
||
address testUser = 0x25E426b153e74Ab36b2685c3A464272De60888Ae; | ||
uint256 claimAmount = 52792622186481736164; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be conservative, we could add a fork test that runs script in the setup, has this test redemption, and also test redemptions that are invalid and fail
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes! like add this to the test suite ? Had a similar thought, and probably not a bad move
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes - like the test file would call setRedemptionENA30Oct24
from the script in the setup function and then you can run some tests to make sure users can claim as expected in diff scenarios - user with rr can claim, user with out can't, double check the conversion rate is expected, etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few comments - most impt is the question on unclaimed pTokens.
ty for the review @stevenvaleri |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good!
Pushed the unclaimed pToken fix @stevenvaleri! |
for the alpha (v.0.1.0) deployment
We got
1324...
ENA for our cliff vest, and were told we'd have the same amount vested over time (if the ENA threshold balance is maintained). Because we didn't halve the Ethena sats pTokens for the alpha like we do for season 3 in the public release, future vesting rewards are not guaranteed. We will use redemption rights, and, if future rewards are lost, will scale the redemption rights down proportionally such that there will be excess pTokens at the end that will never be redeemable.reward per p token calc:
Total kpSATs-2 (both claimed and unclaimed):
4178883670999999914762240
50% ENA vest:
132431200000000000000000
Rewards per p token (rounded down):
63381137368827226
In addition, we'll only be going with holders at the original snapshot, and won't update the redemption rights recipients if users sell or transfer their pTokens, as specified in the docs
This script:
.env
we'll use for the alpha kpSATS run:For future runs, we'll have the script add to the existing redemption rights for each successive vest and we'll use the stored snapshot rather than creating a new one.