Skip to content

[Due for payment 2026-10-26] Merge-no system message shown after admin merging submitter's card & cash expense #104261

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.5.13-0
Reproducible in staging?: Yes
Reproducible in production?: N/A - new feature, doesn't exist in prod
If this was caught during regression testing, add the test name, ID and link from BrowserStack: #102438
Email or phone of affected tester (no customers): N/A
Issue reported by: Applause Internal Team
Bug source: Pull Request QA execution
Device used: Windows 11 / Chrome, iPhone 13 / iOS 27 Beta, Samsung Galaxy A52 / Android 14
App Component: Money Requests

Action Performed:

Preconditions:

  • Prepare 2 accounts (submitter & owner)
  • As submitter, import card transaction
  • As Owner, create a new WS and invite submitter to it

Steps:

  1. [Submitter] Create 2 reports in the WS chat named as Report A & Report B
  2. [Submitter] Add 2 manual expenses on Report B
  3. [Submitter] go to self DM, open any imported card expenses -> More -> Move to Report -> Select Report A
  4. [Owner] Navigate to submitter's WS chat
  5. [Owner] Open the submitter's card expense in Report A -> More -> Merge -> Select any expense from Report B -> Select 2nd option on all details -> Continue -> Merge
  6. [Submitter] Open Report B

Expected Result:

a system message from the admin shown and reads "merged expenses and moved one to Deleted"

Actual Result:

no system message shown after admin merging submitter's card & cash expense. it's also repro with a cash expense that is the only expense on its report (step 6 in PR)

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

To be added by Applause Leads

Bug7288135_1792157491915.bandicam_2026-10-16_20-07-26-093.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Chandana Kiran
Bug ID: 7288135

Issue OwnerCurrent Issue Owner: @daledah

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Oct 16, 2026
  2. applause-bot commented on Oct 16, 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/584897ae4f8e7eeba5f90ef6c8ada07373b86ac6aaa2f9c19ec8af494553802c

  3. melvin-bot commented on Oct 16, 2026

    @melvin-bot

    You have been assigned to this deploy blocker because you recently merged this PR: #102438

  4. melvin-bot commented on Oct 16, 2026

    @melvin-bot

    @stitesExpensify @daledah you have been assigned to this deploy blocker because you reviewed the offending PR: #102438

  5. melvin-bot commented on Oct 16, 2026

    @melvin-bot

    @youssef-lr you have been assigned to this deploy blocker because you authored the offending PR: #102438

  6. melvin-bot commented on Oct 16, 2026

    @melvin-bot

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

  7. github-actions commented on Oct 16, 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.
  8. youssef-lr commented on Oct 16, 2026

    @youssef-lr
    Contributor

    Looking.

  9. MelvinBot commented on Oct 16, 2026

    @MelvinBot
    Contributor

    Deploy Blocker Investigation

    Causing PR: [Payment due @daledah] Allow admins to merge card + cash expenses across draft reports. This is a gap in the new feature, not a regression. Production is unaffected.

    Root cause (medium confidence): App never creates the MERGEDEXPENSEDELETED system message. It only displays it when the server sends it. So either:

    • (a) the server doesn't write the action for this flow, or writes it to the wrong report, or
    • (b) the server sends it with an empty message, and App hides it as "deleted". isDeletedAction only exempts a fixed list of action types, and MERGED_EXPENSE_DELETED isn't on it.

    How to tell which: after the merge, check Report B's report actions in Onyx (or the MergeTransaction response). If no MERGEDEXPENSEDELETED action is there, it's (a) and needs a backend fix. If it's there with an empty message, it's (b), and the fix is one line in App: add the type to that exemption list.

    Recommendation: Don't revert, because the merge itself works. Fix forward. If it's (a), consider demoting the blocker while the backend is fixed, unless product requires the audit-trail message at launch.

    Investigation details

    App checked at 9b90f4ab.

    App only defines and renders the action:

    App doesn't create it optimistically:

    • mergeTransactionRequest deletes the source transaction and report, moves the surviving IOU action, and calls API.write(MERGE_TRANSACTION). It doesn't build a system message for either report.
    • So offline, the message never shows until the request syncs. Online, it depends on the server response.

    An empty-message action gets filtered out:

    • hasDeletedMessage treats an empty message array or empty html as deleted.
    • isDeletedAction then hides it unless its type is in the exemption list.

    I couldn't inspect the server response or backend code, so I can't confirm whether it's (a) or (b).


    view run

  10. youssef-lr commented on Oct 16, 2026

    @youssef-lr
    Contributor

    It's (b). Raising PR now.

  11. added and removed
    ReviewingHas a PR in review
    on Oct 19, 2026
  12. changed the title [-]Merge-no system message shown after admin merging submitter's card & cash expense[/-] [+][Due for payment 2026-10-26] Merge-no system message shown after admin merging submitter's card & cash expense[/+] on Oct 19, 2026
  13. melvin-bot commented on Oct 19, 2026

    @melvin-bot

    @daledah

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.13-6 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-10-26. 🎊

    The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ 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

BugSomething is broken. Auto assigns a BugZero manager.DailyKSv2Engineering

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions