Files
JeyzerMC-comfyui-flakes/web/widgets
Mehdi Chaid 9c927b5011 fix: combo highlight + progress for first generation (#241)
Two parts:

1. queue.js: websocket events (execution_start / executed / etc.) can
   arrive on the websocket transport BEFORE the REST response that
   gives us their prompt_id. The previous handlers looked up the pid
   in promptIds and bailed when it wasn't found — so the very first
   generation in a batch consistently lost its highlight and per-combo
   image stamp, and the overlay missed its progress events.

   Add a pendingByPid event buffer. When an event arrives for an
   unknown pid, queue it. When the patched api.queuePrompt finally
   resolves and registers the pid, replay the buffered events for it.
   Snapshot _currentBatchComboKey at call time so the queued combo key
   stays correct even if the await resolves out of order.

2. generation-data.js: when the overlay opens mid-batch, seed the
   progress bar on the currently-running combo's grid cards by
   reading _activeBatch.runningPromptId synchronously. Without this,
   a late-opened overlay only started showing progress on the *next*
   running combo.

Closes #241
2026-05-22 10:10:25 -04:00
..