#10391·notesnook

Crash "Inserted content deeper than insertion position" when pressing Return while certain elements are selected

Author: k9janerCreated Sep 16, 2026Updated Sep 16, 2026

What happened?

Under a lot of circumstances Notesnook crashes when pressing RETURN while a line with certain elements is selected

Steps to reproduce the problem

For example:

  1. Create a new note
  2. Press RETURN while in the description field to create a new line
  3. Hold "Shift" and press "ARROW UP" to select both lines.
  4. Press RETURN

Result: The app crashes.

I don't fully understand under which circumstances the crash can happen. It seems to be related to special elements in a selection and maybe they need to be the first character in a selection. It seems like most/all special elements can cause this crash, it could be the default "Start writing your note..." block, a hyperlink, a quote, etc.

However sometimes I can e. g. replace a selected hyperlink with a new line by pressing Return WITHOUT a crash and sometimes it DOES crash.

Version

3.4.6-7235196-desktop (Flatpak)

Platform/OS

Linux

Relevant log output

bash
TransformError: Inserted content deeper than insertion position
TransformError: Inserted content deeper than insertion position
    at new t (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:6:13538)
    at L_.step (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:6:13883)
    at k_ (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:6:1330)
    at L_.split (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:6:15451)
    at https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:14:19056
    at Object.splitBlock (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:11:9183)
    at Array.<anonymous> (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:14:26755)
    at https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:14:3781
    at Object.first (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:11:8149)
    at Enter (https://app.notesnook.com/assets/app-Bpyf2PFdsS73.js:14:26653)