原因:重复引用包(但不同版本的)导致冲突了。
Caused by: java.lang.RuntimeException:
Duplicate class com.google.crypto.tink.PublicKeySign found in modules jetified-sshlib-2.2.20 (org.connectbot:sshlib:2.2.20) and jetified-tink-android-1.5.0 (com.google.crypto.tink:tink-android:1.5.0)在Android Studio的终端(Terminal)中
./gradlew app:dependencies然后会打印一堆依赖路径。在里面右键点find,输入"tink"就找到目标位置了

在build.gradle中找到implementation "androidx.security:security-crypto:1.0.0"
改为
implementation ('androidx.security:security-crypto:1.0.0') {
exclude group: "com.google.crypto.tink", module: "tink-android"
}就可以了。这里意思是排除使用这个模块。
查看依赖树使用gradlew -q app:dependencies也可以
5581

被折叠的 条评论
为什么被折叠?



