1
0
mirror of https://github.com/django/django.git synced 2025-07-19 17:19:12 +00:00

[1.9.x] Fixed #25959 -- Updated logging example to use the django logger.

Backport of 483e0091e3891dc4ed898ea0dbf6923c166f0674 from master
This commit is contained in:
Varun Sharma 2015-12-24 20:21:27 +05:30 committed by Tim Graham
parent 47f3ee2625
commit fa21766230

View File

@ -240,8 +240,8 @@ The full documentation for `dictConfig format`_ is the best source of
information about logging configuration dictionaries. However, to give information about logging configuration dictionaries. However, to give
you a taste of what is possible, here are several examples. you a taste of what is possible, here are several examples.
First, here's a simple configuration which writes all request logging from the First, here's a simple configuration which writes all logging from the
:ref:`django-request-logger` logger to a local file:: :ref:`django-logger` logger to a local file::
LOGGING = { LOGGING = {
'version': 1, 'version': 1,
@ -254,7 +254,7 @@ First, here's a simple configuration which writes all request logging from the
}, },
}, },
'loggers': { 'loggers': {
'django.request': { 'django': {
'handlers': ['file'], 'handlers': ['file'],
'level': 'DEBUG', 'level': 'DEBUG',
'propagate': True, 'propagate': True,
@ -459,6 +459,8 @@ Loggers
Django provides several built-in loggers. Django provides several built-in loggers.
.. _django-logger:
``django`` ``django``
~~~~~~~~~~ ~~~~~~~~~~