mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Adding Soft Error Logging to FallbackJSBundleLoader
Reviewed By: michalgr Differential Revision: D4405355 fbshipit-source-id: 7730a1afd74ace7fdad91b22f9254e83d16d1050
This commit is contained in:
committed by
Facebook Github Bot
parent
c3892fa871
commit
87c6bcb65d
@@ -32,4 +32,3 @@ android_library(
|
||||
'PUBLIC',
|
||||
],
|
||||
)
|
||||
|
||||
|
||||
@@ -14,6 +14,8 @@ import java.util.List;
|
||||
import java.util.ListIterator;
|
||||
import java.util.Stack;
|
||||
|
||||
import com.facebook.common.logging.FLog;
|
||||
|
||||
/**
|
||||
* FallbackJSBundleLoader
|
||||
*
|
||||
@@ -24,6 +26,7 @@ import java.util.Stack;
|
||||
public final class FallbackJSBundleLoader extends JSBundleLoader {
|
||||
|
||||
/* package */ static final String RECOVERABLE = "facebook::react::Recoverable";
|
||||
/* package */ static final String TAG = "FallbackJSBundleLoader";
|
||||
|
||||
// Loaders to delegate to, with the preferred one at the top.
|
||||
private Stack<JSBundleLoader> mLoaders;
|
||||
@@ -60,7 +63,7 @@ public final class FallbackJSBundleLoader extends JSBundleLoader {
|
||||
|
||||
mLoaders.pop();
|
||||
mRecoveredErrors.add(e);
|
||||
// TODO (t14839302): Report a soft error for each swallowed exception.
|
||||
FLog.wtf(TAG, "Falling back from recoverable error", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user