MCPcopy Create free account
hub / github.com/tox-dev/filelock / enter_gate

Function enter_gate

tests/core/test_release_interruption.py:125–129  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

123 pending = [None]
124
125 def enter_gate() -> bool:
126 if pending:
127 pending.pop()
128 raise KeyboardInterrupt
129 return transition.acquire()
130
131 gate.__enter__.side_effect = enter_gate
132 gate.__exit__.side_effect = lambda *_args: transition.release()

Callers

nothing calls this directly

Calls 1

acquireMethod · 0.45

Tested by

no test coverage detected