fau.tv changed some things

This commit is contained in:
Ludwig Lehnert 2025-02-16 09:22:53 +01:00
parent ad59ab4da4
commit e5501fb859

7
lib.py
View File

@ -153,17 +153,18 @@ def download_media(media_id: str, outfile_path: str):
cookie_args.append('--cookie') cookie_args.append('--cookie')
cookie_args.append(f'{key}={value}') cookie_args.append(f'{key}={value}')
status = subprocess.call(['curl', '-o', outfile_path, url] + cookie_args) status = subprocess.call(
['curl', '-f', '-o', outfile_path, url] + cookie_args)
return status == 0 return status == 0
def download_playlist(playlist_url: str, outfile_path: str): def download_playlist(playlist_url: str, outfile_path: str):
subprocess.run([ subprocess.call([
'ffmpeg', 'ffmpeg',
'-i', playlist_url, '-i', playlist_url,
'-c', 'copy', '-c', 'copy',
outfile_path, outfile_path,
], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT) ])
def download_clip(clip_id: str, outfile_path: str): def download_clip(clip_id: str, outfile_path: str):