This isn't a scdl or Python issue, but about adding support for UNIXs without UTF-8 as the default locale.
OpenBSD has a custom UTF-8 OS locale that doesn't work well with Python3. Running
import sys
sys.getfilesystemencoding()
Yields:
'ascii'
I'm not well-versed in Python, but it should be as simple as checking for filesystemencoding (OS encoding) and if it's not UTF-8, strip it down (or ask for manual renaming) for every request -- or even just default to the url scheme.
To reproduce/test this, set LC_CTYPE=ascii as an environment variable and download a track with unicode characters. I.e
This isn't a scdl or Python issue, but about adding support for UNIXs without
UTF-8
as the default locale.OpenBSD has a custom UTF-8 OS locale that doesn't work well with Python3. Running
Yields:
I'm not well-versed in Python, but it should be as simple as checking for
filesystemencoding
(OS encoding) and if it's not UTF-8, strip it down (or ask for manual renaming) for every request -- or even just default to the url scheme.To reproduce/test this, set
LC_CTYPE=ascii
as an environment variable and download a track with unicode characters. I.eExactly like #245