Open pfeerick opened 3 years ago
Added a branch to try it out... it was possible to switch from PyQt5 to PySide2 by merely changing the imports.
pyinstaller onefile .exe
seems to be about 5Mb bigger through.
https://github.com/pfeerick/PinetimeFlasher/tree/pyside2
It also isn't fixing the problem I hoped it would solve. The current code is running fine in the Pinebook Pro running Manjaro, but doesn't seem to be able to run it on the pinephone... either get this with PyQt5 imports
Traceback (most recent call last):
File "/home/kde/repos/PinetimeFlasher/./PinetimeFlasher.pyw", line 8, in <module>
from PyQt5.QtWidgets import *
ImportError: /usr/lib/python3.9/site-packages/PyQt5/QtGui.abi3.so: undefined symbol: _ZTI18QOpenGLTimeMonitor, version Qt_5
or with PySide2 imports
Traceback (most recent call last):
File "/home/kde/repos/PinetimeFlasher/./PinetimeFlasher.pyw", line 8, in <module>
from PySide2.QtWidgets import *
File "/usr/lib/python3.9/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py", line 142, in _import
return original_import(name, *args, **kwargs)
ImportError: could not import module 'PySide2.QtGui'
even though
[kde@plasma-mobile PinetimeFlasher]$ pip list | grep -e PyQt5 -e PySide2
PyQt5 5.15.4
PyQt5-sip 12.8.1
PySide2 5.15.2
pyside2 now seems to be better and more consistently supported across OSs and distos than PyQT, probably because it is officially supported by QT.
https://coderslegacy.com/pyside-vs-pyqt-difference/
https://machinekoder.com/pyqt-vs-qt-for-python-pyside2-pyside/
https://www.slant.co/versus/18358/22768/~pyside_vs_pyqt