Windows build number: Win32NT 10.0.18362.0 Microsoft Windows NT 10.0.18362.0
Windows Terminal version (if applicable): latest
ssh into a remote host, execute a command that spits a lot of output
In putty when the connection to a remote host is slow and a command spits a lot of output and that output comes back in frames(due to the slow connection) then I can just fine switch between SCREEN tabs. In windows terminal this is not possible. I am not even able to switch between tabs of the windows terminal until the command previous executed does not finish its output.
Need to wait for full command output before I can do anything else in the windows terminal.
@izghitu I believe your report is a duplicate of https://github.com/microsoft/terminal/issues/6258 which is specifically about Ctrl-C but I am sure that same situation applies to any control sequence, like those used in GNU screen.
@izghitu Which ssh are you using? The ssh.exe that ships with Windows, or one from WSL (or some other one)? And which version?
Also latest doesn't really help as a version number, because at the time of your post, latest could have either meant 1.0, 1.1, or 1.2, depending if you were on the preview or release builds, and if you had gotten the release that shipped on the 22nd. Which WT version number exactly?
@jblaine this doesn't _really_ sound like it's related to Ctrl+C to me at all. Here OP is just trying to switch tabs in screen, which isn't working (and is reasonable if the output is being heavily buffered), nor is switching Terminal tabs (which is really quite surprising)
@zadjii-msft I use the ssh.exe that ships with WIndows. Its location is:
C:\\Windows\\System32\\OpenSSH\\ssh.exe
The version of the WT is Version: 1.1.2021.0
Some other questions from #7191:
tmux/screen running on the remote host?ssh from a WSL distro?wsl.exe ssh.exe <args to ssh...> inside a legacy powershell/cmd window, does the same issue repro? This will cause wsl to create a conpty to host ssh.exe, which could help identify if the issue is conpty vs something else.@zadjii-msft My hour of testing showed the following for what I'm experiencing.
Windows build number: Microsoft Windows [Version 10.0.18363.959]
Windows Terminal version (if applicable): 1.1.2021.0
Windows 10 native ssh client
Remote Linux host running either tmux or GNU screen, multiple versions all work to reproduce issue
Connect via Windows 10 ssh (under Terminal) to a remote host. At the remote host, run a new screen or tmux session OR re-attach to an existing one. Generate a lot of output from a shell in one of the screen or tmux windows. Terminal crawls in batches of text displayed and often becomes unresponsive for periods of time. In my particular case, I am using a Terminal profile with commandLine of "ssh <my args>"
The same behavior can be seen in a WSL distro using the distro's SSH connected to the remote host + attach to screen + cat big file.
It does not happen when running a bare CMD.EXE (outside of Terminal) and then wsl.exe ssh.exe <args to ssh...> + screen resume + cat big file.
After digging around in the open issues here and finding some other issue about slow rendering when colors are at play, I even tested when TERM=vt100 on the remote end and all coloring turned off. The performance issue still exists in that case, so it does not seem to have to do anything with that other color perf. issue.
It does not happen when running a bare CMD.EXE (outside of Terminal) and then
wsl.exe ssh.exe <args to ssh...>+ screen resume + cat big file.
Well that pretty specifically rules out a whole bunch of possible sources of this issue actually. That narrows it down to _specifically_ the Terminal, and rules out conpty, ssh.exe, and screen as possible sources of error.
That being said, I wonder what about the terminal is causing the stuttering. XAML? DX? Scrollbar updating?
Does setting "historySize":0 in your profile help at all? That'll disable scrollback, but might help narrow it down further.
There are also a pair of global renderer settings that might be able to help rule out DX. Does setting either of these to true in the global settings (outside of a profile) change anything?
experimental.rendering.forceFullRepaintexperimental.rendering.softwareNo, none of those helped.
Not sure how related this is to this _exact_ issue, but output seems rather slow in general. I was working to confirm @jblaine 's findings and tried this quick benchmark from 3 different terminals: time bash -c "for i in {1..1000000}; do echo \$i; done;" It shows an order of magnitude slowdown for this terminal:
microsoft terminal:
real 2m53.944s
user 0m15.734s
sys 0m33.375s
wsltty:
real 0m25.828s
user 0m7.188s
sys 0m6.781s
mobaxterm:
real 0m29.078s
user 0m4.203s
sys 0m5.219s
But figured it might help narrow down a cause...
@lucastheisen That's actually something we're dealing with primarily over in #3075, but also in a bunch of different places. I'd keep an eye on that one 馃槈
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.
This should be reopened, please
Thanks. Our bot should be taught to recognize any commenter who can provide additional information.
One more question - are you using a status line in screen or tmux?
Thanks @DHowett. Yes, I do use a statusline in screen. My tmux testing was only for this issue. I don't use tmux in my daily life.
Okay, excellent. Thanks.
We have a pathological redraw case when there are sub-full-screen scrolling regions active (like, where there鈥檚 a status line). We end up retransmitting the entire contents of the screen _for every line_ between the backend and frontend processes in Terminal. The contention on the output queue bogs down the input queue.
I believe we have another version of this lying around somewhere, so I鈥檒l assign myself to deduplicate.
Just messaged Dustin about this - turns out there's _not_ another dupe for this one! _This is now the tracking thread for this issue_. Thanks!