diff --git a/ytnotifier.py b/ytnotifier.py index f3c6754..979f59e 100644 --- a/ytnotifier.py +++ b/ytnotifier.py @@ -125,7 +125,9 @@ async def handle_video(video_id, video_title): tmp_handled_videos.discard(video_id) async def get_video_list(session, channel_id): - for i in invidious_instances: + shuffled_instances = invidious_instances.copy() + random.shuffle(shuffled_instances) + for i in shuffled_instances: try: async with session.get(f'{i}/api/v1/channels/{channel_id}/latest?fields=title,videoId&a={time.time()}', headers={'Cache-Control': 'no-store, max-age=0'}) as resp: if resp.status != 200: