Skip to content

Commit e6a2b88

Browse files
authored
Merge cf617f4 into 4297324
2 parents 4297324 + cf617f4 commit e6a2b88

File tree

13 files changed

+2041
-122
lines changed

13 files changed

+2041
-122
lines changed

samples/react-native/Gemfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ source 'https://rubygems.org'
33
# You may use http://rbenv.org/ or https://rvm.io/ to install and use this version
44
ruby "3.3.0"
55

6-
gem 'cocoapods', '1.15.2'
6+
gem 'cocoapods', '1.16.1'
77
gem 'activesupport', '>= 6.1.7.5', '< 7.1.0'
88
gem 'fastlane', '2.220.0'

samples/react-native/Gemfile.lock

+8-8
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ GEM
3636
babosa (1.0.4)
3737
base64 (0.2.0)
3838
claide (1.1.0)
39-
cocoapods (1.15.2)
39+
cocoapods (1.16.1)
4040
addressable (~> 2.8)
4141
claide (>= 1.0.2, < 2.0)
42-
cocoapods-core (= 1.15.2)
42+
cocoapods-core (= 1.16.1)
4343
cocoapods-deintegrate (>= 1.0.3, < 2.0)
4444
cocoapods-downloader (>= 2.1, < 3.0)
4545
cocoapods-plugins (>= 1.0.0, < 2.0)
@@ -53,8 +53,8 @@ GEM
5353
molinillo (~> 0.8.0)
5454
nap (~> 1.0)
5555
ruby-macho (>= 2.3.0, < 3.0)
56-
xcodeproj (>= 1.23.0, < 2.0)
57-
cocoapods-core (1.15.2)
56+
xcodeproj (>= 1.26.0, < 2.0)
57+
cocoapods-core (1.16.1)
5858
activesupport (>= 5.0, < 8)
5959
addressable (~> 2.8)
6060
algoliasearch (~> 1.0)
@@ -215,7 +215,7 @@ GEM
215215
molinillo (0.8.0)
216216
multi_json (1.15.0)
217217
multipart-post (2.4.1)
218-
nanaimo (0.3.0)
218+
nanaimo (0.4.0)
219219
nap (1.1.0)
220220
naturally (2.2.1)
221221
netrc (0.11.0)
@@ -259,12 +259,12 @@ GEM
259259
uber (0.1.0)
260260
unicode-display_width (2.6.0)
261261
word_wrap (1.0.0)
262-
xcodeproj (1.25.1)
262+
xcodeproj (1.26.0)
263263
CFPropertyList (>= 2.3.3, < 4.0)
264264
atomos (~> 0.1.3)
265265
claide (>= 1.0.2, < 2.0)
266266
colored2 (~> 3.1)
267-
nanaimo (~> 0.3.0)
267+
nanaimo (~> 0.4.0)
268268
rexml (>= 3.3.6, < 4.0)
269269
xcpretty (0.3.0)
270270
rouge (~> 2.0.7)
@@ -278,7 +278,7 @@ PLATFORMS
278278

279279
DEPENDENCIES
280280
activesupport (>= 6.1.7.5, < 7.1.0)
281-
cocoapods (= 1.15.2)
281+
cocoapods (= 1.16.1)
282282
fastlane (= 2.220.0)
283283

284284
RUBY VERSION

