jonathanagustin
commited on
Commit
•
661e280
1
Parent(s):
aedbafa
Update app.py
Browse files
app.py
CHANGED
@@ -105,14 +105,12 @@ class SearchService:
|
|
105 |
'no_warnings': True,
|
106 |
'force_generic_extractor': False,
|
107 |
'skip_download': True,
|
108 |
-
# Include the cookies file
|
109 |
'cookiefile': 'cookies.txt',
|
110 |
}
|
111 |
try:
|
112 |
with yt_dlp.YoutubeDL(ydl_opts) as ydl:
|
113 |
info_dict = ydl.extract_info(youtube_url, download=False)
|
114 |
if info_dict.get('is_live'):
|
115 |
-
# Get the live stream URL
|
116 |
live_url = info_dict.get('url')
|
117 |
if live_url:
|
118 |
logging.debug(f"Found livestream URL: {live_url}")
|
|
|
105 |
'no_warnings': True,
|
106 |
'force_generic_extractor': False,
|
107 |
'skip_download': True,
|
|
|
108 |
'cookiefile': 'cookies.txt',
|
109 |
}
|
110 |
try:
|
111 |
with yt_dlp.YoutubeDL(ydl_opts) as ydl:
|
112 |
info_dict = ydl.extract_info(youtube_url, download=False)
|
113 |
if info_dict.get('is_live'):
|
|
|
114 |
live_url = info_dict.get('url')
|
115 |
if live_url:
|
116 |
logging.debug(f"Found livestream URL: {live_url}")
|