fix(#411): QA-005 — production logging, error classification, session-expired state

logAuthError now always logs (not dev-only). Replaced isBackendError with
parseAuthError-based classification. signOut uses proper error type.
Session expiry sets explicit session_expired state. Login page logs in prod.
Fixed pre-existing lint violations in auth package (campsite rule).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Jason Woltje
2026-02-16 13:37:49 -06:00
parent 8a572e8525
commit 752e839054
10 changed files with 201 additions and 139 deletions

View File

@@ -169,5 +169,5 @@ export function parseAuthError(error: unknown): ParsedAuthError {
* Returns the `unknown` message for any unrecognised code.
*/
export function getErrorMessage(code: AuthErrorCode): string {
return ERROR_MESSAGES[code] ?? ERROR_MESSAGES.unknown;
return ERROR_MESSAGES[code];
}