#1601: output map GUI pulldown broken
-------------------------+--------------------------------------------------
Reporter: cmbarton | Owner: grass-dev@…
Type: defect | Status: new
Priority: normal | Milestone: 7.0.0
Component: wxGUI | Version: svn-trunk
Keywords: GUI parser | Platform: Unspecified
Cpu: Unspecified |
-------------------------+--------------------------------------------------
Comment(by cmbarton):
Here is some more information:
This error affects any module that has 'input' and 'output' argument and
where the 'output' argument is a map. Example modules include r.patch,
r.to.vect, and v.to.rast.
Trying to select a map for output raises an error
GRASS 7.0.svn (Global_latlon):~ > Traceback (most recent call last):
File
"/Applications/GRASS/GRASS-7.0.app/Contents/MacOS/etc/gui/wxpython/gui_core/gselect.py",
line 198, in GetStringValue
return ','.join(self.value)
TypeError: sequence item 1: expected string or Unicode, TreeItemId found
Here is what I've traced so far.
For input and output, GetStringValue is called twice during a map
selection to return self.value, which it can join to other strings with a
comma in the case of multiple inputs. self.value is supposed to be the map
name. Both times GetStringValue is called for the input selection, it
returns the map name.
But for the output selection, it returns only the map name the first time,
and then returns <map name>,<tree item> the second time. since the tree
item is not a string, it raises this error.
I'm still trying to find my way through the new code reorganization. My
guess is that the problem probably lies in forms.py and maybe an incorrect
call to OnUpdateSelection (at least input does NOT call OnUpdateSelection
and output DOES call OnUpdateSelection). It could still be in select.py,
but both input and output call select.py and there is only an error with
output.
The same thing happens whether output is a vector or a raster. Other kinds
of output, like files, don't seem to be affected. I hope the detective
work I've done so far helps.
--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1601#comment:1>
GRASS GIS <http://grass.osgeo.org>