diff options
author | Craig de Stigter <craig.destigter@koordinates.com> | 2011-04-18 16:51:12 +1200 |
---|---|---|
committer | Craig de Stigter <craig.destigter@koordinates.com> | 2011-04-18 16:51:12 +1200 |
commit | 8bc4135947d9a2fc1749ebc4a8cdbd4d72d7a74e (patch) | |
tree | 7faa86d9ba1d0de861202f5f80739b8b677b50b4 /markdown/blockprocessors.py | |
parent | 80aa9a2d52f2fcbffd6e15d208b8ead5886900b1 (diff) | |
download | markdown-8bc4135947d9a2fc1749ebc4a8cdbd4d72d7a74e.tar.gz markdown-8bc4135947d9a2fc1749ebc4a8cdbd4d72d7a74e.tar.bz2 markdown-8bc4135947d9a2fc1749ebc4a8cdbd4d72d7a74e.zip |
sane logging. remove sys.exit() calls (libraries should never ever call sys.exit()) and raise appropriate exceptions instead. backwards incompatible insofar as custom extensions may need tweaks if they're using old markdown logging (but they shouldn't, it was gross)
Diffstat (limited to 'markdown/blockprocessors.py')
-rw-r--r-- | markdown/blockprocessors.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/markdown/blockprocessors.py b/markdown/blockprocessors.py index 77fbc71..10a0177 100644 --- a/markdown/blockprocessors.py +++ b/markdown/blockprocessors.py @@ -15,8 +15,7 @@ as they need to alter how markdown blocks are parsed. import re import util from blockparser import BlockParser -from logging import CRITICAL -from md_logging import message +from markdown import logger def build_block_parser(md_instance, **kwargs): @@ -408,7 +407,7 @@ class HashHeaderProcessor(BlockProcessor): blocks.insert(0, after) else: # This should never happen, but just in case... - message(CRITICAL, "We've got a problem header!") + logger.warn("We've got a problem header: %r" % block) class SetextHeaderProcessor(BlockProcessor): |