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

[$250] Split - Chat header shows split creator and split user avatar briefly when splitting expense #40904

Closed
6 tasks done
lanitochka17 opened this issue Apr 24, 2024 · 19 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Monthly KSv2 Reviewing Has a PR in review

Comments

@lanitochka17
Copy link

lanitochka17 commented Apr 24, 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.65-0
Reproducible in staging?: Y
Reproducible in production?: 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:

  1. Go to staging.new.expensify.com
  2. Go to FAB > Split expense
  3. Split expense with one user that has no chat history
  4. Note the avatar in chat header

Expected Result:

The chat header will show the split user avatar

Actual Result:

The chat header shows split creator and split user avatar briefly.

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

Bug6460097_1713955443502.20240424_183933.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~019386f7d8c4cc34c1
  • Upwork Job ID: 1785372503599595520
  • Last Price Increase: 2024-05-07
  • Automatic offers:
    • Pujan92 | Reviewer | 0
    • bernhardoj | Contributor | 0
@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Apr 24, 2024
Copy link

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

@lanitochka17
Copy link
Author

@anmurali FYI 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

@lanitochka17
Copy link
Author

We think that this bug might be related to #vip-split

@bernhardoj
Copy link
Contributor

Proposal

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

The report header avatar shows both user avatars when doing a split bill with a new user.

What is the root cause of that problem?

The avatar will show all participant avatars in a report.

return getIconsForParticipants(report?.participantAccountIDs ?? [], personalDetails);

When we create a new split with a new user, we optimistically create a new chat with a participant that contains both users.

const allParticipantsAccountIDs = [...participantAccountIDs, currentUserAccountID];

App/src/libs/actions/IOU.ts

Lines 3123 to 3124 in b0ec7b1

// Otherwise, create a new 1:1 chat report
const splitChatReport = ReportUtils.buildOptimisticChatReport(allParticipantsAccountIDs);

But if it's a DM, the participant will exclude the current user, so when the request is completed, BE returns the correct participant, and the correct avatar is shown.

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

For DM case, we should set the participant without the current user,

App/src/libs/actions/IOU.ts

Lines 3123 to 3124 in b0ec7b1

// Otherwise, create a new 1:1 chat report
const splitChatReport = ReportUtils.buildOptimisticChatReport(allParticipantsAccountIDs);

const splitChatReport = ReportUtils.buildOptimisticChatReport(participantAccountIDs);

@melvin-bot melvin-bot bot added the Overdue label Apr 26, 2024
Copy link

melvin-bot bot commented Apr 29, 2024

@anmurali Eep! 4 days overdue now. Issues have feelings too...

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

melvin-bot bot commented Apr 30, 2024

Job added to Upwork: https://www.upwork.com/jobs/~019386f7d8c4cc34c1

@melvin-bot melvin-bot bot changed the title Split - Chat header shows split creator and split user avatar briefly when splitting expense [$250] Split - Chat header shows split creator and split user avatar briefly when splitting expense Apr 30, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Apr 30, 2024
Copy link

melvin-bot bot commented Apr 30, 2024

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

@melvin-bot melvin-bot bot removed the Overdue label Apr 30, 2024
@Pujan92
Copy link
Contributor

Pujan92 commented May 2, 2024

@bernhardoj's proposal looks good which is suggested to pass participantAccountIDs instead of allParticipantsAccountIDs(contains currentUserID) for 1:1 case.

🎀👀🎀 C+ reviewed

Copy link

melvin-bot bot commented May 2, 2024

Triggered auto assignment to @madmax330, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot added the Overdue label May 6, 2024
@anmurali
Copy link

anmurali commented May 6, 2024

@madmax330 do you agree with this? Can I assign the issue to @bernhardoj

@melvin-bot melvin-bot bot removed the Overdue label May 6, 2024
Copy link

melvin-bot bot commented May 7, 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 May 8, 2024

@madmax330 @anmurali @Pujan92 this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

@melvin-bot melvin-bot bot added the Overdue label May 9, 2024
@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label May 10, 2024
Copy link

melvin-bot bot commented May 10, 2024

📣 @Pujan92 🎉 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 May 10, 2024

📣 @bernhardoj 🎉 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 removed the Overdue label May 10, 2024
@bernhardoj
Copy link
Contributor

PR is ready

cc: @Pujan92

@melvin-bot melvin-bot bot removed the Weekly KSv2 label Jun 3, 2024
Copy link

melvin-bot bot commented Jun 3, 2024

This issue has not been updated in over 15 days. @madmax330, @anmurali, @Pujan92, @bernhardoj 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 the Monthly KSv2 label Jun 3, 2024
@bernhardoj
Copy link
Contributor

The PR is merged. I think it's ready for payment @anmurali.

@Pujan92
Copy link
Contributor

Pujan92 commented Jun 14, 2024

Bump @anmurali for the payment!

@anmurali
Copy link

Paid everyone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Monthly KSv2 Reviewing Has a PR in review
Projects
None yet
Development

No branches or pull requests

5 participants