Comfy-Org/ComfyUI · warning · ValueError
Currently only one last frame image is supported.
Error message
Currently only one last frame image is supported.
What it means
Client-side ValueError in the v2.5 LTX image-to-video node: the optional last_frame input, when connected, must also contain exactly one image. Raised only when last_frame is not None and its image count != 1.
Source
Thrown at comfy_api_nodes/nodes_ltxv.py:484
)
@classmethod
async def execute(
cls,
image: Input.Image,
model: dict,
prompt: str,
seed: int = 42,
last_frame: Input.Image | None = None,
) -> IO.NodeOutput:
validate_string(prompt, min_length=1, max_length=10000)
_v25_validate_settings(model)
if get_number_of_images(image) != 1:
raise ValueError("Currently only one input image is supported.")
last_frame_uri = None
if last_frame is not None:
if get_number_of_images(last_frame) != 1:
raise ValueError("Currently only one last frame image is supported.")
last_frame_uri = (await upload_images_to_comfyapi(cls, last_frame, max_images=1, mime_type="image/png"))[0]
return await _v25_submit_and_poll(
cls,
"image-to-video",
ExecuteTaskRequest(
image_uri=(await upload_images_to_comfyapi(cls, image, max_images=1, mime_type="image/png"))[0],
last_frame_uri=last_frame_uri,
prompt=prompt,
model=V25_MODELS_MAP[model["model"]],
duration=int(model["duration"]),
resolution=model["resolution"],
fps=int(model["fps"]),
generate_audio=model["generate_audio"],
),
)
class Ltx25AudioToVideoNode(IO.ComfyNode):View on GitHub (pinned to 1c6d8d45b3)
Solutions
- Reduce the last_frame input to a single image (batch 1 or pick one frame).
- If last frame isn't needed, disconnect the input entirely — it is optional.
- Use the same single-image discipline for both image and last_frame inputs.
Defensive patterns
Strategy: validation
Validate before calling
if last_frame is not None:
assert last_frame.shape[0] == 1, "last_frame must be a single image" Type guard
def is_single_image(t: torch.Tensor | None) -> bool:
return t is None or t.shape[0] == 1 Prevention
- Load the end frame as a single image, mirroring the start frame.
- Disconnect last_frame when not doing first/last-frame generation.
When it happens
Trigger: Connecting a batched or empty IMAGE tensor to the last_frame input of the v2.5 image-to-video node — e.g. both start and end frames loaded as batches, or last_frame sourced from a video frame stack.
Common situations: First/last-frame workflows where both endpoints come from batch loaders; last frame from a decoded video where the whole stack is connected instead of one frame.
Related errors
- Currently only one input image is supported.
- Durations over 10s require a 720p or 1080p resolution and 24
- Durations over 10s are only available for the Fast model at
- Audio duration must be between 2 and 20 seconds, got {audio_
- Total storyboard duration ({duration}s) must be between 3 an
AI-assisted analysis of Comfy-Org/ComfyUI@1c6d8d45b3 (2026-08-14).
Data as JSON: /api/errors/385a26ab5b86a728.
Report an issue: GitHub.