Skip to content

Windows: several lines sent from the terminal lens's input line on a phone still send the first line alone to an agent #269

Closed

Description

@devswha

What happens

#267 fixed a multi-line paste typed into a mirrored terminal on a Windows PC: the block now reaches an agent as one bracketed paste and stays in its message box. That fix sits on the input frame path.

The input line of the terminal lens on a touch screen takes another path. It shapes several lines by xterm's bracketedPasteMode (src/components/PaneTerminal.tsx, the input line's submit), which a mirror repaint never turns on (server/mirror.ts, mirrorFrame), and sends them CR-joined through submit to pane.send_text without mirrorInput. An agent on that pane is expected to take the first line break for Enter and send line one alone, as #257 showed for the input path.

The same holds for a Linux or macOS bridge that mirrors because it has no PTY sidecar (#265): its mirrored panes get no markers either.

Expected

Several lines sent to an agent from the input line stay in its message box until sent, as they do from a paste into the terminal.

Notes

Activity

  1. devswha commented on Oct 1, 2026

    @devswha
    OwnerAuthor

    #281 covers the Windows case: several lines sent from the input line to an agent on a mirrored Windows pane now go as one paste. Checked on a real Windows PC with gjc (one user message holding both lines).

    Still open here: a Linux or macOS bridge that mirrors because it has no PTY sidecar (#265). mirrorInput wraps only on win32, on both the input and the submit path, so its mirrored agent panes still get bare lines. Not reproduced on such a bridge yet.

  2. devswha commented on Oct 2, 2026

    @devswha
    OwnerAuthor

    Fixed by #290 (and #281 for the Windows part).

    Reproduced on Linux first: herdr 0.9.0 hands pane.send_text to the program byte for byte, with no paste markers even where the program turned bracketed paste on (cat -v after ESC[?2004h). With a server that mirrors (terminalAttach: false) and gjc in the pane, two lines sent the way the terminal's input line sends them went as two messages: gjc answered the first line alone. After #290 the same two lines arrive as one message.

    Not checked: a real remote PC that has no Node (the mirror was forced by an option), and the paste-into-terminal path on Linux, which goes through the same function.

  3. added a commit that references this issue on Oct 2, 2026
    9a1797a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions