feat(desktop): add privacy-safe incident diagnostics#10174
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1891aa9d18
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| area: "other", | ||
| failureClass: "user_report", | ||
| phase: "other") | ||
| SentrySDK.capture(message: sentryMessage) { scope in |
There was a problem hiding this comment.
Keep user reports in the Sentry feedback lane
When users click Send Report, this path now only calls capture(message:); the previous SentryFeedback submission was removed. The desktop backend only creates support action items for Sentry issues whose issueCategory is feedback, and its poller also queries issue.category:feedback (desktop/macos/Backend-Rust/src/routes/webhooks.rs:160 and :558), so these report events will be ignored by the existing feedback ingestion while the UI shows success. Keep a privacy-safe feedback-category submission, even with a generic message, or update the ingestion path at the same time.
Useful? React with 👍 / 👎.
| let nsError = error as NSError | ||
| let errorType = String(reflecting: type(of: error)) | ||
| SentrySDK.capture(message: fullMessage) { scope in | ||
| SentrySDK.capture(message: "Desktop error") { scope in |
There was a problem hiding this comment.
Give redacted errors a stable Sentry fingerprint
For production calls to logError(..., error:), every distinct actionable failure now reaches Sentry with the identical message Desktop error, and the differentiators are only stored as context; there is no fingerprint set anywhere under Desktop/Sources. That means unrelated failures reported through this common helper can collapse into the same Sentry issue, hiding new regressions and making the new diagnostics much harder to triage. Use a privacy-safe fingerprint/title derived from fields like error_type, domain, and code.
Useful? React with 👍 / 👎.
Summary
Privacy impact
Product invariants affected
Failure class
Validation
xcrun swift test --package-path Desktop— 2,856 tests passed.xcrun swift build -c debug --package-path Desktoppassed.Follow-up