diff --git a/hive/indexer/blocks.py b/hive/indexer/blocks.py index a1184f81dd9b35e8e0955f66ce2752c642dc5d01..339f40037494b5cf638aa87fa8ce13b54fd8421b 100644 --- a/hive/indexer/blocks.py +++ b/hive/indexer/blocks.py @@ -106,7 +106,7 @@ class Blocks: val = {'hbd_payout':op_value['hbd_payout'], 'hive_payout':op_value['hive_payout'], 'vesting_payout':op_value['vesting_payout']} elif op_type == 'comment_reward_operation': if('payout' not in op_value or op_value['payout'] is None): - logger.error("Broken op: `{}'".format(str(op))) + log.error("Broken op: `{}'".format(str(vop))) key = "{}/{}".format(op_value['author'], op_value['permlink']) val = {'payout':op_value['payout'], 'author_rewards':op_value['author_rewards']} elif op_type == 'effective_comment_vote_operation': diff --git a/hive/indexer/sync.py b/hive/indexer/sync.py index 8677fb67b145cac573fad50f1dc28deb0308d743..5a12fe7d24cb75b7cc99e40b987a72742c13b08e 100644 --- a/hive/indexer/sync.py +++ b/hive/indexer/sync.py @@ -40,10 +40,11 @@ def print_ops_stats(prefix, ops_stats): log.info("`{}': {}".format(k, v)) log.info("############################################################################") + def prepare_vops(vops_by_block): preparedVops = {} - for blockNum, blockDict in vops_by_block.items(): + for blockNum, blockDict in vops_by_block.items(): vopsList = blockDict['ops'] date = blockDict['timestamp'] preparedVops[blockNum] = Blocks.prepare_vops(vopsList, date) diff --git a/hive/steem/client.py b/hive/steem/client.py index 08a38d614b9eccab32240569d1c23b42f3862aa8..cf366dcea553e7e3e02a154b33e56e11016c5c1e 100644 --- a/hive/steem/client.py +++ b/hive/steem/client.py @@ -174,9 +174,11 @@ class SteemClient: resume_on_operation = 0 while from_block < to_block: - result = self.__exec('enum_virtual_ops', {"block_range_begin":from_block, "block_range_end":to_block - , "operation_begin": resume_on_operation, "limit": 1000, "filter": tracked_ops_filter - }) + result = self.__exec('enum_virtual_ops', + {"block_range_begin":from_block, "block_range_end":to_block, + "operation_begin": resume_on_operation, + "filter": tracked_ops_filter + }) ops = result['ops'] if 'ops' in result else [] resume_on_operation = result['next_operation_begin'] if 'next_operation_begin' in result else 0