-
Notifications
You must be signed in to change notification settings - Fork 31.3k
stream: catch and forward error from dest.write #55270
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
Conversation
Review requested:
|
I don't think it should be supported. It is most likely a programmer error. |
76823e6
to
6dfdf7e
Compare
I agree, but I am afraid this would break many user land packages. |
We could mark it as semver-major and run CITGM. I think it should be fixed in the "broken" packages and I don't think there are many of them. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #55270 +/- ##
=======================================
Coverage 87.95% 87.96%
=======================================
Files 656 656
Lines 188310 188315 +5
Branches 35963 35973 +10
=======================================
+ Hits 165630 165645 +15
+ Misses 15854 15848 -6
+ Partials 6826 6822 -4
|
I've been thinking about it, and I think we should more carefully consider whether we should throw directly in The reasons being:
To wrap up, what I am trying to say is that we may wanna consider this breaking change more carefully as all the cc. @nodejs/streams |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will likely break a lot of modules.
Many people (including myself) use object mode streams with strings or buffers. Even Node.js Core implies that, as we assumed this when we flipped Readable.from()
to always be in object mode: Readable.from(['a', 'b']).pipe(fs.createWriteStream())
@mcollina I think you misunderstand this PR. It basically fixes an uncatchable error. Doesn't break anything as far as I can tell. |
Though I do think this PR is a little over engineered. It's enough to catch the error and forward it "as is" to destroy. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I totally misunderstood this. I've left a few comments.
Thank you for the review! 🙏 I appreciate the feedback and am happy to remove this error. As @ronag pointed out, it seems like I may have over-engineered it. My initial intention was to help developers understand the error better, but looking back, it appears I might've complicated things more than I've fixed. Another point for discussion is whether we should catch the error and call destroy on the |
I disagree with @lpinca on this one and would prefer a catchable error. The exception guarantee is understandable and it's possible to isolate the error from other working parts of a service, i.e. better to have a http server return 500 on a broken path than stop responding on all paths. |
The error is already understandable (your suggestion is to call I would also argue that if we want this behavior we should make |
@ronag this change of behavior would be semver-major anyway. |
I'm still unsure about whether we should catch the error or proceed with a hard crash. Is there a similar example in Node.js core that we could use for comparison? On the other hand, does those lines make sense? diff --git a/lib/internal/streams/writable.js b/lib/internal/streams/writable.js
index ac14b202b6..5225aa13f4 100644
--- a/lib/internal/streams/writable.js
+++ b/lib/internal/streams/writable.js
@@ -477,8 +477,9 @@ function _write(stream, chunk, encoding, cb) {
chunk = Stream._uint8ArrayToBuffer(chunk);
encoding = 'buffer';
} else {
- throw new ERR_INVALID_ARG_TYPE(
- 'chunk', ['string', 'Buffer', 'TypedArray', 'DataView'], chunk);
+ stream.destroy(new ERR_INVALID_ARG_TYPE(
+ 'chunk', ['string', 'Buffer', 'TypedArray', 'DataView'], chunk));
+ return
}
} or I should move what I've done in the catch block into |
I think your PR was fine other than there is no need to convert it into another error. |
c01a0b9
to
52d26c2
Compare
52d26c2
to
de9f68a
Compare
CI is green again, can I get another approval or can someone take another look (since I need to rebase to pass the GHA) 🙏 |
This PR is technically ready to land, would you mind taking another quick look on CITGM @mcollina Also need another approval since this PR needed a rebase |
Any news about this PR? We couldn’t found a workaround. And I couldn’t confirm if this PR fixes the issue. |
Hi @mshima I have a few questions here:
|
@jakecastelli thanks for your attention. In my tests, node 22.4.0 works as expected. Creating a minimal reproduction to match our use case is quite difficult, but seems likely this issue.
replace:
with (to make prettier fail):
Generate with offending file in an empty folder:
|
Thanks for providing some more info, I haven't run the script yet to install the pkg, could you confirm if the package name is correct? I searched on npm and found this https://www.npmjs.com/package/jhipster?activeTab=readme and is probably not the one I suppose to install |
@jakecastelli sorry it’s generator-jhipster |
This is the error I've got, do you mind explaining a bit more on why you think this is related to the pipeline? And how do I test with node error
|
That's the expected error.
Looks related to pipeline transforms like: Duplex.from(async function* (files: AsyncGenerator<MemFsEditorFile>) {
for await (const file of files) {
if (isFilePending(file)) {
yield file;
}
}
}),
I use
It's not a single place, yeoman/generator#1577, SBoudrias/mem-fs-editor#282, SBoudrias/mem-fs#40. |
Hi @aduh95 I see you've helped with the CITGM result here - #55270 (comment) 🙏 I have to admit, I'm not entirely sure how to interpret the results. Is there any documentation that explains how to understand the CITGM results? For this PR, are there any user-land packages I should examine more closely? |
Landed in fd8de67 |
const assert = require('node:assert'); | ||
const { Readable, Transform, Writable } = require('node:stream'); | ||
|
||
// Pipeine objects from object mode to non-object mode should throw an error and |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jakecastelli sorry, just out curiosity, is pipeine
a typo? should it be pipeline
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is a typo, thanks for spotting it and PR welcome 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had an other look, my origin intention should be piping
, I've created a quick PR here
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: TBD
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) remove `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #55862 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609
Semver-Major Commits: buffer: * (SEMVER-MAJOR) make `buflen` in integer range (zhenweijin) #51821 build: * (SEMVER-MAJOR) bump supported macOS version to 13.5 (Michaël Zasso) #57115 * (SEMVER-MAJOR) increase minimum Xcode version to 16.1 (Michaël Zasso) #56824 * (SEMVER-MAJOR) link V8 with atomic library (Michaël Zasso) #55014 * (SEMVER-MAJOR) remove support for ppc 32-bit (Michaël Zasso) #55014 * (SEMVER-MAJOR) reset embedder string to "-node.0" (Michaël Zasso) #55014 child_process: * (SEMVER-MAJOR) deprecate passing `args` to `spawn` and `execFile` (Daniel Venable) #57199 deps: * (SEMVER-MAJOR) V8: cherry-pick f915fa4c9f41 (Olivier Flückiger) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0d5d6e71bbb0 (Yagiz Nizipli) #55014 * (SEMVER-MAJOR) V8: cherry-pick 0c11feeeca4a (Michaël Zasso) #55014 * (SEMVER-MAJOR) define V8_PRESERVE_MOST as no-op on Windows (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) always define V8_NODISCARD as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) fix FP16 bitcasts.h (Stefan Stojanovic) #55014 * (SEMVER-MAJOR) patch V8 to support compilation with MSVC (StefanStojanovic) #55014 * (SEMVER-MAJOR) patch V8 to avoid duplicated zlib symbol (Michaël Zasso) #55014 * (SEMVER-MAJOR) disable V8 concurrent sparkplug compilation (Michaël Zasso) #55014 * (SEMVER-MAJOR) always define V8_EXPORT_PRIVATE as no-op (Michaël Zasso) #55014 * (SEMVER-MAJOR) update V8 to 13.0.245.25 (Michaël Zasso) #55014 * (SEMVER-MAJOR) upgrade npm to 11.0.0 (npm team) #56274 * (SEMVER-MAJOR) update undici to 7.0.0 (Node.js GitHub Bot) #56070 fs: * (SEMVER-MAJOR) remove ability to call truncate with fd (Yagiz Nizipli) #57567 * (SEMVER-MAJOR) deprecate passing invalid types in `fs.existsSync` (Carlos Espa) #55753 * (SEMVER-MAJOR) runtime deprecate `fs.F_OK`, `fs.R_OK`, `fs.W_OK`, `fs.X_OK` (Livia Medeiros) #49686 * (SEMVER-MAJOR) remove `dirent.path` (Antoine du Hamel) #55548 lib: * (SEMVER-MAJOR) remove obsolete Cipher export (James M Snell) #57266 * (SEMVER-MAJOR) unexpose six process bindings (Michaël Zasso) #57149 * (SEMVER-MAJOR) make ALS default to AsyncContextFrame (Stephen Belanger) #55552 * (SEMVER-MAJOR) runtime deprecate SlowBuffer (Rafael Gonzaga) #55175 net: * (SEMVER-MAJOR) make _setSimultaneousAccepts() end-of-life deprecated (Yagiz Nizipli) #57550 repl: * (SEMVER-MAJOR) runtime deprecate instantiating without new (Aviv Keller) #54869 src: * (SEMVER-MAJOR) update GetForegroundTaskRunner override (Etienne Pierre-doray) #55014 * (SEMVER-MAJOR) update NODE_MODULE_VERSION to 134 (Michaël Zasso) #55014 * (SEMVER-MAJOR) drop --experimental-permission in favour of --permission (Rafael Gonzaga) #56240 * (SEMVER-MAJOR) add async context frame to AsyncResource (Gerhard Stöbich) #56082 * (SEMVER-MAJOR) nuke deprecated and un-used enum members in `OptionEnvvarSettings` (Juan José) #53079 stream: * (SEMVER-MAJOR) catch and forward error from dest.write (jakecastelli) #55270 test: * (SEMVER-MAJOR) disable fast API call count checks (Michaël Zasso) #55014 test_runner: * (SEMVER-MAJOR) remove promises returned by t.test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) remove promises returned by test() (Colin Ihrig) #56664 * (SEMVER-MAJOR) automatically wait for subtests to finish (Colin Ihrig) #56664 timers: * (SEMVER-MAJOR) check for immediate instance in clearImmediate (Gürgün Dayıoğlu) #57069 * (SEMVER-MAJOR) set several methods EOL (Yagiz Nizipli) #56966 tls: * (SEMVER-MAJOR) remove deprecated tls.createSecurePair (Jonas) #57361 * (SEMVER-MAJOR) make server.prototype.setOptions end-of-life (Yagiz Nizipli) #57339 tools: * (SEMVER-MAJOR) update V8 gypfiles for 13.0 (Michaël Zasso) #55014 url: * (SEMVER-MAJOR) expose urlpattern as global (Jonas) #56950 * (SEMVER-MAJOR) runtime deprecate url.parse (Yagiz Nizipli) #55017 zlib: * (SEMVER-MAJOR) deprecate classes usage without `new` (Yagiz Nizipli) #55718 PR-URL: #57609 Signed-off-by: RafaelGSS <rafael.nunu@hotmail.com>
Fixes: #54945
Wanted to give a quick mention why checking object modes at the start of the pipe function wouldn't work (even though I liked the idea). Because if the chunk from the source stream is not object while source stream is in object mode and destination stream is not in object mode, it should still work.
Consider the following example: