Sentry-react-native: Disable Sentry in Development mode fails in 0.23.2

Created on 20 Sep 2017  路  1Comment  路  Source: getsentry/sentry-react-native

OS:

  • [ x] Windows

_Platform:_

  • [ x] iOS

- [x ] Android

I have following issue:
In the new version 0.23.2 I can't disable Sentry in dev mode anymore without crashing my sentry implementation in my components.

I used to to the following:
if (!__DEV__) {
Sentry.config(Config.SENTRY_ENDPOINT, {
deactivateStacktraceMerging: true,
}).install()
}

But calling something like: Sentry.setVersion(123) will result in an error throwing
Cannot read property 'internal' of undefined

Expected result:
Silently fail and expect to be in develpoment mode.

Most helpful comment

Hey, It should work if you just call or don't call install().

Sentry.config(Config.SENTRY_ENDPOINT, {
   deactivateStacktraceMerging: true,
});
if (!DEV) {
   Sentry.install();
}

>All comments

Hey, It should work if you just call or don't call install().

Sentry.config(Config.SENTRY_ENDPOINT, {
   deactivateStacktraceMerging: true,
});
if (!DEV) {
   Sentry.install();
}
Was this page helpful?
0 / 5 - 0 ratings