diff options
author | Sergey M․ <dstftw@gmail.com> | 2014-12-30 22:46:23 +0600 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2014-12-30 22:46:23 +0600 |
commit | e83eebb12f984c1614204e53c09dc5124b52b45c (patch) | |
tree | 7da3c8725a6ceb805778e7a6d598a9feeb805bf0 | |
parent | a349873226c873a2f3bea9f5dffe167053cb1666 (diff) |
[atresplayer] Fix python3 bug
-rw-r--r-- | youtube_dl/extractor/atresplayer.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/youtube_dl/extractor/atresplayer.py b/youtube_dl/extractor/atresplayer.py index 7e987b2a0..72e83bfc2 100644 --- a/youtube_dl/extractor/atresplayer.py +++ b/youtube_dl/extractor/atresplayer.py @@ -56,7 +56,10 @@ class AtresPlayerIE(InfoExtractor): self._TIME_API_URL, video_id, 'Downloading timestamp', fatal=False), 1000, time.time()) timestamp_shifted = compat_str(timestamp + self._TIMESTAMP_SHIFT) - token = hmac.new(self._MAGIC.encode('utf-8'), episode_id + timestamp_shifted).hexdigest() + token = hmac.new( + self._MAGIC.encode('ascii'), + (episode_id + timestamp_shifted).encode('utf-8') + ).hexdigest() formats = [] for fmt in ['windows', 'android_tablet']: |