-
Notifications
You must be signed in to change notification settings - Fork 27.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unhandled Runtime Error: ChunkLoadError #56484
Comments
We have recently encountered some random crashes when changing routes after upgrading to version 13.5.1. I am not sure about the exact cause, but the page becomes stuck during the route change. In Chrome, it displays an 'Aw, snap!' crash error, while Firefox indicates that the site is slowing down your browser. We are currently deploying on Amplify AWS. |
This is happening for us in production when leaving the landing page for the following resource: _next/static/chunks/webpack-8147f10d25df47dc.js |
Facing the same issue in production. Only the pages using CMS/revalidate feature crashes. The issue is most probably in server page.tsx files. Everything works fine in local. This happened when I updated the app to the latest 13.5.5 canary version. Reverted the version to 13.4.1 and now everything works fine even in production. |
Having the same issue in production... |
We are on page router |
I have changed my hosting to Vercel and so far I haven't had the issue. It appears this is a Netlify issue not a Next issue which I'm glad about cause I love Next but this was making it unusable. Hopefully Netlify fix this. Will keep testing my production app and hopefully it carries on working. |
So we got this error after upgrading to 13.5.5, in development and deployed to vercel in production. Downgrading to 13.5.4 fixed it |
Same kind of issue here, I have catch-all in my root Due to this issue also navigation "crashes" as mentioned earlier in the comments. |
@johnrackles's solution is currently the only fix for this. We were experiencing the exact same issue. The issue we discovered was due to encoded dynamic routes This URL was what Next.js was requesting which 404'd: But manually URL decoding the URL and opening in a new tab correctly resolved the file: We were experiencing this issue on [email protected], but downgrading to [email protected] resolved the issue, so there's definitely been a bug that's been released in version [email protected] or later. |
Had same issue in localhost. I just delete .next folder restart the application and issue resolved. error occurred when i changed routing hierarchy. now its working fine. |
Noticed the same thing as @enijar. The app is trying to load: but if I update the url manually to Current version: |
I think the problem is that the page.js url is double encode When you url decode: http://localhost:3000/_next/static/chunks/app/%255Bstorecode%255D/page.js you get http://localhost:3000/_next/static/chunks/app/%5Bstorecode%5D/page.js And it only happens when navigating. Checked 14.0.0, it still happening |
Facing the same issue, revert back to |
I've tried making a reproduction for the issue mentioned in the lower comments here, specifically double encoding of |
This comment has been minimized.
This comment has been minimized.
Can someone post a reproduction of this? The origin reproduction in the issue description is 404 |
We cannot recreate the issue with the provided information. Please add a reproduction in order for us to be able to investigate. Why was this issue marked with the
|
Here's a repro of this error: https://github.com/enijar/next-load-error-repro Notice that somehow including this third party script causes the issue: <Script
strategy="beforeInteractive"
src="https://cdn.cookielaw.org/scripttemplates/otSDKStub.js"
/> |
As a workaround, you can remove |
Removing |
Bro, you saved our life. Thank you. |
* Next 13.5.7 * Dedupe * Desktop E2E unbreaking * Work around vercel/next.js#56484
@jianliao thanks for the repro |
We land a fix for #57829 and also the one mentioned related to |
I tested the canary locally and can confirm that it the fix works with the Script strategy="beforeInteractive" 🥳 |
@huozhi Thanks for the quick fix. I can confirm it works on 14.0.2-canary.10 now. |
@huozhi I am still getting an error on For some reason Running When I build locally or deploy and navigate from
When I check the console, I see the following:
When I refresh the route the page loads without any problem, but a Let me know if I should open a new issue or can provide any more info. |
@feliche93 please open a new issue with reproduction, thanks |
This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Link to the code that reproduces this issue
https://github.com/rsheppard-dev/lh-plumbing
To Reproduce
Or
Current vs. Expected behavior
I expect page page to load normally however in development I get this error:
`Unhandled Runtime Error
ChunkLoadError: Loading chunk app/(app)/layout failed.
(error: http://localhost:3000/_next/static/chunks/app/(app)/layout.js)
Call Stack
webpack_require.f.j
file:///Users/roy/Documents/Code/lh-plumbing/.next/static/chunks/webpack.js (853:29)
/next/static/chunks/webpack.js (155:40)
Array.reduce
webpack_require.e
file:///Users/roy/Documents/Code/lh-plumbing/.next/static/chunks/webpack.js (154:67)
fn.e
/next/static/chunks/webpack.js (391:50)
loadChunk
node_modules/.pnpm/[email protected]@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (202:31)
preloadModule
node_modules/.pnpm/[email protected]@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (128:0)
resolveModule
node_modules/.pnpm/next@13.5.5-canary.2_@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (1725:0)
processFullRow
node_modules/.pnpm/next@13.5.5-canary.2_@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (1796:0)
processBinaryChunk
node_modules/.pnpm/next@13.5.5-canary.2_@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (1944:0)
progress
node_modules/.pnpm/next@13.5.5-canary.2_@babel[email protected][email protected][email protected]/node_modules/next/dist/compiled/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js (2024:0)`
If I refresh again page loads normally. In production I got a full page of text like this:
0:["8cuD6kwHKIa0es9d4FAUU",[[["",{"children":["(app)",{"children":["__PAGE__",{}]},"$undefined","$undefined",true]}],"$L1",[[],"$L2"]]]] 3:HL["/_next/static/media/e1c529c04de64b40-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] 4:HL["/_next/static/media/e7c7dbb62ddcf6fa-s.p.woff2","font",{"crossOrigin":"","type":"font/woff2"}] 5:HL["/_next/static/css/09cb01cb14dd5f8d.css","style"] 6:I{"id":90287,"chunks":["272:static/chunks/webpack-153c1757a1b8d488.js","158:static/chunks/40519c47-39d723cc761f5bdf.js","981:static/chunks/981-d0de02e3ea918bed.js"],"name":"","async":false} 7:I{"id":28695,"chunks":["272:static/chunks/webpack-153c1757a1b8d488.js","158:static/chunks/40519c47-39d723cc761f5bdf.js","981:static/chunks/981-d0de02e3ea918bed.js"],"name":"","async":false} 1:["$","$L6",null,{"parallelRouterKey":"children","segmentPath":["children"],"loading":"$undefined","loadingStyles":"$undefined","hasLoading":false,"error":"$undefined","errorStyles":"$undefined","template":["$","$L7",null,{}],"templateStyles":"$undefined","notFound":[["$","title",null,{"children":"404: This page could not be found."}],["$","div",null,{"style":{"fontFamily":"system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI ........
Verify canary release
Provide environment information
Operating System: Platform: darwin Arch: arm64 Version: Darwin Kernel Version 23.0.0: Fri Sep 15 14:41:43 PDT 2023; root:xnu-10002.1.13~1/RELEASE_ARM64_T6000 Binaries: Node: 20.3.1 npm: 9.6.7 Yarn: N/A pnpm: 8.6.12 Relevant Packages: next: 13.5.5-canary.2 eslint-config-next: 13.4.19 react: 18.2.0 react-dom: 18.2.0 typescript: 5.2.2 Next.js Config: output: N/A
Which area(s) are affected? (Select all that apply)
Not sure, App Router
Additional context
I am hosting my Next site on Netlify. This error has happened in production on a MacBook Pro and iPhone 13 Pro using Chrome.
I have also had this happen on Safari.
The text was updated successfully, but these errors were encountered: