You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error: Invalid offset - splits unicode bytes
at unicount.strPosToUni (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:99249:13)
at exports2.dlen (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:99332:70)
at checkOp (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:99281:26)
at Object.apply (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:99583:11)
at drop2 (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:146616:57)
at Object.apply2 [as apply] (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:146621:9)
at JSONState._apply (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:147289:44)
at JSONState._flushOperationCache (file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:147442:10)
at file:///Applications/marktext.app/Contents/Resources/app.asar/out/renderer/assets/index-BXt6R5Ri.js:147422:12
Version
MarkText: v0.20.0-rc.1
Operating system: Darwin arm64 25.5.0 (darwin)
Invalid offset - splits unicode bytes is the emoji deletion crash tracked in #4926. With the caret right after an emoji at the end of a paragraph (or just before inline markup such as **), Backspace removed only half of the emoji's UTF-16 surrogate pair. The editor's text operations can't encode that leftover half, so that edit and every edit after it threw this error. Depending on what came next, the stack ends in apply (the next Backspace) or in compose / xfBoundary (any later edit) — your stack is one of these.
The fixes will ship in the next release after v0.20.0-rc.2. If you still see this error on that release, please open a new issue with the steps (the text you were editing and the keys you pressed).
Activity
Jocs commentedon Sep 14, 2026
Thanks for the report!
Invalid offset - splits unicode bytesis the emoji deletion crash tracked in #4926. With the caret right after an emoji at the end of a paragraph (or just before inline markup such as**), Backspace removed only half of the emoji's UTF-16 surrogate pair. The editor's text operations can't encode that leftover half, so that edit and every edit after it threw this error. Depending on what came next, the stack ends inapply(the next Backspace) or incompose/xfBoundary(any later edit) — your stack is one of these.It is fixed on
develop:The fixes will ship in the next release after v0.20.0-rc.2. If you still see this error on that release, please open a new issue with the steps (the text you were editing and the keys you pressed).