Bug report #18408

Some more batch processing errors

Added by al ray over 2 years ago. Updated about 2 years ago.

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

Description

Greetings,

I've tried to use the fill method(double click header) for a batch process and it doesn't work with file provided from open layers, giving off the following error:

2018-03-10T11:53:32 WARNING Traceback (most recent call last):
File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\BatchPanel.py", line 282, in fillParameterValues
self.wrappers[row][column].setValue(wrapper.value())
File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\wrappers.py", line 1361, in setValue
return self.widget.setText(value)
AttributeError: 'BatchInputSelectionPanel' object has no attribute 'setText'

I have also tried to use the autofill option with an input field of my model to complete the name of the output ( something equivalent to "name_of_output{}.shp".format(value_field_of_model) in python) but I get the following error when providing my input field to the "autofill from parameter" popup:

2018-03-10T11:28:38 WARNING Traceback (most recent call last):
File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\BatchPanel.py", line 282, in fillParameterValues
self.wrappers[row][column].setValue(wrapper.value())
File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\wrappers.py", line 1493, in value
return [self.widget.options[i] for i in self.widget.selectedoptions]
File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\wrappers.py", line 1493, in <listcomp>
return [self.widget.options[i] for i in self.widget.selectedoptions]
TypeError: list indices must be integers or slices, not str

Maybe I'm doing it wrong.

model1_flow.png - model (51.3 KB) al ray, 2018-03-10 09:12 PM

Associated revisions

Revision 950d042e
Added by Nyall Dawson about 2 years ago

[processing] Fix errors when filling parameters in batch panel

Fixes #18408

History

#1 Updated by Salvatore Larosa over 2 years ago

What algorithm are you using the batch process for?

#2 Updated by al ray over 2 years ago

Batch process is for a model I made(see attached file) The value that I want to add to the output is the buffer_l value which is a Number parameter/input.

#3 Updated by Mattias Spangmyr about 2 years ago

I encountered a similar error using the batch version of SAGA's "Upslope area" from the processing toolbox in QGIS 3.0.2 on Windows 7 x64 (code rev. 307d082e3d). Error when double clicking the parameter column's header:

Traceback (most recent call last):
  File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\BatchPanel.py", line 282, in fillParameterValues
    self.wrappers[row][column].setValue(wrapper.value())
  File "C:/PROGRA~1/QGIS3~1.0/apps/qgis/./python/plugins\processing\gui\wrappers.py", line 847, in setValue
    self.widget.setText(value)
AttributeError: 'BatchInputSelectionPanel' object has no attribute 'setText'

#4 Updated by Nyall Dawson about 2 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

Also available in: Atom PDF