-
Notifications
You must be signed in to change notification settings - Fork 22
Description
as part of #46 we would like to rewrite the math to take onramp stake, and possiibly all sol, into account for token calculations. we should add the onramp account to DepositStake and WithdrawStake, and pass it in in instruction builders. we should do this in a non-breaking way (try to get the account, print a warning if its missing) to give time to push people to upgrade, so that when we impl DepositSol it goes smoothly
i would love to splice it after the pool stake account so we keep consistent account ordering. normally we would add accounts at the end, but this account cannot be optional if we change the math, so i think its fine
if we just care about stake we could do a multipool-style "cache the number on the pool account and error if it hasnt been updated in the current epoch" but id rather avoid this