Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android TV Remote : disable the log when the device is turned off #117722

Closed
gypais opened this issue May 19, 2024 · 6 comments
Closed

Android TV Remote : disable the log when the device is turned off #117722

gypais opened this issue May 19, 2024 · 6 comments
Labels
integration: androidtv_remote needs-more-information problem in device Issue lies within the device, such firmware, software, or user customization/config

Comments

@gypais
Copy link

gypais commented May 19, 2024

The problem

I have each 75s in log :
2024-05-19 11:27:27 2024-05-19 11:27:27.355 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:29:11 2024-05-19 11:29:11.977 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:29:28 2024-05-19 11:29:28.362 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:30:16 2024-05-19 11:30:16.582 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:32:21 2024-05-19 11:32:21.617 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:34:41 2024-05-19 11:34:41.596 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-19 11:35:30 2024-05-19 11:35:30.677 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21

What version of Home Assistant Core has the issue?

2024.5.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

No response

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@home-assistant
Copy link

Hey there @tronikos, @Drafteed, mind taking a look at this issue as it has been labeled with an integration (androidtv_remote) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of androidtv_remote can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign androidtv_remote Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


androidtv_remote documentation
androidtv_remote source
(message by IssueLinks)

@tronikos
Copy link
Contributor

Can you enable debug logging? I expect to see:
Reconnected to Freebox Player POP at 192.168.1.21
preceding your:
Disconnected from Freebox Player POP at 192.168.1.21

@gypais
Copy link
Author

gypais commented May 20, 2024

2024-05-20 09:23:32 2024-05-20 09:23:32.770 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "net.oqee.launcher" } }
2024-05-20 09:23:32 2024-05-20 09:23:32.797 DEBUG (MainThread) [androidtvremote2] Received: remote_start { }
2024-05-20 09:23:42 2024-05-20 09:23:42.346 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 2 unknown2: 2 player_model: "Freebox Player POP" }
2024-05-20 09:26:57 2024-05-20 09:26:57.827 DEBUG (MainThread) [androidtvremote2] Closing idle connection
2024-05-20 09:26:57 2024-05-20 09:26:57.830 WARNING (MainThread) [homeassistant.components.androidtv_remote] Disconnected from Freebox Player POP at 192.168.1.21
2024-05-20 09:26:57 2024-05-20 09:26:57.833 DEBUG (MainThread) [androidtvremote2] Disconnected from 192.168.1.21. Error: Closed idle connection
2024-05-20 09:26:57 2024-05-20 09:26:57.833 DEBUG (MainThread) [androidtvremote2] Trying to reconnect to 192.168.1.21 in 0.1 seconds
2024-05-20 09:26:59 2024-05-20 09:26:59.264 DEBUG (MainThread) [androidtvremote2] Connection lost. Error: None
2024-05-20 09:27:17 2024-05-20 09:27:17.608 DEBUG (MainThread) [androidtvremote2] Connected to ('192.168.1.21', 6466)
2024-05-20 09:27:17 2024-05-20 09:27:17.625 DEBUG (MainThread) [androidtvremote2] Received: remote_configure { code1: 623 device_info { model: "Freebox Player POP" vendor: "Freebox" unknown1: 1 unknown2: "10" package_name: "com.google.android.tv.remote.service" app_version: "5.2.473254133" } }
2024-05-20 09:27:17 2024-05-20 09:27:17.625 DEBUG (MainThread) [androidtvremote2] Device supports: [<Feature.PING|KEY|IME|POWER|VOLUME|APP_LINK|8: 623>]
2024-05-20 09:27:17 2024-05-20 09:27:17.625 DEBUG (MainThread) [androidtvremote2] Sending: remote_configure { code1: 615 device_info { unknown1: 1 unknown2: "1" package_name: "atvremote" app_version: "1.0.0" } }
2024-05-20 09:27:17 2024-05-20 09:27:17.638 DEBUG (MainThread) [androidtvremote2] Received: remote_set_active { }
2024-05-20 09:27:17 2024-05-20 09:27:17.638 DEBUG (MainThread) [androidtvremote2] Sending: remote_set_active { active: 615 }
2024-05-20 09:27:17 2024-05-20 09:27:17.647 DEBUG (MainThread) [androidtvremote2] Received: remote_start { }
2024-05-20 09:27:17 2024-05-20 09:27:17.647 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 2 unknown2: 2 player_model: "Freebox Player POP" }
2024-05-20 09:27:17 2024-05-20 09:27:17.648 INFO (MainThread) [homeassistant.components.androidtv_remote] Reconnected to Freebox Player POP at 192.168.1.21
2024-05-20 09:27:17 2024-05-20 09:27:17.653 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "net.oqee.launcher" } }
2024-05-20 09:27:43 2024-05-20 09:27:43.690 DEBUG (MainThread) [androidtvremote2] Received: remote_start { started: true }
2024-05-20 09:27:44 2024-05-20 09:27:44.709 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 2362 unknown2: 9 player_model: "Freebox Player POP" }
2024-05-20 09:27:44 2024-05-20 09:27:44.896 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "fr.freebox.fbx8lc.fbxupdater" } }
2024-05-20 09:27:45 2024-05-20 09:27:45.659 DEBUG (MainThread) [androidtvremote2] Received: remote_ime_key_inject { app_info { app_package: "net.oqee.androidtv" } }
2024-05-20 09:27:52 2024-05-20 09:27:52.474 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 2 unknown2: 2 player_model: "Freebox Player POP" }
2024-05-20 09:27:53 2024-05-20 09:27:53.192 DEBUG (MainThread) [androidtvremote2] Received: remote_set_volume_level { unknown1: 2369 unknown2: 9 player_model: "Freebox Player POP" }

@tronikos
Copy link
Contributor

So the connection becomes idle and is closed which results to the warning log Disconnected from Freebox Player POP at 192.168.1.21. It manages to reconnect which results to the info log Reconnected to Freebox Player POP at 192.168.1.21

Both of these logs are required per the silver guideline at https://developers.home-assistant.io/docs/integration_quality_scale_index/ "Handles device/service unavailable. Log a warning once when unavailable, log once when reconnected."

#107649 and the documentation has some workarounds to prevent the Android TV from going to full sleep mode so that it keeps the connection open. If none are working you will just have to ignore these warnings logs or influence the core devs to adjust the guidelines.

@mib1185 mib1185 added problem in device Issue lies within the device, such firmware, software, or user customization/config needs-more-information labels May 20, 2024
@tronikos
Copy link
Contributor

Closing as duplicate of #107649

@tronikos
Copy link
Contributor

@home-assistant close

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration: androidtv_remote needs-more-information problem in device Issue lies within the device, such firmware, software, or user customization/config
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants