VideoHelp Forum





Try StreamFab Downloader and download streaming video from Netflix, Amazon!



+ Reply to Thread
Results 1 to 1 of 1
  1. I made a script to download a playlist from a YouTube channel as a single JSON file, then automatically edit it as a plain text list. It's based on yt-dlp and sfk which I mentioned there. Attached are the script itself in its current state, and an example of a plain text list generated with it.

    1) Would it be possible to also get the upload date just as quickly and conveniently?
    I made quite extensive tests months ago, and found out that:
    – using “--flat-playlist --write-pages --dump-single-json” allows to quickly create a JSON file containing, for all videos available on a channel (even those with restricted access), their link, their title, their duration, the number of views, but not the upload date (also for “shorts” there is no duration, only the number of views, which seems less precise than for “regular” videos);
    – using something like:
    Code:
    yt-dlp %link% --skip-download --print %%(id)s --print %%(upload_date)s --print %%(duration_string)s --print %%(title)s >>"%channel_id%.txt"
    allows to get the upload date, and many other available fields with the --print option, but it's much slower (~5s of processing for each video so it can take hours for a large channel), videos in restricted access are skipped (unless using --cookies to get videos with an age limit), and it can cause a temporary ban (less likely to happen when using --cookies but it's probably bound to happen as well when processing hundreds of videos in a row).

    2) I added replacement formulas for characters encoded as “\u####”, those found in a few lists, plus a few more that could be expected (in French language in particular). Considering that the “####” code corresponds to the character's ASCII code (for instance [hex] 00E9 => [dec] 233, ALT+0233 => é), would there be a way to systematically convert those “\u####” codes to the corresponding character?

    3) Could it be improved in any other way? (I only made a few tests, perhaps it won't work well with other channels.)
    Or are there existing scripts / tools doing the same thing more efficiently and/or more reliably?
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!