[GRASS-dev] First step by GRASS

2015-11-06 Thread Nunzia Laguardia
I want to create a simple plugin that uses grass.
My configuration is:
- OS: widows 7 64bit
- Python: 2.7.4 (32bit)
- Osgeo4W (32bit) with

   -Qgis: 2.12.0
   -Grass: 6.4.4
   -Python: 2.7.4

GISBASE=C:/OSGeo4W/apps/grass/grass-6.4.4
GISRC=C:/Users/intema/AppData/Roaming/GRASS6/.grassrc6
PYTHONPATH=%GISBASE%/etc/python;%GISBASE%/etc/python/grass;%GISBASE%/etc/python/grass/script
PATH=%GISBASE%/lib;%GISBASE%/bin;%GISBASE%/scripts;C:/OSGeo4W/bin

if I open a shell and start python and write the command import
grass.script everything works.
if I open qgis and open the shell of python and write the command import
grass.script I have the following error
  File "C:\OSGeo4W\apps\Python27\lib\subprocess.py", line 878, in
_make_inheritable
_subprocess.DUPLICATE_SAME_ACCESS)
WindowsError: [Error 6] Handle non valido

if I write in my plugin the command import grass.script I have the seame
error.

I followed the tutorial:
https://grasswiki.osgeo.org/wiki/Working_with_GRASS_without_starting_it_explicitly

Please help I read all forum that reported the same mistake but I did not
find solution .
Some indicate that the problem definition dell'stdin stdout and stderr .

I'm sorry for my english.
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

[GRASS-dev] [GRASS GIS] #2793: t.rast.univar lacks "output" option to get output in text file

2015-11-06 Thread GRASS GIS
#2793: t.rast.univar lacks "output" option to get output in text file
---+-
 Reporter:  veroandreo |  Owner:  grass-dev@…
 Type:  enhancement| Status:  new
 Priority:  normal |  Milestone:  7.1.0
Component:  Temporal   |Version:  svn-trunk
 Keywords:  t.rast.univar  |CPU:  Unspecified
 Platform:  Linux  |
---+-
 This would be especially needed by windows users to avoid copy-pasting and
 manually saving to a text file.

--
Ticket URL: 
GRASS GIS 

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

Re: [GRASS-dev] [GRASS GIS] #2793: t.rast.univar lacks "output" option to get output in text file

2015-11-06 Thread GRASS GIS
#2793: t.rast.univar lacks "output" option to get output in text file
--+-
  Reporter:  veroandreo   |  Owner:  grass-dev@…
  Type:  enhancement  | Status:  new
  Priority:  normal   |  Milestone:  7.0.2
 Component:  Temporal |Version:  svn-releasebranch70
Resolution:   |   Keywords:  t.rast.univar
   CPU:  Unspecified  |   Platform:  Linux
--+-
Changes (by veroandreo):

 * version:  svn-trunk => svn-releasebranch70
 * milestone:  7.1.0 => 7.0.2


--
Ticket URL: 
GRASS GIS 

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

Re: [GRASS-dev] [GRASS GIS] #2793: t.rast.univar lacks "output" option to get output in text file

2015-11-06 Thread GRASS GIS
#2793: t.rast.univar lacks "output" option to get output in text file
--+-
  Reporter:  veroandreo   |  Owner:  grass-dev@…
  Type:  enhancement  | Status:  new
  Priority:  normal   |  Milestone:  7.0.2
 Component:  Temporal |Version:  svn-releasebranch70
Resolution:   |   Keywords:  t.rast.univar
   CPU:  Unspecified  |   Platform:  Linux
--+-

Comment (by veroandreo):

 Sorry, it is there in 7.1.

 I hope it could be backported soon.

 Thanks :)

--
Ticket URL: 
GRASS GIS 

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

Re: [GRASS-dev] [GRASS GIS] #2793: t.rast.univar lacks "output" option to get output in text file

