I have problem with building our app with new Google's feature which name is App Bundle.
When I run ./gradlew app:packageProductionReleaseBundle --stacktrace command, I receive:
Execution failed for task ':app:packageProductionReleaseBundle'.
            java.util.concurrent.ExecutionException: com.android.tools.build.bundletool.exceptions.ValidationException: Error validating module 'base'.
                              ...
                           LONG STACK TRACE...
                              ...
Caused by: com.android.tools.build.bundletool.exceptions.BundleFileTypesException$FileUsesReservedNameException: File 'root/res/drawable/adoceansdk_close_interstitial_button.png' uses reserved file or directory name 'res'.
                at com.android.tools.build.bundletool.validation.BundleFilesValidator.validateModuleFile(BundleFilesValidator.java:112)
                at com.android.tools.build.bundletool.validation.ValidatorRunner.lambda$validateBundleModules$6(ValidatorRunner.java:73)
                at com.google.common.collect.ImmutableList.forEach(ImmutableList.java:406)
                at com.android.tools.build.bundletool.validation.ValidatorRunner.validateBundleModules(ValidatorRunner.java:73)
The reason for this is the external library in .jar we use.
How can I fix it without removing this library?
Thank you for the answer in advance.
If this external library is meant to be used in an Android app, I believe it should be exported as an AAR, not a JAR. See https://developer.android.com/studio/projects/android-library
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With