-- coding: utf-8 --
anywsgi-py
quick and dirty use any available WSGI server for running from command line
Getting Started
Regular install
pip install anywsgi
Without a source code checkout
Picking up the latest version
pip uninstall anywsgi; python -m pip install --upgrade git+https://github.com/clach04/anywsgi-py.git
From a source code checkout
# pip uninstall anywsgi
# python -m pip install -r requirements.txt
# TODO requirements_optional.txt
python -m pip install -e .
Hello World Demo
import os
import sys
import anywsgi
from anywsgi import DEFAULT_LISTEN_ADDRESS, DEFAULT_SERVER_PORT
def application(environ, start_response):
start_response('200 OK',[('Content-type','text/html')])
return [b'<html><body>Hello World!</body></html>'] # NOTE Python 3 requires this to be bytes, i.e. an iterator of bytes
print('Python %s on %s' % (sys.version, sys.platform))
listen_address = os.environ.get('LISTEN_ADDRESS', DEFAULT_LISTEN_ADDRESS)
server_port = int(os.environ.get('LISTEN_PORT', DEFAULT_SERVER_PORT))
anywsgi.my_start_server(application, listen_address=listen_address, listen_port=server_port)
Metadata
Release files for anywsgi 0.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| anywsgi-0.0.4.tar.gz | 10.0 kB | Without provenance | Details |
Release files / anywsgi-0.0.4.tar.gz
| Download URL | anywsgi-0.0.4.tar.gz |
|---|---|
| Size | 10.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4e488623ff90aa90c3876c793a0e40d36981c58bf2bd5a41fd19b0c9d87eb38c
|
|
BLAKE2b-256 checksum How to use checksums |
1fe84415fc208973460d5e76aaa556794ab99c7620f924cb744ebba9716151f6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.12.1
|
Security for anywsgi 0.0.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.