Page MenuHomePhabricator

pagetriagelist API does not list any pages
Open, Needs TriagePublic

Description

For my script I would like to retrieve a random new page, as seen on https://en.wikipedia.org/wiki/Special:NewPagesFeed.

But https://en.wikipedia.org/w/api.php?action=pagetriagelist&limit=10&namespace=0 -- this URL is provided by the API documentation page as an example, except I edited the limit from 1000 to 10 -- is empty. It is not expected to be empty, it is expected to be able to show results from the over 14,000 new pages list.

(I don't know what tag to put here. Put none, alas, so far.)

Event Timeline

Gryllida created this task.Dec 25 2016, 8:33 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptDec 25 2016, 8:33 PM
Restricted Application added a project: Collaboration-Team-Triage. · View Herald TranscriptDec 25 2016, 9:59 PM

this URL is provided by the API documentation page as an example

Link very welcome.

Hi,

this URL is provided by the API documentation page as an example

Link very welcome.

Thanks for asking. Please see some copy-pasted information below...

To quote https://en.wikipedia.org/w/api.php?action=help&modules=pagetriagelist,

"Example:

List 1000 pages in namespace 0

api.php?action=pagetriagelist&limit=1000&namespace=0"...

The example output:

{

"warnings": {
    "pagetriagelist": {
        "*": "\"limit\" may not be over 200 (set to 1000) for users."
    }
},
"pagetriagelist": {
    "result": "success",
    "pages": []
}

}

Now I alter it and try api.php?action=pagetriagelist&limit=100&namespace=0:

{

"pagetriagelist": {
    "result": "success",
    "pages": []
}

}

Catrope added a subscriber: Catrope.Jan 3 2017, 6:55 PM

This API is weird and the example is bad: you need to either pass &showreviewed=1 or &showunreviewed=1 (or both).

This is obviously not best practice design for an api.php module. I'll at least fix the examples and then see if this module is used anywhere and if we can make the default parameters saner.

Change 330266 had a related patch set uploaded (by Catrope):
ApiPageTriageList: Better document parameter weirdness

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

Change 330266 merged by jenkins-bot:
ApiPageTriageList: Better document parameter weirdness

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

Restricted Application added a project: Growth-Team. · View Herald TranscriptSat, Oct 12, 4:11 AM