google / google/bundletool

[Bug report] The "get-size total" command incorrectly includes the size of dynamic feature modules that are only install in certain regions

Open
#320 0 comments 4 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
4k
Forks
428
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
We created a dynamic feature module for a feature that is only used in the US region. The manifest delivery mode configuration for this module is as follows.
However, when we evaluated the APK download size of the newly generated bundle using the `bundletool get-size total --apks=/output dir/new_bundle.apks` command, we found that **both the min and max download size had increased due to the dynamic feature module** , even though we did not include the feature module in the command.

We can confirm that `bundletool` mistakenly includes all the dynamic feature modules that have the `install-time` delivery mode in the estimated APK download size. The minimum download size should not be affected by dynamic feature modules that have an `install-time` delivery mode for certain regions. Only the maximum download size should be affected.

```













```

**Bundletool version(s) affected**
1.14

**Stacktrace**
NA

**To Reproduce**
Steps to reproduce the behavior.

1. Create a new dynamic feature module, make the deliver mode as install time for specific country.
2. Generate bundle file
3. Using the `bundletool get-size total --apks=/output dir/new_bundle.apks` command to get new estimate apk download size
4. We found that the estimated minimum download size also increased due to the size of the dynamic feature modules.

**Expected behavior**
The minimum download size should not be affected by dynamic feature modules that have an `install-time` delivery mode for certain regions. Only the maximum download size should be affected.

**Known workaround**
The minimum download size should not be affected by dynamic feature modules that have an `install-time` delivery mode for certain regions.

**Environment:**
Android Studio, bundle tool, dynamic feature

**Additional context**
NA

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.