Improve logging
This commit is contained in:
parent
483d377b6d
commit
3aaaad6fcf
2 changed files with 4 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
||||||
[logging]
|
[logging]
|
||||||
# level = "DEBUG"
|
level = "INFO"
|
||||||
|
|
||||||
[homeassistant]
|
[homeassistant]
|
||||||
entity = "climate.chaudiere"
|
entity = "climate.chaudiere"
|
||||||
|
|
|
@ -104,6 +104,7 @@ class HAClient:
|
||||||
logger.error("Availability message timed out")
|
logger.error("Availability message timed out")
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
|
logger.info("Connected to Home Assistant.")
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
def publish(
|
def publish(
|
||||||
|
@ -143,6 +144,8 @@ class HAClient:
|
||||||
|
|
||||||
if code != 0:
|
if code != 0:
|
||||||
logger.error("MQTT client loop failed with code <{code}>.")
|
logger.error("MQTT client loop failed with code <{code}>.")
|
||||||
|
else:
|
||||||
|
logger.info("MQTT client loop successfully exited")
|
||||||
return code
|
return code
|
||||||
|
|
||||||
def state_update(
|
def state_update(
|
||||||
|
|
Loading…
Reference in a new issue