pandora icon indicating copy to clipboard operation
pandora copied to clipboard

java.io.EOFException

Open LeonDevLifeLog opened this issue 6 years ago • 6 comments

2019-06-18 15:45:47.748 3510-17027/com.example.app W/System.err: java.io.EOFException
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okio.RealBufferedSource.require(RealBufferedSource.java:61)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okio.GzipSource.consumeHeader(GzipSource.java:114)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okio.GzipSource.read(GzipSource.java:73)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okio.Buffer.writeAll(Buffer.java:1135)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okio.RealBufferedSource.readString(RealBufferedSource.java:199)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at tech.linjiang.pandora.network.OkHttpInterceptor.sourceToStrInternal(OkHttpInterceptor.java:313)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at tech.linjiang.pandora.network.OkHttpInterceptor.requestBodyAsStr(OkHttpInterceptor.java:262)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at tech.linjiang.pandora.network.OkHttpInterceptor.insert(OkHttpInterceptor.java:118)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at tech.linjiang.pandora.network.OkHttpInterceptor.intercept(OkHttpInterceptor.java:50)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:254)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okhttp3.RealCall$AsyncCall.execute(RealCall.java:200)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32)
2019-06-18 15:45:47.749 3510-17027/com.example.app W/System.err:     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
2019-06-18 15:45:47.750 3510-17027/com.example.app W/System.err:     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
2019-06-18 15:45:47.750 3510-17027/com.example.app W/System.err:     at java.lang.Thread.run(Thread.java:784)

LeonDevLifeLog avatar Jun 18 '19 07:06 LeonDevLifeLog

你好,这个看起来是网络连接传输这块的问题,和有没有Pandora应该没关系,可能是数据流还没传输完网络突然中断了。不知道你这边是一直出错还是仅这一次情况?

whataa avatar Jun 20 '19 05:06 whataa

一直出现

LeonDevLifeLog avatar Jun 20 '19 08:06 LeonDevLifeLog

方便发一个可测试的api吗,我这边调试下。顺便问一下,你的http请求是通过OKHttp发送的还是原生的HTTPURLConnection方式

whataa avatar Jun 20 '19 09:06 whataa

retrofit,具体不太清楚哪个api产生的,我来调试一下

LeonDevLifeLog avatar Jun 20 '19 11:06 LeonDevLifeLog

请问有任何新进展吗

whataa avatar Jul 08 '19 02:07 whataa

pandora和oss上传文件一起使用会报错: java.io.IOException: read failed: EBADF (Bad file descriptor) at libcore.io.IoBridge.read(IoBridge.java:478) at java.io.FileInputStream.read(FileInputStream.java:177) at okio.Okio$2.read(Okio.java:140) at com.alibaba.sdk.android.oss.network.ProgressTouchableRequestBody.writeTo(ProgressTouchableRequestBody.java:56) at okhttp3.internal.http.CallServerInterceptor.intercept(CallServerInterceptor.java:72) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:45) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:93) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:126) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) ....

ywqian avatar Nov 03 '20 06:11 ywqian