Page MenuHomePhabricator

API: parse does not show revID if title (&text) is given
Closed, InvalidPublic

Description

Author: Wiki.Melancholie

Description:
See:
http://de.wikipedia.org/w/api.php?action=parse&title=Ball&text={{:Ball}}&prop=revid

If there is a given title, the revID should be shown (like with 'page').

Quote: "title - Title of *page* the text belongs to"


Version: unspecified
Severity: enhancement
URL: http://de.wikipedia.org/w/api.php?action=parse&title=Ball&text={{:Ball}}&prop=revid

Details

Reference
bz14707

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:14 PM
bzimport set Reference to bz14707.

There is no revision ID in this case, since you're providing non-saved text.

(In reply to comment #1)

There is no revision ID in this case, since you're providing non-saved text.

That doesn't seem to be the problem. If I remove the text= and the prop= parameters (since prop=revid is included by default anyway), I get an empty page with no revid and no content other than the limit report.

Oh wait, you're using title instead of page. Setting title=Ball basically means that the text will behave like it's on [[Ball]], which means [[Ball]] will be a self-link (bold rather than a link), /Foo will link to [[Ball/Foo]] etc. If you want to parse the content of [[Ball]], set page=Ball.

Wiki.Melancholie wrote:

Hmm, but is there a good reason for showing the always empty tag <parse revid="" /> in those cases?
Maybe remove this tag; or replace it by the articleID/curRevisionID (if given)?

(In reply to comment #4)

Hmm, but is there a good reason for showing the always empty tag <parse
revid="" /> in those cases?
Maybe remove this tag; or replace it by the articleID/curRevisionID (if given)?

Done in r36983. It was intended not to appear in that case, but I confused null and false.