java - 尝试连接到 FireStore 数据库但得到“程序类型已经存在:okio.Buffer$2”
问题描述
我遇到了依赖问题,在某个地方我对 okio.Buffer$2 和可能的 okio.AsyncTimeout 有双重依赖(它在尝试解决问题时弹出,但我无法隔离问题)。这是我的依赖项。
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.google.android.gms:play-services-auth:16.0.1'
//implementation 'com.android.support:support-v4:28.0.0'
//implementation 'com.android.support:customtabs:28.0.0'
//implementation 'com.android.support:support-media-compat:28.0.0'
//implementation 'com.android.support:cardview-v7:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:support-vector-drawable:28.0.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso core:3.0.2'
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'de.hdodenhof:circleimageview:2.2.0'
implementation 'com.github.bumptech.glide:glide:4.9.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.9.0'
implementation 'com.facebook.android:facebook-android-sdk:[4,5)'
implementation files('ksoap2-android-assembly-3.6.3-jar-with-dependencies.jar')
implementation files('build/libs/unirest-java-1.4.10-SNAPSHOT withDependency-ShadedForAndroid.jar')
implementation 'com.google.firebase:firebase-core:16.0.7'
implementation 'com.google.firebase:firebase-firestore:18.0.1'
我已经用尽了许多形式和尝试以及几个小时。如果有人有任何想法,请发表评论。该项目还实现了 facebook signin、google signin 和 firestore。我相信这三个中的一个正在解决这个问题。
解决方案
可以将其排除在implementation
:
implementation ("com.google.firebase:firebase-firestore:18.2.0") {
exclude group: "com.squareup.okio"
}
推荐阅读
- docker - docker build 超时
- spring - 无法从 application.properties 关闭 springboot 2 日志
- excel - 如何更快地制作一个简单的“Sum”循环?
- javascript - 如果之前没有使用 jQuery 设置,如何绑定事件监听器?
- python - 获取 ndArray / list 的所有其他索引
- api - LinkedIn API 403(禁止)在任何请求 url 上,包括 v2
- spring - Spring OAuth2 - 授权服务器 - 区分客户端上的用户
- rxjs - 不应该调用 RxJS iif 参数
- swashbuckle - 使用 Swashbuckle / Swagger 注释数组以具有 minItems
- loops - 有人可以解释一下这段代码在即将到来的测试中是如何工作的吗