[GRASS-user] Problem with Python Scripts and grass.script (GRASS 6.5SVN) on Mac

Michael Barton Michael.Barton at asu.edu
Sat Apr 2 11:24:34 EDT 2011


Have you installed Python from python.org on your Mac? If you have, there may be a problem with that.

Michael
____________________
C. Michael Barton
Director, Center for Social Dynamics & Complexity 
Professor of Anthropology, School of Human Evolution & Social Change
Arizona State University

voice: 	480-965-6262 (SHESC), 480-727-9746 (CSDC)
fax:          480-965-7671 (SHESC),  480-727-0709 (CSDC)
www: http://www.public.asu.edu/~cmbarton, http://csdc.asu.edu











On Apr 1, 2011, at 9:33 AM, Johannes Radinger wrote:

> Hello again,
> 
> I tried to figure out the problem with william kyngesburye.
> the script is also working on his mac. I saved the script in the bin
> folder and ran in the GRASS terminal:
> 
> GRASS 6.5.svn (gisdemo_ncspm):~ > testscript.py newmap=test elevation=elevation.10m geology=geology
> Traceback (most recent call last):
> File "/Library/GRASS/6.5/Modules/bin/testscript.py", line 54, in <module>
>   sys.exit(main())
> File "/Library/GRASS/6.5/Modules/bin/testscript.py", line 47, in main
>   grass.mapcalc("${newmap} = ${elevation} * ${geology}",
> AttributeError: 'module' object has no attribute 'mapcalc'
> 
> 
> What causes this AttributeError?
> Any ideas?
> 
> sys.path and $PYTHONPATH seems to be okay according to william.
> 
> /johannes
> 
> 
> Am 01.04.2011 um 18:04 schrieb Glynn Clements:
> 
>> 
>> Johannes Radinger wrote:
>> 
>>> strange that this script isn't working on my mac...
>>> ..does it produce an outputmap on linux?
>> 
>> Yes.
>> 
>>> what can be the reason why I don't get an output
>>> on my mac with current 6.5?
>> 
>> I don't know.
>> 
>> -- 
>> Glynn Clements <glynn at gclements.plus.com>
> 



More information about the grass-user mailing list