Skip to content

Commit 55c7ed5

Browse files
committed
Try force disabling sdk-v9
1 parent c93f801 commit 55c7ed5

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

.github/workflows/sample-application.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,10 @@ jobs:
104104
[[ "${{ matrix.build-type }}" == "production" ]] && ENABLE_PROD=1 || ENABLE_PROD=0
105105
[[ "${{ matrix.rn-architecture }}" == "new" ]] && ENABLE_NEW_ARCH=1 || ENABLE_NEW_ARCH=0
106106
[[ "${{ matrix.ios-use-frameworks }}" == "dynamic-frameworks" ]] && export USE_FRAMEWORKS=dynamic
107+
108+
# Disable SDK_V9 for dev builds to keep deprecated UserFeedback API
109+
[[ "${{ matrix.build-type }}" == "dev" ]] && export SENTRY_DISABLE_SDK_V9=1
110+
107111
echo "ENABLE_PROD=$ENABLE_PROD"
108112
echo "ENABLE_NEW_ARCH=$ENABLE_NEW_ARCH"
109113
PRODUCTION=$ENABLE_PROD RCT_NEW_ARCH_ENABLED=$ENABLE_NEW_ARCH bundle exec pod install

samples/react-native/ios/Podfile

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,19 @@ target 'sentryreactnativesample' do
5050
:mac_catalyst_enabled => false,
5151
# :ccache_enabled => true
5252
)
53+
54+
# Disable SDK_V9 for Sentry when environment variable is set
55+
if ENV['SENTRY_DISABLE_SDK_V9']
56+
installer.pods_project.targets.each do |target|
57+
if target.name == 'Sentry'
58+
target.build_configurations.each do |config|
59+
config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)']
60+
config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] << 'SDK_V9=0'
61+
config.build_settings['SWIFT_ACTIVE_COMPILATION_CONDITIONS'] ||= ['$(inherited)']
62+
config.build_settings['SWIFT_ACTIVE_COMPILATION_CONDITIONS'].delete('SDK_V9')
63+
end
64+
end
65+
end
66+
end
5367
end
5468
end

0 commit comments

Comments
 (0)