diff --git a/src/calibre/ebooks/oeb/polish/check/parsing.py b/src/calibre/ebooks/oeb/polish/check/parsing.py index e27345dc2d..72e5894ebb 100644 --- a/src/calibre/ebooks/oeb/polish/check/parsing.py +++ b/src/calibre/ebooks/oeb/polish/check/parsing.py @@ -48,6 +48,7 @@ class XMLParseError(BaseError): ' "do the wrong thing".') def __init__(self, msg, *args, **kwargs): + msg = msg or '' BaseError.__init__(self, 'Parsing failed: ' + msg, *args, **kwargs) m = mismatch_pat.search(msg) if m is not None: