Maybe the fact that the editor is placed into a DOM dynamically has
 something to do?
 1. Go to [http://ckeditor.com/ Document Editor demo].
 1. Make a partial selectiom on the table, say 2x3 cell
 [[Image(https://i.imgur.com/lsDMhD2.png)]]
 1. Copy to clipboard.
 1. Move selection into another paragraph.
 1. Paste.
 1. Try to make table seleciton on a pasted table.
== Expected
Our custom selection is being made.
== Actual
Exception is thrown:
 {{{
 ckeditor.js?oqkjc5:66 Uncaught TypeError: Cannot read property
 'ownerDocument' of undefined
     at
 window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.dom.element.getDocument
 (ckeditor.js?oqkjc5:66)
     at
 window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.dom.element.getDocumentPosition
 (ckeditor.js?oqkjc5:108)
     at b (ckeditor.js?oqkjc5:1220)
     at
 window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.dom.document.<anonymous>
 (ckeditor.js?oqkjc5:1227)
     at window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.dom.document.c
 (ckeditor.js?oqkjc5:11)
     at
 window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.dom.document.window.CKEDITOR.window.CKEDITOR.dom.CKEDITOR.event.CKEDITOR.event.fire
 (ckeditor.js?oqkjc5:13)
     at HTMLDocument.<anonymous> (ckeditor.js?oqkjc5:58)
 }}}
== Additional Information
 I was able to reproduce it on Chrome, and Edge. Most likely it's
 reproducible on other browsers too.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066>
CKEditor <http://ckeditor.com/>
The text editor for the Internet
Comment (by k.krzton):
 I got the error on hover over pasted table without selecting. It only
 happens if table is copied with header row.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:1>
Comment (by k.krzton):
 I was also unable to reproduce it on regular sample even with identical
 config and build version.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:2>
Comment (by m.lewandowski):
 @k.krzton it might be related to the fact that that the editor on demo is
 attached at runtime. Worth checking out.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:3>
Comment (by k.krzton):
That might be the case, checking now.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:4>
Comment (by k.krzton):
Replying to [comment:3 m.lewandowski]:
 > @k.krzton it might be related to the fact that that the editor on demo
 is attached at runtime. Worth checking out.
That might be the case, checking now.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:4>
Comment (by k.krzton):
 It is somehow strange, I run the website locally and used dev version and
 build version (based on major) with same config and styles and error does
 not occur then. It occurs only with bundled version. I will check how
 different are those two builds.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:5>
Comment (by k.krzton):
 Ok, editor for website is built from the special preset
 https://github.com/ckeditor/ckeditor-presets/blob/demo/presets/demo-build-
 config.js on which the error is reproducible.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:6>
Comment (by k.krzton):
The minimal set of plugins to reproduce the issue:
 {{{
 config.plugins =
         'table,' +
         'tableresize,' +
         'tableselection,' +
         'toolbar,' +
         'wysiwygarea';
 }}}
Look like the issue with `tablerezise` plugin.
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:7>
* status: new => confirmed
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:8>
 * status:  confirmed => closed
 * resolution:   => fixed
Comment:
 See [https://github.com/ckeditor/ckeditor-dev/issues/417 ckeditor
 /ckeditor-dev/issues/417].
--
Ticket URL: <http://dev.ckeditor.com/ticket/17066#comment:9>