stream: don't flush destroyed writable by ronag · Pull Request #29028 · nodejs/node
Closed
wants to merge 4 commits into
Hidden character warning
The head ref may contain hidden characters:
"stream-flush-destro\u00fded-writable"
Conversation
It doesn't make much sense (and is a bit weird) to flush a stream which has been destroyed.
I need help creating a relevant test for this.
Checklist
-
make -j4 test(UNIX), orvcbuild test(Windows) passes - tests and/or benchmarks are included
- documentation is changed or added
- commit message follows commit guidelines
NOTE TO SELF: Look into needFinish & stream destroyed. errorOrDestroy added in this PR should preferably be async.
ronag
mentioned this pull request
4 tasks
Hmm.. I'm thinking this is more bug fix than breaking change. What do you think @mcollina?
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will need a unit test.
I'm happy to land this as a bug fix as long as it does not break anything on CITGM.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would still consider this a bugfix, but we should:
- verify that CITGM passes
- let it bake for LTS (10.x) for some time before backporting.
@mcollina: Sorry, found further issues.
Consider the updated tests. We now will throw ERR_STREAM_DESTROYED on some tests that assume ERR_STREAM_WRITE_AFTER_END also we now send the err on the write callback and don't emit it as an error on the stream.
How should this be?
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn’t mind being careful and labelling this semver-major.
Ok, I think everything (expect @mcollina's comment on is fixed in a sensical manner.!err && chinksWritten++)
ronag
mentioned this pull request
This was referenced
This was referenced