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

[SC-406] Optional Max DSR #18

Merged
merged 5 commits into from
Apr 24, 2024
Merged

Conversation

hexonaut
Copy link
Contributor

On L2s it makes sense to completely trust the bridge and just burn admin access. As such we have been setting the max dsr to an arbitrarily high value (1000% / year). While this is fine in practise, it is an improvement to allow for the oracle to just disable this feature explicitly. This allows for longer durations for rpow computation before it overflows. With 1000% APY you have an overflow if no update is performed within 20 years which again is fine in practise, but we can remove this limiter.

Copy link
Contributor

@barrutko barrutko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed with Lucas' comment.
Other than that LGTM.
Will approve after the changes.

barrutko
barrutko previously approved these changes Apr 24, 2024
lucas-manuel
lucas-manuel previously approved these changes Apr 24, 2024
Copy link

Coverage after merging SC-406-option-to-disable-max-dsr into master will be

98.89%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   DSRAuthOracle.sol100%100%100%100%
   DSRMainnetOracle.sol100%100%100%100%
   DSROracleBase.sol100%100%100%100%
src/adapters
   DSRBalancerRateProviderAdapter.sol100%100%100%100%
src/forwarders
   DSROracleForwarderArbitrumOne.sol100%100%100%100%
   DSROracleForwarderBase.sol100%100%100%100%
   DSROracleForwarderBaseChain.sol100%100%100%100%
   DSROracleForwarderGnosis.sol100%100%100%100%
   DSROracleForwarderOptimism.sol0%100%0%0%15
src/receivers
   DSROracleReceiverArbitrum.sol100%100%100%100%
   DSROracleReceiverGnosis.sol100%100%100%100%
   DSROracleReceiverOptimism.sol100%100%100%100%

@hexonaut hexonaut merged commit 1232ab6 into master Apr 24, 2024
3 checks passed
@hexonaut hexonaut deleted the SC-406-option-to-disable-max-dsr branch April 24, 2024 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants