Page MenuHomePhabricator

action=parse with title set to a special page returns error pagecannotexist
Closed, ResolvedPublic

Description

Original bug title:
action=parse with title set to a special page returns error pagecannotexist

IMO a bug because it is possible to transclude templates etc. into some of these special pages through MediaWiki messages. If you would like to get a preview of how it will look like at this page, the best way is using action=parse.

@commons
https://commons.wikimedia.org/wiki/Special:ApiSandbox#action=parse&format=json&title=Special%3AWatchlist&text={{WatchlistNotice}}&prop=text&pst=&uselang=de


Version: 1.22.0
Severity: normal

Details

Reference
bz49477

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 1:42 AM
bzimport set Reference to bz49477.
bzimport added a subscriber: Unknown Object (MLST).

mediawiki messages are included different in the interface, some as plain html, other parsing wikitext, some only as plain text, so this can have different result than the original message.

But Special:ExpandTemplates can it, so there is no reason why api should not support that.

Reedy, it looks like you added this check in Gerrit change 29583. What was the reason for it? The code path you added the check to should be using the title only for {{PAGENAME}} and the like in the user-supplied text. Was it just because Gerrit change 18973 had already broken it?

Reedy: Could you answer comment 2, please?

Reedy: Could you answer comment 2, please?

Reedy: Could you answer anomie's question in comment 2, please?

(In reply to comment #5)

Reedy: Could you answer anomie's question in comment 2, please?

I don't think it really matters. Let's just fix it.

Change 106530 had a related patch set uploaded by Anomie:
API: Allow special pages for action=parse&title=

https://gerrit.wikimedia.org/r/106530

Change 106530 merged by jenkins-bot:
API: Allow special pages for action=parse&title=

https://gerrit.wikimedia.org/r/106530

Should be deployed to WMF wikis with 1.23wmf11, see https://www.mediawiki.org/wiki/MediaWiki_1.23/Roadmap for the schedule.