-
Notifications
You must be signed in to change notification settings - Fork 32
Description
Dear developer,
due to YouTube limiting or blocking, i encountered to following errors now when trying to use ytdlp-nodejs with yt-dlp:
Error code: Error: Command failed: /[...]/yt-dlp https://www.youtube.com/watch?v=dQw4w9WgXcQ --dump-json
ERROR: [youtube] dQw4w9WgXcQ: Sign in to confirm you’re not a bot. Use --cookies-from-browser or --cookies for the authentication. See https://github.com/yt-dlp/yt-dlp/wiki/FAQ#how-do-i-pass-cookies-to-yt-dlp for how to manually pass cookies. Also see https://github.com/yt-dlp/yt-dlp/wiki/Extractors#exporting-youtube-cookies for tips on effectively exporting YouTube cookies
This can be fixed by adding the possibility inside ytdlp-nodejs to add a configurable parameter "--cookies ./cookies.txt" to all functions like e.g ytdlp.stream / ytDlp.getInfoAsync so it sends a command to yt-dlp like this:
/[...]/yt-dlp https://www.youtube.com/watch?v=dQw4w9WgXcQ --cookies ./cookies.txt --dump-json
Thanks in advance and kind regards,
nerzlakai96