GeezerVison is showing github.com — fix(h2): keep the session ref'd while requests are queued by kjsik11 · Pull Request #5839 · nodejs/undici
Conversation
This relates to...
Same fix as #5605, which landed on v7.x only.
Rationale
resumeH2() unrefs the session when the peer advertises SETTINGS_MAX_CONCURRENT_STREAMS = 0 even while requests are still queued.
The result is that no handles are left to keep the event loop alive, so the process exits with status 0 while the awaited request never settles.
Changes
lib/dispatcher/client-h2.js: remove the client[kMaxConcurrentStreams] === 0 from the condition, same as fix(h2): keep the connection ref'd while requests are outstanding #5605
test/http2-max-concurrent-streams-zero-unref.js + test/fixtures/h2-no-streams-client.js: child process queues a request behind maxConcurrentStreams: 0 and must stay alive until the headersTimeout error
Features
Bug Fixes
- With a request queued behind
SETTINGS_MAX_CONCURRENT_STREAMS = 0 the process now stays alive until the request settles
Breaking Changes and Deprecations
Tests (Node 24.20.0)
npm run lint
npm run test:h2:core (117/117)
npx borp -p "test/http2-max-concurrent-streams-zero-unref.js" (1/1, main 0/1)
Assisted-by: Claude Code
Status
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.52%. Comparing base (bfea020) to head (88941ad).
⚠️ Report is 2 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #5839 +/- ##
==========================================
- Coverage 93.53% 93.52% -0.01%
==========================================
Files 110 110
Lines 39773 39773
==========================================
- Hits 37200 37199 -1
- Misses 2573 2574 +1
☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.
🚀 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.
This was referenced Sep 18, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
This was referenced Sep 21, 2026
Reviewers
mcollina
mcollina approved these changes
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
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.