Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.31k stars 2.74k forks source link

[$250] iOS - Chat - Chat gets blank after deleting task and does load until user swipes down #45727

Closed m-natarajan closed 1 month ago

m-natarajan commented 1 month ago

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Issue found when validating #45279 Version Number: 9.0.9.1 Reproducible in staging?: y Reproducible in production?: n 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: Applause Internal Team Slack conversation:

Action Performed:

  1. Open the app and log in
  2. Navigate to any report with some chat history
  3. Tap + > Assign task
  4. Enter title and complete task creation
  5. Open the created task
  6. Tap the header and delete the task

    Expected Result:

    User is returned to the report and previous chat history is displayed

    Actual Result:

    The chat history is not displayed until user swipes down

    Workaround:

    Unknown

    Platforms:

    Which of our officially supported platforms is this issue occurring on?

    • [ ] Android: Native
    • [ ] Android: mWeb Chrome
    • [x] iOS: Native
    • [ ] iOS: mWeb Safari
    • [ ] MacOS: Chrome / Safari
    • [ ] MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

https://github.com/user-attachments/assets/1c2d0b29-3d72-40aa-b330-bcb6eb8b7c49

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~018e3d29dc110bc703
  • Upwork Job ID: 1815451828641310685
  • Last Price Increase: 2024-08-05
Issue OwnerCurrent Issue Owner: @eVoloshchak
melvin-bot[bot] commented 1 month ago

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

m-natarajan commented 1 month ago

@abekkala FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

m-natarajan commented 1 month ago

@abekkala We think that this bug might be related to #vip-vsb

melvin-bot[bot] commented 1 month ago

Job added to Upwork: https://www.upwork.com/jobs/~018e3d29dc110bc703

melvin-bot[bot] commented 1 month ago

Triggered auto assignment to Contributor-plus team member for initial proposal review - @eVoloshchak (External)

melvin-bot[bot] commented 1 month ago

@abekkala Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

Zakpak0 commented 1 month ago

Proposal

Please re-state the problem that we are trying to solve in this issue.

Given it is the latest report action, when deleting the last task in an Assign Task list creates a navigation error which leaves the screen blank.

What is the root cause of that problem?

It seems like we aren't waiting for the navigator to be ready before we navigate back to the original report.

What changes do you think we should make in order to solve the problem?

We should change these lines here src/libs/actions/Task.ts

    if (shouldDeleteTaskReport) {
            Navigation.goBack(ROUTES.REPORT_WITH_ID.getRoute(parentReport?.reportID ?? '-1'));
    }

To the following: If we should delete the task report, then lets wait for navigation to be ready and then navigate the user back.

    if (shouldDeleteTaskReport) {
        Navigation.isNavigationReady().then(() => {
            Navigation.goBack(ROUTES.HOME)
            Navigation.navigate(ROUTES.REPORT_WITH_ID.getRoute(parentReport?.reportID ?? '-1'));
        })
    }

Here is a test branch with my changes

What alternative solutions did you explore? (Optional) My inbox and it's search options are flooded with [Deleted task] threads. I'm not sure if this expected behavior. If it is not then I believe that could mean the task feature isn't fully fleshed out? And task actions aren't being handled as well as other features? Like filtering and navigating. I'm not sure, but if my suspicion is correct this could also be contributing to the root cause.

melvin-bot[bot] commented 1 month ago

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

abekkala commented 1 month ago

@eVoloshchak can you review the proposal above?

melvin-bot[bot] commented 1 month ago

@eVoloshchak, @abekkala Still overdue 6 days?! Let's take care of this!

abekkala commented 1 month ago

@eVoloshchak are you able to review that proposal today?

melvin-bot[bot] commented 1 month ago

@eVoloshchak, @abekkala 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

eVoloshchak commented 1 month ago

It seems like we aren't waiting for the navigator to be ready before we navigate back to the original report.

@Zakpak0, inside the Navigation.goBack we check if navigation is ready (canNavigate -> navigationRef.isReady()) There is a difference in implementation between isNavigationReady and navigationRef.isReady(), we need to figure out exactly why the first works, but the second doesn't, so this is resolved app-wide (in goBack method itself)

Zakpak0 commented 1 month ago

@eVoloshchak thank you, will look into this more today.

melvin-bot[bot] commented 1 month ago

@eVoloshchak @abekkala this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

melvin-bot[bot] commented 1 month ago

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

eVoloshchak commented 1 month ago

Not overdue, don't have any satisfactory proposals just yet

melvin-bot[bot] commented 1 month ago

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

abekkala commented 1 month ago

@Zakpak0 are you able to provide an updated proposal?

abekkala commented 1 month ago

Given that we haven't received a proposal and vsb is on hold - I'm closing