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-05-09] [$250] Group chat - Chat header does not follow chat name in LHN after removing all group members #41076

Closed
4 of 6 tasks
izarutskaya opened this issue Apr 26, 2024 · 17 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Weekly KSv2

Comments

@izarutskaya
Copy link

izarutskaya commented Apr 26, 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.66-2
Reproducible in staging?: Y
Reproducible in production?: Y
Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to FAB > Start chat.
  3. Create a group chat.
  4. Click on group chat header.
  5. Go to Members.
  6. Remove all the members.
  7. Return to main chat.

Expected Result:

The chat header name will follow the chat name in LHN.

Actual Result:

The chat header name shows the group creator's name only, while LHN shows "User's group chat".

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

Bug6462517_1714114012791.bandicam_2024-04-26_14-39-01-102.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01529d302503f7e16a
  • Upwork Job ID: 1785001052675362816
  • Last Price Increase: 2024-04-29
  • Automatic offers:
    • s77rt | Reviewer | 0
    • Nodebrute | Contributor | 0
Issue OwnerCurrent Issue Owner: @puneetlath
@izarutskaya izarutskaya added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Apr 26, 2024
Copy link

melvin-bot bot commented Apr 26, 2024

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

@izarutskaya
Copy link
Author

We think this issue might be related to the #vip-vsb.

@dragnoir
Copy link
Contributor

Proposal

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

Chat header does not follow chat name in LHN after removing all group members

What is the root cause of that problem?

On HeaderView we use displayNamesWithTooltips for the header text where it returns the partyicipants names

const displayNamesWithTooltips = ReportUtils.getDisplayNamesWithTooltips(participantPersonalDetails, isMultipleParticipant, undefined, isSelfDM);

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

We need to add a new const

const  isSingleParticipantGroupChat  =  isGroupChat  &&  participants.length  ===  1;

Then update DisplayNames

<DisplayNames
  fullTitle={title}
- displayNamesWithTooltips
+ displayNamesWithTooltips={displayNamesWithTooltips}
  tooltipEnabled={!isSingleParticipantGroupChat}
  numberOfLines={1}
  textStyles={[styles.headerText, styles.pre]}
- shouldUseFullTitle={isChatRoom || isPolicyExpenseChat || isChatThread || isTaskReport || shouldUseGroupTitle}
+ shouldUseFullTitle={isChatRoom || isPolicyExpenseChat || isChatThread || isTaskReport || shouldUseGroupTitle || isSingleParticipantGroupChat}
  renderAdditionalText={renderAdditionalText}
/>

POC:

image

@shahinyan11
Copy link
Contributor

shahinyan11 commented Apr 26, 2024

Proposal

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

Group chat - Chat header does not follow chat name in LHN after removing all group members

What is the root cause of that problem?

It becomes from changes in this PR but I do not think it is regress. Here we pass shouldUseFullTitle which controls displaying fullTitle or displayNamesWithTooltips ( participant names with tooltips )

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

Here need to understand correct behavior, should tooltip be displayed when hovering over group member name if there is only one member ?

If No - Update this condition as follows isGroupChat && (!!report?.reportName || !isMultipleParticipant);

If Yes - Add below code here

if(isGroupChat && !isMultipleParticipant){
    displayNamesWithTooltips[0].displayName = title
}

What alternative solutions did you explore? (Optional)

@melvin-bot melvin-bot bot added the Overdue label Apr 29, 2024
@puneetlath puneetlath added the External Added to denote the issue can be worked on by a contributor label Apr 29, 2024
@melvin-bot melvin-bot bot changed the title Group chat - Chat header does not follow chat name in LHN after removing all group members [$250] Group chat - Chat header does not follow chat name in LHN after removing all group members Apr 29, 2024
Copy link

melvin-bot bot commented Apr 29, 2024

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

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

melvin-bot bot commented Apr 29, 2024

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

@melvin-bot melvin-bot bot removed the Overdue label Apr 29, 2024
@s77rt
Copy link
Contributor

s77rt commented Apr 29, 2024

Thanks for the proposals @dragnoir and @shahinyan11. Since. this is a regression from #40528 and it's still within the regression period @Nodebrute should handle this.

@Nodebrute Can you please comment so you can be assigned

@Nodebrute
Copy link
Contributor

@s77rt Yes. Assign this issue to me.

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

melvin-bot bot commented Apr 29, 2024

📣 @s77rt 🎉 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

Copy link

melvin-bot bot commented Apr 29, 2024

📣 @Nodebrute 🎉 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 Apr 30, 2024
@Nodebrute
Copy link
Contributor

@s77rt The pr is ready for review.

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels May 2, 2024
@melvin-bot melvin-bot bot changed the title [$250] Group chat - Chat header does not follow chat name in LHN after removing all group members [HOLD for payment 2024-05-09] [$250] Group chat - Chat header does not follow chat name in LHN after removing all group members May 2, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label May 2, 2024
Copy link

melvin-bot bot commented May 2, 2024

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

Copy link

melvin-bot bot commented May 2, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.69-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 2024-05-09. 🎊

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

Copy link

melvin-bot bot commented May 2, 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:

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

@s77rt
Copy link
Contributor

s77rt commented May 6, 2024

  • The PR that introduced the bug has been identified: enable tooltip for group title #40528
  • The offending PR has been commented on: Not needed (same author raised the fix)
  • A discussion in #expensify-bugs has been started: Not needed (unique bug)
  • Determine if we should create a regression test for this bug: No

@s77rt
Copy link
Contributor

s77rt commented May 6, 2024

This can be closed since it was a regression

@puneetlath
Copy link
Contributor

Great, thanks @s77rt

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. External Added to denote the issue can be worked on by a contributor Weekly KSv2
Projects
None yet
Development

No branches or pull requests

6 participants