1

I have a project and a Library included in it, If I enable instant run it generates an apk and runs on some phones while on others it crashes immediately even before splash.
If I disable Instant Run I get

java.util.zip.ZipException: duplicate entry: com/nostra13/universalimageloader/cache/disc/DiscCacheAware.class

I can't manage to solve, any help would be appreciated. Here's my Gradle File:

apply plugin: 'com.android.application'

android {
compileSdkVersion 22
buildToolsVersion "23.0.2"

defaultConfig {
    applicationId "com.ids.aldana"
    minSdkVersion 17
    targetSdkVersion 22
    multiDexEnabled true
}

buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
    }
}


}

 dependencies {
compile 'com.android.support:appcompat-v7:22.2.1' //23.4.0
compile 'com.android.support:design:22.2.1'
compile 'com.android.support:recyclerview-v7:22.2.1'
compile project(':viewPagerIndicatorLibrary')
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.3'
compile files('libs/YouTubeAndroidPlayerApi.jar')
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.squareup.okhttp:okhttp:2.4.0'
   }

My Library Gradle:

android {
compileSdkVersion 16
buildToolsVersion "23.0.2"

defaultConfig {
    minSdkVersion 4
    targetSdkVersion 4
    multiDexEnabled true
}

buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
    }
}
}

dependencies {
compile 'com.android.support:support-v4:22.2.1'
compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.3'
}

Can anybody point out the duplicates and tells me how to remove them?

eshteghel company
  • 471
  • 1
  • 7
  • 22

0 Answers0