{"record":{"id":"993bb79317d46000","repo":"calesthio/OpenMontage","slug":"unsupported-local-label-format-expected-one-of","errorCode":null,"errorMessage":"unsupported local {label} format; expected one of {formats}","messagePattern":"unsupported local (.+?) format; expected one of (.+?)","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"tools/video/seedance_ark.py","lineNumber":1041,"sourceCode":"        path = Path(value).expanduser()\n        if not path.is_file():\n            raise ValueError(\n                f\"{label} reference must be a public URL, asset:// ID, \"\n                f\"or existing local file: {value}\"\n            )\n        size = path.stat().st_size\n        if size >= max_bytes:\n            raise ValueError(\n                f\"local {label} must be smaller than {max_bytes // (1024 * 1024)} MB\"\n            )\n        suffix = path.suffix.lower()\n        mime = suffix_to_mime.get(suffix)\n        if not mime:\n            guessed, _ = mimetypes.guess_type(path.name)\n            mime = guessed if guessed in suffix_to_mime.values() else None\n        if not mime:\n            formats = \", \".join(sorted(suffix_to_mime))\n            raise ValueError(\n                f\"unsupported local {label} format; expected one of {formats}\"\n            )\n        if label == \"image\":\n            self._validate_local_image(path)\n        elif label == \"audio\":\n            self._probe_local_audio_duration(path)\n        encoded = base64.b64encode(path.read_bytes()).decode(\"ascii\")\n        return f\"data:{mime};base64,{encoded}\"\n\n    def _validate_local_image(self, path: Path) -> None:\n        self._validate_image_bytes(path.read_bytes(), str(path))\n\n    @staticmethod\n    def _validate_image_bytes(data: bytes, source: str) -> None:\n        try:\n            from PIL import Image\n\n            with Image.open(io.BytesIO(data)) as image:","sourceCodeStart":1023,"sourceCodeEnd":1059,"githubUrl":"https://github.com/calesthio/OpenMontage/blob/95e1c3d0ab93482159818560f6a8c8e866b9139f/tools/video/seedance_ark.py#L1023-L1059","documentation":"Error \"unsupported local {label} format; expected one of {formats}\" thrown in calesthio/OpenMontage.","triggerScenarios":"A local reference file has an extension/format outside the supported set for its media label.","commonSituations":"See trigger scenarios.","solutions":["Convert the file to one of the listed supported formats before submitting.","Check the actual file type with `file <path>` — the extension may not match the real content."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"95e1c3d0ab93482159818560f6a8c8e866b9139f","analyzedAt":"2026-08-15T06:31:20.014Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}