From 114dba3e00c40ab761404e716ca59642f23cc20b Mon Sep 17 00:00:00 2001 From: HuanCheng65 <22636177+HuanCheng65@users.noreply.github.com> Date: Thu, 21 Sep 2023 19:25:58 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20R8=20Full=20Mode=20=E5=AF=BC=E8=87=B4=20?= =?UTF-8?q?Release=20=E9=97=AA=E9=80=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/build.gradle | 4 ++-- app/proguard-rules.pro | 15 +++++++++++++++ build.gradle | 6 +++--- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 9f0e3bd5..bd8e2452 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -123,7 +123,7 @@ dependencies { implementation "com.airbnb.android:lottie:$lottie_version" implementation "com.airbnb.android:lottie-compose:$lottie_version" - implementation 'org.jetbrains.kotlinx:kotlinx-serialization-json:1.5.1' + implementation 'org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.0' implementation 'org.jetbrains.kotlinx:kotlinx-collections-immutable:0.3.5' // implementation 'androidx.compose.material3:material3:1.0.0' @@ -237,7 +237,7 @@ dependencies { implementation "com.google.android.material:material:1.9.0" - implementation "com.squareup.okhttp3:okhttp:4.10.0" + implementation 'com.squareup.okhttp3:okhttp:4.11.0' implementation "com.squareup.retrofit2:retrofit:$retrofit_version" implementation "com.squareup.retrofit2:converter-gson:$retrofit_version" implementation "com.squareup.retrofit2:converter-wire:$retrofit_version" diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index 8bab9ced..2379ea8b 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -256,3 +256,18 @@ void traceEventStart(int,java.lang.String); void traceEventEnd(); } + +# Keep generic signature of Flow (R8 full mode strips signatures from non-kept items). +-keep,allowobfuscation,allowshrinking class kotlinx.coroutines.flow.Flow +-keep,allowobfuscation,allowshrinking class * extends kotlinx.coroutines.flow.Flow + + -keep,allowobfuscation,allowshrinking interface retrofit2.Call + -keep,allowobfuscation,allowshrinking class retrofit2.Response + -keep,allowobfuscation,allowshrinking class kotlin.coroutines.Continuation + +# Retain generic signatures of TypeToken and its subclasses with R8 version 3.0 and higher. +-keep,allowobfuscation,allowshrinking class com.google.gson.reflect.TypeToken +-keep,allowobfuscation,allowshrinking class * extends com.google.gson.reflect.TypeToken + +-if interface * { @retrofit2.http.* ; } +-keep,allowobfuscation interface <1> \ No newline at end of file diff --git a/build.gradle b/build.gradle index 302b8909..8dee2e41 100644 --- a/build.gradle +++ b/build.gradle @@ -2,15 +2,15 @@ buildscript { ext { - glide_version = '4.15.1' + glide_version = '4.16.0' retrofit_version = "2.9.0" kotlin_version = '1.9.10' - coroutines_version = '1.7.2' + coroutines_version = '1.7.3' //https://developer.android.com/jetpack/androidx/releases/compose-kotlin compose_compiler_version = '1.5.3' //https://developer.android.com/jetpack/compose/setup#bom-version-mapping compose_bom_version = '2023.09.01' - wire_version = '4.7.2' + wire_version = '4.9.0' hilt_version = '2.46.1' booster_version = '4.16.2' lottie_version = '6.1.0'