Closed yyk808 closed 5 months ago
I think the system need some time to release the local port 1235
. If you rerun the task
pipeline instantly, the port is still in time-wait
state.
you could try ss -an | grep 1235
@nixff Yes, you are right. I didn't realize there is a time-wait
state for tcp sockets.
I'll close this issue soon.
Env
The newest nightly build of pipy on Archlinux.
Reproduce
First, start a tcp server. Here I use a brief pjs to make it.
Then, connect to this port with a bound address. Here I use
idleTimeout
to speed up this reproduction.At the first time we run it, the program will exit as expected. But if we instantly run it again, it says:
If not set the
bind
option, everything works fine.Plus, from the packets cap by wireshark, the program indeed disconnected gracefully.