gpt4 book ai didi

android - 在模块 guava-20.0.jar (com.google.guava :guava:20. 0) 中找到重复的类 com.google.common.util.concurrent.ListenableFuture

转载 作者:太空狗 更新时间:2023-10-29 16:25:35 30 4
gpt4 key购买 nike

当我在 app/build.gradle 中使用 implementation 'com.google.firebase:firebase-inappmessaging-display:17.2.0' 时,出现此错误:

Duplicate class com.google.common.util.concurrent.ListenableFuture found in modules guava-20.0.jar (com.google.guava:guava:20.0) and listenablefuture-1.0.jar (com.google.guava:listenablefuture:1.0)

Go to the documentation to learn how to Fix dependency resolution errors.

我的 app/build.gradle 中还有这个:

implementation 'com.google.android.gms:play-services-base:16.1.0'
implementation 'com.google.android.gms:play-services-analytics:16.0.8'
implementation 'com.google.android.gms:play-services-awareness:16.0.0'
implementation 'com.google.android.gms:play-services-cast:16.2.0'
implementation 'com.google.android.gms:play-services-gcm:16.1.0'
implementation 'com.google.android.gms:play-services-location:16.0.0'
implementation 'com.google.android.gms:play-services-maps:16.1.0'
implementation 'com.google.firebase:firebase-core:16.0.8'
implementation 'com.google.firebase:firebase-iid:17.1.2'
implementation 'com.google.firebase:firebase-messaging:17.6.0'
implementation 'android.arch.work:work-runtime:1.0.1'
implementation 'com.android.support:multidex:1.0.3'
apply plugin: 'com.google.gms.google-services'

也许我正在使用的库之一已经包含对应用内消息依赖项的支持,然后它就变得多余了?谢谢。

最佳答案

2020 年解决方案

Google 知道这个错误,所以他们制作了一个特殊的包来修复冲突。

将此添加到您的 build.gradle

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,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56639529/

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