20

In RunTime show error in Gradle the error:

Error:Execution failed for task ':app:transformClassesWithInstantRunForDebug'.

Unexpected inputs: ImmutableJarInput{name=com.google.android.gms:play-services-basement:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/43.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.firebase:firebase-analytics:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/37.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.android.gms:play-services-base:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/39.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.firebase:firebase-common:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/41.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.firebase:firebase-core:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/36.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.android.gms:play-services-tasks:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/42.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.firebase:firebase-analytics-impl:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/38.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}, ImmutableJarInput{name=com.google.firebase:firebase-iid:9.0.0, file=/home/nawaf/AndroidStudioProjects/YugiohDeckBuilder/app/build/intermediates/transforms/profilers-transform/debug/40.jar, contentTypes=CLASSES, scopes=EXTERNAL_LIBRARIES, status=REMOVED}

Gradle project-level:

dependencies {
        classpath 'com.android.tools.build:gradle:3.0.1'
        classpath 'com.google.gms:google-services:3.1.0'

    }

gradle app-level:

dependencies {
...
}
apply plugin: 'com.google.gms.google-services'
InsaneCat
  • 2,115
  • 5
  • 21
  • 40
Nawaf Abdu
  • 615
  • 1
  • 7
  • 13

4 Answers4

46

It seems you have enable Instant Run in Android Studio.

1) Disable Instant Run from File -> Settings -> Instant Run
2) Clean Your Project
3) Run Your App

Jaymin Soni
  • 451
  • 3
  • 10
23

Personally, Build => Clean Project and then rebuilding fixed it for me.

karuhanga
  • 3,010
  • 1
  • 27
  • 30
1

Remove Build Folder from Project->app->build and run your project.

Saljith Kj
  • 125
  • 2
  • 4
-3

When I Add this line the problem solved:

        MobileAds.initialize(getApplicationContext(), "ca-app-pub-xxxxxxxxxxxxx");

Thanks for all who response.

Nawaf Abdu
  • 615
  • 1
  • 7
  • 13