Lutron dimmer switches will not load after upgrade to 66.0 hassio

Looks like my connection to Caseta is broken now as well with the non-pro hub. thanks for the ideas in this thread

cappiel,

Did your bridge lose power?

No, seemed to break when I upgraded HA to .67.

Blockquote 2018-04-14 14:01:20 ERROR (MainThread) [homeassistant.setup] Error during setup of component lutron_caseta
Traceback (most recent call last):
File “/usr/src/app/homeassistant/setup.py”, line 142, in _async_setup_component
result = await component.async_setup(hass, processed_config)
File “/usr/src/app/homeassistant/components/lutron_caseta.py”, line 57, in async_setup
yield from bridge.connect()
File “/usr/local/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 40, in connect
yield from self._login()
File “/usr/local/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 284, in _login
yield from self._load_devices()
File “/usr/local/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 314, in _load_devices
for device in device_json[‘Body’][‘Devices’]:
KeyError: ‘Body’

FYI - there is a pull request to fix it on non-pro now:
https://github.com/gurumitts/pylutron-caseta/pull/23

2 Likes

@xnappo, thanks for the info. Of course I ordered Wink hub 2 yesterday.

@xnappo Does it fix HA integration with non pro? Thought it just fixed the script errors to retrieve certificates but assumed HA still doesn’t work. I am not home this weekend to test

It should - I can’t test because my non-pro is on its way to an eBay buyer :smiley:

I have a pro hub and as of this morning can no longer control my dimmers. I did a homeassistant restart and now this is in my logs:

8-04-15 09:05:06 ERROR (MainThread) [homeassistant.setup] Error during setup of component lutron_caseta
Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/homeassistant/setup.py”, line 142, in _async_setup_component
result = await component.async_setup(hass, processed_config)
File “/usr/lib/python3.6/site-packages/homeassistant/components/lutron_caseta.py”, line 57, in async_setup
yield from bridge.connect()
File “/usr/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 40, in connect
yield from self._login()
File “/usr/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 284, in _login
yield from self._load_devices()
File “/usr/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py”, line 314, in _load_devices
for device in device_json[‘Body’][‘Devices’]:
KeyError: ‘Body’

I haven’t read through all of the entries here, but does this seem like the same issue?
I’m running hassio 0.66.1.

@martamoonpie - there error looks similar, but agree not exactly the same. See my bug report here:

You can try the new fix in the pull request - but honestly since you have the Pro - I would switch to the non-official version here:

xnappo

1 Like

Thanks for the quick response. That was surprisingly painless to do and my lights are working again. :grin:

I was able to get lutron working again after the update. Hopefully this will save some of you some money for the pro bridge. There’s a merge that hasn’t been completed for pylutron_caseta yet. I’m using homeassistant/qemux86-64-homeassistant, so change where appropriate.

docker ps

  • Find the container id for homeassistant/qemux86-64-homeassistant or whatever you’re using

docker exec -it CONTAINER_ID /bin/bash
curl -o /usr/lib/python3.6/site-packages/pylutron_caseta/smartbridge.py https://raw.githubusercontent.com/mdonoughe/pylutron-caseta/f5fec6a3a32b71bc70d2a915285ebd4077e05606/pylutron_caseta/smartbridge.py
exit
docker commit CONTAINER_ID homeassistant/qemux86-64-homeassistant:0.67.0.1
docker tag homeassistant/qemux86-64-homeassistant:0.67.0.1 homeassistant/qemux86-64-homeassistant:latest

systemctl restart hassio-supervisor

I am up and working on non-pro via the pull request.

Anyone know where I can find the pylutron-caseta folder on a standard hassio install in order to update the files?

I followed the directions @shdw posted. You may need to follow these directions in order to ssh in

I am running hassbian.
How do I do a pull request to fix this?

@joeaverge9 @brettzie
The pylutron_caseta folder is location at
/usr/lib/python3.6/site-packages/pylutron_caseta/

All you need to do is replace smartbridge.py file with version in pull request.

There are steps posted above but since this PR includes one file change (smartbridge.py), I would just manually replace it. Much easier.

Then retrieve new certificates via the get_lutron_cert.py in this same PR.

Did you switch to the custom upsert/lutron-caseta-pro or just update smartbridge.py?

I switched to the custom upsert/lutron-caseta-pro.

ETA: My lights did end up with slightly different names, so I had to rework some automations and things. So be on the lookout for that if you go that route.

1 Like

Got it working with the Non-Pro.
Yes, I updated the smartbridge.py with the newest
But, becasue I have never had it setup I had to download the latest get_lutron_cert.py and re-run the create certs script.

YEAH!!! Thanks ALL

Hey! I’m trying to run the script to get the certs on my Mac but am running into issues with it…Do you have a place with a script I should run?