platform-espressif cannot satisfy python requirement for pyparsing >=2.0.3,<2.4.0
See original GitHub issueSynopsis
On ArchLinux and NixOS, the system package manager installs pyparsing-2.4.7. The espidf framework is unable to install an appropriate version of pyparsing. One user posted on the PlatformIO forum they tried to use venv
to construct a python environment with an older version of pyparsing to no avail [1].
Are there any work arounds for this issue? My searches yielded few relevant results.
This error effectively makes platformio useless for my ESP32-related development. Would it make sense to incorporate patches that support pyparsing >2.4.0 in platform-espressif?
[1]: https://community.platformio.org/t/espressif32-python-dependencies/15839
Details
In a new, empty platformio project, I’ve set the following settings…
; platformio.ini
[env:usb]
board = esp32cam
platform = espressif32@^2.1.0
; platform = https://github.com/platformio/platform-espressif32.git
framework = espidf
lib_deps = espressif/esp32-camera@^1.0.0
…and when I run pio run
, I find the following error:
# Snipped relevant section
The following Python requirements are not satisfied:
pyparsing>=2.0.3,<2.4.0
$ pio run
Processing usb (board: esp32cam; platform: espressif32@^2.1.0; framework: espidf)
---------------------------------------------------------------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32cam.html
PLATFORM: Espressif 32 (2.1.0) > AI Thinker ESP32-CAM
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-espidf 3.40100.200827 (4.1.0)
- tool-cmake 3.16.4
- tool-esptoolpy 1.30000.201119 (3.0.0)
- tool-ninja 1.7.1
- toolchain-esp32ulp 1.22851.191205 (2.28.51)
- toolchain-xtensa32 2.80200.200827 (8.2.0)
Reading CMake configuration...
-- Found Git: /usr/bin/git (found version "2.30.0")
-- The C compiler identification is GNU 8.2.0
-- The CXX compiler identification is GNU 8.2.0
-- The ASM compiler identification is GNU
-- Found assembler: /home/devuser/.platformio/packages/toolchain-xtensa32/bin/xtensa-esp32-elf-gcc
-- Check for working C compiler: /home/devuser/.platformio/packages/toolchain-xtensa32/bin/xtensa-esp32-elf-gcc
-- Check for working C compiler: /home/devuser/.platformio/packages/toolchain-xtensa32/bin/xtensa-esp32-elf-gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /home/devuser/.platformio/packages/toolchain-xtensa32/bin/xtensa-esp32-elf-g++
-- Check for working CXX compiler: /home/devuser/.platformio/packages/toolchain-xtensa32/bin/xtensa-esp32-elf-g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Project version: 4d8b3c9
-- Building ESP-IDF components for target esp32
-- Checking Python dependencies...
The following Python requirements are not satisfied:
pyparsing>=2.0.3,<2.4.0
Please follow the instructions found in the "Set up the tools" section of ESP-IDF Getting Started Guide
-- Configuring incomplete, errors occurred!
See also "/home/devuser/files/development/embedded/esp-cam/.pio/build/usb/CMakeFiles/CMakeOutput.log".
fatal: not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
CMake Error at /home/devuser/.platformio/packages/framework-espidf/tools/cmake/build.cmake:271 (message):
Some Python dependencies must be installed. Check above message for
details.
Call Stack (most recent call first):
/home/devuser/.platformio/packages/framework-espidf/tools/cmake/build.cmake:397 (__build_check_python)
/home/devuser/.platformio/packages/framework-espidf/tools/cmake/project.cmake:396 (idf_build_process)
CMakeLists.txt:3 (project)
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (3 by maintainers)
Top GitHub Comments
You can use a universal installation script https://docs.platformio.org/en/latest/core/installation.html?highlight=virtual#step-2-install-platformio-core, so no need to mess with Docker.
@veleros Can confirm that the universal installation script was able to provide an isolated python + PlatformIO, and the espressif platform installed pyparsing-2.3.1_ and compiled an “empty”/new project successfully.
FYI to anyone else searching for a solution.
/home/user/.platformio/penv
.source ~/.platformio/penv/bin/activate
(or add this command to your .bashrc, etc) to configure the environment to run the isolated python + platformio.pio run
will download esp-idf, install dependencies, and compile!