rml2pdf: fix logging of exceptions.
exception() cannot be called without a string, yet it is even better to demote those logs to warnings. Conflicts: bin/report/render/rml2pdf/utils.py bzr revid: p_christ@hol.gr-20101123150903-zgiyob943ivcftkq
This commit is contained in:
@@ -66,7 +66,7 @@ def _child_get(node, self=None, tagname=None):
|
||||
except GeneratorExit:
|
||||
continue
|
||||
except Exception, e:
|
||||
logging.getLogger('report').exception(e)
|
||||
logging.getLogger('report').warning('rml_except: "%s"',n.get('rml_except',''), exc_info=True)
|
||||
continue
|
||||
if n.get('rml_tag'):
|
||||
try:
|
||||
@@ -78,7 +78,7 @@ def _child_get(node, self=None, tagname=None):
|
||||
except GeneratorExit:
|
||||
yield n
|
||||
except Exception, e:
|
||||
logging.getLogger('report').exception(e)
|
||||
logging.getLogger('report').warning('rml_tag: "%s"',n.get('rml_tag',''), exc_info=True)
|
||||
yield n
|
||||
else:
|
||||
yield n
|
||||
@@ -89,7 +89,7 @@ def _child_get(node, self=None, tagname=None):
|
||||
except GeneratorExit:
|
||||
continue
|
||||
except Exception, e:
|
||||
logging.getLogger('report').exception(e)
|
||||
logging.getLogger('report').warning('rml_except: "%s"',n.get('rml_except',''), exc_info=True)
|
||||
continue
|
||||
if self and self.localcontext and n.get('rml_tag'):
|
||||
try:
|
||||
@@ -102,7 +102,7 @@ def _child_get(node, self=None, tagname=None):
|
||||
except GeneratorExit:
|
||||
pass
|
||||
except Exception, e:
|
||||
logging.getLogger('report').exception(e)
|
||||
logging.getLogger('report').warning('rml_tag: "%s"',n.get('rml_tag',''), exc_info=True)
|
||||
pass
|
||||
if (tagname is None) or (n.tag==tagname):
|
||||
yield n
|
||||
|
||||
Reference in New Issue
Block a user