2015-11-06 Thread GRASS GIS
#2793: t.rast.univar lacks "output" option to get output in text file
--+-
  Reporter:  veroandreo   |  Owner:  grass-dev@…
  Type:  enhancement  | Status:  new
  Priority:  normal   |  Milestone:  7.0.3
 Component:  Temporal |Version:  svn-releasebranch70
Resolution:   |   Keywords:  t.rast.univar
   CPU:  Unspecified  |   Platform:  Linux
--+-
Changes (by martinl):

 * milestone:  7.0.2 => 7.0.3


Comment:

 I am not sure about 7.0.2, we are very close to release. Any option from
 tgrass devs?

--
Ticket URL: 
GRASS GIS 

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

[GRASS-dev] Return value from g.copy is one when --overwrite - bug or feature?

2015-11-06 Thread Rainer M Krug
When copying via g.copy and specifying --overwrite and the target object
already exists, the return value is 1 but no error message is returned:

,
| simASM:grassAnalysis> g.copy --overwrite region=region1,region2
| simASM:grassAnalysis> echo $?
| 1
| simASM:grassAnalysis>  g.version
| GRASS 7.0.1 (2015)
| simASM:grassAnalysis>
`

From http://tldp.org/LDP/abs/html/exit-status.html:

,
| A successful command returns a 0, while an unsuccessful one returns a
| non-zero value that usually can be interpreted as an error code.
`

So shouldn't the return value be 0 in this case, as the command did what
it was told?

Cheers,

Rainer

-- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, 
UCT), Dipl. Phys. (Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :   +33 - (0)9 53 10 27 44
Cell:   +33 - (0)6 85 62 59 98
Fax :   +33 - (0)9 58 10 27 44

Fax (D):+49 - (0)3 21 21 25 22 44

email:  rai...@krugs.de

Skype:  RMkrug

PGP: 0x0F52F982


signature.asc
Description: PGP signature
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

Re: [GRASS-dev] Return value from g.copy is one when --overwrite - bug or feature?

2015-11-06 Thread Huidae Cho
Rainer,

I cannot seem to replicate your issue:

G srorg6630/tmp ~> g.version
GRASS 7.1.svn (2015)

G srorg6630/tmp ~> g.list region
tmp
tmp.d.rast.edit.6753
tmp1

G srorg6630/tmp ~> g.copy region=tmp,tmp1 --overwrite
Copy region definition  to current mapset as 

G srorg6630/tmp ~> echo $?
0

g.copy returns 1 when it cannot either read the source or write to the
target. Please check your permissions on your region files in
LOCATION/MAPSET/windows/.

Regards,
Huidae


On Fri, Nov 6, 2015 at 8:21 AM, Rainer M Krug  wrote:

> When copying via g.copy and specifying --overwrite and the target object
> already exists, the return value is 1 but no error message is returned:
>
> ,
> | simASM:grassAnalysis> g.copy --overwrite region=region1,region2
> | simASM:grassAnalysis> echo $?
> | 1
> | simASM:grassAnalysis>  g.version
> | GRASS 7.0.1 (2015)
> | simASM:grassAnalysis>
> `
>
> From http://tldp.org/LDP/abs/html/exit-status.html:
>
> ,
> | A successful command returns a 0, while an unsuccessful one returns a
> | non-zero value that usually can be interpreted as an error code.
> `
>
> So shouldn't the return value be 0 in this case, as the command did what
> it was told?
>
> Cheers,
>
> Rainer
>
> --
> Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation
> Biology, UCT), Dipl. Phys. (Germany)
>
> Centre of Excellence for Invasion Biology
> Stellenbosch University
> South Africa
>
> Tel :   +33 - (0)9 53 10 27 44
> Cell:   +33 - (0)6 85 62 59 98
> Fax :   +33 - (0)9 58 10 27 44
>
> Fax (D):+49 - (0)3 21 21 25 22 44
>
> email:  rai...@krugs.de
>
> Skype:  RMkrug
>
> PGP: 0x0F52F982
>
> ___
> grass-dev mailing list
> grass-dev@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-dev
>
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev