yearn / yearn-vaults-descriptions

Home Page:https://vaults.yearn.finance

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bug: Doesn't know when a strategy description is deprecated

DarkGhost7 opened this issue Β· comments

What happened πŸ†˜

The site doesnt know when it should remove a strategy description or the logic isnt as good as it should be. We could possibly replicate the logic the website is using or some type of if debt for strategy > 0, show strategy description.

To Reproduce πŸ”‚

An example
image
the snx vault has 4 strategies listed yet has no current strategies with debt, (yes not yield anything atm).
image

Possible Fix πŸ—οΈ

We could also query if a strategy is simply "isActive" or in the withdrawal queue and greater than -1 (-1 signifies it wont be used any more). I think see if its in the withdrawal queue which should be isActive & if strategy debt > 1 (or some low number like 10,000) or just 0 might work but alot of strategies stick around in the withdrawal queue when they should have been deprecated even if they haven't been harvested in a long time ie they should be taken off the vault but havent for some reason. Or that is my understanding.

More πŸ”Ž

  • Sort the strategy descriptions by tvl so the first strategy read is the most used [Nice to have but optional]
  • The website shows the main (highest tvl not first in withdrawal queue) strategy on the vault details page

How do you go about querying if a strategy is isActive?
api.yearn.finance doesn't seem to return full details for strategies

@Major-Eth might know best here how to get this to interface with the read methods of the strategies