Reputation: 21
I inherited a big project and while gatsby develop
works without any issue, when I run gatsby build
I get the following:
ERROR #95313
Building static HTML failed
See our docs page for more info on this error: https://gatsby.dev/debug-html
80 | start,
81 | end,
> 82 | markerLines
| ^
83 | };
84 | }
85 |
WebpackError: Worker exited before finishing task
- index.js:82
[gatsby-starter-default]/[@babel]/code-frame/lib/index.js:82:1
- caching.js:67
[gatsby-starter-default]/[@babel]/core/lib/config/caching.js:67:1
I tried setting up debugger but nothing new. The lines it shows are from webpack so no help.
I tried --verbose
and it also don't show anything more. How can I better debug this and find the source of the issue? I read gatsby build-html docs(and issues section) and the only mentioned solution that would probably work is checking files one by one(huge project, hoping it doesn't come to that). Any ideas?
Upvotes: 1
Views: 2186
Reputation: 11
Recently I see the exact same error massage after trying to build my Gatsby project. (The cause of error may be different from you and me)
My error message above seemed to say that some error occurred in image cache files during building, so I deleted caches by gatsby clean
. After this, building succeeded.
Upvotes: 1