Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stream: fix typo in ReadableStreamBYOBReader.readIntoRequests #56560

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

MattiasBuelens
Copy link
Contributor

The readIntoRequests field was misspelled as requestIntoRequests. This didn't break anything of importance, but it did show up when inspecting the ReadableStreamBYOBReader:

$ node
> rs = new ReadableStream({ type: "bytes" })
> reader = rs.getReader({ mode: "byob" })
ReadableStreamBYOBReader {
  stream: ReadableStream { locked: true, state: 'readable', supportsBYOB: true },
  requestIntoRequests: 0,
  close: Promise {
    <pending>,
    [Symbol(async_id_symbol)]: 192,
    [Symbol(trigger_async_id_symbol)]: 6
  }
}
> reader.read(new Uint8Array(1))
> reader
ReadableStreamBYOBReader {
  stream: ReadableStream { locked: true, state: 'readable', supportsBYOB: true },
  requestIntoRequests: 0,
  close: Promise {
    <pending>,
    [Symbol(async_id_symbol)]: 192,
    [Symbol(trigger_async_id_symbol)]: 6
  }
}

Note that requestIntoRequests always stays 0, whereas it should be 1 because of the pending read(view) request.

@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. web streams labels Jan 11, 2025
@nodejs-github-bot
Copy link
Collaborator

Copy link

codecov bot commented Jan 11, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.17%. Comparing base (3946f16) to head (61255ff).
Report is 5 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #56560   +/-   ##
=======================================
  Coverage   89.16%   89.17%           
=======================================
  Files         662      662           
  Lines      191751   191751           
  Branches    36900    36912   +12     
=======================================
+ Hits       170972   170990   +18     
+ Misses      13635    13624   -11     
+ Partials     7144     7137    -7     
Files with missing lines Coverage Δ
lib/internal/webstreams/readablestream.js 98.44% <100.00%> (ø)

... and 33 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-ci PRs that need a full CI run. web streams
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants