-
-
Notifications
You must be signed in to change notification settings - Fork 140
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
Unix.EADDRINUSE #139
Comments
Interesting. From your excerpt it looks like this error happened immediately after you tried to start the server. Is that correct? EADDRINUSE can occur if some other service is already using the port that |
I can't immediately think of what might be calling |
I got this error so often that I decided to add simple script to kill the port before starting dream server. Simple and effective. |
@aantron : Unfortunately, no. I've tried to reproduce this on two different machines (Debian and MacOS), and thus far the only way I get an error like the one listed above is if I try to run two copies of the server process at once. @thangngoc89 : When you wrote
Could you clarify, is this specific to the example project (sensors), or working with Dream in general? I'd like to understand if there should be a more user friendly set of scripts/commands on the example project. |
@idkjs, @thangngoc89 what OS are you on? Can you give steps to reproduce this? |
@aantron here is the reproduction. https://github.com/idkjs/sensors. ❯ sw_vers
ProductName: macOS
ProductVersion: 11.4
BuildVersion: 20F71 You run it. It works. Then you decide to do something to it. You @jsthomas It is not impossible that I did something like that, so I closed any editors, checked to see if there was anything on the port, there was nothing, and I ran it again. Same thing. |
Have not been able to observe it on
In particular, with commit idkjs/sensors@fb7d214, I did:
all was well. I also tried running the server while @thangngoc89 what system are you on? |
Also @jsthomas, what system are you using? |
@aantron I am able to reproduce your results and not mine though now I am getting another error that seems unrelated maybe. This machine is weird today. I can't install melange anywhere at the moment either Details```sh /Github/sensors main 4m 16s 3.0.1 ❯ eval (opam env)~/Github/sensors main 3.0.1 ~/Github/sensors main ✘ INT 6s 3.0.1 ~/Github/sensors main ✘ INT 4s 3.0.1 ~/Github/sensors main ✘ INT 1m 45s 3.0.1 ~/Github/sensors main ✘ INT 36s 3.0.1 21.07.21 21:28:54.786 dream.log WARN REQ 1 Raised at Dream__middleware__3 21.07.21 21:28:54.786 dream.http ERROR Raised at Stdlib__map.Make.find in 5 21.07.21 21:28:54.831 dream.log WARN REQ 2 Raised at Dream__middleware__3 21.07.21 21:28:54.831 dream.http ERROR Raised at Stdlib__map.Make.find in 5 21.07.21 21:30:50.329 dream.log WARN REQ 3 Raised at Dream__middleware__3 21.07.21 21:30:50.329 dream.http ERROR Raised at Stdlib__map.Make.find in 5 21.07.21 21:30:56.506 dream.log WARN REQ 4 Raised at Dream__middleware__3 21.07.21 21:30:56.506 dream.http ERROR Raised at Stdlib__map.Make.find in 5 ~/Github/sensors main ✘ INT 2m 49s 3.0.1 21.07.21 21:31:40.970 dream.log WARN REQ 1 Raised at Dream__middleware__Session.middlew3 21.07.21 21:31:40.970 dream.http ERROR Raised at Stdlib__map.Make.find in file "map.ml", 5 21.07.21 21:31:50.176 dream.log WARN REQ 2 Raised at Dream__middleware__Session.middlew3 21.07.21 21:31:50.176 dream.http ERROR Raised at Stdlib__map.Make.find in file "map.ml", 5
|
@thangngoc89 what's your script? |
The systems I tested against are
and
|
Forgot to add, disto is
|
Let’s me clarify this. I often have this problem when I develop my app in watch mode using watchexec/fswatch/whatever/…. |
To comment on something similar, VSCode usually triggers @thangngoc89 The script could still be very useful as we eventually develop some kind of "integrated" watcher, rather than just offer a slightly janky shell script in an example :) Would you mind sharing it in a gist or the like? |
@thangngoc89 I'd also like to, if possible and you have time, to try to reproduce your version of this issue. |
Given your question. Its entirely possible that I had the app running in one terminal then |
I'm closing this for now, as it seems we don't have an issue to debug here. Please do comment if you can reproduce this in some way. I moved the watchexec/fswatch-related command line from @thangngoc89 to #81 (comment). |
I was running https://github.com/jsthomas/sensors from @jsthomas and came across the following error after hitting
control c
. How does one clear this error out?Thanks.
The text was updated successfully, but these errors were encountered: