From d670381fac65b4f3955634c1c4342f9e43017a4a Mon Sep 17 00:00:00 2001 From: Joshua Gross Date: Thu, 20 May 2021 09:47:47 -0700 Subject: [PATCH] Reduce FabricUIManager soft errors further Summary: Reduce soft error volume; see comments. Changelog: [Internal] Reviewed By: ShikaSD Differential Revision: D28551214 fbshipit-source-id: 7e6aa1ee7cad812650bd6219d0cbe568c3cdd3de --- .../com/facebook/react/fabric/FabricUIManager.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ReactAndroid/src/main/java/com/facebook/react/fabric/FabricUIManager.java b/ReactAndroid/src/main/java/com/facebook/react/fabric/FabricUIManager.java index aa01b18d593..7180d707108 100644 --- a/ReactAndroid/src/main/java/com/facebook/react/fabric/FabricUIManager.java +++ b/ReactAndroid/src/main/java/com/facebook/react/fabric/FabricUIManager.java @@ -42,7 +42,6 @@ import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.bridge.ReactContext; import com.facebook.react.bridge.ReactMarker; import com.facebook.react.bridge.ReactMarkerConstants; -import com.facebook.react.bridge.ReactNoCrashSoftException; import com.facebook.react.bridge.ReactSoftException; import com.facebook.react.bridge.ReadableArray; import com.facebook.react.bridge.ReadableMap; @@ -574,11 +573,12 @@ public class FabricUIManager implements UIManager, LifecycleEventListener { try { mountingManager.updateProps(reactTag, props); } catch (Exception ex) { - // TODO T42943890: Fix animations in Fabric and remove this try/catch - ReactSoftException.logSoftException( - TAG, - new ReactNoCrashSoftException( - "Caught exception in synchronouslyUpdateViewOnUIThread", ex)); + // TODO T42943890: Fix animations in Fabric and remove this try/catch? + // There might always be race conditions between surface teardown and + // animations/other operations, so it may not be feasible to remove this. + // Practically 100% of reported errors from this point are because the + // surface has stopped by this point, but the MountItem was queued before + // the surface was stopped. It's likely not feasible to prevent all such races. } }