Page MenuHomePhabricator

Space-less signature prefix can break trailing links in source mode
Open, Needs TriagePublic

Description

Originally reported at https://www.mediawiki.org/wiki/Topic:Vz5c78hc9iapdhul

The signature prefix does not automatically insert a space. This is deliberate as some wikis don’t use spaces before signatures by convention (ja.wiki). In the originally reported example above (uk.wiki) it was just configured incorrectly.

When no space is in the prefix, open ended magic syntax like URLs will merge with the signature prefix and break the link, e.g. you get a link to http://example.org/foo--.

Due to the span tag we used to grey out the signature in the preview, the error is not visible in the preview.

Testing instructions

  • write a comment on ja.wiki in source mode
  • end your comment with a bare external link: http://example.org/foo
  • publish
  • observe your external link merges with the signature prefix (hyphens)