Vscode: UI freeze on moving to trash on linux

Created on 17 Jul 2018  路  12Comments  路  Source: microsoft/vscode


  • VSCode Version: 1.25
  • OS Version: kubuntu 18.04

Steps to Reproduce:

  1. start fresh system/session (I use KDE)
  2. delete any file on HDD, ui freezes for 2 seconds

Moving to trash is synchronous action, but should be done asynchronously or in another thread. I assume that it is implemeted via DBus on Linux :thinking:

electron freeze-slow-crash-leak needs more info upstream

Most helpful comment

It's been almost a year since this issue has been opened and it still occurs to me.
Why hasn't it been fixed, yet?

Same issue

All 12 comments

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

Yes, reproducible. On the first removal there is a freeze for 3 seconds.
Arch linux , kde. To definetely reproduce logout, # sync; echo 3 > /proc/sys/vm/drop_caches, login and launch vscode

Version: 1.31.0-insider
Commit: 9fe48f15b1a252a0e9e1ef5975301203baf10b8a
Date: 2019-01-25T08:13:32.146Z
Electron: 3.1.0
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Linux x64 4.20.3-arch1-1-ARCH

I'm getting the same issue on windows. I just reproduced it on today's insider build. I made a bunch of files like this:

var fs = require('fs');
for (let i=0; i<1000; i++){
    var wstream = fs.createWriteStream(i + '.txt');
    for (let j=0; j<1000; j++){
        wstream.write('Hello world!\n')
    }
    wstream.end();
}

I selected all the files in the vscode explorer and pressed the delete button.
image

Here is a related electron issue.

It looks like the upstream aspect of the problem is that electron does not handle io asynchronously by default. If you want asynchronous io in an electron application, you have to do it yourself. The fact that vscode has not chosen to make io from its explorer asynchronous is a vscode issue, not an electron issue.

I get the prompt that VS Code is no longer responding + UI lock up when deleting anything, big or small files, even if the file is empty.

$ node --version
v10.15.3
$ code --version
1.33.1
51b0b28134d51361cf996d2f0a1c698247aeabd8
x64
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 18.04.2 LTS
Release:        18.04
Codename:       bionic
$ plasmashell --version
plasmashell 5.12.7
$ kf5-config --version
Qt: 5.9.5
KDE Frameworks: 5.44.0
kf5-config: 1.0

It's been almost a year since this issue has been opened and it still occurs to me.
Why hasn't it been fixed, yet?

It's been almost a year since this issue has been opened and it still occurs to me.
Why hasn't it been fixed, yet?

Same issue

Same issue

$ node --version
v10.15.2

$ code --version
1.38.1
b37e54c98e1a74ba89e03073e5a3761284e3ffb0
x64

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 19.04
Release: 19.04
Codename: disco

$ plasmashell --version
plasmashell 5.15.4

$ kf5-config --version
Qt: 5.12.2
KDE Frameworks: 5.56.0
kf5-config: 1.0

We are building exploration builds that use a much newer version of our UI framework (Electron version 6.0.x). I wonder if this issue reproduces with one of these builds, could you try? Download:

I have the same issue (code 1.39.1 88f15d17 installed via snap on Kubuntu 19.04), and I just tried the deb package you suggested.

From a simple test (open a folder + try to delete a file) it looks like it works.

I'm looking forward to get the version based on the new Electron via snap.

I use (K|X)ubuntu 19.04 and VSCode 1.39.1.
I trigger the bug when I use vscode on KDE but not when I use XFCE.

We are building exploration builds that use a much newer version of our UI framework (Electron version 6.0.x). I wonder if this issue reproduces with one of these builds, could you try? Download:

I tested the deb package and it worked

The bug is fixed for me using the provided .deb package (v1.39.0-exploration)

Was this page helpful?
0 / 5 - 0 ratings