Jak opravit PlatformIO: 'Can not find working Python 3.6+ interpreter' na Linux

Problém:

Při pokusu o open PlatformIO v Visual Studio Code, vidíte následující error message:

error.txt
PlatformIO: Can not find working Python 3.6+ Interpreter. Please install the latest Python 3 and restart VSCode

VSCode error message showing PlatformIO cannot find working Python 3.6 interpreter

i když máte Python3 already installed.

Řešení

Issue zde není, že PlatformIO can’t find Python 3, je to, že nemáte venv (virtual environments) installed pro vaši Python verzi!

Na Ubuntu/Debian, můžete ho nainstalovat pomocí

install_venv.sh
sudo apt -y install python3-venv

Alternatively můžete ho nainstalovat pomocí pip:

install_virtualenv.sh
pip install virtualenv

Podívejte se na podobné články podle kategorie: PlatformIO Python