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-09-12][Search v2.1] Workspace selected in workspace switcher resets to Expensify after switching status/tab #48240

Closed
6 tasks
IuliiaHerets opened this issue Aug 29, 2024 · 30 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

Comments

@IuliiaHerets
Copy link

IuliiaHerets commented Aug 29, 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.26-1
Reproducible in staging?: Y
Reproducible in production?: N
Email or phone of affected tester (no customers): applausetester+kh270803a@applause.expensifail.com
Issue reported by: Applause Internal Team

Action Performed:

Precondition:

  • Account has at least one workspace.
  1. Go to staging.new.expensify.com
  2. Go to Search.
  3. Open workspace switcher.
  4. Select a workspace.
  5. Go to different status.
  6. Note that the workspace switcher changes to Expensify.
  7. Open workspace switcher.
  8. Note that the selected workspace persists but the breadcrumbs show Expensify.
  9. Refresh Search page.
  10. Open workspace switcher and select another workspace.
  11. Go to different tab (Invoices or Trips).
  12. Note that the workspace switcher resets to Expensify.

Expected Result:

In Step 8 and 12, the workspace selected in the workspace switcher should persist.

Actual Result:

In Step 8 and 12, the workspace selected in the workspace switcher resets to Expensify after switching to another status or tab.

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

Bug6585836_1724894216386.20240829_091309.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @Kicu
@IuliiaHerets IuliiaHerets added DeployBlockerCash This issue or pull request should block deployment Bug Something is broken. Auto assigns a BugZero manager. labels Aug 29, 2024
Copy link

melvin-bot bot commented Aug 29, 2024

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

Copy link

melvin-bot bot commented Aug 29, 2024

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

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

@IuliiaHerets
Copy link
Author

We think that this bug might be related to #wave-control

@rayane-djouah
Copy link
Contributor

@Kicu - Could you please take a look at this blocker?

@rayane-djouah
Copy link
Contributor

"Workspace selected in workspace switcher resets to Expensify after switching tab (Type)" is intended

But I think that the "switching status" part is a bug

@daledah
Copy link
Contributor

daledah commented Aug 29, 2024

Proposal

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

In Step 8 and 12, the workspace selected in the workspace switcher resets to Expensify after switching to another status or tab.

What is the root cause of that problem?

Currently, when we click on a button in the status bar or in the search menu, we are not updating the activeWorkspaceID. Therefore, in the following line of code:

const activeWorkspaceID = getPolicyIDFromState(state as NavigationState<RootStackParamList>);

we are setting the activeWorkspaceID to undefined, which causes the issue described above.

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

We should update the activeWorkpsaceID using function navigateWithSwitchPolicyID as we did with switch workspace here.

    const {activeWorkspaceID} = useActiveWorkspace();
    Navigation.navigateWithSwitchPolicyID({policyID: activeWorkspaceID});

Add this in here and here

What alternative solutions did you explore? (Optional)

@Kicu
Copy link
Contributor

Kicu commented Aug 29, 2024

I believe it was agreed with @luacmartins that this:

Go to different tab

is not a bug, as our expectation is that clicking on a tab resets all filters, which should include resetting policyID in the switcher.
The bug is wrong state of switcher and I will provide a fix for it. Please assign me to this task

@luacmartins
Copy link
Contributor

Yea, this is not a bug (at least not yet) since we reset all filters when moving to different state/statuses.

@luacmartins luacmartins self-assigned this Aug 29, 2024
@luacmartins luacmartins removed the DeployBlockerCash This issue or pull request should block deployment label Aug 29, 2024
@lanitochka17
Copy link

The selected workspace in the workspace switcher list and the breadcrumbs don't match after the reset
Cannot select the same workspace even though it has a green checkmark.

20240830_010838.mp4

@lanitochka17 lanitochka17 reopened this Aug 29, 2024
@luacmartins luacmartins added Daily KSv2 and removed Hourly KSv2 labels Aug 29, 2024
@luacmartins
Copy link
Contributor

cc @Kicu ^

@luacmartins luacmartins assigned Kicu and unassigned madmax330 Aug 29, 2024
@Kicu
Copy link
Contributor

Kicu commented Aug 30, 2024

I'm working today on this specific bug that selected workspace doesn't match.

While it looks like a minor thing it is tightly connected to my policyID PR: #47787 and I treat it like a bug of how we pass policyID around between query, params and ws switcher.

Will be fixed

@luacmartins luacmartins changed the title Search-Workspace selected in workspace switcher resets to Expensify after switching status/tab [Search v2.1] Workspace selected in workspace switcher resets to Expensify after switching status/tab Aug 30, 2024
@anmurali anmurali added the Daily KSv2 label Sep 9, 2024
Copy link

melvin-bot bot commented Sep 12, 2024

Skipping the payment summary for this issue since all the assignees are employees or vendors. If this is incorrect, please manually add the payment summary SO.

@melvin-bot melvin-bot bot added the Overdue label Sep 12, 2024
@luacmartins
Copy link
Contributor

Payment due today

@melvin-bot melvin-bot bot added Daily KSv2 and removed Daily KSv2 Overdue labels Sep 13, 2024
Copy link

melvin-bot bot commented Sep 16, 2024

@Kicu, @anmurali, @luacmartins Whoops! This issue is 2 days overdue. Let's get this updated quick!

@melvin-bot melvin-bot bot added the Overdue label Sep 16, 2024
@luacmartins
Copy link
Contributor

Bump for payment @anmurali

Copy link

melvin-bot bot commented Sep 20, 2024

@Kicu, @anmurali, @luacmartins, @rayane-djouah Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@melvin-bot melvin-bot bot added the Overdue label Sep 20, 2024
@luacmartins
Copy link
Contributor

@anmurali Bump for payment

Copy link

melvin-bot bot commented Sep 24, 2024

@Kicu, @anmurali, @luacmartins, @rayane-djouah Still overdue 6 days?! Let's take care of this!

@anmurali
Copy link

Sent @rayane-djouah an offer here
@Kicu I need your upwork profile.

@anmurali anmurali added Daily KSv2 and removed Daily KSv2 Overdue labels Sep 25, 2024
@Kicu
Copy link
Contributor

Kicu commented Sep 25, 2024

@anmurali I work at SWM (expert agency) so no payment is required for me :)

Copy link

melvin-bot bot commented Sep 30, 2024

@Kicu, @anmurali, @luacmartins, @rayane-djouah Huh... This is 4 days overdue. Who can take care of this?

@melvin-bot melvin-bot bot added the Overdue label Sep 30, 2024
@luacmartins
Copy link
Contributor

Just pending payment to @rayane-djouah

Copy link

melvin-bot bot commented Oct 2, 2024

@Kicu, @anmurali, @luacmartins, @rayane-djouah 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

@rayane-djouah
Copy link
Contributor

@anmurali Kind bump

Copy link

melvin-bot bot commented Oct 4, 2024

@Kicu, @anmurali, @luacmartins, @rayane-djouah 8 days overdue is a lot. Should this be a Weekly issue? If so, feel free to change it!

@anmurali
Copy link

anmurali commented Oct 5, 2024

Done.

@anmurali anmurali closed this as completed Oct 5, 2024
@melvin-bot melvin-bot bot removed the Overdue label Oct 5, 2024
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
Projects
Status: Done
Development

No branches or pull requests

8 participants