Page MenuHomePhabricator

failed in getting backlinks of some pages in persian wiktionary
Closed, InvalidPublic

Description

Author: iceage2098

Description:
In persian wiktionary, I couldn't get backlinks of some pages (especially template pages) via Mediawiki API. I discussed this problem in wikimedia-tech, and they told me that could be a bug in Mediawiki API.
For example I couldn't get backlinks of pages below in persian wiktionary:

http://fa.wiktionary.org/w/api.php?action=query&list=backlinks&bltitle=%D8%A7%D9%84%DA%AF%D9%88:%D8%A7%D8%B3%D9%85-%D8%A7%D9%86
http://fa.wiktionary.org/w/api.php?action=query&list=backlinks&bltitle=%D8%A7%D9%84%DA%AF%D9%88:%D8%A8%D8%B1%DA%AF%D8%B1%D8%AF%D8%A7%D9%86-%D8%A8%D8%A7%D9%84%D8%A7

Note that these links has a lot of backlinks.


Version: unspecified
Severity: major
URL: http://fa.wiktionary.org/w/api.php?action=query&list=backlinks&bltitle=%D8%A7%D9%84%DA%AF%D9%88:%D8%A7%D8%B3%D9%85-%D8%A7%D9%86

Details

Reference
bz25555

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:20 PM
bzimport set Reference to bz25555.

The backlinks you're seeing in Special:Whatlinkshere are all transclusions (see http://fa.wiktionary.org/w/index.php?title=%D9%88%DB%8C%DA%98%D9%87:%D9%BE%DB%8C%D9%88%D9%86%D8%AF_%D8%A8%D9%87_%D8%A7%DB%8C%D9%86_%D8%B5%D9%81%D8%AD%D9%87/%D8%A7%D9%84%DA%AF%D9%88:%D8%A7%D8%B3%D9%85-%D8%A7%D9%86&uselang=en ), so you have to get them through embeddedin: http://fa.wiktionary.org/w/api.php?action=query&list=embeddedin&eititle=%D8%A7%D9%84%DA%AF%D9%88:%D8%A7%D8%B3%D9%85-%D8%A7%D9%86 . Backlinks only erturns 'real' links, this is by design. You can also combine the two queries in one request using ?action=query&list=backlinks|embeddedin&bltitle=Foo&eititle=Foo