diff --git a/mev_inspect/inspect_block.py b/mev_inspect/inspect_block.py index c517923..de955fb 100644 --- a/mev_inspect/inspect_block.py +++ b/mev_inspect/inspect_block.py @@ -11,6 +11,10 @@ from mev_inspect.crud.arbitrages import ( delete_arbitrages_for_block, write_arbitrages, ) +from mev_inspect.crud.blocks import ( + delete_block, + write_block, +) from mev_inspect.crud.traces import ( delete_classified_traces_for_block, write_classified_traces, @@ -53,6 +57,9 @@ async def inspect_block( logger.info(f"Block: {block_number} -- Total traces: {len(block.traces)}") + delete_block(inspect_db_session, block_number) + write_block(inspect_db_session, block) + total_transactions = len( set(t.transaction_hash for t in block.traces if t.transaction_hash is not None) )