diff options
author | Gard Spreemann <gspreemann@gmail.com> | 2016-03-29 11:12:23 +0200 |
---|---|---|
committer | Gard Spreemann <gspreemann@gmail.com> | 2016-03-29 11:12:23 +0200 |
commit | 5d5f761caeba38491a620e56c32ae8f23c0db848 (patch) | |
tree | 56b9a79ce595a749e46d6b1da004ef2ac001b0d2 | |
parent | 6c1f9f3b488c5f147d6977c3e49eb7eecdbe841d (diff) |
Fail earlier if mpirun or dipha are not found.
-rw-r--r-- | phstuff/diphawrapper.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/phstuff/diphawrapper.py b/phstuff/diphawrapper.py index 06e8913..f6ab403 100644 --- a/phstuff/diphawrapper.py +++ b/phstuff/diphawrapper.py @@ -295,9 +295,9 @@ class DiphaRunner: else: self.dipha = dipha - if self.mpirun is None: + if self.mpirun is None or not os.path.isfile(self.mpirun): raise RuntimeError("Could not find mpirun exectuable.") - if self.dipha is None: + if self.dipha is None or not os.path.isfile(self.dipha): raise RuntimeError("Could not find dipha executable.") self.tmpdir = tempfile.mkdtemp() |