Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pasting multiline text not working (in shell, vi and hangs kakoune) #17449

Open
ant5 opened this issue Jun 19, 2024 · 3 comments
Open

Pasting multiline text not working (in shell, vi and hangs kakoune) #17449

ant5 opened this issue Jun 19, 2024 · 3 comments
Labels
Area-Input Related to input processing (key presses, mouse, etc.) Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-2 A description (P2) Product-Terminal The new Windows Terminal.

Comments

@ant5
Copy link

ant5 commented Jun 19, 2024

Windows Terminal version

1.21.1382.0

Windows build number

10.0.19045.4291

Other Software

QEMU 9.0 with FreeBSD 14.1 guest.
vi 2.2.1
kakoune-2024.05.18

Evironment:
TERM=xterm-256color

Steps to reproduce

Copy multiline text:

builder {
        host.hostname = "builder";
        path = "/ws/builder";
        ip4 = "inherit";
        #ip4.addr = "igb0|192.168.0.28/25";
        #ip4.addr = "lo0|127.0.3.1/24";
        allow.raw_sockets = 1;
        exec.consolelog = "/var/log/jails/${name}_console.log";
        #mount.fdescfs;
    #mount.fstab="/etc/ws/${name}.fstab";
        mount.procfs;
        allow.set_hostname = 0;
        exec.start = "/bin/sh /etc/rc";
        exec.stop = "/bin/sh /etc/rc.shutdown";
        exec.clean;
        allow.mount;
    allow.mount.zfs;
    allow.mount.nullfs;
  1. Run vi editor. Press i for insert mode. Paste text.
  2. Run vi editor. Press \i for insert mode with no-hook processing. Paste text.

Expected Behavior

Pasted text inside editor.

Actual Behavior

  1. vi editor. WindowsTerminal ask about pasting multiline text. Then only two lines of text pasted:
    image

  2. kakoune editor. WindowsTerminal do not ask about pasting multiline text. Nothing happen on screen but kakoune hangs in mean of not responding to any key press:

image

Also in a pure sh shell pasting behave like in vi (pasted only first two lines):

image

@ant5 ant5 added Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Jun 19, 2024
@lhecker
Copy link
Member

lhecker commented Jun 19, 2024

Could this be the same as #17384?

@ant5
Copy link
Author

ant5 commented Jun 19, 2024

May be there is a relation but I dont't feel it the same:

  1. Deadlock when pasting >5 KiB into an application that doesn't read it fast enough #17384 uses WSL
  2. Deadlock when pasting >5 KiB into an application that doesn't read it fast enough #17384 goes to deadlock. In my case neither shell nor vi hangs. Kakoune hangs (stop responding) but if I'm inside tmux I can TERM it easily.
  3. Deadlock when pasting >5 KiB into an application that doesn't read it fast enough #17384 has 4096 bytes pasted. In my case just two lines really pasted (appear).

As you can see on screenshot WT really send all text to paste but something brokes. May be it related to CR/LF.

Also I must add some info: on WT command chcp 65001 ran before QEMU run.

@ant5
Copy link
Author

ant5 commented Jun 20, 2024

I looked at screenshots more carefully and found strange thing.

WT send text with CR as newline separator. Does it have to send LF or CRLF?

@PankajBhojwani PankajBhojwani added Area-Input Related to input processing (key presses, mouse, etc.) Product-Terminal The new Windows Terminal. and removed Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Jun 26, 2024
@PankajBhojwani PankajBhojwani added this to the Terminal v1.22 milestone Jun 26, 2024
@PankajBhojwani PankajBhojwani added the Priority-2 A description (P2) label Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Input Related to input processing (key presses, mouse, etc.) Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-2 A description (P2) Product-Terminal The new Windows Terminal.
Projects
None yet
Development

No branches or pull requests

3 participants