Nodes/OmniNodes/Workflow End 🏁
ComfyUI Node

Workflow End 🏁

A finish line for your workflow β€” and a done-file for your scripts

By TensorVizionΒ·Created 3 months agoΒ·Updated about 8 hours agoΒ· 0
Workflow End 🏁
  • input_1
  • input_2
  • input_3
  • input_4
  • summary
β—„run_labelworkflowβ–Ί
β—„write_logtrueβ–Ί
β—„write_done_markerfalseβ–Ί

ComfyUI workflows rarely have an ending - they just trail off into Save Image nodes. Workflow End gives you an explicit finish line: a terminal node that consumes up to four dangling outputs of any type, and optionally writes a run log entry and a "done" marker file. It exists for two reasons, and they're different enough to be worth separating.

First, the graph-structure reason. ComfyUI only executes nodes that feed an output node. Anything not wired toward a Preview or Save just doesn't run. Workflow End is itself an output node (OUTPUT_NODE = True), so connecting a branch to it guarantees that branch actually executes - a clean way to terminate dangling wires instead of leaving them floating in a way you can't be sure about.

Second, the automation reason. When write_done_marker is on, it writes a small <run_label>.done file into ComfyUI's output folder containing the completion timestamp. An external script or queue manager watching that folder can detect "this batch finished" without polling ComfyUI's HTTP API at all. That's the genuinely useful bit for anyone stitching ComfyUI into a bigger pipeline.

How it works

Up to four input_N sockets, all * type - connect anything you want guaranteed to execute and nothing else. On run it builds a summary line: the timestamp, your run_label, and how many of the four inputs were connected. With write_log on (default), it appends that line to output/omninodes_run_log.txt. With write_done_marker on, it also writes output/<run_label>.done with the timestamp and epoch time.

The marker filename gets sanitized - non-alphanumeric characters are replaced with underscores - so a label like "batch 7" becomes batch_7.done rather than breaking filesystem rules. The summary string shows in the UI and gets printed to the ComfyUI console as [OmniNodes] ....

Inputs and outputs

  • run_label - names the run in the log and the .done file. Make it meaningful; it's your automation's hook.
  • write_log (default true) - append to the run log.
  • write_done_marker (default false) - write the signal file. On by default would be nice, but as shipped it's opt-in.
  • input_1..input_4 - the dangling outputs you want to terminate.

One output: summary, a STRING you can display or log.

Install

cd ComfyUI/custom_nodes
git clone https://github.com/TensorVizion/OmniNodes

Restart ComfyUI; find Workflow End 🏁 under TensorVizion/Workflow. No extra dependencies.

Where people get burned

  • Connecting a branch forces it to run. That's the point, but it's also the trap: wire an expensive branch you didn't mean to commit to into this node, and it will run every time. The four sockets are "guarantee these execute," not "collect these values."
  • The .done file only means the node ran. If your downstream save is on a branch that doesn't reach this node, a .done file can appear before the render is actually on disk. Order matters - put this node downstream of your saves.
  • It's not a bypass or a stop node. ComfyUI already ran everything else when it runs this; nothing here cancels work in flight.

For one-off interactive use it's arguably unnecessary. Where it earns its keep is batch and automation land: a batch_7.done file your script can stat is a much more robust completion signal than parsing console output.

CategoryTensorVizion/Workflow

Inputs (7)

NameTypeDefaultDescription
run_labelSTRINGworkflowβ€”
write_logBOOLEANtrueβ€”
write_done_markerBOOLEANfalseβ€”
input_1opt*β€”
input_2opt*β€”
input_3opt*β€”
input_4opt*β€”

Outputs (1)

NameTypeDescription
summarySTRINGβ€”