Opened 10 years ago
Closed 6 years ago
#2591 closed defect (wontfix)
error in grass.sh selecting python version
Reported by: | foret37 | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.0.7 |
Component: | Default | Version: | unspecified |
Keywords: | Cc: | ||
CPU: | OSX/Intel | Platform: | Unspecified |
Description
I am running Grass 7.0.0RC1 on a Mac OSX 10.10.2. I launched the program using the Grass app, and it failed with an error.
I then ran the script directly in the term, in order to see the error.
cd /Applications/GRASS/GRASS-7.0.app/Contents/MacOS/ ./grass.sh
Rebuilding Addon HTML manual pages index... Rebuilding Addon menu... Python 2.7.9 found. arch: posix_spawnp: /opt/local/bin/pythonw2.7: Bad CPU type in executable
This problem is well known, and has to do with the selection of the wrong version of python, as discussed at http://grasswiki.osgeo.org/wiki/MacOSX_GRASS_errors. Some sluthing showed that grass.sh selects a link in my MacPorts directory, /opt/local/bin, that points to the native Apple version of python. I followed the instructions at MacOSX_GRASS_errors and added the following environment variables: export GRASS_PYTHON=/usr/bin/python2.6 export GRASS_PYTHONWX=/usr/bin/pythonw2.6 but that did not fix the problem (same errors). After a lot of messing around, I found that I can get grass started by placing the directory with the right version of python as first in the path string: export PATH="/usr/bin:$PATH" Grass launches now, regardless of the status of the GRASS_PYTHON and GRASS_PYTHONWX variables. My casual reading of the grass.sh script suggests that it never checks GRASS_PYTHONWX to see if it has a value. That issue suggests that the solution to the problem is add a check for GRASS_PYTHONWX.
One other issue that seems odd: Grass does not remember my initial settings. In other words, each time I login, it goes through the questions for a new user.
Change History (5)
comment:1 by , 9 years ago
Milestone: | 7.0.0 → 7.0.5 |
---|
comment:2 by , 8 years ago
comment:3 by , 8 years ago
Milestone: | 7.0.5 → 7.0.6 |
---|
comment:4 by , 7 years ago
Milestone: | 7.0.6 → 7.0.7 |
---|
Still an issue?