mirror of https://github.com/scrapy/scrapy.git
LOG_DICT_CONFIG for custom logging
Add LOG_DICT_CONFIG option to achive ability add custom logging. For example, for `colorlog.ColoredFormatter`
This commit is contained in:
parent
a07400ce0a
commit
da9c1bf171
|
|
@ -87,7 +87,8 @@ def configure_logging(settings=None, install_root_handler=True):
|
|||
observer = twisted_log.PythonLoggingObserver('twisted')
|
||||
observer.start()
|
||||
|
||||
dictConfig(DEFAULT_LOGGING)
|
||||
dictConfig(settings.get('LOG_DICT_CONFIG', DEFAULT_LOGGING))
|
||||
|
||||
|
||||
if isinstance(settings, dict) or settings is None:
|
||||
settings = Settings(settings)
|
||||
|
|
|
|||
Loading…
Reference in New Issue