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

[PAUSED][$250] Web - Unable to create a split expense with a large number of room members #42562

Closed
1 of 6 tasks
lanitochka17 opened this issue May 23, 2024 · 32 comments
Closed
1 of 6 tasks
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors Monthly KSv2

Comments

@lanitochka17
Copy link

lanitochka17 commented May 23, 2024

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number: 1.4.75-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

Issue found when executing PR #41077

Action Performed:

  1. Log in with a new expensifail account
  2. Create a workspace
  3. Create a room
  4. Invite 30 expensifail users
  5. Navigate to the room
  6. Create a manual split expense with a large number
  7. Set the priority to "Most recent"
  8. Open any of the created chats from the LHN

Expected Result:

I should be able to create the split expense without any errors

Actual Result:

Unable to create a split expense with a large number of room members with a new account. For the new chats I get "Unexpected error creating this chat, please try again later." error. For the split in the room, I get "Unexpected error submitting this expense. Please try again later." error
I also get a "Failed to load resource: the server responded with a status of 403 ()" console error

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

Bug6489845_1716495220190.bandicam_2024-05-23_22-06-06-473.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01cb679b7ebce4149e
  • Upwork Job ID: 1798422926054946284
  • Last Price Increase: 2024-07-31
Issue OwnerCurrent Issue Owner: @sobitneupane
@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels May 23, 2024
Copy link

melvin-bot bot commented May 23, 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.

@lanitochka17
Copy link
Author

@slafortune 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

@slafortune
Copy link
Contributor

on vacation until June 4th - reassigning this.

@slafortune slafortune removed the Bug Something is broken. Auto assigns a BugZero manager. label May 23, 2024
@slafortune slafortune removed their assignment May 23, 2024
@slafortune slafortune added the Bug Something is broken. Auto assigns a BugZero manager. label May 23, 2024
Copy link

melvin-bot bot commented May 23, 2024

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

@slafortune
Copy link
Contributor

Sounds like I'll readd myself to this as well and take it back on the 4th. I didn't add myself back to any that have been assigned where I was unable to look at them at all.

