Page MenuHomePhabricator

Bizarre parser error
Closed, DeclinedPublic

Description

On that page, the wikimarkup:

<nowiki>
[[Image:Trial by Jury - Chaos in the Courtroom.png|thumb|250px|'''Original''' - ''[[Trial by Jury]]'' premièred on 25 March 1875, and was a huge hit, praised by critics, and met with "almost boisterous hilarity" from its audiences. While [[Gilbert and Sullivan]] had collaborated once before, on the Christmas entertainment ''[[Thespis (opera)]]'' (now lost), ''Trial'' introduced many features, such as the autobiographical [[patter song]], that would define their style. This engraving by D. H. Friston dates from ''Trial'''s original run, and was published in the ''Illustrated Sporting and Dramatic News'' on 1 May 1875.]]</nowiki>

The caption of which should be parsed as:

'''Original''' - ''[[Trial by Jury]]'' premièred...

Instead parses as '<!-- -->''Original''' - ''[[Trial by Jury]]'' premièred...

It may be that the later typo, <nowiki>''Trial'''s</nowiki> (meant to be <nowiki>''Trial&lt;!-- --&gt;'s throws the software off, but it still disobeys the law of least surprise.


Version: unspecified
Severity: minor
URL: http://en.wikipedia.org/w/index.php?title=Wikipedia:Featured_picture_candidates/Trial_by_Jury&oldid=216510500

Details

Reference
bz14376

Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 21 2014, 10:13 PM
bzimport added a project: MediaWiki-Parser.
bzimport set Reference to bz14376.

I apologise, I thought that would be wiki-processed. Here it is again.

On that page, the following bit of code:

[[Image:Trial by Jury - Chaos in the Courtroom.png|thumb|250px|'''Original''' -
''[[Trial by Jury]]'' premièred on 25 March 1875, and was a huge hit, praised
by critics, and met with "almost boisterous hilarity" from its audiences. While
[[Gilbert and Sullivan]] had collaborated once before, on the Christmas
entertainment ''[[Thespis (opera)]]'' (now lost), ''Trial'' introduced many
features, such as the autobiographical [[patter song]], that would define their
style. This engraving by D. H. Friston dates from ''Trial'''s original run, and
was published in the ''Illustrated Sporting and Dramatic News'' on 1 May
1875.]]</nowiki>

The caption of which should be parsed as (using HTML markup):

<b>Original</b> - <i>[[Trial by Jury]]</i> premièred...

Instead parses as '<i>Original<b> - </i>[[Trial by Jury]]<i> premièred...

It may be that the later typo, ''Trial'''s (meant to be
''Trial<!-- -->'s throws the software off, but it still disobeys
the law of least surprise.

Testing, I find that any code of the pattern

'''A''' B ''C'' D ''E'''

will duplicate this bug, which may mean that it is unavoidable without breaking clean handling of other complex situations.

Confirmed on the case '''A''' B ''C'' D ''E'''. I would expect that to be rendered:

<b>A</b> B <i>C</i> D <i>E</i>'

The original use care appears fixed though. See http://en.wikipedia.org/wiki/User:Siebrand/test

Assigned to Tim.

This is known and stable behaviour, and is included in passing parser tests. No doubt many pages rely on it.