Last modified: 2013-10-08 08:44:26 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T53294, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 51294 - Condition limit is broken: consumes 100,000+ conditions limit is set to 1000
Condition limit is broken: consumes 100,000+ conditions limit is set to 1000
Status: NEW
Product: MediaWiki extensions
Classification: Unclassified
AbuseFilter (Other open bugs)
unspecified
All All
: High normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-13 16:14 UTC by Helder
Modified: 2013-10-08 08:44 UTC (History)
8 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Helder 2013-07-13 16:14:50 UTC
For a extreme example, consider this filter:
https://en.wikipedia.org/wiki/Special:AbuseFilter/473

How can it consumes 23296 conditions if the condition limit is set to 1000?

Why does that value changes every second?
(reloading the page a few times I got: 51172, then 3986, then 7859, 14690, and so on...)

This is very confusing for users trying to debug and optimize the existing filters...
Comment 1 Helder 2013-07-13 16:19:02 UTC
I don't know if this is a problem, but I noticed the function getFilterProfile uses three keys: 
wfMemcKey( 'abusefilter', 'profile', $filter, 'count' );
wfMemcKey( 'abusefilter', 'profile', $filter, 'total' );
wfMemcKey( 'abusefilter', 'profile-conds', 'total' );

But the resetFilterProfile only resets the first two. Shouldn't it also reset the key profile-conds?

[1] https://git.wikimedia.org/blob/mediawiki%2Fextensions%2FAbuseFilter.git/HEAD/AbuseFilter.class.php#L535
Comment 3 Andre Klapper 2013-07-15 11:16:25 UTC
(In reply to comment #0)
> For a extreme example, consider this filter:
> https://en.wikipedia.org/wiki/Special:AbuseFilter/473
> 
> How can it consumes 23296 conditions if the condition limit is set to 1000?

Where exactly can I see that (position in the UI)?
Comment 4 Helder 2013-07-15 11:48:31 UTC
There is a line like this:
---------------------------------------------------------------------------
Statistics: Of the last 147 actions, this filter has matched 4 (2.72%). On average, its run time is 1.77 ms, and it consumes 13,105 conditions of the condition limit.
---------------------------------------------------------------------------
(the text comes from [[MediaWiki:abusefilter-edit-status]])
Comment 5 Helder 2013-07-15 13:02:13 UTC
It really doesn't known what a "limit" is: I just saw it saying filter 473 consumes 112,686 conditions (!)
Comment 6 Jesús Martínez Novo (Ciencia Al Poder) 2013-08-16 13:13:42 UTC
See also:
https://www.mediawiki.org/wiki/Extension:AbuseFilter/Rules_format#Conditions

(added and documented by Helder)

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links