From 69a58c959705b2dd469ba416250f884472593bee Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Tue, 6 Mar 2018 11:00:24 +0100 Subject: Remove Qt 5.8 support and tests With QtWebKit it's probably okay to still use it (*cough* Hyperbola GNU/Linux-libre^tm *cough*), and only blacklisting it with QtWebEngine would be quite some effort. Fixes #3608 --- qutebrowser/browser/webengine/webenginetab.py | 4 ---- qutebrowser/misc/earlyinit.py | 5 +++++ qutebrowser/misc/miscwidgets.py | 10 ---------- tests/end2end/features/tabs.feature | 6 ------ tox.ini | 5 ++--- 5 files changed, 7 insertions(+), 23 deletions(-) diff --git a/qutebrowser/browser/webengine/webenginetab.py b/qutebrowser/browser/webengine/webenginetab.py index 972145edd..6972c78d4 100644 --- a/qutebrowser/browser/webengine/webenginetab.py +++ b/qutebrowser/browser/webengine/webenginetab.py @@ -703,10 +703,6 @@ class WebEngineTab(browsertab.AbstractTab): def shutdown(self): self.shutting_down.emit() self.action.exit_fullscreen() - if qtutils.version_check('5.8', exact=True, compiled=False): - # WORKAROUND for - # https://bugreports.qt.io/browse/QTBUG-58563 - self.search.clear() self._widget.shutdown() def reload(self, *, force=False): diff --git a/qutebrowser/misc/earlyinit.py b/qutebrowser/misc/earlyinit.py index c78d0848d..9649d27cc 100644 --- a/qutebrowser/misc/earlyinit.py +++ b/qutebrowser/misc/earlyinit.py @@ -172,6 +172,7 @@ def check_qt_version(): from PyQt5.QtCore import (qVersion, QT_VERSION, PYQT_VERSION, PYQT_VERSION_STR) from pkg_resources import parse_version + from qutebrowser.utils import log if (QT_VERSION < 0x050701 or PYQT_VERSION < 0x050700 or parse_version(qVersion()) < parse_version('5.7.1')): text = ("Fatal error: Qt >= 5.7.1 and PyQt >= 5.7 are required, " @@ -179,6 +180,10 @@ def check_qt_version(): PYQT_VERSION_STR)) _die(text) + if qVersion().startswith('5.8.'): + log.init.warning("Running qutebrowser with Qt 5.8 is untested and " + "unsupported!") + def check_ssl_support(): """Check if SSL support is available.""" diff --git a/qutebrowser/misc/miscwidgets.py b/qutebrowser/misc/miscwidgets.py index 0e3def2f9..0867d120c 100644 --- a/qutebrowser/misc/miscwidgets.py +++ b/qutebrowser/misc/miscwidgets.py @@ -260,16 +260,6 @@ class WrapperLayout(QLayout): self._widget = widget container.setFocusProxy(widget) widget.setParent(container) - if (qtutils.version_check('5.8.0', exact=True, compiled=False) and - objects.backend == usertypes.Backend.QtWebEngine and - container.window() and - container.window().windowHandle() and - not container.window().windowHandle().isActive()): - log.misc.debug("Calling QApplication::sync...") - # WORKAROUND for: - # https://bugreports.qt.io/browse/QTBUG-56652 - # https://codereview.qt-project.org/#/c/176113/5//ALL,unified - QApplication.sync() def unwrap(self): self._widget.setParent(None) diff --git a/tests/end2end/features/tabs.feature b/tests/end2end/features/tabs.feature index 037e1cdd0..7a36b60cb 100644 --- a/tests/end2end/features/tabs.feature +++ b/tests/end2end/features/tabs.feature @@ -632,12 +632,6 @@ Feature: Tab management # https://github.com/qutebrowser/qutebrowser/issues/2289 - @qtwebkit_skip @qt==5.8.0 - Scenario: Cloning a tab with a special URL - When I open chrome://gpu - And I run :tab-clone - Then the error "Can't serialize special URL!" should be shown - @qtwebkit_skip @qt<5.9 Scenario: Cloning a tab with a view-source URL When I open / diff --git a/tox.ini b/tox.ini index b27fa7906..111187e22 100644 --- a/tox.ini +++ b/tox.ini @@ -13,8 +13,8 @@ skipsdist = true setenv = QT_QPA_PLATFORM_PLUGIN_PATH={envdir}/Lib/site-packages/PyQt5/plugins/platforms PYTEST_QT_API=pyqt5 - pyqt{,56,571,58,59,510}: LINK_PYQT_SKIP=true - pyqt{,56,571,58,59,510}: QUTE_BDD_WEBENGINE=true + pyqt{,56,571,59,510}: LINK_PYQT_SKIP=true + pyqt{,56,571,59,510}: QUTE_BDD_WEBENGINE=true cov: PYTEST_ADDOPTS=--cov --cov-report xml --cov-report=html --cov-report= passenv = PYTHON DISPLAY XAUTHORITY HOME USERNAME USER CI TRAVIS XDG_* QUTE_* DOCKER basepython = @@ -26,7 +26,6 @@ deps = -r{toxinidir}/misc/requirements/requirements-tests.txt pyqt: -r{toxinidir}/misc/requirements/requirements-pyqt.txt pyqt571: PyQt5==5.7.1 - pyqt58: PyQt5==5.8.2 pyqt59: PyQt5==5.9.2 pyqt510: PyQt5==5.10.1 commands = -- cgit v1.2.3-54-g00ecf