🚀 Raystack: Where Starlette Speed Meets Django Elegance
Raystack is a modern, lightweight Python web framework that merges the asynchronous power of Starlette with the battle-tested structure and development convenience inspired by Django. A clean, minimal framework that gives you the best of both worlds!
⚡ Quick Start
Get your project up and running in minutes!
1. Install Raystack
pip install raystack
2. Create a New Project
raystack startproject myproject
cd myproject
3. Run the Development Server
raystack runserver
Open your browser and navigate to: http://127.0.0.1:8000
🌐 URL-Based Async/Sync Mode Detection
Raystack introduces a unique approach to database interaction, allowing you to explicitly control whether to use synchronous or asynchronous operations by simply specifying the appropriate driver in your database URL.
How It Works:
The mode is determined by the presence of async drivers in your database URL within your config/settings.py file.
# Synchronous mode (default)
DATABASES = {
'default': {
'ENGINE': 'raystack.core.database.sqlalchemy',
'URL': 'sqlite:///db.sqlite3', # Sync mode
}
}
# Asynchronous mode
DATABASES = {
'default': {
'ENGINE': 'raystack.core.database.sqlalchemy',
'URL': 'sqlite+aiosqlite:///' + str(BASE_DIR / 'db.sqlite3'), # Async mode
}
}
Supported Drivers:
Synchronous:
- SQLite:
sqlite:///db.sqlite3 - PostgreSQL:
postgresql://user:pass@localhost/dbname - MySQL:
mysql://user:pass@localhost/dbname
Asynchronous:
- SQLite:
sqlite+aiosqlite:///db.sqlite3(requiresaiosqlite) - PostgreSQL:
postgresql+asyncpg://user:pass@localhost/dbname(requiresasyncpg) - MySQL:
mysql+aiomysql://user:pass@localhost/dbname(requiresaiomysql)
🛠️ ORM Usage Examples
Raystack's ORM automatically detects the mode based on your database configuration and adapts accordingly. No need for separate sync/async methods!
Basic CRUD Operations
# Create
article = await Article.objects.create(title="Hello", content="World", author_id=1)
# Get a single object
user = await UserModel.objects.get(id=1)
# Filter
users = await UserModel.objects.filter(age__gte=25).execute()
# Update
user.name = "Jane Doe"
await user.save()
# Delete
await user.delete()
# Count
count = await UserModel.objects.count()
# Check existence
exists = await UserModel.objects.filter(email="john@example.com").exists()
🔌 Admin Panel & Authentication
Raystack core framework is minimal and doesn't include an admin panel by default. However, we provide a complete example project with admin interface and authentication:
👉 raystack-admin - A full-featured example project with:
- Administrative interface
- User authentication and authorization
- User and group management
- Session and JWT authentication
- Ready-to-use templates and static files
You can use raystack-admin as a reference implementation or starting point for your own admin interface.
📚 Documentation
- Technical Documentation
- ORM Reference
- Template Reference
- Command Reference
- Middleware Reference
- Extending Raystack
- FAQ
🔗 Related Projects
- raystack-admin - Example project with admin interface and authentication
🤝 Contributing
Pull requests and issues are welcome! See GitHub.
📜 License
MIT License. See LICENSE for details.
Metadata
Release files for raystack 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| raystack-0.1.5.tar.gz | 198.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| raystack-0.1.5-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 442.0 kB
Release files / raystack-0.1.5.tar.gz
| Download URL | raystack-0.1.5.tar.gz |
|---|---|
| Size | 198.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f21af72a853e711c9016ecf8390130fc0b1ff111abf1ca863c9d326bf47cd305
|
|
BLAKE2b-256 checksum How to use checksums |
a6168c58bef3267186f8ed7369bb309d4c87e7a76f7a77192200270faa4e75a0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|
Release files / raystack-0.1.5-py3-none-any.whl
| Download URL | raystack-0.1.5-py3-none-any.whl |
|---|---|
| Size | 243.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2570a5d45ea40f8b997b5a4a326f76b051dd51cdb02785a25e1177ceaa0c176e
|
|
BLAKE2b-256 checksum How to use checksums |
b7874779a8f1b98eec933516f94d48f02734bb8afd1ae0f72de08fd1cb8265ab
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.2
|