Skip to content

[Due for payment 2025-12-17] [$250] Expense - Distance field shows Pending on confirm page #76845

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.2.73-0
Reproducible in staging?: Y
Reproducible in production?: N
If this was caught during regression testing, add the test name, ID and link from TestRail: #76384
Email or phone of affected tester (no customers): soidjnsodnjsoidjiosnj@gmail.com
Issue reported by: Applause - Internal Team

Action Performed:

  1. Go to staging.new.expensify.com
  2. Open FAB > Track distance > Manual
  3. Enter amount > Next

Expected Result:

Distance field will show the correct value on confirm page

Actual Result:

Distance field shows Pending on confirm page

Workaround:

Unknown

Platforms:

Select the officially supported platforms where the issue was reproduced:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop
Platforms Tested: On which of our officially supported platforms was this issue tested:
  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence
Bug7021902_1764960511329.5.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021997942232073215377
  • Upwork Job ID: 1997942232073215377
  • Last Price Increase: 2025-12-08
Issue OwnerCurrent Issue Owner: @dylanexpensify

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Dec 5, 2025
  2. melvin-bot commented on Dec 5, 2025

    @melvin-bot

    Triggered auto assignment to @dylanexpensify (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. melvin-bot commented on Dec 5, 2025

    @melvin-bot

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

  4. melvin-bot commented on Dec 5, 2025

    @melvin-bot

    💬 A slack conversation has been started in #expensify-open-source

  5. github-actions commented on Dec 5, 2025

    @github-actions
    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.
  6. Nodebrute commented on Dec 5, 2025

    @Nodebrute
    Contributor

    Proposal

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

    Distance field shows Pending on confirm page

    What is the root cause of that problem?

    This change happened after in this pr #75542 we allowed zero amount expenses. In this pr we have added transaction?.comment?.customUnit?.name which is undefined

    return !!transaction?.routes?.route0?.geometry?.coordinates || (!!isDistanceRequestType && transaction?.comment?.customUnit?.name === CONST.CUSTOM_UNITS.NAME_DISTANCE);

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

    Solution one

    We can check transaction?.comment?.customUnit?.quantity != null) this will work for 0 values too.

        return !!transaction?.routes?.route0?.geometry?.coordinates || (!!isDistanceRequestType &&        (!!isDistanceRequestType && transaction?.comment?.customUnit?.quantity != null));
    

    Solution 2

    We can check for customUnitRateID

        return !!transaction?.routes?.route0?.geometry?.coordinates || (!!isDistanceRequestType &&        (!!isDistanceRequestType && !!transaction?.comment?.customUnit?.customUnitRateID));
    

    What alternative solutions did you explore? (Optional)

    We can add name as 'Distance' optimistically

  7. dylanexpensify commented on Dec 8, 2025

    @dylanexpensify
    Contributor

    Hmm, @cristipaval I can't repro

  8. dylanexpensify commented on Dec 8, 2025

    @dylanexpensify
  9. 10 remaining items

  10. PiyushChandra17 commented on Dec 8, 2025

    @PiyushChandra17
    Contributor

    Proposal

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

    Distance field is showing pending in Confirm Page

    What is the root cause of that problem?

    We are checking for two conditions here in order to show Distance field,

    • hasRoute > it's giving "false"
    • unit > "mi"

    if any of these conditions are not satified, hence has falsy value then it's showing iou.fieldPending here

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

    We need check both conditions hasRoute && unit,

    if (!hasRoute && !unit) {
        return translate('iou.fieldPending');
    }

    What alternative solutions did you explore? (Optional)

    n/A

    Result

    Image

    Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.

  11. Gonals commented on Dec 8, 2025

    @Gonals
    Contributor

    FIxed and deployed. Closing

  12. removed
    DeployBlockerCashThis issue or pull request should block deployment
    on Dec 8, 2025
  13. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Dec 10, 2025
  14. changed the title [-][$250] Expense - Distance field shows Pending on confirm page[/-] [+][Due for payment 2025-12-17] [$250] Expense - Distance field shows Pending on confirm page[/+] on Dec 10, 2025
  15. melvin-bot commented on Dec 10, 2025

    @melvin-bot

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

  16. melvin-bot commented on Dec 10, 2025

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.2.74-12 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 2025-12-17. 🎊

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

    • @Ollyws requires payment through NewDot Manual Requests
  17. melvin-bot commented on Dec 10, 2025

    @melvin-bot

    @Ollyws @dylanexpensify The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

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.EngineeringExternalAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributorsWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions