fix: image gate reacts to ComfyUI Interrupt
GateBus.wait() only checked the gate's own Stop flag, so pressing ComfyUI's Interrupt left the image gate blocked. Add should_cancel to wait() (mirroring wait_payload) and pass mm.processing_interrupted from gate.py, matching the text gate. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -65,3 +65,10 @@ def test_wait_payload_should_cancel_raises():
|
||||
gb.GateBus.arm("p")
|
||||
with pytest.raises(gb.GateCancelled):
|
||||
gb.GateBus.wait_payload("p", should_cancel=lambda: True)
|
||||
|
||||
def test_wait_should_cancel_raises():
|
||||
# image gate: ComfyUI Interrupt (should_cancel) must abort the wait too
|
||||
gb.GateBus.arm("7")
|
||||
with pytest.raises(gb.GateCancelled):
|
||||
gb.GateBus.wait("7", should_cancel=lambda: True)
|
||||
assert gb.GateBus.cancelled is False
|
||||
|
||||
Reference in New Issue
Block a user