-
Notifications
You must be signed in to change notification settings - Fork 30.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set env to extensionHost type in launch.json did not work #22150
Comments
@leozdgao Can you debug your extension using your initial launch.json configuration but without the |
@ramya-rao-a I'm not sure. I just want to find an approach to judge the debugging environment, so I could load some development configuration. Is there anyway to do so without set env? 😕 |
I was currently trying to narrow down if debugging the extension works at all to begin with. Hence the question about trying without the env attribute. |
@ramya-rao-a Oh, debugging the extension works well. But the env configuration did not work. |
@roblourens not sure if |
The extensionHost debugger doesn't yet support setting the env (but it is planned for this milestone). But the nasty problem is that the error squiggly is completely misleading: It flags the type "extensionHost" as wrong and not the illegal use of "env". If the key value pair "foo":"bar" is removed from the env structure the error is flagged correctly: @aeschli Is there a way to let your validator know that the "type" attribute is special (and has higher priority)? |
@weinand BTW, is there anyway to know the code is running in the debug environment besides set env? |
Currently this feature is blocked by #22233 |
@weinand It's difficult for the JSON validator to know which variant ('any of') is the right one. |
@leozdgao with the latest Insiders build you can now access env variables in the extension that are defined in the launch config. |
Steps to Reproduce:
I'm working on a vscode extension development, and my launch.json here:
And
env
seems not to be set. I try to follow the prompt here:And modify my launch.json like this:
But got the connection timeout error here:
The text was updated successfully, but these errors were encountered: