vscode: conpty process blocked update on Windows
I attempted to update Insiders today using the usual “apply update and restart” action and ran into the following error. It looks like some console-related processes blocked update. No VS Code windows were open.
The command line of the process doing the blocking was:
"c:\Users\conno\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\node_modules.asar.unpacked\node-pty\build\Release\conpty\OpenConsole.exe" --headless --inheritcursor --width 80 --height 30 --signal 0x638 --server 0x69c
I am using the new windowsUseConptyDll setting, if that matters.
About this issue
- Original URL
- State: open
- Created 2 years ago
- Reactions: 1
- Comments: 21 (12 by maintainers)
Thanks for checking, yes can you share the dump file to Deepak.Mohan@microsoft.com
Looks like having the job handle https://github.com/microsoft/node-pty/pull/755 would be the right fix given we force close application with background updates and the pty agent process would be unable to drain data from the openconsole process in this case. I actually reverted that change for a more graceful shutdown on the pty side https://github.com/microsoft/node-pty/pull/759/commits/667e93f33d68a7be25f1e550cba6ce723961e400. If the minidump shows that to be the case, I will go ahead and bring back this fix.
@connor4312 the openconsole.exe process should have an associated client process running that would be keeping it from exiting, like node.js process or something (these are process that you spawn from the integrated terminal). Can you check the process tree to see what process are associated with the running openconsole process, it would give a hint on how to repro the issue on my side. Thanks!
I updated Insiders today without a debugging session and didn’t run into the issue 🙂
Thanks for the profile, based on the process lifetimes I was able to backtrack the steps that might repro the issue and I now have a reliable repro,
windowsUseConptyDllon the vscode-copilot repoOpenConsole.exeprocess will be created for each of the npm tasksCopilot extensionOpenConsole.exeprocess is leaked and end up locking the resources folderI feel the scenario during the update might have been the same, @connor4312 just to validate this scenario can you check if update fails when you don’t have any debugging session.
Didn’t have any luck with the copilot repo as well, can you try the following steps before applying the next update
Windows Performance Recorderfrom system start menuCPU usage, Disk I/O activity, File I/O activity, Registry I/O activity, Handle usage