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

Terminal input is slow #18263

Open
1 task done
bersace opened this issue Sep 24, 2024 · 10 comments
Open
1 task done

Terminal input is slow #18263

bersace opened this issue Sep 24, 2024 · 10 comments
Labels
bug [core label] can't reproduce Issue that can't be reproduced (transient, invalid, etc) linux linux-wayland Linux Wayland performance Feedback for performance issues, speed, memory usage, etc terminal Feedback for terminal integration, shell commands, etc

Comments

@bersace
Copy link

bersace commented Sep 24, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

Hi,

Thanks for Zed. It's getting better and better every weeks.

I adopted Zed the day it was available for Linux. I already use alacritty as my terminal, it's super fast. Ever since, typing in Zed embedded terminal is slow. Sometime, it's snappy. But most of the time, it stutters.

Environment

Zed: v0.153.6 (Zed)
OS: Linux Wayland debian 12
Memory: 15.3 GiB
Architecture: x86_64
GPU: Intel(R) UHD Graphics 620 (WHL GT2) || Intel open-source Mesa driver || Mesa 22.3.6

If applicable, add mockups / screenshots to help explain present your vision of the feature

I don't know how to investigate this. I'm open to help.

If applicable, attach your Zed.log file to this issue.

I did not found anything special regarding this in Zed log.

Regards,
Étienne

@bersace bersace added admin read bug [core label] labels Sep 24, 2024
@bitfield
Copy link

This bothers me too (on macOS). It's not that the terminal is slow, per se—it doesn't visibly lag when writing lots of output. The problem seems to be the keystroke latency, especially when editing the command line.

For example, if you simply hold down the spacebar, you can see the cursor stuttering and juddering, slowing down and speeding up from time to time as it struggles to keep up. It's annoying enough that I now switch to a dedicated terminal app when doing anything non-trivial in the Zed terminal.

@JosephTLyons JosephTLyons added performance Feedback for performance issues, speed, memory usage, etc terminal Feedback for terminal integration, shell commands, etc linux linux-wayland Linux Wayland can't reproduce Issue that can't be reproduced (transient, invalid, etc) and removed triage labels Oct 1, 2024
@JosephTLyons
Copy link
Collaborator

Would love to see a screen video of this, as I can't seem to reproduce it on my end on macOS (haven't tested on Linux yet).

@bersace
Copy link
Author

bersace commented Oct 3, 2024

@JosephTLyons , thanks for your attention.

Here zed is struggling:

zed.webm

While alacritty is fine enough (inside Zellij):

alacritty.webm

@Sh4d1
Copy link

Sh4d1 commented Oct 9, 2024

I noticed the same (Linux, 0.156.0), but mostly in nvim inside zed

@failable
Copy link

Same issue especially when using helix in terminal.

@Resince
Copy link

Resince commented Nov 5, 2024

Same issue especially when using msys2 and powershell on windows in terminal.

@Seltonu
Copy link

Seltonu commented Nov 9, 2024

Similar issue using remote ssh with zed, I believe it's related to network performance. The character input in terminal has extremely high latency on poor network connections (coffee shop, hotel, etc). It sometimes becomes unbearably slow to type with characters appearing a few seconds after input. The issue isn't present with a strong/fast internet connection.. Seems for ssh, the terminal rendering each character is network dependent (send character -> receive confirmation -> render?)

@joelazar
Copy link

I can see the same input lag on macOS as well, when I open up Neovim (even if I start it in --clean mode) in the Zed terminal. It's a bit annoying, as I'm using Neovim to resolve merge conflicts, but the terminal gets so slow that I have to use something else.

@joelazar
Copy link

joelazar commented Dec 1, 2024

I noticed that when I open a remote session with Zed and launch a terminal and Neovim on the host, I cannot detect the stuttering that occurs in a local session.

@joelazar
Copy link

joelazar commented Dec 2, 2024

Okay, one more thing, I have a hunch that it might be related somehow to how much I zoomed in on the terminal. I managed to reproduce it quite deterministically by zooming in and out in the terminal and stepping on j and k in Neovim. As I zoom out, after a certain time, the scrolling of the buffer freezes until I stop pressing the key again.

Screen.Recording.2024-12-03.at.00.01.33.mov

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug [core label] can't reproduce Issue that can't be reproduced (transient, invalid, etc) linux linux-wayland Linux Wayland performance Feedback for performance issues, speed, memory usage, etc terminal Feedback for terminal integration, shell commands, etc
Projects
None yet
Development

No branches or pull requests

9 participants