Cleanup for ignored log messages.
This commit is contained in:
parent
d217fe09c6
commit
bcee12853d
@ -256,32 +256,35 @@ def qt_message_handler(msg_type, context, msg):
|
||||
except AttributeError:
|
||||
# Qt < 5.5
|
||||
pass
|
||||
|
||||
# Change levels of some well-known messages to debug so they don't get
|
||||
# shown to the user.
|
||||
# suppressed_msgs is a list of regexes matching the message texts to hide.
|
||||
#
|
||||
# If a message starts with any text in suppressed_msgs, it's not logged as
|
||||
# error.
|
||||
suppressed_msgs = [
|
||||
# PNGs in Qt with broken color profile
|
||||
# https://bugreports.qt.io/browse/QTBUG-39788
|
||||
"libpng warning: iCCP: Not recognizing known sRGB profile that has "
|
||||
"been edited",
|
||||
'libpng warning: iCCP: Not recognizing known sRGB profile that has '
|
||||
'been edited',
|
||||
# Hopefully harmless warning
|
||||
"OpenType support missing for script ",
|
||||
'OpenType support missing for script ',
|
||||
# Error if a QNetworkReply gets two different errors set. Harmless Qt
|
||||
# bug on some pages.
|
||||
# https://bugreports.qt.io/browse/QTBUG-30298
|
||||
"QNetworkReplyImplPrivate::error: Internal problem, this method must "
|
||||
"only be called once.",
|
||||
'QNetworkReplyImplPrivate::error: Internal problem, this method must '
|
||||
'only be called once.',
|
||||
# Sometimes indicates missing text, but most of the time harmless
|
||||
"load glyph failed ",
|
||||
'load glyph failed ',
|
||||
# Harmless, see https://bugreports.qt.io/browse/QTBUG-42479
|
||||
"content-type missing in HTTP POST, defaulting to "
|
||||
"application/x-www-form-urlencoded. Use QNetworkRequest::setHeader() "
|
||||
"to fix this problem.",
|
||||
'content-type missing in HTTP POST, defaulting to '
|
||||
'application/x-www-form-urlencoded. '
|
||||
'Use QNetworkRequest::setHeader() to fix this problem.',
|
||||
# https://bugreports.qt.io/browse/QTBUG-43118
|
||||
"Using blocking call!",
|
||||
'Using blocking call!',
|
||||
# Hopefully harmless
|
||||
'"Method "GetAll" with signature "s" on interface '
|
||||
'"org.freedesktop.DBus.Properties" doesn\'t exist',
|
||||
'"org.freedesktop.DBus.Properties" doesn\'t exist',
|
||||
'WOFF support requires QtWebKit to be built with zlib support.',
|
||||
# Weird Enlightment/GTK X extensions
|
||||
'QXcbWindow: Unhandled client message: "_E_',
|
||||
@ -292,9 +295,10 @@ def qt_message_handler(msg_type, context, msg):
|
||||
]
|
||||
if sys.platform == 'darwin':
|
||||
suppressed_msgs += [
|
||||
"libpng warning: iCCP: known incorrect sRGB profile",
|
||||
"virtual void QSslSocketBackendPrivate::transmit() SSLRead failed "
|
||||
"with: -9805",
|
||||
'libpng warning: iCCP: known incorrect sRGB profile',
|
||||
# https://bugreports.qt.io/browse/QTBUG-47154
|
||||
'virtual void QSslSocketBackendPrivate::transmit() SSLRead failed '
|
||||
'with: -9805',
|
||||
]
|
||||
|
||||
if any(msg.strip().startswith(pattern) for pattern in suppressed_msgs):
|
||||
|
Loading…
Reference in New Issue
Block a user