Repository navigation
Patch Changes
-
#1535
6abad6aThanks @vicb! - chore: bump@opennextjs/awsto 4.2.2See details at https://github.com/opennextjs/opennextjs-aws/releases/tag/v4.2.2
- Match
redirectsandheaderscase-insensitively. - Serve the 404 page for the paths that a
fallback: falseroute does not prerender with abasePath. - Run Server Actions forwarded to a dynamic route.
- Keep the
use cache,fetchandunstable_cacheentries during an ISR revalidation (including with Next.js 16.5).
- Match
-
#1525
002974dThanks @ahmed-abdelkafi! - fix: serve the current version when skew protection receives a deployment id such asconstructorRequests with a deployment id such as
constructorortoStringfailed with "TypeError: version.split is not a function" instead of being served the current version. -
#1511
499bba2Thanks @vicb! - fix: run Server Actions forwarded to a dynamic routeA Server Action posted to a page that does not bundle it (i.e. called from an effect cleanup after a client navigation) is forwarded by Next to the page that does. Since 1.20.16, it failed with "Failed to find Server Action" when that page is a dynamic route (i.e.
/items/[id]/edit). The action now runs, including for catch-all routes, routes withdynamicParams = falseand apps withtrailingSlash: true.Middleware sees
_forwarded-actionin the dynamic segments of the forwarded request, where Next.js passes the route pattern (i.e.[id]). -
#1276
1dcae40Thanks @spokodev! - fix: ignore repeatedinitOpenNextCloudflareForDevcalls with a warningCalling
initOpenNextCloudflareForDevmore than once in the Next.js config file madenext devcrash withSQLite failed; database is locked: SQLITE_BUSYandThe Workers runtime failed to start. Only the first call is now used, subsequent calls log a warning and are ignored. -
#1533
ddf6463Thanks @vicb! - fix: keep thefetchandunstable_cacheentries during an ISR revalidation with Next.js 16.5Next.js 16.5 moved the on-demand revalidation check from the
fetchandunstable_cachecall sites toIncrementalCache#get, so every ISR revalidation regenerated those entries.
ThepatchIncrementalCacheForISRpatch from@opennextjs/aws4.2.2 is now applied to the server bundle.See opennextjs/opennextjs-aws#1384 and opennextjs/opennextjs-aws#1385.
-
#1533
ddf6463Thanks @vicb! - fix: do not loadfunctions-config-manifest.jsonat runtime with Next.js 16.5Next.js 16.5 moved the dynamic
requireoffunctions-config-manifest.jsonto the newNextNodeServer#getMiddlewareConfig, which the adapter did not patch.
Every request of an app without an edge middleware failed with a 500:Error: Dynamic require of "/.next/server/functions-config-manifest.json" is not supportedThe method is now stubbed, like
loadNodeMiddleware. The middleware still runs, outside of the Next.js server. -
#1533
ddf6463Thanks @vicb! - fix: load the chunks of dynamicimport()s with Next.js 16.5 and TurbopackThe Turbopack runtime of Next.js 16.5 declares its own
requireChunk, which installs the module factories of the chunk.
The function generated by the adapter to inline the chunks had the same name and shadowed it, so every module loaded through a dynamicimport()(e.g. ininstrumentation.ts) failed with:Module <id> was instantiated because it was required from module <id>, but the module factory is not available.The generated function is now named
requireInlinedChunk. -
#1533
ddf6463Thanks @vicb! - fix: patch the Turbopack wasm helpers that Next.js 16.5 emits in the chunksNext.js 16.5 emits the wasm helpers (
compileModuleandinstantiate) as anonymous function expressions instead of function declarations.
The patch silently stopped matching, so apps loading wasm with Turbopack (e.g. Prisma 7) failed at runtime with:TypeError: WebAssembly.compileStreaming is not a functionThe patch now replaces the body of the helpers, whatever form they are emitted in.
-
#1440
873d2b9Thanks @mathurshubham! - fix: render<Head>tags from dependencies likenext-seoSince Next.js 15.3,
<Head>tags rendered by a dependency (e.g. the<title>, canonical andog:tags fromnext-seo) were missing from the HTML of pages rendered by the Worker, such asgetServerSidePropspages and ISR fallback paths. Pages pre-rendered at build time were not affected. -
#1529
3cd810bThanks @ahmed-abdelkafi! - fix: accept the.workers.devsuffix forCF_PREVIEW_DOMAIN -
#1433
80addb0Thanks @mathurshubham! - fix: support packages with optional native addonsThe build failed when the app used a package loading a Node.js native addon, e.g.
ssh2(throughcpu-features), even when the addon is optional. The error wasNo loader is configured for ".node" files, orCould not resolve "../build/Release/cpufeatures.node"when the addon was not built (e.g. pnpm skipping the install scripts).Native addons can not run on Workers. They are now replaced with a module throwing a
MODULE_NOT_FOUNDerror, so packages treating the addon as optional work as if it was not installed. A warning lists each stubbed addon during the build: packages that require the addon fail at runtime. -
#1502
dbe786fThanks @haranishi! - fix: warn when the local revalidation queue is missing its service binding