Repository navigation
Description
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.65-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: N/A
Email or phone of affected tester (no customers): ibellicotest+1029@gmail.com
Issue reported by: Applause Internal Team
Device used: Motorola MotoG60 - Android 12 - Chrome (mWeb - Hybrid App) / Windows 10 - Chrome
App Component: Money Requests
Action Performed:
Prerequisite: Account has at least one workspace created and Self DM.
Prerequisite: Delayed submissions and approvals enabled.
- Open the staging.new.expensify.com website.
- Open any workspace chat.
- Submit a manual expense to it.
- Navigate to Self DM.
- Submit another manual expense to it so that now you have 2 expenses on one report.
- Open the expense created in Self DM.
- Tap on the report field and select the report of the expense created in workspace chat.
- Navigate to workspace chat.
- Submit, approve and pay the expenses on the report.
- Open the report and tap on "More"
- Tap on "Cancel Payment"
- Unapprove the expense.
- Delete the report.
- Navigate to Self DM again.
- Note that both expenses are displayed as unreported on Self DM, and that a third preview, that can´t be opened, is also displayed, showing infinite loading.
Expected Result:
After cancelling payment, unapproving and deleting a report on a workspace chat, expenses on it should be moved to Self DM and no extra expense should be displayed with them.
Actual Result:
When the user cancels a payment, unapprove and deletes a report on a workspace chat, that contains an expense that was moved from Self DM, the expenses on the report, are moved to Self DM again, but now, an extra expense preview, that can´t be opened, appears showing infinite loading.
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
Bug6857548_1749684457124.Third.mp4
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~021933269725743755856
- Upwork Job ID: 1933269725743755856
- Last Price Increase: 2025-06-12
Issue Owner
Current Issue Owner: @clarajones-expensifyMetadata
Metadata
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
melvin-bot commentedon Jun 12, 2025
Triggered auto assignment to @clarajones-expensify (
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.bernhardoj commentedon Jun 12, 2025
Proposal
Please re-state the problem that we are trying to solve in this issue.
Extra expenses with infinite loading in self DM after deleting report where the report is previously paid.
What is the root cause of that problem?
When we delete a report, we optimistically move all money request action to self DM. However, money request action also includes pay action.
App/src/libs/actions/Report.ts
Lines 4748 to 4751 in 04a715b
This causes the extra expense.
What changes do you think we should make in order to solve the problem?
We can return early too if the action is a pay action.
OR
We can return early if the
originalMessage.typeis nottrackorcreate.(there is another issue I noticed where the LHN item of the expense thread shows Hidden)
What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?
We can test
deleteAppReportwhere the report has a pay action and assert that there is no extra expenses.clarajones-expensify commentedon Jun 12, 2025
Notes: I was able to reproduce
[-]Expense - Extra expense with infinite loading appears in Self DM after deleting report in WS[/-][+][$250] Expense - Extra expense with infinite loading appears in Self DM after deleting report in WS[/+]melvin-bot commentedon Jun 12, 2025
Job added to Upwork: https://www.upwork.com/jobs/~021933269725743755856
melvin-bot commentedon Jun 12, 2025
Triggered auto assignment to Contributor-plus team member for initial proposal review - @DylanDylann (
External)clarajones-expensify commentedon Jun 12, 2025
Hi @DylanDylann - would you review the above proposal? Thank you!
DylanDylann commentedon Jun 13, 2025
@bernhardoj's proposal looks fine to me. Besides checking actionName we also need to verify the
originalMessage.type🎀👀🎀 C+ reviewed
24 remaining items
melvin-bot commentedon Jul 4, 2025
Payment Summary
Upwork Job
BugZero Checklist (@clarajones-expensify)
clarajones-expensify commentedon Jul 7, 2025
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[Contributor] 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:
[Contributor] 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:
[Contributor] 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.
Regression Test Proposal Template
[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:
Test:
Do we agree 👍 or 👎
clarajones-expensify commentedon Jul 7, 2025
@DylanDylann would you fill out the above checklist? thanks!
DylanDylann commentedon Jul 7, 2025
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[Contributor] 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: [Simplified Actions] Implement DeleteAppReport #58020 (comment)
[Contributor] 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:
[Contributor] 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
Test:
Do we agree 👍 or 👎
clarajones-expensify commentedon Jul 7, 2025
Payment Summary
C: @bernhardoj owed $250 via NewDot manual payment
C+: @DylanDylann owed $250 via NewDot manual payment
bernhardoj commentedon Jul 7, 2025
Requested in ND.
clarajones-expensify commentedon Jul 7, 2025
FYI: not blocker worthy
clarajones-expensify commentedon Jul 7, 2025
Closed job in Upwork
JmillsExpensify commentedon Jul 9, 2025
$250 approved for @bernhardoj
trjExpensify commentedon Oct 3, 2025
approved $250 for @DylanDylann.