Build fails on Xcode 16.0 Beta
Mitch528 opened this issue ยท 13 comments
OS:
- Windows
- MacOS
- Linux
Platform:
- iOS
- Android
SDK:
-
@sentry/react-native
(>= 1.0.0) -
react-native-sentry
(<= 0.43.2)
SDK version: 0.0.0
react-native
version: 5.23.1
Are you using Expo?
- Yes
- No
Are you using sentry.io or on-premise?
- sentry.io (SaaS)
- on-premise
Configuration:
(@sentry/react-native
)
Sentry.init({
dsn: 'https://...@sentry.io/...'
// other options
});
I have the following issue:
Fails to build on Xcode 16.0 Beta (16A5171c)
ios/Pods/Sentry/Sources/SentryCrash/Recording/Monitors/SentryCrashMonitor_CPPException.cpp:60:13: error: no type named 'terminate_handler' in namespace 'std'
60 | static std::terminate_handler g_originalTerminateHandler;
| ~~~~~^
ios/Pods/Sentry/Sources/SentryCrash/Recording/Monitors/SentryCrashMonitor_CPPException.cpp:207:47: error: no member named 'set_terminate' in namespace 'std'
207 | g_originalTerminateHandler = std::set_terminate(CPPExceptionTerminate);
| ~~~~~^
ios/Pods/Sentry/Sources/SentryCrash/Recording/Monitors/SentryCrashMonitor_CPPException.cpp:209:18: error: no type named 'set_terminate' in namespace 'std'
209 | std::set_terminate(g_originalTerminateHandler);
| ~~~~~^
Steps to reproduce:
- Install Sentry package
- Install pods
- Build
Actual result:
Build fails
Expected result:
Build does not fail
Hey @Mitch528 thanks for writing in - this was already fixed in the sentry-cocoa SDK. Please note that it will take a few days to get that released on sentry-cocoa and then dependency bumped and released here as well.
Fix was released in https://github.com/getsentry/sentry-cocoa/releases/tag/8.29.0
Let's use this version in the RN SDK.
I ran pod update
and now get a different error with Xcode 16 beta 1:
@_implementationOnly import _SentryPrivate
No such module '_SentryPrivate
Can we have a temporary workaround until the fix is released?
Hi, is there any update progress? Or a temporary solution?
Hello everyone, we will release 5.24.0 later today which will be compatible with Xcode 16.
Just a quick heads up that 5.24.0 does not include the fix for this issue, but the main branch does include it from #3890
Is there a way to install the pre-release from the main branch which supports xcode 16?
This is my temporary solution:
@sentry+react-native+5.24.0.patch
diff --git a/node_modules/@sentry/react-native/RNSentry.podspec b/node_modules/@sentry/react-native/RNSentry.podspec
index fc7c319..c0bc242 100644
--- a/node_modules/@sentry/react-native/RNSentry.podspec
+++ b/node_modules/@sentry/react-native/RNSentry.podspec
@@ -33,7 +33,7 @@ Pod::Spec.new do |s|
s.preserve_paths = '*.js'
s.dependency 'React-Core'
- s.dependency 'Sentry/HybridSDK', '8.28.0'
+ s.dependency 'Sentry/HybridSDK', '8.29.1'
s.source_files = 'ios/**/*.{h,m,mm}'
s.public_header_files = 'ios/RNSentry.h'
Sentry RN SDK https://github.com/getsentry/sentry-react-native/releases/tag/5.24.1 includes the Xcode 16 sentry-cocoa
fix.
I got the same error for Xcode 16 beta 3