Skip to content

Commit

Permalink
* Removed explicit touch for lock file
Browse files Browse the repository at this point in the history
  • Loading branch information
Lukas Abelt committed Sep 14, 2023
1 parent f49906a commit 5484fab
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions varats-core/varats/utils/filesystem_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,6 @@ def __init__(self, folder: tp.Union[Path, str]) -> None:

@contextmanager
def lock_file(lock_path: Path, lock_mode: int = fcntl.LOCK_EX) -> tp.Generator:
# Ensure that the lock exists
lock_path.touch(exist_ok=True)

open_mode = os.O_RDWR | os.O_CREAT | os.O_TRUNC
lock_fd = os.open(lock_path, open_mode)
try:
Expand Down

0 comments on commit 5484fab

Please sign in to comment.