[GRASS-dev] GRASS6.4 Ptyhon scripts- module

António Rocha antonio.rocha at deimos.com.pt
Mon Jun 21 12:12:07 EDT 2010


Greetings
I was developing a special import script (for a designated dataset) and 
I used r.in.aster Python Script (GRASS7) as a based for this Python 
script in GRASS6.4.. It compiled but I got this error:

make: Entering directory `/home/anrr/Desktop/dwe_devep/r.in.globcover.py'
if [ ! -d /usr/local/grass-6.4.0svn/scripts ]; then mkdir -p 
/usr/local/grass-6.4.0svn/scripts; fi
/usr/bin/install -c  r.in.globcover.py 
/usr/local/grass-6.4.0svn/scripts/r.in.globcover.py
make htmlscript scriptstrings
make[1]: Entering directory `/home/anrr/Desktop/dwe_devep/r.in.globcover.py'
make /usr/local/grass-6.4.0svn/docs/html/r.in.globcover.py.html 
HTMLSRC=/usr/local/grass-6.4.0svn/scripts/r.in.globcover.py
make[2]: Entering directory `/home/anrr/Desktop/dwe_devep/r.in.globcover.py'
if [ "/usr/local/grass-6.4.0svn/scripts/r.in.globcover.py" != "" ] ; 
then GISRC=/usr/local/grass-6.4.0svn/demolocation/grassrc64 
GISBASE=/usr/local/grass-6.4.0svn 
PATH="/usr/local/grass-6.4.0svn/bin:$PATH" 
LD_LIBRARY_PATH="/usr/local/grass-6.4.0svn/bin:/usr/local/grass-6.4.0svn/lib:" 
LC_ALL=C /usr/local/grass-6.4.0svn/scripts/r.in.globcover.py 
--html-description < /dev/null | grep -v '</body>\|</html>' > 
r.in.globcover.py.tmp.html ; true ; fi
Traceback (most recent call last):
  File "/usr/local/grass-6.4.0svn/scripts/r.in.globcover.py", line 50, 
in <module>
    import grass.script as grass
*ImportError: No module named grass.script*

I thought GRASS6.4 Python's script already had this module. Is not 
available?

Just one last question: How can I retrieve image projection, using a 
Python script, with tghe same information-structure I get when I use: 
grass.read_command('g.proj', flags = 'jf').strip()

Thanks

Best regards,
Antonio Rocha


__________ Information from ESET NOD32 Antivirus, version of virus signature database 5215 (20100621) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com




More information about the grass-dev mailing list