VS Code for Linux may be secretly hoarding trashed files
Briefly

VS Code for Linux may be secretly hoarding trashed files
"The reason for this is Snap - a Linux application packaging format - creates a local Trash folder for each VS Code version, one that's separate from the system-managed Trash, according to a VS Code bug report dating back to November 11, 2024. Not only that, but Snap keeps older versions of VS Code after updates, potentially multiplying the number of local Trash folders and the trashed-but-not-deleted files therein. Emptying the system Trash folder doesn't affect the local instances."
"The root cause of the mess, according to a Microsoft engineer, is an unfixed VSCode change from October 11, 2024, that sets the XDG_DATA_HOME environment variable equal to $SNAP_USER_DATA/.local/share. "This creates a bogus Trash that's not the system one, and as such is unmanageable (and is carried over from update to update, gradually inflating)," the bug report explains. The bug may also cause issues beyond unexpected file retention, including messing up fish terminal history, interfering with uv Python installations, and Jupyter Notebook problems, among others."
"Neither VS Code nor Snap offers a way to manage these local trash folders, though this can be achieved with the command line. Robotics engineer Iván López Broceño reports finding almost 200 GB of files that he believed he deleted. Web developer Chris Hayes said in the discussion thread that he found 44 GB of files in Snap's local Trash folder dating back two years."
Snap-installed Visual Studio Code creates a separate local Trash folder for each VS Code version, distinct from the system-managed Trash. Snap retains older VS Code revisions after updates, multiplying local Trash folders and preserving trashed-but-not-deleted files across upgrades. Emptying the system Trash does not remove files in these local Trashes. The underlying change set XDG_DATA_HOME to $SNAP_USER_DATA/.local/share, producing a non-system Trash that carries over updates and inflates storage use. No built-in GUI in VS Code or Snap manages those local Trash folders; removal requires command-line actions. The bug can also disrupt shell history, Python installations, and Jupyter functionality.
Read at Theregister
Unable to calculate read time
[
|
]