Page MenuHomePhabricator

Unsuccessful move attempts trigger VisualEditor
Closed, ResolvedPublic1 Estimated Story Points

Description

Steps to Reproduce:

  1. Don't have sysop rights on English Wikipedia.
  2. Set your default editor to VisualEditor.
  3. Try to move a page to a title that you're not allowed to (e.g. Radio Man -> Radioman on English Wikipedia).

Actual results:
VisualEditor loads on Special:MovePage with the contents of the article. (See screenshot.)

Expected results:
You just get an error message and no VisualEditor stuff.

Screen Shot 2017-09-15 at 3.23.03 PM.png (395×666 px, 93 KB)

Event Timeline

Deskana set the point value for this task to 1.
Deskana moved this task from To Triage to TR1: Releases on the VisualEditor board.
Deskana subscribed.

That's weird.

How can you try to move a page that is move protected?

How can you try to move a page that is move protected?

Actually, it looks like the issue isn't when a page is move protected, but when the page can't be moved for some other reason, like a page of that name already exists, or the new title is invalid.

After the move, you have action=submit in the URL, which makes VE think it's an isEditPage, so getInitialEditMode() will load the editor (this doesn't happen on normal edit pages with action=submit, as mw.config.get( 'wgAction' ) === 'submit' will be true on them, but here this won't prevent the editor from loading).

Change 471294 had a related patch set uploaded (by Bartosz Dziewoński; owner: Bartosz Dziewoński):
[mediawiki/extensions/VisualEditor@master] DesktopArticleTarget.init: Don't load on special pages with action=submit in the URL

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

Change 471294 merged by jenkins-bot:
[mediawiki/extensions/VisualEditor@master] DesktopArticleTarget.init: Don't load on special pages with action=submit in the URL

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

I guess it was, I just tried and there is no bug anymore :)