MCPcopy Create free account
hub / github.com/OpenDCAI/Paper2Any / acquire

Method acquire

fastapi_app/interprocess_lock.py:50–55  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

48 return None
49
50 async def acquire(self) -> _HeldLockSlot:
51 while True:
52 held = self._try_acquire_once()
53 if held is not None:
54 return held
55 await asyncio.sleep(self._poll_interval)
56
57 @staticmethod
58 def release(held: _HeldLockSlot) -> None:

Callers 2

holdMethod · 0.95
inferFunction · 0.80

Calls 1

_try_acquire_onceMethod · 0.95

Tested by

no test coverage detected