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-04-15] [HOLD for payment 2024-04-09] Group chat - Group chat avatar leads to not here page #39249

Closed
6 tasks done
izarutskaya opened this issue Mar 29, 2024 · 22 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

@izarutskaya
Copy link

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.58-0
Reproducible in staging?: Y
Reproducible in production?: N
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. Tap on the group chat header.
  5. Tap on the group chat avatar.

Expected Result:

Group chat avatar opens in full screen view without issue.

Actual Result:

Group chat avatar leads to not here page.

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

Bug6431593_1711719921836.group_chat_avatar.mp4

View all open jobs on GitHub

@izarutskaya izarutskaya added DeployBlockerCash This issue or pull request should block deployment Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Mar 29, 2024
Copy link

melvin-bot bot commented Mar 29, 2024

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

Copy link

melvin-bot bot commented Mar 29, 2024

Triggered auto assignment to @adelekennedy (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels Mar 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.

@izarutskaya
Copy link
Author

@adelekennedy 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.

@izarutskaya
Copy link
Author

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

@izarutskaya
Copy link
Author

Production
image (5)

@marcaaron marcaaron assigned marcaaron and unassigned blimpich Mar 29, 2024
@marcaaron
Copy link
Contributor

@blimpich grabbing this from ya since it's related to Group Chats.

@gijoe0295
Copy link
Contributor

gijoe0295 commented Mar 29, 2024

We set the icon.id as -1 here. Later when we navigated to ProfileAvatar page here, as the id was -1, we cannot find the corresponding avatar.

I think we should use ReportAvatar page for group avatar here.

if (icon.type === CONST.ICON_TYPE_WORKSPACE || icon.id === -1) {
    Navigation.navigate(ROUTES.REPORT_AVATAR.getRoute(reportID));
    return;
}

Then add specific logic for handling group avatar in ReportAvatar.

const isGroupChat = ReportUtils.isGroupChat(report);
const avatarURL = useMemo(() => (isGroupChat ? ReportUtils.getDefaultGroupAvatar(report?.reportID) : ReportUtils.getWorkspaceAvatar(report)), [report]);

Also set isWorkspaceAvatar={!isGroupChat} so we won't have a color background.

@marcaaron
Copy link
Contributor

Thanks - that first link doesn't seem to go anywhere.

@gijoe0295
Copy link
Contributor

I'm sorry. Just updated the correct reference.

@marcaaron
Copy link
Contributor

We will soon modify this to allow adding a custom avatar. So, I think it would be ok to just disable opening an avatar for a Group Chat.

icon.id === -1 is pretty confusing. How about something like this:

diff --git a/src/components/RoomHeaderAvatars.tsx b/src/components/RoomHeaderAvatars.tsx
index 9298062aa6..ee75f91d58 100644
--- a/src/components/RoomHeaderAvatars.tsx
+++ b/src/components/RoomHeaderAvatars.tsx
@@ -15,8 +15,12 @@ type RoomHeaderAvatarsProps = {
     reportID: string;
 };

-function RoomHeaderAvatars({icons, reportID}: RoomHeaderAvatarsProps) {
+function RoomHeaderAvatars({icons, reportID, isGroupChat}: RoomHeaderAvatarsProps) {
     const navigateToAvatarPage = (icon: Icon) => {
+        if (isGroupChat) {
+            return;
+        }
+
         if (icon.type === CONST.ICON_TYPE_WORKSPACE) {
             Navigation.navigate(ROUTES.REPORT_AVATAR.getRoute(reportID));
             return;
diff --git a/src/pages/ReportDetailsPage.tsx b/src/pages/ReportDetailsPage.tsx
index 80563fcf7b..ccfe329419 100644
--- a/src/pages/ReportDetailsPage.tsx
+++ b/src/pages/ReportDetailsPage.tsx
@@ -218,6 +218,7 @@ function ReportDetailsPage({policies, report, session, personalDetails}: ReportD
                                 <RoomHeaderAvatars
                                     icons={icons}
                                     reportID={report?.reportID}
+                                    isGroupChat={ReportUtils.isGroupChat(report)}
                                 />
                             )}
                         </View>

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Hourly KSv2 labels Mar 29, 2024
@marcaaron
Copy link
Contributor

QA re-testing now

@kavimuru
Copy link

kavimuru commented Apr 1, 2024

This is a pass. Tapping the avatar does not navigate to anywhere.

39249.mp4

@marcaaron marcaaron removed the DeployBlockerCash This issue or pull request should block deployment label Apr 1, 2024
@melvin-bot melvin-bot bot removed the Weekly KSv2 label Apr 2, 2024
@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production labels Apr 2, 2024
@melvin-bot melvin-bot bot changed the title Group chat - Group chat avatar leads to not here page [HOLD for payment 2024-04-09] Group chat - Group chat avatar leads to not here page Apr 2, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Apr 2, 2024
Copy link

melvin-bot bot commented Apr 2, 2024

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

Copy link

melvin-bot bot commented Apr 2, 2024

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

Copy link

melvin-bot bot commented Apr 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:

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

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Apr 8, 2024
@melvin-bot melvin-bot bot changed the title [HOLD for payment 2024-04-09] Group chat - Group chat avatar leads to not here page [HOLD for payment 2024-04-15] [HOLD for payment 2024-04-09] Group chat - Group chat avatar leads to not here page Apr 8, 2024
Copy link

melvin-bot bot commented Apr 8, 2024

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

Copy link

melvin-bot bot commented Apr 8, 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:

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

@marcaaron what payment is due here? It looks like there are two connected PRs both reviewed by @s77rt - is the only payment due for the C+ PR reviews?

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

s77rt commented Apr 12, 2024

No payment is due here. This is a part of a #32317

@s77rt
Copy link
Contributor

s77rt commented Apr 12, 2024

  • The PR that introduced the bug has been identified: Create Group Chats + Splits. #37458
  • The offending PR has been commented on: Not needed. Author and Reviewer were tagged on the PR fixing this
  • A discussion in #expensify-bugs has been started: n/a
  • Determine if we should create a regression test for this bug: No

@s77rt
Copy link
Contributor

s77rt commented Apr 12, 2024

Let's close this

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
None yet
Development

No branches or pull requests

7 participants