mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
UPdate log messages
This commit is contained in:
parent
1f7e0936fa
commit
b29eff5ef1
@ -61,12 +61,10 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
|
|||||||
return False
|
return False
|
||||||
except requests.exceptions.MissingSchema:
|
except requests.exceptions.MissingSchema:
|
||||||
_LOGGER.error("Missing resource or schema in configuration. "
|
_LOGGER.error("Missing resource or schema in configuration. "
|
||||||
"Please check the details in the configuration file.")
|
"Please check the details in the configuration file")
|
||||||
return False
|
return False
|
||||||
except requests.exceptions.ConnectionError:
|
except requests.exceptions.ConnectionError:
|
||||||
_LOGGER.error("No route to resource/endpoint: '%s'. "
|
_LOGGER.error("No route to resource/endpoint: %s", url)
|
||||||
"Please check the details in the configuration file.",
|
|
||||||
url)
|
|
||||||
return False
|
return False
|
||||||
|
|
||||||
rest = GlancesData(url)
|
rest = GlancesData(url)
|
||||||
@ -167,6 +165,5 @@ class GlancesData(object):
|
|||||||
response = requests.get(self._resource, timeout=10)
|
response = requests.get(self._resource, timeout=10)
|
||||||
self.data = response.json()
|
self.data = response.json()
|
||||||
except requests.exceptions.ConnectionError:
|
except requests.exceptions.ConnectionError:
|
||||||
_LOGGER.error("No route to host/endpoint '%s'. Is device offline?",
|
_LOGGER.error("No route to host/endpoint: %s", self._resource)
|
||||||
self._resource)
|
|
||||||
self.data = None
|
self.data = None
|
||||||
|
Loading…
x
Reference in New Issue
Block a user