Skip to main content

Extremely Stupid Simple, Blazing Fast, Get Out of your way immediately Microframework for building Python Web Applications.

Project description

Heaven ⚡ :

Heaven is the absolute minimal, insanely fast ASGI web framework for Python purists. It doesn't just get out of your way; it vanishes, leaving you with raw performance and total control.

"Mastery in 30 minutes or less. No grey spots, just pure Python."


Why Heaven?

Feature Heaven FastAPI Flask Django
Learning Curve 30 Mins High Low Extreme
Performance ⚡⚡⚡ ⚡⚡ 🐢
Boilerplate Zero Medium Low Massive
Mastery Complete Partial High Low
Background Jobs Native (Daemons) External External External
  1. Stupid Simple: Built for engineers who hate bloat. If you know Python, you already know Heaven.
  2. Blazing Fast: A thin layer over ASGI, optimized for high-concurrency and low-latency.
  3. Batteries Included (The right ones): Native support for application mounting, centralized hooks (.BEFORE/.AFTER), and powerful background Daemons.
  4. Transparent: No magic decorators that hide logic. Just clear, explicit routing.

Quickstart in 60 Seconds

  1. Install
$ pip install heaven
  1. Code
from heaven import App, Request, Response, Context

app = App()

# Centralized Auth / Pre-processing
async def auth(req, res, ctx):
    if not req.headers.get('Authorization'):
        res.status = 401
        res.abort('Unauthorized')

app.BEFORE('/api/*', auth)

# Simple Handler
async def welcome(req, res, ctx):
    res.body = {"message": "Welcome to Heaven"}

app.GET('/api/v1/welcome', welcome)

3. **Protect** (Automatic OpenAPI)
```python
from heaven import Schema

class User(Schema):
    name: str

app.schema.POST('/user', expects=User, summary="Create User")
app.DOCS('/docs')
  1. Fly (CLI) Heaven comes with a beautiful, zero-config CLI.
pip install heaven

# Auto-discovery & run with reload
heaven fly

# Visualize your API structure
heaven routes
  1. Daemon (Background)
async def pulse(app):
    print("Heartbeat...")
    return 5 # Run every 5 seconds

app.daemons = pulse
  1. Run (Standard)
$ uvicorn app:app --reload

Contributing

We love builders. See the Contribution Guidelines.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

heaven-1.3.15.tar.gz (32.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

heaven-1.3.15-py3-none-any.whl (37.2 kB view details)

Uploaded Python 3

File details

Details for the file heaven-1.3.15.tar.gz.

File metadata

  • Download URL: heaven-1.3.15.tar.gz
  • Upload date:
  • Size: 32.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.3 Linux/6.17.0-19-generic

File hashes

Hashes for heaven-1.3.15.tar.gz
Algorithm Hash digest
SHA256 c30f29fdc46e3ef668367d456016b3112cd04376c7dc43d66151f3eba153c0f2
MD5 051727840d4986ab94cb015dcac6eabb
BLAKE2b-256 2cc5cc2f9cbab9d19010079175dcd9a4f001cef751aa76ca095894e26049c483

See more details on using hashes here.

File details

Details for the file heaven-1.3.15-py3-none-any.whl.

File metadata

  • Download URL: heaven-1.3.15-py3-none-any.whl
  • Upload date:
  • Size: 37.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.3 Linux/6.17.0-19-generic

File hashes

Hashes for heaven-1.3.15-py3-none-any.whl
Algorithm Hash digest
SHA256 0ac08200a8f5bc903da54aa6d683d97e1ac9216832e72e6e84c9e83af181ef12
MD5 2aff2e32cc61aa9c9a052f7b74eb3eee
BLAKE2b-256 4eaffd28daf4803a1baf7782984cf9692feeef65f172795932319d0cf3ac1d5c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page