Skip to content

Deleted Expenses Still Appear in LHN with Unread Concierge Auto-Categorization Messages #67287

Closed

Description

@m-natarajan

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:
Reproducible in staging?: Needs Reproduction
Reproducible in production?: Needs Reproduction
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @puneetlath
Slack conversation (hyperlinked to channel name): #Retain

Action Performed:

  1. Create or view an expense that triggers Concierge auto-categorization
  2. Delete the expense
  3. Check the LHN for remaining threads

Expected Result:

Once an expense is deleted, the related report thread should no longer appear in the LHN.
Any Concierge messages related to deleted reports should not cause the report to remain visible as unread.

Furthermore, we should ignore Concierge messages when counting the number of comments made on a thread before we decide if we delete it completely. Right now, we keep the thread if there were comments on it for audit history. Let's consider the report as without any comments if the only report actions are from Concierge

Actual Result:

After deleting an expense, the associated report thread remains in the LHN.
The Concierge message remains marked as unread, keeping the thread active in the LHN.

Workaround:

Unknown

Platforms:

Select the officially supported platforms where the issue was reproduced:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop
Platforms Tested: On which of our officially supported platforms was this issue tested:
  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

The link for the fullstory is in OP

Image

View all open jobs on GitHub

Activity

  1. added
    Needs Reproduction
    Bug
    on Jul 28, 2025
  2. melvin-bot commented on Jul 28, 2025

    @melvin-bot

    Triggered auto assignment to @dylanexpensify (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.

  3. MelvinBot commented on Jul 28, 2025

    @MelvinBot
    Contributor

    This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989

  4. changed the title [-]Full story : Deleted Expenses Still Appear in LHN with Unread Concierge Auto-Categorization Messages[/-] [+]Deleted Expenses Still Appear in LHN with Unread Concierge Auto-Categorization Messages[/+] on Jul 29, 2025
  5. added
    Internal
    Hot Pick
    and removed
    Needs Reproduction
    on Jul 29, 2025
  6. self-assigned this
    on Jul 29, 2025
  7. removed
    Hot Pick
    on Jul 29, 2025
  8. added
    Reviewing
    on Jul 29, 2025
  9. marcaaron commented on Jul 29, 2025

    @marcaaron
    Contributor

    PR up.

  10. 13 remaining items

  11. marcaaron commented on Aug 29, 2025

    @marcaaron
    Contributor

    @MitchExpensify do you think that other user also might have removed a card feed?

  12. marcaaron commented on Aug 29, 2025

    @marcaaron
    Contributor

    Actually I think @jasperhuangg's changes here might fix this problem for everyone. I started writing an automated test and did some refactoring though so I think I will raise a PR with that at least, but this should be fixed 🤞

  13. marcaaron commented on Aug 29, 2025

    @marcaaron
    Contributor

    Or maybe not. We still want the transaction threads deleted.

  14. moved this to Second Cohort - HIGH in [#whatsnext] #migrateon Sep 2, 2025
  15. danielrvidal commented on Sep 4, 2025

    @danielrvidal
    Contributor

    Nice, looks like this hit production, woo! I don't have a great way of testing that I know of because my test Amex feed categorizes them correctly so I don't get the original concierge message.

    @marcaaron can you think of another way for me to test this?

  16. marcaaron commented on Sep 5, 2025

    @marcaaron
    Contributor

    Ah hmm. Whether you had these auto-categorize messages from Concierge or not the expectation would still be for the threads to not be in the LHN anymore. We delete any thread as long as it does not have a comment from a user in it (or some other kind of non-whitelisted action) so I think a test might be something like:

    • Connect Card Feed
    • Leave a Comment on one of the transaction threads (comments are considered "important" actions that we don't want to lose)
    • Disconnect the Card Feed
    • Confirm that all the threads have been deleted except the one where you left a comment
  17. danielrvidal commented on Sep 9, 2025

    @danielrvidal
    Contributor

    Nice, I think we're good here! Here is the comment of a feed that I removed from the user:

    Admins account:
    Image

    Employees account:

    Image
  18. marcaaron commented on Sep 9, 2025

    @marcaaron
    Contributor

    Nice! I think let's close this one out. If there are any edge cases that pop up we can reopen. Happy to keep looking into any inconsistencies.

  19. moved this from Second Cohort - HIGH to Done in [#whatsnext] #migrateon Sep 9, 2025
  20. ryanldonato commented on Sep 10, 2025

    @ryanldonato
    Contributor

    @marcaaron these deleted expense chats are still showing for accounting@bluesprucecg.com

    Image
  21. marcaaron commented on Sep 11, 2025

    @marcaaron
    Contributor

    If it's the same account from before then that's expected. The fix will only apply to future cases. We would need to manually delete those with a custom query. Can we create a clean up issue and letting this issue reopen only if a new case pops up? I can help write the queries to manually clean this up, but we will need ring1 to help.

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

Metadata

Metadata

Labels

BugInternalReviewingWeekly

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions