A
A
Alexander Rublev2018-12-02 02:38:03
PyQt
Alexander Rublev, 2018-12-02 02:38:03

PyQt5 or PySide2?

Hello.
What to choose now?
PySide 2 has just been released, is there any point in switching to it?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Ruslan Gilfanov, 2018-12-02
@Meller008

The main difference is the licenses under which these two Qt wrappers are distributed.
PyQt5 is distributed under the GPL and a commercial license.
PySide2 is distributed as Qt under the GPL, LGPL and commercial license.
Write open source/free software -- you can use both PyQt5 and PySide 2.o
Write proprietary/commercial software -- only PySide 2 can be used for free, and you need to buy a commercial license to use PyQt5.
And if you live, work for a company or have clients in the US and the European Union - the difference is significant, there are lawsuits there.
In the post-Soviet space, I don't remember anyone suing because of the use of GPL-licensed libraries in commercial products.
If you don't care what modern GUI toolkit to use as a desktop application. With Python, in addition to wrapping the Qt5 GUI toolkit (PyQt5, PySide 2), you can use a wrapper for the Gtk3 GUI toolkit -- see the documentation here Python GTK+ 3 and here PyGObject -- the GTK code and libraries required for Python are licensed under the LGPL, which allows them to be used in commercial products.
Try to formulate the question in such a way that it reflects what interests you.
A bug report on the performance of one of the PySide2 classes compared to the same class in PyQt5 was opened in June and closed in July:
https://bugreports.qt.io/browse/PYSIDE-727
If we talk about performance in general, then the question is not has special meaning.
The performance of both wrappers rests on the performance of Qt5 components.
It is necessary to compare the performance of both wrappers using the same cases.
A big performance difference between PySide2 and PyQt5 on the same case will be the reason for a bug report and fix in PySide2 or PyQt5, respectively.
You can play it safe and not touch PySide2 for 6-12 months from the date of the first stable release (07/16/2018). Suddenly, there are still flaws, so let other developers and companies use PySide2 in production at their own peril and risk now, write bug reports to PySide2 developers, and you will receive from the community a more stable and proven product, not for you and not for your users.
It is not entirely clear what an official project is.
The Qt website has a Qt section for Python, now it says about PySide2:
doc.qt.io/qtforpython/index.html
This is despite the fact that PyQt5 was released a long time ago, and PySide2 was recently stabilized after many years of development.
Perhaps the licensing policy of PySide2 suits the Qt5 developers more and that is why they decided to promote PySide2.
In this case, PySide2 can be considered an "official" project, and PyQt5 has become "handicraft".

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question