Linux users report Microsoft's Visual Studio Code Snap package isn't actually deleting files

How to delete your account at Amazon, Facebook, Google or Microsoft

  • VS Code Snap package bug on Linux keeps deleted files, clogging hard drives
  • Snap creates separate local Trash folders per version, compounding storage issues
  • No fix yet; users advised to install VS Code via .deb/.rpm or Flatpak instead of Snap

Microsoft’s Visual Studio Code, installed as a Snap package on a Linux device, has a strange bug that keeps all the files users deleted, clogging up hard drives as a result, leading to a myriad of other problems for the users.

The bug was first spotted by a couple of software developers, who found gigabytes of files that were supposed to be deleted. Some of them discovered the bug after completely running out of space on their computers.

The Register notes the flaw was first detected more than a year ago, and a bug report was published in early November 2024. In the report, it was said that the cause of the issue lies in Snap creating a local Trash folder for each VS Code version, instead of simply using the system one.

Unaddressed code change

What’s more, Snap (a Linux package format and system) also keeps older versions of VS Code after updates, further multiplying the number of local Trash folders and files that should have been deleted, but are still lingering.

On GitHub, a user discovered that the bug stems from an unaddressed code change introduced in early October 2024 which “creates a bogus Trash that’s not the system one.” According to the user, the folder is unmanageable, “carried over from update to update”, and “gradually inflating”.

Low disk space can slow down the system, editors, and compilers, and cause crashes or failed writes.

The Register says neither VS Code nor Snap have a way to manage these folders, but claims it is possible through the command line.

Right now, there is no indication that a fix is released, or that it is even in the works. For now, many Linux users avoid the bug by installing VS Code from the official .deb/.rpm packages or using alternatives like Flatpak instead of the Snap version.


Best antivirus software header
The best antivirus for all budgets

Follow TechRadar on Google News and add us as a preferred source to get our expert news, reviews, and opinion in your feeds. Make sure to click the Follow button!

And of course you can also follow TechRadar on TikTok for news, reviews, unboxings in video form, and get regular updates from us on WhatsApp too.

TOPICS

Sead is a seasoned freelance journalist based in Sarajevo, Bosnia and Herzegovina. He writes about IT (cloud, IoT, 5G, VPN) and cybersecurity (ransomware, data breaches, laws and regulations). In his career, spanning more than a decade, he’s written for numerous media outlets, including Al Jazeera Balkans. He’s also held several modules on content writing for Represent Communications.

You must confirm your public display name before commenting

Please logout and then login again, you will then be prompted to enter your display name.