When I get an extension error I have no way of knowing why the error happens.
Now, in order to get the error log message, we use the following code: console. error("This is error message");
For the VSCode logs, you can use the Developer: Open Logs Folder command, and for VSCode extensions it's Developer: Open Extensions Logs Folder . You can search for those commands in the Command Palette in the usual way.
You can easily run your extension under the debugger by pressing F5 . This opens a new VS Code window with your extension loaded. Output from your extension shows up in the Debug Console . You can set break points, step through your code, and inspect variables either in the Debug view or the Debug Console .
Views and more Actions click Disable All Installed Extensions then Enable All Extensions . Restart VSCode and it should be done; -) You can make sure again that the extensions are enabled.. Good Luck ! Best regards !
You're probably looking for:
cmd-shift-p
-> Search Show Logs
-> Extension Host
From what I know there are no dedicated logs for extensions. When you are debugging your extension you can write notes to the console. However, when you have problems with an installed extension this won't help. But keep in mind vscode is kinda "web browser", so it has the usual browser developer tools (see Help -> Developer Tools),
which will show you runtime errors (and all the other stuff those tools allow usually, including the entire vscode DOM). That's probably the best option you have in such a scenario.
And for extensions that use previewHTML (or web views) there's a similar goodie, but tailored towards HTML development. Use ctrl/cmd+shift+P to open the command pallet and type "Webview Tools". Select the match to open a similar view like the one described in the first paragraph. But this one is only for the previewHTML content and allows you to debug that! This view is only available when a page containing a web view/previewHTML is active and closes automatically when the web view tab is closed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With