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.