Bug report #11750
Can't assign parent algorithms in Graphical Modeller due to Python error
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||19983|
Python error described below occurs after adding parent algorithms to any algorithm and returning back to the Graphical Modeller window. KeyError value of the error varies according to the first selected parent algorithm in the parent algorithms dialog box. Somewhat interesting is that in earlier versions of QGIS algoritms in the parent algorithm dialog box were given a number in front of them according to the order they are executed. In the latest version (and in master) this seems to be missing/disables and only the name of the algorithm is shown which makes it also hard to be sure in which algorithm the assigning should be done. Don't know if this has anything to do with the bug, but to be clear about the dialog box appearence I attached a picture. After python error you can still continue editing model, but if the model is saved it is broken and cannot be opened again in modeller.
An error has occured while executing Python code:
Traceback (most recent call last):
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerGraphicItem.py", line 353, in mousePressEvent
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerGraphicItem.py", line 182, in editElement
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerAlgorithm.py", line 464, in updateModelerView
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerDialog.py", line 345, in repaintModel
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerScene.py", line 108, in paintModel
arrow = ModelerArrowItem(self.algItems[depend], -1,
KeyError: 'Select by expression'
2.7.5 (default, May 15 2013, 22:44:16) [MSC v.1500 64 bit (AMD64)]
Tested in all following versions:
OSGeo4W 2.6 (64bit)
Standalone 2.6 (64bit)
#3 Updated by Jouko Jarnefelt about 6 years ago
Thanks for quick reply! I replaced current files with the bug fix files and I got new error when starting QGIS. This has something to do with the new ModelerDialog.py file.
File "C:/OSGEO4~1/apps/qgis/./python/plugins\\processing\\modeler\\ModelerDialog.py", line 36, in
from processing.gui.AlgorithmDialog import AlgorithmDialog
File "C:/OSGEO4~1/apps/qgis/./python\\qgis\\utils.py", line 460, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
ImportError: No module named AlgorithmDialog
Should I reopen the ticket?