Hey @slafortune , as an fyi for OOO re-assignments, you're supposed to add an additional assignee, but stay assigned so you can take the issue back over once you're back from OOO (assuming it's still open). Here's the relevant SO where the process is outlined.

I'm going to re-add you to the issue, but happy to tackle it while you're OOO!

@slafortune slafortune self-assigned this May 23, 2024
@nkdengineer
Copy link
Contributor

Proposal

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

Unable to create a split expense with a large number of room members with a new account. For the new chats I get "Unexpected error creating this chat, please try again later." error. For the split in the room, I get "Unexpected error submitting this expense. Please try again later." error
I also get a "Failed to load resource: the server responded with a status of 403 ()" console error

What is the root cause of that problem?

When we invite new user to the room, report?. participants still contains optimistic accountID and then when we create a split expense, we set the participants incorrectly here which makes SplitBill API fails

App/src/libs/actions/IOU.ts

Lines 6511 to 6514 in 8375abe

const chatReportOtherParticipants = Object.keys(chatReport?.participants ?? {})
.map(Number)
.filter((accountID) => accountID !== currentUserAccountID);
participants = chatReportOtherParticipants.map((accountID) => ({accountID, selected: true}));

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

We should use the same way as we do to get the member in RoomMembersPage here to get the correct participants of the report

const chatReportOtherParticipants = ReportUtils.getVisibleChatMemberAccountIDs(report?.reportID ?? '0').flatMap((accountID) => {
    const pendingMember = report?.pendingChatMembers?.findLast((member) => member.accountID === accountID.toString());
    return !pendingMember || pendingMember.pendingAction !== CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE ? accountID : [];
});

App/src/libs/actions/IOU.ts

Lines 6511 to 6514 in 8375abe

const chatReportOtherParticipants = Object.keys(chatReport?.participants ?? {})
.map(Number)
.filter((accountID) => accountID !== currentUserAccountID);
participants = chatReportOtherParticipants.map((accountID) => ({accountID, selected: true}));

What alternative solutions did you explore? (Optional)

NA

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

melvin-bot bot commented May 27, 2024

@slafortune, @zanyrenney Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!

Copy link

melvin-bot bot commented May 31, 2024

@slafortune, @zanyrenney Still overdue 6 days?! Let's take care of this!

Copy link

melvin-bot bot commented Jun 4, 2024

@slafortune, @zanyrenney 10 days overdue. Is anyone even seeing these? Hello?

@slafortune
Copy link
Contributor

Looks like we were both out - sorry for the delay!

@melvin-bot melvin-bot bot removed the Overdue label Jun 5, 2024
@slafortune slafortune added External Added to denote the issue can be worked on by a contributor Overdue labels Jun 5, 2024
@melvin-bot melvin-bot bot changed the title Web - Unable to create a split expense with a large number of room members [$250] Web - Unable to create a split expense with a large number of room members Jun 5, 2024
Copy link

melvin-bot bot commented Jun 5, 2024

Job added to Upwork: https://www.upwork.com/jobs/~01cb679b7ebce4149e

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

melvin-bot bot commented Jun 5, 2024

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

Copy link

melvin-bot bot commented Jun 6, 2024

@slafortune @sobitneupane 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!

@sobitneupane
Copy link
Contributor

Thanks for the proposal @nkdengineer

So, the issue arises if there is any new member(no previous interaction) in the room, right?

Actions Performed should be:

  1. Log in
  2. Create a workspace
  3. Create a room
  4. Invite a user with whom you have no previous interaction
  5. Navigate to the room
  6. Create a manual split expense
  7. Open any of the created chats from the LHN

@nkdengineer
Copy link
Contributor

@sobitneupane Yes, to easier to reproduce this bug we can offline when we invite the member to the room (or invite member quickly before we get the personal detail of user when we search to invite) and online to do the next step that you mentioned above.

@saracouto saracouto added Monthly KSv2 and removed Daily KSv2 labels Jun 7, 2024
@sobitneupane
Copy link
Contributor

@saracouto @slafortune Should I hold the proposal review for now? The status of the issue is Paused and priority is monthly.

@nkdengineer
Copy link
Contributor

@saracouto Why we add Monthly label here?

Copy link

melvin-bot bot commented Jun 12, 2024

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

@slafortune
Copy link
Contributor

Since we are not actively working on VIP split right now, things related are paused. Rather than closing all the GH's, they are being updated to Monthly so Melvin doesn't get too obnoxious! Once this is in focus again, it will move from Monthly to Daily, and the priority will be updated at that time as well. Probably best to focus on anything that isn't monthly/paused.

Copy link

melvin-bot bot commented Jun 19, 2024

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

@slafortune slafortune changed the title [$250] Web - Unable to create a split expense with a large number of room members [PAUSED][$250] Web - Unable to create a split expense with a large number of room members Jun 19, 2024
Copy link

melvin-bot bot commented Jun 20, 2024

@slafortune @sobitneupane this issue is now 4 weeks old, please consider:

  • Finding a contributor to fix the bug
  • Closing the issue if BZ has been unable to add the issue to a VIP or Wave project
  • If you have any questions, don't hesitate to start a discussion in #expensify-open-source

Thanks!

Copy link

melvin-bot bot commented Jun 26, 2024

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

2 similar comments
Copy link

melvin-bot bot commented Jul 3, 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 Jul 10, 2024

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

@slafortune
Copy link
Contributor

still paused

@melvin-bot melvin-bot bot added the Overdue label Jul 11, 2024
@sobitneupane
Copy link
Contributor

#42562 (comment)

@melvin-bot melvin-bot bot removed the Overdue label Jul 12, 2024
Copy link

melvin-bot bot commented Jul 17, 2024

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

@mvtglobally
Copy link

Issue not reproducible during KI retests. (First week)

Copy link

melvin-bot bot commented Jul 24, 2024

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

1 similar comment
Copy link

melvin-bot bot commented Jul 31, 2024

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

@slafortune
Copy link
Contributor

Paused and not recreated in the last test - let's close this!

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 Help Wanted Apply this label when an issue is open to proposals by contributors Monthly KSv2
Projects
None yet
Development

No branches or pull requests

7 participants