Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't assign parent algorithms in Graphical Modeller due to Python error #19983

Closed
qgib opened this issue Nov 26, 2014 · 5 comments
Closed

Can't assign parent algorithms in Graphical Modeller due to Python error #19983

qgib opened this issue Nov 26, 2014 · 5 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Processing Relating to QGIS Processing framework or individual Processing algorithms

Comments

@qgib
Copy link
Contributor

qgib commented Nov 26, 2014

Author Name: Jouko Jarnefelt (Jouko Jarnefelt)
Original Redmine Issue: 11750
Affected QGIS version: master
Redmine category:processing/modeller
Assignee: Victor Olaya


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:/OSGEO41/apps/qgis/./python/plugins\processing\modeler\ModelerGraphicItem.py", line 353, in mousePressEvent
self.action()
File "C:/OSGEO4
1/apps/qgis/./python/plugins\processing\modeler\ModelerGraphicItem.py", line 182, in editElement
self.model.updateModelerView()
File "C:/OSGEO41/apps/qgis/./python/plugins\processing\modeler\ModelerAlgorithm.py", line 464, in updateModelerView
self.modelerdialog.repaintModel()
File "C:/OSGEO4
1/apps/qgis/./python/plugins\processing\modeler\ModelerDialog.py", line 345, in repaintModel
self.scene.paintModel(self.alg)
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'

Python version:
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)
Master


@qgib
Copy link
Contributor Author

qgib commented Nov 27, 2014

Author Name: Giovanni Manghi (@gioman)


it affects also master and other platforms.


  • version was changed from 2.6.0 to master
  • operating_system was changed from Windows7 to
  • os_version was changed from 64bit to

@qgib
Copy link
Contributor Author

qgib commented Nov 28, 2014

Author Name: Victor Olaya (@volaya)


Fixed in changeset "c52b5ae89184c86efc48374021363976d8c26fd3".


  • status_id was changed from Open to Closed

@qgib
Copy link
Contributor Author

qgib commented Nov 28, 2014

Author Name: Jouko Jarnefelt (Jouko Jarnefelt)


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:/OSGEO41/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?

@qgib
Copy link
Contributor Author

qgib commented Dec 1, 2014

Author Name: Jouko Jarnefelt (Jouko Jarnefelt)


I reopened the ticket because another problem still occurs.


  • status_id was changed from Closed to Reopened

@qgib
Copy link
Contributor Author

qgib commented Dec 2, 2014

Author Name: Alexander Bruy (@alexbruy)


Please open separate tickets for different issues.

Regarding your problem, it seems that you updated Processing only partially, while it is necessary to update it completely.


  • status_id was changed from Reopened to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Processing Relating to QGIS Processing framework or individual Processing algorithms labels May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Processing Relating to QGIS Processing framework or individual Processing algorithms
Projects
None yet
Development

No branches or pull requests

1 participant