Demote errors in crash reporter

Summary:
Not fatal errors and actually very, very high-firing. Something about
the serialisation here is wrong so I can't tell the exactly number right now.

Reviewed By: priteshrnandgaonkar

Differential Revision: D27117067

fbshipit-source-id: d9ce8c736ca2228acedeadeb2e7ee6744d766265
This commit is contained in:
Pascal Hartig
2021-03-18 05:44:10 -07:00
committed by Facebook GitHub Bot
parent f04c8e8e2c
commit 414dd4d5ff

View File

@@ -288,11 +288,12 @@ function addFileWatcherForiOSCrashLogs(
} }
fs.readFile(filepath, 'utf8', function (err, data) { fs.readFile(filepath, 'utf8', function (err, data) {
if (err) { if (err) {
console.error(err); console.warn('Failed to read crash file', err);
return; return;
} }
if (shouldShowiOSCrashNotification(serial, data)) if (shouldShowiOSCrashNotification(serial, data)) {
reportCrash(parseCrashLog(data, deviceOs, null)); reportCrash(parseCrashLog(data, deviceOs, null));
}
}); });
}); });
}); });
@@ -450,7 +451,7 @@ export function devicePlugin(client: DevicePluginClient) {
const ignore = !crash.name && !crash.reason; const ignore = !crash.name && !crash.reason;
const unknownCrashCause = crash.reason === UNKNOWN_CRASH_REASON; const unknownCrashCause = crash.reason === UNKNOWN_CRASH_REASON;
if (ignore || unknownCrashCause) { if (ignore || unknownCrashCause) {
console.error('Ignored the notification for the crash', crash); console.warn('Ignored the notification for the crash', crash);
return; return;
} }