
Security News
The Nightmare Before Deployment
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.
zenithweb
Advanced tools
A modern Python web framework with intuitive developer experience and exceptional performance.
🎯 Modern DX: Zero-config setup, database models with chainable queries, one-liner features, and clean architecture patterns - making Python web development incredibly productive.
Zenith brings together exceptional productivity, outstanding performance, and full type safety:
app = Zenith() just works with intelligent defaultsUser.where(active=True).order_by('-created_at').limit(10)app.add_auth(), app.add_admin(), app.add_api()pip install zenithweb
from zenith import Zenith
from zenith import Session # Database session dependency
from zenith.db import ZenithModel # Modern database models
from sqlmodel import Field
from pydantic import BaseModel
from typing import Optional
# 🎯 Zero-config setup - just works!
app = Zenith()
# ⚡ Add features in one line each
app.add_auth() # JWT authentication + /auth/login
app.add_admin() # Admin dashboard at /admin
app.add_api("My API", "1.0.0") # API docs at /docs
# 🏗️ Modern models with chainable query patterns
class User(ZenithModel, table=True):
id: Optional[int] = Field(primary_key=True)
name: str = Field(max_length=100)
email: str = Field(unique=True)
active: bool = Field(default=True)
class UserCreate(BaseModel):
name: str
email: str
active: bool = True
# 🎨 Clean routes with enhanced DX
@app.get("/")
async def home():
return {"message": "Modern DX in Python!"}
@app.get("/users")
async def list_users(): # ✨ No session management needed!
# Clean chaining: User.where().order_by().limit()
users = await User.where(active=True).order_by('-id').limit(10).all()
return {"users": [user.model_dump() for user in users]}
@app.post("/users")
async def create_user(user_data: UserCreate):
# Clean API: User.create() - no session management!
user = await User.create(**user_data.model_dump())
return {"user": user.model_dump()}
@app.get("/users/{user_id}")
async def get_user(user_id: int):
# Automatic 404 handling
user = await User.find_or_404(user_id)
return {"user": user.model_dump()}
# 🏃♂️ Run it
if __name__ == "__main__":
import uvicorn
uvicorn.run(app, host="127.0.0.1", port=8000)
Run with:
uvicorn main:app --reload
app = Zenith() # Just works! No complex configuration needed
DATABASE_URL and SECRET_KEY env vars for productionZENITH_ENV or intelligent detection# Intuitive database operations - seamless chaining!
users = await User.where(active=True).order_by('-created_at').limit(10).all()
user = await User.find_or_404(123) # Automatic 404 handling
user = await User.create(name="Alice", email="alice@example.com")
app.add_auth() # JWT authentication + /auth/login endpoint
app.add_admin() # Admin dashboard at /admin with health checks
app.add_api() # API documentation at /docs and /redoc
@app.get("/users")
async def get_users(session: AsyncSession = Session):
# Simple database session injection
users = await User.all() # ZenithModel uses the session automatically
return users
Session for database, Auth for current userInject(ServiceClass) for business logic/health, /metrics, request tracingapp.spa("dist")Clean organization with zero configuration:
your-app/
├── main.py # app = Zenith() + routes
├── models.py # ZenithModel classes
├── services.py # Business logic (optional)
├── migrations/ # Database migrations (auto-generated)
└── tests/ # Testing with built-in TestClient
Or traditional clean architecture:
your-app/
├── main.py # Application entry point
├── models/ # ZenithModel classes
├── services/ # Service classes with @Service decorator
├── routes/ # Route modules (optional)
├── middleware/ # Custom middleware
└── tests/ # Comprehensive test suite
Zenith delivers high-performance async request handling with production-tested throughput.
Run your own benchmarks:
uv run pytest tests/performance/ -v
The framework is optimized with connection pooling, slotted classes, and efficient middleware. Performance varies by hardware, middleware configuration, and application complexity.
🔥 Modern DX Examples:
app.add_auth(), app.add_admin(), app.add_api()🚀 Complete Examples:
app = Zenith())# Create new project with secure defaults
zen new my-api
# Generate secure SECRET_KEY
zen keygen
# Show configuration and environment info
zen config --all
# Generate boilerplate code
zen generate model User
zen generate service UserService
zen generate graphql UserSchema
# Development server with hot reload
zen dev
# Production server
zen serve --workers 4
# Basic installation
pip install zenithweb
# With production dependencies
pip install "zenithweb[production]"
# With development tools
pip install "zenithweb[dev]"
FROM python:3.12-slim
WORKDIR /app
COPY . .
RUN pip install "zenithweb[production]"
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
from zenith import Zenith
app = Zenith()
# Environment-specific behavior:
# development (or dev): Enhanced error reporting, auto-generated secrets
# production (or prod): Optimized for deployment, requires SECRET_KEY
# test: Testing mode with rate limiting disabled
# staging: Production-like with enhanced monitoring
# Manual configuration if needed
from zenith.config import Config
app = Zenith(
config=Config(
database_url=os.getenv("DATABASE_URL"),
redis_url=os.getenv("REDIS_URL"),
secret_key=os.getenv("SECRET_KEY")
# debug automatically set based on ZENITH_ENV
)
)
We welcome contributions! Please see our Contributing Guide.
git clone https://github.com/nijaru/zenith.git
cd zenith
pip install -e ".[dev]"
pytest # Run tests
Latest Version: v0.0.11 Python Support: 3.12-3.14 Test Suite: 100% passing (899 tests) Performance: High-performance async architecture with production-tested throughput Architecture: Clean separation with Service system and simple dependency patterns
Zenith is production-ready with comprehensive middleware, performance optimizations, and clean architecture patterns for modern Python applications.
MIT License. See LICENSE for details.
FAQs
Modern Python web framework for building APIs with minimal boilerplate
We found that zenithweb demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Season’s greetings from Socket, and here’s to a calm end of year: clean dependencies, boring pipelines, no surprises.

Research
/Security News
Impostor NuGet package Tracer.Fody.NLog typosquats Tracer.Fody and its author, using homoglyph tricks, and exfiltrates Stratis wallet JSON/passwords to a Russian IP address.

Security News
Deno 2.6 introduces deno audit with a new --socket flag that plugs directly into Socket to bring supply chain security checks into the Deno CLI.