Skip to content

[Due for payment 2025-05-22] [Better Expense Report View] - Expense with multiple violations does not show Review Required when held #61473

Closed

Description

@nlemma

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.1.40-0
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from TestRail: #60819
Email or phone of affected tester (no customers): N/A
Issue reported by: Applause Internal Team
Device used: Windows 10 / Chrome, Samsung Galaxy A12 / Android 13
App Component: Chat Report View

Action Performed:

  1. Log in to staging.expensify.com
  2. Create an expense with multiple violations (Duplicate, amount over the limit, no receipt, no categories)
  3. Put the created expense on Hold
  4. Go to Expense Preview

Expected Result:

"Review Required" RBR is displayed on expense with multiple violations

Actual Result:

"Expense is put on hold" is displayed when an expense with multiple violations is put on hold

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug6823013_1746526656448.Recording__329.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @trjExpensify

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on May 6, 2025
  2. melvin-bot commented on May 6, 2025

    @melvin-bot

    Triggered auto assignment to @miljakljajic (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. nkdengineer commented on May 6, 2025

    @nkdengineer
    Contributor

    🚨 Edited by proposal-police: This proposal was edited at 2025-05-06 11:15:36 UTC.

    Proposal

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

    "Expense is put on hold" is displayed when an expense with multiple violations is put on hold

    What is the root cause of that problem?

    We are prioritizing showing 'iou.expenseWasPutOnHold' here

    if (shouldShowHoldMessage && RBRMessage === undefined) {
    RBRMessage = {translationPath: 'iou.expenseWasPutOnHold'};
    }

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

    We should move this code to the below here

    if (hasFieldErrors && RBRMessage === undefined) {
    const merchantMissing = isMerchantMissing(transaction);
    const amountMissing = isAmountMissing(transaction);
    if (amountMissing && merchantMissing) {
    RBRMessage = {translationPath: 'violations.reviewRequired'};
    } else if (amountMissing) {
    RBRMessage = {translationPath: 'iou.missingAmount'};
    } else if (merchantMissing) {
    RBRMessage = {translationPath: 'iou.missingMerchant'};
    }
    }

    Note: We should also consider the priority of iou.missingAmount and iou.missingMerchant to sort

    What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

    None

    What alternative solutions did you explore? (Optional)

    NA

    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.

  4. changed the title [-]Expense - Expense with multiple violations does not show Review Required when held[/-] [+][Better Expense Report View] - Expense with multiple violations does not show Review Required when held[/+] on May 6, 2025
  5. trjExpensify commented on May 6, 2025

    @trjExpensify
    Contributor

    Bug fix from this PR, @JakubKorytko is going to handle.

  6. moved this to Second Cohort - HIGH in [#whatsnext] #migrateon May 6, 2025
  7. 2 remaining items

  8. moved this from Second Cohort - HIGH to Second Cohort - MEDIUM or LOW in [#whatsnext] #migrateon May 9, 2025
  9. trjExpensify commented on May 13, 2025

    @trjExpensify
    Contributor

    Awaiting a deploy.

  10. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on May 15, 2025
  11. changed the title [-][Better Expense Report View] - Expense with multiple violations does not show Review Required when held[/-] [+][Due for payment 2025-05-22] [Better Expense Report View] - Expense with multiple violations does not show Review Required when held[/+] on May 15, 2025
  12. melvin-bot commented on May 15, 2025

    @melvin-bot

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

  13. melvin-bot commented on May 15, 2025

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.45-21 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-05-22. 🎊

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

  14. melvin-bot commented on May 15, 2025

    @melvin-bot

    @DylanDylann @trjExpensify @DylanDylann 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]

  15. trjExpensify commented on May 15, 2025

    @trjExpensify
    Contributor

    I think we can close this now then. 👍

  16. moved this from Second Cohort - MEDIUM or LOW to Done in [#whatsnext] #migrateon May 15, 2025
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.WeeklyKSv2

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions