Troublesome story when using Python3 with VScode on ubuntu

I tried to use ubuntu using GCP. I dropped the python code from github with the familiar VS Code, but I can't use python3 as it is, so make a note.

Since the Python version is displayed at the bottom left of code, clicking it will display the Python version as an option in the command palette (upper search bar). I should be able to select python3 here, but when I type python --version in the terminal, it says that it is the old version of python2.

It seems that you can change the default by typing the following command. sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.6 9

The following is a reference site. https://qastack.jp/unix/410579/change-the-python3-default-version-in-ubuntu

Recommended Posts

Troublesome story when using Python3 with VScode on ubuntu
Preparing python using vscode on ubuntu
Introducing Python using pyenv on Ubuntu 20.04
Notes on using rstrip with python.
When using MeCab with virtualenv python
Precautions when using six with Python 2.5
Settings when using Python 3 requests and Beautiful Soup with crostini on Chromebook
CPU usage is 100% when using pygame on Ubuntu 16.04
A addictive story when using tensorflow on Android
Build python environment with pyenv on EC2 (ubuntu)
Python development on Ubuntu on AWS EC2 (using JupyterLab)
[python] [vscode] When you get angry with space-tab-mixed
What are you using when testing with Python?
build Python on Ubuntu
Install Python 3.3 on Ubuntu 12.04
Precautions when using sqlite3 on macOS Sierra (10.12) with multiprocessing
Check types_map when using mimetypes on AWS Lambda (Python)
Error around GUI when using PyQt5 on Ubuntu (WSL2)
SoC FPGA: A small story when using on Linux
Ubuntu 20.04 on raspberry pi 4 with OpenCV and use with python
A swampy story when using firebase on AWS lamda
Minimum memo when using Python on Mac (pyenv edition)
Minimum notes when using Python on Mac (Homebrew edition)
Using X11 with ubuntu18.04 (C)
Set up Python 3.4 on Ubuntu
Use matplotlib on Ubuntu 12 & Python
[S3] CRUD with S3 using Python [Python]
Story when iterating python tuple
Using Quaternion with Python ~ numpy-quaternion ~
[Python] Using OpenCV with Python (Basic)
Put Python 3.x on Ubuntu
Build python3 environment with ubuntu 16.04
Operate ubuntu on VScode (windows10)
Stumble story with Python array
Install OpenCV on Ubuntu + python
Error when playing with python
Introducing TensorFlow on Ubuntu + Python 2.7
Broadcast on LINE using python
Using OpenCV with Python @Mac
Send using Python with Gmail
Use a macro that runs when saving python with vscode
IP spoof using tor on macOS and check with python
Things to keep in mind when using Python with AtCoder
Things to keep in mind when using cgi with python.
Until building a Python development environment using pyenv on Ubuntu 20.04
Harmonic mean with Python Harmonic mean (using SciPy)
Control the motor with a motor driver using python on Raspberry Pi 3!
Python 3.4 pyvenv fails on Ubuntu 14.04 LTS
[Ubuntu] [Python] Object tracking using dlib
[Python] Using OpenCV with Python (Image Filtering)
Precautions when using pit in Python
Prepare Python development environment on Ubuntu
Web application created with Python + Flask (using VScode) # 1-Virtual environment construction-
Using Rstan from Python with PypeR
Install Python 3.8 on Ubuntu 20.04 (OS standard)
Notes on using MeCab from Python
[Python] Using OpenCV with Python (Edge Detection)
Draw Japanese with matplotlib on Ubuntu
Error and solution when installing python3 with homebrew on mac (catalina 10.15)
Debug python multiprocess program with VSCode
Support when installing pillow on python3.9