merge bug fix
This commit is contained in:
parent
772cd369d6
commit
134553c104
@ -553,15 +553,17 @@ def processBlock(blockindex=None, blockhash=None):
|
||||
blockinfo['txs'] = tempinfo
|
||||
updateLatestBlock(blockinfo)
|
||||
|
||||
try:
|
||||
session = create_database_session_orm('system_dbs', {'db_name': "system"}, SystemBase)
|
||||
entry = session.query(SystemData).filter(SystemData.attribute == 'lastblockscanned').all()[0]
|
||||
entry.value = str(blockinfo['height'])
|
||||
session.commit()
|
||||
session.close()
|
||||
except:
|
||||
logger.info(f"Unable to connect to 'system' database... retrying in {DB_RETRY_TIMEOUT} seconds")
|
||||
time.sleep(DB_RETRY_TIMEOUT)
|
||||
while True:
|
||||
try:
|
||||
session = create_database_session_orm('system_dbs', {'db_name': "system"}, SystemBase)
|
||||
entry = session.query(SystemData).filter(SystemData.attribute == 'lastblockscanned').all()[0]
|
||||
entry.value = str(blockinfo['height'])
|
||||
session.commit()
|
||||
session.close()
|
||||
break
|
||||
except:
|
||||
logger.info(f"Unable to connect to 'system' database... retrying in {DB_RETRY_TIMEOUT} seconds")
|
||||
time.sleep(DB_RETRY_TIMEOUT)
|
||||
|
||||
|
||||
def updateLatestTransaction(transactionData, parsed_data, db_reference, transactionType=None ):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user