Locks owned by this manager, shared by operations using the same key.
Source code in octomate/managers/base.py
| class Locks[Key: Hashable]:
"""Locks owned by this manager, shared by operations using the same key."""
@cached_property
def locks(self) -> dict[Key, asyncio.Lock]:
return {}
def lock(self, key: Key) -> asyncio.Lock:
return self.locks.setdefault(key, asyncio.Lock())
|
lock
lock(key: Key) -> asyncio.Lock
Source code in octomate/managers/base.py
| def lock(self, key: Key) -> asyncio.Lock:
return self.locks.setdefault(key, asyncio.Lock())
|