Skip to content

Commit

Permalink
dtl: fix race condition (#2646)
Browse files Browse the repository at this point in the history
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
  • Loading branch information
tynes and mergify[bot] committed Jun 1, 2022
1 parent 50d2b10 commit 553180e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/many-timers-chew.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@eth-optimism/data-transport-layer': patch
---

Fix race condition
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,6 @@ export const handleEventsSequencerBatchAppended: EventHandlerSet<
}
}

await db.putTransactionBatchEntries([entry.transactionBatchEntry])
await db.putTransactionEntries(entry.transactionEntries)

// Add an additional field to the enqueued transactions in the database
Expand All @@ -219,6 +218,8 @@ export const handleEventsSequencerBatchAppended: EventHandlerSet<
)
}
}

await db.putTransactionBatchEntries([entry.transactionBatchEntry])
},
}

Expand Down

0 comments on commit 553180e

Please sign in to comment.