Skip to content

Conversation

deepanjanroy
Copy link
Contributor

If "prompt_id" is provided in the interrupt call, check first if it matches the currently running prompt. Ignore the interrupt if prompt id does not match. This prevents race conditions where the prompt that was intended to be interrupted had finished already.

If no prompt_id is provided, the behavior remains same as before.

Manual tests:

  • Using curl, checked that
    • providing no json body works (old behavior)
    • wrong prompt_id does not interrupt executing job
    • correct prompt_id does interrupt executing job
  • Tested with latest frontend. Job cancellation works both using queue>right-click>delete, and clicking the red X button beside Run.

@guill guill added Core-Important Core Core team dependency labels Aug 28, 2025
@comfyanonymous comfyanonymous merged commit 464ba1d into comfyanonymous:master Sep 2, 2025
10 checks passed
Thor-ATX pushed a commit to asteriafilmco/ComfyUI that referenced this pull request Sep 3, 2025
…e-update

* commit '4f5812b93712e0f52ae8fe80a89e8b5e7d0fa309': (77 commits)
  Update template to 0.1.73 (comfyanonymous#9686)
  ImageScaleToMaxDimension node. (comfyanonymous#9689)
  Accept prompt_id in interrupt handler (comfyanonymous#9607)
  uso -> uxo/uno as requested.  (comfyanonymous#9688)
  USO style reference. (comfyanonymous#9677)
  Enable Convolution AutoTuning (comfyanonymous#9301)
  Implement the USO subject identity lora. (comfyanonymous#9674)
  Probably not necessary anymore. (comfyanonymous#9646)
  SEEDS: update noise decomposition and refactor (comfyanonymous#9633)
  convert Primitive nodes to V3 schema (comfyanonymous#9372)
  convert nodes_stability.py to V3 schema (comfyanonymous#9497)
  convert Video nodes to V3 schema (comfyanonymous#9489)
  convert Stable Cascade nodes to V3 schema (comfyanonymous#9373)
  ComfyUI version 0.3.56
  Lower ram usage on windows. (comfyanonymous#9628)
  ComfyUI v0.3.55
  Update template to 0.1.70 (comfyanonymous#9620)
  Trim audio to video when saving video. (comfyanonymous#9617)
  Support the 5B fun inpaint model. (comfyanonymous#9614)
  Support wan2.2 5B fun control model. (comfyanonymous#9611)
  ...
toxicwind pushed a commit to toxicwind/ComfyUI that referenced this pull request Oct 12, 2025
* Accept prompt_id in interrupt handler

* remove a log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Core Core team dependency Core-Important

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants