My app crashes at the time of beginning and generates the below error.
The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
So in order to fix an error I changed the build.gradle(project level) from
classpath 'com.android.tools.build:gradle:3.1.2'
classpath 'com.google.gms:google-services:3.0.0'
classpath 'io.fabric.tools:gradle:1.25.4'`
to
classpath 'com.android.tools.build:gradle:3.1.4'
classpath 'com.google.gms:google-services:4.1.0'
classpath 'io.fabric.tools:gradle:1.25.4'
and build.gradle(app level)
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.android.support:support-v4:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.google.android.gms:play-services-gcm:11.8.0'
implementation 'com.google.firebase:firebase-core:11.8.0'
implementation 'com.google.firebase:firebase-crash:11.8.0'
implementation 'com.google.firebase:firebase-auth:11.8.0'
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.3'
to
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
implementation 'com.android.support:support-v4:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.google.android.gms:play-services-gcm:15.0.1'
implementation 'com.google.firebase:firebase-core:16.0.3'
implementation 'com.google.firebase:firebase-crash:11.8.0'
implementation 'com.google.firebase:firebase-auth:11.8.0'
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.5'
After change of above gradle code, my project is running well without the below error.
The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.
But the above gradle changes create another error which is created at runtime when we call activity from one to another which I'm not able to solve, which is as below.
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/..../insta/InstaSplashActivity;
Here, InstaSplashActivity
is an activity that will be called from the first activity, which is creating a crash.