2
在OkHttp中拒绝先前失败的类的重新初始化
我正在尝试使用flask后端将图像上传到我的服务器,该烧瓶将处理文件以保存在文件夹中,并在Android中保存OkHttp。但我在android中收到此错误: I/art: Rejecting re-init on previously-failed class java.lang.Class<okhttp3.internal.platform.ConscryptPlatform$configureTrustManager$1>: java.lang.NoClassDefFoundError: Failed resolution of: Lorg/conscrypt/ConscryptHostnameVerifier; at okhttp3.internal.platform.android.SocketAdapter okhttp3.internal.platform.android.ConscryptSocketAdapter.buildIfSupported() (ConscryptSocketAdapter.kt:64) at void okhttp3.internal.platform.AndroidPlatform.<init>() (AndroidPlatform.kt:45) at okhttp3.internal.platform.Platform okhttp3.internal.platform.AndroidPlatform$Companion.buildIfSupported() (AndroidPlatform.kt:239) at okhttp3.internal.platform.Platform okhttp3.internal.platform.Platform$Companion.findPlatform() (Platform.kt:211) at okhttp3.internal.platform.Platform okhttp3.internal.platform.Platform$Companion.access$findPlatform(okhttp3.internal.platform.Platform$Companion) (Platform.kt:179) at void okhttp3.internal.platform.Platform.<clinit>() (Platform.kt:180) at void okhttp3.OkHttpClient.<init>(okhttp3.OkHttpClient$Builder) (OkHttpClient.kt:219) at void okhttp3.OkHttpClient.<init>() (OkHttpClient.kt:211) at void com.example.swiftpinx.Activity.AddMediaActivity.onClick(android.view.View) (AddMediaActivity.java:207) at …