#21425 closed Cleanup/optimization (fixed)

Logging documentation improvement

Reported by: oubiga Owned by: nobody
Component: Documentation Version: master
Severity: Normal Keywords: logging, levels, log,
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

Now https://docs.djangoproject.com/en/dev/topics/logging/ says:

" Python defines the following log levels:

DEBUG: Low level system information for debugging purposes
INFO: General system information
WARNING: Information describing a minor problem that has occurred.
ERROR: Information describing a major problem that has occurred.
CRITICAL: Information describing a critical problem that has occurred.

[...]

The logger instance contains an entry method for each of the default log levels:

logger.critical()
logger.error()
logger.warning()
logger.info()
logger.debug() "

My proposals are:

" Python defines the following log levels:

CRITICAL: Information describing a critical problem that has occurred.
ERROR: Information describing a major problem that has occurred.
WARNING: Information describing a minor problem that has occurred.
INFO: General system information.
DEBUG: Low level system information for debugging purposes.

[...]

The logger instance contains an entry method for each of the default log levels:

logger.critical()
logger.error()
logger.warning()
logger.info()
logger.debug() "

or:

" Python defines the following log levels:

DEBUG: Low level system information for debugging purposes
INFO: General system information
WARNING: Information describing a minor problem that has occurred.
ERROR: Information describing a major problem that has occurred.
CRITICAL: Information describing a critical problem that has occurred.

[...]

The logger instance contains an entry method for each of the default log levels:

logger.debug()
logger.info()
logger.warning()
logger.error()
logger.critical() "

Change History (2)

comment:1 Changed 18 months ago by timo

  • Easy pickings set
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted
  • Type changed from Uncategorized to Cleanup/optimization

The second ordering is consistent with the Python docs.

comment:2 Changed 18 months ago by Tim Graham <timograham@…>

  • Resolution set to fixed
  • Status changed from new to closed

In 3ccc0253f2a29fe6f3227ca96dcab20143188b21:

Fixed #21425 -- Made order in which loggers are introduced consistent.

Thanks oubiga for the suggestion.

Note: See TracTickets for help on using tickets.
Back to Top