{"record":{"id":"7408b3c584def0ae","repo":"Comfy-Org/ComfyUI","slug":"astra-2-is-limited-to-ast2-max-frames-input-fram","errorCode":null,"errorMessage":"Astra 2 is limited to {AST2_MAX_FRAMES} input frames; video has {n_frames}.","messagePattern":"Astra 2 is limited to (.+?) input frames; video has (.+?)\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"comfy_api_nodes/nodes_topaz.py","lineNumber":1065,"sourceCode":"            model_id = UPSCALER_MODELS_MAP[upscaler_choice]\n            if model_id == \"slc-1\":\n                filters.append(\n                    VideoEnhancementFilter(\n                        model=model_id,\n                        creativity=upscaler_model[\"creativity\"],\n                        isOptimizedMode=True,\n                    )\n                )\n            elif model_id == \"ast-2\":\n                n_frames = video.get_frame_count()\n                ast2_prompt = (upscaler_model[\"prompt\"] or \"\").strip()\n                if ast2_prompt and n_frames > AST2_MAX_FRAMES_WITH_PROMPT:\n                    raise ValueError(\n                        f\"Astra 2 with a prompt is limited to {AST2_MAX_FRAMES_WITH_PROMPT} input frames \"\n                        f\"(~15s @ 30fps); video has {n_frames}. Clear the prompt or shorten the clip.\"\n                    )\n                if n_frames > AST2_MAX_FRAMES:\n                    raise ValueError(f\"Astra 2 is limited to {AST2_MAX_FRAMES} input frames; video has {n_frames}.\")\n                realism = upscaler_model[\"realism\"]\n                filters.append(\n                    VideoEnhancementFilter(\n                        model=model_id,\n                        creativity=upscaler_model[\"creativity\"],\n                        prompt=(ast2_prompt or None),\n                        sharp=upscaler_model[\"sharp\"],\n                        realism=(realism if realism > 0 else None),\n                    )\n                )\n            else:\n                filters.append(VideoEnhancementFilter(model=model_id))\n        if interpolation_choice != \"Disabled\":\n            target_frame_rate = interpolation_model[\"interpolation_frame_rate\"]\n            filters.append(\n                VideoFrameInterpolationFilter(\n                    model=interpolation_choice,\n                    slowmo=interpolation_model[\"interpolation_slowmo\"],","sourceCodeStart":1047,"sourceCodeEnd":1083,"githubUrl":"https://github.com/Comfy-Org/ComfyUI/blob/1c6d8d45b3693bfbb32385b410d813a7fd6be216/comfy_api_nodes/nodes_topaz.py#L1047-L1083","documentation":"Topaz Astra 2 has a hard input frame cap (AST2_MAX_FRAMES) even without a prompt. The V2 video enhance execute calls video.get_frame_count() and raises ValueError when the count exceeds the constant, before any upload happens. This mirrors the provider-side model limit.","triggerScenarios":"ast-2 selected as the upscaler model with a video longer than AST2_MAX_FRAMES (with an empty prompt).","commonSituations":"Enhancing minute-plus footage with Astra 2; 60 fps clips hitting the frame cap in half the wall-clock time expected; users who assume the limit is duration-based rather than frame-based.","solutions":["Trim or split the video so frame count <= AST2_MAX_FRAMES (remember: 60 fps hits the cap in half the seconds).","Switch to a model without the frame cap (e.g. slc-1 or the default models) for long-form content.","Reduce source frame rate before the node if the content allows it."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if upscaler_model[\"upscaler_model\"] == \"ast-2\" and video.get_frame_count() > AST2_MAX_FRAMES:\n    raise ValueError(\"clip too long for ast-2; split it or pick another model\")","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Segment footage before Astra 2 jobs; frame count is the unit, not duration.","Remember high-fps sources consume the frame budget faster."],"tags":["topaz","video","frame-limit","astra-2","validation"],"backgroundTag":null,"analyzedSha":"1c6d8d45b3693bfbb32385b410d813a7fd6be216","analyzedAt":"2026-08-14T19:37:18.893Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}