Add PelixPlay HD 16-thread downloader and auto-metadata
Browse files375 unmodified lines376377378379380381382383384385386387388389390391392393394395396397398399400401375 unmodified linesif not all_embeds and data.get("embeds"):all_embeds = {"latino": data["embeds"]}# Priorizar español latino -> castellano -> cualquier otrolang_order = ["latino", "castellano", "es", "subtitulado", "sub"] + list(all_embeds.keys())chosen_embeds = {}for l in lang_order:if l in all_embeds and all_embeds[l]:chosen_embeds = all_embeds[l]breakif not chosen_embeds:raise RuntimeError("No se encontraron servidores de video activos en PelixPlay para este título.")# Recolectar URLs de StreamWish (dohaxe), Morencius y FileLions primeroembed_candidates = []for prov_key in ["streamwish", "morencius", "filelions", "vidhide"] + list(chosen_embeds.keys()):urls = chosen_embeds.get(prov_key) or []if isinstance(urls, str):urls = [urls]for u in urls:if u and u not in embed_candidates:embed_candidates.append(u)# 1. Intentar desempaquetar directamente desde nuestra IP (HLS4 / HLS3 / HLS2) y verificar segmento 0for emb_url in embed_candidates:375 unmodified lines376377378379380381382383384385386387388389390391392393394395396397398399400375 unmodified linesif not all_embeds and data.get("embeds"):all_embeds = {"latino": data["embeds"]}# Priorizar español latino -> castellano -> cualquier otro, recorriendo todos los servidores (StreamWish, Morencius, FileLions)lang_order = []for l in ["latino", "castellano", "es", "subtitulado", "sub"] + list(all_embeds.keys()):if l not in lang_order and l in all_embeds and all_embeds[l]:lang_order.append(l)embed_candidates = []for l in lang_order:lang_embeds = all_embeds.get(l) or {}for prov_key in ["streamwish", "morencius", "filelions", "vidhide"] + list(lang_embeds.keys()):urls = lang_embeds.get(prov_key) or []if isinstance(urls, str):urls = [urls]for u in urls:if u and u not in embed_candidates:embed_candidates.append(u)if not embed_candidates:raise RuntimeError("No se encontraron servidores de video activos en PelixPlay para este título.")# 1. Intentar desempaquetar directamente desde nuestra IP (HLS4 / HLS3 / HLS2) y verificar segmento 0for emb_url in embed_candidates:
_panel_app.py+17-18