Next.js build error while around 180 statis pages to render
Unanswered
Cape lion posted this in #help-forum
Cape lionOP
As you can see in the screen, i can't build the app cuz it says "too many files open" , but why? I tried to reproduce it on another repo, i copied a lot of pages directories and pase in /src/pages and i also faced it on windows.
Anyone can find a solution?
[image in comment]
Anyone can find a solution?
[image in comment]
3 Replies
Cape lionOP
Cape lionOP
Update - i checked process explorer and during the build, node.exe opens hundred or tousands times the same file:
/.next/package.json
node keeps opens and closes the file, why? Anyone faced the issue?
/.next/package.json
node keeps opens and closes the file, why? Anyone faced the issue?
@Cape lion Update - i checked process explorer and during the build, node.exe opens hundred or tousands times the same file:
/.next/package.json
node keeps opens and closes the file, why? Anyone faced the issue?
maybe try this in your
next.config.jsconst nextConfig = {
experimental: {
cpus: 1,
},
};
export default nextConfig;