Investigate move to PySide6 from PyQt5
Motivation
PySide2 is the official Python binding for Qt from Qt company. They provide official support for the same. It also gets better updates. That is the primary reason for me to suggest the same.
Tasks
Two spikes should be conducted to investigate the feasibility of this task (~4h timeboxes for each), this can be done in either order:
-
[x] Ensure that PySide2 wheel can be built from source (can we use the existing logic in the packaging repository?): https://github.com/freedomofpress/securedrop-client/pull/1089#issuecomment-741799433
-
[ ] Update
requirements/dev-requirements.txtto use PySide2, replacing the imports and ensuring the client is working as expected.
PySide2 is the official Python binding for Qt from Qt company. They provide official support for the same. It also gets better updates. That is the primary reason for me to suggest the same.
@kushaldas has investigated the first step (wheel build) in https://github.com/freedomofpress/securedrop-client/pull/1089#issuecomment-741799433 . It will require a special case to handle the build logic for these wheels, since sources tarballs for pyside are not available on PyPI and requires additional dependencies and configuration .
(This is on the 1/21-2/3 sprint for additional investigation & discussion, as time permits given competing 1.7.0/Focal priorities.)
@creviera has committed to time-boxed work (4 hours) to further investigate if she can successfully build Qt and pyside2 wheels, following the process described by Kushal in https://github.com/freedomofpress/securedrop-client/pull/1089#issuecomment-741799433
To recap, the motivation here is twofold, as I understand it:
- being able to reliably build Qt and its Python bindings to aid in debugging investigations
- migrating to the official bindings, which may have maintainability benefits in future.
As we continue this investigation, we'll monitor whether we're indeed able to realize both of those benefits.
I'll be coming back to this issue within the next couple of weeks to see if we're ready to get started on a migration plan from pyqt to pyside.
--
Update: we decided to prioritize other issues and removed this from the near term
It seems that PyQt6 will be available in debian Trixie, so I have updated the title to reflect that. Not worth upgrading to an EOL software
Closing for purpose of the original issue description (moving to PySide6) since it won't be applicable to the rewrite and likely doesn't have sufficient return for the existing codebase.
We do have an issue open to test the existing client in Trixie (#2354); in that scope we can consider what the minimal necessary effort is to keep the client functional and secure on Trixie. AIUI from a quick search so far, both PyQt5 and PyQt6 (and Qt5/Qt6 themselves) are still available on Trixie; if Debian itself provides backported security updates for Qt5, a Qt6 migration may not be necessary.