Closed cranechu closed 4 years ago
I think this is happening because sudo
does not propagate the environment by default, as a matter of security. It needs to be sudo -E
, and the user must have the appropriate permission.
The real problem, though, is that the adapter uses sudo
when spawning launcher it all. It doesn't actually need to do that, because the launcher will do it when it spawns the debuggee.
@int19h when will this be available in VS Code (on Ubuntu)?
It will be available in an insider build once https://github.com/microsoft/vscode-python/pull/10290 is merged.
Environment data
Actual behavior
I tried to debug a python file with "sudo" by modifying launch.json, but I got the error message below. I tried it twice.
Expected behavior
Debug should work with sudo enabled.
Steps to reproduce:
Here is the copy of launch.json in this minimized repository. "sudo" is manually added.