Skip to content

Ideas for migrating to Qt5 #152

@albertosottile

Description

@albertosottile

This issue serves as a discussion and as a reference about migrating the Syncplay codebase to Qt5.
The release of version 1.5.0 should happen soon, finally supporting macOS with a packed .app and no need of manual installation. Once that is settled, we should have some time to consider this migration.

In my opinion, there are three alternatives at this moment:

  • defer this migration and stick with PySide1.x
  • directly port all the UI code to PySide2
  • port the UI code to Qt.py.

All these strategies have pro and cons, I will try to list them hereafter, being as objective as possible. In the following, I did not include PyQt5 because its open-source license (GPL) is not compatible with the current license of Syncplay.

Defer the migration

Port the UI code to PySide2

  • Pro: porting everything to PySide2 is not that difficult, due to its syntax. In fact, a working port is already available on alby128/pyside2, though it has not been updated to the latest commits yet. Doing this will keep the complexity of the codebase of Syncplay almost unchanged.
  • Cons: while PySide2 works with the current codebase of Syncplay, it is not ready for production deployment. PySide2 is still under active development and its team has not even released a tagged version so far. in this situation, finding binaries of PySide2 is quite hard, and sometimes they are not even consistent between each other, because they have been compiled with quite different sources.

Port the UI code to Qt.py

Note: Qt.py is a shim that allows to code the UI using a common syntax and supports all the major Qt bindings (PySide1, PySide2, PyQt4, and PyQt5).

  • Pro: Qt.py allows to support at the same time PySide and PySide2, while keeping exactly the same codebase. In this way, the UI works with any of these two bindings, so if one day Qt4 abruptly cease to work, migration to Qt5 would be instantaneous. Qt.py uses the syntax of PySide2, so migrating the code is quite easy. Indeed, a working port is available here, updated to the latest commit of master. This code has already been tested, coupled with PySide or PySide2, on Windows 7+, macOS 10.11+, and Ubuntu 16.04.
  • Cons: some minor code tweaks are still required to allow contemporary compatibility with PySide1 and PySide2 (e.g this one). These issues increase a little the codebase complexity of Syncplay.

Everyone is encouraged to comment this issue with their opinion and ideas about this migration.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions