You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2025-03-10] [$250] Android - Workspace - Missing workspace with "Requested" label after joining workspace #53081
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor
Version Number: 9.0.66-3 Reproducible in staging?: Y Reproducible in production?: Y If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: 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:
Launch New Expensify app
[User A] Go to workspace settings > Profile > Share
[User A] Click Copy URL
[User A] Send the invite link to User B
[User B] Open the workspace invite link
Expected Result:
Workspace list will show the joined workspace with a "Requested" label.
Actual Result:
Workspace list does not show the joined workspace with a "Requested" label after opening workspace invite link
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 evidenceBug6643451_1729699239013.1729698540172_Screen_Recording_20241023_234720.mp4
Please re-state the problem that we are trying to solve in this issue.
There is no pending requested workspace shown when trying to join the workspace by link.
What is the root cause of that problem?
This happens if we previously use a workspace join link. For example, if we use workspace A join link then use workspace B join link, then workspace B join link won't work. It all happens because if at least a join link is used once, then we ignore any other incoming link.
It was added to fix an issue where the invite by link API request is triggered multiple times. I can't seem to repro it anymore even after removing the fix, but it probably happened before because the useEffect depends on the whole policy collection.
What changes do you think we should make in order to solve the problem?
We have 2 options to solve it. We want the invite API request to only happen once, but it's possible that the policy onyx data isn't ready yet (especially when we migrate to useOnyx), which could give us a wrong result for the if here.
@slafortune this isn't a dupe of #52394. #52394 is a navigation issue where the workspace list page doesn't open, whereas this issue is that the join request isn't sent to the BE if we use a workspace join link (different link) for the 2nd time.
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.7-2 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
@eh2077@slafortune@eh2077 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]
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 (eg. bug slipped through the normal regression and PR testing process on staging)
2b. Reported on staging (eg. found during regression or PR testing)
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.
[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: NA
[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.
[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:
NA
Test:
As User B:
Have at least 2 workspaces
Copy each workspace share link
As User A:
Open any chat and paste both workspace share links
Open each link
Verify that each link will request to join the workspace
You will be navigated to the workspace list page and a new workspace with Requested badge is shown
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor
Activity
melvin-bot commentedon Nov 25, 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.Shahidullah-Muffakir commentedon Nov 25, 2024
Already tracked under #52394
bernhardoj commentedon Nov 26, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue.
There is no pending requested workspace shown when trying to join the workspace by link.
What is the root cause of that problem?
This happens if we previously use a workspace join link. For example, if we use workspace A join link then use workspace B join link, then workspace B join link won't work. It all happens because if at least a join link is used once, then we ignore any other incoming link.
App/src/pages/workspace/WorkspaceJoinUserPage.tsx
Lines 35 to 45 in 2ce0764
App/src/pages/workspace/WorkspaceJoinUserPage.tsx
Line 27 in 2ce0764
It was added to fix an issue where the invite by link API request is triggered multiple times. I can't seem to repro it anymore even after removing the fix, but it probably happened before because the
useEffectdepends on the whole policy collection.What changes do you think we should make in order to solve the problem?
We have 2 options to solve it. We want the invite API request to only happen once, but it's possible that the
policyonyx data isn't ready yet (especially when we migrate to useOnyx), which could give us a wrong result for theifhere.App/src/pages/workspace/WorkspaceJoinUserPage.tsx
Lines 46 to 52 in 2ce0764
Assuming we migrate to useOnyx
we can replace all the dependencies here with
isPolicyLoading.App/src/pages/workspace/WorkspaceJoinUserPage.tsx
Line 61 in 2ce0764
Then, in the
useEffect, ifisPolicyLoadingis true, then we return early. Then we can remove theisJoinLinkUsed.The 2nd option is to convert
isJoinLinkUsedinto a ref.melvin-bot commentedon Nov 29, 2024
@slafortune Whoops! This issue is 2 days overdue. Let's get this updated quick!
melvin-bot commentedon Dec 3, 2024
@slafortune 6 days overdue. This is scarier than being forced to listen to Vogon poetry!
slafortune commentedon Dec 3, 2024
Closing this as a duplicate
bernhardoj commentedon Dec 4, 2024
@slafortune this isn't a dupe of #52394. #52394 is a navigation issue where the workspace list page doesn't open, whereas this issue is that the join request isn't sent to the BE if we use a workspace join link (different link) for the 2nd time.
bernhardoj commentedon Dec 10, 2024
@slafortune hi, can you recheck this one, please?
bernhardoj commentedon Dec 18, 2024
@slafortune bump ^
28 remaining items
melvin-bot commentedon Mar 3, 2025
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Mar 3, 2025
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.7-2 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 2025-03-10. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Mar 3, 2025
@eh2077 @slafortune @eh2077 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 commentedon Mar 10, 2025
Payment Summary
Upwork Job
BugZero Checklist (@slafortune)
slafortune commentedon Mar 10, 2025
@eh2077 can you please complete the checklist?
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[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 👎
eh2077 commentedon Mar 10, 2025
BugZero Checklist:
Bug classification
Source of bug:
Where bug was reported:
Who reported the bug:
[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/37525/files#r1988148533
[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: NA
[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.
[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:
NA
Test:
As User B:
As User A:
Do we agree 👍 or 👎
eh2077 commentedon Mar 10, 2025
@slafortune Thanks for the reminder. Done
bernhardoj commentedon Mar 11, 2025
Requested in ND.
slafortune commentedon Mar 11, 2025
Reviewer: Role Contributor @bernhardoj owed $250 via NewDot
Reviewer: Role C+ @eh2077 owed $250 via NewDot
JmillsExpensify commentedon Mar 12, 2025
$250 approved for @bernhardoj
JmillsExpensify commentedon Mar 17, 2025
$250 approved for @eh2077