Page MenuHomePhabricator

VisualEditor sometimes creates broken references (cite error ref no key) and adds ref names to non-reused references
Closed, DuplicatePublicBUG REPORT

Description

Steps to replicate the issue:

  • Edit a page in VisualEditor, add or re-use a reference
  • ...? (couldn't reproduce the issue myself)

What happens?:

  • Difflinks like:
Old text.<ref>Reference</ref>

->

Old text.<ref name=":0">Reference</ref>

New text.<ref />
  • Leading to the reference error MediaWiki:Cite error ref no key (Cite error: The opening <ref> tag is malformed or has a bad name) – and an auto-generated reference name even though the reference is not re-used.

Examples from different wikis: enwiki, frwiki, dewiki 1, dewiki 2, dewiki 3, dewiki 4

What should have happened instead?:

  • If the user tried to to re-use the reference:
Old text.<ref name=":0">Reference</ref>

New text.<ref name=":0" />
  • If the user tried to create a new reference:
Old text.<ref>Reference</ref>

New text.<ref>New reference</ref>

Other information: