Extension locks up occasionally when switching between git branches
See original GitHub issueBrief Issue Summary
Occasionally when switching between git branches in the currently open folder (either through the VSCode UI or through the shell, it doesn’t seem to make a difference), the extension appears to get stuck doing something with cmake.
Expected:
- Checkout a different git branch
- The active branch changes.
Apparent Behavior:
Intermittent
- Checkout a different git branch
- The UI seems to be waiting for the branch to change.
cmake.exe
and a VSCode subprocess will both be using 2 cores fully. The cmake subprocess memory usage will steadily climb up. After 10-20 minutes it’s using over 24 GB of memory and still climbing.- During this time no git actions can be taken since there are OS level locks held on seemingly random files preventing them from being opened or modified.
It’s unclear whether this process ever completes on its own.
CMake Tools Log
No log output observed during these events.
Developer Tools Log
No log output observed during these events.
Platform and Versions
- Operating System: Windows 10
- CMake Version: 3.11.0-rc3
- VSCode Version: 1.25.1
- CMake Tools Extension Version: 1.1.0
- Compiler/Toolchain: Visual C++ 2017
Other Notes/Information
This seems to happen most frequently if I switch between branches that have a lot of differences.
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Git not removing files when switching branch - Stack Overflow
It seems to definitely happen the most often when my IDE has a lock on one of the files in the branch i'm...
Read more >Files in Git-Branches are getting corrupted
It seems as though switching branches occasionally leaves one or two files in the state they were in before switching, which then brings...
Read more >Cannot switch branches after pull, push, commit or merge - Jira
Hello! This is a known issue that can be caused by switching too fast between committing. You should be able to delete the...
Read more >Xcode SPM when switching between branches
When I open my project in Xcode or switch Git branch, Xcode starts to resolve package dependencies even if Package.resolved file has not...
Read more >VS2022 Performance Enhancements: Git Branch Switching
How to switch between Git branches in Visual Studio 2022 ... We have also been able to speed up solution reloads by an...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m marking this as an upstream bug. CMT doesn’t use cmake-server’s file-watching facilities, so it’s not helpful to the ext. It would be good to be able to disable it if possible, but there isn’t yet an option to do so. I too have seen cmake-server lock up on systems with a huge number of file changes also while running intrusive security software (Webroot in my case, which causes me no end of grief).
This issue has been closed automatically because it needs more information and has not had recent activity.