For those of you who have used youtube -dl in python I am sure you seen
[youtube:search_url] playlist a: Downloading 20 videos
Is there anyway I can change the setting to download more than 20 videos, let say 100?
Here is my sample code
user_input_terms =["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
for x in range(0, len(user_input_terms)):
logger.msg(user_input_terms)
ydl_opts = {
'outtmpl': '{}.%(ext)s'.format(user_input_terms[x]),
'format': 'bestaudio/best',
'postprocessors': [{
'key': 'FFmpegExtractAudio',
'preferredcodec': 'mp3',
'preferredquality': '192',
}],
}
try:
with youtube_dl.YoutubeDL(ydl_opts,({'format':'137'})) as ydl:
term = user_input_terms
ydl.download([f"https://www.youtube.com/results?sp=EgQIBCgB&q={term}"])
except download_error:
logger.msg("Youtube outputs a mp4 error.")