• Register
0 votes

Problem :

I have just downloaded Python and Visual Studio & trying to test the debugging feature for a simple "Hello World" script but I'm receiving this error:

failed to launch the python process, please validate the path 'python'

Could someone please tell me how to fix this?

6 5 3
6,930 points

Please log in or register to answer this question.

1 Answer

0 votes


1.Your old launch.json file might be causing this issue, due to the recent updates of launch.json file format and structure. 

2. Try to delete launch.json file in the .vscode folder. The .vscode folder exists in your workspace where your source code exists, not to be confused with the one in your user home folder (C:\Users\{username}\.vscode).

3.This workaround worked for me with Windows10 + Visual Studio Code + Python extension. Just delete the existing launch.json and restart Visual Studio Code, and then start your debugging. 

4.The launch.json file will be regenerated again, but this time it should be in the correct shape.

Further Readings:


9 7 4
38,600 points

Related questions

0 votes
1 answer 19 views
Problem : I just installed Python 3.5 and upon running the following code pip install mysql-python I am getting an error, which says: error: Microsoft Visual C++ 14.0 is required (Unable to find vcvarsall.bat) I have used the following lines of code to my PATH C:\ ... (x86)\Microsoft Visual Studio 12.0\VC; C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC My PC has 64bit window 7 setup.
asked Oct 8, 2020 sikandar 2.4k points
0 votes
1 answer 5.8K views
Problem : I am getting following error: pytesseract.pytesseract.tesseractnotfounderror: tesseract is not installed or it's not in your path
asked Nov 7, 2019 peterlaw 6.9k points
0 votes
2 answers 426 views
Problem : When I try to use a print statement in Python, it gives me below error: SyntaxError: Missing parentheses in call to 'print'
asked Oct 22, 2019 peterlaw 6.9k points
1 vote
1 answer 210 views
Problem : I am beginner to Python. Currently if I try to use the request module to have the urls text then I often face below Error: Traceback (most recent call last):  File "/usr/local/lib/python3.6/site-packages/requests-2.18.1-py3.5.egg/requests/adapters.py" ... to get the url's text to parse it. Please find below my line of code for your reference: mytext = requests.get(detail_path).mytext
asked May 2, 2020 stewart 4k points
0 votes
1 answer 3.6K views
Problem : I am new to Python and Tensorflow so I just simply typed the following code : import tensorflow as tf print(tf.__version__) # Build a dataflow graph. c = tf.constant([[1.0, 2.0], [3.0, 4.0]]) d = tf.constant([[1.0, 1.0], [0.0, ... the ' RuntimeError: The Session graph is empty. Add operations to the graph before calling run(). Process finished with exit code 1 How can I fix this error?
asked Nov 21, 2019 peterlaw 6.9k points
0 votes
1 answer 18 views
Problem: I've install Python 3.4 and Python 3.6 on my local machine successfully, but am unable to install packages with pip3. When I execute pip3 install <package>, I get the following SSL related error: pip is configured with locations that require TLS/SSL, ... matching distribution found for <package> How can I fix my Python3.x install so that I can install packages with pip install <package>?
asked Jan 9 Mashhoodch 5.7k points
1 vote
2 answers 100 views
Problem : The program supposed to take in two names, and if they are the same length it should check if they are the same word. But i am getting below error in python python typeerror: not all arguments converted during string formatting
asked Oct 21, 2019 peterlaw 6.9k points
0 votes
1 answer 342 views
Problem: Currently I am trying to learn Android programming. I am also trying to make an android studio project and I am learning to debug my Android application. While running my application everything works perfectly fine, but if I try to debug it then I face below error: “Could not connect to remote process. Aborting debug session.” How can I fix this Android issue?
asked Sep 1, 2020 Raphael Pacheco 4.9k points
1 vote
2 answers 284 views
Problem : I am beginner to numpy. I am trying to execute my code but I am facing below error. &ldquo;Valueerror: all the input arrays must have same number of dimensions&rdquo;. I want to have my all the arrays with a same shape. I am trying to fix above error from past couple of days but still unable to fix it. I am looking for some help in fixing above error.
asked Apr 4, 2020 morrisBson 3.2k points
0 votes
1 answer 2.1K views
Problem : MySample.csv contains the below details : NAME Id No Dept Tommy 1 12 CS Jimmy 2 35 EC Bonny 3 21 IT Franky 4 61 EE And my Python file contains the below code : import csv myifile = open('mysample.csv', "rb") read = csv.reader(myifile) for row in read : ... in for row in read : _csv.Error: iterator should return strings, not bytes (did you open the file in text mode?) How should I fix it?
asked Jan 2, 2020 alecxe 7.5k points