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

YouTube - Treat YouTube URLs of the format `/[user/]<username>/live` as live videos and not playlists if the channel is live #8959

Closed
scottywz opened this issue Mar 24, 2016 · 1 comment
Labels

Comments

@scottywz
Copy link

@scottywz scottywz commented Mar 24, 2016

YouTube URLs of the format https://www.youtube.com/user/<username>/live or https://www.youtube.com/<username>/live should be treated as live videos instead of playlists if the channel is streaming live. Currently, these URLs are being treated as playlists regardless of whether the channel is streaming live. These URLs are useful for referencing the channel's current live stream without having to manually find the video ID for the live stream, which changes each time the channel starts a new live stream.

The page returned by YouTube when the channel is live appears to be identical to the page returned with the watch?v=... URL for the same live content; in fact, the latter URL is the value of the page's canonical meta tag. When the channel is not live, I've seen the page returned be either the channel's home page or a video page saying that the stream is offline. In all cases, there is no redirect except for minor fixups like adding user/ if it's missing.

Example URLs:

$ ./youtube-dl -v -F 'https://www.youtube.com/user/TheYoungTurks/live'
[debug] System config: [u'--prefer-free-formats']
[debug] User config: [u'--hls-use-mpegts']
[debug] Command-line args: [u'-v', u'-F', u'https://www.youtube.com/user/TheYoungTurks/live']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2016.03.18
[debug] Python version 2.7.10 - Linux-4.3.3-301.fc23.x86_64-x86_64-with-fedora-23-Twenty_Three
[debug] exe versions: ffmpeg 2.8.5, ffprobe 2.8.5, rtmpdump 2.4
[debug] Proxy map: {}
[youtube:user] TheYoungTurks: Downloading channel page
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading webpage
[download] Downloading playlist: Uploads from The Young Turks
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #1
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #2
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #3
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #4
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #5
[youtube:playlist] UU1yBKRuGpC1tSM73A0ZjYjQ: Downloading page #6
^C
ERROR: Interrupted by user
@scottywz scottywz changed the title Treat YouTube URLs of the format `/[user/]<username>/live` as live videos and not playlists if the channel is live YouTube - Treat YouTube URLs of the format `/[user/]<username>/live` as live videos and not playlists if the channel is live Mar 24, 2016
@jaimeMF jaimeMF added the request label Mar 24, 2016
@dstftw dstftw closed this in f07e276 Mar 24, 2016
@scottywz
Copy link
Author

@scottywz scottywz commented Mar 28, 2016

It still doesn't cover URLs that omit the user/ or channel/ part. It would be nice to see those covered in order to reduce the amount of typing necessary.

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