Error:Execution failed for task ':app:transformClassesWithJarMergingForDebug'

前端 未结 11 852
抹茶落季
抹茶落季 2020-11-22 16:37

Good day. After updating google repository in AndroidStudio, I have an issue

> Error:Execution failed for task \':app:transformClassesWithJarMergingForDe         


        
相关标签:
11条回答
  • 2020-11-22 17:02

    In terminal execute in root project folder:

    ./gradlew clean
    

    It helped me.

    0 讨论(0)
  • 2020-11-22 17:04

    I resolve this is by changing the version no of recyleview to recyclerview-v7:24.2.1. Please check your dependencies and use the proper version number.

    0 讨论(0)
  • 2020-11-22 17:05

    All the above not working for me.. Because I am using Facebook Ad dependency..

    Incase If anybody using this dependency compile 'com.facebook.android:audience-network-sdk:4.16.0'

    Try this code instead of above

    compile ('com.facebook.android:audience-network-sdk:4.16.0'){
    exclude group: 'com.google.android.gms'
    }
    
    0 讨论(0)
  • 2020-11-22 17:05

    see if their duplicate jars or dependencies your adding remove it and your error will be gone: Eg: if you add android:supportv4 jar and also dependency you will get the error so remove the jar error will be gone

    0 讨论(0)
  • 2020-11-22 17:06

    For me the issue was caused by com.google.android.exoplayer conflicting with com.facebook.android:audience-network-sdk.

    I fixed the problem by excluding the exoplayer library from the audience-network-sdk :

    compile ('com.facebook.android:audience-network-sdk:4.24.0') {
        exclude group: 'com.google.android.exoplayer'
    }
    
    0 讨论(0)
  • 2020-11-22 17:08

    I got this error because I did not have the correct line in my build.gradle. I am using the org.apache.http.legacy.jar library, which requires this:

    android{
       useLibrary 'org.apache.http.legacy'
    
       ...
    }
    

    So check that you have everything in your gradle file that is required.

    0 讨论(0)
提交回复
热议问题