Page MenuHomePhabricator

RESTBase doesn't purge renamed page -> VisualEditor unable to create moved page
Closed, ResolvedPublic0 Estimated Story Points

Description

Page "Project:VisualEditor_testing/Basic_example_worksheet" on mediawiki.org used to be named "VisualEditor:Basic example worksheet".

As no redirect was left, "VisualEditor:Basic_example_worksheet" no longer exists.

Opening VE there by clicking Create (https://www.mediawiki.org/w/index.php?title=VisualEditor:Basic_example_worksheet&veaction=edit) results in an error:

Error loading data from server: ve-api:
Revision IDs (doc=1751441,api=0) returned by server do not match. Would you like to retry?

This is because even though this page doesn't exist in MediaWiki, the RESTBase request is responded to with an actual revision (the last revision of that page before it was renamed, revision 1751441).

The following requests are made:

  1. https://www.mediawiki.org/w/api.php?action=visualeditor&format=json&paction=metadata&page=VisualEditor%3ABasic_example_worksheet&uselang=en
    • oldid: 0
  2. https://www.mediawiki.org/api/rest_v1/page/html/VisualEditor%3ABasic_example_worksheet
<html  .. revision/1751441">
<meta property="mw:TimeUuid" content="de9960d-2afc-11e5-8bd4-6a7065b61a44"/>
<meta property="mw:articleNamespace" content="2500"/>
<link rel="dc:replaces" resource="mwr:revision/1666615"/>
<meta property="dc:modified" content="2015-07-15T14:22:00.000Z"/>
<meta property="mw:revisionSHA1" content="28755873c21aaa53f9540a8819dab3881f1c4df4"/>
<meta property="mw:parsoidVersion" content="0"/>
<link rel="dc:isVersionOf" href="//www.mediawiki.org/wiki/VisualEditor%3ABasic_example_worksheet"/>
<title>VisualEditor:Basic_example_worksheet</title>
<body id="mwAA" ..>
 <p id="mwAQ">Some test cases for VisualEditor.</p>
  1. https://www.mediawiki.org/w/api.php?action=visualeditor&format=json&paction=metadata&page=VisualEditor%3ABasic_example_worksheet&uselang=en&oldid=1751441
    • oldid: 0
  2. https://www.mediawiki.org/api/rest_v1/page/html/VisualEditor%3ABasic_example_worksheet/1751441
<html  .. revision/1751441">
..
<title>VisualEditor:Basic_example_worksheet</title>
<body id="mwAA" ..>
 <p id="mwAQ">Some test cases for VisualEditor.</p>

Event Timeline

Krinkle raised the priority of this task from to Needs Triage.
Krinkle updated the task description. (Show Details)
Krinkle subscribed.

Also affects deleted file pages (that may now exist on Commons). E.g. https://www.mediawiki.org/wiki/File:RCStream_example.png clicking local Create (https://www.mediawiki.org/w/index.php?title=File:RCStream_example.png&veaction=edit) results in:

Error loading data from server: ve-api:
Revision IDs (doc=1678933,api=0) returned by server do not match.

Jdforrester-WMF set Security to None.
Jdforrester-WMF edited a custom field.
Jdforrester-WMF renamed this task from VisualEditor unable to create moved page / RESTBase doesn't purge renamed page to RESTBase doesn't purge renamed page -> VisualEditor unable to create moved page.Nov 19 2015, 7:34 PM
Pchelolo claimed this task.
Pchelolo subscribed.

After https://github.com/wikimedia/restbase/pull/599 was deployed that shouldn't happen any more. Pages recreated before still wouldn't work properly and we can't do anything with that, but newer restored pages will work. Resolving.