During follow-up to T436001: Dolly Parton High load we wanted to identify high-traffic pages at risk of a similar incident. The machine-readable list=configuredpages API was not available on enwiki, even though Special:StablePages (which was available) reports nearly the same thing in human-readable form.
This has been a long-standing quirk: configuredpages has been registered only when $wgFlaggedRevsProtection is off since it was added in 2011. Protection-based wikis such as enwiki got Special:StablePages but no API equivalent.
More generally, FlaggedRevs carries two near-duplicate implementations of the same report: Special:ConfiguredPages (dewiki, $wgFlaggedRevsProtection = false) and Special:StablePages (enwiki, protection-based). The eventual goal is to deprecate and remove some of the complex functionality of the original dewiki variant, so we'd like to reduce the redundancy by having the dewiki implementations be thin subclasses around the simpler enwiki implementations (rather than adding complexity to the enwiki implementation).
Work items:
- Make list=configuredpages available in all setups. Protection always makes the stable version the default version, so on those wikis the module matches the Special:StablePages list and the cpdefault filter is hidden.
- Bug fix: list=configuredpages reported page configurations which had already expired (limited time protection)
- Reuse the Codex UX work done on Special:ConfiguredPages on Special:StablePages.
- To reduce unnecessary forking, give the two reports and the API the same filters: add "Indefinite expiry only" to Special:ConfiguredPages and a matching cpindef API parameter.
- Refactor so Special:ConfiguredPages shares code with Special:StablePages instead of being cut-and-paste copies: ConfiguredPagesPager extends StablePagesPager and ConfiguredPages extends StablePages, each overriding only the dewiki-specific behaviour (which version is the default, and the link to Special:Stabilization). The two dewiki classes drop from ~285 to ~116 lines with no change to the rendered HTML.
- Add test coverage for the API module and for both pagers, which had none.