MCPcopy Create free account
hub / github.com/tox-dev/filelock / __enter__

Method __enter__

src/filelock/_api.py:944–952  ·  view source on GitHub ↗

Acquire the lock. :returns: the lock object

(self)

Source from the content-addressed store, hash-verified

942 return self._context.lock_counter
943
944 def __enter__(self) -> Self:
945 """
946 Acquire the lock.
947
948 :returns: the lock object
949
950 """
951 self.acquire()
952 return self
953
954 def __exit__(
955 self,

Callers

nothing calls this directly

Calls 1

acquireMethod · 0.95

Tested by

no test coverage detected