Open caver456 opened 11 months ago
Looks like pyqt6 doesn't work with python 3.10 or later. There are several discussions on the web about this. Basically:
PS C:\Users\caver\Documents\GitHub\radiolog> pip install pyqt6
Defaulting to user installation because normal site-packages is not writeable
Collecting pyqt6
Downloading PyQt6-6.6.0.tar.gz (1.0 MB)
---------------------------------------- 1.0/1.0 MB 4.4 MB/s eta 0:00:00
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... error
error: subprocess-exited-with-error
× Preparing metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [22 lines of output]
Traceback (most recent call last):
File "C:\Users\caver\AppData\Roaming\Python\Python310-32\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
...
...
there's no obviously useful info in the traceback, as it seems to refer to a generated file and would take a lot of work to track down.
This link may be a solution - though it sounds a bit odd, and, would need to make sure it works on a built installation.
This thread has more detail, and this comment near the end of the thread seems to provide a solution - probably the same thing as mentioned above.
Also, it looks like Qt6 doesn't work on 32bit - only 64bit: https://doc.qt.io/qt-6/supported-platforms.html
So maybe it's time to jump to 64bit...
Also notice at the Qt docs that Qt6 only supports windows 10 1809 or newer (Oct 2018) and Windows 11. Maybe not a big deal - that is 5 years ago - but, it could potentially be cutting off any current radiolog users who have old versions of Windows.
Either way - should still move forward with a test case of 64bit-everything in a virtualenv. If pyqt6 doesn't fix anything, then maybe it's not worth upgrading anyway.
In the virtualenv, Windows 10, python 3.12 64bit: pyqt6 installed from wheels with no action needed. Interesting, but, OK:
(v64) PS C:\Users\caver\Documents\v> pip install -r ..\GitHub\radiolog\requirements.txt
...
...
(note, Pillow 10.1.0 installed from wheel on this combo as well, which is very nice)
...
(v64) PS C:\Users\caver\Documents\v> pip install pyqt6
Collecting pyqt6
Downloading PyQt6-6.6.0-cp37-abi3-win_amd64.whl.metadata (2.2 kB)
Collecting PyQt6-sip<14,>=13.6 (from pyqt6)
Downloading PyQt6_sip-13.6.0-cp312-cp312-win_amd64.whl.metadata (524 bytes)
Collecting PyQt6-Qt6>=6.6.0 (from pyqt6)
Downloading PyQt6_Qt6-6.6.0-py3-none-win_amd64.whl.metadata (551 bytes)
Downloading PyQt6-6.6.0-cp37-abi3-win_amd64.whl (6.5 MB)
---------------------------------------- 6.5/6.5 MB 5.7 MB/s eta 0:00:00
Downloading PyQt6_Qt6-6.6.0-py3-none-win_amd64.whl (62.1 MB)
---------------------------------------- 62.1/62.1 MB 6.3 MB/s eta 0:00:00
Downloading PyQt6_sip-13.6.0-cp312-cp312-win_amd64.whl (73 kB)
---------------------------------------- 73.1/73.1 kB 3.9 MB/s eta 0:00:00
Installing collected packages: PyQt6-Qt6, PyQt6-sip, pyqt6
Successfully installed PyQt6-Qt6-6.6.0 PyQt6-sip-13.6.0 pyqt6-6.6.0
(v64) PS C:\Users\caver\Documents\v> python -VV
Python 3.12.0 (tags/v3.12.0:0fb18b0, Oct 2 2023, 13:03:39) [MSC v.1935 64 bit (AMD64)]
(v64) PS C:\Users\caver\Documents\v> pip list
Package Version
------------------ ----------
certifi 2023.11.17
charset-normalizer 3.3.2
idna 3.6
Pillow 10.1.0
pip 23.3.1
PyGeodesy 23.11.11
PyPDF2 3.0.1
pypiwin32 223
PyQt5 5.15.10
PyQt5-Qt5 5.15.2
PyQt5-sip 12.13.0
PyQt6 6.6.0
PyQt6-Qt6 6.6.0
PyQt6-sip 13.6.0
pyserial 3.5
pywin32 306
reportlab 4.0.7
requests 2.31.0
urllib3 2.1.0
(v64) PS C:\Users\caver\Documents\v>
Onwards.
PyQt6 came out in Jan 2021. That's been plenty of time for the kinks to get worked out.
There are indications/hopes that PyQt6 might fix some font size / dpi issue scaling issues - see #683 and #633.
For some issues regarding display (#668, #669, maybe others) it will make more sense to do the investigation after the upgrade - heck, upgrading may even fix them!
Here's a good web page that talks about the migration procedure:
https://www.pythonguis.com/faq/pyqt5-vs-pyqt6