This commit is contained in:
doms9 2025-09-11 14:55:53 -04:00
parent 8796e2dfc6
commit 00000d9ef1
7 changed files with 318 additions and 44 deletions

View file

@ -3,8 +3,8 @@ import asyncio
from pathlib import Path
import httpx
from scrapers import livetvsx, ppv, streambtw, tvpass
from scrapers.utils import get_logger
from scrapers import livetvsx, ppv, streambtw, streameast, tvpass
from scrapers.utils import UA, get_logger
log = get_logger(__name__)
@ -15,9 +15,7 @@ M3U8_FILE = Path(__file__).parent / "TV.m3u8"
CLIENT = httpx.AsyncClient(
timeout=5,
follow_redirects=True,
headers={
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36 Edg/134.0.0.0"
},
headers={"User-Agent": UA},
)
@ -41,6 +39,7 @@ async def main() -> None:
asyncio.create_task(livetvsx.main(CLIENT)),
asyncio.create_task(ppv.main(CLIENT)),
asyncio.create_task(streambtw.main(CLIENT)),
asyncio.create_task(streameast.main(CLIENT)),
asyncio.create_task(tvpass.main(CLIENT)),
vanilla_fetch(),
]
@ -49,7 +48,9 @@ async def main() -> None:
base_m3u8, tvg_chno = results[-1]
additions = livetvsx.urls | ppv.urls | streambtw.urls | tvpass.urls
additions = (
livetvsx.urls | ppv.urls | streambtw.urls | streameast.urls | tvpass.urls
)
lines = [
f'#EXTINF:-1 tvg-chno="{chnl_num}" tvg-id="(N/A)" tvg-name="{event}" tvg-logo="{info["logo"]}" group-title="Live Events",{event}\n{info["url"]}'