duck.utils.filelockΒΆ
File lock capabilities module.
Module ContentsΒΆ
FunctionsΒΆ
Lock file when modifying or accessing critical sections to avoid race conditions. |
|
Opens a file and acquires an exclusive lock. |
|
Unlock a locked file. |
APIΒΆ
- duck.utils.filelock.lock_file(file_descriptor, retries=5, wait=1)[source]ΒΆ
Lock file when modifying or accessing critical sections to avoid race conditions.