Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[HOLD for payment 2024-11-18] [$250] mWeb - Debug - In workspace chat, delete via debug directs to blank page. #51388

Closed
1 of 8 tasks
IuliiaHerets opened this issue Oct 24, 2024 · 33 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2

Comments

@IuliiaHerets
Copy link

IuliiaHerets commented Oct 24, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 9.0.53-0
Reproducible in staging?: Y
Reproducible in production?: Unable to check in Prod, Debug mode is not available
Issue reported by: Applause Internal Team

Action Performed:

Pre-condition:
1.Go to https://staging.new.expensify.com/home
2. Go to profile icon -- troubleshoot
3. Scroll down to enable debug mode

  1. Go to https://staging.new.expensify.com/home
  2. Tap on a workspace chat
  3. Send a message
  4. Tap header -- debug
  5. Scroll down to tap delete
  6. Note a blank page displayed
  7. Refresh the page
  8. Note hmm not here page displayed
  9. Navigate to LHN
  10. Note report disappeared from LHN

Expected Result:

In workspace chat, delete via debug must not direct to blank page.

Actual Result:

In workspace chat, delete via debug directs to blank page initially and on refresh directs to hmm not here. Then navigating to LHN, particular report is not shown.

Workaround:

Unknown

Platforms:

  • Android: Standalone
  • Android: HybridApp
  • Android: mWeb Chrome
  • iOS: Standalone
  • iOS: HybridApp
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug6644006_1729742485010.Screenrecorder-2024-10-24-09-20-39-977_compress_1.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021849364084876247061
  • Upwork Job ID: 1849364084876247061
  • Last Price Increase: 2024-10-31
Issue OwnerCurrent Issue Owner: @adelekennedy
@IuliiaHerets IuliiaHerets added DeployBlockerCash This issue or pull request should block deployment Bug Something is broken. Auto assigns a BugZero manager. labels Oct 24, 2024
Copy link

melvin-bot bot commented Oct 24, 2024

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

Copy link

melvin-bot bot commented Oct 24, 2024

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

Copy link

melvin-bot bot commented Oct 24, 2024

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

@melvin-bot melvin-bot bot added the Daily KSv2 label Oct 24, 2024
@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Oct 24, 2024
Copy link
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.

@lakchote
Copy link
Contributor

lakchote commented Oct 24, 2024

Not a blocker, it concerns an issue with Debug mode. It also concerns Web as a whole.

@lakchote lakchote added External Added to denote the issue can be worked on by a contributor Daily KSv2 Help Wanted Apply this label when an issue is open to proposals by contributors and removed DeployBlockerCash This issue or pull request should block deployment Hourly KSv2 labels Oct 24, 2024
@melvin-bot melvin-bot bot changed the title mWeb - Debug - In workspace chat, delete via debug directs to blank page. [$250] mWeb - Debug - In workspace chat, delete via debug directs to blank page. Oct 24, 2024
Copy link

melvin-bot bot commented Oct 24, 2024

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

Copy link

melvin-bot bot commented Oct 24, 2024

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

@nyomanjyotisa
Copy link
Contributor

Proposal

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

mWeb - Debug - In workspace chat, delete via debug directs to blank page.

What is the root cause of that problem?

We use Navigation.goBack(); after the delete action

<Button
danger
large
text={translate('common.delete')}
onPress={() => {
onDelete();
Navigation.goBack();
}}
/>

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

Use Navigation.dismissModal(); instead

What alternative solutions did you explore? (Optional)

@NJ-2020
Copy link
Contributor

NJ-2020 commented Oct 24, 2024

Edited by proposal-police: This proposal was edited at 2024-10-24 12:34:01 UTC.

Proposal

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

mWeb - Debug - In workspace chat, delete via debug directs to blank page

What is the root cause of that problem?

When clicking the delete the report, we only navigating back from the report which will only dismiss the modal

onPress={() => {
onDelete();
Navigation.goBack();
}}

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

We need to add the Navigation.dismissModal(); too
And we will run the goBack function if it's small screen width

Navigation.dismissModal();
if (isSmallScreenWidth) {
    Navigation.isNavigationReady().then(() => {
        Navigation.goBack();
    })
}

Result

Screen.Recording.2024-10-24.at.01.43.27.mov

What alternative solutions did you explore? (Optional)

@bernhardoj
Copy link
Contributor

Proposal

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

After deleting report from debug page, a blank page is shown.

What is the root cause of that problem?

When we press delete, it will delete the report and go back to the previous page. The previous page in our case is the report details page. The report details page is wrapped with a withReportOrNotFound HOC. In the HOC, if shouldShowNotFoundPage is true (because the report is empty) and contentShown ref is true, we render nothing.

