Uh oh!
There was an error while loading. Please reload this page.
Child.send boolean - #7739
Conversation
MylesBorins
commented
Jul 14, 2016
MylesBorins
commented
Jul 14, 2016
I know this is a backport, but it seems there is an early EDIT: Looks like we need to pull in #3577 too. |
The documentation indicates that child.send() returns a boolean but it has returned undefinined at since v0.12.0. It now returns a boolean per the (slightly updated) documentation. PR-URL: nodejs#3516 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
There are several places in the cluster module where a version of process.send() is called, but the result is swallowed. Most of these cases are internal, but Worker.prototype.send(), which is publicly documented, also suffers from this problem. This commit exposes the return value to facilitate better error handling, and bring Worker.prototype.send() into compliance with the documentation. PR-URL: nodejs#6998 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ron Korving <ron@ronkorving.nl> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
ce048ca to
b902fdaComparecjihrig
commented
Jul 15, 2016
LGTM once #3577 is included, and the CI is happy. Obviously, it's up to the LTS team though. |
rvagg
commented
Jul 18, 2016
A soft -1 from me simply because this is a behaviour change that's nothing close to critical. The impact is fairly minimal, however, and I'm pretty sure it'd not be a breaking change to users in any way unless we uncover some weird edge case with it. |
Fishrock123
commented
Jul 18, 2016
hmmm, yeah, not sure about this. What's the benefit? |
MylesBorins
commented
Jul 18, 2016
main benefit in my opinion was being accurate to the docs that have been shipping since the start of v4 and remove a potentially odd / unexpected behavior difference between 4 / 6 At the same time I can respect the potential to break people, and that isn't in the spirit of LTS |
Fishrock123
commented
Jul 18, 2016
May be safer to fix the docs for LTS |
jasnell
commented
Jul 20, 2016
I'm also leaning -1 on this. |
MylesBorins
commented
Jul 20, 2016
I'm going to close this and opt for a doc fix. Thanks everyone! |
Checklist
make -j4 test(UNIX), orvcbuild test nosign(Windows) passesAffected core subsystem(s)
lib, doc, cluster
Description of change
This is a backport of #3516 and #6998
Originally it was decided to not land #3516 into v4.x as it is semver minor. I would like to ping @nodejs/lts to reconsider as it would appear that the behavior change is accurate to the documentation. Further #6998 also makes a fix based on the documentation that relies on #3516
It may turn out that we do not wish to make a subtle change like this, especially if it can break people in prod. As such I will be running citgm against this to see if there are any obvious failures. If citgm + ci are both green I think we should consider backporting. It is inline with our documentation and will make subtle behavior equivalent in v4 and v6.