Open paulsmithkc opened 1 year ago
I just ran into this as well on my local machine. Running node 18 on a M1 Macbook Pro. Downgrading to 16 also worked to get around it.
Did tried using explicitly 127.0.0.1
?
I just ran into this as well, on M1 Macbook Air, and GitHub actions CI on Ubuntu 20.04 (but not on my local Linux machine, running a variant of Ubuntu 22.04).
Using tcp:127.0.0.1:PORT
did work, but not http://localhost:PORT
nor tcp:localhost:PORT
, so it seems related to localhost
and not the protocol.
So, turns out that's not exactly the issue. wait-on
seems to be working fine, and I can get tcp:localhost:PORT
to work, as long as that program is listening on ipv6
. This is because Node changed the ipv4
preference to ipv6
from 17+.
The solution is to make those apps listen in ipv6
or wait for them on 127.0.0.1
instead (explicit ipv4
).
Reference links:
Have fun digging into those!
I noticed that with the -v
flag, it always has file:
in front of whatever I told it to await, such as a tcp port. If this isn't related, it perhaps merits another bug, but that's how I got here anyway. Is this the same bug?
Edit: the problem was that my host shell didn't know how to handle CRLFs (DOS). fixed by switching to just LFs (UNIX).
TLDR: not related to this issue.
We ran into an issue with Node 18, were wait-on would wait indefinitely for a service to start, even though it was already started.
Environment:
Test Script:
Bitbucket Pipeline:
We ended up downgrading the Bitbucket Pipeline to Node 16, to make it work for now.