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

Method __enter__

src/filelock/_api.py:584–592  ·  view source on GitHub ↗

Acquire the lock. :returns: the lock object

(self)

Source from the content-addressed store, hash-verified

582 _LOGGER.debug("Lock %s released on %s", lock_id, lock_filename)
583
584 def __enter__(self) -> Self:
585 """
586 Acquire the lock.
587
588 :returns: the lock object
589
590 """
591 self.acquire()
592 return self
593
594 def __exit__(
595 self,

Callers

nothing calls this directly

Calls 1

acquireMethod · 0.95

Tested by

no test coverage detected