-
Notifications
You must be signed in to change notification settings - Fork 9.1k
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
NullPointerException in okhttp3.internal.http.RealInterceptorChain.proceed with synchronous implementation. Thousands of reports #3676
Comments
What version of OkHttp are you using? Have you tried 3.9.0? |
I don't know... I use the version embedded in Retrofit2 v2.3.0. |
Add the dependency explicitly.
…On Mon, Nov 6, 2017 at 11:55 AM rfoa ***@***.***> wrote:
I don't know... I use the version embedded in Retrofit2 v2.3.0.
How can I force the retrofit to use version 3.9.0 of OkHttp?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#3676 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAEEEYye_VnOZsv3JvFl4Xu1gr4S9PpJks5sz2QmgaJpZM4QTxvW>
.
|
Ok, I got it. I'll do it. Thanks. Do you have any idea of the cause of this error? |
@rfoa any luck reproducing with 3.9.0 or 3.9.1? If not, I'll close and you can reopen once we can reproduce on a recent version. |
I've released an update from my application to production using a staged rollout, so I can not say with 100% accuracy. |
I analyzed the error reports carefully and can say that the problem has been solved.
But I can not say which change corrected the problem. |
I use Retrofit2 in my project and lately I'm getting thousands of daily errors from okHttp, according to the Google Play Console Crashes Reports.
Although not directly handle the okHttp, the error log only refer to it... If necessary, I post in the Retrofit2 Github too.
The errors started happening after I started using the Refrofit synchronously (
call.execute
) from within AsyncTaskLoader.I think my implementation is right, since I call
call.execute()
from within theloadInBackground()
method and make the appropriate try/catch.However, when using Retrofit asynchronously (
call.enqueue
) there was no error.I thought Retrofit was returning a null object after it was created (
APIServiceGenerator.createService
), but the problem continues even though the code is surrounded by a NullPointerException try/catch.Unfortunately I can not debug this error because the same error does not occur in my development environment, even testing on real devices and forcing connection failures. Errors only happen when the app is in production.
Please help me. Thanks.
Note: at the moment I can not use RxJava, so I used the AsyncTaskLoader.
List of OS Version
List of Devices
Google Play Error Report 1
Google Play Error Report 2
Project dependencies
My simple AsyncTaskLoader
The text was updated successfully, but these errors were encountered: