Search Issue Tracker
By Design
Votes
0
Found in
2023.1.0b17
2023.2.0a15
Issue ID
UUM-35706
Regression
No
[Android] Build fails with com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable error when building a specific Android project
Reproduction steps:
1. Open the attached “BugRepro” project
2. Click Edit > Project Settings > Publishing settings > Disable Custom Keystore
3. Click File > Build
Expected result: Build finishes successfully
Actual result: Build fails
Reproducible with: 2023.1.0b17, 2023.2.0a15
Couldn’t test with: 2020.3.48f1, 2021.3.25f1, 2022.2.20f1 (UUM-35704: Build freezes when building a specific android project), 2023.1.0a1 (Failed to update Android SDK package list.)
Reproducible on: Windows 10, Ubuntu 22.10
Full error:
Execution failed for task ':launcher:checkReleaseDuplicateClasses'. > A failure occurred while executing com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable > Duplicate class com.unity3d.ads.BuildConfig found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.IUnityAdsInitializationListener found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.IUnityAdsLoadListener found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.IUnityAdsShowListener found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.IUnityAdsTokenListener found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.UnityAds found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.UnityAds$1 found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:) Duplicate class com.unity3d.ads.UnityAds$UnityAdsInitializationError found in modules UnityAds-runtime (:UnityAds:) and com.unity3d.ads.unity-ads-4.7.1-runtime (:com.unity3d.ads.unity-ads-4.7.1:)
Note: Didn’t test other 2023.1 versions, because of the long build time
Comments (2)
-
YousafGrewal
Oct 14, 2023 15:50
Same problem in unity 2022.3.4f1
-
Dimchik_chik
Aug 11, 2023 09:23
Same problem, can't find a solution
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- "GetPreferedValue" returns max value when using auto-sizing
- UI Builder doesn't update the style sheet when using "Extract inline style" right-click option
- “Assertion failed on expression” errors thrown when undoing Nodes creation with keyboard shortcut
- Crash on various stack traces when using Texture2D.CreateExternalTexture() while rendering
- Clicking on section text in Node Library > Context folder throws NullReferenceException errors
Resolution Note:
Issues with external libraries in the project. Need to be sorted out in the project, such as upgrading Unity Ads.