Nodes/ComfyUI-Koolook/Koolook Loop Status
ComfyUI Node

Koolook Loop Status

Koolook Loop Status reports and auto-queues

By malkuthro·Created 11 months ago·Updated a day ago· 8
Koolook Loop Status
  • value
  • value
  • status
index0
total1
filepath
labelloop
auto_queue_nextfalse
index_node_id
server_urlauto
max_auto_queue_depth100
remaining_auto_queue_depth-1

Loop Status is the node you drop inside a frame loop when you're tired of staring at the queue. It passes your payload through untouched while doing two useful things: printing where the loop is, and - if you let it - automatically queueing the next iteration so a whole batch runs without you clicking "Queue" a hundred times.

The idea is simple. A loop in ComfyUI is just a workflow that re-runs with a changed index (typically an "easy int" node driving the loop body). Loop Status sits inside that body, receives the current index and total, and reports label: 3/81 frame 2 - plus the resolved output path if you give it one. The value input is a wildcard: anything you route through it (images, latents, prompts) comes out the other side exactly as it went in. It's a status reporter that happens to live in the data path.

The settings that matter

  • value - pass-through payload. Wire whatever the loop body is processing.
  • index - the current zero-based frame index, from whatever drives your loop. Wire it from the same int node that feeds the loop.
  • total - how many iterations the loop should run. This sets the stop condition.
  • filepath - optional. A sequence-style path like out/shot_%04d.exr; the %04d gets previewed with the current index in the status line, so you can see exactly which file this iteration would write.
  • label - short tag printed before the progress (EXR_SAFE, plate_pass, whatever keeps multiple loops distinguishable).

Then the auto-queue half:

  • auto_queue_next - the interesting one. When on, the node queues the next prompt itself, advancing the connected index node, and keeps doing it until index + 1 reaches total. That's a full unattended batch.
  • server_url - defaults to auto, which detects the running ComfyUI server and port (127.0.0.1:8188 by default). Only touch this if your setup is unusual.
  • max_auto_queue_depth - a safety cap (default 100) on how many child prompts one run may chain. This is the runaway-loop brake. Leave it alone until you know you need to change it.
  • remaining_auto_queue_depth - internal countdown carried into child prompts. The tooltip says it plainly: leave at -1 in normal canvas use.

Install

Part of ComfyUI-Koolook. ComfyUI Manager → Install Custom Nodes → Git URL:

https://github.com/malkuthro/ComfyUI-Koolook.git

Or:

cd ComfyUI/custom_nodes
git clone https://github.com/malkuthro/ComfyUI-Koolook.git

Restart and it's under Koolook/Loop. No models, no extra dependencies. And the pack's one rule: install once. Manager installs to custom_nodes/koolook/; a second git clone creates a parallel install that double-registers and corrupts the workflow store on every restart until you delete one.

Common issues

  • Auto-queue does nothing - auto_queue_next is off, or the index isn't wired from the node actually driving the loop. The node detects the connected index node automatically; if you have an exotic setup, index_node_id is the manual override (leave blank normally).
  • It stopped early - total is set to a value lower than your intended frame count. The stop condition is index + 1 == total.
  • Runaway queue - that's what max_auto_queue_depth is for. It's a hard cap; if a loop is chaining more than you expect, this is the number to lower, not raise.
CategoryKoolook/Loop

Inputs (10)

NameTypeDefaultDescription
value*Payload to pass through unchanged while this node reports loop progress.
indexINT00–999999Current zero-based frame index. Wire this from the easy int node that drives the loop.
totalINT11–100000Total frames/prompts in this loop. Auto-queue stops when index + 1 reaches total.
filepathoptSTRINGOptional sequence path for the printed status line. %04d-style frame tokens are previewed with the current index.
labeloptSTRINGloopShort label printed before progress, for example EXR_SAFE or plate_pass.
auto_queue_nextoptBOOLEANfalseQueue the next prompt automatically after this frame, advancing the connected index node.
index_node_idoptSTRINGAdvanced override for the frame-index node id. Leave blank; the connected index input is normally detected automatically.
server_urloptSTRINGautoComfyUI server used for auto-queue. Leave auto to detect the running server and port.
max_auto_queue_depthoptINT1001–1000Safety cap for child prompts this run may chain, preventing accidental runaway loops.
remaining_auto_queue_depthoptINT-1-1–1000Internal countdown carried into child prompts. Leave at -1 in normal canvas use.

Outputs (2)

NameTypeDescription
value*
statusSTRING