vieuxhibou-django (1.0.0)

Published 2026-09-29 19:00:38 +00:00 by Gilles in Gilles/vieuxhibou-django

Installation

pip install --index-url  vieuxhibou-django

About this package

Logging structuré, registre de loggers modifiables à chaud et enregistrement auprès de vieuxhibou pour les projets Django

vieuxhibou-django

CI License: LGPL v3

Structured logging for Django: a registry of already-instantiated Python loggers, hot-reloadable (NOTSET/DEBUG/INFO/WARNING/ERROR/CRITICAL level, no process restart needed), plus optional registration/heartbeat with a central vieuxhibou server to drive those levels remotely from a dashboard shared with vieuxhibou-gin services.

Installation

pip install vieuxhibou-django
# settings.py
INSTALLED_APPS = [
    ...,
    "vieuxhibou",
]

VIEUXHIBOU_SERVICE_NAME = "my-service"
VIEUXHIBOU_ENV = "prod"
VIEUXHIBOU_VERSION = "1.2.3"

# Optional: registration with a central vieuxhibou server.
# Leaving this empty disables registration/heartbeat (the logger
# registry stays usable locally either way).
VIEUXHIBOU_SERVER_URL = "https://vieuxhibou.example.org"
VIEUXHIBOU_SELF_URL = "https://my-service.example.org"
VIEUXHIBOU_SHARED_TOKEN = "..."
VIEUXHIBOU_HEARTBEAT_INTERVAL = 30  # seconds
python manage.py migrate

The vieuxhibou.urls routes (dashboard + /loggers/ API) need to be mounted into the host project's urlconf, for example:

# urls.py
urlpatterns = [
    ...,
    path("vieuxhibou/", include("vieuxhibou.urls")),
]

Level changes applied through the API are persisted (LoggerOverride) and automatically reapplied the next time the process starts.

Development

make dev            # venv + pip install -e ".[dev]"
make test           # pytest, via tox
make lint           # pylint (+ pylint-django)
make format-check   # autopep8 --diff (CI)
make format         # autopep8 --in-place (local)
make bandit         # static security analysis
make tox            # all tox environments at once

License

LGPLv3, see COPYING + COPYING.LESSER -- chosen over GPLv3 specifically because this package is meant to be imported (i.e. "linked", in the LGPL sense) by projects that have no reason of their own to be GPL.

Requirements

Requires Python: >=3.10
Details
PyPI
2026-09-29 19:00:38 +00:00
196
2026-10-27 02:22:14 +00:00
LGPL-3.0-or-later
50 KiB
Assets (2)
Versions (5) View all
0.0.0.dev0 2026-10-30
1.2.0.dev0 2026-10-30
1.1.0 2026-10-23
0.1.0.dev0 2026-10-23
1.0.0 2026-09-29