Skip to content
Permalink
Browse files
Explain rest null_logger
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Apr 25, 2018
1 parent 9bc1d07 commit 3af2b738321e63ac6e0d33973b6cc6952dc51f21
Showing with 2 additions and 0 deletions.
  1. +2 −0 nikola/plugins/compile/rest/__init__.py
@@ -69,6 +69,8 @@ def read_metadata(self, post, lang=None):
lang = LocaleBorg().current_lang
source_path = post.translated_source_path(lang)

# Silence reST errors, some of which are due to a different
# environment. Real issues will be reported while compiling.
null_logger = logbook.Logger('NULL')
null_logger.handlers = [logbook.NullHandler()]
with io.open(source_path, 'r', encoding='utf-8') as inf:

0 comments on commit 3af2b73

Please sign in to comment.