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

Add forward to legal option in reviewer tools #22886

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

eviljeff
Copy link
Member

@eviljeff eviljeff commented Nov 22, 2024

Fixes: mozilla/addons#15078

Description

Adds a Request legal action in the reviewer tools. Under the hood the activity log is attached to DECISION_ACTIONS.AMO_LEGAL_FORWARD, which has an associated ContentAction class with a process action that resolves the job (if there was one); then creates a new job in the legal escalations queue.

image

Context

There's some TODOs that will be resolved with future refactoring, as it's the first reviewer-tools-launched-action where the process_action in the ContentActionXXX needs to do something. (currently all the actions from the reviewer tools do the necessary action in reviewers/utils.py first)

Testing

  • Make sure you have your CINDER_API defined
  • In the reviewer tools choose an add-on (any state where you could make any changes should do) and choose Forward to Legal. Fill in some notes and submit.
  • In Cinder look in the Legal Escalations queue and see a report for that add-on, with your notes as the report reasoning
  • (resolve the job for a clean slate)
  • Report the add-on for abuse in the add-on, for a policy violation reason, to allow the job to be created in the reviewer tools
  • In the reviewer tools go back to the review page for the add-on (it should be in the review queue if you have the relevant waffle switches enabled, but that's not important)
  • Choose Forward to Legal, but this time select the open job too, then write some notes and submit.
  • In Cinder look in the Legal Escalations queue and see a report for that add-on, with your notes as the report reasoning
  • resolve the job in cinder.
  • (if you resolved the job with a policy that lead to disable; and replayed that decision webhook payload from Cinder back in your local env, it should disable the add-on and send an email to the reporter of the abuse reports, as if the legal escalation hadn't gotten in the middle. Testing that is possibly out of scope for this change though, because all of that is existing functionality)

Checklist

  • Add #ISSUENUM at the top of your PR to an existing open issue in the mozilla/addons repository.
  • Successfully verified the change locally.
  • The change is covered by automated tests, or otherwise indicated why doing so is unnecessary/impossible.
  • Add before and after screenshots (Only for changes that impact the UI).
  • Add or update relevant docs reflecting the changes made.

@eviljeff eviljeff marked this pull request as ready for review November 22, 2024 18:49
@eviljeff eviljeff requested review from a team and KevinMind and removed request for a team November 22, 2024 18:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Task]: Implement forward/escalation to legal queue in Cinder from reviewer tools
1 participant