Skip to content

Commit f2b1bb2

Browse files
authored
Merge pull request #523 from lidofinance/logs-fix
fix: get_logs
2 parents d51899e + b90a6fc commit f2b1bb2

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

tests/regression/test_permissions.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -643,9 +643,14 @@ def fetch_events_in_batches(start_block, end_block, provider=local_rpc_provider,
643643
with tqdm(total=total_batches, desc="Fetching Events") as pbar:
644644
for batch_start in range(start_block, end_block, step):
645645
batch_end = min(batch_start + step - 1, end_block)
646-
batch_events = provider.eth.filter(
647-
{"address": contracts.acl.address, "fromBlock": batch_start, "toBlock": batch_end, "topics": [event_signature_hash]}
648-
).get_all_entries()
646+
647+
batch_events = provider.eth.get_logs({
648+
"address": contracts.acl.address,
649+
"fromBlock": batch_start,
650+
"toBlock": batch_end,
651+
"topics": [event_signature_hash],
652+
})
653+
649654
events.extend(batch_events)
650655
pbar.update(1)
651656
return events

0 commit comments

Comments
 (0)