Page MenuHomePhabricator

Typing a duplicate character after a link results in the wrong change being written to the model
Closed, ResolvedPublic8 Estimated Story Points

Description

Place your cursor outside and after a link: <a>foo</a>|bar</a> and type the same character as is to the right of the cursor ('b').

The model should be: <a>foo</a>bbar, but is actually <a>foo</a>ar.

Bisect blames our rewrite of DOM diffing, which makes sense: https://gerrit.wikimedia.org/r/#/c/247800/

Original report below:


There is a serious bug in the Web visual editor of Wikipedia.

I am editing Wikipedia, at https://fr.wikipedia.org/w/index.php?title=Suppuration&veaction=edit
I click just after nécrose tissulaire
I press Option Space.
I press Option ( to insert a {
I press Option ( to write a second {
In the dialog for the template call, I call the template pourquoi.

After the dialog:

Expected result:

nécrose tissulaire [pourquoi ?] riche

Observed result:

nécrose tissulairer[pourquoi ?]iche

It would be nice to correct this dirty bug.

I have Safari on Mac.

Thank you.

Event Timeline

Esanders renamed this task from The template call degrades the text and goes at an incorrect place to Typing a duplicate character after a link results in the wrong change being written to the model.Aug 10 2016, 10:01 PM
Esanders assigned this task to dchan.
Esanders triaged this task as High priority.
Esanders updated the task description. (Show Details)

Change 304135 had a related patch set uploaded (by Divec):
Fix TextState#getChangeTransaction bug

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

Change 304135 merged by jenkins-bot:
Fix TextState#getChangeTransaction bug

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

Change 304268 had a related patch set uploaded (by Jforrester):
Fix TextState#getChangeTransaction bug

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

Change 304268 merged by jenkins-bot:
Fix TextState#getChangeTransaction bug

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

Mentioned in SAL [2016-08-12T00:15:45Z] <dereckson@tin> Synchronized php-1.28.0-wmf.14/: VE: Fix TextState#getChangeTransaction bug (T141573) ; Echo: Revert "Hack around browser bug in IE breaking badge alignment in Monobook" ([[gerrit:304415]]) ; Core: Revert CSS fix ([[gerrit:304412]], T142750) (duration: 08m 58s)