Skip to content

Commit bf23a63

Browse files
Added clause for refused connection on reconnetion
1 parent af8560c commit bf23a63

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

custom_components/jablotron80/jablotron.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -888,6 +888,8 @@ def connect(self) -> None:
888888
except serial.SerialException as ex:
889889
if "timed out" in f'{ex}':
890890
LOGGER.info('Timeout, retrying')
891+
elif "Connection refused" in f'{ex}':
892+
LOGGER.info('Connection refused by remote host, retrying')
891893
else:
892894
raise
893895

0 commit comments

Comments
 (0)