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

Slow time for source_list attribute update #4

Open
lgnap opened this issue Sep 3, 2024 · 1 comment
Open

Slow time for source_list attribute update #4

lgnap opened this issue Sep 3, 2024 · 1 comment

Comments

@lgnap
Copy link

lgnap commented Sep 3, 2024

Is your feature request related to a problem? Please describe.
Despite to a quick refresh time for playing meta data, the source list is not update too many.
I use the list to know if I can bascule music on this player (I can't update source if the value is not yet into source list)
On the official player, after 5-10 seconds I can see my music player freshly started (and the spotify api provide the data also),
on HA is not there :'(

Describe the solution you'd like
A source_list updated frequently

Describe alternatives you've considered
Is it possible to detect the consumption of the player to know if it's up or not, but can't have the source (must be into "network player" mode to receive spotify)

Additional context
/

I can help to develop it (I'm developer) , but I don't see how/where to start.

Thanks ;-)

@lgnap
Copy link
Author

lgnap commented Sep 4, 2024

Reading the dev documentation I checked a bit the concern and found that the line 89 of init.py file could be modified like that:

        update_interval=timedelta(seconds=5), # default 150 seconds

And I have the expected behaviour => very fast responsiveness to spotify source_list change.
However it will be better if written as a config option instead of hardcode it (thank to custom_components folder :-D )
Could you help on that ?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant