Eugeny / tabby

A terminal for a more modern age
https://tabby.sh
MIT License
59.27k stars 3.4k forks source link

It's lagging. #9378

Closed Amaderis closed 4 months ago

Amaderis commented 10 months ago

Terrible lag when typing on the server. But in another SSH client (MobaXterm) everything is smooth and without such delays. It is impossible to work on data center nodes at all. I really like this application, better than MobaXterm. But this problem is very stressful.

Version: 1.0.205 Platform: Windows x64 10.0.22631 Plugins: none Frontend: xterm-webgl

atlas-eric commented 10 months ago

V1.0.205 The large prompt lag on my new installed M2-Mac One tab open only

Makes it barely useable.

gitmatters commented 9 months ago

Use version 1.0.197 . It's the last version, where ssh and x11 forwarding working flawlessly.

element0xE commented 8 months ago

Use version 1.0.197 . It's the last version, where ssh and x11 forwarding working flawlessly.

I can confirm the typing expirience tru SSH is flawless with version 1.0.197 MacOS Sonoma 14.3.1 | M2 Max

atlas-eric commented 8 months ago

Correct. I went back too and 1.0.197 works great. Sonoma both Intel and M2 versions

Eugeny commented 8 months ago

Could you please record a performance trace on the new version using the built-in debug tools?

atlas-eric commented 8 months ago

How do I connect the Tabby app to the Chrome Dev Tools, for that performance trace?

On Tue, Feb 27, 2024 at 5:50 PM Eugene @.***> wrote:

Could you please record a performance trace https://developer.chrome.com/docs/devtools/performance/reference#record-runtime on the new version using the built-in debug tools?

— Reply to this email directly, view it on GitHub https://github.com/Eugeny/tabby/issues/9378#issuecomment-1967090463, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4JPRLBE6ADLH32TYHJPWXTYVYFGHAVCNFSM6AAAAABBQ7A3YCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNRXGA4TANBWGM . You are receiving this because you commented.Message ID: @.***>

Eugeny commented 8 months ago

Tabby has them built in, it's in Settings -> Application -> Debugging

element0xE commented 8 months ago

image This is a screenshot of the trace performance record result (idk if is useful ), of me typing docker container ls connected to a remote machine via SSH using Tabby 1.0.207.

The lag is present on version Version 1.0.207 (1.0.207) and MacOS Sonoma 14.3.1 | M2 Max

Usually an Electron app like tabby let the user export the performance profile , in order to share it ( https://developer.chrome.com/docs/devtools/performance/reference#save ) but this is not the case , when I click to Save Profile button , no save dialog is appearing image Is Tabby 1.0.207 saving the record in a specific path ?

PS: I can confirm that on Tabby Version 1.0.197 (the version with no LAG on SSH connections ), I can succesfully save the Performance record into the file, in this version the save button is correctly opening the file Dialog. Le me know if the performance record of the working version could be needed.

Chrome for Developers
Performance features reference  |  DevTools  |  Chrome for Developers
A reference on all the ways to record and analyze performance in Chrome DevTools.
Eugeny commented 8 months ago

That's weird - it works for me via the toolbar button:

Screenshot 2024-03-11 at 21 19 03
Eziou commented 8 months ago

Same, v1.0.207 and severe lag on my new m3 pro macbook, macos Sonoma 14.4.

gitmatters commented 8 months ago

Please also note #8968 where I also described the issue.

element0xE commented 8 months ago

That's weird - it works for me via the toolbar button:

Screenshot 2024-03-11 at 21 19 03

I have attempted to save the performance profile multiple times. When I start recording the profile on a local terminal, the save dialog appears correctly, but when I click 'Save', the following error is printed in the console. This results in a 0 byte saved file. [2728:0313/182625.971232:ERROR:CONSOLE(1)] "Error: The request is not allowed by the user agent or the platform in the current context.", source: devtools://devtools/bundled/panels/timeline/timeline.js (1) image


If I try to record the profile during an SSH session the Save dialog does not appear as expected. Let me know if you need more specific screenshot maybe can be usefuel.

element0xE commented 6 months ago

Any update on this issue ? People are still opening new issues about it , I think SSH connection is one of the core features of Tabby and we should focus on it.

atlas-eric commented 6 months ago

Hi Mattia, Thanks so much for your follow up. Eric is away on holiday and will get back to you next week. Until then, be well! Matt

On Wed, Apr 24, 2024 at 12:26 AM Mattia Russo @.***> wrote:

Any update on this issue ? People are still opening new issues about it , I think SSH connection is one of the core features of Tabby and should focus on it.

— Reply to this email directly, view it on GitHub https://github.com/Eugeny/tabby/issues/9378#issuecomment-2074257905, or unsubscribe https://github.com/notifications/unsubscribe-auth/A4JPRLCGCKSKKU6ABCLIOMDY65M77AVCNFSM6AAAAABBQ7A3YCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANZUGI2TOOJQGU . You are receiving this because you commented.Message ID: @.***>

sterid commented 6 months ago

Any update on this issue ? People are still opening new issues about it , I think SSH connection is one of the core features of Tabby and we should focus on it.

totally agree

fhackenberger commented 6 months ago

Same issues with 1.0.207 on Ubuntu 23.10. Version 1.0.197 works nicely without any lagging. For me it's unrelated to using SSH or not. It also lags locally. I'm also unable to save a performance trace unfortunately.

bristlehog commented 5 months ago

Same issue for me with Tabby 1.0.207 for Windows 11 Home, but it lags only when working through SSH, while the local terminal doesn't lag. There's a noticeable lag between every keypress and the letter actually appearing on the screen.

I've tried to do a performance profile, but couldn't save it - the save button just does nothing. Attaching the profile screenshot - there are some dropped frames, but not sure if they're to blame or not.

tabby_perf_profile

h1v9 commented 4 months ago

Same issue here. Windows 11 22H2, Ryzen 5800X, RTX 2070

I did some testing and only keyboard input via ssh seems to be lagging. Local shell works perfectly fine. Htop with low delay seems not to be skipping frames either.

More specifically I tested alpha 208, 198 and 197. (Input) lag seem present on both 208 and 198, but not on 197. Coincidentially, profile saving does not work on both 208 and 198. On 208 nothing happens when pressing the save button, on 198 the following error gets presented in console Failed to save timeline: The request is not allowed by the user agent or the platform in the current context. (NotAllowedError) Profile saving works fine on 197.

Having had a look at the profile themselves I'm not sure where the lagging comes from. On 208 there are some long dropped frames present but I couldn't reproduce them 198. There are some Partially Presented Frames on 198 but those are present also on 197, so they do not seem related to the issue.

EDIT: I also just had another look with Wireshark and the problem could be network related. Alpha 197 packets get correctly recognized as SSHv2 while Alpha 198 get recognized just as "SSH". Moreover, more ACK packets seem to be present between each SSH packet on Alpha 198 compared to Alpha 197. I halso tested Mobaxterm and its behaviour is closer to Alpha 197 (recognized as SSHv2, even less ACK packets) than Alpha 198

h1v9 commented 4 months ago

Problem seems to be related to newer ssh2 package versions. I managed to build Alpha 208 with the old ssh2 used in Alpha 197 (Eugeny/ssh2#9de907d62907d6d45debdcc0ed8dda5b7b19dc7c, seems to be a slightly modified version of ssh2 1.11) and it works perfectly fine without any lag

Now I'm no ssh expert, but in case anyone would want to have a look at what could be the cause here's the comparison of the two versions https://github.com/mscdex/ssh2/compare/24b497ddf2d727ecf3e3e6d414a5ba6172fe320f...v1.14.0

gitmatters commented 4 months ago

@mscdex can you have a look at what @Vadhvis found out. It seems like there is an issue with ssh2 version 1.12+, which causes major constraints for Tabby.

mscdex commented 4 months ago

Try adding client.setNoDelay(true); once connected. Other than that, I have no suggestions.

h1v9 commented 4 months ago

Try adding client.setNoDelay(true); once connected. Other than that, I have no suggestions.

Worked like a charm, thanks. I'll prepare a PR tomorrow

atlasstaking commented 4 months ago

Thanks for all the hard work!! Great news!