Open MKevin3 opened 6 years ago
I don't even add chuck as an interceptor unless I'm in debug mode. Why are you using it for release builds?
I thought the goal of
debugImplementation 'com.readystatesoftware.chuck:library:1.1.0'
releaseImplementation 'com.readystatesoftware.chuck:library-no-op:1.1.0'
Was to allow you to avoid this extra step
// Only add Chuck support for debug builds - its no-op mode is not perfect
@Suppress("ConstantConditionIf")
if (BuildConfig.DEBUG_MODE) {
builder.addInterceptor(ChuckInterceptor(App.instance))
}
It appears the no-op version is just to keep code size down, not to fully stop operation. I have everything working as I want with the extra code step shown above. Just did not think I was going to need to do it.
When I build in release mode and I cancel an OKHTTP call I get an exception as shown below.
The chuck.readystatesoftware.com.ChuckInterceptor.intercept should be full NO-OP but it is catching canceled calls and reporting them as IOExceptions. I turn around and catch those but I should not have to as I am already processing the isCanceled method on the original call.