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

Method wait

test/test_load_balancer.py:178–186  ·  view source on GitHub ↗
(self, event: Event, timeout: int)

Source from the content-addressed store, hash-verified

176 raise Exception("timed out waiting for unlock signal: deadlock?")
177
178 def wait(self, event: Event, timeout: int):
179 if _IS_SYNC:
180 return event.wait(timeout) # type: ignore[call-arg]
181 else:
182 try:
183 asyncio.wait_for(event.wait(), timeout=timeout)
184 except asyncio.TimeoutError:
185 return False
186 return True
187
188
189if __name__ == "__main__":

Callers 7

_test_no_gc_deadlockMethod · 0.95
test_session_gcMethod · 0.95
lock_poolMethod · 0.95
joinallFunction · 0.45
joinMethod · 0.45
async_barrier_waitFunction · 0.45
barrier_waitFunction · 0.45

Calls 1

wait_forMethod · 0.80

Tested by

no test coverage detected