When list=allusers is used with auactiveusers, a property 'recenteditcount'
is returned in the result. In bug 67301[1] it was pointed out that this
property is including various other logged actions, and so should really be
named something like "recentactions".
Gerrit change 130093,[2] merged today, adds the "recentactions" result
property. "recenteditcount" is also returned for backwards compatability,
but will be removed at some point during the MediaWiki 1.25 development
cycle.
Any clients using this property should be updated to use the new property
name. The new property will be available on WMF wikis with 1.24wmf12, see
https://www.mediawiki.org/wiki/MediaWiki_1.24/Roadmap for the schedule.
[1]: https://bugzilla.wikimedia.org/show_bug.cgi?id=67301
[2]: https://gerrit.wikimedia.org/r/#/c/130093/
--
Brad Jorsch (Anomie)
Software Engineer
Wikimedia Foundation
Since last month,[1] action=import would ignore the rootpage parameter when
the namespace parameter was specified, due to underlying changes in
MediaWiki to make Special:Import clearer. Starting with 1.26wmf7,[2][3] it
will instead give an error if both parameters are specified to avoid
incorrect importing by code expecting the old behavior.
[1]: https://gerrit.wikimedia.org/r/#/c/179116/
[2]: https://gerrit.wikimedia.org/r/#/c/210945/
[3]: See https://www.mediawiki.org/wiki/MediaWiki_1.26/Roadmap for the
deployment schedule.
--
Brad Jorsch (Anomie)
Software Engineer
Wikimedia Foundation
After a lot of work, we're ready to provide a more sensible data layout for
format=json results (and also format=php). You can enable this in your
requests by adding "&formatversion=2", but do note that the output
formatting isn't entirely stable yet and might change without warning.
Without specifying formatversion=2, things should be backwards-compatible.
But there are some caveats:
- Modules that were previously outputting raw booleans in JSON may now
have those properties being output using the standard convention:
empty-string for true and absent for false. Instances of this should be
reported in Phabricator <https://phabricator.wikimedia.org/> to be
fixed, please tag with #MediaWiki-API
<https://phabricator.wikimedia.org/project/profile/200/> and the tag for
the relevant extension.
- format=xml will now reversibly mangle tag and attribute names that are
not valid XML, instead of just outputting invalid XML.
- Previously-announced breaking changes to log entry parameter
formatting, that are not actually part of this general result formatting
change but were made at about the same time.
With formatversion=2, we can make some useful changes:
- Return booleans as boolean true instead of empty-string. Where
appropriate,[1] return boolean false instead of omitting the property.
- Return empty objects in JSON as {}, rather than [].
- Have action=query's "pages" be an array, instead of an object with
page ids as keys that can be difficult to iterate.
- Provide useful property names instead of '*'.
- Eliminate useless indirection, e.g. {"text":"..."} instead of
{"text":{"*":"..."}} and {"key1":"value1","key2":"value2"} instead of
[{"name":"key1","*":"value1"},{"name":"key2","*":"value2"}].
If you see missed opportunities to make the above changes in existing
formatversion=2 output, or if there are other changes that would make API
output easier to use in JSON, please let me know! Phabricator
<https://phabricator.wikimedia.org/> would be ideal (tag with #MediaWiki-API
<https://phabricator.wikimedia.org/project/profile/200/>, and the
appropriate extension's tag if applicable), or reply on the mediawiki-api
mailing list <https://lists.wikimedia.org/mailman/listinfo/mediawiki-api>.
Thanks.
[1]: Where the property is usually false, it's sometimes just bloat to
include it.
--
Brad Jorsch (Anomie)
Software Engineer
Wikimedia Foundation