A cross-platform terminal-based real-time chat application built with Python.
Project description
SHANTER
_____ _ _ _ _ _______ ______ _____
/ ____| | | | /\ | \ | |__ __| ____| __ \
| (___ | |__| | / \ | \| | | | | |__ | |__) |
\___ \| __ | / /\ \ | . ` | | | | __| | _ /
____) | | | |/ ____ \| |\ | | | | |____| | \ \
|_____/|_| |_/_/ \_\_| \_| |_| |______|_| \_\
A cross-platform terminal-based real-time chat application for developers, built with Python.
GitHub
https://github.com/shreyash9999/shanter
PyPI
https://pypi.org/project/shanter/
Overview
SHANTER is a terminal-first real-time chat application designed for developers who prefer working from the command line. It provides a lightweight, cross-platform chat experience with user authentication, private messaging, group conversations, and file transfer through a central server.
The project focuses on clean architecture, maintainability, and simplicity while demonstrating practical networking concepts such as TCP sockets, framed JSON protocols, concurrent client handling, and persistent user management.
Features
Authentication
- User registration
- Secure password hashing
- Login / Logout
Messaging
- Private one-to-one messaging
- Online user discovery
- User search
Groups
- Create groups
- Join groups
- Leave groups
- Delete groups
- Group messaging
File Transfer
- Send files directly to online users
- Automatic download location
- Duplicate filename protection
Engineering
- Cross-platform support
- Structured JSON protocol
- SQLite persistence
- Multi-threaded server
- Logging
- Unit tests
- Ruff linting
- Packaged on PyPI
Installation
Install from PyPI
pip install shanter
Requirements
- Python 3.11+
- Developed and tested using Python 3.11.5
Quick Start
Start the server
python -m server.main
Start the client
shanter shell
Available Commands
register
shell
version
Inside the interactive shell:
online
chat <username>
group create <name>
group join <name>
group leave <name>
group delete <name>
group list
group chat <name>
send <filepath> <username>
help
exit
Architecture
SHANTER
+-----------------------+
| CLI Client |
+-----------------------+
|
TCP + JSON Protocol
|
+-----------------------+
| SHANTER Server |
+-----------------------+
| | |
Authentication Groups Messaging
|
SQLite Database
Project Structure
shanter/
│
├── client/ Client application
├── server/ Server implementation
├── common/ Shared utilities and protocol
├── tests/ Unit tests
├── data/ SQLite database
├── README.md
├── pyproject.toml
└── LICENSE
Development
Clone the repository:
git clone https://github.com/shreyash9999/shanter.git
cd shanter
Create a virtual environment:
python -m venv .venv
Activate it:
macOS / Linux
source .venv/bin/activate
Windows
.venv\Scripts\activate
Install dependencies:
pip install -e .
Run the server:
python -m server.main
Run the client:
shanter shell
Testing
Run the complete test suite:
pytest
Run Ruff:
ruff check .
Technologies
- Python
- TCP Sockets
- SQLite
- Typer
- Pytest
- Ruff
Roadmap
Version 2.x
- Authentication
- Interactive CLI
- Private messaging
- Group management
- Group chat
- File transfer
- Logging
- Automated tests
Future
- Invite code system
- Message history
- End-to-end encryption
- Typing indicators
- Read receipts
- User profiles
Contributing
Contributions are welcome.
If you discover a bug or have an idea for an improvement, please open an issue before submitting a pull request.
License
This project is licensed under the MIT License.
See the LICENSE file for the complete license text.
Author
Shreyash Dongare
- GitHub: https://github.com/shreyash9999
- Project: https://github.com/shreyash9999/shanter
If you found SHANTER useful, consider giving the repository a ⭐ on GitHub.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file shanter-2.0.0.tar.gz.
File metadata
- Download URL: shanter-2.0.0.tar.gz
- Upload date:
- Size: 19.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e7bd3c69986c5e2d021e11521b220e2b08c28840fc58264565d49776ac7a4bb
|
|
| MD5 |
5929be0c96b6f9163aee1972b55c88b3
|
|
| BLAKE2b-256 |
b83265f54b992ff3e74232a0e34db6c9a2e0f392012c8137656b699781cea2a9
|
File details
Details for the file shanter-2.0.0-py3-none-any.whl.
File metadata
- Download URL: shanter-2.0.0-py3-none-any.whl
- Upload date:
- Size: 23.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e2b5c5ea9b38b7fdaf2fd412628c95d206a13f3ce198c119fc9e5b78fca8cc12
|
|
| MD5 |
0175317bd56e16ec1e89b68ccd64cc8d
|
|
| BLAKE2b-256 |
95f1eb2322fb855adf2d82f5a571d2ff8da7c2fc5981473849c73dff16b04afd
|