commit 91086cd4dd837a1650944b0f938c8485d739f81e
parent 7c204b788491ca78833ce0324d1806752602a6ae
Author: lash <dev@holbrook.no>
Date: Thu, 10 Nov 2022 08:08:44 +0000
Add conn to callbacks, remove tx from block callback
Diffstat:
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/chainsyncer/driver/base.py b/chainsyncer/driver/base.py
@@ -102,7 +102,7 @@ class SyncDriver:
self.last_start = time.clock_gettime_ns(self.clock_id)
if self.pre_callback != None:
- self.pre_callback()
+ self.pre_callback(conn)
while True and self.running:
try:
@@ -113,7 +113,7 @@ class SyncDriver:
except NoBlockForYou as e:
break
if self.block_callback != None:
- self.block_callback(block, None)
+ self.block_callback(conn, block)
try:
self.process(conn, item, block)
@@ -125,7 +125,7 @@ class SyncDriver:
self.running = False
if self.post_callback != None:
- self.post_callback()
+ self.post_callback(conn)
self.idle(interval)