mirrexagon / nixpkgs-esp-dev

Nix flake and overlay for ESP8266 and ESP32 development.
Creative Commons Zero v1.0 Universal
143 stars 71 forks source link

python packages not matching the esp-idf release #66

Closed mksafavi closed 1 month ago

mksafavi commented 1 month ago

I recently ran into a problem that was cause by the python packages not matching the versions included in the esp-idf release.

I also looked into the esp-idf.constraints files. I think the limits are too lax to get the same versions as the idf release. Do you think it would be better to match the python packages with a requirements.txt from the esp-idf docker containers?

mirrexagon commented 1 month ago

Having a quick poke around the Dockerfile and what it does in esp-idf, it doesn't seem to have its own requirements.txt, it just calls $IDF_PATH/tools/idf_tools.py --non-interactive install-python-env, which seems to use the constraints file to resolve dependency versions. Did you find something more concrete?

mirrexagon commented 1 month ago

I'm updating the Python packages again based on running pip install -r esp-idf/tools/requirements/requirements.core.txt --constraint=espidf.constraints.v5.3.txt --dry-run. But that still depends on the state of packages on PyPI.

If we could download a prebuilt docker container and query what versions it has, maybe that would work? Ideally Espressif would publish an exact requirements file, but even then we would still need to get the hashes for Nix, but it might make it easier?

mirrexagon commented 1 month ago

Also see #25.

mirrexagon commented 1 month ago

Actually, maybe we should move the conversation there - both issues are about matching Python packages to ESP-IDF versions.