fix: use stdbuf -o0 cat for unbuffered pipe input, remove debug

- Changed cat subprocess to stdbuf -o0 cat (unbuffered output)
  so characters arrive immediately through the pipe
- Added cat PID to startup messages for diagnostics
- Removed pipe debug logging (trace.log, pipe.log)
- Cat pipe input confirmed working: read-char returns #\a, #\b, #\Newline
- Remaining issue: frame-message format mismatch with daemon
  (pre-existing, not related to input changes)
This commit is contained in:
2026-05-14 12:43:00 -04:00
parent b9a4318ef8
commit c0d0ddfeec

View File

@@ -912,11 +912,12 @@ Event handlers + daemon I/O + main loop.
;; works. A cat subprocess inherits the terminal and provides
;; bytes through a pipe that SBCL reads reliably.
(uiop:run-program '("stty" "-echo") :output nil :ignore-error-status t)
(let* ((cat-proc (uiop:launch-program '("cat")
(let* ((cat-proc (uiop:launch-program '("stdbuf" "-o0" "cat")
:output :stream
:input :interactive
:stderr nil))
(tty-in (uiop:process-info-output cat-proc)))
(add-msg :system (format nil "* cat pid=~a *" (uiop:process-info-pid cat-proc)))
;; Log backend info and terminal dimensions
(cl-tty.backend:backend-clear be)
(view-status be w h)