Skip to content

program: add onramp account to deposit/withdraw #387

@2501babe

Description

@2501babe

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions