{"record":{"id":"e272c2bfdcd94f8c","repo":"affaan-m/ECC","slug":"views-must-include-input-image-url-the-front-view-e272c2","errorCode":null,"errorMessage":"views must include 'input_image_url' (the front view)","messagePattern":"views must include 'input_image_url' \\(the front view\\)","errorType":"validation","errorClass":"FalError","httpStatus":null,"severity":"error","filePath":"skills/taste-distillation/scripts/taste/falapi.py","lineNumber":512,"sourceCode":"    ``{\"input_image_url\": front, \"back_image_url\": back}``. Passing a bare\n    list assigns images to :data:`VIEW_FIELDS` in order, which is a guess and\n    is only correct if the caller actually sorted them that way; a wrong angle\n    label is worse than omitting the view entirely, because the model trusts\n    it. When in doubt, send one image.\n\n    ``pbr`` requests physically-based maps (metallic, roughness, normal). Without\n    them the mesh lights like painted cardboard in Blender, which defeats the\n    point of minting it. It is ignored when ``geometry_only`` is set.\n\n    Note the endpoint's own input guidance: simple background, single object,\n    object filling >50% of frame. Busy reference stills - collages, wide shots,\n    anything with several subjects - produce garbage meshes. Generate a clean\n    single-object plate first if the pack's stills are not that.\n    \"\"\"\n    if views:\n        payload: dict = {k: v for k, v in views.items() if k in VIEW_FIELDS and v}\n        if \"input_image_url\" not in payload:\n            raise FalError(\"views must include 'input_image_url' (the front view)\")\n    else:\n        urls = [image_url] if isinstance(image_url, str) else list(image_url)\n        if not urls:\n            raise FalError(\"image_to_3d needs at least one image\")\n        payload = {f: u for f, u in zip(VIEW_FIELDS, urls[:len(VIEW_FIELDS)])}\n\n    payload[\"generate_type\"] = \"Geometry\" if geometry_only else \"Normal\"\n    if not geometry_only:\n        payload[\"enable_pbr\"] = bool(pbr)\n    if face_count:\n        # Endpoint range is 40k-1.5M; clamp rather than let it 422.\n        payload[\"face_count\"] = int(max(40_000, min(1_500_000, face_count)))\n\n    result = submit(ENDPOINTS[\"image_to_3d\"], payload, timeout)\n    return _mesh_url(result, ENDPOINTS[\"image_to_3d\"])\n\n\ndef text_to_3d(prompt: str, *, pbr: bool = True, timeout: int = 900) -> str:","sourceCodeStart":494,"sourceCodeEnd":530,"githubUrl":"https://github.com/affaan-m/ECC/blob/8321021c54d670126ce3b2969d5deb880b4b0c2a/skills/taste-distillation/scripts/taste/falapi.py#L494-L530","documentation":"FalError raised by image_to_3d() when a `views` dict is supplied but filtered to no 'input_image_url' entry — the front-view image is mandatory for multi-view 3D generation. Non-VIEW_FIELDS keys and empty values are stripped before the check.","triggerScenarios":"image_to_3d(image_url=..., views={...}) where views contains only back/left/right keys, or where the input_image_url value is empty/None so it is filtered out before validation.","commonSituations":"Caller builds the views dict from per-angle URLs and the front image failed to upload; dict keys misspelled (e.g. 'front_image_url'); empty-string URL passed through.","solutions":["Include 'input_image_url' pointing at the front-view image URL in the views dict","Check the key spelling and that the value is a non-empty URL string","If the front view upload failed, re-upload it via falapi.upload() before calling","If you only have one image, pass it via image_url and omit views"],"exampleFix":"// before\nfalapi.image_to_3d(views={\"back_image_url\": back})  # FalError\n// after\nfalapi.image_to_3d(views={\"input_image_url\": front, \"back_image_url\": back})","handlingStrategy":"validation","validationCode":"def validate_views(views: dict) -> bool:\n    return bool(views) is False or bool(views.get(\"input_image_url\"))","typeGuard":null,"tryCatchPattern":"try:\n    mesh = falapi.image_to_3d(image_url=fallback, views=views)\nexcept falapi.FalError as e:\n    if \"input_image_url\" in str(e):\n        print(\"views dict must contain a non-empty 'input_image_url'\")","preventionTips":["Always populate views['input_image_url'] with the front view before calling","Check spelling of view keys against VIEW_FIELDS","Verify the front-view upload succeeded before building the views dict","Use empty strings/None filtering awareness: empty values are stripped then validated"],"tags":["python","validation","argument"],"backgroundTag":"missing-required-argument","analyzedSha":"8321021c54d670126ce3b2969d5deb880b4b0c2a","analyzedAt":"2026-09-16T10:08:13.343Z","contentChangedAt":"2026-09-16T10:08:13.343Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}