Page MenuHomePhabricator

API: action=flow-parsoid-utils strips meta tag from top of <body>
Closed, DeclinedPublic

Description

When using action=flow-parsoid-utils, meta tags produced by Parsoid located at the top of the <body> content are not included in API output.

Compare https://en.wikipedia.org/w/api.php?action=flow-parsoid-utils&from=wikitext&to=html&format=jsonfm&title=Wikipedia%20talk:Articles%20for%20creation/sandbox&content={{AFC%20submission}} to https://en.wikipedia.org/w/api.php?action=flow-parsoid-utils&from=wikitext&to=html&format=jsonfm&title=Wikipedia%20talk:Articles%20for%20creation/sandbox&content=foo{{AFC%20submission}}

In the first example (with the tag directly at the top of the page), no information about the meta tag (mw:PageProp/nonewsectionlink) is available. However, it IS provided when directly using the Parsoid service at http://parsoid.wmflabs.org/enwiki/Wikipedia_talk%3AArticles_for_creation%2Fsandbox?oldid=599397480

This is important for the Articles for creation helper script on enwiki to function properly (ideally we wouldn't be hijacking a Flow tool in the first place, but until parsoid.wmflabs.org has HTTPS support...).

Thanks!

Theo


Version: unspecified
Severity: normal

Details

Reference
bz62597

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:04 AM
bzimport set Reference to bz62597.
bzimport added a subscriber: Unknown Object (MLST).

(Sorry for bugspam, just note that the closing brackets of the templates need to be included in the first two links for them to work properly.)

Adding Legoktm, who's working on Flow API stuff and will be 1000x more helpful than me ;)

Theopolisme do you want to monitor Flow posts with this, or are you just using flow-parsoid-utils because it's a useful Parsoid API?

Hey -- I wasn't using flow-parsoid-utils as a permanent solution, but rather as an intermediate step until the Parsoid web service was more stable. Since reporting this bug, I've switched to using the MediaWiki built-in revision XML parse tree API instead; although not everything we need is available through it, at least it works :)

So generally, flow-parsoid-utils is intended for internal use, but has the side-effect of being one of the few easy ways to use Parsoid via the MW API.

Since Theo has found a workaround, I'll close this as WONTFIX.