google/bundletool

[BT:1.13.2] Error: The bundle zip file contains directory zip entry 'BUNDLE-METADATA/' which is not allowed.

StarkZhidian opened this issue · 1 comments

Hi,I want to use this command to generate apk:
java -jar ./bundletool-all-1.13.2.jar build-apks --bundle=xxx.aab --output=xxxxx.apks
But I got this error:

[BT:1.13.2] Error: The bundle zip file contains directory zip entry 'BUNDLE-METADATA/' which is not allowed. com.android.tools.build.bundletool.model.exceptions.InvalidBundleException: The bundle zip file contains directory zip entry 'BUNDLE-METADATA/' which is not allowed. at com.android.tools.build.bundletool.model.exceptions.UserExceptionBuilder.build(UserExceptionBuilder.java:58) at com.android.tools.build.bundletool.validation.BundleZipValidator.validateBundleZipEntry(BundleZipValidator.java:33) at com.android.tools.build.bundletool.validation.ValidatorRunner.lambda$validateBundleZipFile$1(ValidatorRunner.java:48) at com.google.common.collect.ImmutableList.forEach(ImmutableList.java:422) at com.android.tools.build.bundletool.validation.ValidatorRunner.validateBundleZipFile(ValidatorRunner.java:47) at com.android.tools.build.bundletool.validation.AppBundleValidator.validateFile(AppBundleValidator.java:100) at com.android.tools.build.bundletool.commands.BuildApksCommand.execute(BuildApksCommand.java:892) at com.android.tools.build.bundletool.BundleToolMain.main(BundleToolMain.java:82) at com.android.tools.build.bundletool.BundleToolMain.main(BundleToolMain.java:54)

The source xxx.aab file was decompressed and recompressed from origin aab file.
But if I use origin source aab file generated by gradle task(bundleRelease) as input, then it's ok.

I was confused about this, could someone help me?

Thank u.

solved