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
[HOLD for payment 2024-09-10][$250] [Search v2.1] Selected expense numbers are shown when logging in to another account #47168
Version Number: 9.0.18-0 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: N/A Email or phone of affected tester (no customers):dave0123seife@gmail.com Issue reported by: Applause - Internal Team
Action Performed:
Log into an account that have expenses
Click on search, found at the bottom
Select all the expenses, Notice the selected numbers are shown a the top
Log out from the account
Log back in with a different account
Go to search
Expected Result:
Selected number is not show
Actual Result:
Selected number of expenses of the previous account are shown
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
@kadiealexander FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors
changed the title [-]Search - Selected expense numbers are shown when logging in to another account[/-][+][$250] Search - Selected expense numbers are shown when logging in to another account[/+]on Aug 14, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@DylanDylann] Determine if we should create a regression test for this bug.
[@DylanDylann] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@DylanDylann] The PR that introduced the bug has been identified. Link to the PR: NA
[@DylanDylann] 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: NA
[@DylanDylann] A discussion in #expensify-bugs 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: NA
[@DylanDylann] Determine if we should create a regression test for this bug. Yes
[@DylanDylann] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
Regression Test Proposal
Open Search page
Select some transactions on the page
Logout and relogin
Open Search page again
Verify the selection is cleared and not in a selection mode
Activity
melvin-bot commentedon Aug 9, 2024
Triggered auto assignment to @kadiealexander (
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.lanitochka17 commentedon Aug 9, 2024
@kadiealexander FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors
bernhardoj commentedon Aug 9, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue.
The selected expense in search page is persisted through different login.
What is the root cause of that problem?
The number of the selected expenses is coming from the search context provider.
App/src/components/Search/SearchPageHeader.tsx
Line 274 in db669c4
App/src/components/Search/SearchPageHeader.tsx
Line 117 in db669c4
The search context provider is put at App.tsx.
App/src/App.tsx
Line 95 in db669c4
So, even when the user log out, the context data is still persisted.
What changes do you think we should make in order to solve the problem?
Move the SearchContextProvider to AuthScreen, just like OptionsListContextProvider.
App/src/libs/Navigation/AppNavigator/AuthScreens.tsx
Lines 355 to 356 in db669c4
What alternative solutions did you explore? (Optional)
Call
clearSelectedTransactionswhen AuthScreens is unmounted.melvin-bot commentedon Aug 12, 2024
@kadiealexander Whoops! This issue is 2 days overdue. Let's get this updated quick!
[-]Search - Selected expense numbers are shown when logging in to another account[/-][+][$250] Search - Selected expense numbers are shown when logging in to another account[/+]melvin-bot commentedon Aug 14, 2024
Job added to Upwork: https://www.upwork.com/jobs/~0112a275318e1e1dc4
melvin-bot commentedon Aug 14, 2024
Triggered auto assignment to Contributor-plus team member for initial proposal review - @eVoloshchak (
External)44 remaining items
kadiealexander commentedon Sep 12, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
kadiealexander commentedon Sep 12, 2024
Payouts due:
Upwork job is here.
DylanDylann commentedon Sep 12, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@DylanDylann] The PR that introduced the bug has been identified. Link to the PR: NA
[@DylanDylann] 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: NA
[@DylanDylann] A discussion in #expensify-bugs 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: NA
[@DylanDylann] Determine if we should create a regression test for this bug. Yes
[@DylanDylann] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
Regression Test Proposal
Do we agree 👍 or 👎
kadiealexander commentedon Sep 16, 2024
Payout summary here.
bernhardoj commentedon Sep 16, 2024
Requested in ND.
JmillsExpensify commentedon Sep 16, 2024
$250 approved for @bernhardoj