Friday, June 21, 2013

Mediawiki User edits by Namespace

English: MediaWiki logo. Русский: Логотип Medi...
\
During work on Orwell01 I got to look through the code of X! counter tool on the WMF toolserver.

Mediawiki's API does not expose a method to get a user's edit counts per namespace. When I was chatting with some WMF developer at the Amsterdam Hackathon - I was told that this was not exposed since it was not stored in the database and had to be worked out in an application. And indeed there is a popular edit counter called X! edit counter maintained by User:TParis that does just this.

However this edit counter does not expose the namespace stats either in its undocumented API either.... Looking at the code I started to explore the database queries being done and found the following:

Enhanced by Zemanta