question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

App crashes on startup after installing instabug RN integration

See original GitHub issue

Steps to Reproduce the Problem

  1. Install the instabug RN SDK
  2. Fire up the app in iOS or Android emulators

Expected Behavior

App doesn’t crash on startup

Actual Behavior

App crashes with the following error on startup:

transform[stderr]: The exported identifier "Survey" is not declared in Babel's scope tracker
transform[stderr]: as a JavaScript value binding, and "@babel/plugin-transform-typescript"
transform[stderr]: never encountered it as a TypeScript type declaration.
transform[stderr]: It will be treated as a JavaScript value.
transform[stderr]:
transform[stderr]: This problem is likely caused by another plugin injecting
transform[stderr]: "Survey" without registering it in the scope tracker. If you are the author
transform[stderr]:  of that plugin, please use "scope.registerDeclaration(declarationPath)".
 BUNDLE  ./index.js

error: node_modules/instabug-reactnative/src/index.ts: /Users/rkeiii/workspace/BookshareMobileReader/node_modules/instabug-reactnative/src/index.ts: Exporting local "Survey", which is not declared.
  16 |   Report,
  17 |   Trace,
> 18 |   Survey,
     |   ^^^^^^
  19 |   APM,
  20 |   BugReporting,
  21 |   CrashReporting,

Instabug integration code

The following is in my main App.tsx

import Instabug from 'instabug-reactnative';
...
  /**
   * Initialize Instabug crash handling service
   */
  useEffect(() => {
    Instabug.start('SECRET_TOKEN', [
      Instabug.invocationEvent.shake,
    ]);
  }, []);

SDK Version

11.5.0

React Native, iOS and Android Versions

React Native 0.7.0 iOS 15.5 Android 13

Device Model

Occurs on both emulators

Issue Analytics

  • State:closed
  • Created 9 months ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
rkeiiicommented, Dec 13, 2022

Thank you for the suggested fix. We’ve actually moved onto another bug tracking platform but I will definitely try this if we end up switching back.

I’m leaving the ticket open since it appears to affect others.

0reactions
DavidMina96commented, Dec 14, 2022

@tomwanzek Thanks a lot for your contribution with this issue fix (and for your wonderful feedback re our package too). Such feedback is what keeps us enhancing our package continually to be up to our customers’ expectations and beyond. 🙏

For anyone facing this error, I’m happy to share that a patch release v11.5.1 should now be out, which includes the fix for this issue. 🚀

I’ll be closing the issue accordingly, but please feel free to re-open it at any time if needs be.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why aren't my crashes appearing? - Instabug Help Center
Crash reports are sent upon the next successful launch of the app. Once sent, they should appear on the dashboard in no time....
Read more >
App crashes on launch and instabug is the cause #194 - GitHub
Steps to Reproduce the Problem Open the app Expected Behavior App will run Actual Behavior App crashes Instabug integration code @Override ...
Read more >
React Native app crashes without any error log - Stack Overflow
Happens when working with TextInput . I have some ideas how I can fix the code, but want to understand why is app...
Read more >
App Center Crashes for iOS - Microsoft Learn
The SDK won't forward any crash log if you're attached to the debugger. Make sure the debugger isn't attached when you crash the...
Read more >
Detect and diagnose crashes - Android Developers
There are many situations that can cause a crash in your app. Some reasons are obvious, like checking for a null value or...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found