hub: the outside-ask request predicate once in request_sql (one Python rule, two SQL copies that already differ on active)
tsk-dd1epavb0306 Proposed
Audit round 6 (tsk-hgnbapyw7hnh), read at 046a4d3b. Kind: duplication (a rule built three times, the copies differ).
What is wrong
- "This request is an outside ask" is written three times, each docstring saying a change here is a change there:
inbox.outside_ask(inbox.py:171-198), Python.events._outside_requests(events.py:791-822), SQL.notifications/listing._open_personal(notifications/listing.py:126-151), SQL.- The listing copy also requires
m.active; the other two do not. An ask from an inactive outside membership is counted under the loose bucket of the bell, not under the project entry, while events and inbox treat it as the project. request_sqlwas created as the one SQL copy of request rules (asked,in_own_right), but this rule is not in it.
Proposal
- One
request_sql.outside_ask(request_cols, membership_cols)clause used by events and listing, twin-tested againstinbox.outside_ask; decide theactiveterm once.
Effort / risk: S. Low; the bell bucket for an inactive outside membership is the only visible change.