Why my gatsby build failed on Error: ENOENT: no such file or directory?(为什么我的Gatsby构建失败错误:ENOENT:没有这样的文件或目录?)
本文介绍了为什么我的Gatsby构建失败错误:ENOENT:没有这样的文件或目录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在生成一个Gatsby站点,可以很好地使用Gatsby开发,但在创建它的Build时会引发错误
success Building production JavaScript and CSS bundles - 26.183s
⠇ Building Rendering Engines
[ ] 45.509 42/47 9 Running gatsby-plugin-sharp.IMAGE_PROCESSING … s 7 %
<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (11572kiB)
impacts deserialization performance (consider using Buffer instead and decode when needed)
<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (11572kiB)
impacts deserialization performance (consider using Buffer instead and decode when needed)
⠙ Building Rendering Engines
[ ] 64.883 44/47 9 Running gatsby-plugin-sharp.IMAGE_PROCESSING … s 7 %
<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (127kiB) impacts deserialization performance (consider using Buffer instead and decode when needed)
<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (127kiB) impacts deserialization performance (consider using Buffer instead and decode when needed)
success Building Rendering Engines - 69.787s
success Building HTML renderer - 70.287s
success Execute page configs - 0.050s
failed Validating Rendering Engines - 73.109s
ERROR #98001 WEBPACK
Built Rendering Engines failed validation failed validation.
Please open an issue with a reproduction at
https://github.com/gatsbyjs/gatsby/issues/new for more help
Error: ENOENT: no such file or directory, open 'C:UsersUCHEDesktopown-r eviewsite.cachequery-engineinterfaces.gql'
- node:fs:585 Object.openSync
node:fs:585:3
- node:fs:453 Object.readFileSync
node:fs:453:35
- index.js:708656 Object.<anonymous>
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:708656 :17
- index.js:734538 __webpack_require__
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:734538 :42
- index.js:708375 Object.<anonymous>
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:708375 :19
- index.js:734538 __webpack_require__
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:734538 :42
- index.js:708334 Object.<anonymous>
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:708334 :22
- index.js:734538 __webpack_require__
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:734538 :42
- index.js:708328 Object.<anonymous>
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.js:708328 :37
- index.js:734538 __webpack_require__
C:/Users/UCHE/Desktop/own-review/site/.cache/query-engine/index.
我尝试在运行Gatsby CLEAN后进行重建,删除了.cache文件,重新安装了NODE_MODULE,但没有成功
有人知道我如何解决此错误吗?
推荐答案
尝试删除您的Gatsby项目中的.cache
目录,然后再次运行yarn start
或yarn build
(如果您正在使用npm
,则运行等效的npm
命令),这为我解决了所有相关问题...
这篇关于为什么我的Gatsby构建失败错误:ENOENT:没有这样的文件或目录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
沃梦达教程
本文标题为:为什么我的Gatsby构建失败错误:ENOENT:没有这样的文件或目录?


猜你喜欢
- 失败的 Canvas 360 jquery 插件 2022-01-01
- Quasar 2+Apollo:错误:找不到ID为默认的Apollo客户端。如果您在组件设置之外,请使用ProvideApolloClient() 2022-01-01
- CSS媒体查询(最大高度)不起作用,但为什么? 2022-01-01
- 400或500级别的HTTP响应 2022-01-01
- Flexslider 箭头未正确显示 2022-01-01
- Css:将嵌套元素定位在父元素边界之外一点 2022-09-07
- 使用RSelum从网站(报纸档案)中抓取多个网页 2022-09-06
- Fetch API 如何获取响应体? 2022-01-01
- addEventListener 在 IE 11 中不起作用 2022-01-01
- 如何使用 JSON 格式的 jQuery AJAX 从 .cfm 页面输出查 2022-01-01