def async_handle_reload_config(call): """Service handler for reloading core config.""" try: conf = yield from conf_util.async_hass_config_yaml(hass) except HomeAssistantError as err: _LOGGER.error(err) return yield from conf_util.async_process_ha_core_config( hass, conf.get(ha.DOMAIN) or {})
def async_prepare_reload(self): """Prepare reloading this entity component. This method must be run in the event loop. """ try: conf = yield from \ conf_util.async_hass_config_yaml(self.hass) except HomeAssistantError as err: self.logger.error(err) return None conf = conf_util.async_process_component_config( self.hass, conf, self.domain) if conf is None: return None yield from self.async_reset() return conf
def async_prepare_reload(self): """Prepare reloading this entity component. This method must be run in the event loop. """ try: conf = yield from \ conf_util.async_hass_config_yaml(self.hass) except HomeAssistantError as err: self.logger.error(err) return None conf = yield from async_prepare_setup_component( self.hass, conf, self.domain) if conf is None: return None yield from self.async_reset() return conf