Skip to content

Commit

Permalink
Merge pull request #16 from apmechev/spider
Browse files Browse the repository at this point in the history
Use SafePopen.

YOPO
  • Loading branch information
apmechev committed Oct 24, 2019
2 parents 4157bc0 + 723ad50 commit 785f6b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion GRID_LRT/application/submit.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def launch(self, database=None):
self._check_authorized()
if not self.temp_file:
self.temp_file = self.make_temp_slurmfile(database = database)
sub = subprocess.Popen(['sbatch', self.temp_file.name], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
sub = SafePopen(['sbatch', self.temp_file.name], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
out = sub.communicate()
if out[1] == "":
return out[0]
Expand Down

0 comments on commit 785f6b5

Please sign in to comment.