Nodes/ComfyUI-LegionPower/Legion: Warmupper
ComfyUI Node

Legion: Warmupper

Pre-boot a worker so your first run isn't the slow one

By Transhumai·Created 10 months ago·Updated 9 months ago· 1
Legion: Warmupper
  • legion_config
  • legion_campaign

LegionWarmup does one thing: it starts a Legion worker ComfyUI process without running any workflow, then hands you the live legion_campaign handle. It exists to kill the worst part of this pack - the cold-start wait.

The first run of a Legion Master can take a while. It has to boot an entire second ComfyUI instance, import all the custom nodes, and only then start your job. With heavy nodes loaded, that's real wall-clock cost on top of the job itself. Warmup moves that cost off the critical path: fire the Warmupper earlier in your graph (or in a quick run by itself), keep the returned campaign around, and pass it into a Master's legion_campaign input later. The Master reuses the already-running worker and skips straight to execution.

How it works

The node is a thin wrapper over the Master's internals. It calls the same "ensure worker is alive" logic with just_warmup=True, so it validates the config, picks or assigns a port, spawns the worker if needed, waits for it to come online, and returns just the campaign. No serialization, no workflow submission - nothing else happens.

Inputs and outputs

  • legion_config (required, type LEGION_CONFIG) - from Legion: Configuration. It has to be a full, valid config; a worker won't warm up from nothing.
  • legion_campaign (output) - the warmed-up handle. Wire it into a Master's legion_campaign input.

Installing

Same as everything else in the pack: ComfyUI Manager search "LegionPower", or clone into custom_nodes:

cd ComfyUI/custom_nodes
git clone https://github.com/Transhumai/ComfyUI-LegionPower.git
cd ComfyUI-LegionPower
pip install -r requirements.txt

Restart. Only requests; no models to download.

Notes and caveats

  • Warmup doesn't change the pack's data-type limits - it's purely about process startup.
  • Workers stay alive for reuse, so once warmed they persist across runs until you change the config or restart ComfyUI. Warmup is a convenience, not a requirement; a Master will cold-start a worker on its own if none exists.
  • If the worker fails to start, the Warmupper errors with the same failed to start in time message as the Master, so troubleshooting is identical: port in use, wrong ComfyUI path, or bad extra_args/env_vars.

Optional node, but if you're repeatedly running a long post-processing worker, it's the difference between a 30-second stall and none.

CategoryLegion

Inputs (1)

NameTypeDefaultDescription
legion_configLEGION_CONFIG

Outputs (1)

NameTypeDescription
legion_campaignLEGION_CAMPAIGN