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 hangs when opening folder in Ubuntu 24.04 #211762

Open
guyrt opened this issue May 1, 2024 · 6 comments
Open

VSCode hangs when opening folder in Ubuntu 24.04 #211762

guyrt opened this issue May 1, 2024 · 6 comments
Assignees

Comments

@guyrt
Copy link

guyrt commented May 1, 2024

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

  • VS Code Version:
1.88.1
e170252f762678dec6ca2cc69aba1570769a5d39
x64
  • OS Version: Ubuntu 24.04 (fresh install)

Steps to Reproduce:

  1. Fresh install ubuntu and vscode (both installed today - code from apt-get)
  2. open code in any folder like "code ."
  3. VSCode hangs.

Last lines in the verbose logs:

[44656:0430/204913.934951:INFO:CONSOLE(655)] "%cTRACE color: #888 CommandService#executeCommand _setContext", source: vscode-file://vscode-app/snap/code/157/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js (655)
[44656:0430/204913.935581:INFO:CONSOLE(655)] "%cTRACE color: #888 [File Watcher (node.js)] stopping file watcher (/XXX/.git/refs/remotes/origin/main (excludes: <none>, includes: ["**/.git/objects/**/**","**/.git/subtree-cache/**/**","**/node_modules/*/**/**","**/.hg/store/**/**"], correlationId: <none>))", source: vscode-file://vscode-app/snap/code/157/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js (655)
[44656:0430/204913.946089:INFO:CONSOLE(655)] "%cTRACE color: #888 [File Watcher (node.js)] Request to start watching: /XXX/.git/refs/remotes/origin/main (excludes: <none>, includes: ["**/.git/objects/**/**","**/.git/subtree-cache/**/**","**/node_modules/*/**/**","**/.hg/store/**/**"], correlationId: <none>)", source: vscode-file://vscode-app/snap/code/157/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js (655)
[44656:0430/204913.946653:INFO:CONSOLE(655)] "%cTRACE color: #888 [File Watcher (node.js)] ignoring a path for watching who's stat info failed to resolve: /XXX/.git/refs/remotes/origin/main (error: Error: ENOENT: no such file or directory, stat '/XXX/.git/refs/remotes/origin/main')", source: vscode-file://vscode-app/snap/code/157/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js (655)
[44656:0430/204913.959913:INFO:CONSOLE(655)] "%cTRACE color: #888 [mainThreadSecretState] Getting password for vscode.github-authentication extension:  github.auth", source: vscode-file://vscode-app/snap/code/157/usr/share/code/resources/app/out/vs/workbench/workbench.desktop.main.js (655)

I tried with folders that aren't tracked in git.

@n7tae
Copy link

n7tae commented May 1, 2024

This is happening with my two fresh Ubuntu 24.04 installs (laptop and desktop). I have tried snap install and apt install. Both fail in the same way: open a folder then click just about anywhere and it locks up vscode.

@lszomoru lszomoru assigned deepak1556 and unassigned lszomoru May 3, 2024
@kmcintyre
Copy link

Same experience here.

@n7tae
Copy link

n7tae commented May 4, 2024

I did finally figure out that for me, opening a folder that contained a .git directory was the problem. If I moved the .git dir to a different name before trying to open it, the folder opened fine. Of course the git info for that folder was not available.

After that, I decided to go back to Ubuntu 24.04. This time VSCode worked fine. I can't say for sure why it's now working, but I did do something different this time when installing 24.04: This time, I followed my laptop's manufacturer's advice and turned off the "Install 3rd party software for for graphics and wifi...". Then after 24.04 was up I added the specified ppa to download drivers from my manufacturer. After that, I installed VSCode.

Yesterday, I did sudo snap refresh and it upgraded VSCode to 1.89 and it's working fine as well.

@hurryman2212
Copy link

hurryman2212 commented May 9, 2024

No update?

EDIT:

Might be related to system Keyring? I was having this issue with the first ever boot session installed with VSCode and it just freezes whenever I open a folder with .git (I'm not sure whether this issue happens recursively).

But after I rebooted it, it suddenly asked for Keyring password, and after I typed it, it works just fine. I don't know. Maybe the Keyring thing is just happned because it was the first run after the first reboot, after VSCode installation, and it was with something else and solved because the reboot has replaced the outdated service for that root cause.

@liheyuan
Copy link

Same experience even if I open a folder that does not contain .git

Try disable wayland, this may work

#212430

@messenjer
Copy link

messenjer commented May 21, 2024

Yes, for me it works when I restart the laptop, after a fresh ubuntu install.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants