pyramid-is-live uses a tween to add an is_live property to Pyramid requests, which is True if the request came from a HTTP interaction and False otherwise, e.g. if the request came from pyramid.paster.bootstrap.
Getting Started
Install this package:
pip install pyramid-is-live
Include it in your application startup:
def main(global_config, **settings): config = Configurator(...) config.include("pyramid_is_live") ...Use request.is_live in your views and scripts!
Contributing
We use tox to run our tests and linters.
Run tox to run all tests and linters.
Run tox -e format to reformat your code using Black and isort.
Release files for pyramid-is-live 0.1.0.post4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pyramid-is-live-0.1.0.post4.tar.gz | 4.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pyramid_is_live-0.1.0.post4-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details |
Total release size:6.9 kB
Release files / pyramid-is-live-0.1.0.post4.tar.gz
| Download URL | pyramid-is-live-0.1.0.post4.tar.gz |
|---|---|
| Size | 4.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fb838dc29f3cf3906fd57365f80dfc68ffa7a61433112bc216a432451ab1cd3a
|
|
BLAKE2b-256 checksum How to use checksums |
1733a4e6ee9f349fd9a8c4b7018261f12e3754b3fc8005d82a0e7e7bbde6e686
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.5
|
Release files / pyramid_is_live-0.1.0.post4-py2.py3-none-any.whl
| Download URL | pyramid_is_live-0.1.0.post4-py2.py3-none-any.whl |
|---|---|
| Size | 2.4 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
23cb1cd65da83919c58bb9d47bb026d268cf109a6542c55718d2cacc43232b12
|
|
BLAKE2b-256 checksum How to use checksums |
86f16581f6bb8d98967183fff8dec8f8793d4e90fcd159f3998a94ba4b1fa8e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.2.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.5
|