[BUG] Integration tuya-local does not load due to missing dependency
Joery opened this issue · 4 comments
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
When setting up the tuya-local integration, the following error message is given:
Config flow could not be loaded: {"message":"Invalid handler specified"}
And the logs give the following error message:
Logger: homeassistant.config_entries
Source: config_entries.py:852
First occurred: 31 January 2023 at 13:35:04 (2 occurrences)
Last logged: 10:15:07
Error occurred loading configuration flow for integration tuya_local: No module named 'tinytuya'
I've already contacted the tuya-local maintainer (see here), however they mention that the wheels repository takes care of dependencies, when checking the manifest, it does specify tinytuya as dependency.
Any idea why the tinytuya dependency doesn't seem to work? Thanks!
Expected Behavior
The integration loads and the config-flow is started.
Steps To Reproduce
- Run Home Assistant with the environment with the environment and docker-compose file mentioned below
- Run through the initial Home Assistant setup
- Install HACS as described here
- Add the tuya-local repository as custom repository in HACS
- Install tuya-local
- Start the tuya-local integration
Environment
- OS: Ubuntu 22.04 with the latest updates installed, running as VM in an ESXi 8 environment.
- How docker service was installed:
Docker & docker-compose were installed via the Docker repository as described here:
https://docs.docker.com/engine/install/ubuntu/#install-using-the-repository
(Using "docker compose" and not the Python-based "docker-compose")
- Home Assistant: Using the latest 2023.1.7-ls115 release
CPU architecture
x86-64
Docker creation
home-assistant:
container_name: home-assistant
depends_on:
- authelia
- traefik
environment:
- PUID=$PUID
- PGID=$PGID
- TZ=$TZ
expose:
- 8123
image: linuxserver/homeassistant:latest
labels:
- traefik.enable=true
- traefik.http.routers.home-assistant.rule=Host(`home.$DOMAIN`)
- traefik.http.services.home-assistant.loadbalancer.server.port=8123
- traefik.http.services.home-assistant.loadbalancer.server.url=http://x.x.x.x:8123
network_mode: host
privileged: true
restart: unless-stopped
volumes:
- $DOCKER/home-assistant:/config
Container logs
No errors or warnings are being logged besides the following:
2023-02-01 10:07:39.098 ERROR (MainThread) [homeassistant.config_entries] Error occurred loading configuration flow for integration tuya_local: No module named 'tinytuya'
We install all the python modules listed in the HA core requirements: https://github.com/home-assistant/core/blob/dev/requirements_all.txt
Perhaps community ones aren't listed there.
I'll look into it but in the meantime you can use this mod to install the module: https://github.com/linuxserver/docker-mods/tree/universal-package-install
Ah, thanks for the link. Tinytuya isn't listed in the HA core requirements, probably because the official Tuya integration is using their own CLI package.
I'll try to see if I can get it working with the package install mod!