fix: prevent reporting to Sentry an error when the user rejects a tx in the wallet#321
Merged
fix: prevent reporting to Sentry an error when the user rejects a tx in the wallet#321
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
ff8630d to
3f0803c
Compare
LautaroPetaccio
approved these changes
Mar 5, 2026
| if (error === null || typeof error !== 'object') return false | ||
|
|
||
| const code = (error as { code: unknown }).code | ||
| // viem UserRejectedRequestError (EIP-1193) |
Collaborator
There was a problem hiding this comment.
WDYT about handling the 4100 error here https://eips.ethereum.org/EIPS/eip-1193 as well?
Contributor
Author
There was a problem hiding this comment.
After iterating this with the model we think this should be handled differently mostly because this 4100 error can be thrown when the wallet is not unlocked and can be related to other kind of errors/bugs. Will handle this in a new PR!
LautaroPetaccio
approved these changes
Mar 5, 2026
85fcb2d to
fcc3571
Compare
braianj
pushed a commit
that referenced
this pull request
Mar 6, 2026
…in the wallet (#321) * fix: prevent reporting to Sentry an error when the user rejects a tx in the wallet * fix: user rejected_action report to Sentry * refactor: PR feedback * chore: indent comment
braianj
added a commit
that referenced
this pull request
Mar 6, 2026
* feat: add email-only sign-in option with dynamic wallet ordering * fix: make email handlers optional and default feature flags to false for mobile compatibility * refactor: usage of sign in option variants * test: update * refactor: connetion buttons * refactor: sort imports * test: fix * fix: Incorrect handling of callback and magic re-log in (#325) * fix: Incorrect handling of callback and magic re-log in * fix: Ignore error * Ignore MISSING_PKCE_METADATA error * fix: Cannot read properties of null (reading length) (#327) * fix: prevent reporting to Sentry an error when the user rejects a tx in the wallet (#321) * fix: prevent reporting to Sentry an error when the user rejects a tx in the wallet * fix: user rejected_action report to Sentry * refactor: PR feedback * chore: indent comment * feat: Add test-ids-to elements for E2E testing (#330) * fix: SSO log-in with Magic by waiting for redirect url before trying to extract params (#329) * fix: SSO log-in with Magic by waiting for redirect url before trying to extract params * fix: apply PR feedback --------- Co-authored-by: Lautaro Petaccio <1120791+LautaroPetaccio@users.noreply.github.com> * fix: Avatar particles image size (#332) * feat: Asynchronously load OTP to reduce start time (#331) * feat: Asynchronously load OTP to reduce start time * fix: Linting * fix: Thirdweb fixed version * fix: Invalid method (#333) * chore: update package.lock.js * fix: preserve non-EMAIL primary option (mobile flow) in useWalletOptions hook and fix 'more options' visibility --------- Co-authored-by: Lautaro Petaccio <1120791+LautaroPetaccio@users.noreply.github.com> Co-authored-by: Alejo Thomas Ortega <alejothomasortega@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Silence Sentry alerts for user-rejected wallet interactions
When a user rejects a transaction or signature in their wallet (e.g. MetaMask), the error was being reported to Sentry as an application error. These are expected user actions, not bugs.
This manifests differently depending on the page and library path:
This PR:
All silenced rejections log a console.info breadcrumb for visibility.
Use Case Summary: