{"record":{"id":"9b6eeacc86ba15f3","repo":"paperclipai/paperclip","slug":"catalog-asset-previews-are-not-supported","errorCode":null,"errorMessage":"Catalog asset previews are not supported.","messagePattern":"Catalog asset previews are not supported\\.","errorType":"http","errorClass":"HttpError","httpStatus":415,"severity":"error","filePath":"server/src/services/skills-catalog.ts","lineNumber":324,"sourceCode":"  if (!result.skill) {\n    throw notFound(\"Catalog skill not found\");\n  }\n  return result.skill;\n}\n\nexport async function readCatalogSkillFile(\n  reference: string,\n  relativePath = \"SKILL.md\",\n): Promise<CatalogSkillFileDetail> {\n  const skill = getCatalogSkillOrThrow(reference);\n  const normalizedPath = normalizePortablePath(relativePath || \"SKILL.md\");\n  const fileEntry = skill.files.find((entry) => entry.path === normalizedPath);\n  if (!fileEntry) {\n    throw notFound(\"Catalog skill file not found\");\n  }\n\n  if (fileEntry.kind === \"asset\") {\n    throw new HttpError(415, \"Catalog asset previews are not supported.\");\n  }\n\n  const content = (await readCatalogFileBytes(skill, normalizedPath)).toString(\"utf8\");\n  return {\n    catalogSkillId: skill.id,\n    path: normalizedPath,\n    kind: fileEntry.kind,\n    content,\n    language: inferLanguageFromPath(normalizedPath),\n    markdown: isMarkdownPath(normalizedPath),\n  };\n}\n\nexport async function copyCatalogSkillFile(reference: string, relativePath: string, targetPath: string): Promise<void> {\n  const skill = getCatalogSkillOrThrow(reference);\n  const normalizedPath = normalizePortablePath(relativePath || \"SKILL.md\");\n  const fileEntry = skill.files.find((entry) => entry.path === normalizedPath);\n  if (!fileEntry) {","sourceCodeStart":306,"sourceCodeEnd":342,"githubUrl":"https://github.com/paperclipai/paperclip/blob/120ae5428fa29bee300bcf806491cd4d965fbb7c/server/src/services/skills-catalog.ts#L306-L342","documentation":"Content-type guard in readCatalogSkillFile: the requested file's manifest entry has kind asset, and only text files (e.g. SKILL.md) can be served inline as content. Asset previews (images, binaries) are unsupported by this endpoint; the asset file path requested is at fault.","triggerScenarios":"Thrown at server/src/services/skills-catalog.ts:324 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Catalog asset previews are not implemented; fetch the asset content directly instead of requesting a preview."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"120ae5428fa29bee300bcf806491cd4d965fbb7c","analyzedAt":"2026-08-18T22:49:45.177Z","contentChangedAt":"2026-08-18T22:49:45.177Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}