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-06-13] [$250] Does not show the chat room in the results when searching for the rooms user is a part of #40654

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

Comments

@m-natarajan
Copy link

m-natarajan commented Apr 21, 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: 1.4.63-11
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @coleaeason
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1713480493902799

Action Performed:

  1. Join any public room
  2. Search for the room using search icon

Expected Result:

Search results should display the result in which the user is a part of

Actual Result:

No results found error message appears
For @davidcardoza Shows the results for any room which are pinned

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

Recording.3009.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~015b0a0277b5ad4344
  • Upwork Job ID: 1782705413299757056
  • Last Price Increase: 2024-04-30
  • Automatic offers:
    • akinwale | Reviewer | 0
Issue OwnerCurrent Issue Owner: @anmurali
@m-natarajan m-natarajan added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Apr 21, 2024
Copy link

melvin-bot bot commented Apr 21, 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.

@saifelance
Copy link

@m-natarajan The current behaviour looks ok

@dragnoir
Copy link
Contributor

dragnoir commented Apr 21, 2024

Proposal

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

when searching for the rooms user is a part of, the room doesn't appear on the serach result

What is the root cause of that problem?

on ChatFinderPage, the useOptionsList does not turn the rooms where the user is invited to.

https://github.com/Expensify/App/blob/aa6e8c6182935acd79cc78356342f3cc61bbe6db/src/pages/ChatFinderPage/index.tsx#L59C46-L59C60

The two functions from OptionsListUtils used to create the optiosn list createOptionList and getOptions had this tine of code:

if (!accountIDs || accountIDs.length === 0) {
return;
}

The invited user to a public room is not allowed to check the list and details of the room users, where accountIDs.length === 0 is true.

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

We need to check if the report is a chat room if accountIDs.length === 0

update here and here to

if ((!accountIDs  ||  accountIDs.length  ===  0) &&  !isChatRoom) {
  return;
}

POC:

20240421_222833.mp4

We can discuss more throw the PR how to make sure it's an invited chat room report.

@saifelance
Copy link

@dragnoir

This issue stems from a condition in the createOptionList and getOptions functions in OptionsListUtils.ts.

To address this issue, you proposed modifying the condition to also check if the report is a chat room before returning if accountIDs.length === 0. Here's how you could implement this change:

if ((!accountIDs || accountIDs.length === 0) && !isChatRoom) { return; }

@saifelance
Copy link

@dragnoir Correct
users should indeed be able to search for and find public chat rooms that they have joined.

You can modify the condition to ensure that public chat rooms are included in the search results.

if ((!accountIDs || accountIDs.length === 0) && !isChatRoom && !isPublic) { return; }

By adding !isPublic to the condition, you ensure that public chat rooms are not excluded from the search results. This change allows users to search for and find public chat rooms they have joined.

@anmurali anmurali added the External Added to denote the issue can be worked on by a contributor label Apr 23, 2024
Copy link

melvin-bot bot commented Apr 23, 2024

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

@melvin-bot melvin-bot bot changed the title Does not show the chat room in the results when searching for the rooms user is a part of [$250] Does not show the chat room in the results when searching for the rooms user is a part of Apr 23, 2024
@melvin-bot melvin-bot bot added Overdue Help Wanted Apply this label when an issue is open to proposals by contributors labels Apr 23, 2024
Copy link

melvin-bot bot commented Apr 23, 2024

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

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Apr 23, 2024
Copy link

melvin-bot bot commented Apr 26, 2024

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

Copy link

melvin-bot bot commented Apr 30, 2024

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

Copy link

melvin-bot bot commented Apr 30, 2024

@akinwale, @anmurali Still overdue 6 days?! Let's take care of this!

@anmurali
Copy link

@akinwale have you had a chance to review proposals above?

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Apr 30, 2024
@davidcardoza
Copy link
Contributor

@anmurali should we find someone else to review proposals? It's been over a week now since there has been activity in this GH.

@akinwale
Copy link
Contributor

akinwale commented May 3, 2024

I missed the notifications on this one. Reviewing the proposal now.

@melvin-bot melvin-bot bot removed the Overdue label May 3, 2024
@akinwale
Copy link
Contributor

akinwale commented May 3, 2024

We can move forward with @dragnoir's proposal here.

@dragnoir You need to add another condition to check that the chat room is a public room, otherwise, the workspace rooms like #announce and #admins will show up in the search results, which I reckon we don't want.

🎀👀🎀 C+ reviewed.

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Daily KSv2 Overdue Weekly KSv2 labels May 8, 2024
@melvin-bot melvin-bot bot added Monthly KSv2 and removed Weekly KSv2 labels Jun 3, 2024
Copy link

melvin-bot bot commented Jun 3, 2024

This issue has not been updated in over 15 days. @akinwale, @dragnoir, @anmurali, @luacmartins eroding to Monthly issue.

P.S. Is everyone reading this sure this is really a near-term priority? Be brave: if you disagree, go ahead and close it out. If someone disagrees, they'll reopen it, and if they don't: one less thing to do!

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Monthly KSv2 labels Jun 6, 2024
@melvin-bot melvin-bot bot changed the title [$250] Does not show the chat room in the results when searching for the rooms user is a part of [HOLD for payment 2024-06-13] [$250] Does not show the chat room in the results when searching for the rooms user is a part of Jun 6, 2024
Copy link

melvin-bot bot commented Jun 6, 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 Jun 6, 2024
Copy link

melvin-bot bot commented Jun 6, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.79-11 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-06-13. 🎊

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

Copy link

melvin-bot bot commented Jun 6, 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:

  • [@akinwale] The PR that introduced the bug has been identified. Link to the PR:
  • [@akinwale] 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:
  • [@akinwale] 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:
  • [@akinwale] Determine if we should create a regression test for this bug.
  • [@akinwale] 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.
  • [@anmurali] 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 Jun 12, 2024
@akinwale
Copy link
Contributor

  • [@akinwale] The PR that introduced the bug has been identified. Link to the PR:
  • [@akinwale] 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:
  • [@akinwale] 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:

Not a regression.

  • [@akinwale] Determine if we should create a regression test for this bug.
  • [@akinwale] 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 Steps

  1. Launch the Expensify App.
  2. Join a new public chat room.
  3. Click or tap on the search icon and try to search for the chat room.
  4. Verify that the chat room appears in the search results.

Do we agree 👍 or 👎?

@akinwale
Copy link
Contributor

@anmurali bump for payment. Thanks.

Copy link

melvin-bot bot commented Jun 17, 2024

@akinwale, @dragnoir, @anmurali, @luacmartins Huh... This is 4 days overdue. Who can take care of this?

Copy link

melvin-bot bot commented Jun 19, 2024

@akinwale, @dragnoir, @anmurali, @luacmartins Still overdue 6 days?! Let's take care of this!

@anmurali
Copy link

@akinwale is paid
@dragnoir - offer is here

@melvin-bot melvin-bot bot added Overdue and removed Overdue labels Jun 21, 2024
Copy link

melvin-bot bot commented Jun 24, 2024

@akinwale, @dragnoir, @anmurali, @luacmartins Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

@anmurali
Copy link

Everyone is paid!

@melvin-bot melvin-bot bot removed the Overdue label Jun 26, 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 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