QuickBlox / quickblox-react-native-samples

quickblox-react-native-samples
BSD 3-Clause "New" or "Revised" License
17 stars 27 forks source link

RNQBSettingsModule.init not working in release mode android 12 #43

Closed sayalichaware closed 1 year ago

sayalichaware commented 1 year ago

Hello developer, I'm facing the issue after updating the latest SDK. It was working perfectly in debug mode but when I create release and test it, it get crashed. I have cross check all the possible ways after RND on this issue.

Attaching the error file which got logged in Crashlytics.

Please help to provide a solution.

Thanks com.consultnet_issue_af1aede8445ba2223411f37213927969_crash_session_63B3D6770374000128655D9FCF29AFAD_DNE_0_v2_stacktrace.txt

kirillTolmachev commented 1 year ago

Hello @sayalichaware Looks like you have a wrong rules in proguard file and obfuscation doesn't work correct. Could you please provide proguard file rules and gradle (application) file.

sayalichaware commented 1 year ago

I have attached the zip file.

Archive.zip

kirillTolmachev commented 1 year ago

@sayalichaware Please modify your proguard rules file to format like below:

-keepattributes EnclosingMethod
-keepattributes InnerClasses
-keepattributes Signature
-keepattributes Exceptions

# For using GSON @Expose annotation
-keepattributes *Annotation*

#quickblox sdk
-keep class com.quickblox.** { *; }

#smack xmpp library
-keep class org.jxmpp.** { *; }
-keep class org.jivesoftware.** { *; }
-dontwarn org.jivesoftware.**

#webrtc
-keep class org.webrtc.** { *; }

#google gms
-keep class com.google.android.gms.** { *; }

#json
-keep class org.json.** { *; }

or you can copy from the android project by link, and try to make release build again.