You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2025-03-13] iOS Reports - Selection mode persists in Reports after entering selection mode in Categories #57238
Version Number: 9.1.3-0 Reproducible in staging?: Yes Reproducible in production?: Yes If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Yes, reproducible on both If this was caught during regression testing, add the test name, ID and link from TestRail: Exp Email or phone of affected tester (no customers):applausetester+sj9032@applause.expensifail.com Issue reported by: Applause Internal Team Device used: iPhone 15 Pro Max / iOS 18.3 App Component: Search
Action Performed:
Precondition:
Account has no expenses at all.
Launch ND or hybrid app.
Go to workspace settings > Categories.
Long press on any category.
Tap Select.
Swipe to right to go back (not app back button).
Tap Reports tab.
Expected Result:
Selection mode will not persist in Reports after entering selection mode in Categories.
Actual Result:
Selection mode persists in Reports after entering selection mode in Categories.
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
None
What alternative solutions did you explore? (Optional)
NA
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.
But for search we specifically turned off shouldAutoTurnOff in here to avoid flickering on search if the selection mode is on and user switches from Search -> other tab -> Search because previously the behaviour was that the selection mode and all the previous selection was persisted on switching away from search tab. But now if you make a selection in search and move away from search the selection is reset. So we don't need shouldAutoTurnOff set to false anymore
What changes do you think we should make in order to solve the problem?
We don't need shouldAutoTurnOff to be false so that it will reset selection mode when navigating into search page. So remove shouldAutoTurnOff prop in SelectionListWithModal as we are only using it for this case. and change
changed the title [-]iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/-][+][Needs Repro] iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/+]on Feb 26, 2025
changed the title [-]iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/-][+][Due for payment 2025-03-13] iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/+]on Mar 6, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.9-8 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@hungvu193@strepanier03@hungvu193 The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Test:
Create a brand new account.
Launch ND or hybrid app.
Go to workspace settings > Categories.
Long press on any category.
Tap Select.
Swipe to the right to go back (not app back button).
Activity
melvin-bot commentedon Feb 21, 2025
Triggered auto assignment to @strepanier03 (
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.daledah commentedon Feb 21, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
Selection mode persists in Reports after entering selection mode in Categories.
What is the root cause of that problem?
When swipe to leave Categories page, we don't have logics to turn off selection mode.
The logics are only implemented with the back button:
App/src/pages/workspace/categories/WorkspaceCategoriesPage.tsx
Lines 392 to 397 in bf50378
What changes do you think we should make in order to solve the problem?
Add an
useEffectto use the above logic when unmountWhat specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
None
What alternative solutions did you explore? (Optional)
NA
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.
FitseTLT commentedon Feb 21, 2025
🚨 Edited by proposal-police: This proposal was edited at 2025-02-21 17:18:47 UTC.
Proposal
Please re-state the problem that we are trying to solve in this issue.
iOS Reports - Selection mode persists in Reports after entering selection mode in Categories
What is the root cause of that problem?
We normally reset mobile selection on mount unless
shouldAutoTurnOffis falseApp/src/hooks/useMobileSelectionMode.ts
Lines 9 to 14 in b9c5fd3
But for search we specifically turned off shouldAutoTurnOff in here to avoid flickering on search if the selection mode is on and user switches from Search -> other tab -> Search because previously the behaviour was that the selection mode and all the previous selection was persisted on switching away from search tab. But now if you make a selection in search and move away from search the selection is reset. So we don't need shouldAutoTurnOff set to false anymore
What changes do you think we should make in order to solve the problem?
We don't need shouldAutoTurnOff to be false so that it will reset selection mode when navigating into search page. So remove shouldAutoTurnOff prop in
SelectionListWithModalas we are only using it for this case. and changeApp/src/components/Search/index.tsx
Line 149 in b9c5fd3
we can additionally consider resetting selection mode in unmount instead of the current approach of resetting on mount
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
N / A
What alternative solutions did you explore? (Optional)
melvin-bot commentedon Feb 24, 2025
@strepanier03 Whoops! This issue is 2 days overdue. Let's get this updated quick!
strepanier03 commentedon Feb 26, 2025
Testing on Android standalone and unable to repro. I'll try on hybrid app tomorrow.
[-]iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/-][+][Needs Repro] iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/+]MelvinBot commentedon Feb 26, 2025
This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989
hungvu193 commentedon Feb 26, 2025
I can reproduce based on the OP steps
trim.244317EA-8880-4FF3-B70F-2D6B92B7AF8D.MOV
@strepanier03 Can you assign me to this issue?
Slack thread:
https://expensify.slack.com/archives/C02NK2DQWUX/p1740534524543399
28 remaining items
[-]iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/-][+][Due for payment 2025-03-13] iOS Reports - Selection mode persists in Reports after entering selection mode in Categories[/+]melvin-bot commentedon Mar 6, 2025
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Mar 6, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.9-8 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2025-03-13. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Mar 6, 2025
@hungvu193 @strepanier03 @hungvu193 The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]
hungvu193 commentedon Mar 10, 2025
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to comment: https://github.com/Expensify/App/pull/50705/files#r1986731525
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
Test:
Do we agree 👍 or 👎
strepanier03 commentedon Mar 13, 2025
Payment Summary
strepanier03 commentedon Mar 13, 2025
@hungvu193 - I've finished up the reg test and you can use the payment summary above to put in your manual payment request.
@FitseTLT - I paid and closed your contract in Upwork.
Thank you both for all your work on this one!
garrettmknight commentedon Mar 21, 2025
$250 approved for @hungvu193