-
Notifications
You must be signed in to change notification settings - Fork 30.4k
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
ENOTFOUND is a real error; lets document it! #26484
Comments
It indeed seems to late to fix that inconsistency. Adding the actual error code to the error also seems like a good idea. The only question for me is how the property should be named. We might also want to check if let's say 90% of all common network errors are of either of the two types. If that is the case, we might want to just use |
I think in practice applications wouldn’t make a difference between So I don’t think aliasing one of these errors to |
I agree that it likely makes little difference for the user. That is why I'd like to add an extra property (e.g., |
PR-URL: nodejs#26495 Fixes: nodejs#26484 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: James M Snell <[email protected]>
@cjihrig and reviewers, thank you so much! |
PR-URL: #26495 Fixes: #26484 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: James M Snell <[email protected]>
PR-URL: #26495 Fixes: #26484 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: James M Snell <[email protected]>
PR-URL: #26495 Fixes: #26484 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Rich Trott <[email protected]> Reviewed-By: James M Snell <[email protected]>
As best as I can tell, network failure often surfaces to the Node user with an error ENOTFOUND. In attempting to determine under what conditions this error is thrown, we found that the ENOTFOUND error is not documented.
@addaleax pointed out that there's a FIXME comment from @bnoordhuis suggesting this error is temporary, but I bet ENOTFOUND is pretty baked and changing it would cause significant friction.
So I'd like to propose the following:
The text was updated successfully, but these errors were encountered: