X Tutup
The Wayback Machine - https://web.archive.org/web/20210813211853/https://github.com/nodejs/node/pull/38181
Skip to content
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

doc: clarify child_process close event #38181

Closed
wants to merge 2 commits into from

Conversation

@Linkgoron
Copy link
Member

@Linkgoron Linkgoron commented Apr 10, 2021

Clarify the 'close' event description in the child_process docs.

This event is a bit confusing, as the documentation did not state that:

  • It's supposed to get emitted after "exit" was already emitted.
  • It also emits when the child_process has failed to spawn (and thus, exit will never be emitted). Another detail, that I did not add to the docs, is that in this case the exit code passed to the closed handler is negative. Should this be mentioned?

fixes: #37998

clarify the 'close' event description in the child_process docs.

fixes: #37998
Copy link
Member

@benjamingr benjamingr left a comment

LGTM

@lpinca
lpinca approved these changes Apr 10, 2021
@jasnell
Copy link
Member

@jasnell jasnell commented Apr 12, 2021

Landed in 474fbb5

@jasnell jasnell closed this Apr 12, 2021
jasnell added a commit that referenced this pull request Apr 12, 2021
clarify the 'close' event description in the child_process docs.

fixes: #37998

PR-URL: #38181
Fixes: #37998
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
BethGriggs added a commit that referenced this pull request Apr 15, 2021
clarify the 'close' event description in the child_process docs.

fixes: #37998

PR-URL: #38181
Fixes: #37998
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
targos added a commit that referenced this pull request May 1, 2021
clarify the 'close' event description in the child_process docs.

fixes: #37998

PR-URL: #38181
Fixes: #37998
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
@danielleadams danielleadams mentioned this pull request May 3, 2021
danielleadams added a commit that referenced this pull request May 8, 2021
clarify the 'close' event description in the child_process docs.

fixes: #37998

PR-URL: #38181
Fixes: #37998
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

6 participants
X Tutup