{"record":{"id":"c78899679ccfb904","repo":"perspective-dev/perspective","slug":"docs-corpus-file-missing-skipping-api-chunks","errorCode":null,"errorMessage":"docs corpus: ${file} missing, skipping API chunks","messagePattern":"docs corpus: (.+?) missing, skipping API chunks","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"rust/perspective-viewer/tools.mjs","lineNumber":326,"sourceCode":"    const chunks = [];\n    const md_files = [\n        ...DOCS_MD_ROOTS.filter(fs.existsSync).flatMap((x) => [\n            ...walkMarkdown(x),\n        ]),\n        ...DOCS_MD_FILES.filter(fs.existsSync),\n    ];\n\n    for (const file of md_files) {\n        chunks.push(...chunkMarkdown(file, fs.readFileSync(file, \"utf8\")));\n    }\n\n    for (const [file, prefix] of DOCS_DTS_FILES) {\n        if (fs.existsSync(file)) {\n            chunks.push(\n                ...chunkDts(file, fs.readFileSync(file, \"utf8\"), prefix),\n            );\n        } else {\n            console.warn(`docs corpus: ${file} missing, skipping API chunks`);\n        }\n    }\n\n    const corpus = normalizeChunks(chunks);\n    const bundle = { schemas: await buildToolSchemas(), chunks: corpus };\n    const json = JSON.stringify(bundle);\n    if (json.length > DOCS_RAW_BUDGET) {\n        console.warn(\n            `docs corpus: ${json.length} bytes exceeds the ${DOCS_RAW_BUDGET} raw budget - consider pruning the manifest`,\n        );\n    }\n\n    fs.mkdirSync(\"dist/docs\", { recursive: true });\n    fs.writeFileSync(\"dist/docs/perspective-docs.json\", json);\n    return {\n        chunks: corpus.length,\n        bytes: json.length,\n        files: md_files.length,","sourceCodeStart":308,"sourceCodeEnd":344,"githubUrl":"https://github.com/perspective-dev/perspective/blob/11c8238c0c9c0b9e490b5a6a2dc277afad1e980a/rust/perspective-viewer/tools.mjs#L308-L344","documentation":"Warning in the docs-corpus builder: a .d.ts file listed in DOCS_DTS_FILES is missing, so its API reference chunks are omitted from the corpus. The docs build continues with reduced API coverage; this indicates generated type definitions weren't built yet or a stale manifest entry.","triggerScenarios":"Thrown at rust/perspective-viewer/tools.mjs:326 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Build the missing .d.ts artifacts before running buildDocsCorpus","Update DOCS_DTS_FILES if the file was renamed or removed","Check earlier build steps for silent failures that skipped type generation","Accept the warning for partial docs when the file is intentionally absent"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"11c8238c0c9c0b9e490b5a6a2dc277afad1e980a","analyzedAt":"2026-09-09T00:35:19.377Z","contentChangedAt":"2026-09-09T00:35:19.377Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}