core: Error installing Honeywell Lyric Integration
The problem
When trying to install Honeywell Lyric integration, it fails.
First, it calls the api.honeywell.com address with the fixed redirect uri=https://my.home-assistant.io/redirect/oauth
If anyone don’t have my home assistant it returns an inmediate error message: “The redirect URL provided does not match the redirect URL registered for the app.”
I worked around this by modifying the uri parameter to http://homeassistant.local:8123/auth/external/callback
At this point I can enter the Honeywell api web without any problems, but when finish and redirect back to homeassistant, an Error without any text shows in homeassistant web UI.
What version of Home Assistant Core has the issue?
core-2022.7.0
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
Honeywell Lyric
Link to integration documentation on our website
https://www.home-assistant.io/integrations/lyric
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Logger: aiohttp.server
Source: components/lyric/api.py:64
First occurred: 16:47:02 (8 occurrences)
Last logged: 17:44:52
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 "/usr/local/lib/python3.10/site-packages/aiohttp/web_middlewares.py", line 117, in impl
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 100, in forwarded_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 79, in ban_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 236, in auth_middleware
return await handler(request)
File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 136, in handle
result = await result
File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 168, in get
return await super().get(request, flow_id)
File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 95, in get
result = await self._flow_mgr.async_configure(flow_id)
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 277, in async_configure
result = await self._async_handle_step(
File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 359, in _async_handle_step
result: FlowResult = await getattr(flow, method)(user_input)
File "/usr/src/homeassistant/homeassistant/helpers/config_entry_oauth2_flow.py", line 303, in async_step_creation
token = await self.flow_impl.async_resolve_external_data(self.external_data)
File "/usr/src/homeassistant/homeassistant/helpers/config_entry_oauth2_flow.py", line 169, in async_resolve_external_data
return await self._token_request(
File "/usr/src/homeassistant/homeassistant/components/lyric/api.py", line 64, in _token_request
resp.raise_for_status()
File "/usr/local/lib/python3.10/site-packages/aiohttp/client_reqrep.py", line 1004, in raise_for_status
raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 500, message='Internal Server Error', url=URL('https://api.honeywell.com/oauth2/token')
Additional information
System Health
| version | core-2022.7.0 |
|---|---|
| installation_type | Home Assistant OS |
| dev | false |
| hassio | true |
| docker | true |
| user | root |
| virtualenv | false |
| python_version | 3.10.5 |
| os_name | Linux |
| os_version | 5.15.32-v8 |
| arch | aarch64 |
| timezone | Europe/Madrid |
| config_dir | /config |
Home Assistant Community Store
| GitHub API | ok |
|---|---|
| GitHub Content | ok |
| GitHub Web | ok |
| GitHub API Calls Remaining | 5000 |
| Installed Version | 1.25.5 |
| Stage | running |
| Available Repositories | 1072 |
| Downloaded Repositories | 6 |
Home Assistant Cloud
| logged_in | false |
|---|---|
| can_reach_cert_server | ok |
| can_reach_cloud_auth | ok |
| can_reach_cloud | ok |
Home Assistant Supervisor
| host_os | Home Assistant OS 8.2 |
|---|---|
| update_channel | stable |
| supervisor_version | supervisor-2022.07.0 |
| agent_version | 1.2.1 |
| docker_version | 20.10.14 |
| disk_total | 3667.5 GB |
| disk_used | 2078.2 GB |
| healthy | true |
| supported | true |
| board | rpi4-64 |
| supervisor_api | ok |
| version_api | ok |
| installed_addons | Samba share (10.0.0), Mosquitto broker (6.1.2), File editor (5.3.3), Terminal & SSH (9.6.0), Grafana (7.6.0), Home Assistant Google Drive Backup (0.108.2) |
Dashboards
| dashboards | 2 |
|---|---|
| resources | 1 |
| views | 1 |
| mode | storage |
Recorder
| oldest_recorder_run | 6 de julio de 2022 08:08 |
|---|---|
| current_recorder_run | 7 de julio de 2022 13:12 |
| estimated_db_size | 68.82 MiB |
| database_engine | sqlite |
| database_version | 3.38.5 |
Sonoff
| version | 3.1.0 (3871c0b) |
|---|---|
| cloud_online | 3 / 4 |
| local_online | 3 / 3 |
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 17
I have the same again. Also found out that the Honeywell-app has a new name Residio.
Following up on the URI issue go to https://my.home-assistant.io and set your instances URL there, and then when you create the lyric app put in https://my.home-assistant.io/redirect/oauth for the callback instead of what you’d normally use.
The integration just broke for me on 2022.8.0.dev0 (I’m running from git), also noticed the response url is wrong as well (where does https://my.home-assistant.io/redirect/oauth even come from? Is this part of the cloud based integration? What happens, like in my case, you aren’t using the cloud based access to HASS?) changing the redirect_uri gets me to log in, but then I get permission denied for type internal.
Ended up changing the auth information in .storage which just broke the integration, which was thankfully enough to get me a remove button. Removed it and tried to re-create it and got the same above issues.
So I think there’s probably 2 issues at play:
I haven noticed that the HomeKit integration has gotten SUBSTANTIALLY better, and honestly at this point the Lyric/Resideo remote API seems superfluous and a subset of what can be used from the HomeKit integration. I’d actually argue in favor of deprecating this entirely on that basis.