Abstract
While developing a bot I've just figure out that a query on the transcludedin API module with a non-numeric tinamespace / gtinamespace throws an error 500 after 60 seconds of execution on major Wikimedia Foundation sites.
Also note that other modules defined in the ApiQueryBacklinksprop may be affected.
Proof of concept
- https://en.wikipedia.org/w/api.php?action=query&titles=A&generator=transcludedin>inamespace=POC
- https://en.wikipedia.org/w/api.php?action=query&titles=A&prop=transcludedin&tinamespace=POC
- https://en.wikipedia.org/w/api.php?action=query&titles=A&generator=linkshere&glhnamespace=POC
- https://en.wikipedia.org/w/api.php?action=query&titles=A&prop=linkshere&glhnamespace=POC
Normal usage examples
- https://en.wikipedia.org/w/api.php?action=query&titles=A&generator=transcludedin>inamespace=0
- https://en.wikipedia.org/w/api.php?action=query&titles=A&prop=transcludedin&tinamespace=0
- https://en.wikipedia.org/w/api.php?action=query&titles=A&generator=linkshere&glhnamespace=0
- https://en.wikipedia.org/w/api.php?action=query&titles=A&prop=linkshere&glhnamespace=0
Notes
As far I can see this is not a problem related to all API modules with a namespace filter e.g. allpages quits immediately as expected:
Here some MediaWiki versions that I think are not affected:
- <=1.24 (has not transcludedin generator)
- 1.27.4
- 1.29.1
Now I really have no time to further investigate because tomorrow morning I'm in an office.