Skip to content

Missing connection state awareness results in endless connection attempt loops (Android TV powered off) and log flooding #320

Description

@bcutter

I discovered the same as this user here, unfortunately it seems he didn't raise an issue in this repo as recommended at the end of the issue:

Android TV integration very chatty in log when configured Android TV device is not available (turned off)
home-assistant/core#69672
(here the problem is already described)

Problem: python-androidtv constantly (every 80 seconds) trys to connect to the tv. If it is powered off, it will go on like forever. On every failed connect attempt an error is written to the log. This floods logs pretty fast pretty heavily.

This is what Home Assistant log contains for ONE single failed connection attempt:

Logger: androidtv.adb_manager.adb_manager_async
Source: /usr/local/lib/python3.9/site-packages/androidtv/adb_manager/adb_manager_async.py:298
First occurred: 30. Mai 2022, 16:21:17 (1445 occurrences)
Last logged: 00:50:11

Couldn't connect to xxx.xxx.xxx.xxx:5555. TcpTimeoutException: Connecting to xxx.xxx.xxx.xxx:5555 timed out (1.0 seconds)

This is what HA's GUI presents:
grafik

The experts from HA (see referenced issue) told this is nothing HA can fix but this only can to be done in this library repo.

By the way: Not related to #15

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions