bodyscape / cielo_home

Integration with Cielo Home
Apache License 2.0
44 stars 10 forks source link

Integration broken #57

Closed jrseliga closed 3 months ago

jrseliga commented 3 months ago

At some point today all of my Cielo devices became Unavailable.

The following troubleshooting steps were completed:

  1. Remove the integration
  2. Restart Home Assistant
  3. Add the integration

Upon adding the integration, while the devices were successfully discovered many of the (most important -- Temperature Control, Mode, etc.) entities are now missing.

Screenshot from 2024-03-29 13-26-54

I suspect Cielo made some changes to their API that is causing this.

gwilliams1205 commented 3 months ago

This has happened to me as well.. It looks like something changed within Cielo.. When I go the home.cielowigle.com app it now shows 0 devices even though their native app still shows my device available. image

mworsnop commented 3 months ago

same here. On the Cielo app website I can click on temp or anything and it says session expired. and it doesnt work

WaleedAly commented 3 months ago

Same issue here

josheharvey commented 3 months ago

Came here because of the same issue

m3rg3d0wn commented 3 months ago

Similar issue. Some attributes works, but not the ones that matter.

IMG_0290

snug-inglenook commented 3 months ago

https://github.com/bodyscape/cielo_home/issues/56

bodyscape commented 3 months ago

I'll check the problem this week.

robajr commented 3 months ago

Seems to be tied to the APIdevice identification File "/config/custom_components/cielo_home/cielohomedevice.py", line 385, in get_available_modes return self._device["appliance"]["mode"]


KeyError: 'appliance'
robajr commented 3 months ago

File "/config/custom_components/cielo_home/cielohomedevice.py", line 580, in _get_action if self._device["latestAction"]["light"] == "on/off"


KeyError: 'light'
robajr commented 3 months ago

Here's a full traceback:

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 239, in handle_call_service response = await hass.services.async_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2319, in async_call response_data = await coro ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/core.py", line 2356, in _execute_service return await target(service_call) ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 905, in entity_service_call single_response = await _handle_entity_call( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 975, in _handle_entity_call result = await task ^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1645, in async_turn_on await self.hass.async_add_executor_job(ft.partial(self.turn_on, *kwargs)) File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run result = self.fn(self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/cielo_home/switch.py", line 91, in turn_on self._device.send_power_on() File "/config/custom_components/cielo_home/cielohomedevice.py", line 85, in send_power_on self._send_power("on") File "/config/custom_components/cielo_home/cielohomedevice.py", line 96, in _send_power action = self._get_action() ^^^^^^^^^^^^^^^^^^ File "/config/custom_components/cielo_home/cielohomedevice.py", line 584, in _get_action if self.get_available_modes() != "mode": ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/cielo_home/cielohomedevice.py", line 385, in get_available_modes return self._device["appliance"]["mode"]


KeyError: 'appliance'
robajr commented 3 months ago

And a received JSON

2024-03-31 08:19:35.742 DEBUG (MainThread) [custom_components.cielo_home.cielohome] Receive Json : {"message_type": "StateUpdate", "action": {"uirules": "default:default:default", "device_status": "off", "temp": "80", "action_source": "iOS", "statustimestamp": "1710023048", "fanspeed": "auto", "turbo": "off", "end_turbo_timestamp": "1692636128", "swinginternal": " ", "mode": "heat", "swing": "pos2", "ontimestamp": "1711897771", "start_turbo_timestamp": "1692636128", "power": "off", "mode_timestamp": "1701188789", "timestamp": "1711897771", "moderules": "default:default:default"}, "mac_address": "xxxxxxx", "mid": "Device", "stateSync": "0", "exe": "0", "my_rule_configuration": {}, "lat_env_var": {"temperature": "75", "humidity": "0"}, "device_status": 1, "device_name": "Office", "fw_version": "2.6.0,2.6.0"} 2024-03-31 08:19:52.379 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [140483649093952] 'appliance'

level451 commented 3 months ago

Same

mworsnop commented 3 months ago

Cielo has fixed the problem. Mine are all working as expected.

bodyscape commented 3 months ago

Cielo has fixed the problem. Mine are all working as expected.

