Bug report #14305

Modeller calculator error

Added by Paolo Cavallini almost 9 years ago. Updated over 8 years ago.

Status:Closed
Priority:Normal
Assignee:Victor Olaya
Category:Processing/Modeller
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:worksforme
Crashes QGIS or corrupts data:No Copied to github as #:22296

Description

Checking:

https://github.com/qgis/QGIS-Documentation/blob/master/source/docs/training_manual/processing/modeler_hydro_calculator.rst

I get an error from modeller calculator:

AttributeError: 'NoneType' object has no attribute 'getCopy'
Traceback (most recent call last):
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerDialog.py", line 424, in addAlgorithm
self._addAlgorithm(alg.getCopy())
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerDialog.py", line 443, in _addAlgorithm
self.repaintModel()
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerDialog.py", line 374, in repaintModel
self.scene.paintModel(self.alg)
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerScene.py", line 90, in paintModel
item = ModelerGraphicItem(alg, model)
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerGraphicItem.py", line 59, in init
self.pixmap = element.algorithm.getIcon().pixmap(15, 15)
File "/usr/share/qgis/python/plugins/processing/modeler/ModelerAlgorithm.py", line 110, in algorithm
self._algInstance = ModelerUtils.getAlgorithm(self.consoleName).getCopy()
AttributeError: 'NoneType' object has no attribute 'getCopy'

qgis_error.png (68.5 KB) Gabriel Vatin, 2016-03-01 04:17 AM

History

#1 Updated by Alexander Bruy almost 9 years ago

  • Status changed from Open to Feedback

I can't reproduce your error, but Modeler calculator does not works for me too (another error). Can you check if 1ffccf05c9 fixes your issue?

#2 Updated by Paolo Cavallini almost 9 years ago

Checked, same error.
Thanks.

#3 Updated by Alexander Bruy almost 9 years ago

Can not reproduce this error with latest master on Linux and with yesterdays OSGeo4W under Windows.
Are there any other messages, e.g. in the console or in the Log tab of the algorithm?

Model from training manual does not work for me too, but with different error.

#4 Updated by Paolo Cavallini almost 9 years ago

Tried once more (one numeric input, a*a), still same issue. No other error from either log or console, besides the one reported.

#5 Updated by Gabriel Vatin over 8 years ago

Hi all,

I have the same error with QGis 2.10 and 2.12 running on Windows... Both versions are on different computers. When I try to edit a first model there is no error. But then I try to edit an other model (using the first model) and then I have this error. I attach an image of this bug.
Any news from this issue ? Thanks !

#6 Updated by Giovanni Manghi over 8 years ago

no error here on the latest master (and Processing shipped with it). Please test and report back.

#7 Updated by Paolo Cavallini over 8 years ago

I cannot test on master right now. On 2.8.7, latest released Processing version, I still see the issue. Given that 2.8 is still an LTR, this might require a fix.
Feel free to close it in case you're sure it has been fixed upstream, and no backport is necessary.

#8 Updated by Giovanni Manghi over 8 years ago

Paolo Cavallini wrote:

I cannot test on master right now. On 2.8.7, latest released Processing version, I still see the issue. Given that 2.8 is still an LTR, this might require a fix.
Feel free to close it in case you're sure it has been fixed upstream, and no backport is necessary.

still no errors on master and 2.14.3,
can you please give it a try and report back?

#9 Updated by Paolo Cavallini over 8 years ago

The exercise models are not working here, and should be updated. Feel free to colse this one if it works for you.

#10 Updated by Giovanni Manghi over 8 years ago

  • Resolution set to worksforme
  • Status changed from Feedback to Closed

reopen if necessary.

Also available in: Atom PDF