Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

java.lang.IllegalStateException at okio.AsyncTimeout.enter #6279

Closed
tateisu opened this issue Sep 22, 2020 · 4 comments
Closed

java.lang.IllegalStateException at okio.AsyncTimeout.enter #6279

tateisu opened this issue Sep 22, 2020 · 4 comments
Labels
bug Bug in existing code needs info More information needed from reporter
Milestone

Comments

@tateisu
Copy link

tateisu commented Sep 22, 2020

(this is NOT dupe of #3641, #3893)

  • using okhttp 4.8.1
  • happen on Android 10(SDK 29),Android 7.0(SDK 24),Android 9(SDK 28)
java.lang.IllegalStateException: 
  at okio.AsyncTimeout.enter (AsyncTimeout.kt:49)
  at okio.AsyncTimeout$source$1.read (AsyncTimeout.kt:157)
  at okio.RealBufferedSource.indexOf (RealBufferedSource.kt:349)
  at okio.RealBufferedSource.readUtf8LineStrict (RealBufferedSource.kt:222)
  at okhttp3.internal.http1.Http1ExchangeCodec.readHeaderLine (Http1ExchangeCodec.kt:210)
  at okhttp3.internal.http1.Http1ExchangeCodec.readResponseHeaders (Http1ExchangeCodec.kt:181)
  at okhttp3.internal.connection.Exchange.readResponseHeaders (Exchange.kt:105)
  at okhttp3.internal.http.CallServerInterceptor.intercept (CallServerInterceptor.kt:82)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.connection.ConnectInterceptor.intercept (ConnectInterceptor.kt:37)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:87)
  at okhttp3.internal.cache.CacheInterceptor.intercept (CacheInterceptor.kt:82)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:87)
  at okhttp3.internal.http.BridgeInterceptor.intercept (BridgeInterceptor.kt:84)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept (RetryAndFollowUpInterceptor.kt:71)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:87)
  at jp.juggler.subwaytooter.App1$Companion$user_agent_interceptor$1.intercept (App1.kt:241)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:87)
  at jp.juggler.subwaytooter.util.ProgressResponseBody$Companion$makeInterceptor$1.intercept (ProgressResponseBody.kt:35)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:112)
  at okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.kt:87)
  at okhttp3.RealCall.getResponseWithInterceptorChain (RealCall.kt:184)
  at okhttp3.RealCall$AsyncCall.run (RealCall.kt:136)
  at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1167)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:641)
  at java.lang.Thread.run (Thread.java:919)
@tateisu tateisu added the bug Bug in existing code label Sep 22, 2020
@swankjesse
Copy link
Member

Executable test case? Typically this indicates thread-unsafe access to streams.

@yschimke yschimke added the needs info More information needed from reporter label Sep 23, 2020
@swankjesse swankjesse added this to the Backlog milestone Oct 2, 2020
@zeroDivider
Copy link

According to our QA, bug happens when they leave phone, not clicking anything.
Our app is calling backend every 5s and at some point this crash happens.
Additionally, it mostly happens on Sony android 12. I have seen it once in prod crashes, but cannot recall what device it was.

I got here from #6262

@yschimke
Copy link
Collaborator

@zeroDivider do you use websockets? If so, should hopefully be fixed by this fix in an upcoming 4.x release #7817

@zeroDivider
Copy link

Yes! When is it going to be released?

Thank you for your comment. I'll upgrade when it gets out and follow up :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug in existing code needs info More information needed from reporter
Projects
None yet
Development

No branches or pull requests

4 participants