Add Youtube subscription feed download #385

Closed
opened 2026-02-20 21:11:21 -05:00 by deekerman · 11 comments
Owner

Originally created by @HaydenRU on GitHub (Oct 26, 2012).

https://github.com/HaydenRU/Random-Python-Scripts/blob/master/ytsubdl.py
I'm sorry that i can't commit properly, your code is way too advanced to understand for me.

I wrote this little script to download last 20 videos from one's Youtube subscription feed.
It parses RSS to grab video links and then downloads them one by one (should have probably used youtube-dl -a, but oh well).

It is very handy to run this as cron job and download last videos on schedule.

I very much admire your work, thanks for a great tool!

Originally created by @HaydenRU on GitHub (Oct 26, 2012). https://github.com/HaydenRU/Random-Python-Scripts/blob/master/ytsubdl.py I'm sorry that i can't commit properly, your code is way too advanced to understand for me. I wrote this little script to download last 20 videos from one's Youtube subscription feed. It parses RSS to grab video links and then downloads them one by one (should have probably used youtube-dl -a, but oh well). It is very handy to run this as cron job and download last videos on schedule. I very much admire your work, thanks for a great tool!
deekerman 2026-02-20 21:11:21 -05:00
  • closed this issue
  • added the
    request
    label
Author
Owner

@jaimeMF commented on GitHub (Jul 7, 2013):

I've added it, but it will need to know your login info (the --netrc option).
For downloading the last 20 videos you can run:

youtube-dl :ytsubscriptions --netrc --playlist-end 20
@jaimeMF commented on GitHub (Jul 7, 2013): I've added it, but it will need to know your login info (the `--netrc` option). For downloading the last 20 videos you can run: ``` youtube-dl :ytsubscriptions --netrc --playlist-end 20 ```
Author
Owner

@HaydenRU commented on GitHub (Jul 7, 2013):

Good stuff!

@HaydenRU commented on GitHub (Jul 7, 2013): Good stuff!
Author
Owner

@jaimeMF commented on GitHub (Jul 7, 2013):

The ytsubscriptions keyword has been changed to :ytsubscriptions or :ytsubs

@jaimeMF commented on GitHub (Jul 7, 2013): The `ytsubscriptions` keyword has been changed to `:ytsubscriptions` or `:ytsubs`
Author
Owner

@Yamakaky commented on GitHub (Aug 24, 2013):

Hi.

I tried using your feature, but it seems I do something wrong. I'm using this command line [#]_ to download the videos posted today on the channels I follow (with -s to test, and login name and password replaced). The problem is that it seems to want to download all the videos on my subscription feed, and not only the ones I selected. Joined the log_ of the session. youtube-dl version : 2013.08.23.

Thanks for your attention.

PS : this feature is not really documented in the man page and README.

