logging: Stop calling basicConfig in create_logger.

From the docs:

> This function does nothing if the root logger already has handlers
> configured for it.

Which we do if we've started up Django and configured settings, and in
particular allowed Django to process `settings.LOGGING`.

So, cut it out -- all it can do is confuse people about how logging
works.

If we ever actually used the `log_format` parameter, this would be
doubly confused, because only the first call would have any effect.
This commit is contained in:
Greg Price
2017-12-12 16:30:12 -08:00
parent b6491fd52a
commit 1c810baaef

View File

@@ -197,7 +197,6 @@ def create_logger(name: str,
* "log_file" should be declared in zproject/settings.py in ZULIP_PATHS.
"""
logging.basicConfig(format=log_format)
logger = logging.getLogger(name)
if log_file: