Fixed
Status Update
Comments
xa...@android.com <xa...@android.com> #2
Is this fixed? I'm still seeing this issue with AGP 8.1.0-beta01 + Gradle 8.1
[Deleted User] <[Deleted User]> #3
The fix has not been landed.
je...@google.com <je...@google.com>
hu...@gmail.com <hu...@gmail.com> #4
Due to this bug in CI we hit configuration cache invalidation 100% of the time. Can we make sure the fix lands soon? And especially before 8.1.0 stable.
cu...@gmail.com <cu...@gmail.com> #5
I cc'ed you on the CL which should be landed this week.
ch...@google.com <ch...@google.com>
jo...@google.com <jo...@google.com>
xa...@google.com <xa...@google.com>
hu...@google.com <hu...@google.com> #6
Aurimas, is this 8.1 blocking for Androidx? If not, feel free to remove the "Blocking release" label.
Description
Android gradle plugin version: 0.13.1
OS: MacOS
STEPS TO REPRODUCE:
1. Add a string to res/values/strings.xml
e.g. <string name="app_name">SimpleTest</string>
2. Add a product flavor which overrides this string:
productFlavors {
INT {
resValue "string", "app_name", "SimpleTest INT"
}
}
3. Execute:
gradle assembleINTDebug
EXPECTED RESULTS:
Build succeeds and the app is named "SimpleTest INT"
OBSERVED RESULTS:
Build fails with error:
:SimpleTest:mergeINTDebugResources FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':SimpleTest:mergeINTDebugResources'.
> /Users/xyz/AndroidStudioProjects/SimpleTest/SimpleTest/build/generated/res/generated/INT/debug/values/generated.xml: Error: Duplicate resources: /Users/xyz/AndroidStudioProjects/SimpleTest/SimpleTest/build/generated/res/generated/INT/debug/values/generated.xml:string/app_name, /Users/xyz/AndroidStudioProjects/SimpleTest/SimpleTest/src/main/res/values/strings.xml:string/app_name
ADDITIONAL INFORMATION:
When I add a resource file via a sourceSet for this build flavor instead of using resValue, I can successfully override the app_name.
I think setting a resource with resValue should behave the same as when using a sourceSet.