Logger messages (#818)

* Change the way logger messages are generated by using the printf-like method
* Use single quotes around log values that can be empty strings
* Fix bug in log message
This commit is contained in:
Veronica Berglyd Olsen
2021-07-02 10:22:00 +02:00
committed by GitHub
parent 671888b6ea
commit 1b89d0a4f0
20 changed files with 219 additions and 219 deletions
+2 -2
View File
@@ -644,7 +644,7 @@ class ToOdt(Tokenizer):
"""
refStyle = self._mainPara.get(parName, None)
if refStyle is None:
logger.error("Unknown paragraph style '%s'" % parName)
logger.error("Unknown paragraph style '%s'", parName)
return "Standard"
if not refStyle.checkNew(oStyle):
@@ -1295,5 +1295,5 @@ def _mkTag(nsName, tagName):
theNS = XML_NS.get(nsName, "")
if theNS:
return "{%s}%s" % (theNS, tagName)
logger.warning("Missing xml namespace '%s'" % nsName)
logger.warning("Missing xml namespace '%s'", nsName)
return tagName