Page MenuHomePhabricator

Editing an empty Flow board description (that has previously contained a category?) gives "Previous revision identifier is missing"
Closed, ResolvedPublic

Description

If I edit an empty board description, and click "Save description", I get the message Previous revision identifier is missing


Reproduced at https://www.mediawiki.org/wiki/Talk:Sandbox
and https://lv.wikipedia.org/wiki/Vikip%C4%93dijas_diskusija:Flow

If I blank an existing description, that does Not cause the bug to appear.
However https://www.mediawiki.org/wiki/Talk:Sandbox used to have a description until 2 days ago, so that's odd...

Ah, I replicated part of the edits from Talk:Sandbox at https://www.mediawiki.org/wiki/User_talk:Quiddity_%28WMF%29 by adding [[Category:Flow|*]] and then deleting it, and now that page is also suffering the bug.

Details

Related Gerrit Patches:

Event Timeline

Quiddity created this task.Aug 26 2015, 5:43 PM
Quiddity raised the priority of this task from to Needs Triage.
Quiddity updated the task description. (Show Details)
Quiddity added a subscriber: Quiddity.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptAug 26 2015, 5:43 PM
Quiddity renamed this task from Editing an empty Flow board description gives "Previous revision identifier is missing" to Editing an empty Flow board description (that has previously contained a category?) gives "Previous revision identifier is missing".Aug 26 2015, 5:44 PM
Quiddity set Security to None.
Catrope assigned this task to Mooeypoo.Aug 26 2015, 5:48 PM
Etonkovidova added a subscriber: Etonkovidova.EditedAug 26 2015, 7:52 PM

In betalabs it happens only when a board description has a template(any template) and that template was deleted and 'Save changes' was clicked:

  1. Delete a content from a board descirption.
  2. In wikitext mode - add [[Category:Flow|*]] - click on 'Save description'

The following error is displayed:
[32ec9d4d] Exception Caught: Row has null primary key:

In Console: Uncaught Error: ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds
ve.dm.Document.getBranchNodeFromOffset @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:189ve.dm.Surface.setSelection @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:152ve.dm.SurfaceFragment.select @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:166ve.ce.Surface.handleLinearDelete @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:410ve.ce.Surface.onDocumentKeyDown @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:366ve.EventSequencer.callListener @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:44ve.EventSequencer.onEvent @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:41ve.EventSequencer.pendingCalls @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:39jQuery.event.dispatch @ load.php?debug=false&lang=en&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=3vxc1Hwb:65jQuery.event.add.elemData.handle @ load.php?debug=false&lang=en&modules=jquery%2Cmediawiki&only=scripts&skin=vector&version=3vxc1Hwb:60

Uncaught Error: Invalid start offset: -1ve.Document.selectNodes @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:31ve.dm.SurfaceFragment.getSelectedNode @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:165ve.dm.SurfaceFragment.getSelectedModels @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:158ve.ui.LinearContext.getRelatedSources @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:470ve.ui.LinearContext.isInspectable @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:470ve.ui.LinearContext.afterContextChange @ load.php?debug=false&lang=en&modules=ext.flow.editors.none|ext.flow.visualEditor|ext.visualEditor.c…:469mw.loader.implement.ve.ui.DesktopContext.afterContextChange @ VM3297:116


If I blank an existing description, that does Not cause the bug to appear.

I thought that it was never allowed to create Flow pages in production with an empty board description. If at some point, an empty board description was created and then it was disallowed, it might explain 'Previous revision identifier is missing".

I thought that it was never allowed to create Flow pages in production with an empty board description.

No, you can still create it by creating a topic.

Change 234135 had a related patch set uploaded (by Mooeypoo):
Populate the Description data model even if content is empty

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

Change 234135 merged by jenkins-bot:
Populate the Description data model even if content is empty

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

DannyH triaged this task as Unbreak Now! priority.Aug 27 2015, 5:02 PM
DannyH added a subscriber: DannyH.

In betalabs it happens only when a board description has a template(any template) and that template was deleted and 'Save changes' was clicked:

  1. Delete a content from a board descirption.
  2. In wikitext mode - add [[Category:Flow|*]] - click on 'Save description'

The following error is displayed:
[32ec9d4d] Exception Caught: Row has null primary key:

Filed as T110390: Exception Caught: Row has null primary key.

In Console: Uncaught Error: ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds

Filed as T110393: VE error editing board description.

Checked in betalabs. Since other bugs were filed separately T110390: Exception Caught: Row has null primary key T110393: VE error editing board description - this issue was just verified for new empty board to which [[Category:Flow|*]] was added.

Also, empty new boards were tested for links/mention.

DannyH closed this task as Resolved.Aug 28 2015, 5:21 PM
Etonkovidova added a comment.EditedAug 31 2015, 4:55 PM

Re-checked in betalabs - the specific error is not present anymore.