apple/swift-matter-examples

Failing in installing esp-matter sdk

Closed this issue · 1 comments

I followed the guide on how to install the prerequisites and esp-idf and esp-matter SDKs on my mac machine using the documentation linked in the project. ESP Matter SDK fails to install when I run ./install.sh. Here is the last few line of the error output:

...

  File "/Users/a.asadi/esp/esp-matter/connectedhomeip/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 573, in setup
    result = step(spin)
             ^^^^^^^^^^
  File "/Users/a.asadi/esp/esp-matter/connectedhomeip/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/env_setup.py", line 762, in virtualenv
    if not virtualenv_setup.install(
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/a.asadi/esp/esp-matter/connectedhomeip/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py", line 443, in install
    install_packages(gn_target)
  File "/Users/a.asadi/esp/esp-matter/connectedhomeip/connectedhomeip/third_party/pigweed/repo/pw_env_setup/py/pw_env_setup/virtualenv_setup/install.py", line 424, in install_packages
    raise subprocess.CalledProcessError(
subprocess.CalledProcessError: Command '['ninja', '-C', '/Users/a.asadi/esp/esp-matter/connectedhomeip/connectedhomeip/.environment/gn_out', '-v', ':python_packages.install']' returned non-zero exit status 1.

I also explained and provided more info about the installation issue on the esp-matter repo itself. espressif/esp-matter#1021

This issue does not directly relate to this repository but I'm asking for help if anyone has encountered and fixed it.

Here is the solution to the this problem: espressif/esp-matter#1021 (comment)

Before installing download the patch from the comment linked above.

cd connectedhomeip/connectedhomeip
git apply path/to/change_python_pkg_version.patch
rm -rf .environment
cd ../../
source ~/esp/esp-idf/export.sh
./install.sh

Replace path/to/change_python_pkg_version.patch with the actual path.