Avatar ·

Proguard-rules.pro में पैकेज जोड़ने के बाद Proguard Missing classes पर त्रुटि दे रहा है

सभी को नमस्ते! कई दिनों से इस समस्या से जूझ रहा हूँ। प्रोजेक्ट Kotlin में है, R8 (Android Gradle Plugin 7.4+) के माध्यम से obfuscation का उपयोग कर रहा हूँ। सब कुछ ठीक चल रहा था, जब तक मैंने कुछ तीसरे पक्ष की libraries (Retrofit, Gson, Room) कनेक्ट करना शुरू नहीं किया। मैंने `proguard-rules.pro` में data models को सुरक्षित रखने के लिए rules जोड़े: ``` -keep class com.myapp.data.model.** { *; } -keep class com.myapp.data.remote.** { *; } ``` और Retrofit के लिए: ``` -keepattributes Signature -keepattributes *Annotation* -keep class retrofit2.** { *; } -keepclasseswithmembers class * { @retrofit2.http.* ; } ``` लेकिन release build (minifyEnabled true) बनाते समय ये errors आ रही हैं: ``` Missing classes detected while running R8: com.google.gson.internal.ConstructorConstructor com.google.gson.interna