Repository navigation
Description
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number:
Reproducible in staging?: Needs Reproduction
Reproducible in production?: Needs Reproduction
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @shawnborton
Slack conversation (hyperlinked to channel name): #Expensify Bugs
Action Performed:
- Navigate to Reports
- Open a report that contains more than 10 card expenses
- Observe that the expense rows are highlighted
- Notice that the page loads scrolled down instead of starting at the top.
Expected Result:
No expense rows should be highlighted by default when opening a report.
The report view should always start scrolled to the very top, regardless of how many expenses are in the report.
Actual Result:
Expense rows are highlighted upon opening. For reports with >10 card expenses, the page is not at the top but is scrolled down by default.
Workaround:
Unknown
Platforms:
Select the officially supported platforms where the issue was reproduced:
- Android: App
- Android: mWeb Chrome
- iOS: App
- iOS: mWeb Safari
- iOS: mWeb Chrome
- Windows: Chrome
- MacOS: Chrome / Safari
- MacOS: Desktop
Platforms Tested:
On which of our officially supported platforms was this issue tested:- Android: App
- Android: mWeb Chrome
- iOS: App
- iOS: mWeb Safari
- iOS: mWeb Chrome
- Windows: Chrome
- MacOS: Chrome / Safari
- MacOS: Desktop
Screenshots/Videos
Add any screenshot/video evidence
The video for the issue is in OP
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~021957565230943425423
- Upwork Job ID: 1957565230943425423
- Last Price Increase: 2025-08-18
Issue Owner
Current Issue Owner: @Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
melvin-bot commentedon Aug 18, 2025
Triggered auto assignment to @lschurr (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.MelvinBot commentedon Aug 18, 2025
This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989
truph01 commentedon Aug 18, 2025
I can reproduce this bug by following the test step in OP:
Screen.Recording.2025-08-19.at.02.50.37.mov
I can take over this issue as C+ based on message.
[-]Report opens with expense rows highlighted and page scrolled down[/-][+][$250] Report opens with expense rows highlighted and page scrolled down[/+]melvin-bot commentedon Aug 18, 2025
Job added to Upwork: https://www.upwork.com/jobs/~021957565230943425423
melvin-bot commentedon Aug 18, 2025
Current assignee @truph01 is eligible for the External assigner, not assigning anyone new.
trjExpensify commentedon Aug 18, 2025
Thanks, @truph01. Assigned you for C+ duties.
mkzie2 commentedon Aug 19, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
Expense rows are highlighted upon opening. For reports with >10 card expenses, the page is not at the top but is scrolled down by default.
What is the root cause of that problem?
The backend can return some transactions of the expense report in
OpenAppAPI. When it happens,useNewTransactionshook returns the remaining list of transactions of the expense report after theOpenReportAPI is completeApp/src/components/MoneyRequestReportView/MoneyRequestReportView.tsx
Line 109 in b7b6678
App/src/hooks/useNewTransactions.ts
Lines 10 to 30 in b7b6678
Then the expense is highlighted, and the page scrolls down to the highlighted expense here.
App/src/components/MoneyRequestReportView/MoneyRequestReportActionsList.tsx
Lines 584 to 590 in b7b6678
What changes do you think we should make in order to solve the problem?
We should consider
hasOnceLoadedReportActionsparam astrueif it's not the first time theOpenReportis called. That means the previous value ofreportMetadata?.hasOnceLoadedReportActionsistrueApp/src/components/MoneyRequestReportView/MoneyRequestReportView.tsx
Line 109 in b7b6678
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
NA
What alternative solutions did you explore? (Optional)
We can only consider a transaction to be a new transaction if it's just created by checking the
insertedtimeApp/src/hooks/useNewTransactions.ts
Lines 10 to 30 in b7b6678
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
Pujan92 commentedon Aug 19, 2025
We have a similar issue and we can put this on hold until that's #66801 merged.
shawnborton commentedon Aug 19, 2025
Ah yeah, we can probably close this issue in favor of that linked PR.
trjExpensify commentedon Aug 19, 2025
yeah, agreed this is a dupe, let's close.