.. [#] youtube-dl -s -u <username> -p <password> :ytsubs --dateafter now-1day
.. _log: http://pastebin.com/ZtxKKT09

@Yamakaky commented on GitHub (Aug 24, 2013): Hi. I tried using your feature, but it seems I do something wrong. I'm using this command line [#]_ to download the videos posted today on the channels I follow (with -s to test, and login name and password replaced). The problem is that it seems to want to download all the videos on my subscription feed, and not only the ones I selected. Joined the log_ of the session. youtube-dl version : 2013.08.23. Thanks for your attention. PS : this feature is not really documented in the man page and README. .. [#] `youtube-dl -s -u <username> -p <password> :ytsubs --dateafter now-1day` .. _log: http://pastebin.com/ZtxKKT09
Author
Owner

@jaimeMF commented on GitHub (Aug 24, 2013):

@Yamakaky please open a new issue for improving the documentation (contributions welcomed).
For the other thing (other time don't be afraid of opening a new issue), it's downloading the video webpage because the date is not known in advance, but the videos that doesn't match the date shouldn't be downloaded, if they are downloaded open a new issue and we'll try to fix it.

@jaimeMF commented on GitHub (Aug 24, 2013): @Yamakaky please open a new issue for improving the documentation (contributions welcomed). For the other thing (other time don't be afraid of opening a new issue), it's downloading the video webpage because the date is not known in advance, but the videos that doesn't match the date shouldn't be downloaded, if they are downloaded open a new issue and we'll try to fix it.
Author
Owner

@Yamakaky commented on GitHub (Aug 24, 2013):

It's written 'Downloading video #1 to 381' so it seems not to work ^^

@Yamakaky commented on GitHub (Aug 24, 2013): It's written 'Downloading video #1 to 381' so it seems not to work ^^
Author
Owner

@jaimeMF commented on GitHub (Aug 24, 2013):

It seems to work fine:

$ y-dl http://www.youtube.com/user/TommyEdisonXP --dateafter now-1month --test
[debug] System config: []
[debug] User config: ['--keep-video', '--verbose', '--write-info-json', '--write-thumbnail']
[debug] Command-line args: ['http://www.youtube.com/user/TommyEdisonXP', '--dateafter', 'now-1month', '--test']
[debug] youtube-dl version 2013.08.23
[debug] Git HEAD: f2aeefe
[debug] Python version 2.7.5 - Darwin-11.4.2-x86_64-i386-64bit
[debug] Proxy map: {}
[youtube:user] TommyEdisonXP: Downloading video ids from 1 to 51
[youtube:user] TommyEdisonXP: Downloading video ids from 51 to 101
[download] Downloading playlist: TommyEdisonXP
[youtube:user] playlist 'TommyEdisonXP': Collected 86 video ids (downloading 86 of them)
[download] Downloading video #1 of 86
[youtube] Setting language
[youtube] xWenoaoYJ6w: Downloading video webpage
[youtube] xWenoaoYJ6w: Downloading video info webpage
[youtube] xWenoaoYJ6w: Extracting video information
[info] Video description metadata as JSON to: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.mp4.info.json
[youtube] xWenoaoYJ6w: Downloading thumbnail ...
[youtube] xWenoaoYJ6w: Writing thumbnail to: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.jpg
[download] Destination: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.mp4
[download] 100.0% of 10.00KiB at  7.39MiB/s ETA 00:00
[download] Downloading video #2 of 86
[youtube] Setting language
[youtube] NeB0BH8rAc8: Downloading video webpage
[youtube] NeB0BH8rAc8: Downloading video info webpage
[youtube] NeB0BH8rAc8: Extracting video information
[info] Video description metadata as JSON to: App That Identifies Objects For Blind People-NeB0BH8rAc8.mp4.info.json
[youtube] NeB0BH8rAc8: Downloading thumbnail ...
[youtube] NeB0BH8rAc8: Writing thumbnail to: App That Identifies Objects For Blind People-NeB0BH8rAc8.jpg
[download] Destination: App That Identifies Objects For Blind People-NeB0BH8rAc8.mp4
[download] 100.0% of 10.00KiB at 928.42KiB/s ETA 00:00
[download] Downloading video #3 of 86
[youtube] Setting language
[youtube] UzffnbBex6c: Downloading video webpage
[youtube] UzffnbBex6c: Downloading video info webpage
[youtube] UzffnbBex6c: Extracting video information
[download] [download] 2013-07-16 upload date is not in range 2013-07-25 - 9999-12-31
...

The message Downloading video #3 of 86 could probably be improved, open an issue with the request and (if possible) some sugesttion.

@jaimeMF commented on GitHub (Aug 24, 2013): It seems to work fine: ``` $ y-dl http://www.youtube.com/user/TommyEdisonXP --dateafter now-1month --test [debug] System config: [] [debug] User config: ['--keep-video', '--verbose', '--write-info-json', '--write-thumbnail'] [debug] Command-line args: ['http://www.youtube.com/user/TommyEdisonXP', '--dateafter', 'now-1month', '--test'] [debug] youtube-dl version 2013.08.23 [debug] Git HEAD: f2aeefe [debug] Python version 2.7.5 - Darwin-11.4.2-x86_64-i386-64bit [debug] Proxy map: {} [youtube:user] TommyEdisonXP: Downloading video ids from 1 to 51 [youtube:user] TommyEdisonXP: Downloading video ids from 51 to 101 [download] Downloading playlist: TommyEdisonXP [youtube:user] playlist 'TommyEdisonXP': Collected 86 video ids (downloading 86 of them) [download] Downloading video #1 of 86 [youtube] Setting language [youtube] xWenoaoYJ6w: Downloading video webpage [youtube] xWenoaoYJ6w: Downloading video info webpage [youtube] xWenoaoYJ6w: Extracting video information [info] Video description metadata as JSON to: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.mp4.info.json [youtube] xWenoaoYJ6w: Downloading thumbnail ... [youtube] xWenoaoYJ6w: Writing thumbnail to: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.jpg [download] Destination: How A Blind Person Experiences VidCon 2013-xWenoaoYJ6w.mp4 [download] 100.0% of 10.00KiB at 7.39MiB/s ETA 00:00 [download] Downloading video #2 of 86 [youtube] Setting language [youtube] NeB0BH8rAc8: Downloading video webpage [youtube] NeB0BH8rAc8: Downloading video info webpage [youtube] NeB0BH8rAc8: Extracting video information [info] Video description metadata as JSON to: App That Identifies Objects For Blind People-NeB0BH8rAc8.mp4.info.json [youtube] NeB0BH8rAc8: Downloading thumbnail ... [youtube] NeB0BH8rAc8: Writing thumbnail to: App That Identifies Objects For Blind People-NeB0BH8rAc8.jpg [download] Destination: App That Identifies Objects For Blind People-NeB0BH8rAc8.mp4 [download] 100.0% of 10.00KiB at 928.42KiB/s ETA 00:00 [download] Downloading video #3 of 86 [youtube] Setting language [youtube] UzffnbBex6c: Downloading video webpage [youtube] UzffnbBex6c: Downloading video info webpage [youtube] UzffnbBex6c: Extracting video information [download] [download] 2013-07-16 upload date is not in range 2013-07-25 - 9999-12-31 ... ``` The message `Downloading video #3 of 86` could probably be improved, open an issue with the request and (if possible) some sugesttion.
Author
Owner

@Yamakaky commented on GitHub (Aug 24, 2013):

I understand what it is doing. It check if the video needs to be downloaded before each download, not all at the beginning. It's not very efficient, especially to get a few in a lot, or to continue stopped download of a long playlist. I gonna open an issue for that.

Thanks for your answer.

@Yamakaky commented on GitHub (Aug 24, 2013): I understand what it is doing. It check if the video needs to be downloaded before each download, not all at the beginning. It's not very efficient, especially to get a few in a lot, or to continue stopped download of a long playlist. I gonna open an issue for that. Thanks for your answer.
Author
Owner

@FernandoMiguel commented on GitHub (Mar 10, 2014):

sorry for picking up this ticket, but it was what google provided me with.

$ youtube-dl --version
2014.03.10

youtube-dl --verbose -i -u email@domain.tld :ytsubs
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['--verbose', '-i', '-u', '', ':ytsubs']
[debug] Encodings: locale 'UTF-8', fs 'UTF-8', out 'UTF-8', pref: 'UTF-8'
Type account password and press return:
[debug] youtube-dl version 2014.03.10
[debug] Python version 2.7.6 - Linux-3.13.0-16-generic-x86_64-with-Ubuntu-14.04-trusty
[debug] Proxy map: {}
[youtube:subscriptions] Downloading login page
[youtube:subscriptions] Logging in
[youtube:subscriptions] subscriptions feed: Downloading page 1
[download] Downloading playlist: Youtube Subscriptions
[youtube:subscriptions] playlist Youtube Subscriptions: Collected 0 video ids (downloading 0 of them)

any help would be appreciated :(

@FernandoMiguel commented on GitHub (Mar 10, 2014): sorry for picking up this ticket, but it was what google provided me with. $ youtube-dl --version 2014.03.10 youtube-dl --verbose -i -u email@domain.tld :ytsubs [debug] System config: [] [debug] User config: [] [debug] Command-line args: ['--verbose', '-i', '-u', '<PRIVATE>', ':ytsubs'] [debug] Encodings: locale 'UTF-8', fs 'UTF-8', out 'UTF-8', pref: 'UTF-8' Type account password and press return: [debug] youtube-dl version 2014.03.10 [debug] Python version 2.7.6 - Linux-3.13.0-16-generic-x86_64-with-Ubuntu-14.04-trusty [debug] Proxy map: {} [youtube:subscriptions] Downloading login page [youtube:subscriptions] Logging in [youtube:subscriptions] subscriptions feed: Downloading page 1 [download] Downloading playlist: Youtube Subscriptions [youtube:subscriptions] playlist Youtube Subscriptions: Collected 0 video ids (downloading 0 of them) any help would be appreciated :(
Author
Owner

@phihag commented on GitHub (Mar 10, 2014):

@FernandoMiguel Please open a new issue for new problems. That simplifies tracking them, and means that we can close the issue once your problem has been solved. :ytsubs works fine for me though, are you sure that you do have any subscriptions?

@phihag commented on GitHub (Mar 10, 2014): @FernandoMiguel Please [open a new issue](https://github.com/rg3/youtube-dl/issues/new) for new problems. That simplifies tracking them, and means that we can close the issue once your problem has been solved. `:ytsubs` works fine for me though, are you sure that you do have any subscriptions?
Author
Owner

@FernandoMiguel commented on GitHub (Mar 10, 2014):

@phihag sorry about the extra noise.
new ticket at https://github.com/rg3/youtube-dl/issues/2542

@FernandoMiguel commented on GitHub (Mar 10, 2014): @phihag sorry about the extra noise. new ticket at https://github.com/rg3/youtube-dl/issues/2542
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/youtube-dl#385
No description provided.