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

APY calculation differs from webapp #67

Open
varanauskas opened this issue May 2, 2022 · 1 comment · May be fixed by #68
Open

APY calculation differs from webapp #67

varanauskas opened this issue May 2, 2022 · 1 comment · May be fixed by #68

Comments

@varanauskas
Copy link

varanauskas commented May 2, 2022

The APY calculation in the webapp has been updated with epoch_period

(Anchor-Protocol/anchor-web-app#353)

https://github.com/Anchor-Protocol/anchor-web-app/blob/d43ab70b8e85dfa144e506160d904d897fcbb27d/app/src/%40anchor-protocol/app-fns/logics/earn/computeApy.ts#L10

This logic is not replicated in earn.getAPY

return new Dec(epochState.deposit_rate).mul(BLOCKS_PER_YEAR).toNumber();

@varanauskas varanauskas linked a pull request May 2, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants
@varanauskas and others