Micky's earlier suggestion of entering
- Code: Select all
PYTHONIOENCODING=utf8 python3 ATC-pie.py
- Code: Select all
#!/bin/sh
PYTHONIOENCODING=utf8 python3 ATC-pie.py
And here's my path:
- Code: Select all
heviiguy@heviiApfel Resources$ echo $PATH
/opt/local/Library/Frameworks/Python.framework/Versions/3.4/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/local/bin:/opt/local/sbin:/opt/X11/bin:/usr/local/MacGPG2/bin:/Library/TeX/texbin:/usr/local/mysql/bin:/usr/local/php5/bin:/Applications/davinci.app/Contents/Resources/bin:/Applications/Argyll_V1.9.2/bin:/Applications/enblend-enfuse-4.0-mac:/Applications/McGimp-2.9-std.app/Contents/MacOS
This is what happens when I directly run the python script from my terminal...
- Code: Select all
heviiguy@heviiApfel Resources$ cd /Users/heviiguy/Programs/FlightGear/ATC-Pie/Code/
heviiguy@heviiApfel Code$ PYTHONIOENCODING=utf8 python3 ATC-pie.py
Loading aircraft & airline data... done.
Reading world navigation data... done.
Speech recognition modules not found; voice instructions disabled.
Speech synthesis module not found; pilot read-back disabled.
Setting up session 7681-0 in AD mode at location LSZR...
No elevation map found; using field elevation.
Radar position is: 47°29'15.49''N 9°33'9.63''E
No background image list found.
Closing main window.
heviiguy@heviiApfel Code$
As the above shows, it works as expected. It also works if I call the bash script...
- Code: Select all
heviiguy@heviiApfel Code$ ./ATC-Pie.sh
Loading aircraft & airline data... done.
Reading world navigation data... done.
Speech recognition modules not found; voice instructions disabled.
Speech synthesis module not found; pilot read-back disabled.
Setting up session 9975-0 in AD mode at location LSZR...
No elevation map found; using field elevation.
Radar position is: 47°29'15.49''N 9°33'9.63''E
No background image list found.
Closing main window.
heviiguy@heviiApfel Code$
Yet, if I try to run the same code from Automator,it hangs
Here's the Automator entry:
- Code: Select all
cd /Users/heviiguy/Programs/FlightGear/ATC-Pie/Code/
PYTHONIOENCODING=utf8 python3 ATC-pie.py
This is the output...
The action"Run Shell Script" encountered an error"
-: line 1: python3: command not found
And even when tell it where to find python3, it refuses to play nicely...
- Code: Select all
cd /Users/heviiguy/Programs/FlightGear/ATC-Pie/Code/
/opt/local/Library/Frameworks/Python.framework/Versions/3.4/bin/python3 PYTHONIOENCODING=utf8 python3 ATC-pie.py
This is the resultant dialogue:
/opt/local/Library/Frameworks/Python.framework/Versions/3.4/Resources/Python.app/Contents/MacOS/Python: can't open file 'PYTHONIOENCODING=utf8': [Errno 2] No such file or directory
Arrrgggghhhhh
Any suggestions? They would be most welcome!