From 21e4735ae047e690e6cf95721b1632095259069c Mon Sep 17 00:00:00 2001 From: Chris <31113062+chris-adam@users.noreply.github.com> Date: Tue, 11 Feb 2025 16:26:34 +0100 Subject: [PATCH] DMS-1074 - Added new error to ignore --- email2pdf2/email2pdf2.py | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/email2pdf2/email2pdf2.py b/email2pdf2/email2pdf2.py index 8380861..25d6676 100755 --- a/email2pdf2/email2pdf2.py +++ b/email2pdf2/email2pdf2.py @@ -52,13 +52,18 @@ IMAGE_LOAD_BLACKLIST = frozenset(['emltrk.com', 'trk.email', 'shim.gif']) -WKHTMLTOPDF_ERRORS_IGNORE = frozenset([r'QFont::setPixelSize: Pixel size <= 0 \(0\)', - r'Invalid SOS parameters for sequential JPEG', - r'libpng warning: Out of place sRGB chunk', - r'Exit with code 1 due to network error: ContentNotFoundError', - r'Exit with code 1 due to network error: ProtocolUnknownError', - r'Exit with code 1 due to network error: UnknownContentError', - r'libpng warning: iCCP: known incorrect sRGB profile']) +WKHTMLTOPDF_ERRORS_IGNORE = frozenset( + [ + r"QFont::setPixelSize: Pixel size <= 0 \(0\)", + r"Invalid SOS parameters for sequential JPEG", + r"libpng warning: Out of place sRGB chunk", + r"Exit with code 1 due to network error: ContentNotFoundError", + r"Exit with code 1 due to network error: ProtocolUnknownError", + r"Exit with code 1 due to network error: UnknownContentError", + r"libpng warning: iCCP: known incorrect sRGB profile", + r"libpng warning: iCCP: cHRM chunk does not match sRGB", + ] +) WKHTMLTOPDF_EXTERNAL_COMMAND = 'wkhtmltopdf'