Repository navigation
stream: fix stale byte stream queue size - #67499
Open
MattiasBuelens wants to merge 1 commit into
Open
MattiasBuelens wants to merge 1 commit into
MattiasBuelens wants to merge 1 commit into
Conversation
Re-read the byte controller's queue size before filling each pending read request. A released BYOB reader can leave a partially filled pull-into descriptor that is enqueued while a default reader has multiple pending reads. Caching the queue size causes the loop to dequeue from an empty queue after fulfilling the first read request. Add a regression test for one, two, and three pending reads and verify that any remaining queued bytes are preserved. Signed-off-by: Mattias Buelens <mattias@buelens.com>
MattiasBuelens
force-pushed
the
webstreams-byte-enqueue-stale-queue-size
branch
from
November 15, 2026 20:13
496e1e8 to
01f4238
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #67499 +/- ##
=======================================
Coverage 90.66% 90.66%
=======================================
Files 799 799
Lines 280254 280243 -11
Branches 54122 54116 -6
=======================================
- Hits 254091 254083 -8
- Misses 16280 16281 +1
+ Partials 9883 9879 -4
🚀 New features to boost your workflow:
|
jasnell
approved these changes
Nov 15, 2026
Collaborator
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.
Re-read the byte controller's queue size before filling each pending read request. A released BYOB reader can leave a partially filled pull-into descriptor that is enqueued while a default reader has multiple pending reads. Caching the queue size causes the loop to dequeue from an empty queue after fulfilling the first read request, which triggers an internal assertion error.
Add a regression test for one, two, and three pending reads and verify that any remaining queued bytes are preserved. (I'll also upstream this test to Web Platform Tests.)
Disclosure: code generated by AI (6.1 Sol via Codex), reviewed by me.