customerio / customerio-reactnative

MIT License
23 stars 11 forks source link

Error run android with customer 3.7.0 #269

Closed edersonfaccin closed 3 weeks ago

edersonfaccin commented 1 month ago

I am using react native with customer.io in the latest version

For IOS works well done. For Android I have this issue below

com.android.tools.r8.internal.Jc: Sealed classes are not supported as program classes justified-tracking-3.10.-runtime.jar

react: 18.2.0 react-native: 0.71.13 customerio-reactnative: 3.7.0

mrehan27 commented 1 month ago

Hi @edersonfaccin. Thanks for reaching out to us. Sorry to hear about the issue you're experiencing. Starting from 3.7.0, compiling Android apps with our React Native package needs to be compatible with Gradle 8. Since you mentioned you are currently using React Native 0.71.13, you might only need to update your Android Gradle Plugin version to at least 7.4.1. Please note that Android Gradle Plugin version is different from Gradle version and needs to be specified in either android/build.gradle file or android/settings.gradle depending on your project settings.

If your project specifies it in android/build.gradle file, please update the version as follows:

classpath("com.android.tools.build:gradle:7.4.1")

If your project specifies it in android/settings.gradle, please update the version as follows:

id "com.android.application" version "7.4.1" apply false

Do let us know if you still face any issues or have more questions. Have a great day!

mrehan27 commented 3 weeks ago

Closing this due to inactivity. The solution shared above should solve the problem. If not, please feel free to reopen or ask questions if you have trouble implementing the suggested solution.