Add the text below to build.gradle in the android{} section to solve the problem.
android { ... packagingOptions { exclude 'jsr305_annotations/Jsr305_annotations.gwt.xml' exclude 'build-data.properties' } ... }
If you get more errors, a DuplicateFileException adds an exception file. For example:
Mistake
Duplicate files copied in APK jsr305_annotations/Jsr305_annotations.gwt.xml
Decision
exclude 'jsr305_annotations/Jsr305_annotations.gwt.xml'
Lokesh patel
source share