Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

homeassistant's upgrade to aiohue 2.3.0 seems to break diyhue compatibility with hue integration #678

Closed
2 tasks done
sidequestboy opened this issue Aug 14, 2021 · 2 comments

Comments

@sidequestboy
Copy link

sidequestboy commented Aug 14, 2021

Describe the bug

Upgrading to Home Assistant Core 2021.5.1 breaks the Hue integration's compatibility with the diyhue bridge

Steps to Reproduce

Install HA core 2021.5.1, install diyhue 1.4.1, add lights to diyhue via deconz for example, add the Philips Hue built-in HA integration, will be unable to connect to diyhue.

Expected behavior

The integration should connect fine like before

Logs

Logger: homeassistant.components.hue
Source: components/hue/bridge.py:252
Integration: Philips Hue (documentation, issues)
First occurred: 10:43:26 AM (1 occurrences)
Last logged: 10:43:26 AM

Unknown error connecting with Hue bridge at 192.168.1.142
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 85, in async_setup
    await authenticate_bridge(hass, bridge)
  File "/usr/src/homeassistant/homeassistant/components/hue/bridge.py", line 252, in authenticate_bridge
    await bridge.initialize()
  File "/usr/local/lib/python3.8/site-packages/aiohue/bridge.py", line 66, in initialize
    await self._figure_out_protocol()
  File "/usr/local/lib/python3.8/site-packages/aiohue/bridge.py", line 51, in _figure_out_protocol
    await self.request("head", "")
  File "/usr/local/lib/python3.8/site-packages/aiohue/bridge.py", line 85, in request
    res.raise_for_status()
  File "/usr/local/lib/python3.8/site-packages/aiohttp/client_reqrep.py", line 1000, in raise_for_status
    raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 501, message="Unsupported method ('HEAD')", url=URL('https://192.168.1.142/api/13354f82f8dc11eb89a70242ac1e2103/')
 Add-on version: 1.4.1
 You are running the latest version of this add-on.
 System: Home Assistant OS 6.2  (armv7 / raspberrypi4)
 Home Assistant Core: 2021.5.1
 Home Assistant Supervisor: 2021.06.8
...
192.168.1.142 - - [14/Aug/2021 10:51:17] code 501, message Unsupported method ('HEAD')
192.168.1.142 - - [14/Aug/2021 10:51:17] "HEAD /api/13354f82f8dc11eb89a70242ac1e2103/ HTTP/1.1" 501 -
...

Docker Info (please complete the following information):

Raspberry Pi 4, Home Assistant OS 6.2, supervisor-2021.06.8

Checklist

  • I confirm that this is a bug report
  • I confirm that I have completed this template to the best of my ability

Additional context

Rolling back HA core to 2021.5.0 makes this work again. It seems that the 2021.5.1 release includes a dependency upgrade from aiohue 2.1.0 to 2.3.0 50217 which seems likely to be the breaking change?

@sidequestboy sidequestboy changed the title homeassistant's upgrade to aiohue 2.3.0 breaks compatibility with ha hue integration homeassistant's upgrade to aiohue 2.3.0 seems to break diyhue compatibility with hue integration Aug 14, 2021
@mariusmotea
Copy link
Member

There is a new API implemented on the hue bridges, not documented yet. The guys from HA reverse engineered this API and implemented some features. We did the same, but the new API is implemented only in beta branch for last Hue Sync and Hue app compatibility.

@sidequestboy
Copy link
Author

thank you for the explanation - I installed the beta branch and can confirm that this is no longer an issue there. Though there seem to be other strange issues, so I think I will roll back for now.

Thanks for your fantastic work btw!

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

No branches or pull requests

2 participants