tinycreative / react-native-intercom

React Native wrapper for Intercom.io
MIT License
407 stars 280 forks source link

[Android] java.lang.ArithmeticException #427

Closed gziolle closed 3 years ago

gziolle commented 3 years ago

Hello! I caught this error through Google Play. Still not able to reproduce it.

java.lang.ArithmeticException: at io.intercom.android.sdk.api.ProgressRequestBody.writeTo (ProgressRequestBody.java:56) at io.intercom.okhttp3.MultipartBody.writeOrCountBytes (MultipartBody.java:173) at io.intercom.okhttp3.MultipartBody.writeTo (MultipartBody.java:114) at io.intercom.okhttp3.internal.http.CallServerInterceptor.intercept (CallServerInterceptor.java:72) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:147) at io.intercom.okhttp3.internal.connection.ConnectInterceptor.intercept (ConnectInterceptor.java:45) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:147) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:121) at io.intercom.okhttp3.internal.cache.CacheInterceptor.intercept (CacheInterceptor.java:93) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:147) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:121) at io.intercom.okhttp3.internal.http.BridgeInterceptor.intercept (BridgeInterceptor.java:93) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:147) at io.intercom.okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept (RetryAndFollowUpInterceptor.java:126) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:147) at io.intercom.okhttp3.internal.http.RealInterceptorChain.proceed (RealInterceptorChain.java:121) at io.intercom.okhttp3.RealCall.getResponseWithInterceptorChain (RealCall.java:250) at io.intercom.okhttp3.RealCall$AsyncCall.execute (RealCall.java:201) at io.intercom.okhttp3.internal.NamedRunnable.run (NamedRunnable.java:32) 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)

I'm using "react-native-intercom": "^16.0.0" and on build.gradle: 'io.intercom.android:intercom-sdk:6.+'

mccooll commented 3 years ago

Looks like that will be fixed for you in higher versions: https://github.com/intercom/intercom-android/releases/tag/7.1.0

gziolle commented 3 years ago

Thanks @mccooll!! I'll test it out and share the results here.

gziolle commented 3 years ago

@mccooll We updated the lib and the error no longer occurs. I'll close this issue. Thank you very much for your help!