mirror of
https://github.com/home-assistant/core.git
synced 2025-08-05 05:35:11 +02:00
Merge pull request #669 from pavoni/handle-efergy_value_error
Trap and trace error rather than throwing exception when efergy server
This commit is contained in:
@@ -97,5 +97,5 @@ class EfergySensor(Entity):
|
|||||||
self._state = response.json()['sum']
|
self._state = response.json()['sum']
|
||||||
else:
|
else:
|
||||||
self._state = 'Unknown'
|
self._state = 'Unknown'
|
||||||
except RequestException:
|
except (RequestException, ValueError):
|
||||||
_LOGGER.warning('Could not update status for %s', self.name)
|
_LOGGER.warning('Could not update status for %s', self.name)
|
||||||
|
Reference in New Issue
Block a user