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 2023-08-14] [HOLD for payment 2023-08-07] [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace #22359

Closed
6 tasks done
kbecciv opened this issue Jul 6, 2023 · 43 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

@kbecciv
Copy link

kbecciv commented Jul 6, 2023

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


Action Performed:

  1. Create a workspace and go to invite members page
  2. Paste an invalid number like "+916541237890" inside the search field and select it
  3. Click next > invite
  4. Go back to LHN and observe there is a RBR on it
  5. Click on avatar > follow the RBR and click on workspace > members

Expected Result:

There should be a way to remove the RBR from avatar and settings

Actual Result:

There is no way to remove RBR from settings after inviting an invalid member into a workspace

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android / native
  • Android / Chrome
  • iOS / native
  • iOS / Safari
  • MacOS / Chrome / Safari
  • MacOS / Desktop

Version Number: 1.3.37-2
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
Notes/Photos/Videos: Any additional supporting documentation

2023-07-06.10.59.08.mp4
Recording.3460.mp4

Expensify/Expensify Issue URL:
Issue reported by: @Nathan-Mulugeta
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1688630661683609

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~012f84973149e5c0ce
  • Upwork Job ID: 1678916595916169216
  • Last Price Increase: 2023-07-18
@kbecciv kbecciv added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Jul 6, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jul 6, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Jul 6, 2023

Bug0 Triage Checklist (Main S/O)

  • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

@Nodebrute
Copy link
Contributor

Nodebrute commented Jul 6, 2023

Proposal

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

Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace

What is the root cause of that problem?

even when api returns an error still that member is included in policy members and obviously it shows an error for this
Screenshot 2023-07-07 at 1 27 13 AM
Looks like we are intentionally adding members with errors....and removing the error in OfflineWithFeedBack but OfflineWithFeedback's on close method never gets triggered hence these errors are not getting dismisses
Screenshot 2023-07-07 at 2 06 06 AM

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

Solution 1
we should not add members in policy members object if api returns an error while adding them,
Solution 2
We can set there errors to null

I don't get the point of keeping that invalid entry in policy members list. We can again add it multiple times. This is the same invalid entry that I have added multiple times.
Screenshot 2023-07-07 at 2 10 50 AM

What alternative solutions did you explore? (Optional)

@Christinadobrzyn
Copy link
Contributor

Christinadobrzyn commented Jul 6, 2023

might be related to - #20961 (comment) asking

@Nathan-Mulugeta
Copy link

Just as an info, this issue was introduced on this week's latest release, I think #20961 was reported 20 days ago. This issue was not there then.

@Christinadobrzyn
Copy link
Contributor

Ah okay, thank you @Nathan-Mulugeta! It does sound like it might be separate then but I'll wait to confirm with @PauloGasparSv. Thanks!

@melvin-bot melvin-bot bot added the Overdue label Jul 10, 2023
@Christinadobrzyn
Copy link
Contributor

watching for an update #20961 (comment)

@melvin-bot melvin-bot bot removed the Overdue label Jul 10, 2023
@Christinadobrzyn
Copy link
Contributor

Not related to #20961 (comment) - moving forward with treating this separately!

I can reproduce but I'm not sure how we want to remove the RBR - any suggestions @Nathan-Mulugeta

@Christinadobrzyn Christinadobrzyn added the External Added to denote the issue can be worked on by a contributor label Jul 11, 2023
@melvin-bot melvin-bot bot changed the title Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace Jul 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jul 11, 2023

Job added to Upwork: https://www.upwork.com/jobs/~012f84973149e5c0ce

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Jul 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jul 11, 2023

Current assignee @Christinadobrzyn is eligible for the External assigner, not assigning anyone new.

@melvin-bot
Copy link

melvin-bot bot commented Jul 11, 2023

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

@tienifr
Copy link
Contributor

tienifr commented Jul 12, 2023

Proposal

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

There is no way to remove RBR from settings after inviting an invalid member into a workspace

What is the root cause of that problem?

When the API for adding members return an error, we're currently not showing the errored member in the workspace member list due to this line https://github.com/Expensify/App/blob/a3404b1df7bfbe5c45eef594f9e0578d07abff13/src/pages/workspace/WorkspaceMembersPage.js#L371C5-L371C5.
We don't have the member info in personalDetails so it doesn't show, therefore the user cannot see the error and can not dismiss it by closing the error in OfflineWithoutFeedback.

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

We need to optimistically add the member details (with login) to personalDetails when we add a member to the workspace.
In successData, we'll clear the above member details since it has the dummy ID, and the back-end already returns correct accountID in personalDetails for that member.

What alternative solutions did you explore? (Optional)

  1. There's another issue where when adding members while offline, the member will not show in the member list, this will be fixed by the above change as well.

If somehow we don't want to optimistically add the member to personalDetails, we can add the login to the policyMember record when we create the error, and modify the logic in the member list here to still show that member which is not in personalDetails but has error.

  1. If we don't care about the member will not show in the member list while offline, we can add the new members to personalDetails in failureData instead of optimisticData to avoid flicker.

@Christinadobrzyn Christinadobrzyn removed the Daily KSv2 label Jul 14, 2023
@Christinadobrzyn Christinadobrzyn removed their assignment Jul 14, 2023
@Christinadobrzyn Christinadobrzyn added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Jul 14, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jul 14, 2023

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

@melvin-bot

This comment was marked as outdated.

@melvin-bot melvin-bot bot changed the title [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace [HOLD for payment 2023-08-07] [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace Jul 31, 2023
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Jul 31, 2023
@melvin-bot
Copy link

melvin-bot bot commented Jul 31, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Jul 31, 2023

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.47-6 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 2023-08-07. 🎊

After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.

  • External issue reporter
  • Contributor that fixed the issue
  • Contributor+ that helped on the issue and/or PR

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

As a reminder, here are the bonuses/penalties that should be applied for any External issue:

  • Merged PR within 3 business days of assignment - 50% bonus
  • Merged PR more than 9 business days after assignment - 50% penalty

@melvin-bot

This comment was marked as outdated.

@JmillsExpensify
Copy link

@eVoloshchak Can you get us kicked off with the BZ checklist?

@Christinadobrzyn
Copy link
Contributor

Back from ooo! Thanks for handling this @JmillsExpensify - I'm happy to take it off your plate!

@melvin-bot melvin-bot bot added Daily KSv2 Weekly KSv2 and removed Weekly KSv2 Daily KSv2 labels Aug 6, 2023
@melvin-bot melvin-bot bot changed the title [HOLD for payment 2023-08-07] [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace [HOLD for payment 2023-08-14] [HOLD for payment 2023-08-07] [$1000] Invite Member - No way to remove RBR from avatar after inviting an invalid number into a workspace Aug 7, 2023
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Aug 7, 2023
@melvin-bot
Copy link

melvin-bot bot commented Aug 7, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Aug 7, 2023

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.50-3 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 2023-08-14. 🎊

After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.

  • External issue reporter
  • Contributor that fixed the issue
  • Contributor+ that helped on the issue and/or PR

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

As a reminder, here are the bonuses/penalties that should be applied for any External issue:

  • Merged PR within 3 business days of assignment - 50% bonus
  • Merged PR more than 9 business days after assignment - 50% penalty

@melvin-bot
Copy link

melvin-bot bot commented Aug 7, 2023

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:

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

@JmillsExpensify
Copy link

@eVoloshchak If you wouldn't mind kicking off the BZ checklist above in the next week, thank you!

@Christinadobrzyn

This comment was marked as outdated.

@eVoloshchak
Copy link
Contributor

@Christinadobrzyn, this has introduced a regression (#23947), so no urgency bonus, and the bounty should be reduced 50%

@eVoloshchak
Copy link
Contributor

eVoloshchak commented Aug 14, 2023

  • The PR that introduced the bug has been identified. Link to the PR: I'm unable to pinpoint the exact PR that has introduced this, this is how it was implemented initially (judging by the code)
  • 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: N/A
  • 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: I don't think there is an additional discussion needed, this is an edge case that was missed, it can be reproduced only with an invalid number, we have a section in the reviewer checklist that covers this: added steps to cover failure scenarios
  • Determine if we should create a regression test for this bug.
    Is it easy to test for this bug? Yes
    Is the bug related to an important user flow? Yes
    Is it an impactful bug? I'd argue it is, having an error indicator always enabled with no ability to dismiss it isn't good

@eVoloshchak
Copy link
Contributor

Regression Test Proposal

  1. Create a workspace and go to invite members page
  2. Paste an invalid number like "+916541237890" inside the search field and select it
  3. Click next > invite
  4. Verify that there's an error indicator (RBR) for the newly invited account
  5. Verify that you can dismiss the error by pressing a close button

Do we agree 👍 or 👎

@Christinadobrzyn
Copy link
Contributor

Christinadobrzyn commented Aug 18, 2023

looks like the regression (#23947) is resolved and the payment date should have been 8/16.

I don't know why this didn't revert to a daily for payment but paying this now!

Payouts due after regression based on #22359 (comment)

Issue Reporter: $250 @Nathan-Mulugeta PAID in Upwork
Contributor: $500 @tienifr PAID in Upwork
Contributor+: $500 @eVoloshchak - please submit your request

Eligible for 50% #urgency bonus? No - because of regression

Upwork job is here.
Internal job posting - https://www.upwork.com/ab/applicants/1678916595916169216/job-details

Regression test posted here - https://github.com/Expensify/Expensify/issues/309337
Closing Upwork and this GH as complete

@tienifr
Copy link
Contributor

tienifr commented Aug 19, 2023

@Christinadobrzyn I believe the contributor's penalty due to regression should not be applied for this issue. The change to introduce contributor's penalty for regression is introduced in Jul 28, thus will only affect contracts from that date onwards. While this issue was assigned (and contract started) on Jul 20.

@tienifr
Copy link
Contributor

tienifr commented Aug 29, 2023

@Christinadobrzyn could you please take a look at the above comment? Thanks!

@Christinadobrzyn
Copy link
Contributor

Christinadobrzyn commented Sep 14, 2023

It looks like the penalty is based on this comment - #22359 (comment)

We announced the regression penalty on July 27th. The regression related to this issue was found on July 31st so I believe the penalty would apply here as this regression was after the announcement.

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

8 participants