You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
the source parameter is our filename, and will be encoded to 'utf-8', not legacy 'mbcs' in python 3.6
and finally passed to open() in io.c:new_file_source
thus interpreted as a mbcs string, so, the "File not found" exception is not suprised
maybe this should be the responsiblity of cython for python 3.6 to handle these things by using unicode version of windows API,
but for now, we just replace sys.getfilesystemencoding() to "mbcs"
The text was updated successfully, but these errors were encountered:
mfmain
changed the title
read_csv(filename_with_asian_locale) failed in python 3.6
read_csv(filename_with_asian_locale) failed in python 3.6 for windows
Jun 5, 2017
Code:
Problem description
python 3.6 changed sys.getfilesystemencoding() to return "utf-8" instead of "mbcs"
see PEP 529.
How to fix
Here is the problem: parsers.pyx
the source parameter is our filename, and will be encoded to 'utf-8', not legacy 'mbcs' in python 3.6
and finally passed to open() in io.c:new_file_source
thus interpreted as a mbcs string, so, the "File not found" exception is not suprised
maybe this should be the responsiblity of cython for python 3.6 to handle these things by using unicode version of windows API,
but for now, we just replace sys.getfilesystemencoding() to "mbcs"
The text was updated successfully, but these errors were encountered: