crawly
crawly copied to clipboard
`Could not start application crawly` when trying to enter IEx
Having crawly as a dev dependency on mix gives an error if I try to run iex -S mix in my phoenix project:
** (Mix) Could not start application crawly: Crawly.Application.start(:normal, []) returned an error: shutdown: failed to start child: {:ranch_listener_sup, Crawly.API.Router.HTTP}
** (EXIT) shutdown: failed to start child: :ranch_acceptors_sup
** (EXIT) {:listen_error, Crawly.API.Router.HTTP, :eaddrinuse}
The error :eaddrinuse only happens because I'm already running phoenix in localhost:3000.
Why is crawly trying to reserve port 3000? Also: could we improve the error message to be more clear?
Crawly automatically starts a cowboy http endpoint to allow remote controlling of the Crawly service.
It is probably a good idea to let this as an opt-in feature, to avoid unexpected scenarios like this.
It would be nice to be able to disable this. We found this to be an issue when running tests while also running a dev environment. It can be solved by setting different port in the test environment from what is used in dev, but it seems more appropriate to simply disable remote control.