Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
fix(forking): ignore txs that fail when running the block in traceTra…
Browse files Browse the repository at this point in the history
…nsaction (#929)
  • Loading branch information
davidmurdoch committed Aug 6, 2021
1 parent f5508da commit 8f69e39
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/chains/ethereum/ethereum/src/helpers/run-transactions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,13 @@ export async function runTransactions(
block: RuntimeBlock
) {
for (let i = 0, l = transactions.length; i < l; i++) {
await vm.runTx({
tx: transactions[i] as any,
block: block as any
});
await vm
.runTx({
tx: transactions[i] as any,
block: block as any
})
// we ignore transactions that error because we just want to _run_ these,
// transactions just to update the blockchain's state
.catch(() => {});
}
}

0 comments on commit 8f69e39

Please sign in to comment.