I am a newbie in python sockets and am really troubled by the stubbornness of the socket.accept() method. I really need a way of ending a socket.accept() method or any other alt
You have several options here:
accept() will raise an exception if it fails.accept() return by design.accept(), (async like AcceptEx() and overlapped IO on Windows).