Benoit ANDRE wrote:
I experienced some problem (bogus ?) with the "save workspace" in gxw
format.
When there is a clause "where" in the vector layer, a "=" sign in the
sql query (i.e. d.vect map=essais_psql_grass@07485 where=termine=1
display=shape,attr type=point,line,boundary,area color=255:255:0
fcolor=255:255:0 lcolor=255:255:0 icon=basic/circle size=5 width=1
layer=1 llayer=1 attrcol=nom xref=center yref=center lsize=8) causes
this message when saving workspace :
Writing current settings to workspace file failed (too many values to
unpack).
This not appear if a "<" or ">" sign (... where=termine>1 ...).
[CC to grass-dev.]
It appears that something is using e.g.:
(var,val) = string.split('=')
when it should be using:
(var,val) = string.split('=', 1)
so that only one split occurs.
As for exactly what is doing this: someone familiar with the code
which saves the workspace can probably find it quicker than I can.
--
Glynn Clements <glynn@gclements.plus.com>
Hi,
right Glynn, fixed now in develbr6/trunk and backported to releasebranch_6_3
http://trac.osgeo.org/grass/changeset/31260
Martin
2008/5/5 Glynn Clements <glynn@gclements.plus.com>:
> I experienced some problem (bogus ?) with the "save workspace" in gxw
> format.
>
> When there is a clause "where" in the vector layer, a "=" sign in the
> sql query (i.e. d.vect map=essais_psql_grass@07485 where=termine=1
> display=shape,attr type=point,line,boundary,area color=255:255:0
> fcolor=255:255:0 lcolor=255:255:0 icon=basic/circle size=5 width=1
> layer=1 llayer=1 attrcol=nom xref=center yref=center lsize=8) causes
> this message when saving workspace :
>
> Writing current settings to workspace file failed (too many values to
> unpack).
>
> This not appear if a "<" or ">" sign (... where=termine>1 ...).
[CC to grass-dev.]
It appears that something is using e.g.:
(var,val) = string.split('=')
when it should be using:
(var,val) = string.split('=', 1)
so that only one split occurs.
As for exactly what is doing this: someone familiar with the code
which saves the workspace can probably find it quicker than I can.
--
Glynn Clements <glynn@gclements.plus.com>
_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev
--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa *