Page MenuHomePhabricator

When editing an old version of a page, the VisualEditor shows the diff to that old version and not to the most recent version
Open, MediumPublic

Description

As reported today (permalink) on the German-language Wikipedia's feedback page, when editing an old version of a page, the VE's saving dialog shows the diff with that old version, not the most recent version.

Steps to reproduce:

  1. Go to the article about Annalena Baerbock and observe that Robert Habeck is mentioned in the second sentence of the article.
  2. Go to the page history and open an old version from July or earlier, e.g. this one. Observe that Robert Habeck is not mentioned in the second sentence.
  3. Now open the old version for visual editing, make some random changes to the first sentences, go to the save dialog ("Änderungen veröffentlichen" in the upper right-hand corner) and click on "Überprüfe deine Änderungen" at the bottom of the dialog.
  4. Inspect the diff and verify that the left column, despite claiming that it shows the current version ("Aktuelle Version"), actually shows the old version:

grafik.png (389×896 px, 18 KB)

  1. Go back to the old version of the article without saving anything and open the article in wikitext edit mode.
  2. Make the same change and click on "Änderungen zeigen" at the very bottom. Observe that here the diff is shown between the actual current version (where Robert Habeck has been added) and the edited version:

grafik.png (436×801 px, 25 KB)

Event Timeline

Cirdan renamed this task from When editing an old version of a page, the VisualEditor shows the diff to that old version and not the most recent version to When editing an old version of a page, the VisualEditor shows the diff to that old version and not to the most recent version.Sep 8 2018, 2:38 PM
Cirdan updated the task description. (Show Details)
Deskana moved this task from To Triage to Needs Discussion/Analysis on the VisualEditor board.
Deskana subscribed.

This is borderline for me as to whether it should be prioritised for work or put into the backlog. An estimation of how much effort it would take to fix would be helpful—if it's not much effort, taking care of it quickly would be best.

It's probably not that hard, but I think the current behaviour of diffing latest vs your version instead of loaded version vs your version in the old wikitext editor is equally confusing, in that it mixes changes you may have just made with changes resulting from you editing an old version.

JTannerWMF subscribed.

We are not prioritizing this work at this time.

Copying discussion from the merged task:

[VisualEditor's behavior] is consistent with how visual diff in the same dialog works, but inconsistent with the classic wikitext editor.

Though wouldn't it be better to show the actual changes that will be made after saving the page, i.e. what the classic editor shows?

Maybe… I don't think that is obviously better. And it has its own set of issues (for example, if someone else edits the page in the meantime, the diff shown by the classic editor is not what is actually going to be saved, because of automatic edit conflict resolution).

Related: T121185 (which is basically a request to change wikitext editor behavior to match ours)