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-08-19] [$250] Track - Self-DM chat appears briefly when track expense from FAB #46674

Closed
1 of 6 tasks
lanitochka17 opened this issue Aug 1, 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 External Added to denote the issue can be worked on by a contributor

Comments

@lanitochka17
Copy link

lanitochka17 commented Aug 1, 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.15-1
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Issue reported by: Applause - Internal Team

Action Performed:

  1. Go to FAB> Track expense> Finish the flow
  2. Go to self-DM chat> Select Do nothing from actionable whispers
  3. Open any other chat
  4. Go back to FAB> Track Expense

Expected Result:

Self-DM chat should not appears when select option to track expense

Actual Result:

Self-DM chat appears briefly when track expense from FAB even other chat was open before this action

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

Bug6558934_1722496514437.Recording__3629.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0184fba06192689bb7
  • Upwork Job ID: 1819379087245531554
  • Last Price Increase: 2024-08-02
  • Automatic offers:
    • c3024 | Reviewer | 103403398
Issue OwnerCurrent Issue Owner: @isabelastisser / @isabelastisser
@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Aug 1, 2024
Copy link

melvin-bot bot commented Aug 1, 2024

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

We think that this bug might be related to #vip-vsp

@lanitochka17
Copy link
Author

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

@OfstadC
Copy link
Contributor

OfstadC commented Aug 1, 2024

Didn't get to this today. Reassigning as i'm out tomorrow and Monday. Happy to take back on Tuesday if no forward movement before then

@OfstadC OfstadC removed the Bug Something is broken. Auto assigns a BugZero manager. label Aug 1, 2024
@OfstadC OfstadC removed their assignment Aug 1, 2024
@OfstadC OfstadC added the Bug Something is broken. Auto assigns a BugZero manager. label Aug 1, 2024
Copy link

melvin-bot bot commented Aug 1, 2024

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

@bernhardoj
Copy link
Contributor

Proposal

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

The self DM shows briefly when open track expense.

What is the root cause of that problem?

The self DM shows because the matching route here for the track expense page is the self DM report.

let matchingRootRoute = getMatchingRootRouteForRHPRoute(focusedRHPRoute);

It checks the screen params and if reportID is found and valid, then the report is returned.

const reportID = (route.params as Record<string, string | undefined>)?.reportID;
if (ReportConnection.getAllReports()?.[`${ONYXKEYS.COLLECTION.REPORT}${reportID}`]) {
return {name: SCREENS.REPORT, params: {reportID}};
}

Track expense page reportID params is the self DM reportID. Because the matching route is found, we push it to the adapted routes,

if (matchingRootRoute && (!isNarrowLayout || !isRHPScreenOpenedFromLHN)) {
routes.push(matchingRootRoute);
}

which will be later used if isCentralPaneAndBottomTabMandatory or isFullScreenNavigatorMandatory is true, which is true in our case.

const {adaptedState, metainfo} = getAdaptedStateFromPath(path, linkingConfig.config);
if (adaptedState && (metainfo.isCentralPaneAndBottomTabMandatory || metainfo.isFullScreenNavigatorMandatory)) {
const diff = getPartialStateDiff(rootState, adaptedState as State<RootStackParamList>, metainfo);
const diffActions = getActionsFromPartialDiff(diff);
for (const diffAction of diffActions) {
root.dispatch(diffAction);
}
}

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

We can include the money request screen in RHP_SCREENS_OPENED_FROM_LHN list so it won't be added to the stack when navigating to the money request page, including track expense.

const isRHPScreenOpenedFromLHN = focusedRHPRoute?.name && RHP_SCREENS_OPENED_FROM_LHN.includes(focusedRHPRoute?.name as RHPScreenOpenedFromLHN);
// This may happen if this RHP doens't have a route that should be under the overlay defined.
if (!matchingRootRoute || isRHPScreenOpenedFromLHN) {
metainfo.isCentralPaneAndBottomTabMandatory = false;
metainfo.isFullScreenNavigatorMandatory = false;

if (matchingRootRoute && (!isNarrowLayout || !isRHPScreenOpenedFromLHN)) {
routes.push(matchingRootRoute);
}

const RHP_SCREENS_OPENED_FROM_LHN = [SCREENS.MONEY_REQUEST.CREATE, ...];

Copy link
Contributor

github-actions bot commented Aug 2, 2024

true

@isabelastisser
Copy link
Contributor

#vip-vsb status.

@isabelastisser isabelastisser added External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors labels Aug 2, 2024
Copy link

melvin-bot bot commented Aug 2, 2024

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

@melvin-bot melvin-bot bot changed the title Track - Self-DM chat appears briefly when track expense from FAB [$250] Track - Self-DM chat appears briefly when track expense from FAB Aug 2, 2024
Copy link

melvin-bot bot commented Aug 2, 2024

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

@c3024
Copy link
Contributor

c3024 commented Aug 4, 2024

@bernhardoj 's proposal here LGTM!

🎀 👀 🎀 C+ Reviewed

Copy link

melvin-bot bot commented Aug 4, 2024

Triggered auto assignment to @puneetlath, 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 Aug 5, 2024
Copy link

melvin-bot bot commented Aug 5, 2024

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

Offer link
Upwork job

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Daily KSv2 labels Aug 6, 2024
@bernhardoj
Copy link
Contributor

PR is ready

cc: @c3024

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Aug 12, 2024
@melvin-bot melvin-bot bot changed the title [$250] Track - Self-DM chat appears briefly when track expense from FAB [HOLD for payment 2024-08-19] [$250] Track - Self-DM chat appears briefly when track expense from FAB Aug 12, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Aug 12, 2024
Copy link

melvin-bot bot commented Aug 12, 2024

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

Copy link

melvin-bot bot commented Aug 12, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.18-10 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-08-19. 🎊

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

Copy link

melvin-bot bot commented Aug 12, 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:

  • [@c3024] The PR that introduced the bug has been identified. Link to the PR:
  • [@c3024] 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:
  • [@c3024] 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:
  • [@c3024] Determine if we should create a regression test for this bug.
  • [@c3024] 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.
  • [@isabelastisser] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:

@melvin-bot melvin-bot bot added Daily KSv2 Overdue and removed Weekly KSv2 labels Aug 18, 2024
@c3024 c3024 mentioned this issue Aug 19, 2024
49 tasks
@c3024
Copy link
Contributor

c3024 commented Aug 19, 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:

  • [@c3024] The PR that introduced the bug has been identified. Link to the PR: Ideal nav v2 workspaces #37421
  • [@c3024] 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/37421/files#r1721237982
  • [@c3024] 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: I don't think this bug could not have been identified earlier so no discussion was started.
  • [@c3024] Determine if we should create a regression test for this bug. Yes
  • [@c3024] 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.

Regression Test Proposal

  1. Press FAB > Track Expense
  2. Press Back
  3. Verify that the self-DM page does not appear

@melvin-bot melvin-bot bot removed the Overdue label Aug 19, 2024
@isabelastisser
Copy link
Contributor

@puneetlath do you agree with the regression test proposal?

@bernhardoj
Copy link
Contributor

Requested in ND.

@isabelastisser
Copy link
Contributor

Payment summary:

$250 to @c3024 for C+ review. Paid in Upwork.
$250 to @bernhardoj for proposal. Requested in ND, PENDING.

@isabelastisser
Copy link
Contributor

All set!

@JmillsExpensify
Copy link

$250 approved for @bernhardoj

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
No open projects
Archived in project
Development

No branches or pull requests

7 participants