Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HOLD for payment 2024-10-17] [$250] Header flickers on the search page when switching tabs while reports are already selected. #49084

Closed
1 of 6 tasks
m-natarajan opened this issue Sep 12, 2024 · 31 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor

Comments

@m-natarajan
Copy link

m-natarajan commented Sep 12, 2024

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.33-1
Reproducible in staging?: Y
Reproducible in production?: Y
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: @jayeshmangwani
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1726146285093739

Action Performed:

  1. Open the app and go to the Search tab.
  2. Select one or two reports.
  3. Change the tab and then return to the Search tab.
  4. Observe the header of the Search tab.

Expected Result:

No visual issues (Header should not flicker)

Actual Result:

Header flickers, and for a moment, the sidebar screen header becomes visible.

Workaround:

Can the user still use Expensify without this being fixed? Have you informed them of the workaround?

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

header-flickers.mp4
az_recorder_20240912_091901.mp4

Add any screenshot/video evidence

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021836532792123032065
  • Upwork Job ID: 1836532792123032065
  • Last Price Increase: 2024-09-18
  • Automatic offers:
    • jjcoffee | Reviewer | 104043289
Issue OwnerCurrent Issue Owner: @alexpensify
@m-natarajan m-natarajan added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Sep 12, 2024
Copy link

melvin-bot bot commented Sep 12, 2024

Triggered auto assignment to @alexpensify (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
Copy link
Contributor

daledah commented Sep 12, 2024

Edited by proposal-police: This proposal was edited at 2024-09-12 15:09:06 UTC.

Proposal

Please re-state the problem that we are trying to solve in this issue.

Header flickers, and for a moment, the sidebar screen header becomes visible.

What is the root cause of that problem?

We're using useMobileSelectionMode in

const {selectionMode} = useMobileSelectionMode();

and

const {selectionMode} = useMobileSelectionMode(true);

so the selection will be reset after open search page

turnOffMobileSelectionMode();

What changes do you think we should make in order to solve the problem?

In most cases, we want to reset selection mode when users open page, but in Search page, we have the logic to turn on selection mode so we shouldn't reset it

  1. Disable shouldAutoTurnOff in useMobileSelectionMode
useMobileSelectionMode(false)
  1. Add new props shouldAutoTurnOff and pass it as false to SelectionListWithModal

  2. Use shouldAutoTurnOff in here

After doing that, the selection mode won't be auto reset at the beginning. But If users open page without any selections and selection mode is enable (in case users enable selection mode and go to search page by deeplink) -> we should turn off it

    const wasSelectionOn = useRef(false)

    useEffect(() => {
        ...
        if (selectedKeys.length > 0 && !selectionMode?.isEnabled) {
            wasSelectionOn.current = true
            turnOnMobileSelectionMode();
        }else if(selectedKeys.length == 0  && selectionMode?.isEnabled && !wasSelectionOn.current){
            turnOffMobileSelectionMode()
        }
    }, [isSmallScreenWidth, selectedTransactions, selectionMode?.isEnabled]);

What alternative solutions did you explore? (Optional)

NA

@melvin-bot melvin-bot bot added the Overdue label Sep 16, 2024
@alexpensify
Copy link
Contributor

Adding this one to my test list and will get to it later this week.

@melvin-bot melvin-bot bot removed the Overdue label Sep 16, 2024
@alexpensify alexpensify added the External Added to denote the issue can be worked on by a contributor label Sep 18, 2024
@melvin-bot melvin-bot bot changed the title Header flickers on the search page when switching tabs while reports are already selected. [$250] Header flickers on the search page when switching tabs while reports are already selected. Sep 18, 2024
Copy link

melvin-bot bot commented Sep 18, 2024

Job added to Upwork: https://www.upwork.com/jobs/~021836532792123032065

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Sep 18, 2024
Copy link

melvin-bot bot commented Sep 18, 2024

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

@alexpensify
Copy link
Contributor

@jjcoffee when you get a chance, can you review if one of these proposals will fix this issue? Thanks!

@jjcoffee
Copy link
Contributor

@daledah's proposal LGTM!

🎀👀🎀 C+ reviewed

Copy link

melvin-bot bot commented Sep 19, 2024

Triggered auto assignment to @aldo-expensify, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Sep 19, 2024
Copy link

melvin-bot bot commented Sep 19, 2024

📣 @jjcoffee 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job

Copy link

melvin-bot bot commented Sep 19, 2024

📣 @daledah You have been assigned to this job!
Please apply to the Upwork job and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Once you apply to this job, your Upwork ID will be stored and you will be automatically hired for future jobs!
Keep in mind: Code of Conduct | Contributing 📖

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Sep 20, 2024
@daledah
Copy link
Contributor

daledah commented Sep 20, 2024

@jjcoffee PR is ready.

@alexpensify
Copy link
Contributor

Awesome, now we wait for this one to go through the review process.

@alexpensify
Copy link
Contributor

The PR is still under review

@aldo-expensify
Copy link
Contributor

Thanks, reviewed

@alexpensify
Copy link
Contributor

Thank you!

@alexpensify
Copy link
Contributor

Ok, waiting for this one to go to Prod.

Copy link

melvin-bot bot commented Oct 10, 2024

⚠️ Looks like this issue was linked to a Deploy Blocker here

If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

If a regression has occurred and you are the assigned CM follow the instructions here.

If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

@alexpensify
Copy link
Contributor

@jjcoffee when you get a chance, can you please confirm if this blocker notice is correct? Thanks!

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Oct 10, 2024
@melvin-bot melvin-bot bot changed the title [$250] Header flickers on the search page when switching tabs while reports are already selected. [HOLD for payment 2024-10-17] [$250] Header flickers on the search page when switching tabs while reports are already selected. Oct 10, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Oct 10, 2024
Copy link

melvin-bot bot commented Oct 10, 2024

Reviewing label has been removed, please complete the "BugZero Checklist".

Copy link

melvin-bot bot commented Oct 10, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.47-4 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 2024-10-17. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented Oct 10, 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:

  • [@jjcoffee] The PR that introduced the bug has been identified. Link to the PR:
  • [@jjcoffee] 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:
  • [@jjcoffee] 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:
  • [@jjcoffee] Determine if we should create a regression test for this bug.
  • [@jjcoffee] 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.
  • [@alexpensify] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@jjcoffee
Copy link
Contributor

when you get a chance, can you please confirm if this blocker notice is correct? Thanks!

@alexpensify Yes it's correct, the PR got reverted. @daledah is working on a fix.

@alexpensify
Copy link
Contributor

alexpensify commented Oct 17, 2024

Payouts due: 2024-10-17

Upwork job is here. I'm still working on the payment process here. @daledah please accept the invite in Upwork. Thanks!

@alexpensify
Copy link
Contributor

I've completed the payment process for @jjcoffee. I'm waiting for @daledah to accept the invite and then I can complete the payment process. Also, I confirmed that there is no payment for reporting an issue.

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Oct 17, 2024
@alexpensify
Copy link
Contributor

I'm offline until Tuesday, but I passed by to check the payment status. We are waiting for @daledah to accept the offer in Upwork, and then I can complete the process.

@daledah
Copy link
Contributor

daledah commented Oct 18, 2024

@alexpensify I accepted the offer

@melvin-bot melvin-bot bot added the Overdue label Oct 21, 2024
Copy link

melvin-bot bot commented Oct 21, 2024

@alexpensify, @jjcoffee, @aldo-expensify, @daledah Whoops! This issue is 2 days overdue. Let's get this updated quick!

@aldo-expensify
Copy link
Contributor

@alexpensify I accepted the offer

I think this means we can close... Please reopen if I got that wrong :)

@alexpensify
Copy link
Contributor

@aldo-expensify—I was offline until today, hence the overdue notice. I saved this GitHub to return to when I was online again, but please keep it open. BZ still needs to go into Upwork and complete the payment process. Keeping this one closed, I finished the payment process last night.

@aldo-expensify
Copy link
Contributor

Thanks @alexpensify , will keep that in mind the next time :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor
Projects
No open projects
Status: No status
Development

No branches or pull requests

5 participants