connector

This commit is contained in:
4tochka 2019-05-05 00:46:49 +04:00
parent 9d7c9bb7f5
commit 9d9b7f42a9

View File

@ -344,6 +344,7 @@ class Connector:
self.log.error(str(traceback.format_exc())) self.log.error(str(traceback.format_exc()))
async def _new_block(self, block): async def _new_block(self, block):
try:
if self.block_headers_cache.get(block["hash"]) is not None: if self.block_headers_cache.get(block["hash"]) is not None:
return return
@ -357,7 +358,7 @@ class Connector:
bt = time.time() bt = time.time()
self.cache_loading = True if self.last_block_height < self.app_block_height_on_start else False self.cache_loading = True if self.last_block_height < self.app_block_height_on_start else False
try:
if self.deep_synchronization: if self.deep_synchronization:
tx_bin_list = [block["rawTx"][i]["txId"] for i in block["rawTx"]] tx_bin_list = [block["rawTx"][i]["txId"] for i in block["rawTx"]]
else: else: