okhttp-OkGo icon indicating copy to clipboard operation
okhttp-OkGo copied to clipboard

Unexpected TLS version: NONE

Open 494293346 opened this issue 7 years ago • 5 comments

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.RealConnection.connectTls(RealConnection.java:282) at okhttp3.internal.connection.RealConnection.establishProtocol(RealConnection.java:251) at okhttp3.internal.connection.RealConnection.connect(RealConnection.java:151) at okhttp3.internal.connection.StreamAllocation.findConnection(StreamAllocation.java:195) at okhttp3.internal.connection.StreamAllocation.findHealthyConnection(StreamAllocation.java:121) at okhttp3.internal.connection.StreamAllocation.newStream(StreamAllocation.java:100) at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:42) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:92) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:67) at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:93) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:92) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:67) at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:92) at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:120) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:92) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:67) at com.lzy.okgo.interceptor.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:76) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:92) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:67) at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:185) at okhttp3.RealCall$AsyncCall.execute(RealCall.java:135) at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636) at java.lang.Thread.run(Thread.java:764)

请问这是我使用不当造成的, 还是OK本身有这个问题呢?

494293346 avatar Jun 26 '18 09:06 494293346

我也遇到这个问题,你解决了吗?不知道怎么出现的,线上bugly有这个反馈

liweiGe avatar Jan 22 '19 06:01 liweiGe

我也是

zzzsssbo avatar Mar 23 '20 01:03 zzzsssbo

okgo3.0.4版本内部使用的okhttp3版本是3.8.1 okhttp3在3.10.0修复了这个问题 链接:https://square.github.io/okhttp/changelog_3x/

guozhicheng1987 avatar Apr 16 '20 17:04 guozhicheng1987

怎么将okgo中的okhttp更换为3.10.0版本呢

zzzsssbo avatar May 19 '20 03:05 zzzsssbo

是不在维护了吗?

chapliny avatar Mar 29 '21 05:03 chapliny