简体   繁体   English

Flutter:任务 ':firebase_core:compileDebugJavaWithJavac' 执行失败

[英]Flutter: Execution failed for task ':firebase_core:compileDebugJavaWithJavac'

I would like to ask some help regarding flutter.我想寻求一些关于 flutter 的帮助。

    FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':firebase_core:compileDebugJavaWithJavac'.
> Could not create service of type DefaultGeneralCompileCaches using GradleScopeCompileServices.createGeneralCompileCaches().
   > Unexpected lock protocol found in lock file. Expected 3, found 0.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

This is the error I am getting, I've never seen anything like this before.这是我遇到的错误,我以前从未见过这样的错误。 Other apps runs perfectly fine so there's no value in adding flutter doctor if you want to see some other code lemme know down in the comment.其他应用程序运行良好,因此如果您想在评论中查看其他代码让我知道,添加flutter doctor没有任何价值。

It seems like you are facing this issue when the android gradle build is running.当 android gradle 构建运行时,您似乎遇到了这个问题。 As per the error output, this might get you back on track.根据错误 output,这可能会让您回到正轨。

Try deleting the gradle cache located under尝试删除位于下的 gradle 缓存

Windows: Windows:

C:\Users\user\.gradle

Mac/Linux:苹果电脑/Linux:

/Users/prabhath/.gradle

folder and rerun the build.文件夹并重新运行构建。 Hope this will solve your problem.希望这能解决您的问题。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Flutter 构建失败 [任务 ':firebase_core:compileReleaseJavaWithJavac' 执行失败。] - Flutter build fails [Execution failed for task ':firebase_core:compileReleaseJavaWithJavac'.] 任务 ':react-native-firebase:compileDebugJavaWithJavac' 执行失败。 #2099、 - Execution failed for task ':react-native-firebase:compileDebugJavaWithJavac'. #2099 , 任务 ':react-native-firebase:compileDebugJavaWithJavac' 执行失败 - Execution failed for task ':react-native-firebase:compileDebugJavaWithJavac' 更新 flutter sdk 会导致 firebase_core、firebase_auth 出现问题 - updating flutter sdk cause an issue with firebase_core, firebase_auth MissingPluginException(在 Android 上找不到方法 Firebase#initializeCore 在通道插件上的实现。flutter.io/firebase_core) - MissingPluginException(No implementation found for method Firebase#initializeCore on channel plugins.flutter.io/firebase_core) on Android MissingPluginException(在通道插件上未找到方法 Firebase#initializeCore 的实现。flutter.io/firebase_core)在构建中 - MissingPluginException(No implementation found for method Firebase#initializeCore on channel plugins.flutter.io/firebase_core) on build Flutter 当我添加 package firebase_core 时出现 pod 安装错误 - Flutter pod install error when i add package firebase_core flutter 中的任务“:app:transformDexArchiveWithExternalLibsDexMergerForDebug”执行失败 - Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug' in flutter FlutterFire Firebase class 在 firebase_core 中无法识别 package - FlutterFire Firebase class not recognised in firebase_core package 尝试构建 apk 并发生以下错误:Flutter Firebase.app(appName) error, Execution failed for task ':app:compileFlutterBuildDebug' - Trying to build apk and these error occur: Flutter Firebase.app(appName) error, Execution failed for task ':app:compileFlutterBuildDebug'
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM