Page MenuHomePhabricator

Error "ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds" appears and VE hangs after deleting a focusable node which is followed by another focusable node and then nothing
Closed, ResolvedPublic1 Story Points

Description

Steps to reproduce:
1, Create a page
2.Insert a focusable node like graph/template/image/gallery /code block/heiro

  1. Insert an empty reflist

4.Save the page

  1. Re-open the page

6.Delete the focusable node or the empty reflist

Observed Result:
Following errors appear in the console, context menu appears at the top right and VE hangs so cannot save the page or do anything in that session.

Error: ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds
load.ph...988a6fb (line 309, col 353)
Error: Invalid start offset: -1

Event Timeline

Ryasmeen raised the priority of this task from to Needs Triage.
Ryasmeen updated the task description. (Show Details)
Ryasmeen added a project: VisualEditor.
Ryasmeen added a subscriber: Ryasmeen.
Restricted Application added subscribers: StudiesWorld, Aklapper. · View Herald TranscriptDec 10 2015, 10:05 PM
Jdforrester-WMF triaged this task as High priority.Dec 11 2015, 7:31 PM
Jdforrester-WMF set Security to None.
Jdforrester-WMF edited a custom field.
Jdforrester-WMF moved this task from To Triage to TR0: Interrupt on the VisualEditor board.
Jdforrester-WMF added subscribers: Esanders, DLynch, dchan.

Change 258936 had a related patch set uploaded (by DLynch):
Fragment delete: handle a document with no valid content offsets

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

Change 258936 merged by jenkins-bot:
Fragment delete: handle a document with no valid content offsets

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

Jdforrester-WMF renamed this task from Error "ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds" appears and VE hangs after deleting any focusable node which is followed by an empty reflist to Error "ve.dm.Document.getBranchNodeFromOffset(): offset -1 is out of bounds" appears and VE hangs after deleting a focusable node which is followed by another focusable node and then nothing.Dec 14 2015, 6:26 PM
Jdforrester-WMF closed this task as Resolved.
Jdforrester-WMF assigned this task to DLynch.
Jdforrester-WMF lowered the priority of this task from High to Normal.