Skip to content

fix(auth): show the generic message when getSession fails - #542

Draft
9thLevelSoftware wants to merge 1 commit into
mainfrom
cursor/auth-callback-generic-session-error-4faa
Draft

9thLevelSoftware wants to merge 1 commit into
mainfrom
cursor/auth-callback-generic-session-error-4faa

Conversation

@9thLevelSoftware

Copy link
Copy Markdown
Owner

Summary

When supabase.auth.getSession() returned an error during OAuth callback exchange, AuthCallback rendered error.message on the failure card. That path now logs the raw error with console.error and shows the existing GENERIC_AUTH_FAILURE_MESSAGE ("Authentication could not be completed. Please try again."). Successful session resolution and the URL error-code mapping are unchanged.

Verification

  • npm test -- src/app/components/__tests__/AuthCallback.test.tsx: 9 passed, including a new case that a getSession error shows the generic copy and does not render the provider message.
  • npm run lint: exit 0 (255 pre-existing warnings, no new diagnostics in the changed files).
  • npm run typecheck: OK — no new type errors (app 21 known, test 139 known).
Open in Web Open in Cursor 

AuthCallback rendered the raw Supabase session error. Keep that detail in the console and show GENERIC_AUTH_FAILURE_MESSAGE instead.

Co-authored-by: Devil <9thLevelSoftware@users.noreply.github.com>
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
phoenix-portal e17aa9d Commit Preview URL

Branch Preview URL
Oct 25 2026, 08:17 AM

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants