Skip to content

[HOLD for payment 2024-09-10][$250] [Search v2.1] Selected expense numbers are shown when logging in to another account #47168

Closed

Description

@lanitochka17

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: 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:

  1. Log into an account that have expenses
  2. Click on search, found at the bottom
  3. Select all the expenses, Notice the selected numbers are shown a the top
  4. Log out from the account
  5. Log back in with a different account
  6. 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?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6566633_1723204844051.IMG_3620.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0112a275318e1e1dc4
  • Upwork Job ID: 1823627646288296373
  • Last Price Increase: 2024-08-28
  • Automatic offers:
    • DylanDylann | Contributor | 103746189
Issue OwnerCurrent Issue Owner: @kadiealexander

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Aug 9, 2024
  2. melvin-bot commented on Aug 9, 2024

    @melvin-bot

    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.

  3. lanitochka17 commented on Aug 9, 2024

    @lanitochka17
    Author

    @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

  4. bernhardoj commented on Aug 9, 2024

    @bernhardoj
    Contributor

    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.

    itemsLength={selectedTransactionsKeys.length}

    const {selectedTransactions, clearSelectedTransactions} = useSearchContext();

    The search context provider is put at App.tsx.

    SearchContextProvider,

    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.

    return (
    <OptionsListContextProvider>

    What alternative solutions did you explore? (Optional)

    Call clearSelectedTransactions when AuthScreens is unmounted.

  5. melvin-bot commented on Aug 12, 2024

    @melvin-bot

    @kadiealexander Whoops! This issue is 2 days overdue. Let's get this updated quick!

  6. added
    ExternalAdded to denote the issue can be worked on by a contributor
    on Aug 14, 2024
  7. 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
  8. melvin-bot commented on Aug 14, 2024

    @melvin-bot
  9. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Aug 14, 2024
  10. melvin-bot commented on Aug 14, 2024

    @melvin-bot

    Triggered auto assignment to Contributor-plus team member for initial proposal review - @eVoloshchak (External)

  11. 44 remaining items

  12. kadiealexander commented on Sep 12, 2024

    @kadiealexander
    Contributor

    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:

  13. kadiealexander commented on Sep 12, 2024

    @kadiealexander
    Contributor

    Payouts due:

    Upwork job is here.

  14. DylanDylann commented on Sep 12, 2024

    @DylanDylann
    Contributor

    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

    1. Open Search page
    2. Select some transactions on the page
    3. Logout and relogin
    4. Open Search page again
    5. Verify the selection is cleared and not in a selection mode

    Do we agree 👍 or 👎

  15. kadiealexander commented on Sep 16, 2024

    @kadiealexander
    Contributor

    Payout summary here.

  16. bernhardoj commented on Sep 16, 2024

    @bernhardoj
    Contributor

    Requested in ND.

  17. JmillsExpensify commented on Sep 16, 2024

    @JmillsExpensify
    Contributor

    $250 approved for @bernhardoj

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions