MCPcopy Index your code
hub / github.com/python/cpython / clear

Method clear

Lib/asyncio/locks.py:194–198  ·  view source on GitHub ↗

Reset the internal flag to false. Subsequently, tasks calling wait() will block until set() is called to set the internal flag to true again.

(self)

Source from the content-addressed store, hash-verified

192 fut.set_result(True)
193
194 def clear(self):
195 """Reset the internal flag to false. Subsequently, tasks calling
196 wait() will block until set() is called to set the internal flag
197 to true again."""
198 self._value = False
199
200 async def wait(self):
201 """Block until the internal flag is true.

Callers 15

test_eventMethod · 0.95
test_reprMethod · 0.95
test_clearMethod · 0.95
_force_closeMethod · 0.45
_write_sendmsgMethod · 0.45
_write_sendMethod · 0.45
put_nowaitMethod · 0.45
connection_lostMethod · 0.45
closeMethod · 0.45

Calls

no outgoing calls

Tested by 6

test_eventMethod · 0.76
test_reprMethod · 0.76
test_clearMethod · 0.76