Closed rafaelmaeuer closed 2 years ago
@rafaelmaeuer you've likely have an outdated pod, try to:
cd ios pod update pod install
does it help?
Same issue
I can confirm that running a project on IOS using both sentry-react-native
and use_frameworks!
fails with
▸ Compiling RNSentry.m
❌ /path-to-my-project/node_modules/@sentry/react-native/ios/RNSentry.m:11:9: 'Sentry/SentryTraceContext.h' file not found
#import <Sentry/SentryTraceContext.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@rafaelmaeuer you've likely have an outdated pod, try to:
cd ios pod update pod install
does it help?
Nope I did this several times while figuring out this error...
@rafaelmaeuer you've likely have an outdated pod, try to:
cd ios pod update pod install
does it help?
Nope I did this several times while figuring out this error...
@rafaelmaeuer I've created an empty project (template) and everything worked out, so I can't reproduce this issue, since this class was added in the latest versions of the iOS SDK, seems like a cached pod issue.
Try to remove the pod lock file and the node_nodules
and yarn/npn install
again, pod install
as well, if that does not work.
Can you provide a minimal reproduction example?
Yes of course:
npx react-native init MyApp --version 0.68.2
cd MyApp
yarn add @sentry/react-native
platform :ios, '11.0'
+use_frameworks!
install! 'cocoapods', :deterministic_uuids => false
cd ios
pod install
MyApp.xcworkspace
and build MyApp
@brustolin or @philipphofmann can you take a look at this? I can't reproduce it but I've not tried with use_frameworks
The RN SDK imports SentryTraceContext
, which is not public
https://github.com/getsentry/sentry-react-native/blob/736eee2697e95315f1a76fc24e865c4564a5a9a8/ios/RNSentry.m#L11
see https://github.com/getsentry/sentry-cocoa/blob/master/Sources/Sentry/include/SentryTraceContext.h.
@brustolin, did you maybe recently change anything for the SentryTraceContext? Was it public before?
@philipphofmann Nope, I did not changed its availability. SentryTraceContext was never public.
So, a quick workaround in order for you to continue using the SDK before we fix it.
@interface SentryTraceContext : NSObject
- (nullable instancetype)initWithDict:(NSDictionary<NSString *, id> *)dictionary;
@end
@brustolin, could you maybe open a PR to fix the code in RNSentry.m
, please?
Build of React Native App fails after upgrading sentry-react-native to v4.x.x.
react-native-firebase > v15 requires
use_frameworks!
in podfile: https://github.com/invertase/react-native-firebase/blob/main/CHANGELOG.md#breaking-changesSeems like sentry-react-native has problems handling dynamic libraries in v4. There is an open PR on sentry-cocoa for this: https://github.com/getsentry/sentry-cocoa/pull/1726
Environment
How do you use Sentry?
Which SDK and version?
Steps to Reproduce
use_frameworks!
to podfileExpected Result
Build should complete.
Actual Result
Error: 'Sentry/SentryTraceContext.h' file not found in 'Development Pods/RNSentry/RNSentry.m'
For now this requires to hold back either sentry-react-native < v4 or react-native-firebase < v15