openzim / youtube

Create a ZIM file from a Youtube channel/username/playlist
GNU General Public License v3.0
52 stars 29 forks source link

Add feature to filter videos by date #67

Closed deborahlow97 closed 4 years ago

deborahlow97 commented 4 years ago

Fixes #31

Context

Approach

Case: video upload date isn't within range: (Date specified: 20191212)

image

kelson42 commented 4 years ago

@deborahlow97 Thank you very much for your patch. This will be reviewed around the end of the week, so please don't wonder if you see no activity in the next days on this PR. What would be really helpful, if you want to continue with Python, would be if you could have a look to bugs on Sotoki https://github.com/openzim/sotoki.

deborahlow97 commented 4 years ago

@deborahlow97 Thank you very much for your patch. This will be reviewed around the end of the week, so please don't wonder if you see no activity in the next days on this PR. What would be really helpful, if you want to continue with Python, would be if you could have a look to bugs on Sotoki https://github.com/openzim/sotoki.

Thank you for the speedy reply! Am happy to take a look at the issues at Sotoki 😀

deborahlow97 commented 4 years ago

Thanks @deborahlow97 !

Unfortunately, this can't work as-is as Youtube-dl is used for downloading videos only but not for selecting/filtering them. This is done via the Youtube API, currently only using the --type and --id info.

what you could do it keep the youtube_dl.DateRange which a good human-to-range parser and use those dates to change API calls so we'd only get filtered results. There should be no need for the daterange YoutubeDL param afterward.

Let me know if I can be of any additional help

Thanks for pointing that out! I'll fix that.