You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm currently trying to close the Sentry connection on runtime whenever we detect an app update is available and the user has been prompted. As I'm lead to believe the current way to do so is as below, however, this prompts a deprecation notice to use Sentry.getClient() instead. This method does not exist, thus it seems this deprecation notice is incorrect.
Sentry.getCurrentHub().getClient().close(0);// deprecated, but worksSentry.getClient().close(0);// Sentry.getClient is not a function
In contrast it does seem to work correctly when trying to close a Vue-specific instance of Sentry. In other words, this following prompts (correctly) to use the alternative:
SentryVue.getCurrentHub().getClient().close(0);// deprecated, but worksSentryVue.getClient().close(0);// works just fine
While having to go through this many hoops to simply disable Sentry seems like a drag, that is a separate issue, though I would like to know whether this is correct, or whether only Sentry or SentryVue needs to be closed.
I'm currently using the following Sentry-relevant packages:
Thank you for opening this issue, currently getClient isn't exposed but we'll expose it on the next release.
Also in regard to your issue we will also expose a close function on Capacitor that allows it to close both native and JavaScript SDKs.
Hey all!
I'm currently trying to close the Sentry connection on runtime whenever we detect an app update is available and the user has been prompted. As I'm lead to believe the current way to do so is as below, however, this prompts a deprecation notice to use
Sentry.getClient()
instead. This method does not exist, thus it seems this deprecation notice is incorrect.In contrast it does seem to work correctly when trying to close a Vue-specific instance of Sentry. In other words, this following prompts (correctly) to use the alternative:
While having to go through this many hoops to simply disable Sentry seems like a drag, that is a separate issue, though I would like to know whether this is correct, or whether only
Sentry
orSentryVue
needs to be closed.I'm currently using the following Sentry-relevant packages:
The text was updated successfully, but these errors were encountered: