Skip to content

Commit

Permalink
Add more fault tolerance for eth txn receipt query (#235)
Browse files Browse the repository at this point in the history
  • Loading branch information
wanliqun authored Oct 15, 2024
1 parent dc185a3 commit 09ee1a8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions store/eth_data.go
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,12 @@ func queryEthReceiptByEthTxnReceipt(
if err != nil {
return nil, errors.WithMessagef(err, "failed to get block (%v)", bnh)
}

if block == nil {
return nil, errors.New("invalid block data (must not be nil)")
}
}

txnHashes := getEthBlockTxnHashes(block)

if rcptOpt.Concurrency <= 1 { // No parallelism
Expand Down

0 comments on commit 09ee1a8

Please sign in to comment.