Page MenuHomePhabricator

Switching between visual editor and source mode gives error message
Closed, ResolvedPublic

Description

"Some parts of the edit form did not reach the server; double-check that your edits are intact and try again"

Reproduce:

  1. Go to https://en.wikipedia.org/wiki/Special:Random
  2. Open the page in visual editor
  3. Make some edits
  4. Switch to source mode (it asks if you want to keep edits, say yes)
  5. Then you get "Some parts of the edit form did not reach the server; double-check that your edits are intact and try again" but you can still edit page.

It was reported here: https://fi.wikipedia.org/wiki/Keskustelu_Wikipediasta:Visuaalinen_muokkain
user said they used 3 different browsers and got the error in all of them. And I can reproduce this.

Event Timeline

There is a note at enwiki's VPT that says this also happens with ReFill, and another report at https://en.wikipedia.org/wiki/Wikipedia:Teahouse#%22Some_parts_of_the_edit_form_did_not_reach_the_server;_double-check_that_your_edits_are_intact_and_try_again.%22

I wonder whether people experiencing this have ReFill enabled.

This message is [[MediaWiki:Edit form incomplete]], which seems to belong to the (old) Preview system. Are these editors previewing their changes? Which wikitext editor are they using? I can't reproduce this, but perhaps it's because I have the 2017 wikitext editor enabled, and I don't think that it uses the same error messages.

I've never used ReFill. I don't have 2017 wikitext editor enabled.

rMW264b4039b30f: Remove outdated transition code seems suspicious. Perhaps VE and other scripts are still relying on the old behavior removed in that patch.

Change 449919 had a related patch set uploaded (by DLynch; owner: DLynch):
[mediawiki/extensions/VisualEditor@master] Include wpUltimateParam when switching from VE to source editor

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

matmarex subscribed.

(Note that there is no data loss, for VE or other affected tools, just a misleading message.)

Change 449919 merged by jenkins-bot:
[mediawiki/extensions/VisualEditor@master] Include wpUltimateParam when switching from VE to source editor

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

(Note that there is no data loss, for VE or other affected tools, just a misleading message.)

I do think it's a situation where it makes it really easy for people who encountered it to assume there was data loss and leave the page, not realizing that their changes were still there. Kind of a "UX-driven data loss" scenario.

I can't reproduce this anywhere (Beta cluster/production) following the steps mentioned. So not sure how to verify the fix in this case.

@Ryasmeen I can reproduce the issue on https://www.mediawiki.org/wiki/Project:Sandbox currently as an anonymous user. You have to switch from VE to old wikitext editor (so this depends on not having NWE enabled in preferences).

Recording: https://drive.google.com/file/d/1LCCs06bwUBnjt8On7FjCJMB8fxMKCt1K/view (too large for Phabricator)

Note that the red message at the top is "Some parts of the edit form did not reach the server…", rather than the familiar "Remember that this is only a preview…". It's subtle :) With the fix applied, it should display "Remember that this is only a preview…" again.

@matmarex: Ah! This is about OWE. Thanks for clarifying that :)

Although, I see this text "Remember that this is only a preview; your changes have not yet been saved!" only when I am going to "source mode" via the "Edit Source" tab but not when I am switching through the switcher.

When switched through the tab:

Screen Shot 2018-08-09 at 12.46.23 AM.png (589×1 px, 164 KB)

When switched through the switcher:

Screen Shot 2018-08-09 at 12.46.04 AM.png (597×1 px, 172 KB)

@Ryasmeen On a closer look, the "Remember that this is only a preview" should not appear after switching from VE to OWE, because we switch to the diff view (rather than the preview view).

But your screenshots are very confusing.

In the first example, I think you chose to discard your changes (or you ran into T199655, which is another editor switching bug), and you have "Show preview on first edit" enabled in https://en.wikipedia.beta.wmflabs.org/wiki/Special:Preferences#mw-prefsection-editing.

In the second example, I have no idea what is happening, because that's clearly a preview and you should be seeing a diff. Did you click "Show preview" after loading the page and have "Show previews without reloading the page" enabled? Apparently in that case the "Remember that this is only a preview" notice doesn't appear (that should be a separate bug).

Deskana triaged this task as Medium priority.
Deskana subscribed.

The actual error reported here seems to be fixed, so I'm closing this as resolved.