Yup me too is working again!!

m3rg3d0wn commented 3 months ago

Cielo has fixed the problem. Mine are all working as expected.

YES! Mine is working again as well.

gwilliams1205 commented 3 months ago

Yup.. it's back up and running!!! I did call them and opened a ticket. Looks like they figured some stuff out

bodyscape commented 3 months ago

reopen this issue if you any problem!

jrseliga commented 3 months ago

These situations are always a good reminder to look for locally controlled alternatives wherever possible. There's just too many variables when relying on companies to stay in business, hoping they continue to support / do not sunset products, having an active internet connection, or just dealing with simple bugs that may have low priority to these vendors.

Despite all the awesome work the community and people like @bodyscape do to help us get these devices into Home Assistant, these concerns become particularly important for critical systems that handle heating/cooling as often times reliability is entirely our of their hands.

With those concerns in mind this lead me to looking for other options and I came across this article. It has a pretty comprehensive guide to get local control of your heat pump / mini-split through ESPHome.

The pre-built dongle lists support for an array of devices from many vendors. I cannot speak to those known-working devices, but I can confirm it works with MRCOOL 4th Gen DIY indoor air handlers.

The process was super simple. Plug-in the dongle, setup WIFI, and the device was auto-discovered by Home Assistant's ESPHome integration.

The only challenging part, as noted in that article, was the USB port did need to be modified. I've seen at least one person suggest you can just force it to fit but I chose to remove the plastic notches with a hobby knife.

oggolc commented 3 months ago

These situations are always a good reminder to look for locally controlled alternatives wherever possible. There's just too many variables when relying on companies to stay in business, hoping they continue to support / do not sunset products, having an active internet connection, or just dealing with simple bugs that may have low priority to these vendors.

Despite all the awesome work the community and people like @bodyscape do to help us get these devices into Home Assistant, these concerns become particularly important for critical systems that handle heating/cooling as often times reliability is entirely our of their hands.

With those concerns in mind this lead me to looking for other options and I came across this article. It has a pretty comprehensive guide to get local control of your heat pump / mini-split through ESPHome.

The pre-built dongle lists support for an array of devices from many vendors. I cannot speak to those known-working devices, but I can confirm it works with MRCOOL 4th Gen DIY indoor air handlers.

The process was super simple. Plug-in the dongle, setup WIFI, and the device was auto-discovered by Home Assistant's ESPHome integration.

The only challenging part, as noted in that article, was the USB port did need to be modified. I've seen at least one person suggest you can just force it to fit but I chose to remove the plastic notches with a hobby knife.

I'm thinking can we flash the existing USB dongle instead of getting a new one so that we don't have to cut the plastic.

mworsnop commented 3 months ago

It would be cool if we could flash the Cielo devices. 😊 they told me the latest version (and most expensive, of course) The schedules and Compfy Our local and do not need Internet to work. I wonder if they would also communicate with HA locally.

or I wonder if we could make a board with a ESP 32 or 8266 and some components To do the same thing. It might be worth looking into I guess.

oggolc commented 3 months ago

It would be cool if we could flash the Cielo devices. 😊 they told me the latest version (and most expensive, of course) The schedules and Compfy Our local and do not need Internet to work. I wonder if they would also communicate with HA locally.

or I wonder if we could make a board with a ESP 32 or 8266 and some components To do the same thing. It might be worth looking into I guess.

I'm gonna pop open the existing USB dongle tonight and see if I can find the ESP32/8266 chip in it.

macjustice commented 3 months ago

Mine is still offline, did people who had the problem resolve have to re-authenticate or did it just clear up without user action?

edit: Nevermind, reloading the integration did the trick, thanks everybody!

mworsnop commented 3 months ago

Mine just worked again

mworsnop commented 3 months ago

I think my resolution might be to get a BroadLink IR transmitter and a temperature sensor. Even if the temperature sensor needed to be a completely separate unit, it would still be less than $60 for Both units and then it would be all local.

WaleedAly commented 2 months ago

@mworsnop I had removed my Cielo integration when it stopped working. After getting your comment, I reinstalled it and I confirm it works for me as well. The integration was not updated, so I'm not sure if it will continue to work or might break again.