GeezerVison is showing github.com — http2: finish pending writes after stream close by trivikr · Pull Request #63439 · nodejs/node
Conversation
trivikr
commented
May 19, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
This fixes a race where an HTTP/2 stream can close while writes are still
queued. In that state, pending write callbacks could be left unresolved, which
kept the test process alive until timeout.
The fix completes pending write callbacks when nghttp2 closes the stream and
prevents additional data from being queued once the stream is closed.
The existing regression test now also verifies that all server-side write
callbacks run before the stream closes.
Fixes: #58252
Tested with:
python3 tools/test.py parallel/test-http2-close-while-writing
python3 tools/test.py --repeat=1000 parallel/test-http2-close-while-writing
python3 tools/test.py --repeat=10000 parallel/test-http2-close-while-writing
Assisted-by: openai:gpt-5.5
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
Review requested:
- @nodejs/http2
- @nodejs/net
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
nodejs-github-bot
added
c++
Issues and PRs that require attention from people who are familiar with C++.
lib / src
Issues and PRs involving general changes in the lib/ or src/ directories.
needs-ci
PRs that need a full CI run.
labels
May 19, 2026
Flush pending Http2Stream write callbacks when nghttp2 closes the
stream but JS keeps it alive to finish readable-side cleanup. Also
avoid queueing additional writes once the stream is closed.
Fixes: nodejs#58252
Signed-off-by: Kamat, Trivikram <[email protected]>
Assisted-by: openai:gpt-5.5
|
See also #63249
As a happy side bonus, as part of this work I hunted down the underlying issue for #58252: buggy cleanup of reset streams.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
codecov
Bot
commented
May 19, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
|
❌ Patch coverage is 88.88889% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 90.06%. Comparing base (0b5b189) to head (58e9183).
⚠️ Report is 1 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #63439 +/- ##
=======================================
Coverage 90.06% 90.06%
=======================================
Files 714 714
Lines 225918 225931 +13
Branches 42734 42739 +5
=======================================
+ Hits 203464 203480 +16
- Misses 14232 14233 +1
+ Partials 8222 8218 -4
... and 29 files with indirect coverage changes
🚀 New features to boost your workflow:
- ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Labels
c++
Issues and PRs that require attention from people who are familiar with C++.
lib / src
Issues and PRs involving general changes in the lib/ or src/ directories.
needs-ci
PRs that need a full CI run.
Milestone
No milestone
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.