{"record":{"id":"d3a1cb5fcd720fe3","repo":"vercel/next.js","slug":"failed-to-seed-turbopack-cache-from-sourceversio","errorCode":null,"errorMessage":"Failed to seed Turbopack cache from ${sourceVersionDir} to ${targetVersionDir}.","messagePattern":"Failed to seed Turbopack cache from (.+?) to (.+?)\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/next/src/lib/turbopack-cache-seed.ts","lineNumber":59,"sourceCode":"  } catch {\n    return\n  }\n  if (!sourceVersionDir) return\n\n  const tmpDir = `${targetVersionDir}.seeding`\n  // Making sure we don't copy partial data if process interrupted\n  // There is a potential race condition here\n  // if someone wrote to the cache while we were seeding it\n  // but with the immutable design and all that, I'm not super worried\n  try {\n    fs.mkdirSync(cacheDir, { recursive: true })\n    fs.rmSync(tmpDir, { recursive: true, force: true })\n    seedCacheDir(sourceVersionDir, tmpDir)\n    fs.renameSync(tmpDir, targetVersionDir)\n    Log.info(`Seeded Turbopack cache from ${sourceVersionDir}.`)\n  } catch {\n    fs.rmSync(tmpDir, { recursive: true, force: true })\n    Log.warn(\n      `Failed to seed Turbopack cache from ${sourceVersionDir} to ${targetVersionDir}.`\n    )\n  }\n}\n\nfunction findSeedSource(\n  worktreeInfo: GitWorktreeInfo,\n  projectDir: string,\n  distDir: string,\n  version: string\n): string | undefined {\n  const projectRelToWorktree = path.relative(\n    worktreeInfo.worktreeRoot,\n    projectDir\n  )\n  const distRelToProject = path.relative(projectDir, distDir)\n  const currentWorktree = path.resolve(worktreeInfo.worktreeRoot)\n","sourceCodeStart":41,"sourceCodeEnd":77,"githubUrl":"https://github.com/vercel/next.js/blob/0eb377541648e63402a47b38fee00a8d0ce8f8f1/packages/next/src/lib/turbopack-cache-seed.ts#L41-L77","documentation":"seedTurbopackCacheIfNeeded copies a previous Turbopack persistent-cache version directory into the target version via a temp dir plus rename; this warning is logged when seeding fails (missing source, IO error, interrupted copy) and the dev server continues with a cold cache.","triggerScenarios":"Thrown at packages/next/src/lib/turbopack-cache-seed.ts:59 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Delete the stale .next/cache directory and let Turbopack rebuild its cache."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0eb377541648e63402a47b38fee00a8d0ce8f8f1","analyzedAt":"2026-08-19T02:10:13.922Z","contentChangedAt":"2026-08-19T02:10:13.922Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}