Comfy-Org/ComfyUI · error · Exception
Kling task {response.data.task_id} succeeded but no video da
Error message
Kling task {response.data.task_id} succeeded but no video data found in response. What it means
Raised by validate_video_result_response after a Kling video task reported success but the response contains no playable video in task_result.videos. The task lifecycle completed (polled to a terminal state), yet the result payload is missing the video entry — an upstream data inconsistency, and the response.data.task_id is embedded in the message.
Source
Thrown at comfy_api_nodes/nodes_kling.py:307
f"Negative prompt is too long: {len(negative_prompt)} characters"
)
return True
def validate_task_creation_response(response) -> None:
"""Validates that the Kling task creation request was successful."""
if not is_valid_task_creation_response(response):
error_msg = f"Kling initial request failed. Code: {response.code}, Message: {response.message}, Data: {response.data}"
logging.error(error_msg)
raise Exception(error_msg)
def validate_video_result_response(response) -> None:
"""Validates that the Kling task result contains a video."""
if not is_valid_video_response(response):
error_msg = f"Kling task {response.data.task_id} succeeded but no video data found in response."
logging.error("Error: %s.\nResponse: %s", error_msg, response)
raise Exception(error_msg)
def validate_image_result_response(response) -> None:
"""Validates that the Kling task result contains an image."""
if not is_valid_image_response(response):
error_msg = f"Kling task {response.data.task_id} succeeded but no image data found in response."
logging.error("Error: %s.\nResponse: %s", error_msg, response)
raise Exception(error_msg)
def validate_input_image(image: torch.Tensor) -> None:
"""
Validates the input image adheres to the expectations of the Kling API:
- The image resolution should not be less than 300*300px
- The aspect ratio of the image should be between 1:2.5 ~ 2.5:1
See: https://app.klingai.com/global/dev/document-api/apiReference/model/imageToVideo
"""View on GitHub (pinned to 1c6d8d45b3)
Solutions
- Re-run the Kling video node to create a fresh task
- Record the task_id from the message and check it in the Kling developer console
- If persistent across prompts, check Kling status pages or API changelog for result-schema changes
- Reduce requested duration/resolution to shorten generation time and avoid artifact expiry
Defensive patterns
Strategy: retry
Try / catch
for attempt in range(2):
try:
out = await kling_video_node(...)
break
except Exception as e:
if attempt == 1 or "no video data found" not in str(e):
raise Prevention
- Re-submit the task on this inconsistency; it is usually not input-related
- Keep the task_id from the message for console follow-up
- Avoid extremely long generations that outlive result storage
When it happens
Trigger: Kling marks a video task as succeeded but returns task_result without videos (or videos empty) — server-side rendering pipeline failure, expired result storage, or a schema change in the result payload.
Common situations: Long video jobs whose artifacts expire before retrieval; Kling infra incidents; very rare and usually resolved by re-submitting the task.
Related errors
- Kling task {response.data.task_id} succeeded but no image da
- Kling request failed. Code: {response.code}, Message: {respo
- Gemini did not generate a video. Model response: {model_mess
- Gemini did not generate a video. Try rephrasing your prompt,
- Gemini interaction did not complete (status: {interaction.st
AI-assisted analysis of Comfy-Org/ComfyUI@1c6d8d45b3 (2026-08-14).
Data as JSON: /api/errors/4bda99cd22e7f762.
Report an issue: GitHub.