mirror of
https://github.com/doms9/iptv.git
synced 2026-03-10 11:47:34 +01:00
e
- edit watchfooty.py scraping
This commit is contained in:
parent
75f1d95b12
commit
00000d9c59
5 changed files with 51 additions and 47 deletions
|
|
@ -68,8 +68,10 @@ async def process_event(
|
|||
timeout=10_000,
|
||||
)
|
||||
|
||||
if resp.status != 200:
|
||||
log.warning(f"URL {url_num}) Status Code: {resp.status}")
|
||||
if not resp or resp.status != 200:
|
||||
log.warning(
|
||||
f"URL {url_num}) Status Code: {resp.status if resp else 'None'}"
|
||||
)
|
||||
return
|
||||
|
||||
try:
|
||||
|
|
@ -83,7 +85,9 @@ async def process_event(
|
|||
if (match := event_id_pattern.search(href)) and (
|
||||
event_id := match[1]
|
||||
).isalnum():
|
||||
|
||||
event_url = f"https://aliez.tv/player/live.php?id={event_id}"
|
||||
|
||||
else:
|
||||
event_url = href if href.startswith("http") else f"https:{href}"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue