Skip to content

[Due for payment 2026-02-26] Reports - Deleted expense is still visible on chart on "Bar" view mode. #81110

Closed

Description

@jponikarchuk

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.3.11.17
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: #80833
Email or phone of affected tester (no customers): ibellicotest+2250@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Motorola MotoG60 / Android 12 (Hybrid app)
App Component: Search

Action Performed:

Prerequisite: Account has at least one workspace.

  1. Open the Expensify app.
  2. Open any workspace chat.
  3. Create two manual expenses with date from different weeks.
  4. Navigate to "Reports" > "Expenses"
  5. Tap on "Filters" > "Group by" > "Week"
  6. Apply filters.
  7. Tap on "View" > "Bar"
  8. Tap on any of the expenses on chart.
  9. Long tap on expense preview and select it.
  10. Tap on dropdown menu and delete the expense.
  11. Use device´s back button.
  12. Note that you land on chart again, and deleted expense is still displayed.
  13. Tap on deleted expense.
  14. Note that you land on an empty state screen.

Expected Result:

Deleted expense should automatically disappear from chart on "Bar" view.

Actual Result:

Deleted expense is still displayed on chart after returning to "Bar" view.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

1.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @NicMendonca

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Jan 31, 2026
  2. melvin-bot commented on Jan 31, 2026

    @melvin-bot

    @lakchote recently merged #80833, but they are OOO right now, so I'll auto-assign someone else.

  3. melvin-bot commented on Jan 31, 2026

    @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.

  4. melvin-bot commented on Jan 31, 2026

    @melvin-bot

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

  5. melvin-bot commented on Jan 31, 2026

    @melvin-bot

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

  6. github-actions commented on Jan 31, 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.
  7. OSBotify commented on Jan 31, 2026

    @OSBotify
    Contributor

    🔍 Investigation Summary

    Classification: Frontend bug
    Causing PR: #80833 - "Add support for groupBy week in Search - v2" by @cristipaval (High confidence)
    Related Issues: None

    Recommendation: REVERT

    The PR #80833 introduced the "Group by Week" feature for search, but there is an existing bug in the codebase that affects all grouped search views (including the new week grouping). When a transaction is deleted from a chart view, the search snapshot is not properly updated unless the entire report is being deleted.

    Labels: Keeping DeployBlockerCash as this is a frontend bug that requires an App PR to be reverted or fixed. No label changes made.

    📋 Detailed Analysis

    Evidence

    PR #80833 was merged on January 29, 2026, and added support for grouping expenses by week in the search feature. The issue report specifically mentions this PR in the regression test link and states the bug is reproducible in staging but N/A for production (confirming it is a new feature).

    The steps to reproduce clearly show:

    1. Create expenses grouped by week
    2. View them in bar chart mode
    3. Delete an expense
    4. The deleted expense still appears in the chart

    Verification

    The PR modified the following key files related to search and grouping:

    • src/components/Search/index.tsx - Added week group handling
    • src/components/Search/SearchChartView.tsx - Added week grouping configuration for charts
    • src/components/Search/SearchList/index.tsx - Added week matching logic
    • src/components/SelectionListWithSections/Search/WeekListItemHeader.tsx - New component for week headers

    Root Cause

    The root cause is in /home/runner/work/App/App/src/libs/actions/IOU/index.ts at line 8621-8636. The deleteMoneyRequest function only updates the search snapshot when shouldDeleteIOUReport is true:

    if (hash && shouldDeleteIOUReport) {
        optimisticData.push({
            onyxMethod: Onyx.METHOD.MERGE,
            key: `${ONYXKEYS.COLLECTION.SNAPSHOT}${hash}`,
            value: {
                data: {
                    [`${ONYXKEYS.COLLECTION.REPORT}${iouReport?.reportID}`]: {
                        pendingFields: {
                            preview: CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE,
                        },
                    },
                },
            },
        });
    }

    When deleting a single transaction (not the whole report), shouldDeleteIOUReport is false, so the snapshot does not get updated. This means the chart view continues to display the deleted expense because it is still reading from the stale snapshot data.

    Note: This is actually a pre-existing bug that affects all grouped search views, not just the new week grouping. However, PR #80833 exposed this bug by introducing a new grouping type that users can encounter.

  8. 29 remaining items

  9. melvin-bot commented on Feb 18, 2026

    @melvin-bot

    Current assignee @ShridharGoel is eligible for the External assigner, not assigning anyone new.

  10. melvin-bot commented on Feb 18, 2026

    @melvin-bot

    Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.

  11. removed
    Help WantedApply this label when an issue is open to proposals by contributors
    on Feb 18, 2026
  12. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Feb 19, 2026
  13. changed the title [-]Reports - Deleted expense is still visible on chart on "Bar" view mode.[/-] [+][Due for payment 2026-02-26] Reports - Deleted expense is still visible on chart on "Bar" view mode.[/+] on Feb 19, 2026
  14. melvin-bot commented on Feb 19, 2026

    @melvin-bot

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

  15. melvin-bot commented on Feb 19, 2026

    @melvin-bot

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

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

  16. melvin-bot commented on Feb 19, 2026

    @melvin-bot

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

  17. trjExpensify commented on Feb 25, 2026

    @trjExpensify
    Contributor

    PR on prod, closing!

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.EngineeringExternalAdded to denote the issue can be worked on by a contributorWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions