Android WebView not finding TracingController

Viewed 3302

I'm trying to write a simple app with a WebView, but when I create a WebView I get an error:

java.lang.NoClassDefFoundError: Failed resolution of: Landroid/webkit/TracingController;

I searched and found that TracingController is implemented from api level 28, but I only have 27.

How can I resolve this?

2 Answers

Might be late but helpful if someone has the same issue.I had same issue on my project and I figured out that issue is with the SDK version 28. - If you use the below sets of dependencies then you will not have this issue.

compileSdkVersion 27
buildToolsVersion '28.0.3'

minSdkVersion 16
targetSdkVersion 26

Also, I have included the dependencies used in my project. I have used MoPub SDK for Ads and Google AdMob & Facebook mediation adapters.

compile "com.android.support:appcompat-v7:27.1.1"
compile "com.android.support:design:27.1.1"
compile 'com.android.support.constraint:constraint-layout:1.1.3'
compile('com.crashlytics.sdk.android:crashlytics:2.6.5@aar') {
    transitive = true
}
compile 'com.android.support:multidex:1.0.3'
compile "com.google.firebase:firebase-core:16.0.1"
compile "com.google.firebase:firebase-ads:15.0.1"
compile "com.google.android.gms:play-services-analytics:15.0.0"
compile "com.google.firebase:firebase-config:15.0.0"
compile 'com.google.android.ads.consent:consent-library:1.0.6'

// Glide
compile 'com.github.bumptech.glide:glide:3.7.0'

/* Mopub SDK */
compile('com.mopub:mopub-sdk:5.3.0@aar') {
    transitive = true
}
compile 'com.mopub.mediation:admob:15.0.0.11'

compile 'com.mopub.mediation:facebookaudiencenetwork:5.0.0.0'
compile 'com.facebook.android:audience-network-sdk:5.0.0'

same issue here, only appearing on Android 8 in ionic after building with --release. The app shows the splash screen and then is stuck in white screen

Related