diff --git a/homeassistant/components/sensor/yweather.py b/homeassistant/components/sensor/yweather.py index c308d36f50b..b0156497177 100644 --- a/homeassistant/components/sensor/yweather.py +++ b/homeassistant/components/sensor/yweather.py @@ -13,7 +13,7 @@ from homeassistant.const import (CONF_PLATFORM, TEMP_CELSIUS, from homeassistant.helpers.entity import Entity from homeassistant.util import Throttle -REQUIREMENTS = ["yahooweather==0.6"] +REQUIREMENTS = ["yahooweather==0.7"] SENSOR_TYPES = { 'weather_current': ['Current', None], @@ -139,6 +139,9 @@ class YahooWeatherSensor(Entity): def update(self): """Get the latest data from Yahoo! and updates the states.""" self._data.update() + if not self._data.yahoo.RawData: + _LOGGER.info("Don't receive weather data from yahoo!") + return # default code for weather image self._code = self._data.yahoo.Now["code"] diff --git a/requirements_all.txt b/requirements_all.txt index 26a4afdeb63..4f0a4aa12e6 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -473,7 +473,7 @@ xbee-helper==0.0.7 xmltodict==0.10.2 # homeassistant.components.sensor.yweather -yahooweather==0.6 +yahooweather==0.7 # homeassistant.components.zeroconf zeroconf==0.17.6