aapt2-proto dependency required for public API but not available
Using 1.1.0 as a library from maven.google.com has a dependency declared on 'aapt2-proto' in the pom.xml as runtime. This means that it will be present on the runtime classpath but not on the compile-time classpath. This means that if you try to invoke API functions which accept or return these types your code will not resolve.
For example, create a project which depends on 1.1.0 and try to call com.android.tools.build.bundletool.model.utils.xmlproto.XmlProtoNode's constructor with an XmlNode. This is impossible because the dependency is not on the compile classpath. You are required to maintain an explicit dependency on 'aapt2-proto' yourself which requires keeping it in sync with bundletool which isn't great.
The aapt2-proto dependency should likely be switched from shadow to api and the redundant shadow exclude of com.android.aapt can then be removed.
You are perfectly correct.
This is a hack currently in place caused by the unfortunate way that AGP releases all its libraries to Maven together, bundletool depends on some of these libraries (e.g. apkzlib, apksig, ...), and AGP depends on bundletool. Packaging the classes of those libraries in the Maven artifact (after renaming them), and using shadowJar is the only way we've found to make this work so far.
We have some ideas on how to fix this, but this work hasn't been prioritized yet.