-
-
Notifications
You must be signed in to change notification settings - Fork 30.4k
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
Twitch integration uses excessive API requests #128866
Comments
I'm wrong about I took a crack at this, but async Python breaks my brain and I gave up. Taking |
I mean I am happy to help you out where needed. I use Twitch not that often so it's not that high on my priority list (which is long), so if I can help you out with that, that would be awesome |
I can open a half-baked PR this evening. It won't be right, but it'll be
close. It should reduce API calls by about 50% the way I did it.
…On Mon, Oct 21, 2024, 2:43 PM home-assistant[bot] ***@***.***> wrote:
twitch documentation <https://www.home-assistant.io/integrations/twitch>
twitch source
<https://github.com/home-assistant/core/tree/dev/homeassistant/components/twitch>
—
Reply to this email directly, view it on GitHub
<#128866 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAFUDNOZTYSDZCJKF7FJVDDZ4VDNNAVCNFSM6AAAAABQJACQG2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMRXGQ2TSMRQHE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Also be aware, something got merged that centralizes the api calls, so there already is a difference between 2024.10 and |
The problem
Many of the Helix API requests (e.g.
get-streams
,get-channel-followers
, andget-followed-channels
) offer pagination. I follow about 120 channels, which ends up being somewhere in the area of 500 API requests and takes about 3 minutes to update every channel.For me, the number of API requests could be reduced by 75% by adding pagination. Further, if usage of
check-user-subscription
(no pagination available) became a config option, the number of API requests would be reduced to only about 10.What version of Home Assistant Core has the issue?
core-2024.10.3
What type of installation are you running?
Home Assistant OS
Integration causing the issue
twitch
The text was updated successfully, but these errors were encountered: