Open kgunderman opened 4 months ago
Looks like the issue was twofold for me.
First - I used patch-package
and removed the hasConstants
override located at: node_modules/apptentive-react-native/android/src/main/java/com/apptentive/android/sdk/reactlibrary/ApptentiveModu Le.kt:359:3
This resolved the issue described in the first screenshot
node_modules/apptentive-react-native/android/src/main/java/com/apptentive/android/sdk/reactlibrary/ApptentiveModu
Le.kt:359:3 'hasConstants' overrides nothing
Second - It looks like the apptentive library is using lifecycle-viewmodel:2.3.1
, and this was causing conflicting dependencies in my project that are using lifecycle-viewmodel:2.5.1
.
I was able to resolve this conflict by adding:
configurations.all {
resolutionStrategy.eachDependency { DependencyResolveDetails details ->
// apptentive-react-native 6.7.0 is using viewmodel 2.3.1 which is incompatible with lifecycle 2.5.1
// this is a temp workaround until apptentive updates their library
if (details.requested.group == 'androidx.lifecycle') {
if (details.requested.name.startsWith('lifecycle-viewmodel')) {
details.useVersion '2.5.1'
}
}
}
}
to my app/build.gradle
file
We have the same issues. I hope the owners will fix it soon
Thanks, it solved the hasContants issue, good catch!
Now, I'm facing a crash issue when I call the engage method, it results into:
java.lang.IllegalArgumentException: com.google.android.material.dialog.MaterialAlertDialogBuilder requires a value for the com.debugapp.v3:attr/colorSurface attribute to be set in your app theme. You can either set the attribute in your theme or update your theme to inherit from Theme.MaterialComponents (or a descendant).
Have anyone faced this issue? How did u address it? I have added the colorSurface to the styles.xml but it didn't fix the issue, I'm tracking this issue in another ticket: https://github.com/apptentive/apptentive-react-native/issues/262
The app builds fine with React-Native 0.71, and for 0.73.4 when
apptentive-react-native
is not a dependency. However whenever I addapptentive-react-native
as a dependency to my 0.73.4 project the build fails:My android/build.grade: