zadam / trilium

Build your personal knowledge base with Trilium Notes
GNU Affero General Public License v3.0
27.52k stars 1.88k forks source link

"import into note" from zip look like lost data or content display confusing #1675

Open dolt131943 opened 3 years ago

dolt131943 commented 3 years ago

Relate trilium and OS vesion: 0.45.10, macOs bigSur 11.2.1

I use "import into note" import a zip that export from trilium notes.

It look like lost data or some content display confusion.

orginal document: image

after create new note and import to root, that shown different and look like different note display same content like one note: image

image

new db and import log: trilium-2021-02-22.log

dolt131943 commented 3 years ago

This may be not the import problem. maybe the content display problem.

Sometimes it can also trigger this problem when I use original db (not import one),

reproduce step like this but not necessarily:

  1. open a note, input some text;
  2. Suddenly unable to input a new line, but can edit exists text , but cannot save; (like a bug)
  3. now switch to other empty node, it will always show same content like last edit.
  4. if edit this content , will not be saved.
  5. reopen app or close current tab will solve this problem.

I have found those message in log, maybe the reason : 17:17:28.981 JS Error: Uncaught error: Message: Uncaught CKEditorError: split-operation-position-invalid Read more: https://ckeditor.com/docs/ckeditor5/latest/framework/guides/support/error-codes.html#error-split-operation-position-invalid, URL: http://127.0.0.1:37840/#root/fWPOM4NiHaiE/f8Mw1msWqYjm/EfSLIqjkuUcL/JbHYgD1KiCvm-e36U, Line: 5, Column: 7462, Error object: {"name":"CKEditorError","context":{"baseVersion":104,"splitPosition":{"root":"main","path":[9,18],"stickiness":"toNext"},"howMany":-17,"insertionPosition":{"root":"main","path":[10],"stickiness": "toNone"},"graveyardPosition":null,"__className":"SplitOperation"}}, CKEditorError: split-operation-position-invalid Read more: https://ckeditor.com/docs/ckeditor5/latest/framework/guides/support/error-codes.html#error-split-operation-position-invalid at el._validate (<anonymous>:5:331273) at Fl.on.priority (<anonymous>:5:371012) at Fl.fire (<anonymous>:5:128716) at Fl.<computed> [as applyOperation] (<anonymous>:5:157962) at ol.split (<anonymous>:5:337629) at K_ (<anonymous>:5:770830) at <anonymous>:5:770552 at <anonymous>:5:770728 at Fl.change (<anonymous>:5:371639) at U_.execute (<anonymous>:5:770326)^M Stack: Error at Object.w [as logError] (http://127.0.0.1:37840/app-dist/desktop.js:1:77260) at window.onerror (http://127.0.0.1:37840/app-dist/desktop.js:1:290039) 17:17:29.118 JS Error: Uncaught error: Message: Uncaught CKEditorError: split-operation-position-invalid

full log upload: trilium-2021-02-22.log