Page 1 of 1

build and flash ok with esp-idf shell, not with eclipse

Posted: Thu Oct 19, 2023 10:33 am
by vincent
hi,
I had a project which was working fine last year. I had to put it on pause, and now my IDE cannot build nor flash this project.
I updated everything, tried a fresh install, but i keep the same errors, which seems to be my IDE call my own version of python, not the one from the virtual environment.

The following Python requirements are not satisfied:

Requirement 'click<8.1,>=7.0' was not met. Installed version: 8.1.3


Requirement 'esptool~=4.7.dev1' was not met. Installed version: 3.3


Requirement 'pyparsing<3.1,>=3.0.3' was not met. Installed version: 2.3.1

To install the missing packages, please run "install.bat"

Diagnostic information:

IDF_PYTHON_ENV_PATH: C:\Users\Vincent\work\Espressif\python_env\idf5.1_py3.9_env

Python interpreter used: C:\Users\Vincent\work\Espressif\python_env\idf5.1_py3.9_env\Scripts\python.exe

Constraint file: C:\Users\Vincent\work\Espressif\espidf.constraints.v5.1.txt

Requirement files:

- C:\Espressif\frameworks\esp-idf-v5.1.1\tools\requirements\requirements.core.txt

Python being checked: C:\Users\Vincent\work\Espressif\python_env\idf5.1_py3.9_env\Scripts\python.exe


ESP-IDF v5.1.1
I checked modules versions in the virtual env, it looks fine.
I tried to execute install.bat as mentionned, the batch works well but i keep the same error.
How can i fix this please ?
working on Windows 10, Eclipse 2023-09 with latest plugin ESP and ESP-IDF v5.1.1

Re: build and flash ok with esp-idf shell, not with eclipse

Posted: Tue Oct 24, 2023 2:27 pm
by kondalkolipaka
Hello,

It looks like incorrect PATH and IDF_PYTHON_ENV_PATH being sent while running a build. This is either due to incorrect IDE build environment set or IDE variables are not taking precedence over system variables during the build.

To fix this, can you try the following:

Please make sure you get the latest IDE plugin version v2.11.0 and build the project and see that helps. If not, please proceed with the next steps.

1. Espressif > ESP-IDF Tools Manager > Install Tools >
2. Choose all the details in the dialog including python. Here you can specifiy system python path, needn't be a ESP-IDF Python. This is used to run idf_tools.py command not for the build
3. Once the installation is complete, please try to run the build again and see if you are able build it. In the previous step, running Install Tools will reset build environment variables

If the issue still persists, please try the following:
1. Go to the IDE preferences > C/C++ > Build > Environment
2. Verify does IDF_PYTHON_ENV_PATH is correctly set. Looking at the log you've provided it seems to be correct set to .../idf5.1_py3.9_env which is correct!
3. Choose Replace native environment variables with the specified one option. You can find this right below the environment variables. This is to replace your system python with the one specified in the eclipse
3. Now select IDF_PYTHON_ENV_PATH row, and click on on Edit.. and this will launch a dialog, without modifying just click on Ok. This will replace system path with the IDE environemnt path.
4. Now try to build a project and see if that helps.

I hope that helps!

Re: build and flash ok with esp-idf shell, not with eclipse

Posted: Fri Jun 06, 2025 7:37 pm
by mstroven
I have the same problem with a brand new Ubuntu 24.04.2 LTS, a clean Eclipse ver 2025-03 and ESP-IDF Eclipse Plugin ver 3.4.0. An older project set for ESP32c3 will build from the command line, but Eclipse keeps messing with CMakeCache.txt and other files causing the Eclipse environment to think the target is ESP32c6, and produces this: "WARNING: The IDF_PYTHON_ENV_PATH is missing in environment variables!" followed by "Build not configured correctly"
However, I do have the variable set:

Code: Select all

mstroven > "echo $IDF_PYTHON_ENV_PATH"
results in:
"

Code: Select all

/home/mstroven/.espressif/python_env/idf5.4_py3.12_env
" New projects created from templates build fine. What is missing in my old project?

Re: build and flash ok with esp-idf shell, not with eclipse

Posted: Mon Jun 09, 2025 6:13 am
by kondalkolipaka
> "Build not configured correctly"

This issue usually occurs when you’ve imported a project that doesn’t have the IDF Nature set in the .project settings, or when you’re trying to build a project without selecting a launch configuration or target.

Closing a project and reopening can help in this case and make sure to choose a launch configuration with the target - Please check if that helps?