maestral
maestral copied to clipboard
Move to PyQt6 is problematic for some Linux distros
It's probably a bit premature to start using qt6. Not many distributions carry it, so for linux at least, this effectively prevents people from updating.
Originally posted by @peterhoeg in https://github.com/samschott/maestral/issues/655#issuecomment-1082862088
@peterhoeg, thanks for flagging this. My reasons for the switch are:
- Qt 5.15 LTS has moved to a commercial licence and a private repo in January 2021. The non-commercial version no longer receives patches since then.
- PyQt5 wheels are not available for ARM / Apple Silicon. This complicates development on my M1 Mac, even when using a Linux VM.
- PyQt6 provides manylinux1 wheels, allowing it to be installed theoretically on the same systems as PyQt5 5.15.
I did not anticipate issues when distributing Maestral outside of PyPI, where dependencies are not just fetched with a pip-install, but do acknowledge that this is an issue for some distros.
Maybe a compromise could be to use an abstraction layer such as https://github.com/spyder-ide/qtpy which works with PyQt5 and PyQt6, though it annoyingly uses the Qt5 API. This would not solve manual testing on PyQt5 for me but would reduce the chances of missing any major issues.
-
KDE maintains the "Qt 5 Patch Collection" to address exactly that. We're using that on NixOS and I know that Arch Linux does too, but I don't know about other distro or how you would use it on macos or windows where qt5 is most likely distributed in binary form.
-
Noted.
-
This will not cut it on NixOS as we patch qt quite a bit and we haven't added proper support for qt6 yet.
I guess this would be an issue for any linux distro really that distributes maestral in !pip form.
qtpy does sound like a good work around for pretty much everybody but you... Those pesky users getting in the way of your development workflow! ;-)
To address the testing part, we have some very nice features on NixOS for automating proper integration testing that involves launching applications in VMs and using OCR to ensure that we get it to launch the way we expect. I've opened an issue for that and will add tests for maestral (we can do that with the existing 1.5.3 version of course). That doesn't of course address other distros but it would be a start.
Thanks again for all your hard work on maestral!
The gui installation is failing for me on qt6 stuff. Is there a way to force qt5 for now? Thanks
You have a few options:
- if you don't need the GUI, you can just use the cli version (that's what I do)
- you can stay on the latest 1.5.x
You haven't shared any details of your setup, but if you're on linux, it might be helpful to provide additional information about that as well as whatever error you're getting as the pip install method should in principle work across all the standard distributions.
Similar problem here. I use Maestral on three machines with Ubuntu 20.04 LTE.
On two of the boxes I get this error updating to the newest version:
Using cached PyQt6-6.3.0-cp37-abi3-manylinux1_x86_64.whl (7.8 MB)
Requirement already satisfied, skipping upgrade: markdown2 in /usr/local/lib/python3.8/dist-packages (from maestral-qt>=1.6.1; sys_platform == "linux" and extra == "gui"->maestral[gui]) (2.4.1)
Requirement already satisfied, skipping upgrade: cryptography>=2.0 in /usr/lib/python3/dist-packages (from SecretStorage>=3.2; sys_platform == "linux"->keyring>=22->maestral[gui]) (2.8)
Requirement already satisfied, skipping upgrade: zipp>=0.5 in /usr/local/lib/python3.8/dist-packages (from importlib-metadata>=3.6->keyring>=22->maestral[gui]) (3.6.0)
Requirement already satisfied, skipping upgrade: ply>=3.4 in /usr/local/lib/python3.8/dist-packages (from stone>=2.*->dropbox<12.0,>=11.28.0->maestral[gui]) (3.11)
ERROR: Could not find a version that satisfies the requirement PyQt6-Qt6>=6.3.0 (from PyQt6->maestral-qt>=1.6.1; sys_platform == "linux" and extra == "gui"->maestral[gui]) (from versions: none)
ERROR: No matching distribution found for PyQt6-Qt6>=6.3.0 (from PyQt6->maestral-qt>=1.6.1; sys_platform == "linux" and extra == "gui"->maestral[gui])
I can install the newest version on one of the boxes. But don't ask me why. This box is older and a bit more messed up...
The gui installation is failing for me on qt6 stuff. Is there a way to force qt5 for now? Thanks
I had the same problem in Linux Mint 20..3. I managed installing the GUI by using:
python3 -m pip install --upgrade maestral-qt
I do not know why, but ir worked. Last couple of lines of the installation messages:
Installing collected packages: PyQt6-Qt6, PyQt6-sip, markdown2, PyQt6, maestral-qt
Successfully installed PyQt6-6.3.1 PyQt6-Qt6-6.3.1 PyQt6-sip-13.4.0 maestral-qt-1.6.3 markdown2-2.4
I had this error. Based on advice from #687, I was able to get the GUI to install on Ubuntu 20.04 by upgrading pip.