Core: Component not found: hue

Created on 27 Apr 2019  路  10Comments  路  Source: home-assistant/core

Home Assistant release with the issue:

hass --version
0.92.1

Last working Home Assistant release (if known): 0.91.x

Component/platform: Hue (maybe others too)

Description of problem:

Create a simple configuration.yaml file with just the following.

hue:
  bridges:
    - host: 192.169.1.100

And try to run the following command hass -c . --script check_config. The command will fail with.

INFO:homeassistant.util.package:Attempting install of colorlog==4.0.2
Testing configuration at /Users/aerialls/homeassistant-hue-bug/.
Failed config
  General Errors:
    - Component not found: hue

It was working great with the latest release in 0.91.x. I've checked all commit releated to Hue without finding much.

All 10 comments

This is likely due to the changes in https://github.com/home-assistant/home-assistant/pull/23112 which allowed for imports to be moved to the top of the file. CC: @balloob

$ docker run -it python:3.7 /bin/sh
# cd /root
# pip install homeassistant==0.92.1
# echo hue: > configuration.yaml
# hass -c . --script check_config
INFO:homeassistant.util.package:Attempting install of colorlog==4.0.2
Testing configuration at /root/.
Failed config
  General Errors:
    - Component not found: hue

Successful config (partial)
# pip install aiohue
# hass -c . --script check_config
Testing configuration at /root/.
# 

The problem is that the check config script runs with skipping pip. It should only do that when it's run from inside HA, not via CLI.

Same here:
[Info] Installed homeassistant==0.92.1, check config now
[Error] Wrong config found!
Testing configuration at /tmp/config
Failed config
General Errors:
- Component not found: hue
- Platform not found: light.hue
Can I just continue the update, or is it better to wait for a fix?

Unfortunately, 0.92.2 is out but got the same error:
[Info] Installed homeassistant==0.92.2, check config now
[Error] Wrong config found!
Testing configuration at /tmp/config
Failed config
General Errors:
- Component not found: hue
- Platform not found: light.hue

Successful config (partial)

Same here, when testing with Home Assistant configuration plugin for 0.92.2 got this:
[Error] Wrong config found!
Testing configuration at /tmp/config
Failed config
General Errors:
- Component not found: hue

Successful config (partial)

Well I thought, since I'm running Hass io in a vm, I create a snapshot and just go on with the update.

First It did not boot at all, but that was due to config error in http component. Restored snapshot, fixed it.
Then ran the config checker again, only error was:

[Info] Start install HomeAssistant latest
You are using pip version 19.0.3, however version 19.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
[Info] Installed homeassistant==0.92.2, check config now
[Error] Wrong config found!
Testing configuration at /tmp/config
Failed config
General Errors:
- Platform not found: light.hue
- Component not found: hue

Successful config (partial)

So I clicked "update".....
And everything just works!

FYI, The issue is still here with 0.93.

I found the issue. I've opened the PR #23957 to fix it.

Was this page helpful?
0 / 5 - 0 ratings