我正在尝试通过直接采用this gist中的代码来实现React Native项目中的websocket连接的Trustmanager。它需要okhttp-ws模块来运行。 但是,它在:app:checkDebugDuplicateClasses上失败了 Execution failed for task ':app:checkDebugDuplicateClasses'.
> 1 exception was raised by workers:
java.lang.RuntimeException: java.lang.RuntimeException:
D
我们迁移到java 11,并开始不时地看到非常奇怪的请求失败,除了测试环境中的异常(它是部署到kubernetes的对接容器):
okhttp版本3.12.1:
java.lang.IndexOutOfBoundsException: Index: 0
at java.base/java.util.Collections$EmptyList.get(Collections.java:4481)
at okhttp3.internal.connection.RealConnection.connectTls(RealConnection.java:326)
at okht
我将react-native更新到最新版本(0.47.1),然后初始化了一个新的react-native项目,但根本无法运行它。okhttp3有一个SSL问题,我没有单独安装它。我在cacerts文件中添加了证书,该文件位于以下文件夹:C:\Program Files\Java\jre7\lib\security;,但仍有问题。
这是堆栈跟踪:
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':app'
在过去的几周里,我看到很多在import语句行中使用行号的崩溃。
例如,在第2行出现崩溃的堆栈跟踪
Fatal Exception: java.lang.IllegalArgumentException: Unexpected TLS version: NONE
at okhttp3.TlsVersion.forJavaName(TlsVersion.java:2)
at okhttp3.Handshake.get(Handshake.java:4)
at okhttp3.internal.connection.RealConnection.connectTls(RealCo
我只需要下载和保存文件,只有'okhttp'库在‘节点js',而不是在java。但我不知道怎么把我的文件保存在我的电脑上。我只需要使用okhttp库。请帮帮我。
okhttp:
const okhttp = require('okhttp');
var MimeBuilder = okhttp.MimeBuilder;
var Request = okhttp.Request;
var RequestBody = okhttp.RequestBody;
var RequestBuilder = okhttp.RequestBuilder;
var Fo
正在尝试将RN与Firebase集成。显然,我得到了下一个错误: Cannot find a version of 'com.squareup.okhttp3:okhttp' that satisfies the version constraints:
Dependency path 'getnow:react-native-firebase:unspecified' --> 'com.facebook.react:react-native:0.57.7' --> 'com.squareup.okhttp3:okh
Alexa应用程序不断崩溃,并给出了这个总结。
`
java.lang.IllegalStateException:无法发出新请求,因为前面的响应e仍然处于打开状态:请调用response.close()
at okhttp3.internal.connection.Transmitter.newExchange$okhttp(Transmitter.kt:14)
at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.kt:5)
at okhttp3.internal.http.Real
我从几个月前就已经集成了retrofit2;直到昨天还没有出现用户问题(华为,MHA-L29型号,Android7.0):
Fatal Exception: java.lang.IllegalArgumentException: Unexpected TLS version: NONE
at okhttp3.TlsVersion.forJavaName(TlsVersion.java:53)
at okhttp3.Handshake.get(Handshake.java:56)
at okhttp3.internal.connection.RealCo
有时,我的app从后台到前台崩溃,其logcat如下:
Fatal Exception: java.lang.StackOverflowError
at com.android.org.bouncycastle.asn1.DefiniteLengthInputStream.read(DefiniteLengthInputStream.java:74)
at java.io.FilterInputStream.read(FilterInputStream.java:118)
at com.android.org.bouncycastle.asn1.Def
我在我的项目中使用Retrofit-1.6.0 + okhttp-2.0.0-RC1。当我运行这个项目时,我会得到错误。
java.lang.RuntimeException: Retrofit detected an unsupported OkHttp on the classpath.
To use OkHttp with this version of Retrofit, you'll need:
1. com.squareup.okhttp:okhttp:1.6.0 (or newer)
2. com.squareup.okhttp:okhttp-urlconnection:
我使用的是毕加索2.3.2和okhttp 1.5.4
最初我得到的是这样的RTE:
java.lang.RuntimeException: Picasso detected an unsupported OkHttp on the classpath.
To use OkHttp with this version of Picasso, you'll need:
1. com.squareup.okhttp:okhttp:1.6.0 (or newer)
2. com.squareup.okhttp:okhttp-urlconnection:1.6.0 (or newer)
Note
网络都是正,为什么只有bugly 的接口检测就提示UnknownHostException: Unable to resolve host "android.bugly.qq.com":
CrashReport: java.net.UnknownHostException: Unable to resolve host "android.bugly.qq.com": No address associated with hostname
at java.net.Inet6AddressImpl.lookupHostByName(Inet6Add
E/JavaBinder: *** Uncaught remote exception! (Exceptions are not yet supported across processes.)
java.lang.ArrayIndexOutOfBoundsException: length=8192; index=8192
at com.android.okhttp.okio.Buffer.writeByte(Buffer.java:973)
at com.android.okhttp.internal.Platform.concatLengthPrefixed
我正在使用改装-beta2 2和我得到以下崩溃不时。我不知道我做错了什么。如果有人能给我一个解决这个问题的提示,那就太好了。
Fatal Exception: java.util.NoSuchElementException
at com.squareup.okhttp.internal.http.RouteSelector.next(RouteSelector.java:79)
at com.squareup.okhttp.internal.http.StreamAllocation.findConnection(StreamAllocation.
我使用okhttp向服务器发送请求,但收到以下错误 Server chose TLSv1, but that protocol version is not enabled or not supported by the client.
javax.net.ssl.SSLHandshakeException: Server chose TLSv1, but that protocol version is not enabled or not supported by the client.
at sun.security.ssl.ClientHandshaker.serverHel
这是我在运行最近继承的Android应用程序时获得的堆栈跟踪。我们没有使用OkHttp作为显式依赖项,而跟踪中的com.android.okhttp让我认为AOSP现在在内部使用OkHttp?
java.lang.Throwable: Explicit termination method 'close' not called
E at dalvik.system.CloseGuard.open(CloseGuard.java:184)
E at com.android.org.conscrypt.OpenSSLSocketImpl.startHandsha