{"record":{"id":"7cffaeaae94522f4","repo":"abhigyanpatwari/GitNexus","slug":"unsupported-analyzer-build-entry-absolutepath","errorCode":null,"errorMessage":"Unsupported analyzer build entry: ${absolutePath}","messagePattern":"Unsupported analyzer build entry: (.+?)","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"gitnexus/src/core/analyzer-identity.ts","lineNumber":783,"sourceCode":"          state: statState(link),\n        });\n        if (depth >= limits.buildDepth) {\n          throw new Error(\n            `Analyzer build scan exceeded depth ${limits.buildDepth}: ${absolutePath}`,\n          );\n        }\n        pending.push({ absoluteDir: absolutePath, depth: depth + 1 });\n      } else if (link.isFile()) {\n        const state = statState(link);\n        scannedBytes += stateSize(state, absolutePath);\n        if (scannedBytes > limits.buildBytes) {\n          throw new Error(`Analyzer build scan exceeded ${limits.buildBytes} bytes: ${buildRoot}`);\n        }\n        entries.push({ absolutePath, relativePath, kind: 'file', state });\n      } else if (link.isSymbolicLink()) {\n        entries.push({ absolutePath, relativePath, kind: 'symlink', state: statState(link) });\n      } else {\n        throw new Error(`Unsupported analyzer build entry: ${absolutePath}`);\n      }\n    }\n  }\n  entries.sort((a, b) => compareBytes(a.relativePath, b.relativePath));\n  return entries;\n}\n\nfunction buildSnapshot(entries: readonly BuildEntry[]): Array<{\n  relativePath: string;\n  kind: BuildEntry['kind'];\n  state: StatState;\n}> {\n  return entries.map(({ relativePath, kind, state }) => ({ relativePath, kind, state }));\n}\n\nfunction buildCacheKey(entry: Pick<BuildEntry, 'relativePath' | 'kind'>): string {\n  return JSON.stringify([entry.kind, entry.relativePath]);\n}","sourceCodeStart":765,"sourceCodeEnd":801,"githubUrl":"https://github.com/abhigyanpatwari/GitNexus/blob/aac7515d2a8c50a1f8f923c6fb77218b333560d6/gitnexus/src/core/analyzer-identity.ts#L765-L801","documentation":"collectBuildEntries classifies every build-tree entry via lstat into directory, regular file, or symbolic link; anything else — FIFO/named pipe, unix socket, character/block device — hits the else branch and throws. The receipt schema simply has no representation for such nodes, and hashing them would be meaningless, so their presence is treated as a corrupt or polluted build tree.","triggerScenarios":"A stray 'mkfifo' pipe, a lingering socket file left by a dev server or database, or a device node inside the analyzer's dist/src directory when resolveAnalyzerRunnerIdentity scans it. Common after running tools that create lock/IPC files with unusual types inside the build output.","commonSituations":"A dev server crashed and left a .sock file in the build dir; someone created a named pipe for log tailing inside dist/; containerized builds that materialize device-like special files into the output layer.","solutions":["Locate special files: 'find dist -type p -o -type s -o -type b -o -type c' (POSIX) and delete the offenders.","Reconfigure the tool that created the socket/pipe to place IPC files outside the build tree (e.g. /tmp).","Clean-rebuild dist after removal so the scan sees only directories, files, and links."],"exampleFix":"# before: stray IPC files inside the build tree\n$ ls dist/run.sock dist/log.fifo\n\n# after: remove special files, keep IPC artifacts outside dist/\n$ find dist -type p -o -type s | xargs rm -f","handlingStrategy":"validation","validationCode":"import { readdirSync } from 'node:fs';\n\nfunction buildTreeHasOnlySupportedEntries(buildRoot: string): boolean {\n  const stack = [buildRoot];\n  while (stack.length > 0) {\n    const dir = stack.pop()!;\n    for (const entry of readdirSync(dir, { withFileTypes: true })) {\n      if (entry.isDirectory() || entry.isFile() || entry.isSymbolicLink()) continue;\n      return false;\n    }\n    // descend only directories (not symlinks) as the scan does\n  }\n  return true;\n}","typeGuard":"function isUnsupportedBuildEntryError(error: unknown): boolean {\n  return error instanceof Error && /^Unsupported analyzer build entry:/.test(error.message);\n}","tryCatchPattern":"try {\n  identity = resolveAnalyzerRunnerIdentity(import.meta.url);\n} catch (error) {\n  if (isUnsupportedBuildEntryError(error)) {\n    reportUserError(`Special file in build tree: ${error.message}; remove FIFOs/sockets from dist.`);\n  }\n  throw error;\n}","preventionTips":["Configure dev servers and IPC tools to create sockets/pipes in /tmp, never inside the build directory.","Add a pre-run check for special files when packaging custom builds: find dist -type p -o -type s."],"tags":["gitnexus","analyzer-identity","filesystem","special-files","build-tree"],"backgroundTag":"unsupported-file-entry-type","analyzedSha":"aac7515d2a8c50a1f8f923c6fb77218b333560d6","analyzedAt":"2026-08-20T23:29:22.980Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}