fix(reporter): do not hang perfetto writes after a stream error - #42715
Open
Sebastien Tardif (SebTardif) wants to merge 2 commits into
Open
Sebastien Tardif (SebTardif) wants to merge 2 commits into
Sebastien Tardif (SebTardif) wants to merge 2 commits into
Conversation
A failed write after backpressure waited forever for drain. Reject that wait on error and settle the close promise so the reporter exits. Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
Contributor
Test results for "tests 1"1 failed 2 flaky51731 passed, 1247 skipped Merge workflow run. |
Contributor
Test results for "MCP"2 failed 8562 passed, 1446 skipped Merge workflow run. |
This was referenced Sep 15, 2026
Devin Rousso (dcrousso)
requested changes
Sep 15, 2026
Listen for file-stream errors while waiting on gzip drain. Signed-off-by: Sebastien Tardif <sebtardif@ncf.ca>
Sebastien Tardif (SebTardif)
requested a review
from Devin Rousso (dcrousso)
September 15, 2026 23:56
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Problem
ChunkWriter.writewaited only on'drain'. Afterwrite()returned false, an'error'(for example ENOSPC or EISDIR) never fired drain, soonEndhung.Change
The drain waiter also listens for
'error'. The close promise resolves on'error'as well as'close'soclose()can rethrow.Validation
tests/playwright-test/reporter-perfetto.spec.ts: pointingoutputFileat a directory makes the run fail instead of hanging.