django-detailed-request-logging-1.2.0
توضیحات
Middleware to log requests in Django with more detailed information.
| ویژگی | مقدار |
|---|---|
| سیستم عامل | OS Independent |
| نام فایل | django-detailed-request-logging-1.2.0 |
| نام | django-detailed-request-logging |
| نسخه کتابخانه | 1.2.0 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Jaroslaw Surkont, Gerhard Bräunlich, Robin Engler, Christian Ribeaud, François Martin |
| ایمیل نویسنده | jaroslaw.surkont@unibas.ch, gerhard.braeunlich@id.ethz.ch, robin.engler@sib.swiss, christian.ribeaud@karakun.com, francois.martin@karakun.com |
| آدرس صفحه اصلی | https://gitlab.com/biomedit/django-detailed-request-logging |
| آدرس اینترنتی | https://pypi.org/project/django-detailed-request-logging/ |
| مجوز | LGPL3 |
[](https://gitlab.com/biomedit/django-detailed-request-logging/-/commits/master)
[](https://gitlab.com/biomedit/django-detailed-request-logging/-/commits/master)
[](https://github.com/psf/black)
[](https://pypi.org/project/django-detailed-request-logging)
[](https://www.gnu.org/licenses/lgpl-3.0)
[](https://pypi.org/project/django-detailed-request-logging)
# django-detailed-request-logging
## Releases
This project follows the [semantic versioning specification](https://semver.org/) for its releases.
## Development
### Requirements
- Python >=3.7
- Django >=3.2
- django-rest-framework >=3.12
### Setup
- Create and activate a python3 venv.
- Install the library in the editable mode `pip install -e .[test,stubs]`
- Install dev requirements `pip install -r requirements-dev.txt`.
- Install git hooks to automatically format code using black with `pre-commit install`
## Installation
### From git in `requirements.txt`
To install this package from this git repository, add the `django-detailed-request-logging` package to the `requirements.txt` file.
To use it, add the following entry to `MIDDLEWARE` inside of your `settings.py` file:
```python
MIDDLEWARE = [
...,
"django_detailed_request_logging.middleware.LoggingMiddleware",
]
```
Then, add a new entry `LOGGING_REQUEST_MIDDLEWARE` to your `settings.py` file, changing the value of `apps` to the
names of the apps you want to log requests on and changing the value of `skip_methods` to include all HTTP methods
you do **NOT** want to get logged:
```python
LOGGING_REQUEST_MIDDLEWARE = {
"apps": ("projects",),
"skip_methods": ("OPTIONS",),
}
```
نیازمندی
| مقدار | نام |
|---|---|
| >=3.2 | Django |
| >=3.12 | djangorestframework |
| - | django-stubs |
| - | djangorestframework-stubs |
| - | assertpy |
| - | pytest |
| - | pytest-django |
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=3.7 | Python |
نحوه نصب
نصب پکیج whl django-detailed-request-logging-1.2.0:
pip install django-detailed-request-logging-1.2.0.whl
نصب پکیج tar.gz django-detailed-request-logging-1.2.0:
pip install django-detailed-request-logging-1.2.0.tar.gz