Last modified: 2014-03-30 21:14:39 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 T33397, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 31397 - namespaces above ID 127 are not shown correctly in the log
namespaces above ID 127 are not shown correctly in the log
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
AbuseFilter (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: se4598
: schema-change
: 55564 60622 (view as bug list)
Depends on:
Blocks: 63261
  Show dependency treegraph
 
Reported: 2011-10-05 22:13 UTC by Patrick Westerhoff
Modified: 2014-03-30 21:14 UTC (History)
7 users (show)

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


Attachments

Description Patrick Westerhoff 2011-10-05 22:13:27 UTC
Hey,

I noticed a problem when AbuseFilter triggers on an edit that is performed on a custom namespace. The log shows an entry like this:

    <IP> triggered filter 8, performing the action "edit" on :Page title. Actions taken: […]

As you can see, the page is mentioned as “:Page title”, while the actual name is “Custom namespace:Page title”. Going to the details page for the log entry also shows that the namespace is correctly recognized within the action parameters, but the log entry is missing the namespace (and as such also produces an invalid link).

It works as expected with built-in namespaces, the problem just appeared for a custom namespace. Judging by the extension's source, I guess that there is some problem in recognizing the custom namespace, when the filter triggers. After all the log is just using the `afl_namespace` database field equally for all log entries.

As of now, I can neither take a look at the database to confirm the incorrect `afl_namespace` content, nor replicate this explicitely. I can however try to do this locally on a test wiki if required.
Comment 1 se4598 2014-01-30 17:24:36 UTC
Hey, if you still have this bug or a testcase, can you provide more information, e.g. on your used namespaces?

I'm especially interested in the ID (number) of the custom namespace.
Comment 2 Patrick Westerhoff 2014-01-30 18:25:25 UTC
Uh, well, that’s somewhat difficult after all this time :D

I did look through a few thousand filter log entries now but couldn’t find a recent example, so I don’t know if the issue still exists or not.

The namespace where this originally happened is `202`.
Comment 3 se4598 2014-01-30 19:08:42 UTC
ok thanks. I have tested it locally with two namespaces at ID 120 and ID 220. For the former it shows correctly in the log, the latter is displayed as described above.

The db shows that for this record the namespace is saved as 127 due the field only "tinyint" wide, which only supports values between -128 and 127, although mediawiki itself uses normal integers.
Comment 4 se4598 2014-01-30 19:11:21 UTC
*** Bug 60622 has been marked as a duplicate of this bug. ***
Comment 5 Gerrit Notification Bot 2014-02-02 20:49:12 UTC
Change 110881 had a related patch set uploaded by Se4598:
abuse_filter_log table only uses tinyint not int for namespace ID

https://gerrit.wikimedia.org/r/110881
Comment 6 Gerrit Notification Bot 2014-03-04 02:26:11 UTC
Change 110881 merged by jenkins-bot:
abuse_filter_log table only uses tinyint not int for namespace ID

https://gerrit.wikimedia.org/r/110881
Comment 7 se4598 2014-03-30 21:14:39 UTC
*** Bug 55564 has been marked as a duplicate of this bug. ***

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


Navigation
Links