From e062843b6ab91d7af9234b596ee6f5d0da0e8237 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lu=C3=ADs=20Duarte?= Date: Mon, 24 Jun 2024 21:14:38 +0100 Subject: [PATCH] Abstract proguard rules at package level --- uni/android/app/proguard-rules.pro | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/uni/android/app/proguard-rules.pro b/uni/android/app/proguard-rules.pro index 04297640f..fbec115a4 100644 --- a/uni/android/app/proguard-rules.pro +++ b/uni/android/app/proguard-rules.pro @@ -20,10 +20,13 @@ # hide the original source file name. #-renamesourcefileattribute SourceFile -# The 6 lines below are added to fix #1243 --dontwarn com.google.errorprone.annotations.CanIgnoreReturnValue --dontwarn com.google.errorprone.annotations.CheckReturnValue --dontwarn com.google.errorprone.annotations.Immutable --dontwarn com.google.errorprone.annotations.RestrictedApi --dontwarn javax.annotation.Nullable --dontwarn javax.annotation.concurrent.GuardedBy +# These are annotations related to static analysis tools. Proguard +# tries to optimize/obfuscate the bundle, it needs all +# packages to be present. Because these annotations do not exist +# at optimize time, it will warn us that it cannot find those packages. +# Unfortunaly, AFAIK there's no real way to packages include their "own" +# proguard or some of them just do not do it, so we sometimes need to handle it +# when we add a new dependency. + +-dontwarn com.google.errorprone.annotations.* +-dontwarn javax.annotation.*