Closed roflcoopter closed 1 year ago
Your build environment is broken in the docker container. You need to install any required build dependencies,. Looks like you are missing gcc to start and I'm sure numpy has others.
Yeah definitely, but i am running the official Home Assistant docker container which makes it difficult to install extra packages
So we didn't test on docker, as it's unsupported. I've tested on home assistant OS and a core install. Home assistant OS will pull the appropriate python packages and not attempt to build from source like we are seeing here. I would think that the Docker image should pull the Shapely musllinux wheel from https://github.com/home-assistant/wheels-custom-integrations the same as Home assistant OS. But as it installs in Home assistant OS, I don't think it's an issue with the integration.
So, I was incorrect, container is a supported install method, was thinking you were running supervised. I'll see if I can spin up a container and see if I can replicate.
Great, thanks for taking the time!
Hi all,
Same issue using stable homeassistant docker "stable" release
Logger: homeassistant.setup Source: setup.py:207 First occurred: 19:01:38 (1 occurrences) Last logged: 19:01:38
Setup failed for custom integration husqvarna_automower: Requirements for husqvarna_automower not found: ['Shapely>=1.8.2'].
I just pulled the latest HA stable container (2023.6.3) and installed Husqvarna Automower 2023.6.1, the install authenticated and installed all required packages without issue. Any further ideas on what might be unique about your installs?
For reference I used the following compose template.
version: '3'
services:
homeassistant:
container_name: homeassistant
image: "ghcr.io/home-assistant/home-assistant:stable"
volumes:
- /mnt/data/docker/ha/config:/config
- /etc/localtime:/etc/localtime:ro
restart: unless-stopped
privileged: true
network_mode: host
I believe this isn't related to the latest HA version since I got the same error on my 2023.5.3 setup. The integration isn't working anymore & after checking my configuration in the developer tools > YAML tab, I got this feedback:
Integration error: husqvarna_automower - Requirements for husqvarna_automower not found: ['Shapely>=1.8.2'].
I've tried to update Husqvarna integration in my HA 2023.6.3 docker and it fails to work. In logs I see: Setup failed for custom integration husqvarna_automower: Requirements for husqvarna_automower not found: ['Shapely>=1.8.2'].
Restoring backup fixes the issue. Maybe it's for HA 2023.7, but with each integration upgrade I need to play back and forth - copy my coordinates and other info, update, remove integration, add integration and set things back.
Yup - removed the integration and added and did setup again - everything works now.
I've tried to update Husqvarna integration in my HA 2023.6.3 docker and it fails to work. In logs I see: Setup failed for custom integration husqvarna_automower: Requirements for husqvarna_automower not found: ['Shapely>=1.8.2'].
Restoring backup fixes the issue. Maybe it's for HA 2023.7, but with each integration upgrade I need to play back and forth - copy my coordinates and other info, update, remove integration, add integration and set things back.
Yup - removed the integration and added and did setup again - everything works now.
Can you clarify this for me, when you removed the integration and reinstalled, did you install the current version 2023.6.1 or an older version?
I have installed 2023.7 version and it worked. But after HA restart it stopped working and I'm trying now to get back to working state without restoring backup. Have issues with configuration page not loading (2023.7 and 2023.6.1).
Update: Downloaded 2023.6.0, configured successfully and checked that it's working after restart. Updated to 2023.6.1 - getting errors.
`Logger: homeassistant.setup Source: setup.py:207 First occurred: 16:41:45 (1 occurrences) Last logged: 16:41:45
Setup failed for custom integration husqvarna_automower: Requirements for husqvarna_automower not found: ['Shapely>=1.8.2'].`
`Logger: homeassistant.util.package Source: util/package.py:107 First occurred: 16:40:29 (3 occurrences) Last logged: 16:41:45
Unable to install package Shapely>=1.8.2: error: subprocess-exited-with-error × pip subprocess to install build dependencies did not run successfully. │ exit code: 1 ╰─> [297 lines of output] Looking in links: https://wheels.home-assistant.io/alpine-3.12/amd64/ Collecting Cython~=0.29 Using cached Cython-0.29.36-py2.py3-none-any.whl (988 kB` (just a part - long one)
Got it, please post logs and we can look into it. I wasn't able to replicate earlier.
Added to my post above what I see in logs at the moment.
Downgraded integration to 2023.6.0 - everything works and HA restarts fast. My guess is that Docker container needs to be updated with Shapely >= 1.8.2. Not sure what it is, but was it a dependency all the time just lower build or it was introduced with 2023.6.1?
Added to my post above what I see in logs at the moment.
Downgraded integration to 2023.6.0 - everything works and HA restarts fast. My guess is that Docker container needs to be updated with Shapely >= 1.8.2. Not sure what it is, but was it a dependency all the time just lower build or it was introduced with 202
Added to my post above what I see in logs at the moment.
Downgraded integration to 2023.6.0 - everything works and HA restarts fast. My guess is that Docker container needs to be updated with Shapely >= 1.8.2. Not sure what it is, but was it a dependency all the time just lower build or it was introduced with 2023.6.1?
Yes, we added Shapely as a dependency in 2023.6.1. I'm not able to replicate it on my Docker host, I've rebooted several times without issue. Would it be possible to spin up a fresh HA container and see if you have the same installation issue?
I will try.
Is Shapely a part of docker image or it needs to be installed somehow?
I will try.
Is Shapely a part of docker image or it needs to be installed somehow?
It's compiled and hosted by Home Assistant at https://wheels.home-assistant.io/musllinux/ That's the issue, it should pull that wheel and install it, but it's falling back to trying to build it from source, which fails since the container and HA OS don't have a full build environment.
One note, I see in your logs, that it's looking for cython in https://wheels.home-assistant.io/alpine-3.12/amd64/ that will give a 404, since current version is 3.14, no idea if related.
Created another container and everything looks good. So something is broken in my setup. Will need to check how to fix as I have loads of integrations set :) Thanks for help!
Created another container and everything looks good. So something is broken in my setup. Will need to check how to fix as I have loads of integrations set :) Thanks for help!
Any chance your container is out of date, maybe need to pull the latest image?
It's the latest. And even tried to delete container, delete image, create container and have the same issue.
Very same issue here.
OK, so I'm at a standstill on this one, since I'm unable to replicate.
If you are having this issue, I would suggest a few things.
Beyond that, perhaps there is a bug in core that we need to raise, based on the responses here, it seems pretty limited. Would be good to know if this is only affecting a specific architecture.
I once again created a new separate container and compared container variables. And found the difference which was causing all of this.
Old and not working variable: WHEELS_LINKS https://wheels.home-assistant.io/alpine-3.12/amd64/
Working one: WHEELS_LINKS https://wheels.home-assistant.io/musllinux/
I just updated my original container with new link and tadaaa - integration got loaded.
@prairiesnpr - thank you for pointing to the right direction! Will need to check other variables as well :)
Sorry for being so quiet on this issue.
I actually switched to the linuxserver/homeassistant
container which at first gave me some other issues.
It turns out that i had to explicitly pull the amd64 tag linuxserver/homeassistant:amd64-2023.6.3
The multiarch container pulled the wrong image for some reason.
However, that container does not have https://wheels.home-assistant.io/musllinux/
as a pip index URL, so i created a custom init script which runs pip3 install --no-cache-dir --no-index --only-binary=:all: --find-links "https://wheels.home-assistant.io/musllinux/" Shapely>=1.8.2
and the problem is then solved!
@roflcoopter the pip3 command did the trick for me - thanks! I just hope that I do not have to repeat this every time the container starts again...
Hi all, the pip3 command fixed the issue for me too. I just had to remove the Husqvarna integration and add it again.
Thank you @triumfas and @roflcoopter. :)
Prerequirements [X] I have connected my mower(s) to the Automower Connect App [X] I have connected my Husqvanra developers account to the Authentication API [X] I have connected my Husqvarna developers account to the Automower Connect API
Describe the bug For some reason the integration stopped working when i tried o update to HA 2023.6.3 Now when i try to downgrade HA it still refuses to load the integration, failing to install deps. Here is the error log:
Is this something anyone else is experiencing?
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
Additional context Add any other context about the problem here.