File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change 1414 " python-dateutil==2.9.0"
1515 ],
1616 "single_config_entry" : true ,
17- "version" : " 1.0.6 "
17+ "version" : " 1.0.7 "
1818 }
Original file line number Diff line number Diff line change @@ -376,6 +376,7 @@ def _handle_coordinator_update(self) -> None:
376376 order = ocado_data .get ("total" )
377377 if order is not None :
378378 result = set_total (self , order , now ) # noqa: F841
379+ _LOGGER .debug ("Set_total returned %s" , result )
379380 else :
380381 self ._attr_state = None
381382 self ._attr_icon = "mdi:help-circle"
@@ -385,10 +386,16 @@ def _handle_coordinator_update(self) -> None:
385386 }
386387 if self .entity_id is not None :
387388 current = self .hass .states .get (self .entity_id )
389+ new = self ._hass_custom_attributes
388390
389391 if current is None :
390392 self .async_write_ha_state ()
391393 return
394+
395+ old = current .attributes
396+ if detect_attr_changes (new , old ): # type: ignore
397+ _LOGGER .debug ("Updating due to new attributes" )
398+ self .async_write_ha_state ()
392399
393400
394401class OcadoUpcoming (CoordinatorEntity , SensorEntity ): # type: ignore
You can’t perform that action at this time.
0 commit comments