/bin/sh: 1: python: not found in VS Code [Solved]

Shahriyar Al Mustakim Mitul - May 25 '22 - - Dev Community

/bin/sh: 1: python: not found occurs when you have python3 installed . For example, you can check your python version:

Image description
You can see something like this. Now check if you have python3 installed or not.

Image description
It works . If it does not work for you, then install python3 in the latest version.

Follow these steps to install python3:

Step 1: Update and Refresh Repository Lists

sudo apt update
Enter fullscreen mode Exit fullscreen mode

Step 2: Install Supporting Software

sudo apt install software-properties-common
Enter fullscreen mode Exit fullscreen mode

Step 3: Add Deadsnakes PPA

sudo add-apt-repository ppa:deadsnakes/ppa
Enter fullscreen mode Exit fullscreen mode

The system will prompt you to press enter to continue. Do so, and allow it to finish. Refresh the package lists again:

sudo apt update
Enter fullscreen mode Exit fullscreen mode

Step 4: Install Python 3
Go to this page and look for the latest version of python3 : https://www.python.org/downloads/

sudo apt install python3.10.4
Enter fullscreen mode Exit fullscreen mode

python3.10.4 was the latest version when I was creating the blog.

Now, check the version

python3 --version
Enter fullscreen mode Exit fullscreen mode

You can read this blog for more ways to install python into Ubuntu.

Now we have python3 installed .
Image description
Still python does not work.
Let's tell our system that python3 is python.

Image description
Now it works perfectly.

Now, go to your VS Code and the problem will be solved.

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
Terabox Video Player