#NEWLINE# def _queue_add_block( self , address , height , total_subsidy , fees , hex_bits , hex_hash , currency , algo , merged = False , worker = None , **kwargs ) : #NEWLINE# #INDENT# block_key = 'current_block_{}_{}' . format ( currency , algo ) #NEWLINE# new_block_key = 'unproc_block_{}' . format ( hex_hash ) #NEWLINE# chain_indexes_serial = self . solve_cmd ( keys = [ ] , args = [ block_key , time . time ( ) , new_block_key ] ) #NEWLINE# chain_indexs = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# for chain in chain_indexes_serial : #NEWLINE# #INDENT# ( chain_id , last_index ) = chain . split ( ':' ) #NEWLINE# chain_indexs [ 'chain_{}_solve_index' . format ( chain_id ) ] = last_index #NEWLINE# #UNINDENT# self . redis . hmset ( new_block_key , dict ( address = address , worker = worker , height = height , total_subsidy = total_subsidy , fees = fees , hex_bits = hex_bits , hash = hex_hash , currency = currency , algo = algo , merged = int ( bool ( merged ) ) , ** chain_indexs ) )