3

I have integrated crashlytics using react-native-firebase, and i have uploaded all the required dSYMs into the console. So, the crashes are shown, but they are obfuscated and they can't be tracked down in this format.

Fatal Exception: RCTFatalException: Unhandled JS Exception: TypeError: undefined is not an object (evaluating 't.code')

This error is located at:
    in O
    in B
    in p
    in RCTView
    in Portal.Host
    in c
    in h
    in s
    in v
    in u
    in RCTView
    in RCTView
    in o
0  CoreFoundation

I had no success trying to de-obfuscate them somehow. Any ideas?

angelos_lex
  • 1,593
  • 16
  • 24
  • Is this a stacktrace on the Crashlytics dashboard, or is it just a log? Could you attach a screenshot of the console where the stacktrace for the crash is displayed? Finally you can check the RN+Firebase github issues for anything similar to this: https://github.com/invertase/react-native-firebase – Kevin Kokomani Jun 09 '20 at 19:30

1 Answers1

6

This is a Javascript exception, and you have probably copied the raw text. If you check in the formatted text, it will look like something like this:

Unhandled JS Exception: TypeError: undefined is not an object (evaluating 't.code') This error is located at: in O in B in p in RCTView in Portal.Host ..., stack: value@1451:1379 value@1451:1558 value@1764:2262 value@1764:1616 Tl@161:77714 

This format matches the JSC (react-native) stack trace and you can use a tool like stack-beautifier to parse it in a humanly readable form. The tool also has a nice documentation of the process needed to reach a humanly readable format. In short, you will need to:

  1. Find or re-create the source maps using react-native bundle from the needed branch, again, detailed steps in the tool’s documentation on how to do this
  2. Extract the JSC stack trace into a new txt file, add new lines in the proper places (i.e. first one goes after "...stack:")
  3. Run the tool with all of the above input and you should get what you are looking for