ESP-IDF Extension for Visual Studio Code - install fail

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 12:57 am

I tried to install the Espressif ESP-IDF Extension for Visual Studio Code. It was going well, until the following.

Can someone tell me what I should do?

I am not a programmer, I am hardware developer. Previously I have only done limited work with the Arduino IDE. VSC and the ESP-IDF is totally new to me. To put it bluntly, I'm lost.

VS Code information.
Version: 1.58.0 (user setup)
Commit: 2d23c42a936db1c7b3b06f918cde29561cc47cd6
Date: 2021-07-08T06:54:55.083Z
Electron: 12.0.13
Chrome: 89.0.4389.128
Node.js: 14.16.0
V8: 8.9.255.25-electron.0
OS: Windows_NT x64 10.0.19041

I was installing the default, ESP-IDF 4.3 with the Espressif IDF 1.1.0 installer for VSC.


Installing package Toolchain for Xtensa (ESP32) based on GCC
Installing zip package Toolchain for Xtensa (ESP32) based on GCC
Installing package Toolchain for Xtensa (ESP32-S2) based on GCC
Installing zip package Toolchain for Xtensa (ESP32-S2) based on GCC
Installing package Toolchain for Xtensa (ESP32-S3) based on GCC
Installing zip package Toolchain for Xtensa (ESP32-S3) based on GCC
Installing package Toolchain for 32-bit RISC-V based on GCC
Installing zip package Toolchain for 32-bit RISC-V based on GCC
Installing package Toolchain for ESP32 ULP coprocessor
Installing zip package Toolchain for ESP32 ULP coprocessor
Installing package Toolchain for ESP32-S2 ULP coprocessor
Installing zip package Toolchain for ESP32-S2 ULP coprocessor
Installing package CMake build system
Installing zip package CMake build system
Installing package OpenOCD for ESP32
Installing zip package OpenOCD for ESP32
Installing package Ninja build system
Installing zip package Ninja build system
Installing package IDF wrapper tool for Windows
Installing zip package IDF wrapper tool for Windows
Installing package Ccache (compiler cache)
Installing zip package Ccache (compiler cache)
Installing package dfu-util (Device Firmware Upgrade Utilities)
Installing zip package dfu-util (Device Firmware Upgrade Utilities)
Installing package Python Wheels distribution bundled for the specific version of IDF and Python
Installing zip package Python Wheels distribution bundled for the specific version of IDF and Python

Traceback (most recent call last):
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1672, in <module>
main(sys.argv[1:])
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1668, in main
action_func(args)
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1340, in action_install_python_env
idf_python_env_path, _, virtualenv_python = get_python_env_path()
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 967, in get_python_env_path
idf_version_str = subprocess.check_output(['git', 'describe'],
File "subprocess.py", line 411, in check_output
File "subprocess.py", line 489, in run
File "subprocess.py", line 854, in __init__
File "subprocess.py", line 1307, in _execute_child
FileNotFoundError: [WinError 2] The system cannot find the file specified
Command failed: C:\Users\Rudy\.espressif\tools\idf-python\python.exe C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py install-python-env
Traceback (most recent call last):
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1672, in <module>
main(sys.argv[1:])
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1668, in main
action_func(args)
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1340, in action_install_python_env
idf_python_env_path, _, virtualenv_python = get_python_env_path()
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 967, in get_python_env_path
idf_version_str = subprocess.check_output(['git', 'describe'],
File "subprocess.py", line 411, in check_output
File "subprocess.py", line 489, in run
File "subprocess.py", line 854, in __init__
File "subprocess.py", line 1307, in _execute_child
FileNotFoundError: [WinError 2] The system cannot find the file specified
Command failed: C:\Users\Rudy\.espressif\tools\idf-python\python.exe C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py install-python-env
Traceback (most recent call last):
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1672, in <module>
main(sys.argv[1:])
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1668, in main
action_func(args)
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 1340, in action_install_python_env
idf_python_env_path, _, virtualenv_python = get_python_env_path()
File "C:\Users\Rudy\esp\esp-idf\tools\idf_tools.py", line 967, in get_python_env_path
idf_version_str = subprocess.check_output(['git', 'describe'],
File "subprocess.py", line 411, in check_output
File "subprocess.py", line 489, in run
File "subprocess.py", line 854, in __init__
File "subprocess.py", line 1307, in _execute_child
FileNotFoundError: [WinError 2] The system cannot find the file specified

Victoria Nope
Posts: 75
Joined: Fri Dec 04, 2020 9:56 pm

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby Victoria Nope » Sun Jul 11, 2021 2:09 am

Do you have installed all the prerequisites? It seems the error is raised for missing Git (haven't checked that script, just the log sounds like executing "git describe" failed to run for missing git executable).

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 3:47 am

I installed Git before I updated Visual Studio Code. Maybe a path problem?

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 3:59 am

Victoria Nope wrote:
Sun Jul 11, 2021 2:09 am
Do you have installed all the prerequisites? It seems the error is raised for missing Git (haven't checked that script, just the log sounds like executing "git describe" failed to run for missing git executable).
OK. You are right. I went fumbled my way into Developer: Toggle Developer Tools and in the Console output it has Git is not found in the current environment.

When the ESP-IDF extension installer was running I noticed it saying something like setting up a virtual environment. So I am assuming that my Git install isn't being found.

Now I need to figure out how to get it seen. When I installed Git the installer asked what editor I was using and I selected Visual Studio Code. I had thought that would have worked.

VS Code has the Git: Enabled box is ticked.

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 4:43 am

The path was set for Git/cmd but not for Git/bin.
Now to figure out how to continue the install.

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 5:40 am

Now I am really stuck. I can't get VS Code to complete the install. I can't get it to re-install. Uninstall only changes the status to uninstalled, and changes the button option to Install. So when I click the Install button it briefly (half a second) shows installing, then states the application is installed. I can't seem to force a real re-install.

Victoria Nope
Posts: 75
Joined: Fri Dec 04, 2020 9:56 pm

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby Victoria Nope » Sun Jul 11, 2021 11:04 am

You can follow this answer to add Git (essentially path to any application) to the PATH environment variable.

-Rudy-
Posts: 31
Joined: Sun Feb 05, 2017 1:08 am

Re: ESP-IDF Extension for Visual Studio Code - install fail

Postby -Rudy- » Sun Jul 11, 2021 11:45 am

I started a new topic for my problem under Discussion Forum / IDEs for ESP-IDF

Visual Studio Code ESP-IDF Extension - errors when installed
viewtopic.php?f=40&t=22067

Who is online

Users browsing this forum: sage1234 and 204 guests