Debugging Python program doesn't work after updating to VS Code 1.66.0

Viewed 1304

Today (2022/3/31) I let the auto-update function update my VS Code to latest version 1.66.0 on Windows. After that, my normal debugging process doesn't work any more: when I press F5, the debugging control panel flashes and disappears immediately, nothing else happends. I couldn't find any useful error message on output and terminal windows. My launch.json file looks like this:

{
        "name": "DEBUG",
        "type": "python",
        "request": "launch",
        "program": "${workspaceFolder}\\starting.py",        
        "console": "integratedTerminal",    
        "justMyCode": false,
    }

I tried to change the console above to externalTerminal but it didn't help. Could someone tell me how to find out what's going on here?

Cheers,

4 Answers

Click on the python extention (publisher microsoft) and select "install pre-release". It would be V2022.5.10961002 (you can see it when you hover with the mouse above the extension)

Fixed the problem for me.

You can try to reinstall the Python extension or install the older version of the Python extension. Delete the deprecated configuration of python.pythonPath in your settings.json.

Click on the python extention (publisher microsoft) and select "install pre-release". It would be V2022.5.10961002 (you can see it when you hover with the mouse above the extension)

Fixed the problem for me.

After digging and digging I've found the issue was with the current version of the python extension for the VS code (mine was the latest). Downgrading the extension version to v2021.12.1559732655 solved the issue and now breakpoints works.

In order to downgrade the extension go to file->preferences->extension select the python package press the expend arrow near the uninstall button and select install a different version.

Credits for the solution: https://docs.microsoft.com/en-us/answers/questions/724858/vscode-debugger-not-working-for-python.html

Related