Django-globals
Django-globals is a very simple application, that allow you to define thread specific global variables.
It includes a middleware Global, which can be used to access to the current request and user, which is useful outside of a view when the “request” variable is not defined.
Installation
Install using pip
pip install django-globals
Configuration
In your project’s settings.py, add django_globals.middleware.Global to MIDDLEWARE (or MIDDLEWARE_CLASSES on Django < 1.10).
Usage
Now you can use from django_globals import globals and access to the globals.request and globals.user from anywhere.
Help
For more information see the documentation at:
https://django-globals.readthedocs.io/
If you have questions or have trouble using the app please file a bug report at:
Metadata
Release files for django-globals 0.3.2
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 |
|---|---|---|---|---|
| django-globals-0.3.2.tar.gz | 3.2 kB | Without provenance | Details for django-globals-0.3.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| django_globals-0.3.2-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for django_globals-0.3.2-py2.py3-none-any.whl |
Total release size: 5.9 kB
Release files / django-globals-0.3.2.tar.gz
| Download URL | django-globals-0.3.2.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bfcee81e7c6771f32ea12a4c7f82b52ce69ef1dd571356693ce21788e7cbab57
|
|
BLAKE2b-256 checksum How to use checksums |
1149e07d7a8ed6bab195b0210dfa407278fa33784d090b547b651b3379ba3438
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Python-urllib/3.6
|
Release files / django_globals-0.3.2-py2.py3-none-any.whl
| Download URL | django_globals-0.3.2-py2.py3-none-any.whl |
|---|---|
| Size | 2.6 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
000d9172c1443a9cb4ba70ff1ac656d6f082fe9d8afa07a5ff2f5b1edb235253
|
|
BLAKE2b-256 checksum How to use checksums |
1b3152cf6de4f1f5972d8540986b414c231fd4c7cf699c33d204de07b0708376
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Python-urllib/3.6
|
Security for django-globals 0.3.2
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.