yearn / yearn-vaults-v3

GNU Affero General Public License v3.0
104 stars 37 forks source link

Add target_debt as an update_debt function argument #77

Closed jmonteer closed 2 years ago

jmonteer commented 2 years ago

Description: Background: https://github.com/jmonteer/yearn-vaults-v3/issues/73

Add target_debt to the _update_debt function as an argument.

The vault will try to match the strategy's debt to the target_debt. Right now, we are using strategy.max_debt as target_debt (implicitely). This means that we need to add a check to ensure that target_debt <= max_debt Worth thinking if this should be a min or an assert, taking into account the implications.

Dependencies: NA

Acceptance criteria:

Payment Trigger: PR is merged Category: DEV Level: 0