Skip to content

Android - Expense - Inconsistent behavior after deleting expense opened via growl. #102845

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: 9.5.1-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: #100015
Email or phone of affected tester (no customers): ibellicotest+3215@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: Money Requests

Action Performed:

Prerequisite: Account has at least one workspace.

  1. Open the Expensify app.
  2. Create a manual expense via FAB and submit it to workspace chat.
  3. Return to "Inbox"
  4. Create a second manual expense via FAB and submit it to workspace.
  5. Tap on "View" on the displayed growl.
  6. Once expense was opened, tap on "More" > "Delete" > "Delete"
  7. Note that you land on chat, instead of landing on parent report.
  8. Return to "Inbox" one more time.
  9. Create another manual expense via FAB and submit it to workspace.
  10. Tap on "View" on the displayed growl.
  11. Tap on expense header to navigate to details page.
  12. Delete the expense.
  13. Note that you land on parent report.

Expected Result:

After opening an expense via growl and deleting it, user should return to parent report if there are more expenses.

Actual Result:

Behavior after deleting expense opened via growl is inconsistent if there are more expenses on report. If expense is deleted via "More" menu, user lands on chat, and if expense is deleted via details page, user lands on parent report.

Workaround:

Unknown

Platforms:

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

Screenshots/Videos

Bug7274905_1790910746230.View_15.mp4

View all open jobs on GitHub

Applause Internal Information
Exported by: Rizky Gunawan
Bug ID: 7274905

Issue OwnerCurrent Issue Owner: @mhawryluk

Activity

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

  3. melvin-bot commented on Oct 2, 2026

    @melvin-bot

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

  4. melvin-bot commented on Oct 2, 2026

    @melvin-bot

    @mountiny @situchan you have been assigned to this deploy blocker because you reviewed the offending PR: #100015

  5. github-actions commented on Oct 2, 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. melvin-bot commented on Oct 2, 2026

    @melvin-bot

    @mhawryluk you have been assigned to this deploy blocker because you authored the offending PR: #100015

  7. melvin-bot commented on Oct 2, 2026

    @melvin-bot

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

  8. MelvinBot commented on Oct 2, 2026

    @MelvinBot
    Contributor

    Deploy Blocker Analysis

    Causing PR: Confirm new expenses with a “View” toast instead of scrolling to and highlighting the row v2 (high confidence).

    Recommendation: Demote and fix forward. Do not revert. This is a navigation inconsistency in an unreleased feature on narrow layout only. The expense is still deleted correctly, and no data is lost.

    Root Cause: On narrow layout, the growl's "View" opens the expense thread directly on top of the workspace chat, with backTo set to the chat. It skips the parent expense report. More > Delete then calls goBack(backTo), so the user lands on the chat. The details-page delete works out the parent report on its own, so it lands correctly.

    Recommended Fix: In navigateToCreatedExpense.ts, make the narrow branch match the wide branch. When the report has several expenses, open the expense report first, then stack the thread on it. A smaller option is to pass the expense report route as the thread's backTo. Add a narrow, multi-expense case to tests/unit/navigateToCreatedExpenseTest.ts.

    Investigation details
    1. After a FAB expense from Inbox, the app opens the workspace chat (dismissModalAndOpenReportInInboxTab.ts:90). The growl shows because the focused report is the chat (ExpenseAddedGrowl.tsx:116).
    2. navigateToCreatedExpense (new in this PR) sets backTo to the active route, which is the chat (L55). The narrow branch returns before the iouReportID handling. The wide branch stacks report → thread for multi-expense reports (L67-L84), so wide layouts are not affected.
    3. More > Delete calls onBackButtonPress (MoneyRequestHeaderSecondaryActions.tsx:629), which resolves to Navigation.goBack(backTo) (ReportHeader.tsx:68-70).
    4. The details-page delete calls getNavigationUrlOnMoneyRequestDelete (DynamicReportDetailsPage/index.tsx:890-907). That function returns the expense report route when the report survives (DeleteMoneyRequest.ts:374-376).

    Other checklist PRs: I checked the other App PRs in this deploy against the delete, navigation, header, and growl code. None of them change this navigation.

    Not a regression: More > Delete works in the existing chat → report → thread flow. Only the new "View" entry point leaves the report out of the stack.


    Next Steps: Reply with @MelvinBot implement this to create a draft PR, or @MelvinBot <your feedback> to refine this analysis.


    view run

  9. mhawryluk commented on Oct 2, 2026

    @mhawryluk
    Member

    I agree with Melvin that we should demote it and fix later, nothing is actually broken, it's just a little inconsistent

  10. melvin-bot commented on Oct 2, 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.

  11. melvin-bot commented on Oct 2, 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.

  12. mhawryluk commented on Oct 2, 2026

    @mhawryluk
    Member

    actually, I think this PR should fix this issue too: #102854

  13. added and removed
    DeployBlockerCashThis issue or pull request should block deployment
    on Oct 2, 2026
  14. mountiny commented on Oct 2, 2026

    @mountiny
    Contributor

    I think we can demote this one

  15. situchan commented on Oct 4, 2026

    @situchan
    Contributor

    This is not a regression from #100015. The production app already has two different mechanisms.

    The More menu uses:

    const deleteNavigateBackUrl = goBackRoute ?? backTo ?? Navigation.getActiveRoute();
    setDeleteTransactionNavigateBackUrl(deleteNavigateBackUrl);

    while the details page uses navigateBackOnDeleteTransaction unconditionally.

    The prod app also already produces a no-backTo arrival at the expense report:

    Navigation.navigate(ROUTES.SEARCH_MONEY_REQUEST_REPORT.getRoute({reportID: parentReportID}));

    Navigation.navigate(ROUTES.SEARCH_MONEY_REQUEST_REPORT.getRoute({reportID}), {forceReplace: !isNarrowLayout});

    Repro step:

    1. In a workspace chat, create two expenses in a report.
    2. Open one expense (tap its preview).
    3. Tap the breadcrumb/subtitle under the header title to open the expense report — this navigation carries no backTo.
    4. Open an expense from that report, then tap More > Delete > Delete. Note where you land.
    5. Repeat steps 2-3, open another expense, tap the expense header to reach the details page, and delete from there.
    6. The two delete entry points land you in different places.

    Or just update step 5, 10 in OP:

    Tap on "View" on the displayed growl.

    to: Tao on the created expense in report preview

    bug.mp4
  16. melvin-bot commented on Oct 5, 2026

    @melvin-bot

    @mhawryluk Whoops! This issue is 2 days overdue. Let's get this updated quick!

  17. mhawryluk commented on Oct 6, 2026

    @mhawryluk
    Member

    it has been fixed by this PR: #102854. now in both cases we are back to the parent report instead of chat.

    Nagranie.z.ekranu.2026-10-6.o.14.14.43.mov

    may I ask for a retest?

  18. mountiny commented on Oct 7, 2026

    @mountiny
    Contributor

    Asked for a retest.

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