Android: Duplicate class XX found in modules

Viewed 98

Good morning friends, I need help.

This project needs to use these two libraries. And when compiling they are having a conflict because there are certain classes.

In fact, I already separated them as "independent" modules and I keep getting the error.

I call the two libraries in the build.gradle (:app) like this:

    implementation project(path: ':smartill')
    implementation project(path: ':smartill-mini-plus')

also, add in gradle.properties

android.useAndroidX=true
android.enableJetifier=true

Any ideas to separate them?

enter image description here

enter image description here

Error text:

Execution failed for task ':app:checkPaStagingDuplicateClasses'.
> 1 exception was raised by workers:
java.lang.RuntimeException: Duplicate class com.dm.commonlib.ThreadPoolManager found in 
modules jetified-smart_minilib_v1.0.9-runtime.jar 
(smart_minilib_v1.0.9.aar) and jetified-tilllib-runtime.jar (tilllib.aar)
Duplicate class com.dm.commonlib.Utils found in modules jetified-smart_minilib_v1.0.9- 
runtime.jar (smart_minilib_v1.0.9.aar) and jetified-tilllib-runtime.jar (tilllib.aar)
0 Answers
Related