I was running into the 500 internal error issue like some others. I am on the latest version of HASSIO, 0.72.1. And I didn’t want to downgrade per one of the suggestions. Looking in the logs I found that the issue was with this line 201 data = request.GET, as the error said “‘function’ object has no attribute ‘get’”. Since I could get all the way to the authorization and had the codes, I hard coded the data into the following code to make it work and get past trying to grab the codes from the URL.
After you get the page with the 500 error, copy the CODE and STATE from the URL and replace it as listed below. Restart hassio from the command line (leaving your web pages open) and then refresh the authorization page. Click Continue on the original authorization popup, and you are now authorized. I’m sure a little tweaking of the request code will work, but I am not that familiar with Python.
#data = request.GET
#if 'code' not in data or 'state' not in data:
# return self.json_message('Authentication failed, not the right '
# 'variables, try again.', HTTP_BAD_REQUEST)
self.lyric.authorization_code(code='codefromurl', state='statefromurl')
Unfortunately I see little activity in this topic. When I moved to HASSIO few months ago my lyric setup in HASS broke and never took the time to set it back up. Are you guys still using this custom component under recent HASS versions (eg .73.x)?
Indeed! just created the custom_components folder again and copied the last files from here and I was back in business again. Did not even have to re-authorize. Using 75.2 (HassIO)
I got an error, running version 0.77.3 and trying to configure Lyric.
See error code:
2018-09-09 12:00:16 INFO (MainThread) [homeassistant.components.http.view] Serving /api/lyric/authent
icate to 192.168.1.9 (auth: False)
2018-09-09 12:00:16 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/aiohttp/web_protocol.py", line 390, in start
resp = await self._request_handler(request)
File "/usr/local/lib/python3.6/site-packages/aiohttp/web_app.py", line 352, in _handle
resp = await handler(request)
File "/usr/local/lib/python3.6/site-packages/aiohttp/web_middlewares.py", line 106, in impl
return await handler(request)
File "/usr/src/app/homeassistant/components/http/static.py", line 66, in staticresource_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/ban.py", line 67, in ban_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/auth.py", line 68, in auth_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/real_ip.py", line 34, in real_ip_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/ban.py", line 67, in ban_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/auth.py", line 68, in auth_middleware
return await handler(request)
File "/usr/src/app/homeassistant/components/http/view.py", line 113, in handle
result = await result
File "/usr/local/lib/python3.6/asyncio/coroutines.py", line 212, in coro
res = func(*args, **kw)
File "/config/custom_components/lyric.py", line 201, in get
data = request.GET
AttributeError: 'Request' object has no attribute 'GET'
The reported temps are still working (ie, updating in a climate card), but changing the set temp via a card does not change the set point on the thermostat.
The official Honeywell app is where I have a schedule defined and where I can manually update the set temp if needed.
I can still change temps but only once. If I change one temp, I can’t change the other zones right after. It doesn’t actually update unless I try after a few hours. But it has been that way since day 1 for me.
I downgraded to 63.3 and it still won’t work. Any ideas,
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.6/site-packages/homeassistant/setup.py”, line 193, in _async_setup_component
component.setup, hass, processed_config)
File “/usr/lib/python3.6/asyncio/futures.py”, line 327, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.6/asyncio/tasks.py”, line 250, in _wakeup
future.result()
File “/usr/lib/python3.6/asyncio/futures.py”, line 243, in result
raise self._exception
File “/usr/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/home/ha/.homeassistant/custom_components/lyric.py”, line 116, in setup
import lyric
File “/srv/homeassistant/lib/python3.6/site-packages/lyric/init.py”, line 6, in
from requests_oauthlib import OAuth2Session
File “/srv/homeassistant/lib/python3.6/site-packages/requests_oauthlib/init.py”, line 11, in
if requests.version < ‘2.0.0’:
TypeError: ‘<’ not supported between instances of ‘module’ and ‘str’
Are you using the custom component or the homekit controller method? I was getting a lot of the broken pipe errors with the homekit method, but it seems to be working flawlessly on 0.80 (I just updated today, so fingers crossed).