Comfy-Org/ComfyUI · warning · ValueError
At least one input image is required
Error message
At least one input image is required
What it means
Raised at the top of the GLSL render node's execute() when, after filtering the optional Autogrow image inputs for non-None values, none remain. The shader pipeline needs at least one input texture (both as the sizing reference for 'match first input' mode and as the batch dimension source), so an empty image set is rejected before any GL work starts.
Source
Thrown at comfy_extras/nodes_glsl.py:773
images: io.Autogrow.Type,
floats: io.Autogrow.Type = None,
ints: io.Autogrow.Type = None,
bools: io.Autogrow.Type = None,
curves: io.Autogrow.Type = None,
**kwargs,
) -> io.NodeOutput:
image_list = [v for v in images.values() if v is not None]
float_list = (
[v if v is not None else 0.0 for v in floats.values()] if floats else []
)
int_list = [v if v is not None else 0 for v in ints.values()] if ints else []
bool_list = [v if v is not None else False for v in bools.values()] if bools else []
curve_luts = [v.to_lut().astype(np.float32) for v in curves.values() if v is not None] if curves else []
if not image_list:
raise ValueError("At least one input image is required")
# Determine output dimensions
if size_mode["size_mode"] == "custom":
out_width = size_mode["width"]
out_height = size_mode["height"]
else:
out_height, out_width = image_list[0].shape[1:3]
batch_size = image_list[0].shape[0]
# Prepare batches
image_batches = []
for batch_idx in range(batch_size):
batch_images = [img_tensor[batch_idx].cpu().numpy().astype(np.float32) for img_tensor in image_list]
image_batches.append(batch_images)
all_batch_outputs = _render_shader_batch(
fragment_shader,View on GitHub (pinned to 1c6d8d45b3)
Solutions
- Connect at least one image output (e.g. LoadImage or EmptyLatentImage-derived image) to one of the node's image inputs.
- If the upstream node can legitimately emit nothing, feed a small placeholder image (a 64x64 black tensor via an empty-image node) to satisfy the requirement.
- Check that an upstream switch node actually selected the branch that produces the image.
Defensive patterns
Strategy: validation
Validate before calling
images = {k: v for k, v in image_inputs.items() if v is not None}
if not images:
raise ValueError("Connect at least one image input to the GLSL node before running") Prevention
- Always connect one image input, even a small placeholder, before executing.
- Mute/bypass the GLSL node while building the workflow.
- Check upstream switch nodes actually emit an image on the selected branch.
When it happens
Trigger: Executing the GLSL node with all image inputs unconnected, or with every connected wire carrying None (e.g. upstream optional outputs that produced nothing); using size_mode 'custom' thinking no image is needed — the check fires regardless.
Common situations: Wiring the node up while building a workflow and pressing Run early; a switch/mux node upstream returning None on the selected branch.
Related errors
- Need at least {require_count} hooks to combine, but only had
- INVALID_TAG_FILTER
- UNSUPPORTED_MEDIA_TYPE
- INVALID_BODY
- INVALID_HASH
AI-assisted analysis of Comfy-Org/ComfyUI@1c6d8d45b3 (2026-08-14).
Data as JSON: /api/errors/1e79040479113173.
Report an issue: GitHub.