Skip to content

Commit e031264

Browse files
committed
updated youtube_download_video.sh
1 parent b70ab4b commit e031264

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

Diff for: media/youtube_download_video.sh

+15-1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,14 @@ If you run into a error determining a video format to download such as this:
3434
3535
WARNING: [youtube] RVVDi1PHgw4: nsig extraction failed: Some formats may be missing
3636
37+
If you run into this error:
38+
39+
ERROR: [youtube] ...: Sign in to confirm you’re not a bot.
40+
41+
Then you should provide a filename and then after it args to pass to yt-dlp such as
42+
43+
--cookies-from-browser chrome
44+
3745
Try to upgrade yt-dlp first as sites like YouTube update their site breaking this and requiring a yt-dlp update
3846
"
3947

@@ -113,7 +121,13 @@ else
113121
timestamp "Determining download filename"
114122
# "$format" is only needed here for it to return the right file extension
115123
# in the "$output_filename" format eg. '.mp4' instead of '.webm'
116-
filename="$(yt-dlp --get-filename --format "$format" --output "$output_filename" "$url")"
124+
filename="$(
125+
yt-dlp --get-filename \
126+
--format "$format" \
127+
--output "$output_filename" \
128+
"$@" \
129+
"$url"
130+
)"
117131
fi
118132
if ! [ -f "$filename" ]; then
119133
die "Failed to find expected output file: $filename"

0 commit comments

Comments
 (0)