Skip to content
Sign upLog in
← Back to Community

How To Make A Chat In Python

Profile icon
CodingElf66

Hi everyone! Does anyone know how to make a chat in Python? I tried to search it up and understand the code, but there is always something wrong. They give me server.py and client.py, but my main.py is empty, the code doesn't work. Does anyone know how to make it? Thank you!

Answered by ruiwenge2 [earned 5 cycles]
View Answer
Voters
Profile icon
FluzeG
Profile icon
UltimatePython
Profile icon
CodingElf66
Comments
hotnewtop
Profile icon
ruiwenge2
Profile icon
CodingElf66

@ruiwenge2
Thanks!

Profile icon
ruiwenge2

np!

@JeffreyChen13

Profile icon
ruiwenge2

hey

@JeffreyChen13
, i created a video conferencing app: https://replit.com/talk/share/EasyMeet-A-video-conferencing-app-I-made/142702

you can take a look at the chat feature that uses socketio, hope that helps!

Profile icon
CodingElf66

@ruiwenge2
I like it! Very nicely designed, I upvoted it! You are a very good coder.

Profile icon
ruiwenge2

@JeffreyChen13
thanks! You can also look at my multiplayer pong game: https://replit.com/talk/share/MultiPong-A-multiplayer-pong-game-and-its-my-birthday-today-D/143432

Profile icon
CodingElf66

@ruiwenge2
Thanks for the link!

Profile icon
ruiwenge2

@JeffreyChen13
i also made a Socket.IO tutorial: https://replit.com/talk/learn/SocketIO-Tutorial-What-its-for-and-how-to-use/143781

Profile icon
CodingElf66

@ruiwenge2
Ok thanks!

Profile icon
ruiwenge2

@JeffreyChen13
np :)

do you think it's a good tutorial?

Profile icon
CodingElf66

@ruiwenge
, I tried running it as the website told me to, and I got this error:

connect.send("You are connected from:" + str(addr))
File "main.py", line 16, in <module> connect.send("You are connected from:" + str(addr)) TypeError: string argument without an encoding
Profile icon
ruiwenge2

@JeffreyChen13
or you can take a look at this: https://replit.com/@JWZ6/Chat-in-Python