Categories
| Category | Description | Example |
|---|---|---|
network | No connection or request timed out | Sync failed, no internet |
auth | Session expired or credentials rejected | Token invalid |
sync_conflict | Same record modified on two devices while offline | Last-write-wins applied |
corrupted_local_state | Drift database integrity failure | Unreadable record |
algorithm_failure | Mana engine returned an invalid or out-of-range result | Pool calculation error |
unexpected | Any error that does not match a known category | Unhandled exception |
UI behaviour by category
| Category | User action shown | Urgency |
|---|---|---|
network | Try again when connected | None |
auth | Sign in again | None |
sync_conflict | No action needed (resolved automatically) | None |
corrupted_local_state | Contact support | Low |
algorithm_failure | Restart app; contact support if it continues | Low |
unexpected | Try again; contact support if it continues | None |
Copy rules
- No blame. Never frame the error as the user’s fault.
- No urgency by default. Do not use exclamation marks or alarming phrasing.
- Provide a safe next step. Every error message must give the user one clear, low-effort action or explicitly tell them no action is needed.
- Avoid technical language. Don’t expose error codes, stack traces, or internal identifiers in user-facing copy.
Examples by category
network
network
Banned: “Connection failed. Please check your internet.”Use: “Couldn’t sync right now. It will try again when you’re connected.”
auth
auth
Banned: “Your session has expired. You must sign in again.”Use: “You’ve been signed out. Sign in again to continue.”
sync_conflict
sync_conflict
Banned: “Conflict detected. Changes may have been lost.”Use: Nothing shown to the user in most cases. If shown: “A small update was applied in the background.”
corrupted_local_state
corrupted_local_state
Banned: “Database error. Your data may be corrupt.”Use: “Something went wrong with your data. If this keeps happening, contact support and we’ll help.”
algorithm_failure
algorithm_failure
Banned: “Mana calculation error. Please restart.”Use: “There was a problem loading your plan. Restarting the app usually fixes this.”
unexpected
unexpected
Banned: “An unexpected error occurred.”Use: “Something didn’t work as expected. Try again, and contact support if it keeps happening.”
Logging rules
- Redact task titles. If the user has opted out of data sharing, task titles must not appear in logs.
- Redact check-in values. Raw [body, mind, mood] scores are sensitive health data - never log them in plain text.
- Log the error category and code path. Enough context to reproduce the issue, not enough to reconstruct private content.
- Include the version. App version and database schema version must accompany every error log.