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

twitch support fails if channel name contains uppercase characters #23917

Closed
madewokherd opened this issue Jan 31, 2020 · 0 comments
Closed

twitch support fails if channel name contains uppercase characters #23917

madewokherd opened this issue Jan 31, 2020 · 0 comments

Comments

@madewokherd
Copy link

@madewokherd madewokherd commented Jan 31, 2020

Checklist

  • I'm reporting a broken site support
  • I've verified that I'm running youtube-dl version 2020.01.24
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar issues including closed ones

Verbose log

C:\Users\madew>youtube-dl -v https://www.twitch.tv/SpeedrunHypeTV
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.twitch.tv/SpeedrunHypeTV']
[debug] Encodings: locale cp1252, fs utf-8, out utf-8, pref cp1252
[debug] youtube-dl version 2020.01.24
[debug] Python version 3.6.5 (CPython) - Windows-10-10.0.18362-SP0
[debug] exe versions: ffmpeg 4.0, ffprobe 4.0
[debug] Proxy map: {}
[twitch:stream] SpeedrunHypeTV: Downloading stream JSON
ERROR: SpeedrunHypeTV is offline
Traceback (most recent call last):
  File "c:\users\madew\appdata\local\programs\python\python36\lib\site-packages\youtube_dl\YoutubeDL.py", line 796, in extract_info
    ie_result = ie.extract(url)
  File "c:\users\madew\appdata\local\programs\python\python36\lib\site-packages\youtube_dl\extractor\common.py", line 530, in extract
    ie_result = self._real_extract(url)
  File "c:\users\madew\appdata\local\programs\python\python36\lib\site-packages\youtube_dl\extractor\twitch.py", line 582, in _real_extract
    raise ExtractorError('%s is offline' % channel_id, expected=True)
youtube_dl.utils.ExtractorError: SpeedrunHypeTV is offline

Description

When given a channel url with uppercase characters, the twitch extractor incorrectly reports that the channel is offline. For example:

C:\Users\madew>youtube-dl -s https://www.twitch.tv/SpeedrunHypeTV
[twitch:stream] SpeedrunHypeTV: Downloading stream JSON
ERROR: SpeedrunHypeTV is offline

C:\Users\madew>youtube-dl -s https://www.twitch.tv/speedrunhypetv
[twitch:stream] speedrunhypetv: Downloading stream JSON
[twitch:stream] speedrunhypetv: Downloading channel access token
[twitch:stream] speedrunhypetv: Downloading m3u8 information

The easy work-around is to convert to lowercase, but this behavior is confusing and incorrect because channel url's are case-insensitive in a browser.

@dstftw dstftw closed this in 00de61a Jan 31, 2020
bbepis referenced this issue in animelover1984/youtube-dl Feb 6, 2020
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
1 participant
You can’t perform that action at this time.