Skip to content

Commit f368be8

Browse files
committed
Merge pull request #562 from daniel-ge/fix/lsf
fix: LSF plugin
2 parents 295116e + 8d9fb50 commit f368be8

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

nipype/pipeline/plugins/lsf.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,10 @@ def _is_pending(self, taskid):
5252
result = cmd.run(ignore_exception=True)
5353
iflogger.setLevel(oldlevel)
5454
# logger.debug(result.runtime.stdout)
55-
if 'PEND' in result.runtime.stdout or 'RUN' in result.runtime.stdout:
56-
return True
57-
else:
55+
if 'DONE' in result.runtime.stdout or 'EXIT' in result.runtime.stdout:
5856
return False
57+
else:
58+
return True
5959

6060
def _submit_batchtask(self, scriptfile, node):
6161
cmd = CommandLine('bsub', environ=os.environ.data,
@@ -71,9 +71,9 @@ def _submit_batchtask(self, scriptfile, node):
7171
else:
7272
bsubargs += (" " + node.plugin_args['bsub_args'])
7373
if '-o' not in bsubargs: # -o outfile
74-
bsubargs = '%s -o %s' % (bsubargs, path)
74+
bsubargs = '%s -o %s' % (bsubargs, scriptfile + ".log")
7575
if '-e' not in bsubargs:
76-
bsubargs = '%s -e %s' % (bsubargs, path) # -e error file
76+
bsubargs = '%s -e %s' % (bsubargs, scriptfile + ".log") # -e error file
7777
if node._hierarchy:
7878
jobname = '.'.join((os.environ.data['LOGNAME'],
7979
node._hierarchy,

0 commit comments

Comments
 (0)