Re: [GRASS-dev] Weird v.proj bug: ERROR: Option does not accept multiple answers

2016-05-20 Thread Markus Neteler
On Fri, May 20, 2016 at 10:39 AM, Moritz Lennert
 wrote:
...
> How is this a bug ?

... right, it is not.

...
> So, when you write:
>
> v.proj -l bla location=nc_spf_grass7 mapset=PERMANENT
>
> this translates to
>
> v.proj -l location=bla location=nc_spf_grass7 mapset=PERMANENT
>
> i.e. you define the location parameter twice, which is obviously an error
> and so the error message is logical.

Yes. I got confused with the order in G6:

https://grass.osgeo.org/grass64/manuals/v.proj.html
v.proj [-lz] [input=name] location=name [mapset=name] ...

https://grass.osgeo.org/grass70/manuals/v.proj.html
v.proj [-lzw] location=name [mapset=name] [input=name] ...

Sorry for the noise! All fine.

cheers,
Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Weird v.proj bug: ERROR: Option does not accept multiple answers

2016-05-20 Thread Moritz Lennert

On 20/05/16 07:12, Markus Neteler wrote:


On May 20, 2016 2:35 AM, "Vaclav Petras" > wrote:
 >
 >
 > On Thu, May 19, 2016 at 6:10 PM, Markus Neteler > wrote:
 >>
 >>
 >> today I came across a weird error (both 7.0.svn and trunk):
 >>
 >> # NC datasets
 >> GRASS 7.0.5svn (nc_spm_08_grass7):~ > v.proj -l bla
 >> location=nc_spf_grass7 mapset=PERMANENT
 >>
 >> Description:
 >>  Re-projects a vector map from one location to the current location.
 >> ...
 >> ERROR: Option  does not accept multiple answers
 >
 >
 > This is caused by the parser and it happens with every module:
 >
 > > g.region xxx region=yyy
 > ...
 > ERROR: Option  does not accept multiple answers

Mhh, a super bug!



How is this a bug ?

The general rule in the parser is that the first parameter can be given 
unnamed, i.e.


v.proj location=nc_spf_grass7 mapset=PERMANENT

is equivalent to

v.proj nc_spf_grass7 mapset=PERMANENT

So, when you write:

v.proj -l bla location=nc_spf_grass7 mapset=PERMANENT

this translates to

v.proj -l location=bla location=nc_spf_grass7 mapset=PERMANENT

i.e. you define the location parameter twice, which is obviously an 
error and so the error message is logical.


Moritz
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Weird v.proj bug: ERROR: Option does not accept multiple answers

2016-05-19 Thread Markus Neteler
On May 20, 2016 2:35 AM, "Vaclav Petras"  wrote:
>
>
> On Thu, May 19, 2016 at 6:10 PM, Markus Neteler  wrote:
>>
>>
>> today I came across a weird error (both 7.0.svn and trunk):
>>
>> # NC datasets
>> GRASS 7.0.5svn (nc_spm_08_grass7):~ > v.proj -l bla
>> location=nc_spf_grass7 mapset=PERMANENT
>>
>> Description:
>>  Re-projects a vector map from one location to the current location.
>> ...
>> ERROR: Option  does not accept multiple answers
>
>
> This is caused by the parser and it happens with every module:
>
> > g.region xxx region=yyy
> ...
> ERROR: Option  does not accept multiple answers

Mhh, a super bug!
Confusing...

Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Weird v.proj bug: ERROR: Option does not accept multiple answers

2016-05-19 Thread Vaclav Petras
On Thu, May 19, 2016 at 6:10 PM, Markus Neteler  wrote:

>
> today I came across a weird error (both 7.0.svn and trunk):
>
> # NC datasets
> GRASS 7.0.5svn (nc_spm_08_grass7):~ > v.proj -l bla
> location=nc_spf_grass7 mapset=PERMANENT
>
> Description:
>  Re-projects a vector map from one location to the current location.
> ...
> ERROR: Option  does not accept multiple answers
>

This is caused by the parser and it happens with every module:

> g.region xxx region=yyy
...
ERROR: Option  does not accept multiple answers
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] Weird v.proj bug: ERROR: Option does not accept multiple answers

2016-05-19 Thread Markus Neteler
Hi,

today I came across a weird error (both 7.0.svn and trunk):

# NC datasets
GRASS 7.0.5svn (nc_spm_08_grass7):~ > v.proj -l bla
location=nc_spf_grass7 mapset=PERMANENT

Description:
 Re-projects a vector map from one location to the current location.
...
ERROR: Option  does not accept multiple answers


How come? Is it just me?

Markus
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev