gpt4 book ai didi

Webpack编译无法读取null的属性 'semaphore'

转载 作者:行者123 更新时间:2023-12-02 15:54:46 28 4
gpt4 key购买 nike

尝试构建我的 React 应用程序,但遇到此编译错误:

/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/Compilation.js:268
_this.semaphore.release();

TypeError: Cannot read property 'semaphore' of null
at factoryCallback (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/Compilation.js:268:12)
at factory (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/NormalModuleFactory.js:235:20)
at resolver (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/NormalModuleFactory.js:60:20)
at asyncLib.parallel.e (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/NormalModuleFactory.js:127:20)
at /Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/async/dist/async.js:3861:9
at /Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/async/dist/async.js:421:16
at iteratorCallback (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/async/dist/async.js:996:13)
at /Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/async/dist/async.js:906:16
at /Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/async/dist/async.js:3858:13
at resolvers.normal.resolve (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/webpack/lib/NormalModuleFactory.js:119:22)
at onError (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/enhanced-resolve/lib/Resolver.js:65:10)
at loggingCallbackWrapper (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/enhanced-resolve/lib/createInnerCallback.js:31:19)
at runAfter (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/enhanced-resolve/lib/Resolver.js:158:4)
at innerCallback (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/enhanced-resolve/lib/Resolver.js:146:3)
at loggingCallbackWrapper (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/enhanced-resolve/lib/createInnerCallback.js:31:19)
at next (/Users/jimvercoelen/Documents/bitbucket/inboundmuse-client/node_modules/tapable/lib/Tapable.js:252:11)

我不知道是什么导致了这个问题。当我尝试谷歌帮助时,看起来我是唯一面临这个问题的人..

最佳答案

深入研究 node_modules/webpack/lib/Compilation.js:268 并实际记录错误后,出现了一些 use full 的情况。由于我自己的错误,它无法编译。

如果您遇到同样的问题;尝试记录 Compilation.js:268 文件中的错误;

if(err) {
console.log({ err })
return errorOrWarningAndCallback(new ModuleNotFoundError(module, err, dependencies));
}

关于Webpack编译无法读取null的属性 'semaphore',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46322347/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com