Status Update
Comments
ra...@google.com <ra...@google.com>
je...@google.com <je...@google.com>
cm...@google.com <cm...@google.com> #2
The toString was deliberately prefixed like this to make it clear this wasn't meant to be passed back as a maven version, as it wasn't necessarily consistent
Annoyingly 3.0 alphas, betas & rc and 3.0 beta and rc did not do this, although perhaps that doesn't matter so much
cm...@google.com <cm...@google.com> #3
It's a reasonable request that we do return something that exactly corresponds with the maven version though
tr...@block.xyz <tr...@block.xyz> #4
As a point of reference, the GradleVersion
class looks roughly like this:
public String toString() {
return "Gradle " + this.version;
}
public String getVersion() {
return this.version;
}
Also, I have what I think is a valid use-case for having the actual Maven version string. I use this string for building functional test fixtures for my Gradle plugin test suite. The AGP version is a parameter I pass in so I can test against multiple versions and ensure wide compatibility.
cm...@google.com <cm...@google.com> #5
an...@google.com <an...@google.com> #6
Thank you for your patience while our engineering team worked to resolve this issue. A fix for this issue is now available in:
- Android Studio Jellyfish | 2023.3.1 Canary 7
- Android Gradle Plugin 8.4.0-alpha07
We encourage you to try the latest update.
If you notice further issues or have questions, please file a new bug report.
Thank you for taking the time to submit feedback — we really appreciate it!
Description
DESCRIBE THE ISSUE IN DETAIL:
I have two requests for this issue:
AndroidPluginVersion
should not omit leading 0s for thepreview
property.AndroidPluginVersion
should have an immediately useful string representation that doesn't require stripping off the"Android Gradle Plugin version "
prefix. I use this string in many places inSTEPS TO REPRODUCE:
For example, if I call
toString()
on an instance of AGP from version 8.4.0-alpha01, it will returnAndroid Gradle Plugin version 8.4.0-alpha1
(note that it ends withalpha1
and notalpha01
.By contrast, if I look at the kdoc for
preview
, this is what it says:Where the leading 0 is clearly visible.
Version of Gradle Plugin: 8.4.0-alpha01 (and maybe earlier versions)