database64128 / youtube-dl-wpf

A simple GUI wrapper for youtube-dl and yt-dlp.
GNU General Public License v3.0
871 stars 68 forks source link

nsig and PhantomJS warning doesn't go away. #202

Open FrostedVolcano opened 4 months ago

FrostedVolcano commented 4 months ago

Yesterday, while I tried to download videos, the log had this warnign:

024-07-10T12:30:19.044+06:00 [I] WARNING: [youtube] Tbg2XJPNFUc: Native nsig extraction failed: Trying with PhantomJS
2024-07-10T12:30:19.045+06:00 [I]          n = 5jaiZYPkNeTMqyf2M ; player = https://www.youtube.com/s/player/b22ef6e7/player_ias.vflset/en_US/base.js
2024-07-10T12:30:19.045+06:00 [I] [youtube] Tbg2XJPNFUc: Executing signature code
2024-07-10T12:30:20.737+06:00 [I] WARNING: [youtube] Tbg2XJPNFUc: Native nsig extraction failed: Trying with PhantomJS
2024-07-10T12:30:20.737+06:00 [I]          n = SHDu-_OhFZ5BIOsKK ; player = https://www.youtube.com/s/player/b22ef6e7/player_ias.vflset/en_US/base.js

This error was also present in yt-dlp cli. So, I downloaded PhantomJS. My yt-dlp.exe and ffmpeg.exe are in the same folder and I put phantomjs.exe in that exact folder. yt-dlp stopped giving that error but the log of youtube-dl-wpf was still giving that error.

database64128 commented 4 months ago

For FFmpeg, yt-dlp inherited the --ffmpeg-location option from youtube-dl, which youtube-dl-wpf uses to set the FFmpeg location. For PhantomJS, however, yt-dlp does not have an equivalent option, and simply executes it with the binary name, which requires the binary to be in PATH or the working directory.

youtube-dl-wpf runs yt-dlp from the current working directory, which is usually the directory youtube-dl-wpf.exe resides in. You can move PhantomJS there, or add it to PATH.