Prepare plugin for PyQt6 and QGIS 4#24
Conversation
|
Updating this plugin for QGIS 4 would be much appreciated. An errCouldn't load plugin 'changeDataSource' due to an error when calling its classFactory() method
PyQt6.uic.exceptions.UIFileException: /QGIS/QGIS4/profiles/default/python/plugins/changeDataSource/ui/changeDataSource_dialog_base.ui: invalid Qt Designer file: [Errno 2] No such file or directory: '/QGIS/QGIS4/profiles/default/python/plugins/changeDataSource/ui/changeDataSource_dialog_base.ui'
Traceback (most recent call last):
File "/usr/lib/python3.14/site-packages/PyQt6/uic/ui_file.py", line 35, in __init__
document = ElementTree.parse(ui_file)
File "/usr/lib/python3.14/xml/etree/ElementTree.py", line 1214, in parse
tree.parse(source, parser)
~~~~~~~~~~^^^^^^^^^^^^^^^^
File "/usr/lib/python3.14/xml/etree/ElementTree.py", line 566, in parse
source = open(source, "rb")
FileNotFoundError: [Errno 2] No such file or directory: '/QGIS/QGIS4/profiles/default/python/plugins/changeDataSource/ui/changeDataSource_dialog_base.ui'
Python version: 3.14.5 (main, May 10 2026, 18:26:20) [GCC 16.1.1 20260430]
QGIS version: 4.0.2-Norrköping Norrköping, exported This might just be an issue of me putting the files in the wrong place: I have not developed QGIS plugins ever and was just hoping that a zip of the source folder would install. Yet I think that the issue is only in the "refactoring" part of the PR. |
|
+1 |
Will make the plugin usable under QGIS 4. Also includes some refactoring for structure and readability.
Closes #23.