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-06-06] [$500] Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments #37688

Closed
6 tasks done
jasperhuangg opened this issue Mar 4, 2024 · 69 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Daily KSv2 External Added to denote the issue can be worked on by a contributor NewFeature Something to build that is a new item.

Comments

@jasperhuangg
Copy link
Contributor

jasperhuangg commented Mar 4, 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!


Action Performed:

Open NewDot as a user who has been blocked from chat. You can use a test account and flag a message as assault sent from another test account. In the message sent from the other test account, say something like "This is a test message from an Expensify contributor! Please flag me as assault and block me."

Expected Result:

You should be entirely blocked from chatting i.e. the compose box should be replaced with the component below
Screenshot 2024-03-04 at 10 01 59 AM

Actual Result:

The user can input into the compose box, but sending a message yields an API error.

Workaround:

Yes

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
Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01d4da9c062fd01064
  • Upwork Job ID: 1767797318852526080
  • Last Price Increase: 2024-03-13
  • Automatic offers:
    • shubham1206agra | Reviewer | 0
Issue OwnerCurrent Issue Owner: @sakluger / @anmurali
@jasperhuangg jasperhuangg added Daily KSv2 NewFeature Something to build that is a new item. labels Mar 4, 2024
Copy link

melvin-bot bot commented Mar 4, 2024

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Daily KSv2 labels Mar 4, 2024
@nkdengineer
Copy link
Contributor

nkdengineer commented Mar 4, 2024

I would be delighted to contribute to it if it's open for collaboration.

Proposal

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

  • Feature request: Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments

What is the root cause of that problem?

  • No need RCA because it is feature request

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

  • Below are the main steps to handle this feature:
  1. Create a new onyxkey: PRIVATE_BLOCKED_FROM_CHAT: privateBlockedFromChat to store the value

  2. Subscribe this key in here

  3. Create a new component BlockedReportFooter to display the blocked view: "Note: You have been banned from ..." - similar to ArchivedReportFooter

  4. Then, update this to:

    const hideComposer = !ReportUtils.canUserPerformWriteAction(props.report) || privateBlockedFromChat
  1. Then, add the below to this:
    {privateBlockedFromChat && <BlockedReportFooter report={props.report} />}

What alternative solutions did you explore? (Optional)

  • Also, we need to consider the case, PRIVATE_BLOCKED_FROM_CHAT appears for each report instead of all reports as we did in main solution

@melvin-bot melvin-bot bot added the Overdue label Mar 12, 2024
@sakluger
Copy link
Contributor

I'm adding the external label and adding this to VIP-VSB.

@melvin-bot melvin-bot bot removed the Overdue label Mar 13, 2024
@sakluger sakluger added the External Added to denote the issue can be worked on by a contributor label Mar 13, 2024
@melvin-bot melvin-bot bot changed the title Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments [$500] Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments Mar 13, 2024
Copy link

melvin-bot bot commented Mar 13, 2024

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

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

melvin-bot bot commented Mar 13, 2024

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

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Mar 13, 2024
@sakluger
Copy link
Contributor

Hi @shubham1206agra, what do you think of the existing proposal for this issue?

@shubham1206agra
Copy link
Contributor

@nkdengineer's proposal looks good to me.

🎀 👀 🎀 C+ Reviewed

Copy link

melvin-bot bot commented Mar 15, 2024

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

@luacmartins
Copy link
Contributor

Proposal looks good, but we should name the key nvp_privateBlockedFromChat

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

melvin-bot bot commented Mar 15, 2024

📣 @shubham1206agra 🎉 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 Mar 15, 2024

📣 @nkdengineer You have been assigned to this job!
Please apply to the Upwork job and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
Once you apply to this job, your Upwork ID will be stored and you will be automatically hired for future jobs!
Keep in mind: Code of Conduct | Contributing 📖

@nkdengineer
Copy link
Contributor

nkdengineer commented Mar 18, 2024

