Skip to content

Commit

Permalink
Print entity type in "too slow" warnings (#10641)
Browse files Browse the repository at this point in the history
* Update entity.py

* Update entity.py
  • Loading branch information
andrey-git authored and balloob committed Nov 18, 2017
1 parent e449cee commit b86110a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions homeassistant/helpers/entity.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,10 @@ def async_update_ha_state(self, force_refresh=False):

if not self._slow_reported and end - start > 0.4:
self._slow_reported = True
_LOGGER.warning("Updating state for %s took %.3f seconds. "
_LOGGER.warning("Updating state for %s (%s) took %.3f seconds. "
"Please report platform to the developers at "
"https://goo.gl/Nvioub", self.entity_id,
end - start)
type(self), end - start)

# Overwrite properties that have been set in the config file.
if DATA_CUSTOMIZE in self.hass.data:
Expand Down

0 comments on commit b86110a

Please sign in to comment.