Page MenuHomePhabricator

Good faith filter group not UNIONing properly
Closed, ResolvedPublic

Description

For https://en.wikipedia.beta.wmflabs.org/wiki/Special:RecentChanges?goodfaith=maybebadfaith I see results.

For https://en.wikipedia.beta.wmflabs.org/wiki/Special:RecentChanges?goodfaith=good%3Bmaybebadfaith ('good' OR 'maybebadfaith'), I don't.

That's not correct, since it's supposed to be a UNION within a group.

Event Timeline

Restricted Application added a project: Collaboration-Team-Triage. · View Herald TranscriptMar 15 2017, 4:02 AM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Mattflaschen-WMF removed Mattflaschen-WMF as the assignee of this task.

I see results with those 2 URLs but looking at the code, I would add parenthesis around the condition in this line to be extra sure the priority is executed correctly.

I'm not sure >makeList( $betweenConditions, \IDatabase::LIST_OR ); does it in all cases.

SBisson triaged this task as High priority.Mar 16 2017, 4:59 PM

I see results with those 2 URLs but looking at the code, I would add parenthesis around the condition in this line to be extra sure the priority is executed correctly.
I'm not sure >makeList( $betweenConditions, \IDatabase::LIST_OR ); does it in all cases.

It doesn't seem to be the problem but there's definitely something wrong here.

I see results with those 2 URLs but looking at the code, I would add parenthesis around the condition in this line to be extra sure the priority is executed correctly.
I'm not sure >makeList( $betweenConditions, \IDatabase::LIST_OR ); does it in all cases.

If anyone can't reproduce, make sure you're logged in and have ORES enabled.

Otherwise, the ORES filters don't apply. (I accidentally wasn't logged in yesterday, that's why I kept changing the URLs, but it is reproducible with either version of the URLs if I'm logged in with ORES).

From analyzing the queries, it looks like maybebadfaith is ignored completely (probably because I renamed it from maybebad). Doing just ?goodfaith=maybebadfaith results in no WHERE clause on the score at all, whereas ?goodfaith=good,maybebadfaith and ?goodfaith=good result in the same query. This suggests maybebadfaith is ignored.

Change 343185 had a related patch set uploaded (by Catrope):
[mediawiki/extensions/ORES] Follow-up 4a892c8fb: also apply maybebadfaith hack in queryCallable

https://gerrit.wikimedia.org/r/343185

Change 343185 merged by jenkins-bot:
[mediawiki/extensions/ORES] Follow-up 4a892c8fb: also apply maybebadfaith hack in queryCallable

https://gerrit.wikimedia.org/r/343185

This should be fixed now, but observe that "Likely good faith" + "Maybe bad faith" = everything. This is because "Likely good faith" is defined as score> 0.234 and "Maybe bad faith" is defined as score < 0.371. Because the lower bound for "good" is below the upper bound for "maybebad", all changes are either "good" or "maybebad", and some changes are both.

Checked on enwiki (WMF.17) - UNION is implemented - any combination of 'good faith' filters returns results.

QA Recommendation: Resolve

jmatazzoni closed this task as Resolved.Mar 23 2017, 11:55 PM
jmatazzoni claimed this task.