Uncaught DOMException: Failed to execute 'setStart' on 'Range' upon Undo/Redo #3158
Labels
browser:chrome
The issue can only be reproduced in the Chrome browser.
browser:safari
The issue can only be reproduced in the Safari browser.
plugin:undo
The plugin which probably causes the issue.
status:confirmed
An issue confirmed by the development team.
support:2
An issue reported by a commercially licensed client.
type:bug
A bug.
Milestone
Type of report
Bug
Provide detailed reproduction steps (if any)
While performing Undo or Redo, on numerous seemingly random occasions, I've observed messages such as the following in the console:
Uncaught DOMException: Failed to execute 'setStart' on 'Range': There is no child at offset 6
, accompanied by a loss of function of the Undo/Redo keys, as if the snapshot stack had become truncated.The presence of
<br>
's rather than<p>
's appears to be a critical element in this issue. The following sequence provides a repeatable example:Go to https://ckeditor.com/docs/ckeditor4/latest/examples/htmlformatting.html.
Replace the contents of the editor (in Source mode) with the following:
<img alt="" src="https://ckeditor.com/apps/ckfinder/userfiles/images/pebbles.jpg" style="float:left; height:40px; width:60px">
Click Source (to go to WYSIWYG mode)
Click the image
Hit the following keys:
<br>
)<br>
)Expected result
The entered text "foo" should be removed. Further Undos should remove the images.
Actual result
"foo" is removed, but Undo/Redo no longer function.
The following error is observed in the console:
Other details
dialogui,dialog,a11yhelp,about,basicstyles,blockquote,notification,button,toolbar,clipboard,panel,floatpanel,menu,contextmenu,elementspath,indent,indentlist,list,enterkey,entities,popup,filetools,filebrowser,floatingspace,listblock,richcombo,format,horizontalrule,htmlwriter,image,fakeobjects,link,magicline,maximize,pastefromword,pastetext,removeformat,resize,menubutton,scayt,showborders,sourcearea,specialchar,stylescombo,tab,table,tabletools,tableselection,undo,lineutils,widgetselection,widget,notificationaggregator,uploadwidget,uploadimage,wsc,wysiwygarea
The text was updated successfully, but these errors were encountered: