Bump version
This commit is contained in:
parent
70873e4aec
commit
d9196f5ff5
@ -5,6 +5,7 @@ import time
|
|||||||
import signal
|
import signal
|
||||||
|
|
||||||
# external imports
|
# external imports
|
||||||
|
import sqlalchemy
|
||||||
from chainlib.eth.block import (
|
from chainlib.eth.block import (
|
||||||
block_by_number,
|
block_by_number,
|
||||||
Block,
|
Block,
|
||||||
@ -92,6 +93,10 @@ class BlockPollSyncer(Syncer):
|
|||||||
return self.backend.get()
|
return self.backend.get()
|
||||||
except NoBlockForYou as e:
|
except NoBlockForYou as e:
|
||||||
break
|
break
|
||||||
|
# TODO: To properly handle this, ensure that previous request is rolled back
|
||||||
|
# except sqlalchemy.exc.OperationalError as e:
|
||||||
|
# logg.error('database error: {}'.format(e))
|
||||||
|
# break
|
||||||
last_block = block.number
|
last_block = block.number
|
||||||
self.process(conn, block)
|
self.process(conn, block)
|
||||||
start_tx = 0
|
start_tx = 0
|
||||||
@ -116,6 +121,7 @@ class HeadSyncer(BlockPollSyncer):
|
|||||||
self.backend.set(block.number, i)
|
self.backend.set(block.number, i)
|
||||||
self.filter.apply(conn, block, tx)
|
self.filter.apply(conn, block, tx)
|
||||||
except IndexError as e:
|
except IndexError as e:
|
||||||
|
logg.debug('index error syncer rcpt get {}'.format(e))
|
||||||
self.backend.set(block.number + 1, 0)
|
self.backend.set(block.number + 1, 0)
|
||||||
break
|
break
|
||||||
i += 1
|
i += 1
|
||||||
@ -130,7 +136,6 @@ class HeadSyncer(BlockPollSyncer):
|
|||||||
if r == None:
|
if r == None:
|
||||||
raise NoBlockForYou()
|
raise NoBlockForYou()
|
||||||
b = Block(r)
|
b = Block(r)
|
||||||
logg.debug('get {}'.format(b))
|
|
||||||
|
|
||||||
return b
|
return b
|
||||||
|
|
||||||
@ -161,7 +166,6 @@ class HistorySyncer(HeadSyncer):
|
|||||||
if r == None:
|
if r == None:
|
||||||
raise NoBlockForYou()
|
raise NoBlockForYou()
|
||||||
b = Block(r)
|
b = Block(r)
|
||||||
logg.debug('get {}'.format(b))
|
|
||||||
|
|
||||||
return b
|
return b
|
||||||
|
|
||||||
|
@ -3,4 +3,4 @@ SQLAlchemy==1.3.20
|
|||||||
confini~=0.3.6b2
|
confini~=0.3.6b2
|
||||||
semver==2.13.0
|
semver==2.13.0
|
||||||
hexathon~=0.0.1a3
|
hexathon~=0.0.1a3
|
||||||
chainlib~=0.0.1a17
|
chainlib~=0.0.1a18
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[metadata]
|
[metadata]
|
||||||
name = chainsyncer
|
name = chainsyncer
|
||||||
version = 0.0.1a17
|
version = 0.0.1a18
|
||||||
description = Generic blockchain syncer driver
|
description = Generic blockchain syncer driver
|
||||||
author = Louis Holbrook
|
author = Louis Holbrook
|
||||||
author_email = dev@holbrook.no
|
author_email = dev@holbrook.no
|
||||||
|
Loading…
Reference in New Issue
Block a user