MCPcopy Index your code
hub / github.com/mongodb/mongo-python-driver / locked

Method locked

pymongo/_asyncio_lock.py:106–108  ·  view source on GitHub ↗

Return True if lock is acquired.

(self)

Source from the content-addressed store, hash-verified

104 return f"<{res[1:-1]} [{extra}]>"
105
106 def locked(self) -> bool:
107 """Return True if lock is acquired."""
108 return self._locked
109
110 async def acquire(self) -> bool:
111 """Acquire a lock.

Callers 10

targetMethod · 0.80
test_waitMethod · 0.80
test_wait_cancelMethod · 0.80
test_context_managerMethod · 0.80
_release_locksFunction · 0.80
__repr__Method · 0.80
waitMethod · 0.80
notifyMethod · 0.80
_after_forkFunction · 0.80

Calls

no outgoing calls

Tested by 5

targetMethod · 0.64
test_waitMethod · 0.64
test_wait_cancelMethod · 0.64
test_context_managerMethod · 0.64