Skip to content

[Due for payment 2026-08-27] IOU - Error message after delete the split Time expense in IOU #98245

Closed

Description

@applause-bot

If you haven’t already, check out our contributing guidelines for onboarding. To join our Slack channel, fill out this form.


Version Number: v9.4.52-0
Reproducible in staging?: Yes
Reproducible in production?: No
If this was caught during regression testing, add the test name, ID and link from BrowserStack: https://test-management.browserstack.com/projects/2219752/test-runs/68502605/folder/52646791/47002824/1646242756?sort=%2Bidentifier
Email or phone of affected tester (no customers): leungbratwerwwr3t353t6@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Windows 10/Chrome
App Component: Chat Report View

Action Performed:

Preconditions: Workspace has toggled on Time feature and has a selfDM

  1. Open the NewDot app
  2. Navigate to the Workspace chat
  3. Create a Time expense -> More -> Split -> Save
  4. Click on More -> Delete
  5. Navigate to a 1:1 DM chat
  6. Create a manual expense IOU
  7. Click on the IOU report -> Add expense -> Add existing expense
  8. Select the split Time expense in step 4 in selfDM -> Add to report
  9. Select both the expenses -> Delete

Expected Result:

The user can delete the IOU expense

Actual Result:

An error appears on split Time expense: Unexpected error deleting this expense. Please try again later.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7230696_1786420319474.time.1.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Julia Ponikarchuk
Bug ID: 7230696

Issue OwnerCurrent Issue Owner: @ZhenjaHorbach

