Closed pt2121 closed 8 years ago
Thanks! I am looking into this.
@kaushikgopal I checked this and it seems to be an AOSP/OkHttp bug. Android framework assumes OkHttp's cancel
is blocking and yells android.os.NetworkOnMainThreadException. See https://github.com/square/okhttp/issues/1592, https://github.com/square/okhttp/issues/1862, and https://github.com/square/retrofit/issues/1046. Anyway, I added a workaround and rebased. Could you review this when have a chance?
@prt2121 it appears that we no longer require the workaround cause issues was fixed in a later version of okhttp. i've bumped the version(s) and merged in your code. Cheers and thanks for the great work!
@kaushikgopal thanks!
Thank you so much for this! I haven't gotten time to look into Retrofit 2 in detail.
However, i do notice a crash if you run the Retrofit fragment example, then hit the back button - you'll notice an RxJava related exception. We should fix this probably before merging in :)
Let me know if you can't reproduce it.