{"record":{"id":"06cc5783b3ac9e4c","repo":"github/spec-kit","slug":"catalog-url-must-be-non-empty","errorCode":null,"errorMessage":"Catalog URL must be non-empty.","messagePattern":"Catalog URL must be non-empty\\.","errorType":"validation","errorClass":"IntegrationValidationError","httpStatus":null,"severity":"error","filePath":"src/specify_cli/integrations/catalog.py","lineNumber":404,"sourceCode":"                \"priority\": e.priority,\n                \"install_allowed\": e.install_allowed,\n                \"description\": e.description,\n            }\n            for e in entries\n        ]\n\n    def add_catalog(self, url: str, name: Optional[str] = None) -> None:\n        \"\"\"Add a catalog source to the project-level config file.\n\n        The URL is normalized (whitespace stripped) and validated before being\n        written. Duplicate URLs are rejected, including near-duplicates that\n        differ only by surrounding whitespace. Priority is derived as\n        ``max(existing) + 1`` so the new entry sorts last in the resolution\n        order unless the user edits the file manually.\n        \"\"\"\n        url = url.strip()\n        if not url:\n            raise IntegrationValidationError(\"Catalog URL must be non-empty.\")\n        self._validate_catalog_url(url)\n        config_path = self.project_root / \".specify\" / self.CONFIG_FILENAME\n\n        data: Dict[str, Any] = {\"catalogs\": []}\n        if config_path.exists():\n            try:\n                raw = yaml.safe_load(config_path.read_text(encoding=\"utf-8\"))\n            except (yaml.YAMLError, OSError, UnicodeError) as exc:\n                raise IntegrationValidationError(\n                    f\"Failed to read catalog config {config_path}: {exc}\"\n                ) from exc\n            if raw is None:\n                raw = {}\n            if not isinstance(raw, dict):\n                raise IntegrationValidationError(\n                    f\"Catalog config file {config_path} is corrupted \"\n                    \"(expected a mapping).\"\n                )","sourceCodeStart":386,"sourceCodeEnd":422,"githubUrl":"https://github.com/github/spec-kit/blob/bf88c9f9a82fa370c7a7257aa2b3cf10b457b65c/src/specify_cli/integrations/catalog.py#L386-L422","documentation":"Error \"Catalog URL must be non-empty.\" thrown in github/spec-kit.","triggerScenarios":"Thrown at src/specify_cli/integrations/catalog.py:404 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Provide a non-empty catalog URL when adding a catalog."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"bf88c9f9a82fa370c7a7257aa2b3cf10b457b65c","analyzedAt":"2026-08-14T19:43:37.150Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}