diff options
author | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-08-03 15:22:51 +0200 |
---|---|---|
committer | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-08-03 15:22:51 +0200 |
commit | 03950c90f778293e65e2b79f2cf8ea3274695460 (patch) | |
tree | 80123719aaa26b9767b79896ce90217a6274f820 /youtube_dl/compat.py | |
parent | 47a8b7c14a085ce558db3b5a85ded850cd5df642 (diff) | |
parent | dc48695ab9c84cda56ee723aee11e5da44c2258a (diff) |
Merge remote-tracking branch 'jaimemf/format_spec_groups' (closes #6124)
Diffstat (limited to 'youtube_dl/compat.py')
-rw-r--r-- | youtube_dl/compat.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/youtube_dl/compat.py b/youtube_dl/compat.py index e4b9286c0..ace5bd716 100644 --- a/youtube_dl/compat.py +++ b/youtube_dl/compat.py @@ -436,6 +436,11 @@ except TypeError: # Python 2.6 yield n n += step +if sys.version_info >= (3, 0): + from tokenize import tokenize as compat_tokenize_tokenize +else: + from tokenize import generate_tokens as compat_tokenize_tokenize + __all__ = [ 'compat_HTTPError', 'compat_basestring', @@ -457,6 +462,7 @@ __all__ = [ 'compat_socket_create_connection', 'compat_str', 'compat_subprocess_get_DEVNULL', + 'compat_tokenize_tokenize', 'compat_urllib_error', 'compat_urllib_parse', 'compat_urllib_parse_unquote', |