summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKonstantin Ryabitsev <konstantin@linuxfoundation.org>2021-06-07 13:36:13 -0400
committerKonstantin Ryabitsev <konstantin@linuxfoundation.org>2021-06-07 13:36:13 -0400
commit826b2ca273105345d8429d55b625ba791a0a8361 (patch)
treeacce2b05c17b8a4a2e6e5030262f6b43c25661e0
parente27f705d0b62dc9177983e841d8a4c9b556ef536 (diff)
downloadb4-826b2ca273105345d8429d55b625ba791a0a8361.tar.gz
Shuffle DKIM logging code around a bit
PyCharm is unhappy with PEP conformance, so shuffle things around a bit to satisfy it. Signed-off-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
-rw-r--r--b4/__init__.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/b4/__init__.py b/b4/__init__.py
index 9721e22..2ab2d4b 100644
--- a/b4/__init__.py
+++ b/b4/__init__.py
@@ -45,7 +45,6 @@ except ModuleNotFoundError:
__VERSION__ = '0.8-dev'
-logger = logging.getLogger('b4')
def _dkim_log_filter(record):
# Hide all dkim logging output in normal operation by setting the level to
@@ -55,6 +54,9 @@ def _dkim_log_filter(record):
record.levelname = 'DEBUG'
record.msg = 'DKIM: ' + record.msg
return True
+
+
+logger = logging.getLogger('b4')
dkimlogger = logger.getChild('dkim')
dkimlogger.addFilter(_dkim_log_filter)