我试图构建我的应用程序,但它总是返回这个奇怪的错误:
Launching lib\main.dart on M2003J15SC in debug mode...
FAILURE: Build failed with an exception.
* What went wrong:
A problem was found with the configuration of task ':location:compileDebugJavaWithJavac'.
> File 'C:\Native\findhelpapp\findhelpapp\build\location\intermediates\annotation_processor_list\debug\annotationProcessors.json' specified for property 'processorListFile' does not exist.
* 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
BUILD FAILED in 52s
Exception: Gradle task assembleDebug failed with exit code 1
Exited (sigterm)我试图运行flutter clean并重新构建项目,但它也不起作用:"(
那么我应该怎么做才能修复这个错误呢?
我的flutter doctor日志:-
C:\Native\findhelpapp\findhelpapp>flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.20.4, on Microsoft Windows [Version 10.0.18362.1082], locale en-US)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[√] Android Studio (version 3.6)
[√] IntelliJ IDEA Community Edition (version 2019.3)
[√] VS Code (version 1.49.1)
[√] Connected device (1 available)
• No issues found!
C:\Native\findhelpapp\findhelpapp>发布于 2020-09-22 20:20:09
2.复制gradle.properties末尾的下一行
android.useAndroidX=true
android.enableJetifier=true
在文件app\build.gradle上
android {
compileSdkVersion 28
defaultConfig {
minSdkVersion 21
targetSdkVersion 28
multiDexEnabled true}
4.运行你的应用程序
https://stackoverflow.com/questions/63997339
复制相似问题