aiohttp-utils
aiohttp-utils provides handy utilities for building aiohttp.web applications.
Method-based handlers (“resources”)
Routing utilities
Content negotiation with JSON rendering by default
Everything is optional. You can use as much (or as little) of this toolkit as you need.
from aiohttp import web
from aiohttp_utils import Response, routing, negotiation
app = web.Application(router=routing.ResourceRouter())
# Method-based handlers
class HelloResource:
async def get(self, request):
name = request.GET.get('name', 'World')
return Response({
'message': 'Hello ' + name
})
app.router.add_resource_object('/', HelloResource())
# Content negotiation
negotiation.setup(
app, renderers={
'application/json': negotiation.render_json
}
)
Install
$ pip install aiohttp-utils
Documentation
Full documentation is available at https://aiohttp-utils.readthedocs.io/.
Project Links
License
MIT licensed. See the bundled LICENSE file for more details.
Metadata
Release files for aiohttp-utils 3.2.1
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 |
|---|---|---|---|---|
| aiohttp-utils-3.2.1.tar.gz | 20.1 kB | Without provenance | Details for aiohttp-utils-3.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| aiohttp_utils-3.2.1-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for aiohttp_utils-3.2.1-py2.py3-none-any.whl |
Total release size: 30.6 kB
Release files / aiohttp-utils-3.2.1.tar.gz
| Download URL | aiohttp-utils-3.2.1.tar.gz |
|---|---|
| Size | 20.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
50959c43af1a5ef830bc7ad62c1e8d805946a41e75561169487bcfb89ab5203c
|
|
BLAKE2b-256 checksum How to use checksums |
fc754b2fda5623ec032af5b8c603967eee3e437d3a257fff661ddfcf1d1facf7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.2
|
Release files / aiohttp_utils-3.2.1-py2.py3-none-any.whl
| Download URL | aiohttp_utils-3.2.1-py2.py3-none-any.whl |
|---|---|
| Size | 10.6 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
2ea1d6e20c6c29062ba6bffbd8aa8cb852dbf0403499908c473f3932c0d7877b
|
|
BLAKE2b-256 checksum How to use checksums |
0669cdae27ac34ccb3d0616f963ab03159e2e59b21e62ae3d08bfc171f48683b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.2
|
Security for aiohttp-utils 3.2.1
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.