feat(debug-report): capture account count + per-account provider/auth-type, and attach recent app logs #235

Closed
opened 2026-07-03 16:47:39 +00:00 by JMR-dev · 0 comments
JMR-dev commented 2026-07-03 16:47:39 +00:00 (Migrated from github.com)

Enrich the opt-in debug / problem report (issue #34; DiagnosticsCollector) so it's more useful for triage — without adding PII.

Add to the report

  • Number of accounts configured in the app.
  • Per-account type / provider + auth method — e.g. Gmail / Outlook / generic IMAP, plus the AuthType (OAUTH_OUTLOOK, app-password, …). Do NOT include the email address or any credential — only the count and the provider/auth-type enums. (Privacy: the report is user-submitted and must stay PII-free, consistent with how DiagnosticsCollector already emits only settings values.)
    • Source: the account DAO in AccountDatabase. Derive a coarse provider label from AuthType and/or the IMAP host (map to Gmail / Outlook / Other) — don't store the raw host if it could identify the user.

If feasible — attach recent logs

  • Add recent device/app logs as a separate JSON object/array in the submitted report (alongside the existing settings block), not inlined into existing fields.
  • Prefer the app's own AppLog buffer (already used, e.g. in IdleService) over raw logcat, so it's scoped to our app and easier to scrub; if logcat is used, filter to the app's tags/PID.
  • Privacy is a hard constraint: scrub PII (email addresses, tokens, message content) before submission; release builds already strip Log.d/v. Bound the size (last N lines / last few minutes) so the payload stays reasonable.

Notes

  • Keep it strictly opt-in, sent only on explicit submit (the report is already gated that way).
  • Update the diagnostics/report tests and the data-safety docs (docs/play-data-safety.md, PRIVACY.md) if the report's contents change.
Enrich the opt-in debug / problem report (issue #34; `DiagnosticsCollector`) so it's more useful for triage — **without adding PII**. ## Add to the report - **Number of accounts** configured in the app. - **Per-account type / provider + auth method** — e.g. Gmail / Outlook / generic IMAP, plus the `AuthType` (OAUTH_OUTLOOK, app-password, …). **Do NOT include the email address or any credential** — only the count and the provider/auth-type enums. (Privacy: the report is user-submitted and must stay PII-free, consistent with how `DiagnosticsCollector` already emits only settings values.) - Source: the account DAO in `AccountDatabase`. Derive a **coarse provider label** from `AuthType` and/or the IMAP host (map to Gmail / Outlook / Other) — don't store the raw host if it could identify the user. ## If feasible — attach recent logs - Add **recent device/app logs** as a **separate JSON object/array** in the submitted report (alongside the existing `settings` block), not inlined into existing fields. - Prefer the app's own `AppLog` buffer (already used, e.g. in `IdleService`) over raw logcat, so it's scoped to our app and easier to scrub; if logcat is used, filter to the app's tags/PID. - **Privacy is a hard constraint:** scrub PII (email addresses, tokens, message content) before submission; release builds already strip `Log.d/v`. Bound the size (last N lines / last few minutes) so the payload stays reasonable. ## Notes - Keep it strictly opt-in, sent only on explicit submit (the report is already gated that way). - Update the diagnostics/report tests and the data-safety docs (`docs/play-data-safety.md`, `PRIVACY.md`) if the report's contents change.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: JMR-dev/LibreMail#235