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 2023-10-23] [$500] user have to press two times on Use current location #29100

Closed
4 of 6 tasks
m-natarajan opened this issue Oct 9, 2023 · 27 comments
Closed
4 of 6 tasks
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 Oct 9, 2023

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: 1.3.79-3
Reproducible in staging?: Yes
Reproducible in production?: Yes
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: @gadhiyamanan
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1696574867561759

Action Performed:

  1. click on FAB and select Request money
  2. go to distance tab
  3. click on Start
  4. enter any character which will suggest you location
  5. click on Use current location

Expected Result:

current location should be applied as start point

Actual Result:

on first click suggestion closes and on second click current location applies

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

Android: Native
Android: mWeb Chrome
Screen_Recording_20231006_122023_Chrome.mp4
iOS: Native
iOS: mWeb Safari
RPReplay_Final1696575159.MP4
MacOS: Chrome / Safari
use.location.mp4
Screen.Recording.2023-10-06.at.12.18.00.PM.mov
MacOS: Desktop
Screen.Recording.2023-10-06.at.12.20.59.PM.mov

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~013503150cd677c799
  • Upwork Job ID: 1711409892031705088
  • Last Price Increase: 2023-10-09
  • Automatic offers:
    • graylewis | Contributor | 27142852
    • gadhiyamanan | Reporter | 27142856
@m-natarajan m-natarajan added the External Added to denote the issue can be worked on by a contributor label Oct 9, 2023
@melvin-bot melvin-bot bot changed the title user have to press two times on Use current location [$500] user have to press two times on Use current location Oct 9, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 9, 2023

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

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Oct 9, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 9, 2023

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

@melvin-bot melvin-bot bot added the Daily KSv2 label Oct 9, 2023
@akinwale
Copy link
Contributor

akinwale commented Oct 9, 2023

Proposal

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

The user has to press the Use current location button twice before the button actually registers a click if the address search suggestions are visible.

What is the root cause of that problem?

The dismissal (upon clicking outside) of the address search suggestions displayed causes the button to change position which prevents the button itself from being able to capture the click or tap event at the current mouse or touch point. Essentially, the button is no longer at the position where the user initially clicked or tapped, so nothing registers.

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

In WaypointEditor, use a fixed position for the button so that it doesn't move while the user is attempting to click it.

Solution 1
Add a FixedFooter and place the "Use current location" button there. This will require modifying the Form by adding the isSubmitButtonVisible={false} prop and then adding a custom Save button in the FixedFooter which submits the form, because we want to display the "Use current location" button above the Save button.

In this scenario, I would also recommend moving the RBR error to display above "Use current location". We can add a prop to conditionally render the RBR above or below as required.

29100-demo-1.mp4

Solution 2
Place the "Use current location" button above the address search input.

29100-demo-2.mp4

What alternative solutions did you explore? (Optional)

None.

@graylewis
Copy link
Contributor

graylewis commented Oct 9, 2023

Proposal

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

The location button is not clickable because it moves when the autocomplete receives the onBlur event.

What is the root cause of that problem?

Because onBlur is processed before onClick (causing the button to move), the UserCurrentLocationButton never receives the onClick event.

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

Since onMouseDown is processed before onBlur, we can use onMouseDown (desktop) and onTouchStart (mobile) on the PressableWithFeedback component to intercept the action and prevent the onBlur event from propagating.

onMouseDown={(e) => {e.preventDefault()}}
onTouchStart={(e) => {e.preventDefault()}}

This allows the UserCurrentLocationButton to be triggered without any layout changes and without interfering with the operation of the autocomplete field.

What alternative solutions did you explore?

N/A

@m-natarajan m-natarajan added the Bug Something is broken. Auto assigns a BugZero manager. label Oct 10, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 10, 2023

