{"record":{"id":"b97936f96f1feef5","repo":"vercel/next.js","slug":"failed-to-update-prerender-cache-for","errorCode":null,"errorMessage":"Failed to update prerender cache for","messagePattern":"Failed to update prerender cache for","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"packages/next/src/server/lib/incremental-cache/index.ts","lineNumber":790,"sourceCode":"      !ctx.isImplicitBuildTimeCache\n    ) {\n      const warningText = `Failed to set Next.js data cache for ${ctx.fetchUrl || pathname}, items over 2MB can not be cached (${itemSize} bytes)`\n\n      if (this.dev) {\n        throw new Error(warningText)\n      }\n      console.warn(warningText)\n      return\n    }\n\n    try {\n      if (!ctx.fetchCache && ctx.cacheControl) {\n        this.cacheControls.set(toRoute(pathname), ctx.cacheControl)\n      }\n\n      await this.cacheHandler?.set(pathname, data, ctx)\n    } catch (error) {\n      console.warn('Failed to update prerender cache for', pathname, error)\n    }\n  }\n}\n","sourceCodeStart":772,"sourceCodeEnd":794,"githubUrl":"https://github.com/vercel/next.js/blob/43273a1d21a35646ec43230e05727e18ac258396/packages/next/src/server/lib/incremental-cache/index.ts#L772-L794","documentation":"Warning logged in IncrementalCache.set after the configured cacheHandler.set(...) call threw while persisting a prerender entry for the given pathname. The catch block deliberately swallows the handler failure and continues — a failed cache write degrades freshness but must not break rendering — so the operator only gets this console.warn naming the pathname and the underlying error.","triggerScenarios":"Thrown at packages/next/src/server/lib/incremental-cache/index.ts:785 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check filesystem permissions and available disk space for the .next cache directory.","Verify the cache handler configuration and connectivity if using a custom external cache."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"43273a1d21a35646ec43230e05727e18ac258396","analyzedAt":"2026-08-19T02:10:13.922Z","contentChangedAt":"2026-08-19T02:10:13.922Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}