Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot find protocol declaration for 'SentryMXManagerDelegate' #3800

Closed
5 of 11 tasks
emre-atilla opened this issue May 6, 2024 · 7 comments
Closed
5 of 11 tasks

Cannot find protocol declaration for 'SentryMXManagerDelegate' #3800

emre-atilla opened this issue May 6, 2024 · 7 comments

Comments

@emre-atilla
Copy link

OS:

  • Windows
  • MacOS
  • Linux

Platform:

  • iOS
  • Android

SDK:

  • @sentry/react-native (>= 1.0.0)
  • react-native-sentry (<= 0.43.2)

SDK version: 5.22.1

react-native version: 0.72.7

Are you using Expo?

  • Yes
  • No

Are you using sentry.io or on-premise?

  • sentry.io (SaaS)
  • on-premise

If you are using sentry.io, please post a link to your issue so we can take a look:

[Link to issue]

Configuration:

(@sentry/react-native)

Sentry.init({
  dsn: "https://xxx@yyy.ingest.us.sentry.io/zzz",
  // Set tracesSampleRate to 1.0 to capture 100% of transactions for performance monitoring.
  // We recommend adjusting this value in production.
  tracesSampleRate: 1.0,
  _experiments: {
    // profilesSampleRate is relative to tracesSampleRate.
    // Here, we'll capture profiles for 100% of transactions.
    profilesSampleRate: 1.0,
  },
});

I have the following issue:
image

image

I have this issue on iOS it says Cannot find protocol declaration for 'SentryMXManagerDelegate'

[Description]

Steps to reproduce:

  • npx @sentry/wizard@latest -s -I reactNative
@krystofwoldrich
Copy link
Member

krystofwoldrich commented May 6, 2024

Hi @emre-atilla,
thank you for the message,
we will take a look at this.

If you are able to create a minimal reproducible example, could you share it with us, it would help us debugging the issue.

Are you using use_frameworks, static, dynamic? Are you using new_architecture?

@krystofwoldrich
Copy link
Member

@brustolin @philipphofmann This seems specific to sentry-cocoa, any ideas?

@emre-atilla
Copy link
Author

emre-atilla commented May 7, 2024

Hi @krystofwoldrich thank you for responding,

I created a repo for reproduce error again.

What I did :

  • i just simply install with npx @sentry/wizard@latest -s -I reactNative
  • I add my own dsn number to the project

and its working on android what I expect but on iOS it says cannot find protocol declaration for 'SentryMXManagerDelegate'

here is repo : https://github.com/emre-atilla/ProjectCloneForSentry

@krystofwoldrich
Copy link
Member

Thank you for the repro. I've reproduced the build issue, we'll investigate it and keep you updated.

@krystofwoldrich
Copy link
Member

The Sentry pod requires APPLICATION_EXTENSION_API_ONLY to be set to YES, but your podfile sets it to NO for all pods.

You can change your code like this to fix the build.

      # Check if the pod is not Sentry
      unless target.name == 'Sentry'
        # Iterate through each build configuration
        target.build_configurations.each do |config|
          # Modify the build settings
          config.build_settings['APPLICATION_EXTENSION_API_ONLY'] = 'No'
        end
      end

Could you share with us why are you using the APPLICATION_EXTENSION_API_ONLY flag?

Let us know if this help you solve the issue, in case it did not or you have some other question feel free to post it here and we can reopen this.

@emre-atilla
Copy link
Author

Thank you so much for your help it solves the issue. I don't really remember why I used the APPLICATION_EXTENSION_API_ONLY flag it's a bit old project

@julian-gargicevich
Copy link

julian-gargicevich commented May 23, 2024

krystofwoldrich I'm getting this same error after upgrading to 5.22 from 5.19, I'm using expo and the expo plugin

If it's of any help, I have these build properties needed for firebase.

[
      "expo-build-properties",
      {
        ios: {
          useFrameworks: "static",
          deploymentTarget: "15.0",
        },
      },
    ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Archived in project
Development

No branches or pull requests

3 participants