Chrome-Logger support for Django. ChromeLogger is a protocol which allows sending logging messages to the Browser.
This module implements simple support for Django. It consists of two components:
- LoggingMiddleware which is responsible for sending all log messages associated with the request to the browser.
- ChromeLoggerHandler a python logging handler which collects all messages.
Configuration in settings.py is as follows:
MIDDLEWARE = [
'chromelogger.LoggingMiddleware',
... # other middlewares
]
LOGGING = {
...
'handlers': {
'browser': {
'class': 'chromelogger.ChromeLoggerHandler',
},
...
},
'loggers': {
'django': {
'handlers': ['console', 'browser'],
'level': 'DEBUG',
},
...
}
}
The code lives on GitHub, where you can report Issues. The full documentation is available on ReadTheDocs.