I added ResideMenu in my project using its gradle dependency. but i am getting this issue :
Error:Execution failed for task ':app:transformClassesWithJarMergingForDebug'.
com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: com/nineoldandroids/animation/Animator$AnimatorListener.class
when i checked the external libraries i found that library-2.4.0 and resideMenu-1.6 both contains com.nineoldandroids :
I went through almost all similar problems here on stackoverflow and tried the solutions. Can anyone tell me what needs to be done to remove this issue.
Below are the dependencies that i am using in my project :
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.jakewharton:butterknife:7.0.1'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.pnikosis:materialish-progress:1.7'
compile 'com.loopj.android:android-async-http:1.4.9'
compile 'com.google.code.gson:gson:2.6.2'
compile 'com.wrapp.floatlabelededittext:library:0.0.6'
compile 'com.android.support:multidex:1.0.1'
compile 'com.specyci:residemenu:1.6+'
}
You can exclude nineoldandroids from one your your dependencies. i.e:
Change below:
compile 'com.specyci:residemenu:1.6+'
With this:
compile ('com.specyci:residemenu:1.6+') {
exclude group: 'com.nineoldandroids', module: 'library'
}
NOTE: To list all sub dependencies tree, use gradle dependencies
or gradlew dependencies
commands. Then you can get the correct group and module names for the library which you want to exclude.
Adding exclude command with another library resolved the issue :
compile ('com.wrapp.floatlabelededittext:library:0.0.6'){
exclude group: 'com.nineoldandroids', module: 'library' }
compile ('com.specyci:residemenu:1.6+') {
exclude group: 'com.nineoldandroids', module: 'library' }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With