Activity

  1. added
    DeployBlockerCash
    Bug
    on Aug 11, 2026
  2. applause-bot commented on Aug 11, 2026

    @applause-bot
    Author

    While Applause doesn't embed attachments for this bug, here are the links for quick view:
    https://platform.applause.com/services/links/v1/external/1abaaaa9db5a48e040ec87b10b20fc9ac525b097ca7ba5d8612fb63b20fb7ca4

  3. melvin-bot commented on Aug 11, 2026

    @melvin-bot

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

  4. melvin-bot commented on Aug 11, 2026

    @melvin-bot

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

  5. github-actions commented on Aug 11, 2026

    @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. MelvinBot commented on Aug 11, 2026

    @MelvinBot
    Contributor

    🔍 Investigation Summary

    Classification: Backend bug (server rejects the delete) — but see label note below
    Causing PR: None identified in the v9.4.52 staging release (Low confidence — no App PR in this release touched the delete/move/split code paths)
    Related Issues: N/A

    Recommendation: NEEDS INVESTIGATION

    The visible error is a server-side rejection of DeleteMoneyRequest, and no PR in this release modified the App-side delete / "add existing expense" (move-to-report) / split code paths — so I could not pin an App PR as the cause. Because the issue is not reproducible on production, the DeployBlockerCash label is being kept (see below), and an owner needs to confirm whether the fix is App-side or backend before any label is removed.

    Assigned: no causing PR identified — leaving the existing assignee (@rlinoz) to drive investigation
    Labels: No changes. DeployBlockerCash is intentionally kept (issue is not reproducible in production, and confidence is too low to remove any blocker label).

    📋 Detailed Analysis

    Evidence

    • The user-facing error is iou.error.genericDeleteFailureMessage ("Unexpected error deleting this expense. Please try again later."). In the App this string is only written into failureData for the delete flow — i.e. it is shown when the DeleteMoneyRequest API command comes back with a non-success jsonCode. It is a server rejection, not a client-side validation failure.
    • The delete request the App sends is minimal — only transactionID and reportActionID (deleteMoneyRequest → API.write(WRITE_COMMANDS.DELETE_MONEY_REQUEST, {transactionID, reportActionID})). There is no client-side gate that produces this message.
    • I reviewed the merged-PR set for the v9.4.52 staging checklist (Deploy Checklist: New Expensify 2026-08-10 #98179). Filtering the production→staging commit range for delete, split, move, add existing, unreported, selfDM, and changeTransactions surfaced no PR that modifies the delete / move-to-report / split flows used in this repro. The delete action file was last changed by PRs that are not in this release.
    • Reproducible on staging only, not production. That normally points to a release PR, but the relevant code paths were not touched this release, which instead points to a backend change or a pre-existing backend edge case being newly exercised.

    Verification

    • Affected delete code path: src/libs/actions/IOU/DeleteMoneyRequest.ts — deleteMoneyRequest(), where the failure error is attached and the DELETE_MONEY_REQUEST command is issued.
      const parameters: DeleteMoneyRequestParams = {
      transactionID,
      reportActionID: reportAction.reportActionID,
      };
      // STEP 3: Make the API request
      API.write(WRITE_COMMANDS.DELETE_MONEY_REQUEST, parameters, {optimisticData, successData, failureData});
    • Error string source: src/languages/en.ts → iou.error.genericDeleteFailureMessage.
      genericDeleteFailureMessage: 'Unexpected error deleting this expense. Please try again later.',
    • The "Add existing expense → Add to report" step is handled by changeTransactionsReport in src/libs/actions/Transaction.ts, which builds the optimistic moved-in IOU report action (newIOUAction, spread from the source oldIOUAction) for the split Time expense.
      const newIOUAction = {
      ...oldIOUAction,
      reportID,
      originalMessage: {
      ...originalMessage,
      IOUTransactionID: originalMessage?.IOUTransactionID ?? transaction.transactionID,
      type: actionType,
      },
      reportActionID: optimisticMoneyRequestReportActionID,
      pendingAction: CONST.RED_BRICK_ROAD_PENDING_ACTION.ADD,
      actionName: oldIOUAction?.actionName ?? CONST.REPORT.ACTIONS.TYPE.IOU,
      created: oldIOUAction?.created ?? DateUtils.getDBTime(),
      ...(!oldIOUAction && {
      actorAccountID: accountID,
      message: getIOUReportActionMessage(reportID, actionType, Math.abs(transaction.amount), transaction.comment?.comment ?? '', transaction.currency, getCurrencyDecimals),
      }),
      };

      Git history for this file in the release window shows only the "move all matching" work (PR Allow moving all matching expenses to a report from Search #96482, which is not on this checklist) and the unrelated currency-display refactor — nothing that changes the delete params.

    Root Cause

    Most consistent hypothesis: the backend DeleteMoneyRequest command cannot cleanly delete a split Time expense that was created in selfDM and then moved into an IOU report (the reported step-9 bulk delete). The App optimistically deletes it and then rolls back with the generic failure message when the server responds with an error. Because the App only sends transactionID + reportActionID and no release PR altered how those are produced for this flow, the fix most likely needs to happen in the backend delete handler for moved/split transactions. This should be confirmed by checking the server logs / jsonCode returned by DeleteMoneyRequest for the failing transaction before deciding revert vs. roll-forward.

  7. thelullabyy commented on Aug 11, 2026

    @thelullabyy
    Contributor

    Checking...

  8. rlinoz commented on Aug 11, 2026

    @rlinoz
    Contributor

    I think this is not new behavior and is different in prod and staging because of this PR #91932 cc: @ZhenjaHorbach

  9. ZhenjaHorbach commented on Aug 11, 2026

    @ZhenjaHorbach
    Contributor

    I think this is not new behavior and is different in prod and staging because of this PR #91932 cc: @ZhenjaHorbach

    Looks like we just need to improve the filter on Add existing expense screen
    Since we can't move splits to 1:1 DM chat
    CC: @garrettmknight

  10. rlinoz commented on Aug 11, 2026

    @rlinoz
    Contributor

    Yeah, I think that makes sense and this is issue should not be a blocker.

  11. 1 remaining item

  12. added
    Daily
    and removed
    Hourly
    on Aug 11, 2026
  13. ZhenjaHorbach commented on Aug 12, 2026

    @ZhenjaHorbach
    Contributor

    Okay
    Added a fix here

  14. melvin-bot commented on Aug 17, 2026

    @melvin-bot

    @ZhenjaHorbach Eep! 4 days overdue now. Issues have feelings too...

  15. added
    Reviewing
    on Aug 18, 2026
  16. melvin-bot commented on Aug 19, 2026

    @melvin-bot

    ⚠️ Looks like this issue was linked to a Deploy Blocker here

    If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

    If a regression has occurred and you are the assigned CM follow the instructions here.

    If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

  17. melvin-bot commented on Aug 19, 2026

    @melvin-bot

    ⚠️ Looks like this issue was linked to a Deploy Blocker here

    If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results.

    If a regression has occurred and you are the assigned CM follow the instructions here.

    If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future.

  18. removed
    Reviewing
    on Aug 20, 2026
  19. changed the title [-]IOU - Error message after delete the split Time expense in IOU[/-] [+][Due for payment 2026-08-27] IOU - Error message after delete the split Time expense in IOU[/+] on Aug 20, 2026
  20. melvin-bot commented on Aug 20, 2026

    @melvin-bot

    @ZhenjaHorbach

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.4.56-3 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 2026-08-27. 🎊

    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]. If no checklist is needed for this issue, you can click: [no checklist button]

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

Metadata

Metadata

Labels

BugDailyEngineering

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions