Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: writing video datetime to cache #8188

Open
TheLoneWolfling opened this issue Jan 9, 2016 · 5 comments
Open

Feature request: writing video datetime to cache #8188

TheLoneWolfling opened this issue Jan 9, 2016 · 5 comments

Comments

@TheLoneWolfling
Copy link

@TheLoneWolfling TheLoneWolfling commented Jan 9, 2016

There are a couple of youtube channels that I keep up-to-date with youtube-dl. For the most part, it works.

Unfortunately, there are a couple of cases where it's (obnoxiously) slow. In particular, when I want everything of a particular series on a channel (easily accomplished with --match-title) only after the date I switched over to youtube-dl for the channel (again, easily accomplished with --date-after).

It then proceeds to download the entire history of the user (regardless of date), and download the DASH manifest of every single video matching the title before checking the date. Every time. After reading #1502, I understand that dates of user history are sometimes out of order, so the first time doing all that downloading of info files and history is kind of unvoidable.

But given that this is in a script that's run on a regular basis, and (as far as I know) the upload time of a video doesn't change, I don't suppose that you could add an option to cache it? A simple key-value (video id -> datetime) would do.

(Alternatively, a way to specify "I know these videos are in order" would do.)

I saw --cache-dir, but "At the moment, only YouTube player files (for videos with obfuscated signatures) are cached".

I also tried working around it with --write-info-json and --load-info, but could not figure out how to get youtube-dl to load said files when downloading more than a single file.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Jan 9, 2016

Why not just use --download-archive?

@TheLoneWolfling
Copy link
Author

@TheLoneWolfling TheLoneWolfling commented Jan 9, 2016

I do. But download-archive does not record files outside the date limits set.

@amollberg
Copy link

@amollberg amollberg commented May 1, 2016

I have implemented caching of extractor results for video pages on my fork here. Once it builds up a cache of the videos, on subsequent executions it blazes through the list in seconds. However, the cache file grows fairly quickly as it caches a lot more information than just video datetime.

Hopefully this is still something that can be useful regarding this issue.

@weedy
Copy link

@weedy weedy commented Nov 19, 2017

I can see this issue and #858 exists already so I'm going to post here.

Please add some ability to cache SOMETHING when youtube-dl goes through all the trouble of downloading DASH manifests. I have quite a few channels now with over 3000 videos so youtube-dl invocations are taking more then one hour to finish.

@aleksfadini
Copy link

@aleksfadini aleksfadini commented May 22, 2019

I still have this problem. Is there a fix? Maybe an alternative to --date-after ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants
You can’t perform that action at this time.