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

feat: Add switch to YRF so it turns off when EmissionManager is active #25

Closed
wants to merge 3 commits into from

Conversation

Oighty
Copy link
Contributor

@Oighty Oighty commented Nov 18, 2024

Adds a function to the YRF, shouldNotBuy, which checks if the EmissionManager will be active or not. If this function returns true, the YRF bond market is not created.

Because we are conditionally not using the funds in the contract to buy back OHM, reserves could accumulate over time in the contract. This would create a very large buy whenever it turns back on. Therefore, we also modify the weekly yield withdrawal logic to only fund the contract the delta between the current balance and the next yield (if at all).

Copy link

LCOV of commit 4c65490 during CI #63

Summary coverage rate:
  lines......: 69.4% (1365 of 1966 lines)
  functions..: 72.2% (296 of 410 functions)
  branches...: no data found

Files changed coverage rate: n/a

@Oighty Oighty closed this Nov 18, 2024
@0xJem 0xJem deleted the yrf-switch branch November 18, 2024 17:51
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.

1 participant