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-20] [$250] QBO - Back button on workspace editor returns to Accounting after changing Import settings #51696

Closed
1 of 8 tasks
lanitochka17 opened this issue Oct 29, 2024 · 23 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 Engineering External Added to denote the issue can be worked on by a contributor

Comments

@lanitochka17
Copy link

lanitochka17 commented Oct 29, 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.55-4
Reproducible in staging?: Y
Reproducible in production?: No, new feature
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: N/A
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause - Internal Team

Action Performed:

Precondition:

  • Workspace is connected to QBO
  1. Go to www.staging.chat.expensify.com
  2. Go to workspace settings > Accounting
  3. Click Import
  4. Click Classes > Tap Displayed as
  5. Select Tags or Report fields
  6. Click back button twice to return to Accounting page
  7. Click back button to return to workspace editor
  8. Click back button again

Expected Result:

App will return to workspace list

Actual Result:

App returns to Accounting page when tapping back button from workspace editor after changing Import settings

Workaround:

Unknown

Platforms:

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

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

Screenshots/Videos

Add any screenshot/video evidence
Screen_Recording_20241029_230206_Chrome.2.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021851664505290782444
  • Upwork Job ID: 1851664505290782444
  • Last Price Increase: 2024-10-30
  • Automatic offers:
    • FitseTLT | Contributor | 104739114
Issue OwnerCurrent Issue Owner: @slafortune
@lanitochka17 lanitochka17 added the DeployBlockerCash This issue or pull request should block deployment label Oct 29, 2024
Copy link

melvin-bot bot commented Oct 29, 2024

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

Copy link

melvin-bot bot commented Oct 29, 2024

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

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.

@jasperhuangg
Copy link
Contributor

This also happens on prod, NAB

@jasperhuangg jasperhuangg added External Added to denote the issue can be worked on by a contributor Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. and removed DeployBlockerCash This issue or pull request should block deployment Hourly KSv2 labels Oct 30, 2024
@melvin-bot melvin-bot bot changed the title QBO - Back button on workspace editor returns to Accounting after changing Import settings [$250] QBO - Back button on workspace editor returns to Accounting after changing Import settings Oct 30, 2024
Copy link

melvin-bot bot commented Oct 30, 2024

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

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Oct 30, 2024
Copy link

melvin-bot bot commented Oct 30, 2024

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

Copy link

melvin-bot bot commented Oct 30, 2024

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

@twilight2294
Copy link
Contributor

twilight2294 commented Oct 30, 2024

Edited by proposal-police: This proposal was edited at 2024-11-01 04:47:21 UTC.

Proposal

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

Back button on workspace editor returns to Accounting after changing Import settings

What is the root cause of that problem?

In the below code:

onBackButtonPress={() => Navigation.goBack(ROUTES.POLICY_ACCOUNTING.getRoute(policyID))}

the fallback route navigates to new FullScreenNavigator instead of back to the existing one:

if (shouldEnforceFallback || (isFirstRouteInNavigator && fallbackRoute)) {
navigate(fallbackRoute, CONST.NAVIGATION.TYPE.UP);
return;
}

This is the reason we return to the accounting page.

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

We need to just use Navigation.goBack() here so that we do not create FullScreenNavigator

If similar bug occurs in other connections or places, we should fix that too.

What alternative solutions did you explore? (Optional)

@FitseTLT
Copy link
Contributor

Proposal

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

QBO - Back button on workspace editor returns to Accounting after changing Import settings

What is the root cause of that problem?

The root cause lies in here

onBackButtonPress={() => Navigation.goBack(ROUTES.POLICY_ACCOUNTING.getRoute(policyID))}