// If the content was shown, but it's not anymore, that means the report was deleted, and we are probably navigating out of this screen.
// Return null for this case to avoid rendering FullScreenLoadingIndicator or NotFoundPage when animating transition.
if (shouldShowNotFoundPage && contentShown.current) {
return null;
}

The comment mentions why we do that. Basically, if the report is previously available but now is not, we assume that the page will be dismissed along with the deletion and we don't want to show not found page while navigating back. However, that is not the case when we delete it from the debug page.

Also, that's not the case if say:

  1. User A invite user B to a room
  2. User B open the room details page
  3. User A removes B from room
  4. User B sees blank page

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

Because we don't want to show the not found briefly when navigating back, we can check for the screen focused state instead.

// If the content was shown, but it's not anymore, that means the report was deleted, and we are probably navigating out of this screen.
// Return null for this case to avoid rendering FullScreenLoadingIndicator or NotFoundPage when animating transition.
if (shouldShowNotFoundPage && contentShown.current) {
return null;
}

if (shouldShowNotFoundPage && !isFocused) {
    return null;
}

@NJ-2020
Copy link
Contributor

NJ-2020 commented Oct 24, 2024

Proposal Updated

@lakchote
Copy link
Contributor

@alitoshmatov please review proposals, thank you.

Copy link

melvin-bot bot commented Oct 29, 2024

@lakchote, @alitoshmatov, @adelekennedy Huh... This is 4 days overdue. Who can take care of this?

@melvin-bot melvin-bot bot added the Overdue label Oct 29, 2024
@bernhardoj
Copy link
Contributor

PR is ready

cc: @allroundexperts

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Nov 11, 2024
@melvin-bot melvin-bot bot changed the title [$250] mWeb - Debug - In workspace chat, delete via debug directs to blank page. [HOLD for payment 2024-11-18] [$250] mWeb - Debug - In workspace chat, delete via debug directs to blank page. Nov 11, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Nov 11, 2024
Copy link

melvin-bot bot commented Nov 11, 2024

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

Copy link

melvin-bot bot commented Nov 11, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.59-3 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 2024-11-18. 🎊

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

Copy link

melvin-bot bot commented Nov 11, 2024

@allroundexperts @adelekennedy 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]

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Nov 18, 2024
Copy link

melvin-bot bot commented Nov 18, 2024

Payment Summary

Upwork Job

BugZero Checklist (@adelekennedy)

  • I have verified the correct assignees and roles are listed above and updated the neccesary manual offers
  • I have verified that there are no duplicate or incorrect contracts on Upwork for this job (https://www.upwork.com/ab/applicants/1849364084876247061/hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@bernhardoj
Copy link
Contributor

Requested in ND.

@adelekennedy
Copy link

adelekennedy commented Nov 18, 2024

Payouts due:

confirming payment summary here

@adelekennedy
Copy link

BugZero Checklist:

  • [Contributor] Classify the bug:
Bug classification

Source of bug:

  • 1a. Result of the original design (eg. a case wasn't considered)
  • 1b. Mistake during implementation
  • 1c. Backend bug
  • 1z. Other:

Where bug was reported:

  • 2a. Reported on production
  • 2b. Reported on staging (deploy blocker)
  • 2c. Reported on both staging and production
  • 2d. Reported on a PR
  • 2z. Other:

Who reported the bug:

  • 3a. Expensify user
  • 3b. Expensify employee
  • 3c. Contributor
  • 3d. QA
  • 3z. Other:
  • [Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.

    Link to comment:

  • [Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.

    Link to discussion:

  • [Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.

Regression Test Proposal Template
  • [BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.

    Link to issue:

Regression Test Proposal

Precondition:

Test:

Do we agree 👍 or 👎

@adelekennedy
Copy link

nearly forgot the checklist @allroundexperts for a quick review

@allroundexperts
Copy link
Contributor

Checklist

  1. There isn't a single PR that caused this. We never handled this edge case.
  2. N/A
  3. N/A
  4. A regression test would be helpful

Regression Test

Prerequisite: Enable debug mode by going to settings -> troubleshoot

  1. Open any chat
  2. Press the header to open details
  3. Press Debug
  4. Scroll to the bottom and press Delete

Verify you see a not found detail page

Do we 👍 or 👎 ?

@melvin-bot melvin-bot bot added the Overdue label Nov 21, 2024
@JmillsExpensify
Copy link

$250 approved for @bernhardoj

Copy link

melvin-bot bot commented Nov 22, 2024

@lakchote, @allroundexperts, @bernhardoj, @adelekennedy Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

Copy link

melvin-bot bot commented Nov 29, 2024

⚠️ 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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2
Projects
None yet
Development

No branches or pull requests

9 participants