任务':app:compileDebugJavaWithJavac'的执行失败。扑

时间:2019-08-17 06:00:18

标签: flutter

我的项目进展顺利,直到我运行flutter clean,然后尝试在出现错误的android上运行我的应用程序

    FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:compileDebugJavaWithJavac'.
> java.lang.IllegalStateException: Expected BEGIN_OBJECT but was STRING at line 1 column 1 path $

* 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 20s
Gradle task assembleDebug failed with exit code 1
Exited (sigterm)

1 个答案:

答案 0 :(得分:0)

当您的应用的依赖项与您的开发环境不兼容时,很可能会出现此问题。

在以下 SO 帖子中,此错误的最佳解决方案是更新上面评论中提到的依赖项。要备份参考资料,您可以参考这篇 SO 帖子,其中展示了遇到的问题: