Google cloud translate API crashing for Android API level 19 or lower

  • Replies:0
  • OpenNot stickiedUnanswered
  • Forum posts: 1

Aug 29, 2018, 6:36:56 AM via Website

My Android App works fine on API level greater than 19. But when i run my app on API level 19 or lower, i crashes while opening. I tried removing Libraries from the gradle from which i concluded that below given libraries are causing the crash.

compile ('com.google.apis:google-api-services-translate:v2-rev47-1.22.0') {
exclude group: 'com.google.guava'
}
compile ('com.google.cloud:google-cloud-translate:0.5.0') {
exclude group: 'io.grpc', module: 'grpc-all'
exclude group: 'com.google.protobuf', module: 'protobuf-java'
exclude group: 'com.google.api-client', module: 'google-api-client-appengine'
}

The specified versions are :
Android Studio Version: 3.1.4
compileSdkVersion: 22
buildToolsVersion: 22
minSdkVersion: 16
targetSdkVersion: 22

These are the logs:

java.lang.NoClassDefFoundError: com.google.android.gms.internal.zzno
at com.google.android.gms.measurement.internal.zzx.zzj(Unknown Source)
at com.google.android.gms.measurement.internal.zzt.(Unknown Source)
at com.google.android.gms.measurement.internal.zzx.zzBQ(Unknown Source)
at com.google.android.gms.measurement.internal.zzt.zzaU(Unknown Source)
at com.google.android.gms.measurement.AppMeasurementContentProvider.onCreate(Unknown Source)
at android.content.ContentProvider.attachInfo(ContentProvider.java:1591)
at android.content.ContentProvider.attachInfo(ContentProvider.java:1562)
at android.app.ActivityThread.installProvider(ActivityThread.java:4790)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:4385)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4325)
at android.app.ActivityThread.access$1500(ActivityThread.java:135)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1256)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5017)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
at dalvik.system.NativeStart.main(Native Method)

I need to know exactly why is this happening. And what is the solution.
Any help is most appreciated. Thanks. :)

Be the first to answer

Recommended articles