Last modified: 2013-06-27 22:41:30 UTC
Steps to reproduce: 1. Insert the cursor immediately after the first letter of a link 2. Hit delete/backspace 3. Type a new character 4. The new character isn't part of the link, so select the entire word and click the link button 5. Re-enter the link article 6. Save your changes Expected result: If you started with "[[Porcupine]]", you should end up with "[[porcupine]]". Actual result: If you started with "[[Porcupine]]", you end up with "[[porcupine|p]][[Porcupine|orcupine]]". This is just a common use case demonstrating a more general bug. Namely, if you create a new link that subsumes an existing link, the existing link is preserved within the new link instead of being replaced.
Ed, is this due to the DM stuff around adjacent annotations?
Similar but different. This case should definitely be fixed in VE, not Parsoid.
There are two issues here. First off, we should change getComparableObject() for MWInternalLinkAnnotation to normalize the title and possibly tweak other things to the point where links to the same title are comparable, even if they have different capitalizations or space-vs-underscore variants of that title. That will be both more semantically correct and serve as a workaround for this bug. Secondly, because we want to stop merging comparable but different annotations in the converter, we need Parsoid to correctly process at least things like <a href="Porcupine">p</a><a href="Porcupine">orcupine</a> (adjacent <a>s with the same href) and possibly <a href="porcupine">p</a><a href="Porcupine">orcupine</a> as well (adjacent <a>s with different hrefs that normalize to the same title).
Related URL: https://gerrit.wikimedia.org/r/70633 (Gerrit Change I5fb5bfc69c344ca4ce4803d7b6116074648a8d7e)
Change 70633 merged by jenkins-bot: Fix comparison of MW internal links https://gerrit.wikimedia.org/r/70633
(In reply to comment #5) > Change 70633 merged by jenkins-bot: > Fix comparison of MW internal links > > https://gerrit.wikimedia.org/r/70633 And with that change, this bug is fixed; closing. It will be deployed this afternoon.