Page MenuHomePhabricator

RSS: Parse wikitext in description field
Closed, ResolvedPublicBUG REPORT

Description

Feature summary (what you would like to be able to do and where): Currently wikitext from a Cargo query is sent to the RSS description element as unparsed wikitext (e.g. [http://www.example.com Example]). It would be better if it were to be parsed as HTML first (e.g. <a href="http://www.example.com">Example</a>).

I think a wiki would be able to display the HTML anyway (if not, perhaps HTML vs wikitext could be an option in the Cargo query).

Use case(s) (list the steps that you performed to discover that problem, and describe the actual underlying problem which you want to solve. Do not describe only a solution): See Benefits.

Benefits (why should this be implemented?): This change would allow RSS feeds containing wikitext to be displayed properly on non-wiki websites.

Event Timeline

@Samwilson - mentioning you here in case you've not spotted this one. Thanks.

It would be nice if the description could even include a fully-parsed Cargo query. Maybe that comes free when you sort out parsing links and wikitext in general.

For instance, it might be that each RSS item is like a blog post or update for the month, and included within its text is a Cargo query displaying a list of all the latest things mentioned that month.

Just noticed that when description is not set in the query, it defaults to the HTML (not wikitext) of the page.

• Samwilson changed the subtype of this task from "Feature Request" to "Bug Report".Sep 14 2023, 1:31 AM

Yep, I think it definitely makes sense to parse description as wikitext. This was certainly an oversight in the initial patch.

Change 1009392 had a related patch set uploaded (by Jayanthvikashs; author: Jayanthvikashs):

[mediawiki/extensions/Cargo@master] Parse feed description as wikitext in RSS feed format

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

Change 1009392 merged by jenkins-bot:

[mediawiki/extensions/Cargo@master] Parse description as wikitext in feed format

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

Yaron_Koren claimed this task.

I think this is done now! @Jayanthvikashs - thank you for your help with this.