Enable policy->action selection in reviewer tools, for negative policies#24918
Enable policy->action selection in reviewer tools, for negative policies#24918eviljeff wants to merge 1 commit into
Conversation
429f10f to
27b41f1
Compare
|
|
||
| @library.global_function | ||
| @jinja2.pass_context | ||
| def toggle_when_action(context, definition_key, *, default=False): |
There was a problem hiding this comment.
I added this because I was bored of constructing extra action_xxx lists each time we needed to toggle on something in a single place. It didn't scale well.
27b41f1 to
d00d898
Compare
|
Mmm, this needs more work - I overlooked that the reject_version action, that it replaces, still has some logic to clear needshumanreview we don't do in ContentActionRejectVersion. We either need to add in some special casing in the It's something that's going to trip up the expansion to multiple versions and non-negative enforcment actions too - that even after we implemented reviewer tools using ContentAction there's still some logic that is reviewer tools specific that stayed. |
I think it would make sense to migrate that logic over to |
|
Note to myself: waffle switch for this PR is called |
better naming welcome |
Fixes mozilla/addons#16122
Description
Support policy selections directly in reviewer tools, which create decisions based on the enforcement actions of the policies selected. In this (first) patch, only some reviewer tool actions are replaced (reject latest version, and disable addon)
Context
Follow-up pieces for this:
Testing
Checklist
#ISSUENUMat the top of your PR to an existing open issue in the mozilla/addons repository.