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-08-19] [$250] Noticeable Delay When Selecting Assignee During Task Assignment #44443

Closed
5 of 6 tasks
izarutskaya opened this issue Jun 26, 2024 · 51 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 Engineering External Added to denote the issue can be worked on by a contributor

Comments

@izarutskaya
Copy link

izarutskaya commented Jun 26, 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: v9.0.2-0
Reproducible in staging?: Y
Reproducible in production?: N
Email or phone of affected tester (no customers): abebemiherat@gmail.com
Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team

Action Performed:

  1. FAB > Assign Task
  2. Add title > Go to Assignee
  3. Click on Assignee > Select User

Expected Result:

There should be no noticeable delay, and the process should be smooth when selecting an assignee from the dropdown during task assignment

Actual Result:

Noticeable delay when selecting an assignee

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

Bug6525043_1719393634471.Screen_Recording_2024-06-25_at_11.30.08_PM.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0179306ad6d57e7abf
  • Upwork Job ID: 1805923850414823822
  • Last Price Increase: 2024-07-10
Issue OwnerCurrent Issue Owner: @dylanexpensify
@izarutskaya izarutskaya added DeployBlockerCash This issue or pull request should block deployment Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. DeployBlocker Indicates it should block deploying the API labels Jun 26, 2024
Copy link

melvin-bot bot commented Jun 26, 2024

Triggered auto assignment to @MitchExpensify (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.

Copy link

melvin-bot bot commented Jun 26, 2024

Triggered auto assignment to @mountiny (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Jun 26, 2024
Copy link
Contributor

👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@izarutskaya
Copy link
Author

@MitchExpensify 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.

@izarutskaya
Copy link
Author

We think this issue might be related to the #vip-vsb

@mountiny mountiny added External Added to denote the issue can be worked on by a contributor and removed DeployBlockerCash This issue or pull request should block deployment Hourly KSv2 DeployBlocker Indicates it should block deploying the API labels Jun 26, 2024
Copy link

melvin-bot bot commented Jun 26, 2024

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

@melvin-bot melvin-bot bot changed the title Noticeable Delay When Selecting Assignee During Task Assignment [$250] Noticeable Delay When Selecting Assignee During Task Assignment Jun 26, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Jun 26, 2024
Copy link

melvin-bot bot commented Jun 26, 2024

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

@melvin-bot melvin-bot bot added the Daily KSv2 label Jun 26, 2024
@mountiny
Copy link
Contributor

I barely saw som delay in the video, demoting and marking external

@nyomanjyotisa
Copy link
Contributor

Proposal

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

Delay When Selecting Assignee During Task Assignment

What is the root cause of that problem?

const debouncedOnSelectRow = useCallback(lodashDebounce(onSelectRow, 200), [onSelectRow]);

This line of code causes a 200 millis delay when selecting an assignee during task assignment

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

change that code to the following code since we need to keep the onSelectRow not called more than once in 200 millis

    const lastExecutedRef = useRef(0);
    const debouncedOnSelectRow = useCallback((item: TItem) => {
        const now = Date.now();
    
        if (now - lastExecutedRef.current >= 200) {
          onSelectRow(item);
          lastExecutedRef.current = now;
        }
    }, [onSelectRow]);

Result (no delay on selecting assignee and not going back twice on multiple mouse clicks on select Priority mode):
https://github.com/Expensify/App/assets/73281575/60b796d8-87d4-4efa-92d4-124393933fef

What alternative solutions did you explore? (Optional)

N/A

@mountiny
Copy link
Contributor

@huzaifa-99 @parasharrajat this seems to be coming from your PR then. can you have a look please

@parasharrajat
Copy link
Member

Yes, looks like it @mountiny. IMO, I see no delay and I thought it is fine on the original PR. @huzaifa-99 any idea on enhancing this?

IMO, this issue should still be counted as an enhancement, not a regression.

@huzaifa-99
Copy link
Contributor

I didn't see any noticeable delays during tests, and IMO this is not a regression.

@huzaifa-99 any idea on enhancing this?

will look into it shortly today.

@parasharrajat
Copy link
Member

We initially used that. There is some discussion here #25604 (comment) about it.

@BrtqKr BrtqKr mentioned this issue Jul 22, 2024
50 tasks
@melvin-bot melvin-bot bot added Overdue Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 Overdue labels Jul 22, 2024
@BrtqKr
Copy link
Contributor

BrtqKr commented Jul 22, 2024

ok, it doesn't seem to be happening in the current state of the app, so I guess the PR is ready for the review.

@dylanexpensify
Copy link
Contributor

@mananjadhav for review!

@dylanexpensify
Copy link
Contributor

bump @mananjadhav

@mananjadhav
Copy link
Collaborator

I am done with my review and here's the checklist. Waiting on @mountiny but I think he was OOO last week.

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Aug 12, 2024
@melvin-bot melvin-bot bot changed the title [$250] Noticeable Delay When Selecting Assignee During Task Assignment [HOLD for payment 2024-08-19] [$250] Noticeable Delay When Selecting Assignee During Task Assignment Aug 12, 2024
Copy link

melvin-bot bot commented Aug 12, 2024

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

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Aug 12, 2024
Copy link

melvin-bot bot commented Aug 12, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.18-10 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-08-19. 🎊

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

  • @mananjadhav requires payment through NewDot Manual Requests
  • @BrtqKr does not require payment (Contractor)

Copy link

melvin-bot bot commented Aug 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:

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

@dylanexpensify
Copy link
Contributor

Payment coming up!

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Aug 18, 2024
Copy link

melvin-bot bot commented Aug 19, 2024

Payment Summary

Upwork Job

  • Reviewer: @mananjadhav owed $250 via NewDot
  • Contributor: @BrtqKr is from an agency-contributor and not due payment

BugZero Checklist (@dylanexpensify)

  • I have verified the correct assignees and roles are listed above and updated the neccesary manual offers
  • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants/1805923850414823822/hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@mananjadhav
Copy link
Collaborator

@dylanexpensify Can you please complete the payout summary?

I don't think we have any offending PR here. We did link a PR earlier but we've been using debounce even before. The existing regression tests for changes from debounce to useSingleExecution should cover the tests. Hence no new tests needed.

@melvin-bot melvin-bot bot added the Overdue label Aug 20, 2024
@dylanexpensify
Copy link
Contributor

Reviewing today! Apologies for delay!

@melvin-bot melvin-bot bot removed the Overdue label Aug 21, 2024
@dylanexpensify
Copy link
Contributor

Payment summary:

Contributor+: @mananjadhav $250 via NewDot

Please apply/request!

@JmillsExpensify
Copy link

$250 approved for @mananjadhav

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 Engineering External Added to denote the issue can be worked on by a contributor
Projects
No open projects
Development

No branches or pull requests