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

VSCode unresponsive for 1-2 seconds when switching between windows #203442

Closed
artemudovyk opened this issue Jan 25, 2024 · 9 comments
Closed

VSCode unresponsive for 1-2 seconds when switching between windows #203442

artemudovyk opened this issue Jan 25, 2024 · 9 comments
Assignees
Labels
freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues

Comments

@artemudovyk
Copy link

artemudovyk commented Jan 25, 2024

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.85.2, x64.
  • OS Version: Fedora Linux 39 (Workstation Edition), Wayland, AMD GPU.

Steps to Reproduce:

  1. Open 2 VSCode windows (maximized).
  2. Open the first one, then switch to the second one. It will be unresponsive for 1-2 seconds.

Demo video:

2024-01-25.13-19-12.mp4

Happens only with 2+ VSCode (or 2+ VSCode Insiders) windows. If I'd open a VSCode + VSCode Insiders - it's fine. Switching between different apps (VSCode + Firefox, for example) is also fine.

If I don't maximize windows and keep them in window mode, it's fine:

2024-01-25.13-21-29.mp4

What I tried and it didn't help:

  • Install VSCode Insiders. The same happens with 2 windows of VSCode Insiders, but not if one is VSCode and the other is VSCode Insiders. But it's not optimal because something will still lag with 3+ projects opened.
  • Disable hardware acceleration.
  • Disable all extensions.
@bpasero
Copy link
Member

bpasero commented Jan 25, 2024

Can you try to reproduce with our nightly insider builds? You can give our preview releases a try from: https://code.visualstudio.com/insiders/

@bpasero bpasero added info-needed Issue requires more information from poster freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues labels Jan 25, 2024
@artemudovyk
Copy link
Author

artemudovyk commented Jan 25, 2024

I've updated VSCode Insiders today with the package manager and am currently on version 1.86.0-insider. Or is there a more recent version?

It's better, but not resolved entirely:

2024-01-25.15-19-10.mp4

Specific timecodes:

  • 0:18
  • 0:30
  • 0:46

@bpasero bpasero removed the info-needed Issue requires more information from poster label Jan 25, 2024
@bpasero bpasero removed their assignment Jan 25, 2024
@bpasero
Copy link
Member

bpasero commented Jan 25, 2024

Thanks for the video, this looks like a window manager or upstream issue to me.

@artemudovyk
Copy link
Author

artemudovyk commented Jan 30, 2024

The latest build of VSCode Insider suffers from the same problem - it now occurs almost every time switching windows, contrary to five days ago when it could lag sometimes, but was fine for the most part.

Version: 1.86.0-insider
Commit: 9c5eabb
Date: 2024-01-30T03:55:53.004Z
Electron: 27.2.3
ElectronBuildId: 26495564
Chromium: 118.0.5993.159
Node.js: 18.17.1
V8: 11.8.172.18-electron.0
OS: Linux x64 6.6.13-200.fc39.x86_64

2024-01-30.18-09-33.mp4

@yesccx
Copy link

yesccx commented Apr 20, 2024

Is there currently a solution? I have also encountered the same problem.

@artemudovyk
Copy link
Author

artemudovyk commented Apr 20, 2024

Didn't find one and no update up to this date fixed the issue on any VS code versions. Installed code and code-insiders and when there's a need to work open 2 projects, I'll just use each of them to open 1 project.
I've tried KDE instead of GNOME DE, and the problem didn't occur there. But I tested it very briefly, so not 100% sure.
For now, I'm waiting for a Fedora 40 to be stable with a new version of GNOME, and I hope it will resolve the problem with a VS Code.

@artemudovyk
Copy link
Author

artemudovyk commented Apr 25, 2024

I've upgraded to Fedora 40 (GNOME 46). The issue persists.

Tinkered with it a bit, and found out that VSCode launches in XWayland instead of Wayland. When launching VSCode or VSCode insiders with flags to launch in Wayland (something like code --enable-features=UseOzonePlatform --ozone-platform=wayland --enable-features=WaylandWindowDecorations), lags when switching between windows doesn't appear anymore.

Another issue is that I can't pin the app in the Dash to Panel when the VSCode launches with the options I've mentioned above, as it treats it as a different application. So the experience is not optimal on that front.

Related to #207033

@artemudovyk
Copy link
Author

artemudovyk commented Sep 23, 2024

Fixed by forcing Wayland.

@deepak1556
Copy link
Collaborator

closing per above comment

@deepak1556 deepak1556 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues
Projects
None yet
Development

No branches or pull requests

4 participants