hass-emulated-hue / core

Hue Emulation for Home Assistant
Apache License 2.0
320 stars 55 forks source link

Refactor and Beta Testing #265

Open alexyao2015 opened 2 years ago

alexyao2015 commented 2 years ago

Please see this comment for more information:

https://github.com/hass-emulated-hue/core/discussions/228#discussioncomment-2002926

To install this version, follow the instructions here and enter master for the value. It is also available as a tag for those not using the addon. Simply pull the master tag.

As I continue development, it would be extremely helpful for bugs and issues related to this new build to be reported here.

sojhinn commented 2 years ago

Downloaded and started testing. I was able to get the refactor version to work with hyperion as a hub. The hue app is not connecting. I cannot create a hub entertainment group in the hue essentials app. It looks like its trying to communicate via v2 but the refactor does not.

alexyao2015 commented 2 years ago

Thanks for testing. The v2 api has not been implemented yet but will be eventually. See the original comment for the roadmap.

github-actions[bot] commented 2 years ago

This issue has been marked as stale due to no activity and will be closed in 7 days.

dcmeglio commented 2 years ago

This was working for me but suddenly nothing can even connect to the hue hub. Not the hue app, nor Harmony app not Harmony hub. Wondering if haos 8.2 caused an issue. Is it working for anyone else?

dcmeglio commented 2 years ago

No idea of this adding is supported anymore. Author seems to have gone dark? But my issue seems to be a bug. my guess is this is because I defined a light entity in the configuration.yaml?

2022-06-15 22:59:36,073 ERROR aiohttp.server -- Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request
    resp = await request_handler(request)
  File "/usr/local/lib/python3.10/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/app/emulated_hue/apiv1.py", line 73, in wrapped_func
    return await func(cls, request)
  File "/app/emulated_hue/apiv1.py", line 144, in async_get_lights
    return send_json_response(await self.__async_get_all_lights())
  File "/app/emulated_hue/apiv1.py", line 788, in __async_get_all_lights
    device = await async_get_device(self.ctl, entity_id)
  File "/app/emulated_hue/controllers/devices.py", line 594, in async_get_device
    device_obj = new_device_obj(BrightnessDevice)
  File "/app/emulated_hue/controllers/devices.py", line 552, in new_device_obj
    return klass(
  File "/app/emulated_hue/controllers/devices.py", line 89, in __init__
    self._device = DeviceProperties.from_hass(
  File "/app/emulated_hue/controllers/devices.py", line 40, in from_hass
    device_id: str = ctl.controller_hass.get_device_id_from_entity_id(entity_id)
alexyao2015 commented 2 years ago

I'm still here, but haven't had a lot of time recently to work on this. Likely will be back towards the later/end of this year to really get things going again.

That does appear to be an actual bug. Presumably the light entity you added doesn't have a device attached to it in home assistant? If you click on the entity and go to related, does it show a device? I believe its expecting a device, but none exists.

dcmeglio commented 2 years ago

Correct. No device. It’s because I created it in yaml and you can’t assign a device via yaml

alexyao2015 commented 2 years ago

I pushed a fix. Give it a try

dcmeglio commented 2 years ago

Sorry how do I get it to update? It says there’s no update available

edit: guess I just needed to rebuild the container. So far so good.

alexyao2015 commented 2 years ago

If you restart the dev addon, it will automatically update

mat1990dj commented 1 year ago

Can we still use this? I can't find anymore the refactor tag

alexyao2015 commented 1 year ago

It was merged into master so use master now.

mat1990dj commented 1 year ago

So I'm trying to use the official Hue App, is this supported on any branch? If I use the stable integration it asks for update, and if I use the dev integration with master it doesn't but after accepting the request on home assistant and getting confirmation from the hue app it hangs on "Connecting" in the "share analytics" screen

alexyao2015 commented 1 year ago

Not yet

Tapsu10 commented 1 year ago

is the hue app supported now?