sate-dev/sate-core — Issue #4: Assuming "mafft" is a python script
Author: smirarab
Created: 2011-10-22 21:35:23+00:00
State: open

a nice feature of SATe is that you can substitute the default bundled tools with whatever version of the tool you have available by changing the path attribute in config files. This however, does not work for mafft. The real mafft program is not in python. In SATe there is a python script that wraps around mafft. But it is hardcoded in SATe that mafft should be called with "python". Now if I change my local path to a *real* mafft installation, it will fail because mafft is not in python (it's a shell script).

```
Exception: SATe failed because one of the programs it tried to run failed.
The invocation that failed was:
"/lusr/bin/python" "/projects/sate7/tools/bin/mafft.6.857-64bit" "--localpair" "--maxiterate" "1000" "--ep" "0.123" "--quiet" "XXX.fasta"

File "/projects/sate7/tools/bin/mafft.6.857-64bit", line 5
myself=`dirname "$0"`/`basename "$0"`; export myself
^
SyntaxError: invalid syntax
```

If we were dealing with linux we could have solved this with a simple shebang. But I don't think windows works with shebang. Instead I think we need to create a small platform-dependent script (Shell, .bat, etc.) that calls the python script. This way we don't need to hard-code python in tools.py and therefore user can customize mafft to use a real installation on their systems.