Status Update
Comments
sg...@google.com <sg...@google.com> #2
No these warnings where not supposed to be shown.
Right now the only way to get rid of them is to explicitly setting the handling of the default constructor with the system property com.android.tools.r8.enableEmptyMemberRulesToDefaultInitRuleConversion
. Setting it to true
keeps the current behavior. Setting it to false
will enable the more aggressive removal of the default constructors.
./gradlew -Dcom.android.tools.r8.enableEmptyMemberRulesToDefaultInitRuleConversion=true assembleMyAppRelease --rerun-tasks
If you instead try false
and you run into app failures, then the warnings you already got might help you in adding missing rules for this mode to work.
ch...@google.com <ch...@google.com>
ap...@google.com <ap...@google.com> #3
Project: r8
Branch: main
Author: Søren Gjesse <
Link:
Disable warnings for implicitly kept default constructors
Expand for full commit details
Disable warnings for implicitly kept default constructors
Fixes: b/372749733
Change-Id: I2e1ef97658dbf09fd2b2f1491d680a84c42bf49b
Files:
- M
src/main/java/com/android/tools/r8/shaking/ProguardConfigurationParserOptions.java
- M
src/test/java/com/android/tools/r8/shaking/EmptyMemberRulesToDefaultInitRuleConversionTest.java
Hash: 885e13fad6efe4cedb32707be1c874734ecd47c5
Date: Fri Oct 11 15:02:53 2024
ap...@google.com <ap...@google.com> #4
Project: r8
Branch: 8.7
Author: Søren Gjesse <
Link:
Disable warnings for implicitly kept default constructors
Expand for full commit details
Disable warnings for implicitly kept default constructors
Fixes: b/372749733
Change-Id: I2e1ef97658dbf09fd2b2f1491d680a84c42bf49b
Files:
- M
src/main/java/com/android/tools/r8/shaking/ProguardConfigurationParserOptions.java
- M
src/test/java/com/android/tools/r8/shaking/EmptyMemberRulesToDefaultInitRuleConversionTest.java
Hash: bb0cdd479176bf53cce74b1f10029dc7f454dde4
Date: Fri Oct 11 15:33:06 2024
ap...@google.com <ap...@google.com> #5
Project: r8
Branch: 8.7
Author: Søren Gjesse <
Link:
Version 8.7.18
Expand for full commit details
Version 8.7.18
Bug: b/370937458
Bug: b/372749733
Change-Id: I33726130f3bf37167ccefa22bcb0cd3d14f6a398
Files:
- M
src/main/java/com/android/tools/r8/Version.java
Hash: 84ea5eee063248e40efa5800a15412e89f45aa20
Date: Fri Oct 11 15:33:20 2024
m....@anfe.ma <m....@anfe.ma> #6
Thanks for the fast fix! :)
an...@google.com <an...@google.com> #7
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 Ladybug | 2024.2.1 Patch 2
- Android Gradle Plugin 8.7.2
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
I'm currently developing an Android App using Gradle & Android Studio.
I recently upgraded my project to
When running
./gradlew assembleMyAppRelease --rerun-tasks
i get lots of warnings of the following format:This might be a totally valid warning (can't judge). However, this does occur for
proguard-android-optimize.txt
which is the reason i'm writing this ticket.This warning also occurs for a few major dependencies' proguard files (e.g.
navigation-common-2.8.2/proguard.txt
,retrofit2.pro
) but i guess that's the job of the dependencies' maintainers.Might be related to: https://issuetracker.google.com/issues/225394515
Full warning text attached: