Skip to content

Commit

Permalink
process: remove lock/unlock
Browse files Browse the repository at this point in the history
  • Loading branch information
skshetry authored and pmrowla committed Jan 13, 2023
1 parent 2665162 commit 643ce11
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/dvc_task/proc/process.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
from funcy import cached_property
from shortuuid import uuid

from ..contrib.kombu_filesystem import LOCK_SH, lock, unlock
from ..utils import makedirs
from .exceptions import TimeoutExpired

Expand All @@ -39,11 +38,7 @@ def from_dict(cls, data: Dict[str, Any]) -> "ProcessInfo":
def load(cls, filename: str) -> "ProcessInfo":
"""Construct the process information from a file."""
with open(filename, encoding="utf-8") as fobj:
lock(fobj, LOCK_SH)
try:
return cls.from_dict(json.load(fobj))
finally:
unlock(fobj)
return cls.from_dict(json.load(fobj))

def asdict(self) -> Dict[str, Any]:
"""Return this info as a dictionary."""
Expand Down

0 comments on commit 643ce11

Please sign in to comment.