Skip to content

Commit

Permalink
added PermissionError
Browse files Browse the repository at this point in the history
  • Loading branch information
jfennick committed Mar 9, 2023
1 parent b968b42 commit 8393fa2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cwltool/job.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ def relink_initialworkdir(
pass
elif os.path.isdir(host_outdir_tgt) and not vol.resolved.startswith("_:"):
ensure_writable(host_outdir_tgt, include_root=True)
shutil.rmtree(host_outdir_tgt)
try:
shutil.rmtree(host_outdir_tgt)
except PermissionError:
pass
if not vol.resolved.startswith("_:"):
try:
os.symlink(vol.resolved, host_outdir_tgt)
Expand Down

0 comments on commit 8393fa2

Please sign in to comment.