Page MenuHomePhabricator

prop=sortkey ignored for generator=categorymembers
Closed, InvalidPublic

Description

Author: srbauer

Description:
cmprop is working fine in list mode, but in generator mode the parameter gcmprop is ignored.


Version: unspecified
Severity: normal
URL: http://de.wikipedia.org/w/api.php?action=query&generator=categorymembers&gcmcategory=Astronomie&gcmprop=sortkey

Details

Reference
bz10456

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 9:50 PM
bzimport set Reference to bz10456.

(In reply to comment #0)

cmprop is working fine in list mode, but in generator mode the parameter
gcmprop is ignored.

Weird. Does this occur only with prop=sortkey (as the title suggest) or with the gcmprop parameter in its entirety? Either way, I'm on it.

Resolving as INVALID. Generators are just intended to generate a titles/pageids/revids array for use in the next step. Outputting sortkey while in generator mode is simply not possible.

srbauer wrote:

No problem if this behaviour is as expected, but then the documentation should be checked - at the moment I can't find the slightest hint for these limitations.

(In reply to comment #3)

No problem if this behaviour is as expected, but then the documentation should
be checked - at the moment I can't find the slightest hint for these
limitations.

The documentation is incomplete as hell anyway. Many API features are even entirely undocumented.

srbauer wrote:

I see, the normal way of programming ;-)

What about an error for paramters that are allowed in prop/list mode but ignored in generator mode - instead of just silently ignoring them?

(In reply to comment #5)

I see, the normal way of programming ;-)

What about an error for parameters that are allowed in prop/list mode but
ignored in generator mode - instead of just silently ignoring them?

Could be done. We had a little trouble with gwlprop, which wasn't allowed, but because there was a default value for it, an error would *always* be thrown. I suggested checking against the default, but Yuri fixed it by simply silently ignoring the gwlprop param. We'd have to discuss this with Yuri before we go around changing half a dozen files.