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

[VEN-2943]: add support for Pendle's getPtToSyRate #240

Merged
merged 6 commits into from
Dec 27, 2024

Conversation

kkirka
Copy link
Collaborator

@kkirka kkirka commented Dec 11, 2024

This PR modifies Pendle oracle to support using yield tokens as a base, as an alternative to using the underlying asset directly. This is the approach recommended by the Pendle team for tokens where redemptions/withdrawals are not guaranteed.

@kkirka kkirka changed the title feat: add support for pendle's getPtToSyRate feat: add support for Pendle's getPtToSyRate Dec 11, 2024
@kkirka kkirka force-pushed the feat/pendle-sy-rate branch from de5f34f to 97d3797 Compare December 11, 2024 10:11
@chechu chechu changed the title feat: add support for Pendle's getPtToSyRate [VEN-2943]: add support for Pendle's getPtToSyRate Dec 11, 2024
@kkirka kkirka force-pushed the feat/pendle-sy-rate branch from fde5d09 to 79489b4 Compare December 23, 2024 17:29
contracts/oracles/PendleOracle.sol Outdated Show resolved Hide resolved
contracts/oracles/PendleOracle.sol Outdated Show resolved Hide resolved
contracts/oracles/PendleOracle.sol Outdated Show resolved Hide resolved
Problem: Some terms were used ambiguously throughout the docs, e.g.
"underlying asset" could refer to Pendle market's asset or an SY token
or a yield token.

Solution:
* Use the term "underlying token" to refer to the oracle's underlying
  token (it can be either the market's asset or the yield token).
* Use the term "yield token" to refer to an interest-bearing token
  wrapped by SY.
* Use the term "market's asset" to refer to the underlying asset of
  the Pendle market. 1 PT will eventually be equivalent to 1 asset
  at redemption.
@kkirka kkirka force-pushed the feat/pendle-sy-rate branch from 08f530b to fb5a4ec Compare December 23, 2024 17:53
Copy link

Code Coverage

Package Line Rate Branch Rate Health
contracts 85% 80%
contracts.interfaces 28% 21%
contracts.oracles 89% 80%
contracts.oracles.common 100% 100%
Summary 84% (295 / 352) 76% (144 / 190)

@kkirka kkirka merged commit b914616 into develop Dec 27, 2024
4 checks passed
@kkirka kkirka deleted the feat/pendle-sy-rate branch December 27, 2024 10:33
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 this pull request may close these issues.

3 participants