Confgen.py failed to run

kyrpav
Posts: 37
Joined: Wed Jan 29, 2020 8:27 am

Confgen.py failed to run

Postby kyrpav » Wed Sep 22, 2021 6:55 am

I am getting this issue:

Code: Select all

CMake Error at /Users/kyrpav/esp/esp-idf/tools/cmake/kconfig.cmake:260 (message):Failed to run confgen.py
(python;/Users/kyrpav/esp/esp-idf/tools/kconfig_new/confgen.py;--kconfig;/Users/kyrpav/esp/esp-idf/Kconfig;--sdkconfig-rename;/Users/kyrpav/esp/esp-idf/sdkconfig.rename;--config;/Users/kyrpav/workspace/esp32/tutorials/LearnEsp32/sdkconfig;--env-file;/Users/kyrpav/workspace/esp32/tutorials/LearnEsp32/build/config.env).
Error 1
I am using latest version 4.4 of idf. and i have updated the kconfiglib but it did not help ( i do not know if it is relevant). Python version that i am using is inside .esspessif folder and it is: .espressif/python_env/idf4.4_py3.9_env/bin/
in my profile i have set

Code: Select all

alias get_idf='source $HOME/esp/esp-idf/export.sh'
alias python=python3
to be able to use python3 (either i do not know if this is also relevant i just say it cause i saw at the beginning of the error that it says "python;")

How can this be fixed?

User avatar
ESP_Roland
Posts: 240
Joined: Tue Oct 09, 2018 10:28 am

Re: Confgen.py failed to run

Postby ESP_Roland » Wed Sep 22, 2021 9:29 am

Hi kyrpav,

setting an alias for Python is not required. I recommend you to remove it. The export script will check it and will use python3 if it is available. More importantly, it will use the same Python everywhere. Setting an alias could produce some side effects.

You don't see anything else beside just those tree error lines?

If not then you could try to invoke the command manually (without ";"), eg.

Code: Select all

python /Users/kyrpav/esp/esp-idf/tools/kconfig_new/confgen.py --kconfig /Users/kyrpav/esp/esp-idf/Kconfig --sdkconfig-rename /Users/kyrpav/esp/esp-idf/sdkconfig.rename --config /Users/kyrpav/workspace/esp32/tutorials/LearnEsp32/sdkconfig --env-file /Users/kyrpav/workspace/esp32/tutorials/LearnEsp32/build/config.env
and see if any error output is generated which could help to narrow down the issue.

kyrpav
Posts: 37
Joined: Wed Jan 29, 2020 8:27 am

Re: Confgen.py failed to run

Postby kyrpav » Wed Sep 22, 2021 6:07 pm

Hi ESP_Roland
I do not know if what i will describe have any connection between them but this is have happend.

i did run the command without ; and it run without error or output. when i run it with ; then technically i just open python which is the same version as i use in ESP.

After this i maximised vscode and there was an error that my vscode installation was corrupted and that i need to reinstall.

I did not reinstall just restarted vscode.

Then when intelligence came up and vscode did by itself a reconfiguration of the ESP plugin (i do not know why it did it itself) i build the project and everything when back to normal. Error disappears. Is it relevant? i do not know.

After this i tried to readd to MakeList the following code:

Code: Select all

set(EXTRA_COMPONENT_DIRS $ENV{IDF_PATH}/examples/common_components/protocol_examples_common)
and again i got the same error on build but wait.

After this i did close vscode and reopen it. I got the same issue about install corrupted and i restarted one more time. Then again same things happend esp-idf pluggin did reconfiguration by itselect and then everything where find again build is as always successful and without any errors.

Is anything of these helpful at all?

User avatar
ESP_Roland
Posts: 240
Joined: Tue Oct 09, 2018 10:28 am

Re: Confgen.py failed to run

Postby ESP_Roland » Thu Sep 23, 2021 9:16 am

This doesn't seem to be a confgen issue but a vscode one. Please try to reinstall it as it suggests.

Who is online

Users browsing this forum: No registered users and 140 guests