-
Notifications
You must be signed in to change notification settings - Fork 27.6k
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
Compilation time extremely slow (Next > 12.0.9) #38590
Comments
I've looked at the trace files (thanks) and could not immediately see the cause of the issue. One idea is that you have a custom webpack configuration that might play a role (if that's the case, keep in mind that modifying the webpack config is not covered by semver, hence the unexpected results). Could you attach your |
@balazsorban44, I created a repo with the same |
Thanks. I tried your reproduction locally. The repo had version
So I cannot reproduce the significant decrease that is described. Being able to look at the actual repository might be more useful. As pointed out though, based on the reproduction there are some modifications to the |
@balazsorban44 thanks. I run building the project on Archlinux and Ubuntu, the compilation time on |
I cannot check on macOS right now, but let me know if the suggested debugging method helps, so we can at least confirm if the issue comes from one of the extensions in |
Used |
@balazsorban44, I added you to a repo where the issue is consistently reproduced. |
@balazsorban44 any updates on this issue? |
I noticed the exact same thing running @balazsorban44 This is also on MacOS. More specifically, MacOS 12.3.1 (Monterey) with a MacBook Pro (16-inch, 2021) M1 Max. Essentially the exact same thing as reported in Why does it compile twice? (second time always much slower) · Discussion #39901 · vercel/next.js
UPDATE: I downgraded and locked to 12.2.4 and this slowdown is gone, so this "issue" seems to have been introduced in 12.2.5 |
I just tested v12.3.0 and sadly, this is even worse now, because running
The huge pause occurs (for me) in between these 2 lines above. There is no longer a second |
The issue has been identified by a user and linked to a recent PR, see my comment here. Feel free to share your experience as well. Hopefully the Next.js people can provide a workaround. |
Seeing this as well after updating to 12.2.5.
MacOS 12.1 - M1 |
@timkindberg could you try |
@ijjk Thanks, this is solving the issue for me |
For me, the issue is reproduced in |
@ijjk canary.1 seemed to solve it for me but I rolled back to 12.2.4 instead. |
I found out that in my case, the problem was in |
This closed issue has been automatically locked because it had no new activity for a month. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Verify canary release
Provide environment information
What browser are you using? (if relevant)
No response
How are you deploying your application? (if relevant)
No response
Describe the Bug
After updating the
next
package from version 12.0.9 to 12.2.0 and above, thenext dev
compilation time extremely slow.I tried to use compilation with SWC and with babel, the result is the same.
nextjs 12.0.9:
compiled client and server successfully in 3.4s (577 modules)
trace: https://gist.github.com/R1ZEN/2d032dba11947ac3b48ecfe9a4e1008d
nextjs 12.2.0:
compiled client and server successfully in 46.8s (667 modules)
trace: https://gist.github.com/R1ZEN/36445c707eb0e50a58cccd05af2ac19f
Expected Behavior
Compilation time would be the same or faster
Link to reproduction
I don't have a reproduction that I can share at the moment
To Reproduce
I don't have a reproduction that I can share at the moment, but might have some time to come up with one.
The text was updated successfully, but these errors were encountered: