Closed
Labels
streamIssues and PRs related to Node.js streams.Issues and PRs related to Node.js streams.
Description
Version
main
Platform
macOS 26.5.0
Subsystem
stream
What steps will reproduce the bug?
import { push } from 'stream/iter';
const { writer, readable } = push({ highWaterMark: 10 });
try {
writer.writevSync([1]);
} catch (e) {
console.log(e.name, e.code);
}
console.log(await readable[Symbol.asyncIterator]().next());How often does it reproduce? Is there a required condition?
Always
What is the expected behavior? Why is that the expected behavior?
writevSync([1]) should throw a Node validation error like TypeError ERR_INVALID_ARG_TYPE, and the invalid chunk should not be written, so the readable should remain empty/pending.
What do you see instead?
TypeError undefined
[Object: null prototype] { done: false, value: [ 1 ] }it throws TypeError undefined, and the invalid value is queued.
Additional information
No response
Metadata
Metadata
Assignees
Labels
streamIssues and PRs related to Node.js streams.Issues and PRs related to Node.js streams.
Activity
stream: validate writevSync chunks before queuing
stream: validate writevSync chunks before queuing
stream: validate writevSync chunks before queuing
stream: validate writevSync chunks before queuing
stream: validate writevSync chunks before queuing