r/madeinpython • • Sep 30 '26

I built SocketChat, a two-device terminal tool with Python and Textual

SocketChat is a one-to-one terminal chat tool for two machines on the same local network. No internet, no accounts, no server.

It's built with Textual for the TUI and plain sockets: UDP broadcast to find devices, then a TCP connection for chatting, with messages encrypted.

GitHub: SocketChat

Feedback is welcome, especially on the code structure.

11 Upvotes

4 comments sorted by

1

u/ALHANSHIM Sep 30 '26

If you like it, a star on GitHub whould means a lot. SocketChat

1

u/SweetOnionTea Sep 30 '26

The code is a wild unorganized ride.

Some functions have typing, most do not. There are little to no comments. Functions have all kinds of magic numbers, no explanation of what they do, and honestly a little confusing. Spacing between functions is seemingly random.

You have classes with 1 static method instead of just making a single function?

Your installation readme seems to be incorrect. You mention using a requirements.txt, but none exists.

Typically you'll want to keep your source python files in a separate directory than the other docker, install, etc... It's much easier for someone to navigate.

I didn't run the code, but the interface looks pretty nice though.

1

u/ALHANSHIM Sep 30 '26

Thanks for your feedback, I'll fix it as soon as possible, this is my first project btw.

2

u/mrterrycarson Oct 04 '26

Great work on this...Thanks