microsoft / vscode-python

Python extension for Visual Studio Code
https://aka.ms/pvsc-marketplace
MIT License
4.28k stars 1.17k forks source link

Python extension should not register 'python' debugger in web #20299

Open sbatten opened 1 year ago

sbatten commented 1 year ago

Testing microsoft/vscode#167433

insiders.vscode.dev

image
joyceerhl commented 1 year ago

Given we now do support debugging in the web with https://github.com/microsoft/vscode/issues/167399, I think the debug welcome view is never going to show up...or could the fact that the debug view is always populated now be related to workspace trust changes for web?

sbatten commented 1 year ago

There are no recent changes to workspace trust in the web that I am aware of, but it could be that we just assumed debugging is available now. It seems wrong for this case because I have launch configs, but they will not work as they require a different debug adapter.

joyceerhl commented 1 year ago

@connor4312 do you happen to have context on why the debug view is populated with launch configs in web now and not before?

connor4312 commented 1 year ago

The debug view is shown if there's at least one installed extension that registers a debugger. It looks like (one of) the Python extensions now does this--just testing by seeing what completions are available for type in a launch.json.

image
joyceerhl commented 1 year ago

Ah, that'll be the experimental Python WASM extension, that makes sense. Also confirmed that if I uninstall that extension the welcome view reappears. @sbatten do you have that extension installed, and if you uninstall it does the debug view show up for you?

sbatten commented 1 year ago

I don't but it's actually coming from the main python extension. I disable that and get the welcome view. So as far as continue working on... this is working.

joyceerhl commented 1 year ago

@paulacamargo25 does the Python extension contribute a debugger that works in web, and if it does not, can we ensure not to register it in web?

paulacamargo25 commented 1 year ago

@joyceerhl No, our debugger doesn't work on the web, I check and we already show a message, that python configuration is not supported.

Screenshot 2022-11-30 at 11 17 25 AM

I'll check if it's possible not to register it at all.