Triggered auto assignment to @CortneyOfstad (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@melvin-bot
Copy link

melvin-bot bot commented Oct 10, 2023

Bug0 Triage Checklist (Main S/O)

  • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

@burczu
Copy link
Contributor

burczu commented Oct 11, 2023

The proposal from @graylewis does the trick and I think we can proceed with it.

Solutions proposed by @akinwale involve relocation of the Use current location button which, I think, is something we would like to avoid.

🎀 👀 🎀 C+ reviewed

@melvin-bot
Copy link

melvin-bot bot commented Oct 11, 2023

Triggered auto assignment to @johnmlee101, 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 Oct 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 11, 2023

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

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@melvin-bot
Copy link

melvin-bot bot commented Oct 11, 2023

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

Offer link
Upwork job

@graylewis
Copy link
Contributor

I'm expecting to submit a PR in the next few hours for this issue.

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Oct 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 13, 2023

🎯 ⚡️ Woah @burczu / @graylewis, great job pushing this forwards! ⚡️

The pull request got merged within 3 working days of assignment, so this job is eligible for a 50% #urgency bonus 🎉

  • when @graylewis got assigned: 2023-10-11 15:13:04 Z
  • when the PR got merged: 2023-10-13 14:23:30 UTC

On to the next one 🚀

@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 16, 2023
@melvin-bot melvin-bot bot changed the title [$500] user have to press two times on Use current location [HOLD for payment 2023-10-23] [$500] user have to press two times on Use current location Oct 16, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 16, 2023

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

After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.

  • External issue reporter
  • Contributor that fixed the issue
  • Contributor+ that helped on the issue and/or PR

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

As a reminder, here are the bonuses/penalties that should be applied for any External issue:

  • Merged PR within 3 business days of assignment - 50% bonus
  • Merged PR more than 9 business days after assignment - 50% penalty

@melvin-bot
Copy link

melvin-bot bot commented Oct 16, 2023

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:

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

@CortneyOfstad CortneyOfstad removed their assignment Oct 18, 2023
@CortneyOfstad
Copy link
Contributor

Heading OoO until Oct. 25 so reassigning this so it can be paid on time 👍

@CortneyOfstad CortneyOfstad added Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Oct 18, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 18, 2023

Triggered auto assignment to @abekkala (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Oct 18, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 18, 2023

Bug0 Triage Checklist (Main S/O)

  • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

@abekkala
Copy link
Contributor

abekkala commented Oct 19, 2023

PAYMENTS TO BE MADE OCT 23

@abekkala abekkala changed the title [HOLD for payment 2023-10-23] [HOLD for payment 2023-10-23] [$500] user have to press two times on Use current location [HOLD for payment 2023-10-23] [$500] user have to press two times on Use current location Oct 19, 2023
@melvin-bot melvin-bot bot added Overdue Daily KSv2 and removed Daily KSv2 Overdue labels Oct 23, 2023
@abekkala
Copy link
Contributor

@burczu can you complete the checklist above?

@abekkala
Copy link
Contributor

@gadhiyamanan payment made and contract ended - thank you! 🎉

@graylewis payment made and contract ended - thank you! 🎉

@melvin-bot melvin-bot bot added the Overdue label Oct 26, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 27, 2023

@johnmlee101, @burczu, @graylewis, @abekkala Whoops! This issue is 2 days overdue. Let's get this updated quick!

@abekkala
Copy link
Contributor

@burczu can you complete the checklist above?

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Oct 27, 2023
@abekkala
Copy link
Contributor

@burczu can you complete the checklist above?

@melvin-bot melvin-bot bot removed the Overdue label Oct 30, 2023
@burczu
Copy link
Contributor

burczu commented Oct 31, 2023

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:

  • [@burczu] The PR that introduced the bug has been identified. Link to the PR: I don't think that any other PR introduced this issue. It was done this way since the beginning.
  • [@burczu] 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: n/a
  • [@burczu] 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: n/a
  • [@burczu] Determine if we should create a regression test for this bug. I don't think we need regression tests here - the bug wasn't impactful and didn't block any flow in the App. It was just inconvenient behaviour for the user so it was just UX fix.
  • [@burczu] 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.
  • [@CortneyOfstad] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

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
None yet
Development

No branches or pull requests

7 participants