visual-studio-code - 如何确定哪个 VS Code 扩展导致崩溃?

标签 visual-studio-code

语境

我在一个相当大的 repo 中使用 VS Code,我的扩展主机不断崩溃。当我在禁用扩展的情况下运行编辑器时,我可以不间断地工作。在这段时间里,VS Code 使用了我机器的大部分 CPU。

问题

有没有办法让我检查哪个扩展是导致崩溃的罪魁祸首?

最佳答案

v1.52 中有一个新功能 - Extension Bisect - 这有助于确定导致问题的扩展。见 https://github.com/microsoft/vscode-docs/blob/vnext/release-notes/v1_52.md#trouble-shooting-extension-bisect

... sometimes extensions misbehave and sometimes it isn't obvious if an issue is caused by an extension and if so by which extension. Until today, you needed to disable all extensions and then one by one re-enable extensions to find a bad extension. This process is now getting easy with a new feature called "Extension Bisect". It uses the binary search algorithm to quickly identify an extension that causes trouble. In essence, it disables half your extensions and asks you to check for the issue you were seeing. If the issue is gone the bad extension must have been in the list of disabled extensions, otherwise in the list of enabled extensions. This process is now repeated on the list, which must contain the bad extension until only a single extension is left.

You can start extension bisect via Start Extension Bisect. It then guide through the process of repeatedly disabling and re-enabling extensions. After each reload you will be prompted to confirm if the issue is still there.



"Extension Bisect" will repeatedly ask you to check if the issue is still there or not. You can always abort via Stop Bisect and when having dismissed the bisect notification you can continue via Continue Extension Bisect.


请参阅发行说明链接中的图片。

关于visual-studio-code - 如何确定哪个 VS Code 扩展导致崩溃?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59277252/

相关文章:

git - 如何为某些项目禁用 git 而其他项目不在 Visual Studio Code 中禁用 git?

typescript - vscode 调试器无法解析 tsconfig.json 路径

php - Lumen 框架未命中 Vscode 上的断点

html - 带有美化功能的 Vscode 不会缩进 django html 模板

django - 如何配置 VS Code 以使用 Prettier HTML 格式化程序?

visual-studio-code - 是否可以打开和编辑 vsix 包(VS 代码的扩展文件)?如果是,那么如何?

visual-studio-code - 什么是Visual Studio代码实验?

c++ - 如何在windows上使用cl.exe定义task.json来在vscode中编译C/C++代码?

autocomplete - Tab 与 VS Code 中的智能感知和片段冲突

visual-studio-code - 如何摆脱 VSCode 'Dirty Editor'