[GRASS-user] v.out.gps

Hello,

I am trying to convert some points to gpx waypoints with v.out.gps,
but I get this error:

GRASS 7.0.svn (spearfish60):~ > v.out.gps -w input=archsites
type=point output=mywaypoints format=gpx

Traceback (most recent call last):

  File "/usr/local/grass-7.0.svn/scripts/v.out.gps", line 337, in <module>

    main()

  File "/usr/local/grass-7.0.svn/scripts/v.out.gps", line 208, in main

    re1 = re.compile(r'^\([PLBCFKA]\)')

NameError: global name 're' is not defined

ciao

--
--
Paolo C.
Lat. 44° 39' 11.08'' N Long. 7° 23' 25.26'' E

Hi,

2009/10/6 Paolo Craveri <pcraveri@gmail.com>:

re1 = re.compile(r'^\([PLBCFKA]\)')

NameError: global name 're' is not defined

hopefully fixed in r39426 (untested).

Un saluto, Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

2009/10/6 Martin Landa <landa.martin@gmail.com>:

Hi,

2009/10/6 Paolo Craveri <pcraveri@gmail.com>:

re1 = re.compile(r'^\([PLBCFKA]\)')

NameError: global name 're' is not defined

hopefully fixed in r39426 (untested).

Un saluto, Martin

--
Martin Landa <landa.martin gmail.com> * http://gama.fsv.cvut.cz/~landa

Thanks Martin

unfortunately there are still errors:

v.out.gps -w input=archsites@PERMANENT type=point output=points.gpx
ERROR: Required parameter <input> not set:
    (Input coordinate file ('-' to read from stdin)).
ERROR: Required parameter <input> not set:
    (Name of input file to be imported).
ERROR: Error reprojecting data

ciao

--
--
Paolo C.
Lat. 44° 39' 11.08'' N Long. 7° 23' 25.26'' E

Paolo:

unfortunately there are still errors:

v.out.gps -w input=archsites@PERMANENT type=point output=points.gpx
ERROR: Required parameter <input> not set:
    (Input coordinate file ('-' to read from stdin)).
ERROR: Required parameter <input> not set:
    (Name of input file to be imported).
ERROR: Error reprojecting data

try this patch:

Index: scripts/v.out.gps/v.out.gps.py

--- scripts/v.out.gps/v.out.gps.py (revision 39432)
+++ scripts/v.out.gps/v.out.gps.py (working copy)
@@ -217,7 +217,7 @@
     tmp_proj = tmp + ".proj"
     tf = open(tmp_proj, 'w')
     p1 = grass.pipe_command('v.out.ascii', input = inmap, format = 'standard')
- p2 = grass.feed_command('m.proj', flags = 'od', quiet = True, stdout = tf)
+ p2 = grass.feed_command('m.proj', input = '-', flags = 'od', quiet = True, stdout = tf)
     tf.close()

     lineno = 0
Index: scripts/m.proj/m.proj.py

--- scripts/m.proj/m.proj.py (revision 39432)
+++ scripts/m.proj/m.proj.py (working copy)
@@ -34,6 +34,7 @@
#% type: string
#% gisprompt: old_file,file,file
#% description: Input coordinate file ('-' to read from stdin)
+#% answer: -
#% required : yes
#% key_desc : filename
#%end

Hamish