QtCreator blocks/is unresponsive for a minute when opening a file in the nix store
-
Hi,
I am on NixOS and whenever I open a file in /nix/store, like a header, QtCreator is unresponsive for a whole minute. It seems that QtCreator wants to crawl parts of the nix store, which is huge.
I profiled QtCreator, and it seems the top-level call is QFileSystemModelPrivate::fileSystemChanged(QString const&, QList<…> const&)
I attached a flamegraph with the problem.I tried it with the QtCreator version in my current nix store:
Qt Creator 17.0.1 based on Qt 6.9.3plus I tried it with the QtCreator built by Qt:
Qt Creator 18.0.0 based on Qt 6.10.0Both show the same symptoms.
Has anybody experienced the same?
Thanks
-
The culprit seems to be the "File system" view in the left panel. It wants to display the whole tree where the file is located which happens to be the nix store. Mine contains 34046 directories at the moment. This all happens on the UI thread, blocking the whole UI. The workaround is to close the "File System" view.