I'm looking for a working example of a Python socket multi-client chat
问题 I've been trying to code a server socket that accepts connections from multiple clients, a client socket that allows for a connection to the server and real time exchange of messages between multiple clients. I found only one working example, which doesn't produce any runtime errors, but if Client1 sends out a message, Client2 doesn't receive the message until Client2 sends a message of its own. This makes it very confusing to chat. I'm not sure how to modify the code, so that each time