Skip to content

[Due for payment 2025-06-16] [Due for payment 2025-06-13] [$250] Incorrect system message displayed for report change action #61334

Closed

Description

@m-natarajan

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.39-2
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: @puneetlath
Slack conversation (hyperlinked to channel name): #Retain

Action Performed:

  1. User A submits an expense report with a couple expenses on a workspace to User B
  2. User A submits a second expense report with a couple expenses on the same workspace to User B
  3. Admin C of the workspace moves one of the expenses from report1 to report2 in OldDot
  4. As User A observe the system message for the action

Expected Result:

The system should display a clear and accurate message indicating:
What was changed (e.g., “Report name updated”)
Who made the change (if applicable)
Any relevant context or field values (e.g., old vs. new value)

Actual Result:

Changed the expense message displayed

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

Image

Image

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021918353941303457218
  • Upwork Job ID: 1918353941303457218
  • Last Price Increase: 2025-05-02
  • Automatic offers:
    • FitseTLT | Contributor | 107288813
Issue OwnerCurrent Issue Owner: @
Issue OwnerCurrent Issue Owner: @
Issue OwnerCurrent Issue Owner: @NicMendonca

Activity

  1. added
    Bug
    Daily
    on May 2, 2025
  2. melvin-bot commented on May 2, 2025

    @melvin-bot

    Triggered auto assignment to @NicMendonca (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. FitseTLT commented on May 2, 2025

    @FitseTLT
    Contributor

    🚨 Edited by proposal-police: This proposal was edited at 2025-05-02 16:35:41 UTC.

    Proposal

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

    Incorrect system message displayed for report change action

    What is the root cause of that problem?

    We are not handling the case of MODIFIEDEXPENSE report action corresponding to moving expenses across reports so it is falling back to default changed expense copy here

    if (message === '') {
    return translateLocal('iou.changedTheExpense');
    }

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

    Option 1. We can display the reportAction message for this case so add the code here

     if (reportActionOriginalMessage?.movedFromReport) {
            return getReportActionMessageText(reportAction);
        }
    

    Option 2: add a new copy whose content will be consulted with design team but it can generally accept a param from the data available from originalMessage like "movedFromReport(it can be the report name of the movedFromReport or the report id if it is not available), and optionally if needed "merchant"(even "transactionID" if needed) and we will return the copy with the condition if (reportActionOriginalMessage?.movedFromReport) here
    optionally we can also use a copy similar to movedFromPersonalSpace which could display the movement of the expense by displaying the name of the movedFromReport (and also the report name of the report it has moved to which is the current report but I think this info is useless as it is obvious that the expense has moved to the current report which is the parent of the report action) with or without the actor display name but the exact copy should be consulted with the internal team.

    Or we can follow the same path as movedTransaction copy where we can pass the moved from report name and URL and display the linked name same as here

    App/src/libs/ReportUtils.ts

    Lines 5774 to 5781 in 1b61468

    const movedTransactionOriginalMessage = getOriginalMessage(action as ReportAction<typeof CONST.REPORT.ACTIONS.TYPE.MOVED_TRANSACTION>) ?? {};
    const {toReportID} = movedTransactionOriginalMessage as OriginalMessageMovedTransaction;
    const {reportName, reportUrl} = getReportDetails(toReportID);
    const message = translateLocal('iou.movedTransaction', {
    reportUrl,
    reportName,
    });
    return message;

    but for copy to clipboard and lhn we can display the report name without the link.

    We can also consider: Instead of falling back to general changeExpense copy here we can consider using option 1 of falling back to report action message which would avoid displaying general message.

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

    We will add tests to ModifiedExpenseMessageTest.ts corresponding to our changes we make by asserting the expected content.

    What alternative solutions did you explore? (Optional)

  4. added
    External
    on May 2, 2025
  5. changed the title [-]Incorrect system message displayed for report change action[/-] [+][$250] Incorrect system message displayed for report change action[/+] on May 2, 2025
  6. melvin-bot commented on May 2, 2025

    @melvin-bot
  7. added
    Help Wanted
    on May 2, 2025
  8. melvin-bot commented on May 2, 2025

    @melvin-bot

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

  9. FitseTLT commented on May 2, 2025

    @FitseTLT
    Contributor

    @NicMendonca @puneetlath I think the step should be updated we can only move expenses across open reports (not submitted) from different workspaces. Isn't it? That's the only thing that's working for me from OD

  10. DylanDylann commented on May 5, 2025

    @DylanDylann
    Contributor

    @puneetlath It seems you are using the old expense report view. Could you reproduce this bug on the new expense report view? I can't reproduce this bug on the new expense report view

    Screen.Recording.2025-05-05.at.14.19.02.mov
  11. 34 remaining items

  12. melvin-bot commented on Jun 6, 2025

    @melvin-bot

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

  13. melvin-bot commented on Jun 6, 2025

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.60-2-staging 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-06-13. 🎊

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

  14. melvin-bot commented on Jun 6, 2025

    @melvin-bot

    @akinwale @NicMendonca @akinwale 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. added
    Weekly
    and removed
    Weekly
    on Jun 9, 2025
  16. changed the title [-][Due for payment 2025-06-13] [$250] Incorrect system message displayed for report change action[/-] [+][Due for payment 2025-06-16] [Due for payment 2025-06-13] [$250] Incorrect system message displayed for report change action[/+] on Jun 9, 2025
  17. melvin-bot commented on Jun 9, 2025

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.62-0 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-06-16. 🎊

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

  18. melvin-bot commented on Jun 9, 2025

    @melvin-bot

    @akinwale @NicMendonca @akinwale 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]

  19. akinwale commented on Jun 12, 2025

    @akinwale
    Contributor

    BugZero Checklist:

    Bug classification

    Source of bug:

    • 1a. Result of the original design (eg. a case wasn't considered)
    • 1b. Mistake during implementation
    • 1c. Backend bug
    • 1z. Other:

    Where bug was reported:

    • 2a. Reported on production (eg. bug slipped through the normal regression and PR testing process on staging)
    • 2b. Reported on staging (eg. found during regression or PR testing)
    • 2d. Reported on a PR
    • 2z. Other:

    Who reported the bug:

    • 3a. Expensify user
    • 3b. Expensify employee
    • 3c. Contributor
    • 3d. QA
    • 3z. Other:
    • [@akinwale] 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

    • [@akinwale] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source 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

    • [@akinwale] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.

    • [BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.

      Link to issue:

    Regression Test Proposal

    Precondition:

    • User A is an employee member of workspace X and workspace Y respectively
    • User B is an admin of workspace X and workspace Y respectively

    Test:

    1. Launch Expensify.
    2. As User A, create an expense report (1) in workspace X with two expenses.
    3. As User A, create a second expense report (2) in workspace Y with two expenses.
    4. As admin User B on OldDot, move a single expense from expense report 1 to expense report 2.
    5. Verify that the system message in expense report 2 is in the format moved an expense from {REPORT_NAME}.

    Do we agree 👍 or 👎?

  20. added
    Daily
    and removed
    Weekly
    on Jun 13, 2025
  21. NicMendonca commented on Jun 13, 2025

    @NicMendonca
    Contributor

    Payment summary

    Contributor+: @akinwale - $250 via NewDot Manual Requests
    Contributor: @FitseTLT - $250 via Upwork (done ✅ )

  22. JmillsExpensify commented on Jun 16, 2025

    @JmillsExpensify
    Contributor

    $250 approved for @akinwale

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentBugDailyExternal

Type

No type

Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions