Open jamesaduncan opened 3 years ago
Hi @jamesaduncan, this module waits 200ms between each attempt to connect and tries up to 100 times. Is there some underlying problem, like an error being thrown that isn't expected. Or are you calling connect
from somewhere else? I know it's been a while since you posted this, but if you could share the code you were using, that would help.
If you worked around this or fixed it in some other way, please do let me know and I will close this issue.
I am, unfortunately, having to write code on Windows 10 at the moment. When I try to connect() ngrok fails:
(node:24516) UnhandledPromiseRejectionWarning: NgrokClientError at NgrokClient.request (C:\Users\James Duncan\Dev\laddr\node_modules\ngrok\src\client.js:47:23)
This seems to occur because the web server is not up and listening in time before the post to api/tunnels is fired.
With a 500ms delay after the call to spawn, everything seems to work.