-
Notifications
You must be signed in to change notification settings - Fork 0
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
Unreliable Senior Tranche yield #7
Comments
disputed: If I understand correctly then the issue is that senior tranche doesnt get any APY under the two listed circumstances above - if this is the case than that is intendent behaviour. The protection is only up to whatever the junior tranche offers, anything beyond that will result in losses for the senior tranche. The loss of APY when falling below the utilizationThreshold is intended to act as a protection to the junior tranche, and encourage senior tranche holders to pull out (as they now get 0% APY), so also intended. If theres anything Im missing, please let me know! |
I can see the points from the comments by @kitty-the-kat, this might be intended behaviour. I will elaborate further to make sure the suggestions are clear. If the explanations below were already understood, I will remove this issue because it may be a non-issue. The suggestion for - loss[1] = _amount - _trancheBalances[0];
+ loss[1] = _amount - _trancheBalances[0] + seniorProfit; The reason this change may make sense is because the return values of The suggestion for With that said, I can understand why the design might choose a zero senior tranche yield when over the utilisationThreshold provides a useful incentive to withdraw. But this should be documented because it breaks the "fixed yield" assumption for the senior tranche and may be considered unexpected behaviour by users. |
The Senior Tranche is designed to earn a fixed amount of yield. This yield is not always accounted for in the PnL calculations.
Technical Details
PnLFixedRate.sol does not account for
seniorProfit
in two cases:distributeLoss()
when the loss is greater than or equal to the value of the Junior Tranche and could cause losses for the Senior TranchedistributeProfit()
when the utilisation ratio is greater thanutilisationThreshold
Impact
Medium. The PnLFixedRate.sol calculations do not account for
seniorProfit
in less common edge cases.Recommendation
The amount
seniorProfit
should likely be summed intoloss[1]
orprofit[1]
respectively. Otherwise, whendistributeAssets()
is called andfixedRate.lastDistribution
is updated without theseniorProfit
getting added to either tranche, users who deposited into the Senior Tranche will lose out on the yield they should have received since the previous distribution.The text was updated successfully, but these errors were encountered: