[GRASS5] [bug #782] (grass) r.out.ascii/r.in.ascii

this bug's URL: http://intevation.de/rt/webrt?serial_num=782
-------------------------------------------------------------------------

Subject: r.out.ascii/r.in.ascii

Platform: Linux/Intel
Linux distro: RedHat
linux cpu: Intel (i486, i586, pentium ...)
Xwindows version: Xfree 3.3.6
Xwindows manager: xfce-3.7.2
TclTk version: n/a
grass downloaded at: CVS Server, Germany
grass binary for platform: I compiled the sources myself
grass sources source: yes, I am using the latest GRASS from CVS
c compiler name: gcc

GRASS:/mnt/usr4/projects/nevada/coeur > r.out.ascii

OPTION: Name of an existing raster map
     key: input
required: YES

Enter the name of an existing raster file
Enter 'list' for a list of existing raster files
Hit RETURN to cancel request

unionville_dem

<unionville_dem>

OPTION: Name of an output ASCII grid map (use out=- for stdout)
     key: output
required: YES

Enter the name of an existing raster file
Enter 'list' for a list of existing raster files
Hit RETURN to cancel request

  Notice that when the input map is named, the option for output map name is skipped and the input name is requested again. It runs fine after this:

Enter the name of an existing raster file
Enter 'list' for a list of existing raster files
Hit RETURN to cancel request

unionville_dem

<unionville_dem>

OPTION: Number of decimal places
     key: dp
default: 6
required: NO
enter option > 6

You have chosen:
  dp=6
Is this correct? (y/n) [y]

OPTION: Char string to represent no data cell
     key: null
default: *
required: NO
enter option >

FLAG: Set the following flag?
    Suppress printing of header information?(y/n) [n]

et cetera.

  BTW, the same bug appears in r.in.ascii. I can file a separate report on that if so desired. Again, input name is requested. When provided, output name request flies by on the screen and the input name is again requested. The second time the module works as advertised.

Rich

-------------------------------------------- Managed by Request Tracker

Request Tracker wrote:

GRASS:/mnt/usr4/projects/nevada/coeur > r.out.ascii

OPTION: Name of an existing raster map
     key: input
required: YES

Enter the name of an existing raster file
Enter 'list' for a list of existing raster files
Hit RETURN to cancel request
> unionville_dem
<unionville_dem>

OPTION: Name of an output ASCII grid map (use out=- for stdout)
     key: output
required: YES

Enter the name of an existing raster file
Enter 'list' for a list of existing raster files
Hit RETURN to cancel request

  Notice that when the input map is named, the option for output map
  name is skipped and the input name is requested again. It runs fine
  after this:

It appears that the author didn't quite understand the command-line
parser. That argument has:

    parm.output->gisprompt = "old,cell,raster" ;

which tells the parser that the "output" argument is the name of an
existing raster map layer (it isn't; it's a filename).

I'll commit a fix to this.

  BTW, the same bug appears in r.in.ascii. I can file a separate
  report on that if so desired. Again, input name is requested. When
  provided, output name request flies by on the screen and the input
  name is again requested. The second time the module works as
  advertised.

r.in.ascii may have a bug, but it's not the same bug. Only "output"
has a "gisprompt" value.

--
Glynn Clements <glynn.clements@virgin.net>