Changes between Version 3 and Version 4 of Ticket #3610, comment 4


Ignore:
Timestamp:
02/04/2016 04:52:11 PM (4 years ago)
Author:
sebastian
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #3610, comment 4

    v3 v4  
    1 It seems that the reason it works when reading files from the local file system directly, is that Python automatically encodes filenames, e.g. when calling `open()`, according to [https://docs.python.org/2/library/sys.html#sys.getfilesystemencoding sys.getfilesystemencoding()]. 
     1It seems that the reason it works when reading files from the local file system directly, is that Python automatically encodes filenames, e.g. when calling `open()`, according to [https://docs.python.org/2/library/sys.html#sys.getfilesystemencoding sys.getfilesystemencoding()]. This however, isn't always `UTF-8`. 
    22 
    3 This however, isn't always `UTF-8`. So it seems that if we want to ensure consistent behavior here, we have to manually decode/encode filenames in both cases. But apparently Windows uses Unicode natively. So no idea what happens if you pass encoded `UTF-8` to a file API there. 
     3So it seems that if we want to ensure consistent behavior here, we have to manually decode/encode filenames in both cases. But apparently Windows uses Unicode natively. So no idea what happens if you pass encoded `UTF-8` to a file API there.