Skip to content

Commit

Permalink
Log error when retrieving EthereumTx
Browse files Browse the repository at this point in the history
  • Loading branch information
Uxio0 committed Oct 29, 2024
1 parent 9f05a89 commit 0024028
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions safe_transaction_service/history/services/index_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,12 @@ def txs_create_or_update_from_tx_hashes(
ethereum_tx.update_with_block_and_receipt(ethereum_block, tx_receipt)
ethereum_txs_dict[ethereum_tx.tx_hash] = ethereum_tx
logger.debug("Blocks, transactions and receipts were inserted")

# TODO Remove, this is meant to detect a bug on production
for tx_hash, ethereum_tx in ethereum_txs_dict.items():
if not ethereum_tx:
logger.error("Unexpected missing tx with tx-hash=%s", tx_hash)

return list(ethereum_txs_dict.values())

@transaction.atomic
Expand Down

0 comments on commit 0024028

Please sign in to comment.