pyWSGIapp
pywsgiapp is a lightweight WSGI application framework aimed at simplifying the development of WSGI-based web applications. It offers an intuitive interface for managing HTTP requests and responses, enabling easy creation and deployment of web applications.
Features
- Lightweight and easy-to-use WSGI framework.
- Customizable request handler for processing HTTP requests.
- Compatible with WSGI servers like
gunicorn.
Installation
To install the package, use the following command:
pip install pywsgiapp
Usage
Example: Basic WSGI Application
Here’s an example of how to use pywsgiapp to create a simple WSGI application:
from pywsgiapp.WSGIApp import createWSGIApp
# Define a request handler function
def requestHandler(url: str, requestHeaders: dict, postData: dict) -> dict:
response_body = f"Received URL: {url}, Headers: {requestHeaders}, Post Data: {postData}"
return {
"responseCode": 200,
"responseHeaders": {"Content-Type": "text/plain"},
"responseBody": response_body
}
# Create the WSGI application
app = createWSGIApp(requestHandler)
Save this code in a file (e.g., basic.py) and run it with a WSGI server like gunicorn:
gunicorn basic:app
For more examples, see the Examples Documentation.
pywsgiapp/: The main package containing the framework code.examples/: Example scripts demonstrating how to use the framework.setup.py: Metadata and installation configuration.requirements.txt: List of dependencies for development and deployment.
Development
If you want to contribute or modify the framework, follow these steps:
-
Clone the repository:
git clone https://github.com/jaythorat/pywsgiapp.git cd pywsgiapp
-
Install the package in editable mode:
pip install -e .
Dependencies
The framework requires the following dependencies:
gunicorn>=20.1.0
Install them using:
pip install -r requirements.txt
License
This project is licensed under the MIT License. See the LICENSE file for details.
Contributing
Contributions are welcome! If you’d like to contribute, please follow these steps:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Commit your changes and push the branch.
- Open a pull request.
Contact
For any questions or issues, feel free to contact the author:
- Author: Jay Thorat
- Email: dev.jaythorat@gmail.com
- GitHub: jaythorat
- Portfolio: portfolio.jaythorat.in
Metadata
Release files for pywsgiapp 0.0.7
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 | Actions |
|---|---|---|---|---|
| pywsgiapp-0.0.7.tar.gz | 8.6 kB | Without provenance | Details for pywsgiapp-0.0.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pywsgiapp-0.0.7-py3-none-any.whl | Python 3 | none | any | Details for pywsgiapp-0.0.7-py3-none-any.whl |
Total release size: 18.5 kB
Release files / pywsgiapp-0.0.7.tar.gz
| Download URL | pywsgiapp-0.0.7.tar.gz |
|---|---|
| Size | 8.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0f61435184d5f0b821f68d2a12963fb54038a8192db009f428b8bff5e2ee5e4
|
|
BLAKE2b-256 checksum How to use checksums |
5de298627022bffefd5136b9d7124f2b3868017d0e98c2073e531cd3a86958d4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Release files / pywsgiapp-0.0.7-py3-none-any.whl
| Download URL | pywsgiapp-0.0.7-py3-none-any.whl |
|---|---|
| Size | 9.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f5a13e9a50e2a0f659045a8a58f54f493a4f7d19d3e43f9843a6a094bc8efb92
|
|
BLAKE2b-256 checksum How to use checksums |
18661bb51a1c37b2c494f399efb39c1f0c3cdcd4e45f7d9f1ad13f0e6bd1b5e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Security for pywsgiapp 0.0.7
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.