esphome / firmware

Holds firmware configuration files for projects that the ESPHome team provides.
https://esphome.io/projects
Apache License 2.0
126 stars 89 forks source link

can not build esp32 s3 box-3 #198

Closed lecrams closed 3 weeks ago

lecrams commented 3 weeks ago

using esphome 2024.5.4 gives me errors when I try to build the box-3 yaml: ERROR Unable to import component image: Traceback (most recent call last): File "C:\Users\a5128563\AppData\Roaming\Python\Python312\site-packages\esphome\loader.py", line 176, in _lookup_module module = importlib.import_module(f"esphome.components.{domain}") ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Program Files\Python312\Lib\importlib__init__.py", line 90, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 1387, in _gcd_import File "", line 1360, in _find_and_load File "", line 1331, in _find_and_load_unlocked File "", line 935, in _load_unlocked File "", line 995, in exec_module File "", line 488, in _call_with_frames_removed File "C:\Users\a5128563\AppData\Roaming\Python\Python312\site-packages\esphome\components\image__init.py", line 10, in from magic import Magic File "C:\Users\a5128563\AppData\Roaming\Python\Python312\site-packages\magic\init__.py", line 209, in libmagic = loader.load_lib() ^^^^^^^^^^^^^^^^^ File "C:\Users\a5128563\AppData\Roaming\Python\Python312\site-packages\magic\loader.py", line 49, in load_lib raise ImportError('failed to find libmagic. Check your installation') ImportError: failed to find libmagic. Check your installation WARNING GPIO0 is a strapping PIN and should only be used for I/O with care. Attaching external pullup/down resistors to strapping pins can cause unexpected failures. See https://esphome.io/guides/faq.html#why-am-i-getting-a-warning-about-strapping-pins Failed config

What can be wrong?

lecrams commented 3 weeks ago

Solved the issue by installing libmagic with the following commands: pip install python-libmagic pip install python-magic-bin. Now everything builds fine