feat(mobile): enrich Sentry error context - #5432
Conversation
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Executive SummarySign-out now treats Files Reviewed (1 file)
Previous Review Summary (commit 8fb5361)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit 8fb5361)Status: 1 Issue Found | Recommendation: Address before merge Executive SummarySign-out can re-bind Sentry to the previous user because the new layout context effect ignores Overview
Issue Details (click to expand)WARNING
Files Reviewed (40 files)
Reviewed by grok-4.6 · Input: 127.6K · Output: 6.9K · Cached: 268.8K Review guidance: REVIEW.md from base branch |
| } catch (error) { | ||
| Sentry.captureException(error); | ||
| } catch { | ||
| Sentry.captureException(new Error('Attachment image metadata strip failed'), { |
There was a problem hiding this comment.
bot: Preserve the original image-processing failure when reporting it
Suggested fix: Bind the caught value and report that exception with the new static tags/fingerprint (for example, catch (error) { Sentry.captureException(error, { ... }) }). If raw native exception messages are intentionally excluded for privacy, route it through an approved sanitizer that still preserves safe diagnostic information such as error type and source stack; the current new Error only points to this catch handler and makes re-encode failures difficult to diagnose.
Summary
Verification
pnpm formatpnpm test(523 files, 5,340 tests)pnpm typecheckpnpm lintpnpm check:unusedgit diff --check