Logging utility for Django
Project description
Django logging handlers
Django logging handlers is a collection of handlers for logging messages to various services, such as Telegram, Slack, Discord, and more.
Quick start
- Install via pip
pip install django-logging-handlers
- Add
django-logging-handlers
to your INSTALLED_APPS setting like this
INSTALLED_APPS = [
...
'django_logging_handlers',
]
- Register Logging
LOGGING = {
...
"handlers": {
...
"telegram": {
"level": "ERROR",
"class": "django_logging_handlers.handlers.TelegramHandler",
"token": "<telegram bot token>",
"chat": "<chat id>",
"message": "", # optional: if you want to add a message together
# with the traceback
"file_name": PROJECT_NAME, # optional: if you want to edit the file name,
# defaults to "traceback.html"
},
},
"loggers": {
"django.request": {
"handlers": [..., "telegram"],
"level": "ERROR",
"propagate": True,
},
},
}
Live Features
- Telegram
Planned features
- Slack
- Discord
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django_logging_handlers-0.1.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0bf9f5b8e8eb817c5dfdbc657c92bce1c67242defae9038c93fefdaed95d36e6 |
|
MD5 | 779c41fcbbd07d4876a239154614fe5a |
|
BLAKE2b-256 | c633dbfed169a7a060ab0bc17deb5a6876510e4235a091adf8caf55aa98dad09 |
Close
Hashes for django_logging_handlers-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d5c4e9a0b4ae9be2eb12fd859aca28582aab8f82c530bb205574d05debbcb233 |
|
MD5 | a78f3403561080d72849e0bd1ba14381 |
|
BLAKE2b-256 | ff3f84dfdbb4f7c869088dfa4c79aa32688f013769dbd24e4aa5f629721fdb3e |