sentry-capacitor: Angular - Uncaught SentryError: Native Client is not available, can't start on native.

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which package are you using?

@sentry/angular

SDK Version

7.6.0

Framework Version

0.6.1

Link to Sentry event

No response

Steps to Reproduce

Environment

How do you use Sentry? Sentry SaaS (sentry.io)

Which SDK and version?

@sentry/angular: ^7.6.0
@sentry/capacitor: ^0.6.1

Ionic:

   Ionic CLI                     : 6.20.1
   Ionic Framework               : @ionic/angular 6.1.13
   @angular-devkit/build-angular : 14.0.5
   @angular-devkit/schematics    : 14.0.5
   @angular/cli                  : 14.0.5
   @ionic/angular-toolkit        : 6.1.0

Capacitor:

   Capacitor CLI      : 3.6.0
   @capacitor/android : 3.6.0
   @capacitor/core    : 3.6.0
   @capacitor/ios     : 3.6.0

Steps to Reproduce

error.js:8 Uncaught SentryError: Native Client is not available, can't start on native.
    at new SentryError (error.js:8:28)
    at 41406 (wrapper.js:336:25)
    at __webpack_require__ (bootstrap:19:1)
    at 88931 (index.js:2:1)
    at __webpack_require__ (bootstrap:19:1)
    at 71571 (eventorigin.js:2:1)
    at __webpack_require__ (bootstrap:19:1)
    at 82103 (scope.js:7:1)
    at __webpack_require__ (bootstrap:19:1)
    at 85208 (xhr.js:49:2)

Expected Result

Had been using sentry capacitor plugin for several months. This issue happens recently and unable to initial sentry service and App at all.

Actual Result

error.js:8 Uncaught SentryError: Native Client is not available, can't start on native.
    at new SentryError (error.js:8:28)
    at 41406 (wrapper.js:336:25)
    at __webpack_require__ (bootstrap:19:1)
    at 88931 (index.js:2:1)
    at __webpack_require__ (bootstrap:19:1)
    at 71571 (eventorigin.js:2:1)
    at __webpack_require__ (bootstrap:19:1)
    at 82103 (scope.js:7:1)
    at __webpack_require__ (bootstrap:19:1)
    at 85208 (xhr.js:49:2)

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 2
  • Comments: 27 (5 by maintainers)

Most upvoted comments

Ok, I may have found the source of the issue, I’ll check what’s enabling the Native flag on the Web code tomorrow and hopefully it’s just a quick fix to unblock you from using Angular 14.

@lucas-zimerman any updates? 😬

Hi, you were correct 😄, https://github.com/getsentry/sentry-javascript/pull/5260 introduced a new call to SetContext and that sets the context before the Capacitor SDK gets initialized,

I’ll release a PR to fix this new Behavior.

@lucas-zimerman could you take a look?