-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
Description
Currently we get the "block_from", but opening a file in our own persisted storage, however this value can also be obtained by querying the table in dune itself. The table does not yet exist, but once it does we could experiment with fetching this value from one, or both places...
dune-bridge/pysrc/fetch/dune.py
Lines 94 to 104 in a53f3cd
| # TODO - could be replaced by Dune Query on the app_data table (once available). | |
| block_from, | |
| block_to=int( | |
| # KeyError here means the query has been modified and column no longer exists | |
| # IndexError means no results were returned from query (which is unlikely). | |
| (await self.fetch(QUERIES["LATEST_APP_HASH_BLOCK"].query))[0][ | |
| "latest_block" | |
| ] | |
| ), | |
| ) | |