You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The block number caching is not robust to network failures. When a new block arrives, the block_archivecorrects the block number cache in case of reorgs. However, since this correction makes queries, it may fail. In such cases, the cache will be in an inconsistent state.
The solution is making the update_latest_block routine never fail, and handle queries by block number in block_tree differently. We'll probably have to remove the cache and add a loop, walking back through the block_tree data structure until we find what we're looking for (or fall back to requesting it to the provider).
The text was updated successfully, but these errors were encountered:
The block number caching is not robust to network failures. When a new block arrives, the
block_archive
corrects the block number cache in case of reorgs. However, since this correction makes queries, it may fail. In such cases, the cache will be in an inconsistent state.The solution is making the
update_latest_block
routine never fail, and handle queries by block number inblock_tree
differently. We'll probably have to remove the cache and add a loop, walking back through theblock_tree
data structure until we find what we're looking for (or fall back to requesting it to the provider).The text was updated successfully, but these errors were encountered: