"You don't have an extension for debugging 'JSON with Comments'" warning when debugging VS Code theme
Asked Answered
B

4

31

I generated the files necessary for creating a color theme in VS Code. I did this with the generator-code node package.

My file structure is as follows

When I run VS Code's debugger, I get this warning that prevents the debugger from running.

Here are the contents of my launch.json file for reference:

{
  "version": "0.2.0",
  "configurations": [
      {
          "name": "Extension",
          "type": "extensionHost",
          "request": "launch",
          "runtimeExecutable": "${execPath}",
          "args": [
              "--extensionDevelopmentPath=${workspaceFolder}"
          ],
          "outFiles": [
              "${workspaceFolder}/out/**/*.js"
          ],
      }
  ]
}

In case you're wondering what I'm expecting to happen when I run the debugger, here's the moment in the tutorial I was following where I ran into this problem.

Edit: Well, I evaded the problem somehow by deleting the files and starting over. I'm not sure what was causing the problem before.

Builder answered 17/7, 2021 at 23:16 Comment(0)
M
60

This popup only appears for me when trying to launch the debugger while having the launch.json or tasks.json file open. Switching to one of my test files and launching the debugger fixes it

Math answered 23/9, 2021 at 16:23 Comment(2)
tasks.json is another very typical one to have open that would cause this. I tried to add it to your answer, but the suggested edit queue was full.Mather
Thanks @Mather . I added that to the answerMath
R
2

Try Adding Configurations (Menu-->Run-->Add Configuration-->your browser)

Repression answered 15/4, 2023 at 14:37 Comment(0)
A
1

Ensure that the folder you have the extension code in is the folder you open in VSCode. It has to be the root project folder in VSCode for the extension to be run.

Aback answered 16/10, 2023 at 3:31 Comment(0)
C
0

I had this error when my launch.json was not according to the version + configurations scheme, I copy pasted the content of configurations to the file instead of putting it in the array.

{
    "name": "Extension",
    "type": "extensionHost",
    "request": "launch",
    "runtimeExecutable": "${execPath}",
    "args": [
        "--extensionDevelopmentPath=${workspaceFolder}"
    ],
    "outFiles": [
        "${workspaceFolder}/out/**/*.js"
    ],
}
Cloister answered 1/2, 2022 at 7:3 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.