-
-
Notifications
You must be signed in to change notification settings - Fork 16.7k
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
Proposed check for port already in use #1569
Comments
EADDRINUSE is pretty descriptive IMO, even if it's just an all caps errno, any changes to make things more descriptive should be in node core, I'd love to actually patch node to display things like |
@isaacs do you think it would be reasonable to add something like ^ that in core? similar to the original patches to show the filename of file related errors I think this would help quite a bit |
Yeah, we could add something helpful there, like the port/host/path you passed to listen(). Patch welcome. |
@isaacs cool thanks for the confirmation I'll send a patch when I have a minute |
When express.js generates app.js to start the Express server on a port (default 3000), it throws an exception if the port is already in use. So instead, the error could be caught with the following check and produce a more descriptive error message, by changing:
to:
The text was updated successfully, but these errors were encountered: