Simple chat in Python with asynchronous run server and client.
Server requires passlib library for proper password encryption and decryption, use pip to install, or from requirements.txt
pip install passlibpip install -r requirements.txtBoth server and client scripts supposed to be run from separete terminals with the following positional arguments:
- hostname
- port
Example:
python3 server.py localhost 1066python3 client.py localhost 1066Given server is running, when launched the client, it will prompt to choose authentication operation. User can whether log in or register(client automatically logs in after successful registration). After succesful authentication user can start chatting with others.
Every message is broadcast by default. To send a message to one user, specify his name with '@' sign.
Example:
@username Hey, there!To exit either type 'quit' in prompt or press 'Ctrl-C'.