android - Excluding jar file duplicate from build -


first of all, got this:

* went wrong: execution failed task ':app:transformclasseswithjarmergingfordebug'. > com.android.build.api.transform.transformexception: java.util.zip.zipexception: duplicate entry: com/nostra13/universalimageloader/cache/disc/diskcache.class 

i use universalimageloader jar in app project, have library module uses exact same jar.

i tried add app build.gradle file:

 compile (project(':imagesubsampling')){         exclude group: 'com.nostra13.universalimageloader', module: 'com.nostra13.universalimageloader'     } 

or

 compile (project(':imagesubsampling')){         exclude group: 'com.nostra13', module: 'universalimageloader'     } 

or

 compile (project(':imagesubsampling')){         exclude group: 'com.nostra13.universalimageloader'     } 

nothing works.
therefore, question is:

 compile (project(':imagesubsampling')){        <what write here exclude jar file library>     } 

is there better solution rid of duplicates?
write exactly?

i met issue when there're more one universal image loader reference in project(maybe in libs folder, or in dependencies of project,sublibs).

check again build.gradle files(in android studio) in project.keep 1 , delete others solve problem.


Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

How to get the ip address of VM and use it to configure SSH connection dynamically in Ansible -

javascript - Get parameter of GET request -