Skip to content
This repository has been archived by the owner on Jul 23, 2021. It is now read-only.

ModuleNotFoundError: No module named 'hue_sensors' #19

Closed
ashald opened this issue Dec 18, 2017 · 8 comments
Closed

ModuleNotFoundError: No module named 'hue_sensors' #19

ashald opened this issue Dec 18, 2017 · 8 comments

Comments

@ashald
Copy link

ashald commented Dec 18, 2017

Just installed Home Assistant 0.60.0 as a Docker container and that's what I see in log when I activate the plugin

Log Details (ERROR)
Sun Dec 17 2017 21:12:05 GMT-0500 (EST)

Error while setting up platform hue
Traceback (most recent call last):
  File "/usr/src/app/homeassistant/helpers/entity_component.py", line 171, in _async_setup_platform
    SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
  File "/usr/local/lib/python3.6/asyncio/tasks.py", line 358, in wait_for
    return fut.result()
  File "/usr/local/lib/python3.6/asyncio/futures.py", line 245, in result
    raise self._exception
  File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/sensor/hue.py", line 24, in setup_platform
    import hue_sensors as hs
ModuleNotFoundError: No module named 'hue_sensors'
@robmarkcole
Copy link
Owner

robmarkcole commented Dec 18, 2017

Appears HA has failed to install hue_sensors. Is there another error in the logs on startup stating something like 'failed to install hue_sensors'? Cheers

@robmarkcole
Copy link
Owner

OK I'm running 85f0119 on Docker (synology) and no errors. Let me know and please close this issue if the release resolves. Btw be sure to remove hue from your config.
Cheers

@michaelmaat
Copy link

After updating hass.io and hue-sensors-hass to 0.60 I ran into the same problem as Ashald.

Here is my config:

sensor:
  - platform: hue_sensor

hue:
  bridges:
    - host: 192.168.178.44

Removing the hue/bridges/host did fix the hue sensors, but my lights didn't show up anymore. So I put back the config and did a full reboot (hassio host reboot instead of hassio homeassistant restart) of my Pi. Now everything works again :)

@ashald
Copy link
Author

ashald commented Dec 19, 2017

I'm running under Docker on Synology as well. I pulled the latest code from the repo and removed hue from the config but now I see:

Traceback (most recent call last):
  File "/usr/src/app/homeassistant/helpers/entity_component.py", line 171, in _async_setup_platform
    SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
  File "/usr/local/lib/python3.6/asyncio/tasks.py", line 358, in wait_for
    return fut.result()
  File "/usr/local/lib/python3.6/asyncio/futures.py", line 245, in result
    raise self._exception
  File "/usr/local/lib/python3.6/concurrent/futures/thread.py", line 56, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/sensor/hue_sensor.py", line 40, in setup_platform
    url = load_conf(filepath) + '/sensors'
  File "/config/custom_components/sensor/hue_sensor.py", line 26, in load_conf
    with open(filepath, 'r') as file_path:
FileNotFoundError: [Errno 2] No such file or directory: '/config/phue.conf'

There is indeed no /config/phue.conf in my /config but there is phue-0017886c3a18.conf. o_O Did I miss anything else?..

@ashald
Copy link
Author

ashald commented Dec 19, 2017

P.S.: After I copied phue-0017886c3a18.conf to phue.conf it worked. But I'm not sure that was the right thing to do...

@ashald
Copy link
Author

ashald commented Dec 19, 2017

P.P.S.: Also, if I remove

hue:

from my config then I don't see my lights in HA... is that intentional? I'd rather see them there. Just wonder if it's incompatible with this package in any way.

@hanssep
Copy link

hanssep commented Dec 25, 2017

Confirming @michaelmaat "solution" works. This is an awesome addon but it should work with the hue: component enabled in the configuration (my Hue lights don't show otherwise).

Looking forward seeing this as an official component in next HASS release.

@robmarkcole
Copy link
Owner

Interesting, so reboot of Hassio is required. Cheers

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants