Django settings日志配置
Python programmers will often use print() in their code as a quick and convenient debugging tool. Using the logging framework is only a little more effort than that, but it's much more elegant and flexible. As well as being useful for debugging, logging can also provide you with more - and better structured - information about the state and health of your application.
概况¶
Django uses and extends Python's builtin logging module to perform system logging. This module is discussed in detail in Python's own documentation; this section provides a quick overview.
日志框架的组成元素¶
一份 Python logging 配置有下面四个部分组成:
- Loggers
- Handlers
- 过滤器(filters)
- Formatters
相关文章:
djangoproject | Django logging日志
djangoproject | 如何配置和使用日志
为者常成,行者常至
自由转载-非商用-非衍生-保持署名(创意共享3.0许可证)