I am trying to debug a python program that takes a module as argument ( see args). The launch.json config is below:
{
"name": "Python: Actions",
"type": "python",
"request": "launch",
"module": "my_module",
"args": [
"--module",
"module"
],
"cwd": "/cwd",
"console": "integratedTerminal"
},
When I run the program like this it works: python -m my_module --module module
However, when I launch the debug config, it can't find the module passed as argument. Here is command line statement issued by vscode when I launch de config:
cd /cwd ; env "PYTHONIOENCODING=UTF-8" "PYTHONUNBUFFERED=1" /path/to/python ~/.vscode/extensions/ms-python.python-2018.12.1/pythonFiles/ptvsd_launcher.py --default --client --host localhost --port 60664 -m my_module --module module