QuickbooksImportPage is the first route in the RHP navigator so when we goBack with fallbackRoute the isFirstRouteInNavigator will be true and we will navigate to the fallbackRoute (in this case policy accounting page)
if (shouldEnforceFallback || (isFirstRouteInNavigator && fallbackRoute)) {
navigate(fallbackRoute, CONST.NAVIGATION.TYPE.UP);

so the import route will be replaced by duplicate POLICY_ACCOUNTING route as we already had an existing accounting route in the nav state

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

We don't need the fallbackRoute in the goBack so should remove this line

onBackButtonPress={() => Navigation.goBack(ROUTES.POLICY_ACCOUNTING.getRoute(policyID))}

we should also make similar fix here
onBackButtonPress={() => Navigation.goBack(ROUTES.POLICY_ACCOUNTING.getRoute(policyID))}

What alternative solutions did you explore? (Optional)

@jayeshmangwani
Copy link
Contributor

@twilight2294 I noticed you updated the proposal after another contributor added theirs. Previously, the permalink pointed to a different page, but now it points to the same page indicated by the other contributor. It's not an issue, but I just wanted to mention that whenever we update the proposal, it’s helpful to leave a comment saying, 'Proposal updated.'

@jayeshmangwani
Copy link
Contributor

Thanks for the proposals @FitseTLT @twilight2294 !
I’m testing some other pages that use the fallback route under accounting. I’m trying to understand the purpose of adding this fallback route(on original PR), as it's implemented on several accounting pages (e.g., SageIntacctAdvancedPage, NetSuiteImportAddCustomSegmentContent, QuickbooksDesktopImportPage, etc.)

@FitseTLT
Copy link
Contributor

FitseTLT commented Nov 1, 2024

@jayeshmangwani fallback routes are used for direct link(or refreshing of the page). For cases where there are multiple pages in a flow when the route below the current route in the stack can not be generated from the link with our customRouter, we will need to provide the backTo link directly as a fallbackRoute so it will navigate to the correct page before the current page in the flow but in the current case we don't need them. To test that you can switch to small screen on web and refresh it and click goBack and if it navigates correctly without the fallbackRoute it means fallbackRoute is not needed.

@jayeshmangwani
Copy link
Contributor

Thanks for the explanation @FitseTLT! What I’m trying to say is that we’ve added a fallback route to many accounting pages. I’m currently checking how many of those pages are experiencing the same issue as this one.

@jayeshmangwani
Copy link
Contributor

Thanks for the proposals above! Both suggestions involve removing the fallback route, but I’d prefer going with @FitseTLT 's Proposal of removing the onBackButtonPress altogether. they initially indicated the correct page where the issue originates, for this specific issue. For other pages with similar issues, we can do thorough testing in the PR.

🎀 👀 🎀 C+ reviewed

Copy link

melvin-bot bot commented Nov 3, 2024

Current assignee @jasperhuangg is eligible for the choreEngineerContributorManagement assigner, not assigning anyone new.

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Nov 4, 2024
Copy link

melvin-bot bot commented Nov 4, 2024

📣 @FitseTLT 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Keep in mind: Code of Conduct | Contributing 📖

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Nov 5, 2024
@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 13, 2024
@melvin-bot melvin-bot bot changed the title [$250] QBO - Back button on workspace editor returns to Accounting after changing Import settings [HOLD for payment 2024-11-20] [$250] QBO - Back button on workspace editor returns to Accounting after changing Import settings Nov 13, 2024
Copy link

melvin-bot bot commented Nov 13, 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 Nov 13, 2024
Copy link

melvin-bot bot commented Nov 13, 2024

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

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

Copy link

melvin-bot bot commented Nov 13, 2024

@jayeshmangwani @slafortune @jayeshmangwani 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 19, 2024
@jayeshmangwani
Copy link
Contributor

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: https://github.com/Expensify/App/pull/46511/files/0cff3d994e289bc54912dd94d2af620c97f5ac7c#r1825724163

  • [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: N/A

  • [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

Precondition:
Workspace is connected to QBO

  1. Navigate to Settings -> Workspaces -> Select any workspace connected to QBO -> Accounting
  2. Click Import
  3. Select Classes, then tap Displayed as.
  4. Choose Tags or Report fields
  5. Click back button twice to return to Accounting page
  6. Click back button again to return to workspace editor
  7. Click back button one more time and Verify that user return to workspaces list

Do we agree 👍 or 👎

@abekkala
Copy link
Contributor

Stevie is ooo - I'll process payment tomorrow:

PAYMENT SUMAMRY FOR NOV 20

@abekkala abekkala self-assigned this Nov 19, 2024
@abekkala
Copy link
Contributor

@FitseTLT payment sent and contract ended - thank you! 🎉

@garrettmknight
Copy link
Contributor

$250 approved for @jayeshmangwani

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 Engineering External Added to denote the issue can be worked on by a contributor
Projects
Development

No branches or pull requests

8 participants