-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
events: show inspected error in uncaught 'error' message #25621
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729
nodejs-github-bot
added
the
events
Issues and PRs related to the events subsystem / EventEmitter.
label
Jan 21, 2019
lpinca
approved these changes
Jan 21, 2019
BridgeAR
approved these changes
Jan 22, 2019
@BridgeAR Done, thanks for the review! |
addaleax
added
the
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
label
Jan 22, 2019
mmarchini
approved these changes
Jan 23, 2019
addaleax
added a commit
that referenced
this pull request
Jan 23, 2019
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729 PR-URL: #25621 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matheus Marchini <mat@mmarchini.me>
Landed in eeea0dd |
addaleax
added a commit
that referenced
this pull request
Jan 23, 2019
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729 PR-URL: #25621 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matheus Marchini <mat@mmarchini.me>
Merged
MylesBorins
added a commit
that referenced
this pull request
Jan 24, 2019
Notable Changes: * events: * For unhandled `error` events with an argument that is not an `Error` object, the resulting exeption will have more information about the argument. #25621 * child_process: * When the `maxBuffer` option is passed, `stdout` and `stderr` will be truncated rather than unavailable in case of an error. #24951 * policy: * Experimental support for module integrity checks through a manifest file is implemented now. #23834 * n-api: * The `napi_threadsafe_function` feature is now stable. #25556 * report: * An experimental diagnostic API for capturing process state is available as `process.report` and through command line flags. #22712 * tls: * `tls.connect()` takes a `timeout` option analogous to the `net.connect()` one. #25517 * worker: * `process.umask()` is available as a read-only function inside Worker threads now. #25526 * An `execArgv` option that supports a subset of Node.js command line options is supported now. #25467 PR-URL: #25687
MylesBorins
added a commit
that referenced
this pull request
Jan 25, 2019
Notable Changes: * events: * For unhandled `error` events with an argument that is not an `Error` object, the resulting exeption will have more information about the argument. #25621 * child_process: * When the `maxBuffer` option is passed, `stdout` and `stderr` will be truncated rather than unavailable in case of an error. #24951 * policy: * Experimental support for module integrity checks through a manifest file is implemented now. #23834 * n-api: * The `napi_threadsafe_function` feature is now stable. #25556 * report: * An experimental diagnostic API for capturing process state is available as `process.report` and through command line flags. #22712 * tls: * `tls.connect()` takes a `timeout` option analogous to the `net.connect()` one. #25517 * worker: * `process.umask()` is available as a read-only function inside Worker threads now. #25526 * An `execArgv` option that supports a subset of Node.js command line options is supported now. #25467 PR-URL: #25687
BethGriggs
pushed a commit
that referenced
this pull request
Apr 29, 2019
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729 PR-URL: #25621 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matheus Marchini <mat@mmarchini.me>
Merged
BethGriggs
pushed a commit
that referenced
this pull request
May 10, 2019
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729 PR-URL: #25621 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matheus Marchini <mat@mmarchini.me>
MylesBorins
pushed a commit
that referenced
this pull request
May 16, 2019
If there is no handler for `.emit('error', value)` and `value` is not an `Error` object, we currently just call `.toString()` on it. Almost always, using `util.inspect()` provides better information for diagnostic purposes, so prefer to use that instead. Refs: nodejs/help#1729 PR-URL: #25621 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matheus Marchini <mat@mmarchini.me>
This was referenced May 29, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
author ready
PRs that have at least one approval, no pending requests for changes, and a CI started.
events
Issues and PRs related to the events subsystem / EventEmitter.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
If there is no handler for
.emit('error', value)
andvalue
is not an
Error
object, we currently just call.toString()
on it.
Almost always, using
util.inspect()
provides better informationfor diagnostic purposes, so prefer to use that instead.
Refs: nodejs/help#1729
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes