-
Notifications
You must be signed in to change notification settings - Fork 68
Debug Adapter: Compatibility with node 13 #2068
Comments
Here's a more useful version of the trace, from
|
@puremourning We are slowly phasing it out the TypeScript debug adapter. We have a new python based debug adapter. If you want to try the new one, you will need to follow these steps. Switch to the insiders version of the extension:
Then add these settings:
Reload, VS Code after adding. Check the
Let me know if this helps. |
@puremourning To use it as a debug adapter, run the For "attach" requests with "host" and "port specified (i.e. attach-by-socket), the debug server that is started by using |
Thanks. I’ll try it this weekend. Does this self contained ptvsd adapter use the same launch config as vscode-python? I considered switching in the past, but as the launch configs are different it would be a breaking change for users. |
For now it can handle the old configs as well, although there are some changes to defaults - e.g. "console" defaults to "integratedTerminal" now, and "subProcess" to true. We'll be deprecating the old stuff going forward though - but that will apply to the VSCode extension also. The biggest incentive to switch, though, is that "pythonPath" is now just "python" - so you won't have to explain to the users how and why it's totally different from |
:) thanks 🙏 |
One more thing. We're in the process of doing a rename of the project, in part to remove the legacy association with VS - instead of |
@int19h - thanks I was able to make debugpy work, though I did have to specify |
It should allow it to be omitted, and default to |
@puremourning with the python extension, it adds An advantage of using "python", is that you can pass interpreter arguments to it as well. So these are all valid:
|
@karthiknadig I'm all for that change, I was just reporting that as a strict compatibility with the typescript adapter, this is a change. @int19h raised: https://github.com/microsoft/ptvsd/issues/2070 As it happens there's a simple way in vimspector to specify a default for this value, so I'm not super worried. |
Even with the extension not in the picture, there's some logic to pick a default for "python" in the adapter itself (or rather in the launcher). I added that there specifically for non-VSCode use cases, hence why I'm treating it as a bug. I think that code just got regressed at some point, probably when I added the ability to use an array there instead of a single value - it's still trying to do this, it's just not doing it correctly. |
I'm going to go ahead and close this issue - if there are any more issues with debugpy Vimspector integration, just file them directly in the new repo. |
Thanks for everything. Much appreciated. |
Environment data
"python.jediEnabled"
set to; more info How to update the language server to the latest stable version vscode-python#3977): n/a (debug adapter)Expected behaviour
Debug adapter starts up under
node
v13 environment, when runningnode out/client/debugger/debugAdapter/main.js
Under node 12, it works:
Actual behaviour
Steps to reproduce:
nvm
swtich to node 13 environment (nvm install 13; nvm use 13
)node node out/client/debugger/debugAdapter/main.js
(error above)
Contrast with node 12:
nvm
swtich to node 12 environment (nvm install 12; nvm use 12
)node node out/client/debugger/debugAdapter/main.js
(starts)
Logs
None - debug adapter doesn't start up.
Additional context
For simplicity's sake vimpector uses the debug adaptor out of this extension (rather than directly launching
ptvsd
). When users run in a node 13 environment, the adapter fails to start with the above error.I assume that VScode is bundling and controlling the
node
environment normally, which is why VScode is not itself affected. Is there any interest in fixing the adapter to work in a node 13 environment ?The text was updated successfully, but these errors were encountered: