Ejemplo n.º 1
0
 def _export_receipts(self, transaction_hashes):
     receipts_rpc = list(generate_get_receipt_json_rpc(transaction_hashes))
     response = self.batch_web3_provider.make_batch_request(json.dumps(receipts_rpc))
     results = rpc_response_batch_to_results(response)
     receipts = [self.receipt_mapper.json_dict_to_receipt(result) for result in results]
     for receipt in receipts:
         self._export_receipt(receipt)
Ejemplo n.º 2
0
 def _export_receipts(self, tx_hashes):
     receipts_rpc = list(
         generate_get_receipt_by_tx_hash_json_rpc(tx_hashes))
     response = self.ipc_wrapper.make_request(json.dumps(receipts_rpc))
     results = rpc_response_batch_to_results(response)
     receipts = [
         self.receipt_mapper.json_dict_to_receipt(result)
         for result in results
     ]
     for receipt in receipts:
         self._export_receipt(receipt)
Ejemplo n.º 3
0
    def _export_batch(self, batch_start, batch_end):
        blocks_rpc = list(
            generate_get_block_by_number_json_rpc(batch_start, batch_end,
                                                  self.export_transactions))
        response = self.ipc_wrapper.make_request(json.dumps(blocks_rpc))
        results = rpc_response_batch_to_results(response)
        blocks = [
            self.block_mapper.json_dict_to_block(result) for result in results
        ]

        for block in blocks:
            self._export_block(block)