Page MenuHomePhabricator

Edit conflict preview not working on big pages
Closed, ResolvedPublic5 Estimated Story Points

Description

When you get an edit conflict on a bigger page the preview button does not work.

Steps to reproduce:

  1. Create an edit conflict (myself logged-in against myself as an IP) on a wikipage with much text.
  2. Click on Preview
  3. Nothing happens, no preview is shown.

This might also be the problem behind https://www.mediawiki.org/wiki/Topic:Uun8oeocci3h79i7 ( still not investigated fully )

Acceptance Criteria

  • Independent of page size, we can show a preview

Notes
A big page means anything above 2000 Bytes.
This can probably be solved through using a POST request instead of GET

Details

Related Objects

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

This is the js error I get when I click the preview button:

GET https://de.wikipedia.org/w/api.php?action=parse&format=json&formatversion=2…anuell%20ersetzt%20werden%2E%0A%7C%7B%7BX%7D%7D%20nicht%20geplant%0A%7C%7D 414
WMDE-Fisch renamed this task from Preview button isn't working (no reaction) to Edit conflict preview not working on big pages.Feb 25 2019, 12:49 PM
WMDE-Fisch updated the task description. (Show Details)

This is the js error I get when I click the preview button:

GET https://de.wikipedia.org/w/api.php?action=parse&format=json&formatversion=2…anuell%20ersetzt%20werden%2E%0A%7C%7B%7BX%7D%7D%20nicht%20geplant%0A%7C%7D 414

I just found out that this is related to big pages where the conflicts appear. So the reason behind this is quite straight forward. I updated the issue description accordingly.

Lea_WMDE set the point value for this task to 5.

I believe I just ran into this problem as well. I'd just like to note surprise at 2000 bytes being described as a big. At EnWiki that would be considered an extremely short page.

Change 506005 had a related patch set uploaded (by Awight; owner: Adam Wight):
[mediawiki/core@master] Use POST to submit content as a request parameter

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

As you said, POST is all that we needed here. I got fancy and only POST when submitting content via a request parameter.

Change 506005 merged by jenkins-bot:
[mediawiki/core@master] Use POST to submit wikitext to mw.api.parse

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