Accumulate touched over several blocks
So if several blocks are processed together, the touched addresses is their union not just the most recent Fixes #630
This commit is contained in:
parent
214fc83648
commit
a735a3f0c1
@ -48,11 +48,10 @@ class Notifications(object):
|
|||||||
# new block height
|
# new block height
|
||||||
return
|
return
|
||||||
touched = tmp.pop(height)
|
touched = tmp.pop(height)
|
||||||
touched.update(tbp.pop(height, set()))
|
|
||||||
for old in [h for h in tmp if h <= height]:
|
for old in [h for h in tmp if h <= height]:
|
||||||
del tmp[old]
|
del tmp[old]
|
||||||
for old in [h for h in tbp if h <= height]:
|
for old in [h for h in tbp if h <= height]:
|
||||||
del tbp[old]
|
touched.update(tbp.pop(old))
|
||||||
await self.notify(height, touched)
|
await self.notify(height, touched)
|
||||||
|
|
||||||
async def notify(self, height, touched):
|
async def notify(self, height, touched):
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user