uservoice/uservoice-android-sdk

IllegalAccessError - incompatible with New Relic

Opened this issue · 0 comments

In the UserVoice init method we are seeing a chain of calls that ultimately gets to BabayagaTask.doInBackground(args) which is using OkHttp. It seems like it's using a version of OkHttp that is not compatible with NewRelic and is causing a crash.

E/UncaughtException: java.lang.RuntimeException: An error occurred while executing doInBackground() ......

Caused by: java.lang.IllegalAccessError: Method 'void com.squareup.okhttp.Call.(com.squareup.okhttp.OkHttpClient, com.squareup.okhttp.Request)' is inaccessible to class 'com.newrelic.agent.android.instrumentation.okhttp2.CallExtension' (declaration of 'com.newrelic.agent.android.instrumentation.okhttp2.CallExtension' appears in /data/app/appname.debug-5RvW1p6O37wA3Wu8tGTF4g==/split_lib_dependencies_apk.apk)
at com.newrelic.agent.android.instrumentation.okhttp2.CallExtension.(CallExtension.java:31)
at com.newrelic.agent.android.instrumentation.okhttp2.OkHttp2Instrumentation.newCall(OkHttp2Instrumentation.java:36)
at com.uservoice.uservoicesdk.babayaga.BabayagaTask.doInBackground(BabayagaTask.java:81)
at com.uservoice.uservoicesdk.babayaga.BabayagaTask.doInBackground(BabayagaTask.java:21)
at android.os.AsyncTask$2.call(AsyncTask.java:333)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:245) 
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162) 
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636) 
at java.lang.Thread.run(Thread.java:764) 

Our app is using:
com.uservoice:uservoice-android-sdk:1.2.6'
compile 'com.newrelic.agent.android:android-agent:5.16.0'
compile 'com.squareup.okhttp3:okhttp:3.8.1'

Is this something you've encountered before?