{"record":{"id":"0cf8026966522ec4","repo":"invoke-ai/InvokeAI","slug":"source-no-downloadable-files-found","errorCode":null,"errorMessage":"{source}: No downloadable files found","messagePattern":"(.+?): No downloadable files found","errorType":"exception","errorClass":"ValueError","httpStatus":400,"severity":"error","filePath":"invokeai/app/services/model_install/model_install_default.py","lineNumber":1279,"sourceCode":"        config: Optional[ModelRecordChanges] = None,\n    ) -> ModelInstallJob:\n        return ModelInstallJob(\n            id=self._next_id(),\n            source=source,\n            config_in=config or ModelRecordChanges(),\n            local_path=self._app_config.models_path,\n            inplace=True,\n        )\n\n    def _import_remote_model(\n        self,\n        source: HFModelSource | URLModelSource,\n        remote_files: List[RemoteModelFile],\n        metadata: Optional[AnyModelRepoMetadata],\n        config: Optional[ModelRecordChanges],\n    ) -> ModelInstallJob:\n        if len(remote_files) == 0:\n            raise ValueError(f\"{source}: No downloadable files found\")\n        destdir = self._find_reusable_tmpdir(source)\n        if destdir is None:\n            destdir = Path(\n                mkdtemp(\n                    dir=self._app_config.models_path,\n                    prefix=TMPDIR_PREFIX,\n                )\n            )\n        install_job = ModelInstallJob(\n            id=self._next_id(),\n            source=source,\n            config_in=config or ModelRecordChanges(),\n            source_metadata=metadata,\n            local_path=destdir,  # local path may change once the download has started due to content-disposition handling\n            bytes=0,\n            total_bytes=0,\n        )\n        # remember the temporary directory for later removal","sourceCodeStart":1261,"sourceCodeEnd":1297,"githubUrl":"https://github.com/invoke-ai/InvokeAI/blob/0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06/invokeai/app/services/model_install/model_install_default.py#L1261-L1297","documentation":"_import_remote_model() creates the install job for a remote source (HF repo or URL) after files were resolved. If the resolved remote_files list is empty, it raises ValueError('{source}: No downloadable files found'). Unlike error 715 (raised during file resolution), this fires when resolution nominally succeeded but produced zero files.","triggerScenarios":"Metadata/download-URL resolution returned an empty list that passed through _remote_files_from_source without raising; an HF repo with no weight files matching the requested variant/path filters; a URL source whose metadata yields no files.","commonSituations":"Gated or empty HF repos; requesting a variant (e.g. 'fp16') that doesn't exist for the repo; repos containing only non-weight files filtered out by the download URL matcher; deleted repos cached as metadata-only.","solutions":["Verify the repo/URL contains downloadable weight files and relax variant/subfolder/path filters on the source.","Clear stale metadata for the repo so download URLs are re-resolved.","Use a direct file URL via URLModelSource pointing at the exact weights file.","Check HF authentication for gated repos and confirm repo id spelling (owner/name)."],"exampleFix":"// before\nservice.download_and_cache_model(HFModelSource(repo_id='author/repo', variant='nonexistent'))\n// after\nservice.download_and_cache_model(HFModelSource(repo_id='author/repo'))  # valid variant or no filter, and repo has weights","handlingStrategy":"validation","validationCode":"import requests\ninfo = requests.get(f'https://huggingface.co/api/models/{repo_id}', timeout=10).json()\nweight_files = [s for s in info.get('siblings', []) if not s['rfilename'].endswith(('.md', '.gitattributes'))]\nassert weight_files, f'{repo_id} has no downloadable weight files'","typeGuard":"def source_has_files(source) -> bool:\n    try:\n        return len(service._remote_files_from_source(source)) > 0\n    except Exception:\n        return False","tryCatchPattern":"try:\n    service.download_and_cache_model(source)\nexcept ValueError as e:\n    if 'No downloadable files found' in str(e):\n        logger.error('Source %s has no files; check variant/subfolder or use a direct file URL', source)","preventionTips":["Confirm the repo has weight files before installing.","Avoid nonexistent variant/subfolder values in HFModelSource.","Use direct file URLs for single-file downloads.","Refresh/clear stale metadata so download URLs are re-resolved."],"tags":["download","huggingface","validation"],"backgroundTag":"no-downloadable-files-found","analyzedSha":"0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06","analyzedAt":"2026-08-29T04:46:49.967Z","schemaVersion":2},"datasetVersion":"2026-08-29T07:17:48.351Z"}