Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

bareASGI

A lightweight Python ASGI web server framework (read the docs).

Overview

This is a bare ASGI web server framework. The goal is to provide a minimal implementation, with other facilities (serving static files, CORS, sessions, etc.) being implemented by optional packages.

The framework is targeted at micro-services which require a light footprint (in a container for example), or as a base for larger frameworks.

Python 3.8+ is required.

Optional Packages

Functionality

The framework provides the basic functionality required for developing a web application, including:

  • Http,
  • WebSockets,
  • Routing,
  • Lifecycle,
  • Middleware

Simple Server

Here is a simple server with a request handler that returns some text.

import uvicorn
from bareasgi import Application, HttpRequest, HttpResponse, text_writer

async def example_handler(request: HttpRequest) -> HttpResponse:
    return HttpResponse(
        200,
        [(b'content-type', b'text/plain')],
        text_writer('This is not a test')
    )

app = Application()
app.http_router.add({'GET'}, '/', example_handler)

uvicorn.run(app, port=9009)

Download files

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

Source Distribution

bareasgi-5.0.0a5.tar.gz (32.3 kB view details)

Uploaded Source

Built Distribution

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

bareasgi-5.0.0a5-py3-none-any.whl (41.2 kB view details)

Uploaded Python 3

File details

Details for the file bareasgi-5.0.0a5.tar.gz.

File metadata

  • Download URL: bareasgi-5.0.0a5.tar.gz
  • Upload date:
  • Size: 32.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.13

File hashes

Hashes for bareasgi-5.0.0a5.tar.gz
Algorithm Hash digest
SHA256 830dff5a4b74961a5c4653b99baf160106b91f4f8a0976ef3a68e2db888c6ff2
MD5 496e6f7978781265cea9e783bb52eebc
BLAKE2b-256 687e142e3057bf4de425a88e5e95dbe31a1c63e049faa1f47b461ebc0d184342

See more details on using hashes here.

File details

Details for the file bareasgi-5.0.0a5-py3-none-any.whl.

File metadata

  • Download URL: bareasgi-5.0.0a5-py3-none-any.whl
  • Upload date:
  • Size: 41.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.13

File hashes

Hashes for bareasgi-5.0.0a5-py3-none-any.whl
Algorithm Hash digest
SHA256 6c3cfdb3a2c9a35aedf4cdf415396510769514b19fcfaf2309657e93dda922fc
MD5 bafc0a75eab47dcb31d79542a5e59eca
BLAKE2b-256 a37731c8ae6bf12a131f15049dda14ca170d1f0584de6c98ea7af5b567b69238

See more details on using hashes here.

Release history Release notifications | RSS feed

5.0.0

2 files

This release

5.0.0a5 This release

2 files

4.4.1

2 files

4.4.0

2 files

4.3.0

2 files

4.2.0

2 files

4.1.0

2 files

4.0.1

2 files

4.0.0

2 files

3.7.1

2 files

3.7.0

2 files

3.5.4

2 files

3.5.3

2 files

3.5.2

2 files

3.5.1

2 files

3.5.0

2 files

3.4.2

2 files

3.4.1

2 files

3.4.0

2 files

3.3.0

2 files

3.2.1

2 files

3.2.0

2 files

3.1.0

2 files

3.0.2

2 files

3.0.1

2 files

2.0.2

2 files

2.0.1

2 files

2.0.0

2 files

1.4.0

2 files

1.3.1

2 files

1.3.0

2 files

1.2.0

2 files

1.1.0

2 files

1.0.3

2 files

1.0.1

2 files

1.0.0

2 files

0.3.0

2 files

0.2.4

2 files

0.2.3

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.0

2 files

0.0.1

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page