-
Notifications
You must be signed in to change notification settings - Fork 3.5k
[No QA][Sentry] Active spans logging #79768
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[No QA][Sentry] Active spans logging #79768
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 28991fe283
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| function shouldForwardLog(log: {message?: string; parameters?: Record<string, unknown> | undefined}) { | ||
| if (log.message?.search('[Sentry]')) { | ||
| return true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix inverted Sentry log filter condition
The new filter uses log.message?.search('[Sentry]') directly as a truthy check, but search() returns 0 when the substring is at the start (falsy) and -1 when not found (truthy). This means messages that begin with [Sentry] are not forwarded, while unrelated logs that don’t contain [Sentry] are forwarded, which defeats the intended filtering. This will misroute logs in any environment where the [Sentry] prefix is used. Consider using includes('[Sentry]') or search(...) !== -1 to align the behavior with the intended filter.
Useful? React with 👍 / 👎.
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
trjExpensify
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sentry tooling! 👍
mountiny
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@truph01 Can you give it a test and check Sentry?
Sure, I'll take care of it this weekend. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppScreen.Recording.2026-01-19.at.10.54.42.movAndroid: mWeb ChromeScreen.Recording.2026-01-19.at.10.56.39.moviOS: HybridAppScreen.Recording.2026-01-19.at.10.39.57.moviOS: mWeb SafariScreen.Recording.2026-01-19.at.10.42.49.movMacOS: Chrome / SafariScreen.Recording.2026-01-19.at.10.31.10.mov |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
Explanation of Change
This PR adds logs around functions in
activeSpans. We also define redaction mechanism for parameters added to logs.Fixed Issues
$ #73322
PROPOSAL:
Tests
setup/telemetry/index.tscreateSpan. For expamle Open reportOffline tests
N/A
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
N/A
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
Details