-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
(Continuation of #5395 because that was getting rather big)
Current state
On July 22th, 2023, the flip was finally switched to Qt 6 by default. All you need to ensure is what PyQt6 is available, and Qt 6 will be used automatically. If it's not available, you will get a warning shown by qutebrowser.
All information below is considered historical.
The qt6-v2 branch has been merged to master on March 18th, 2023, but with Qt 5 still being the default. See #7628 for details. This issue is now repurposed on what there needs to be done for Qt 6 to be the default Qt wrapper.
The last fixes for the qt6-v2 branch with Qt 6 support went in around May 19th. Multiple core developers (and users) have been using it as a daily driver since far longer (late 2021 / early 2022) and all known crashes are fixed, with all tests passing.
There is still a lot of remaining work, however, on the development side. Due to the big amount of changes (currently 156 commits, 314 files changed, 12,978 additions and 4,094 deletions) it's tricky to integrate this into master without breaking lots of existing open PRs. Thus, we'd like to do another round of PR merging before attempting to do so. The current approach also breaks various tooling, by not properly supporting static analysis (#7128, but that will introduce another big code churn), or by not fixing linting issues yet (#1455).
Bottomline: Feel free to use the qt6-v2 branch, keep in mind it will be rebased from time to time, and it will still take lots of efforts behind the scenes to get it fully integrated.
How to try
mkvenv.py
- Take a backup of your qutebrowser data directory (see
:version) unless you don't mind losing cookies and such when down-/upgrading. This isn't needed if you use--temp-basedirbelow, but if you forget to do so, your data will get upgraded, and as far as I'm aware, there is no way to read it with Qt 5 after that. - Clone the git repo, e.g. via
git clone https://github.com/qutebrowser/qutebrowser.git cd qutebrowserCheck out the branch usinggit checkout qt6-v2- Create a new separate environment via
python3 scripts/mkvenv.py --venv-dir .venv-qt6 --pyqt-version 6.3 - Set
QUTE_QT_WRAPPER=PyQt6somewhere in the environment - Run
.venv-qt6/bin/qutebrowser --temp-basedirand verify via:versionthat you're indeed on Qt 6
Archlinux
qutebrowser-qt6-git is available in the AUR.
Windows / macOS
Built as part of the nightly builds on CI. Click on the most recent passing build, then find the qt6 builds under "Artifacts". Note that you will need to be logged in with a GitHub account to download.
Note for macOS: Due to a PyInstaller issue, Chromium's sandboxing is currently disabled for macOS builds with Qt 6. This means that there will be no additional layer of protection in case of Chromium security bugs. Thus, it's advised to not use this build in production. Hopefully, this situation will be resolved before the final 3.0.0 release.
Flatpak
Published in the flathub-beta repo:
Adding the flathub-beta remote and installing from the beta branch can be done through an application manager (Gnome Software, Discover, ...) or via the command-line.
$ flatpak remote-add --if-not-exists flathub-beta https://flathub.org/beta-repo/flathub-beta.flatpakrepo $ flatpak install flathub-beta org.qutebrowser.qutebrowser//beta
Remaining issues
- Flickering rectangles with AMD graphics: Qt 6: Blank rectangles (mainly with AMD graphics?) #7398 (seems to be fixed in Qt 6.4)
- Mouse wheel sometimes stops working for me: Qt6: mouse scrolling doesn't work after suspend until qb is restarted #7523 (known upsteam Qt issue)
- favicons don't show for some tabs sometimes
(TODO: find reproducer, going to eg https://github.com/qutebrowser/qutebrowser/commits/qt6-test and clicking on one of the commits seems to lose the favicon) (from @toofar, haven't checked if it's still an issue)see Switching to Qt 6 by default #7202 (comment) - Wrong MPRIS name: Qt 6: Wrong MPRIS name #7431
TODOs
- Get macOS builds to work
-
Look at remaining API changes and new features (comment below)moved to Interesting changes in Qt 6.0/.1/.2/.3 #7756 - Look at remaining
FIXME:qt6comments - Make sure qutebrowser has enough feedback (e.g. logging?) about which Qt wrappers it uses and why
-
Maybe investigate storing the Qt wrapper to use in a config file so that we don't unexpectedly switch (and destroy data?) if one is unavailable - Decide what to do about test coverage (switch to Qt 6? Combine?)
-
Probably merge some PRs while waiting for more feedback and to avoid crazy conflicts with the next stepsmoved to v4 -
Integrate Feat/pyqt wrapper bulk import rewrite #7128 if we didn't find a way to make static analysis work otherwisesee Type checking and auto-completion with PyQt6 (and PyQt5) #7370 and linked discussion and issue -
Adoptmoved to v4black(Use auto-formatters (black/isort, maybe autopep8/yapf) #1455) so that we pass "normal" linting again and don't have crazy long lines -
Look at adopting PySide6 againnot a priority at the moment - Check if we can revert 3c4d51a
- Potentially start cherry-picking some stuff to master
- Figure out why our way of blocking back/forward mouse button presses broke
- Perhaps introduce a Qt 5 warning to get people to switch over