balancer / dune-spellbook

SQL views for Dune Analytics
Other
7 stars 12 forks source link

create balancer_compatible macros #87

Open viniabussafi opened 1 month ago

viniabussafi commented 1 month ago

change macros in order to make them compatible with friendly forks

viniabussafi commented 1 month ago

Reference: https://github.com/duneanalytics/spellbook/blob/main/macros/models/_sector/dex/uniswap_compatible_trades.sql

viniabussafi commented 1 month ago

We can do better than uniswap_compatible_trades: https://github.com/duneanalytics/spellbook/blob/main/macros/models/_sector/dex/balancer_compatible_trades.sql FROM statements can be written like {{ source(project_decodedas ~ '' ~ blockchain, BPool_evt_LOG_SWAP) }}

viniabussafi commented 3 weeks ago

Have a PR ready for this, but will hold until tomorrow due to this: https://github.com/duneanalytics/spellbook/pull/6078#issuecomment-2148446549

viniabussafi commented 3 weeks ago

Working on PR

viniabussafi commented 3 weeks ago

Tests have passed and results are behaving as expected for balancer spells. Beethoven spells are broken, need to check why

viniabussafi commented 3 weeks ago

dex.prices is causing outliers on beethoven_x_fantom.liquidity. Will have to look into it in the future, but will keep this one as-is to try and get this PR merged as soon as I can

viniabussafi commented 2 days ago

just got approved. Waiting for merge