Skip to content

Commit

Permalink
debug: bump RNR, patch it and log more stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
siddarthkay committed Sep 15, 2024
1 parent 2402d0b commit b0e55f2
Show file tree
Hide file tree
Showing 6 changed files with 183 additions and 18 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@ run-re-frisk: ##@run Start re-frisk server
run-android: export TARGET := android
# Disabled for debug builds to avoid 'maximum call stack exceeded' errors.
# https://github.com/status-im/status-mobile/issues/18493
run-android: export ORG_GRADLE_PROJECT_hermesEnabled := false
run-android: export ORG_GRADLE_PROJECT_hermesEnabled := true
# enabling new architecture requires hermes to be enabled
run-android: export ORG_GRADLE_PROJECT_newArchEnabled := false
run-android: export ORG_GRADLE_PROJECT_newArchEnabled := true
run-android: ##@run Build Android APK and start it on the device
@scripts/run-android.sh

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ class MainActivity : NavigationActivity(), ActivityCompat.OnRequestPermissionsRe
val defaultUncaughtExceptionHandler = Thread.getDefaultUncaughtExceptionHandler()
// High priority, so don't use StatusThreadPoolExecutor
Thread.setDefaultUncaughtExceptionHandler { thread, t ->
Log.v("RNError", "Trying to log all Errors in MainActivity.lt -> " + t.message)
if (t.message?.contains("Loss of precision during arithmetic conversion") == true) {
// Skip this exception
Log.e("RNError", "Caught harmless arithmetic conversion error", t)
Expand Down
4 changes: 2 additions & 2 deletions android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@ commitHash=unknown
# to write custom TurboModules/Fabric components OR use libraries that
# are providing them.
# enabling new architecture requires hermes to be enabled
newArchEnabled=false
newArchEnabled=true

# Use this property to enable or disable the Hermes JS engine.
# If set to false, you will be using JSC instead.
# Disabled for debug builds to avoid 'maximum call stack exceeded' errors.
# https://github.com/status-im/status-mobile/issues/18493
hermesEnabled=false
hermesEnabled=true
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
"react-native-navigation": "7.39.0",
"react-native-orientation-locker": "^1.5.0",
"react-native-permissions": "4.1.5",
"react-native-reanimated": "3.6.1",
"react-native-reanimated": "3.8.1",
"react-native-redash": "18.1.0",
"react-native-shadow-2": "^7.0.8",
"react-native-shake": "^3.3.1",
Expand Down
11 changes: 11 additions & 0 deletions patches/NativeReanimatedModule.cpp.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
--- /tmp/tmp-status-mobile-de25cbf05/tmp.DAzJrrqMnT/NativeReanimatedModule.cpp 2024-09-15 09:55:26.503298000 +0530
+++ ./node_modules/react-native-reanimated/Common/cpp/NativeModules/NativeReanimatedModule.cpp 2024-09-15 09:57:28.977947310 +0530
@@ -600,7 +600,7 @@

for (const auto &[shadowNode, props] : copiedOperationsQueue) {
const ShadowNodeFamily &family = shadowNode->getFamily();
- react_native_assert(family.getSurfaceId() == surfaceId_);
+// react_native_assert(family.getSurfaceId() == surfaceId_);

#if REACT_NATIVE_MINOR_VERSION >= 73
// Fix for catching nullptr returned from commit hook was introduced
Loading

0 comments on commit b0e55f2

Please sign in to comment.