Skip to content

Commit

Permalink
Don't kill trace until export batch is empty.
Browse files Browse the repository at this point in the history
  • Loading branch information
NoahSaso committed Jan 6, 2024
1 parent 91db149 commit 2e8013b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/scripts/export/trace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,11 @@ const trace = async () => {
)

const interval = setInterval(() => {
if (exporting === 0 && traceQueue.length === 0) {
if (
exporting === 0 &&
traceQueue.length === 0 &&
exportBatch.length === 0
) {
clearInterval(interval)
resolve()
}
Expand Down

0 comments on commit 2e8013b

Please sign in to comment.