[Sentry] - Add Auth manual error tracking#77231
Conversation
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / SafariScreen.Recording.2025-12-16.at.3.56.26.AM.mov
|
|
Please merge main as the branch is behind 1k+ commits and hopefully fix 👇
|
|
@situchan I updated it, looks like it helped |
|
No product considerations, removing my review |
|
@situchan thanks for the review! For testing on dev, I just added a timer in Expensify.tsx to trigger the reauthenticate function after 10 seconds: And in reauthenticate I hardcoded some responses, e.g.:
Also, when testing on dev, please remember to enable Sentry dev logging, basically by commenting out: and Here you can see some example errors in sentry dashboard: |
|
@situchan You have access to sentry if you sign in with the github sso |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.2.82-0 🚀
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.2.82-0 🚀
|
|
@rinej can you qa this please |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.2.82-0 🚀
|
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.2.84-0 🚀
|
|
Here are the filtered events -> https://expensify.sentry.io/issues/errors-outages/?environment=staging&query=authentication_function%3A%5Breauthenticate%2CAuthenticate%5D&referrer=issue-list&statsPeriod=14d Looks like it is working fine ✅ We have quite a lot of errors with partnerUserID is missing, I will investigate it |
|
🚀 Deployed to production by https://github.com/AndrewGable in version: 9.2.84-8 🚀
|





Explanation of Change
Adds Sentry tracking for authentication failures to improve debugging of auth issues.
Tracks 3 failure scenarios: missing params, network retries, and auth failures
Includes context like error type, function name, json code, and command for easier debugging
Sentry dashboard example:

Fixed Issues
$ #74139
PROPOSAL:
Tests
Offline tests
QA Steps
Reach out to @rinej @sosek108 @rlinoz or @adhorodyski for the internalQA
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari