Magic word to output article count of remote wikis
Closed, ResolvedPublic


Author: artslave

Would it be possible to have subdomain-specific article count variables? Something along
the lines of {{en:NUMBEROFARTICLES}}, or {{NUMBEROFARTICLES{{1}}}}, where a language code
could be entered as a parameter?

It would be a bonus if the user could specify a level of precision to which the number
could be rounded.

This would be very useful on the portal, and probably several other Meta
and Foundation pages which are currently manually updated and always behind.

Version: unspecified
Severity: enhancement


Unknown Object (Diffusion Commit)
bzimport set Reference to bz1534.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Feb 15 2005, 1:05 AM
  • Bug 1564 has been marked as a duplicate of this bug. ***
mxn added a comment.Mar 5 2006, 11:48 PM

For the Wikipedia portal, it would be more helpful to use the level of precision
to truncate the article count, rather than to round it. Also, Catherine's second
syntax proposal might be better written {{NUMBEROFARTICLES|{{1}}}} (with a pipe
in there).

It's really difficult to integrate, as the databases are distinct, and there's no SQL setup configured in
all projects to reach the statistics tables of each project. The only thing that exists is a table that maps
projet codes or interwiki prefixes to URLs.

What would be needed is that every project generate their own basic statistic dumps into a common statistics
database which could be reached from all projects. But they would need to refresh those dumps regularly to
this extra database. Having them updating instantly a centralization database would have a serious
performance impact on all wiki projects due to the extra synchronization needed. But may be it could be a
background thread that runs periodically to update the external database.

Such background database update task could be used to export other things, like the list of blocked vandals
or spammers, and to automatically import from every project.

But is it needed in the MediaWiki software itself? Can't that be performed by a bot? How many projects such
bot will need to update? and with which frequency (don't forget that each bot update will add to the history
of each project, so it could generate rapidly huge volums of transactions if it runs on all current 229

So may be an extra connection to a central statistics database, running as a thread of the MediaWiki server
will be better, avoiding too many update transactions into lots of projects, and unnecessary logs into an
article for the imported data.

artslave wrote:

A bot is probably actually the best solution for this (there weren't many around
when I first proposed this). The stats don't need to be kept in a database,
really -- any wiki page would do.

On poking around, it looks like User:Mutante was working on a script to do this
as of March -- see and for details.

mxn added a comment.Jul 21 2009, 5:51 AM
  • Bug 7911 has been marked as a duplicate of this bug. ***

chinchi29 wrote:

This function exists in template:NUMBEROF ( which is updated trough bot.

[mass-moving wikistats reports from Wikimedia→Statistics to Analytics→Wikistats to have stats issues under one Bugzilla product (see bug 42088) - sorry for the bugspam!]

mxn added a subscriber: mxn.Nov 24 2014, 8:58 PM
epriestley closed this task as "Resolved" by committing Unknown Object (Diffusion Commit).Mar 4 2015, 8:22 AM
Aklapper reopened this task as "Open".Mar 4 2015, 10:19 PM
Aklapper added a subscriber: Aklapper.
Nemo_bis changed the title from "Language-specific article count variables" to "Magic word to output article count of remote wikis".Dec 5 2015, 3:15 PM
Nemo_bis set Security to None.
Nemo_bis added a subscriber: Nemo_bis.

I believe this is a WORKSFORME: Mxn created Module:Project_portal, which can be used to output the article count of any Wikimedia wiki (via the on-wiki lists which are updated by bots).

Nemo_bis closed this task as "Resolved".Dec 5 2015, 3:17 PM
Nemo_bis assigned this task to mxn.
Meno25 removed a subscriber: Meno25.Dec 22 2015, 4:09 AM

Add Comment