-
Notifications
You must be signed in to change notification settings - Fork 647
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed lockfile check when using a Docker read-only filesystem #3832
Changes from 1 commit
c7fa13e
41342f6
51e3b75
186fbfe
f08e1c3
5b5ec9d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -197,7 +197,7 @@ def _load_offsets(self): | |
try: | ||
with fasteners.InterProcessLock(lock_name) as filelock: | ||
pass | ||
except PermissionError: | ||
except (PermissionError, OSError): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. According to the Python docs, EDIT: It's |
||
warnings.warn(f"Cannot write lock/offset file in same location as " | ||
"{self.filename}. Using slow offset calculation.") | ||
self._read_offsets(store=True) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A reproducer for the original handled PermissionError is straightforward, like below, I wonder if we could cook something up for the other error? May not be worth much energy though.