Skip to content

Commit

Permalink
fix: cast blocks as hex when splitting trace_filter batch (#170)
Browse files Browse the repository at this point in the history
  • Loading branch information
BobTheBuidler authored Dec 21, 2024
1 parent f1f02f8 commit e9c7e87
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions eth_portfolio/_ledgers/address.py
Original file line number Diff line number Diff line change
Expand Up @@ -568,8 +568,8 @@ async def _trace_filter(fromBlock: int, toBlock: int, **kwargs) -> List[FilterTr
halfway = from_block + chunk_size

results = await gather(
_trace_filter(fromBlock=fromBlock, toBlock=halfway, **kwargs),
_trace_filter(fromBlock=halfway + 1, toBlock=toBlock, **kwargs),
_trace_filter(fromBlock=fromBlock, toBlock=hex(halfway), **kwargs),
_trace_filter(fromBlock=hex(halfway + 1), toBlock=toBlock, **kwargs),
)
return results[0] + results[1]

Expand Down

0 comments on commit e9c7e87

Please sign in to comment.