[Performance] Read Spotnana tripData from report NVPs - #100872
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.
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
@jasperhuangg Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c25de01534
ℹ️ About Codex in GitHub
Your team has set up Codex to 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 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (!isCurrentUserTraveler(reportNameValuePairs, currentUserEmail)) { | ||
| continue; | ||
| } | ||
| const reservations = getReservationsFromTripReport(report); | ||
| const reservations = getReservationsFromTripReport(report, reportNameValuePairs); |
There was a problem hiding this comment.
Filter reservations to the matching traveler
When a trip contains separate PNRs for the current user and other travelers, this report-level check succeeds because the user appears in any one PNR, but getReservationsFromTripReport() then returns reservations from every PNR in the payload. Consequently, Home can list another traveler's flights or hotels alongside the current user's reservations. Filter the payload or returned reservations by the PNRs whose traveler list contains currentUserEmail.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
That was the case before already
|
🚧 blimpich has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/blimpich in version: 9.4.77-0 🚀
|
|
Yes — one help site article needed an update. Draft PR: #101001 WhyMost of this PR is an internal data-source refactor (reading
On checking the docs, the Upcoming travel section wasn't documented at all — What the draft PR changesOne file,
How I verified the labels and behavior
Live web UI check: the Home tab label is confirmed. The Upcoming travel section itself could not be observed live — the test account has no booked trips, so the section doesn't render. The behavior described in the article is read from code, not from a live trip, so please sanity-check it against what you saw in your test. @rlinoz, please review the linked help site PR and confirm it reflects the current behavior. Then mark the linked help site PR view run · no recording available |
|
Deploy Blocker #101054 was identified to be related to this PR. |
|
🚀 Deployed to production by https://github.com/luacmartins in version: 9.4.77-4 🚀
Bundle Size Analysis (Sentry): |
Issues attributed to commits in this pull requestThis pull request was merged and Sentry observed the following issues:
|
Explanation of Change
Moves Spotnana
tripDatareads from reports to their corresponding report name-value-pairs, so App is ready for Auth to stop duplicating the payload in report data.This is also fixing the
Upcoming travelsection in the home tab, by looking at the traveler instead of the owner of the trip chat.related auth pr: https://github.com/Expensify/Auth/pull/24416
Fixed Issues
https://github.com/Expensify/Expensify/issues/680660
PROPOSAL:
Tests
Offline tests
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand 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