Skip to content
Snippets Groups Projects
Commit 3fb71241 authored by Sybren A. Stüvel's avatar Sybren A. Stüvel
Browse files

Also catch FileNotFoundError when doing a write check

This error is raised when the parent directory of a write check location
doesn't exist.
parent 2846632a
No related branches found
No related tags found
No related merge requests found
...@@ -897,7 +897,7 @@ class FlamencoWorker: ...@@ -897,7 +897,7 @@ class FlamencoWorker:
testfile = write_path.open('a+', encoding='utf8') testfile = write_path.open('a+', encoding='utf8')
with testfile as outfile: with testfile as outfile:
outfile.write('') outfile.write('')
except PermissionError: except (PermissionError, FileNotFoundError):
raise PreTaskCheckFailed('%s is not writable' % write_path) from None raise PreTaskCheckFailed('%s is not writable' % write_path) from None
if post_delete: if post_delete:
try: try:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment