werkzeug + twisted.web
Project description
Klein is a micro-framework for developing production-ready web services with Python. It is ‘micro’ in that it has an incredibly small API similar to Bottle and Flask. It is not ‘micro’ in that it depends on things outside the standard library. This is primarily because it is built on widely used and well tested components like Werkzeug and Twisted.
A Klein bottle is an example of a non-orientable surface, and a glass Klein bottle looks like a twisted bottle or twisted flask. This, of course, made it too good of a pun to pass up.
Klein’s documentation can be found at Read The Docs.
Example
This is a sample Klein application that returns ‘Hello, world!’, running on port 8080.
from klein import run, route
@route('/')
def home(request):
return 'Hello, world!'
run("localhost", 8080)
Contribute
klein is hosted on GitHub and is an open source project that welcomes contributions of all kinds from the community, including:
code patches,
documentation improvements,
reviews for contributed patches.
For more information about contributing, see the contributor 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
Built Distribution
File details
Details for the file klein-24.8.0.tar.gz
.
File metadata
- Download URL: klein-24.8.0.tar.gz
- Upload date:
- Size: 104.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1eef4f583c4f8ef4fc57d8b57753fe6e8935501eb36497bb574064e80e3d0b15 |
|
MD5 | 03aae172aa0c84d5499e091b1ba71547 |
|
BLAKE2b-256 | 325570e08b134db00f2e9b5c00f6df6e4f1c13b46041b15451e8f3c28bd74908 |
File details
Details for the file klein-24.8.0-py2.py3-none-any.whl
.
File metadata
- Download URL: klein-24.8.0-py2.py3-none-any.whl
- Upload date:
- Size: 93.8 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 90e15b74f8c842a1519ea0b4e473e97fb8265c046d8b900815008c7614c59173 |
|
MD5 | c453554b9c89d87c6bffc6eea7ccfcf8 |
|
BLAKE2b-256 | b4cca5b41def4b6bfa81aa0a1bb71360cb63d9d7158d63c9368666411c100eb8 |