java.lang.NoSuchMethodError:没有直接的方法 - 在迁移过程中的冲突:谷歌地方SDK和截击

问题描述 投票:0回答:1

虽然迁移到新Places SDK,我面临过这样的错误:

java.lang.NoSuchMethodError: No direct method <init>(Ljava/io/InputStream;J)V in class Lcom/android/volley/toolbox/DiskBasedCache$CountingInputStream; or its super classes (declaration of 'com.android.volley.toolbox.DiskBasedCache$CountingInputStream' appears in /data/app/com.xx.xxx-SfwuN0IipN88dVqeHkiSvQ==/base.apk)
    at com.android.volley.toolbox.DiskBasedCache.initialize(DiskBasedCache.java:166)
    at com.android.volley.CacheDispatcher.run(CacheDispatcher.java:84)

我使用的凌空(其导入为一个项目)在我的应用程序。我想崩溃因发生的版本冲突?

android google-places
1个回答
0
投票

我只是需要从地方库排除抽射,使其工作。

之前:

dependencies {
 implementation 'com.google.android.libraries.places:places:1.0.0'
}

后:

implementation ('com.google.android.libraries.places:places:1.0.0' ){
    exclude module: 'volley'
}
© www.soinside.com 2019 - 2024. All rights reserved.