Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
[mixcloud] using --flat-playlist fails #15394
Comments
|
This is a Python 3.2-specific issue. We're going to drop support for Python 3.2. (#14515) Is there a reason for you to use Python 3.2? Python 2.7 should work just fine. |
|
I'm using a Python 3.2 build on Android as well as on Ubuntu 12.04 where it is the default. On Ubuntu I can replace it easily with a newer version probably, although on Android it is going to be more problematic to compile a newer version. And IIRC python 2.7 does not work properly on Android with TLS. |
|
For Ubuntu, you should consider upgrading to a newer version. 12.04 has been dropped by Canonical on April 28, 2017. And the default Python on 12.04 is 2.7. For Android, I guess you're using QPython? It's known to have several issues. I suggest a newer version. Currently I use https://github.com/yan12125/python3-android/ and TLS connections work just fine. |
|
Yup I'm going yo upgrade, thanks for the pointers. QPython has 3.6.1 Android binaries, going to try these. |
|
And you are right for Ubuntu 12.04. 2.7 is the default for Python2 while Python3 is v3.2.3. I vaguely remember having to switch to Python 3 a long time ago to fix an issue with Python 2 on some sites. |
|
If there's something wrong with Python 2 and youtube-dl, feel free to open a new bug. Python 2.7 will be supported for foreeable future. BTW, Termux is also an excellent package provider on Android. Just tried it and it's Python 3.6.4 works just fine with youtube-dl. |
|
Termux is indeed a very nice project and its Python works great, and for no less than 4 different archs (although it requires Lollipop+). Also thanks for the committed fix to still have it work with 3.2, this is appreciated. I saw you added compat b64 to a bunch of providers. |
Using --flat-playlist on mixcloud fails (this used to work). Omitting --flat-playlist works, but it would be great to have this issue fixed for consistency.
python3 youtube-dl -v https://www.mixcloud.com/rafatarg/ella-fitzgerald-and-louis-armstrong/ -J --flat-playlist
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.mixcloud.com/rafatarg/ella-fitzgerald-and-louis-armstrong/', '-J', '--flat-playlist']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2018.01.21
[debug] Python version 3.2.3 (CPython) - Linux-3.2.0-70-generic-x86_64-with-Ubuntu-12.04-precise
[debug] exe versions: avconv 0.10.12-7, avprobe 0.10.12-7, ffmpeg 0.10.12-7, ffprobe 0.10.12-7
[debug] Proxy map: {}
Traceback (most recent call last):
File "/usr/lib/python3.2/runpy.py", line 160, in _run_module_as_main
"main", fname, loader, pkg_name)
File "/usr/lib/python3.2/runpy.py", line 73, in _run_code
exec(code, run_globals)
File "youtube-dl/main.py", line 19, in
File "youtube-dl/youtube_dl/init.py", line 465, in main
File "youtube-dl/youtube_dl/init.py", line 455, in _real_main
File "youtube-dl/youtube_dl/YoutubeDL.py", line 1988, in download
File "youtube-dl/youtube_dl/YoutubeDL.py", line 784, in extract_info
File "youtube-dl/youtube_dl/extractor/common.py", line 438, in extract
File "youtube-dl/youtube_dl/extractor/mixcloud.py", line 112, in _real_extract
File "/usr/lib/python3.2/base64.py", line 83, in b64decode
raise TypeError("expected bytes, not %s" % s.class.name)
TypeError: expected bytes, not str