KIOS-Research/ImportPhotos

Python throws error when viewing photos (Click Photos) on Fedora but not on Ubuntu (qgis 3.22 & 3.24)

Closed this issue · 2 comments

It's unclear to me if this is an issue or missing lib with the python installation of this distro (Fedora 35) because looking at the code it seems like only the python3-qgis libs are used.

TypeError: arguments did not match any overloaded call: QRect(): too many arguments QRect(int, int, int, int): argument 2 has unexpected type 'float' QRect(QPoint, QPoint): argument 1 has unexpected type 'int' QRect(QPoint, QSize): argument 1 has unexpected type 'int' QRect(QRect): argument 1 has unexpected type 'int'
Traceback (most recent call last):
File "/home/erik/.local/share/QGIS/QGIS3/profiles/default/python/plugins/ImportPhotos/code/MouseClick.py", line 119, in canvasReleaseEvent
self.photosDLG.viewer.resizeEvent([])
File "/home/erik/.local/share/QGIS/QGIS3/profiles/default/python/plugins/ImportPhotos/code/PhotosViewer.py", line 122, in resizeEvent
self.leftClick.setGeometry(QRect(self.left_newloc[0], self.left_newloc[1], self.left_newloc[2], self.left_newloc[3]))
TypeError: arguments did not match any overloaded call:
QRect(): too many arguments
QRect(int, int, int, int): argument 2 has unexpected type 'float'
QRect(QPoint, QPoint): argument 1 has unexpected type 'int'
QRect(QPoint, QSize): argument 1 has unexpected type 'int'
QRect(QRect): argument 1 has unexpected type 'int'

Python version: 3.10.4 (main, Mar 25 2022, 00:00:00) [GCC 11.2.1 20220127 (Red Hat 11.2.1-9)]
QGIS version: 3.24.1-Tisler Tisler, exported

Python Path:

/home/erik/.local/share/QGIS/QGIS3/profiles/default/python/plugins/contour
/usr/share/qgis/python
/home/erik/.local/share/QGIS/QGIS3/profiles/default/python
/home/erik/.local/share/QGIS/QGIS3/profiles/default/python/plugins
/usr/share/qgis/python/plugins
/usr/lib64/python310.zip
/usr/lib64/python3.10
/usr/lib64/python3.10/lib-dynload
/usr/lib64/python3.10/site-packages
/usr/lib/python3.10/site-packages
/home/erik/.local/share/QGIS/QGIS3/profiles/default/python
/home/erik/.local/share/QGIS/QGIS3/profiles/default/python/plugins/HCMGIS/forms

Any thoughts would be greatly appreciated

I have the same error on Unbuntu 22

I have the same error on Ubuntu 22 and Qgis 3.28 . Also static analysis with pyright shows all the type errors and then it throws the sam in qgis runtime