samples/react-native/android/app/src/main/java/io/sentry/reactnative/sample/MainApplication.kt

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import com.facebook.react.ReactPackage
99
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.load
1010
import com.facebook.react.defaults.DefaultReactHost.getDefaultReactHost
1111
import com.facebook.react.defaults.DefaultReactNativeHost
12+
import com.facebook.react.soloader.OpenSourceMergedSoMapping
1213
import com.facebook.soloader.SoLoader
1314
import io.sentry.Hint
1415
import io.sentry.SentryEvent
@@ -40,7 +41,7 @@ class MainApplication() : Application(), ReactApplication {
4041
// When the native init is enabled the `autoInitializeNativeSdk`
4142
// in JS has to be set to `false`
4243
// this.initializeSentry()
43-
SoLoader.init(this, false)
44+
SoLoader.init(this, OpenSourceMergedSoMapping)
4445
if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
4546
// If you opted-in for the New Architecture, we load the native entry point for this app.
4647
load()

samples/react-native/android/app/src/main/jni/CMakeLists.txt

+5-3
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ project(appmodules)
3030
# This file includes all the necessary to let you build your application with the New Architecture.
3131
include(${REACT_ANDROID_DIR}/cmake-utils/ReactNative-application.cmake)
3232

33-
# App needs to add and link against tm (TurboModules) folder
34-
add_subdirectory(${REACT_ANDROID_DIR}/../../../tm/ tm_build)
35-
target_link_libraries(${CMAKE_PROJECT_NAME} tm)
33+
# Define where the additional source code lives. We need to crawl back the jni, main, src, app, android folders
34+
target_sources(${CMAKE_PROJECT_NAME} PRIVATE ../../../../../tm/NativeSampleModule.cpp)
35+
36+
# Define where CMake can find the additional header files. We need to crawl back the jni, main, src, app, android folders
37+
target_include_directories(${CMAKE_PROJECT_NAME} PUBLIC ../../../../../tm)

samples/react-native/android/app/src/main/jni/OnLoad.cpp

+4
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include <fbjni/fbjni.h>
3434
#include <react/renderer/componentregistry/ComponentDescriptorProviderRegistry.h>
3535
#include <rncore.h>
36+
#include <NativeSampleModule.h>
3637

3738
#ifdef REACT_NATIVE_APP_CODEGEN_HEADER
3839
#include REACT_NATIVE_APP_CODEGEN_HEADER
@@ -70,6 +71,9 @@ std::shared_ptr<TurboModule> cxxModuleProvider(
7071
// if (name == NativeCxxModuleExample::kModuleName) {
7172
// return std::make_shared<NativeCxxModuleExample>(jsInvoker);
7273
// }
74+
if (name == NativeSampleModule::kModuleName) {
75+
return std::make_shared<NativeSampleModule>(jsInvoker);
76+
}
7377

7478
// And we fallback to the CXX module providers autolinked
7579
return autolinking_cxxModuleProvider(name, jsInvoker);

samples/react-native/android/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11

22
buildscript {
33
ext {
4-
buildToolsVersion = "34.0.0"
5-
minSdkVersion = 23
6-
compileSdkVersion = 34
4+
buildToolsVersion = "35.0.0"
5+
minSdkVersion = 24
6+
compileSdkVersion = 35
77
targetSdkVersion = 34
88
ndkVersion = "26.1.10909125"
99
kotlinVersion = "1.9.24"

samples/react-native/android/gradle/wrapper/gradle-wrapper.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

samples/react-native/android/gradlew

+2-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,8 @@ done
8484
# shellcheck disable=SC2034
8585
APP_BASE_NAME=${0##*/}
8686
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
87-
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
87+
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
88+
' "$PWD" ) || exit
8889

8990
# Use the maximum available, or set MAX_FD != -1 to use that value.
9091
MAX_FD=maximum

samples/react-native/ios/sentryreactnativesample.xcodeproj/project.pbxproj

+6-4
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,7 @@
451451
"$(inherited)",
452452
);
453453
INFOPLIST_FILE = sentryreactnativesampleTests/Info.plist;
454-
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
454+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
455455
LD_RUNPATH_SEARCH_PATHS = (
456456
"$(inherited)",
457457
"@executable_path/Frameworks",
@@ -475,7 +475,7 @@
475475
BUNDLE_LOADER = "$(TEST_HOST)";
476476
COPY_PHASE_STRIP = NO;
477477
INFOPLIST_FILE = sentryreactnativesampleTests/Info.plist;
478-
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
478+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
479479
LD_RUNPATH_SEARCH_PATHS = (
480480
"$(inherited)",
481481
"@executable_path/Frameworks",
@@ -506,6 +506,7 @@
506506
ENABLE_BITCODE = NO;
507507
INFOPLIST_FILE = sentryreactnativesample/Info.plist;
508508
INFOPLIST_KEY_CFBundleDisplayName = "Sentry RN";
509+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
509510
LD_RUNPATH_SEARCH_PATHS = (
510511
"$(inherited)",
511512
"@executable_path/Frameworks",
@@ -539,6 +540,7 @@
539540
"DEVELOPMENT_TEAM[sdk=iphoneos*]" = 97JCY7859U;
540541
INFOPLIST_FILE = sentryreactnativesample/Info.plist;
541542
INFOPLIST_KEY_CFBundleDisplayName = "Sentry RN";
543+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
542544
LD_RUNPATH_SEARCH_PATHS = (
543545
"$(inherited)",
544546
"@executable_path/Frameworks",
@@ -620,7 +622,7 @@
620622
"${PODS_CONFIGURATION_BUILD_DIR}/React-graphics/React_graphics.framework/Headers",
621623
"${PODS_CONFIGURATION_BUILD_DIR}/React-graphics/React_graphics.framework/Headers/react/renderer/graphics/platform/ios",
622624
);
623-
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
625+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
624626
LD = "";
625627
LDPLUSPLUS = "";
626628
LD_RUNPATH_SEARCH_PATHS = (
@@ -709,7 +711,7 @@
709711
"${PODS_CONFIGURATION_BUILD_DIR}/React-graphics/React_graphics.framework/Headers",
710712
"${PODS_CONFIGURATION_BUILD_DIR}/React-graphics/React_graphics.framework/Headers/react/renderer/graphics/platform/ios",
711713
);
712-
IPHONEOS_DEPLOYMENT_TARGET = 12.4;
714+
IPHONEOS_DEPLOYMENT_TARGET = 15.1;
713715
LD = "";
714716
LDPLUSPLUS = "";
715717
LD_RUNPATH_SEARCH_PATHS = (

samples/react-native/ios/sentryreactnativesample/AppDelegate.mm

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#import "AppDelegate.h"
22

33
#import <React/RCTBundleURLProvider.h>
4+
#import <RCTAppDelegate+Protected.h>
45
#import <React/CoreModulesPlugins.h>
56
#import <ReactCommon/RCTTurboModuleManager.h>
67

samples/react-native/package.json

+19-18
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"postinstall": "patch-package",
77
"android": "react-native run-android",
88
"ios": "react-native run-ios",
9-
"start": "react-native start --experimental-debugger",
9+
"start": "react-native start",
1010
"test": "jest",
1111
"lint": "npx eslint . --ext .js,.jsx,.ts,.tsx",
1212
"fix": "eslint . --ext .js,.jsx,.ts,.tsx --fix",
@@ -21,31 +21,32 @@
2121
"build-android-release-splits-flavors": "export SENTRY_SAMPLE_ENABLE_ABI_SPLIT=true; export SENTRY_SAMPLE_ENABLE_FLAVORS=true; cd android; ./gradlew assembleRelease; cd .."
2222
},
2323
"dependencies": {
24-
"@react-navigation/bottom-tabs": "^6.5.12",
25-
"@react-navigation/native": "^6.1.9",
26-
"@react-navigation/native-stack": "^6.9.17",
27-
"@react-navigation/stack": "^6.3.20",
24+
"@react-navigation/bottom-tabs": "^6.6.1",
25+
"@react-navigation/native": "^6.1.18",
26+
"@react-navigation/native-stack": "^6.11.0",
27+
"@react-navigation/stack": "^6.4.1",
2828
"@sentry/react-native": "6.1.0",
2929
"delay": "^6.0.0",
3030
"react": "18.3.1",
31-
"react-native": "0.75.4",
32-
"react-native-gesture-handler": "^2.18.1",
33-
"react-native-reanimated": "3.15.0",
34-
"react-native-safe-area-context": "4.10.5",
35-
"react-native-screens": "3.34.0",
36-
"react-native-svg": "^15.6.0",
31+
"react-native": "0.76.1",
32+
"react-native-gesture-handler": "^2.20.2",
33+
"react-native-reanimated": "3.16.1",
34+
"react-native-safe-area-context": "4.12.0",
35+
"react-native-screens": "3.35.0",
36+
"react-native-svg": "^15.8.0",
3737
"react-native-vector-icons": "^10.0.3",
3838
"react-redux": "^8.1.3",
3939
"redux": "^4.2.1"
4040
},
4141
"devDependencies": {
42-
"@babel/core": "^7.22.5",
43-
"@babel/preset-env": "^7.22.5",
44-
"@babel/runtime": "^7.22.5",
45-
"@react-native/babel-preset": "0.75.4",
46-
"@react-native/eslint-config": "0.75.4",
47-
"@react-native/metro-config": "0.75.4",
48-
"@react-native/typescript-config": "0.75.4",
42+
"@babel/core": "^7.25.2",
43+
"@babel/preset-env": "^7.25.3",
44+
"@babel/runtime": "^7.25.0",
45+
"@react-native-community/cli": "15.0.0",
46+
"@react-native/babel-preset": "0.76.1",
47+
"@react-native/eslint-config": "0.76.1",
48+
"@react-native/metro-config": "0.76.1",
49+
"@react-native/typescript-config": "0.76.1",
4950
"@sentry/babel-plugin-component-annotate": "^2.18.0",
5051
"@types/react": "^18.2.65",
5152
"@types/react-native-vector-icons": "^6.4.18",
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
import type { TurboModule } from 'react-native';
2-
import { TurboModuleRegistry } from 'react-native';
1+
import {TurboModule, TurboModuleRegistry} from 'react-native';
32

43
export interface Spec extends TurboModule {
54
crashOrString(): string;
65
}
76

8-
export default TurboModuleRegistry.get<Spec>('NativePlatformSampleModule');
7+
export default TurboModuleRegistry.getEnforcing<Spec>('NativePlatformSampleModule');

0 commit comments

Comments
 (0)