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-01] [$250] TransitionOD-ND - When disabling tax in OD, ND "page not Found", "Back" takes to WS selection #50465

Closed
1 of 6 tasks
lanitochka17 opened this issue Oct 8, 2024 · 19 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 External Added to denote the issue can be worked on by a contributor

Comments

@lanitochka17
Copy link

lanitochka17 commented Oct 8, 2024

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.0.46-3
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/5053996
Issue reported by: Applause - Internal Team

Action Performed:

  1. Open ND App
  2. Create a WS
  3. Log in as the same user in OD
  4. In OD Click on Workspaces
  5. Select the same WS as in ND
  6. In OD go to WS settings and enable Tax
  7. In ND go to WS settings, on LHP click on Tax icon
    8.With Tax page open in ND, navigate to OD and disable Tax option

Expected Result:

In ND the user is navigated to the LHP/WS editor page

Actual Result:

The user is shown "Ops...It's not here" page, the "Back" button takes you back to the WS selection page(User leaves the WS editor page)

Workaround:

Unknown

Platforms:

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

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence
Bug6628416_1728397298522.taxdisablestaging.1.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021845793851841023680
  • Upwork Job ID: 1845793851841023680
  • Last Price Increase: 2024-10-14
Issue OwnerCurrent Issue Owner: @sonialiap
@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Oct 8, 2024
Copy link

melvin-bot bot commented Oct 8, 2024

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

@lanitochka17
Copy link
Author

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

@bernhardoj
Copy link
Contributor

Proposal

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

Going back from not found tax page leads to workspace list page.

What is the root cause of that problem?

When we disable the tax page, it's expected that a full screen not found page will show. The reason pressing back leads to the workspace list page is because a Navigation.dismissModal is called, which closes the workspace details page.

function PageNotFoundFallback({policyID, shouldShowFullScreenFallback, fullPageNotFoundViewProps, isMoneyRequest}: PageNotFoundFallbackProps) {
return (
<NotFoundPage
shouldForceFullScreen={shouldShowFullScreenFallback}
onBackButtonPress={() => {
if (shouldShowFullScreenFallback) {
Navigation.dismissModal();
return;
}
Navigation.goBack(policyID && !isMoneyRequest ? ROUTES.WORKSPACE_PROFILE.getRoute(policyID) : undefined);

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

shouldShowFullScreenFallback is true if the feature is disabled or the policy is not accessible.

shouldShowFullScreenFallback={!isFeatureEnabled || isPolicyNotAccessible}

I think we should only close the workspace detail page if the policy is not accessible. To do that, we need to pass both isFeatureEnabled and isPolicyNotAccessible to PageNotFoundFallback and remove the shouldShowFullScreenFallback props and instead, add it as a local variable in PageNotFoundFallback.

isFeatureEnabled={isFeatureEnabled}
isPolicyNotAccessible={isPolicyNotAccessible}

Then, in PageNotFoundCallback,

function PageNotFoundFallback({policyID, shouldShowFullScreenFallback, fullPageNotFoundViewProps, isMoneyRequest}: PageNotFoundFallbackProps) {
return (
<NotFoundPage
shouldForceFullScreen={shouldShowFullScreenFallback}
onBackButtonPress={() => {
if (shouldShowFullScreenFallback) {
Navigation.dismissModal();
return;
}
Navigation.goBack(policyID && !isMoneyRequest ? ROUTES.WORKSPACE_PROFILE.getRoute(policyID) : undefined);
}}

only use dismissModal if the policy is not accessible. If the feature is disabled, then we will just go back.

const shouldShowFullScreenFallback = !isFeatureEnabled || isPolicyNotAccessible;
onBackButtonPress={() => {
    if (isPolicyNotAccessible) {
        Navigation.dismissModal();
        return;
    }
    Navigation.goBack(policyID && !isMoneyRequest ? ROUTES.WORKSPACE_PROFILE.getRoute(policyID) : undefined);
}}

@melvin-bot melvin-bot bot added the Overdue label Oct 10, 2024
@sonialiap sonialiap added the External Added to denote the issue can be worked on by a contributor label Oct 14, 2024
Copy link

melvin-bot bot commented Oct 14, 2024

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

@melvin-bot melvin-bot bot changed the title TransitionOD-ND - When disabling tax in OD, ND "page not Found", "Back" takes to WS selection [$250] TransitionOD-ND - When disabling tax in OD, ND "page not Found", "Back" takes to WS selection Oct 14, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Oct 14, 2024
Copy link

melvin-bot bot commented Oct 14, 2024

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

@melvin-bot melvin-bot bot removed the Overdue label Oct 14, 2024
@mananjadhav
Copy link
Collaborator

Got assigned today. Will review the proposal.

@mananjadhav
Copy link
Collaborator

I think @bernhardoj's proposal looks good. We'll need to check if it exists for other pages such as "Tags", etc.

🎀 👀 🎀 C+ reviewed.

Copy link

melvin-bot bot commented Oct 14, 2024

Triggered auto assignment to @madmax330, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Oct 15, 2024
@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Oct 15, 2024
@bernhardoj
Copy link
Contributor

PR is ready
cc: @mananjadhav

@mananjadhav
Copy link
Collaborator

Thanks, I'll review and test by tomorrow.

@dylanexpensify dylanexpensify moved this to Release 3: Fall 2024 (Nov) in [#whatsnext] #expense Oct 18, 2024
@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Oct 25, 2024
@melvin-bot melvin-bot bot added the Awaiting Payment Auto-added when associated PR is deployed to production label Oct 25, 2024
@melvin-bot melvin-bot bot changed the title [$250] TransitionOD-ND - When disabling tax in OD, ND "page not Found", "Back" takes to WS selection [HOLD for payment 2024-11-01] [$250] TransitionOD-ND - When disabling tax in OD, ND "page not Found", "Back" takes to WS selection Oct 25, 2024
Copy link

melvin-bot bot commented Oct 25, 2024

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

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Oct 25, 2024
Copy link

melvin-bot bot commented Oct 25, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.53-1 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-01. 🎊

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

  • @mananjadhav requires payment through NewDot Manual Requests
  • @bernhardoj requires payment through NewDot Manual Requests

Copy link

melvin-bot bot commented Oct 25, 2024

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@mananjadhav] The PR that introduced the bug has been identified. Link to the PR:
  • [@mananjadhav] 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:
  • [@mananjadhav] A discussion in #expensify-bugs 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:
  • [@mananjadhav] Determine if we should create a regression test for this bug.
  • [@mananjadhav] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
  • [@sonialiap] Link the GH issue for creating/updating the regression test once above steps have been agreed upon: https://github.com/Expensify/Expensify/issues/441368

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Oct 31, 2024
Copy link

melvin-bot bot commented Nov 1, 2024

Payment Summary

Upwork Job

BugZero Checklist (@sonialiap)

  • 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/1845793851841023680/hired)
  • I have paid out the Upwork contracts or cancelled the ones that are incorrect
  • I have verified the payment summary above is correct

@mananjadhav
Copy link
Collaborator

I tried to find an offending PR for this one but I couldn't. We refactored this code quite a bit but I think we should add a regression test for this.

@sonialiap Here's the regression test proposal and this one is ready for payout.

Prerequisite: logged in as the same user in 2 tabs/devices.

  1. Open any workspace > More features > Enable taxes.
  2. Open Taxes.
  3. From the other devices, disable the taxes from the More features page.
  4. Back to the first device, verify a not found page is shown.
  5. Press the back button.
  6. Verify you are navigated back to the WS settings page.

@bernhardoj
Copy link
Contributor

Requested in ND.

@melvin-bot melvin-bot bot added the Overdue label Nov 4, 2024
@sonialiap
Copy link
Contributor

Payment summary:

@github-project-automation github-project-automation bot moved this from Release 3: Fall 2024 (Nov) to Done in [#whatsnext] #expense Nov 4, 2024
@melvin-bot melvin-bot bot removed the Overdue label Nov 4, 2024
@JmillsExpensify
Copy link

$250 approved for @bernhardoj

@garrettmknight
Copy link
Contributor

$250 approved for @mananjadhav

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. Daily KSv2 External Added to denote the issue can be worked on by a contributor
Projects
Archived in project
Development

No branches or pull requests

7 participants