-
-
Notifications
You must be signed in to change notification settings - Fork 222
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
[Feature proposal] Distinguishing between error strings and error numbers #179
Comments
Ah yeah... I should not have reused I don't want to do a breaking change just for this, so I suggest we add a And in the next major version, we stop putting the exit code on the |
Sounds good. So |
|
Since |
What would it contain? Example? |
For example |
Do you have any use-case for this? You could mostly compare |
The use case would be if a user wants to print the signal name but not number. Some users might consider that more user-friendly. Also signal names are cross-platform, whereas signal numbers aren't. |
Alright, any suggestion on what to name this string-only property? |
|
I think it should be |
Should |
👍
No, I think it should stay, since users are used to it from Node.js core errors. |
PR at #187 |
At the moment
result.code
is either a string likeEACCES
, an integer like13
orundefined
.It would be nice to split this property into two:
code
for the string anderrno
for the integer.This would be a breaking change if the name
code
is re-used. Otherwise we can pick another property name.If this sounds good, I will submit a PR.
The text was updated successfully, but these errors were encountered: