vscode: VS Code is unable to activate a debugger extension because of path casing discrepancies
- VS Code Version: 1.54.1
- OS Version: Windows 10 19041
More information here: https://github.com/microsoft/vscode-cpptools/issues/7114
I want to highlight this from the customer’s logs. They are trying to load the ms-vscode.cpptools
extension, but the reasoning in the log does not make sense because ms-vscode.cpptools
registers the 'cppvsdbg'
debugger type). Downgrading VS Code to 1.53.2 fixes the issue for the customer. We’re not sure what would cause this.
[2021-03-05 16:49:27.882] [exthost] [error] Activating extension ms-vscode.cpptools failed due to an error:
[2021-03-05 16:49:27.886] [exthost] [error] Error: a DebugAdapterDescriptorFactory can only be registered from the extension that defines the 'cppvsdbg' debugger.
at m.registerDebugAdapterDescriptorFactory (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:91:25505)
at Object.registerDebugAdapterDescriptorFactory (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:95:37807)
at Object.initialize (c:\Users\sesa404214\.vscode\extensions\ms-vscode.cpptools-1.2.2\dist\main.js:18300:35)
at c:\Users\sesa404214\.vscode\extensions\ms-vscode.cpptools-1.2.2\dist\main.js:26903:27
at Generator.next (<anonymous>)
at c:\Users\sesa404214\.vscode\extensions\ms-vscode.cpptools-1.2.2\dist\main.js:26841:71
at new Promise (<anonymous>)
at module.exports.__awaiter (c:\Users\sesa404214\.vscode\extensions\ms-vscode.cpptools-1.2.2\dist\main.js:26837:12)
at activate (c:\Users\sesa404214\.vscode\extensions\ms-vscode.cpptools-1.2.2\dist\main.js:26870:12)
at Function._callActivateOptional (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:91:14037)
at Function._callActivate (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:91:13714)
at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:91:11746
at processTicksAndRejections (internal/process/task_queues.js:97:5)
Does this issue occur when all extensions are disabled?: No
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 32 (26 by maintainers)
Commits related to this issue
- fs - go back to previous realpath version & increment version (fix #118562) — committed to microsoft/vscode by bpasero 3 years ago
- fs - go back to previous realpath version & increment version (fix #118562) (#118956) — committed to microsoft/vscode by bpasero 3 years ago
This is a fun one, the problematic call was the conversion from
fs.realpath
callback version to the promise version on line https://github.com/microsoft/vscode/commit/b28cd23d521059938e08515618cdc670f3baa79b#diff-505206763bd72133dfaa593fe504440c0d863477741e23d87ed706bca6aa8a57R55 . Node gives different results for these.This fix has been pushed to
main
for insiders but also a recovery for Feb.The fix for this should also fix the following issues:
And maybe:
If I run with
1.54.1
it fails. If I run with1.53.2
it does NOT fail.There is indeed electron minor version bump from
1.53.2
to1.54.0
but there is no node version change and I have looked through the electron commits, nothing related to this code path in node was changed.To rule out runtime effects, I updated
1.54
branch to same runtime as1.53
and followed steps https://github.com/microsoft/vscode/issues/118812#issuecomment-797527967, the issue was still reproducible. I also switched the runtime to use binaries from https://electronjs.org/ to rule out any internal patches.So this is purely a regression on our app code, performing a git bisect now.