Skip to main content
Answered

Android app crashes when setting up Intercom React Native

  • October 18, 2022
  • 6 replies
  • 1059 views

  • New Participant
  • 2 replies

I'm seeing this weird error.

TypeError: null is not an object (evaluating 'IntercomEventEmitter.UNREAD_COUNT_CHANGE_NOTIFICATION')

 

image.pngI followed the guide on the official Github repo https://github.com/intercom/intercom-react-native#android.

 

After trying the manual linking, I get a different error when building the app.

> Task :intercom-react-native:generateDebugRFile FAILED
Execution optimizations have been disabled for task ':intercom-react-native:generateDebugRFile' to ensure correctness due to the following reasons:
- Gradle detected a problem with the following location: '/Users/bryamrodriguez/src/sammy-native/node_modules/@intercom/intercom-react-native/android/build/intermediates/packaged_manifests/debug'. Reason: Task ':intercom-react-native:generateDebugRFile' uses this output of task ':intercom_intercom-react-native:processDebugManifest' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed. Please refer to https://docs.gradle.org/7.3.3/userguide/validation_problems.html#implicit_dependencyfor more details about this problem.
 
FAILURE: Build failed with an exception.
 
* What went wrong:
Execution failed for task ':intercom-react-native:generateDebugRFile'.
> A failure occurred while executing com.android.build.gradle.internal.res.GenerateLibraryRFileTask$GenerateLibRFileRunnable
> /Users/bryamrodriguez/src/sammy-native/node_modules/@intercom/intercom-react-native/android/build/intermediates/local_only_symbol_list/debug/R-def.txt

I'm using:

react native: 0.69.6

@intercom/intercom-react-native: 3.0.5

Device: Pixel 4 API 33

 

Best answer by Daniel M15

Hey @bryam​! Daniel from Customer Support Engineering here 🔧 

 

Could you please contact us over the Messenger for this one if you haven't already? There have been some reported issues on React native and it would be helpful for tracking the ongoing issues if you could write in to us 🙏 Thanks!

View original
Did this topic help you find an answer to your question?

6 replies

Daniel M15
Employee
  • Employee
  • 240 replies
  • Answer
  • November 3, 2022

Hey @bryam​! Daniel from Customer Support Engineering here 🔧 

 

Could you please contact us over the Messenger for this one if you haven't already? There have been some reported issues on React native and it would be helpful for tracking the ongoing issues if you could write in to us 🙏 Thanks!


  • New Participant
  • 2 replies
  • November 30, 2022

Did you ever find a solution? I'm getting a similar error on Android.

 

TypeError: Cannot read property 'UNREAD_COUNT_CHANGE_NOTIFICATION' of null, js engine: hermes

 

RN Version 0.70.5

"@intercom/intercom-react-native": "^4.0.1",


  • Author
  • New Participant
  • 2 replies
  • November 30, 2022

Not a solution, but we decided against this SDK and used the web plugin and included it with a webview in our mobile app


  • New Participant
  • 2 replies
  • December 1, 2022

Nevermind, figured it out. My build config was messed up and my env vars weren't getting set.


Matthew R13 wrote:

Nevermind, figured it out. My build config was messed up and my env vars weren't getting set.

I have the same issue and tried a bunch of other things, could you please tell me what was the issue that you found?


  • New Participant
  • 1 reply
  • August 28, 2024

Is there a solution for this, everything works on the ios expo side of things. But crashes with the null error on android. Im using the very latest of everything. 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings