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

"dateafter" flag should affect page download #13700

Closed
lgrn opened this issue Jul 22, 2017 · 2 comments
Closed

"dateafter" flag should affect page download #13700

lgrn opened this issue Jul 22, 2017 · 2 comments
Labels

Comments

@lgrn
Copy link

@lgrn lgrn commented Jul 22, 2017

  • I've verified and I assure that I'm running youtube-dl 2017.07.15
  • At least skimmed through README and most notably FAQ and BUGS sections
  • Searched the bugtracker for similar issues including closed ones

What is the purpose of your issue?

  • Feature request (request for a new functionality)
$ youtube-dl -v --dateafter 20170721 https://www.youtube.com/user/PewDiePie/videos         
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'-v', u'--dateafter', u'20170721', u'https://www.youtube.com/user/PewDiePie/videos']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2017.07.15
[debug] Python version 2.7.12 - Linux-4.8.0-58-generic-x86_64-with-Ubuntu-16.04-xenial
[debug] exe versions: none
[debug] Proxy map: {}
[youtube:user] PewDiePie: Downloading channel page
[youtube:playlist] UU-lHJZR3Gqxm24_Vd_AJ5Yw: Downloading webpage
[download] Downloading playlist: Uploads from PewDiePie
[youtube:playlist] UU-lHJZR3Gqxm24_Vd_AJ5Yw: Downloading page #1
[youtube:playlist] UU-lHJZR3Gqxm24_Vd_AJ5Yw: Downloading page #2
[youtube:playlist] UU-lHJZR3Gqxm24_Vd_AJ5Yw: Downloading page #3
(...)

Output note: This should match nothing. There are no new uploads after 20170721.

"dateafter" flag should affect page download

Currently when running youtube-dl with the dateafter flag, as you can see from the above output, it seems that youtube-dl completely ignores whatever you put in as the date as far as the "Downloading page" process is concerned.

Since the page is sorted chronologically, the logic should go like this:

  • Inspect dateafter flag given by user
  • Download page #1 only.
  • If dateafter does not match anything, abort.
  • Else, continue as normal.

This is not the best way to do it of course, it would be better to run the process once for every page and check when you reach a page that doesn't have 100% videos that should be downloaded (this is the last page), so that just the right amount of pages are fetched. At least with the above way, which may be easier to implement, you can avoid the currently very annoying behavior where youtube-dl fetches every page of a channel (potentially a lot) only to to conclude that zero videos matched your date filter.

This issue is similar to #1846 and #1816 but it's not identical.

@dstftw dstftw closed this Jul 22, 2017
@dstftw dstftw added the duplicate label Jul 22, 2017
@lgrn
Copy link
Author

@lgrn lgrn commented Jul 22, 2017

@dstftw duplicate of what issue?

@sicode
Copy link

@sicode sicode commented May 20, 2019

Agree, wasted Time

image

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
3 participants
You can’t perform that action at this time.