-
Notifications
You must be signed in to change notification settings - Fork 318
Labels
bugSomething isn't workingSomething isn't working
Description
Summary:
- Wrap OAuth provider calls in try/catch and return a structured error when the provider is unreachable.
- Show a user-friendly message in the UI when sign in fails due to provider unavailability.
- Add unit tests for the failure path and an e2e test for UI behavior.
Files changed:
- frontend/src/lib/server/auth.ts
- frontend/src/components/SignInButton.tsx (or equivalent)
- tests/unit/auth.spec.ts
- tests/e2e/auth-provider-failure.spec.ts
Why:
- Prevents frontend crashes/hangs when third-party auth services are down.
- Improves UX and observability.
How tested:
- Unit tests added for provider failure and 5xx responses.
- Playwright e2e simulating provider downtime and asserting the error toast.
Notes:
- Logging added but no sensitive data is recorded.
- Telemetry hook included; configure Sentry/monitoring DSN as needed.
Checklist:
- Wrap provider calls in try/catch and return structured error response
- Return HTTP 502 with
OAUTH_PROVIDER_UNAVAILABLE/OAUTH_PROVIDER_ERROR - Show readable error message in UI
- Add unit tests
- Add e2e test
- Add telemetry/logging statement
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
In progress