Skip to content

[HOLD for payment 2024-02-15] [$500] Distance-By adding 2nd add stop user can delete empty location #35644

Closed

Description

@izarutskaya

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.4.35
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: Applause-Internal Team
Slack conversation:

Action Performed:

  1. Go to https://staging.new.expensify.com/
  2. Tap on a workspace chat
  3. Tap plus icon --- request money
  4. Tap distance
  5. Enter start and end distance waypoints
  6. Tap add stop
  7. Note 3 dots on top right is not displayed to delete waypoint
  8. Select a location
  9. Navigate back and select add stop again
  10. Now note, 3 dots on top right is displayed to delete waypoint before location is selected
  11. Tap delete waypoint and note user can delete empty location.

Expected Result:

When adding first add stop, after adding location only 3 dots on top to delete waypoint displayed. Same behaviour must be displayed while user adding another stop point and before adding location 3dots to delete waypoint must not be shown and user must not be able to delete empty location.

Actual Result:

When adding first add stop, after adding location only 3 dots on top to delete waypoint displayed but when user add another stop point before adding location 3dots to delete waypoint shown and user can delete empty location.

Workaround:

unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

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

Screenshots/Videos

Bug6364419_1706848809407.stop.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0196d67f3a0a23173a
  • Upwork Job ID: 1753354514723856384
  • Last Price Increase: 2024-02-02
  • Automatic offers:
    • fedirjh | Reviewer | 28142825
    • ZhenjaHorbach | Contributor | 28142827

Activity

  1. added
    ExternalAdded to denote the issue can be worked on by a contributor
    BugSomething is broken. Auto assigns a BugZero manager.
    on Feb 2, 2024
  2. changed the title [-]Distance-By adding 2nd add stop user can delete empty location[/-] [+][$500] Distance-By adding 2nd add stop user can delete empty location[/+] on Feb 2, 2024
  3. melvin-bot commented on Feb 2, 2024

    @melvin-bot
  4. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Feb 2, 2024
  5. melvin-bot commented on Feb 2, 2024

    @melvin-bot

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

  6. melvin-bot commented on Feb 2, 2024

    @melvin-bot

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

  7. ZhenjaHorbach commented on Feb 2, 2024

    @ZhenjaHorbach
    Contributor

    Proposal

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

    Distance-By adding 2nd add stop user can delete empty location

    What is the root cause of that problem?

    The main problem with issue is that we check only waypoint count and regardless of the fullness of the input
    We will show threeDots button

    const shouldShowThreeDotsButton = waypointCount > 2;

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

    To fix this issue we can update this const and add waypointAddress
    And if we have an address in currentWaypoint from transaction
    Only then do we show the button

    const shouldShowThreeDotsButton = waypointCount > 2 && waypointAddress;

    What alternative solutions did you explore? (Optional)

    NA

  8. pc6n commented on Feb 2, 2024

    @pc6n

    Proposal

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

    When a second stop is added the user see the three dots button and can delete it .
    (while its still empty)

    What is the root cause of that problem?

    We only check for the number of waypoints and show the button when there are more than 2 waypoints.

    const shouldShowThreeDotsButton = waypointCount > 2;

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

    I would check if there are more than two waypoints and if a current waypoint is already available e.g. the user wants to edit a waypoint. I think it doesnt makes sense to delete a waypoint which isnt saved.

    const isCurrentWaypointAvailable = !_.isEmpty(currentWaypoint);
    const shouldShowThreeDotsButton = waypointCount > 2 && isCurrentWaypointAvailable;
    

    Additionally we could also test if it is a stop waypoint. I think it doesnt makes sense to be able to delete start and finish endpoints. Editing should be enough for them.

    distance.waypointDescription.stop

    What alternative solutions did you explore? (Optional)

    NA

  9. fedirjh commented on Feb 2, 2024

    @fedirjh
    Contributor

    @ZhenjaHorbach Proposal looks good to me.

    🎀 👀 🎀 C+ reviewed

  10. melvin-bot commented on Feb 2, 2024

    @melvin-bot

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

  11. 17 remaining items

  12. changed the title [-][$500] Distance-By adding 2nd add stop user can delete empty location[/-] [+][HOLD for payment 2024-02-15] [$500] Distance-By adding 2nd add stop user can delete empty location[/+] on Feb 8, 2024
  13. melvin-bot commented on Feb 8, 2024

    @melvin-bot

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

  14. melvin-bot commented on Feb 8, 2024

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.38-6 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-02-15. 🎊

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

  15. melvin-bot commented on Feb 8, 2024

    @melvin-bot

    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:

    • [@fedirjh] The PR that introduced the bug has been identified. Link to the PR:
    • [@fedirjh] 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:
    • [@fedirjh] 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:
    • [@fedirjh] Determine if we should create a regression test for this bug.
    • [@fedirjh] 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.
    • [@kevinksullivan] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
  16. melvin-bot commented on Feb 20, 2024

    @melvin-bot

    @Beamanator, @kevinksullivan, @fedirjh, @ZhenjaHorbach Eep! 4 days overdue now. Issues have feelings too...

  17. ZhenjaHorbach commented on Feb 20, 2024

    @ZhenjaHorbach
    Contributor

    Oh )
    It's time to pay ))

  18. Beamanator commented on Feb 21, 2024

    @Beamanator
    Contributor

    True :D Bump @kevinksullivan for payout & @fedirjh for checklist 🙏

  19. fedirjh commented on Feb 21, 2024

    @fedirjh
    Contributor

    BugZero Checklist:

  20. kevinksullivan commented on Feb 22, 2024

    @kevinksullivan
    Contributor

    All set on payment

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

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions