You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
doc: readable.read() still documents pre-v26 behaviour (returns all buffered data when size is omitted) #67323
Since v26.0.0, readable.read() called with no size returns one buffered chunk per call. This came from #60441 (semver-major, "stream: readable read one buffer at a time"). The API docs still describe the old behaviour:
If the size argument is not specified, all of the data contained in the internal buffer will be returned.
The YAML history of readable.read([size]) also has no changes: entry for v26.0.0.
Reproduction. A non-object-mode Readable with three pushes:
Add the migration hint from stream: readable read one buffer at a time #60441's description: readable.read(readable.readableLength) gets close to the old behaviour, and some edge cases need a readable.read(0) first.
The v26.0.0 changelog lists this change only under "Semver-Major Commits", not under "Notable Changes", so it is easy to miss when upgrading. Code that loops on read() and does work per call changes its output shape. For example, Next.js 16.4's inline Flight writer emits one <script> per read() call, so on Node 26 a large App Router page carries about 20× more inline scripts and gets slower at the tail.
Activity
v-dev-cl commentedon Nov 7, 2026
Downstream report with a minimal reproduction: vercel/next.js#101343 (Next.js 16.4's inline Flight writer loops on
read(); on Node 26 a page goes from 3 to 407 inline scripts). Repro: https://github.com/v-dev-cl/next-node26-flight-repro