hacs / integration

HACS gives you a powerful UI to handle downloads of all your custom needs.
https://hacs.xyz
MIT License
5.26k stars 1.27k forks source link

Failed to install HACS #2238

Closed ardoviniandrea closed 2 years ago

ardoviniandrea commented 2 years ago

System Health details

System Health

version core-2021.10.1
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.9.7
os_name Linux
os_version 5.10.17-v8
arch aarch64
timezone Europe/Copenhagen
Home Assistant Community Store error | failed to load: unknown -- | --
AccuWeather error | failed to load: unknown -- | --
Home Assistant Cloud logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Home Assistant OS 6.4 -- | -- update_channel | stable supervisor_version | supervisor-2021.10.0 docker_version | 20.10.7 disk_total | 58.0 GB disk_used | 7.3 GB healthy | true supported | true board | rpi3-64 supervisor_api | ok version_api | ok installed_addons | SSH & Web Terminal (9.0.1), Node-RED (10.0.1), Glances (0.13.0), File editor (5.3.3), Samba share (9.5.1), Duck DNS (1.14.0), AdGuard Home (4.1.9), NGINX Home Assistant SSL proxy (3.0.2)
Lovelace dashboards | 1 -- | -- resources | 15 views | 5 mode | storage
Spotify api_endpoint_reachable | ok -- | --

Checklist

Describe the issue

After upgrading core to 2021.10.03 HACS stopped working (ie. not loading saying "entity not found") Some of my custom integration were also not working.

I restored the previous core from the backup created before the upgrade.

Now everything works but I cannot access HACS anymore. I tried removing HACS completely following the guide but when I reinstall it again it gives me the error I posted in the debug logs below

Reproduction steps

mentioned in the "describe issue"

Debug logs

This error originated from a custom integration.

Logger: homeassistant.config_entries
Source: custom_components/hacs/tasks/setup_frontend.py:4
Integration: HACS (documentation, issues)
First occurred: 10:44:20 AM (1 occurrences)
Last logged: 10:44:20 AM

Error setting up entry for hacs
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 304, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/config/custom_components/hacs/__init__.py", line 39, in async_setup_entry
    return await hacs_ui_setup(hass, config_entry)
  File "/config/custom_components/hacs/operational/setup.py", line 99, in async_setup_entry
    await _async_common_setup(hass)
  File "/config/custom_components/hacs/operational/setup.py", line 55, in _async_common_setup
    await hacs.tasks.async_load()
  File "/config/custom_components/hacs/tasks/manager.py", line 43, in async_load
    await asyncio.gather(*[_load_module(task) for task in task_modules])
  File "/config/custom_components/hacs/tasks/manager.py", line 39, in _load_module
    task_module = import_module(f"{__package__}.{module}")
  File "/usr/local/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/config/custom_components/hacs/tasks/setup_frontend.py", line 4, in <module>
    from hacs_frontend import locate_dir
ImportError: cannot import name 'locate_dir' from 'hacs_frontend' (/usr/local/lib/python3.9/site-packages/hacs_frontend/__init__.py)
hacs-bot[bot] commented 2 years ago

Make sure you have read the issue guidelines and that you filled out the entire template.

ludeeus commented 2 years ago

Your python packages have issues, run ha core rebuild to rebuild the core container, this will restart it and HA will reinstall missing packages.

TheJokerArtZ commented 2 years ago

Hi i dont know if im right here but i cant install HACS with the install command:

wget -O - https://get.hacs.xyz | bash -

and i get this far:

error

i tried different command always the same error

pls halp

ludeeus commented 2 years ago

@TheJokerArtZ disable IPv6 and no, not the right place, this is unrelated.

ardoviniandrea commented 2 years ago

Your python packages have issues, run ha core rebuild to rebuild the core container, this will restart it and HA will reinstall missing packages.

This actually fixed it, thank you very much. My HACS was completely new and I had to re-download everything but all good.

Thanks