Does anyone know how to create a account that has nvp_privateBlockedFromChat: true?

@nkdengineer
Copy link
Contributor

I am checking it

@sakluger
Copy link
Contributor

@anmurali I'm going OOO again for two weeks (until May 31). I don't think you'll need to do much while I'm gone, but it ends up getting completed, and payment is due, could you please help with payments? I'll take back over if it's still open when I return.

@nkdengineer
Copy link
Contributor

@jasperhuangg I followed your step here. The conversation link is https://dev.new.expensify.com:8082/r/1520828873841856. And the user A who sent a flagged message is nkdengineer+210@outlook.com. That flagged message is This is a test message from an Expensify contributor! Please flag me as assault and block me. What is the next step here? Thanks

@nkdengineer
Copy link
Contributor

@jasperhuangg Please help check my comment here when you have a chance.

@jasperhuangg
Copy link
Contributor Author

@nkdengineer Sorry was OOO, I just blocked you via our Concierge tool. You should be able to get the NVP set in your Onyx store if you try to add a comment to any report with nkdengineer+210@outlook.com

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Weekly KSv2 labels May 27, 2024
@nkdengineer
Copy link
Contributor

Thanks, @jasperhuangg, now I can test the issue. @shubham1206agra PR #38571 is ready

@shubham1206agra
Copy link
Contributor

@jasperhuangg Please block the user work.sa1206+pr37688@gmail.com.

@jasperhuangg
Copy link
Contributor Author

@shubham1206agra I've blocked that email address, let me know if you need anything else.

@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 30, 2024
@melvin-bot melvin-bot bot changed the title [$500] Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments [HOLD for payment 2024-06-06] [$500] Access the PRIVATE_BLOCKED_FROM_CHAT NVP to block the UI for adding comments May 30, 2024
@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label May 30, 2024
Copy link

melvin-bot bot commented May 30, 2024

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

Copy link

melvin-bot bot commented May 30, 2024

The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.77-11 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-06-06. 🎊

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

Copy link

melvin-bot bot commented May 30, 2024

BugZero Checklist: The PR adding this new feature has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  • [@shubham1206agra] Please propose regression test steps to ensure the new feature will work correctly on production in further releases.
  • [@sakluger / @anmurali] Link the GH issue for creating/updating the regression test once above steps have been agreed upon.

@anmurali
Copy link

anmurali commented Jun 4, 2024

4 down, 3 more to go before payment is due.

@sakluger
Copy link
Contributor

sakluger commented Jun 5, 2024

@shubham1206agra I see a comment that says we sent you an automatic offer but I can't find one. Did we send you an Upwork offer for this issue? If not I can send one. Also, could you please complete the BZ checklist?

@anmurali I'm unassigning you since I'm back now.

@melvin-bot melvin-bot bot added Daily KSv2 and removed Weekly KSv2 labels Jun 6, 2024
@sakluger
Copy link
Contributor

sakluger commented Jun 6, 2024

I didn't hear back so I sent a new offer. Here are the offers:

Contributor: @nkdengineer $500, sent offer via Upwork (offer)
Contributor+: @shubham1206agra $500, sent offer via Upwork (offer)

@shubham1206agra
Copy link
Contributor

BugZero Checklist: The PR adding this new feature has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:

  1. Login with an account that is blocked by internal team
  2. Open any report. Verify that text "Note: You have been banned from communicating in this channel" is displayed and the composer is not displayed.
  • [@sakluger / @anmurali] Link the GH issue for creating/updating the regression test once above steps have been agreed upon.

@nkdengineer
Copy link
Contributor

@sakluger Thanks, I accepted the offer

@sakluger
Copy link
Contributor

sakluger commented Jun 7, 2024

Thanks! All paid out.

@sakluger sakluger closed this as completed Jun 7, 2024
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 Daily KSv2 External Added to denote the issue can be worked on by a contributor NewFeature Something to build that is a new item.
Projects
No open projects
Development

No branches or pull requests

7 participants