Duplicate class com.google.commo

2020-10-15  本文已影响0人  hasJava

flutter 更新到 1.22.1后编译Android 时报以下错
Duplicate class com.google.common.util.concurrent.ListenableFuture found in modules jetified-guava-20.0.jar (com.google.guava:guava:20.0) and jetified-listenablefuture-1.0.jar (com.google.guava:listenablefuture:1.0)

解决方案:
    在app/build.gradle 文件里的 dependencies 下新增如下代码
   implementation 'com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava'

引用文章: android - 在模块guava-20.0.jar(com.google.guava:guava:20.0)中找到的重复类com.google.common.util.concurrent.ListenableFuture - IT工具网

上一篇下一篇

猜你喜欢

热点阅读