Build : Passage aux R classes non transitives (suppression de android.nonTransitiveRClass=false).#61
Open
Spriana wants to merge 1 commit into
Open
Conversation
….nonTransitiveRClass=false). Le flag android.nonTransitiveRClass=false, ajouté par l'assistant de migration AGP, forçait des R classes transitives ; le non transitif est le défaut depuis AGP 8. Le seul code qui en dépendait référençait un attribut de bibliothèque via le R de l'app : R.attr.colorPrimary dans AbsThemedActivity, colorPrimary étant déclaré par appcompat et non par l'app. Migration : R.attr.colorPrimary -> androidx.appcompat.R.attr.colorPrimary (2 occurrences, lignes 37 et 39). Même ID de ressource (un seul attribut colorPrimary dans les ressources fusionnées, l'app n'en déclare aucun), donc comportement runtime identique. Vérifications : - L'app ne déclare aucun attribut colorPrimary, ni dans les ressources actuelles (aucun <attr name="colorPrimary"> ni declare-styleable) ni dans tout l'historique git. - En mode non transitif, la compilation ne cassait qu'à ces 2 références (énumération exhaustive par le compilateur). - :app:assembleRelease (compilation + R8 + packaging) réussit en mode non transitif. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Modification de juste deux lignes nécessaire pour passer au futur voulu par AGP. Slack a un article sympa sur les R classes non transitives, mais leur app n’a rien à voir en scope avec RespawnIRC. Pas d’amélioration du temps de build pour RespawnIRC car il n’y a qu’un module.