vscode
vscode copied to clipboard
Open file/folder crashes VS Code in Ubuntu 24.04
Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: 1.89.1
- OS Version: Ubuntu 24.04
Steps to Reproduce:
- Launch VS Code with an open folder
- Select any of the following from the File menu and VS Code crashes immediately
- Open File
- Open Folder
- Open Workspace from File
The following work:
- File -> Open Recent
- File -> New Window
The following causes a crash:
- File -> New Window -> Open File -> select a folder to open
- File -> New Window -> Open Folder -> select a folder to open
There could be an issue with the open file due to changes in GNOME 46 Nautilus.
Can you confirm if the issue is present with latest insiders https://code.visualstudio.com/insiders
Can you confirm if the issue is present with latest insiders https://code.visualstudio.com/insiders
There is an error when trying to install.
Can someone suggest a workaround for the time being?
Have the same issue with vscode installed through Ubuntu Snap. Tried the insiders and regular .deb packages and they seem to work fine.
@papanireal Which version of Ubuntu are you using?
@papanireal Which version of Ubuntu are you using?
24.04
I tried again with the latest .deb and there is still an error.
Does this issue occur when all extensions are disabled?: Yes
* VS Code Version: 1.89.1 * OS Version: Ubuntu 24.04Steps to Reproduce:
1. Launch VS Code with an open folder 2. Select any of the following from the File menu and VS Code crashes immediately * Open File * Open Folder * Open Workspace from FileThe following work:
* File -> Open Recent * File -> New WindowThe following causes a crash:
* File -> New Window -> Open File -> select a folder to open * File -> New Window -> Open Folder -> select a folder to openThere could be an issue with the open file due to changes in GNOME 46 Nautilus.
I had the same problem since I updated VSCode today, it was instant closing, not even opening the main menu. What worked for me was uninstalling all vscode and autoremove after. Then, installing it from the official webpage .deb file, with that, I solved it
@papanireal @Lexslogic Are you using Gnome 46 Wayland desktop?
I had the same problem since I updated VSCode today, it was instant closing, not even opening the main menu.
Same here after updating the VSCode from snap. Now, I have lost access to VS Code completely. The issue which was reported, extended to a complete failure.
Next ....
- Uninstalled VS Code from App Center
autoremove --purge- Re-installed from App Center
- Same problem
Next ...
- Uninstalled VS Code from App Center
autoremove --purge- Downloaded
code_1.90.0-1717531825_amd64.debfrom https://code.visualstudio.com/Download - Right-click -> Open With... -> GDebi Package Installer
- "Error: Dependency is not satisfiable: libglib 2.0-0 (>= 2.37.3)"
Error: Dependency is not satisfiable: libglib 2.0-0 (>= 2.37.3)
MySQL Workbench - Dependency Issue You want the deb for ubuntu 22.04, not 23.10.
I had the same issue for three days, but now the Vscode doesnt even start anymore Please fix ASAP
OS: Ubuntu 24.04 (Xorg)
Does the following have any relevance? If so, how can it be fixed?
~/.config/Code/logs/20240607T005226/main.log
2024-06-07 00:52:27.002 [info] update#setState idle 2024-06-07 00:52:27.935 [error] vscode-file: Refused to load resource /snap/code/159/usr/share/code/resources/app/extensions/theme-seti/icons/seti.woff from vscode-file: protocol (original URL: vscode-file://vscode-app/snap/code/159/usr/share/code/resources/app/extensions/theme-seti/icons/seti.woff)
However, there is no /snap/code/159
From Visual Studio Code crashes on Ubuntu 22.04.4 LTS
This also works (No need to reinstall or downgrade)
code --in-process-gpu
Above works for me too, although ...
$ code --in-process-gpu
Warning: 'in-process-gpu' is not in the list of known options, but still passed to Electron/Chromium.
I got same issues today and have been unable to resolve this. Vs code closes almost immediately I attempt to open it. I haven't installed any new extension since I last used it a few hours ago.
I just resolved mine now. I downloaded the deb file from vscode's site, installed it using:
sudo dpkg -i [file_path/file_name.deb]
This solved my isses:
Note: remember to uninstall the previous vscode you have before or after doing this avoid confusions
I can also confirm that uninstalling via snap & manually installing code_1.90.0-1717531825_amd64.deb fixes the issue.
sudo dpkg -i code_1.90.0-1717531825_amd64.deb
It seems there is an issue with the snap code installation.
No errors in ~/.config/Code/logs/20240607T130517/main.log
Note: Although I exported my settings and extensions before uninstal, snap uninstall didn't remove the extensions from ~/.vscode and everything was there after manually installing above (which was great).
I also had VSCode crash on Ubuntu 24.04 but right now, after installing all the updates from apt-get and snap and rebooting, VSCode works fine. I didn't do any hacks to fix it myself (like disabling wayland, etc).
Version: 1.90.0
Commit: 89de5a8d4d6205e5b11647eb6a74844ca23d2573
Date: 2024-06-04T19:43:07.605Z
Electron: 29.4.0
ElectronBuildId: 9593362
Chromium: 122.0.6261.156
Node.js: 20.9.0
V8: 12.2.281.27-electron.0
OS: Linux x64 6.8.0-35-generic snap
Update: VSCode was working fine a day or two with external monitor. Then I unplugged the monitor and VSCode started crashing again. Plugged the monitor back - VSCode works fine :)
nope, snap code (160) (=1.90.0) is a total failure. same for the .deb package. what a fubar.
Same problem here:
vscode-file: Refused to load resource /snap/code/159/usr/share/code/resources/app/extensions/theme-seti/icons/seti.woff from vscode-file: protocol (original URL: vscode-file://vscode-app/snap/code/159/usr/share/code/resources/app/extensions/theme-seti/icons/seti.woff)
Same here, but VS Code crashes immediately when starting it.
ubuntu 24.04 vs code 1.90
code --in-process-gpu
I had same issue and it also works for me.
If your VSCode crashes immediately you open it. Perhaps you have installed it through the App Center. To solve this issue, Uninstall VSCode from App Center and follow the following steps;
-
First, download and install the GPG key to trust packages from the Microsoft repository:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg sudo install -o root -g root -m 644 packages.microsoft.gpg /etc/apt/trusted.gpg.d/ rm packages.microsoft.gpg -
Next, add the Visual Studio Code repository to your system's software sources list:
echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" | sudo tee /etc/apt/sources.list.d/vscode.list -
Finally, update your package lists and install Visual Studio Code:
sudo apt-get updatesudo apt-get install code
Following these 3 simple steps should definitely fix your issue. Have a great time coding with VSCode!
just updated the snap version, got 1.90.1 and it doesn't crash anymore
It's still crashed on Fedora even with the latest version :/
I solved that by removing "recent" items from Open folder dialog, type this in terminal:
rm ~/.local/share/recently-used.xbel
If your VSCode crashes immediately you open it. Perhaps you have installed it through the App Center. To solve this issue, Uninstall VSCode from App Center and follow the following steps;
- First, download and install the GPG key to trust packages from the Microsoft repository:
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg sudo install -o root -g root -m 644 packages.microsoft.gpg /etc/apt/trusted.gpg.d/ rm packages.microsoft.gpg- Next, add the Visual Studio Code repository to your system's software sources list:
echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" | sudo tee /etc/apt/sources.list.d/vscode.list- Finally, update your package lists and install Visual Studio Code:
sudo apt-get updatesudo apt-get install codeFollowing these 3 simple steps should definitely fix your issue. Have a great time coding with VSCode!
Thanks @Olorunnisola01 , it works perfect to me
The new veraion seems fixed problem
This is such a laughable problem to have for Microsoft when they can't stop bragging about how much they love open-source.
This is happening to me also with the latest snap version on Ubuntu 24.04, but it doesn't happen with all folders and of note it doesn't happen at all in Kubuntu 24.04 with plasma.
Who said it only happen on snap package is a liar. I am anti-snap person, it is a bug from VScode. Now they seems fix it