Skip to content

Commit 8ed6838

Browse files
psafontmr-c
authored andcommitted
fix: delete tmp dirs only when asked (#978)
1 parent d32e079 commit 8ed6838

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

cwltool/executors.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ def execute(self,
9696
getdefault(runtime_context.compute_checksum, True),
9797
path_mapper=runtime_context.path_mapper)
9898

99-
if runtime_context.rm_tmpdir is not None:
99+
if runtime_context.rm_tmpdir:
100100
if runtime_context.cachedir is None:
101101
output_dirs = self.output_dirs # type: Iterable[Any]
102102
else:

cwltool/job.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ def _execute(self,
381381
_logger.debug(u"[job %s] Removing input staging directory %s", self.name, self.stagedir)
382382
shutil.rmtree(self.stagedir, True)
383383

384-
if runtimeContext.rm_tmpdir is not None:
384+
if runtimeContext.rm_tmpdir:
385385
_logger.debug(u"[job %s] Removing temporary directory %s", self.name, self.tmpdir)
386386
shutil.rmtree(self.tmpdir, True)
387387

0 commit comments

Comments
 (0)