Skip to content

Don't report OAuth access_denied to Sentry#128

Open
gumclaw wants to merge 1 commit intomainfrom
fix/oauth-access-denied-sentry
Open

Don't report OAuth access_denied to Sentry#128
gumclaw wants to merge 1 commit intomainfrom
fix/oauth-access-denied-sentry

Conversation

@gumclaw
Copy link
Copy Markdown

@gumclaw gumclaw commented Mar 30, 2026

Summary

  • Skip Sentry.captureException when the OAuth error code is access_denied (user cancelled/denied the authorization prompt)
  • Other OAuth error types continue to be reported to Sentry
  • Adds tests verifying both behaviors

Fixes https://gumroad-to.sentry.io/issues/7374154819/

Test plan

  • npx jest --passWithNoTests passes (91 tests)
  • Verify in staging: cancel OAuth prompt → no new Sentry event
  • Verify in staging: simulate a real OAuth error → Sentry event created

🤖 Generated with Claude Code

When a user cancels or denies the OAuth authorization prompt,
expo-auth-session returns an error with code access_denied. This is
expected user behavior, not a real error. Skip Sentry reporting for
this case while continuing to capture all other OAuth errors.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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