-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add IDF_SKIP_PYTHON_CHECK env var (IDFGH-7790) #9328
Conversation
@stkw0 If you create a global (not user-specific) virtual environment and add the environment's interpreter to PATH, do you still get this error? I think it should work without bypassing the check. Something along these lines:
|
Right now I have IDF installed as any other application (say firefox, or whatever), the package managers is the one that installs IDF, this behavior is working fine in version 4.x of IDF. To avoid breaking this behavior no venv can be used as this would require user set-up (which is unfeasible because the package manager runs in a different user). After the package managers installs IDF it should be working without any configuration from user perspective (that's how it's working with v4.x and the idea would be to still work in a similar manner in 5.0) I understand that IDF is mainly used through local user installation, but is unfeasible in some use cases. I'm sorry if my explanations are not clear enough. |
Do you mean that you install all the Python package dependencies of ESP-IDF globally (as in, If that is the case, I'm afraid this won't work in general, since IDF's dependencies may conflict that with dependencies of other software in the system. There will also be a problem if multiple versions of IDF are installed side by side on the same system. With our current installation approach, each version will use its own virtual environment, and as a result can use different versions of packages.
I'm afraid I don't understand the reason behind this. It is possible to create a virtual environment as one user and then use it as another user. (For example, you can do |
ESP-IDF install scripts also support an environment variable, For example:
This will install all the tools and the virtual environment to /opt/esp. Later, as a regular user, you can run $IDF_PATH/export.sh and it will pick up the tools installed in /opt/esp. The only requirement is that IDF_TOOLS_PATH should be set to the same value in the user's environment. |
I mean more like |
Thanks, I would try if modifying the package to put IDF_TOOLS_PATH=/usr/share/esp-idf/tools in /etc/env.d fixes the issue |
Okay, so this doesn't work because obviously files installed by the package manager are not writable
|
I see, that's a bug which deserves to be fixed. We shouldn't require that I'll open a new issue to track this fix. |
Okay, thank you for your time |
It's really useful to make locally reproducible workflow. I presume if I checked out a revision then all rebuild should be the same (except hash which has a date change) . What happened actually is 2 weeks later after my vacation my build workflow failed, as it downloaded new espidf.constraints.v5.0.txt and complains esptool 4.2 should be installed instead of 4.1 And why this |
… file The Python dependency checker called from the export scripts and before build remains offline, i.e. it will use the previously downloaded constraint file but won't download a newer version. Related to #9328
… file The Python dependency checker called from the export scripts and before build remains offline, i.e. it will use the previously downloaded constraint file but won't download a newer version. Related to #9328
In some environments IDF is installed system-wide. With v5.0 some checks are done against user directories which obviously doesn't contain the required dependencies (they are installed system-wide) and as a result IDF fails to execute. A workaround for this is to simply ignore those checks if the user knows those dependencies are really provided, this way IDF can be run successfully.
Another approach would be to correctly check if dependencies are met wherever they are located.
See #9327