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
{{ message }}
Repository navigation
JSONL readers split messages at U+2028/U+2029 on newer Node: an LS in a window title hangs every read of that window #565
On newer Node, node:readline ends a line at U+2028 (LS) and U+2029 (PS) as well as at LF. JSON.stringify leaves both characters raw, so any JSON message carrying them in a string is cut in two by a readline-based JSONL reader. Both halves then fail JSON.parse, and the readers drop them silently.
Version behaviour: checked on this Mac with the same script. Node v22.23.2 gives 1 line; Node v26.7.0 splits {"t":"a b"} into 2. cua's own kernel needs Node 24 or later.
Live evidence (linux171, Linux: the tree text's escapes (\r \n \t) are undocumented for the model, and VT/FF/NEL/LS/PS stay raw (a forging path) #558's x64 check at 657d7f7 and at main cf02ca3, private Xvfb, cua-engine 0.4.4): U+2028 or U+2029 anywhere in node text, a window title or an app id hangs listWindows/getApp. The cell answers "js execution timed out; kernel reset" after 60 s, and that window can never be read. Any app or web page whose title contains LS can therefore block every read of its window. Evidence is on dc-linux171-1e68 in ~/.local/share/cua-171/check558/ (README.md).
Readers to audit (main cf02ca3):src/repl-host/kernel-child.mjs:365 (kernel and worker messages), src/repl-host/supervisor.mjs:736, src/mcp/server.mjs:400 (MCP client requests), src/mcp/http.mjs:275, src/mcp/upstream.mjs:72, src/runtime/engine.mjs:878, src/sandbox/app-server.mjs:40. Some of their writers are the vendor's, which cua can't change, so the fix belongs on the reading side.
Fix
Every JSONL reader cua owns splits on \n only: a small shared splitter that replaces createInterface for JSON channels, with CR trimmed where a channel allows CRLF.
Where cua writes JSONL itself, it may also escape U+2028/U+2029 (/) as defence in depth.
Tests: a message whose string holds LS or PS survives every reader whole, on the Node versions cua supports, including a window title with LS through listWindows on the own host.
Check the macOS own host too. It uses the same kernel-child and supervisor, so a macOS window title with LS likely hangs the same way.
Relation
Found by #558's live check. #558's LS/PS tree escape is correct (unit-tested) but can't be shown live until this lands.
[review-trail] reviewer-high on PR #571: 0e7f3de..97f606e found 4 P2s (2 jsonl.mjs lifecycle issues and probe-runtime fixed in-PR; wire.rs went to #512 and linux-engine-diff to after #568, per ruling 1192). The scoped re-review of 97f606e..cb3eac6 is correct, with no material findings.
Activity
SSFSKIM commentedon Nov 24, 2026
[board] in-progress: Taken by cursor235 (ruling 1190)
SSFSKIM commentedon Nov 24, 2026
[board] in-review: Draft PR #571 (0.29.18); review + live checks pending
#171 M6a: version 0.29.19
jsonl lines(): resume a paused input and let go of it at the end, as …
probe-runtime: read and write the vendor runtime's MCP stream with th…
SSFSKIM commentedon Nov 24, 2026
[review-trail] reviewer-high on PR #571: 0e7f3de..97f606e found 4 P2s (2 jsonl.mjs lifecycle issues and probe-runtime fixed in-PR; wire.rs went to #512 and linux-engine-diff to after #568, per ruling 1192). The scoped re-review of 97f606e..cb3eac6 is correct, with no material findings.
#171 M6a: Linux sessions run on cua's own runtime, with no vendor tre…
Merge origin/main (#568, M6a; 0.29.19) into fix/565-jsonl-separators …
linux-engine-diff: read the engine's stdout at LF only (refs #565)
Plugin 0.29.20: JSONL readers end a line at LF only and writers escap…
JSONL: split lines at LF only and write U+2028/U+2029 escaped (#565) (#…
SSFSKIM commentedon Nov 24, 2026
[board] done: Landed via PR #571 (cua 0.29.20)
Merge origin/main (f6a6002, cua 0.29.20: #565, #568 M6a) into feat/11…
#572: every JSONL line the engine writes escapes U+2028 and U+2029
linux-engine 0.4.5: a Chrome drop under load is answered as it landed (…
#171 M6b pre-flight, revision 2: the re-review's six fixes and ruling…
#171 M6b: retire the vendor's Linux package (cua 0.30.0) (#594)