Jordan Rodrigues
Jordan Rodrigues

Reputation: 31

Python: Failed to Launch Debug Adapter, Operation was cancelled. Visual Studio Community 2022

So I've seen that many people have asked this question before, but it's always in relation to a different framework/language.

I was working on a solution in python and seemingly for no reason I couldn't debug anymore.

I opened a new solution to see if I had somehow broken my solution, but now I can't debug at all.

The programs do however execute just fine.

VS Error with the most basic code

I've tried all of the suggested fixes I could find:

-Restart PC

-Open the De-bug options, Enabling JS debugging for ASP NET (Even though I'm working in python)

-Repairing VS

-Completely Uninstalling VS and Re-installing

-Looking for the path C:\Users\username\vsdbg\ (Doesn't exist)

I suspect there has been some kind of conflict between 2019 vs and 2022 VS but I'm certain I've removed all of the old files related to 2019

Upvotes: 0

Views: 2793

Answers (2)

Sigja
Sigja

Reputation: 93

I had the similar problem. What I did to solve it was to use a newer Python version. I was using Python 3.6. It looks like VS does not support Python 3.6 anymore - see this link.

Upvotes: 0

Jordan Rodrigues
Jordan Rodrigues

Reputation: 31

Okay so I've managed to fix: Looks like the issue was coming from the version of Python that the solution was attempting to de-bug with.

  1. Drop down the Python environment selector,
  2. Navigate to existing environment
  3. Select the latest version of python environment (Make sure you have it downloaded and installed correctly)

Fix

Upvotes: 3

Related Questions