Warn when combining Qt 5.12 with older Qt

Fixes #4581
This commit is contained in:
Florian Bruhin 2019-02-21 14:11:30 +01:00
parent 03e7fdf507
commit b10d84f31a

View File

@ -173,8 +173,10 @@ def check_qt_version():
PYQT_VERSION_STR)
from pkg_resources import parse_version
from qutebrowser.utils import log
parsed_qversion = parse_version(qVersion())
if (QT_VERSION < 0x050701 or PYQT_VERSION < 0x050700 or
parse_version(qVersion()) < parse_version('5.7.1')):
parsed_qversion < parse_version('5.7.1')):
text = ("Fatal error: Qt >= 5.7.1 and PyQt >= 5.7 are required, "
"but Qt {} / PyQt {} is installed.".format(qt_version(),
PYQT_VERSION_STR))
@ -184,6 +186,12 @@ def check_qt_version():
log.init.warning("Running qutebrowser with Qt 5.8 is untested and "
"unsupported!")
if (parsed_qversion >= parse_version('5.12') and
(PYQT_VERSION < 0x050c00 or QT_VERSION < 0x050c00)):
log.init.warning("Combining PyQt {} with Qt {} is unsupported! Ensure "
"all versions are newer than 5.12 to avoid potential "
"issues.".format(PYQT_VERSION_STR, qt_version()))
def check_ssl_support():
"""Check if SSL support is available."""