refactor(morpho): GraphQL-only V2 markets monitoring#321
Open
spalen0 wants to merge 2 commits into
Open
Conversation
Drop per-vault RPC adapter walks in favor of one vaultV2s query plus batched market metrics, and remove OUSD V2 (funds live in V1). Co-authored-by: Cursor <cursoragent@cursor.com>
Add main() batching/failure tests, a MorphoMarketV1 happy-path parse case, document zero-supply skips, and drop the dead TVL guard. Co-authored-by: Cursor <cursoragent@cursor.com>
spalen0
marked this pull request as ready for review
July 24, 2026 15:39
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
markets_v2.pyto drop RPC: onevaultV2squery loads TVL/liquidity/MorphoMarketV1positions, then onemarketsquery per chain for state/bad debtOUSD Vault V2from config (all funds sit in monitored V1 via MetaMorpho adapter)MorphoMarketV1adapters or truncated adapter/position pagesTest plan
pytest tests/test_morpho_markets.pypython protocols/morpho/markets_v2.pyvs prior run — identical risk scoresMade with Cursor