You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Currently, createServer calls server.listen but this method always resolves, even if there is a problem such as the port being taken. This means ultimately these exceptions land as unhandled exceptions as there is no way to handle them.
To Reproduce
Start prism-cli on a certain port.
In another terminal start one on the same port.
Expected behaviour
I'd expect the promise to reject, which would allow those of us using createServer directly to handle the scenario. It would also allow prism-cli to respond gracefully without causing an unhandled exception.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment (remove any that are not applicable):
Library version: 3.3.3
OS: OSX Catalina
The text was updated successfully, but these errors were encountered:
Describe the bug
Currently,
createServer
callsserver.listen
but this method always resolves, even if there is a problem such as the port being taken. This means ultimately these exceptions land as unhandled exceptions as there is no way to handle them.To Reproduce
Expected behaviour
I'd expect the promise to reject, which would allow those of us using
createServer
directly to handle the scenario. It would also allow prism-cli to respond gracefully without causing an unhandled exception.Screenshots
If applicable, add screenshots to help explain your problem.
Environment (remove any that are not applicable):
The text was updated successfully, but these errors were encountered: