[GRASS-dev] [GRASS GIS] #1696: Error message v.db.dropcol (Add-On Path)

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: grass-dev@…
     Type: defect | Status: new
Priority: normal | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------
Hi,

when I try to drop a column from a table I get following error message
although the table is modified correctly:

{{{
(Tue Aug 14 12:47:30 2012)
v.db.dropcol map=sender_point@FIDIMO_Cele column=testcol
/usr/local/grass-6.5.svn/scripts/v.db.dropcol: 1: eval: adin
ger/05_GRASS/GRASS_Scripts=/home/radinger/U_Radinger/05_GRAS
S/FIDIMO/FIDIMO_Script/fidimo for grass 6.x/r.fidimo: not
found
/usr/local/grass-6.5.svn/scripts/v.db.dropcol: 1: eval: /r.r
dfilter=/home/radinger/U_Radinger/05_GRASS/FIDIMO/FIDIMO_Scr
ipt/fidimo for grass 6.x/r.fidimo: not found
(Tue Aug 14 12:47:31 2012) Command finished (1 sec)
}}}

and here an extended output with the -x flag:

{{{

(Tue Aug 14 13:00:50 2012)
v.db.dropcol map=sender_point@FIDIMO_Cele column=testcol
+ [ -z /usr/local/grass-6.5.svn ]
+ [ map=sender_point@FIDIMO_Cele != @ARGS_PARSED@ ]
+ basename /usr/local/grass-6.5.svn/scripts/v.db.dropcol
+ CMDLINE=v.db.dropcol
+ CMDLINE=v.db.dropcol "map=sender_point@FIDIMO_Cele"
+ CMDLINE=v.db.dropcol "map=sender_point@FIDIMO_Cele"
"column=testcol"
+ export CMDLINE
+ exec g.parser
/usr/local/grass-6.5.svn/scripts/v.db.dropcol
map=sender_point@FIDIMO_Cele column=testcol
+ [ -z /usr/local/grass-6.5.svn ]
+ [ @ARGS_PARSED@ != @ARGS_PARSED@ ]
+ basename /usr/local/grass-6.5.svn/scripts/v.db.dropcol
+ PROG=v.db.dropcol
+ g.tempfile pid=10834
+ TEMPFILE=/home/radinger/Documents/GRASS_locations/Cele_loc
ation/FIDIMO_Cele/.tmp/grassgis/10834.0
+ [ 0 -ne 0 ]
+ [ -z /home/radinger/Documents/GRASS_locations/Cele_locatio
n/FIDIMO_Cele/.tmp/grassgis/10834.0 ]
+ trap exitprocedure 2 3 15
+ g.gisenv
+ eval GISDBASE='/home/radinger/Documents/GRASS_locations';
LOCATION_NAME='Cele_location'; MAPSET='FIDIMO_Cele'; ADDON_P
ATH='/home/radinger/.grass6/addons:/home/radinger/.grass6/ad
dons:/home/radinger/.grass6/addons:/home/radinger/.grass6/ad
dons:/home/radinger/U_Radinger/05_GRASS/GRASS_Scripts:/home/
radinger/U_R'; adinger/05_GRASS/GRASS_Scripts='/home/radinge
r/U_Radinger/05_GRASS/FIDIMO/FIDIMO_Script/fidimo for grass
6.x/r.fidimo'; /r.rdfilter='/home/radinger/U_Radinger/05_GRA
SS/FIDIMO/FIDIMO_Script/fidimo for grass 6.x/r.fidimo';
GRASS_GUI='wxpython';
+ GISDBASE=/home/radinger/Documents/GRASS_locations
+ LOCATION_NAME=Cele_location
+ MAPSET=FIDIMO_Cele
+ ADDON_PATH=/home/radinger/.grass6/addons:/home/radinger/.g
rass6/addons:/home/radinger/.grass6/addons:/home/radinger/.g
rass6/addons:/home/radinger/U_Radinger/05_GRASS/GRASS_Script
s:/home/radinger/U_R
+ adinger/05_GRASS/GRASS_Scripts=/home/radinger/U_Radinger/0
5_GRASS/FIDIMO/FIDIMO_Script/fidimo for grass 6.x/r.fidimo
/usr/local/grass-6.5.svn/scripts/v.db.dropcol: 1: eval: adin
ger/05_GRASS/GRASS_Scripts=/home/radinger/U_Radinger/05_GRAS
S/FIDIMO/FIDIMO_Script/fidimo for grass 6.x/r.fidimo: not
found
+ /r.rdfilter=/home/radinger/U_Radinger/05_GRASS/FIDIMO/FIDI
MO_Script/fidimo for grass 6.x/r.fidimo
/usr/local/grass-6.5.svn/scripts/v.db.dropcol: 1: eval: /r.r
dfilter=/home/radinger/U_Radinger/05_GRASS/FIDIMO/FIDIMO_Scr
ipt/fidimo for grass 6.x/r.fidimo: not found
+ GRASS_GUI=wxpython
+ : /usr/local/grass-6.5.svn
/home/radinger/Documents/GRASS_locations Cele_location
FIDIMO_Cele
+ g.findfile element=vector file=sender_point@FIDIMO_Cele
mapset=FIDIMO_Cele
+ eval name='sender_point@FIDIMO_Cele' mapset='FIDIMO_Cele'
fullname='sender_point@FIDIMO_Cele' file='/home/radinger/Doc
uments/GRASS_locations/Cele_location/FIDIMO_Cele/vector/send
er_point'
+ name=sender_point@FIDIMO_Cele mapset=FIDIMO_Cele
fullname=sender_point@FIDIMO_Cele file=/home/radinger/Docume
nts/GRASS_locations/Cele_location/FIDIMO_Cele/vector/sender_
point
+ [ ! /home/radinger/Documents/GRASS_locations/Cele_location
/FIDIMO_Cele/vector/sender_point ]
+ v.db.connect map=sender_point@FIDIMO_Cele -gl layer=1 fs=|
+ cut -f2 -d|
+ table=sender_point
+ [ -z sender_point ]
+ cut -f3 -d|
+ v.db.connect -gl fs=| map=sender_point@FIDIMO_Cele layer=1
+ keycol=cat
+ cut -f4 -d|
+ v.db.connect -gl fs=| map=sender_point@FIDIMO_Cele layer=1
+ database=/home/radinger/Documents/GRASS_locations/Cele_loc
ation/FIDIMO_Cele/sqlite.db
+ v.db.connect -gl fs=| map=sender_point@FIDIMO_Cele layer=1
+ cut -f5 -d|
+ driver=sqlite
+ col=testcol
+ [ testcol = cat ]
+ cut -d| -f1,2
+ v.info --q -c map=sender_point@FIDIMO_Cele layer=1
+ grep |testcol$
+ [ 0 -ne 0 ]
+ [ sqlite = sqlite ]
+ grep -v |testcol$
+ cut -d| -f1,2
+ v.info --q -c map=sender_point@FIDIMO_Cele layer=1
+ cut -d| -f1
+ cat /home/radinger/Documents/GRASS_locations/Cele_location
/FIDIMO_Cele/.tmp/grassgis/10834.0.coldesc
+ cut -d| -f2
+ cat /home/radinger/Documents/GRASS_locations/Cele_location
/FIDIMO_Cele/.tmp/grassgis/10834.0.coldesc
+ paste -d /home/radinger/Documents/GRASS_locations/Cele_lo
cation/FIDIMO_Cele/.tmp/grassgis/10834.0.colnames /home/radi
nger/Documents/GRASS_locations/Cele_location/FIDIMO_Cele/.tm
p/grassgis/10834.0.coltypes
+ tr \n ,
+ sed s+,$++g
+ COLDEF=cat INTEGER,River TEXT,Station
TEXT,Station_fullname TEXT,X_LambII INTEGER,Y_LambII
INTEGER,X_Lamb93 INTEGER,Y_Lamb93 INTEGER,adj_X DOUBLE
PRECISION,adj_Y DOUBLE PRECISION,N INTEGER
+ sed s+,$++g
+ tr \n ,
+ cat /home/radinger/Documents/GRASS_locations/Cele_location
/FIDIMO_Cele/.tmp/grassgis/10834.0.colnames
+ COLNAMES=cat,River,Station,Station_fullname,X_LambII,Y_Lam
bII,X_Lamb93,Y_Lamb93,adj_X,adj_Y,N
+ echo BEGIN TRANSACTION;
CREATE TEMPORARY TABLE sender_point_backup(cat INTEGER,River
TEXT,Station TEXT,Station_fullname TEXT,X_LambII
INTEGER,Y_LambII INTEGER,X_Lamb93 INTEGER,Y_Lamb93
INTEGER,adj_X DOUBLE PRECISION,adj_Y DOUBLE PRECISION,N
INTEGER);
INSERT INTO sender_point_backup SELECT cat,River,Station,Sta
tion_fullname,X_LambII,Y_LambII,X_Lamb93,Y_Lamb93,adj_X,adj_
Y,N FROM sender_point;
DROP TABLE sender_point;
CREATE TABLE sender_point(cat INTEGER,River TEXT,Station
TEXT,Station_fullname TEXT,X_LambII INTEGER,Y_LambII
INTEGER,X_Lamb93 INTEGER,Y_Lamb93 INTEGER,adj_X DOUBLE
PRECISION,adj_Y DOUBLE PRECISION,N INTEGER);
INSERT INTO sender_point SELECT cat,River,Station,Station_fu
llname,X_LambII,Y_LambII,X_Lamb93,Y_Lamb93,adj_X,adj_Y,N
FROM sender_point_backup;
CREATE UNIQUE INDEX sender_point_cat ON sender_point ( cat
);
DROP TABLE sender_point_backup;
COMMIT;
+ db.execute input=/home/radinger/Documents/GRASS_locations/
Cele_location/FIDIMO_Cele/.tmp/grassgis/10834.0
+ [ 0 -eq 1 ]
+ cleanup
+ rm -f /home/radinger/Documents/GRASS_locations/Cele_locati
on/FIDIMO_Cele/.tmp/grassgis/10834.0 /home/radinger/Document
s/GRASS_locations/Cele_location/FIDIMO_Cele/.tmp/grassgis/10
834.0.coltypes /home/radinger/Documents/GRASS_locations/Cele
_location/FIDIMO_Cele/.tmp/grassgis/10834.0.colnames /home/r
adinger/Documents/GRASS_locations/Cele_location/FIDIMO_Cele/
.tmp/grassgis/10834.0.coldesc
+ v.support map=sender_point@FIDIMO_Cele
cmdhist=v.db.dropcol "map=sender_point@FIDIMO_Cele"
"column=testcol"
+ exit 0
(Tue Aug 14 13:00:52 2012) Command finished (1 sec)
}}}

This might be related to ticket #1683 and is caused by a whitespace in one
of the specified Add-On paths. This has been tested on Ubuntu 12.04 with
GRASS 6.5SVN r52671.

/johannes

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1696&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: hamish
     Type: defect | Status: assigned
Priority: normal | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------
Changes (by hamish):

* cc: grass-dev@… (added)
  * owner: grass-dev@… => hamish
  * status: new => assigned

Comment:

right, this is a sibling of #1683, sorry I haven't been able to get to all
of them yet. Further review of the GUI's method of setting the ADDON
environment variable is needed too, but the scripts should be robust
enough to deal with it regardless.

Hamish

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/1696#comment:1&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: hamish
     Type: defect | Status: assigned
Priority: blocker | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------
Changes (by hamish):

  * priority: normal => blocker

Comment:

Replying to [comment:1 hamish]:
> right, this is a sibling of #1683, sorry I haven't been able to
> get to all of them yet. Further review of the GUI's method of
> setting the ADDON environment variable is needed too, but the
> scripts should be robust enough to deal with it regardless.

re. "Further review of the GUI's method of setting the ADDON environment
variable is needed", 6.4.3 should not be released with the recent system
vs. grass enviro var duplication confusion.

Last chance to justify the need for a parallel method before I remove the
g.gisenv ADDON_PATH stuff from init.sh and the GUI in 6.x.svn... As quoted
above, I didn't want to do that without discussion of why the redundant
g.gisenv method needed to be there.

Hamish

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/1696#comment:2&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: martinl
     Type: defect | Status: new
Priority: blocker | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------
Changes (by martinl):

  * owner: hamish => martinl
  * status: assigned => new

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1696#comment:3&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: martinl
     Type: defect | Status: assigned
Priority: blocker | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------
Changes (by martinl):

  * status: new => assigned

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1696#comment:4&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
---------------------------+------------------------------------------------
Reporter: jradinger | Owner: martinl
     Type: defect | Status: assigned
Priority: blocker | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Keywords: | Platform: Unspecified
      Cpu: All |
---------------------------+------------------------------------------------

Comment(by martinl):

For record, first steps to eliminate GIS env ADDON_PATH done in r53481.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1696#comment:5&gt;
GRASS GIS <http://grass.osgeo.org>

#1696: Error message v.db.dropcol (Add-On Path)
----------------------------+-----------------------------------------------
  Reporter: jradinger | Owner: martinl
      Type: defect | Status: closed
  Priority: blocker | Milestone: 6.4.3
Component: Shell Scripts | Version: unspecified
Resolution: fixed | Keywords:
  Platform: Unspecified | Cpu: All
----------------------------+-----------------------------------------------
Changes (by martinl):

  * status: assigned => closed
  * resolution: => fixed

Comment:

GIS env ADDON_PATH has been elimited in all active branches. Seems to be
solved. Closing for now, re-open if needed.

--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1696#comment:6&gt;
GRASS GIS <http://grass.osgeo.org>